feat: Initial commit

This commit is contained in:
Cyper committed 2026-03-30 23:33:32 -04:00
1 parent 16004f5a84
commit 04b9739853
21 files changed
+4163

No files matched your search

+5
View File
@@ -0,0 +1,5 @@
<div>
<span>&copy; <%= (new Date()).getFullYear() %> Cyper</span>
<span style="color: var(--border)">|</span>
<span>All rights reserved</span>
</div>
+4
View File
@@ -0,0 +1,4 @@
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title><%= typeof(title) !== "undefined" ? title + ' - ' : "" %>Template</title>
+29
View File
@@ -0,0 +1,29 @@
<nav>
<a href="/" class="nav-brand">Cyper</a>
<% if (typeof(account) !== "undefined" && account.authenticated) { %>
<div class="nav-avatar-wrap">
<button class="nav-avatar" id="navAvatarBtn" aria-haspopup="true" aria-expanded="false">
<% if (account.avatarUrl) { %>
<img src="<%= account.avatarUrl %>" alt="<%= account.username %>" />
<% } else { %>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor">
<path d="M12 12c2.7 0 4.8-2.1 4.8-4.8S14.7 2.4 12 2.4 7.2 4.5 7.2 7.2 9.3 12 12 12zm0 2.4c-3.2 0-9.6 1.6-9.6 4.8v2.4h19.2v-2.4c0-3.2-6.4-4.8-9.6-4.8z"/>
</svg>
<% } %>
</button>
<div class="nav-dropdown" id="navDropdown" aria-hidden="true">
<div class="nav-dropdown-header">
<span class="nav-dropdown-username"><%= account.username %></span>
</div>
<a href="/profile" class="nav-dropdown-item">Profile</a>
<a href="/settings" class="nav-dropdown-item">Settings</a>
<div class="nav-dropdown-divider"></div>
<form method="post" action="/logout">
<button class="nav-dropdown-item nav-dropdown-signout" type="submit">Sign out</button>
</form>
</div>
</div>
<% } %>
</nav>
+24
View File
@@ -0,0 +1,24 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<%- include('_partials/header', { title: "Home" }); %>
<link rel="icon" href="/img/favicon.ico" type="image/x-icon">
<link rel="stylesheet" href="/css/site.css">
</head>
<body>
<header>
<%- include("_partials/navbar"); %>
</header>
<main class="px-6 py-10">
<h1 class="page-title">Home</h1>
</main>
<footer>
<%- include("_partials/footer"); %>
</footer>
<script src="/js/navbar.js"></script>
</body>
</html>
+43
View File
@@ -0,0 +1,43 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<%- include('_partials/header', { title: "Login" }); %>
<link rel="icon" href="/img/favicon.ico" type="image/x-icon">
<link rel="stylesheet" href="/css/site.css">
</head>
<body>
<header>
<%- include("_partials/navbar"); %>
</header>
<main class="grid place-items-center px-4">
<div class="card w-full max-w-sm">
<h1 class="text-lg font-semibold tracking-wide mb-6" style="color: var(--khaki)">Sign in</h1>
<form method="post" class="flex flex-col gap-4">
<div class="field">
<label for="username">Username</label>
<input id="username" name="username" type="text" autocomplete="username" />
</div>
<div class="field">
<label for="password">Password</label>
<input id="password" name="password" type="password" autocomplete="current-password" />
</div>
<div class="flex justify-end pt-2">
<button class="btn btn-primary" type="submit">Sign in</button>
</div>
</form>
</div>
</main>
<footer>
<%- include("_partials/footer"); %>
</footer>
<script src="/js/navbar.js"></script>
</body>
</html>
+26
View File
@@ -0,0 +1,26 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<%- include('_partials/header', { title: "401 Unauthorized" }); %>
<link rel="icon" href="/img/favicon.ico" type="image/x-icon">
<link rel="stylesheet" href="/css/site.css">
</head>
<body>
<header>
<%- include("_partials/navbar"); %>
</header>
<main class="grid place-items-center px-4">
<div class="error-page">
<span class="error-code">401</span>
<h1 class="error-title">Unauthorized</h1>
<p class="error-message">You need to be signed in to access this page.</p>
<a href="/login" class="btn btn-primary">Sign in</a>
</div>
</main>
<footer>
<%- include("_partials/footer"); %>
</footer>
</body>
</html>
+28
View File
@@ -0,0 +1,28 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<%- include('_partials/header', { title: "404 Not Found" }); %>
<link rel="icon" href="/img/favicon.ico" type="image/x-icon">
<link rel="stylesheet" href="/css/site.css">
</head>
<body>
<header>
<%- include("_partials/navbar"); %>
</header>
<main class="grid place-items-center px-4">
<div class="error-page">
<span class="error-code">404</span>
<h1 class="error-title">Not Found</h1>
<p class="error-message">
The resource <code class="error-resource"><%= resource %></code> does not exist.
</p>
<a href="/" class="btn btn-secondary">Go home</a>
</div>
</main>
<footer>
<%- include("_partials/footer"); %>
</footer>
</body>
</html>
+29
View File
@@ -0,0 +1,29 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<%- include('_partials/header', { title: "500 Internal Server Error" }); %>
<link rel="icon" href="/img/favicon.ico" type="image/x-icon">
<link rel="stylesheet" href="/css/site.css">
</head>
<body>
<header>
<%- include("_partials/navbar"); %>
</header>
<main class="grid place-items-center px-4">
<div class="error-page">
<span class="error-code">500</span>
<h1 class="error-title">Internal Server Error</h1>
<p class="error-message">Something went wrong on our end. Please try again later.</p>
<% if (environment !== 'prod' && typeof(error) !== 'undefined') { %>
<pre class="error-trace"><%= error %></pre>
<% } %>
<a href="/" class="btn btn-secondary">Go home</a>
</div>
</main>
<footer>
<%- include("_partials/footer"); %>
</footer>
</body>
</html>
+27
View File
@@ -0,0 +1,27 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<%- include('_partials/header', { title: "Home" }); %>
<link rel="icon" href="/img/favicon.ico" type="image/x-icon">
<link rel="stylesheet" href="/css/site.css">
</head>
<body>
<header class="bg-red-700">
<%- include("_partials/navbar"); %>
</header>
<main class="bg-green-700">
<h1>Test Page</h1>
<form method='post' action='/logout'>
<button class="btn m-2 p-1" type="submit">Logout</button>
</form>
</main>
<footer class="bg-blue-700">
<%- include("_partials/footer"); %>
</footer>
<script src="/js/navbar.js"></script>
</body>
</html>