Accessibility
Image requires exactly one of alt or decorative in every mode — passing both, or neither, is a type error. How that choice is exposed depends on whether the image conveys meaning.
alt that describes purpose or content (for example, "Prepared logo" or "Officer profile photo").decorative when the image adds no information beyond surrounding text or UI chrome. It renders an empty alt and is skipped by screen readers.Do not omit alt or use placeholder strings like "image" when the image carries meaning.
Renders a native <img> with the alt attribute forwarded directly (empty when decorative is set). Screen readers announce the alt text as the image label.
Accessibility attributes are applied to the <svg> node:
alt set): role="img" and aria-label={alt}.aria-hidden={true} and focusable={false}.Both theme variants mount in the DOM, but the inactive variant uses display: none and is removed from the accessibility tree. Assistive tech announces a single image — the visible variant — with the shared alt value. Pass id once; it is applied to a display: contents themed root so the document keeps a single stable id without JavaScript theme branching (and without duplicating id on both variants).
alt text.src, the browser treats them like raster images; alt text behavior matches standard <img> semantics.