diff options
| author | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-08-23 03:44:29 +0300 |
|---|---|---|
| committer | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-08-23 03:44:56 +0300 |
| commit | d6dae88345d24b8e468f63faad6a09173d2cbeac (patch) | |
| tree | 8e8912d1f6c784a09ce6a4fd450378ca60f9ced7 | |
| parent | 2bbb7c9172dafe3d77be970767e22dbd7c53c960 (diff) | |
fix: serve a google-eligible favicon
| -rw-r--r-- | website/_headers | 9 | ||||
| -rw-r--r-- | website/assets/favicon.png | bin | 2196 -> 7872 bytes | |||
| -rw-r--r-- | website/assets/favicon.svg | 6 | ||||
| -rw-r--r-- | website/astro.config.mjs | 8 | ||||
| -rw-r--r-- | website/favicon.ico | bin | 0 -> 15086 bytes | |||
| -rw-r--r-- | website/index.html | 3 | ||||
| -rw-r--r-- | website/scripts/prepare-docs.mjs | 1 | ||||
| -rw-r--r-- | website/src/components/MarketingLayout.astro | 3 | ||||
| -rw-r--r-- | website/src/components/SiteLayout.astro | 3 |
9 files changed, 29 insertions, 4 deletions
diff --git a/website/_headers b/website/_headers index 6422cca9..47081953 100644 --- a/website/_headers +++ b/website/_headers @@ -6,6 +6,15 @@ /assets/* Cache-Control: public, max-age=604800, immutable +# Icon URLs stay stable for Google's favicon crawler, so they can't be +# cache-busted with a query; keep them out of the immutable asset rule. +/assets/favicon.png + Cache-Control: public, max-age=86400 + +/favicon.ico + Content-Type: image/x-icon + Cache-Control: public, max-age=86400 + /install.sh Content-Type: text/plain Content-Disposition: inline diff --git a/website/assets/favicon.png b/website/assets/favicon.png Binary files differindex 79404044..a7720d48 100644 --- a/website/assets/favicon.png +++ b/website/assets/favicon.png diff --git a/website/assets/favicon.svg b/website/assets/favicon.svg new file mode 100644 index 00000000..8e3f8c42 --- /dev/null +++ b/website/assets/favicon.svg @@ -0,0 +1,6 @@ +<svg role="img" aria-label="Herdr logo" xmlns="http://www.w3.org/2000/svg" width="256" height="256" viewBox="125 125 250 250" preserveAspectRatio="xMidYMid meet"> + <rect width="512" height="512" fill="#d9dad8"/> + <g fill="#303438" transform="translate(0 512) scale(.1 -.1)" stroke="none"> + <path d="M2794 3710 c-129 -33 -299 -135 -359 -214 -21 -28 -26 -42 -21 -63 9 -38 154 -178 199 -192 32 -11 41 -9 104 23 171 86 354 70 475 -43 150 -138 150 -379 0 -511 -107 -95 -278 -94 -386 2 l-46 40 -11 -29 c-16 -40 -14 -122 4 -164 60 -144 264 -222 452 -174 360 92 559 494 430 868 -36 103 -81 173 -175 267 -71 72 -100 93 -180 132 -52 26 -127 54 -167 62 -96 21 -230 20 -319 -4z M2183 3695 c-116 -32 -221 -108 -273 -199 -17 -28 -30 -54 -30 -58 0 -4 20 1 45 12 66 28 220 68 294 76 64 7 65 7 137 83 40 41 71 77 69 79 -2 2 -21 8 -42 13 -55 12 -140 10 -200 -6z M2212 3388 c-159 -22 -390 -122 -559 -241 -299 -210 -585 -600 -609 -828 -12 -118 40 -251 125 -318 96 -76 178 -98 426 -116 110 -8 224 -21 254 -29 125 -34 230 -115 272 -211 11 -24 24 -81 30 -127 20 -170 65 -271 166 -374 34 -35 63 -65 63 -67 0 -1 -10 -27 -22 -57 -29 -76 -37 -259 -14 -350 42 -170 158 -318 311 -397 44 -23 98 -46 120 -52 22 -6 45 -14 51 -18 5 -5 15 -48 22 -96 6 -48 14 -92 17 -97 4 -6 415 -10 1131 -10 l1124 0 0 1584 0 1585 -55 -19 c-84 -29 -143 -68 -232 -154 l-83 -78 -54 49 c-111 102 -233 151 -391 160 -113 6 -199 -10 -298 -54 l-60 -27 -26 34 c-37 51 -120 134 -127 128 -3 -4 0 -34 7 -67 17 -89 7 -268 -21 -356 -103 -328 -377 -545 -688 -545 -161 0 -273 41 -373 137 -37 35 -66 75 -85 116 -79 173 -8 407 124 407 44 0 68 -14 117 -66 74 -78 167 -82 238 -9 60 62 72 147 33 231 -42 90 -120 130 -238 122 -50 -4 -85 -14 -131 -37 -89 -45 -122 -52 -176 -40 -92 20 -262 163 -302 253 -11 25 -21 45 -22 45 -1 -1 -30 -6 -65 -11z m-256 -505 c115 -88 129 -102 132 -131 2 -18 -2 -40 -9 -49 -7 -8 -69 -55 -138 -105 -103 -73 -130 -88 -151 -83 -35 8 -51 34 -48 74 3 31 12 42 83 92 44 31 80 61 82 66 1 4 -30 31 -69 58 -39 28 -77 56 -85 63 -18 19 -16 72 4 94 32 35 63 23 199 -79z m528 -88 c23 -24 28 -52 14 -82 l-13 -28 -141 -3 c-130 -2 -142 -1 -158 17 -23 26 -24 66 -1 91 16 18 32 20 151 20 105 0 136 -3 148 -15z"/> + </g> +</svg> diff --git a/website/astro.config.mjs b/website/astro.config.mjs index 8afbf46f..b216e6d8 100644 --- a/website/astro.config.mjs +++ b/website/astro.config.mjs @@ -71,7 +71,7 @@ export default defineConfig({ starlight({ title: 'herdr', description: 'Terminal-native agent runtime and multiplexer.', - favicon: '/assets/favicon.png?v=14', + favicon: '/favicon.ico', defaultLocale: 'root', locales: { root: { label: 'English', lang: 'en' }, @@ -110,6 +110,12 @@ export default defineConfig({ ], customCss: ['./src/styles/starlight.css'], head: [ + { + // Google's favicon crawler rejects icons smaller than 48px + tag: 'link', + attrs: { rel: 'icon', type: 'image/png', sizes: '192x192', href: '/assets/favicon.png' }, + }, + { tag: 'link', attrs: { rel: 'apple-touch-icon', href: '/assets/logo.png' } }, // the brand display face; Starlight owns its own <head>, so the // marketing pages' font link doesn't reach docs { tag: 'link', attrs: { rel: 'preconnect', href: 'https://fonts.googleapis.com' } }, diff --git a/website/favicon.ico b/website/favicon.ico Binary files differnew file mode 100644 index 00000000..fe1d81c0 --- /dev/null +++ b/website/favicon.ico diff --git a/website/index.html b/website/index.html index 4186792e..cf8dd79a 100644 --- a/website/index.html +++ b/website/index.html @@ -47,7 +47,8 @@ /> <meta name="twitter:image:alt" content="Herdr — run them anywhere, leave them running." /> - <link rel="icon" type="image/png" sizes="32x32" href="/assets/favicon.png?v=14" /> + <link rel="icon" href="/favicon.ico" sizes="48x48" /> + <link rel="icon" type="image/png" sizes="192x192" href="/assets/favicon.png" /> <link rel="apple-touch-icon" href="/assets/logo.png" /> <link rel="preload" diff --git a/website/scripts/prepare-docs.mjs b/website/scripts/prepare-docs.mjs index e8278851..1fc8bc56 100644 --- a/website/scripts/prepare-docs.mjs +++ b/website/scripts/prepare-docs.mjs @@ -73,6 +73,7 @@ async function preparePublicAssets() { 'latest.json', 'preview.json', 'robots.txt', + 'favicon.ico', '_headers', '_redirects', ]) { diff --git a/website/src/components/MarketingLayout.astro b/website/src/components/MarketingLayout.astro index a536ec47..6db7e00d 100644 --- a/website/src/components/MarketingLayout.astro +++ b/website/src/components/MarketingLayout.astro @@ -46,7 +46,8 @@ const ogImageUrl = new URL(ogImage, 'https://herdr.dev').toString(); <meta name="twitter:image" content={ogImageUrl} /> <meta name="twitter:image:alt" content={ogImageAlt} /> - <link rel="icon" type="image/png" sizes="32x32" href="/assets/favicon.png?v=14" /> + <link rel="icon" href="/favicon.ico" sizes="48x48" /> + <link rel="icon" type="image/png" sizes="192x192" href="/assets/favicon.png" /> <link rel="apple-touch-icon" href="/assets/logo.png" /> <link rel="preload" href="/assets/jbm.woff2" as="font" type="font/woff2" crossorigin /> <script> diff --git a/website/src/components/SiteLayout.astro b/website/src/components/SiteLayout.astro index 85240b2e..f056458c 100644 --- a/website/src/components/SiteLayout.astro +++ b/website/src/components/SiteLayout.astro @@ -59,7 +59,8 @@ const facts = version ? `v${version} · Apache 2.0` : 'Apache 2.0'; <meta name="twitter:image" content={ogImageUrl} /> <meta name="twitter:image:alt" content={ogImageAlt} /> - <link rel="icon" type="image/png" sizes="32x32" href="/assets/favicon.png?v=14" /> + <link rel="icon" href="/favicon.ico" sizes="48x48" /> + <link rel="icon" type="image/png" sizes="192x192" href="/assets/favicon.png" /> <link rel="apple-touch-icon" href="/assets/logo.png" /> <link rel="preload" href="/assets/jbm.woff2?v=2" as="font" type="font/woff2" crossorigin /> <link rel="preconnect" href="https://fonts.googleapis.com" /> |
