Problem/Motivation
The dashboard KPI card and the by-role table render the provider-type icons
as two bare Unicode characters: the cloud glyph (U+2601) and the hexagon
(U+2B21). Most system font stacks have no glyph for these, the hexagon in
particular, so they show a missing-glyph box ("tofu") instead of an icon. The
result looks broken and changes with the OS, browser and installed fonts.
Steps to reproduce
- Run a few AI operations so the dashboard has data.
- Open /admin/reports/ai-metering on a system whose fonts lack U+2601 /
U+2B21 (common on Windows and many Linux setups). - The "cloud" and "local" labels show a box glyph in front of the count.
Environment
- Drupal version: 11.x
- ai_metering version: 1.0.x
Proposed resolution
Replace the bare glyphs with inline SVG icons drawn through a CSS mask, so
they no longer depend on font coverage. The icons take the surrounding text
color via currentColor, keeping the current blue (cloud) and green (local)
styling, and are marked aria-hidden so the text label stays the accessible
name.
Remaining tasks
- Implementation, MR, green pipeline.
User interface changes
Cloud and local icons display consistently across fonts. No layout or wording
change.
API changes
N/A
Data model changes
N/A
AI assistance
N/A
Issue fork ai_metering-3610909
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #4
codeitwisely commented