bsmnt 0.12.0 → 0.13.1

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.
Files changed (188) hide show
  1. package/dist/application/add-integration/index.d.ts.map +1 -1
  2. package/dist/application/add-integration/index.js +23 -0
  3. package/dist/application/add-integration/index.js.map +1 -1
  4. package/dist/domain/consent.d.ts +17 -0
  5. package/dist/domain/consent.d.ts.map +1 -0
  6. package/dist/domain/consent.js +13 -0
  7. package/dist/domain/consent.js.map +1 -0
  8. package/dist/domain/integration.d.ts +19 -2
  9. package/dist/domain/integration.d.ts.map +1 -1
  10. package/dist/domain/integration.js +10 -1
  11. package/dist/domain/integration.js.map +1 -1
  12. package/dist/domain/jobs.d.ts +17 -0
  13. package/dist/domain/jobs.d.ts.map +1 -0
  14. package/dist/domain/jobs.js +13 -0
  15. package/dist/domain/jobs.js.map +1 -0
  16. package/dist/domain/skills.d.ts +23 -2
  17. package/dist/domain/skills.d.ts.map +1 -1
  18. package/dist/domain/skills.js +23 -2
  19. package/dist/domain/skills.js.map +1 -1
  20. package/dist/domain/templates.d.ts +7 -1
  21. package/dist/domain/templates.d.ts.map +1 -1
  22. package/dist/domain/templates.js +2 -0
  23. package/dist/domain/templates.js.map +1 -1
  24. package/dist/index.js +34 -9
  25. package/dist/index.js.map +1 -1
  26. package/dist/infrastructure/create/setup-agent.d.ts.map +1 -1
  27. package/dist/infrastructure/create/setup-agent.js +11 -4
  28. package/dist/infrastructure/create/setup-agent.js.map +1 -1
  29. package/dist/infrastructure/integrations/inject-integration.d.ts.map +1 -1
  30. package/dist/infrastructure/integrations/inject-integration.js +36 -2
  31. package/dist/infrastructure/integrations/inject-integration.js.map +1 -1
  32. package/dist/modules/features/consent/ketch/config.d.ts +18 -0
  33. package/dist/modules/features/consent/ketch/config.d.ts.map +1 -0
  34. package/dist/modules/features/consent/ketch/config.js +24 -0
  35. package/dist/modules/features/consent/ketch/config.js.map +1 -0
  36. package/dist/modules/features/consent/ketch/mergers/biome.d.ts +16 -0
  37. package/dist/modules/features/consent/ketch/mergers/biome.d.ts.map +1 -0
  38. package/dist/modules/features/consent/ketch/mergers/biome.js +31 -0
  39. package/dist/modules/features/consent/ketch/mergers/biome.js.map +1 -0
  40. package/dist/modules/features/consent/ketch/mergers/check-integration.d.ts +13 -0
  41. package/dist/modules/features/consent/ketch/mergers/check-integration.d.ts.map +1 -0
  42. package/dist/modules/features/consent/ketch/mergers/check-integration.js +64 -0
  43. package/dist/modules/features/consent/ketch/mergers/check-integration.js.map +1 -0
  44. package/dist/modules/features/consent/ketch/mergers/env-example.d.ts +12 -0
  45. package/dist/modules/features/consent/ketch/mergers/env-example.d.ts.map +1 -0
  46. package/dist/modules/features/consent/ketch/mergers/env-example.js +28 -0
  47. package/dist/modules/features/consent/ketch/mergers/env-example.js.map +1 -0
  48. package/dist/modules/features/consent/ketch/mergers/footer.d.ts +17 -0
  49. package/dist/modules/features/consent/ketch/mergers/footer.d.ts.map +1 -0
  50. package/dist/modules/features/consent/ketch/mergers/footer.js +40 -0
  51. package/dist/modules/features/consent/ketch/mergers/footer.js.map +1 -0
  52. package/dist/modules/features/consent/ketch/mergers/knip.d.ts +18 -0
  53. package/dist/modules/features/consent/ketch/mergers/knip.d.ts.map +1 -0
  54. package/dist/modules/features/consent/ketch/mergers/knip.js +37 -0
  55. package/dist/modules/features/consent/ketch/mergers/knip.js.map +1 -0
  56. package/dist/modules/features/consent/ketch/mergers/layout.d.ts +25 -0
  57. package/dist/modules/features/consent/ketch/mergers/layout.d.ts.map +1 -0
  58. package/dist/modules/features/consent/ketch/mergers/layout.js +55 -0
  59. package/dist/modules/features/consent/ketch/mergers/layout.js.map +1 -0
  60. package/dist/modules/features/jobs/ashby/config.d.ts +19 -0
  61. package/dist/modules/features/jobs/ashby/config.d.ts.map +1 -0
  62. package/dist/modules/features/jobs/ashby/config.js +29 -0
  63. package/dist/modules/features/jobs/ashby/config.js.map +1 -0
  64. package/dist/modules/features/jobs/ashby/mergers/check-integration.d.ts +14 -0
  65. package/dist/modules/features/jobs/ashby/mergers/check-integration.d.ts.map +1 -0
  66. package/dist/modules/features/jobs/ashby/mergers/check-integration.js +78 -0
  67. package/dist/modules/features/jobs/ashby/mergers/check-integration.js.map +1 -0
  68. package/dist/modules/features/jobs/ashby/mergers/env-example.d.ts +12 -0
  69. package/dist/modules/features/jobs/ashby/mergers/env-example.d.ts.map +1 -0
  70. package/dist/modules/features/jobs/ashby/mergers/env-example.js +27 -0
  71. package/dist/modules/features/jobs/ashby/mergers/env-example.js.map +1 -0
  72. package/dist/modules/features/jobs/ashby/mergers/knip.d.ts +18 -0
  73. package/dist/modules/features/jobs/ashby/mergers/knip.d.ts.map +1 -0
  74. package/dist/modules/features/jobs/ashby/mergers/knip.js +41 -0
  75. package/dist/modules/features/jobs/ashby/mergers/knip.js.map +1 -0
  76. package/dist/paths.d.ts +12 -0
  77. package/dist/paths.d.ts.map +1 -1
  78. package/dist/paths.js +12 -0
  79. package/dist/paths.js.map +1 -1
  80. package/package.json +3 -1
  81. package/src/agent-skills/ashby-pagebuilder-block/SKILL.md +277 -0
  82. package/src/agent-skills/hubspot-pagebuilder-block/SKILL.md +58 -25
  83. package/src/agent-skills/ketch-consent-check/SKILL.md +197 -0
  84. package/src/agent-skills/ketch-consent-setup/SKILL.md +326 -0
  85. package/src/agent-skills/ketch-consent-setup/references/ui-customization.md +329 -0
  86. package/src/agent-skills/page-builder-block/SKILL.md +150 -0
  87. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/components/anchor-id-input.tsx +17 -0
  88. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/components/presentation-input.tsx +146 -0
  89. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/components/spacing-steps-input.tsx +84 -0
  90. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/fetchers/layout.ts +6 -3
  91. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/icons.ts +8 -0
  92. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/page-builder-config.ts +1 -1
  93. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/presentation.ts +47 -15
  94. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/queries.ts +12 -0
  95. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/components/reusable/blog-content.ts +5 -5
  96. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/components/reusable/description.ts +3 -3
  97. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/components/reusable/gated-content.ts +3 -3
  98. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/components/reusable/hero.ts +3 -3
  99. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/components/reusable/rich-text-block.ts +3 -3
  100. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/components/singleton/content-collection.ts +3 -3
  101. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/index.ts +8 -0
  102. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/layout/spacing-settings.ts +120 -0
  103. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/shared/anchor.ts +75 -0
  104. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/shared/block.ts +46 -0
  105. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/shared/presentation.ts +44 -0
  106. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/schemas/shared/spacing.ts +164 -0
  107. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/singletons.ts +7 -0
  108. package/src/modules/features/cms/sanity-pagebuilder/files/lib/integrations/sanity/structure.ts +4 -4
  109. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/components/anchor-id-input.tsx +17 -0
  110. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/components/presentation-input.tsx +146 -0
  111. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/components/spacing-steps-input.tsx +84 -0
  112. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/fetchers/layout.ts +4 -2
  113. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/icons.ts +8 -0
  114. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/page-builder-config.ts +1 -1
  115. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/presentation.ts +47 -15
  116. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/queries.ts +12 -0
  117. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/components/reusable/blog-content.ts +5 -5
  118. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/components/reusable/description.ts +3 -3
  119. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/components/reusable/gated-content.ts +3 -3
  120. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/components/reusable/hero.ts +3 -3
  121. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/components/reusable/rich-text-block.ts +3 -3
  122. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/components/singleton/content-collection.ts +3 -3
  123. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/index.ts +8 -0
  124. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/layout/spacing-settings.ts +120 -0
  125. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/shared/anchor.ts +75 -0
  126. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/shared/block.ts +46 -0
  127. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/shared/presentation.ts +44 -0
  128. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/schemas/shared/spacing.ts +164 -0
  129. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/singletons.ts +7 -0
  130. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/structure.ts +4 -4
  131. package/src/modules/features/cms/sanity-pagebuilder-cache/files/lib/integrations/sanity/tags.ts +2 -0
  132. package/src/modules/features/consent/ketch/files/lib/integrations/check-integration.ts +25 -0
  133. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/README.md +70 -0
  134. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/categories.ts +20 -0
  135. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/consent-store.ts +107 -0
  136. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/env.ts +20 -0
  137. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/ketch-experience.css +136 -0
  138. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/preferences-button.tsx +51 -0
  139. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/script.tsx +8 -0
  140. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/types.ts +15 -0
  141. package/src/modules/features/consent/ketch/files/lib/integrations/ketch/use-consent.ts +26 -0
  142. package/src/modules/features/jobs/ashby/files/_sanity-adapter/job-board-block.ts +53 -0
  143. package/src/modules/features/jobs/ashby/files/lib/integrations/ashby/README.md +134 -0
  144. package/src/modules/features/jobs/ashby/files/lib/integrations/ashby/env.ts +3 -0
  145. package/src/modules/features/jobs/ashby/files/lib/integrations/ashby/index.ts +40 -0
  146. package/src/modules/features/jobs/ashby/files/lib/integrations/ashby/normalize.ts +124 -0
  147. package/src/modules/features/jobs/ashby/files/lib/integrations/ashby/types.ts +20 -0
  148. package/src/modules/features/jobs/ashby/files/lib/integrations/check-integration.ts +25 -0
  149. package/src/templates/next-default/lib/utils/README.md +1 -0
  150. package/src/templates/next-default/lib/utils/image-sizes.ts +64 -25
  151. package/src/templates/next-experiments/lib/utils/README.md +1 -0
  152. package/src/templates/next-experiments/lib/utils/image-sizes.ts +64 -25
  153. package/src/templates/next-pagebuilder/AGENTS.md +129 -0
  154. package/src/templates/next-pagebuilder/CLAUDE.md +3 -0
  155. package/src/templates/next-pagebuilder/README.md +70 -0
  156. package/src/templates/next-pagebuilder/app/(content)/layout.tsx +2 -0
  157. package/src/templates/next-pagebuilder/components/layout/spacing-scale/index.tsx +18 -0
  158. package/src/templates/next-pagebuilder/components/page-builder/components/article-content/index.tsx +1 -1
  159. package/src/templates/next-pagebuilder/components/page-builder/components/content-collection/index.tsx +2 -2
  160. package/src/templates/next-pagebuilder/components/page-builder/components/description.tsx +3 -7
  161. package/src/templates/next-pagebuilder/components/page-builder/components/gated-content/index.tsx +2 -2
  162. package/src/templates/next-pagebuilder/components/page-builder/components/hero.tsx +3 -7
  163. package/src/templates/next-pagebuilder/components/page-builder/components/rich-text-block.tsx +3 -5
  164. package/src/templates/next-pagebuilder/components/page-builder/registry.tsx +70 -0
  165. package/src/templates/next-pagebuilder/components/page-builder/renderer.tsx +33 -49
  166. package/src/templates/next-pagebuilder/components/page-builder/section.tsx +35 -0
  167. package/src/templates/next-pagebuilder/components/page-document/index.tsx +2 -2
  168. package/src/templates/next-pagebuilder/lib/integrations/sanity/sanity.types.ts +92 -4
  169. package/src/templates/next-pagebuilder/lib/utils/image-sizes.ts +64 -25
  170. package/src/templates/next-pagebuilder-cache/AGENTS.md +136 -0
  171. package/src/templates/next-pagebuilder-cache/CLAUDE.md +3 -0
  172. package/src/templates/next-pagebuilder-cache/README.md +75 -0
  173. package/src/templates/next-pagebuilder-cache/app/(content)/layout.tsx +2 -0
  174. package/src/templates/next-pagebuilder-cache/components/layout/spacing-scale/index.tsx +46 -0
  175. package/src/templates/next-pagebuilder-cache/components/page-builder/components/article-content/index.tsx +1 -1
  176. package/src/templates/next-pagebuilder-cache/components/page-builder/components/content-collection/index.tsx +2 -2
  177. package/src/templates/next-pagebuilder-cache/components/page-builder/components/description.tsx +3 -7
  178. package/src/templates/next-pagebuilder-cache/components/page-builder/components/gated-content/index.tsx +2 -2
  179. package/src/templates/next-pagebuilder-cache/components/page-builder/components/hero.tsx +3 -7
  180. package/src/templates/next-pagebuilder-cache/components/page-builder/components/rich-text-block.tsx +3 -5
  181. package/src/templates/next-pagebuilder-cache/components/page-builder/registry.tsx +70 -0
  182. package/src/templates/next-pagebuilder-cache/components/page-builder/renderer.tsx +33 -49
  183. package/src/templates/next-pagebuilder-cache/components/page-builder/section.tsx +35 -0
  184. package/src/templates/next-pagebuilder-cache/components/page-document/index.tsx +2 -2
  185. package/src/templates/next-pagebuilder-cache/lib/integrations/sanity/sanity.types.ts +92 -4
  186. package/src/templates/next-pagebuilder-cache/lib/utils/image-sizes.ts +64 -25
  187. package/src/templates/next-webgl/lib/utils/README.md +1 -0
  188. package/src/templates/next-webgl/lib/utils/image-sizes.ts +64 -25
@@ -1,13 +1,13 @@
1
- import { ArticleContent } from "./components/article-content"
2
- import { ContentCollection } from "./components/content-collection"
1
+ import {
2
+ reserveAnchorIds,
3
+ resolveAnchorId,
4
+ } from "@/lib/integrations/sanity/schemas/shared/anchor"
3
5
  import type {
4
6
  ContentCollectionSearchParams,
5
7
  PinnedCollectionCategory,
6
8
  } from "./components/content-collection/types"
7
- import { Description } from "./components/description"
8
- import { GatedContent } from "./components/gated-content"
9
- import { Hero } from "./components/hero"
10
- import { RichTextBlock } from "./components/rich-text-block"
9
+ import { type BlockContext, getBlockEntry } from "./registry"
10
+ import { Section } from "./section"
11
11
  import type { PageBuilderBlock, PageBuilderBlocks } from "./types"
12
12
 
13
13
  type RendererProps = {
@@ -23,49 +23,33 @@ export function Renderer({
23
23
  }: RendererProps) {
24
24
  if (!blocks?.length) return null
25
25
 
26
+ const context: BlockContext = { searchParams, pinnedCategory }
27
+
28
+ const reservedAnchorIds = reserveAnchorIds(blocks)
29
+ const takenAnchorIds = new Set<string>()
30
+
26
31
  return (
27
- <div className="space-y-16">
28
- {blocks.map((block: PageBuilderBlock) => (
29
- <PageBuilderNode
30
- key={block._key}
31
- block={block}
32
- searchParams={searchParams}
33
- pinnedCategory={pinnedCategory}
34
- />
35
- ))}
36
- </div>
37
- )
38
- }
32
+ <>
33
+ {blocks.map((block: PageBuilderBlock) => {
34
+ const entry = getBlockEntry(block._type)
39
35
 
40
- function PageBuilderNode({
41
- block,
42
- searchParams,
43
- pinnedCategory,
44
- }: {
45
- block: PageBuilderBlock
46
- searchParams: ContentCollectionSearchParams
47
- pinnedCategory: PinnedCollectionCategory
48
- }) {
49
- switch (block._type) {
50
- case "blogCollection":
51
- return (
52
- <ContentCollection
53
- block={block}
54
- searchParams={searchParams}
55
- pinnedCategory={pinnedCategory}
56
- />
57
- )
58
- case "blogContent":
59
- return <ArticleContent block={block} />
60
- case "hero":
61
- return <Hero block={block} />
62
- case "description":
63
- return <Description block={block} />
64
- case "richTextBlock":
65
- return <RichTextBlock block={block} />
66
- case "gatedContent":
67
- return <GatedContent block={block} />
68
- default:
69
- return null
70
- }
36
+ // No entry means the content is ahead of the generated types.
37
+ if (!entry || entry.isEmpty?.(block)) return null
38
+
39
+ return (
40
+ <Section
41
+ anchorId={resolveAnchorId(
42
+ block,
43
+ takenAnchorIds,
44
+ reservedAnchorIds
45
+ )}
46
+ key={block._key}
47
+ presentation={block.presentation}
48
+ >
49
+ {entry.render(block, context)}
50
+ </Section>
51
+ )
52
+ })}
53
+ </>
54
+ )
71
55
  }
@@ -0,0 +1,35 @@
1
+ import type { ReactNode } from "react"
2
+ import { spacingPaddingValue } from "@/lib/integrations/sanity/schemas/shared/spacing"
3
+ import { cn } from "@/lib/styles/cn"
4
+
5
+ export type SectionPresentation = {
6
+ paddingTop?: string | null
7
+ paddingBottom?: string | null
8
+ } | null
9
+
10
+ type SectionProps = {
11
+ anchorId?: string | null | undefined
12
+ presentation?: SectionPresentation | undefined
13
+ className?: string | undefined
14
+ children: ReactNode
15
+ }
16
+
17
+ export function Section({
18
+ anchorId,
19
+ presentation,
20
+ className,
21
+ children,
22
+ }: SectionProps) {
23
+ return (
24
+ <section
25
+ id={anchorId || undefined}
26
+ style={{
27
+ paddingTop: spacingPaddingValue(presentation?.paddingTop),
28
+ paddingBottom: spacingPaddingValue(presentation?.paddingBottom),
29
+ }}
30
+ className={cn(anchorId && "scroll-mt-24", className)}
31
+ >
32
+ {children}
33
+ </section>
34
+ )
35
+ }
@@ -90,7 +90,7 @@ export const PageDocument = ({
90
90
  // Editor-selected page-level structured data (FAQ, Event, custom, etc.).
91
91
  const pageJsonLd = buildPageJsonLd(page.metadata?.jsonLd)
92
92
 
93
- // Blog posts (pages with a Blog Content block) emit Article JSON-LD with
93
+ // Blog posts (pages with a Blog Posts block) emit Article JSON-LD with
94
94
  // fields derived from the post — no Custom block needed. Skipped when the
95
95
  // editor already supplied an Article (via a Custom block) to avoid duplicates.
96
96
  const blogBlock = page.pageBuilder?.find(
@@ -132,7 +132,7 @@ export const PageDocument = ({
132
132
  {pageJsonLd.map(({ key, data }) => (
133
133
  <JsonLd key={key} data={data} />
134
134
  ))}
135
- <article className="mx-auto flex w-full max-w-6xl flex-1 flex-col gap-14 px-4 py-14 md:px-6 md:py-20">
135
+ <article className="mx-auto flex w-full max-w-6xl flex-1 flex-col px-4 py-14 md:px-6 md:py-20">
136
136
  <h1>{title}</h1>
137
137
  {sections.length ? (
138
138
  sections