bsmnt 0.4.1 → 0.4.2
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/dist/{helpers/add → application/add-hooks}/index.d.ts +4 -4
- package/dist/application/add-hooks/index.d.ts.map +1 -0
- package/dist/{helpers/add → application/add-hooks}/index.js +22 -35
- package/dist/application/add-hooks/index.js.map +1 -0
- package/dist/{utils → application/add-integration}/format-results.d.ts +1 -6
- package/dist/application/add-integration/format-results.d.ts.map +1 -0
- package/dist/{utils → application/add-integration}/format-results.js +1 -6
- package/dist/application/add-integration/format-results.js.map +1 -0
- package/dist/{helpers/integrate → application/add-integration}/index.d.ts +2 -1
- package/dist/application/add-integration/index.d.ts.map +1 -0
- package/dist/{helpers/integrate → application/add-integration}/index.js +46 -41
- package/dist/application/add-integration/index.js.map +1 -0
- package/dist/application/create-project/build-context.d.ts +9 -0
- package/dist/application/create-project/build-context.d.ts.map +1 -0
- package/dist/application/create-project/build-context.js +13 -0
- package/dist/application/create-project/build-context.js.map +1 -0
- package/dist/application/create-project/index.d.ts +44 -0
- package/dist/application/create-project/index.d.ts.map +1 -0
- package/dist/application/create-project/index.js +70 -0
- package/dist/application/create-project/index.js.map +1 -0
- package/dist/application/create-project/map-selection-to-registry.d.ts +3 -0
- package/dist/application/create-project/map-selection-to-registry.d.ts.map +1 -0
- package/dist/application/create-project/map-selection-to-registry.js +30 -0
- package/dist/application/create-project/map-selection-to-registry.js.map +1 -0
- package/dist/application/create-project/resolve-selection.d.ts +15 -0
- package/dist/application/create-project/resolve-selection.d.ts.map +1 -0
- package/dist/application/create-project/resolve-selection.js +11 -0
- package/dist/application/create-project/resolve-selection.js.map +1 -0
- package/dist/{helpers/skills → application/install-skills}/index.d.ts +1 -1
- package/dist/application/install-skills/index.d.ts.map +1 -0
- package/dist/{helpers/skills → application/install-skills}/index.js +31 -44
- package/dist/application/install-skills/index.js.map +1 -0
- package/dist/{utils/detect-project.d.ts → application/shared/project-detection.d.ts} +8 -15
- package/dist/application/shared/project-detection.d.ts.map +1 -0
- package/dist/{utils/detect-project.js → application/shared/project-detection.js} +8 -24
- package/dist/application/shared/project-detection.js.map +1 -0
- package/dist/core/create/build-plan.d.ts +8 -0
- package/dist/core/create/build-plan.d.ts.map +1 -0
- package/dist/core/create/build-plan.js +89 -0
- package/dist/core/create/build-plan.js.map +1 -0
- package/dist/core/create/execute-plan.d.ts +23 -0
- package/dist/core/create/execute-plan.d.ts.map +1 -0
- package/dist/core/create/execute-plan.js +23 -0
- package/dist/core/create/execute-plan.js.map +1 -0
- package/dist/core/create/internal-ids.d.ts +23 -0
- package/dist/core/create/internal-ids.d.ts.map +1 -0
- package/dist/core/create/internal-ids.js +36 -0
- package/dist/core/create/internal-ids.js.map +1 -0
- package/dist/core/create/registry.d.ts +12 -0
- package/dist/core/create/registry.d.ts.map +1 -0
- package/dist/core/create/registry.js +33 -0
- package/dist/core/create/registry.js.map +1 -0
- package/dist/core/create/types.d.ts +96 -0
- package/dist/core/create/types.d.ts.map +1 -0
- package/dist/core/create/types.js +2 -0
- package/dist/core/create/types.js.map +1 -0
- package/dist/domain/agents.d.ts +61 -0
- package/dist/domain/agents.d.ts.map +1 -0
- package/dist/domain/agents.js +35 -0
- package/dist/domain/agents.js.map +1 -0
- package/dist/domain/animations.d.ts +20 -0
- package/dist/domain/animations.d.ts.map +1 -0
- package/dist/domain/animations.js +13 -0
- package/dist/domain/animations.js.map +1 -0
- package/dist/domain/cms.d.ts +24 -0
- package/dist/domain/cms.d.ts.map +1 -0
- package/dist/domain/cms.js +13 -0
- package/dist/domain/cms.js.map +1 -0
- package/dist/domain/hooks.d.ts +67 -0
- package/dist/domain/hooks.d.ts.map +1 -0
- package/dist/domain/hooks.js +52 -0
- package/dist/domain/hooks.js.map +1 -0
- package/dist/domain/skills.d.ts +70 -0
- package/dist/domain/skills.d.ts.map +1 -0
- package/dist/domain/skills.js +84 -0
- package/dist/domain/skills.js.map +1 -0
- package/dist/domain/templates.d.ts +51 -0
- package/dist/domain/templates.d.ts.map +1 -0
- package/dist/domain/templates.js +27 -0
- package/dist/domain/templates.js.map +1 -0
- package/dist/index.js +124 -115
- package/dist/index.js.map +1 -1
- package/dist/infrastructure/agents/register-sanity-mcp.d.ts +12 -0
- package/dist/infrastructure/agents/register-sanity-mcp.d.ts.map +1 -0
- package/dist/infrastructure/agents/register-sanity-mcp.js +153 -0
- package/dist/infrastructure/agents/register-sanity-mcp.js.map +1 -0
- package/dist/infrastructure/create/apply-copy-paths.d.ts +3 -0
- package/dist/infrastructure/create/apply-copy-paths.d.ts.map +1 -0
- package/dist/infrastructure/create/apply-copy-paths.js +12 -0
- package/dist/infrastructure/create/apply-copy-paths.js.map +1 -0
- package/dist/infrastructure/create/apply-merge-paths.d.ts +3 -0
- package/dist/infrastructure/create/apply-merge-paths.d.ts.map +1 -0
- package/dist/infrastructure/create/apply-merge-paths.js +17 -0
- package/dist/infrastructure/create/apply-merge-paths.js.map +1 -0
- package/dist/infrastructure/create/apply-package-json.d.ts +8 -0
- package/dist/infrastructure/create/apply-package-json.d.ts.map +1 -0
- package/dist/infrastructure/create/apply-package-json.js +46 -0
- package/dist/infrastructure/create/apply-package-json.js.map +1 -0
- package/dist/infrastructure/create/copy-template.d.ts +10 -0
- package/dist/infrastructure/create/copy-template.d.ts.map +1 -0
- package/dist/infrastructure/create/copy-template.js.map +1 -0
- package/dist/infrastructure/create/executor.d.ts +3 -0
- package/dist/infrastructure/create/executor.d.ts.map +1 -0
- package/dist/infrastructure/create/executor.js +21 -0
- package/dist/infrastructure/create/executor.js.map +1 -0
- package/dist/{helpers/create/init-git.d.ts → infrastructure/create/init-git-repo.d.ts} +2 -3
- package/dist/infrastructure/create/init-git-repo.d.ts.map +1 -0
- package/dist/{helpers/create/init-git.js → infrastructure/create/init-git-repo.js} +1 -4
- package/dist/infrastructure/create/init-git-repo.js.map +1 -0
- package/dist/{helpers/create/install.d.ts → infrastructure/create/install-dependencies.d.ts} +1 -1
- package/dist/infrastructure/create/install-dependencies.d.ts.map +1 -0
- package/dist/{helpers/create/install.js → infrastructure/create/install-dependencies.js} +1 -1
- package/dist/infrastructure/create/install-dependencies.js.map +1 -0
- package/dist/infrastructure/create/lifecycle-registry.d.ts +3 -0
- package/dist/infrastructure/create/lifecycle-registry.d.ts.map +1 -0
- package/dist/infrastructure/create/lifecycle-registry.js +38 -0
- package/dist/infrastructure/create/lifecycle-registry.js.map +1 -0
- package/dist/infrastructure/create/merge-registry.d.ts +3 -0
- package/dist/infrastructure/create/merge-registry.d.ts.map +1 -0
- package/dist/infrastructure/create/merge-registry.js +27 -0
- package/dist/infrastructure/create/merge-registry.js.map +1 -0
- package/dist/infrastructure/create/rename-files.d.ts.map +1 -0
- package/dist/infrastructure/create/rename-files.js.map +1 -0
- package/dist/{helpers → infrastructure}/create/setup-agent.d.ts +9 -7
- package/dist/infrastructure/create/setup-agent.d.ts.map +1 -0
- package/dist/infrastructure/create/setup-agent.js +77 -0
- package/dist/infrastructure/create/setup-agent.js.map +1 -0
- package/dist/infrastructure/create/setup-sanity.d.ts.map +1 -0
- package/dist/{helpers → infrastructure}/create/setup-sanity.js +1 -19
- package/dist/infrastructure/create/setup-sanity.js.map +1 -0
- package/dist/infrastructure/integrations/inject-integration.d.ts +9 -0
- package/dist/infrastructure/integrations/inject-integration.d.ts.map +1 -0
- package/dist/{helpers/integrate/merge-orchestrator.js → infrastructure/integrations/inject-integration.js} +26 -38
- package/dist/infrastructure/integrations/inject-integration.js.map +1 -0
- package/dist/modules/features/agents/index.d.ts +3 -0
- package/dist/modules/features/agents/index.d.ts.map +1 -0
- package/dist/modules/features/agents/index.js +4 -0
- package/dist/modules/features/agents/index.js.map +1 -0
- package/dist/modules/features/agents/shared.d.ts +4 -0
- package/dist/modules/features/agents/shared.d.ts.map +1 -0
- package/dist/modules/features/agents/shared.js +21 -0
- package/dist/modules/features/agents/shared.js.map +1 -0
- package/dist/{configs/animations.d.ts → modules/features/animation/config.d.ts} +1 -1
- package/dist/modules/features/animation/config.d.ts.map +1 -0
- package/dist/{configs/animations.js → modules/features/animation/config.js} +1 -1
- package/dist/modules/features/animation/config.js.map +1 -0
- package/dist/modules/features/animation/gsap.d.ts +3 -0
- package/dist/modules/features/animation/gsap.d.ts.map +1 -0
- package/dist/modules/features/animation/gsap.js +16 -0
- package/dist/modules/features/animation/gsap.js.map +1 -0
- package/dist/modules/features/animation/index.d.ts +3 -0
- package/dist/modules/features/animation/index.d.ts.map +1 -0
- package/dist/modules/features/animation/index.js +4 -0
- package/dist/modules/features/animation/index.js.map +1 -0
- package/dist/modules/features/animation/motion.d.ts +3 -0
- package/dist/modules/features/animation/motion.d.ts.map +1 -0
- package/dist/modules/features/animation/motion.js +16 -0
- package/dist/modules/features/animation/motion.js.map +1 -0
- package/dist/modules/features/cms/index.d.ts +3 -0
- package/dist/modules/features/cms/index.d.ts.map +1 -0
- package/dist/modules/features/cms/index.js +7 -0
- package/dist/modules/features/cms/index.js.map +1 -0
- package/dist/modules/features/cms/sanity/config.d.ts.map +1 -0
- package/dist/{helpers/integrate → modules/features/cms}/sanity/config.js +3 -2
- package/dist/modules/features/cms/sanity/config.js.map +1 -0
- package/dist/modules/features/cms/sanity/index.d.ts +3 -0
- package/dist/modules/features/cms/sanity/index.d.ts.map +1 -0
- package/dist/modules/features/cms/sanity/index.js +61 -0
- package/dist/modules/features/cms/sanity/index.js.map +1 -0
- package/dist/{helpers/integrate/sanity/mergers/check-integration-merger.d.ts → modules/features/cms/sanity/mergers/check-integration.d.ts} +1 -1
- package/dist/modules/features/cms/sanity/mergers/check-integration.d.ts.map +1 -0
- package/dist/{helpers/integrate/sanity/mergers/check-integration-merger.js → modules/features/cms/sanity/mergers/check-integration.js} +1 -1
- package/dist/modules/features/cms/sanity/mergers/check-integration.js.map +1 -0
- package/dist/{helpers/integrate/sanity/mergers/layout-merger.d.ts → modules/features/cms/sanity/mergers/layout.d.ts} +1 -1
- package/dist/modules/features/cms/sanity/mergers/layout.d.ts.map +1 -0
- package/dist/{helpers/integrate/sanity/mergers/layout-merger.js → modules/features/cms/sanity/mergers/layout.js} +1 -1
- package/dist/modules/features/cms/sanity/mergers/layout.js.map +1 -0
- package/dist/modules/features/cms/sanity/mergers/sitemap.d.ts +13 -0
- package/dist/modules/features/cms/sanity/mergers/sitemap.d.ts.map +1 -0
- package/dist/modules/features/cms/sanity/mergers/sitemap.js +92 -0
- package/dist/modules/features/cms/sanity/mergers/sitemap.js.map +1 -0
- package/dist/modules/features/cms/sanity-pagebuilder/config.d.ts +14 -0
- package/dist/modules/features/cms/sanity-pagebuilder/config.d.ts.map +1 -0
- package/dist/modules/features/cms/sanity-pagebuilder/config.js +44 -0
- package/dist/modules/features/cms/sanity-pagebuilder/config.js.map +1 -0
- package/dist/modules/features/cms/sanity-pagebuilder/index.d.ts +3 -0
- package/dist/modules/features/cms/sanity-pagebuilder/index.d.ts.map +1 -0
- package/dist/modules/features/cms/sanity-pagebuilder/index.js +46 -0
- package/dist/modules/features/cms/sanity-pagebuilder/index.js.map +1 -0
- package/dist/modules/features/hooks/factory.d.ts +4 -0
- package/dist/modules/features/hooks/factory.d.ts.map +1 -0
- package/dist/modules/features/hooks/factory.js +26 -0
- package/dist/modules/features/hooks/factory.js.map +1 -0
- package/dist/modules/features/hooks/index.d.ts +3 -0
- package/dist/modules/features/hooks/index.d.ts.map +1 -0
- package/dist/modules/features/hooks/index.js +4 -0
- package/dist/modules/features/hooks/index.js.map +1 -0
- package/dist/modules/presets/index.d.ts +3 -0
- package/dist/modules/presets/index.d.ts.map +1 -0
- package/dist/modules/presets/index.js +11 -0
- package/dist/modules/presets/index.js.map +1 -0
- package/dist/modules/presets/next-default.d.ts +3 -0
- package/dist/modules/presets/next-default.d.ts.map +1 -0
- package/dist/modules/presets/next-default.js +9 -0
- package/dist/modules/presets/next-default.js.map +1 -0
- package/dist/modules/presets/next-experiments.d.ts +3 -0
- package/dist/modules/presets/next-experiments.d.ts.map +1 -0
- package/dist/modules/presets/next-experiments.js +9 -0
- package/dist/modules/presets/next-experiments.js.map +1 -0
- package/dist/modules/presets/next-pagebuilder.d.ts +3 -0
- package/dist/modules/presets/next-pagebuilder.d.ts.map +1 -0
- package/dist/modules/presets/next-pagebuilder.js +10 -0
- package/dist/modules/presets/next-pagebuilder.js.map +1 -0
- package/dist/modules/presets/next-webgl.d.ts +3 -0
- package/dist/modules/presets/next-webgl.d.ts.map +1 -0
- package/dist/modules/presets/next-webgl.js +9 -0
- package/dist/modules/presets/next-webgl.js.map +1 -0
- package/dist/paths.d.ts +7 -1
- package/dist/paths.d.ts.map +1 -1
- package/dist/paths.js +8 -2
- package/dist/paths.js.map +1 -1
- package/index.js +2 -2
- package/package.json +11 -4
- package/src/modules/features/cms/sanity/files/.knip.json +8 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/api/blog/[slug]/route.ts +3 -4
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/api/revalidate/route.ts +1 -4
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/blog/[slug]/page.tsx +8 -9
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/layout.tsx +2 -2
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/sitemap.md/route.ts +18 -29
- package/src/modules/features/cms/sanity/files/app/sitemap.xml/route.ts +51 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/env.ts +2 -4
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/queries.ts +0 -42
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/schemas/index.ts +1 -1
- package/src/modules/features/cms/sanity/files/lib/scripts/copy-sanity-mcp.ts +23 -0
- package/src/modules/features/cms/sanity/files/lib/scripts/generate-page.ts +297 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/utils/json-ld.tsx +1 -6
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/utils/metadata.ts +2 -2
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/utils/url.ts +4 -2
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/proxy.ts +11 -11
- package/src/template-hooks/use-device-perf.ts +27 -17
- package/src/templates/next-default/.env.example +3 -3
- package/src/templates/next-default/.vscode/extensions.json +1 -5
- package/src/templates/next-default/.vscode/settings.json +1 -1
- package/src/templates/next-default/.zed/settings.json +47 -0
- package/src/templates/next-default/README.md +7 -6
- package/src/templates/next-default/_gitignore +1 -3
- package/src/templates/next-default/app/layout.tsx +21 -35
- package/src/templates/next-default/app/robots.ts +3 -4
- package/src/templates/next-default/app/sitemap.xml/route.ts +29 -29
- package/src/templates/next-default/biome.json +9 -2
- package/src/templates/next-default/components/ui/image/index.tsx +2 -1
- package/src/templates/next-default/components/ui/link/index.tsx +35 -35
- package/src/templates/next-default/lefthook.yml +25 -0
- package/src/templates/next-default/lib/README.md +8 -4
- package/src/templates/next-default/lib/hooks/use-media.ts +6 -3
- package/src/templates/next-default/lib/scripts/dev.ts +32 -0
- package/src/templates/next-default/lib/styles/README.md +13 -0
- package/src/templates/next-default/lib/styles/fonts.ts +20 -0
- package/src/templates/next-default/lib/styles/global.css +15 -196
- package/src/templates/next-default/lib/styles/index.css +3 -0
- package/src/templates/next-default/lib/styles/tokens.css +182 -0
- package/src/templates/next-default/lib/utils/README.md +40 -0
- package/src/templates/next-default/lib/utils/easings.ts +240 -0
- package/src/templates/next-default/lib/utils/fetch.ts +84 -0
- package/src/templates/next-default/lib/utils/global-css.d.ts +1 -0
- package/src/templates/next-default/lib/utils/json-ld.tsx +70 -68
- package/src/templates/next-default/lib/utils/math.ts +236 -0
- package/src/templates/next-default/lib/utils/metadata.ts +26 -27
- package/src/templates/next-default/lib/utils/strings.ts +246 -0
- package/src/templates/next-default/lib/utils/types.d.ts +15 -0
- package/src/templates/next-default/lib/utils/url.ts +8 -5
- package/src/templates/next-default/lib/utils/viewport.ts +199 -0
- package/src/templates/next-default/package.json +12 -7
- package/src/templates/next-default/svg.d.ts +1 -0
- package/src/templates/next-experiments/.env.example +3 -3
- package/src/templates/next-experiments/.knip.json +3 -0
- package/src/templates/next-experiments/.vscode/extensions.json +1 -5
- package/src/templates/next-experiments/.vscode/settings.json +1 -1
- package/src/templates/next-experiments/.zed/settings.json +47 -0
- package/src/templates/next-experiments/README.md +7 -6
- package/src/templates/next-experiments/_gitignore +1 -3
- package/src/templates/next-experiments/app/layout.tsx +21 -35
- package/src/templates/next-experiments/app/robots.ts +5 -2
- package/src/templates/next-experiments/app/sitemap.xml/route.ts +51 -0
- package/src/templates/next-experiments/biome.json +4 -2
- package/src/templates/next-experiments/components/layout/navigation-menu.tsx +1 -1
- package/src/templates/next-experiments/components/layout/wrapper/index.tsx +6 -6
- package/src/templates/next-experiments/components/ui/image/index.tsx +33 -33
- package/src/templates/next-experiments/lib/README.md +8 -4
- package/src/templates/next-experiments/lib/hooks/use-media.ts +6 -3
- package/src/templates/next-experiments/lib/scripts/dev.ts +32 -0
- package/src/templates/next-experiments/lib/styles/README.md +13 -0
- package/src/templates/next-experiments/lib/styles/fonts.ts +20 -0
- package/src/templates/next-experiments/lib/styles/global.css +16 -196
- package/src/templates/next-experiments/lib/styles/index.css +3 -0
- package/src/templates/next-experiments/lib/styles/tokens.css +182 -0
- package/src/templates/next-experiments/lib/utils/README.md +40 -0
- package/src/templates/next-experiments/lib/utils/easings.ts +240 -0
- package/src/templates/next-experiments/lib/utils/fetch.ts +84 -0
- package/src/templates/next-experiments/lib/utils/global-css.d.ts +1 -0
- package/src/templates/next-experiments/lib/utils/json-ld.tsx +70 -68
- package/src/templates/next-experiments/lib/utils/math.ts +236 -0
- package/src/templates/next-experiments/lib/utils/metadata.ts +26 -27
- package/src/templates/next-experiments/lib/utils/strings.ts +246 -0
- package/src/templates/next-experiments/lib/utils/types.d.ts +15 -0
- package/src/templates/next-experiments/lib/utils/url.ts +8 -5
- package/src/templates/next-experiments/lib/utils/viewport.ts +199 -0
- package/src/templates/next-experiments/package.json +6 -6
- package/src/templates/next-experiments/svg.d.ts +1 -0
- package/src/templates/next-pagebuilder/.vscode/extensions.json +16 -0
- package/src/templates/next-pagebuilder/.vscode/settings.json +105 -0
- package/src/templates/next-pagebuilder/.zed/settings.json +47 -0
- package/src/templates/next-pagebuilder/_gitignore +1 -3
- package/src/templates/next-pagebuilder/app/(content)/[[...slug]]/page.tsx +1 -1
- package/src/templates/next-pagebuilder/app/(content)/layout.tsx +0 -1
- package/src/templates/next-pagebuilder/app/robots.ts +3 -4
- package/src/templates/next-pagebuilder/biome.json +17 -0
- package/src/templates/next-pagebuilder/components/layout/footer/index.tsx +4 -5
- package/src/templates/next-pagebuilder/components/layout/header/index.tsx +1 -1
- package/src/templates/next-pagebuilder/components/page-builder/components/article-content/index.tsx +4 -9
- package/src/templates/next-pagebuilder/components/page-builder/components/article-content/related-post-item.tsx +4 -4
- package/src/templates/next-pagebuilder/components/page-builder/components/content-collection/content-card.tsx +3 -1
- package/src/templates/next-pagebuilder/components/page-builder/components/content-collection/index.tsx +12 -5
- package/src/templates/next-pagebuilder/components/page-builder/components/content-collection/types.ts +3 -1
- package/src/templates/next-pagebuilder/components/page-builder/renderer.tsx +6 -2
- package/src/templates/next-pagebuilder/components/page-builder/types.ts +9 -7
- package/src/templates/next-pagebuilder/components/page-document/index.tsx +12 -2
- package/src/templates/next-pagebuilder/lefthook.yml +25 -0
- package/src/templates/next-pagebuilder/lib/integrations/sanity/sanity.types.ts +208 -0
- package/src/templates/next-pagebuilder/lib/styles/global.css +0 -1
- package/src/templates/next-pagebuilder/next.config.ts +0 -2
- package/src/templates/next-pagebuilder/package.json +13 -25
- package/src/templates/next-pagebuilder/postcss.config.mjs +27 -1
- package/src/templates/next-pagebuilder/svg.d.ts +1 -0
- package/src/templates/next-webgl/.env.example +3 -3
- package/src/templates/next-webgl/.vscode/extensions.json +1 -5
- package/src/templates/next-webgl/.vscode/settings.json +1 -1
- package/src/templates/next-webgl/.zed/settings.json +47 -0
- package/src/templates/next-webgl/README.md +7 -6
- package/src/templates/next-webgl/_gitignore +1 -3
- package/src/templates/next-webgl/app/layout.tsx +21 -35
- package/src/templates/next-webgl/app/robots.ts +3 -4
- package/src/templates/next-webgl/app/sitemap.xml/route.ts +29 -29
- package/src/templates/next-webgl/biome.json +9 -2
- package/src/templates/next-webgl/components/ui/image/index.tsx +2 -1
- package/src/templates/next-webgl/components/webgl/components/scene/index.tsx +0 -2
- package/src/templates/next-webgl/lefthook.yml +25 -0
- package/src/templates/next-webgl/lib/README.md +8 -4
- package/src/templates/next-webgl/lib/hooks/use-media.ts +6 -3
- package/src/templates/next-webgl/lib/scripts/dev.ts +32 -0
- package/src/templates/next-webgl/lib/styles/README.md +13 -0
- package/src/templates/next-webgl/lib/styles/fonts.ts +20 -0
- package/src/templates/next-webgl/lib/styles/global.css +16 -196
- package/src/templates/next-webgl/lib/styles/index.css +3 -0
- package/src/templates/next-webgl/lib/styles/tokens.css +182 -0
- package/src/templates/next-webgl/lib/utils/README.md +40 -0
- package/src/templates/next-webgl/lib/utils/easings.ts +240 -0
- package/src/templates/next-webgl/lib/utils/fetch.ts +84 -0
- package/src/templates/next-webgl/lib/utils/global-css.d.ts +1 -0
- package/src/templates/next-webgl/lib/utils/json-ld.tsx +70 -68
- package/src/templates/next-webgl/lib/utils/math.ts +236 -0
- package/src/templates/next-webgl/lib/utils/metadata.ts +26 -27
- package/src/templates/next-webgl/lib/utils/strings.ts +246 -0
- package/src/templates/next-webgl/lib/utils/types.d.ts +15 -0
- package/src/templates/next-webgl/lib/utils/url.ts +8 -5
- package/src/templates/next-webgl/lib/utils/viewport.ts +199 -0
- package/src/templates/next-webgl/package.json +13 -8
- package/src/templates/next-webgl/svg.d.ts +1 -0
- package/src/templates/next-webgl/tsconfig.tsbuildinfo +1 -1
- package/dist/configs/animations.d.ts.map +0 -1
- package/dist/configs/animations.js.map +0 -1
- package/dist/configs/skills.d.ts +0 -27
- package/dist/configs/skills.d.ts.map +0 -1
- package/dist/configs/skills.js +0 -18
- package/dist/configs/skills.js.map +0 -1
- package/dist/configs/skills.json +0 -26
- package/dist/helpers/add/hooks-config.d.ts +0 -22
- package/dist/helpers/add/hooks-config.d.ts.map +0 -1
- package/dist/helpers/add/hooks-config.js +0 -31
- package/dist/helpers/add/hooks-config.js.map +0 -1
- package/dist/helpers/add/index.d.ts.map +0 -1
- package/dist/helpers/add/index.js.map +0 -1
- package/dist/helpers/create/copy-template.d.ts +0 -11
- package/dist/helpers/create/copy-template.d.ts.map +0 -1
- package/dist/helpers/create/copy-template.js.map +0 -1
- package/dist/helpers/create/index.d.ts +0 -24
- package/dist/helpers/create/index.d.ts.map +0 -1
- package/dist/helpers/create/index.js +0 -99
- package/dist/helpers/create/index.js.map +0 -1
- package/dist/helpers/create/init-git.d.ts.map +0 -1
- package/dist/helpers/create/init-git.js.map +0 -1
- package/dist/helpers/create/install.d.ts.map +0 -1
- package/dist/helpers/create/install.js.map +0 -1
- package/dist/helpers/create/rename-files.d.ts.map +0 -1
- package/dist/helpers/create/rename-files.js.map +0 -1
- package/dist/helpers/create/setup-agent.d.ts.map +0 -1
- package/dist/helpers/create/setup-agent.js +0 -91
- package/dist/helpers/create/setup-agent.js.map +0 -1
- package/dist/helpers/create/setup-sanity.d.ts.map +0 -1
- package/dist/helpers/create/setup-sanity.js.map +0 -1
- package/dist/helpers/create/update-package.d.ts +0 -20
- package/dist/helpers/create/update-package.d.ts.map +0 -1
- package/dist/helpers/create/update-package.js +0 -97
- package/dist/helpers/create/update-package.js.map +0 -1
- package/dist/helpers/integrate/index.d.ts.map +0 -1
- package/dist/helpers/integrate/index.js.map +0 -1
- package/dist/helpers/integrate/merge-config.d.ts +0 -21
- package/dist/helpers/integrate/merge-config.d.ts.map +0 -1
- package/dist/helpers/integrate/merge-config.js +0 -42
- package/dist/helpers/integrate/merge-config.js.map +0 -1
- package/dist/helpers/integrate/merge-orchestrator.d.ts +0 -10
- package/dist/helpers/integrate/merge-orchestrator.d.ts.map +0 -1
- package/dist/helpers/integrate/merge-orchestrator.js.map +0 -1
- package/dist/helpers/integrate/sanity/config.d.ts.map +0 -1
- package/dist/helpers/integrate/sanity/config.js.map +0 -1
- package/dist/helpers/integrate/sanity/mergers/check-integration-merger.d.ts.map +0 -1
- package/dist/helpers/integrate/sanity/mergers/check-integration-merger.js.map +0 -1
- package/dist/helpers/integrate/sanity/mergers/layout-merger.d.ts.map +0 -1
- package/dist/helpers/integrate/sanity/mergers/layout-merger.js.map +0 -1
- package/dist/helpers/integrate/sanity/mergers/sitemap-merger.d.ts +0 -11
- package/dist/helpers/integrate/sanity/mergers/sitemap-merger.d.ts.map +0 -1
- package/dist/helpers/integrate/sanity/mergers/sitemap-merger.js +0 -133
- package/dist/helpers/integrate/sanity/mergers/sitemap-merger.js.map +0 -1
- package/dist/helpers/skills/index.d.ts.map +0 -1
- package/dist/helpers/skills/index.js.map +0 -1
- package/dist/utils/detect-project.d.ts.map +0 -1
- package/dist/utils/detect-project.js.map +0 -1
- package/dist/utils/format-results.d.ts.map +0 -1
- package/dist/utils/format-results.js.map +0 -1
- package/src/helpers/integrate/sanity/files/lib/integrations/sanity/WEBHOOK-SETUP.md +0 -74
- package/src/helpers/integrate/sanity/files/lib/integrations/sanity/sitemap.ts +0 -90
- package/src/template-hooks/config.js +0 -32
- package/src/templates/next-default/css.d.ts +0 -1
- package/src/templates/next-default/lib/utils/portable-text-to-markdown.ts +0 -83
- package/src/templates/next-default/tsconfig.tsbuildinfo +0 -1
- package/src/templates/next-experiments/css.d.ts +0 -1
- package/src/templates/next-experiments/lib/utils/portable-text-to-markdown.ts +0 -83
- package/src/templates/next-pagebuilder/app/api/[[...slug]]/route.ts +0 -100
- package/src/templates/next-pagebuilder/app/api/draft-mode/disable/route.ts +0 -7
- package/src/templates/next-pagebuilder/app/api/draft-mode/enable/route.ts +0 -20
- package/src/templates/next-pagebuilder/app/api/revalidate/route.ts +0 -121
- package/src/templates/next-pagebuilder/app/sitemap.md/route.ts +0 -124
- package/src/templates/next-pagebuilder/app/studio/[[...tool]]/page.tsx +0 -8
- package/src/templates/next-pagebuilder/components/sanity/draft-mode-toggle.tsx +0 -27
- package/src/templates/next-pagebuilder/components/sanity/rich-text.tsx +0 -87
- package/src/templates/next-pagebuilder/components/sanity/visual-editing.tsx +0 -28
- package/src/templates/next-pagebuilder/components/ui/sanity-image/index.tsx +0 -41
- package/src/templates/next-pagebuilder/lib/integrations/check-integration.ts +0 -5
- package/src/templates/next-pagebuilder/lib/integrations/sanity/client.ts +0 -27
- package/src/templates/next-pagebuilder/lib/integrations/sanity/components/disable-draft-mode.tsx +0 -23
- package/src/templates/next-pagebuilder/lib/integrations/sanity/components/page-builder-input.tsx +0 -36
- package/src/templates/next-pagebuilder/lib/integrations/sanity/components/page-category-input.tsx +0 -50
- package/src/templates/next-pagebuilder/lib/integrations/sanity/components/rich-text.tsx +0 -84
- package/src/templates/next-pagebuilder/lib/integrations/sanity/confirm-publish-action.ts +0 -40
- package/src/templates/next-pagebuilder/lib/integrations/sanity/constants.ts +0 -1
- package/src/templates/next-pagebuilder/lib/integrations/sanity/env.ts +0 -34
- package/src/templates/next-pagebuilder/lib/integrations/sanity/fetchers/layout.ts +0 -34
- package/src/templates/next-pagebuilder/lib/integrations/sanity/icons.ts +0 -58
- package/src/templates/next-pagebuilder/lib/integrations/sanity/live/index.tsx +0 -88
- package/src/templates/next-pagebuilder/lib/integrations/sanity/markdown-proxy.config.ts +0 -50
- package/src/templates/next-pagebuilder/lib/integrations/sanity/page-builder-config.ts +0 -132
- package/src/templates/next-pagebuilder/lib/integrations/sanity/page-category.ts +0 -28
- package/src/templates/next-pagebuilder/lib/integrations/sanity/presentation.ts +0 -118
- package/src/templates/next-pagebuilder/lib/integrations/sanity/queries.ts +0 -394
- package/src/templates/next-pagebuilder/lib/integrations/sanity/sanity.cli.ts +0 -29
- package/src/templates/next-pagebuilder/lib/integrations/sanity/sanity.config.ts +0 -116
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/components/index.ts +0 -4
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/components/reusable/blog-content.ts +0 -89
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/components/reusable/description.ts +0 -29
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/components/reusable/hero.ts +0 -28
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/components/singleton/content-collection.ts +0 -45
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/content/author.ts +0 -70
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/content/blog-category.ts +0 -55
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/index.ts +0 -96
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/layout/company-data.ts +0 -62
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/layout/footer.ts +0 -79
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/layout/navbar.ts +0 -74
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/shared/link.ts +0 -125
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/shared/logo-field.ts +0 -9
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/shared/metadata.ts +0 -68
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/shared/nav-objects.ts +0 -192
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/shared/page-builder.ts +0 -39
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/shared/page-folder.ts +0 -124
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/shared/page.ts +0 -232
- package/src/templates/next-pagebuilder/lib/integrations/sanity/schemas/shared/richText.ts +0 -63
- package/src/templates/next-pagebuilder/lib/integrations/sanity/singletons.ts +0 -44
- package/src/templates/next-pagebuilder/lib/integrations/sanity/structure.ts +0 -453
- package/src/templates/next-pagebuilder/lib/integrations/sanity/utils/image.ts +0 -8
- package/src/templates/next-pagebuilder/lib/integrations/sanity/utils/link.ts +0 -137
- package/src/templates/next-pagebuilder/lib/integrations/sanity/utils/page-builder-markdown.ts +0 -81
- package/src/templates/next-pagebuilder/lib/scripts/sanity-typegen.ts +0 -45
- package/src/templates/next-pagebuilder/lib/utils/json-ld.tsx +0 -213
- package/src/templates/next-pagebuilder/lib/utils/metadata.ts +0 -167
- package/src/templates/next-pagebuilder/lib/utils/sitemap.ts +0 -37
- package/src/templates/next-pagebuilder/proxy.ts +0 -81
- package/src/templates/next-webgl/css.d.ts +0 -1
- package/src/templates/next-webgl/lib/utils/portable-text-to-markdown.ts +0 -83
- package/dist/{helpers → infrastructure}/create/copy-template.js +0 -0
- package/dist/{helpers → infrastructure}/create/rename-files.d.ts +0 -0
- package/dist/{helpers → infrastructure}/create/rename-files.js +0 -0
- package/dist/{helpers → infrastructure}/create/setup-sanity.d.ts +0 -0
- package/dist/{helpers/integrate → modules/features/cms}/sanity/config.d.ts +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/api/draft-mode/disable/route.ts +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/api/draft-mode/enable/route.ts +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/studio/[[...tool]]/page.tsx +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/studio/layout.tsx +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/components/ui/sanity-image/index.tsx +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/README.md +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/check-integration.ts +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/MARKDOWN-PROXY.md +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/README.md +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/client.ts +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/components/disable-draft-mode.tsx +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/components/rich-text.tsx +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/confirm-publish-action.ts +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/live/index.tsx +1 -1
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/markdown-proxy.config.ts +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/sanity.cli.ts +0 -0
- package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/sanity.config.ts +1 -1
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/sanity.types.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/schema.json +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/schemas/article.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/schemas/example.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/schemas/link.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/schemas/metadata.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/schemas/navigation.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/schemas/richText.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/structure.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/utils/image.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/integrations/sanity/utils/link.ts +0 -0
- /package/src/{helpers/integrate → modules/features/cms}/sanity/files/lib/utils/portable-text-to-markdown.ts +0 -0
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import fs from "fs-extra";
|
|
2
|
+
/**
|
|
3
|
+
* Sanity-specific import to add
|
|
4
|
+
*/
|
|
5
|
+
const SANITY_IMPORT = `import { isSanityConfigured } from "@/lib/integrations/check-integration"`;
|
|
6
|
+
/**
|
|
7
|
+
* Sanity fetch logic to inject before return statement.
|
|
8
|
+
* Uses early return pattern and spread operator for cleaner code.
|
|
9
|
+
*/
|
|
10
|
+
const SANITY_FETCH_LOGIC = `
|
|
11
|
+
// Only fetch Sanity articles if Sanity is configured
|
|
12
|
+
if (isSanityConfigured()) {
|
|
13
|
+
try {
|
|
14
|
+
const sanityModule = await import("@/lib/integrations/sanity/client")
|
|
15
|
+
const sanityGroq = await import("next-sanity")
|
|
16
|
+
|
|
17
|
+
const client = sanityModule?.client
|
|
18
|
+
const groq = sanityGroq?.groq
|
|
19
|
+
|
|
20
|
+
// Skip if client is null (shouldn't happen since we check isSanityConfigured)
|
|
21
|
+
if (!(client && groq)) return baseRoutes
|
|
22
|
+
|
|
23
|
+
type SanityDocument = {
|
|
24
|
+
slug: { current: string }
|
|
25
|
+
_updatedAt: string
|
|
26
|
+
metadata?: { noIndex?: boolean }
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
const articles = (await client.fetch(
|
|
30
|
+
groq\`*[_type == "article" && defined(slug.current)] {
|
|
31
|
+
slug,
|
|
32
|
+
_updatedAt,
|
|
33
|
+
metadata
|
|
34
|
+
}\`
|
|
35
|
+
)) as SanityDocument[]
|
|
36
|
+
|
|
37
|
+
// Add articles to sitemap (exclude noIndex articles)
|
|
38
|
+
const articleEntries: MetadataRoute.Sitemap = articles
|
|
39
|
+
.filter((article: SanityDocument) => !article.metadata?.noIndex)
|
|
40
|
+
.map((article: SanityDocument) => ({
|
|
41
|
+
url: \`\${APP_BASE_URL}/blog/\${article.slug.current}\`,
|
|
42
|
+
lastModified: new Date(article._updatedAt),
|
|
43
|
+
changeFrequency: "weekly" as const,
|
|
44
|
+
priority: 0.7,
|
|
45
|
+
}))
|
|
46
|
+
|
|
47
|
+
return [...baseRoutes, ...articleEntries]
|
|
48
|
+
} catch (error) {
|
|
49
|
+
console.error("Error generating sitemap from Sanity:", error)
|
|
50
|
+
return baseRoutes
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
`;
|
|
55
|
+
/**
|
|
56
|
+
* Merge Sanity integration into template sitemap.
|
|
57
|
+
* Preserves all existing agnostic code (routes, baseRoutes structure)
|
|
58
|
+
* and injects Sanity-specific fetching logic.
|
|
59
|
+
*/
|
|
60
|
+
export async function mergeSitemap(templatePath) {
|
|
61
|
+
let content = await fs.readFile(templatePath, "utf-8");
|
|
62
|
+
// Skip if already has Sanity integration
|
|
63
|
+
if (content.includes("isSanityConfigured")) {
|
|
64
|
+
return { skipped: true, reason: "Already has Sanity integration" };
|
|
65
|
+
}
|
|
66
|
+
// 1. Add Sanity import after existing imports
|
|
67
|
+
const importMatches = [...content.matchAll(/^import .+$/gm)];
|
|
68
|
+
if (importMatches.length > 0) {
|
|
69
|
+
const lastImport = importMatches.at(-1);
|
|
70
|
+
if (lastImport && lastImport.index !== undefined) {
|
|
71
|
+
const insertPos = lastImport.index + lastImport[0].length;
|
|
72
|
+
content =
|
|
73
|
+
content.slice(0, insertPos) +
|
|
74
|
+
"\n" +
|
|
75
|
+
SANITY_IMPORT +
|
|
76
|
+
content.slice(insertPos);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
// 2. Add Sanity fetch logic before the final return statement
|
|
80
|
+
// Find the last "return baseRoutes" or "return [...baseRoutes" pattern
|
|
81
|
+
const returnMatch = content.match(/(\n)([ \t]*)(return\s+(?:baseRoutes|\[\.\.\.baseRoutes))/m);
|
|
82
|
+
if (returnMatch) {
|
|
83
|
+
const returnIndex = content.indexOf(returnMatch[0]);
|
|
84
|
+
content =
|
|
85
|
+
content.slice(0, returnIndex) +
|
|
86
|
+
SANITY_FETCH_LOGIC +
|
|
87
|
+
content.slice(returnIndex);
|
|
88
|
+
}
|
|
89
|
+
await fs.writeFile(templatePath, content);
|
|
90
|
+
return { success: true };
|
|
91
|
+
}
|
|
92
|
+
//# sourceMappingURL=sitemap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sitemap.js","sourceRoot":"","sources":["../../../../../../src/modules/features/cms/sanity/mergers/sitemap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,UAAU,CAAC;AAE1B;;GAEG;AACH,MAAM,aAAa,GAAG,2EAA2E,CAAC;AAElG;;;GAGG;AACH,MAAM,kBAAkB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA4C1B,CAAC;AAQF;;;;GAIG;AACH,MAAM,CAAC,KAAK,UAAU,YAAY,CAAC,YAAoB;IACtD,IAAI,OAAO,GAAG,MAAM,EAAE,CAAC,QAAQ,CAAC,YAAY,EAAE,OAAO,CAAC,CAAC;IAEvD,yCAAyC;IACzC,IAAI,OAAO,CAAC,QAAQ,CAAC,oBAAoB,CAAC,EAAE,CAAC;QAC5C,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,gCAAgC,EAAE,CAAC;IACpE,CAAC;IAED,8CAA8C;IAC9C,MAAM,aAAa,GAAG,CAAC,GAAG,OAAO,CAAC,QAAQ,CAAC,eAAe,CAAC,CAAC,CAAC;IAC7D,IAAI,aAAa,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC9B,MAAM,UAAU,GAAG,aAAa,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;QACxC,IAAI,UAAU,IAAI,UAAU,CAAC,KAAK,KAAK,SAAS,EAAE,CAAC;YAClD,MAAM,SAAS,GAAG,UAAU,CAAC,KAAK,GAAG,UAAU,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC;YAC1D,OAAO;gBACN,OAAO,CAAC,KAAK,CAAC,CAAC,EAAE,SAAS,CAAC;oBAC3B,IAAI;oBACJ,aAAa;oBACb,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;QAC3B,CAAC;IACF,CAAC;IAED,8DAA8D;IAC9D,uEAAuE;IACvE,MAAM,WAAW,GAAG,OAAO,CAAC,KAAK,CAChC,2DAA2D,CAC3D,CAAC;IACF,IAAI,WAAW,EAAE,CAAC;QACjB,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC;QACpD,OAAO;YACN,OAAO,CAAC,KAAK,CAAC,CAAC,EAAE,WAAW,CAAC;gBAC7B,kBAAkB;gBAClB,OAAO,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC;IAC7B,CAAC;IAED,MAAM,EAAE,CAAC,SAAS,CAAC,YAAY,EAAE,OAAO,CAAC,CAAC;IAC1C,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;AAC1B,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sanity Page Builder integration configuration manifest.
|
|
3
|
+
* Single source of truth for dependencies, scripts, and the additive paths
|
|
4
|
+
* the feature ships into a generated project.
|
|
5
|
+
*/
|
|
6
|
+
export interface SanityPagebuilderIntegrationConfig {
|
|
7
|
+
name: string;
|
|
8
|
+
dependencies: Record<string, string>;
|
|
9
|
+
devDependencies: Record<string, string>;
|
|
10
|
+
scripts: Record<string, string>;
|
|
11
|
+
additivePaths: string[];
|
|
12
|
+
}
|
|
13
|
+
export declare const sanityPagebuilderConfig: SanityPagebuilderIntegrationConfig;
|
|
14
|
+
//# sourceMappingURL=config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/modules/features/cms/sanity-pagebuilder/config.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,MAAM,WAAW,kCAAkC;IAClD,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACrC,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACxC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC,aAAa,EAAE,MAAM,EAAE,CAAC;CACxB;AAED,eAAO,MAAM,uBAAuB,EAAE,kCA0CrC,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sanity Page Builder integration configuration manifest.
|
|
3
|
+
* Single source of truth for dependencies, scripts, and the additive paths
|
|
4
|
+
* the feature ships into a generated project.
|
|
5
|
+
*/
|
|
6
|
+
export const sanityPagebuilderConfig = {
|
|
7
|
+
name: "sanity-pagebuilder",
|
|
8
|
+
dependencies: {
|
|
9
|
+
"@phosphor-icons/react": "^2.1.10",
|
|
10
|
+
"@portabletext/types": "^4.0.2",
|
|
11
|
+
"@sanity/asset-utils": "^2.3.0",
|
|
12
|
+
"@sanity/image-url": "^2.0.3",
|
|
13
|
+
"@sanity/table": "^2.0.1",
|
|
14
|
+
"@sanity/vision": "^5.17.1",
|
|
15
|
+
"@sanity/visual-editing": "^5.3.1",
|
|
16
|
+
"next-sanity": "^12.1.4",
|
|
17
|
+
sanity: "^5.17.1",
|
|
18
|
+
"sanity-plugin-media": "^4.1.1",
|
|
19
|
+
},
|
|
20
|
+
devDependencies: {
|
|
21
|
+
"schema-dts": "^2.0.0",
|
|
22
|
+
},
|
|
23
|
+
scripts: {
|
|
24
|
+
"sanity:extract": "cd lib/integrations/sanity && bun --env-file ../../../.env.local sanity schema extract",
|
|
25
|
+
"sanity:typegen": "bun ./lib/scripts/sanity-typegen.ts",
|
|
26
|
+
predev: "bun run sanity:typegen",
|
|
27
|
+
prebuild: "bun run sanity:typegen",
|
|
28
|
+
},
|
|
29
|
+
additivePaths: [
|
|
30
|
+
"lib/integrations/sanity",
|
|
31
|
+
"lib/integrations/check-integration.ts",
|
|
32
|
+
"lib/utils/json-ld.tsx",
|
|
33
|
+
"lib/utils/metadata.ts",
|
|
34
|
+
"lib/utils/sitemap.ts",
|
|
35
|
+
"lib/scripts/sanity-typegen.ts",
|
|
36
|
+
"app/studio",
|
|
37
|
+
"app/api",
|
|
38
|
+
"app/sitemap.md",
|
|
39
|
+
"proxy.ts",
|
|
40
|
+
"components/sanity",
|
|
41
|
+
"components/ui/sanity-image",
|
|
42
|
+
],
|
|
43
|
+
};
|
|
44
|
+
//# sourceMappingURL=config.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../../../../src/modules/features/cms/sanity-pagebuilder/config.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAUH,MAAM,CAAC,MAAM,uBAAuB,GAAuC;IAC1E,IAAI,EAAE,oBAAoB;IAE1B,YAAY,EAAE;QACb,uBAAuB,EAAE,SAAS;QAClC,qBAAqB,EAAE,QAAQ;QAC/B,qBAAqB,EAAE,QAAQ;QAC/B,mBAAmB,EAAE,QAAQ;QAC7B,eAAe,EAAE,QAAQ;QACzB,gBAAgB,EAAE,SAAS;QAC3B,wBAAwB,EAAE,QAAQ;QAClC,aAAa,EAAE,SAAS;QACxB,MAAM,EAAE,SAAS;QACjB,qBAAqB,EAAE,QAAQ;KAC/B;IAED,eAAe,EAAE;QAChB,YAAY,EAAE,QAAQ;KACtB;IAED,OAAO,EAAE;QACR,gBAAgB,EACf,wFAAwF;QACzF,gBAAgB,EAAE,qCAAqC;QACvD,MAAM,EAAE,wBAAwB;QAChC,QAAQ,EAAE,wBAAwB;KAClC;IAED,aAAa,EAAE;QACd,yBAAyB;QACzB,uCAAuC;QACvC,uBAAuB;QACvB,uBAAuB;QACvB,sBAAsB;QACtB,+BAA+B;QAC/B,YAAY;QACZ,SAAS;QACT,gBAAgB;QAChB,UAAU;QACV,mBAAmB;QACnB,4BAA4B;KAC5B;CACD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/modules/features/cms/sanity-pagebuilder/index.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kCAAkC,CAAC;AAItE,eAAO,MAAM,wBAAwB,EAAE,aA2BtC,CAAC"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import path from "node:path";
|
|
2
|
+
import { CMS_FEATURE_MODULE_IDS, CREATE_LIFECYCLE_STEP_IDS, SANITY_PAGEBUILDER_FEATURE_MODULE_ID, } from "../../../../core/create/internal-ids.js";
|
|
3
|
+
import { SANITY_PAGEBUILDER_FILES_DIR } from "../../../../paths.js";
|
|
4
|
+
import { sanityPagebuilderConfig } from "./config.js";
|
|
5
|
+
export const sanityPagebuilderFeature = {
|
|
6
|
+
id: SANITY_PAGEBUILDER_FEATURE_MODULE_ID,
|
|
7
|
+
kind: "feature",
|
|
8
|
+
label: "Sanity (Page Builder)",
|
|
9
|
+
conflictsWith: [CMS_FEATURE_MODULE_IDS.sanity],
|
|
10
|
+
contribute(context) {
|
|
11
|
+
return {
|
|
12
|
+
packageJson: {
|
|
13
|
+
dependencies: sanityPagebuilderConfig.dependencies,
|
|
14
|
+
devDependencies: sanityPagebuilderConfig.devDependencies,
|
|
15
|
+
scripts: sanityPagebuilderConfig.scripts,
|
|
16
|
+
},
|
|
17
|
+
copyPaths: sanityPagebuilderConfig.additivePaths.map((relativePath) => ({
|
|
18
|
+
from: path.join(SANITY_PAGEBUILDER_FILES_DIR, relativePath),
|
|
19
|
+
to: withProjectPrefix(relativePath, context.pathPrefix),
|
|
20
|
+
overwrite: false,
|
|
21
|
+
})),
|
|
22
|
+
env: [
|
|
23
|
+
{ key: "NEXT_PUBLIC_SANITY_PROJECT_ID", required: true },
|
|
24
|
+
{ key: "NEXT_PUBLIC_SANITY_DATASET", required: true },
|
|
25
|
+
{ key: "SANITY_API_READ_TOKEN", required: true },
|
|
26
|
+
],
|
|
27
|
+
lifecycle: {
|
|
28
|
+
finalize: [{ id: CREATE_LIFECYCLE_STEP_IDS.sanitySetupProject }],
|
|
29
|
+
},
|
|
30
|
+
};
|
|
31
|
+
},
|
|
32
|
+
};
|
|
33
|
+
function withProjectPrefix(relativePath, prefix) {
|
|
34
|
+
if (!prefix)
|
|
35
|
+
return relativePath;
|
|
36
|
+
for (const start of ["app/", "lib/", "components/"]) {
|
|
37
|
+
if (relativePath.startsWith(start)) {
|
|
38
|
+
return `${prefix}${relativePath}`;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
if (relativePath === "proxy.ts" || relativePath === "proxy.js") {
|
|
42
|
+
return `${prefix}${relativePath}`;
|
|
43
|
+
}
|
|
44
|
+
return relativePath;
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/modules/features/cms/sanity-pagebuilder/index.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EACN,sBAAsB,EACtB,yBAAyB,EACzB,oCAAoC,GACpC,MAAM,yCAAyC,CAAC;AAEjD,OAAO,EAAE,4BAA4B,EAAE,MAAM,sBAAsB,CAAC;AACpE,OAAO,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC;AAEtD,MAAM,CAAC,MAAM,wBAAwB,GAAkB;IACtD,EAAE,EAAE,oCAAoC;IACxC,IAAI,EAAE,SAAS;IACf,KAAK,EAAE,uBAAuB;IAC9B,aAAa,EAAE,CAAC,sBAAsB,CAAC,MAAM,CAAC;IAC9C,UAAU,CAAC,OAAO;QACjB,OAAO;YACN,WAAW,EAAE;gBACZ,YAAY,EAAE,uBAAuB,CAAC,YAAY;gBAClD,eAAe,EAAE,uBAAuB,CAAC,eAAe;gBACxD,OAAO,EAAE,uBAAuB,CAAC,OAAO;aACxC;YACD,SAAS,EAAE,uBAAuB,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,YAAY,EAAE,EAAE,CAAC,CAAC;gBACvE,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC,4BAA4B,EAAE,YAAY,CAAC;gBAC3D,EAAE,EAAE,iBAAiB,CAAC,YAAY,EAAE,OAAO,CAAC,UAAU,CAAC;gBACvD,SAAS,EAAE,KAAK;aAChB,CAAC,CAAC;YACH,GAAG,EAAE;gBACJ,EAAE,GAAG,EAAE,+BAA+B,EAAE,QAAQ,EAAE,IAAI,EAAE;gBACxD,EAAE,GAAG,EAAE,4BAA4B,EAAE,QAAQ,EAAE,IAAI,EAAE;gBACrD,EAAE,GAAG,EAAE,uBAAuB,EAAE,QAAQ,EAAE,IAAI,EAAE;aAChD;YACD,SAAS,EAAE;gBACV,QAAQ,EAAE,CAAC,EAAE,EAAE,EAAE,yBAAyB,CAAC,kBAAkB,EAAE,CAAC;aAChE;SACD,CAAC;IACH,CAAC;CACD,CAAC;AAEF,SAAS,iBAAiB,CAAC,YAAoB,EAAE,MAAmB;IACnE,IAAI,CAAC,MAAM;QAAE,OAAO,YAAY,CAAC;IAEjC,KAAK,MAAM,KAAK,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,aAAa,CAAC,EAAE,CAAC;QACrD,IAAI,YAAY,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE,CAAC;YACpC,OAAO,GAAG,MAAM,GAAG,YAAY,EAAE,CAAC;QACnC,CAAC;IACF,CAAC;IAED,IAAI,YAAY,KAAK,UAAU,IAAI,YAAY,KAAK,UAAU,EAAE,CAAC;QAChE,OAAO,GAAG,MAAM,GAAG,YAAY,EAAE,CAAC;IACnC,CAAC;IAED,OAAO,YAAY,CAAC;AACrB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"factory.d.ts","sourceRoot":"","sources":["../../../../src/modules/features/hooks/factory.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,EAAS,KAAK,MAAM,EAAE,MAAM,0BAA0B,CAAC;AAG9D,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,MAAM,GAAG,aAAa,CAsB/D"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { HOOK_FEATURE_MODULE_IDS } from "../../../core/create/internal-ids.js";
|
|
2
|
+
import { HOOKS } from "../../../domain/hooks.js";
|
|
3
|
+
import { TEMPLATE_HOOKS_DIR } from "../../../paths.js";
|
|
4
|
+
export function createHookFeature(hookId) {
|
|
5
|
+
return {
|
|
6
|
+
id: HOOK_FEATURE_MODULE_IDS[hookId],
|
|
7
|
+
kind: "feature",
|
|
8
|
+
label: HOOKS[hookId].label,
|
|
9
|
+
contribute(context) {
|
|
10
|
+
const hook = HOOKS[hookId];
|
|
11
|
+
return {
|
|
12
|
+
packageJson: {
|
|
13
|
+
dependencies: hook.dependencies,
|
|
14
|
+
devDependencies: hook.devDependencies,
|
|
15
|
+
},
|
|
16
|
+
copyPaths: [
|
|
17
|
+
{
|
|
18
|
+
from: `${TEMPLATE_HOOKS_DIR}/${hook.file}`,
|
|
19
|
+
to: `${context.pathPrefix}hooks/${hook.file}`,
|
|
20
|
+
},
|
|
21
|
+
],
|
|
22
|
+
};
|
|
23
|
+
},
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=factory.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../../../../src/modules/features/hooks/factory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,sCAAsC,CAAC;AAE/E,OAAO,EAAE,KAAK,EAAe,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAEvD,MAAM,UAAU,iBAAiB,CAAC,MAAc;IAC/C,OAAO;QACN,EAAE,EAAE,uBAAuB,CAAC,MAAM,CAAC;QACnC,IAAI,EAAE,SAAS;QACf,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC,KAAK;QAC1B,UAAU,CAAC,OAAO;YACjB,MAAM,IAAI,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;YAE3B,OAAO;gBACN,WAAW,EAAE;oBACZ,YAAY,EAAE,IAAI,CAAC,YAAY;oBAC/B,eAAe,EAAE,IAAI,CAAC,eAAe;iBACrC;gBACD,SAAS,EAAE;oBACV;wBACC,IAAI,EAAE,GAAG,kBAAkB,IAAI,IAAI,CAAC,IAAI,EAAE;wBAC1C,EAAE,EAAE,GAAG,OAAO,CAAC,UAAU,SAAS,IAAI,CAAC,IAAI,EAAE;qBAC7C;iBACD;aACD,CAAC;QACH,CAAC;KACD,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/modules/features/hooks/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAInE,eAAO,MAAM,YAAY,EAAE,aAAa,EAEvC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/features/hooks/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAC;AACjD,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAEjD,MAAM,CAAC,MAAM,YAAY,GAAoB,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAC9E,iBAAiB,CAAC,MAA4B,CAAC,CAC/C,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/modules/presets/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAM/D,eAAO,MAAM,aAAa,EAAE,YAAY,EAKvC,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { nextDefaultPreset } from "./next-default.js";
|
|
2
|
+
import { nextExperimentsPreset } from "./next-experiments.js";
|
|
3
|
+
import { nextPagebuilderPreset } from "./next-pagebuilder.js";
|
|
4
|
+
import { nextWebglPreset } from "./next-webgl.js";
|
|
5
|
+
export const presetModules = [
|
|
6
|
+
nextDefaultPreset,
|
|
7
|
+
nextPagebuilderPreset,
|
|
8
|
+
nextWebglPreset,
|
|
9
|
+
nextExperimentsPreset,
|
|
10
|
+
];
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/modules/presets/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAElD,MAAM,CAAC,MAAM,aAAa,GAAmB;IAC5C,iBAAiB;IACjB,qBAAqB;IACrB,eAAe;IACf,qBAAqB;CACrB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-default.d.ts","sourceRoot":"","sources":["../../../src/modules/presets/next-default.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE/D,eAAO,MAAM,iBAAiB,EAAE,YAM/B,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { PRESET_MODULE_IDS } from "../../core/create/internal-ids.js";
|
|
2
|
+
export const nextDefaultPreset = {
|
|
3
|
+
id: PRESET_MODULE_IDS["next-default"],
|
|
4
|
+
kind: "preset",
|
|
5
|
+
label: "Default",
|
|
6
|
+
description: "Next.js starter preset",
|
|
7
|
+
template: "next-default",
|
|
8
|
+
};
|
|
9
|
+
//# sourceMappingURL=next-default.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-default.js","sourceRoot":"","sources":["../../../src/modules/presets/next-default.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAGtE,MAAM,CAAC,MAAM,iBAAiB,GAAiB;IAC9C,EAAE,EAAE,iBAAiB,CAAC,cAAc,CAAC;IACrC,IAAI,EAAE,QAAQ;IACd,KAAK,EAAE,SAAS;IAChB,WAAW,EAAE,wBAAwB;IACrC,QAAQ,EAAE,cAAc;CACxB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-experiments.d.ts","sourceRoot":"","sources":["../../../src/modules/presets/next-experiments.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE/D,eAAO,MAAM,qBAAqB,EAAE,YAMnC,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { PRESET_MODULE_IDS } from "../../core/create/internal-ids.js";
|
|
2
|
+
export const nextExperimentsPreset = {
|
|
3
|
+
id: PRESET_MODULE_IDS["next-experiments"],
|
|
4
|
+
kind: "preset",
|
|
5
|
+
label: "Experiments",
|
|
6
|
+
description: "Creative coding starter preset",
|
|
7
|
+
template: "next-experiments",
|
|
8
|
+
};
|
|
9
|
+
//# sourceMappingURL=next-experiments.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-experiments.js","sourceRoot":"","sources":["../../../src/modules/presets/next-experiments.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAGtE,MAAM,CAAC,MAAM,qBAAqB,GAAiB;IAClD,EAAE,EAAE,iBAAiB,CAAC,kBAAkB,CAAC;IACzC,IAAI,EAAE,QAAQ;IACd,KAAK,EAAE,aAAa;IACpB,WAAW,EAAE,gCAAgC;IAC7C,QAAQ,EAAE,kBAAkB;CAC5B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-pagebuilder.d.ts","sourceRoot":"","sources":["../../../src/modules/presets/next-pagebuilder.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE/D,eAAO,MAAM,qBAAqB,EAAE,YAOnC,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { PRESET_MODULE_IDS, SANITY_PAGEBUILDER_FEATURE_MODULE_ID, } from "../../core/create/internal-ids.js";
|
|
2
|
+
export const nextPagebuilderPreset = {
|
|
3
|
+
id: PRESET_MODULE_IDS["next-pagebuilder"],
|
|
4
|
+
kind: "preset",
|
|
5
|
+
label: "Page Builder",
|
|
6
|
+
description: "Next.js page builder preset with built-in Sanity support",
|
|
7
|
+
template: "next-pagebuilder",
|
|
8
|
+
defaultFeatures: [SANITY_PAGEBUILDER_FEATURE_MODULE_ID],
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=next-pagebuilder.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-pagebuilder.js","sourceRoot":"","sources":["../../../src/modules/presets/next-pagebuilder.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,iBAAiB,EACjB,oCAAoC,GACpC,MAAM,mCAAmC,CAAC;AAG3C,MAAM,CAAC,MAAM,qBAAqB,GAAiB;IAClD,EAAE,EAAE,iBAAiB,CAAC,kBAAkB,CAAC;IACzC,IAAI,EAAE,QAAQ;IACd,KAAK,EAAE,cAAc;IACrB,WAAW,EAAE,0DAA0D;IACvE,QAAQ,EAAE,kBAAkB;IAC5B,eAAe,EAAE,CAAC,oCAAoC,CAAC;CACvD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-webgl.d.ts","sourceRoot":"","sources":["../../../src/modules/presets/next-webgl.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAE/D,eAAO,MAAM,eAAe,EAAE,YAM7B,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { PRESET_MODULE_IDS } from "../../core/create/internal-ids.js";
|
|
2
|
+
export const nextWebglPreset = {
|
|
3
|
+
id: PRESET_MODULE_IDS["next-webgl"],
|
|
4
|
+
kind: "preset",
|
|
5
|
+
label: "WebGL/WebGPU",
|
|
6
|
+
description: "3D graphics starter preset",
|
|
7
|
+
template: "next-webgl",
|
|
8
|
+
};
|
|
9
|
+
//# sourceMappingURL=next-webgl.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next-webgl.js","sourceRoot":"","sources":["../../../src/modules/presets/next-webgl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,mCAAmC,CAAC;AAGtE,MAAM,CAAC,MAAM,eAAe,GAAiB;IAC5C,EAAE,EAAE,iBAAiB,CAAC,YAAY,CAAC;IACnC,IAAI,EAAE,QAAQ;IACd,KAAK,EAAE,cAAc;IACrB,WAAW,EAAE,4BAA4B;IACzC,QAAQ,EAAE,YAAY;CACtB,CAAC"}
|
package/dist/paths.d.ts
CHANGED
|
@@ -6,9 +6,15 @@ export declare const TEMPLATE_HOOKS_DIR: string;
|
|
|
6
6
|
export declare const PLUGINS_DIR: string;
|
|
7
7
|
/**
|
|
8
8
|
* Directory containing the Sanity integration source files.
|
|
9
|
-
* Always resolves to `src/
|
|
9
|
+
* Always resolves to `src/modules/features/cms/sanity/files/` relative to the
|
|
10
10
|
* project root -- these are static assets that live under `src/` and are NOT
|
|
11
11
|
* compiled into `dist/`, so the path is stable across dev and prod.
|
|
12
12
|
*/
|
|
13
13
|
export declare const SANITY_FILES_DIR: string;
|
|
14
|
+
/**
|
|
15
|
+
* Directory containing the Sanity Page Builder integration source files.
|
|
16
|
+
* Always resolves to `src/modules/features/cms/sanity-pagebuilder/files/`
|
|
17
|
+
* relative to the project root.
|
|
18
|
+
*/
|
|
19
|
+
export declare const SANITY_PAGEBUILDER_FILES_DIR: string;
|
|
14
20
|
//# sourceMappingURL=paths.d.ts.map
|
package/dist/paths.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paths.d.ts","sourceRoot":"","sources":["../src/paths.ts"],"names":[],"mappings":"AAaA,6DAA6D;AAC7D,eAAO,MAAM,aAAa,EAAE,MAI3B,CAAC;AAEF,0DAA0D;AAC1D,eAAO,MAAM,kBAAkB,EAAE,MAIhC,CAAC;AAEF,2DAA2D;AAC3D,eAAO,MAAM,WAAW,EAAE,MAA2C,CAAC;AAEtE;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,EAAE,
|
|
1
|
+
{"version":3,"file":"paths.d.ts","sourceRoot":"","sources":["../src/paths.ts"],"names":[],"mappings":"AAaA,6DAA6D;AAC7D,eAAO,MAAM,aAAa,EAAE,MAI3B,CAAC;AAEF,0DAA0D;AAC1D,eAAO,MAAM,kBAAkB,EAAE,MAIhC,CAAC;AAEF,2DAA2D;AAC3D,eAAO,MAAM,WAAW,EAAE,MAA2C,CAAC;AAEtE;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,EAAE,MAQ9B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,4BAA4B,EAAE,MAQ1C,CAAC"}
|
package/dist/paths.js
CHANGED
|
@@ -16,9 +16,15 @@ export const TEMPLATE_HOOKS_DIR = path.join(PROJECT_ROOT, "src", "template-hooks
|
|
|
16
16
|
export const PLUGINS_DIR = path.join(PROJECT_ROOT, "plugins");
|
|
17
17
|
/**
|
|
18
18
|
* Directory containing the Sanity integration source files.
|
|
19
|
-
* Always resolves to `src/
|
|
19
|
+
* Always resolves to `src/modules/features/cms/sanity/files/` relative to the
|
|
20
20
|
* project root -- these are static assets that live under `src/` and are NOT
|
|
21
21
|
* compiled into `dist/`, so the path is stable across dev and prod.
|
|
22
22
|
*/
|
|
23
|
-
export const SANITY_FILES_DIR = path.join(PROJECT_ROOT, "src", "
|
|
23
|
+
export const SANITY_FILES_DIR = path.join(PROJECT_ROOT, "src", "modules", "features", "cms", "sanity", "files");
|
|
24
|
+
/**
|
|
25
|
+
* Directory containing the Sanity Page Builder integration source files.
|
|
26
|
+
* Always resolves to `src/modules/features/cms/sanity-pagebuilder/files/`
|
|
27
|
+
* relative to the project root.
|
|
28
|
+
*/
|
|
29
|
+
export const SANITY_PAGEBUILDER_FILES_DIR = path.join(PROJECT_ROOT, "src", "modules", "features", "cms", "sanity-pagebuilder", "files");
|
|
24
30
|
//# sourceMappingURL=paths.js.map
|
package/dist/paths.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paths.js","sourceRoot":"","sources":["../src/paths.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,UAAU,GAAW,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC1D,MAAM,SAAS,GAAW,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;AAEnD;;;;GAIG;AACH,MAAM,YAAY,GAAW,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC;AAE3D,6DAA6D;AAC7D,MAAM,CAAC,MAAM,aAAa,GAAW,IAAI,CAAC,IAAI,CAC7C,YAAY,EACZ,KAAK,EACL,WAAW,CACX,CAAC;AAEF,0DAA0D;AAC1D,MAAM,CAAC,MAAM,kBAAkB,GAAW,IAAI,CAAC,IAAI,CAClD,YAAY,EACZ,KAAK,EACL,gBAAgB,CAChB,CAAC;AAEF,2DAA2D;AAC3D,MAAM,CAAC,MAAM,WAAW,GAAW,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE,SAAS,CAAC,CAAC;AAEtE;;;;;GAKG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAW,IAAI,CAAC,IAAI,CAChD,YAAY,EACZ,KAAK,EACL,SAAS,EACT,
|
|
1
|
+
{"version":3,"file":"paths.js","sourceRoot":"","sources":["../src/paths.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,UAAU,GAAW,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC1D,MAAM,SAAS,GAAW,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;AAEnD;;;;GAIG;AACH,MAAM,YAAY,GAAW,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC;AAE3D,6DAA6D;AAC7D,MAAM,CAAC,MAAM,aAAa,GAAW,IAAI,CAAC,IAAI,CAC7C,YAAY,EACZ,KAAK,EACL,WAAW,CACX,CAAC;AAEF,0DAA0D;AAC1D,MAAM,CAAC,MAAM,kBAAkB,GAAW,IAAI,CAAC,IAAI,CAClD,YAAY,EACZ,KAAK,EACL,gBAAgB,CAChB,CAAC;AAEF,2DAA2D;AAC3D,MAAM,CAAC,MAAM,WAAW,GAAW,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE,SAAS,CAAC,CAAC;AAEtE;;;;;GAKG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAW,IAAI,CAAC,IAAI,CAChD,YAAY,EACZ,KAAK,EACL,SAAS,EACT,UAAU,EACV,KAAK,EACL,QAAQ,EACR,OAAO,CACP,CAAC;AAEF;;;;GAIG;AACH,MAAM,CAAC,MAAM,4BAA4B,GAAW,IAAI,CAAC,IAAI,CAC5D,YAAY,EACZ,KAAK,EACL,SAAS,EACT,UAAU,EACV,KAAK,EACL,oBAAoB,EACpB,OAAO,CACP,CAAC"}
|
package/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { existsSync } from "node:fs";
|
|
4
|
-
import { fileURLToPath, pathToFileURL } from "node:url";
|
|
5
4
|
import { dirname, join } from "node:path";
|
|
5
|
+
import { fileURLToPath } from "node:url";
|
|
6
6
|
|
|
7
7
|
const __filename = fileURLToPath(import.meta.url);
|
|
8
8
|
const __dirname = dirname(__filename);
|
|
@@ -10,7 +10,7 @@ const __dirname = dirname(__filename);
|
|
|
10
10
|
const distEntry = join(__dirname, "dist", "index.js");
|
|
11
11
|
|
|
12
12
|
if (existsSync(distEntry)) {
|
|
13
|
-
await import(
|
|
13
|
+
await import(distEntry);
|
|
14
14
|
} else {
|
|
15
15
|
// Dev mode: run TypeScript source via local tsx
|
|
16
16
|
const { execFileSync } = await import("node:child_process");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bsmnt",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.2",
|
|
4
4
|
"packageManager": "bun@1.2.20",
|
|
5
5
|
"description": "CLI to scaffold basement projects and add integrations",
|
|
6
6
|
"type": "module",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"!src/templates/*/.next",
|
|
21
21
|
"!src/templates/*/bun.lock",
|
|
22
22
|
"src/template-hooks",
|
|
23
|
-
"src/
|
|
23
|
+
"src/modules/features/cms/sanity/files",
|
|
24
24
|
"plugins"
|
|
25
25
|
],
|
|
26
26
|
"scripts": {
|
|
@@ -28,10 +28,15 @@
|
|
|
28
28
|
"check": "tsc --noEmit",
|
|
29
29
|
"dev": "tsx src/index.ts",
|
|
30
30
|
"lint": "biome check .",
|
|
31
|
-
"lint:fix": "biome check --write .",
|
|
31
|
+
"lint:fix": "biome check --write --unsafe .",
|
|
32
|
+
"format": "biome format --write .",
|
|
33
|
+
"knip": "bunx knip",
|
|
34
|
+
"knip:fix": "bunx knip --fix",
|
|
35
|
+
"update:packages": "cross-env NPM_CHECK_INSTALLER=bun bunx npm-check -u",
|
|
32
36
|
"changeset": "changeset",
|
|
33
37
|
"version-packages": "changeset version",
|
|
34
38
|
"release": "changeset publish",
|
|
39
|
+
"prepare": "lefthook install",
|
|
35
40
|
"prepublishOnly": "rm -rf dist && bun run build",
|
|
36
41
|
"default": "turbo run dev --filter=bsmnt-next-starter",
|
|
37
42
|
"webgpu": "turbo run dev --filter=bsmnt-webgpu-starter",
|
|
@@ -70,12 +75,14 @@
|
|
|
70
75
|
"sanity": "^5.11.0"
|
|
71
76
|
},
|
|
72
77
|
"devDependencies": {
|
|
73
|
-
"@biomejs/biome": "2.
|
|
78
|
+
"@biomejs/biome": "^2.4.14",
|
|
74
79
|
"@changesets/changelog-github": "^0.5.2",
|
|
75
80
|
"@changesets/cli": "^2.29.8",
|
|
76
81
|
"@types/fs-extra": "^11.0.4",
|
|
77
82
|
"@types/node": "^25.2.3",
|
|
78
83
|
"@types/prompts": "^2.4.9",
|
|
84
|
+
"cross-env": "^10.1.0",
|
|
85
|
+
"lefthook": "^1.13.0",
|
|
79
86
|
"tsx": "^4.19.0",
|
|
80
87
|
"turbo": "^2.5.0",
|
|
81
88
|
"typescript": "^5.8.0"
|
package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/api/blog/[slug]/route.ts
RENAMED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { NextResponse } from "next/server";
|
|
2
|
-
import { portableTextToMarkdown } from "@/lib/utils/portable-text-to-markdown";
|
|
3
2
|
import { isSanityConfigured } from "@/lib/integrations/check-integration";
|
|
4
|
-
import { getBaseUrl } from "@/lib/utils/url";
|
|
5
|
-
import { ARTICLE_QUERY } from "@/lib/integrations/sanity/queries";
|
|
6
3
|
import { SanityFetch } from "@/lib/integrations/sanity/live";
|
|
4
|
+
import { ARTICLE_QUERY } from "@/lib/integrations/sanity/queries";
|
|
7
5
|
import type { Article } from "@/lib/integrations/sanity/sanity.types";
|
|
6
|
+
import { portableTextToMarkdown } from "@/lib/utils/portable-text-to-markdown";
|
|
8
7
|
|
|
9
8
|
export async function GET(
|
|
10
9
|
_request: Request,
|
|
@@ -17,7 +16,7 @@ export async function GET(
|
|
|
17
16
|
}
|
|
18
17
|
|
|
19
18
|
const slug = rawSlug.slice(0, -3);
|
|
20
|
-
const baseUrl =
|
|
19
|
+
const baseUrl = process.env.NEXT_PUBLIC_BASE_URL || "http://localhost:3000";
|
|
21
20
|
|
|
22
21
|
if (!isSanityConfigured()) {
|
|
23
22
|
return new NextResponse("# 404 Not Found\n\nCMS not configured.", {
|
package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/api/revalidate/route.ts
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { revalidateTag } from "next/cache";
|
|
2
2
|
import { type NextRequest, NextResponse } from "next/server";
|
|
3
3
|
import { parseBody } from "next-sanity/webhook";
|
|
4
4
|
|
|
@@ -25,9 +25,6 @@ export async function POST(request: NextRequest) {
|
|
|
25
25
|
revalidateTag(`${body._type}:${body.slug.current}`, "max");
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
revalidatePath("/sitemap.xml");
|
|
29
|
-
revalidatePath("/sitemap.md");
|
|
30
|
-
|
|
31
28
|
return NextResponse.json({
|
|
32
29
|
status: 200,
|
|
33
30
|
revalidated: true,
|
package/src/{helpers/integrate → modules/features/cms}/sanity/files/app/blog/[slug]/page.tsx
RENAMED
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
import { notFound } from "next/navigation";
|
|
2
|
-
import { sanityFetch } from "@/lib/integrations/sanity/live";
|
|
3
2
|
import { client } from "@/lib/integrations/sanity/client";
|
|
3
|
+
import { RichText } from "@/lib/integrations/sanity/components/rich-text";
|
|
4
|
+
import { sanityFetch } from "@/lib/integrations/sanity/live";
|
|
4
5
|
import {
|
|
5
|
-
ARTICLE_QUERY,
|
|
6
6
|
ALL_ARTICLES_QUERY,
|
|
7
|
+
ARTICLE_QUERY,
|
|
7
8
|
} from "@/lib/integrations/sanity/queries";
|
|
8
|
-
import { RichText } from "@/lib/integrations/sanity/components/rich-text";
|
|
9
9
|
|
|
10
10
|
export async function generateStaticParams() {
|
|
11
11
|
if (!client) return [];
|
|
12
|
-
const articles = await client.fetch
|
|
13
|
-
Array<{ slug?: { current?: string } }>
|
|
14
|
-
>(ALL_ARTICLES_QUERY);
|
|
12
|
+
const articles = await client.fetch(ALL_ARTICLES_QUERY);
|
|
15
13
|
|
|
16
|
-
return (articles ?? [])
|
|
17
|
-
|
|
18
|
-
|
|
14
|
+
return (articles ?? []).flatMap((article) => {
|
|
15
|
+
const slug = article.slug?.current;
|
|
16
|
+
return slug ? [{ slug }] : [];
|
|
17
|
+
});
|
|
19
18
|
}
|
|
20
19
|
|
|
21
20
|
type Props = {
|