perf: self-host fonts, eliminate CLS, a11y and contrast fixes
- Self-host Inter and JetBrains Mono (woff2, 69KB total) - Remove Google Fonts dependency entirely (no external requests) - Service Worker pre-caches font files - Eliminate font-swap layout shifts - WCAG contrast fix: disabled button uses solid color instead of opacity - Footer link always underlined for distinguishability - Translated aria-labels via data-i18n-aria - Dimmed QR with "Bezahlt" stamp on paid invoices - Hide wallet/address buttons when invoice is paid
This commit is contained in:
31
style.css
31
style.css
@@ -1,19 +1,19 @@
|
||||
@font-face {
|
||||
font-family: 'Inter fallback';
|
||||
src: local('Arial');
|
||||
size-adjust: 107%;
|
||||
ascent-override: 90%;
|
||||
descent-override: 25%;
|
||||
line-gap-override: 0%;
|
||||
font-family: 'Inter';
|
||||
font-style: normal;
|
||||
font-weight: 100 900;
|
||||
font-display: swap;
|
||||
src: url('fonts/inter-400.woff2') format('woff2');
|
||||
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'JetBrains Mono fallback';
|
||||
src: local('Courier New');
|
||||
size-adjust: 112%;
|
||||
ascent-override: 78%;
|
||||
descent-override: 22%;
|
||||
line-gap-override: 0%;
|
||||
font-family: 'JetBrains Mono';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
font-display: swap;
|
||||
src: url('fonts/jetbrains-400.woff2') format('woff2');
|
||||
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
||||
}
|
||||
|
||||
:root {
|
||||
@@ -28,8 +28,8 @@
|
||||
--success: #4caf50;
|
||||
--error: #f44336;
|
||||
--radius: 8px;
|
||||
--font: 'Inter', 'Inter fallback', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
||||
--mono: 'JetBrains Mono', 'JetBrains Mono fallback', 'Fira Code', monospace;
|
||||
--font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
||||
--mono: 'JetBrains Mono', 'Fira Code', monospace;
|
||||
}
|
||||
|
||||
* {
|
||||
@@ -320,7 +320,8 @@ textarea {
|
||||
}
|
||||
|
||||
.btn-primary:disabled {
|
||||
opacity: 0.5;
|
||||
background: #804020;
|
||||
color: #ccc;
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user