@aglyn/besigner-ui 1.0.0-beta.143
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/LICENSE +201 -0
- package/README.md +7 -0
- package/package.json +73 -0
- package/src/besigner.d.ts +88 -0
- package/src/besigner.js +89 -0
- package/src/besigner.js.map +1 -0
- package/src/index.d.ts +17 -0
- package/src/index.js +18 -0
- package/src/index.js.map +1 -0
- package/src/lib/box-styler/box-styler.d.ts +57 -0
- package/src/lib/box-styler/box-styler.js +240 -0
- package/src/lib/box-styler/box-styler.js.map +1 -0
- package/src/lib/box-styler/components/box-diagram.d.ts +89 -0
- package/src/lib/box-styler/components/box-diagram.js +661 -0
- package/src/lib/box-styler/components/box-diagram.js.map +1 -0
- package/src/lib/box-styler/components/legend.d.ts +56 -0
- package/src/lib/box-styler/components/legend.js +130 -0
- package/src/lib/box-styler/components/legend.js.map +1 -0
- package/src/lib/box-styler/components/spacing-editor.d.ts +55 -0
- package/src/lib/box-styler/components/spacing-editor.js +347 -0
- package/src/lib/box-styler/components/spacing-editor.js.map +1 -0
- package/src/lib/box-styler/constants.d.ts +17 -0
- package/src/lib/box-styler/constants.js +30 -0
- package/src/lib/box-styler/constants.js.map +1 -0
- package/src/lib/box-styler/index.d.ts +2 -0
- package/src/lib/box-styler/index.js +4 -0
- package/src/lib/box-styler/index.js.map +1 -0
- package/src/lib/box-styler/region-fills.d.ts +107 -0
- package/src/lib/box-styler/region-fills.js +139 -0
- package/src/lib/box-styler/region-fills.js.map +1 -0
- package/src/lib/box-styler/spacing-value.d.ts +104 -0
- package/src/lib/box-styler/spacing-value.js +223 -0
- package/src/lib/box-styler/spacing-value.js.map +1 -0
- package/src/lib/box-styler/types.d.ts +29 -0
- package/src/lib/box-styler/types.js +18 -0
- package/src/lib/box-styler/types.js.map +1 -0
- package/src/lib/components/accordion-list.component.d.ts +50 -0
- package/src/lib/components/accordion-list.component.js +228 -0
- package/src/lib/components/accordion-list.component.js.map +1 -0
- package/src/lib/components/add-controls.component.d.ts +22 -0
- package/src/lib/components/add-controls.component.js +50 -0
- package/src/lib/components/add-controls.component.js.map +1 -0
- package/src/lib/components/app-bar-breadcrumbs.component.d.ts +29 -0
- package/src/lib/components/app-bar-breadcrumbs.component.js +279 -0
- package/src/lib/components/app-bar-breadcrumbs.component.js.map +1 -0
- package/src/lib/components/app-bar-primary.component.d.ts +21 -0
- package/src/lib/components/app-bar-primary.component.js +108 -0
- package/src/lib/components/app-bar-primary.component.js.map +1 -0
- package/src/lib/components/app-bar-secondary.component.d.ts +21 -0
- package/src/lib/components/app-bar-secondary.component.js +94 -0
- package/src/lib/components/app-bar-secondary.component.js.map +1 -0
- package/src/lib/components/aside-panel.component.d.ts +23 -0
- package/src/lib/components/aside-panel.component.js +505 -0
- package/src/lib/components/aside-panel.component.js.map +1 -0
- package/src/lib/components/besigner-conflict-alert.component.d.ts +36 -0
- package/src/lib/components/besigner-conflict-alert.component.js +51 -0
- package/src/lib/components/besigner-conflict-alert.component.js.map +1 -0
- package/src/lib/components/besigner-dnd-context.component.d.ts +32 -0
- package/src/lib/components/besigner-dnd-context.component.js +75 -0
- package/src/lib/components/besigner-dnd-context.component.js.map +1 -0
- package/src/lib/components/besigner-draft-alert.component.d.ts +70 -0
- package/src/lib/components/besigner-draft-alert.component.js +155 -0
- package/src/lib/components/besigner-draft-alert.component.js.map +1 -0
- package/src/lib/components/besigner-root-provider.component.d.ts +33 -0
- package/src/lib/components/besigner-root-provider.component.js +68 -0
- package/src/lib/components/besigner-root-provider.component.js.map +1 -0
- package/src/lib/components/binding-preview-controls.component.d.ts +28 -0
- package/src/lib/components/binding-preview-controls.component.js +63 -0
- package/src/lib/components/binding-preview-controls.component.js.map +1 -0
- package/src/lib/components/closeable-drawer.component.d.ts +32 -0
- package/src/lib/components/closeable-drawer.component.js +134 -0
- package/src/lib/components/closeable-drawer.component.js.map +1 -0
- package/src/lib/components/component-accordion-list.d.ts +28 -0
- package/src/lib/components/component-accordion-list.js +205 -0
- package/src/lib/components/component-accordion-list.js.map +1 -0
- package/src/lib/components/component-icon.component.d.ts +32 -0
- package/src/lib/components/component-icon.component.js +51 -0
- package/src/lib/components/component-icon.component.js.map +1 -0
- package/src/lib/components/component-picker.d.ts +27 -0
- package/src/lib/components/component-picker.js +368 -0
- package/src/lib/components/component-picker.js.map +1 -0
- package/src/lib/components/components-grid-list.component.d.ts +31 -0
- package/src/lib/components/components-grid-list.component.js +162 -0
- package/src/lib/components/components-grid-list.component.js.map +1 -0
- package/src/lib/components/custom-css-form.component.d.ts +115 -0
- package/src/lib/components/custom-css-form.component.js +699 -0
- package/src/lib/components/custom-css-form.component.js.map +1 -0
- package/src/lib/components/device-preview-controls.component.d.ts +22 -0
- package/src/lib/components/device-preview-controls.component.js +150 -0
- package/src/lib/components/device-preview-controls.component.js.map +1 -0
- package/src/lib/components/dnd/canvas-drop-indicator.d.ts +20 -0
- package/src/lib/components/dnd/canvas-drop-indicator.js +61 -0
- package/src/lib/components/dnd/canvas-drop-indicator.js.map +1 -0
- package/src/lib/components/dnd/draggable-droppable.d.ts +31 -0
- package/src/lib/components/dnd/draggable-droppable.js +383 -0
- package/src/lib/components/dnd/draggable-droppable.js.map +1 -0
- package/src/lib/components/dnd/draggable.d.ts +42 -0
- package/src/lib/components/dnd/draggable.js +66 -0
- package/src/lib/components/dnd/draggable.js.map +1 -0
- package/src/lib/components/dnd/drop-indicator.d.ts +31 -0
- package/src/lib/components/dnd/drop-indicator.js +139 -0
- package/src/lib/components/dnd/drop-indicator.js.map +1 -0
- package/src/lib/components/dnd/droppable.d.ts +43 -0
- package/src/lib/components/dnd/droppable.js +63 -0
- package/src/lib/components/dnd/droppable.js.map +1 -0
- package/src/lib/components/element-card.component.d.ts +23 -0
- package/src/lib/components/element-card.component.js +49 -0
- package/src/lib/components/element-card.component.js.map +1 -0
- package/src/lib/components/element-classes-field.component.d.ts +41 -0
- package/src/lib/components/element-classes-field.component.js +140 -0
- package/src/lib/components/element-classes-field.component.js.map +1 -0
- package/src/lib/components/element-detail-overlay.component.d.ts +55 -0
- package/src/lib/components/element-detail-overlay.component.js +157 -0
- package/src/lib/components/element-detail-overlay.component.js.map +1 -0
- package/src/lib/components/element-detail.component.d.ts +56 -0
- package/src/lib/components/element-detail.component.js +171 -0
- package/src/lib/components/element-detail.component.js.map +1 -0
- package/src/lib/components/element-info-details.component.d.ts +18 -0
- package/src/lib/components/element-info-details.component.js +169 -0
- package/src/lib/components/element-info-details.component.js.map +1 -0
- package/src/lib/components/element-interactions-form.component.d.ts +21 -0
- package/src/lib/components/element-interactions-form.component.js +199 -0
- package/src/lib/components/element-interactions-form.component.js.map +1 -0
- package/src/lib/components/element-preview.component.d.ts +75 -0
- package/src/lib/components/element-preview.component.js +346 -0
- package/src/lib/components/element-preview.component.js.map +1 -0
- package/src/lib/components/element-props-form.component.d.ts +565 -0
- package/src/lib/components/element-props-form.component.js +2392 -0
- package/src/lib/components/element-props-form.component.js.map +1 -0
- package/src/lib/components/element-styles-form-template.component.d.ts +27 -0
- package/src/lib/components/element-styles-form-template.component.js +89 -0
- package/src/lib/components/element-styles-form-template.component.js.map +1 -0
- package/src/lib/components/element-styles-form.component.d.ts +52 -0
- package/src/lib/components/element-styles-form.component.js +1350 -0
- package/src/lib/components/element-styles-form.component.js.map +1 -0
- package/src/lib/components/empty-document-slot.d.ts +39 -0
- package/src/lib/components/empty-document-slot.js +121 -0
- package/src/lib/components/empty-document-slot.js.map +1 -0
- package/src/lib/components/empty-results.d.ts +22 -0
- package/src/lib/components/empty-results.js +131 -0
- package/src/lib/components/empty-results.js.map +1 -0
- package/src/lib/components/history-controls.component.d.ts +21 -0
- package/src/lib/components/history-controls.component.js +67 -0
- package/src/lib/components/history-controls.component.js.map +1 -0
- package/src/lib/components/inline-markdown-editor.component.d.ts +17 -0
- package/src/lib/components/inline-markdown-editor.component.js +220 -0
- package/src/lib/components/inline-markdown-editor.component.js.map +1 -0
- package/src/lib/components/inline-text-editor.component.d.ts +48 -0
- package/src/lib/components/inline-text-editor.component.js +905 -0
- package/src/lib/components/inline-text-editor.component.js.map +1 -0
- package/src/lib/components/insert-token-menu.component.d.ts +86 -0
- package/src/lib/components/insert-token-menu.component.js +232 -0
- package/src/lib/components/insert-token-menu.component.js.map +1 -0
- package/src/lib/components/instance-attr-overrides.component.d.ts +50 -0
- package/src/lib/components/instance-attr-overrides.component.js +298 -0
- package/src/lib/components/instance-attr-overrides.component.js.map +1 -0
- package/src/lib/components/interact-controls.component.d.ts +22 -0
- package/src/lib/components/interact-controls.component.js +74 -0
- package/src/lib/components/interact-controls.component.js.map +1 -0
- package/src/lib/components/markdown-attribute-field.component.d.ts +40 -0
- package/src/lib/components/markdown-attribute-field.component.js +103 -0
- package/src/lib/components/markdown-attribute-field.component.js.map +1 -0
- package/src/lib/components/node-card.d.ts +24 -0
- package/src/lib/components/node-card.js +86 -0
- package/src/lib/components/node-card.js.map +1 -0
- package/src/lib/components/node-context-menu.d.ts +25 -0
- package/src/lib/components/node-context-menu.js +558 -0
- package/src/lib/components/node-context-menu.js.map +1 -0
- package/src/lib/components/node-leaf.d.ts +39 -0
- package/src/lib/components/node-leaf.js +628 -0
- package/src/lib/components/node-leaf.js.map +1 -0
- package/src/lib/components/node-outline.d.ts +24 -0
- package/src/lib/components/node-outline.js +156 -0
- package/src/lib/components/node-outline.js.map +1 -0
- package/src/lib/components/node-overlay.d.ts +23 -0
- package/src/lib/components/node-overlay.js +299 -0
- package/src/lib/components/node-overlay.js.map +1 -0
- package/src/lib/components/node-quick-actions.d.ts +24 -0
- package/src/lib/components/node-quick-actions.js +284 -0
- package/src/lib/components/node-quick-actions.js.map +1 -0
- package/src/lib/components/node-tree-view.d.ts +106 -0
- package/src/lib/components/node-tree-view.js +820 -0
- package/src/lib/components/node-tree-view.js.map +1 -0
- package/src/lib/components/panel-controls.component.d.ts +22 -0
- package/src/lib/components/panel-controls.component.js +76 -0
- package/src/lib/components/panel-controls.component.js.map +1 -0
- package/src/lib/components/picker-search-field.d.ts +38 -0
- package/src/lib/components/picker-search-field.js +79 -0
- package/src/lib/components/picker-search-field.js.map +1 -0
- package/src/lib/components/plugin-settings-field.component.d.ts +38 -0
- package/src/lib/components/plugin-settings-field.component.js +264 -0
- package/src/lib/components/plugin-settings-field.component.js.map +1 -0
- package/src/lib/components/properties-dialog.component.d.ts +22 -0
- package/src/lib/components/properties-dialog.component.js +40 -0
- package/src/lib/components/properties-dialog.component.js.map +1 -0
- package/src/lib/components/property-binding-field.component.d.ts +142 -0
- package/src/lib/components/property-binding-field.component.js +325 -0
- package/src/lib/components/property-binding-field.component.js.map +1 -0
- package/src/lib/components/property-values-form.component.d.ts +43 -0
- package/src/lib/components/property-values-form.component.js +223 -0
- package/src/lib/components/property-values-form.component.js.map +1 -0
- package/src/lib/components/scheme-preview-controls.component.d.ts +26 -0
- package/src/lib/components/scheme-preview-controls.component.js +56 -0
- package/src/lib/components/scheme-preview-controls.component.js.map +1 -0
- package/src/lib/components/screen-link-field.component.d.ts +118 -0
- package/src/lib/components/screen-link-field.component.js +282 -0
- package/src/lib/components/screen-link-field.component.js.map +1 -0
- package/src/lib/components/site-theme-color-tokens-provider.component.d.ts +33 -0
- package/src/lib/components/site-theme-color-tokens-provider.component.js +53 -0
- package/src/lib/components/site-theme-color-tokens-provider.component.js.map +1 -0
- package/src/lib/components/subtree-json-dialog.component.d.ts +46 -0
- package/src/lib/components/subtree-json-dialog.component.js +125 -0
- package/src/lib/components/subtree-json-dialog.component.js.map +1 -0
- package/src/lib/components/token-pill.component.d.ts +51 -0
- package/src/lib/components/token-pill.component.js +164 -0
- package/src/lib/components/token-pill.component.js.map +1 -0
- package/src/lib/components/token-text-field.component.d.ts +146 -0
- package/src/lib/components/token-text-field.component.js +603 -0
- package/src/lib/components/token-text-field.component.js.map +1 -0
- package/src/lib/components/tree/tree-list.d.ts +6 -0
- package/src/lib/components/tree/tree-list.js +108 -0
- package/src/lib/components/tree/tree-list.js.map +1 -0
- package/src/lib/components/viewport-canvas.component.d.ts +23 -0
- package/src/lib/components/viewport-canvas.component.js +128 -0
- package/src/lib/components/viewport-canvas.component.js.map +1 -0
- package/src/lib/components/viewport-frame.component.d.ts +47 -0
- package/src/lib/components/viewport-frame.component.js +332 -0
- package/src/lib/components/viewport-frame.component.js.map +1 -0
- package/src/lib/components/viewport-root.component.d.ts +22 -0
- package/src/lib/components/viewport-root.component.js +112 -0
- package/src/lib/components/viewport-root.component.js.map +1 -0
- package/src/lib/components/viewport-zoom-controls.d.ts +29 -0
- package/src/lib/components/viewport-zoom-controls.js +147 -0
- package/src/lib/components/viewport-zoom-controls.js.map +1 -0
- package/src/lib/components/workspace-editor.component.d.ts +23 -0
- package/src/lib/components/workspace-editor.component.js +191 -0
- package/src/lib/components/workspace-editor.component.js.map +1 -0
- package/src/lib/components/workspace-panel.component.d.ts +28 -0
- package/src/lib/components/workspace-panel.component.js +147 -0
- package/src/lib/components/workspace-panel.component.js.map +1 -0
- package/src/lib/constants/sample-data.d.ts +18 -0
- package/src/lib/constants/sample-data.js +106 -0
- package/src/lib/constants/sample-data.js.map +1 -0
- package/src/lib/constants/shared.d.ts +17 -0
- package/src/lib/constants/shared.js +18 -0
- package/src/lib/constants/shared.js.map +1 -0
- package/src/lib/contexts/besigner-app-context.d.ts +30 -0
- package/src/lib/contexts/besigner-app-context.js +41 -0
- package/src/lib/contexts/besigner-app-context.js.map +1 -0
- package/src/lib/contexts/binding-picker-context.d.ts +78 -0
- package/src/lib/contexts/binding-picker-context.js +21 -0
- package/src/lib/contexts/binding-picker-context.js.map +1 -0
- package/src/lib/contexts/canvas-host-tokens-context.d.ts +49 -0
- package/src/lib/contexts/canvas-host-tokens-context.js +63 -0
- package/src/lib/contexts/canvas-host-tokens-context.js.map +1 -0
- package/src/lib/contexts/canvas-reveal-context.d.ts +32 -0
- package/src/lib/contexts/canvas-reveal-context.js +34 -0
- package/src/lib/contexts/canvas-reveal-context.js.map +1 -0
- package/src/lib/contexts/component-promotion-context.d.ts +89 -0
- package/src/lib/contexts/component-promotion-context.js +21 -0
- package/src/lib/contexts/component-promotion-context.js.map +1 -0
- package/src/lib/contexts/components-drawer-context.provider.d.ts +32 -0
- package/src/lib/contexts/components-drawer-context.provider.js +80 -0
- package/src/lib/contexts/components-drawer-context.provider.js.map +1 -0
- package/src/lib/contexts/element-drawer-context.d.ts +1005 -0
- package/src/lib/contexts/element-drawer-context.js +45 -0
- package/src/lib/contexts/element-drawer-context.js.map +1 -0
- package/src/lib/contexts/inspected-selection.d.ts +32 -0
- package/src/lib/contexts/inspected-selection.js +38 -0
- package/src/lib/contexts/inspected-selection.js.map +1 -0
- package/src/lib/contexts/inspector-extras-context.d.ts +56 -0
- package/src/lib/contexts/inspector-extras-context.js +35 -0
- package/src/lib/contexts/inspector-extras-context.js.map +1 -0
- package/src/lib/contexts/interactions-context.d.ts +99 -0
- package/src/lib/contexts/interactions-context.js +22 -0
- package/src/lib/contexts/interactions-context.js.map +1 -0
- package/src/lib/contexts/layout-chrome-context.d.ts +37 -0
- package/src/lib/contexts/layout-chrome-context.js +75 -0
- package/src/lib/contexts/layout-chrome-context.js.map +1 -0
- package/src/lib/contexts/media-asset-facts-context.d.ts +74 -0
- package/src/lib/contexts/media-asset-facts-context.js +27 -0
- package/src/lib/contexts/media-asset-facts-context.js.map +1 -0
- package/src/lib/contexts/media-picker-context.d.ts +88 -0
- package/src/lib/contexts/media-picker-context.js +21 -0
- package/src/lib/contexts/media-picker-context.js.map +1 -0
- package/src/lib/contexts/rendered-canvas-elements.d.ts +42 -0
- package/src/lib/contexts/rendered-canvas-elements.js +79 -0
- package/src/lib/contexts/rendered-canvas-elements.js.map +1 -0
- package/src/lib/contexts/repeat-record-context.d.ts +38 -0
- package/src/lib/contexts/repeat-record-context.js +21 -0
- package/src/lib/contexts/repeat-record-context.js.map +1 -0
- package/src/lib/contexts/repeat-rows-context.d.ts +53 -0
- package/src/lib/contexts/repeat-rows-context.js +38 -0
- package/src/lib/contexts/repeat-rows-context.js.map +1 -0
- package/src/lib/contexts/toolbar-extras-context.d.ts +31 -0
- package/src/lib/contexts/toolbar-extras-context.js +33 -0
- package/src/lib/contexts/toolbar-extras-context.js.map +1 -0
- package/src/lib/drafts/besigner-draft-store.d.ts +110 -0
- package/src/lib/drafts/besigner-draft-store.js +125 -0
- package/src/lib/drafts/besigner-draft-store.js.map +1 -0
- package/src/lib/drafts/besigner-server-draft.d.ts +130 -0
- package/src/lib/drafts/besigner-server-draft.js +211 -0
- package/src/lib/drafts/besigner-server-draft.js.map +1 -0
- package/src/lib/form-fields/components/shared/inline-form-control.d.ts +32 -0
- package/src/lib/form-fields/components/shared/inline-form-control.js +85 -0
- package/src/lib/form-fields/components/shared/inline-form-control.js.map +1 -0
- package/src/lib/form-fields/components/shared/toggle-button-form-control.d.ts +33 -0
- package/src/lib/form-fields/components/shared/toggle-button-form-control.js +83 -0
- package/src/lib/form-fields/components/shared/toggle-button-form-control.js.map +1 -0
- package/src/lib/form-fields/form-fields.d.ts +20 -0
- package/src/lib/form-fields/form-fields.js +21 -0
- package/src/lib/form-fields/form-fields.js.map +1 -0
- package/src/lib/form-fields/index.d.ts +1 -0
- package/src/lib/form-fields/index.js +3 -0
- package/src/lib/form-fields/index.js.map +1 -0
- package/src/lib/hooks/use-add-element-drawer-callback.d.ts +28 -0
- package/src/lib/hooks/use-add-element-drawer-callback.js +112 -0
- package/src/lib/hooks/use-add-element-drawer-callback.js.map +1 -0
- package/src/lib/hooks/use-aglyn-besigner-flag.d.ts +23 -0
- package/src/lib/hooks/use-aglyn-besigner-flag.js +47 -0
- package/src/lib/hooks/use-aglyn-besigner-flag.js.map +1 -0
- package/src/lib/hooks/use-aglyn-besigner-panel-value.d.ts +23 -0
- package/src/lib/hooks/use-aglyn-besigner-panel-value.js +54 -0
- package/src/lib/hooks/use-aglyn-besigner-panel-value.js.map +1 -0
- package/src/lib/hooks/use-aglyn-besigner-panel.d.ts +23 -0
- package/src/lib/hooks/use-aglyn-besigner-panel.js +47 -0
- package/src/lib/hooks/use-aglyn-besigner-panel.js.map +1 -0
- package/src/lib/hooks/use-anchored-rect.d.ts +68 -0
- package/src/lib/hooks/use-anchored-rect.js +131 -0
- package/src/lib/hooks/use-anchored-rect.js.map +1 -0
- package/src/lib/hooks/use-besigner-app-context.d.ts +18 -0
- package/src/lib/hooks/use-besigner-app-context.js +19 -0
- package/src/lib/hooks/use-besigner-app-context.js.map +1 -0
- package/src/lib/hooks/use-besigner-document.d.ts +309 -0
- package/src/lib/hooks/use-besigner-document.js +500 -0
- package/src/lib/hooks/use-besigner-document.js.map +1 -0
- package/src/lib/hooks/use-besigner-draft.d.ts +209 -0
- package/src/lib/hooks/use-besigner-draft.js +429 -0
- package/src/lib/hooks/use-besigner-draft.js.map +1 -0
- package/src/lib/hooks/use-clipboard-callbacks.d.ts +29 -0
- package/src/lib/hooks/use-clipboard-callbacks.js +82 -0
- package/src/lib/hooks/use-clipboard-callbacks.js.map +1 -0
- package/src/lib/hooks/use-clipboard-shortcuts.d.ts +52 -0
- package/src/lib/hooks/use-clipboard-shortcuts.js +102 -0
- package/src/lib/hooks/use-clipboard-shortcuts.js.map +1 -0
- package/src/lib/hooks/use-component-propagation-notice.d.ts +96 -0
- package/src/lib/hooks/use-component-propagation-notice.js +177 -0
- package/src/lib/hooks/use-component-propagation-notice.js.map +1 -0
- package/src/lib/hooks/use-debounced-commit.d.ts +43 -0
- package/src/lib/hooks/use-debounced-commit.js +88 -0
- package/src/lib/hooks/use-debounced-commit.js.map +1 -0
- package/src/lib/hooks/use-delete-element-callback.d.ts +24 -0
- package/src/lib/hooks/use-delete-element-callback.js +82 -0
- package/src/lib/hooks/use-delete-element-callback.js.map +1 -0
- package/src/lib/hooks/use-detail-hover-intent.d.ts +76 -0
- package/src/lib/hooks/use-detail-hover-intent.js +123 -0
- package/src/lib/hooks/use-detail-hover-intent.js.map +1 -0
- package/src/lib/hooks/use-document-repair-callbacks.d.ts +50 -0
- package/src/lib/hooks/use-document-repair-callbacks.js +237 -0
- package/src/lib/hooks/use-document-repair-callbacks.js.map +1 -0
- package/src/lib/hooks/use-insert-token-options.d.ts +52 -0
- package/src/lib/hooks/use-insert-token-options.js +230 -0
- package/src/lib/hooks/use-insert-token-options.js.map +1 -0
- package/src/lib/hooks/use-leaf-drag.d.ts +24 -0
- package/src/lib/hooks/use-leaf-drag.js +28 -0
- package/src/lib/hooks/use-leaf-drag.js.map +1 -0
- package/src/lib/hooks/use-leaf-drop.d.ts +31 -0
- package/src/lib/hooks/use-leaf-drop.js +43 -0
- package/src/lib/hooks/use-leaf-drop.js.map +1 -0
- package/src/lib/hooks/use-markdown-media-picker.d.ts +63 -0
- package/src/lib/hooks/use-markdown-media-picker.js +110 -0
- package/src/lib/hooks/use-markdown-media-picker.js.map +1 -0
- package/src/lib/hooks/use-media-asset-facts-overlay.d.ts +43 -0
- package/src/lib/hooks/use-media-asset-facts-overlay.js +133 -0
- package/src/lib/hooks/use-media-asset-facts-overlay.js.map +1 -0
- package/src/lib/hooks/use-move-node-callbacks.d.ts +22 -0
- package/src/lib/hooks/use-move-node-callbacks.js +57 -0
- package/src/lib/hooks/use-move-node-callbacks.js.map +1 -0
- package/src/lib/hooks/use-node-with-host-tokens.d.ts +42 -0
- package/src/lib/hooks/use-node-with-host-tokens.js +59 -0
- package/src/lib/hooks/use-node-with-host-tokens.js.map +1 -0
- package/src/lib/hooks/use-picker-filter.d.ts +61 -0
- package/src/lib/hooks/use-picker-filter.js +122 -0
- package/src/lib/hooks/use-picker-filter.js.map +1 -0
- package/src/lib/hooks/use-repeat-preview.d.ts +64 -0
- package/src/lib/hooks/use-repeat-preview.js +214 -0
- package/src/lib/hooks/use-repeat-preview.js.map +1 -0
- package/src/lib/hooks/use-repeat-sources.d.ts +17 -0
- package/src/lib/hooks/use-repeat-sources.js +41 -0
- package/src/lib/hooks/use-repeat-sources.js.map +1 -0
- package/src/lib/hooks/use-visible-component-categories.d.ts +37 -0
- package/src/lib/hooks/use-visible-component-categories.js +79 -0
- package/src/lib/hooks/use-visible-component-categories.js.map +1 -0
- package/src/lib/utils/active-host-theme.d.ts +28 -0
- package/src/lib/utils/active-host-theme.js +77 -0
- package/src/lib/utils/active-host-theme.js.map +1 -0
- package/src/lib/utils/attr-target.d.ts +170 -0
- package/src/lib/utils/attr-target.js +229 -0
- package/src/lib/utils/attr-target.js.map +1 -0
- package/src/lib/utils/attribute-field-value.d.ts +21 -0
- package/src/lib/utils/attribute-field-value.js +28 -0
- package/src/lib/utils/attribute-field-value.js.map +1 -0
- package/src/lib/utils/canvas-context-menu.d.ts +28 -0
- package/src/lib/utils/canvas-context-menu.js +56 -0
- package/src/lib/utils/canvas-context-menu.js.map +1 -0
- package/src/lib/utils/canvas-reveal.d.ts +115 -0
- package/src/lib/utils/canvas-reveal.js +165 -0
- package/src/lib/utils/canvas-reveal.js.map +1 -0
- package/src/lib/utils/describe-element.d.ts +72 -0
- package/src/lib/utils/describe-element.js +159 -0
- package/src/lib/utils/describe-element.js.map +1 -0
- package/src/lib/utils/device-preview-styles.d.ts +89 -0
- package/src/lib/utils/device-preview-styles.js +228 -0
- package/src/lib/utils/device-preview-styles.js.map +1 -0
- package/src/lib/utils/docs-help.d.ts +22 -0
- package/src/lib/utils/docs-help.generated.d.ts +47 -0
- package/src/lib/utils/docs-help.generated.js +229 -0
- package/src/lib/utils/docs-help.generated.js.map +1 -0
- package/src/lib/utils/docs-help.js +37 -0
- package/src/lib/utils/docs-help.js.map +1 -0
- package/src/lib/utils/held-answers-store.d.ts +59 -0
- package/src/lib/utils/held-answers-store.js +94 -0
- package/src/lib/utils/held-answers-store.js.map +1 -0
- package/src/lib/utils/in-place-edit-surface.d.ts +118 -0
- package/src/lib/utils/in-place-edit-surface.js +164 -0
- package/src/lib/utils/in-place-edit-surface.js.map +1 -0
- package/src/lib/utils/inline-markdown-edit.store.d.ts +71 -0
- package/src/lib/utils/inline-markdown-edit.store.js +90 -0
- package/src/lib/utils/inline-markdown-edit.store.js.map +1 -0
- package/src/lib/utils/inline-text-edit.store.d.ts +85 -0
- package/src/lib/utils/inline-text-edit.store.js +78 -0
- package/src/lib/utils/inline-text-edit.store.js.map +1 -0
- package/src/lib/utils/instance-leaf-hit.d.ts +39 -0
- package/src/lib/utils/instance-leaf-hit.js +56 -0
- package/src/lib/utils/instance-leaf-hit.js.map +1 -0
- package/src/lib/utils/muted-classes.d.ts +76 -0
- package/src/lib/utils/muted-classes.js +108 -0
- package/src/lib/utils/muted-classes.js.map +1 -0
- package/src/lib/utils/muted-styles.d.ts +125 -0
- package/src/lib/utils/muted-styles.js +193 -0
- package/src/lib/utils/muted-styles.js.map +1 -0
- package/src/lib/utils/numeric-text-value.d.ts +42 -0
- package/src/lib/utils/numeric-text-value.js +47 -0
- package/src/lib/utils/numeric-text-value.js.map +1 -0
- package/src/lib/utils/preset-interactions.d.ts +37 -0
- package/src/lib/utils/preset-interactions.js +87 -0
- package/src/lib/utils/preset-interactions.js.map +1 -0
- package/src/lib/utils/publish-failure-message.d.ts +35 -0
- package/src/lib/utils/publish-failure-message.js +51 -0
- package/src/lib/utils/publish-failure-message.js.map +1 -0
- package/src/lib/utils/rank-picker-results.d.ts +45 -0
- package/src/lib/utils/rank-picker-results.js +136 -0
- package/src/lib/utils/rank-picker-results.js.map +1 -0
- package/src/lib/utils/responsive-sx.d.ts +65 -0
- package/src/lib/utils/responsive-sx.js +129 -0
- package/src/lib/utils/responsive-sx.js.map +1 -0
- package/src/lib/utils/rich-text-commands.d.ts +28 -0
- package/src/lib/utils/rich-text-commands.js +43 -0
- package/src/lib/utils/rich-text-commands.js.map +1 -0
- package/src/lib/utils/sanitize-rich-text.d.ts +52 -0
- package/src/lib/utils/sanitize-rich-text.js +173 -0
- package/src/lib/utils/sanitize-rich-text.js.map +1 -0
- package/src/lib/utils/state-sx.d.ts +255 -0
- package/src/lib/utils/state-sx.js +338 -0
- package/src/lib/utils/state-sx.js.map +1 -0
- package/src/lib/utils/style-field-groups.d.ts +136 -0
- package/src/lib/utils/style-field-groups.js +874 -0
- package/src/lib/utils/style-field-groups.js.map +1 -0
- package/src/lib/utils/style-field-search.d.ts +84 -0
- package/src/lib/utils/style-field-search.js +505 -0
- package/src/lib/utils/style-field-search.js.map +1 -0
- package/src/lib/utils/style-target.d.ts +69 -0
- package/src/lib/utils/style-target.js +203 -0
- package/src/lib/utils/style-target.js.map +1 -0
- package/src/lib/utils/theme-scale-options.d.ts +169 -0
- package/src/lib/utils/theme-scale-options.js +702 -0
- package/src/lib/utils/theme-scale-options.js.map +1 -0
- package/src/lib/utils/token-editable-dom.d.ts +82 -0
- package/src/lib/utils/token-editable-dom.js +280 -0
- package/src/lib/utils/token-editable-dom.js.map +1 -0
- package/src/lib/utils/token-segments.d.ts +111 -0
- package/src/lib/utils/token-segments.js +246 -0
- package/src/lib/utils/token-segments.js.map +1 -0
- package/src/lib/utils/visibility-styles.d.ts +38 -0
- package/src/lib/utils/visibility-styles.js +54 -0
- package/src/lib/utils/visibility-styles.js.map +1 -0
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2022 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/ export const samplePageData = [
|
|
17
|
+
{
|
|
18
|
+
$id: 'sample-element-1',
|
|
19
|
+
componentId: 'sample-element',
|
|
20
|
+
props: {},
|
|
21
|
+
nodes: [
|
|
22
|
+
{
|
|
23
|
+
$id: 'sample-element-11',
|
|
24
|
+
componentId: 'sample-element-1',
|
|
25
|
+
props: {
|
|
26
|
+
children: 'hello'
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
$id: 'sample-element-21',
|
|
31
|
+
componentId: 'sample-element-2',
|
|
32
|
+
props: {
|
|
33
|
+
children: 'hello'
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
$id: 'sample-element-31',
|
|
38
|
+
componentId: 'sample-element-3',
|
|
39
|
+
props: {
|
|
40
|
+
children: 'hello'
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
]
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
$id: 'sample-element-2',
|
|
47
|
+
componentId: 'sample-element-4',
|
|
48
|
+
props: {},
|
|
49
|
+
nodes: [
|
|
50
|
+
{
|
|
51
|
+
$id: 'sample-element-13',
|
|
52
|
+
componentId: 'sample-element-1',
|
|
53
|
+
sx: {
|
|
54
|
+
fontWeight: 'fontWeightBold'
|
|
55
|
+
},
|
|
56
|
+
props: {
|
|
57
|
+
children: 'hello'
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
$id: 'sample-element-23',
|
|
62
|
+
componentId: 'sample-element-2',
|
|
63
|
+
props: {
|
|
64
|
+
children: 'hello'
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
$id: 'sample-element-33',
|
|
69
|
+
componentId: 'sample-element-3',
|
|
70
|
+
props: {
|
|
71
|
+
children: 'hello'
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
]
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
$id: 'sample-element-3',
|
|
78
|
+
componentId: 'sample-element-4',
|
|
79
|
+
props: {},
|
|
80
|
+
nodes: [
|
|
81
|
+
{
|
|
82
|
+
$id: 'sample-element-14',
|
|
83
|
+
componentId: 'sample-element-1',
|
|
84
|
+
props: {
|
|
85
|
+
children: 'hello'
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
$id: 'sample-element-24',
|
|
90
|
+
componentId: 'sample-element-2',
|
|
91
|
+
props: {
|
|
92
|
+
children: 'hello'
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
$id: 'sample-element-34',
|
|
97
|
+
componentId: 'sample-element-3',
|
|
98
|
+
props: {
|
|
99
|
+
children: 'hello'
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
]
|
|
103
|
+
}
|
|
104
|
+
];
|
|
105
|
+
|
|
106
|
+
//# sourceMappingURL=sample-data.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../libs/besigner/feature/designer/src/lib/constants/sample-data.tsx"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { AglynNodesList } from '@aglyn/aglyn'\n\nexport const samplePageData: AglynNodesList = [\n {\n $id: 'sample-element-1',\n componentId: 'sample-element',\n props: {},\n nodes: [\n {\n $id: 'sample-element-11',\n componentId: 'sample-element-1',\n props: {\n children: 'hello',\n },\n },\n {\n $id: 'sample-element-21',\n componentId: 'sample-element-2',\n props: {\n children: 'hello',\n },\n },\n {\n $id: 'sample-element-31',\n componentId: 'sample-element-3',\n props: {\n children: 'hello',\n },\n },\n ],\n },\n {\n $id: 'sample-element-2',\n componentId: 'sample-element-4',\n props: {},\n nodes: [\n {\n $id: 'sample-element-13',\n componentId: 'sample-element-1',\n sx: { fontWeight: 'fontWeightBold' },\n props: {\n children: 'hello',\n },\n },\n {\n $id: 'sample-element-23',\n componentId: 'sample-element-2',\n props: {\n children: 'hello',\n },\n },\n {\n $id: 'sample-element-33',\n componentId: 'sample-element-3',\n props: {\n children: 'hello',\n },\n },\n ],\n },\n {\n $id: 'sample-element-3',\n componentId: 'sample-element-4',\n props: {},\n nodes: [\n {\n $id: 'sample-element-14',\n componentId: 'sample-element-1',\n props: {\n children: 'hello',\n },\n },\n {\n $id: 'sample-element-24',\n componentId: 'sample-element-2',\n props: {\n children: 'hello',\n },\n },\n {\n $id: 'sample-element-34',\n componentId: 'sample-element-3',\n props: {\n children: 'hello',\n },\n },\n ],\n },\n]\n"],"names":["samplePageData","$id","componentId","props","nodes","children","sx","fontWeight"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAID,OAAO,MAAMA,iBAAiC;IAC5C;QACEC,KAAK;QACLC,aAAa;QACbC,OAAO,CAAC;QACRC,OAAO;YACL;gBACEH,KAAK;gBACLC,aAAa;gBACbC,OAAO;oBACLE,UAAU;gBACZ;YACF;YACA;gBACEJ,KAAK;gBACLC,aAAa;gBACbC,OAAO;oBACLE,UAAU;gBACZ;YACF;YACA;gBACEJ,KAAK;gBACLC,aAAa;gBACbC,OAAO;oBACLE,UAAU;gBACZ;YACF;SACD;IACH;IACA;QACEJ,KAAK;QACLC,aAAa;QACbC,OAAO,CAAC;QACRC,OAAO;YACL;gBACEH,KAAK;gBACLC,aAAa;gBACbI,IAAI;oBAAEC,YAAY;gBAAiB;gBACnCJ,OAAO;oBACLE,UAAU;gBACZ;YACF;YACA;gBACEJ,KAAK;gBACLC,aAAa;gBACbC,OAAO;oBACLE,UAAU;gBACZ;YACF;YACA;gBACEJ,KAAK;gBACLC,aAAa;gBACbC,OAAO;oBACLE,UAAU;gBACZ;YACF;SACD;IACH;IACA;QACEJ,KAAK;QACLC,aAAa;QACbC,OAAO,CAAC;QACRC,OAAO;YACL;gBACEH,KAAK;gBACLC,aAAa;gBACbC,OAAO;oBACLE,UAAU;gBACZ;YACF;YACA;gBACEJ,KAAK;gBACLC,aAAa;gBACbC,OAAO;oBACLE,UAAU;gBACZ;YACF;YACA;gBACEJ,KAAK;gBACLC,aAAa;gBACbC,OAAO;oBACLE,UAAU;gBACZ;YACF;SACD;IACH;CACD,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2022 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export declare const DEFAULT_LEFT_DRAWER_WIDTH = 240;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2022 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/ export const DEFAULT_LEFT_DRAWER_WIDTH = 240;
|
|
17
|
+
|
|
18
|
+
//# sourceMappingURL=shared.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../libs/besigner/feature/designer/src/lib/constants/shared.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport const DEFAULT_LEFT_DRAWER_WIDTH = 240\n"],"names":["DEFAULT_LEFT_DRAWER_WIDTH"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAED,OAAO,MAAMA,4BAA4B,IAAG"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { type AppUUN, type IBesignerAppController } from '@aglyn/besigner';
|
|
18
|
+
export type IBesignerAppContext = IBesignerAppController | undefined;
|
|
19
|
+
export declare const BesignerAppContext: import("react").Context<IBesignerAppController>;
|
|
20
|
+
export default BesignerAppContext;
|
|
21
|
+
export declare function useBesignerAppContext(): IBesignerAppController;
|
|
22
|
+
export interface BesignerAppProviderProps {
|
|
23
|
+
appName?: AppUUN;
|
|
24
|
+
children?: JSX.Children;
|
|
25
|
+
}
|
|
26
|
+
export declare function BesignerAppProvider(props: BesignerAppProviderProps): import("react").JSX.Element;
|
|
27
|
+
export declare namespace BesignerAppProvider {
|
|
28
|
+
var displayName: string;
|
|
29
|
+
var aglyn: boolean;
|
|
30
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* @license
|
|
4
|
+
* Copyright 2026 Aglyn LLC
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/ import { doesBesignerAppExist, getBesignerApp } from "@aglyn/besigner";
|
|
18
|
+
import { createContext, useContext, useMemo } from "react";
|
|
19
|
+
export const BesignerAppContext = /*#__PURE__*/ createContext(undefined);
|
|
20
|
+
BesignerAppContext.displayName = 'BesignerAppContext';
|
|
21
|
+
BesignerAppContext.aglyn = true;
|
|
22
|
+
export default BesignerAppContext;
|
|
23
|
+
export function useBesignerAppContext() {
|
|
24
|
+
return useContext(BesignerAppContext);
|
|
25
|
+
}
|
|
26
|
+
export function BesignerAppProvider(props) {
|
|
27
|
+
const { appName, children } = props;
|
|
28
|
+
// App initialization is browser-only; render undefined during SSR instead
|
|
29
|
+
// of throwing (matches the previous framework getApp semantics).
|
|
30
|
+
const state = useMemo(()=>doesBesignerAppExist(appName) ? getBesignerApp(appName) : undefined, [
|
|
31
|
+
appName
|
|
32
|
+
]);
|
|
33
|
+
return /*#__PURE__*/ _jsx(BesignerAppContext.Provider, {
|
|
34
|
+
value: state,
|
|
35
|
+
children: children
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
BesignerAppProvider.displayName = 'BesignerAppProvider';
|
|
39
|
+
BesignerAppProvider.aglyn = true;
|
|
40
|
+
|
|
41
|
+
//# sourceMappingURL=besigner-app-context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../libs/besigner/feature/designer/src/lib/contexts/besigner-app-context.tsx"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n type AppUUN,\n doesBesignerAppExist,\n getBesignerApp,\n type IBesignerAppController,\n} from '@aglyn/besigner'\nimport { createContext, useContext, useMemo } from 'react'\n\nexport type IBesignerAppContext = IBesignerAppController | undefined\n\nexport const BesignerAppContext =\n createContext<IBesignerAppContext>(undefined)\nBesignerAppContext.displayName = 'BesignerAppContext'\nBesignerAppContext.aglyn = true\nexport default BesignerAppContext\n\nexport function useBesignerAppContext(): IBesignerAppController {\n return useContext(BesignerAppContext)\n}\n\nexport interface BesignerAppProviderProps {\n appName?: AppUUN\n children?: JSX.Children\n}\n\nexport function BesignerAppProvider(props: BesignerAppProviderProps) {\n const { appName, children } = props\n // App initialization is browser-only; render undefined during SSR instead\n // of throwing (matches the previous framework getApp semantics).\n const state = useMemo<IBesignerAppContext>(\n () => (doesBesignerAppExist(appName) ? getBesignerApp(appName) : undefined),\n [appName],\n )\n return (\n <BesignerAppContext.Provider value={state}>\n {children}\n </BesignerAppContext.Provider>\n )\n}\nBesignerAppProvider.displayName = 'BesignerAppProvider'\nBesignerAppProvider.aglyn = true\n"],"names":["doesBesignerAppExist","getBesignerApp","createContext","useContext","useMemo","BesignerAppContext","undefined","displayName","aglyn","useBesignerAppContext","BesignerAppProvider","props","appName","children","state","Provider","value"],"mappings":";AAAA;;;;;;;;;;;;;;;CAeC,GAED,SAEEA,oBAAoB,EACpBC,cAAc,QAET,kBAAiB;AACxB,SAASC,aAAa,EAAEC,UAAU,EAAEC,OAAO,QAAQ,QAAO;AAI1D,OAAO,MAAMC,mCACXH,cAAmCI,WAAU;AAC/CD,mBAAmBE,WAAW,GAAG;AACjCF,mBAAmBG,KAAK,GAAG;AAC3B,eAAeH,mBAAkB;AAEjC,OAAO,SAASI;IACd,OAAON,WAAWE;AACpB;AAOA,OAAO,SAASK,oBAAoBC,KAA+B;IACjE,MAAM,EAAEC,OAAO,EAAEC,QAAQ,EAAE,GAAGF;IAC9B,0EAA0E;IAC1E,iEAAiE;IACjE,MAAMG,QAAQV,QACZ,IAAOJ,qBAAqBY,WAAWX,eAAeW,WAAWN,WACjE;QAACM;KAAQ;IAEX,qBACE,KAACP,mBAAmBU,QAAQ;QAACC,OAAOF;kBACjCD;;AAGP;AACAH,oBAAoBH,WAAW,GAAG;AAClCG,oBAAoBF,KAAK,GAAG"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
/**
|
|
18
|
+
* Host-app-provided binding options for the Attributes panel's "Insert
|
|
19
|
+
* binding" menu (AGL-100): the console supplies the host's variables
|
|
20
|
+
* (`{{name}}`) and functions (`{{fn:name(args)}}`); the designer stays
|
|
21
|
+
* storage-agnostic and hides the control when no options exist.
|
|
22
|
+
*/
|
|
23
|
+
export interface BindingOption {
|
|
24
|
+
/** Menu label, e.g. `Message` or `Sum(P1, P2)`. */
|
|
25
|
+
label: string;
|
|
26
|
+
/** Token appended to the element text, e.g. `{{Message}}`. */
|
|
27
|
+
token: string;
|
|
28
|
+
/** Section header the option renders under (e.g. Variables). */
|
|
29
|
+
group?: string;
|
|
30
|
+
/**
|
|
31
|
+
* Live value preview shown as the option's secondary line (AGL-262),
|
|
32
|
+
* e.g. a variable's current value — picking a binding shouldn't
|
|
33
|
+
* require remembering what it holds.
|
|
34
|
+
*/
|
|
35
|
+
preview?: string;
|
|
36
|
+
/**
|
|
37
|
+
* Caption rendered under the group's subheader (AGL-583) — e.g. where a
|
|
38
|
+
* context-dependent token group resolves ("Resolves on collection
|
|
39
|
+
* pages"). Read from the group's first visible option.
|
|
40
|
+
*/
|
|
41
|
+
groupHint?: string;
|
|
42
|
+
}
|
|
43
|
+
export interface BindingPickerContextValue {
|
|
44
|
+
options?: BindingOption[];
|
|
45
|
+
/**
|
|
46
|
+
* Live-resolution inputs (AGL-97): the host's variable docs (by name)
|
|
47
|
+
* and function definitions (by name) so the canvas can render resolved
|
|
48
|
+
* values via `resolveBindings`. Optional — without them the canvas
|
|
49
|
+
* shows raw tokens regardless of the toggle.
|
|
50
|
+
*/
|
|
51
|
+
variables?: Record<string, import('@aglyn/aglyn').HostVariable>;
|
|
52
|
+
functions?: Record<string, import('@aglyn/aglyn').HostFunction>;
|
|
53
|
+
/**
|
|
54
|
+
* Props declared by the reusable component being edited (AGL-1335), so
|
|
55
|
+
* `{{prop.*}}` is offered in the insert picker like every other binding.
|
|
56
|
+
*
|
|
57
|
+
* Set ONLY inside a component editor — everywhere else the tokens would
|
|
58
|
+
* resolve to nothing, and offering a binding that cannot resolve is worse
|
|
59
|
+
* than not offering it. That is why this is a context value rather than
|
|
60
|
+
* something the designer derives: nothing on the canvas says which
|
|
61
|
+
* definition it belongs to.
|
|
62
|
+
*/
|
|
63
|
+
componentProps?: import('@aglyn/aglyn').ReusableComponentProp[];
|
|
64
|
+
/**
|
|
65
|
+
* Whose properties {@link componentProps} are: a reusable component's, or a
|
|
66
|
+
* shared layout's (AGL-2893). Both bind the same way; what an empty binding
|
|
67
|
+
* picker tells the author to add names the right one.
|
|
68
|
+
*/
|
|
69
|
+
componentPropsOwner?: 'component' | 'layout';
|
|
70
|
+
/**
|
|
71
|
+
* The site being edited, for `{{host.*}}` tokens (AGL-2881): the canvas
|
|
72
|
+
* fills them in from it through the resolver the published page composes
|
|
73
|
+
* with. Optional — without it the tokens draw as written.
|
|
74
|
+
*/
|
|
75
|
+
host?: import('@aglyn/aglyn').HostTokenSource | null;
|
|
76
|
+
}
|
|
77
|
+
export declare const BindingPickerContext: import("react").Context<BindingPickerContextValue>;
|
|
78
|
+
export default BindingPickerContext;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/ import { createContext } from "react";
|
|
17
|
+
export const BindingPickerContext = createContext({});
|
|
18
|
+
BindingPickerContext.displayName = 'BindingPickerContext';
|
|
19
|
+
export default BindingPickerContext;
|
|
20
|
+
|
|
21
|
+
//# sourceMappingURL=binding-picker-context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../libs/besigner/feature/designer/src/lib/contexts/binding-picker-context.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { createContext } from 'react'\n\n/**\n * Host-app-provided binding options for the Attributes panel's \"Insert\n * binding\" menu (AGL-100): the console supplies the host's variables\n * (`{{name}}`) and functions (`{{fn:name(args)}}`); the designer stays\n * storage-agnostic and hides the control when no options exist.\n */\nexport interface BindingOption {\n /** Menu label, e.g. `Message` or `Sum(P1, P2)`. */\n label: string\n /** Token appended to the element text, e.g. `{{Message}}`. */\n token: string\n /** Section header the option renders under (e.g. Variables). */\n group?: string\n /**\n * Live value preview shown as the option's secondary line (AGL-262),\n * e.g. a variable's current value — picking a binding shouldn't\n * require remembering what it holds.\n */\n preview?: string\n /**\n * Caption rendered under the group's subheader (AGL-583) — e.g. where a\n * context-dependent token group resolves (\"Resolves on collection\n * pages\"). Read from the group's first visible option.\n */\n groupHint?: string\n}\n\nexport interface BindingPickerContextValue {\n options?: BindingOption[]\n /**\n * Live-resolution inputs (AGL-97): the host's variable docs (by name)\n * and function definitions (by name) so the canvas can render resolved\n * values via `resolveBindings`. Optional — without them the canvas\n * shows raw tokens regardless of the toggle.\n */\n variables?: Record<string, import('@aglyn/aglyn').HostVariable>\n functions?: Record<string, import('@aglyn/aglyn').HostFunction>\n /**\n * Props declared by the reusable component being edited (AGL-1335), so\n * `{{prop.*}}` is offered in the insert picker like every other binding.\n *\n * Set ONLY inside a component editor — everywhere else the tokens would\n * resolve to nothing, and offering a binding that cannot resolve is worse\n * than not offering it. That is why this is a context value rather than\n * something the designer derives: nothing on the canvas says which\n * definition it belongs to.\n */\n componentProps?: import('@aglyn/aglyn').ReusableComponentProp[]\n /**\n * Whose properties {@link componentProps} are: a reusable component's, or a\n * shared layout's (AGL-2893). Both bind the same way; what an empty binding\n * picker tells the author to add names the right one.\n */\n componentPropsOwner?: 'component' | 'layout'\n /**\n * The site being edited, for `{{host.*}}` tokens (AGL-2881): the canvas\n * fills them in from it through the resolver the published page composes\n * with. Optional — without it the tokens draw as written.\n */\n host?: import('@aglyn/aglyn').HostTokenSource | null\n}\n\nexport const BindingPickerContext = createContext<BindingPickerContextValue>(\n {},\n)\nBindingPickerContext.displayName = 'BindingPickerContext'\n\nexport default BindingPickerContext\n"],"names":["createContext","BindingPickerContext","displayName"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAED,SAASA,aAAa,QAAQ,QAAO;AAgErC,OAAO,MAAMC,uBAAuBD,cAClC,CAAC,GACF;AACDC,qBAAqBC,WAAW,GAAG;AAEnC,eAAeD,qBAAoB"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { type HostTokenSource } from '@aglyn/aglyn';
|
|
18
|
+
import { type ReactNode } from 'react';
|
|
19
|
+
/**
|
|
20
|
+
* The site whose `{{host.*}}` tokens the canvas fills in (AGL-2881), or
|
|
21
|
+
* `undefined` to draw them as written.
|
|
22
|
+
*
|
|
23
|
+
* Every leaf the canvas draws needs the answer — the document's own nodes, a
|
|
24
|
+
* component instance's definition, a placed form's design, the layout chrome —
|
|
25
|
+
* so it is decided once, at the top of the canvas, and carried down by context
|
|
26
|
+
* rather than by a subscription on every element.
|
|
27
|
+
*/
|
|
28
|
+
export declare const CanvasHostTokensContext: import("react").Context<HostTokenSource>;
|
|
29
|
+
export interface CanvasHostTokensProviderProps {
|
|
30
|
+
children?: ReactNode;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Decides {@link CanvasHostTokensContext} from the site the console hands the
|
|
34
|
+
* binding picker, and from the WYSIWYG bindings toggle.
|
|
35
|
+
*
|
|
36
|
+
* The raw-token view keeps the tokens: an author who turned resolution off
|
|
37
|
+
* asked to see what is written, and a business name is a resolved value like
|
|
38
|
+
* a variable's. With no site to read — still loading, or a surface that has
|
|
39
|
+
* none — the tokens draw as written too.
|
|
40
|
+
*
|
|
41
|
+
* The value keeps its identity while every token resolves to the same thing.
|
|
42
|
+
* The console's host document is a new object on each snapshot, and a write to
|
|
43
|
+
* a field no token reads would otherwise redraw every leaf on the canvas.
|
|
44
|
+
*/
|
|
45
|
+
export declare function CanvasHostTokensProvider(props: CanvasHostTokensProviderProps): import("react").JSX.Element;
|
|
46
|
+
export declare namespace CanvasHostTokensProvider {
|
|
47
|
+
var displayName: string;
|
|
48
|
+
}
|
|
49
|
+
export default CanvasHostTokensContext;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
/**
|
|
3
|
+
* @license
|
|
4
|
+
* Copyright 2026 Aglyn LLC
|
|
5
|
+
*
|
|
6
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7
|
+
* you may not use this file except in compliance with the License.
|
|
8
|
+
* You may obtain a copy of the License at
|
|
9
|
+
*
|
|
10
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
11
|
+
*
|
|
12
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
13
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
14
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
15
|
+
* See the License for the specific language governing permissions and
|
|
16
|
+
* limitations under the License.
|
|
17
|
+
*/ import { hostTokenMerge } from "@aglyn/aglyn";
|
|
18
|
+
import { createContext, useContext, useMemo } from "react";
|
|
19
|
+
import useAglynBesignerFlag from "../hooks/use-aglyn-besigner-flag.js";
|
|
20
|
+
import BindingPickerContext from "./binding-picker-context.js";
|
|
21
|
+
/**
|
|
22
|
+
* The site whose `{{host.*}}` tokens the canvas fills in (AGL-2881), or
|
|
23
|
+
* `undefined` to draw them as written.
|
|
24
|
+
*
|
|
25
|
+
* Every leaf the canvas draws needs the answer — the document's own nodes, a
|
|
26
|
+
* component instance's definition, a placed form's design, the layout chrome —
|
|
27
|
+
* so it is decided once, at the top of the canvas, and carried down by context
|
|
28
|
+
* rather than by a subscription on every element.
|
|
29
|
+
*/ export const CanvasHostTokensContext = /*#__PURE__*/ createContext(undefined);
|
|
30
|
+
CanvasHostTokensContext.displayName = 'CanvasHostTokensContext';
|
|
31
|
+
/**
|
|
32
|
+
* Decides {@link CanvasHostTokensContext} from the site the console hands the
|
|
33
|
+
* binding picker, and from the WYSIWYG bindings toggle.
|
|
34
|
+
*
|
|
35
|
+
* The raw-token view keeps the tokens: an author who turned resolution off
|
|
36
|
+
* asked to see what is written, and a business name is a resolved value like
|
|
37
|
+
* a variable's. With no site to read — still loading, or a surface that has
|
|
38
|
+
* none — the tokens draw as written too.
|
|
39
|
+
*
|
|
40
|
+
* The value keeps its identity while every token resolves to the same thing.
|
|
41
|
+
* The console's host document is a new object on each snapshot, and a write to
|
|
42
|
+
* a field no token reads would otherwise redraw every leaf on the canvas.
|
|
43
|
+
*/ export function CanvasHostTokensProvider(props) {
|
|
44
|
+
const { children } = props;
|
|
45
|
+
const [resolveFlag] = useAglynBesignerFlag('resolveBindings');
|
|
46
|
+
const { host } = useContext(BindingPickerContext);
|
|
47
|
+
const site = resolveFlag === false ? undefined : host != null ? host : undefined;
|
|
48
|
+
const resolvedTokens = site ? JSON.stringify(hostTokenMerge(site)) : '';
|
|
49
|
+
const value = useMemo(()=>site, // What every token resolves to keys the value, not the document's
|
|
50
|
+
// identity.
|
|
51
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
52
|
+
[
|
|
53
|
+
resolvedTokens
|
|
54
|
+
]);
|
|
55
|
+
return /*#__PURE__*/ _jsx(CanvasHostTokensContext.Provider, {
|
|
56
|
+
value: value,
|
|
57
|
+
children: children
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
CanvasHostTokensProvider.displayName = 'CanvasHostTokensProvider';
|
|
61
|
+
export default CanvasHostTokensContext;
|
|
62
|
+
|
|
63
|
+
//# sourceMappingURL=canvas-host-tokens-context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../libs/besigner/feature/designer/src/lib/contexts/canvas-host-tokens-context.tsx"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { type HostTokenSource, hostTokenMerge } from '@aglyn/aglyn'\nimport { createContext, type ReactNode, useContext, useMemo } from 'react'\nimport useAglynBesignerFlag from '../hooks/use-aglyn-besigner-flag'\nimport BindingPickerContext from './binding-picker-context'\n\n/**\n * The site whose `{{host.*}}` tokens the canvas fills in (AGL-2881), or\n * `undefined` to draw them as written.\n *\n * Every leaf the canvas draws needs the answer — the document's own nodes, a\n * component instance's definition, a placed form's design, the layout chrome —\n * so it is decided once, at the top of the canvas, and carried down by context\n * rather than by a subscription on every element.\n */\nexport const CanvasHostTokensContext = createContext<\n HostTokenSource | undefined\n>(undefined)\nCanvasHostTokensContext.displayName = 'CanvasHostTokensContext'\n\nexport interface CanvasHostTokensProviderProps {\n children?: ReactNode\n}\n\n/**\n * Decides {@link CanvasHostTokensContext} from the site the console hands the\n * binding picker, and from the WYSIWYG bindings toggle.\n *\n * The raw-token view keeps the tokens: an author who turned resolution off\n * asked to see what is written, and a business name is a resolved value like\n * a variable's. With no site to read — still loading, or a surface that has\n * none — the tokens draw as written too.\n *\n * The value keeps its identity while every token resolves to the same thing.\n * The console's host document is a new object on each snapshot, and a write to\n * a field no token reads would otherwise redraw every leaf on the canvas.\n */\nexport function CanvasHostTokensProvider(props: CanvasHostTokensProviderProps) {\n const { children } = props\n const [resolveFlag] = useAglynBesignerFlag('resolveBindings')\n const { host } = useContext(BindingPickerContext)\n const site = resolveFlag === false ? undefined : (host ?? undefined)\n const resolvedTokens = site ? JSON.stringify(hostTokenMerge(site)) : ''\n const value = useMemo(\n () => site,\n // What every token resolves to keys the value, not the document's\n // identity.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [resolvedTokens],\n )\n return (\n <CanvasHostTokensContext.Provider value={value}>\n {children}\n </CanvasHostTokensContext.Provider>\n )\n}\nCanvasHostTokensProvider.displayName = 'CanvasHostTokensProvider'\n\nexport default CanvasHostTokensContext\n"],"names":["hostTokenMerge","createContext","useContext","useMemo","useAglynBesignerFlag","BindingPickerContext","CanvasHostTokensContext","undefined","displayName","CanvasHostTokensProvider","props","children","resolveFlag","host","site","resolvedTokens","JSON","stringify","value","Provider"],"mappings":";AAAA;;;;;;;;;;;;;;;CAeC,GAED,SAA+BA,cAAc,QAAQ,eAAc;AACnE,SAASC,aAAa,EAAkBC,UAAU,EAAEC,OAAO,QAAQ,QAAO;AAC1E,OAAOC,0BAA0B,sCAAkC;AACnE,OAAOC,0BAA0B,8BAA0B;AAE3D;;;;;;;;CAQC,GACD,OAAO,MAAMC,wCAA0BL,cAErCM,WAAU;AACZD,wBAAwBE,WAAW,GAAG;AAMtC;;;;;;;;;;;;CAYC,GACD,OAAO,SAASC,yBAAyBC,KAAoC;IAC3E,MAAM,EAAEC,QAAQ,EAAE,GAAGD;IACrB,MAAM,CAACE,YAAY,GAAGR,qBAAqB;IAC3C,MAAM,EAAES,IAAI,EAAE,GAAGX,WAAWG;IAC5B,MAAMS,OAAOF,gBAAgB,QAAQL,YAAaM,eAAAA,OAAQN;IAC1D,MAAMQ,iBAAiBD,OAAOE,KAAKC,SAAS,CAACjB,eAAec,SAAS;IACrE,MAAMI,QAAQf,QACZ,IAAMW,MACN,kEAAkE;IAClE,YAAY;IACZ,uDAAuD;IACvD;QAACC;KAAe;IAElB,qBACE,KAACT,wBAAwBa,QAAQ;QAACD,OAAOA;kBACtCP;;AAGP;AACAF,yBAAyBD,WAAW,GAAG;AAEvC,eAAeF,wBAAuB"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
/**
|
|
18
|
+
* Nodes the canvas is showing despite the hidden class (AGL-592).
|
|
19
|
+
*
|
|
20
|
+
* Read from the `revealedNodeIds` flag once, at the top of the canvas, and
|
|
21
|
+
* carried down by context: every leaf needs the answer, and a subscription
|
|
22
|
+
* per leaf would put one on every element on the page. Undefined outside the
|
|
23
|
+
* canvas, where nothing has been revealed.
|
|
24
|
+
*/
|
|
25
|
+
export declare const CanvasRevealContext: import("react").Context<readonly string[]>;
|
|
26
|
+
/**
|
|
27
|
+
* Classes the canvas is rendering without (AGL-2486). Read from the
|
|
28
|
+
* `mutedClasses` flag once, at the top of the canvas, for the same reason
|
|
29
|
+
* the reveal list is: every leaf needs the answer.
|
|
30
|
+
*/
|
|
31
|
+
export declare const CanvasMutedClassesContext: import("react").Context<readonly string[]>;
|
|
32
|
+
export default CanvasRevealContext;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/ import { createContext } from "react";
|
|
17
|
+
/**
|
|
18
|
+
* Nodes the canvas is showing despite the hidden class (AGL-592).
|
|
19
|
+
*
|
|
20
|
+
* Read from the `revealedNodeIds` flag once, at the top of the canvas, and
|
|
21
|
+
* carried down by context: every leaf needs the answer, and a subscription
|
|
22
|
+
* per leaf would put one on every element on the page. Undefined outside the
|
|
23
|
+
* canvas, where nothing has been revealed.
|
|
24
|
+
*/ export const CanvasRevealContext = createContext(undefined);
|
|
25
|
+
CanvasRevealContext.displayName = 'CanvasRevealContext';
|
|
26
|
+
/**
|
|
27
|
+
* Classes the canvas is rendering without (AGL-2486). Read from the
|
|
28
|
+
* `mutedClasses` flag once, at the top of the canvas, for the same reason
|
|
29
|
+
* the reveal list is: every leaf needs the answer.
|
|
30
|
+
*/ export const CanvasMutedClassesContext = createContext(undefined);
|
|
31
|
+
CanvasMutedClassesContext.displayName = 'CanvasMutedClassesContext';
|
|
32
|
+
export default CanvasRevealContext;
|
|
33
|
+
|
|
34
|
+
//# sourceMappingURL=canvas-reveal-context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../../../../../../libs/besigner/feature/designer/src/lib/contexts/canvas-reveal-context.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2026 Aglyn LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { createContext } from 'react'\n\n/**\n * Nodes the canvas is showing despite the hidden class (AGL-592).\n *\n * Read from the `revealedNodeIds` flag once, at the top of the canvas, and\n * carried down by context: every leaf needs the answer, and a subscription\n * per leaf would put one on every element on the page. Undefined outside the\n * canvas, where nothing has been revealed.\n */\nexport const CanvasRevealContext = createContext<readonly string[] | undefined>(\n undefined,\n)\nCanvasRevealContext.displayName = 'CanvasRevealContext'\n\n/**\n * Classes the canvas is rendering without (AGL-2486). Read from the\n * `mutedClasses` flag once, at the top of the canvas, for the same reason\n * the reveal list is: every leaf needs the answer.\n */\nexport const CanvasMutedClassesContext = createContext<\n readonly string[] | undefined\n>(undefined)\nCanvasMutedClassesContext.displayName = 'CanvasMutedClassesContext'\n\nexport default CanvasRevealContext\n"],"names":["createContext","CanvasRevealContext","undefined","displayName","CanvasMutedClassesContext"],"mappings":"AAAA;;;;;;;;;;;;;;;CAeC,GAED,SAASA,aAAa,QAAQ,QAAO;AAErC;;;;;;;CAOC,GACD,OAAO,MAAMC,sBAAsBD,cACjCE,WACD;AACDD,oBAAoBE,WAAW,GAAG;AAElC;;;;CAIC,GACD,OAAO,MAAMC,4BAA4BJ,cAEvCE,WAAU;AACZE,0BAA0BD,WAAW,GAAG;AAExC,eAAeF,oBAAmB"}
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2026 Aglyn LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import type * as Aglyn from '@aglyn/aglyn';
|
|
18
|
+
/**
|
|
19
|
+
* Host-app callbacks for reusable-component flows (AGL-35). The designer
|
|
20
|
+
* stays storage-agnostic: the console provides `onPromote` ("Save as
|
|
21
|
+
* reusable component" on a selected subtree) and `onDemote` ("Detach" an
|
|
22
|
+
* instance into an editable copy); the Attributes panel shows the actions
|
|
23
|
+
* only when the callbacks exist.
|
|
24
|
+
*/
|
|
25
|
+
export interface ComponentPromotionContextValue {
|
|
26
|
+
onPromote?: (node: Aglyn.NodeSchema<any>) => void;
|
|
27
|
+
onDemote?: (node: Aglyn.NodeSchema<any>) => void;
|
|
28
|
+
/**
|
|
29
|
+
* "Edit component" on a selected instance (AGL-1303 phase 1): the
|
|
30
|
+
* console opens the component's own besigner in a new tab. Kills the
|
|
31
|
+
* dead end where the panel offered only Save-as/Detach and an author
|
|
32
|
+
* could not find where the component's truth lives.
|
|
33
|
+
*
|
|
34
|
+
* This comment used to say phase 2's live propagation "rides AGL-1301's
|
|
35
|
+
* co-editing on component documents — no extra plumbing here". That is
|
|
36
|
+
* wrong in two ways, and it was load-bearing enough to mislead whoever
|
|
37
|
+
* picked phase 2 up (AGL-1898). AGL-1301's co-editing DID land for
|
|
38
|
+
* component documents, but its RTDB room is keyed
|
|
39
|
+
* `coedit/{org}/{host}/{docType}/{docId}/…`: a screen besigner subscribes
|
|
40
|
+
* to its own screen's room and never to a component's. Even if it did,
|
|
41
|
+
* the payload is component-internal node ids, not the
|
|
42
|
+
* `cmp__{instance}__{def}` ids a screen renders.
|
|
43
|
+
*
|
|
44
|
+
* The propagation that actually works is unrelated to co-editing:
|
|
45
|
+
* {@link definitions} arrives from a live `onSnapshot` over the host's
|
|
46
|
+
* `components` collection, so an open canvas re-renders its instances
|
|
47
|
+
* when a component's PARENT doc changes. In the component editor, Save
|
|
48
|
+
* writes only the version doc; Publish writes the parent. So today the
|
|
49
|
+
* loop is edit → Save → **Publish** → other tabs update, and a Save alone
|
|
50
|
+
* does nothing anywhere else. Whether Save should propagate is a product
|
|
51
|
+
* question (it would show screen authors component content the live site
|
|
52
|
+
* does not have) and is open on AGL-1898 — not something to infer from
|
|
53
|
+
* this comment.
|
|
54
|
+
*/
|
|
55
|
+
onEditComponent?: (node: Aglyn.NodeSchema<any>) => void;
|
|
56
|
+
/**
|
|
57
|
+
* The host's component definitions, keyed by id (AGL-1247/1251). The
|
|
58
|
+
* designer stays storage-agnostic: the console reads them and passes them
|
|
59
|
+
* down, exactly as it does the callbacks above.
|
|
60
|
+
*
|
|
61
|
+
* Three consumers, deliberately one field: the Attributes panel reads each
|
|
62
|
+
* definition's declared `props` to build an instance's fields, `NodeLeaf`
|
|
63
|
+
* renders the definition's subtree inside the instance so the canvas shows
|
|
64
|
+
* the component instead of a dashed box, and `ComponentIconComponent`
|
|
65
|
+
* reads its chosen `icon` (AGL-1193). Splitting them would let the panel,
|
|
66
|
+
* the canvas and the hierarchy disagree about what a definition is.
|
|
67
|
+
*/
|
|
68
|
+
definitions?: Record<string, Aglyn.ReusableComponentTree | undefined>;
|
|
69
|
+
/**
|
|
70
|
+
* The host's FORM entities, keyed by id — the published `rootId`/`nodes`
|
|
71
|
+
* design of each, in the shape the graft consumes
|
|
72
|
+
* (`docs/specs/reusable-forms.md`).
|
|
73
|
+
*
|
|
74
|
+
* Beside {@link definitions} rather than in a context of its own because a
|
|
75
|
+
* placed form and a component instance are one mechanism: both are a node
|
|
76
|
+
* standing for a tree stored on another document, both are expanded by
|
|
77
|
+
* `composeReusableComponentNodes`, and `NodeLeaf` needs both in the same
|
|
78
|
+
* memo — a form design may contain an instance, and a component may contain
|
|
79
|
+
* a placed form. Two contexts would have to be kept in step by hand for a
|
|
80
|
+
* canvas that has to graft them together anyway.
|
|
81
|
+
*
|
|
82
|
+
* `undefined` while the read is still settling, distinct from `{}` for "this
|
|
83
|
+
* host has none": grafting against an empty map would draw the page's own
|
|
84
|
+
* fields and swap them for the entity's a beat later.
|
|
85
|
+
*/
|
|
86
|
+
formDesigns?: Record<string, Aglyn.PlacedFormDesign | undefined>;
|
|
87
|
+
}
|
|
88
|
+
export declare const ComponentPromotionContext: import("react").Context<ComponentPromotionContextValue>;
|
|
89
|
+
export default ComponentPromotionContext;
|