CnStatsBlock (the primitive) supports icon: Component for an MDI Vue icon import. The dashboard widget wrapper CnStatsBlockWidget does NOT forward icon-related props from the widgetDef envelope through to the underlying component, so dashboards configured purely via JSON manifest can't put icons on their KPI tiles.
Two options to consider:
iconClass: string — forward widgetDef.props.iconClass as a CSS class applied to a wrapping <div> (consumers use NC core CSS classes like icon-link, icon-mail — already in their stylesheet). Easiest to ship.
iconName: string — accept an MDI icon name (e.g. 'Database') and dynamic-import the matching Vue icon. More flexible but heavier.
Used by ConductionNL/integriq#831 (KPI tiles ship icon-less for now).
CnStatsBlock(the primitive) supportsicon: Componentfor an MDI Vue icon import. The dashboard widget wrapperCnStatsBlockWidgetdoes NOT forward icon-related props from the widgetDef envelope through to the underlying component, so dashboards configured purely via JSON manifest can't put icons on their KPI tiles.Two options to consider:
iconClass: string— forwardwidgetDef.props.iconClassas a CSS class applied to a wrapping<div>(consumers use NC core CSS classes likeicon-link,icon-mail— already in their stylesheet). Easiest to ship.iconName: string— accept an MDI icon name (e.g.'Database') and dynamic-import the matching Vue icon. More flexible but heavier.Used by ConductionNL/integriq#831 (KPI tiles ship icon-less for now).