feat: Add required Terms of Service acceptance to registration, enhance terms page content, and introduce utility scripts for thumbnail and dummy data generation.

This commit is contained in:
x
2026-01-24 16:32:28 +01:00
parent 2ad318e7c5
commit ee416a1d08
4 changed files with 112 additions and 55 deletions

View File

@@ -24,6 +24,9 @@ export default (router, tpl) => {
if (password !== password_confirm) return renderError("Passwords do not match");
if (username.length < 3) return renderError("Username too short");
// Password complexity check
if (password.length < 20) return renderError("Password must be at least 20 characters long");
// Check token
const tokenRow = await db`
select * from invite_tokens where token = ${token} and is_used = false

View File

@@ -15,10 +15,17 @@
<div style="color: #ff6b6b; margin-bottom: 10px; text-align: center;">{{ error }}</div>
@endif
<input type="text" name="username" placeholder="username" autocomplete="off" required />
<input type="password" name="password" placeholder="password" autocomplete="off" required />
<input type="password" name="password_confirm" placeholder="confirm password" autocomplete="off" required />
<input type="text" name="token" placeholder="invite token" autocomplete="off" required />
<button type="submit">Create Account</button>
<input type="password" name="password" placeholder="password" autocomplete="off" required minlength="20"
title="Must be at least 20 characters long." />
<input type="password" name="password_confirm" placeholder="confirm password" autocomplete="off" /><br>
<input type="text" name="token" placeholder="invite token" autocomplete="off" /><br>
<p style="text-align: left; font-size: 0.9em; margin: 10px 0; color: #fff;">
<input type="checkbox" id="tos-page" name="tos" required />
<label for="tos-page">I have read and accept the <a href="/terms" target="_blank"
style="color: var(--accent); text-decoration: underline;">Terms of Service</a> and I am at least 18
years old</label>
</p>
<input type="submit" value="Register" />
<div style="margin-top: 15px; text-align: center;">
<a href="/login" style="color: var(--accent); text-decoration: none;">Back to Login</a>
</div>

View File

@@ -119,9 +119,16 @@
<form class="login-form" method="post" action="/register">
<h2 style="text-align: center; margin-bottom: 20px;">Register</h2>
<input type="text" name="username" placeholder="username" autocomplete="off" required />
<input type="password" name="password" placeholder="password" autocomplete="off" required />
<input type="password" name="password" placeholder="password" autocomplete="off" required minlength="20"
title="Must be at least 20 characters long." />
<input type="password" name="password_confirm" placeholder="confirm password" autocomplete="off" required />
<input type="text" name="token" placeholder="invite token" autocomplete="off" required />
<p style="text-align: left; font-size: 0.9em; margin: 0; color: #fff;">
<input type="checkbox" id="tos-modal" name="tos" required />
<label for="tos-modal">I have read and accept the <a href="/terms" target="_blank"
style="color: var(--accent); text-decoration: underline;">Terms of Service</a> and I am at least 18 years
old</label>
</p>
<button type="submit">Create Account</button>
</form>
</div>

View File

@@ -1,56 +1,96 @@
@include(snippets/header)
<div id="main">
<div class="tos">
<p>Terms of Service</p>
<ol>
<li>Acceptance of Terms</li>
<p>By accessing and using this website, you acknowledge that your access is a privilege, not a right. If you do not agree with these terms, you are free to leave at any time.</p>
<li>No Claims</li>
<p>Visitors to this website have no claims whatsoever against the website owner or operators. Access to the website and its content is provided as-is, with no guarantees, warranties, or entitlements of any kind.</p>
<li>No Liability</li>
<p>This website and its operators assume no liability for any errors, omissions, inaccuracies, or any other issues that may arise from the use of this site. Use of this website is entirely at your own risk.</p>
<li>No Warranty</li>
<p>There is no warranty regarding the completeness, accuracy, reliability, or availability of the content provided on this website. The content may change at any time without notice.</p>
<li>Compliance with Requests</li>
<p>The website owner reserves the right to remove content, restrict access, or comply with any valid legal or personal requests at their sole discretion.</p>
<li>Changes to Terms</li>
<p>These terms may be updated at any time without prior notice. It is your responsibility to review them periodically.</p>
</ol>
<p>Data Privacy</p>
<ol>
<li>No Data Logging</li>
<p>This website does not collect, store, or log any personal data, including IP addresses or other identifying information of its visitors. No server-side logs are maintained.</p>
<li>Use of Cookies</li>
<p>Upon changing the theme, a single cookie is set. This cookie solely stores the name of the currently active theme to enhance the visual experience. It does not contain any personal data, tracking information, or other identifiers.</p>
<li>Cookie Control</li>
<p>The cookie is purely of cosmetic nature and not essential for the website's functionality. Users can disable cookies for this website entirely via their browser settings without affecting their ability to access and use the site.</p>
<li>No Third-Party Tracking</li>
<p>This website does not use third-party tracking services, analytics tools, or embedded content that collects user data.</p>
<li>User Accounts</li>
<p>When a former visitor is granted access with an account, the following data is collected:</p>
<ul>
<li>The User Agent</li>
<li>The Timestamp of the first login</li>
<li>The Timestamp of the account's last usage</li>
<li>The User's last recorded action</li>
</ul>
<div class="tos">
<h1 style="text-align: center; margin-bottom: 20px;">Terms of Service</h1>
<ol>
<li>
<strong>Acceptance of Terms</strong>
<p>By accessing and using this website, you acknowledge that your access is a privilege, not a right. If
you do not agree with these terms, you are free to leave at any time.</p>
</li>
<li>
<strong>No Claims</strong>
<p>Visitors to this website have no claims whatsoever against the website owner or operators. Access to
the website and its content is provided as-is, with no guarantees, warranties, or entitlements of
any kind.</p>
</li>
<li>
<strong>No Liability</strong>
<p>This website and its operators assume no liability for any errors, omissions, inaccuracies, or any
other issues that may arise from the use of this site. Use of this website is entirely at your own
risk.</p>
</li>
<li>
<strong>No Warranty</strong>
<p>There is no warranty regarding the completeness, accuracy, reliability, or availability of the
content provided on this website. The content may change at any time without notice.</p>
</li>
<li>
<strong>Compliance with Requests</strong>
<p>The website owner reserves the right to remove content, restrict access, or comply with any valid
legal or personal requests at their sole discretion.</p>
</li>
<li>
<strong>Changes to Terms</strong>
<p>These terms may be updated at any time without prior notice. It is your responsibility to review them
periodically.</p>
</li>
</ol>
<li>Email Communication</li>
<p>If you send me an email your mail is stored on our server, we can make a connection to your Email-Address and your user account if you contact us this way.</p>
<p>The Emails are not deleted after being answered.</p>
<h2 style="margin-top: 30px;">Data Privacy</h2>
<ol>
<li>
<strong>No Data Logging</strong>
<p>This website does not collect, store, or log any personal data, including IP addresses or other
identifying information of its visitors. No server-side logs are maintained.</p>
</li>
<li>
<strong>Use of Cookies</strong>
<p>Upon changing the theme, a single cookie is set. This cookie solely stores the name of the currently
active theme to enhance the visual experience. It does not contain any personal data, tracking
information, or other identifiers.</p>
</li>
<li>
<strong>Cookie Control</strong>
<p>The cookie is purely of cosmetic nature and not essential for the website's functionality. Users can
disable cookies for this website entirely via their browser settings without affecting their ability
to access and use the site.</p>
</li>
<li>
<strong>No Third-Party Tracking</strong>
<p>This website does not use third-party tracking services, analytics tools, or embedded content that
collects user data.</p>
</li>
<li>
<strong>User Accounts</strong>
<p>When a former visitor is granted access with an account, the following data is collected:</p>
<ul>
<li>The User Agent</li>
<li>The Timestamp of the first login</li>
<li>The Timestamp of the account's last usage</li>
<li>The User's last recorded action</li>
</ul>
<br>
</li>
<li>
<strong>Email Communication</strong>
<p>If you send me an email your mail is stored on our server, we can make a connection to your
Email-Address and your user account if you contact us this way.</p>
<p>The Emails are not deleted after being answered.</p>
</li>
<li>
<strong>Fully complying with Art. 15 GDPR</strong>
<p>You can ask anytime what data we have of you and how we use it, see Email Communication too.</p>
</li>
<li>
<strong>Changes to This Policy</strong>
<p>This privacy policy may be updated from time to time. Users are encouraged to review it periodically
to stay informed about any changes.</p>
</li>
</ol>
<li>Fully complying with Art. 15 GDPR</li>
<p>You can ask anytime what data we have of you and how we use it, see Email Communication too.</p>
<li>Changes to This Policy</li>
<p>This privacy policy may be updated from time to time. Users are encouraged to review it periodically to stay informed about any changes.</p>
<p>By using this website, you acknowledge and accept the terms of service and the data privacy policy.</p>
</ol>
</div>
<p style="margin-top: 30px; font-style: italic;">By using this website, you acknowledge and accept the terms of
service and the data privacy policy.</p>
</div>
</div>
@include(snippets/footer)