chore: format views and remove some unused classes and divs

This commit is contained in:
Floorb 2023-06-01 17:48:58 -04:00
parent 19b2deda2a
commit 5362be443c
15 changed files with 305 additions and 236 deletions

View file

@ -51,9 +51,7 @@
</style> </style>
<main class="bd-main"> <main class="bd-main">
<div class="preloader"></div> <div class="container">
<div class="bd-side-background"></div>
<div class="bd-main-container container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<article class="message is-info"> <article class="message is-info">
@ -67,7 +65,8 @@
<h1 class="title is-4">Pastes Archive</h1> <h1 class="title is-4">Pastes Archive</h1>
<form class="table_filterer" method="GET"> <form class="table_filterer" method="GET">
<label><i class="fa fa-search"></i> <label><i class="fa fa-search"></i>
<input class="search" type="search" name="q" placeholder="Filter..." value="<?= pp_html_escape($filter_value); ?>" /> <input class="search" type="search" name="q" placeholder="Filter..."
value="<?= pp_html_escape($filter_value); ?>"/>
</label> </label>
<label> <label>
Show&nbsp; Show&nbsp;

View file

@ -97,9 +97,11 @@ $flashes = getFlashes();
</a> </a>
<?php if ($current_user !== null && $current_user->role >= User::ROLE_MODERATOR): ?> <?php if ($current_user !== null && $current_user->role >= User::ROLE_MODERATOR): ?>
<?php $has_reports = Report::where(['open' => true])->count() > 0; ?> <?php $has_reports = Report::where(['open' => true])->count() > 0; ?>
<a class="button navbar-item mx-2" href="/admin" <?= $has_reports ? 'style="color: red;"' : '' ?>> <a class="button navbar-item mx-2"
href="/admin" <?= $has_reports ? 'style="color: red;"' : '' ?>>
<span class="icon has-text-info"> <span class="icon has-text-info">
<i class="fa <?= $has_reports ? 'fa-exclamation' : 'fa-toolbox' ?>" aria-hidden="true" <?= $has_reports ? 'style="color: red;"' : '' ?>></i> <i class="fa <?= $has_reports ? 'fa-exclamation' : 'fa-toolbox' ?>"
aria-hidden="true" <?= $has_reports ? 'style="color: red;"' : '' ?>></i>
</span> </span>
<span>Admin</span> <span>Admin</span>
</a> </a>
@ -107,7 +109,8 @@ $flashes = getFlashes();
<?php endif; /* !$site_is_private */ ?> <?php endif; /* !$site_is_private */ ?>
<div class="navbar-item has-dropdown is-hoverable"> <div class="navbar-item has-dropdown is-hoverable">
<a class="navbar-link" role="presentation"><?= pp_html_escape($current_user->username) ?></a> <a class="navbar-link"
role="presentation"><?= pp_html_escape($current_user->username) ?></a>
<div class="navbar-dropdown"> <div class="navbar-dropdown">
<a class="navbar-item" href="<?= urlForMember($current_user) ?>">Pastes</a> <a class="navbar-item" href="<?= urlForMember($current_user) ?>">Pastes</a>
<a class="navbar-item" href="<?= urlForPage('profile') ?>">Settings</a> <a class="navbar-item" href="<?= urlForPage('profile') ?>">Settings</a>
@ -140,7 +143,8 @@ $flashes = getFlashes();
<span>Events</span> <span>Events</span>
</a> </a>
<?php endif; ?> <?php endif; ?>
<a class="button is-info modal-button" data-target="#signin" href="/login?login">Sign In / Up</a> <a class="button is-info modal-button" data-target="#signin" href="/login?login">Sign In /
Up</a>
</div> </div>
<?php endif; ?> <?php endif; ?>
</div> </div>
@ -150,7 +154,8 @@ $flashes = getFlashes();
</nav> </nav>
<?php if ($current_user): ?> <?php if ($current_user): ?>
<div class="hidden" id="js-data-holder" data-user-id="<?= $current_user->id ?>" data-csrf-token="<?= $csrf_token ?>"></div> <div class="hidden" id="js-data-holder" data-user-id="<?= $current_user->id ?>"
data-csrf-token="<?= $csrf_token ?>"></div>
<?php endif; ?> <?php endif; ?>
<div id="#signin" class="modal modal-fx-fadeInScale"> <div id="#signin" class="modal modal-fx-fadeInScale">

View file

@ -20,11 +20,12 @@ function outputPasteCard($paste) {
</div> </div>
</div></div>'; </div></div>';
} }
?> ?>
<main class="bd-main"> <main class="bd-main">
<!-- START CONTAINER --> <!-- START CONTAINER -->
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<!-- Start Row --> <!-- Start Row -->

View file

@ -1,6 +1,6 @@
<main class="bd-main"> <main class="bd-main">
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<?php if (isset($error)): ?> <?php if (isset($error)): ?>

View file

@ -35,8 +35,8 @@
</script> </script>
<main class="bd-main"> <main class="bd-main">
<!-- START CONTAINER --> <!-- START CONTAINER -->
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<!-- Start Row --> <!-- Start Row -->

View file

View file

@ -1,10 +1,12 @@
<main class="bd-main"> <main class="bd-main">
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<?php if (isset($success)): ?> <?php if (isset($success)): ?>
<div class="notification is-success"><i class="fa fa-exclamation-circle" aria-hidden="true"></i><?= pp_html_escape($success); ?></div> <div class="notification is-success"><i class="fa fa-exclamation-circle"
aria-hidden="true"></i><?= pp_html_escape($success); ?>
</div>
<?php if (isset($new_password)): ?> <?php if (isset($new_password)): ?>
<p>Your new password is as follows:</p> <p>Your new password is as follows:</p>
<code><?= pp_html_escape($new_password); ?></code> <code><?= pp_html_escape($new_password); ?></code>
@ -13,12 +15,15 @@
<?php if (isset($recovery_code)): ?> <?php if (isset($recovery_code)): ?>
<br><span class="tag is-danger is-medium">IMPORTANT!</span> <br><span class="tag is-danger is-medium">IMPORTANT!</span>
<p><b>If you wish to recover your account later, you will need the following code. Store it in a safe place!</b></p> <p><b>If you wish to recover your account later, you will need the following code. Store it in a
safe place!</b></p>
<code id="recovery"><?= pp_html_escape($recovery_code); ?></code> <code id="recovery"><?= pp_html_escape($recovery_code); ?></code>
<p>If you do not save this code, and you forget your password, there is no way to get your account back!</p> <p>If you do not save this code, and you forget your password, there is no way to get your
account back!</p>
<?php endif; ?> <?php endif; ?>
<?php elseif (isset($error)): ?> <?php elseif (isset($error)): ?>
<div class="notification is-info"><i class="fa fa-exclamation-circle" aria-hidden="true"></i><?= pp_html_escape($error); ?></p></div> <div class="notification is-info"><i class="fa fa-exclamation-circle"
aria-hidden="true"></i><?= pp_html_escape($error); ?></p></div>
<?php endif; ?> <?php endif; ?>
<?php outputFlashes($flashes); ?> <?php outputFlashes($flashes); ?>
<?php if (isset($_GET['register'])) { ?> <?php if (isset($_GET['register'])) { ?>
@ -54,15 +59,18 @@
<div class="field"> <div class="field">
<div class="notification"> <div class="notification">
<div class="captcha_container"> <div class="captcha_container">
<img src="/captcha?t=<?= $captcha_token = setupCaptcha() ?>" alt="CAPTCHA Image" /> <img src="/captcha?t=<?= $captcha_token = setupCaptcha() ?>"
alt="CAPTCHA Image"/>
<span id="captcha_refresh" style="height: 100%;"> <span id="captcha_refresh" style="height: 100%;">
<a href="javascript:void(0)"> <a href="javascript:void(0)">
<i class="fa fa-refresh" style="height: 100%;"></i> <i class="fa fa-refresh" style="height: 100%;"></i>
</a> </a>
</span> </span>
<input type="hidden" name="captcha_token" value="<?= $captcha_token ?>"/> <input type="hidden" name="captcha_token" value="<?= $captcha_token ?>"/>
<input type="text" class="input" name="captcha_answer" placeholder="Enter the CAPTCHA" /> <input type="text" class="input" name="captcha_answer"
<p class="is-size-6 has-text-grey-light has-text-left mt-2">and press "Enter"</p> placeholder="Enter the CAPTCHA"/>
<p class="is-size-6 has-text-grey-light has-text-left mt-2">and press
"Enter"</p>
</div> </div>
</div> </div>
</div> </div>

View file

@ -1,7 +1,7 @@
<link rel="stylesheet" href="theme/bulma/css/bulma-tagsinput.min.css"/> <link rel="stylesheet" href="theme/bulma/css/bulma-tagsinput.min.css"/>
<main class="bd-main"> <main class="bd-main">
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<?php if (isset($global_site_info['banner'])): ?> <?php if (isset($global_site_info['banner'])): ?>
@ -93,7 +93,9 @@
<div class="level-item is-pulled-left mr-1"> <div class="level-item is-pulled-left mr-1">
<div class="field"> <div class="field">
<div class="subtitle has-text-weight-semibold " <div class="subtitle has-text-weight-semibold "
style="margin-left: 2px; margin-bottom: 0.6rem; font-size: 1rem;">Expiry</div> style="margin-left: 2px; margin-bottom: 0.6rem; font-size: 1rem;">
Expiry
</div>
<div class="control"> <div class="control">
<div class="select"> <div class="select">
<?php <?php
@ -119,7 +121,8 @@
<div class="level-item is-pulled-left mx-1"> <div class="level-item is-pulled-left mx-1">
<div class="field"> <div class="field">
<div class="subtitle has-text-weight-semibold " <div class="subtitle has-text-weight-semibold "
style="margin-left: 2px; margin-bottom: 0.6rem; font-size: 1rem;">Visibility style="margin-left: 2px; margin-bottom: 0.6rem; font-size: 1rem;">
Visibility
&nbsp;&nbsp; &nbsp;&nbsp;
</div> </div>
<div class="control"> <div class="control">
@ -133,14 +136,17 @@
} }
?> ?>
<select name="visibility"> <select name="visibility">
<option value="0" <?php echo ($post_visibility == "0") ? 'selected="selected"' : ''; ?>> <option
value="0" <?php echo ($post_visibility == "0") ? 'selected="selected"' : ''; ?>>
Public Public
</option> </option>
<option value="1" <?php echo ($post_visibility == "1") ? 'selected="selected"' : ''; ?>> <option
value="1" <?php echo ($post_visibility == "1") ? 'selected="selected"' : ''; ?>>
Unlisted Unlisted
</option> </option>
<?php if ($current_user) { ?> <?php if ($current_user) { ?>
<option value="2" <?php echo ($post_visibility == "2") ? 'selected="selected"' : ''; ?>> <option
value="2" <?php echo ($post_visibility == "2") ? 'selected="selected"' : ''; ?>>
Private Private
</option> </option>
<?php } else { ?> <?php } else { ?>
@ -186,15 +192,18 @@
<?php if ($captcha_enabled && $current_user === null): ?> <?php if ($captcha_enabled && $current_user === null): ?>
<div class="is-one-quarter"> <div class="is-one-quarter">
<div class="captcha_container"> <div class="captcha_container">
<img src="/captcha?t=<?= $captcha_token = setupCaptcha() ?>" alt="CAPTCHA Image" /> <img src="/captcha?t=<?= $captcha_token = setupCaptcha() ?>"
alt="CAPTCHA Image"/>
<span id="captcha_refresh" style="height: 100%;"> <span id="captcha_refresh" style="height: 100%;">
<a href="javascript:void(0)"> <a href="javascript:void(0)">
<i class="fa fa-refresh" style="height: 100%;"></i> <i class="fa fa-refresh" style="height: 100%;"></i>
</a> </a>
</span> </span>
<input type="hidden" name="captcha_token" value="<?= $captcha_token ?>"/> <input type="hidden" name="captcha_token" value="<?= $captcha_token ?>"/>
<input type="text" class="input" name="captcha_answer" placeholder="Enter the CAPTCHA" /> <input type="text" class="input" name="captcha_answer"
<p class="is-size-6 has-text-grey-light has-text-left mt-2">and press "Enter"</p> placeholder="Enter the CAPTCHA"/>
<p class="is-size-6 has-text-grey-light has-text-left mt-2">and press
"Enter"</p>
</div> </div>
</div> </div>
<?php endif; ?> <?php endif; ?>

View file

@ -1,10 +1,11 @@
<main class="bd-main"> <main class="bd-main">
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<?php if (isset($page)): ?> <?php if (isset($page)): ?>
<h1 class="title is-4"><?= pp_html_escape($page->page_title); ?><h1> <h1 class="title is-4"><?= pp_html_escape($page->page_title); ?>
<h1>
<?= $page->page_content; ?> <?= $page->page_content; ?>
<?php else: ?> <?php else: ?>
<h1 class="title is-4">Page not found.</h1> <h1 class="title is-4">Page not found.</h1>

View file

@ -1,5 +1,5 @@
<main class="bd-main"> <main class="bd-main">
<div class="bd-main-container container"> <div class="container">
<div class="bd-lead"> <div class="bd-lead">
<div class="rule"> <div class="rule">
<h2>The short version</h2> <h2>The short version</h2>
@ -34,7 +34,8 @@
</ul> </ul>
<p>Additionally, cookies of users that are logged into the service may contain:</p> <p>Additionally, cookies of users that are logged into the service may contain:</p>
<ul> <ul>
<li>A random authentication secret ("remember me" token) unique to the user to persist their login</li> <li>A random authentication secret ("remember me" token) unique to the user to persist their login
</li>
</ul> </ul>
<p>These data are required for authentication, user security, or customization, which are all <p>These data are required for authentication, user security, or customization, which are all
"legitimate interests" as above, and thus we cannot ask for consent to use these "legitimate interests" as above, and thus we cannot ask for consent to use these

View file

@ -1,6 +1,6 @@
<main class="bd-main"> <main class="bd-main">
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<h1 class="title is-5">Total Pastes: <?= $total_user_pastes ?></h1> <h1 class="title is-5">Total Pastes: <?= $total_user_pastes ?></h1>

View file

@ -1,6 +1,6 @@
<main class="bd-main"> <main class="bd-main">
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<h1 class="title is-5">Reporting <b><?= pp_html_escape($paste->title) ?></b></h1> <h1 class="title is-5">Reporting <b><?= pp_html_escape($paste->title) ?></b></h1>

View file

@ -1,7 +1,7 @@
<main class="bd-main"> <main class="bd-main">
<!-- START CONTAINER --> <!-- START CONTAINER -->
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<!-- Start Row --> <!-- Start Row -->
@ -12,53 +12,72 @@
<ul class="rules"> <ul class="rules">
<li class="rule"> <li class="rule">
The paste <u>must</u> have recognizable show characters, MLP universe influences (AU allowed) and/or links to MLP content (eg. YouTube, /mlp/, pony boorus.) The paste <u>must</u> have recognizable show characters, MLP universe influences (AU
allowed) and/or links to MLP content (eg. YouTube, /mlp/, pony boorus.)
</li> </li>
<li class="rule"> <li class="rule">
Pony drama pastes are allowed, but must not contain any "dox" (information revealing an internet user's real identity), or any call to harm a real life person in any way. Pony drama pastes are allowed, but must not contain any "dox" (information revealing an
internet user's real identity), or any call to harm a real life person in any way.
</li> </li>
<li class="rule"> <li class="rule">
Storing code for pony related projects is allowed. For anything else, choose another pastebin. Storing code for pony related projects is allowed. For anything else, choose another
pastebin.
</li> </li>
<li class="rule"> <li class="rule">
Storing archived greentext/prose is allowed if the content is already publicly available. Please credit the original author in the title and/or the start of the paste, if possible. Storing archived greentext/prose is allowed if the content is already publicly available.
Please credit the original author in the title and/or the start of the paste, if possible.
</li> </li>
</ul> </ul>
<h2>2. Do not post links to illegal content</h2> <h2>2. Do not post links to illegal content</h2>
<ul class="rules"> <ul class="rules">
<li class="rule"> <li class="rule">
Links to photographs or videos depicting human minors in a pornographic, sexually suggestive, or violent manner. Links to photographs or videos depicting human minors in a pornographic, sexually
suggestive, or violent manner.
</li> </li>
<li class="rule"> <li class="rule">
Actual photographs or videos of sadistic gore or animal cruelty (Art, as in rendered drawing, is allowed) Actual photographs or videos of sadistic gore or animal cruelty (Art, as in rendered
drawing, is allowed)
</li> </li>
<li class="rule"> <li class="rule">
Do not post stories containing explicit sexual situations involving real underage humans. Do not post stories containing explicit sexual situations involving real underage humans.
</li> </li>
<li class="rule"> <li class="rule">
Pastes containing or linking calls to violence, harm, or terrorist threats to the real world <u>will be removed and the account banned/removed.</u> Pastes containing or linking calls to violence, harm, or terrorist threats to the real world
<u>will be removed and the account banned/removed.</u>
</li> </li>
<li class="rule"> <li class="rule">
<u>Unless stated what it is in the title and paste</u>, pastes containing link dumps to file upload sites or Tor (.onion) sites will be removed. <u>Unless stated what it is in the title and paste</u>, pastes containing link dumps to file
upload sites or Tor (.onion) sites will be removed.
The moderation does not know what the files are, and does not have time to verify them. The moderation does not know what the files are, and does not have time to verify them.
</li> </li>
<li class="rule">Pastes containing calls to download and/or link to copyrighted material will be removed if excessively posted and/or reported by the copyright holder.</li> <li class="rule">Pastes containing calls to download and/or link to copyrighted material will be
removed if excessively posted and/or reported by the copyright holder.
</li>
</ul> </ul>
<h2>3. Do not abuse site functionality</h2> <h2>3. Do not abuse site functionality</h2>
<ul class="rules"> <ul class="rules">
<li class="rule"> <li class="rule">
You are permitted to have multiple accounts for purposes of archiving or for personal privacy - for example, if you use multiple names. You are permitted to have multiple accounts for purposes of archiving or for personal
If you are archiving someone else's content, please do not create an account under their name. Instead, use <code>{name}-ARCHIVE</code>. privacy - for example, if you use multiple names.
If you are archiving someone else's content, please do not create an account under their
name. Instead, use <code>{name}-ARCHIVE</code>.
</li class="rule"> </li class="rule">
<li class="rule">You may not use multiple accounts for the purposes of evading bans.</li> <li class="rule">You may not use multiple accounts for the purposes of evading bans.</li>
<li class="rule"><u>Do not spam. </u>While we do understand shitposting is part of chan culture, please do not go overboard. At least put a paste expiry time. <li class="rule"><u>Do not spam. </u>While we do understand shitposting is part of chan culture,
We reserve the right to remove shitposts during database clean up.</li> please do not go overboard. At least put a paste expiry time.
<li class="rule">Do not abuse the report function. This means crying to get your greentext taken down. You posted it to a public domain (eg 4chan), it belongs to the internet now.</li> We reserve the right to remove shitposts during database clean up.
<li class="rule">If you think someone is violating a rule, submit a report instead of otherwise calling them out (such as on /mlp/). </li>
Don't submit false reports or report pastes you do not like. Don&#39;t like it, don&#39;t read it. (Unless it breaks any other rules listed here.)</li> <li class="rule">Do not abuse the report function. This means crying to get your greentext taken
down. You posted it to a public domain (eg 4chan), it belongs to the internet now.
</li>
<li class="rule">If you think someone is violating a rule, submit a report instead of otherwise
calling them out (such as on /mlp/).
Don't submit false reports or report pastes you do not like. Don&#39;t like it, don&#39;t
read it. (Unless it breaks any other rules listed here.)
</li>
</ul> </ul>
<h2>4. Keep this place tidy</h2> <h2>4. Keep this place tidy</h2>
@ -71,17 +90,21 @@
<h2>5. Using Pastedown</h2> <h2>5. Using Pastedown</h2>
<ul class="rules"> <ul class="rules">
<li class="rule">Embedded images must not contain explicit images. Non-embed links are fine. </li> <li class="rule">Embedded images must not contain explicit images. Non-embed links are fine.
</li>
<li class="rule">No non pony related images,</li> <li class="rule">No non pony related images,</li>
<li class="rule"> <li class="rule">
No embedded photographs or videos depicting human minors in a pornographic, sexually suggestive, or violent manner. No embedded photographs or videos depicting human minors in a pornographic, sexually
suggestive, or violent manner.
This will result in an instant ban. This will result in an instant ban.
</li> </li>
<li class="rule"> <li class="rule">
No foalcon, lolicon or any underage cartoon characters depicted in a sexual or nude situation. No foalcon, lolicon or any underage cartoon characters depicted in a sexual or nude
situation.
</li class="rule"> </li class="rule">
<li class="rule"> <li class="rule">
Links go through a whitelist system, thus some links will be blocked. If you believe your link should be whitelisted, please email the administrators. Links go through a whitelist system, thus some links will be blocked. If you believe your
link should be whitelisted, please email the administrators.
</li> </li>
</ul> </ul>
@ -89,9 +112,12 @@
<h2>N. Rules are not exhaustive</h2> <h2>N. Rules are not exhaustive</h2>
<p>There may always be situations or actions that were not accounted for in the above rules, or that may be unique or extraordinary in their circumstances. <p>There may always be situations or actions that were not accounted for in the above rules, or that
All enforcement of the rules, as well as the decision as to whether something is or is not acceptable, is ultimately left up to the discretion of the site&#39;s staff. may be unique or extraordinary in their circumstances.
<span style="color:rgb(44, 53, 60); font-family:source sans pro,helvetica neue,helvetica,roboto,arial,sans-serif">There are no real rules about moderation &mdash; enjoy your ban. All enforcement of the rules, as well as the decision as to whether something is or is not
acceptable, is ultimately left up to the discretion of the site&#39;s staff.
<span
style="color:rgb(44, 53, 60); font-family:source sans pro,helvetica neue,helvetica,roboto,arial,sans-serif">There are no real rules about moderation &mdash; enjoy your ban.
</p> </p>
</div> </div>
</div> </div>

View file

@ -1,4 +1,5 @@
<?php <?php
use PonePaste\Models\Paste; use PonePaste\Models\Paste;
use PonePaste\Models\User; use PonePaste\Models\User;
@ -38,8 +39,8 @@ $public_paste_badges = [
} }
?> ?>
<main class="bd-main"> <main class="bd-main">
<div class="bd-side-background"></div>
<div class="bd-main-container container"> <div class="container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<div class="flex flex--space-between"> <div class="flex flex--space-between">
@ -53,11 +54,17 @@ $public_paste_badges = [
<p>Admin Actions:</p> <p>Admin Actions:</p>
<form method="post"> <form method="post">
<input type="hidden" name="csrf_token" value="<?= $csrf_token ?>"> <input type="hidden" name="csrf_token" value="<?= $csrf_token ?>">
<button class="button is-small is-success" type="submit" name="reset_password">Reset Password</button> <button class="button is-small is-success" type="submit" name="reset_password">Reset
Password
</button>
<?php if ($profile_info->role === User::ROLE_MODERATOR): ?> <?php if ($profile_info->role === User::ROLE_MODERATOR): ?>
<button class="button is-small is-warning" type="submit" name="change_role">Demote Moderator</button> <button class="button is-small is-warning" type="submit" name="change_role">Demote
Moderator
</button>
<?php elseif ($profile_info->role === 0): ?> <?php elseif ($profile_info->role === 0): ?>
<button class="button is-small is-warning" type="submit" name="change_role">Promote to Moderator</button> <button class="button is-small is-warning" type="submit" name="change_role">Promote
to Moderator
</button>
<?php endif; ?> <?php endif; ?>
</form> </form>
</div> </div>
@ -111,15 +118,18 @@ $public_paste_badges = [
<br/> <br/>
<div class="tabs"> <div class="tabs">
<ul class="tabs-menu"> <ul class="tabs-menu">
<li class="<?= $tab === 'pastes' ? 'is-active' : '' ?>" data-target="first-tab"><a href="?tab=pastes">My Pastes</a></li> <li class="<?= $tab === 'pastes' ? 'is-active' : '' ?>" data-target="first-tab"><a
<li class="<?= $tab === 'favourites' ? 'is-active' : '' ?>" data-target="second-tab"><a href="?tab=favourites">Favorites</a></li> href="?tab=pastes">My Pastes</a></li>
<li class="<?= $tab === 'favourites' ? 'is-active' : '' ?>" data-target="second-tab"><a
href="?tab=favourites">Favorites</a></li>
</ul> </ul>
</div> </div>
<?php endif; ?> <?php endif; ?>
<div class="tab-content<?= $tab === 'favourites' ? ' is-hidden' : '' ?>" id="first-tab"> <div class="tab-content<?= $tab === 'favourites' ? ' is-hidden' : '' ?>" id="first-tab">
<form class="table_filterer" method="GET"> <form class="table_filterer" method="GET">
<label><i class="fa fa-search"></i> <label><i class="fa fa-search"></i>
<input class="search" type="search" name="q" placeholder="Filter..." value="<?= pp_html_escape($filter_value); ?>" /> <input class="search" type="search" name="q" placeholder="Filter..."
value="<?= pp_html_escape($filter_value); ?>"/>
</label> </label>
<label> <label>
Show&nbsp; Show&nbsp;
@ -133,7 +143,8 @@ $public_paste_badges = [
</label> </label>
<button type="submit" class="button js-hidden">Search</button> <button type="submit" class="button js-hidden">Search</button>
</form> </form>
<table id="archive" class="table is-fullwidth is-hoverable" data-user-id="<?= pp_html_escape($profile_info->id); ?>"> <table id="archive" class="table is-fullwidth is-hoverable"
data-user-id="<?= pp_html_escape($profile_info->id); ?>">
<thead> <thead>
<tr class="paginator__sort"> <tr class="paginator__sort">
<th data-sort-field="title" class="td-right">Title</th> <th data-sort-field="title" class="td-right">Title</th>
@ -165,7 +176,8 @@ $public_paste_badges = [
?> ?>
<?php if ($is_current_user || $paste->visible == Paste::VISIBILITY_PUBLIC): ?> <?php if ($is_current_user || $paste->visible == Paste::VISIBILITY_PUBLIC): ?>
<tr data-paste-info="<?= pp_html_escape(json_encode($pasteJson)); ?>"> <tr data-paste-info="<?= pp_html_escape(json_encode($pasteJson)); ?>">
<td><a href="<?= urlForPaste($paste) ?>" title="<?= $escaped_title ?>"><?= $escaped_title ?></a></td> <td><a href="<?= urlForPaste($paste) ?>"
title="<?= $escaped_title ?>"><?= $escaped_title ?></a></td>
<td data-sort="<?= $p_date->format('U') ?>" class="td-center"> <td data-sort="<?= $p_date->format('U') ?>" class="td-center">
<?= $p_date->format('d F Y') ?> <?= $p_date->format('d F Y') ?>
</td> </td>
@ -206,7 +218,8 @@ $public_paste_badges = [
</div> </div>
<?php if ($is_current_user) { ?> <?php if ($is_current_user) { ?>
<div class="tab-content<?= $tab === 'pastes' ? ' is-hidden' : '' ?>" id="second-tab"> <div class="tab-content<?= $tab === 'pastes' ? ' is-hidden' : '' ?>" id="second-tab">
<table id="favs" class="table is-fullwidth is-hoverable<?= $current_page === 'favourites' ? 'is-active' : '' ?>"> <table id="favs"
class="table is-fullwidth is-hoverable<?= $current_page === 'favourites' ? 'is-active' : '' ?>">
<thead> <thead>
<tr> <tr>
<th class="td-right">Title</th> <th class="td-right">Title</th>
@ -229,8 +242,10 @@ $public_paste_badges = [
?> ?>
<?php if ($is_current_user || $row['visible'] == Paste::VISIBILITY_PUBLIC): ?> <?php if ($is_current_user || $row['visible'] == Paste::VISIBILITY_PUBLIC): ?>
<tr data-paste-info="<?= pp_html_escape(json_encode($pasteJson)); ?>"> <tr data-paste-info="<?= pp_html_escape(json_encode($pasteJson)); ?>">
<td><a href="<?= urlForPaste($paste) ?>" title="<?= $escaped_title ?>"><?= $escaped_title ?></a></td> <td><a href="<?= urlForPaste($paste) ?>"
<td data-sort="<?= $p_date->format('U') ?>" class="td-center"><?= $f_date->format('d F Y') ?></td> title="<?= $escaped_title ?>"><?= $escaped_title ?></a></td>
<td data-sort="<?= $p_date->format('U') ?>"
class="td-center"><?= $f_date->format('d F Y') ?></td>
<td class="td-center"> <td class="td-center">
<?php if ($delta->days <= 2): ?> <?php if ($delta->days <= 2): ?>
<i class='far fa-check-square fa-lg' aria-hidden='true'></i> <i class='far fa-check-square fa-lg' aria-hidden='true'></i>

View file

@ -50,9 +50,7 @@ $selectedloader = "$bg[$i]"; // set variable equal to which random filename was
} }
</style> </style>
<main class="bd-main" id="dstop-scrolling"> <main class="bd-main" id="dstop-scrolling">
<!-- <div class="preloader"></div> --> <div class="container">
<div class="bd-side-background"></div>
<div class="bd-main-container container">
<div class="bd-duo"> <div class="bd-duo">
<div class="bd-lead"> <div class="bd-lead">
<div class="content panel"> <div class="content panel">
@ -83,7 +81,8 @@ $selectedloader = "$bg[$i]"; // set variable equal to which random filename was
<div class="column is-4 has-text-centered"> <div class="column is-4 has-text-centered">
<h1 class="title is-6" style="margin-bottom:0;"><?= pp_html_escape($paste->title); ?></h1> <h1 class="title is-6" style="margin-bottom:0;"><?= pp_html_escape($paste->title); ?></h1>
<small class="title is-6 has-text-weight-normal has-text-grey"> <small class="title is-6 has-text-weight-normal has-text-grey">
By <a href="<?= urlForMember($paste->user) ?>"><?= pp_html_escape($paste->user->username) ?></a> By <a
href="<?= urlForMember($paste->user) ?>"><?= pp_html_escape($paste->user->username) ?></a>
<br/> <br/>
Created: <?= $paste->created_at ?> Created: <?= $paste->created_at ?>
<br/> <br/>
@ -103,7 +102,9 @@ $selectedloader = "$bg[$i]"; // set variable equal to which random filename was
<input type="hidden" name="csrf_token" value="<?= $csrf_token ?>"/> <input type="hidden" name="csrf_token" value="<?= $csrf_token ?>"/>
<?php endif; ?> <?php endif; ?>
<input type="hidden" name="fave" value="1"/> <input type="hidden" name="fave" value="1"/>
<button type="submit" class="icon tool-icon button--no-style"><i class="fas fa-star fa-lg <?= $paste_is_favourited ? '' : 'has-text-grey' ?>" title="Favourite"></i></button> <button type="submit" class="icon tool-icon button--no-style"><i
class="fas fa-star fa-lg <?= $paste_is_favourited ? '' : 'has-text-grey' ?>"
title="Favourite"></i></button>
</form> </form>
<?php endif; ?> <?php endif; ?>
<a class="icon tool-icon flip" href="<?= urlForReport($paste); ?>"><i <a class="icon tool-icon flip" href="<?= urlForReport($paste); ?>"><i
@ -175,7 +176,8 @@ $selectedloader = "$bg[$i]"; // set variable equal to which random filename was
<input type="hidden" name="csrf_token" value="<?= $csrf_token ?>"/> <input type="hidden" name="csrf_token" value="<?= $csrf_token ?>"/>
<?php endif; ?> <?php endif; ?>
<div class="field"> <div class="field">
<input class="button is-small <?= $paste->is_hidden ? 'is-success' : 'is-danger' ?>" type="submit" name="hide" id="hide" <input class="button is-small <?= $paste->is_hidden ? 'is-success' : 'is-danger' ?>"
type="submit" name="hide" id="hide"
value="<?= $paste->is_hidden ? 'Unhide' : 'Hide' ?> Paste"/> value="<?= $paste->is_hidden ? 'Unhide' : 'Hide' ?> Paste"/>
</div> </div>
</form> </form>
@ -256,7 +258,9 @@ $selectedloader = "$bg[$i]"; // set variable equal to which random filename was
<div class="control"> <div class="control">
<div class="control"> <div class="control">
<input name="tag_input" class="input js-tag-input" id="field_tags" <input name="tag_input" class="input js-tag-input" id="field_tags"
value="<?= pp_html_escape($paste->tags->map(function($t) { return $t->name; })->join(',')) ?>" /> value="<?= pp_html_escape($paste->tags->map(function ($t) {
return $t->name;
})->join(',')) ?>"/>
</div> </div>
</div> </div>
</div> </div>
@ -268,7 +272,8 @@ $selectedloader = "$bg[$i]"; // set variable equal to which random filename was
<div class="level-item is-pulled-left mr-1"> <div class="level-item is-pulled-left mr-1">
<div class="field"> <div class="field">
<div class="subtitle has-text-weight-semibold " <div class="subtitle has-text-weight-semibold "
style="margin-left: 2px; margin-bottom: 0.6rem; font-size: 1rem;">Expiry</div> style="margin-left: 2px; margin-bottom: 0.6rem; font-size: 1rem;">Expiry
</div>
<div class="control"> <div class="control">
<!-- Expiry --> <!-- Expiry -->
<div class="select"> <div class="select">
@ -289,7 +294,8 @@ $selectedloader = "$bg[$i]"; // set variable equal to which random filename was
<div class="level-item is-pulled-left mx-1"> <div class="level-item is-pulled-left mx-1">
<div class="field"> <div class="field">
<div class="subtitle has-text-weight-semibold " <div class="subtitle has-text-weight-semibold "
style="margin-left: 2px; margin-bottom: 0.6rem; font-size: 1rem;">Visibility style="margin-left: 2px; margin-bottom: 0.6rem; font-size: 1rem;">
Visibility
&nbsp;&nbsp; &nbsp;&nbsp;
</div> </div>
<div class="control"> <div class="control">
@ -338,9 +344,7 @@ $selectedloader = "$bg[$i]"; // set variable equal to which random filename was
</div> </div>
</form> </form>
<?php } ?> <?php } ?>
</div> </div>
</div> </div>
</div> </div>
</main> </main>