@charisol/plexo-sdk 1.4.42 → 2.0.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.
Files changed (255) hide show
  1. package/README.md +72 -0
  2. package/dist/InlineColorPicker-8ewm1Asx.js +2912 -0
  3. package/dist/client-DlVJt_6V.js +339 -0
  4. package/dist/colorUtils-ohNG3v1i.js +222 -0
  5. package/dist/columnOrder-f5-VOg2T.js +11 -0
  6. package/dist/{compiler-BvseEhDC.js → compiler-Dhpsq71h.js} +121 -120
  7. package/dist/compiler.js +1 -1
  8. package/dist/{compilerClient-BIrZIgfG.js → compilerClient-BC4TGAr9.js} +93 -92
  9. package/dist/compilerClient.js +1 -1
  10. package/dist/{iconSvgStatic-CGue7nyp.js → iconSvgStatic-Lnpg27U9.js} +66 -75
  11. package/dist/index.js +14042 -15423
  12. package/dist/legacy-B4E71HSa.js +16192 -0
  13. package/dist/lint-D-2x-Yeb.js +225 -0
  14. package/dist/{mjmlBrowser-DWk0mRD6.js → mjmlBrowser-wlHcAT8n.js} +2 -2
  15. package/dist/plexo-sdk.css +1 -1
  16. package/dist/rolldown-runtime-B1bRi_D7.js +27 -0
  17. package/dist/sanitize.js +1 -1
  18. package/dist/{sanitizeCompiledHtml-CNjUXlMK.js → sanitizeCompiledHtml-GgGsetm3.js} +673 -698
  19. package/dist/{zoom-in-DL4pfiLG.js → schemas-Bq5o5MfF.js} +916 -2120
  20. package/dist/utilities/colorUtils.d.ts +35 -0
  21. package/dist/utilities/playground.interfaces.d.ts +19 -1
  22. package/dist/v2/V2Editor.d.ts +25 -0
  23. package/dist/v2/compile/build.d.ts +38 -0
  24. package/dist/v2/compile/html.d.ts +18 -0
  25. package/dist/v2/compile/index.d.ts +28 -15
  26. package/dist/v2/compile/react.d.ts +17 -0
  27. package/dist/v2/compile/schema.d.ts +16 -0
  28. package/dist/v2/components/canvas/AlignmentGuidesOverlay.d.ts +7 -0
  29. package/dist/v2/components/canvas/CanvasArea.d.ts +2 -0
  30. package/dist/v2/components/canvas/CanvasControls.d.ts +2 -0
  31. package/dist/v2/components/canvas/ContextualToolbar.d.ts +7 -0
  32. package/dist/v2/components/canvas/DropIndicator.d.ts +6 -0
  33. package/dist/v2/components/canvas/IrView.d.ts +12 -0
  34. package/dist/v2/components/canvas/NodeRenderer.d.ts +12 -0
  35. package/dist/v2/components/canvas/PageFrame.d.ts +9 -0
  36. package/dist/v2/components/canvas/ResizeHandles.d.ts +8 -0
  37. package/dist/v2/components/canvas/SectionToolbar.d.ts +6 -0
  38. package/dist/v2/components/canvas/SpacingOverlay.d.ts +7 -0
  39. package/dist/v2/components/design/AutoUpdateWatcher.d.ts +7 -0
  40. package/dist/v2/components/design/DesignSystemPanel.d.ts +7 -0
  41. package/dist/v2/components/design/ReviewView.d.ts +7 -0
  42. package/dist/v2/components/design/StrataCard.d.ts +8 -0
  43. package/dist/v2/components/design/TidyView.d.ts +15 -0
  44. package/dist/v2/components/design/bits.d.ts +20 -0
  45. package/dist/v2/components/design/useStrataSync.d.ts +51 -0
  46. package/dist/v2/components/layout/ContextMenu.d.ts +2 -0
  47. package/dist/v2/components/layout/EditorShell.d.ts +2 -0
  48. package/dist/v2/components/layout/LeftToolRail.d.ts +2 -0
  49. package/dist/v2/components/layout/PreviewOverlay.d.ts +6 -0
  50. package/dist/v2/components/layout/TopToolbar.d.ts +8 -0
  51. package/dist/v2/components/modals/SettingsModal.d.ts +7 -0
  52. package/dist/v2/components/modals/ShortcutsModal.d.ts +7 -0
  53. package/dist/v2/components/properties/ColorField.d.ts +14 -0
  54. package/dist/v2/components/properties/ElementSettings.d.ts +39 -0
  55. package/dist/v2/components/properties/LinkField.d.ts +26 -0
  56. package/dist/v2/components/properties/PageInspector.d.ts +2 -0
  57. package/dist/v2/components/properties/PropertiesPanel.d.ts +2 -0
  58. package/dist/v2/components/properties/SectionSettings.d.ts +6 -0
  59. package/dist/v2/components/properties/sections/ConstraintsSection.d.ts +7 -0
  60. package/dist/v2/components/properties/sections/LayoutDiagnostics.d.ts +7 -0
  61. package/dist/v2/components/sections/BlockInspector.d.ts +9 -0
  62. package/dist/v2/components/sections/FieldForm.d.ts +14 -0
  63. package/dist/v2/components/sections/ManagedChildNotice.d.ts +7 -0
  64. package/dist/v2/components/sections/SectionThumb.d.ts +11 -0
  65. package/dist/v2/components/sidebar/FlyoutDrawer.d.ts +2 -0
  66. package/dist/v2/components/sidebar/InsertPanel.d.ts +2 -0
  67. package/dist/v2/components/sidebar/LayersPanel.d.ts +2 -0
  68. package/dist/v2/components/sidebar/LibraryPanel.d.ts +3 -0
  69. package/dist/v2/components/sidebar/PagesPanel.d.ts +2 -0
  70. package/dist/v2/components/sidebar/SectionsPanel.d.ts +6 -0
  71. package/dist/v2/components/sidebar/SolPanel.d.ts +3 -0
  72. package/dist/v2/components/sidebar/TemplateChooser.d.ts +13 -0
  73. package/dist/v2/context/BlockContext.d.ts +7 -0
  74. package/dist/v2/context/EditorContext.d.ts +213 -0
  75. package/dist/v2/context/FrameContext.d.ts +3 -0
  76. package/dist/v2/context/ParentLayoutContext.d.ts +10 -0
  77. package/dist/v2/context/PlacementContext.d.ts +4 -0
  78. package/dist/v2/data/blankPage.d.ts +3 -0
  79. package/dist/v2/data/insertableComponents.d.ts +17 -0
  80. package/dist/v2/data/samplePageData.d.ts +3 -0
  81. package/dist/v2/design/audit.d.ts +78 -0
  82. package/dist/v2/design/baseline.d.ts +3 -0
  83. package/dist/v2/design/baselineData.d.ts +3 -0
  84. package/dist/v2/design/components.d.ts +9 -0
  85. package/dist/v2/design/css.d.ts +16 -0
  86. package/dist/v2/design/fonts.d.ts +10 -0
  87. package/dist/v2/design/index.d.ts +11 -0
  88. package/dist/v2/design/lint.d.ts +22 -0
  89. package/dist/v2/design/shades.d.ts +15 -0
  90. package/dist/v2/design/textStyles.d.ts +29 -0
  91. package/dist/v2/design/themes.d.ts +35 -0
  92. package/dist/v2/design/tokens.d.ts +24 -0
  93. package/dist/v2/design/types.d.ts +81 -0
  94. package/dist/v2/host/HostContext.d.ts +176 -0
  95. package/dist/v2/host/SolMark.d.ts +8 -0
  96. package/dist/v2/index.d.ts +19 -11
  97. package/dist/v2/migrate/legacy.d.ts +26 -0
  98. package/dist/v2/render/adapt.d.ts +12 -0
  99. package/dist/v2/render/anchors.d.ts +7 -0
  100. package/dist/v2/render/elementCss.d.ts +7 -0
  101. package/dist/v2/render/elementProps.d.ts +92 -0
  102. package/dist/v2/render/elements.d.ts +32 -0
  103. package/dist/v2/render/formAction.d.ts +33 -0
  104. package/dist/v2/render/frames.d.ts +10 -0
  105. package/dist/v2/render/iconSet.d.ts +5 -0
  106. package/dist/v2/render/ir.d.ts +20 -0
  107. package/dist/v2/render/nodeStyle.d.ts +24 -0
  108. package/dist/v2/render/placement.d.ts +12 -0
  109. package/dist/v2/render/resolve.d.ts +3 -0
  110. package/dist/v2/render/runtime.d.ts +18 -0
  111. package/dist/v2/render/sanitize.d.ts +15 -0
  112. package/dist/v2/render/socialIcons.d.ts +83 -0
  113. package/dist/v2/sections/catalog/about.d.ts +2 -0
  114. package/dist/v2/sections/catalog/announcement.d.ts +2 -0
  115. package/dist/v2/sections/catalog/contact.d.ts +2 -0
  116. package/dist/v2/sections/catalog/cta.d.ts +2 -0
  117. package/dist/v2/sections/catalog/faq.d.ts +2 -0
  118. package/dist/v2/sections/catalog/features.d.ts +2 -0
  119. package/dist/v2/sections/catalog/footer.d.ts +5 -0
  120. package/dist/v2/sections/catalog/gallery.d.ts +2 -0
  121. package/dist/v2/sections/catalog/header.d.ts +2 -0
  122. package/dist/v2/sections/catalog/hero.d.ts +2 -0
  123. package/dist/v2/sections/catalog/logos.d.ts +2 -0
  124. package/dist/v2/sections/catalog/pricing.d.ts +2 -0
  125. package/dist/v2/sections/catalog/stats.d.ts +2 -0
  126. package/dist/v2/sections/catalog/steps.d.ts +2 -0
  127. package/dist/v2/sections/catalog/team.d.ts +2 -0
  128. package/dist/v2/sections/catalog/testimonials.d.ts +2 -0
  129. package/dist/v2/sections/catalog/video.d.ts +2 -0
  130. package/dist/v2/sections/kit.d.ts +64 -0
  131. package/dist/v2/sections/materialize.d.ts +72 -0
  132. package/dist/v2/sections/names.d.ts +6 -0
  133. package/dist/v2/sections/pageTemplates.d.ts +52 -0
  134. package/dist/v2/sections/registry.d.ts +5 -0
  135. package/dist/v2/sections/types.d.ts +103 -0
  136. package/dist/v2/sol/catalogSchema.d.ts +43 -0
  137. package/dist/v2/sol/commands.d.ts +21 -0
  138. package/dist/v2/sol/describe.d.ts +32 -0
  139. package/dist/v2/sol/index.d.ts +7 -0
  140. package/dist/v2/sol/parse.d.ts +10 -0
  141. package/dist/v2/sol/prompt.d.ts +5 -0
  142. package/dist/v2/sol/schema.d.ts +177 -0
  143. package/dist/v2/sol/summarize.d.ts +4 -0
  144. package/dist/v2/strata/autoUpdate.d.ts +37 -0
  145. package/dist/v2/strata/client.d.ts +38 -0
  146. package/dist/v2/strata/index.d.ts +8 -0
  147. package/dist/v2/strata/merge.d.ts +27 -0
  148. package/dist/v2/strata/types.d.ts +115 -0
  149. package/dist/v2/types/editor.d.ts +175 -0
  150. package/dist/v2/utils/css.d.ts +3 -0
  151. package/dist/v2/utils/id.d.ts +3 -0
  152. package/dist/v2-compile.js +138 -7
  153. package/dist/v2-strata.js +2 -0
  154. package/dist/v2.js +11089 -8174
  155. package/package.json +6 -1
  156. package/dist/toReact-BBzjWoFG.js +0 -595
  157. package/dist/v2/ai/commands.d.ts +0 -616
  158. package/dist/v2/ai/dispatch.d.ts +0 -24
  159. package/dist/v2/ai/nodeSchema.d.ts +0 -196
  160. package/dist/v2/brand/BrandColorSwatches.d.ts +0 -4
  161. package/dist/v2/brand/BrandPanel.d.ts +0 -4
  162. package/dist/v2/brand/ChangeSetGallery.d.ts +0 -10
  163. package/dist/v2/brand/StyleSetEditor.d.ts +0 -22
  164. package/dist/v2/canvas/CatalogDragContext.d.ts +0 -27
  165. package/dist/v2/canvas/ContextMenuContext.d.ts +0 -16
  166. package/dist/v2/canvas/DeviceModeContext.d.ts +0 -20
  167. package/dist/v2/canvas/DragEngineContext.d.ts +0 -13
  168. package/dist/v2/canvas/LayoutGuideContext.d.ts +0 -22
  169. package/dist/v2/canvas/PreviewModeContext.d.ts +0 -15
  170. package/dist/v2/canvas/SidebarContext.d.ts +0 -21
  171. package/dist/v2/canvas/StylePainterContext.d.ts +0 -19
  172. package/dist/v2/canvas/WorkspaceThemeContext.d.ts +0 -19
  173. package/dist/v2/canvas/aiTextTransforms.d.ts +0 -24
  174. package/dist/v2/canvas/animationPresets.d.ts +0 -12
  175. package/dist/v2/canvas/constants.d.ts +0 -6
  176. package/dist/v2/canvas/layoutRoles.d.ts +0 -12
  177. package/dist/v2/canvas/modelRect.d.ts +0 -4
  178. package/dist/v2/canvas/rectMath.d.ts +0 -34
  179. package/dist/v2/canvas/reorderMath.d.ts +0 -8
  180. package/dist/v2/canvas/resizeMath.d.ts +0 -16
  181. package/dist/v2/canvas/resolveBoxStyle.d.ts +0 -12
  182. package/dist/v2/canvas/resolveTargetSection.d.ts +0 -10
  183. package/dist/v2/canvas/sectionDividerShapes.d.ts +0 -12
  184. package/dist/v2/canvas/snapping.d.ts +0 -28
  185. package/dist/v2/canvas/useAlignNode.d.ts +0 -10
  186. package/dist/v2/canvas/useClipboardKeyBinding.d.ts +0 -7
  187. package/dist/v2/canvas/useDeleteKeyBinding.d.ts +0 -3
  188. package/dist/v2/canvas/useDragEngine.d.ts +0 -44
  189. package/dist/v2/canvas/useDraggableNode.d.ts +0 -30
  190. package/dist/v2/canvas/useInlineTextEdit.d.ts +0 -29
  191. package/dist/v2/canvas/usePointerEngine.d.ts +0 -22
  192. package/dist/v2/canvas/useResizeHandle.d.ts +0 -12
  193. package/dist/v2/canvas/useResolvedTextStyles.d.ts +0 -13
  194. package/dist/v2/canvas/useSelectionRects.d.ts +0 -13
  195. package/dist/v2/canvas/useUndoRedoKeyBinding.d.ts +0 -8
  196. package/dist/v2/catalog/elementCatalog.d.ts +0 -31
  197. package/dist/v2/catalog/imagePreset.d.ts +0 -7
  198. package/dist/v2/compile/toReact.d.ts +0 -32
  199. package/dist/v2/components/AdornmentLayer.d.ts +0 -20
  200. package/dist/v2/components/AskSolPanel.d.ts +0 -25
  201. package/dist/v2/components/CatalogDragGhost.d.ts +0 -6
  202. package/dist/v2/components/CellBoundary.d.ts +0 -14
  203. package/dist/v2/components/CenterCanvas.d.ts +0 -3
  204. package/dist/v2/components/ContentTabPanel.d.ts +0 -12
  205. package/dist/v2/components/ContextMenu.d.ts +0 -5
  206. package/dist/v2/components/ContextualToolbar.d.ts +0 -25
  207. package/dist/v2/components/ImagesTabPanel.d.ts +0 -15
  208. package/dist/v2/components/LayoutGuidePanel.d.ts +0 -10
  209. package/dist/v2/components/ManageLayersPanel.d.ts +0 -13
  210. package/dist/v2/components/NodeRenderer.d.ts +0 -8
  211. package/dist/v2/components/PreviewOverlay.d.ts +0 -11
  212. package/dist/v2/components/ResizeHandle.d.ts +0 -6
  213. package/dist/v2/components/RightRail.d.ts +0 -13
  214. package/dist/v2/components/SectionDividerOverlay.d.ts +0 -8
  215. package/dist/v2/components/SectionEdgeAddZone.d.ts +0 -17
  216. package/dist/v2/components/SectionGridOverlay.d.ts +0 -10
  217. package/dist/v2/components/SectionNamePill.d.ts +0 -6
  218. package/dist/v2/components/SectionNode.d.ts +0 -5
  219. package/dist/v2/components/SectionSideRail.d.ts +0 -17
  220. package/dist/v2/components/SelectionToolbar.d.ts +0 -11
  221. package/dist/v2/components/StylePainterToast.d.ts +0 -5
  222. package/dist/v2/components/V2Canvas.d.ts +0 -59
  223. package/dist/v2/components/nodes/ButtonNode.d.ts +0 -4
  224. package/dist/v2/components/nodes/ContainerNode.d.ts +0 -11
  225. package/dist/v2/components/nodes/EmbedNode.d.ts +0 -4
  226. package/dist/v2/components/nodes/ImageNode.d.ts +0 -4
  227. package/dist/v2/components/nodes/InputNode.d.ts +0 -4
  228. package/dist/v2/components/nodes/MenuNode.d.ts +0 -18
  229. package/dist/v2/components/nodes/TextNode.d.ts +0 -4
  230. package/dist/v2/inspector/AiQuickEditPanel.d.ts +0 -12
  231. package/dist/v2/inspector/AnimationPanel.d.ts +0 -11
  232. package/dist/v2/inspector/DesignAccordions.d.ts +0 -7
  233. package/dist/v2/inspector/FieldRenderer.d.ts +0 -9
  234. package/dist/v2/inspector/IconPopoverButton.d.ts +0 -9
  235. package/dist/v2/inspector/MenuIconPanel.d.ts +0 -7
  236. package/dist/v2/inspector/MenuManagePanel.d.ts +0 -8
  237. package/dist/v2/inspector/Popover.d.ts +0 -21
  238. package/dist/v2/inspector/SectionDividerPanel.d.ts +0 -9
  239. package/dist/v2/inspector/fieldStyles.d.ts +0 -15
  240. package/dist/v2/inspector/fields/ColorField.d.ts +0 -7
  241. package/dist/v2/inspector/fields/NumberField.d.ts +0 -7
  242. package/dist/v2/inspector/fields/SelectField.d.ts +0 -7
  243. package/dist/v2/inspector/fields/TextField.d.ts +0 -7
  244. package/dist/v2/inspector/fields/TextStyleField.d.ts +0 -11
  245. package/dist/v2/inspector/fields/TextareaField.d.ts +0 -7
  246. package/dist/v2/inspector/schema.d.ts +0 -25
  247. package/dist/v2/inspector/useFieldCommit.d.ts +0 -12
  248. package/dist/v2/store/brandDefaults.d.ts +0 -4
  249. package/dist/v2/store/brandTypes.d.ts +0 -40
  250. package/dist/v2/store/cloneSubtree.d.ts +0 -12
  251. package/dist/v2/store/createBrandStore.d.ts +0 -2
  252. package/dist/v2/store/createCanvasStore.d.ts +0 -2
  253. package/dist/v2/store/seed.d.ts +0 -17
  254. package/dist/v2/store/types.d.ts +0 -163
  255. package/dist/v2/ui/theme.d.ts +0 -85
@@ -0,0 +1,15 @@
1
+ export declare const escapeHtml: (s: string) => string;
2
+ export declare const escapeAttr: (s: string) => string;
3
+ /** A link target: http(s), mailto/tel/sms, or a page-relative address. Anything else (javascript:, data:…) becomes "#". */
4
+ export declare function safeHref(value: unknown): string;
5
+ /** An image address: http(s), relative, or an embedded raster/SVG image. Empty/unsafe → '' (the builders show a placeholder). */
6
+ export declare function safeImageSrc(value: unknown): string;
7
+ /** A CSS colour: hex, rgb()/hsl() with plain numbers, or a named colour. Otherwise undefined. */
8
+ export declare function safeColor(value: unknown): string | undefined;
9
+ /** Space-separated class names made only of letters, digits and `_ - : / [ ] . % # !` — enough for utility classes, no quotes or spaces inside a token. */
10
+ export declare function safeClassList(value: unknown): string;
11
+ /** An identifier safe for ids, form field names and class suffixes. */
12
+ export declare const safeIdent: (value: unknown, fallback?: string) => string;
13
+ export declare const clampInt: (value: unknown, min: number, max: number, fallback: number) => number;
14
+ export declare const asString: (value: unknown, max?: number) => string;
15
+ export declare const asArray: <T>(value: unknown, max?: number) => T[];
@@ -0,0 +1,83 @@
1
+ export interface SocialIcon {
2
+ label: string;
3
+ /** SVG path on a 24×24 grid. */
4
+ path: string;
5
+ /** Drawn as a stroked outline instead of a filled glyph. */
6
+ outline?: boolean;
7
+ brand: string;
8
+ }
9
+ export declare const SOCIAL_ICONS: {
10
+ facebook: {
11
+ label: string;
12
+ path: string;
13
+ brand: string;
14
+ };
15
+ instagram: {
16
+ label: string;
17
+ path: string;
18
+ brand: string;
19
+ };
20
+ x: {
21
+ label: string;
22
+ path: string;
23
+ brand: string;
24
+ };
25
+ linkedin: {
26
+ label: string;
27
+ path: string;
28
+ brand: string;
29
+ };
30
+ youtube: {
31
+ label: string;
32
+ path: string;
33
+ brand: string;
34
+ };
35
+ tiktok: {
36
+ label: string;
37
+ path: string;
38
+ brand: string;
39
+ };
40
+ whatsapp: {
41
+ label: string;
42
+ path: string;
43
+ brand: string;
44
+ };
45
+ github: {
46
+ label: string;
47
+ path: string;
48
+ brand: string;
49
+ };
50
+ pinterest: {
51
+ label: string;
52
+ path: string;
53
+ brand: string;
54
+ };
55
+ telegram: {
56
+ label: string;
57
+ path: string;
58
+ brand: string;
59
+ };
60
+ threads: {
61
+ label: string;
62
+ path: string;
63
+ brand: string;
64
+ };
65
+ discord: {
66
+ label: string;
67
+ path: string;
68
+ brand: string;
69
+ };
70
+ email: {
71
+ label: string;
72
+ path: string;
73
+ outline: true;
74
+ brand: string;
75
+ };
76
+ website: {
77
+ label: string;
78
+ path: string;
79
+ outline: true;
80
+ brand: string;
81
+ };
82
+ };
83
+ export type SocialNetwork = keyof typeof SOCIAL_ICONS;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const about: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const announcement: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const contact: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const cta: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const faq: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const features: KindDef;
@@ -0,0 +1,5 @@
1
+ import type { MenuLink } from '../../render/elementProps';
2
+ import type { KindDef } from '../types';
3
+ /** Turns “Name | /page” lines into links. A line without an address still shows, pointing nowhere yet. */
4
+ export declare function parseLinks(raw: unknown): MenuLink[];
5
+ export declare const footer: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const gallery: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const header: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const hero: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const logos: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const pricing: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const stats: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const steps: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const team: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const testimonials: KindDef;
@@ -0,0 +1,2 @@
1
+ import type { KindDef } from '../types';
2
+ export declare const video: KindDef;
@@ -0,0 +1,64 @@
1
+ import type { DocumentNode, ElementStyles } from '../types/editor';
2
+ import type { TextStyleId } from '../design/textStyles';
3
+ import type { BuildCtx, SectionBackground, Tone } from './types';
4
+ /** The colours text should use on each kind of background, all by reference to the design system. */
5
+ export declare function toneFor(background: SectionBackground): Tone;
6
+ type Styles = Partial<ElementStyles>;
7
+ type Kids = Array<DocumentNode | null | false | undefined>;
8
+ export type ButtonVariant = 'primary' | 'secondary' | 'ghost';
9
+ /**
10
+ * The words layouts are written in. Every node gets a stable id from the section's id and a slot name, so editing a section
11
+ * keeps the selection (and any unsaved typing) on the same element, and a node can be traced back to the content field it shows.
12
+ */
13
+ export declare function kit(ctx: BuildCtx): {
14
+ id: (slot: string) => string;
15
+ box: (slot: string, children: Kids, styles?: Styles, extra?: Partial<DocumentNode>) => DocumentNode;
16
+ container: (children: Kids, styles?: Styles) => DocumentNode;
17
+ stack: (slot: string, children: Kids, o?: {
18
+ gap?: string;
19
+ align?: "flex-start" | "center" | "flex-end" | "stretch";
20
+ styles?: Styles;
21
+ }) => DocumentNode;
22
+ row: (slot: string, children: Kids, o?: {
23
+ gap?: string;
24
+ align?: "flex-start" | "center" | "flex-end" | "stretch";
25
+ justify?: "flex-start" | "center" | "flex-end" | "space-between";
26
+ wrap?: boolean;
27
+ stack?: boolean;
28
+ styles?: Styles;
29
+ }) => DocumentNode;
30
+ grid: (slot: string, children: Kids, cols?: [number, number, number], o?: {
31
+ gap?: string;
32
+ styles?: Styles;
33
+ }) => DocumentNode;
34
+ split: (slot: string, left: DocumentNode, right: DocumentNode, o?: {
35
+ ratio?: [number, number];
36
+ gap?: string;
37
+ align?: "flex-start" | "center" | "stretch";
38
+ }) => DocumentNode;
39
+ text: (path: string, value: unknown, style: TextStyleId, o?: {
40
+ color?: string;
41
+ align?: "left" | "center" | "right";
42
+ maxWidth?: string;
43
+ styles?: Styles;
44
+ }) => DocumentNode | null;
45
+ button: (path: string, field: unknown, variant?: ButtonVariant) => DocumentNode | null;
46
+ image: (path: string, src: unknown, alt: unknown, o?: {
47
+ ratio?: string;
48
+ radius?: string;
49
+ fit?: "cover" | "contain";
50
+ styles?: Styles;
51
+ }) => DocumentNode;
52
+ icon: (path: string, name: unknown, o?: {
53
+ size?: string;
54
+ color?: string;
55
+ circle?: boolean;
56
+ styles?: Styles;
57
+ }) => DocumentNode;
58
+ card: (slot: string, children: Kids, styles?: Styles) => DocumentNode;
59
+ divider: (slot: string) => DocumentNode;
60
+ tone: Tone;
61
+ align: "left" | "center";
62
+ };
63
+ export type Kit = ReturnType<typeof kit>;
64
+ export {};
@@ -0,0 +1,72 @@
1
+ import type { DocumentNode } from '../types/editor';
2
+ import type { BlockSpec, BlockStyle, NodeOverride } from './types';
3
+ export declare function blockOf(node: DocumentNode | null | undefined): BlockSpec | null;
4
+ /** A new block with realistic starter content, in the layout asked for (or the kind's first). */
5
+ export declare function defaultBlock(kind: BlockSpec['kind'], variant?: string): BlockSpec;
6
+ /** An element's slot: its id without the section's prefix (the part that stays the same when the section is rebuilt). */
7
+ export declare const SECTION_SLOT = "@section";
8
+ export declare const slotOf: (sectionId: string, nodeId: string) => string;
9
+ /** The hidden field that gives a list item an identity of its own, so its tweaks follow it when the list changes. */
10
+ export declare const ITEM_KEY = "_key";
11
+ /**
12
+ * Makes sure every list item (at any depth) has a unique id. Items from before ids existed take their position as id
13
+ * (which is exactly what their saved tweaks were keyed by, so old designs keep working and the result is deterministic);
14
+ * an item added to a list that already has ids gets a fresh one; a copied item (same id twice) gets a new id.
15
+ * Returns the same object when nothing needed adding.
16
+ */
17
+ export declare function ensureItemKeys<T>(value: T): T;
18
+ /**
19
+ * An element's tweak key: its slot, with list positions swapped for the item's id (`items-2-question` -> `items-@k3-question`).
20
+ * Already-canonical and non-list slots pass through unchanged.
21
+ */
22
+ export declare function canonicalSlot(slot: string, content: unknown): string;
23
+ /** The section node for a block: its styles, and its contents built from the block. Ids derive from `sectionId`, so rebuilding is stable. */
24
+ export declare function buildSection(input: BlockSpec, sectionId?: string): DocumentNode;
25
+ /** Rebuilds a block section from its (possibly just-edited) block, keeping its id. */
26
+ export declare function rematerialize(section: DocumentNode): DocumentNode;
27
+ /** Sets a value at a path like `items.2.title`, immutably, creating what's missing. */
28
+ export declare function setAt<T>(root: T, path: string, value: unknown): T;
29
+ export declare function getAt(root: unknown, path: string): unknown;
30
+ export declare const withBlock: (section: DocumentNode, next: BlockSpec) => DocumentNode;
31
+ export declare function setBlockContent(section: DocumentNode, path: string, value: unknown): DocumentNode;
32
+ export declare function setBlockContentAll(section: DocumentNode, patch: Record<string, unknown>): DocumentNode;
33
+ /** Changes the layout, keeping every word. If the new layout suits a different background, the section follows it unless the person chose one. */
34
+ export declare function setBlockVariant(section: DocumentNode, variant: string): DocumentNode;
35
+ export declare function setBlockStyle(section: DocumentNode, patch: Partial<BlockStyle>): DocumentNode;
36
+ /** Turns a managed section into ordinary elements the person can place and style freely. */
37
+ export declare function detachBlock(section: DocumentNode): DocumentNode;
38
+ /** The managed section a node lives in (null if it isn't inside one, or is the section itself). */
39
+ export declare function findBlockSection(root: DocumentNode, nodeId: string): DocumentNode | null;
40
+ export type BoundEdit = {
41
+ content?: string;
42
+ href?: string;
43
+ src?: string;
44
+ alt?: string;
45
+ iconName?: string;
46
+ };
47
+ /**
48
+ * If `nodeId` is a bound element of a managed section, applies an edit made to it (typing, replacing a picture) to the
49
+ * section's content and rebuilds the section; returns the new tree. Returns null when the node isn't bound, so the caller
50
+ * handles it as an ordinary edit.
51
+ */
52
+ export declare function applyBoundEdit(root: DocumentNode, nodeId: string, edit: BoundEdit): DocumentNode | null;
53
+ /** Where a tweak to this element is stored: its slot, following list items by id rather than position. */
54
+ export declare function overrideKey(section: DocumentNode, nodeId: string): string;
55
+ /** Merges a change to one element of a managed section into that element's tweaks, and rebuilds the section. */
56
+ export declare function setBlockOverride(section: DocumentNode, nodeId: string, patch: NodeOverride): DocumentNode;
57
+ /** Forgets the tweaks on one element (or all of them), putting the section back to how it was designed. */
58
+ export declare function resetBlockOverrides(section: DocumentNode, nodeId?: string): DocumentNode;
59
+ /** How many elements of the section currently carry a tweak (tweaks for pieces this layout doesn't have are kept, but not counted). */
60
+ export declare const countOverrides: (section: DocumentNode) => number;
61
+ /** The managed section that owns a node for the purpose of tweaking: the node's section, or the node itself when it is one. */
62
+ export declare function tweakTarget(root: DocumentNode, nodeId: string): DocumentNode | null;
63
+ /**
64
+ * If `nodeId` is inside a managed section (or is one), applies a style/visibility change made to it as a tweak — kept
65
+ * across rebuilds, so a designer's changes survive edits to the words or a switch of layout — and returns the new tree;
66
+ * null when the node isn't managed, so the caller edits it normally.
67
+ */
68
+ export declare function applyBlockTweak(root: DocumentNode, nodeId: string, patch: NodeOverride): DocumentNode | null;
69
+ /** True when the node is an element inside a managed section (so it can't be moved, duplicated or restructured — only tweaked). */
70
+ export declare const isManagedChild: (root: DocumentNode, nodeId: string) => boolean;
71
+ /** Swaps a managed section for another node (same position). */
72
+ export declare function replaceNodeById(root: DocumentNode, id: string, next: DocumentNode): DocumentNode;
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Plain-language names for the layers a section is built from. Layout code names nodes with short slots
3
+ * (`items-0-card`) or content paths (`items.2.title`); the Layers panel shows `name`, so those get translated here.
4
+ * Display only: node ids, bindings and overrides never read the name.
5
+ */
6
+ export declare function friendlyName(raw: string): string;
@@ -0,0 +1,52 @@
1
+ import type { DocumentNode, PageDefinition } from '../types/editor';
2
+ import type { DesignSystem } from '../design/types';
3
+ import type { SectionKind } from './types';
4
+ /**
5
+ * Page templates: ready-made full pages ("Home", "About", "Pricing"…) assembled from the section catalog, each section in a
6
+ * good layout and already filled with believable words. Picking one gives a site owner a complete page to edit, instead of
7
+ * a blank one — no design decisions needed. React-free, so servers (the host's "new page" route) can call it too.
8
+ */
9
+ export interface PageTemplateSection {
10
+ kind: SectionKind;
11
+ /** A layout id from the catalog (default: the kind's first). */
12
+ variant?: string;
13
+ /** Overrides on top of the kind's starter words. */
14
+ content?: Record<string, unknown>;
15
+ background?: import('./types').SectionBackground;
16
+ }
17
+ export interface PageTemplate {
18
+ id: string;
19
+ name: string;
20
+ description: string;
21
+ sections: PageTemplateSection[];
22
+ }
23
+ export declare const PAGE_TEMPLATES: PageTemplate[];
24
+ export declare const getPageTemplate: (id: string) => PageTemplate;
25
+ /** What to show on a template card: name, one line, and the section names as a little preview strip. */
26
+ export interface PageTemplateSummary {
27
+ id: string;
28
+ name: string;
29
+ description: string;
30
+ sections: string[];
31
+ }
32
+ export declare function listPageTemplates(): PageTemplateSummary[];
33
+ /**
34
+ * A stable seed for a template's ids. plexo-web's `seedFor` should combine it with the new page's own id
35
+ * (`${templateSeed(t)}-${pageId}`) and pass the result as `seed`, so two pages made from one template never share ids and
36
+ * the same request always yields the same page (safe to retry on the server).
37
+ */
38
+ export declare const templateSeed: (templateId: string) => string;
39
+ /** The sections of a template as ready-built nodes (menu and footer included), ids derived from `seed`. */
40
+ export declare function buildTemplateSections(templateId: string, opts?: {
41
+ seed?: string;
42
+ designSystem?: DesignSystem;
43
+ }): DocumentNode[];
44
+ /** True when a page has nothing on it yet (no sections, or only the empty placeholder section a new page starts with). */
45
+ export declare function isPageEmpty(root: DocumentNode): boolean;
46
+ /** A full page from a template. Pass `seed` to make its ids unique among a site's pages (see templateSeed). */
47
+ export declare function buildPageFromTemplate(templateId: string, opts: {
48
+ name: string;
49
+ designSystem?: DesignSystem;
50
+ seed?: string;
51
+ slug?: string;
52
+ }): PageDefinition;
@@ -0,0 +1,5 @@
1
+ import type { KindDef, SectionKind } from './types';
2
+ /** Every kind of section, in the order the gallery shows them. */
3
+ export declare const KINDS: KindDef[];
4
+ export declare function getKind(kind: SectionKind): KindDef;
5
+ export declare const hasKind: (kind: string) => kind is SectionKind;
@@ -0,0 +1,103 @@
1
+ import type { DocumentNode } from '../types/editor';
2
+ /**
3
+ * Sections: ready-made, editable page sections ("a hero", "pricing", "FAQ"). A section is stored as a small structured
4
+ * block — what kind it is, which layout, and its content — and the page tree under it is *derived* from that. So switching
5
+ * the layout keeps the words, editing is a plain form (or typing right on the page), the section is responsive by
6
+ * construction, and an AI can change one safely by editing its content instead of guessing at layout.
7
+ */
8
+ export type SectionKind = 'announcement' | 'header' | 'hero' | 'logos' | 'features' | 'about' | 'stats' | 'steps' | 'gallery' | 'video' | 'testimonials' | 'pricing' | 'team' | 'faq' | 'cta' | 'contact' | 'footer';
9
+ export type SectionBackground = 'canvas' | 'surface' | 'sunken' | 'primary' | 'inverted' | 'gradient' | 'image';
10
+ export interface BlockStyle {
11
+ /** Which of the brand's surfaces the section sits on. */
12
+ background?: SectionBackground;
13
+ /** For `image`: the picture behind the section (a dark layer keeps text readable). */
14
+ image?: string;
15
+ align?: 'left' | 'center';
16
+ spacing?: 'tight' | 'normal' | 'airy';
17
+ /** Header only: stay at the top while scrolling. */
18
+ pinned?: boolean;
19
+ }
20
+ /**
21
+ * A change someone made to one element inside a section (a different colour, a bigger heading, hidden on phones). Kept per
22
+ * element, apart from the content, so it survives when the words or the layout change — which is what lets a designer
23
+ * tweak a section however they like without losing the easy way to edit it.
24
+ */
25
+ export interface NodeOverride {
26
+ styles?: Partial<import('../types/editor').ElementStyles>;
27
+ responsive?: {
28
+ tablet?: Partial<import('../types/editor').ElementStyles>;
29
+ mobile?: Partial<import('../types/editor').ElementStyles>;
30
+ };
31
+ responsiveVisibility?: import('../types/editor').ResponsiveVisibility;
32
+ hidden?: boolean;
33
+ }
34
+ export interface BlockSpec {
35
+ kind: SectionKind;
36
+ variant: string;
37
+ content: Record<string, unknown>;
38
+ style?: BlockStyle;
39
+ /** Per-element tweaks, keyed by the element's slot (its id without the section prefix). */
40
+ overrides?: Record<string, NodeOverride>;
41
+ }
42
+ /** What a person edits. Drives the content form, validation, and the schema an AI works against. */
43
+ export type FieldType = 'text' | 'longtext' | 'image' | 'link' | 'button' | 'icon' | 'toggle' | 'select' | 'list';
44
+ export interface FieldDef {
45
+ key: string;
46
+ label: string;
47
+ type: FieldType;
48
+ hint?: string;
49
+ /** Longest sensible text (a limit the form shows and an AI respects). */
50
+ max?: number;
51
+ options?: Array<[value: string, label: string]>;
52
+ /** For `list`: the fields of each item, and how many items make sense. */
53
+ item?: FieldDef[];
54
+ min?: number;
55
+ limit?: number;
56
+ /** For `list`: what to call one item ("feature", "question"). */
57
+ itemName?: string;
58
+ }
59
+ /** Builds the section's contents from its block. */
60
+ export interface BuildCtx {
61
+ sectionId: string;
62
+ content: Record<string, any>;
63
+ style: Required<Pick<BlockStyle, 'align' | 'spacing'>> & BlockStyle;
64
+ /** The colours text should use on this section's background. */
65
+ tone: Tone;
66
+ }
67
+ export interface Tone {
68
+ heading: string;
69
+ body: string;
70
+ muted: string;
71
+ accent: string;
72
+ /** Border / divider colour that works on this background. */
73
+ line: string;
74
+ /** Card surface on this background. */
75
+ card: string;
76
+ onAccent: string;
77
+ inverse: boolean;
78
+ }
79
+ export interface VariantDef {
80
+ id: string;
81
+ label: string;
82
+ description: string;
83
+ /** Which content fields this layout shows (the others stay in the content but are hidden in the form). Default: all. */
84
+ uses?: string[];
85
+ /** Backgrounds that suit this layout best (the first is the default). */
86
+ backgrounds?: SectionBackground[];
87
+ /** Extra styles for the section itself (e.g. a header's bottom border). */
88
+ sectionStyles?: import('../types/editor').ElementStyles;
89
+ build(ctx: BuildCtx): DocumentNode[];
90
+ }
91
+ export interface KindDef {
92
+ kind: SectionKind;
93
+ label: string;
94
+ description: string;
95
+ /** Groups the gallery. */
96
+ group: 'Navigation' | 'Intro' | 'Content' | 'Proof' | 'Convert' | 'Footer';
97
+ /** Slim vertical padding (headers, bars, footers) instead of a full section's. */
98
+ compact?: boolean;
99
+ fields: FieldDef[];
100
+ /** Realistic starter copy, so a new section looks finished. */
101
+ defaults: Record<string, unknown>;
102
+ variants: VariantDef[];
103
+ }
@@ -0,0 +1,43 @@
1
+ import { type PageTemplateSummary } from '../sections/pageTemplates';
2
+ import type { FieldDef, SectionBackground, SectionKind } from '../sections/types';
3
+ /** One thing a person (or SOL) can fill in on a section. `path` is how a command points at it (`heading`, `items.0.title`). */
4
+ export interface SolField {
5
+ path: string;
6
+ type: FieldDef['type'];
7
+ label: string;
8
+ hint?: string;
9
+ max?: number;
10
+ options?: string[];
11
+ /** For lists: what one entry is called, how many make sense, and what each entry holds. */
12
+ itemName?: string;
13
+ min?: number;
14
+ limit?: number;
15
+ itemFields?: SolField[];
16
+ }
17
+ export interface SolVariant {
18
+ id: string;
19
+ label: string;
20
+ description: string;
21
+ fields?: string[];
22
+ backgrounds?: SectionBackground[];
23
+ }
24
+ export interface SolKind {
25
+ kind: SectionKind;
26
+ name: string;
27
+ description: string;
28
+ group: string;
29
+ variants: SolVariant[];
30
+ fields: SolField[];
31
+ }
32
+ export interface SolCatalog {
33
+ kinds: SolKind[];
34
+ /** Ready-made starting layouts for a new page (`addPage` with a `templateId`). */
35
+ pageTemplates: PageTemplateSummary[];
36
+ style: {
37
+ background: SectionBackground[];
38
+ align: string[];
39
+ spacing: string[];
40
+ };
41
+ }
42
+ /** Every kind of section, its layouts and what can be written in it. Derived from the registry, so it never drifts from what the editor can build. */
43
+ export declare function catalogSchema(): SolCatalog;
@@ -0,0 +1,21 @@
1
+ import type { DocumentNode, PageDefinition } from '../types/editor';
2
+ import type { DesignSystem } from '../design/types';
3
+ import { type CommandResult } from './schema';
4
+ export type { CommandResult, SolCommand } from './schema';
5
+ /** Builds the starting sections for a named page template, or null if there is no such template. */
6
+ export type PageTemplateResolver = (templateId: string) => DocumentNode[] | null;
7
+ /** Replaces the page-template lookup (the built-in page templates by default); null turns templates off. */
8
+ export declare function setPageTemplateResolver(resolver: PageTemplateResolver | null): void;
9
+ export interface ApplyOptions {
10
+ templates?: PageTemplateResolver | null;
11
+ }
12
+ export interface ApplyResult {
13
+ pages: PageDefinition[];
14
+ designSystem: DesignSystem;
15
+ results: CommandResult[];
16
+ }
17
+ /**
18
+ * Applies SOL's suggested changes. Pure and immutable; never throws. Each command is checked on its own: good ones apply,
19
+ * bad ones are reported in plain English and leave everything else untouched.
20
+ */
21
+ export declare function applyCommands(pages: PageDefinition[], designSystem: DesignSystem, commands: unknown[], opts?: ApplyOptions): ApplyResult;
@@ -0,0 +1,32 @@
1
+ import type { DocumentNode, PageDefinition } from '../types/editor';
2
+ import type { DesignSystem } from '../design/types';
3
+ export interface SolSectionSummary {
4
+ id: string;
5
+ /** Present for managed sections. */
6
+ kind?: string;
7
+ variant?: string;
8
+ /** A few words of what it says, so the model can tell sections apart. */
9
+ preview: string;
10
+ /** Designed by hand (not built from a section kind): it can be moved, copied or removed, but not edited by content. */
11
+ freeForm?: boolean;
12
+ }
13
+ export interface SolDesignSummary {
14
+ pages: Array<{
15
+ id: string;
16
+ name: string;
17
+ slug: string;
18
+ isHome?: boolean;
19
+ sections: SolSectionSummary[];
20
+ }>;
21
+ brand: {
22
+ primaryColor?: string;
23
+ secondaryColor?: string;
24
+ headingFont?: string;
25
+ bodyFont?: string;
26
+ neutrals: string;
27
+ roundness: string;
28
+ };
29
+ }
30
+ export declare function describeSection(node: DocumentNode): SolSectionSummary;
31
+ /** A compact, JSON-friendly picture of the site (pages, their sections in order, the brand) for the model to read. */
32
+ export declare function describeDesign(pages: PageDefinition[], designSystem: DesignSystem): SolDesignSummary;
@@ -0,0 +1,7 @@
1
+ export { catalogSchema, type SolCatalog, type SolKind, type SolField, type SolVariant } from './catalogSchema';
2
+ export { describeDesign, describeSection, type SolDesignSummary, type SolSectionSummary } from './describe';
3
+ export { applyCommands, setPageTemplateResolver, type ApplyOptions, type ApplyResult, type PageTemplateResolver } from './commands';
4
+ export { solCommandSchema, type SolCommand, type SolCommandOp, type CommandResult } from './schema';
5
+ export { parseSolReply, type ParsedSolReply } from './parse';
6
+ export { describeCommand } from './summarize';
7
+ export { SOL_SYSTEM_PROMPT } from './prompt';
@@ -0,0 +1,10 @@
1
+ import { type SolCommand } from './schema';
2
+ export interface ParsedSolReply {
3
+ /** What SOL said, with the commands block taken out. */
4
+ text: string;
5
+ commands: SolCommand[] | null;
6
+ /** Plain-English note when part of the suggestion couldn't be read. */
7
+ error?: string;
8
+ }
9
+ /** Pulls a fenced `plexo-commands` block out of a reply. Tolerates trailing commas and a reply cut off before the closing fence. */
10
+ export declare function parseSolReply(reply: string): ParsedSolReply;
@@ -0,0 +1,5 @@
1
+ /**
2
+ * A ready-made system prompt for the host's AI. Send it with `context.catalog` and `context.design` (both come with every
3
+ * `onAskSol` call) so SOL knows what can be built and what the site looks like right now.
4
+ */
5
+ export declare const SOL_SYSTEM_PROMPT = "You are SOL, a friendly assistant inside a website builder. The site owner is not technical: speak plainly, never mention JSON, ids, code or \"blocks\" in what you say to them.\n\nYou are given two JSON documents: \"catalog\" (every kind of section you can add, its layouts and the fields you can fill in) and \"design\" (the site's pages, their sections in order, and the brand). Only use kinds, layouts and fields that appear in the catalog, and only refer to pages and sections by the ids in \"design\".\n\nWhen the owner asks for a change, reply with one or two short, warm sentences explaining what you suggest, then a fenced block of changes like this:\n\n```plexo-commands\n[\n {\"op\": \"addSection\", \"pageId\": \"<page id>\", \"kind\": \"hero\", \"variant\": \"<layout id>\", \"content\": {\"headline\": \"...\"}, \"afterSectionId\": \"<section id>\"},\n {\"op\": \"updateSection\", \"sectionId\": \"<section id>\", \"content\": {\"heading\": \"...\"}, \"variant\": \"<layout id>\", \"style\": {\"background\": \"surface\", \"align\": \"center\", \"spacing\": \"airy\"}},\n {\"op\": \"removeSection\", \"sectionId\": \"<section id>\"},\n {\"op\": \"moveSection\", \"sectionId\": \"<section id>\", \"index\": 0},\n {\"op\": \"duplicateSection\", \"sectionId\": \"<section id>\"},\n {\"op\": \"setBrand\", \"tokens\": {\"primaryColor\": \"#1D4ED8\", \"headingFont\": \"Poppins\", \"bodyFont\": \"Inter\", \"neutrals\": \"warm\", \"roundness\": \"round\"}},\n {\"op\": \"addPage\", \"name\": \"About\", \"templateId\": \"<optional, from catalog.pageTemplates>\"},\n {\"op\": \"renamePage\", \"pageId\": \"<page id>\", \"name\": \"Our story\"}\n]\n```\n\nRules:\n- The owner always reviews and approves your changes before anything happens, so suggest them confidently, but keep each suggestion small and focused.\n- Content keys are the field paths from the catalog (\"headline\", \"items.0.title\"). A list field needs the whole list. Keep text within each field's \"max\".\n- Write real, specific copy for the owner's business; never lorem ipsum.\n- Sections marked freeForm in \"design\" were designed by hand: you may move, copy or remove them but not edit their content. Add a new section instead.\n- If you only need to answer a question or give advice, reply in plain text with no block.";