1
0

New Jade templates.

This commit is contained in:
Alexander Andreev 2022-02-08 04:24:20 +04:00
parent 907bdeffcc
commit ebc4442540
Signed by: Arav
GPG Key ID: 1327FE8A374CC86F
4 changed files with 83 additions and 0 deletions

19
web/templates/404.jade Normal file
View File

@ -0,0 +1,19 @@
extends base.jade
block head
style(type="text/css").
#error {
font-size: 3.5rem;
line-height: 5rem;
text-align: center;
margin: 6rem 0; }
#error h1 { font-size: 8rem; }
block header
h1 xDDDD
block body
section#error
h1 404
| Nod Found xD

24
web/templates/base.jade Normal file
View File

@ -0,0 +1,24 @@
doctype html
html(lang="en")
head
title Arav's dwelling / Upload
meta(charset="utf-8")
meta(http-equiv="X-UA-Compatible" content="IE=edge")
meta(name="viewport" content="width=device-width, initial-scale=1.0")
meta(name="theme-color" content="#cd2682")
meta(name="description" content="File upload service that keep files for 2 days.")
link(rel="icon" href="/assets/img/favicon.svg" sizes="any" type="image/svg+xml")
link(href="/assets/css/main.css" rel="stylesheet")
block head
body
header
svg#logo(viewBox="0 -25 216 40")
text.logo Arav's dwelling
text.under(y="11") Welcome to my sacred place, wanderer
nav
a(href=.MainSite title="Arav's dwelling") Back to main website
block header
h1 Upload
block body
footer
| 2017—2022 Arav <#[a(href="mailto:me@arav.top") me@arav.top] >

31
web/templates/index.jade Normal file
View File

@ -0,0 +1,31 @@
extends base.jade
block body
section#rules.center
h2 Rules
ul
li Max. file size is #{.FileMaxSz}.
li Anything you upload should comply with Russian Federation's law.
li Generally speaking, anything that could cause me to deal with police, FSB, etc is forbidden.
li If anything illegal will be found it will be removed.
section#used-space.center
h2 Used space
div
span #{.StorageUsedStr}
progress(value=.StorageUsed max=.StorageCapacity)
span #{.StorageCapStr}
div
| #{.StorageAvailStr}
section#upload.center
h2 Upload
form(action="/" method="POST" enctype="multipart/form-data")
input(type="file" name="file")
input(type="submit" value="Upload")
section.center
p A resulted link looks like this /f/base64rawURL(sha256)/filename.ext.
p filename.ext could be anything but empty. It is a name the file will be retrieved with.
section
h2 Privacy statements
p I will cooperate with law enforcements and provide them with logs, and, if it still there, a file caused problems. Other than such situations logs won't get to the hands of third parties.
p Upload logs include: access time, IP-address, name of a file it was uploaded with, a SHA-256 hash of the file, download name, size of the file in bytes.
p Each download also being logged and include: access time, IP-address, name of a file it was requested with, download name.
p Download name is a salted SHA-256 hash of the file encoded using base64 raw URL encoding.

View File

@ -0,0 +1,9 @@
extends base.jade
block body
section#file
h2 Your link
center
a(href=.DownloadURL) #{.DownloadURL}
center It will be available for next #{.KeepForHours} hours.
center
a(href="/") Back to index page