Better markdown editor for create_thread

This commit is contained in:
Akif9748 2022-09-23 23:20:00 +03:00
parent b8b10a71c5
commit 43720f0ca0
3 changed files with 8 additions and 7 deletions

View file

@ -23,7 +23,5 @@ form {
} }
.CodeMirror { .CodeMirror {
width: 100%;
width: 422.5px;
} }

View file

@ -8,7 +8,7 @@ app.get("/", async (req, res) => {
const const
mem = process.memoryUsage().heapUsed / Math.pow(2, 20), mem = process.memoryUsage().heapUsed / Math.pow(2, 20),
users = await UserModel.count({ deleted: false }), users = await UserModel.count({ deleted: false }),
threads = await ThreadModel.count({ state: "DELETED"}), threads = await ThreadModel.count({ state: "OPEN" }),
messages = await MessageModel.count({ deleted: false }); messages = await MessageModel.count({ deleted: false });
res.reply("index", { mem, users, threads, messages }) res.reply("index", { mem, users, threads, messages })

View file

@ -13,7 +13,9 @@
<h2 class="title" style="align-self: baseline;">Title:</h2> <h2 class="title" style="align-self: baseline;">Title:</h2>
<input name="title" class="input" required></input> <input name="title" class="input" required></input>
<h2 class="title" style="align-self: baseline;">Content:</h2> <h2 class="title" style="align-self: baseline;">Content:</h2>
<textarea rows="4" cols="50" name="content" id="textarea" class="input" ></textarea> <div style="width: 100%;">
<textarea id="textarea"></textarea>
</div>
<h2 class="title" style="align-self: baseline;">Category:</h2> <h2 class="title" style="align-self: baseline;">Category:</h2>
<select name="category"> <select name="category">
@ -33,7 +35,8 @@
enabled: true, enabled: true,
uniqueId: "thread-create", uniqueId: "thread-create",
delay: 1000, delay: 1000,
}, },// width: 100%;
element: textarea, element: textarea,
spellChecker: false spellChecker: false