From 523e519a3bd5c96845406f38db3bb5925ef824d5 Mon Sep 17 00:00:00 2001 From: Nixietab <75538775+nixietab@users.noreply.github.com> Date: Sun, 23 Aug 2026 08:08:23 -0300 Subject: [PATCH] made the file index work on phones --- assets/about.html | 7 +++++++ assets/index.html | 24 ++++++++++++++++++++---- server.go | 10 +++++++++- 3 files changed, 36 insertions(+), 5 deletions(-) diff --git a/assets/about.html b/assets/about.html index 95ed6a1..667efa2 100644 --- a/assets/about.html +++ b/assets/about.html @@ -48,6 +48,13 @@ footer { color: #666; letter-spacing: .08em; } + +@media (max-width: 600px) { + body { + padding: 12px; + font-size: 13px; + } +}
diff --git a/assets/index.html b/assets/index.html index 60f2fee..5169e12 100644 --- a/assets/index.html +++ b/assets/index.html @@ -139,20 +139,36 @@ footer a:hover { font-size: 12px; } } + +@media (max-width: 430px) { + body { + padding: 8px; + font-size: 12px; + } + + td, + th { + padding: 4px; + } + + .ty { + display: none; + } +}| {{.Label}}{{if .Active}}{{if .Desc}} ▼{{else}} ▲{{end}}{{end}} | {{end}}|||||
|---|---|---|---|---|---|
| {{.Label}}{{if .Active}}{{if .Desc}} ▼{{else}} ▲{{end}}{{end}} | {{end}}|||||
| ../ | - | ||||
| ../ | - | ||||
| {{.Name}} | -{{.Type}} | -{{if .IsDir}}-{{else}}{{.SizeS}}{{end}} | +{{.Type}} | +{{if .IsDir}}-{{else}}{{.SizeS}}{{end}} | {{.ModS}} |
| empty directory | |||||