--- import Icon from '@ui/Icon.astro' import icons from '@data/icons.json' interface Props { title?: string type?: 'outline' | 'filled' } const { title, type = 'outline' } = Astro.props // Dev preview limits icons to 20 (see BaseLayout). const limit = 20 const entries = Object.entries(icons as Record }>) .filter(([, icon]) => icon.svg?.[type]) .slice(0, limit) ---

{title}

{ entries.map( ([iconName, icon]) => icon.svg?.[type] && ( ), ) } {/* 21 empty divs (flexbox filler) */} {Array.from({ length: 21 }).map(() =>
)}