CE: Site favicon matches desktop app icon#314
Merged
Conversation
- /favicon.ico now serves the real Windows .ico (16x16 + 32x32 PNGs) from the desktop crate instead of a hardcoded purple 'M' SVG - Add /favicon-32.png, /apple-touch-icon.png, /icon-512.png routes, baked in via include_bytes! from crates/modelrelay-desktop/icons/ - All four routes set Cache-Control: public, max-age=86400, immutable - Register new paths in SESSION_EXEMPT_ROUTES - Update page_shell_custom, landing, and pricing templates to link the real icons via a standard favicon/apple-touch-icon block - Update favicon_returns_success test to assert real .ico magic bytes and add apple_touch_icon_returns_png test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
/favicon-32.png,/apple-touch-icon.png,/icon-512.pngroutes (all baked viainclude_bytes!fromcrates/modelrelay-desktop/icons/)/favicon.iconow serves the real Windows.icofrom the desktop crate (16x16 + 32x32 PNG sub-images) withContent-Type: image/x-iconCache-Control: public, max-age=86400, immutableSESSION_EXEMPT_ROUTESpage_shell_custominmodelrelay-webplus the landing and pricing templates inmodelrelay-cloudto link the real icons via a standard favicon/apple-touch-icon blockfavicon_returns_successto assert real.icomagic bytes and addsapple_touch_icon_returns_pngWhy
The desktop app and the website should share branding. Today
modelrelay.iostill shows a placeholder 'M' tab icon and/apple-touch-icon.png404s on iOS bookmarks. With the designed desktop icon shipping in PR #312, the site should use the same artwork everywhere a browser expects a favicon or an apple-touch-icon.Verify
After deploy:
curl -sI https://modelrelay.io/apple-touch-icon.png→200 image/pngfile <(curl -s https://modelrelay.io/favicon.ico)→MS Windows icon resourcecurl -sI https://modelrelay.io/favicon-32.png→200 image/pngcurl -sI https://modelrelay.io/icon-512.png→200 image/png