[fix](trx-frontend-http): vendor DSEG14 font locally to avoid CDN content blockers
Same issue as Leaflet — content blockers block the jsdelivr CDN request, causing the seven-segment font to fail loading and fall back to monospace. Also replace preload-to-stylesheet swap with media="print" onload swap for themes.css and leaflet.css to eliminate Safari preload warnings. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Stan Grams <sjg@haxx.space>
This commit is contained in:
@@ -8,9 +8,9 @@
|
||||
<link rel="shortcut icon" href="/favicon.ico?v=5" />
|
||||
<link rel="apple-touch-icon" sizes="180x180" href="/favicon.png?v=5" />
|
||||
<link rel="stylesheet" href="/style.css" />
|
||||
<link rel="preload" as="style" href="/themes.css" onload="this.onload=null;this.rel='stylesheet'" />
|
||||
<link rel="stylesheet" href="/themes.css" media="print" onload="this.media='all'" />
|
||||
<noscript><link rel="stylesheet" href="/themes.css" /></noscript>
|
||||
<link rel="preload" as="style" href="/vendor/leaflet.css" onload="this.onload=null;this.rel='stylesheet'" />
|
||||
<link rel="stylesheet" href="/vendor/leaflet.css" media="print" onload="this.media='all'" />
|
||||
<noscript><link rel="stylesheet" href="/vendor/leaflet.css" /></noscript>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
font-display: swap;
|
||||
src: url('https://cdn.jsdelivr.net/npm/@fontsource/dseg14-classic/files/dseg14-classic-latin-400-normal.woff2') format('woff2');
|
||||
src: url('/vendor/dseg14-classic-latin-400-normal.woff2') format('woff2');
|
||||
unicode-range: U+0030-0039, U+002E, U+002D, U+0020, U+002B;
|
||||
}
|
||||
|
||||
|
||||
BIN
Binary file not shown.
Reference in New Issue
Block a user