Ga naar hoofdinhoud

CnDashboardIcon

Renders an icon for any value following the dashboard icon convention: a registry key → the built-in MDI component, a URL → an <img>, or null/empty/unknown → the default icon. Pair with CnIconPicker for selection.

<CnDashboardIcon :name="dashboard.icon" :size="24" />

Props

NameTypeDefaultDescription
nameStringnullIcon identifier — a registry key (e.g. 'Star'), a URL (rendered as <img>), or null/empty for the default icon.
sizeNumber20Icon size in pixels (size on MDI components, width/height on <img>).
altStringnullAlt text for URL icons; falls back to 'icon'. Ignored for decorative MDI icons.