Source cleanup + SQL structure

This commit is contained in:
flash 2021-05-05 17:52:04 +02:00
parent 0a428332bd
commit b582f6e105
9 changed files with 162 additions and 544 deletions

154
chie.sql Normal file
View File

@ -0,0 +1,154 @@
-- --------------------------------------------------------
-- Host: 127.0.0.1
-- Server version: 10.4.18-MariaDB-1:10.4.18+maria~bionic-log - mariadb.org binary distribution
-- Server OS: debian-linux-gnu
-- HeidiSQL Version: 11.2.0.6213
-- --------------------------------------------------------
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET NAMES utf8 */;
/*!50503 SET NAMES utf8mb4 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
-- Dumping database structure for flash_forum
CREATE DATABASE IF NOT EXISTS `flash_forum` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_bin */;
USE `flash_forum`;
-- Dumping structure for table flash_forum.fmf_categories
CREATE TABLE IF NOT EXISTS `fmf_categories` (
`cat_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`cat_order` smallint(6) NOT NULL DEFAULT 0,
`cat_type` tinyint(3) unsigned NOT NULL DEFAULT 0,
`cat_parent` int(10) unsigned NOT NULL DEFAULT 0,
`cat_variation` tinyint(3) unsigned NOT NULL DEFAULT 0,
`cat_created` timestamp NOT NULL DEFAULT current_timestamp(),
`cat_name` varchar(50) COLLATE utf8mb4_bin NOT NULL,
`cat_description` text COLLATE utf8mb4_bin DEFAULT NULL,
`cat_link` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL,
`cat_count_topics` int(10) unsigned NOT NULL DEFAULT 0,
`cat_count_posts` int(10) unsigned NOT NULL DEFAULT 0,
`cat_last_post_id` int(10) unsigned DEFAULT NULL,
PRIMARY KEY (`cat_id`),
KEY `categories_type_key` (`cat_type`),
KEY `categories_parent_key` (`cat_parent`),
KEY `categories_order_key` (`cat_order`),
KEY `categories_last_post_foreign` (`cat_last_post_id`),
CONSTRAINT `categories_last_post_foreign` FOREIGN KEY (`cat_last_post_id`) REFERENCES `fmf_posts` (`post_id`) ON DELETE SET NULL ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
-- Data exporting was unselected.
-- Dumping structure for table flash_forum.fmf_posts
CREATE TABLE IF NOT EXISTS `fmf_posts` (
`post_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`topic_id` int(10) unsigned NOT NULL,
`cat_id` int(10) unsigned NOT NULL,
`user_id` int(10) unsigned DEFAULT NULL,
`post_type` tinyint(3) unsigned NOT NULL DEFAULT 0,
`post_created` timestamp NOT NULL DEFAULT current_timestamp(),
`post_edited` timestamp NULL DEFAULT NULL,
`post_deleted` timestamp NULL DEFAULT NULL,
`post_text` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
PRIMARY KEY (`post_id`),
KEY `posts_topic_foreign` (`topic_id`),
KEY `posts_user_foreign` (`user_id`),
KEY `posts_category_foreign` (`cat_id`),
KEY `posts_created_key` (`post_created`),
KEY `posts_deleted_key` (`post_deleted`),
FULLTEXT KEY `posts_text_fulltext` (`post_text`),
CONSTRAINT `posts_category_foreign` FOREIGN KEY (`cat_id`) REFERENCES `fmf_categories` (`cat_id`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `posts_topic_foreign` FOREIGN KEY (`topic_id`) REFERENCES `fmf_topics` (`topic_id`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `posts_user_foreign` FOREIGN KEY (`user_id`) REFERENCES `fmf_users` (`user_id`) ON DELETE SET NULL ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
-- Data exporting was unselected.
-- Dumping structure for table flash_forum.fmf_sessions
CREATE TABLE IF NOT EXISTS `fmf_sessions` (
`sess_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`user_id` int(10) unsigned NOT NULL,
`sess_key` char(64) COLLATE utf8mb4_bin NOT NULL,
`sess_created` timestamp NOT NULL DEFAULT current_timestamp(),
PRIMARY KEY (`sess_id`),
UNIQUE KEY `sessions_key_unique` (`sess_key`),
KEY `sessions_user_foreign` (`user_id`),
KEY `sessions_created_key` (`sess_created`),
CONSTRAINT `sessions_user_foreign` FOREIGN KEY (`user_id`) REFERENCES `fmf_users` (`user_id`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
-- Data exporting was unselected.
-- Dumping structure for table flash_forum.fmf_topics
CREATE TABLE IF NOT EXISTS `fmf_topics` (
`topic_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`cat_id` int(10) unsigned NOT NULL,
`user_id` int(10) unsigned NOT NULL,
`topic_created` timestamp NOT NULL DEFAULT current_timestamp(),
`topic_bumped` timestamp NULL DEFAULT NULL,
`topic_locked` timestamp NULL DEFAULT NULL,
`topic_resolved` timestamp NULL DEFAULT NULL,
`topic_confirmed` timestamp NULL DEFAULT NULL,
`topic_title` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
`topic_count_replies` int(10) unsigned NOT NULL DEFAULT 0,
`topic_last_post_id` int(10) unsigned DEFAULT NULL,
PRIMARY KEY (`topic_id`),
KEY `topics_category_foreign` (`cat_id`),
KEY `topics_bumped_key` (`topic_bumped`),
KEY `topics_title_key` (`topic_title`),
KEY `topics_user_foreign` (`user_id`),
KEY `topic_last_post_foreign` (`topic_last_post_id`),
CONSTRAINT `topic_last_post_foreign` FOREIGN KEY (`topic_last_post_id`) REFERENCES `fmf_posts` (`post_id`) ON DELETE SET NULL ON UPDATE CASCADE,
CONSTRAINT `topics_category_foreign` FOREIGN KEY (`cat_id`) REFERENCES `fmf_categories` (`cat_id`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `topics_user_foreign` FOREIGN KEY (`user_id`) REFERENCES `fmf_users` (`user_id`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
-- Data exporting was unselected.
-- Dumping structure for table flash_forum.fmf_track
CREATE TABLE IF NOT EXISTS `fmf_track` (
`cat_id` int(10) unsigned NOT NULL,
`topic_id` int(10) unsigned NOT NULL,
`user_id` int(10) unsigned NOT NULL,
`track_timestamp` timestamp NOT NULL DEFAULT current_timestamp(),
UNIQUE KEY `track_unique` (`topic_id`,`user_id`),
KEY `track_category_foreign` (`cat_id`),
KEY `track_topic_foreign` (`topic_id`),
KEY `track_user_foreign` (`user_id`),
KEY `track_timestamp_key` (`track_timestamp`),
CONSTRAINT `track_category_foreign` FOREIGN KEY (`cat_id`) REFERENCES `fmf_categories` (`cat_id`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `track_topic_foreign` FOREIGN KEY (`topic_id`) REFERENCES `fmf_topics` (`topic_id`) ON DELETE CASCADE ON UPDATE CASCADE,
CONSTRAINT `track_user_foreign` FOREIGN KEY (`user_id`) REFERENCES `fmf_users` (`user_id`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
-- Data exporting was unselected.
-- Dumping structure for table flash_forum.fmf_users
CREATE TABLE IF NOT EXISTS `fmf_users` (
`user_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`user_login` varchar(16) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
`user_email` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
`user_email_verification` char(32) COLLATE utf8mb4_bin DEFAULT NULL,
`user_password` varchar(255) CHARACTER SET ascii COLLATE ascii_bin NOT NULL,
`user_moderator` tinyint(3) unsigned NOT NULL DEFAULT 0,
`user_created` timestamp NOT NULL DEFAULT current_timestamp(),
`user_ip_created` varbinary(16) NOT NULL,
`user_date_format` varchar(50) COLLATE utf8mb4_bin NOT NULL DEFAULT 'D Y-m-d H:i:s T',
`user_time_zone` varchar(50) COLLATE utf8mb4_bin NOT NULL DEFAULT 'UTC',
`user_flags` int(10) unsigned NOT NULL DEFAULT 0,
`user_banned` timestamp NULL DEFAULT NULL,
`user_banned_reason` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL,
PRIMARY KEY (`user_id`),
UNIQUE KEY `users_login_unique` (`user_login`),
UNIQUE KEY `users_email_unique` (`user_email`),
UNIQUE KEY `users_email_verification_unique` (`user_email_verification`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
-- Data exporting was unselected.
/*!40101 SET SQL_MODE=IFNULL(@OLD_SQL_MODE, '') */;
/*!40014 SET FOREIGN_KEY_CHECKS=IFNULL(@OLD_FOREIGN_KEY_CHECKS, 1) */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40111 SET SQL_NOTES=IFNULL(@OLD_SQL_NOTES, 1) */;

View File

@ -2,7 +2,7 @@
include_once '_utils.php';
define('FMF_UF_SCROLLBEYOND', 1);
define('FMF_UF_NEWSTYLE', 2);
//define('FMF_UF_NEWSTYLE', 2);
function get_user_id(string $username, string $email): int {
global $pdo;
@ -217,7 +217,7 @@ function verify_password(string $pass, ?int $user = null): bool {
function user_set_password(int $user, string $password): void {
global $pdo;
if($user < 1)
return;
@ -231,7 +231,7 @@ function user_set_password(int $user, string $password): void {
function user_set_email(int $user, string $email, bool $verified = false): ?string {
global $pdo;
if($user < 1)
return null;

View File

@ -1,11 +1,4 @@
<?php if(isset($_GET['_new'])): ?>
</div>
<?php endif; ?>
<div class="footer">
<?php if(isset($_GET['_new'])): ?>
<div class="footer-text">&copy; flashwave 2010-2020 - powered by Chie</div>
<script src="//flash.moe/assets/2020v2.js" charset="utf-8" type="text/javascript"></script>
<?php else: ?>
Powered by Chie<br/>
&copy; <a href="https://flash.moe">Flashwave</a> 2019-<?=date('Y');?>
<?php
@ -16,22 +9,7 @@ if(!empty($extendedFooter)) {
<?php
}
?>
<?php endif; ?>
</div>
</div>
<script type="text/javascript">
var _paq = window._paq || [];
_paq.push(['disableCookies']);
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
_paq.push(['setTrackerUrl', '//uiharu.railgun.sh/mtm']);
_paq.push(['setSiteId', 'w4PqjBGmOL5l']);
var g = document.createElement('script');
g.type = 'text/javascript'; g.async = true;
g.defer = true; g.src = '//uiharu.railgun.sh/mtm.js';
document.head.appendChild(g);
})();
</script>
</body>
</html>

View File

@ -1,8 +1,5 @@
<?php
include_once '_user.php';
if(user_has_flag(current_user_id(), FMF_UF_NEWSTYLE))
$_GET['_new'] = true;
?>
<!doctype html>
<html>
@ -10,41 +7,10 @@ if(user_has_flag(current_user_id(), FMF_UF_NEWSTYLE))
<meta charset="utf-8"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title><?=$title ?? 'flash.moe message board';?></title>
<?php if(isset($_GET['_new'])): ?>
<link href="//flash.moe/assets/2020v2.css" type="text/css" rel="stylesheet"/>
<link href="//flash.moe/assets/sprite.css" type="text/css" rel="stylesheet"/>
<link href="//flash.moe/css/electrolize/style.css" type="text/css" rel="stylesheet"/>
<link href="/style2.css" type="text/css" rel="stylesheet"/>
<?php else: ?>
<link href="/style.css" type="text/css" rel="stylesheet"/>
<?php endif; ?>
</head>
<body>
<?php if(!isset($_GET['_new'])): ?>
<div class="wrapper<?php if(user_has_flag(current_user_id(), FMF_UF_SCROLLBEYOND)) { echo ' scrollbeyond'; }?>">
<?php endif; ?>
<div class="header">
<?php if(isset($_GET['_new'])): ?>
<div class="header-background">
<img src="//flash.moe/assets/headers/mkt-044.jpg" alt="//flash.moe/assets/headers/mkt-044.jpg"/>
</div>
<div class="header-foreground">
<a class="header-logo" href="/">
<div class="header-flash">flash.moe&nbsp;</div>
<div class="header-wave">message board</div>
</a>
<div class="header-menu">
<a href="/">Home</a>
<?php if(session_active()) { ?>
<a href="/settings">Settings</a>
<a href="/logout/<?=logout_token();?>">Log out</a>
<?php } else { ?>
<a href="/login">Log in</a>
<a href="/register">Register</a>
<?php } ?>
</div>
</div>
<?php else: ?>
<h1>flash.moe message board</h1>
<div class="header-wrap">
<div class="header-nav">
@ -64,19 +30,4 @@ if(user_has_flag(current_user_id(), FMF_UF_NEWSTYLE))
</form>
<?php } ?>
</div>
<?php endif; ?>
</div>
<?php if(isset($_GET['_new'])): ?>
<div class="container">
<div class="wrapper<?php if(user_has_flag(current_user_id(), FMF_UF_SCROLLBEYOND)) { echo ' scrollbeyond'; }?>">
<?php if(empty($hideSearch)) { ?>
<form method="get" action="/search" class="header-search">
<input type="search" name="q"/>
<input type="submit" value="Search"/>
</form>
<?php } ?>
<?php endif; ?>
<div class="forum-shutdown">
This message board will be taken offline in May 2021. Registration and posting have already been disabled.<br/>
<a href="https://flashii.net/forum/topic.php?t=688">Musewave support has moved to a forum topic on Flashii.net.</a>
</div>

View File

@ -1,26 +0,0 @@
<?php
require_once '../../startup.php';
header('Content-Type: text/plain; charset=utf-8');
function die_gh(int $code, string $msg = ''): void {
http_response_code($code);
echo $msg;
exit;
}
if(!defined('GITHUB_SECRET') || empty(GITHUB_SECRET))
die_gh(500, 'no token defined');
$rawBody = file_get_contents('php://input');
if(empty($rawBody))
die_gh(404, 'no data');
$sig = explode('=', $_SERVER['HTTP_X_HUB_SIGNATURE'], 2);
if(count($sig) !== 2 || $sig[0] !== 'sha1' || !hash_equals(hash_hmac($sig[0], $rawBody, GITHUB_SECRET), $sig[1]))
die_gh(403, 'invalid signature');
$body = json_decode($_SERVER['CONTENT_TYPE'] === 'application/x-www-form-urlencoded' ? $_POST['payload'] : $rawBody);

View File

@ -1,8 +1,6 @@
<?php
require_once '../startup.php';
die_ex('Posting has been disabled.', 200);
include_once '_category.php';
include_once '_user.php';
include_once '_topics.php';
@ -39,7 +37,7 @@ if($postId > 0) {
if($topicId > 0) {
$topicInfo = topic_info($topicId);
if(empty($topicInfo))
die_ex('Topic not found.', 404);

View File

@ -1,8 +1,6 @@
<?php
require_once '../startup.php';
die_ex('Registration has been disabled. Thank you for your interest.', 200);
include_once '_user.php';
if(session_active()) {
@ -34,7 +32,7 @@ if(empty($antiSpam)) {
if(isset($_POST['username'], $_POST['password'], $_POST['password_confirm'], $_POST['email']) && CSRF::verify()) {
$antiSpamValue = isset($_POST[$antiSpam]) && is_string($_POST[$antiSpam]) ? $_POST[$antiSpam] : '';
if($antiSpamValue !== ANTI_SPAM_ANSWER) {
$error = 'Please check the value of the last form again.';
} else {
@ -50,7 +48,7 @@ if(isset($_POST['username'], $_POST['password'], $_POST['password_confirm'], $_P
$error = 'This username or e-mail address has already been used.';
} else {
$registerInfo = create_user($username, $email, $password, $_SERVER['REMOTE_ADDR']);
if($registerInfo['user_id'] < 1) {
$error = 'Failed to create user.';
} else {

View File

@ -10,7 +10,6 @@ if(!session_active()) {
$options = [
FMF_UF_SCROLLBEYOND => 'Scroll beyond end of the page.',
FMF_UF_NEWSTYLE => 'Preview new style.',
];
$timeZones = DateTimeZone::listIdentifiers();
@ -112,10 +111,10 @@ foreach($timeZones as $key => $timeZone) {
uasort($timeZones, function($a, $b) {
$diff = $a->offset <=> $b->offset;
if($diff === 0)
return strcmp($a->getName(), $b->getName());
return $diff;
});

View File

@ -1,434 +0,0 @@
h1 {
color: #9DAAD9;
font-weight: bold;
font-size: 22px;
text-decoration: none;
}
h2 {
font-weight: bold;
font-size: 22px;
text-decoration: none;
line-height: 120%;
}
h3 {
font-size: 1.3em;
font-weight: bold;
line-height: 120%;
}
h4 {
margin: 0;
font-size: 1.1em;
font-weight: bold;
}
p {
font-size: 1.1em;
}
h3 > a {
display: inline-block;
padding: 2px 5px;
}
input[type="text"],
input[type="password"],
input[type="email"],
input[type="search"],
input[type="submit"],
input[type="reset"],
input[type="button"] {
color: #9daad9;
font-family: Tahoma, Geneva, 'Dejavu Sans', Arial, Helvetica, sans-serif;
font-size: 12px;
font-weight: 400;
padding: 2px;
border: 1px solid #9daad9;
background-color: #191E33;
}
input[type="button"],
input[type="reset"],
input[type="submit"] {
cursor: pointer;
padding: 2px 4px;
}
input[type="submit"] {
font-weight: 700;
}
textarea {
background-color: #191E33;
color: #9DAAD9;
font-family: Tahoma, Geneva, 'Dejavu Sans', Arial, Helvetica, sans-serif;
font-weight: normal;
border: 1px solid #A9B8C2;
padding: 2px;
font-size: 12px;
}
select {
color: #9DAAD9;
background-color: #191E33;
font-family: Tahoma, Geneva, 'Dejavu Sans', Arial, Helvetica, sans-serif;
font-size: 11px;
font-weight: normal;
border: 1px solid #A9B8C2;
padding: 1px;
}
option {
padding: 0 1em 0 0;
}
.wrapper {
margin: 0 auto;
width: 100%;
max-width: 1000px;
}
.wrapper.scrollbeyond {
padding-bottom: 100vh;
}
.wrapper a {
color: #567194;
text-decoration: none;
transition: color .1s;
}
.wrapper a:active {
color: #4C5A8E;
text-decoration: none;
}
.wrapper a:hover {
color: #FFFFFF;
text-decoration: underline;
}
.forum-category,
.topics {
border: 1px solid #000;
background-color: #191e33;
color: #cecece;
margin: 4px 0;
}
.forum-category-title,
.topics-header {
font-weight: 700;
display: flex;
align-items: center;
}
.forum-category-title-info,
.topics-header-info {
flex: 1 1 auto;
padding: 4px 5px;
}
.forum-category-board,
.topics-item {
border-top: 1px solid #000;
background-color: #1a2237;
display: flex;
align-items: center;
min-height: 40px;
}
.forum-category-board-indicator,
.topics-item-indicator,
.topics-item-indicator-closed,
.topics-item-indicator-locked {
width: 20px;
height: 20px;
line-height: 20px;
border: 1px solid #000;
flex: 0 0 auto;
margin: 5px;
background-color: #1a2237;
}
.topics-item-indicator-closed {
background-color: #0c0;
margin-left: 0;
}
.topics-item-indicator-locked {
background-color: #c00;
margin-left: 0;
}
.forum-category-board-indicator.unread,
.topics-item-indicator.unread {
background-color: #4D556A;
}
.topics-item-indicator,
.topics-item-indicator-closed,
.topics-item-indicator-locked {
width: 16px;
height: 16px;
line-height: 16px;
}
.forum-category-board-info,
.topics-item-info {
flex: 1 1 auto;
}
.forum-category-count,
.topics-item-count {
width: 60px;
text-align: center;
padding: 4px 5px;
}
.forum-category-latest,
.topics-item-author,
.topics-item-created,
.topics-item-latest {
width: 120px;
text-align: center;
}
.topics-item-created time,
.forum-category-latest time,
.topics-item-latest time {
font-size: .9em;
line-height: 1.2em;
display: inline-block;
}
.forum-category-latest-header,
.topics-item-latest-header {
padding: 4px 5px;
}
.forum-category-board-desc {
font-size: .9em;
line-height: 1.2em;
}
.topics-item-status {
display: inline-block;
margin-right: 4px;
}
.auth-form {
max-width: 300px;
margin: 5px auto;
}
.auth-header {
padding: 5px 0;
}
.auth-field {
margin: 5px 0;
display: block;
}
.auth-field-value input {
width: 100%;
}
.auth-buttons {
text-align: center;
padding: 5px;
}
.auth-message {
text-align: center;
}
.auth-message-error {
color: #f00;
}
.forum-title {
padding: 2px 5px;
}
.posting-header {
display: flex;
padding: 4px 0;
}
.posting-title {
flex: 1 1 auto;
}
.posting-submit {
margin-left: 4px;
}
.posting-text {
display: block;
width: 100%;
min-width: 100%;
max-width: 100%;
min-height: 500px;
}
.posting-message {
padding: 0 3px;
}
.posting-message-error {
color: #f00;
}
.createtopicbtn,
.topic-btns a {
display: inline-block;
color: #fff !important;
text-decoration: none !important;
font-size: 12px;
font-weight: 400;
padding: 5px 10px;
background-color: #393939;
background-image: linear-gradient(0deg, #1118 0%, #2228 50%, #3338 50%, #5558 100%);
border-radius: 5px;
overflow: hidden;
cursor: pointer;
filter: drop-shadow(0 1px 5px #000);
margin: 5px 0;
margin-right: 10px;
}
.search-form {
display: flex;
}
.search-input {
flex: 1 1 auto;
}
.search-submit {
margin-left: 4px;
}
.post {
display: flex;
border: 1px solid #000;
background-color: #191e33;
color: #cecece;
margin: 2px 0;
}
.post-details {
flex: 0 0 auto;
width: 120px;
display: flex;
flex-direction: column;
align-items: center;
border: 0 solid #000;
border-right-width: 1px;
}
.post-permalink-wrap {
text-align: center;
font-size: .9em;
line-height: 1.4em;
}
.post-username {
font-size: 1.2em;
line-height: 1.5em;
}
.post-details * {
margin: 1px 0;
}
/*@media(max-width: 600px) {*/
.post {
flex-direction: column;
}
.post-details {
border-right-width: 0;
border-bottom-width: 1px;
width: 100%;
flex-direction: row;
}
.post-avatar {
width: 40px;
height: 40px;
order: 1;
margin: 5px;
}
.post-username {
order: 2;
padding: 10px;
}
.post-permalink-wrap {
order: 3;
flex: 1 1 auto;
text-align: right !important;
}
.post-permalink {
padding: 10px;
}
/*}*/
.post-text {
flex: 1 1 auto;
background-color: #1a2237;
min-height: 160px;
padding: 2px 5px;
display: flex;
flex-direction: column;
}
.post-text-inner {
flex: 1 1 auto;
padding: 3px 0;
word-wrap: normal;
word-break: break-word;
}
.post-footer {
display: flex;
flex: 0 0 auto;
font-size: .9em;
}
.post-edited {
flex: 1 1 auto;
font-style: italic;
}
.post-options {
flex: 0 0 auto;
}
.post-options a {
margin: 0 5px;
}
.post-deleted .post-text {
min-height: 0;
}
.setting {
margin: 10px 0;
}
.setting-head h3 {
line-height: 1.5em;
}
.setting-value input[type="text"],
.setting-value input[type="password"],
.setting-value input[type="email"],
.setting-value select {
min-width: 400px;
margin: 1px 0;
}
.settings-message {
padding: 0 3px;
}
.settings-message-error {
color: #f00;
}
.settings-option {
margin: 2px 0;
padding: 0 4px;
display: block;
}
.event {
display: block;
border: 1px solid #000;
background-color: #191e33;
color: #cecece;
margin: 2px 0;
}
.event-msg {
margin: 4px;
display: flex;
}
.event-msg img {
vertical-align: bottom;
}
.event-msg time {
font-size: .9em;
margin: 0 4px;
}
.event-msg-text {
flex: 1 1 auto;
margin: 0 4px;
}
.notice {
display: block;
border: 1px solid #000;
background-color: #1a2237;
color: #cecece;
margin: 2px 0;
padding: 4px;
}
.header-search {
}