yeet source viewer; replace with gitea

This commit is contained in:
2026-01-19 02:15:26 -05:00
parent 1b9f9293bf
commit 9d93ff7812
6 changed files with 10 additions and 427 deletions

View File

@@ -3,12 +3,12 @@
'Android was originally an operating system for cameras',
'"password" is still one of the most commonly used passwords',
'People call me funny sometimes I guess',
'Haiii <3',
'e^(i*pi) = -1',
'According to the leading fan theory, 1 + 1 might actually not be 11',
'xkcd.com is a thing, and it is funny most of the time',
'Apparently I am a hooman',
'This message changes every time you refresh the page',
'I wish my friends would talk to me more often',
'I am a functional introvert'
'I am a functional introvert',
'Haiii <3'
]; %>Fun Fact: <%= facts[Math.floor(Math.random() * facts.length)] %></p>

View File

@@ -3,6 +3,6 @@
<a id="button" href="/">Home</a>
<a id="button" href="/art">Art</a>
<a id="button" href="/music">Playlist</a>
<a id="button" href="/source">Source code</a>
<a id="button" href="/git">Gitea</a>
</div>
</div>

View File

@@ -1,79 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Directory Tree</title>
<meta name="fediverse:creator" content="@oddbyte@mastodon.social">
<style>
<%- include('partials/style') %>
.directory {
font-weight: bold;
color: #0066cc;
cursor: pointer;
}
.file {
color: #00af00;
}
.directory-tree {
text-align-last: left;
}
</style>
</head>
<body>
<%- include('partials/navbar') %>
<div id="container_top">
<div id="container_main">
<div id="container_thing">
<main>
<h1>Directory Tree</h1>
<p>(here is where all the raw files are)</p>
<ul class="directory-tree">
<% function renderTree(items, indentLevel = 0) { %>
<% items.forEach(item => { %>
<li>
<% if (item.type === 'directory') { %>
<span class="directory"><%= item.name %></span>
<% if (item.children && item.children.length > 0) { %>
<ul>
<%= renderTree(item.children, indentLevel + 1) %>
</ul>
<% } %>
<% } else { %>
<a href="/source/<%= encodeURIComponent(item.path).replaceAll('%2F', '/') %>" class="file"><%= item.name %></a>
<% } %>
</li>
<% }); %>
<% } %>
<%= renderTree(paths) %>
</ul>
<h1>Rendered Pages</h1>
<div style="display: flex; align-items: center; justify-content: center; flex-wrap: nowrap; flex-direction: column; align-self: center;">
<div style="max-width: 500px; display: flex; align-items: center; justify-content: center; flex-wrap: nowrap; flex-direction: column; align-self: center;">
<p>these are the thingies that you see when you use my site like a normal person (in a browser, hopefully)</p>
<p style="text-align-last: left;">
<a href="/">/</a> &lt;-- Main Page <br />
<a href="/music">/music</a> &lt;-- My Youtube Music playlist<br />
<a href="/source">/source</a> &lt;-- You are here :P <br />
<a href="/art">/art</a> &lt;-- My art ^.^<br />
<a href="/blog">/blog</a> &lt;-- My crappy blog<br />
</p>
</div>
</div>
<h1>Files</h1>
<div style="display: flex; align-items: center; justify-content: center; flex-wrap: nowrap; flex-direction: column; align-self: center;">
<div style="max-width: 500px; display: flex; align-items: center; justify-content: center; flex-wrap: nowrap; flex-direction: column; align-self: center;">
<p style="text-align-last: left;">
<a href="/favicon.ico">/favicon.ico</a> &lt;-- icon</br>
<a href="/robots.txt">/robots.txt</a> &lt;-- tells some robots to go away
</p>
</div>
</div>
</div>
</div>
</div>
</body>
</html>

View File

@@ -1,25 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<title>Oddbyte</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link id="favicon" rel="shortcut icon" type="image/png" href="data:image/png;base64,<%- faviconb64 %>">
<link rel="canonical" href="https://oddbyte.dev/"/>
<meta name="fediverse:creator" content="@oddbyte@mastodon.social">
<style>
body {
background-color: black;
color: white;
}
</style>
</head>
<body>
<h1 class="selectDisable">Source code for <code><%-filePath %></code></h1>
<p><a href="/source" style="color: white;">Back</a></p>
<hr />
<pre><code><%= fileContent %></code></pre>
<hr />
<p><a href="/source" style="color: white;">Back</a></p>
</body>
</html>