mirror of https://gitgud.io/fatchan/jschan.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
59 lines
2.5 KiB
59 lines
2.5 KiB
extends ../layout.pug
|
|
|
|
block head
|
|
title Edit Post
|
|
|
|
block content
|
|
h1.board-title Edit Post
|
|
.form-wrapper.flex-center.mv-10
|
|
form.form-post(action='/forms/editpost' method='POST')
|
|
input(type='hidden' name='_csrf' value=csrf)
|
|
input(type='hidden' name='board' value=post.board)
|
|
input(type='hidden' name='postId' value=post.postId)
|
|
.anchor(id=post.postId)
|
|
div(class=`mv-5 post-container ${post.thread || ban === true ? '' : 'op'}` data-board=post.board data-post-id=post.postId data-user-id=post.userId)
|
|
- const postURL = `/${post.board}/thread/${post.thread || post.postId}.html`;
|
|
.post-info
|
|
span.noselect
|
|
label
|
|
if !post.thread
|
|
include ../includes/posticons.pug
|
|
input.edit.post-subject(value=post.subject placeholder='Subject' type='text' name='subject' maxlength=globalLimits.fieldLength.subject)
|
|
input.edit.post-name(value=post.email type='text' name='email' placeholder='Email' maxlength=globalLimits.fieldLength.email)
|
|
input.edit.post-name(type='text' name='name' placeholder='Name' maxlength=globalLimits.fieldLength.name value=post.name+(post.capcode || ''))
|
|
if post.country && post.country.code
|
|
span(class=`flag flag-${post.country.code.toLowerCase()}` title=post.country.name alt=post.country.name)
|
|
|
|
|
if post.tripcode
|
|
span.post-tripcode #{post.tripcode}
|
|
|
|
|
if post.capcode
|
|
span.post-capcode #{post.capcode}
|
|
|
|
|
- const postDate = new Date(post.date);
|
|
time.post-date.reltime(datetime=postDate.toISOString()) #{postDate.toLocaleString(undefined, { hourCycle:'h23' })}
|
|
|
|
|
if post.userId
|
|
span.user-id(style=`background-color: #${post.userId}`) #{post.userId}
|
|
|
|
|
span.post-links
|
|
a.noselect.no-decoration(href=`${postURL}#${post.postId}`) No.
|
|
span.post-quoters
|
|
a.no-decoration(href=`${postURL}#postform`) #{post.postId}
|
|
if !post.thread
|
|
|
|
|
span.noselect: a(href=`${postURL}#postform`) [Reply]
|
|
.post-data
|
|
pre.post-message
|
|
textarea.edit.fw(name='message' rows='15' placeholder='Message') #{post.nomarkup}
|
|
if post.banmessage
|
|
p.ban
|
|
span.message USER WAS BANNED FOR THIS POST
|
|
|
|
|
span.reason(data-reason=post.banmessage) #{post.banmessage}
|
|
label.mt-5
|
|
input.post-check(type='checkbox', name='hide_name' value='1')
|
|
| Hide Username
|
|
label.mv-5
|
|
input(type='text', name='log_message', placeholder='Modlog message' autocomplete='off')
|
|
input(type='submit', value='save')
|
|
|