--- /** * RequirementList.astro * --------------------------------------------------------------------------- * Renders the store rules / requirements. Each item has an mdi icon that * signals tone: 'check-decagram' / 'information' = neutral rule, * 'alert' = caution, 'close-circle' = hard no / final. * * Used on the storefront and repeated on the order page; the OrderForm also * requires an explicit acknowledgment of these. */ import Icon from '@components/Icon.astro'; import type { Requirement } from '@data/store-products'; interface Props { items: Requirement[]; /** Optional heading shown above the list. */ heading?: string; } const { items, heading } = Astro.props; // Map the requirement icon to a tone color. function toneColor(icon: Requirement['icon']): string { switch (icon) { case 'alert': return '#d8b35a'; // gold — caution case 'close-circle': return '#e5655a'; // red — hard no case 'check-decagram': case 'information': default: return 'var(--color-accent)'; } } --- {heading && (

{heading}

)}