@tryvitris/website-harness 0.1.0-beta.5 → 0.1.0-beta.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -4
- package/agent/graph.yaml +0 -2
- package/agent/refs/components.md +5 -41
- package/agent/refs/compose.md +1 -1
- package/agent/refs/implement.md +2 -2
- package/agent/refs/jev.md +1 -1
- package/agent/refs/layout.md +1 -1
- package/agent/refs/storyboard.md +1 -1
- package/agent/refs/template-adaptation.md +1 -1
- package/bin/api/agent/evaluate.js +10 -15
- package/bin/api/agent/grade.js +10 -15
- package/bin/api/cli/api.js +18 -23
- package/bin/api/cli.js +20 -25
- package/bin/api/engine.js +11 -16
- package/bin/api/hosting.js +12 -17
- package/bin/api/index.js +2 -3
- package/bin/api/references.js +1 -2
- package/bin/api/render.js +2 -4
- package/bin/chunks/{chunk-4GZCAWWK.js → chunk-4MFPATAB.js} +2 -4
- package/bin/chunks/{chunk-5OOPJNGN.js → chunk-5JTBC6UK.js} +1 -4
- package/bin/chunks/{chunk-Z2UNY47A.js → chunk-5YSPWKFF.js} +1 -1
- package/bin/chunks/{chunk-FYN4T4SV.js → chunk-7V3OKLKH.js} +15 -26
- package/bin/chunks/{chunk-3CTBXY5K.js → chunk-FRABKM65.js} +1936 -1899
- package/bin/chunks/{chunk-4DM5TTLG.js → chunk-H7Y72HXC.js} +5 -5
- package/bin/chunks/{chunk-R7YELY3C.js → chunk-HL6JVA4A.js} +100 -81
- package/bin/chunks/{chunk-54JC5L35.js → chunk-O55LAQ2C.js} +3 -5
- package/bin/chunks/{chunk-VH7PM7KJ.js → chunk-P56ZDMX7.js} +4 -6
- package/bin/chunks/{chunk-7VLBEAFW.js → chunk-PGFFKPK6.js} +2 -2
- package/bin/chunks/{chunk-YQYHROLZ.js → chunk-QRWGFLUU.js} +2 -2
- package/bin/chunks/{chunk-CBEJZO4L.js → chunk-TTAUU3AZ.js} +2 -2
- package/bin/chunks/{chunk-E5Y46VBX.js → chunk-VTI32UGJ.js} +200 -103
- package/bin/chunks/{chunk-DRJQ4OOU.js → chunk-WOORR67N.js} +0 -45
- package/bin/chunks/{chunk-B5I45LFD.js → chunk-YZWEXHT4.js} +11 -13
- package/bin/chunks/{chunk-YCVGD2CG.js → chunk-ZIROO2U4.js} +1204 -1176
- package/bin/chunks/{chunk-42IXFXUD.js → chunk-ZWFG4GPG.js} +11 -15
- package/bin/chunks/{design-context-store-IAT2P2OC.js → design-context-store-DCZOAK56.js} +10 -15
- package/bin/chunks/{packets-VBMY4SQJ.js → packets-QOLWPRNV.js} +10 -15
- package/bin/chunks/{policy-2I37JUU3.js → policy-MP2JZXI3.js} +1 -1
- package/bin/chunks/{preparation-S4MG3RPL.js → preparation-T2IOD5SJ.js} +10 -15
- package/bin/chunks/{questions-HKELBDFL.js → questions-XK545GCX.js} +1 -11
- package/bin/types/src/agent/composition-authoring.d.ts +2 -2
- package/bin/types/src/agent/jev/calibration.d.ts +2 -2
- package/bin/types/src/agent/jev/config.d.ts +1 -1
- package/bin/types/src/agent/jev/questions.d.ts +0 -10
- package/bin/types/src/agent/jev/types.d.ts +0 -2
- package/bin/types/src/agent/site-inputs.d.ts +9 -1
- package/bin/types/src/agent/template-catalog.d.ts +20 -0
- package/bin/types/src/agent/theme-selection.d.ts +4 -2
- package/bin/types/src/build/archives.d.ts +2 -0
- package/bin/vitris-art.js +10 -15
- package/bin/vitris-build.js +3 -5
- package/bin/vitris-create-site.js +12 -17
- package/bin/vitris-cursor-hook.js +10 -15
- package/bin/vitris-eval.js +12 -17
- package/bin/vitris-go.js +14 -19
- package/bin/vitris-harvest.js +11 -16
- package/bin/vitris-knowledge.js +11 -16
- package/bin/vitris-launch-preflight.js +11 -17
- package/bin/vitris-motion-view.js +13 -19
- package/bin/vitris-references.js +4 -7
- package/bin/vitris-refresh.js +11 -16
- package/bin/vitris-stock.js +1 -1
- package/bin/vitris-themes.js +10 -15
- package/bin/vitris-upgrade.js +11 -16
- package/bin/vitris-verify-browser.js +43 -8
- package/bin/vitris-verify-performance.js +3 -5
- package/bin/vitris.js +20 -25
- package/design-system/MASTER.md +2 -2
- package/docs/CLI.md +2 -1
- package/docs/DISTRIBUTION.md +1 -1
- package/package.json +2 -7
- package/templates/site/README.md +2 -0
- package/templates/site/gitignore +1 -0
- package/bin/chunks/chunk-6H3T46F5.js +0 -25
- package/bin/chunks/chunk-ANMJRJQ5.js +0 -31
- package/bin/chunks/chunk-FOXUQXTV.js +0 -278
- package/bin/chunks/chunk-HNORQ74T.js +0 -40
- package/bin/chunks/chunk-T7DGRVTP.js +0 -458
- package/bin/types/src/agent/jev/block-catalog.d.ts +0 -95
- package/bin/types/src/agent/jev/component-select.d.ts +0 -102
- package/bin/types/src/blocks/library-profile.d.ts +0 -9
- package/bin/types/src/blocks/metadata.d.ts +0 -65
- package/bin/vitris-blocks.js +0 -238
- package/blocks/CONVENTIONS.md +0 -121
- package/blocks/INDEX.md +0 -130
- package/blocks/about/about-awards/README.md +0 -36
- package/blocks/about/about-awards/styles.css +0 -13
- package/blocks/about/about-awards/template.html +0 -1
- package/blocks/about/about-credentials/README.md +0 -33
- package/blocks/about/about-credentials/block.meta.json +0 -85
- package/blocks/about/about-credentials/styles.css +0 -4
- package/blocks/about/about-credentials/template.html +0 -1
- package/blocks/about/about-founder/README.md +0 -35
- package/blocks/about/about-founder/styles.css +0 -9
- package/blocks/about/about-founder/template.html +0 -1
- package/blocks/about/about-mission/README.md +0 -31
- package/blocks/about/about-mission/styles.css +0 -5
- package/blocks/about/about-mission/template.html +0 -1
- package/blocks/about/about-statement/README.md +0 -28
- package/blocks/about/about-statement/styles.css +0 -7
- package/blocks/about/about-statement/template.html +0 -1
- package/blocks/about/about-story/README.md +0 -35
- package/blocks/about/about-story/styles.css +0 -5
- package/blocks/about/about-story/template.html +0 -1
- package/blocks/about/about-timeline/README.md +0 -33
- package/blocks/about/about-timeline/styles.css +0 -8
- package/blocks/about/about-timeline/template.html +0 -1
- package/blocks/about/about-values/README.md +0 -31
- package/blocks/about/about-values/styles.css +0 -3
- package/blocks/about/about-values/template.html +0 -1
- package/blocks/blog/blog-featured/README.md +0 -39
- package/blocks/blog/blog-featured/styles.css +0 -12
- package/blocks/blog/blog-featured/template.html +0 -1
- package/blocks/blog/blog-index/README.md +0 -34
- package/blocks/blog/blog-index/styles.css +0 -6
- package/blocks/blog/blog-index/template.html +0 -1
- package/blocks/blog/blog-post-header/README.md +0 -31
- package/blocks/blog/blog-post-header/styles.css +0 -8
- package/blocks/blog/blog-post-header/template.html +0 -1
- package/blocks/contact/contact-cards/README.md +0 -32
- package/blocks/contact/contact-cards/styles.css +0 -7
- package/blocks/contact/contact-cards/template.html +0 -1
- package/blocks/contact/contact-chips/README.md +0 -41
- package/blocks/contact/contact-chips/styles.css +0 -13
- package/blocks/contact/contact-chips/template.html +0 -1
- package/blocks/contact/contact-hours/README.md +0 -41
- package/blocks/contact/contact-hours/block.meta.json +0 -87
- package/blocks/contact/contact-hours/styles.css +0 -8
- package/blocks/contact/contact-hours/template.html +0 -1
- package/blocks/contact/contact-map/README.md +0 -39
- package/blocks/contact/contact-map/styles.css +0 -10
- package/blocks/contact/contact-map/template.html +0 -1
- package/blocks/contact/contact-offices/README.md +0 -32
- package/blocks/contact/contact-offices/styles.css +0 -8
- package/blocks/contact/contact-offices/template.html +0 -1
- package/blocks/contact/contact-phone-first/README.md +0 -33
- package/blocks/contact/contact-phone-first/block.meta.json +0 -86
- package/blocks/contact/contact-phone-first/styles.css +0 -11
- package/blocks/contact/contact-phone-first/template.html +0 -1
- package/blocks/contact/contact-split/README.md +0 -43
- package/blocks/contact/contact-split/styles.css +0 -12
- package/blocks/contact/contact-split/template.html +0 -1
- package/blocks/contact/contact-visit/README.md +0 -36
- package/blocks/contact/contact-visit/block.meta.json +0 -88
- package/blocks/contact/contact-visit/styles.css +0 -13
- package/blocks/contact/contact-visit/template.html +0 -1
- package/blocks/contact/service-areas/README.md +0 -32
- package/blocks/contact/service-areas/styles.css +0 -9
- package/blocks/contact/service-areas/template.html +0 -1
- package/blocks/content/glossary/README.md +0 -35
- package/blocks/content/glossary/styles.css +0 -6
- package/blocks/content/glossary/template.html +0 -1
- package/blocks/content/list-split/README.md +0 -33
- package/blocks/content/list-split/styles.css +0 -13
- package/blocks/content/list-split/template.html +0 -1
- package/blocks/content/prose-split/README.md +0 -32
- package/blocks/content/prose-split/styles.css +0 -12
- package/blocks/content/prose-split/template.html +0 -1
- package/blocks/content/specification-ledger/README.md +0 -32
- package/blocks/content/specification-ledger/block.meta.json +0 -85
- package/blocks/content/specification-ledger/styles.css +0 -10
- package/blocks/content/specification-ledger/template.html +0 -1
- package/blocks/cta/cta-band/README.md +0 -33
- package/blocks/cta/cta-band/styles.css +0 -11
- package/blocks/cta/cta-band/template.html +0 -1
- package/blocks/cta/cta-card/README.md +0 -35
- package/blocks/cta/cta-card/styles.css +0 -8
- package/blocks/cta/cta-card/template.html +0 -1
- package/blocks/cta/cta-floating-bar/README.md +0 -28
- package/blocks/cta/cta-floating-bar/styles.css +0 -8
- package/blocks/cta/cta-floating-bar/template.html +0 -1
- package/blocks/cta/cta-inline/README.md +0 -30
- package/blocks/cta/cta-inline/styles.css +0 -9
- package/blocks/cta/cta-inline/template.html +0 -1
- package/blocks/cta/cta-newsletter/README.md +0 -34
- package/blocks/cta/cta-newsletter/styles.css +0 -8
- package/blocks/cta/cta-newsletter/template.html +0 -1
- package/blocks/cta/cta-photo-fan/README.md +0 -36
- package/blocks/cta/cta-photo-fan/styles.css +0 -14
- package/blocks/cta/cta-photo-fan/template.html +0 -1
- package/blocks/cta/cta-split/README.md +0 -38
- package/blocks/cta/cta-split/styles.css +0 -10
- package/blocks/cta/cta-split/template.html +0 -1
- package/blocks/faq/faq-accordion/README.md +0 -36
- package/blocks/faq/faq-accordion/styles.css +0 -6
- package/blocks/faq/faq-accordion/template.html +0 -1
- package/blocks/faq/faq-grouped/README.md +0 -40
- package/blocks/faq/faq-grouped/styles.css +0 -20
- package/blocks/faq/faq-grouped/template.html +0 -1
- package/blocks/faq/faq-split/README.md +0 -37
- package/blocks/faq/faq-split/styles.css +0 -5
- package/blocks/faq/faq-split/template.html +0 -1
- package/blocks/faq/faq-tabs/README.md +0 -36
- package/blocks/faq/faq-tabs/styles.css +0 -3
- package/blocks/faq/faq-tabs/template.html +0 -1
- package/blocks/feature/feature-bento/README.md +0 -33
- package/blocks/feature/feature-bento/styles.css +0 -7
- package/blocks/feature/feature-bento/template.html +0 -1
- package/blocks/feature/feature-compare-table/README.md +0 -44
- package/blocks/feature/feature-compare-table/styles.css +0 -15
- package/blocks/feature/feature-compare-table/template.html +0 -1
- package/blocks/feature/feature-comparison/README.md +0 -34
- package/blocks/feature/feature-comparison/styles.css +0 -6
- package/blocks/feature/feature-comparison/template.html +0 -1
- package/blocks/feature/feature-grid-3/README.md +0 -34
- package/blocks/feature/feature-grid-3/styles.css +0 -8
- package/blocks/feature/feature-grid-3/template.html +0 -1
- package/blocks/feature/feature-icon-list/README.md +0 -39
- package/blocks/feature/feature-icon-list/styles.css +0 -9
- package/blocks/feature/feature-icon-list/template.html +0 -1
- package/blocks/feature/feature-spotlight/README.md +0 -39
- package/blocks/feature/feature-spotlight/styles.css +0 -5
- package/blocks/feature/feature-spotlight/template.html +0 -1
- package/blocks/feature/feature-stats-band/README.md +0 -33
- package/blocks/feature/feature-stats-band/styles.css +0 -8
- package/blocks/feature/feature-stats-band/template.html +0 -1
- package/blocks/feature/feature-tabs/README.md +0 -38
- package/blocks/feature/feature-tabs/styles.css +0 -7
- package/blocks/feature/feature-tabs/template.html +0 -1
- package/blocks/feature/feature-thumb-list/README.md +0 -38
- package/blocks/feature/feature-thumb-list/styles.css +0 -13
- package/blocks/feature/feature-thumb-list/template.html +0 -1
- package/blocks/feature/feature-zigzag/README.md +0 -31
- package/blocks/feature/feature-zigzag/styles.css +0 -6
- package/blocks/feature/feature-zigzag/template.html +0 -1
- package/blocks/footer/footer-columns/README.md +0 -39
- package/blocks/footer/footer-columns/styles.css +0 -16
- package/blocks/footer/footer-columns/template.html +0 -1
- package/blocks/footer/footer-compact/README.md +0 -33
- package/blocks/footer/footer-compact/styles.css +0 -12
- package/blocks/footer/footer-compact/template.html +0 -1
- package/blocks/footer/footer-cta/README.md +0 -37
- package/blocks/footer/footer-cta/styles.css +0 -18
- package/blocks/footer/footer-cta/template.html +0 -1
- package/blocks/footer/footer-social/README.md +0 -37
- package/blocks/footer/footer-social/styles.css +0 -17
- package/blocks/footer/footer-social/template.html +0 -1
- package/blocks/footer/footer-wordmark/README.md +0 -40
- package/blocks/footer/footer-wordmark/styles.css +0 -19
- package/blocks/footer/footer-wordmark/template.html +0 -1
- package/blocks/gallery/gallery-before-after/README.md +0 -31
- package/blocks/gallery/gallery-before-after/styles.css +0 -6
- package/blocks/gallery/gallery-before-after/template.html +0 -1
- package/blocks/gallery/gallery-carousel/README.md +0 -32
- package/blocks/gallery/gallery-carousel/styles.css +0 -7
- package/blocks/gallery/gallery-carousel/template.html +0 -1
- package/blocks/gallery/gallery-grid/README.md +0 -39
- package/blocks/gallery/gallery-grid/styles.css +0 -13
- package/blocks/gallery/gallery-grid/template.html +0 -1
- package/blocks/gallery/gallery-masonry/README.md +0 -33
- package/blocks/gallery/gallery-masonry/styles.css +0 -4
- package/blocks/gallery/gallery-masonry/template.html +0 -1
- package/blocks/gallery/gallery-mosaic-split/README.md +0 -40
- package/blocks/gallery/gallery-mosaic-split/styles.css +0 -15
- package/blocks/gallery/gallery-mosaic-split/template.html +0 -1
- package/blocks/hero/hero-asymmetric/README.md +0 -34
- package/blocks/hero/hero-asymmetric/styles.css +0 -13
- package/blocks/hero/hero-asymmetric/template.html +0 -10
- package/blocks/hero/hero-before-after/README.md +0 -38
- package/blocks/hero/hero-before-after/styles.css +0 -8
- package/blocks/hero/hero-before-after/template.html +0 -19
- package/blocks/hero/hero-editorial/README.md +0 -34
- package/blocks/hero/hero-editorial/block.meta.json +0 -85
- package/blocks/hero/hero-editorial/styles.css +0 -6
- package/blocks/hero/hero-editorial/template.html +0 -10
- package/blocks/hero/hero-evidence/README.md +0 -32
- package/blocks/hero/hero-evidence/block.meta.json +0 -85
- package/blocks/hero/hero-evidence/styles.css +0 -13
- package/blocks/hero/hero-evidence/template.html +0 -1
- package/blocks/hero/hero-form/README.md +0 -46
- package/blocks/hero/hero-form/styles.css +0 -11
- package/blocks/hero/hero-form/template.html +0 -15
- package/blocks/hero/hero-menu/README.md +0 -36
- package/blocks/hero/hero-menu/styles.css +0 -7
- package/blocks/hero/hero-menu/template.html +0 -10
- package/blocks/hero/hero-overlay/README.md +0 -35
- package/blocks/hero/hero-overlay/styles.css +0 -14
- package/blocks/hero/hero-overlay/template.html +0 -10
- package/blocks/hero/hero-page/README.md +0 -35
- package/blocks/hero/hero-page/styles.css +0 -19
- package/blocks/hero/hero-page/template.html +0 -1
- package/blocks/hero/hero-product/README.md +0 -41
- package/blocks/hero/hero-product/styles.css +0 -11
- package/blocks/hero/hero-product/template.html +0 -14
- package/blocks/hero/hero-service/README.md +0 -37
- package/blocks/hero/hero-service/block.meta.json +0 -85
- package/blocks/hero/hero-service/styles.css +0 -17
- package/blocks/hero/hero-service/template.html +0 -1
- package/blocks/hero/hero-split/README.md +0 -36
- package/blocks/hero/hero-split/styles.css +0 -7
- package/blocks/hero/hero-split/template.html +0 -11
- package/blocks/hero/hero-statement/README.md +0 -33
- package/blocks/hero/hero-statement/styles.css +0 -8
- package/blocks/hero/hero-statement/template.html +0 -1
- package/blocks/hero/hero-stats/README.md +0 -37
- package/blocks/hero/hero-stats/styles.css +0 -10
- package/blocks/hero/hero-stats/template.html +0 -10
- package/blocks/hero/hero-video-still/README.md +0 -36
- package/blocks/hero/hero-video-still/styles.css +0 -9
- package/blocks/hero/hero-video-still/template.html +0 -13
- package/blocks/icons.md +0 -44
- package/blocks/incentives/incentive-banner/README.md +0 -28
- package/blocks/incentives/incentive-banner/styles.css +0 -7
- package/blocks/incentives/incentive-banner/template.html +0 -1
- package/blocks/incentives/incentive-cards/README.md +0 -31
- package/blocks/incentives/incentive-cards/styles.css +0 -4
- package/blocks/incentives/incentive-cards/template.html +0 -1
- package/blocks/navbar/nav-announcement/README.md +0 -35
- package/blocks/navbar/nav-announcement/styles.css +0 -10
- package/blocks/navbar/nav-announcement/template.html +0 -14
- package/blocks/navbar/nav-centered/README.md +0 -35
- package/blocks/navbar/nav-centered/styles.css +0 -11
- package/blocks/navbar/nav-centered/template.html +0 -12
- package/blocks/navbar/nav-minimal/README.md +0 -29
- package/blocks/navbar/nav-minimal/styles.css +0 -5
- package/blocks/navbar/nav-minimal/template.html +0 -6
- package/blocks/navbar/nav-split/README.md +0 -34
- package/blocks/navbar/nav-split/styles.css +0 -11
- package/blocks/navbar/nav-split/template.html +0 -11
- package/blocks/navbar/nav-utility/README.md +0 -37
- package/blocks/navbar/nav-utility/styles.css +0 -17
- package/blocks/navbar/nav-utility/template.html +0 -12
- package/blocks/pricing/menu-featured/README.md +0 -34
- package/blocks/pricing/menu-featured/styles.css +0 -4
- package/blocks/pricing/menu-featured/template.html +0 -1
- package/blocks/pricing/menu-sections/README.md +0 -33
- package/blocks/pricing/menu-sections/styles.css +0 -9
- package/blocks/pricing/menu-sections/template.html +0 -1
- package/blocks/pricing/pricing-table/README.md +0 -40
- package/blocks/pricing/pricing-table/styles.css +0 -9
- package/blocks/pricing/pricing-table/template.html +0 -1
- package/blocks/pricing/pricing-tiers/README.md +0 -34
- package/blocks/pricing/pricing-tiers/styles.css +0 -7
- package/blocks/pricing/pricing-tiers/template.html +0 -1
- package/blocks/pricing/pricing-toggle/README.md +0 -34
- package/blocks/pricing/pricing-toggle/styles.css +0 -10
- package/blocks/pricing/pricing-toggle/template.html +0 -1
- package/blocks/process/process-carousel/README.md +0 -33
- package/blocks/process/process-carousel/styles.css +0 -5
- package/blocks/process/process-carousel/template.html +0 -1
- package/blocks/process/process-split/README.md +0 -35
- package/blocks/process/process-split/styles.css +0 -6
- package/blocks/process/process-split/template.html +0 -1
- package/blocks/process/process-stepper/README.md +0 -40
- package/blocks/process/process-stepper/styles.css +0 -11
- package/blocks/process/process-stepper/template.html +0 -1
- package/blocks/process/process-steps/README.md +0 -35
- package/blocks/process/process-steps/styles.css +0 -6
- package/blocks/process/process-steps/template.html +0 -1
- package/blocks/process/process-sticky/README.md +0 -38
- package/blocks/process/process-sticky/styles.css +0 -12
- package/blocks/process/process-sticky/template.html +0 -1
- package/blocks/process/process-timeline/README.md +0 -35
- package/blocks/process/process-timeline/styles.css +0 -10
- package/blocks/process/process-timeline/template.html +0 -1
- package/blocks/services/services-cards/README.md +0 -34
- package/blocks/services/services-cards/styles.css +0 -3
- package/blocks/services/services-cards/template.html +0 -1
- package/blocks/services/services-carousel/README.md +0 -34
- package/blocks/services/services-carousel/styles.css +0 -6
- package/blocks/services/services-carousel/template.html +0 -1
- package/blocks/services/services-list/README.md +0 -32
- package/blocks/services/services-list/block.meta.json +0 -85
- package/blocks/services/services-list/styles.css +0 -10
- package/blocks/services/services-list/template.html +0 -1
- package/blocks/services/services-menu/README.md +0 -39
- package/blocks/services/services-menu/styles.css +0 -6
- package/blocks/services/services-menu/template.html +0 -1
- package/blocks/services/services-packages/README.md +0 -34
- package/blocks/services/services-packages/styles.css +0 -6
- package/blocks/services/services-packages/template.html +0 -1
- package/blocks/services/services-panels/README.md +0 -36
- package/blocks/services/services-panels/styles.css +0 -15
- package/blocks/services/services-panels/template.html +0 -1
- package/blocks/services/services-photo-grid/README.md +0 -39
- package/blocks/services/services-photo-grid/styles.css +0 -10
- package/blocks/services/services-photo-grid/template.html +0 -1
- package/blocks/services/services-priority/README.md +0 -33
- package/blocks/services/services-priority/block.meta.json +0 -86
- package/blocks/services/services-priority/styles.css +0 -16
- package/blocks/services/services-priority/template.html +0 -1
- package/blocks/stats/stats-cards/README.md +0 -31
- package/blocks/stats/stats-cards/styles.css +0 -4
- package/blocks/stats/stats-cards/template.html +0 -1
- package/blocks/stats/stats-mosaic/README.md +0 -27
- package/blocks/stats/stats-mosaic/styles.css +0 -9
- package/blocks/stats/stats-mosaic/template.html +0 -1
- package/blocks/stats/stats-row/README.md +0 -29
- package/blocks/stats/stats-row/styles.css +0 -8
- package/blocks/stats/stats-row/template.html +0 -1
- package/blocks/stats/stats-split/README.md +0 -35
- package/blocks/stats/stats-split/styles.css +0 -3
- package/blocks/stats/stats-split/template.html +0 -1
- package/blocks/team/team-featured/README.md +0 -42
- package/blocks/team/team-featured/styles.css +0 -9
- package/blocks/team/team-featured/template.html +0 -1
- package/blocks/team/team-grid/README.md +0 -35
- package/blocks/team/team-grid/styles.css +0 -8
- package/blocks/team/team-grid/template.html +0 -1
- package/blocks/team/team-list/README.md +0 -32
- package/blocks/team/team-list/styles.css +0 -7
- package/blocks/team/team-list/template.html +0 -1
- package/blocks/testimonial/testimonial-carousel/README.md +0 -32
- package/blocks/testimonial/testimonial-carousel/styles.css +0 -7
- package/blocks/testimonial/testimonial-carousel/template.html +0 -1
- package/blocks/testimonial/testimonial-grid/README.md +0 -32
- package/blocks/testimonial/testimonial-grid/styles.css +0 -5
- package/blocks/testimonial/testimonial-grid/template.html +0 -1
- package/blocks/testimonial/testimonial-mosaic/README.md +0 -38
- package/blocks/testimonial/testimonial-mosaic/styles.css +0 -14
- package/blocks/testimonial/testimonial-mosaic/template.html +0 -1
- package/blocks/testimonial/testimonial-platform/README.md +0 -34
- package/blocks/testimonial/testimonial-platform/styles.css +0 -17
- package/blocks/testimonial/testimonial-platform/template.html +0 -1
- package/blocks/testimonial/testimonial-rating/README.md +0 -28
- package/blocks/testimonial/testimonial-rating/styles.css +0 -6
- package/blocks/testimonial/testimonial-rating/template.html +0 -1
- package/blocks/testimonial/testimonial-spotlight/README.md +0 -31
- package/blocks/testimonial/testimonial-spotlight/styles.css +0 -9
- package/blocks/testimonial/testimonial-spotlight/template.html +0 -1
- package/blocks/testimonial/testimonial-switcher/README.md +0 -39
- package/blocks/testimonial/testimonial-switcher/styles.css +0 -23
- package/blocks/testimonial/testimonial-switcher/template.html +0 -1
- package/blocks/testimonial/testimonial-wall/README.md +0 -34
- package/blocks/testimonial/testimonial-wall/styles.css +0 -7
- package/blocks/testimonial/testimonial-wall/template.html +0 -1
- package/blocks/trust-strip/trust-badges/README.md +0 -30
- package/blocks/trust-strip/trust-badges/styles.css +0 -5
- package/blocks/trust-strip/trust-badges/template.html +0 -1
- package/blocks/trust-strip/trust-certs/README.md +0 -31
- package/blocks/trust-strip/trust-certs/styles.css +0 -12
- package/blocks/trust-strip/trust-certs/template.html +0 -1
- package/blocks/trust-strip/trust-logos/README.md +0 -32
- package/blocks/trust-strip/trust-logos/styles.css +0 -5
- package/blocks/trust-strip/trust-logos/template.html +0 -1
- package/blocks/trust-strip/trust-quote/README.md +0 -29
- package/blocks/trust-strip/trust-quote/styles.css +0 -5
- package/blocks/trust-strip/trust-quote/template.html +0 -1
- package/blocks/trust-strip/trust-reviews/README.md +0 -35
- package/blocks/trust-strip/trust-reviews/styles.css +0 -9
- package/blocks/trust-strip/trust-reviews/template.html +0 -1
- package/blocks/work/case-alternating/README.md +0 -34
- package/blocks/work/case-alternating/block.meta.json +0 -86
- package/blocks/work/case-alternating/styles.css +0 -7
- package/blocks/work/case-alternating/template.html +0 -1
- package/blocks/work/case-carousel/README.md +0 -26
- package/blocks/work/case-carousel/styles.css +0 -7
- package/blocks/work/case-carousel/template.html +0 -1
- package/blocks/work/case-header/README.md +0 -38
- package/blocks/work/case-header/styles.css +0 -18
- package/blocks/work/case-header/template.html +0 -1
- package/blocks/work/project-evidence/README.md +0 -35
- package/blocks/work/project-evidence/block.meta.json +0 -87
- package/blocks/work/project-evidence/styles.css +0 -12
- package/blocks/work/project-evidence/template.html +0 -1
- package/blocks/work/project-grid/README.md +0 -38
- package/blocks/work/project-grid/styles.css +0 -9
- package/blocks/work/project-grid/template.html +0 -1
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
import type { JevClient } from "./client.ts";
|
|
2
|
-
import { partitionBatchItems } from "./batching.ts";
|
|
3
|
-
import { type ComponentFitDimension } from "./questions.ts";
|
|
4
|
-
import { loadBlockLibrary, type BlockRecord, type SectionState } from "./block-catalog.ts";
|
|
5
|
-
export declare const COMPONENT_FIT_WEIGHTS: Record<ComponentFitDimension, number>;
|
|
6
|
-
export declare const CUSTOM_CANDIDATE_ID = "custom";
|
|
7
|
-
export interface ComponentRecommendation {
|
|
8
|
-
id: string;
|
|
9
|
-
score: number;
|
|
10
|
-
scoreState?: "observed" | "partial" | "unavailable";
|
|
11
|
-
reasonCodes: string[];
|
|
12
|
-
adaptations: string[];
|
|
13
|
-
exampleHandle: string;
|
|
14
|
-
previewEvidence?: BlockRecord["previewEvidence"];
|
|
15
|
-
custom: boolean;
|
|
16
|
-
}
|
|
17
|
-
export interface ComponentSelectResult {
|
|
18
|
-
libraryProfile?: string;
|
|
19
|
-
libraryReleaseIdentity?: string;
|
|
20
|
-
ranked: ComponentRecommendation[];
|
|
21
|
-
routeToAgent: boolean;
|
|
22
|
-
reason?: string;
|
|
23
|
-
cacheKey: string;
|
|
24
|
-
raw: Record<string, unknown>;
|
|
25
|
-
receiptIds?: string[];
|
|
26
|
-
cacheHit?: boolean;
|
|
27
|
-
provenance?: ComponentCacheProvenance;
|
|
28
|
-
discovery?: {
|
|
29
|
-
eligibleIds: string[];
|
|
30
|
-
rejected: Array<{
|
|
31
|
-
id: string;
|
|
32
|
-
reason: string;
|
|
33
|
-
}>;
|
|
34
|
-
shortlistIds: string[];
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
export interface ComponentCacheProvenance {
|
|
38
|
-
libraryProfile?: string;
|
|
39
|
-
libraryReleaseIdentity?: string;
|
|
40
|
-
preparationId: string;
|
|
41
|
-
cacheKey: string;
|
|
42
|
-
libraryHash: string;
|
|
43
|
-
stateHash: string;
|
|
44
|
-
model: string;
|
|
45
|
-
policy: string;
|
|
46
|
-
questionSemantics: string;
|
|
47
|
-
receiptIds: string[];
|
|
48
|
-
}
|
|
49
|
-
export declare function cacheKeyForSelection(opts: {
|
|
50
|
-
state: SectionState;
|
|
51
|
-
libraryHash: string;
|
|
52
|
-
model: string;
|
|
53
|
-
policy: string;
|
|
54
|
-
questionSemantics?: string;
|
|
55
|
-
profile?: string;
|
|
56
|
-
}): string;
|
|
57
|
-
export declare function componentStateHash(state: SectionState): string;
|
|
58
|
-
export declare function planComponentQuestions(state: SectionState, lib: ReturnType<typeof loadBlockLibrary>): {
|
|
59
|
-
questionIds: string[];
|
|
60
|
-
partitions: ReturnType<typeof partitionBatchItems>["partitions"];
|
|
61
|
-
stateHash: string;
|
|
62
|
-
candidates: BlockRecord[];
|
|
63
|
-
discovery: NonNullable<ComponentSelectResult["discovery"]>;
|
|
64
|
-
};
|
|
65
|
-
export declare function verifyComponentCacheHit(opts: {
|
|
66
|
-
root: string;
|
|
67
|
-
cached: ComponentSelectResult;
|
|
68
|
-
state: SectionState;
|
|
69
|
-
libraryHash: string;
|
|
70
|
-
model: string;
|
|
71
|
-
policy?: string;
|
|
72
|
-
profile?: string;
|
|
73
|
-
}): {
|
|
74
|
-
ok: true;
|
|
75
|
-
} | {
|
|
76
|
-
ok: false;
|
|
77
|
-
reason: string;
|
|
78
|
-
};
|
|
79
|
-
export declare function recommendComponents(opts: {
|
|
80
|
-
root: string;
|
|
81
|
-
kernel: string;
|
|
82
|
-
client: JevClient;
|
|
83
|
-
state: SectionState;
|
|
84
|
-
preparationId?: string;
|
|
85
|
-
nodeId?: string;
|
|
86
|
-
signal?: AbortSignal;
|
|
87
|
-
}): Promise<ComponentSelectResult>;
|
|
88
|
-
export declare function draftAuthoringSnippet(block: BlockRecord, copy: {
|
|
89
|
-
heading?: string;
|
|
90
|
-
body?: string;
|
|
91
|
-
cta?: string;
|
|
92
|
-
mediaId?: string;
|
|
93
|
-
}): string;
|
|
94
|
-
export declare function attachComponentRecommendations(opts: {
|
|
95
|
-
root: string;
|
|
96
|
-
kernel: string;
|
|
97
|
-
client: JevClient;
|
|
98
|
-
nodeId: string;
|
|
99
|
-
preparationId: string;
|
|
100
|
-
inputHash?: string;
|
|
101
|
-
signal?: AbortSignal;
|
|
102
|
-
}): Promise<string>;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { type BlockLibrary } from "../agent/jev/block-catalog.ts";
|
|
2
|
-
export type LibraryProfile = "legacy-v0" | "slice-v1";
|
|
3
|
-
/** The profile is site-owned. A refresh must not rewrite launch.json. */
|
|
4
|
-
export declare function readLibraryProfile(siteRoot: string): LibraryProfile;
|
|
5
|
-
export declare function loadProfiledBlockLibrary(kernel: string, siteRoot: string): {
|
|
6
|
-
profile: LibraryProfile;
|
|
7
|
-
releaseIdentity: string;
|
|
8
|
-
library: BlockLibrary;
|
|
9
|
-
};
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
export interface BlockMeta {
|
|
2
|
-
schemaVersion: 1;
|
|
3
|
-
id: string;
|
|
4
|
-
revision: number;
|
|
5
|
-
status: "draft" | "inspected" | "pilot" | "stable" | "deprecated";
|
|
6
|
-
owner: string;
|
|
7
|
-
sourceHash: string;
|
|
8
|
-
fit: {
|
|
9
|
-
visitorJobs: string[];
|
|
10
|
-
pageRoles: string[];
|
|
11
|
-
useWhen: string[];
|
|
12
|
-
avoidWhen: string[];
|
|
13
|
-
};
|
|
14
|
-
content: {
|
|
15
|
-
requiredSlots: string[];
|
|
16
|
-
optionalSlots: string[];
|
|
17
|
-
testedItemCounts: number[];
|
|
18
|
-
};
|
|
19
|
-
media: {
|
|
20
|
-
min: number;
|
|
21
|
-
max: number;
|
|
22
|
-
optionalBehavior: string;
|
|
23
|
-
aspect: string[];
|
|
24
|
-
};
|
|
25
|
-
composition: {
|
|
26
|
-
hierarchy: string;
|
|
27
|
-
alignment: string;
|
|
28
|
-
density: string;
|
|
29
|
-
mediaProminence: string;
|
|
30
|
-
geometry: string[];
|
|
31
|
-
boundary: string;
|
|
32
|
-
};
|
|
33
|
-
adaptation: {
|
|
34
|
-
flexible: string[];
|
|
35
|
-
invariants: string[];
|
|
36
|
-
customWhen: string[];
|
|
37
|
-
};
|
|
38
|
-
responsive: {
|
|
39
|
-
readingOrder: string;
|
|
40
|
-
reflow: string;
|
|
41
|
-
crop: string;
|
|
42
|
-
};
|
|
43
|
-
interaction: {
|
|
44
|
-
behavior: string;
|
|
45
|
-
islands: string[];
|
|
46
|
-
};
|
|
47
|
-
evidence: {
|
|
48
|
-
provenance: string[];
|
|
49
|
-
testedContexts: string[];
|
|
50
|
-
accessibility: string[];
|
|
51
|
-
previewManifest?: string;
|
|
52
|
-
};
|
|
53
|
-
}
|
|
54
|
-
export declare function blockSourceHash(dir: string): string;
|
|
55
|
-
export declare function blockPreviewRendererHash(root: string): string;
|
|
56
|
-
export declare function readBlockMeta(dir: string, id: string, slots: {
|
|
57
|
-
name: string;
|
|
58
|
-
required: boolean;
|
|
59
|
-
}[]): BlockMeta | undefined;
|
|
60
|
-
export declare function blockPreviewEvidence(dir: string, meta?: BlockMeta): {
|
|
61
|
-
status: "current" | "stale" | "unavailable";
|
|
62
|
-
mobile?: string;
|
|
63
|
-
desktop?: string;
|
|
64
|
-
hashes?: Record<string, string>;
|
|
65
|
-
};
|
package/bin/vitris-blocks.js
DELETED
|
@@ -1,238 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
3
|
-
blockPreviewRendererHash,
|
|
4
|
-
blockSourceHash,
|
|
5
|
-
loadBlockLibrary,
|
|
6
|
-
loadProfiledBlockLibrary
|
|
7
|
-
} from "./chunks/chunk-FOXUQXTV.js";
|
|
8
|
-
import "./chunks/chunk-HNORQ74T.js";
|
|
9
|
-
import {
|
|
10
|
-
baseCss,
|
|
11
|
-
flattenBody,
|
|
12
|
-
primitivesCss,
|
|
13
|
-
siteIslands
|
|
14
|
-
} from "./chunks/chunk-YCVGD2CG.js";
|
|
15
|
-
import {
|
|
16
|
-
themeCss
|
|
17
|
-
} from "./chunks/chunk-LKN75JGA.js";
|
|
18
|
-
import {
|
|
19
|
-
defaultTheme
|
|
20
|
-
} from "./chunks/chunk-YYPYYOEV.js";
|
|
21
|
-
import "./chunks/chunk-GZDLXYZV.js";
|
|
22
|
-
import "./chunks/chunk-7FS67SRF.js";
|
|
23
|
-
|
|
24
|
-
// scripts/blocks-preview.ts
|
|
25
|
-
import { mkdirSync, readdirSync, readFileSync, writeFileSync, existsSync, statSync, unlinkSync } from "node:fs";
|
|
26
|
-
import { join, dirname, normalize, extname, resolve } from "node:path";
|
|
27
|
-
import { fileURLToPath } from "node:url";
|
|
28
|
-
import { createServer } from "node:http";
|
|
29
|
-
import { createHash } from "node:crypto";
|
|
30
|
-
var kernelRoot = join(dirname(fileURLToPath(import.meta.url)), "..");
|
|
31
|
-
var blocksRoot = join(kernelRoot, "blocks");
|
|
32
|
-
var argv = process.argv.slice(2);
|
|
33
|
-
var outIndex = argv.indexOf("--out");
|
|
34
|
-
var siteIndex = argv.indexOf("--site");
|
|
35
|
-
var siteRoot = siteIndex >= 0 && argv[siteIndex + 1] ? resolve(argv[siteIndex + 1]) : void 0;
|
|
36
|
-
var installed = /(^|[/\\])node_modules([/\\]|$)/.test(kernelRoot);
|
|
37
|
-
var outRoot = outIndex >= 0 && argv[outIndex + 1] ? resolve(argv[outIndex + 1]) : join(siteRoot || (installed ? process.cwd() : kernelRoot), "dist", "blocks");
|
|
38
|
-
var profiled = siteRoot ? loadProfiledBlockLibrary(kernelRoot, siteRoot) : void 0;
|
|
39
|
-
var library = new Map((profiled?.library || loadBlockLibrary(kernelRoot)).blocks.map((block) => [block.id, block]));
|
|
40
|
-
var sha = (bytes) => createHash("sha256").update(bytes).digest("hex");
|
|
41
|
-
var esc = (value) => value.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """);
|
|
42
|
-
function imageStatus(id, dir, previewHtml) {
|
|
43
|
-
const block = library.get(id);
|
|
44
|
-
const rel = block?.meta?.evidence.previewManifest;
|
|
45
|
-
if (!rel) return { status: "unavailable" };
|
|
46
|
-
const file = join(dir, rel);
|
|
47
|
-
if (!existsSync(file)) return { status: "unavailable" };
|
|
48
|
-
try {
|
|
49
|
-
const manifest = JSON.parse(readFileSync(file, "utf8"));
|
|
50
|
-
const valid = manifest.blockId === id && manifest.sourceHash === blockSourceHash(dir) && manifest.previewHtmlHash === sha(previewHtml) && manifest.rendererHash === blockPreviewRendererHash(kernelRoot) && ["mobile", "desktop"].every((kind) => {
|
|
51
|
-
const image = manifest.images?.[kind];
|
|
52
|
-
return image?.file && existsSync(join(dirname(file), image.file)) && sha(readFileSync(join(dirname(file), image.file))) === image.hash;
|
|
53
|
-
});
|
|
54
|
-
return { status: valid ? "current" : "stale", manifest: rel };
|
|
55
|
-
} catch {
|
|
56
|
-
return { status: "stale", manifest: rel };
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
function placeholder(w, h, label) {
|
|
60
|
-
const fs = Math.max(12, Math.round(Math.min(w, h) / 9));
|
|
61
|
-
const svg = `<svg xmlns="http://www.w3.org/2000/svg" width="${w}" height="${h}" viewBox="0 0 ${w} ${h}"><defs><linearGradient id="g" x1="0" y1="0" x2="1" y2="1"><stop offset="0" stop-color="#cbbba9"/><stop offset="1" stop-color="#7a6756"/></linearGradient></defs><rect width="${w}" height="${h}" fill="url(#g)"/><text x="50%" y="50%" dominant-baseline="middle" text-anchor="middle" font-family="system-ui,sans-serif" font-size="${fs}" fill="#fff" opacity="0.7">${label}</text></svg>`;
|
|
62
|
-
return `data:image/svg+xml;charset=utf-8,${encodeURIComponent(svg)}`;
|
|
63
|
-
}
|
|
64
|
-
function placeholderMedia(html) {
|
|
65
|
-
return html.replace(/<img\b[^>]*>/g, (tag) => {
|
|
66
|
-
const src = tag.match(/\bsrc="([^"]*)"/)?.[1] ?? "";
|
|
67
|
-
if (!/^\/(media|stock)\//.test(src)) return tag;
|
|
68
|
-
const w = Number(tag.match(/\bwidth="(\d+)"/)?.[1] ?? 1200);
|
|
69
|
-
const h = Number(tag.match(/\bheight="(\d+)"/)?.[1] ?? 900);
|
|
70
|
-
const isLogo = /logo/i.test(src) || w <= 240 && h <= 80;
|
|
71
|
-
const isAvatar = /avatar|review|portrait-sm/i.test(src) || w === h && w <= 160;
|
|
72
|
-
const label = isLogo ? "logo" : isAvatar ? "" : `${w}\xD7${h}`;
|
|
73
|
-
const fill = isLogo ? placeholderLogo(w, h) : placeholder(w, h, label);
|
|
74
|
-
return tag.replace(/\bsrc="[^"]*"/, `src="${fill}"`);
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
function placeholderLogo(w, h) {
|
|
78
|
-
const svg = `<svg xmlns="http://www.w3.org/2000/svg" width="${w}" height="${h}" viewBox="0 0 ${w} ${h}"><rect x="2" y="${h / 4}" width="${h / 2}" height="${h / 2}" rx="4" fill="#555"/><rect x="${h / 2 + 10}" y="${h / 2 - 5}" width="${w - h / 2 - 14}" height="10" rx="5" fill="#555"/></svg>`;
|
|
79
|
-
return `data:image/svg+xml;charset=utf-8,${encodeURIComponent(svg)}`;
|
|
80
|
-
}
|
|
81
|
-
function readmeExample(readme) {
|
|
82
|
-
const m = readme.match(/## Example\s*```html\s*([\s\S]*?)```/);
|
|
83
|
-
return m ? m[1].trim() : null;
|
|
84
|
-
}
|
|
85
|
-
function readmeVariants(readme) {
|
|
86
|
-
const line = readme.match(/\*\*Variants:\*\*\s*(.+)/)?.[1]?.trim() ?? "";
|
|
87
|
-
if (!line || line.startsWith("(none)")) return [];
|
|
88
|
-
return line.split(",").map((v) => v.trim()).filter(Boolean);
|
|
89
|
-
}
|
|
90
|
-
function readmeLook(readme) {
|
|
91
|
-
return readme.split("\n").map((l) => l.trim()).find((l) => l && !l.startsWith("#") && !l.startsWith("-") && !l.startsWith("```")) ?? "";
|
|
92
|
-
}
|
|
93
|
-
function withVariant(example, name, variant) {
|
|
94
|
-
return example.replace(new RegExp(`^<${name}(\\s|>)`), `<${name} variant="${variant}"$1`);
|
|
95
|
-
}
|
|
96
|
-
var sharedCss = [themeCss(defaultTheme), baseCss, primitivesCss].join("\n");
|
|
97
|
-
var indexByCat = /* @__PURE__ */ new Map();
|
|
98
|
-
var total = 0;
|
|
99
|
-
var written = /* @__PURE__ */ new Set();
|
|
100
|
-
mkdirSync(outRoot, { recursive: true });
|
|
101
|
-
var cats = readdirSync(blocksRoot, { withFileTypes: true }).filter((d) => d.isDirectory()).map((d) => d.name).sort();
|
|
102
|
-
for (const cat of cats) {
|
|
103
|
-
const names = readdirSync(join(blocksRoot, cat), { withFileTypes: true }).filter((d) => d.isDirectory()).map((d) => d.name).sort();
|
|
104
|
-
for (const name of names) {
|
|
105
|
-
const dir = join(blocksRoot, cat, name);
|
|
106
|
-
if (!existsSync(join(dir, "template.html"))) continue;
|
|
107
|
-
if (!library.has(`${cat}/${name}`)) continue;
|
|
108
|
-
const catalog = {
|
|
109
|
-
[name]: {
|
|
110
|
-
html: readFileSync(join(dir, "template.html"), "utf8"),
|
|
111
|
-
css: readFileSync(join(dir, "styles.css"), "utf8"),
|
|
112
|
-
island: existsSync(join(dir, "island.js")) ? readFileSync(join(dir, "island.js"), "utf8") : null
|
|
113
|
-
}
|
|
114
|
-
};
|
|
115
|
-
const readme = existsSync(join(dir, "README.md")) ? readFileSync(join(dir, "README.md"), "utf8") : "";
|
|
116
|
-
const example = readmeExample(readme) ?? `<${name}><h2 slot="heading">${name}</h2><p>No example in README yet.</p></${name}>`;
|
|
117
|
-
const variants = readmeVariants(readme);
|
|
118
|
-
const look = readmeLook(readme);
|
|
119
|
-
const id = `${cat}/${name}`;
|
|
120
|
-
const record = library.get(id);
|
|
121
|
-
const renders = [{ file: `${name}.html`, label: name, body: example }];
|
|
122
|
-
for (const v of variants) renders.push({ file: `${name}--${v}.html`, label: `${name} \xB7 ${v}`, body: withVariant(example, name, v) });
|
|
123
|
-
const destDir = join(outRoot, cat);
|
|
124
|
-
mkdirSync(destDir, { recursive: true });
|
|
125
|
-
let baseHtml = "";
|
|
126
|
-
for (const r of renders) {
|
|
127
|
-
const flat = flattenBody(placeholderMedia(r.body), catalog, { name: "Blocks Preview", motion: { strength: "off" } });
|
|
128
|
-
const page = {
|
|
129
|
-
path: `/${cat}/${r.file}`,
|
|
130
|
-
title: r.label,
|
|
131
|
-
bodyHtml: flat.html,
|
|
132
|
-
used: [name],
|
|
133
|
-
usesMotion: false,
|
|
134
|
-
usesLeadForm: /data-lead-form/.test(flat.html)
|
|
135
|
-
};
|
|
136
|
-
const js = siteIslands([page], catalog);
|
|
137
|
-
const html = `<!doctype html>
|
|
138
|
-
<html lang="en">
|
|
139
|
-
<head>
|
|
140
|
-
<meta charset="utf-8">
|
|
141
|
-
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
142
|
-
<title>${cat}/${r.label}</title>
|
|
143
|
-
<style>${sharedCss}
|
|
144
|
-
${catalog[name].css}</style>
|
|
145
|
-
<style>.bp-bar{position:fixed;inset-inline:0;bottom:0;z-index:999;display:flex;gap:1rem;align-items:center;padding:.4rem .9rem;font:12px/1.4 system-ui,sans-serif;color:#eee;background:#1d1a17;opacity:.9}.bp-bar a{color:#fff}.bp-bar span{color:#bbb}</style>
|
|
146
|
-
</head>
|
|
147
|
-
<body>
|
|
148
|
-
${flat.html}
|
|
149
|
-
<div class="bp-bar"><a href="../index.html">\u2190 All blocks</a><strong>${cat}/${r.label}</strong><span>${look}</span></div>
|
|
150
|
-
${js.trim() ? `<script type="module">${js}</script>` : ""}
|
|
151
|
-
</body>
|
|
152
|
-
</html>`;
|
|
153
|
-
const output = join(destDir, r.file);
|
|
154
|
-
writeFileSync(output, html);
|
|
155
|
-
if (r.file === `${name}.html`) baseHtml = html;
|
|
156
|
-
written.add(output);
|
|
157
|
-
}
|
|
158
|
-
if (!indexByCat.has(cat)) indexByCat.set(cat, []);
|
|
159
|
-
const variantLinks = variants.map((v) => `<a href="${cat}/${name}--${v}.html" class="badge badge--outline">${v}</a>`).join(" ");
|
|
160
|
-
const image = imageStatus(id, dir, baseHtml);
|
|
161
|
-
const roles = record?.meta?.fit.pageRoles.join("|") || cat;
|
|
162
|
-
const jobs = record?.meta?.fit.visitorJobs.join("|") || look;
|
|
163
|
-
const geometry = record?.geometry.join("|") || "";
|
|
164
|
-
const mediaFit = record?.meta ? record.meta.media.min > 0 ? "required" : "optional" : record?.mediaRequired ? "required" : "optional";
|
|
165
|
-
indexByCat.get(cat).push(
|
|
166
|
-
`<li class="bp-item" data-role="${esc(roles)}" data-job="${esc(jobs)}" data-geometry="${esc(geometry)}" data-media="${mediaFit}"><div><a class="bp-item__name" href="${cat}/${name}.html">${esc(name)}</a><label class="bp-compare-label"><input type="checkbox" class="bp-compare" value="${cat}/${name}.html"> compare</label></div><span class="bp-item__look">${esc(look)}<small>Image evidence: ${image.status}; metadata: ${record?.metadataSource || "legacy-readme"}</small></span>${variantLinks ? `<span class="bp-item__variants">${variantLinks}</span>` : ""}</li>`
|
|
167
|
-
);
|
|
168
|
-
total++;
|
|
169
|
-
}
|
|
170
|
-
}
|
|
171
|
-
for (const cat of readdirSync(outRoot, { withFileTypes: true }).filter((d) => d.isDirectory())) {
|
|
172
|
-
const dir = join(outRoot, cat.name);
|
|
173
|
-
for (const name of readdirSync(dir)) {
|
|
174
|
-
const file = join(dir, name);
|
|
175
|
-
if (name.endsWith(".html") && !written.has(file) && statSync(file).isFile()) unlinkSync(file);
|
|
176
|
-
}
|
|
177
|
-
}
|
|
178
|
-
var groups = [...indexByCat.entries()].map(
|
|
179
|
-
([cat, items]) => `<section class="bp-group" id="${cat}"><h2>${cat} <span class="bp-count">${items.length}</span></h2><ul class="bp-list">${items.join("\n")}</ul></section>`
|
|
180
|
-
).join("\n");
|
|
181
|
-
var toc = [...indexByCat.keys()].map((cat) => `<a class="badge" href="#${cat}">${cat}</a>`).join(" ");
|
|
182
|
-
var geometryOptions = [...new Set([...library.values()].flatMap((b) => b.geometry))].sort().map((value) => `<option value="${esc(value)}">${esc(value)}</option>`).join("");
|
|
183
|
-
var roleOptions = [...new Set([...library.values()].flatMap((b) => b.meta?.fit.pageRoles || [b.category]))].sort().map((value) => `<option value="${esc(value)}">${esc(value)}</option>`).join("");
|
|
184
|
-
writeFileSync(
|
|
185
|
-
join(outRoot, "index.html"),
|
|
186
|
-
`<!doctype html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1"><title>Vitris blocks</title>
|
|
187
|
-
<style>${sharedCss}
|
|
188
|
-
.bp-head{padding-block:var(--space-8) var(--space-6);display:grid;gap:var(--space-4)}
|
|
189
|
-
.bp-toc{display:flex;flex-wrap:wrap;gap:var(--space-2)}
|
|
190
|
-
.bp-toc .badge{text-decoration:none}
|
|
191
|
-
.bp-group{padding-block:var(--space-6);border-top:1px solid var(--color-border)}
|
|
192
|
-
.bp-group h2{font-size:var(--step-2);margin-bottom:var(--space-4);display:flex;gap:.5rem;align-items:baseline}
|
|
193
|
-
.bp-count{font-family:var(--font-body);font-size:var(--step-0);color:var(--color-muted);font-weight:500}
|
|
194
|
-
.bp-list{list-style:none;margin:0;padding:0;display:grid;gap:var(--space-2)}
|
|
195
|
-
.bp-item{display:grid;grid-template-columns:14rem 1fr auto;gap:var(--space-4);align-items:center;padding:var(--space-2) 0;border-bottom:1px dashed var(--color-border)}
|
|
196
|
-
.bp-item__name{font-weight:600}
|
|
197
|
-
.bp-item__look{color:var(--color-muted);font-size:var(--step-0)}
|
|
198
|
-
.bp-item__variants{display:flex;gap:var(--space-1)}
|
|
199
|
-
.bp-item__variants .badge{text-decoration:none;min-height:1.5rem;padding:0 .5rem;font-size:.75rem}
|
|
200
|
-
.bp-item__look small{display:block;color:var(--color-muted);font-size:.75rem}
|
|
201
|
-
.bp-compare-label{display:block;font:12px system-ui;color:var(--color-muted);margin-top:.3rem}
|
|
202
|
-
.bp-filters{display:flex;flex-wrap:wrap;gap:var(--space-2);align-items:end}
|
|
203
|
-
.bp-filters label{display:grid;gap:.2rem;font:12px system-ui}
|
|
204
|
-
.bp-filters input,.bp-filters select{min-height:2.5rem;padding:.3rem .5rem}
|
|
205
|
-
.bp-compare-view{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--space-3);margin-top:var(--space-4)}
|
|
206
|
-
.bp-compare-view iframe{width:100%;height:650px;border:1px solid var(--color-border)}
|
|
207
|
-
[hidden]{display:none!important}
|
|
208
|
-
@media(max-width:719px){.bp-item{grid-template-columns:1fr}}
|
|
209
|
-
</style></head>
|
|
210
|
-
<body><main class="wrap"><header class="bp-head"><p class="eyebrow">Kernel block library</p><h1>Vitris blocks</h1><p class="lede">${total} blocks across ${indexByCat.size} categories, rendered from each block's README example with the default theme and placeholder media. Variant chips render the same example with <code>variant="\u2026"</code>. Image evidence is marked unavailable or stale when no verified capture exists.</p><div class="bp-filters"><label>Find by job or name<input id="bp-search" type="search" placeholder="e.g. hours, credentials"></label><label>Page role<select id="bp-role"><option value="">Any role</option>${roleOptions}</select></label><label>Media<select id="bp-media"><option value="">Any</option><option value="optional">Works without essential media</option><option value="required">Requires media</option></select></label><label>Geometry<select id="bp-geometry"><option value="">Any</option>${geometryOptions}</select></label></div><div class="bp-toc">${toc}</div><div class="bp-compare-view" id="bp-compare-view" hidden></div></header>${groups}</main><script>
|
|
211
|
-
const items=[...document.querySelectorAll('.bp-item')];
|
|
212
|
-
const fields=['search','role','media','geometry'].map(id=>document.getElementById('bp-'+id));
|
|
213
|
-
function filter(){const [search,role,media,geometry]=fields.map(x=>x.value.toLowerCase().trim());for(const item of items){const text=item.textContent.toLowerCase()+' '+item.dataset.job.toLowerCase();item.hidden=!!(search&&!text.includes(search)||role&&!item.dataset.role.toLowerCase().split('|').includes(role)||media&&item.dataset.media!==media||geometry&&!item.dataset.geometry.toLowerCase().split('|').includes(geometry));}for(const group of document.querySelectorAll('.bp-group'))group.hidden=![...group.querySelectorAll('.bp-item')].some(x=>!x.hidden);}
|
|
214
|
-
fields.forEach(x=>x.addEventListener('input',filter));
|
|
215
|
-
document.querySelectorAll('.bp-compare').forEach(box=>box.addEventListener('change',()=>{const selected=[...document.querySelectorAll('.bp-compare:checked')];if(selected.length>2){selected[0].checked=false;selected.shift();}const view=document.getElementById('bp-compare-view');view.hidden=!selected.length;view.innerHTML='';for(const item of selected){const frame=document.createElement('iframe');frame.title='Comparison: '+item.value;frame.src=item.value;view.append(frame);}}));
|
|
216
|
-
</script></body></html>`
|
|
217
|
-
);
|
|
218
|
-
console.log(`Wrote ${total} block previews to ${outRoot}`);
|
|
219
|
-
if (argv.includes("--serve")) {
|
|
220
|
-
const portIdx = argv.indexOf("--port");
|
|
221
|
-
const port = portIdx >= 0 ? Number(argv[portIdx + 1]) || 4173 : 4173;
|
|
222
|
-
const types = { ".html": "text/html; charset=utf-8", ".css": "text/css", ".js": "text/javascript", ".svg": "image/svg+xml" };
|
|
223
|
-
const server = createServer((req, res) => {
|
|
224
|
-
const urlPath = decodeURIComponent((req.url ?? "/").split("?")[0]);
|
|
225
|
-
let rel = normalize(urlPath).replace(/^(\.\.[/\\])+/, "");
|
|
226
|
-
if (rel.endsWith("/") || rel === "\\" || rel === "") rel = join(rel, "index.html");
|
|
227
|
-
const file = join(outRoot, rel);
|
|
228
|
-
if (!file.startsWith(outRoot) || !existsSync(file) || !statSync(file).isFile()) {
|
|
229
|
-
res.writeHead(404, { "content-type": "text/plain" }).end("Not found");
|
|
230
|
-
return;
|
|
231
|
-
}
|
|
232
|
-
res.writeHead(200, { "content-type": types[extname(file)] ?? "application/octet-stream" });
|
|
233
|
-
res.end(readFileSync(file));
|
|
234
|
-
});
|
|
235
|
-
server.listen(port, "127.0.0.1", () => {
|
|
236
|
-
console.log(`Serving block previews at http://127.0.0.1:${port}/ (Ctrl+C to stop)`);
|
|
237
|
-
});
|
|
238
|
-
}
|
package/blocks/CONVENTIONS.md
DELETED
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
# Block conventions
|
|
2
|
-
|
|
3
|
-
Original vanilla blocks for Vitris agents. Inspired by modern small-business templates (Apex / Munch / Verdict visual language) — not a port of any paid library.
|
|
4
|
-
|
|
5
|
-
## How agents use blocks
|
|
6
|
-
|
|
7
|
-
These conventions govern library maintenance and optional block reuse. In `composition-v1`, a site author may consult an eligible block after describing the content relationship; the gallery and shortlist are not mandatory authoring steps. The procedure below applies to block selection and `blocks-v0` authoring.
|
|
8
|
-
|
|
9
|
-
1. Open [`INDEX.md`](INDEX.md) and pick by **role** (hero, feature, faq, …) and **register** (trade / beauty / b2b / food / professional).
|
|
10
|
-
2. Open the block's `README.md`. The **Slots** table lists every slot and whether it is optional; the **Example** is a complete, working authoring snippet — copy it, then swap copy and media.
|
|
11
|
-
3. Copy `blocks/<category>/<name>/` into the site as `components/<your-kebab-name>/`. Rename the root class if you rename the folder (`c-<folder>`).
|
|
12
|
-
4. Compose pages with authoring tags + optional `variant="…"`.
|
|
13
|
-
|
|
14
|
-
Sites own their components. Blocks are copy sources in the kernel package (`node_modules/@vitris/kernel/blocks/`).
|
|
15
|
-
|
|
16
|
-
`blocks/` is the source of truth. `scripts/generate-blocks.ts` only produced the first draft and refuses to overwrite the library without `--force`. After editing a README, regenerate the index with `node --experimental-strip-types scripts/write-blocks-index.ts`.
|
|
17
|
-
|
|
18
|
-
## Previewing blocks
|
|
19
|
-
|
|
20
|
-
From the kernel repo: `npm run blocks:serve` renders every block's README example (once per variant) into `dist/blocks/` and serves it at `http://127.0.0.1:4173/` (default theme, placeholder media, islands live). `npm run blocks:preview` only writes the files.
|
|
21
|
-
|
|
22
|
-
From an installed package, run `vitris-blocks --out <output-directory>` (or `vitris-blocks --serve --out <output-directory>`). This is a compiled JavaScript bin; Node does not strip TypeScript under `node_modules`. The gallery marks image evidence current, stale, or unavailable, and supports job/role/media/geometry filters plus two-block comparison.
|
|
23
|
-
|
|
24
|
-
Because the preview renders the README example, the example _is_ the visual spec. Keep it realistic: 3–4 cards, real-length copy, one CTA pair.
|
|
25
|
-
|
|
26
|
-
## Anatomy of a block
|
|
27
|
-
|
|
28
|
-
```
|
|
29
|
-
blocks/<category>/<name>/
|
|
30
|
-
template.html root `.c-<name>`; bare <slot> elements; layout classes only
|
|
31
|
-
styles.css `.c-<name>…` rules on top of kernel primitives; tokens only
|
|
32
|
-
README.md look line, metadata, Slots table, Example, variants
|
|
33
|
-
island.js optional; kernel islands (`data-island="…"`) are preferred
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
### Slots carry the content classes
|
|
37
|
-
|
|
38
|
-
Templates expose bare slots. Typography classes live on the slotted content so authors control emphasis without touching the template:
|
|
39
|
-
|
|
40
|
-
```html
|
|
41
|
-
<feature-grid-3>
|
|
42
|
-
<p slot="eyebrow" class="eyebrow eyebrow--accent">Why homeowners call us first</p>
|
|
43
|
-
<h2 slot="heading">Built for Maine weather.</h2>
|
|
44
|
-
<p slot="lede" class="lede">Three things every crew member signs up for.</p>
|
|
45
|
-
<article slot="items" class="card">…</article>
|
|
46
|
-
</feature-grid-3>
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
Heroes use the default slot for `<h1>` + `<p class="lede lede--lg">` + a `.btn-group`; named slots for `eyebrow`, `media`, and optional `proof`.
|
|
50
|
-
|
|
51
|
-
### README contract (enforced by `src/blocks.test.ts`)
|
|
52
|
-
|
|
53
|
-
- `## Slots` table: `| \`slot\` | description |`. Descriptions starting with "Optional" mark non-required slots. Every `<slot name>` in the template must appear here and vice-versa; the default slot is documented as `(default)`.
|
|
54
|
-
- `## Example` fenced `html` block whose outer tag is `<name …>` and which fills every required slot.
|
|
55
|
-
- The flattened example must not leave a stray `<slot>` or nest block elements inside `<p>`.
|
|
56
|
-
|
|
57
|
-
## Section rhythm
|
|
58
|
-
|
|
59
|
-
Four useful head patterns. Choose or adapt them to the section's job and surrounding rhythm:
|
|
60
|
-
|
|
61
|
-
```html
|
|
62
|
-
<!-- left-aligned (default for feature / services / process / about / team / blog) -->
|
|
63
|
-
<div class="section__head"><slot name="eyebrow"></slot><slot name="heading"></slot><slot name="lede"></slot></div>
|
|
64
|
-
|
|
65
|
-
<!-- centered (pricing / testimonial / FAQ / CTA cards / contact cards / menu / values / trust) -->
|
|
66
|
-
<div class="section__head section__head--center">…</div>
|
|
67
|
-
|
|
68
|
-
<!-- head + actions on one row (carousels, "All projects" links) -->
|
|
69
|
-
<div class="section__head section__head--row"><div>…</div><div class="btn-group">…</div></div>
|
|
70
|
-
|
|
71
|
-
<!-- editorial split: short label column left, heading + lede right (about / work / interior pages) -->
|
|
72
|
-
<div class="section__head section__head--split"><slot name="eyebrow"></slot><slot name="heading"></slot><slot name="lede"></slot></div>
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
`.section__head` supplies a readable default measure and gap. Page-specific CSS may change those values where the composition needs it.
|
|
76
|
-
|
|
77
|
-
Interior pages need a clear page purpose, one `h1`, and a useful opening. `hero/hero-page`, `hero/hero-service`, and `work/case-header` are starting points; a site-owned opening may fit better. Use `content/prose-split`, `content/list-split`, and `content/glossary` when their structure helps the reader. Plain semantic prose is also valid.
|
|
78
|
-
|
|
79
|
-
## Spacing, borders, radii
|
|
80
|
-
|
|
81
|
-
- Prefer semantic spacing tokens. `.grid`, `.split`, and `.card__body` are useful defaults; a site-owned layout may replace them. Control trailing margins so content does not create accidental gaps.
|
|
82
|
-
- Border, surface, radius, and elevation follow the selected direction. `.card` variants provide available treatments, not required styling.
|
|
83
|
-
- Give media explicit dimensions and a deliberate crop. `.frame` and `.ratio-*` are optional presentation helpers. A hero image that is the LCP candidate should use `fetchpriority="high"`.
|
|
84
|
-
- Photo tiles with text over a scrim use `.photo-card` (`<a class="photo-card"><img><div class="photo-card__body"><h3>…</h3><p>…</p></div></a>`). The scrim and light text live in the primitive, so block CSS stays token-only.
|
|
85
|
-
- Mosaics (`testimonial-mosaic`, `gallery-mosaic-split`) span tiles with `is-wide` / `is-tall` on the slotted tile. Fill every cell in the example — an empty cell reads as a bug.
|
|
86
|
-
- Pill choices in forms use `<fieldset class="chips"><legend>…</legend><label><input type="radio"><span>…</span></label>…</fieldset>`; town lists and jump-navs reuse the same pill look.
|
|
87
|
-
- Stats: `.stat` / `.stat__value` (`--step-4`), `.stat--sm` in bands. Prices: `.price` / `.price__amount` / `.price__period`.
|
|
88
|
-
- Let long button labels reflow or change the layout so controls remain readable and reachable. On small screens, preserve essential navigation and actions; secondary actions may move into an accessible drawer.
|
|
89
|
-
|
|
90
|
-
## Mobile
|
|
91
|
-
|
|
92
|
-
Check blocks at mobile and desktop widths, and at intermediate widths where their content changes. These are examples, not universal geometry rules:
|
|
93
|
-
|
|
94
|
-
- Photo grids may stack or remain two-up when crop, captions, and tap targets support that choice.
|
|
95
|
-
- Stats can stack or pair according to label length and reading order.
|
|
96
|
-
- Navbars retain the brand, primary route access, and important actions at narrow widths; drawer transformation is one option.
|
|
97
|
-
- Tables must remain understandable and operable on narrow screens. A labeled responsive layout can be preferable to horizontal scrolling.
|
|
98
|
-
|
|
99
|
-
## Dark bands
|
|
100
|
-
|
|
101
|
-
Use `variant="dark"` where the block documents it (CTA / footer / quote / stats bands). That remaps tokens locally on the block root — not a global dark theme.
|
|
102
|
-
|
|
103
|
-
For a dark *panel inside* a light block (founder quote, stat tiles, a CTA tile in a photo grid, the service-hero quote card) put `data-scheme="dark"` on that element — in the template or on the slotted tile. It remaps the same tokens, so `.card`, `.stat`, `.btn-outline` and friends adapt without any hex in block CSS.
|
|
104
|
-
|
|
105
|
-
## Motion & islands
|
|
106
|
-
|
|
107
|
-
- Scroll reveal stays on authoring tags (`motion="editorial"`).
|
|
108
|
-
- Interactive widgets use `data-island="header|carousel|tabs|before-after|counter|lightbox"`.
|
|
109
|
-
- `data-count-to` counts integers only — leave decimals (4.9) as static text.
|
|
110
|
-
- No autoplay carousels, no scroll-jacking, no background video autoplay.
|
|
111
|
-
- Tabs (`process-stepper`, `testimonial-switcher`, `feature-tabs`) hide panels with the `hidden` attribute. If a panel has its own `display` (e.g. `.photo-card` is flex), add `.c-x__panels > [hidden]{display:none}` or the hidden panel will still render.
|
|
112
|
-
- No marquees — not for logos, not for CTA copy (`design-system/MASTER.md`). Use `trust-logos` / `trust-reviews` and a static `cta-band` instead, even when a reference site scrolls them.
|
|
113
|
-
- Hover-expanding panels (`services-panels`) must also expand on `:focus-within`, and the first panel is open by default when nothing is hovered.
|
|
114
|
-
|
|
115
|
-
## Icons
|
|
116
|
-
|
|
117
|
-
Inline SVG with class `.icon` (see [`icons.md`](icons.md)). Stroke icons, currentColor, 24 viewBox. Filled glyphs (stars, play) set `fill: currentColor; stroke: none` locally.
|
|
118
|
-
|
|
119
|
-
## Tokens only
|
|
120
|
-
|
|
121
|
-
Block CSS must use `var(--color-*)`, `var(--space-*)`, `var(--step-*)`, `var(--radius*)`, `var(--shadow-*)`. No raw hex except inside documented dark variants / overlays / scrims that intentionally set a local palette. Use `color-mix(in srgb, var(--color-text) 85%, transparent)` for translucent overlays instead of `#000`.
|