@vef-framework-react/form-editor 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/_internal/_rolldown/runtime.cjs +1 -0
- package/dist/cjs/components/button/index.cjs +1 -0
- package/dist/cjs/components/checkbox-group-field/index.cjs +1 -0
- package/dist/cjs/components/code-editor/code-editor-input.cjs +1 -0
- package/dist/cjs/components/code-editor/index.cjs +1 -0
- package/dist/cjs/components/containers/index.cjs +1 -0
- package/dist/cjs/components/date-field/index.cjs +1 -0
- package/dist/cjs/components/display/index.cjs +1 -0
- package/dist/cjs/components/field-entries.cjs +1 -0
- package/dist/cjs/components/mobile/alert-block.cjs +1 -0
- package/dist/cjs/components/mobile/button.cjs +1 -0
- package/dist/cjs/components/mobile/checkbox-group.cjs +1 -0
- package/dist/cjs/components/mobile/date-adapters.cjs +1 -0
- package/dist/cjs/components/mobile/date.cjs +1 -0
- package/dist/cjs/components/mobile/daterange.cjs +1 -0
- package/dist/cjs/components/mobile/datetime.cjs +1 -0
- package/dist/cjs/components/mobile/definitions.cjs +1 -0
- package/dist/cjs/components/mobile/divider.cjs +1 -0
- package/dist/cjs/components/mobile/input-cell.cjs +1 -0
- package/dist/cjs/components/mobile/number.cjs +1 -0
- package/dist/cjs/components/mobile/option-group.cjs +1 -0
- package/dist/cjs/components/mobile/paragraph.cjs +1 -0
- package/dist/cjs/components/mobile/picker-trigger.cjs +1 -0
- package/dist/cjs/components/mobile/radio.cjs +1 -0
- package/dist/cjs/components/mobile/scope.cjs +1 -0
- package/dist/cjs/components/mobile/select.cjs +1 -0
- package/dist/cjs/components/mobile/switch.cjs +1 -0
- package/dist/cjs/components/mobile/textarea.cjs +1 -0
- package/dist/cjs/components/mobile/textfield.cjs +1 -0
- package/dist/cjs/components/mobile/theme.cjs +1 -0
- package/dist/cjs/components/number-field/index.cjs +1 -0
- package/dist/cjs/components/radio-field/index.cjs +1 -0
- package/dist/cjs/components/select-field/index.cjs +1 -0
- package/dist/cjs/components/switch-field/index.cjs +1 -0
- package/dist/cjs/components/textarea-field/index.cjs +1 -0
- package/dist/cjs/components/textfield/index.cjs +1 -0
- package/dist/cjs/editor/canvas/canvas-field.cjs +1 -0
- package/dist/cjs/editor/canvas/canvas.cjs +1 -0
- package/dist/cjs/editor/canvas/drop-indicator.cjs +1 -0
- package/dist/cjs/editor/canvas/drop-zones.cjs +1 -0
- package/dist/cjs/editor/canvas/json-split-view.cjs +1 -0
- package/dist/cjs/editor/canvas/mobile-seed-state.cjs +2 -0
- package/dist/cjs/editor/canvas/phone-frame.cjs +1 -0
- package/dist/cjs/editor/dnd.cjs +1 -0
- package/dist/cjs/editor/editor-layout-context.cjs +1 -0
- package/dist/cjs/editor/footer/footer.cjs +1 -0
- package/dist/cjs/editor/form-config/form-basics-tab.cjs +1 -0
- package/dist/cjs/editor/form-config/form-config-drawer.cjs +1 -0
- package/dist/cjs/editor/form-config/outline-tab.cjs +1 -0
- package/dist/cjs/editor/form-editor.cjs +1 -0
- package/dist/cjs/editor/palette/field-groups.cjs +1 -0
- package/dist/cjs/editor/palette/palette-group.cjs +1 -0
- package/dist/cjs/editor/palette/palette-item.cjs +1 -0
- package/dist/cjs/editor/palette/palette-panel.cjs +1 -0
- package/dist/cjs/editor/preview-effects.cjs +1 -0
- package/dist/cjs/editor/preview-runtime-context.cjs +1 -0
- package/dist/cjs/editor/properties/block-layout-section.cjs +1 -0
- package/dist/cjs/editor/properties/container-properties.cjs +1 -0
- package/dist/cjs/editor/properties/entries/built-ins.cjs +1 -0
- package/dist/cjs/editor/properties/entries/checkbox-entry.cjs +1 -0
- package/dist/cjs/editor/properties/entries/coerce.cjs +1 -0
- package/dist/cjs/editor/properties/entries/entry-field.cjs +1 -0
- package/dist/cjs/editor/properties/entries/icon-entry.cjs +1 -0
- package/dist/cjs/editor/properties/entries/index.cjs +1 -0
- package/dist/cjs/editor/properties/entries/key-entry.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/action-editor.cjs +2 -0
- package/dist/cjs/editor/properties/entries/linkage/actions-editor.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/condition-editor.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/container-linkage-section.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/expression-assist.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/index.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/linkage-rules-entry.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/mutators.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/options.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/rule-diagnostics.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/rule-list-editor.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/styles.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/trigger-editor.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/use-linkage-editor-model.cjs +1 -0
- package/dist/cjs/editor/properties/entries/linkage/use-stable-options.cjs +1 -0
- package/dist/cjs/editor/properties/entries/number-entry.cjs +1 -0
- package/dist/cjs/editor/properties/entries/options-source/index.cjs +1 -0
- package/dist/cjs/editor/properties/entries/options-source/source-mutators.cjs +1 -0
- package/dist/cjs/editor/properties/entries/select-entry.cjs +1 -0
- package/dist/cjs/editor/properties/entries/text-entry.cjs +1 -0
- package/dist/cjs/editor/properties/form-data-sources-panel.cjs +1 -0
- package/dist/cjs/editor/properties/form-linkage-panel.cjs +1 -0
- package/dist/cjs/editor/properties/form-variables-panel.cjs +1 -0
- package/dist/cjs/editor/properties/option-editors.cjs +1 -0
- package/dist/cjs/editor/properties/panel-header.cjs +1 -0
- package/dist/cjs/editor/properties/properties-empty.cjs +1 -0
- package/dist/cjs/editor/properties/properties-header.cjs +1 -0
- package/dist/cjs/editor/properties/properties-panel.cjs +1 -0
- package/dist/cjs/editor/properties/properties-provider.cjs +1 -0
- package/dist/cjs/editor/properties/properties-tabs.cjs +1 -0
- package/dist/cjs/editor/properties/use-confirmable-kind-switch.cjs +1 -0
- package/dist/cjs/editor/remove-node-confirm.cjs +1 -0
- package/dist/cjs/editor/schema-apply.cjs +2 -0
- package/dist/cjs/editor/styles.cjs +1 -0
- package/dist/cjs/editor/toolbar/notify.cjs +1 -0
- package/dist/cjs/editor/toolbar/schema-io.cjs +1 -0
- package/dist/cjs/editor/toolbar/toolbar.cjs +1 -0
- package/dist/cjs/editor/use-editor-shortcuts.cjs +1 -0
- package/dist/cjs/editor/validation-summary.cjs +1 -0
- package/dist/cjs/engine/assert-never.cjs +1 -0
- package/dist/cjs/engine/conversion/index.cjs +1 -0
- package/dist/cjs/engine/ids.cjs +1 -0
- package/dist/cjs/engine/keys.cjs +1 -0
- package/dist/cjs/engine/linkage/cycle.cjs +1 -0
- package/dist/cjs/engine/linkage/default-evaluator.cjs +1 -0
- package/dist/cjs/engine/linkage/effects.cjs +1 -0
- package/dist/cjs/engine/linkage/evaluator.cjs +1 -0
- package/dist/cjs/engine/linkage/index.cjs +1 -0
- package/dist/cjs/engine/linkage/operators.cjs +1 -0
- package/dist/cjs/engine/linkage/source-tracking.cjs +1 -0
- package/dist/cjs/engine/linkage/taxonomy.cjs +1 -0
- package/dist/cjs/engine/linkage/validator.cjs +1 -0
- package/dist/cjs/engine/registry/defaults-mobile.cjs +1 -0
- package/dist/cjs/engine/registry/defaults.cjs +1 -0
- package/dist/cjs/engine/registry/form-field-registry.cjs +1 -0
- package/dist/cjs/engine/schema/edit-ops.cjs +1 -0
- package/dist/cjs/engine/schema/mutate.cjs +1 -0
- package/dist/cjs/engine/schema/nodes.cjs +1 -0
- package/dist/cjs/engine/schema/permission-bridge.cjs +1 -0
- package/dist/cjs/engine/schema/presentation.cjs +1 -0
- package/dist/cjs/engine/schema/reconcile.cjs +1 -0
- package/dist/cjs/engine/schema/removal-impact.cjs +1 -0
- package/dist/cjs/engine/schema/rewrite.cjs +1 -0
- package/dist/cjs/engine/schema/validate.cjs +1 -0
- package/dist/cjs/engine/schema/walk.cjs +1 -0
- package/dist/cjs/engine/validation.cjs +1 -0
- package/dist/cjs/icons.cjs +1 -0
- package/dist/cjs/index.cjs +1 -0
- package/dist/cjs/render/chrome/mobile-chrome.cjs +1 -0
- package/dist/cjs/render/chrome/pc-chrome.cjs +1 -0
- package/dist/cjs/render/chrome/subform-shell.cjs +1 -0
- package/dist/cjs/render/data-source-context.cjs +0 -0
- package/dist/cjs/render/flex-style.cjs +1 -0
- package/dist/cjs/render/form-field.cjs +1 -0
- package/dist/cjs/render/form-renderer.cjs +1 -0
- package/dist/cjs/render/grid-style.cjs +1 -0
- package/dist/cjs/render/parts/field-shell.cjs +1 -0
- package/dist/cjs/render/parts/label.cjs +1 -0
- package/dist/cjs/render/parts/options-status.cjs +1 -0
- package/dist/cjs/render/stack-style.cjs +1 -0
- package/dist/cjs/render/subform-columns.cjs +1 -0
- package/dist/cjs/render/submit.cjs +1 -0
- package/dist/cjs/runtime/effects.cjs +1 -0
- package/dist/cjs/runtime/resolve-scope-values.cjs +1 -0
- package/dist/cjs/runtime/runtime-context.cjs +1 -0
- package/dist/cjs/runtime/runtime-state-controller.cjs +1 -0
- package/dist/cjs/runtime/stabilize-state-map.cjs +1 -0
- package/dist/cjs/store/engine-provider.cjs +1 -0
- package/dist/cjs/store/form-store.cjs +1 -0
- package/dist/cjs/types/chrome.cjs +0 -0
- package/dist/cjs/types/component.cjs +1 -0
- package/dist/cjs/types/data-source.cjs +1 -0
- package/dist/cjs/types/index.cjs +1 -0
- package/dist/cjs/types/linkage.cjs +0 -0
- package/dist/cjs/types/properties.cjs +1 -0
- package/dist/cjs/types/schema.cjs +1 -0
- package/dist/es/components/button/index.js +183 -0
- package/dist/es/components/checkbox-group-field/index.js +103 -0
- package/dist/es/components/code-editor/code-editor-input.js +3 -0
- package/dist/es/components/code-editor/index.js +212 -0
- package/dist/es/components/containers/index.js +72 -0
- package/dist/es/components/date-field/index.js +197 -0
- package/dist/es/components/display/index.js +276 -0
- package/dist/es/components/field-entries.js +184 -0
- package/dist/es/components/mobile/alert-block.js +40 -0
- package/dist/es/components/mobile/button.js +41 -0
- package/dist/es/components/mobile/checkbox-group.js +35 -0
- package/dist/es/components/mobile/date-adapters.js +16 -0
- package/dist/es/components/mobile/date.js +42 -0
- package/dist/es/components/mobile/daterange.js +48 -0
- package/dist/es/components/mobile/datetime.js +42 -0
- package/dist/es/components/mobile/definitions.js +58 -0
- package/dist/es/components/mobile/divider.js +10 -0
- package/dist/es/components/mobile/input-cell.js +56 -0
- package/dist/es/components/mobile/number.js +73 -0
- package/dist/es/components/mobile/option-group.js +34 -0
- package/dist/es/components/mobile/paragraph.js +30 -0
- package/dist/es/components/mobile/picker-trigger.js +94 -0
- package/dist/es/components/mobile/radio.js +35 -0
- package/dist/es/components/mobile/scope.js +61 -0
- package/dist/es/components/mobile/select.js +45 -0
- package/dist/es/components/mobile/switch.js +22 -0
- package/dist/es/components/mobile/textarea.js +32 -0
- package/dist/es/components/mobile/textfield.js +30 -0
- package/dist/es/components/mobile/theme.js +8 -0
- package/dist/es/components/number-field/index.js +186 -0
- package/dist/es/components/radio-field/index.js +139 -0
- package/dist/es/components/select-field/index.js +128 -0
- package/dist/es/components/switch-field/index.js +133 -0
- package/dist/es/components/textarea-field/index.js +137 -0
- package/dist/es/components/textfield/index.js +138 -0
- package/dist/es/editor/canvas/canvas-field.js +202 -0
- package/dist/es/editor/canvas/canvas.js +415 -0
- package/dist/es/editor/canvas/drop-indicator.js +42 -0
- package/dist/es/editor/canvas/drop-zones.js +42 -0
- package/dist/es/editor/canvas/json-split-view.js +148 -0
- package/dist/es/editor/canvas/mobile-seed-state.js +103 -0
- package/dist/es/editor/canvas/phone-frame.js +109 -0
- package/dist/es/editor/dnd.js +75 -0
- package/dist/es/editor/editor-layout-context.js +34 -0
- package/dist/es/editor/footer/footer.js +154 -0
- package/dist/es/editor/form-config/form-basics-tab.js +184 -0
- package/dist/es/editor/form-config/form-config-drawer.js +224 -0
- package/dist/es/editor/form-config/outline-tab.js +132 -0
- package/dist/es/editor/form-editor.js +179 -0
- package/dist/es/editor/palette/field-groups.js +19 -0
- package/dist/es/editor/palette/palette-group.js +147 -0
- package/dist/es/editor/palette/palette-item.js +153 -0
- package/dist/es/editor/palette/palette-panel.js +109 -0
- package/dist/es/editor/preview-effects.js +22 -0
- package/dist/es/editor/preview-runtime-context.js +24 -0
- package/dist/es/editor/properties/block-layout-section.js +161 -0
- package/dist/es/editor/properties/container-properties.js +575 -0
- package/dist/es/editor/properties/entries/built-ins.js +21 -0
- package/dist/es/editor/properties/entries/checkbox-entry.js +31 -0
- package/dist/es/editor/properties/entries/coerce.js +8 -0
- package/dist/es/editor/properties/entries/entry-field.js +43 -0
- package/dist/es/editor/properties/entries/icon-entry.js +21 -0
- package/dist/es/editor/properties/entries/index.js +9 -0
- package/dist/es/editor/properties/entries/key-entry.js +29 -0
- package/dist/es/editor/properties/entries/linkage/action-editor.js +260 -0
- package/dist/es/editor/properties/entries/linkage/actions-editor.js +64 -0
- package/dist/es/editor/properties/entries/linkage/condition-editor.js +265 -0
- package/dist/es/editor/properties/entries/linkage/container-linkage-section.js +71 -0
- package/dist/es/editor/properties/entries/linkage/expression-assist.js +87 -0
- package/dist/es/editor/properties/entries/linkage/index.js +3 -0
- package/dist/es/editor/properties/entries/linkage/linkage-rules-entry.js +110 -0
- package/dist/es/editor/properties/entries/linkage/mutators.js +209 -0
- package/dist/es/editor/properties/entries/linkage/options.js +155 -0
- package/dist/es/editor/properties/entries/linkage/rule-diagnostics.js +58 -0
- package/dist/es/editor/properties/entries/linkage/rule-list-editor.js +126 -0
- package/dist/es/editor/properties/entries/linkage/styles.js +276 -0
- package/dist/es/editor/properties/entries/linkage/trigger-editor.js +64 -0
- package/dist/es/editor/properties/entries/linkage/use-linkage-editor-model.js +20 -0
- package/dist/es/editor/properties/entries/linkage/use-stable-options.js +12 -0
- package/dist/es/editor/properties/entries/number-entry.js +25 -0
- package/dist/es/editor/properties/entries/options-source/index.js +122 -0
- package/dist/es/editor/properties/entries/options-source/source-mutators.js +31 -0
- package/dist/es/editor/properties/entries/select-entry.js +23 -0
- package/dist/es/editor/properties/entries/text-entry.js +23 -0
- package/dist/es/editor/properties/form-data-sources-panel.js +170 -0
- package/dist/es/editor/properties/form-linkage-panel.js +36 -0
- package/dist/es/editor/properties/form-variables-panel.js +184 -0
- package/dist/es/editor/properties/option-editors.js +170 -0
- package/dist/es/editor/properties/panel-header.js +93 -0
- package/dist/es/editor/properties/properties-empty.js +62 -0
- package/dist/es/editor/properties/properties-header.js +31 -0
- package/dist/es/editor/properties/properties-panel.js +195 -0
- package/dist/es/editor/properties/properties-provider.js +95 -0
- package/dist/es/editor/properties/properties-tabs.js +91 -0
- package/dist/es/editor/properties/use-confirmable-kind-switch.js +26 -0
- package/dist/es/editor/remove-node-confirm.js +60 -0
- package/dist/es/editor/schema-apply.js +36 -0
- package/dist/es/editor/styles.js +74 -0
- package/dist/es/editor/toolbar/notify.js +59 -0
- package/dist/es/editor/toolbar/schema-io.js +107 -0
- package/dist/es/editor/toolbar/toolbar.js +394 -0
- package/dist/es/editor/use-editor-shortcuts.js +43 -0
- package/dist/es/editor/validation-summary.js +66 -0
- package/dist/es/engine/assert-never.js +8 -0
- package/dist/es/engine/conversion/index.js +127 -0
- package/dist/es/engine/ids.js +18 -0
- package/dist/es/engine/keys.js +48 -0
- package/dist/es/engine/linkage/cycle.js +25 -0
- package/dist/es/engine/linkage/default-evaluator.js +79 -0
- package/dist/es/engine/linkage/effects.js +41 -0
- package/dist/es/engine/linkage/evaluator.js +119 -0
- package/dist/es/engine/linkage/index.js +9 -0
- package/dist/es/engine/linkage/operators.js +44 -0
- package/dist/es/engine/linkage/source-tracking.js +17 -0
- package/dist/es/engine/linkage/taxonomy.js +51 -0
- package/dist/es/engine/linkage/validator.js +360 -0
- package/dist/es/engine/registry/defaults-mobile.js +12 -0
- package/dist/es/engine/registry/defaults.js +25 -0
- package/dist/es/engine/registry/form-field-registry.js +52 -0
- package/dist/es/engine/schema/edit-ops.js +264 -0
- package/dist/es/engine/schema/mutate.js +39 -0
- package/dist/es/engine/schema/nodes.js +61 -0
- package/dist/es/engine/schema/permission-bridge.js +46 -0
- package/dist/es/engine/schema/presentation.js +37 -0
- package/dist/es/engine/schema/reconcile.js +258 -0
- package/dist/es/engine/schema/removal-impact.js +59 -0
- package/dist/es/engine/schema/rewrite.js +11 -0
- package/dist/es/engine/schema/validate.js +320 -0
- package/dist/es/engine/schema/walk.js +103 -0
- package/dist/es/engine/validation.js +122 -0
- package/dist/es/icons.js +74 -0
- package/dist/es/index.js +54 -0
- package/dist/es/render/chrome/mobile-chrome.js +119 -0
- package/dist/es/render/chrome/pc-chrome.js +76 -0
- package/dist/es/render/chrome/subform-shell.js +38 -0
- package/dist/es/render/data-source-context.js +0 -0
- package/dist/es/render/flex-style.js +24 -0
- package/dist/es/render/form-field.js +37 -0
- package/dist/es/render/form-renderer.js +516 -0
- package/dist/es/render/grid-style.js +23 -0
- package/dist/es/render/parts/field-shell.js +119 -0
- package/dist/es/render/parts/label.js +44 -0
- package/dist/es/render/parts/options-status.js +19 -0
- package/dist/es/render/stack-style.js +13 -0
- package/dist/es/render/subform-columns.js +118 -0
- package/dist/es/render/submit.js +112 -0
- package/dist/es/runtime/effects.js +109 -0
- package/dist/es/runtime/resolve-scope-values.js +14 -0
- package/dist/es/runtime/runtime-context.js +10 -0
- package/dist/es/runtime/runtime-state-controller.js +99 -0
- package/dist/es/runtime/stabilize-state-map.js +14 -0
- package/dist/es/store/engine-provider.js +37 -0
- package/dist/es/store/form-store.js +306 -0
- package/dist/es/types/chrome.js +1 -0
- package/dist/es/types/component.js +13 -0
- package/dist/es/types/data-source.js +5 -0
- package/dist/es/types/index.js +5 -0
- package/dist/es/types/linkage.js +1 -0
- package/dist/es/types/properties.js +7 -0
- package/dist/es/types/schema.js +15 -0
- package/dist/types/src/components/button/index.d.ts +8 -0
- package/dist/types/src/components/checkbox-group-field/index.d.ts +2 -0
- package/dist/types/src/components/code-editor/code-editor-input.d.ts +1 -0
- package/dist/types/src/components/code-editor/index.d.ts +4 -0
- package/dist/types/src/components/containers/index.d.ts +12 -0
- package/dist/types/src/components/date-field/index.d.ts +4 -0
- package/dist/types/src/components/display/index.d.ts +4 -0
- package/dist/types/src/components/field-entries.d.ts +103 -0
- package/dist/types/src/components/mobile/alert-block.d.ts +12 -0
- package/dist/types/src/components/mobile/button.d.ts +9 -0
- package/dist/types/src/components/mobile/checkbox-group.d.ts +11 -0
- package/dist/types/src/components/mobile/date-adapters.d.ts +28 -0
- package/dist/types/src/components/mobile/date.d.ts +10 -0
- package/dist/types/src/components/mobile/daterange.d.ts +11 -0
- package/dist/types/src/components/mobile/datetime.d.ts +10 -0
- package/dist/types/src/components/mobile/definitions.d.ts +9 -0
- package/dist/types/src/components/mobile/divider.d.ts +10 -0
- package/dist/types/src/components/mobile/input-cell.d.ts +30 -0
- package/dist/types/src/components/mobile/number.d.ts +25 -0
- package/dist/types/src/components/mobile/option-group.d.ts +17 -0
- package/dist/types/src/components/mobile/paragraph.d.ts +10 -0
- package/dist/types/src/components/mobile/picker-trigger.d.ts +31 -0
- package/dist/types/src/components/mobile/radio.d.ts +12 -0
- package/dist/types/src/components/mobile/scope.d.ts +42 -0
- package/dist/types/src/components/mobile/select.d.ts +12 -0
- package/dist/types/src/components/mobile/switch.d.ts +14 -0
- package/dist/types/src/components/mobile/textarea.d.ts +3 -0
- package/dist/types/src/components/mobile/textfield.d.ts +11 -0
- package/dist/types/src/components/mobile/theme.d.ts +16 -0
- package/dist/types/src/components/number-field/index.d.ts +2 -0
- package/dist/types/src/components/radio-field/index.d.ts +2 -0
- package/dist/types/src/components/select-field/index.d.ts +2 -0
- package/dist/types/src/components/switch-field/index.d.ts +2 -0
- package/dist/types/src/components/textarea-field/index.d.ts +2 -0
- package/dist/types/src/components/textfield/index.d.ts +11 -0
- package/dist/types/src/editor/canvas/canvas-field.d.ts +24 -0
- package/dist/types/src/editor/canvas/canvas.d.ts +11 -0
- package/dist/types/src/editor/canvas/drop-indicator.d.ts +14 -0
- package/dist/types/src/editor/canvas/drop-zones.d.ts +48 -0
- package/dist/types/src/editor/canvas/json-split-view.d.ts +15 -0
- package/dist/types/src/editor/canvas/mobile-seed-state.d.ts +9 -0
- package/dist/types/src/editor/canvas/phone-frame.d.ts +15 -0
- package/dist/types/src/editor/dnd.d.ts +88 -0
- package/dist/types/src/editor/editor-layout-context.d.ts +53 -0
- package/dist/types/src/editor/footer/footer.d.ts +7 -0
- package/dist/types/src/editor/form-config/form-basics-tab.d.ts +34 -0
- package/dist/types/src/editor/form-config/form-config-drawer.d.ts +8 -0
- package/dist/types/src/editor/form-config/outline-tab.d.ts +2 -0
- package/dist/types/src/editor/form-editor.d.ts +142 -0
- package/dist/types/src/editor/palette/field-groups.d.ts +12 -0
- package/dist/types/src/editor/palette/palette-group.d.ts +31 -0
- package/dist/types/src/editor/palette/palette-item.d.ts +34 -0
- package/dist/types/src/editor/palette/palette-panel.d.ts +17 -0
- package/dist/types/src/editor/preview-effects.d.ts +14 -0
- package/dist/types/src/editor/preview-runtime-context.d.ts +23 -0
- package/dist/types/src/editor/properties/block-layout-section.d.ts +19 -0
- package/dist/types/src/editor/properties/container-properties.d.ts +19 -0
- package/dist/types/src/editor/properties/entries/built-ins.d.ts +19 -0
- package/dist/types/src/editor/properties/entries/checkbox-entry.d.ts +3 -0
- package/dist/types/src/editor/properties/entries/coerce.d.ts +6 -0
- package/dist/types/src/editor/properties/entries/entry-field.d.ts +29 -0
- package/dist/types/src/editor/properties/entries/icon-entry.d.ts +8 -0
- package/dist/types/src/editor/properties/entries/index.d.ts +8 -0
- package/dist/types/src/editor/properties/entries/key-entry.d.ts +14 -0
- package/dist/types/src/editor/properties/entries/linkage/action-editor.d.ts +42 -0
- package/dist/types/src/editor/properties/entries/linkage/actions-editor.d.ts +43 -0
- package/dist/types/src/editor/properties/entries/linkage/condition-editor.d.ts +28 -0
- package/dist/types/src/editor/properties/entries/linkage/container-linkage-section.d.ts +14 -0
- package/dist/types/src/editor/properties/entries/linkage/expression-assist.d.ts +33 -0
- package/dist/types/src/editor/properties/entries/linkage/index.d.ts +1 -0
- package/dist/types/src/editor/properties/entries/linkage/linkage-rules-entry.d.ts +17 -0
- package/dist/types/src/editor/properties/entries/linkage/mutators.d.ts +73 -0
- package/dist/types/src/editor/properties/entries/linkage/options.d.ts +72 -0
- package/dist/types/src/editor/properties/entries/linkage/rule-diagnostics.d.ts +20 -0
- package/dist/types/src/editor/properties/entries/linkage/rule-list-editor.d.ts +75 -0
- package/dist/types/src/editor/properties/entries/linkage/styles.d.ts +46 -0
- package/dist/types/src/editor/properties/entries/linkage/trigger-editor.d.ts +35 -0
- package/dist/types/src/editor/properties/entries/linkage/use-linkage-editor-model.d.ts +46 -0
- package/dist/types/src/editor/properties/entries/linkage/use-stable-options.d.ts +17 -0
- package/dist/types/src/editor/properties/entries/number-entry.d.ts +3 -0
- package/dist/types/src/editor/properties/entries/options-source/index.d.ts +9 -0
- package/dist/types/src/editor/properties/entries/options-source/source-mutators.d.ts +14 -0
- package/dist/types/src/editor/properties/entries/select-entry.d.ts +3 -0
- package/dist/types/src/editor/properties/entries/text-entry.d.ts +3 -0
- package/dist/types/src/editor/properties/form-data-sources-panel.d.ts +16 -0
- package/dist/types/src/editor/properties/form-linkage-panel.d.ts +13 -0
- package/dist/types/src/editor/properties/form-variables-panel.d.ts +17 -0
- package/dist/types/src/editor/properties/option-editors.d.ts +33 -0
- package/dist/types/src/editor/properties/panel-header.d.ts +21 -0
- package/dist/types/src/editor/properties/properties-empty.d.ts +13 -0
- package/dist/types/src/editor/properties/properties-header.d.ts +13 -0
- package/dist/types/src/editor/properties/properties-panel.d.ts +18 -0
- package/dist/types/src/editor/properties/properties-provider.d.ts +42 -0
- package/dist/types/src/editor/properties/properties-tabs.d.ts +24 -0
- package/dist/types/src/editor/properties/use-confirmable-kind-switch.d.ts +38 -0
- package/dist/types/src/editor/remove-node-confirm.d.ts +8 -0
- package/dist/types/src/editor/schema-apply.d.ts +25 -0
- package/dist/types/src/editor/styles.d.ts +37 -0
- package/dist/types/src/editor/toolbar/notify.d.ts +13 -0
- package/dist/types/src/editor/toolbar/schema-io.d.ts +12 -0
- package/dist/types/src/editor/toolbar/toolbar.d.ts +42 -0
- package/dist/types/src/editor/use-editor-shortcuts.d.ts +23 -0
- package/dist/types/src/editor/validation-summary.d.ts +19 -0
- package/dist/types/src/engine/assert-never.d.ts +18 -0
- package/dist/types/src/engine/conversion/index.d.ts +87 -0
- package/dist/types/src/engine/ids.d.ts +14 -0
- package/dist/types/src/engine/keys.d.ts +70 -0
- package/dist/types/src/engine/linkage/cycle.d.ts +28 -0
- package/dist/types/src/engine/linkage/default-evaluator.d.ts +10 -0
- package/dist/types/src/engine/linkage/effects.d.ts +76 -0
- package/dist/types/src/engine/linkage/evaluator.d.ts +72 -0
- package/dist/types/src/engine/linkage/index.d.ts +8 -0
- package/dist/types/src/engine/linkage/operators.d.ts +23 -0
- package/dist/types/src/engine/linkage/source-tracking.d.ts +25 -0
- package/dist/types/src/engine/linkage/taxonomy.d.ts +49 -0
- package/dist/types/src/engine/linkage/validator.d.ts +23 -0
- package/dist/types/src/engine/registry/defaults-mobile.d.ts +17 -0
- package/dist/types/src/engine/registry/defaults.d.ts +22 -0
- package/dist/types/src/engine/registry/form-field-registry.d.ts +79 -0
- package/dist/types/src/engine/schema/edit-ops.d.ts +101 -0
- package/dist/types/src/engine/schema/mutate.d.ts +41 -0
- package/dist/types/src/engine/schema/nodes.d.ts +34 -0
- package/dist/types/src/engine/schema/permission-bridge.d.ts +37 -0
- package/dist/types/src/engine/schema/presentation.d.ts +30 -0
- package/dist/types/src/engine/schema/reconcile.d.ts +80 -0
- package/dist/types/src/engine/schema/removal-impact.d.ts +39 -0
- package/dist/types/src/engine/schema/rewrite.d.ts +15 -0
- package/dist/types/src/engine/schema/validate.d.ts +36 -0
- package/dist/types/src/engine/schema/walk.d.ts +90 -0
- package/dist/types/src/engine/validation.d.ts +139 -0
- package/dist/types/src/icons.d.ts +8 -0
- package/dist/types/src/index.d.ts +39 -0
- package/dist/types/src/render/chrome/mobile-chrome.d.ts +9 -0
- package/dist/types/src/render/chrome/pc-chrome.d.ts +7 -0
- package/dist/types/src/render/chrome/subform-shell.d.ts +17 -0
- package/dist/types/src/render/data-source-context.d.ts +42 -0
- package/dist/types/src/render/flex-style.d.ts +26 -0
- package/dist/types/src/render/form-field.d.ts +32 -0
- package/dist/types/src/render/form-renderer.d.ts +65 -0
- package/dist/types/src/render/grid-style.d.ts +24 -0
- package/dist/types/src/render/parts/field-shell.d.ts +33 -0
- package/dist/types/src/render/parts/label.d.ts +20 -0
- package/dist/types/src/render/parts/options-status.d.ts +14 -0
- package/dist/types/src/render/stack-style.d.ts +19 -0
- package/dist/types/src/render/subform-columns.d.ts +16 -0
- package/dist/types/src/render/submit.d.ts +91 -0
- package/dist/types/src/runtime/effects.d.ts +77 -0
- package/dist/types/src/runtime/resolve-scope-values.d.ts +8 -0
- package/dist/types/src/runtime/runtime-context.d.ts +21 -0
- package/dist/types/src/runtime/runtime-state-controller.d.ts +33 -0
- package/dist/types/src/runtime/stabilize-state-map.d.ts +12 -0
- package/dist/types/src/runtime/types.d.ts +13 -0
- package/dist/types/src/store/engine-provider.d.ts +50 -0
- package/dist/types/src/store/form-store.d.ts +234 -0
- package/dist/types/src/types/chrome.d.ts +51 -0
- package/dist/types/src/types/component.d.ts +116 -0
- package/dist/types/src/types/data-source.d.ts +70 -0
- package/dist/types/src/types/index.d.ts +6 -0
- package/dist/types/src/types/linkage.d.ts +350 -0
- package/dist/types/src/types/properties.d.ts +122 -0
- package/dist/types/src/types/schema.d.ts +839 -0
- package/package.json +77 -0
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/*! @vef-framework-react/form-editor v2.4.0 made by Venus | 2026-06-15T15:10:34.033Z */
|
|
2
|
+
import { findNode as e, findScope as t, nodeLabel as n, walkNodes as r } from "./walk.js";
|
|
3
|
+
import { collectSubtreeKeysByScope as i } from "../keys.js";
|
|
4
|
+
import { removeBlock as a } from "./mutate.js";
|
|
5
|
+
import { pruneFormLinkageForRootBucket as o, pruneScopedReferences as s } from "./reconcile.js";
|
|
6
|
+
//#region src/engine/schema/removal-impact.ts
|
|
7
|
+
function c(e) {
|
|
8
|
+
return e.removedRules.length > 0 || e.unreachable.length > 0 || e.formRulesRemoved > 0;
|
|
9
|
+
}
|
|
10
|
+
var l = {
|
|
11
|
+
removedRules: [],
|
|
12
|
+
unreachable: [],
|
|
13
|
+
formRulesRemoved: 0
|
|
14
|
+
};
|
|
15
|
+
function u(n, r, c) {
|
|
16
|
+
let u = e(n, r);
|
|
17
|
+
if (!u) return l;
|
|
18
|
+
let p = i(u, t(n, r) ?? []), m = s(a(n, r), p), h = d(n), g = d(m), _ = [];
|
|
19
|
+
for (let [t, n] of h) {
|
|
20
|
+
if (e(m, t) === void 0) continue;
|
|
21
|
+
let r = g.get(t)?.ruleIds ?? /* @__PURE__ */ new Set(), i = [...n.ruleIds].filter((e) => !r.has(e)).length;
|
|
22
|
+
i > 0 && _.push({
|
|
23
|
+
ownerId: t,
|
|
24
|
+
ownerLabel: n.label,
|
|
25
|
+
count: i
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
let v = new Set(f(n).map((e) => e.id)), y = f(m).filter((e) => !v.has(e.id)), b = 0;
|
|
29
|
+
if (c?.rules !== void 0) {
|
|
30
|
+
let e = o(c, p);
|
|
31
|
+
b = c.rules.length - (e.rules?.length ?? 0);
|
|
32
|
+
}
|
|
33
|
+
return {
|
|
34
|
+
removedRules: _,
|
|
35
|
+
unreachable: y,
|
|
36
|
+
formRulesRemoved: b
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
function d(e) {
|
|
40
|
+
let t = /* @__PURE__ */ new Map();
|
|
41
|
+
return r(e, (e) => {
|
|
42
|
+
let r = e.linkage?.rules;
|
|
43
|
+
r === void 0 || r.length === 0 || t.set(e.id, {
|
|
44
|
+
label: n(e) ?? e.id,
|
|
45
|
+
ruleIds: new Set(r.map((e) => e.id))
|
|
46
|
+
});
|
|
47
|
+
}), t;
|
|
48
|
+
}
|
|
49
|
+
function f(e) {
|
|
50
|
+
let t = [];
|
|
51
|
+
return r(e, (e) => {
|
|
52
|
+
e.linkage?.defaults?.hidden === !0 && ((e.linkage.rules?.some((e) => e.actions.some((e) => e.type === "show")) ?? !1) || t.push({
|
|
53
|
+
id: e.id,
|
|
54
|
+
label: n(e) ?? e.id
|
|
55
|
+
}));
|
|
56
|
+
}), t;
|
|
57
|
+
}
|
|
58
|
+
//#endregion
|
|
59
|
+
export { u as collectRemovalImpact, c as hasRemovalImpact };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*! @vef-framework-react/form-editor v2.4.0 made by Venus | 2026-06-15T15:10:34.033Z */
|
|
2
|
+
import { containerBodies as e, mapPreservingIdentity as t, withContainerBodies as n } from "./nodes.js";
|
|
3
|
+
import { isContainerNode as r } from "./walk.js";
|
|
4
|
+
//#region src/engine/schema/rewrite.ts
|
|
5
|
+
function i(i, a) {
|
|
6
|
+
if (!r(i)) return i;
|
|
7
|
+
let o = e(i), s = t(o, a);
|
|
8
|
+
return s === o ? i : n(i, s);
|
|
9
|
+
}
|
|
10
|
+
//#endregion
|
|
11
|
+
export { i as rewriteContainerBodies };
|
|
@@ -0,0 +1,320 @@
|
|
|
1
|
+
/*! @vef-framework-react/form-editor v2.4.0 made by Venus | 2026-06-15T15:10:34.033Z */
|
|
2
|
+
import { CONTAINER_TYPES as e, GAP_SCALES as t } from "../../types/schema.js";
|
|
3
|
+
import { createIssue as n, hasErrorIssues as r, isRecord as i, validateRemoteRequest as a } from "../validation.js";
|
|
4
|
+
import { validateLinkageSchema as o } from "../linkage/validator.js";
|
|
5
|
+
//#region src/engine/schema/validate.ts
|
|
6
|
+
var s = /^\w+$/, c = /^[A-Z_]\w*$/i;
|
|
7
|
+
function l(e) {
|
|
8
|
+
return c.test(e);
|
|
9
|
+
}
|
|
10
|
+
var u = new Set(Object.keys({
|
|
11
|
+
string: !0,
|
|
12
|
+
number: !0,
|
|
13
|
+
boolean: !0,
|
|
14
|
+
json: !0
|
|
15
|
+
}));
|
|
16
|
+
function d(e, t) {
|
|
17
|
+
if (!i(e)) return {
|
|
18
|
+
valid: !1,
|
|
19
|
+
issues: [n("", "schema_not_object")]
|
|
20
|
+
};
|
|
21
|
+
let a = [], o = e;
|
|
22
|
+
(typeof o.id != "string" || o.id.length === 0) && a.push(n("id", "id_required")), o.version !== 2 && a.push(n("version", "version_unsupported")), f(o.variables, a);
|
|
23
|
+
let s = p(o.dataSources, a), { presentations: c } = o;
|
|
24
|
+
if (!i(c)) return a.push(n("presentations", "presentation_not_object")), {
|
|
25
|
+
valid: !1,
|
|
26
|
+
issues: a
|
|
27
|
+
};
|
|
28
|
+
g({
|
|
29
|
+
dataSourceIds: s,
|
|
30
|
+
formLinkage: o.linkage,
|
|
31
|
+
issues: a,
|
|
32
|
+
layer: c.pc,
|
|
33
|
+
registry: t.pc,
|
|
34
|
+
where: "presentations.pc"
|
|
35
|
+
}), c.mobile !== void 0 && g({
|
|
36
|
+
dataSourceIds: s,
|
|
37
|
+
formLinkage: void 0,
|
|
38
|
+
issues: a,
|
|
39
|
+
layer: c.mobile,
|
|
40
|
+
registry: t.mobile,
|
|
41
|
+
where: "presentations.mobile"
|
|
42
|
+
});
|
|
43
|
+
let l = !r(a);
|
|
44
|
+
return {
|
|
45
|
+
valid: l,
|
|
46
|
+
...l ? { schema: o } : {},
|
|
47
|
+
issues: a
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
function f(e, t) {
|
|
51
|
+
if (e === void 0) return;
|
|
52
|
+
if (!Array.isArray(e)) {
|
|
53
|
+
t.push(n("variables", "variables_invalid"));
|
|
54
|
+
return;
|
|
55
|
+
}
|
|
56
|
+
let r = e, a = /* @__PURE__ */ new Set(), o = /* @__PURE__ */ new Set();
|
|
57
|
+
for (let [e, s] of r.entries()) {
|
|
58
|
+
let r = `variables[${e}]`;
|
|
59
|
+
if (!i(s)) {
|
|
60
|
+
t.push(n(r, "variables_invalid"));
|
|
61
|
+
continue;
|
|
62
|
+
}
|
|
63
|
+
typeof s.id != "string" || s.id.length === 0 || a.has(s.id) ? t.push(n(`${r}.id`, "variables_invalid")) : a.add(s.id), typeof s.name != "string" || !l(s.name) || o.has(s.name) ? t.push(n(`${r}.name`, "variables_invalid")) : o.add(s.name), (typeof s.type != "string" || !u.has(s.type)) && t.push(n(`${r}.type`, "variables_invalid"));
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
function p(e, t) {
|
|
67
|
+
let r = /* @__PURE__ */ new Set();
|
|
68
|
+
if (e === void 0) return r;
|
|
69
|
+
if (!Array.isArray(e)) return t.push(n("dataSources", "data_sources_invalid")), r;
|
|
70
|
+
let o = e;
|
|
71
|
+
for (let [e, s] of o.entries()) {
|
|
72
|
+
let o = `dataSources[${e}]`;
|
|
73
|
+
if (!i(s)) {
|
|
74
|
+
t.push(n(o, "data_sources_invalid"));
|
|
75
|
+
continue;
|
|
76
|
+
}
|
|
77
|
+
switch (typeof s.id != "string" || s.id.length === 0 || r.has(s.id) ? t.push(n(`${o}.id`, "data_sources_invalid")) : r.add(s.id), typeof s.name != "string" && t.push(n(`${o}.name`, "data_sources_invalid")), s.kind) {
|
|
78
|
+
case "static":
|
|
79
|
+
m(s.options, `${o}.options`, "data_sources_invalid", t);
|
|
80
|
+
break;
|
|
81
|
+
case "remote":
|
|
82
|
+
t.push(...a(s.request, `${o}.request`)), h(s.mapping, `${o}.mapping`, "data_sources_invalid", t);
|
|
83
|
+
break;
|
|
84
|
+
default: t.push(n(`${o}.kind`, "data_sources_invalid"));
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
return r;
|
|
88
|
+
}
|
|
89
|
+
function m(e, t, r, a) {
|
|
90
|
+
if (!Array.isArray(e)) {
|
|
91
|
+
a.push(n(t, r));
|
|
92
|
+
return;
|
|
93
|
+
}
|
|
94
|
+
let o = e;
|
|
95
|
+
for (let [e, s] of o.entries()) (!i(s) || typeof s.label != "string" || typeof s.value != "string" && typeof s.value != "number") && a.push(n(`${t}[${e}]`, r));
|
|
96
|
+
}
|
|
97
|
+
function h(e, t, r, a) {
|
|
98
|
+
if (e !== void 0) {
|
|
99
|
+
if (!i(e)) {
|
|
100
|
+
a.push(n(t, r));
|
|
101
|
+
return;
|
|
102
|
+
}
|
|
103
|
+
for (let i of [
|
|
104
|
+
"labelKey",
|
|
105
|
+
"valueKey",
|
|
106
|
+
"disabledKey",
|
|
107
|
+
"descriptionKey"
|
|
108
|
+
]) e[i] !== void 0 && typeof e[i] != "string" && a.push(n(`${t}.${i}`, r));
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
function g(e) {
|
|
112
|
+
let { dataSourceIds: t, formLinkage: a, issues: s, layer: c, registry: l, where: u } = e;
|
|
113
|
+
if (!i(c)) {
|
|
114
|
+
s.push(n(u, "presentation_not_object"));
|
|
115
|
+
return;
|
|
116
|
+
}
|
|
117
|
+
if (!Array.isArray(c.children)) {
|
|
118
|
+
s.push(n(`${u}.children`, "children_not_array"));
|
|
119
|
+
return;
|
|
120
|
+
}
|
|
121
|
+
let d = {
|
|
122
|
+
issues: s,
|
|
123
|
+
registry: l,
|
|
124
|
+
seenIds: /* @__PURE__ */ new Set(),
|
|
125
|
+
keysByScope: /* @__PURE__ */ new Map(),
|
|
126
|
+
dataSourceIds: t
|
|
127
|
+
}, f = s.length;
|
|
128
|
+
for (let [e, t] of c.children.entries()) _(t, `${u}.children[${e}]`, [], d);
|
|
129
|
+
r(s.slice(f)) || s.push(...o(c, a).issues);
|
|
130
|
+
}
|
|
131
|
+
function _(e, t, r, a) {
|
|
132
|
+
if (!i(e)) {
|
|
133
|
+
a.issues.push(n(t, "block_not_object"));
|
|
134
|
+
return;
|
|
135
|
+
}
|
|
136
|
+
I(e.id, t, a), R(e.span, t, a), z(e.flex, t, a);
|
|
137
|
+
let { type: o } = e;
|
|
138
|
+
if (typeof o != "string" || o.length === 0) {
|
|
139
|
+
a.issues.push(n(`${t}.type`, "type_required"));
|
|
140
|
+
return;
|
|
141
|
+
}
|
|
142
|
+
switch (o) {
|
|
143
|
+
case "section":
|
|
144
|
+
D(e, t, r, a);
|
|
145
|
+
return;
|
|
146
|
+
case "tabs":
|
|
147
|
+
N(e, t, r, a);
|
|
148
|
+
return;
|
|
149
|
+
case "subform":
|
|
150
|
+
P(e, t, r, a);
|
|
151
|
+
return;
|
|
152
|
+
case "flex":
|
|
153
|
+
A(e, t, r, a);
|
|
154
|
+
return;
|
|
155
|
+
case "grid":
|
|
156
|
+
j(e, t, r, a);
|
|
157
|
+
return;
|
|
158
|
+
default: b(e, o, t, r, a);
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
var v = [
|
|
162
|
+
"label",
|
|
163
|
+
"placeholder",
|
|
164
|
+
"helperText",
|
|
165
|
+
"title",
|
|
166
|
+
"text",
|
|
167
|
+
"message"
|
|
168
|
+
];
|
|
169
|
+
function y(e, t, r) {
|
|
170
|
+
for (let i of v) e[i] !== void 0 && typeof e[i] != "string" && r.issues.push(n(`${t}.${i}`, "display_text_invalid", { prop: i }));
|
|
171
|
+
}
|
|
172
|
+
function b(e, t, r, i, a) {
|
|
173
|
+
if (!a.registry.has(t)) {
|
|
174
|
+
a.issues.push(n(`${r}.type`, "unknown_field_type", { type: t }));
|
|
175
|
+
return;
|
|
176
|
+
}
|
|
177
|
+
y(e, r, a);
|
|
178
|
+
let o = typeof e.key == "string" && e.key.length > 0, s = a.registry.get(t)?.config.keyed === !0;
|
|
179
|
+
s && !o && a.issues.push(n(`${r}.key`, "key_required", { type: t })), o && !s ? a.issues.push(n(`${r}.key`, "stray_key", { type: t })) : o && L(e.key, i, r, a), S(e.validate, `${r}.validate`, a), e.dataSource !== void 0 && x(e.dataSource, `${r}.dataSource`, a);
|
|
180
|
+
}
|
|
181
|
+
function x(e, t, r) {
|
|
182
|
+
if (!i(e)) {
|
|
183
|
+
r.issues.push(n(t, "data_source_invalid"));
|
|
184
|
+
return;
|
|
185
|
+
}
|
|
186
|
+
switch (e.kind) {
|
|
187
|
+
case "static":
|
|
188
|
+
m(e.options, `${t}.options`, "data_source_invalid", r.issues);
|
|
189
|
+
return;
|
|
190
|
+
case "ref": {
|
|
191
|
+
let { dataSourceId: i } = e;
|
|
192
|
+
typeof i == "string" ? i.length === 0 ? r.issues.push(n(`${t}.dataSourceId`, "data_source_id_empty")) : r.dataSourceIds.has(i) || r.issues.push(n(`${t}.dataSourceId`, "data_source_ref_unknown", { id: i })) : r.issues.push(n(`${t}.dataSourceId`, "data_source_invalid"));
|
|
193
|
+
return;
|
|
194
|
+
}
|
|
195
|
+
case "remote":
|
|
196
|
+
r.issues.push(...a(e.request, `${t}.request`)), h(e.mapping, `${t}.mapping`, "data_source_invalid", r.issues);
|
|
197
|
+
return;
|
|
198
|
+
default: r.issues.push(n(`${t}.kind`, "data_source_invalid"));
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
function S(e, t, r) {
|
|
202
|
+
if (e === void 0) return;
|
|
203
|
+
if (!i(e)) {
|
|
204
|
+
r.issues.push(n(t, "validate_malformed"));
|
|
205
|
+
return;
|
|
206
|
+
}
|
|
207
|
+
let { max: a, maxLength: o, min: s, minLength: c, pattern: l } = e;
|
|
208
|
+
typeof c == "number" && typeof o == "number" && c > o && r.issues.push(n(`${t}.minLength`, "validate_range_invalid", {
|
|
209
|
+
lower: "minLength",
|
|
210
|
+
upper: "maxLength"
|
|
211
|
+
})), typeof s == "number" && typeof a == "number" && s > a && r.issues.push(n(`${t}.min`, "validate_range_invalid", {
|
|
212
|
+
lower: "min",
|
|
213
|
+
upper: "max"
|
|
214
|
+
})), typeof l == "string" && l.length > 0 && !C(l) && r.issues.push(n(`${t}.pattern`, "pattern_invalid"));
|
|
215
|
+
}
|
|
216
|
+
function C(e) {
|
|
217
|
+
try {
|
|
218
|
+
return new RegExp(e), !0;
|
|
219
|
+
} catch {
|
|
220
|
+
return !1;
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
var w = new Set(t);
|
|
224
|
+
function T(e, t, r) {
|
|
225
|
+
e !== void 0 && !w.has(e) && r.issues.push(n(`${t}.gap`, "gap_invalid"));
|
|
226
|
+
}
|
|
227
|
+
function E(e, t, r, i) {
|
|
228
|
+
typeof e.key == "string" && e.key.length > 0 && i.issues.push(n(`${r}.key`, "stray_key_on_container", { type: t }));
|
|
229
|
+
}
|
|
230
|
+
function D(e, t, r, i) {
|
|
231
|
+
E(e, "section", t, i), e.variant !== "card" && e.variant !== "collapse" && i.issues.push(n(`${t}.variant`, "variant_invalid")), e.title !== void 0 && typeof e.title != "string" && i.issues.push(n(`${t}.title`, "title_invalid")), T(e.gap, t, i), F(e.children, `${t}.children`, r, i);
|
|
232
|
+
}
|
|
233
|
+
var O = new Set([
|
|
234
|
+
"start",
|
|
235
|
+
"center",
|
|
236
|
+
"end",
|
|
237
|
+
"between",
|
|
238
|
+
"around"
|
|
239
|
+
]), k = new Set([
|
|
240
|
+
"start",
|
|
241
|
+
"center",
|
|
242
|
+
"end",
|
|
243
|
+
"stretch"
|
|
244
|
+
]);
|
|
245
|
+
function A(e, t, r, i) {
|
|
246
|
+
E(e, "flex", t, i), e.direction !== void 0 && e.direction !== "row" && e.direction !== "column" && i.issues.push(n(`${t}.direction`, "flex_invalid")), e.justify !== void 0 && !O.has(e.justify) && i.issues.push(n(`${t}.justify`, "flex_invalid")), e.align !== void 0 && !k.has(e.align) && i.issues.push(n(`${t}.align`, "flex_invalid")), e.wrap !== void 0 && typeof e.wrap != "boolean" && i.issues.push(n(`${t}.wrap`, "flex_invalid")), e.gap !== void 0 && !M(e.gap) && i.issues.push(n(`${t}.gap`, "gap_invalid")), F(e.children, `${t}.children`, r, i);
|
|
247
|
+
}
|
|
248
|
+
function j(e, t, r, i) {
|
|
249
|
+
E(e, "grid", t, i), e.columns !== void 0 && (typeof e.columns != "number" || !Number.isInteger(e.columns) || e.columns < 1 || e.columns > 24) && i.issues.push(n(`${t}.columns`, "columns_invalid", { max: 24 })), e.gap !== void 0 && !M(e.gap) && i.issues.push(n(`${t}.gap`, "gap_invalid")), e.rowGap !== void 0 && !M(e.rowGap) && i.issues.push(n(`${t}.rowGap`, "gap_invalid")), F(e.children, `${t}.children`, r, i);
|
|
250
|
+
}
|
|
251
|
+
function M(e) {
|
|
252
|
+
return typeof e == "number" && Number.isInteger(e) && e >= 0;
|
|
253
|
+
}
|
|
254
|
+
function N(e, t, r, a) {
|
|
255
|
+
if (E(e, "tabs", t, a), T(e.gap, t, a), !Array.isArray(e.tabs)) {
|
|
256
|
+
a.issues.push(n(`${t}.tabs`, "children_not_array"));
|
|
257
|
+
return;
|
|
258
|
+
}
|
|
259
|
+
if (e.tabs.length === 0) {
|
|
260
|
+
a.issues.push(n(`${t}.tabs`, "tabs_empty"));
|
|
261
|
+
return;
|
|
262
|
+
}
|
|
263
|
+
let { tabs: o } = e;
|
|
264
|
+
for (let [e, s] of o.entries()) {
|
|
265
|
+
let o = `${t}.tabs[${e}]`;
|
|
266
|
+
if (!i(s)) {
|
|
267
|
+
a.issues.push(n(o, "tab_malformed"));
|
|
268
|
+
continue;
|
|
269
|
+
}
|
|
270
|
+
I(s.id, o, a), typeof s.label != "string" && a.issues.push(n(`${o}.label`, "tab_malformed")), F(s.children, `${o}.children`, r, a);
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
function P(t, r, a, o) {
|
|
274
|
+
t.variant !== "table" && t.variant !== "stack" && (t.variant = "stack");
|
|
275
|
+
let s = typeof t.key == "string" && t.key.length > 0;
|
|
276
|
+
s ? L(t.key, a, r, o) : o.issues.push(n(`${r}.key`, "key_required", { type: "subform" })), T(t.gap, r, o), t.minRows !== void 0 && !M(t.minRows) && o.issues.push(n(`${r}.minRows`, "rows_bound_invalid")), t.maxRows !== void 0 && !M(t.maxRows) && o.issues.push(n(`${r}.maxRows`, "rows_bound_invalid")), typeof t.minRows == "number" && typeof t.maxRows == "number" && t.minRows > t.maxRows && o.issues.push(n(`${r}.minRows`, "rows_bound_invalid"));
|
|
277
|
+
let c = s ? [...a, t.key] : a;
|
|
278
|
+
if (F(t.template, `${r}.template`, c, o), t.variant === "table" && Array.isArray(t.template)) for (let [a, s] of t.template.entries()) {
|
|
279
|
+
let t = i(s) ? s.type : void 0, c = typeof t == "string" && e.includes(t), l = i(s) && typeof s.key == "string" && s.key.length > 0;
|
|
280
|
+
(c || !l) && o.issues.push(n(`${r}.template[${a}]`, "subform_table_column"));
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
function F(e, t, r, i) {
|
|
284
|
+
if (!Array.isArray(e)) {
|
|
285
|
+
i.issues.push(n(t, "children_not_array"));
|
|
286
|
+
return;
|
|
287
|
+
}
|
|
288
|
+
let a = e;
|
|
289
|
+
for (let [e, n] of a.entries()) _(n, `${t}[${e}]`, r, i);
|
|
290
|
+
}
|
|
291
|
+
function I(e, t, r) {
|
|
292
|
+
if (typeof e != "string" || e.length === 0) {
|
|
293
|
+
r.issues.push(n(`${t}.id`, "id_required"));
|
|
294
|
+
return;
|
|
295
|
+
}
|
|
296
|
+
if (r.seenIds.has(e)) {
|
|
297
|
+
r.issues.push(n(`${t}.id`, "duplicate_id", { id: e }));
|
|
298
|
+
return;
|
|
299
|
+
}
|
|
300
|
+
r.seenIds.add(e);
|
|
301
|
+
}
|
|
302
|
+
function L(e, t, r, i) {
|
|
303
|
+
s.test(e) || i.issues.push(n(`${r}.key`, "key_invalid_charset", { key: e }));
|
|
304
|
+
let a = t.join("/"), o = i.keysByScope.get(a) ?? /* @__PURE__ */ new Set();
|
|
305
|
+
o.has(e) ? i.issues.push(n(`${r}.key`, "duplicate_key", { key: e })) : o.add(e), i.keysByScope.set(a, o);
|
|
306
|
+
}
|
|
307
|
+
function R(e, t, r) {
|
|
308
|
+
e !== void 0 && (typeof e != "number" || !Number.isInteger(e) || e < 1 || e > 24) && r.issues.push(n(`${t}.span`, "span_invalid", { max: 24 }));
|
|
309
|
+
}
|
|
310
|
+
function z(e, t, r) {
|
|
311
|
+
if (e !== void 0) {
|
|
312
|
+
if (!i(e)) {
|
|
313
|
+
r.issues.push(n(`${t}.flex`, "flex_invalid"));
|
|
314
|
+
return;
|
|
315
|
+
}
|
|
316
|
+
e.grow !== void 0 && (typeof e.grow != "number" || e.grow < 0) && r.issues.push(n(`${t}.flex.grow`, "flex_invalid")), e.shrink !== void 0 && (typeof e.shrink != "number" || e.shrink < 0) && r.issues.push(n(`${t}.flex.shrink`, "flex_invalid")), e.basis !== void 0 && typeof e.basis != "string" && r.issues.push(n(`${t}.flex.basis`, "flex_invalid"));
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
//#endregion
|
|
320
|
+
export { l as isValidVariableName, d as validateSchema };
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
/*! @vef-framework-react/form-editor v2.4.0 made by Venus | 2026-06-15T15:10:34.033Z */
|
|
2
|
+
import { CONTAINER_TYPES as e } from "../../types/schema.js";
|
|
3
|
+
import { bodyScopeKey as t, containerBodies as n } from "./nodes.js";
|
|
4
|
+
import { isShallowEqual as r } from "@vef-framework-react/shared";
|
|
5
|
+
//#region src/engine/schema/walk.ts
|
|
6
|
+
var i = new Set(e);
|
|
7
|
+
function a(e) {
|
|
8
|
+
return i.has(e.type);
|
|
9
|
+
}
|
|
10
|
+
function o(e) {
|
|
11
|
+
return !i.has(e.type);
|
|
12
|
+
}
|
|
13
|
+
function s(e, t) {
|
|
14
|
+
return r(e, t);
|
|
15
|
+
}
|
|
16
|
+
function c(e) {
|
|
17
|
+
return e.length === 0;
|
|
18
|
+
}
|
|
19
|
+
function l(e) {
|
|
20
|
+
if ("label" in e && typeof e.label == "string" && e.label.length > 0) return e.label;
|
|
21
|
+
if ("title" in e && typeof e.title == "string" && e.title.length > 0) return e.title;
|
|
22
|
+
}
|
|
23
|
+
function u(e, r, i) {
|
|
24
|
+
if (i(e, r), a(e)) {
|
|
25
|
+
let a = t(e), o = a === void 0 ? r : [...r, a];
|
|
26
|
+
for (let t of n(e)) for (let e of t) u(e, o, i);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
function d(e, t) {
|
|
30
|
+
for (let n of e.children) u(n, [], t);
|
|
31
|
+
}
|
|
32
|
+
function f(e, t) {
|
|
33
|
+
d(e, (e, n) => {
|
|
34
|
+
o(e) && t(e, n);
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
function p(e) {
|
|
38
|
+
let t = 0;
|
|
39
|
+
return f(e, () => {
|
|
40
|
+
t += 1;
|
|
41
|
+
}), t;
|
|
42
|
+
}
|
|
43
|
+
function m(e, r) {
|
|
44
|
+
function i(e, o) {
|
|
45
|
+
let s = r(e, o);
|
|
46
|
+
if (s !== void 0) return s;
|
|
47
|
+
if (a(e)) {
|
|
48
|
+
let r = t(e), a = r === void 0 ? o : [...o, r];
|
|
49
|
+
for (let t of n(e)) for (let e of t) {
|
|
50
|
+
let t = i(e, a);
|
|
51
|
+
if (t !== void 0) return t;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
for (let t of e.children) {
|
|
56
|
+
let e = i(t, []);
|
|
57
|
+
if (e !== void 0) return e;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
function h(e, t) {
|
|
61
|
+
return m(e, (e) => e.id === t ? e : void 0);
|
|
62
|
+
}
|
|
63
|
+
function g(e, t) {
|
|
64
|
+
let n = h(e, t);
|
|
65
|
+
return n && o(n) ? n : void 0;
|
|
66
|
+
}
|
|
67
|
+
function _(e, t) {
|
|
68
|
+
return m(e, (e, n) => e.id === t ? n : void 0);
|
|
69
|
+
}
|
|
70
|
+
function v(e) {
|
|
71
|
+
let t = /* @__PURE__ */ new Set();
|
|
72
|
+
return u(e, [], (e) => {
|
|
73
|
+
t.add(e.id);
|
|
74
|
+
}), t;
|
|
75
|
+
}
|
|
76
|
+
function y(e, t) {
|
|
77
|
+
return v(e).has(t);
|
|
78
|
+
}
|
|
79
|
+
function b(e, t) {
|
|
80
|
+
return m(e, (e) => {
|
|
81
|
+
if (a(e)) {
|
|
82
|
+
for (let r of n(e)) if (r.some((e) => e.id === t)) return e;
|
|
83
|
+
}
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
function x(e, t) {
|
|
87
|
+
function r(e, i) {
|
|
88
|
+
if (e.id === t) return {
|
|
89
|
+
node: e,
|
|
90
|
+
parent: i
|
|
91
|
+
};
|
|
92
|
+
if (a(e)) for (let t of n(e)) for (let n of t) {
|
|
93
|
+
let t = r(n, e);
|
|
94
|
+
if (t !== void 0) return t;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
for (let t of e.children) {
|
|
98
|
+
let e = r(t);
|
|
99
|
+
if (e !== void 0) return e;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
//#endregion
|
|
103
|
+
export { y as containsNode, p as countFields, g as findField, h as findNode, x as findNodeWithParentContainer, b as findParentContainer, _ as findScope, a as isContainerNode, o as isLeafField, c as isRootScope, l as nodeLabel, s as scopeEquals, f as walkFields, d as walkNodes };
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
/*! @vef-framework-react/form-editor v2.4.0 made by Venus | 2026-06-15T15:10:34.033Z */
|
|
2
|
+
import { isPlainObject as e } from "@vef-framework-react/shared";
|
|
3
|
+
//#region src/engine/validation.ts
|
|
4
|
+
var t = new Set([
|
|
5
|
+
"data_source_ref_unknown",
|
|
6
|
+
"request_incomplete",
|
|
7
|
+
"condition_group_empty",
|
|
8
|
+
"source_key_empty",
|
|
9
|
+
"source_key_unresolved",
|
|
10
|
+
"source_empty",
|
|
11
|
+
"actions_empty",
|
|
12
|
+
"target_key_empty",
|
|
13
|
+
"target_key_unresolved",
|
|
14
|
+
"variable_empty",
|
|
15
|
+
"data_source_id_empty",
|
|
16
|
+
"retrigger_ignored",
|
|
17
|
+
"default_hidden_unreachable",
|
|
18
|
+
"subform_table_column"
|
|
19
|
+
]), n = {
|
|
20
|
+
schema_not_object: "Schema 必须是对象",
|
|
21
|
+
id_required: "id 必须为非空字符串",
|
|
22
|
+
version_unsupported: "version 必须为 2",
|
|
23
|
+
presentation_not_object: "必须是对象",
|
|
24
|
+
variables_invalid: "variables 定义无效:需为对象数组,每项包含非空 id、合法的 name(字母 / 数字 / 下划线,不能以数字开头)、受支持的 type,且 name 唯一",
|
|
25
|
+
data_sources_invalid: "dataSources 定义无效:需为对象数组,每项包含唯一非空 id、字符串 name 与合法的 kind(static / remote)定义",
|
|
26
|
+
block_not_object: "节点必须是对象",
|
|
27
|
+
children_not_array: "必须是数组",
|
|
28
|
+
tabs_empty: "tabs 不能为空",
|
|
29
|
+
tab_malformed: "标签页必须是对象且 label 为字符串",
|
|
30
|
+
type_required: "type 必须为非空字符串",
|
|
31
|
+
flex_invalid: "flex 配置无效:grow / shrink 须为非负数,basis 须为字符串",
|
|
32
|
+
gap_invalid: "间距取值非法(需为预设档位或非负整数)",
|
|
33
|
+
variant_invalid: "variant 必须为 \"card\" 或 \"collapse\"",
|
|
34
|
+
title_invalid: "title 必须为字符串",
|
|
35
|
+
rows_bound_invalid: "行数限制无效:minRows / maxRows 须为非负整数且 minRows ≤ maxRows",
|
|
36
|
+
subform_table_column: "表格子表单的列必须是绑定字段(不能是容器或展示 / 按钮类组件)",
|
|
37
|
+
validate_malformed: "validate 必须是对象",
|
|
38
|
+
pattern_invalid: "pattern 不是合法的正则表达式",
|
|
39
|
+
data_source_invalid: "数据源定义无效:kind 须为 static / ref / remote 且结构完整",
|
|
40
|
+
request_malformed: "request 必须是对象且 resource / action 为字符串",
|
|
41
|
+
request_incomplete: "request 的 resource / action 尚未填写",
|
|
42
|
+
linkage_malformed: "linkage 结构无效:必须是对象",
|
|
43
|
+
rules_not_array: "rules 必须是数组",
|
|
44
|
+
rule_malformed: "规则结构无效:必须是对象",
|
|
45
|
+
trigger_malformed: "触发器结构无效:必须是包含 kind 的对象",
|
|
46
|
+
trigger_requires_keyed_leaf: "kind \"change\" 只能用于 keyed 叶子字段",
|
|
47
|
+
condition_malformed: "条件结构无效",
|
|
48
|
+
condition_kind_invalid: "kind 不是受支持的条件类型",
|
|
49
|
+
logic_invalid: "logic 必须为 \"all\" 或 \"any\"",
|
|
50
|
+
condition_group_empty: "条件组没有子条件,规则不会生效",
|
|
51
|
+
operator_invalid: "operator 不是受支持的联动操作符",
|
|
52
|
+
source_key_empty: "sourceKey 尚未选择",
|
|
53
|
+
source_empty: "表达式 / 脚本内容为空",
|
|
54
|
+
actions_not_array: "actions 必须是数组",
|
|
55
|
+
actions_empty: "规则没有任何动作,不会生效",
|
|
56
|
+
action_malformed: "动作结构无效",
|
|
57
|
+
defaults_requires_keyed_leaf: "defaults.required 只能用于 keyed 叶子字段",
|
|
58
|
+
defaults_on_form_scope: "表单级联动不支持 defaults(表单没有自身字段)",
|
|
59
|
+
default_hidden_unreachable: "默认隐藏但没有任何「显示」动作的规则,运行时将永远不可见",
|
|
60
|
+
target_key_empty: "targetKey 尚未选择",
|
|
61
|
+
variable_empty: "variable 尚未填写",
|
|
62
|
+
data_source_id_empty: "dataSourceId 尚未选择",
|
|
63
|
+
value_malformed: "取值结构无效:须为 literal 或 expression 形态",
|
|
64
|
+
alert_level_invalid: "level 不是受支持的提示级别",
|
|
65
|
+
retrigger_invalid: "retrigger 必须为 \"edge\" 或 \"always\"",
|
|
66
|
+
retrigger_ignored: "retrigger 仅对条件触发生效,事件触发将忽略该配置",
|
|
67
|
+
self_reference: "条件不能引用本节点自身(该规则会写入自身的值)"
|
|
68
|
+
}, r = {
|
|
69
|
+
duplicate_id: "id 与其他节点重复:{id}",
|
|
70
|
+
unknown_field_type: "字段类型 \"{type}\" 未在字段注册表中",
|
|
71
|
+
key_required: "key 必须为非空字符串(\"{type}\" 是 keyed 类型)",
|
|
72
|
+
stray_key: "key 不应出现(字段类型 \"{type}\" 不是 keyed 字段)",
|
|
73
|
+
stray_key_on_container: "key 不应出现(\"{type}\" 是纯布局容器)",
|
|
74
|
+
duplicate_key: "key 在同一作用域内重复:{key}",
|
|
75
|
+
key_invalid_charset: "key 只能包含字母、数字和下划线:{key}",
|
|
76
|
+
display_text_invalid: "{prop} 必须为字符串",
|
|
77
|
+
span_invalid: "span 必须为 1..{max} 的整数",
|
|
78
|
+
columns_invalid: "columns 必须为 1 到 {max} 之间的整数",
|
|
79
|
+
validate_range_invalid: "{lower} 不能大于 {upper}",
|
|
80
|
+
data_source_ref_unknown: "引用的数据源不存在:{id}",
|
|
81
|
+
trigger_kind_invalid: "kind \"{kind}\" 不能用于该作用域",
|
|
82
|
+
action_unknown_type: "type \"{type}\" 不是受支持的联动动作",
|
|
83
|
+
state_action_on_edge_trigger: "\"{type}\" 是状态动作,只能用于条件触发",
|
|
84
|
+
state_action_on_form_scope: "\"{type}\" 是状态动作,不能用于表单级联动",
|
|
85
|
+
action_requires_keyed_leaf: "\"{type}\" 只能用于 keyed 叶子字段",
|
|
86
|
+
source_key_unresolved: "sourceKey 未指向同一作用域内已存在的 keyed 节点:{key}",
|
|
87
|
+
target_key_unresolved: "targetKey 未指向同一作用域内已存在的 keyed 节点:{key}",
|
|
88
|
+
cycle_detected: "联动规则存在循环依赖:{cycle}"
|
|
89
|
+
};
|
|
90
|
+
function i(e) {
|
|
91
|
+
return e in r;
|
|
92
|
+
}
|
|
93
|
+
function a(e, t) {
|
|
94
|
+
if (!i(e)) return n[e];
|
|
95
|
+
let a = t;
|
|
96
|
+
return r[e].replaceAll(/\{(?<name>\w+)\}/g, (e, t) => String(a[t]));
|
|
97
|
+
}
|
|
98
|
+
function o(e, t) {
|
|
99
|
+
return a(e, t);
|
|
100
|
+
}
|
|
101
|
+
function s(e, n, r, i) {
|
|
102
|
+
return {
|
|
103
|
+
path: e,
|
|
104
|
+
code: n,
|
|
105
|
+
severity: t.has(n) ? "warning" : "error",
|
|
106
|
+
message: a(n, r),
|
|
107
|
+
...i === void 0 ? {} : { ruleId: i }
|
|
108
|
+
};
|
|
109
|
+
}
|
|
110
|
+
function c(e) {
|
|
111
|
+
return e.some((e) => e.severity === "error");
|
|
112
|
+
}
|
|
113
|
+
function l(t) {
|
|
114
|
+
return e(t);
|
|
115
|
+
}
|
|
116
|
+
function u(e, t, n) {
|
|
117
|
+
if (!l(e)) return [s(t, "request_malformed", void 0, n)];
|
|
118
|
+
let r = [], { action: i, resource: a } = e;
|
|
119
|
+
return typeof a == "string" ? a.length === 0 && r.push(s(`${t}.resource`, "request_incomplete", void 0, n)) : r.push(s(`${t}.resource`, "request_malformed", void 0, n)), typeof i == "string" ? i.length === 0 && r.push(s(`${t}.action`, "request_incomplete", void 0, n)) : r.push(s(`${t}.action`, "request_malformed", void 0, n)), r;
|
|
120
|
+
}
|
|
121
|
+
//#endregion
|
|
122
|
+
export { s as createIssue, o as formatIssueMessage, c as hasErrorIssues, l as isRecord, u as validateRemoteRequest };
|
package/dist/es/icons.js
ADDED
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/*! @vef-framework-react/form-editor v2.4.0 made by Venus | 2026-06-15T15:10:34.033Z */
|
|
2
|
+
import { jsx as e } from "@emotion/react/jsx-runtime";
|
|
3
|
+
import { DynamicIcon as t, Icon as n } from "@vef-framework-react/components";
|
|
4
|
+
import { BracesIcon as r, CalendarIcon as i, CalendarRangeIcon as a, ChevronDownIcon as o, ChevronRightIcon as s, ChevronUpIcon as c, CircleDotIcon as l, CircleHelpIcon as u, CircleXIcon as d, ClipboardListIcon as f, ClockIcon as p, Code2Icon as m, CodeIcon as h, CopyIcon as g, DatabaseIcon as _, DownloadIcon as v, EllipsisIcon as y, EyeIcon as b, FolderPlusIcon as x, GitBranchIcon as S, GripVerticalIcon as C, HashIcon as w, InfoIcon as T, LayoutGridIcon as E, LayoutListIcon as D, LayoutPanelTopIcon as O, Link2Icon as ee, ListChecksIcon as k, ListTreeIcon as A, MinusIcon as j, MonitorIcon as M, MousePointer2Icon as N, MousePointerClickIcon as P, PaletteIcon as F, PilcrowIcon as I, PlusIcon as L, Redo2Icon as R, RocketIcon as z, SearchIcon as B, Settings2Icon as V, ShieldCheckIcon as H, SlidersHorizontalIcon as U, SmartphoneIcon as W, SquareIcon as G, SquarePenIcon as K, StretchHorizontalIcon as q, TableIcon as J, TextIcon as Y, ToggleLeftIcon as X, Trash2Icon as Z, TriangleAlertIcon as Q, TypeIcon as $, Undo2Icon as te, UploadIcon as ne, XIcon as re } from "lucide-react";
|
|
5
|
+
//#region src/icons.tsx
|
|
6
|
+
var ie = {
|
|
7
|
+
braces: r,
|
|
8
|
+
calendar: i,
|
|
9
|
+
"calendar-range": a,
|
|
10
|
+
"chevron-down": o,
|
|
11
|
+
"chevron-right": s,
|
|
12
|
+
"chevron-up": c,
|
|
13
|
+
"circle-dot": l,
|
|
14
|
+
"circle-help": u,
|
|
15
|
+
"circle-x": d,
|
|
16
|
+
"clipboard-list": f,
|
|
17
|
+
clock: p,
|
|
18
|
+
code: h,
|
|
19
|
+
"code-2": m,
|
|
20
|
+
copy: g,
|
|
21
|
+
database: _,
|
|
22
|
+
download: v,
|
|
23
|
+
ellipsis: y,
|
|
24
|
+
eye: b,
|
|
25
|
+
"folder-plus": x,
|
|
26
|
+
"git-branch": S,
|
|
27
|
+
"grip-vertical": C,
|
|
28
|
+
hash: w,
|
|
29
|
+
info: T,
|
|
30
|
+
"layout-grid": E,
|
|
31
|
+
"layout-list": D,
|
|
32
|
+
"layout-panel-top": O,
|
|
33
|
+
"link-2": ee,
|
|
34
|
+
"list-checks": k,
|
|
35
|
+
"list-tree": A,
|
|
36
|
+
minus: j,
|
|
37
|
+
monitor: M,
|
|
38
|
+
"mouse-pointer-2": N,
|
|
39
|
+
"mouse-pointer-click": P,
|
|
40
|
+
palette: F,
|
|
41
|
+
pilcrow: I,
|
|
42
|
+
plus: L,
|
|
43
|
+
"redo-2": R,
|
|
44
|
+
rocket: z,
|
|
45
|
+
search: B,
|
|
46
|
+
"settings-2": V,
|
|
47
|
+
"shield-check": H,
|
|
48
|
+
"sliders-horizontal": U,
|
|
49
|
+
smartphone: W,
|
|
50
|
+
square: G,
|
|
51
|
+
"square-pen": K,
|
|
52
|
+
"stretch-horizontal": q,
|
|
53
|
+
table: J,
|
|
54
|
+
text: Y,
|
|
55
|
+
"toggle-left": X,
|
|
56
|
+
"trash-2": Z,
|
|
57
|
+
"triangle-alert": Q,
|
|
58
|
+
type: $,
|
|
59
|
+
"undo-2": te,
|
|
60
|
+
upload: ne,
|
|
61
|
+
x: re
|
|
62
|
+
};
|
|
63
|
+
function ae({ name: r, ...i }) {
|
|
64
|
+
let a = ie[r];
|
|
65
|
+
return a ? /* @__PURE__ */ e(n, {
|
|
66
|
+
component: a,
|
|
67
|
+
...i
|
|
68
|
+
}) : /* @__PURE__ */ e(t, {
|
|
69
|
+
name: r,
|
|
70
|
+
...i
|
|
71
|
+
});
|
|
72
|
+
}
|
|
73
|
+
//#endregion
|
|
74
|
+
export { ae as EditorIcon };
|