{
  "version": 3,
  "sources": ["landing-reveal.js"],
  "sourcesContent": ["import { register } from \"../../core/components.js\";\n\n/** How much of an element has to be on the screen before it shows. */\nconst SHOWN_AT = 0.15;\n\n/**\n * Brings each `reveal` element in as it first scrolls into view - its\n * stylesheet (`_home.css`) has it rise and fade in - and leaves it shown.\n * Without the observer, or where motion is not wanted, everything shows at\n * once.\n */\nregister(\"landing-reveal\", (root) => {\n    const elements = root.find(\"[data-ref=reveal]\");\n    if (\n        !(\"IntersectionObserver\" in window) ||\n        window.matchMedia(\"(prefers-reduced-motion: reduce)\").matches\n    ) {\n        elements.addClass(\"reveal--shown\");\n        return;\n    }\n    root.addClass(\"home__sections--revealing\");\n    const observer = new IntersectionObserver(\n        (entries) => {\n            entries\n                .filter((entry) => entry.isIntersecting)\n                .forEach((entry) => {\n                    entry.target.classList.add(\"reveal--shown\");\n                    observer.unobserve(entry.target);\n                });\n        },\n        { threshold: SHOWN_AT },\n    );\n    elements.each(function () {\n        observer.observe(this);\n    });\n});\n"],
  "mappings": "AAAA,OAAS,YAAAA,MAAgB,2BAGzB,MAAMC,EAAW,IAQjBD,EAAS,iBAAmBE,GAAS,CACjC,MAAMC,EAAWD,EAAK,KAAK,mBAAmB,EAC9C,GACI,EAAE,yBAA0B,SAC5B,OAAO,WAAW,kCAAkC,EAAE,QACxD,CACEC,EAAS,SAAS,eAAe,EACjC,MACJ,CACAD,EAAK,SAAS,2BAA2B,EACzC,MAAME,EAAW,IAAI,qBAChBC,GAAY,CACTA,EACK,OAAQC,GAAUA,EAAM,cAAc,EACtC,QAASA,GAAU,CAChBA,EAAM,OAAO,UAAU,IAAI,eAAe,EAC1CF,EAAS,UAAUE,EAAM,MAAM,CACnC,CAAC,CACT,EACA,CAAE,UAAWL,CAAS,CAC1B,EACAE,EAAS,KAAK,UAAY,CACtBC,EAAS,QAAQ,IAAI,CACzB,CAAC,CACL,CAAC",
  "names": ["register", "SHOWN_AT", "root", "elements", "observer", "entries", "entry"]
}
