Skip to content

Add per-widget brand favicons#44

Merged
jbeshir merged 1 commit into
mainfrom
favicon-brand-tiles
Jun 21, 2026
Merged

Add per-widget brand favicons#44
jbeshir merged 1 commit into
mainfrom
favicon-brand-tiles

Conversation

@jbeshir

@jbeshir jbeshir commented Jun 21, 2026

Copy link
Copy Markdown
Owner

Gives each widget a browser-tab favicon, consistent with the personal-site brand (rose red + gold, after beshir-personal-website/public/favicon.svg).

Design

A shared rounded rose-red tile (dark-mode-aware gradient) carries a per-widget gold/cream glyph:

Widget Glyph
function-plotter a plotted curve with a gold point
image-comparison-table a split compare panel with a gold divider
japanese-verb-tower three stacked blocks, gold cap
pennsic-planner a tent with a gold pennant

The glyphs stay legible down to 16px.

Mechanics

  • public/favicon.svg — hand-authored, dark-mode-aware (prefers-color-scheme swaps the tile gradient + glyph fills) primary icon.
  • public/favicon.ico — multi-size (16/32/48) raster fallback generated from the SVG's light variant; silences the bare /favicon.ico probe and covers legacy browsers.
  • index.html references both, .ico first with sizes="any" so modern browsers still prefer the SVG.
  • scripts/validate-widgets.mjs now asserts each widget references both icons and that both files exist in public/.

Note: favicons render only for the top-level document (the <slug>.widgets.beshir.org tab/bookmark), not for iframe embeds.

Verified in-sandbox: validate-widgets.mjs passes for all 4 widgets, and a function-plotter build copies favicon.svg + favicon.ico into dist/.

🤖 Generated with Claude Code

Each widget gets a browser-tab favicon consistent with the personal-site
brand (rose red + gold): a shared rounded rose-red tile carrying a per-widget
gold/cream glyph — a plotted curve (function-plotter), a split compare panel
(image-comparison-table), stacked blocks (japanese-verb-tower), and a tent
with a pennant (pennsic-planner).

The SVG is the dark-mode-aware primary; a generated multi-size favicon.ico
provides the legacy/probe fallback. index.html references both (ico first,
sizes=any, so modern browsers still prefer the SVG). validate-widgets.mjs now
asserts both <link>s and both files are present.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@jbeshir jbeshir merged commit 028d6a7 into main Jun 21, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant