@conloca/astro-cms 0.1.14 → 0.1.16
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 +65 -5
- package/dist/collections-Bd7EME4b.mjs +129 -0
- package/dist/collections-Bd7EME4b.mjs.map +1 -0
- package/dist/collections.d.mts +3 -3
- package/dist/collections.d.mts.map +1 -1
- package/dist/collections.mjs +2 -56
- package/dist/components.d.mts +6 -31
- package/dist/components.d.mts.map +1 -1
- package/dist/components.mjs +100 -45
- package/dist/components.mjs.map +1 -1
- package/dist/hydration.d.mts +2 -2
- package/dist/hydration.mjs +2 -3
- package/dist/index.d.mts +12 -88
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +19 -797
- package/dist/index.mjs.map +1 -1
- package/dist/internal/acorn-default.mjs +29 -0
- package/dist/{cms-handler.d.mts → internal/cms-handler.d.mts} +0 -1
- package/dist/internal/cms-handler.d.mts.map +1 -0
- package/dist/{cms-handler.mjs → internal/cms-handler.mjs} +57 -8
- package/dist/internal/cms-handler.mjs.map +1 -0
- package/dist/internal/page-handler.astro +541 -0
- package/dist/lib/hydration-script.d.mts +1 -2
- package/dist/lib/hydration-script.d.mts.map +1 -1
- package/dist/lib/hydration-script.mjs +1 -2
- package/dist/lib/hydration-script.mjs.map +1 -1
- package/dist/locales-helpers-BvYYqnJ5.d.mts +64 -0
- package/dist/locales-helpers-BvYYqnJ5.d.mts.map +1 -0
- package/dist/locales-helpers-qiwh7nxS.mjs +54 -0
- package/dist/locales-helpers-qiwh7nxS.mjs.map +1 -0
- package/dist/node/content.d.mts +18 -0
- package/dist/node/content.d.mts.map +1 -0
- package/dist/node/content.d.ts +3 -0
- package/dist/node/content.d.ts.map +1 -0
- package/dist/node/content.js +2 -0
- package/dist/node/content.mjs +2 -0
- package/dist/node/index.d.mts +200 -0
- package/dist/node/index.d.mts.map +1 -0
- package/dist/node/index.d.ts +4 -0
- package/dist/node/index.d.ts.map +1 -0
- package/dist/node/index.js +3 -0
- package/dist/node/index.mjs +2513 -0
- package/dist/node/index.mjs.map +1 -0
- package/dist/{serialize-props-DqfDQeFl.mjs → serialize-props-BHoNpzH6.mjs} +4 -5
- package/dist/{serialize-props-DqfDQeFl.mjs.map → serialize-props-BHoNpzH6.mjs.map} +1 -1
- package/dist/src/cms-handler.d.ts +19 -0
- package/dist/src/cms-handler.d.ts.map +1 -0
- package/dist/src/cms-handler.js +366 -0
- package/dist/src/collections.d.ts +32 -0
- package/dist/src/collections.d.ts.map +1 -0
- package/dist/src/collections.js +50 -0
- package/dist/src/components/HydrationWrapper.d.ts +18 -0
- package/dist/src/components/HydrationWrapper.d.ts.map +1 -0
- package/dist/src/components/HydrationWrapper.js +21 -0
- package/dist/src/components/RenderWithBlocks.d.ts +23 -0
- package/dist/src/components/RenderWithBlocks.d.ts.map +1 -0
- package/dist/src/components/RenderWithBlocks.js +129 -0
- package/dist/src/components/RenderWithHydration.d.ts +17 -0
- package/dist/src/components/RenderWithHydration.d.ts.map +1 -0
- package/dist/src/components/RenderWithHydration.js +36 -0
- package/dist/src/components.d.ts +4 -0
- package/dist/src/components.d.ts.map +1 -0
- package/dist/src/components.js +3 -0
- package/dist/src/discovery/astro-frontmatter.d.ts +18 -0
- package/dist/src/discovery/astro-frontmatter.d.ts.map +1 -0
- package/dist/src/discovery/astro-frontmatter.js +24 -0
- package/dist/src/discovery/extract-props-ts.d.ts +41 -0
- package/dist/src/discovery/extract-props-ts.d.ts.map +1 -0
- package/dist/src/discovery/extract-props-ts.js +231 -0
- package/dist/src/discovery/merge-registry.d.ts +58 -0
- package/dist/src/discovery/merge-registry.d.ts.map +1 -0
- package/dist/src/discovery/merge-registry.js +332 -0
- package/dist/src/discovery/registry-endpoint.d.ts +42 -0
- package/dist/src/discovery/registry-endpoint.d.ts.map +1 -0
- package/dist/src/discovery/registry-endpoint.js +81 -0
- package/dist/src/discovery/scan-components.d.ts +98 -0
- package/dist/src/discovery/scan-components.d.ts.map +1 -0
- package/dist/src/discovery/scan-components.js +399 -0
- package/dist/src/discovery/scan-mdx.d.ts +63 -0
- package/dist/src/discovery/scan-mdx.d.ts.map +1 -0
- package/dist/src/discovery/scan-mdx.js +112 -0
- package/dist/src/discovery/scan-overrides.d.ts +71 -0
- package/dist/src/discovery/scan-overrides.d.ts.map +1 -0
- package/dist/src/discovery/scan-overrides.js +33 -0
- package/dist/src/hydration.d.ts +4 -0
- package/dist/src/hydration.d.ts.map +1 -0
- package/dist/src/hydration.js +4 -0
- package/dist/src/index.d.ts +11 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/index.js +25 -0
- package/dist/src/lib/hydration-scanner.d.ts +47 -0
- package/dist/src/lib/hydration-scanner.d.ts.map +1 -0
- package/dist/src/lib/hydration-scanner.js +135 -0
- package/dist/src/lib/hydration-script.d.ts +28 -0
- package/dist/src/lib/hydration-script.d.ts.map +1 -0
- package/dist/src/lib/hydration-script.js +88 -0
- package/dist/src/lib/hydration-utils.d.ts +51 -0
- package/dist/src/lib/hydration-utils.d.ts.map +1 -0
- package/dist/src/lib/hydration-utils.js +83 -0
- package/dist/src/lib/page-api.d.ts +77 -0
- package/dist/src/lib/page-api.d.ts.map +1 -0
- package/dist/src/lib/page-api.js +121 -0
- package/dist/src/lib/route-utils.d.ts +41 -0
- package/dist/src/lib/route-utils.d.ts.map +1 -0
- package/dist/src/lib/route-utils.js +78 -0
- package/dist/src/lib/routing-config.d.ts +32 -0
- package/dist/src/lib/routing-config.d.ts.map +1 -0
- package/dist/src/lib/routing-config.js +93 -0
- package/dist/src/lib/serialize-props.d.ts +6 -0
- package/dist/src/lib/serialize-props.d.ts.map +1 -0
- package/dist/src/lib/serialize-props.js +7 -0
- package/dist/src/lib/virtual-module-generators.d.ts +57 -0
- package/dist/src/lib/virtual-module-generators.d.ts.map +1 -0
- package/dist/src/lib/virtual-module-generators.js +263 -0
- package/dist/src/lib/withHydration.d.ts +51 -0
- package/dist/src/lib/withHydration.d.ts.map +1 -0
- package/dist/src/lib/withHydration.js +49 -0
- package/dist/src/loader.d.ts +14 -0
- package/dist/src/loader.d.ts.map +1 -0
- package/dist/src/loader.js +89 -0
- package/dist/src/locales-helpers.d.ts +61 -0
- package/dist/src/locales-helpers.d.ts.map +1 -0
- package/dist/src/locales-helpers.js +49 -0
- package/dist/src/mime-types.d.ts +3 -0
- package/dist/src/mime-types.d.ts.map +1 -0
- package/dist/src/mime-types.js +19 -0
- package/dist/src/path-validation.d.ts +8 -0
- package/dist/src/path-validation.d.ts.map +1 -0
- package/dist/src/path-validation.js +12 -0
- package/dist/src/plugin-spa.d.ts +164 -0
- package/dist/src/plugin-spa.d.ts.map +1 -0
- package/dist/src/plugin-spa.js +972 -0
- package/dist/src/safe-json-stringify.d.ts +13 -0
- package/dist/src/safe-json-stringify.d.ts.map +1 -0
- package/dist/src/safe-json-stringify.js +6 -0
- package/dist/src/site-styles/content-wrapper-endpoint.d.ts +76 -0
- package/dist/src/site-styles/content-wrapper-endpoint.d.ts.map +1 -0
- package/dist/src/site-styles/content-wrapper-endpoint.js +227 -0
- package/dist/src/site-styles/render-endpoint.d.ts +55 -0
- package/dist/src/site-styles/render-endpoint.d.ts.map +1 -0
- package/dist/src/site-styles/render-endpoint.js +263 -0
- package/dist/src/site-styles/styles-endpoint.d.ts +61 -0
- package/dist/src/site-styles/styles-endpoint.d.ts.map +1 -0
- package/dist/src/site-styles/styles-endpoint.js +158 -0
- package/dist/src/types.d.ts +627 -0
- package/dist/src/types.d.ts.map +1 -0
- package/dist/src/types.js +1 -0
- package/dist/{types-Bsd_qENn.d.mts → types-CS9neadI.d.mts} +193 -3
- package/dist/types-CS9neadI.d.mts.map +1 -0
- package/dist/virtual-modules.d.ts +155 -0
- package/dist/{withHydration-692fMySA.mjs → withHydration-C256ox_6.mjs} +6 -2
- package/dist/withHydration-C256ox_6.mjs.map +1 -0
- package/dist/{withHydration-BGgQDE-H.d.mts → withHydration-DkKpkmzJ.d.mts} +5 -2
- package/dist/withHydration-DkKpkmzJ.d.mts.map +1 -0
- package/package.json +106 -40
- package/dist/cms-handler.d.mts.map +0 -1
- package/dist/cms-handler.mjs.map +0 -1
- package/dist/collections.mjs.map +0 -1
- package/dist/handlers/page-handler.astro +0 -299
- package/dist/loader-W3i9kf3p.mjs +0 -61
- package/dist/loader-W3i9kf3p.mjs.map +0 -1
- package/dist/types-Bsd_qENn.d.mts.map +0 -1
- package/dist/withHydration-692fMySA.mjs.map +0 -1
- package/dist/withHydration-BGgQDE-H.d.mts.map +0 -1
package/dist/components.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"components.mjs","names":[],"sources":["../src/components/HydrationWrapper.tsx","../src/components/RenderWithHydration.tsx","../src/components/RenderWithBlocks.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport { serializeProps } from '../lib/serialize-props.js';\nimport type { HydrationStrategy } from '../types.js';\n\ninterface HydrationWrapperProps {\n componentName: string;\n strategy: HydrationStrategy;\n props: Record<string, unknown>;\n children: ReactNode;\n}\n\n/**\n * Wraps hydratable components with data attributes for browser hydration.\n *\n * When strategy is 'none', renders children directly without wrapper overhead.\n * Otherwise, wraps in a div with data-hydrate attributes that the browser\n * hydration script uses to find and hydrate components.\n */\nexport function HydrationWrapper({ componentName, strategy, props, children }: HydrationWrapperProps) {\n // No hydration needed - render children directly without wrapper\n if (strategy === 'none') {\n return <>{children}</>;\n }\n\n // Wrap with hydration markers for the browser script to find\n return (\n <div\n style={{ display: 'contents' }}\n data-hydrate={componentName}\n data-hydrate-strategy={strategy}\n data-props={serializeProps(props)}\n >\n {children}\n </div>\n );\n}\n","import type { Config, Data } from '@puckeditor/core';\nimport { Render } from '@puckeditor/core';\nimport { isHydratable } from '../lib/hydration-utils.js';\nimport { HydrationWrapper } from './HydrationWrapper.js';\n\ninterface RenderWithHydrationProps {\n config: Config;\n data: Data;\n}\n\n/**\n * Wrapper around Puck's Render component that adds hydration support.\n *\n * For each component with a hydration strategy configured, wraps the\n * component's render output with HydrationWrapper to add data-hydrate\n * attributes for browser-side hydration.\n *\n * Non-hydratable components render without any wrapper overhead.\n */\nexport function RenderWithHydration({ config, data }: RenderWithHydrationProps) {\n // Create wrapped config with hydration-aware render functions\n const wrappedConfig: Config = {\n ...config,\n components: Object.fromEntries(\n Object.entries(config.components).map(([name, componentConfig]) => {\n const strategy = isHydratable(name, config);\n\n if (strategy === 'none') {\n // No wrapping needed - component stays static\n return [name, componentConfig];\n }\n\n // Wrap the render function so its output becomes HydrationWrapper children\n const originalRender = componentConfig.render;\n return [\n name,\n {\n ...componentConfig,\n render: (props) => (\n <HydrationWrapper componentName={name} strategy={strategy} props={props}>\n {originalRender(props)}\n </HydrationWrapper>\n ),\n },\n ];\n }),\n ),\n };\n\n return <Render config={wrappedConfig} data={data} />;\n}\n","import type { ComponentConfig, Config, Data } from '@puckeditor/core';\nimport { Render } from '@puckeditor/core';\nimport type { ComponentType } from 'react';\nimport { hasHydratableComponents } from '../lib/hydration-utils.js';\nimport { RenderWithHydration } from './RenderWithHydration.js';\n\ninterface MDXComponent {\n id: string;\n title: string;\n Component: ComponentType;\n}\n\ninterface RenderWithBlocksProps {\n config: Config;\n data: Data;\n mdxComponents: MDXComponent[];\n}\n\n/**\n * Internal component for rendering Puck pages with MDX blocks.\n *\n * Uses Puck's Render component for static rendering in Astro.\n * All content is pre-rendered at build time with no client-side JavaScript.\n *\n * MDX blocks are passed as React components (not HTML strings), which:\n * - Avoids dangerouslySetInnerHTML security risks\n * - More efficient (no HTML conversion round-trip)\n * - Type-safe with proper React component types\n *\n * **Note:** This function is internal. Use `createPageRendererWithBlocks` instead,\n * which provides a factory pattern to handle the closure correctly.\n *\n * @internal\n * @param props - Component props\n * @param props.config - Base Puck configuration\n * @param props.data - Puck page data containing component tree\n * @param props.mdxComponents - Array of evaluated MDX React components\n */\nfunction RenderWithBlocks({ config, data, mdxComponents }: RenderWithBlocksProps) {\n // Build enhanced config with MDX blocks\n const blockComponents: Record<string, ComponentConfig> = {};\n const blockCategoryList: string[] = [];\n\n // Create component configs for each block\n mdxComponents.forEach((block) => {\n const componentKey = `Block_${block.id}`;\n\n // Capture component in closure - Puck doesn't persist defaultProps reliably\n const BlockComponent = block.Component;\n\n blockComponents[componentKey] = {\n label: block.title,\n fields: {},\n defaultProps: {},\n render: () => {\n // Use blockId and BlockComponent from closure - no prop dependency\n return (\n <div className=\"mdx-content prose prose-sm max-w-none\">\n <BlockComponent />\n </div>\n );\n },\n };\n blockCategoryList.push(componentKey);\n });\n\n // Merge with existing config\n const existingCategories = config.categories || {};\n const existingComponents = config.components || {};\n\n // Merge block components with existing config components\n const mergedComponents = {\n ...existingComponents,\n ...blockComponents,\n } as Config['components'];\n\n const enhancedConfig: Config = {\n ...config,\n categories: {\n ...existingCategories,\n blocks: {\n title: 'Content Blocks',\n components: blockCategoryList,\n },\n },\n components: mergedComponents,\n };\n\n // Check if page has hydratable components\n const needsHydration = hasHydratableComponents(data, enhancedConfig);\n\n // Render with hydration support if needed, otherwise static\n return needsHydration ? (\n <RenderWithHydration config={enhancedConfig} data={data} />\n ) : (\n <Render config={enhancedConfig} data={data} />\n );\n}\n\n/**\n * Factory function to create a PageRenderer with MDX components baked in via closure.\n *\n * This approach avoids dangerouslySetInnerHTML by keeping React components as components\n * throughout the rendering pipeline. Components are captured in the closure and don't\n * need to be passed as props (which Astro can't serialize).\n *\n * @param config - The Puck configuration with component definitions\n * @param data - Puck page data containing component tree\n * @param mdxComponents - Array of evaluated MDX components\n * @returns A PageRenderer component with no props needed (components in closure)\n *\n * @example\n * ```astro\n * ---\n * import { createPageRendererWithBlocks } from '@conloca/astro-cms/components';\n * import { evaluateMDXBlocks } from '@conloca/mdx/node';\n * import { createContentAPI } from '@conloca/content-api/node';\n * import config from '../puck.config';\n *\n * const api = await createContentAPI({ contentRoot: './content' });\n * const mdxComponents = await evaluateMDXBlocks(api, 'en');\n * const PageRenderer = createPageRendererWithBlocks(config, puckData, mdxComponents);\n * ---\n * <PageRenderer />\n * ```\n *\n * Benefits:\n * - No dangerouslySetInnerHTML (safer, no XSS risk from HTML strings)\n * - No string conversion round-trip (more efficient)\n * - Type safe React components throughout\n * - Normal React rendering with proper escaping\n */\nexport function createPageRendererWithBlocks(config: Config, data: Data, mdxComponents: MDXComponent[]): ComponentType {\n // Capture components in closure - no need to pass as props\n return function PageRendererWithBlocks() {\n return <RenderWithBlocks config={config} data={data} mdxComponents={mdxComponents} />;\n };\n}\n"],"mappings":";;;;;;;;;;;;AAkBA,SAAgB,iBAAiB,EAAE,eAAe,UAAU,OAAO,YAAmC;AAEpG,KAAI,aAAa,OACf,QAAO,gCAAG,WAAY;AAIxB,QACE,oBAAC;EACC,OAAO,EAAE,SAAS,YAAY;EAC9B,gBAAc;EACd,yBAAuB;EACvB,cAAY,eAAe,MAAM;EAEhC;GACG;;;;;;;;;;;;;;ACdV,SAAgB,oBAAoB,EAAE,QAAQ,QAAkC;AA8B9E,QAAO,oBAAC;EAAO,QA5Be;GAC5B,GAAG;GACH,YAAY,OAAO,YACjB,OAAO,QAAQ,OAAO,WAAW,CAAC,KAAK,CAAC,MAAM,qBAAqB;IACjE,MAAM,WAAW,aAAa,MAAM,OAAO;AAE3C,QAAI,aAAa,OAEf,QAAO,CAAC,MAAM,gBAAgB;IAIhC,MAAM,iBAAiB,gBAAgB;AACvC,WAAO,CACL,MACA;KACE,GAAG;KACH,SAAS,UACP,oBAAC;MAAiB,eAAe;MAAgB;MAAiB;gBAC/D,eAAe,MAAM;OACL;KAEtB,CACF;KACD,CACH;GACF;EAE2C;GAAQ;;;;;;;;;;;;;;;;;;;;;;;;;ACXtD,SAAS,iBAAiB,EAAE,QAAQ,MAAM,iBAAwC;CAEhF,MAAM,kBAAmD,EAAE;CAC3D,MAAM,oBAA8B,EAAE;AAGtC,eAAc,SAAS,UAAU;EAC/B,MAAM,eAAe,SAAS,MAAM;EAGpC,MAAM,iBAAiB,MAAM;AAE7B,kBAAgB,gBAAgB;GAC9B,OAAO,MAAM;GACb,QAAQ,EAAE;GACV,cAAc,EAAE;GAChB,cAAc;AAEZ,WACE,oBAAC;KAAI,WAAU;eACb,oBAAC,mBAAiB;MACd;;GAGX;AACD,oBAAkB,KAAK,aAAa;GACpC;CAGF,MAAM,qBAAqB,OAAO,cAAc,EAAE;CAIlD,MAAM,mBAAmB;EACvB,GAJyB,OAAO,cAAc,EAAE;EAKhD,GAAG;EACJ;CAED,MAAM,iBAAyB;EAC7B,GAAG;EACH,YAAY;GACV,GAAG;GACH,QAAQ;IACN,OAAO;IACP,YAAY;IACb;GACF;EACD,YAAY;EACb;AAMD,QAHuB,wBAAwB,MAAM,eAAe,GAIlE,oBAAC;EAAoB,QAAQ;EAAsB;GAAQ,GAE3D,oBAAC;EAAO,QAAQ;EAAsB;GAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqClD,SAAgB,6BAA6B,QAAgB,MAAY,eAA8C;AAErH,QAAO,SAAS,yBAAyB;AACvC,SAAO,oBAAC;GAAyB;GAAc;GAAqB;IAAiB"}
|
|
1
|
+
{"version":3,"file":"components.mjs","names":[],"sources":["../src/components/HydrationWrapper.tsx","../src/components/RenderWithHydration.tsx","../src/components/RenderWithBlocks.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport { serializeProps } from '../lib/serialize-props.js';\nimport type { HydrationStrategy } from '../types.js';\n\ninterface HydrationWrapperProps {\n componentName: string;\n strategy: HydrationStrategy;\n props: Record<string, unknown>;\n children: ReactNode;\n}\n\n/**\n * Wraps hydratable components with data attributes for browser hydration.\n *\n * When strategy is 'none', renders children directly without wrapper overhead.\n * Otherwise, wraps in a div with data-hydrate attributes that the browser\n * hydration script uses to find and hydrate components.\n */\nexport function HydrationWrapper({ componentName, strategy, props, children }: HydrationWrapperProps) {\n // No hydration needed - render children directly without wrapper\n if (strategy === 'none') {\n return <>{children}</>;\n }\n\n // Strip Puck-internal props that aren't needed for hydration.\n // `puck` contains functions (renderDropZone) that can't survive JSON serialization\n // and would crash on hydration if a component called them.\n const { puck: _puck, ...hydrateProps } = props as Record<string, unknown> & { puck?: unknown };\n\n // Wrap with hydration markers for the browser script to find\n return (\n <div\n style={{ display: 'contents' }}\n data-hydrate={componentName}\n data-hydrate-strategy={strategy}\n data-props={serializeProps(hydrateProps)}\n >\n {children}\n </div>\n );\n}\n","import type { Config, Data } from '@puckeditor/core';\nimport { Render } from '@puckeditor/core/rsc';\nimport { isHydratable } from '../lib/hydration-utils.js';\nimport { HydrationWrapper } from './HydrationWrapper.js';\n\ninterface RenderWithHydrationProps {\n config: Config;\n data: Data;\n}\n\n/**\n * Wrapper around Puck's Render component that adds hydration support.\n *\n * For each component with a hydration strategy configured, wraps the\n * component's render output with HydrationWrapper to add data-hydrate\n * attributes for browser-side hydration.\n *\n * Non-hydratable components render without any wrapper overhead.\n */\nexport function RenderWithHydration({ config, data }: RenderWithHydrationProps) {\n // Create wrapped config with hydration-aware render functions\n const wrappedConfig: Config = {\n ...config,\n components: Object.fromEntries(\n Object.entries(config.components).map(([name, componentConfig]) => {\n const strategy = isHydratable(name, config);\n\n if (strategy === 'none') {\n // No wrapping needed - component stays static\n return [name, componentConfig];\n }\n\n // Wrap the render function so its output becomes HydrationWrapper children\n const originalRender = componentConfig.render;\n return [\n name,\n {\n ...componentConfig,\n render: (props) => (\n <HydrationWrapper componentName={name} strategy={strategy} props={props}>\n {originalRender(props)}\n </HydrationWrapper>\n ),\n },\n ];\n }),\n ),\n };\n\n return <Render config={wrappedConfig} data={data} />;\n}\n","import type { MDXBlockEvaluationResult } from '@conloca/mdx/node';\nimport type { ComponentConfig, Config, Data } from '@puckeditor/core';\nimport { Render } from '@puckeditor/core/rsc';\nimport cn from 'clsx';\nimport type { ComponentType } from 'react';\nimport { hasHydratableComponents } from '../lib/hydration-utils.js';\nimport { RenderWithHydration } from './RenderWithHydration.js';\n\ninterface MDXComponent {\n id: string;\n title: string;\n Component: ComponentType;\n}\n\nfunction isRenderableBlock(block: MDXBlockEvaluationResult | MDXComponent): block is MDXComponent {\n return 'Component' in block && !('ok' in block);\n}\n\ninterface RenderWithBlocksProps {\n config: Config;\n data: Data;\n mdxComponents: MDXComponent[];\n}\n\ninterface ContentBlockSectionProps {\n title?: string;\n subtitle?: string;\n label?: string;\n blockId: string;\n width?: 'narrow' | 'default';\n tone?: 'transparent' | 'subtle';\n}\n\nconst contentBlockWidthClasses: Record<NonNullable<ContentBlockSectionProps['width']>, string> = {\n narrow: 'max-w-3xl',\n default: 'max-w-4xl',\n};\n\nconst contentBlockToneClasses: Record<NonNullable<ContentBlockSectionProps['tone']>, string> = {\n transparent: '',\n subtle:\n 'rounded-3xl border border-surface-200/80 bg-surface-100/70 p-6 sm:p-8 dark:border-surface-800/60 dark:bg-surface-900/50',\n};\n\nfunction createFailedBlockComponent(block: Extract<MDXBlockEvaluationResult, { ok: false }>): ComponentType {\n return function FailedBlockComponent() {\n return (\n <div className=\"p-4 bg-red-50 border border-red-200 rounded text-red-600\">\n <p className=\"font-semibold mb-2\">MDX Block Error</p>\n <p className=\"text-sm\">Block: {block.id}</p>\n <p className=\"text-xs mt-2\">{block.error.message}</p>\n </div>\n );\n };\n}\n\nfunction resolveRenderableBlocks(blocks: (MDXBlockEvaluationResult | MDXComponent)[]): MDXComponent[] {\n return blocks.map((block) => {\n if (isRenderableBlock(block)) {\n return block;\n }\n\n if (block.ok) {\n return block;\n }\n\n return {\n id: block.id,\n title: block.title,\n Component: createFailedBlockComponent(block),\n };\n });\n}\n\n// ── Main Component ──────────────────────────────────────────────────────────\n\n/**\n * Internal component for rendering Puck pages with MDX blocks.\n *\n * Enhances the Puck config by:\n * 1. Registering each MDX block as a dynamic Puck component (`Block_{id}`)\n * 2. Overriding ContentBlockSection's render to resolve blockId → actual MDX content\n *\n * MDX blocks are passed as React components (not HTML strings), which:\n * - Avoids dangerouslySetInnerHTML security risks\n * - More efficient (no HTML conversion round-trip)\n * - Type-safe with proper React component types\n *\n * @internal\n */\nfunction RenderWithBlocks({ config, data, mdxComponents }: RenderWithBlocksProps) {\n // Build enhanced config with MDX blocks\n const blockComponents: Record<string, ComponentConfig> = {};\n const blockCategoryList: string[] = [];\n const blockComponentMap = new Map(mdxComponents.map((block) => [block.id, block]));\n\n // Create component configs for each block\n mdxComponents.forEach((block) => {\n const componentKey = `Block_${block.id}`;\n\n // Capture component in closure - Puck doesn't persist defaultProps reliably\n const BlockComponent = block.Component;\n\n blockComponents[componentKey] = {\n label: block.title,\n fields: {},\n defaultProps: {},\n render: () => {\n // Use blockId and BlockComponent from closure - no prop dependency\n return (\n <div className=\"mdx-content conloca-prose max-w-none\">\n <BlockComponent />\n </div>\n );\n },\n };\n blockCategoryList.push(componentKey);\n });\n\n // Merge with existing config\n const existingCategories = config.categories || {};\n const existingComponents = config.components || {};\n const contentBlockSection = existingComponents.ContentBlockSection as\n | ComponentConfig<ContentBlockSectionProps>\n | undefined;\n\n const enhancedContentBlockSection = contentBlockSection\n ? {\n ...contentBlockSection,\n render: ({\n blockId,\n label,\n title,\n subtitle,\n tone = 'transparent',\n width = 'default',\n }: ContentBlockSectionProps) => {\n const selectedBlock = blockComponentMap.get(blockId);\n const SelectedBlockComponent = selectedBlock?.Component;\n\n return (\n <section className=\"pb-16 sm:pb-20\">\n <div className={cn('mx-auto px-4 sm:px-6 lg:px-8', contentBlockWidthClasses[width])}>\n {label ? (\n <p className=\"mb-4 text-sm font-medium uppercase tracking-[0.18em] text-brand-700 dark:text-brand-300\">\n {label}\n </p>\n ) : null}\n {title && (\n <h2 className=\"text-2xl sm:text-3xl font-bold text-surface-900 dark:text-white mb-4\">{title}</h2>\n )}\n {subtitle && (\n <p className=\"text-surface-500 dark:text-surface-400 text-sm leading-relaxed mb-6\">{subtitle}</p>\n )}\n <div className={cn(contentBlockToneClasses[tone])}>\n {SelectedBlockComponent && (\n <div className=\"mdx-content conloca-prose max-w-none\">\n <SelectedBlockComponent />\n </div>\n )}\n </div>\n </div>\n </section>\n );\n },\n }\n : undefined;\n\n // Merge block components with existing config components\n const mergedComponents = {\n ...existingComponents,\n ...(enhancedContentBlockSection && { ContentBlockSection: enhancedContentBlockSection }),\n ...blockComponents,\n } as Config['components'];\n\n const enhancedConfig: Config = {\n ...config,\n categories: {\n ...existingCategories,\n blocks: {\n title: 'Content Blocks',\n components: blockCategoryList,\n },\n },\n components: mergedComponents,\n };\n\n // Check if page has hydratable components\n const needsHydration = hasHydratableComponents(data, enhancedConfig);\n\n if (needsHydration) {\n return <RenderWithHydration config={enhancedConfig} data={data} />;\n }\n\n return <Render config={enhancedConfig} data={data} />;\n}\n\n/**\n * Factory function to create a PageRenderer with MDX components baked in via closure.\n *\n * This approach avoids dangerouslySetInnerHTML by keeping React components as components\n * throughout the rendering pipeline. Components are captured in the closure and don't\n * need to be passed as props (which Astro can't serialize).\n *\n * @param config - The Puck configuration with component definitions\n * @param data - Puck page data containing component tree\n * @param mdxComponents - Array of evaluated MDX block results\n * @returns A PageRenderer component with no props needed (components in closure)\n */\nexport function createPageRendererWithBlocks(\n config: Config,\n data: Data,\n mdxComponents: (MDXBlockEvaluationResult | MDXComponent)[],\n): ComponentType {\n const renderableBlocks = resolveRenderableBlocks(mdxComponents);\n\n // Capture components in closure - no need to pass as props\n return function PageRendererWithBlocks() {\n return <RenderWithBlocks config={config} data={data} mdxComponents={renderableBlocks} />;\n };\n}\n"],"mappings":"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"}
|
package/dist/hydration.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { n as WithHydrationStrategy, r as withHydration, t as HydrationMeta } from "./withHydration-BGgQDE-H.mjs";
|
|
1
|
+
import { n as HydrationStrategy } from "./types-CS9neadI.mjs";
|
|
3
2
|
import { ComponentRegistry } from "./lib/hydration-script.mjs";
|
|
3
|
+
import { n as WithHydrationStrategy, r as withHydration, t as HydrationMeta } from "./withHydration-DkKpkmzJ.mjs";
|
|
4
4
|
export { type ComponentRegistry, type HydrationMeta, type HydrationStrategy, type WithHydrationStrategy, withHydration };
|
package/dist/hydration.mjs
CHANGED
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
import { t as withHydration } from "./withHydration-
|
|
2
|
-
|
|
3
|
-
export { withHydration };
|
|
1
|
+
import { t as withHydration } from "./withHydration-C256ox_6.mjs";
|
|
2
|
+
export { withHydration };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,45 +1,11 @@
|
|
|
1
|
-
import { n as
|
|
2
|
-
import { n as
|
|
1
|
+
import { n as localesFromAstroI18n, r as localesFromStarlight, t as ConlocaLocales } from "./locales-helpers-BvYYqnJ5.mjs";
|
|
2
|
+
import { a as PageReference, c as TemplateConfig, i as PageData, n as HydrationStrategy, o as ResolvedRoutingConfig, r as LayoutProps, t as DataCollectionEntry } from "./types-CS9neadI.mjs";
|
|
3
3
|
import { ComponentRegistry } from "./lib/hydration-script.mjs";
|
|
4
|
+
import { n as WithHydrationStrategy, r as withHydration, t as HydrationMeta } from "./withHydration-DkKpkmzJ.mjs";
|
|
5
|
+
import { MdxComponentDescriptor, MdxComponentInsertHint, MdxComponentProp, MdxComponents, MdxJsxComponentDescriptor, MdxSnippetDescriptor, defineMdxComponents, readStringAttribute, writeStringAttribute } from "@conloca/cms-spa/mdx-components";
|
|
6
|
+
import { CoreFieldsMode, FieldHint, FieldHintCommon, FieldHintVariant, FieldHints, PageSchemaDescriptor, PageSchemaEntry, PageSchemaGroup, PageSchemas, definePageSchema } from "@conloca/cms-spa/page-schemas";
|
|
4
7
|
import { BlockMeta, PageMeta, blockMetaSchema, pageMetaSchema } from "@conloca/content-api/schemas";
|
|
5
8
|
import { Config, Data } from "@puckeditor/core";
|
|
6
|
-
import { AstroIntegration } from "astro";
|
|
7
|
-
import { Loader } from "astro/loaders";
|
|
8
|
-
import { UIConfig } from "@conloca/cms-spa";
|
|
9
|
-
|
|
10
|
-
//#region src/lib/hydration-scanner.d.ts
|
|
11
|
-
/**
|
|
12
|
-
* Result of scanning a component file for withHydration usage.
|
|
13
|
-
*/
|
|
14
|
-
interface HydrationDiscovery {
|
|
15
|
-
/** Component name derived from filename (PascalCase) */
|
|
16
|
-
componentName: string;
|
|
17
|
-
/** Absolute path to the component file */
|
|
18
|
-
filePath: string;
|
|
19
|
-
/** Hydration strategy extracted from withHydration call */
|
|
20
|
-
strategy: 'load' | 'visible' | 'idle';
|
|
21
|
-
}
|
|
22
|
-
/**
|
|
23
|
-
* Scans component directories for files using withHydration wrapper.
|
|
24
|
-
*
|
|
25
|
-
* This function performs static analysis to discover components marked
|
|
26
|
-
* for hydration, without executing any component code.
|
|
27
|
-
*
|
|
28
|
-
* @param componentPaths - Relative paths to scan (e.g., ['src/components/puck'])
|
|
29
|
-
* @param projectRoot - Absolute path to the project root
|
|
30
|
-
* @returns Array of discovered hydratable components with their strategies
|
|
31
|
-
*
|
|
32
|
-
* @example
|
|
33
|
-
* ```typescript
|
|
34
|
-
* const discoveries = await scanForHydratableComponents(
|
|
35
|
-
* ['src/components/puck'],
|
|
36
|
-
* '/path/to/project'
|
|
37
|
-
* )
|
|
38
|
-
* // => [{ componentName: 'TestimonialGrid', filePath: '...', strategy: 'visible' }]
|
|
39
|
-
* ```
|
|
40
|
-
*/
|
|
41
|
-
declare function scanForHydratableComponents(componentPaths: string[], projectRoot: string): Promise<HydrationDiscovery[]>;
|
|
42
|
-
//#endregion
|
|
43
9
|
//#region src/lib/hydration-utils.d.ts
|
|
44
10
|
/**
|
|
45
11
|
* Extended ComponentConfig with hydration support.
|
|
@@ -91,6 +57,12 @@ declare function findHydratableComponents(data: Data, config: Config): Hydratabl
|
|
|
91
57
|
declare function hasHydratableComponents(data: Data, config: Config): boolean;
|
|
92
58
|
//#endregion
|
|
93
59
|
//#region src/lib/route-utils.d.ts
|
|
60
|
+
declare function toDate(value: string | Date | null | undefined): Date | undefined;
|
|
61
|
+
interface PublishSchedule {
|
|
62
|
+
publishAt?: string | Date | null;
|
|
63
|
+
unpublishAt?: string | Date | null;
|
|
64
|
+
}
|
|
65
|
+
declare function isPublished(data: PublishSchedule): boolean;
|
|
94
66
|
/**
|
|
95
67
|
* Extract slug from pathname given a route pattern.
|
|
96
68
|
*
|
|
@@ -132,53 +104,5 @@ declare function pathnameFromSlug(slug: string | undefined, pattern: string): st
|
|
|
132
104
|
*/
|
|
133
105
|
declare function serializeProps(props: Record<string, unknown>): string;
|
|
134
106
|
//#endregion
|
|
135
|
-
|
|
136
|
-
interface ConlocaLoaderOptions {
|
|
137
|
-
collection: string;
|
|
138
|
-
contentRoot: string;
|
|
139
|
-
site?: string;
|
|
140
|
-
/** Collection kind. If not provided, defaults to 'block' for 'blocks' collection, 'page' otherwise. */
|
|
141
|
-
kind?: 'page' | 'block' | 'data';
|
|
142
|
-
}
|
|
143
|
-
/**
|
|
144
|
-
* Custom Astro content loader for Conloca CMS.
|
|
145
|
-
* Loads content from the Conloca content directory into Astro collections.
|
|
146
|
-
*/
|
|
147
|
-
declare function conlocaLoader(options: ConlocaLoaderOptions): Loader;
|
|
148
|
-
//#endregion
|
|
149
|
-
//#region src/plugin-spa.d.ts
|
|
150
|
-
interface ConlocaCMSOptions extends Omit<UIConfig, 'basename'> {
|
|
151
|
-
contentRoot: string;
|
|
152
|
-
canvasDir?: string;
|
|
153
|
-
route?: string;
|
|
154
|
-
puckConfigPath: string;
|
|
155
|
-
schemasPath?: string;
|
|
156
|
-
/**
|
|
157
|
-
* Default layout for content pages.
|
|
158
|
-
* When provided without routing config, enables routing with catch-all pattern.
|
|
159
|
-
* For multi-route setups, use routing.routes.{name}.layout instead.
|
|
160
|
-
*
|
|
161
|
-
* @example './src/layouts/Layout.astro'
|
|
162
|
-
*/
|
|
163
|
-
layout?: string;
|
|
164
|
-
routing?: RoutingConfigInput;
|
|
165
|
-
templates?: Record<string, TemplateConfig>;
|
|
166
|
-
/**
|
|
167
|
-
* Paths to scan for hydratable components.
|
|
168
|
-
* Components using withHydration() in these directories are auto-discovered.
|
|
169
|
-
*
|
|
170
|
-
* @example ['src/components/puck']
|
|
171
|
-
*/
|
|
172
|
-
componentPaths?: string[];
|
|
173
|
-
/**
|
|
174
|
-
* Path to the assets directory for image uploads.
|
|
175
|
-
* When provided, enables the Media Library and asset upload API routes.
|
|
176
|
-
*
|
|
177
|
-
* @example 'src/assets/uploads'
|
|
178
|
-
*/
|
|
179
|
-
assetsPath?: string;
|
|
180
|
-
}
|
|
181
|
-
declare function conlocaCMS(options: ConlocaCMSOptions): AstroIntegration;
|
|
182
|
-
//#endregion
|
|
183
|
-
export { type BlockMeta, type ComponentRegistry, type ConlocaCMSOptions, type ConlocaLoaderOptions, type HydratableComponent, type HydratableComponentConfig, type HydrationDiscovery, type HydrationMeta, type HydrationStrategy, type PageMeta, type TemplateConfig, type WithHydrationStrategy, blockMetaSchema, conlocaCMS, conlocaLoader, extractSlugFromPathname, findHydratableComponents, hasHydratableComponents, isHydratable, pageMetaSchema, pathnameFromSlug, scanForHydratableComponents, serializeProps, withHydration };
|
|
107
|
+
export { type BlockMeta, type ComponentRegistry, type ConlocaLocales, type CoreFieldsMode, type DataCollectionEntry, type FieldHint, type FieldHintCommon, type FieldHintVariant, type FieldHints, type HydratableComponent, type HydratableComponentConfig, type HydrationMeta, type HydrationStrategy, type LayoutProps, type MdxComponentDescriptor, type MdxComponentInsertHint, type MdxComponentProp, type MdxComponents, type MdxJsxComponentDescriptor, type MdxSnippetDescriptor, type PageData, type PageMeta, type PageReference, type PageSchemaDescriptor, type PageSchemaEntry, type PageSchemaGroup, type PageSchemas, type ResolvedRoutingConfig, type TemplateConfig, type WithHydrationStrategy, blockMetaSchema, defineMdxComponents, definePageSchema, extractSlugFromPathname, findHydratableComponents, hasHydratableComponents, isHydratable, isPublished, localesFromAstroI18n, localesFromStarlight, pageMetaSchema, pathnameFromSlug, readStringAttribute, serializeProps, toDate, withHydration, writeStringAttribute };
|
|
184
108
|
//# sourceMappingURL=index.d.mts.map
|
package/dist/index.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.mts","names":[],"sources":["../src/lib/hydration-
|
|
1
|
+
{"version":3,"file":"index.d.mts","names":[],"sources":["../src/lib/hydration-utils.ts","../src/lib/route-utils.ts","../src/lib/serialize-props.ts"],"mappings":";;;;;;;;;;;;;UAQiB;;EAEf,YAAY;EACZ,UAAU;;;;;;UAOK;;EAEf;;EAEA,OAAO;;EAEP,UAAU,QAAQ;;EAElB;;;;;;;;;;;;iBAac,aAAa,uBAAuB,QAAQ,SAAS;;;;;;;;;iBAsBrD,yBAAyB,MAAM,MAAM,QAAQ,SAAS;;;;;iBA0CtD,wBAAwB,MAAM,MAAM,QAAQ;;;iBCvG5C,OAAO,gBAAgB,0BAAuB;UAcpD;EACR,qBAAqB;EACrB,uBAAuB;;iBAGT,YAAY,MAAM;;;;;;;;;;;;;;;;;iBAgClB,wBAAwB,kBAAkB;;;;;;;;;;;;;;;;iBAkC1C,iBAAiB,0BAA0B;;;;;;;iBCjF3C,eAAe,OAAO"}
|