@code0-tech/pictor 0.0.0-mvp.25 → 0.0.0-mvp.27
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/assets/components/badge/Badge.style.css +1 -1
- package/dist/assets/components/button/Button.style.css +1 -1
- package/dist/assets/components/context-menu/ContextMenu.style.css +1 -0
- package/dist/assets/components/d-flow-folder/DFlowFolder.style.css +1 -0
- package/dist/assets/components/{d-flow/function → d-flow-function}/DFlowFunctionDefaultCard.style.css +1 -1
- package/dist/assets/components/d-flow-panel/DFlowMiniMap.style.css +1 -0
- package/dist/assets/components/d-flow-suggestion/DFlowSuggestionSearchInput.style.css +1 -0
- package/dist/assets/components/d-layout/DLayout.style.css +1 -1
- package/dist/assets/components/d-resizable/DResizable.style.css +1 -1
- package/dist/assets/components/file-tabs/FileTabs.style.css +1 -1
- package/dist/assets/components/form/Input.style.css +1 -1
- package/dist/assets/components/segmented-control/SegmentedControl.style.css +1 -1
- package/dist/components/avatar/Avatar.js +7 -7
- package/dist/components/badge/Badge.d.ts +1 -1
- package/dist/components/badge/Badge.js +57 -17
- package/dist/components/breadcrumb/Breadcrumb.js +5 -5
- package/dist/components/button/Button.js +8 -8
- package/dist/components/context-menu/ContextMenu.d.ts +31 -0
- package/dist/components/context-menu/ContextMenu.js +191 -0
- package/dist/components/d-application/DApplication.service.d.ts +5 -0
- package/dist/components/d-application/DApplication.service.js +9 -0
- package/dist/components/d-flow/DFlow.d.ts +5 -3
- package/dist/components/d-flow/DFlow.edges.hook.d.ts +2 -1
- package/dist/components/d-flow/DFlow.edges.hook.js +98 -136
- package/dist/components/d-flow/DFlow.js +214 -199
- package/dist/components/d-flow/DFlow.nodes.hook.d.ts +5 -1
- package/dist/components/d-flow/DFlow.nodes.hook.js +101 -123
- package/dist/components/d-flow/DFlow.service.d.ts +12 -7
- package/dist/components/d-flow/DFlow.service.js +117 -7
- package/dist/components/d-flow/{edge/DFlowEdge.d.ts → DFlowEdge.d.ts} +5 -3
- package/dist/components/d-flow/DFlowEdge.js +69 -0
- package/dist/components/d-flow/index.d.ts +1 -10
- package/dist/components/d-flow/index.js +9 -44
- package/dist/components/d-flow-data-type/DFlowDataType.service.d.ts +9 -0
- package/dist/components/{d-flow/data-type → d-flow-data-type}/DFlowDataType.service.js +12 -10
- package/dist/components/{d-flow/data-type → d-flow-data-type}/DFlowDataType.view.d.ts +8 -2
- package/dist/components/d-flow-data-type/DFlowDataType.view.js +71 -0
- package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeContainsKeyRule.d.ts +2 -3
- package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeContainsKeyRule.js +3 -3
- package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeContainsTypeRule.d.ts +2 -3
- package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeContainsTypeRule.js +4 -4
- package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeParentRule.d.ts +2 -3
- package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeParentRule.js +3 -3
- package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeReturnTypeRule.d.ts +2 -3
- package/dist/components/d-flow-data-type/rules/DFlowDataTypeReturnTypeRule.js +246 -0
- package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeRule.d.ts +2 -3
- package/dist/components/{d-flow/tab → d-flow-file}/DFlowTabDefault.d.ts +2 -3
- package/dist/components/d-flow-file/DFlowTabDefault.js +139 -0
- package/dist/components/{d-flow/tab → d-flow-file}/DFlowTabTrigger.d.ts +2 -2
- package/dist/components/d-flow-file/DFlowTabTrigger.js +75 -0
- package/dist/components/d-flow-file/DFlowTabs.d.ts +6 -0
- package/dist/components/d-flow-file/DFlowTabs.js +128 -0
- package/dist/components/d-flow-file/index.d.ts +1 -0
- package/dist/components/d-flow-file/index.js +4 -0
- package/dist/components/{d-flow/folder → d-flow-folder}/DFlowFolder.d.ts +11 -5
- package/dist/components/d-flow-folder/DFlowFolder.js +158 -0
- package/dist/components/d-flow-folder/DFlowFolderContextMenu.d.ts +18 -0
- package/dist/components/d-flow-folder/DFlowFolderContextMenu.js +69 -0
- package/dist/components/d-flow-folder/DFlowFolderCreateDialog.d.ts +9 -0
- package/dist/components/d-flow-folder/DFlowFolderCreateDialog.js +76 -0
- package/dist/components/d-flow-folder/DFlowFolderItemPathInput.d.ts +5 -0
- package/dist/components/d-flow-folder/DFlowFolderItemPathInput.js +49 -0
- package/dist/components/d-flow-folder/DFlowFolderRenameDialog.d.ts +9 -0
- package/dist/components/d-flow-folder/DFlowFolderRenameDialog.js +55 -0
- package/dist/components/{d-flow/function → d-flow-function}/DFlowFunction.input.hook.d.ts +1 -1
- package/dist/components/{d-flow/function → d-flow-function}/DFlowFunction.input.hook.js +1 -1
- package/dist/components/{d-flow/function → d-flow-function}/DFlowFunction.return.hook.d.ts +2 -2
- package/dist/components/d-flow-function/DFlowFunction.return.hook.js +9 -0
- package/dist/components/{d-flow/function → d-flow-function}/DFlowFunction.service.d.ts +1 -1
- package/dist/components/d-flow-function/DFlowFunction.service.js +12 -0
- package/dist/components/{d-flow/function → d-flow-function}/DFlowFunction.view.d.ts +12 -0
- package/dist/components/d-flow-function/DFlowFunction.view.js +132 -0
- package/dist/components/{d-flow/function → d-flow-function}/DFlowFunctionDefaultCard.d.ts +4 -4
- package/dist/components/d-flow-function/DFlowFunctionDefaultCard.js +120 -0
- package/dist/components/d-flow-function/DFlowFunctionGroupCard.d.ts +13 -0
- package/dist/components/d-flow-function/DFlowFunctionGroupCard.js +68 -0
- package/dist/components/{d-flow/function → d-flow-function}/DFlowFunctionSuggestionCard.d.ts +3 -4
- package/dist/components/d-flow-function/DFlowFunctionSuggestionCard.js +48 -0
- package/dist/components/{d-flow/function → d-flow-function}/DFlowFunctionTriggerCard.d.ts +3 -3
- package/dist/components/d-flow-function/DFlowFunctionTriggerCard.js +71 -0
- package/dist/components/{d-flow/input → d-flow-input}/DFlowInputDataType.d.ts +1 -1
- package/dist/components/{d-flow/input → d-flow-input}/DFlowInputDataType.js +175 -165
- package/dist/components/d-flow-panel/DFlowExport.js +32 -0
- package/dist/components/d-flow-panel/DFlowMiniMap.js +33 -0
- package/dist/components/d-flow-panel/DFlowPanelControl.d.ts +6 -0
- package/dist/components/d-flow-panel/DFlowPanelControl.js +70 -0
- package/dist/components/d-flow-panel/DFlowPanelLayout.d.ts +4 -0
- package/dist/components/d-flow-panel/DFlowPanelLayout.js +47 -0
- package/dist/components/d-flow-panel/DFlowPanelSize.d.ts +2 -0
- package/dist/components/d-flow-panel/DFlowPanelSize.js +94 -0
- package/dist/components/d-flow-panel/index.d.ts +5 -0
- package/dist/components/d-flow-panel/index.js +12 -0
- package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestion.hook.d.ts +0 -15
- package/dist/components/d-flow-suggestion/DFlowSuggestion.hook.js +161 -0
- package/dist/components/d-flow-suggestion/DFlowSuggestion.view.d.ts +14 -0
- package/dist/components/d-flow-suggestion/DFlowSuggestion.view.js +4 -0
- package/dist/components/d-flow-suggestion/DFlowSuggestionMenu.js +83 -0
- package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestionMenu.util.d.ts +1 -1
- package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestionMenu.util.js +1 -1
- package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestionMenuFooter.js +5 -5
- package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestionMenuSearchBar.d.ts +1 -1
- package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestionMenuSearchBar.js +1 -1
- package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestionSearchInput.d.ts +1 -1
- package/dist/components/d-flow-suggestion/DFlowSuggestionSearchInput.js +35 -0
- package/dist/components/d-flow-suggestion/index.d.ts +1 -0
- package/dist/components/d-flow-suggestion/index.js +4 -0
- package/dist/components/{d-flow/type → d-flow-type}/DFlowType.service.d.ts +1 -1
- package/dist/components/d-flow-type/DFlowType.service.js +12 -0
- package/dist/components/{d-flow/type → d-flow-type}/DFlowType.view.d.ts +6 -0
- package/dist/components/{d-flow/type → d-flow-type}/DFlowType.view.js +16 -10
- package/dist/components/d-flow-validation/DDataTypeValidation.hook.d.ts +2 -0
- package/dist/components/d-flow-validation/DDataTypeValidation.hook.js +18 -0
- package/dist/components/d-flow-validation/DFlowValidation.hook.d.ts +3 -0
- package/dist/components/d-flow-validation/DFlowValidation.hook.js +22 -0
- package/dist/components/d-flow-validation/DFlowValidation.js +66 -0
- package/dist/components/d-flow-validation/DNodeValidation.hook.d.ts +3 -0
- package/dist/components/d-flow-validation/DNodeValidation.hook.js +62 -0
- package/dist/components/d-flow-validation/DValueValidation.hook.d.ts +3 -0
- package/dist/components/d-flow-validation/DValueValidation.hook.js +8 -0
- package/dist/components/{d-flow/validation → d-flow-validation}/index.js +2 -2
- package/dist/components/d-fullscreen/DFullScreen.js +2 -2
- package/dist/components/d-member/DNamespaceMemberContent.js +140 -92
- package/dist/components/d-member/DNamespaceMemberList.js +5 -5
- package/dist/components/d-organization/DOrganizationList.js +7 -7
- package/dist/components/d-organization/DOrganizationMenu.js +5 -5
- package/dist/components/d-organization/DOrganizatonContent.js +29 -29
- package/dist/components/d-project/DNamespaceProjectContent.js +6 -6
- package/dist/components/d-project/DNamespaceProjectList.js +5 -5
- package/dist/components/d-project/DNamespaceProjectMenu.js +51 -22
- package/dist/components/d-project/index.js +10 -9
- package/dist/components/d-resizable/DResizable.js +18 -17
- package/dist/components/d-role/DNamespaceRoleContent.js +11 -11
- package/dist/components/d-role/DNamespaceRolePermissions.js +5 -5
- package/dist/components/d-runtime/DRuntimeContent.js +10 -10
- package/dist/components/d-runtime/DRuntimeList.js +7 -7
- package/dist/components/d-user/DUser.session.hook.js +2 -2
- package/dist/components/d-user/DUserContent.js +19 -19
- package/dist/components/d-user/DUserInput.js +9 -9
- package/dist/components/d-user/DUserList.js +9 -9
- package/dist/components/file-tabs/FileTabs.js +2 -2
- package/dist/components/file-tabs/FileTabs.service.d.ts +5 -0
- package/dist/components/file-tabs/FileTabs.service.js +68 -16
- package/dist/components/file-tabs/FileTabs.view.d.ts +1 -0
- package/dist/components/form/CheckboxInput.js +4 -4
- package/dist/components/form/EmailInput.js +12 -12
- package/dist/components/form/Input.js +220 -206
- package/dist/components/form/Input.selection.hook.js +9 -9
- package/dist/components/form/Input.syntax.hook.js +7 -7
- package/dist/components/form/NumberInput.js +9 -9
- package/dist/components/form/PasswordInput.js +6 -6
- package/dist/components/form/SwitchInput.js +7 -7
- package/dist/components/form/TextInput.js +10 -10
- package/dist/components/segmented-control/SegmentedControl.d.ts +1 -1
- package/dist/components/segmented-control/SegmentedControl.js +14 -12
- package/dist/index.d.ts +8 -0
- package/dist/index.js +117 -117
- package/dist/node_modules/@floating-ui/core/dist/floating-ui.core.js +527 -0
- package/dist/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +402 -0
- package/dist/node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.js +208 -0
- package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js +136 -0
- package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.js +130 -0
- package/dist/node_modules/@radix-ui/primitive/dist/index.js +9 -0
- package/dist/node_modules/@radix-ui/react-arrow/dist/index.js +24 -0
- package/dist/node_modules/@radix-ui/react-collection/dist/index.js +48 -0
- package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.js +29 -0
- package/dist/node_modules/@radix-ui/react-context/dist/index.js +53 -0
- package/dist/node_modules/@radix-ui/react-context-menu/dist/index.js +222 -0
- package/dist/node_modules/@radix-ui/react-direction/dist/index.js +10 -0
- package/dist/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +127 -0
- package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.js +17 -0
- package/dist/node_modules/@radix-ui/react-focus-scope/dist/index.js +136 -0
- package/dist/node_modules/@radix-ui/react-id/dist/index.js +13 -0
- package/dist/node_modules/@radix-ui/react-menu/dist/index.js +636 -0
- package/dist/node_modules/@radix-ui/react-popper/dist/index.js +219 -0
- package/dist/node_modules/@radix-ui/react-portal/dist/index.js +15 -0
- package/dist/node_modules/@radix-ui/react-presence/dist/index.js +70 -0
- package/dist/node_modules/@radix-ui/react-primitive/dist/index.js +36 -0
- package/dist/node_modules/@radix-ui/react-roving-focus/dist/index.js +183 -0
- package/dist/node_modules/@radix-ui/react-slot/dist/index.js +49 -0
- package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.js +10 -0
- package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +52 -0
- package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.js +14 -0
- package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.js +6 -0
- package/dist/node_modules/@radix-ui/react-use-size/dist/index.js +27 -0
- package/dist/node_modules/aria-hidden/dist/es2015/index.js +52 -0
- package/dist/node_modules/get-nonce/dist/es2015/index.js +7 -0
- package/dist/node_modules/react/cjs/react-compiler-runtime.development.js +2 -2
- package/dist/node_modules/react/cjs/react-compiler-runtime.production.js +8 -8
- package/dist/node_modules/react-remove-scroll/dist/es2015/Combination.js +11 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +112 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js +31 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js +16 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +68 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/medium.js +5 -0
- package/dist/node_modules/react-remove-scroll/dist/es2015/sidecar.js +7 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js +71 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/constants.js +7 -0
- package/dist/node_modules/react-remove-scroll-bar/dist/es2015/utils.js +25 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/component.js +11 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/hook.js +15 -0
- package/dist/node_modules/react-style-singleton/dist/es2015/singleton.js +30 -0
- package/dist/node_modules/tslib/tslib.es6.js +27 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/assignRef.js +6 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js +26 -0
- package/dist/node_modules/use-callback-ref/dist/es2015/useRef.js +25 -0
- package/dist/node_modules/use-sidecar/dist/es2015/exports.js +18 -0
- package/dist/node_modules/use-sidecar/dist/es2015/medium.js +67 -0
- package/dist/utils/generics.d.ts +5 -6
- package/dist/utils/generics.js +2 -2
- package/dist/utils/objectStore.js +15 -15
- package/dist/utils/reactiveArrayService.js +5 -5
- package/package.json +7 -4
- package/dist/assets/components/d-flow/folder/DFlowFolder.style.css +0 -1
- package/dist/assets/components/d-flow/minimap/DFlowMiniMap.style.css +0 -1
- package/dist/assets/components/d-flow/suggestion/DFlowSuggestionSearchInput.style.css +0 -1
- package/dist/components/d-flow/DFlow.view.d.ts +0 -113
- package/dist/components/d-flow/DFlow.view.js +0 -248
- package/dist/components/d-flow/control/DFlowControl.d.ts +0 -2
- package/dist/components/d-flow/control/DFlowControl.js +0 -81
- package/dist/components/d-flow/control/index.d.ts +0 -1
- package/dist/components/d-flow/control/index.js +0 -4
- package/dist/components/d-flow/data-type/DFlowDataType.service.d.ts +0 -10
- package/dist/components/d-flow/data-type/DFlowDataType.validation.type.d.ts +0 -2
- package/dist/components/d-flow/data-type/DFlowDataType.validation.type.js +0 -18
- package/dist/components/d-flow/data-type/DFlowDataType.validation.value.d.ts +0 -4
- package/dist/components/d-flow/data-type/DFlowDataType.validation.value.js +0 -20
- package/dist/components/d-flow/data-type/DFlowDataType.view.js +0 -65
- package/dist/components/d-flow/data-type/rules/DFlowDataTypeReturnTypeRule.js +0 -243
- package/dist/components/d-flow/edge/DFlowEdge.js +0 -48
- package/dist/components/d-flow/export/DFlowExport.js +0 -24
- package/dist/components/d-flow/folder/DFlowFolder.js +0 -119
- package/dist/components/d-flow/function/DFlowFunction.return.hook.js +0 -11
- package/dist/components/d-flow/function/DFlowFunction.service.js +0 -9
- package/dist/components/d-flow/function/DFlowFunction.vaildation.hook.d.ts +0 -10
- package/dist/components/d-flow/function/DFlowFunction.vaildation.hook.js +0 -74
- package/dist/components/d-flow/function/DFlowFunction.view.js +0 -117
- package/dist/components/d-flow/function/DFlowFunctionDefaultCard.js +0 -158
- package/dist/components/d-flow/function/DFlowFunctionGroupCard.d.ts +0 -5
- package/dist/components/d-flow/function/DFlowFunctionGroupCard.js +0 -55
- package/dist/components/d-flow/function/DFlowFunctionSuggestionCard.js +0 -26
- package/dist/components/d-flow/function/DFlowFunctionTriggerCard.js +0 -93
- package/dist/components/d-flow/minimap/DFlowMiniMap.js +0 -22
- package/dist/components/d-flow/minimap/index.d.ts +0 -1
- package/dist/components/d-flow/minimap/index.js +0 -4
- package/dist/components/d-flow/suggestion/DFlowSuggestion.hook.js +0 -150
- package/dist/components/d-flow/suggestion/DFlowSuggestion.service.d.ts +0 -5
- package/dist/components/d-flow/suggestion/DFlowSuggestion.service.js +0 -18
- package/dist/components/d-flow/suggestion/DFlowSuggestion.view.d.ts +0 -21
- package/dist/components/d-flow/suggestion/DFlowSuggestion.view.js +0 -25
- package/dist/components/d-flow/suggestion/DFlowSuggestionMenu.js +0 -67
- package/dist/components/d-flow/suggestion/DFlowSuggestionSearchInput.js +0 -35
- package/dist/components/d-flow/suggestion/index.d.ts +0 -2
- package/dist/components/d-flow/suggestion/index.js +0 -7
- package/dist/components/d-flow/tab/DFlowTabDefault.js +0 -103
- package/dist/components/d-flow/tab/DFlowTabTrigger.js +0 -51
- package/dist/components/d-flow/tab/DFlowTabs.d.ts +0 -2
- package/dist/components/d-flow/tab/DFlowTabs.js +0 -105
- package/dist/components/d-flow/type/DFlowType.service.js +0 -9
- package/dist/components/d-flow/validation/DFlowValidation.hook.d.ts +0 -3
- package/dist/components/d-flow/validation/DFlowValidation.hook.js +0 -10
- package/dist/components/d-flow/validation/DFlowValidation.js +0 -60
- /package/dist/assets/components/{d-flow/input → d-flow-input}/DFlowInputDataType.style.css +0 -0
- /package/dist/assets/components/{d-flow/validation → d-flow-validation}/DFlowValidation.style.css +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/index.d.ts +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/index.js +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeItemOfCollectionRule.d.ts +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeItemOfCollectionRule.js +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeNumberRangeRule.d.ts +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeNumberRangeRule.js +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeRegexRule.d.ts +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeRegexRule.js +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeRule.js +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeRules.d.ts +0 -0
- /package/dist/components/{d-flow/data-type → d-flow-data-type}/rules/DFlowDataTypeRules.js +0 -0
- /package/dist/components/{d-flow/folder → d-flow-folder}/index.d.ts +0 -0
- /package/dist/components/{d-flow/folder → d-flow-folder}/index.js +0 -0
- /package/dist/components/{d-flow/function → d-flow-function}/index.d.ts +0 -0
- /package/dist/components/{d-flow/function → d-flow-function}/index.js +0 -0
- /package/dist/components/{d-flow/export → d-flow-panel}/DFlowExport.d.ts +0 -0
- /package/dist/components/{d-flow/minimap → d-flow-panel}/DFlowMiniMap.d.ts +0 -0
- /package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestionMenu.d.ts +0 -0
- /package/dist/components/{d-flow/suggestion → d-flow-suggestion}/DFlowSuggestionMenuFooter.d.ts +0 -0
- /package/dist/components/{d-flow/type → d-flow-type}/index.d.ts +0 -0
- /package/dist/components/{d-flow/type → d-flow-type}/index.js +0 -0
- /package/dist/components/{d-flow/validation → d-flow-validation}/DFlowValidation.d.ts +0 -0
- /package/dist/components/{d-flow/validation → d-flow-validation}/index.d.ts +0 -0
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { jsx as e, jsxs as o, Fragment as v } from "react/jsx-runtime";
|
|
2
|
+
import b, { memo as y } from "react";
|
|
3
|
+
import { useReactFlow as T, useStore as s, Handle as x, Position as S } from "@xyflow/react";
|
|
4
|
+
import { Text as l } from "../text/Text.js";
|
|
5
|
+
import { useService as m } from "../../utils/contextStore.js";
|
|
6
|
+
import "merge-props";
|
|
7
|
+
import { FileTabsService as R } from "../file-tabs/FileTabs.service.js";
|
|
8
|
+
import { Card as z } from "../card/Card.js";
|
|
9
|
+
import { Flex as n } from "../flex/Flex.js";
|
|
10
|
+
import { IconBolt as f, IconChevronDown as F } from "@tabler/icons-react";
|
|
11
|
+
import { Button as B } from "../button/Button.js";
|
|
12
|
+
import { DFlowTabTrigger as _ } from "../d-flow-file/DFlowTabTrigger.js";
|
|
13
|
+
import { DFlowTypeReactiveService as C } from "../d-flow-type/DFlowType.service.js";
|
|
14
|
+
import { Badge as D } from "../badge/Badge.js";
|
|
15
|
+
const J = y((i) => {
|
|
16
|
+
const {
|
|
17
|
+
data: a,
|
|
18
|
+
id: d
|
|
19
|
+
} = i, r = m(R), p = T(), t = m(C).getById(a.instance.type?.id), h = i.width ?? 0, u = i.height ?? 0, g = s((c) => c.width), w = s((c) => c.height);
|
|
20
|
+
return b.useEffect(() => {
|
|
21
|
+
r.registerTab({
|
|
22
|
+
id: t?.id,
|
|
23
|
+
active: !0,
|
|
24
|
+
closeable: !0,
|
|
25
|
+
children: /* @__PURE__ */ o(v, { children: [
|
|
26
|
+
/* @__PURE__ */ e(f, { size: 12 }),
|
|
27
|
+
/* @__PURE__ */ e(l, { size: "sm", children: t?.names?.nodes[0]?.content })
|
|
28
|
+
] }),
|
|
29
|
+
content: /* @__PURE__ */ e(_, { instance: a.instance }),
|
|
30
|
+
show: !0
|
|
31
|
+
});
|
|
32
|
+
}, [t?.id, a.instance, r, t?.names?.nodes]), /* @__PURE__ */ o(n, { align: "center", style: {
|
|
33
|
+
flexDirection: "column"
|
|
34
|
+
}, "data-flow-refernce": d, children: [
|
|
35
|
+
/* @__PURE__ */ e(D, { color: "info", style: {
|
|
36
|
+
borderTopRightRadius: "0.35rem",
|
|
37
|
+
borderTopLeftRadius: "0.35rem",
|
|
38
|
+
borderBottomLeftRadius: 0,
|
|
39
|
+
borderBottomRightRadius: 0
|
|
40
|
+
}, children: "Starting node" }),
|
|
41
|
+
/* @__PURE__ */ o(z, { variant: "normal", color: "info", paddingSize: "xs", className: r.getActiveTab()?.id == t?.id ? "d-flow-viewport-default-card--active" : void 0, onClick: () => {
|
|
42
|
+
p.setViewport({
|
|
43
|
+
x: g / 2 + i.positionAbsoluteX * -1 - h / 2,
|
|
44
|
+
y: w / 2 + i.positionAbsoluteY * -1 - u / 2,
|
|
45
|
+
zoom: 1
|
|
46
|
+
}, {
|
|
47
|
+
duration: 250
|
|
48
|
+
}), r.activateTab(t?.id);
|
|
49
|
+
}, children: [
|
|
50
|
+
/* @__PURE__ */ o(n, { style: {
|
|
51
|
+
gap: "1.3rem"
|
|
52
|
+
}, align: "center", justify: "space-between", children: [
|
|
53
|
+
/* @__PURE__ */ o(n, { style: {
|
|
54
|
+
gap: "0.7rem"
|
|
55
|
+
}, align: "center", children: [
|
|
56
|
+
/* @__PURE__ */ e(f, { size: 16 }),
|
|
57
|
+
/* @__PURE__ */ e(l, { display: "block", size: "md", children: t?.names?.nodes[0]?.content ?? t?.id })
|
|
58
|
+
] }),
|
|
59
|
+
/* @__PURE__ */ e(n, { align: "center", style: {
|
|
60
|
+
gap: "0.7rem"
|
|
61
|
+
}, children: /* @__PURE__ */ e(B, { p: "0", paddingSize: "xxs", variant: "none", disabled: !0, children: /* @__PURE__ */ e(F, { size: 16 }) }) })
|
|
62
|
+
] }),
|
|
63
|
+
/* @__PURE__ */ e(x, { isConnectable: !1, type: "source", style: {
|
|
64
|
+
bottom: "2px"
|
|
65
|
+
}, className: "d-flow-viewport-default-card__handle d-flow-viewport-default-card__handle--source", position: S.Bottom })
|
|
66
|
+
] })
|
|
67
|
+
] }, d);
|
|
68
|
+
});
|
|
69
|
+
export {
|
|
70
|
+
J as DFlowFunctionTriggerCard
|
|
71
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
|
-
import { ValidationProps } from '
|
|
2
|
+
import { ValidationProps } from '../form';
|
|
3
3
|
import { DataType, GenericType } from '@code0-tech/sagittarius-graphql-types';
|
|
4
4
|
export interface DFlowInputDataTypeProps extends ValidationProps<DataType | GenericType> {
|
|
5
5
|
onDataTypeChange?: (value: DataType | GenericType) => void;
|
|
@@ -1,35 +1,45 @@
|
|
|
1
1
|
import { jsxs as S, jsx as c, Fragment as j } from "react/jsx-runtime";
|
|
2
|
-
import { c as be } from "
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import {
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import {
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import {
|
|
19
|
-
|
|
2
|
+
import { c as be } from "../../_virtual/compiler-runtime.js";
|
|
3
|
+
import m from "react";
|
|
4
|
+
import "@radix-ui/react-checkbox";
|
|
5
|
+
import { InputLabel as ve } from "../form/InputLabel.js";
|
|
6
|
+
import "merge-props";
|
|
7
|
+
import { InputMessage as Me } from "../form/InputMessage.js";
|
|
8
|
+
import '../../assets/components/d-flow-input/DFlowInputDataType.style.css';import '../../assets/components/form/Input.style.css';/* empty css */
|
|
9
|
+
import { IconSettings as le, IconTrash as Oe } from "@tabler/icons-react";
|
|
10
|
+
import "../form/EmailInput.js";
|
|
11
|
+
import "../form/Input.js";
|
|
12
|
+
import { InputSuggestionMenuContent as De, InputSuggestionMenuContentItems as ke } from "../form/InputSuggestion.js";
|
|
13
|
+
import "../form/NumberInput.js";
|
|
14
|
+
import "../form/PasswordInput.js";
|
|
15
|
+
import "@radix-ui/react-one-time-password-field";
|
|
16
|
+
import "@radix-ui/react-radio-group";
|
|
17
|
+
import "../form/SwitchInput.js";
|
|
18
|
+
import { TextInput as F } from "../form/TextInput.js";
|
|
19
|
+
/* empty css */
|
|
20
|
+
import { Button as re } from "../button/Button.js";
|
|
21
|
+
import { Text as A } from "../text/Text.js";
|
|
22
|
+
import { Flex as X } from "../flex/Flex.js";
|
|
23
|
+
import { Badge as Be } from "../badge/Badge.js";
|
|
24
|
+
import { useSuggestions as Ve } from "../d-flow-suggestion/DFlowSuggestion.hook.js";
|
|
25
|
+
import { DFlowSuggestionMenuFooter as ye } from "../d-flow-suggestion/DFlowSuggestionMenuFooter.js";
|
|
26
|
+
import { toInputSuggestions as Ae } from "../d-flow-suggestion/DFlowSuggestionMenu.util.js";
|
|
27
|
+
import { DFlowSuggestionType as _e } from "../d-flow-suggestion/DFlowSuggestion.view.js";
|
|
28
|
+
import { Menu as Ke, MenuTrigger as we, MenuPortal as Ge } from "../menu/Menu.js";
|
|
29
|
+
const Te = /* @__PURE__ */ new Set(["ITEM_OF_COLLECTION", "REGEX", "NUMBER_RANGE"]), he = "__blockingSignature", Fe = ["CONTAINS_KEY", "CONTAINS_TYPE", "ITEM_OF_COLLECTION", "NUMBER_RANGE", "REGEX"], de = (t) => {
|
|
20
30
|
const {
|
|
21
31
|
formValidation: e,
|
|
22
|
-
initialValue:
|
|
32
|
+
initialValue: n,
|
|
23
33
|
onDataTypeChange: p = () => {
|
|
24
34
|
},
|
|
25
|
-
blockingDataType:
|
|
26
|
-
} =
|
|
35
|
+
blockingDataType: a
|
|
36
|
+
} = t, y = m.useMemo(() => Ie(n, a), [n, a]), [s, u] = m.useState(y), T = m.useMemo(() => Y(s), [s]), l = m.useMemo(() => Y(a), [a]), B = m.useMemo(() => new Map((J(s) ? s.genericMappers ?? [] : []).map((r) => [r.target ?? "", r])), [s]), I = m.useMemo(() => l?.rules?.nodes?.filter(Boolean), [l]), E = m.useCallback((r) => {
|
|
27
37
|
u((o) => {
|
|
28
38
|
if (!o) return o;
|
|
29
39
|
const i = q(o);
|
|
30
40
|
return r(i), p(i), Le(o, i), i;
|
|
31
41
|
});
|
|
32
|
-
}, []), b =
|
|
42
|
+
}, []), b = m.useCallback((r, o, i) => {
|
|
33
43
|
E((N) => {
|
|
34
44
|
const h = Y(N);
|
|
35
45
|
if (!h) return;
|
|
@@ -38,20 +48,20 @@ const Te = /* @__PURE__ */ new Set(["ITEM_OF_COLLECTION", "REGEX", "NUMBER_RANGE
|
|
|
38
48
|
const f = Ce(R, l);
|
|
39
49
|
if (f && !i?.allowBlocked) return;
|
|
40
50
|
const g = o(q(R));
|
|
41
|
-
g !== void 0 && (f && (
|
|
51
|
+
g !== void 0 && (f && (se(g, f), ae(g, f)), v[r] = g);
|
|
42
52
|
});
|
|
43
|
-
}, [l, E]), V =
|
|
53
|
+
}, [l, E]), V = m.useCallback((r) => {
|
|
44
54
|
E((o) => {
|
|
45
55
|
const i = Y(o);
|
|
46
56
|
if (!i) return;
|
|
47
57
|
const N = oe(i), h = N[r];
|
|
48
58
|
h && (Pe(h, l) || N.splice(r, 1));
|
|
49
59
|
});
|
|
50
|
-
}, [l, E]), d =
|
|
60
|
+
}, [l, E]), d = m.useCallback((r, o) => {
|
|
51
61
|
b(r, (i) => (!("dataTypeIdentifier" in i?.config) || !i?.config?.dataTypeIdentifier || (L(o) ? (i.config.dataTypeIdentifier.dataType = o, delete i.config.dataTypeIdentifier.genericType) : J(o) && (i.config.dataTypeIdentifier.genericType = o, delete i.config.dataTypeIdentifier.dataType)), i), {
|
|
52
62
|
allowBlocked: !0
|
|
53
63
|
});
|
|
54
|
-
}, [b]), D =
|
|
64
|
+
}, [b]), D = m.useCallback((r, o, i) => {
|
|
55
65
|
E((N) => {
|
|
56
66
|
if (!J(N)) return;
|
|
57
67
|
const h = N.genericMappers ?? [], v = h.findIndex((g) => g.target === r);
|
|
@@ -71,13 +81,13 @@ const Te = /* @__PURE__ */ new Set(["ITEM_OF_COLLECTION", "REGEX", "NUMBER_RANGE
|
|
|
71
81
|
return f ? (L(f) ? (M.dataType = f, delete M.genericType) : J(f) && (M.genericType = f, delete M.dataType), g) : (delete M?.dataType, delete M?.genericType, g);
|
|
72
82
|
}), onNestedChange: (f) => d(o, f), onGenericMapperChange: D }, `${r.variant}-${o}`) : null;
|
|
73
83
|
}),
|
|
74
|
-
/* @__PURE__ */ S(
|
|
75
|
-
/* @__PURE__ */ c(
|
|
84
|
+
/* @__PURE__ */ S(Ke, { children: [
|
|
85
|
+
/* @__PURE__ */ c(we, { asChild: !0, children: /* @__PURE__ */ S(re, { color: "primary", children: [
|
|
76
86
|
/* @__PURE__ */ c(le, { size: 16 }),
|
|
77
87
|
" Add new rule"
|
|
78
88
|
] }) }),
|
|
79
|
-
/* @__PURE__ */ c(
|
|
80
|
-
/* @__PURE__ */ c(
|
|
89
|
+
/* @__PURE__ */ c(Ge, { children: /* @__PURE__ */ S(De, { children: [
|
|
90
|
+
/* @__PURE__ */ c(ke, { onSuggestionSelect: (r) => {
|
|
81
91
|
E((o) => {
|
|
82
92
|
"rules" in o ? o?.rules?.nodes?.push(r.value) : "dataType" in o?.genericType && o?.genericType?.dataType?.rules?.nodes?.push(r.value);
|
|
83
93
|
});
|
|
@@ -104,33 +114,33 @@ const Te = /* @__PURE__ */ new Set(["ITEM_OF_COLLECTION", "REGEX", "NUMBER_RANGE
|
|
|
104
114
|
}
|
|
105
115
|
}
|
|
106
116
|
})) }),
|
|
107
|
-
/* @__PURE__ */ c(
|
|
117
|
+
/* @__PURE__ */ c(ye, {})
|
|
108
118
|
] }) })
|
|
109
119
|
] })
|
|
110
120
|
] }),
|
|
111
|
-
!e?.valid && e?.notValidMessage && /* @__PURE__ */ c(
|
|
121
|
+
!e?.valid && e?.notValidMessage && /* @__PURE__ */ c(Me, { children: e.notValidMessage })
|
|
112
122
|
] });
|
|
113
|
-
}, Ye = (
|
|
123
|
+
}, Ye = (t) => {
|
|
114
124
|
const e = be.c(56), {
|
|
115
|
-
rule:
|
|
125
|
+
rule: n,
|
|
116
126
|
blockingRule: p,
|
|
117
|
-
genericMap:
|
|
118
|
-
onRemove:
|
|
119
|
-
onConfigChange:
|
|
127
|
+
genericMap: a,
|
|
128
|
+
onRemove: y,
|
|
129
|
+
onConfigChange: s,
|
|
120
130
|
onHeaderKeyChange: u,
|
|
121
131
|
onHeaderDataTypeChange: T,
|
|
122
132
|
onNestedChange: l,
|
|
123
133
|
onGenericMapperChange: B
|
|
124
|
-
} =
|
|
134
|
+
} = t, I = n?.config?.dataTypeIdentifier ?? void 0, E = !!I?.genericKey, [b, V] = m.useState(!1), d = !!p, D = n.variant, r = D ? !Te.has(D) : !1;
|
|
125
135
|
let o;
|
|
126
|
-
e[0] !==
|
|
127
|
-
const [i, N] =
|
|
136
|
+
e[0] !== n.config ? (o = () => ue(n?.config), e[0] = n.config, e[1] = o) : o = e[1];
|
|
137
|
+
const [i, N] = m.useState(o);
|
|
128
138
|
let h;
|
|
129
|
-
e[2] !==
|
|
130
|
-
N(ue(
|
|
131
|
-
}, e[2] =
|
|
139
|
+
e[2] !== n.config ? (h = () => {
|
|
140
|
+
N(ue(n?.config));
|
|
141
|
+
}, e[2] = n.config, e[3] = h) : h = e[3];
|
|
132
142
|
let v;
|
|
133
|
-
e[4] !==
|
|
143
|
+
e[4] !== n ? (v = [n], e[4] = n, e[5] = v) : v = e[5], m.useEffect(h, v);
|
|
134
144
|
let R;
|
|
135
145
|
e: {
|
|
136
146
|
if (!r) {
|
|
@@ -143,7 +153,7 @@ const Te = /* @__PURE__ */ new Set(["ITEM_OF_COLLECTION", "REGEX", "NUMBER_RANGE
|
|
|
143
153
|
}
|
|
144
154
|
if (I.genericKey) {
|
|
145
155
|
let C;
|
|
146
|
-
e[6] !==
|
|
156
|
+
e[6] !== a || e[7] !== I.genericKey ? (C = a.get(I.genericKey), e[6] = a, e[7] = I.genericKey, e[8] = C) : C = e[8];
|
|
147
157
|
const k = C?.sourceDataTypeIdentifiers?.[0];
|
|
148
158
|
R = k?.dataType?.name?.nodes?.[0]?.content ?? k?.genericType?.dataType?.name?.nodes?.[0]?.content;
|
|
149
159
|
break e;
|
|
@@ -158,47 +168,47 @@ const Te = /* @__PURE__ */ new Set(["ITEM_OF_COLLECTION", "REGEX", "NUMBER_RANGE
|
|
|
158
168
|
}, e[9] = g) : g = e[9];
|
|
159
169
|
const M = g;
|
|
160
170
|
let P;
|
|
161
|
-
e[10] !== i || e[11] !== d || e[12] !==
|
|
171
|
+
e[10] !== i || e[11] !== d || e[12] !== s || e[13] !== n.config || e[14] !== D ? (P = (C) => {
|
|
162
172
|
if (d)
|
|
163
173
|
return;
|
|
164
|
-
const O = C?.target?.name, k = Je(i,
|
|
174
|
+
const O = C?.target?.name, k = Je(i, n.config, {
|
|
165
175
|
variant: D,
|
|
166
176
|
numberRangeKey: O
|
|
167
177
|
});
|
|
168
|
-
k &&
|
|
169
|
-
}, e[10] = i, e[11] = d, e[12] =
|
|
178
|
+
k && s(k);
|
|
179
|
+
}, e[10] = i, e[11] = d, e[12] = s, e[13] = n.config, e[14] = D, e[15] = P) : P = e[15];
|
|
170
180
|
const _ = P;
|
|
171
181
|
let z;
|
|
172
|
-
e[16] !==
|
|
182
|
+
e[16] !== n ? (z = me(n), e[16] = n, e[17] = z) : z = e[17];
|
|
173
183
|
const K = z;
|
|
174
184
|
let U;
|
|
175
|
-
e[18] !== p ? (U =
|
|
185
|
+
e[18] !== p ? (U = me(p), e[18] = p, e[19] = U) : U = e[19];
|
|
176
186
|
const W = U;
|
|
177
187
|
let $;
|
|
178
|
-
e[20] !== f || e[21] !==
|
|
188
|
+
e[20] !== f || e[21] !== a || e[22] !== E || e[23] !== I || e[24] !== d || e[25] !== b || e[26] !== W || e[27] !== K || e[28] !== B || e[29] !== T || e[30] !== u || e[31] !== l || e[32] !== y || e[33] !== n ? ($ = () => {
|
|
179
189
|
if (!K && !E)
|
|
180
190
|
return null;
|
|
181
|
-
const C = /* @__PURE__ */ c(ge, { rule:
|
|
191
|
+
const C = /* @__PURE__ */ c(ge, { rule: n, genericMap: a, isBlocked: d, dataTypeLabel: f, onClick: () => V(ze), onRemove: d ? void 0 : y, onKeyChange: d ? void 0 : u, onDataTypeChange: d ? void 0 : T });
|
|
182
192
|
if (K)
|
|
183
193
|
return /* @__PURE__ */ S(j, { children: [
|
|
184
194
|
C,
|
|
185
195
|
b ? /* @__PURE__ */ c(de, { initialValue: K, blockingDataType: W, onDataTypeChange: l }) : null
|
|
186
196
|
] });
|
|
187
197
|
if (I?.genericKey) {
|
|
188
|
-
const O =
|
|
198
|
+
const O = a.get(I.genericKey);
|
|
189
199
|
return /* @__PURE__ */ S(j, { children: [
|
|
190
200
|
C,
|
|
191
201
|
b ? O?.sourceDataTypeIdentifiers?.map((k, fe) => {
|
|
192
|
-
const
|
|
193
|
-
if (!
|
|
202
|
+
const ne = k?.dataType ?? k?.genericType;
|
|
203
|
+
if (!ne)
|
|
194
204
|
return null;
|
|
195
|
-
const Se = d ?
|
|
196
|
-
return ie ? /* @__PURE__ */ c(de, { initialValue:
|
|
205
|
+
const Se = d ? ne : void 0, ie = I.genericKey;
|
|
206
|
+
return ie ? /* @__PURE__ */ c(de, { initialValue: ne, blockingDataType: Se, onDataTypeChange: (Re) => B(ie, fe, Re) }, `${ie}-${fe}`) : null;
|
|
197
207
|
}) : null
|
|
198
208
|
] });
|
|
199
209
|
}
|
|
200
210
|
return null;
|
|
201
|
-
}, e[20] = f, e[21] =
|
|
211
|
+
}, e[20] = f, e[21] = a, e[22] = E, e[23] = I, e[24] = d, e[25] = b, e[26] = W, e[27] = K, e[28] = B, e[29] = T, e[30] = u, e[31] = l, e[32] = y, e[33] = n, e[34] = $) : $ = e[34];
|
|
202
212
|
const Q = $;
|
|
203
213
|
if (r && (K || E)) {
|
|
204
214
|
let C;
|
|
@@ -210,56 +220,56 @@ const Te = /* @__PURE__ */ new Set(["ITEM_OF_COLLECTION", "REGEX", "NUMBER_RANGE
|
|
|
210
220
|
e[39] === Symbol.for("react.memo_cache_sentinel") ? (x = {
|
|
211
221
|
flex: 1
|
|
212
222
|
}, e[39] = x) : x = e[39];
|
|
213
|
-
const Z = d ? void 0 :
|
|
223
|
+
const Z = d ? void 0 : y, ee = d ? void 0 : u, te = d ? void 0 : T;
|
|
214
224
|
let w;
|
|
215
|
-
e[40] !== f || e[41] !==
|
|
225
|
+
e[40] !== f || e[41] !== a || e[42] !== d || e[43] !== n || e[44] !== Z || e[45] !== ee || e[46] !== te ? (w = /* @__PURE__ */ c(ge, { rule: n, genericMap: a, isBlocked: d, dataTypeLabel: f, onRemove: Z, onKeyChange: ee, onDataTypeChange: te }), e[40] = f, e[41] = a, e[42] = d, e[43] = n, e[44] = Z, e[45] = ee, e[46] = te, e[47] = w) : w = e[47];
|
|
216
226
|
let G;
|
|
217
|
-
e[48] !== i || e[49] !== _ || e[50] !== d || e[51] !==
|
|
227
|
+
e[48] !== i || e[49] !== _ || e[50] !== d || e[51] !== n.variant ? (G = n.variant === "REGEX" || n.variant === "ITEM_OF_COLLECTION" ? /* @__PURE__ */ c(F, { clearable: !0, left: /* @__PURE__ */ c(A, { size: "sm", children: n.variant === "REGEX" ? "Pattern" : "Items" }), leftType: "icon", defaultValue: i, onChange: M, onBlur: _, w: "100%", disabled: d }) : n.variant === "NUMBER_RANGE" ? /* @__PURE__ */ S(j, { children: [
|
|
218
228
|
/* @__PURE__ */ c(F, { clearable: !0, defaultValue: i?.from?.toString() ?? "", onChange: M, onBlur: _, w: "100%", left: /* @__PURE__ */ c(A, { size: "sm", children: "From" }), leftType: "icon", disabled: d, name: "from" }),
|
|
219
229
|
/* @__PURE__ */ c(F, { clearable: !0, defaultValue: i?.steps?.toString() ?? "", onChange: M, onBlur: _, left: /* @__PURE__ */ c(A, { size: "sm", children: "Steps" }), leftType: "icon", w: "100%", disabled: d, name: "steps" }),
|
|
220
230
|
/* @__PURE__ */ c(F, { clearable: !0, left: /* @__PURE__ */ c(A, { size: "sm", children: "To" }), leftType: "icon", defaultValue: i?.to?.toString() ?? "", onChange: M, onBlur: _, w: "100%", disabled: d, name: "to" })
|
|
221
|
-
] }) : null, e[48] = i, e[49] = _, e[50] = d, e[51] =
|
|
231
|
+
] }) : null, e[48] = i, e[49] = _, e[50] = d, e[51] = n.variant, e[52] = G) : G = e[52];
|
|
222
232
|
let H;
|
|
223
233
|
return e[53] !== w || e[54] !== G ? (H = /* @__PURE__ */ c("div", { className: "d-flow-viewport-data-type-input__rule", children: /* @__PURE__ */ S("div", { style: x, children: [
|
|
224
234
|
w,
|
|
225
235
|
G
|
|
226
236
|
] }) }), e[53] = w, e[54] = G, e[55] = H) : H = e[55], H;
|
|
227
237
|
}, ge = ({
|
|
228
|
-
rule:
|
|
238
|
+
rule: t,
|
|
229
239
|
dataTypeLabel: e,
|
|
230
|
-
onClick:
|
|
240
|
+
onClick: n,
|
|
231
241
|
onRemove: p,
|
|
232
|
-
isBlocked:
|
|
233
|
-
onKeyChange:
|
|
234
|
-
onDataTypeChange:
|
|
242
|
+
isBlocked: a,
|
|
243
|
+
onKeyChange: y,
|
|
244
|
+
onDataTypeChange: s,
|
|
235
245
|
genericMap: u
|
|
236
246
|
}) => {
|
|
237
|
-
const T =
|
|
247
|
+
const T = t.variant, l = T ? !Te.has(T) : !1, B = l ? Ve({
|
|
238
248
|
dataType: {
|
|
239
249
|
id: "gid://sagittarius/DataType/878634678"
|
|
240
250
|
}
|
|
241
|
-
}, [], "", 0, [0], 1, [
|
|
242
|
-
|
|
243
|
-
b("key" in (
|
|
244
|
-
}, [
|
|
251
|
+
}, [], "", 0, [0], 1, [_e.DATA_TYPE]) : [], I = t?.config?.dataTypeIdentifier?.dataType?.rules?.nodes?.length ?? t?.config?.dataTypeIdentifier?.genericType?.dataType?.rules?.nodes?.length ?? u.get(t?.config?.dataTypeIdentifier?.genericKey)?.sourceDataTypeIdentifiers?.map((i) => i?.dataType?.rules?.nodes?.length ?? i.genericType?.dataType?.rules?.nodes?.length) ?? 0, [E, b] = m.useState(() => "key" in (t?.config ?? {}) ? t?.config?.key ?? "" : ""), [V, d] = m.useState(() => e ?? "");
|
|
252
|
+
m.useEffect(() => {
|
|
253
|
+
b("key" in (t?.config ?? {}) ? t?.config?.key ?? "" : "");
|
|
254
|
+
}, [t]), m.useEffect(() => {
|
|
245
255
|
d(e ?? "");
|
|
246
256
|
}, [e]);
|
|
247
|
-
const D =
|
|
248
|
-
!
|
|
249
|
-
}, [
|
|
250
|
-
!
|
|
251
|
-
}, [V,
|
|
252
|
-
if (!
|
|
257
|
+
const D = m.useCallback(() => {
|
|
258
|
+
!y || a || y(E);
|
|
259
|
+
}, [a, E, y]), r = m.useCallback(() => {
|
|
260
|
+
!s || a || V.trim() === "" && s(void 0);
|
|
261
|
+
}, [V, a, s]), o = m.useCallback((i) => {
|
|
262
|
+
if (!s || a) return;
|
|
253
263
|
const N = i.value;
|
|
254
264
|
if (!N) return;
|
|
255
|
-
|
|
265
|
+
s(N);
|
|
256
266
|
const h = i?.valueData?.displayText?.join(" ") ?? e ?? "";
|
|
257
267
|
d(h);
|
|
258
|
-
}, [e,
|
|
268
|
+
}, [e, a, s]);
|
|
259
269
|
return /* @__PURE__ */ S("div", { children: [
|
|
260
270
|
/* @__PURE__ */ S(X, { justify: "space-between", children: [
|
|
261
|
-
/* @__PURE__ */ c(
|
|
262
|
-
p ? /* @__PURE__ */ c(re, { color: "error", onClick: p, children: /* @__PURE__ */ c(
|
|
271
|
+
/* @__PURE__ */ c(Be, { color: "info", children: t?.variant }),
|
|
272
|
+
p ? /* @__PURE__ */ c(re, { color: "error", onClick: p, children: /* @__PURE__ */ c(Oe, { size: 16 }) }) : null
|
|
263
273
|
] }),
|
|
264
274
|
/* @__PURE__ */ S(X, { mt: 0.7, style: {
|
|
265
275
|
flexDirection: "column",
|
|
@@ -268,154 +278,154 @@ const Te = /* @__PURE__ */ new Set(["ITEM_OF_COLLECTION", "REGEX", "NUMBER_RANGE
|
|
|
268
278
|
l ? /* @__PURE__ */ S(X, { align: "center", style: {
|
|
269
279
|
gap: ".7rem"
|
|
270
280
|
}, children: [
|
|
271
|
-
|
|
272
|
-
/* @__PURE__ */ c(F, { left: /* @__PURE__ */ c(A, { size: "sm", children: "DataType" }), leftType: "icon", disabled:
|
|
281
|
+
t.variant === "CONTAINS_KEY" ? /* @__PURE__ */ c(F, { left: /* @__PURE__ */ c(A, { size: "sm", children: "Key" }), leftType: "icon", disabled: a, defaultValue: E, onChange: (i) => "value" in i.target && b(i.target.value), onBlur: D }) : null,
|
|
282
|
+
/* @__PURE__ */ c(F, { left: /* @__PURE__ */ c(A, { size: "sm", children: "DataType" }), leftType: "icon", disabled: a, suggestionsFooter: /* @__PURE__ */ c(ye, {}), suggestions: Ae(B), value: V, onChange: (i) => "value" in i.target && d(i.target.value), onBlur: r, onSuggestionSelect: o })
|
|
273
283
|
] }) : null,
|
|
274
|
-
|
|
284
|
+
t.variant != "REGEX" && t.variant != "ITEM_OF_COLLECTION" && t.variant != "NUMBER_RANGE" ? /* @__PURE__ */ c(ve, { children: /* @__PURE__ */ S(X, { align: "center", style: {
|
|
275
285
|
gap: ".7rem"
|
|
276
286
|
}, children: [
|
|
277
287
|
"+",
|
|
278
288
|
I,
|
|
279
289
|
" rules included",
|
|
280
|
-
/* @__PURE__ */ c(re, { color: "primary", onClick:
|
|
290
|
+
/* @__PURE__ */ c(re, { color: "primary", onClick: n, children: "Show/Hide Rules" })
|
|
281
291
|
] }) }) : null
|
|
282
292
|
] })
|
|
283
293
|
] });
|
|
284
|
-
}, ue = (
|
|
294
|
+
}, ue = (t) => t ? "pattern" in t || t?.__typename === "DataTypeRulesRegexConfig" ? t?.pattern ?? "" : "items" in t || t?.__typename === "DataTypeRulesItemOfCollectionConfig" ? JSON.stringify(t.items) : t : "", Je = (t, e, n) => {
|
|
285
295
|
const {
|
|
286
296
|
variant: p,
|
|
287
|
-
numberRangeKey:
|
|
288
|
-
} =
|
|
289
|
-
if (
|
|
297
|
+
numberRangeKey: a
|
|
298
|
+
} = n ?? {}, y = p === "NUMBER_RANGE", s = e ?? void 0;
|
|
299
|
+
if (y) {
|
|
290
300
|
const u = {
|
|
291
301
|
__typename: "DataTypeRulesNumberRangeConfig",
|
|
292
|
-
...
|
|
302
|
+
...s
|
|
293
303
|
};
|
|
294
|
-
if (typeof
|
|
304
|
+
if (typeof t != "string")
|
|
295
305
|
return {
|
|
296
306
|
...u,
|
|
297
|
-
...
|
|
307
|
+
...t
|
|
298
308
|
};
|
|
299
|
-
if (!
|
|
309
|
+
if (!a)
|
|
300
310
|
return u;
|
|
301
311
|
const T = {
|
|
302
312
|
...u
|
|
303
313
|
};
|
|
304
|
-
switch (
|
|
314
|
+
switch (a) {
|
|
305
315
|
case "from":
|
|
306
316
|
T.from = (() => {
|
|
307
|
-
if (
|
|
308
|
-
const l = Number(
|
|
317
|
+
if (t.trim() === "") return;
|
|
318
|
+
const l = Number(t);
|
|
309
319
|
return Number.isFinite(l) ? l : u.from;
|
|
310
320
|
})();
|
|
311
321
|
break;
|
|
312
322
|
case "steps":
|
|
313
323
|
T.steps = (() => {
|
|
314
|
-
if (
|
|
315
|
-
const l = Number(
|
|
324
|
+
if (t.trim() === "") return;
|
|
325
|
+
const l = Number(t);
|
|
316
326
|
return Number.isFinite(l) ? l : u.steps;
|
|
317
327
|
})();
|
|
318
328
|
break;
|
|
319
329
|
case "to":
|
|
320
330
|
T.to = (() => {
|
|
321
|
-
if (
|
|
322
|
-
const l = Number(
|
|
331
|
+
if (t.trim() === "") return;
|
|
332
|
+
const l = Number(t);
|
|
323
333
|
return Number.isFinite(l) ? l : u.to;
|
|
324
334
|
})();
|
|
325
335
|
break;
|
|
326
336
|
}
|
|
327
337
|
return T;
|
|
328
338
|
}
|
|
329
|
-
if (!
|
|
330
|
-
if (typeof
|
|
331
|
-
return
|
|
339
|
+
if (!s) {
|
|
340
|
+
if (typeof t != "string")
|
|
341
|
+
return t;
|
|
332
342
|
try {
|
|
333
|
-
return JSON.parse(
|
|
343
|
+
return JSON.parse(t);
|
|
334
344
|
} catch {
|
|
335
345
|
return;
|
|
336
346
|
}
|
|
337
347
|
}
|
|
338
|
-
if (typeof
|
|
339
|
-
return
|
|
340
|
-
if (
|
|
348
|
+
if (typeof t != "string")
|
|
349
|
+
return t;
|
|
350
|
+
if (s.__typename === "DataTypeRulesRegexConfig" || "pattern" in s)
|
|
341
351
|
return {
|
|
342
|
-
...
|
|
343
|
-
pattern:
|
|
352
|
+
...s,
|
|
353
|
+
pattern: t
|
|
344
354
|
};
|
|
345
|
-
if (
|
|
355
|
+
if (s.__typename === "DataTypeRulesItemOfCollectionConfig" || "items" in s)
|
|
346
356
|
try {
|
|
347
357
|
return {
|
|
348
|
-
...
|
|
349
|
-
items: JSON.parse(
|
|
358
|
+
...s,
|
|
359
|
+
items: JSON.parse(t)
|
|
350
360
|
};
|
|
351
361
|
} catch {
|
|
352
|
-
return
|
|
362
|
+
return s;
|
|
353
363
|
}
|
|
354
364
|
try {
|
|
355
|
-
return JSON.parse(
|
|
365
|
+
return JSON.parse(t);
|
|
356
366
|
} catch {
|
|
357
|
-
return
|
|
367
|
+
return s;
|
|
358
368
|
}
|
|
359
|
-
}, q = (
|
|
360
|
-
if (
|
|
361
|
-
return JSON.stringify(
|
|
362
|
-
},
|
|
363
|
-
if (
|
|
364
|
-
return
|
|
365
|
-
}, Le = (
|
|
366
|
-
if (
|
|
367
|
-
return L(
|
|
368
|
-
}, oe = (
|
|
369
|
+
}, q = (t) => t == null ? t : JSON.parse(JSON.stringify(t)), pe = (t) => {
|
|
370
|
+
if (t)
|
|
371
|
+
return JSON.stringify(t);
|
|
372
|
+
}, me = (t) => {
|
|
373
|
+
if (t?.config?.dataTypeIdentifier)
|
|
374
|
+
return t?.config?.dataTypeIdentifier?.dataType ?? t?.config?.dataTypeIdentifier?.genericType ?? void 0;
|
|
375
|
+
}, Le = (t, e) => pe(t) === pe(e), Pe = (t, e) => !t || !e?.rules?.nodes || !Ne(t) ? !1 : !!Ce(t, e), Ce = (t, e) => !t || !e?.rules?.nodes ? void 0 : e.rules.nodes?.filter(Boolean).find((p) => ce(t, p)), L = (t) => t != null && t.rules !== void 0, J = (t) => t != null && typeof t == "object" && "genericMappers" in t, Y = (t) => {
|
|
376
|
+
if (t)
|
|
377
|
+
return L(t) ? t : t.dataType ?? void 0;
|
|
378
|
+
}, oe = (t) => (t.rules ? t.rules.nodes || (t.rules.nodes = []) : t.rules = {
|
|
369
379
|
nodes: []
|
|
370
|
-
},
|
|
371
|
-
if (!
|
|
372
|
-
const
|
|
373
|
-
if (!p || !
|
|
374
|
-
return
|
|
375
|
-
const
|
|
376
|
-
return
|
|
380
|
+
}, t.rules.nodes), Ie = (t, e) => {
|
|
381
|
+
if (!t && !e) return;
|
|
382
|
+
const n = q(t ?? e), p = Y(n), a = Y(e);
|
|
383
|
+
if (!p || !a)
|
|
384
|
+
return n;
|
|
385
|
+
const y = oe(p);
|
|
386
|
+
return a.rules?.nodes?.filter(Boolean)?.forEach((u) => {
|
|
377
387
|
if (!u) return;
|
|
378
|
-
const T =
|
|
388
|
+
const T = y.findIndex((l) => ce(l, u));
|
|
379
389
|
if (T === -1) {
|
|
380
390
|
const l = q(u);
|
|
381
|
-
|
|
391
|
+
se(l, u), y.push(l), ae(l, u);
|
|
382
392
|
} else {
|
|
383
|
-
const l =
|
|
384
|
-
|
|
393
|
+
const l = y[T];
|
|
394
|
+
se(l, u), ae(l, u);
|
|
385
395
|
}
|
|
386
|
-
}),
|
|
387
|
-
},
|
|
388
|
-
const
|
|
389
|
-
if (!
|
|
390
|
-
const
|
|
391
|
-
if (!
|
|
392
|
-
const
|
|
393
|
-
|
|
394
|
-
}, ce = (
|
|
395
|
-
if (!
|
|
396
|
-
const
|
|
397
|
-
return
|
|
398
|
-
variant:
|
|
399
|
-
config:
|
|
396
|
+
}), n;
|
|
397
|
+
}, ae = (t, e) => {
|
|
398
|
+
const n = t?.config?.dataTypeIdentifier, p = e?.config?.dataTypeIdentifier;
|
|
399
|
+
if (!n || !p) return;
|
|
400
|
+
const a = n.dataType ?? n.genericType, y = p.dataType ?? p.genericType;
|
|
401
|
+
if (!a || !y) return;
|
|
402
|
+
const s = Ie(a, y);
|
|
403
|
+
s && (L(s) ? n.dataType = s : n.genericType = s);
|
|
404
|
+
}, ce = (t, e) => {
|
|
405
|
+
if (!t || !e) return !1;
|
|
406
|
+
const n = Ne(t), p = Ee(e);
|
|
407
|
+
return n && p ? n === p : t.id && e.id ? t.id === e.id : JSON.stringify({
|
|
408
|
+
variant: t.variant,
|
|
409
|
+
config: t.config
|
|
400
410
|
}) === JSON.stringify({
|
|
401
411
|
variant: e.variant,
|
|
402
412
|
config: e.config
|
|
403
413
|
});
|
|
404
|
-
}, Ne = (
|
|
405
|
-
if (
|
|
406
|
-
return
|
|
407
|
-
}, Ee = (
|
|
408
|
-
if (
|
|
409
|
-
return
|
|
410
|
-
variant:
|
|
411
|
-
config:
|
|
414
|
+
}, Ne = (t) => {
|
|
415
|
+
if (t)
|
|
416
|
+
return t?.[he];
|
|
417
|
+
}, Ee = (t) => {
|
|
418
|
+
if (t)
|
|
419
|
+
return t.id ? `id:${t.id}` : `config:${JSON.stringify({
|
|
420
|
+
variant: t.variant,
|
|
421
|
+
config: t.config
|
|
412
422
|
})}`;
|
|
413
|
-
},
|
|
414
|
-
const
|
|
415
|
-
|
|
423
|
+
}, se = (t, e) => {
|
|
424
|
+
const n = Ee(e);
|
|
425
|
+
n && (t[he] = n);
|
|
416
426
|
};
|
|
417
|
-
function ze(
|
|
418
|
-
return !
|
|
427
|
+
function ze(t) {
|
|
428
|
+
return !t;
|
|
419
429
|
}
|
|
420
430
|
export {
|
|
421
431
|
de as DFlowInputDataType
|