{ "$schema": "https://ui.shadcn.com/schema/registry-item.json", "name": "scroller", "title": "Scroller", "description": "Navigation par sections avec scroll-spy (IntersectionObserver).", "files": [ { "path": "registry/valraiso/scroller/scroller.astro", "content": "---\nimport styles from \"./scroller.module.css\";\n\n/**\n * Scroller — sommaire avec scroll-spy : surligne l'entrée correspondant à la\n * section visible (IntersectionObserver) et défile en douceur au clic.\n *\n * Comportement : smooth scroll au clic, scroll-spy via IntersectionObserver\n * (l'item courant porte `data-current`), nettoyage sur `astro:before-swap`.\n *\n * Props :\n * - `items` : liste `{ name, title }` (name = id de la section cible).\n * - `class` : classe(s) ajoutée(s) au conteneur racine.\n *\n * Personnalisation (variables CSS) : --ads-scroller-gap,\n * --ads-scroller-link-color, --ads-scroller-link-current-color,\n * --ads-scroller-link-font-size.\n */\ninterface NavigationItem {\n name: string;\n title: string;\n}\n\ninterface Props {\n class?: string;\n items: NavigationItem[];\n}\n\nconst { class: className, items } = Astro.props;\n---\n\n