feat(config): support *_MB env vars for upload size limits

- Add `applyMegabytesOrBytesEnv` to accept size settings in either bytes or MB
- Prefer `*_BYTES` when set, otherwise convert `*_MB` to bytes with overflow guard
- Add coverage for MB-based environment overrides
- Introduce `static/js/upload-popups.js` to lazy-load and cache popup templatesfeat(config): support *_MB env vars for upload size limits

- Add `applyMegabytesOrBytesEnv` to accept size settings in either bytes or MB
- Prefer `*_BYTES` when set, otherwise convert `*_MB` to bytes with overflow guard
- Add coverage for MB-based environment overrides
- Introduce `static/js/upload-popups.js` to lazy-load and cache popup templates
This commit is contained in:
2026-04-29 01:42:41 +03:00
parent 82acaffdd8
commit 6035ea1eb2
20 changed files with 544 additions and 166 deletions

View File

@@ -22,10 +22,13 @@
:root {
font-family: 'PixelOperator', 'MS Sans Serif', Arial, sans-serif;
font-smooth: never;
-webkit-font-smoothing: none;
-moz-osx-font-smoothing: grayscale;
text-rendering: geometricPrecision;
image-rendering: pixelated;
cursor: url('/static/cursors/vaporwave-hotline-white-plus/Normal\ Select.cur'), auto;
--base-font-size: 14px;
--ui-scale: 1;
--w98-blue: #000078;
--w98-blue-gradient: linear-gradient(90deg, #000078 0%, #000078 28%, #0f80cd 50%, #000078 72%, #000078 100%);
--w98-gray: #c0c0c0;
@@ -38,6 +41,7 @@
box-sizing: border-box;
scrollbar-width: auto;
scrollbar-color: #c0c0c0 #808080;
image-rendering: pixelated;
}
html {
@@ -75,7 +79,7 @@ label[for],
.menu-button,
.win98-button:not(:disabled),
a {
cursor: url('/static/cursors/vaporwave-hotline-white-plus/Link\ Select.cur'), pointer;
cursor: pointer;
}
button,
@@ -90,7 +94,7 @@ input[type="password"],
input[type="number"],
input[type="file"],
textarea {
cursor: url('/static/cursors/vaporwave-hotline-white-plus/Hotline\ Black\ Handwriting.cur'), text;
cursor: text;
}
:focus-visible {
@@ -172,18 +176,19 @@ textarea:disabled {
}
@media (min-width: 1800px) {
:root { --base-font-size: 15px; }
.desktop-wrap { zoom: 1.2; }
:root { --base-font-size: 15px; --ui-scale: 1.2; }
}
@media (min-width: 2048px) {
:root { --base-font-size: 16px; }
.desktop-wrap { zoom: 1.36; }
:root { --base-font-size: 16px; --ui-scale: 1.36; }
}
@media (min-width: 2560px) {
:root { --base-font-size: 18px; }
.desktop-wrap { zoom: 1.58; }
:root { --base-font-size: 18px; --ui-scale: 1.58; }
}
@media (min-width: 3200px) {
:root { --base-font-size: 20px; --ui-scale: 1.88; }
}
@media (prefers-reduced-motion: reduce) {