strategy-panel 1.0.1 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.fatherrc.ts +11 -26
- package/.umirc.ts +4 -0
- package/README.md +33 -33
- package/es/assets/decive.svg +1 -1
- package/es/assets/hand.svg +1 -1
- package/es/assets/lock.svg +8 -0
- package/es/components/canvas/component-tree-panel/category-tree/category-type.d.ts +1 -0
- package/es/{common/graph-common → components/canvas/component-tree-panel/category-tree}/category-type.js +28 -12
- package/es/{pages → components/canvas}/component-tree-panel/category-tree/index.d.ts +17 -16
- package/es/{pages → components/canvas}/component-tree-panel/category-tree/index.js +14 -14
- package/es/{pages → components/canvas}/component-tree-panel/category-tree/index.less +36 -36
- package/es/{pages → components/canvas}/component-tree-panel/category-tree/node-title.d.ts +12 -12
- package/es/{pages → components/canvas}/component-tree-panel/category-tree/node-title.js +5 -3
- package/es/{pages → components/canvas}/component-tree-panel/index.d.ts +17 -17
- package/es/{pages → components/canvas}/component-tree-panel/index.js +1 -0
- package/es/{pages → components/canvas}/component-tree-panel/index.less +1 -0
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/data-origin.d.ts +49 -49
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/data-origin.js +26 -34
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/index.d.ts +11 -11
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/index.js +15 -23
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/style.less +1 -1
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/cross-line.d.ts +9 -9
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/cross-line.js +6 -10
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/index.d.ts +10 -9
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/index.js +17 -13
- package/es/{pages → components/canvas}/config-panel/components/condition-configuration/style.less +74 -74
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/components/cycle-time.d.ts +9 -9
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/components/cycle-time.js +24 -33
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/components/time-horizon.d.ts +10 -10
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/components/time-horizon.js +18 -28
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/delay-time.d.ts +9 -9
- package/es/components/canvas/config-panel/components/time-trigger/effective-time.d.ts +7 -0
- package/es/components/canvas/config-panel/components/time-trigger/effective-time.js +43 -0
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/index.d.ts +9 -8
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/index.js +18 -17
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/interval-time.d.ts +9 -9
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/interval-time.js +4 -8
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/persistent-time.d.ts +9 -9
- package/es/components/canvas/config-panel/components/time-trigger/section-Detail.d.ts +10 -0
- package/es/components/canvas/config-panel/components/time-trigger/section-Detail.js +125 -0
- package/es/components/canvas/config-panel/components/time-trigger/section-time.d.ts +9 -0
- package/es/components/canvas/config-panel/components/time-trigger/section-time.js +81 -0
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/timing-time.d.ts +9 -9
- package/es/{pages → components/canvas}/config-panel/components/time-trigger/timing-time.js +7 -11
- package/es/{pages → components/canvas}/config-panel/config-common.d.ts +38 -37
- package/es/{pages → components/canvas}/config-panel/config-common.js +9 -15
- package/es/{pages → components/canvas}/config-panel/index.d.ts +14 -13
- package/es/{pages → components/canvas}/config-panel/index.js +2 -2
- package/es/{pages → components/canvas}/config-panel/node-form.d.ts +23 -22
- package/es/{pages → components/canvas}/config-panel/node-form.js +14 -16
- package/es/{pages → components/canvas}/config-panel/style.less +90 -81
- package/es/{pages → components/canvas}/dag-canvas/canvas-content.d.ts +11 -10
- package/es/{pages → components/canvas}/dag-canvas/canvas-content.js +23 -12
- package/es/{pages → components/canvas}/dag-canvas/index.d.ts +23 -18
- package/es/{pages → components/canvas}/dag-canvas/index.js +5 -2
- package/es/{pages → components/canvas}/dag-canvas/preview.d.ts +10 -10
- package/es/components/canvas/dag-canvas/preview.js +53 -0
- package/es/{pages → components/canvas}/index.d.ts +48 -42
- package/es/{pages → components/canvas}/index.js +20 -10
- package/es/{pages → components/canvas}/index.less +2 -2
- package/es/{pages → components/canvas}/strategy-header/index.d.ts +48 -56
- package/es/components/canvas/strategy-header/index.js +210 -0
- package/es/{pages → components/canvas}/strategy-header/style.less +4 -3
- package/es/{pages → components/canvas}/strategy-header/theme-switch/index.d.ts +4 -4
- package/es/{pages → components/canvas}/strategy-header/theme-switch/index.js +2 -3
- package/es/index.d.ts +9 -8
- package/es/index.js +8 -7
- package/es/packages/graph-canvas/graph-common.d.ts +19 -0
- package/es/packages/graph-canvas/graph-common.js +19 -0
- package/es/packages/graph-canvas/graph-model/edge/group-edge/index.d.ts +4 -0
- package/es/packages/graph-canvas/graph-model/edge/group-edge/index.js +63 -0
- package/es/packages/graph-canvas/graph-model/edge/index.d.ts +2 -0
- package/es/packages/graph-canvas/graph-model/edge/index.js +2 -0
- package/es/packages/graph-canvas/graph-model/node/application-node/application-element.d.ts +9 -0
- package/es/packages/graph-canvas/graph-model/node/application-node/application-element.js +20 -0
- package/es/packages/graph-canvas/graph-model/node/application-node/application-element.less +17 -0
- package/es/packages/graph-canvas/graph-model/node/application-node/index.d.ts +7 -0
- package/es/{common/graph-common/shape/nodes/GroupNode.js → packages/graph-canvas/graph-model/node/application-node/index.js} +42 -22
- package/es/{common/graph-common/shape/nodes/CommonNode.d.ts → packages/graph-canvas/graph-model/node/common-node/index.d.ts} +7 -5
- package/es/{common/graph-common/shape/nodes/CommonNode.js → packages/graph-canvas/graph-model/node/common-node/index.js} +8 -7
- package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/common-node}/node-element.d.ts +9 -9
- package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/common-node}/node-element.js +16 -14
- package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/common-node}/node-element.less +4 -4
- package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/condition-node}/condition-element.d.ts +9 -9
- package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/condition-node}/condition-element.js +20 -15
- package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/condition-node}/condition-element.less +76 -81
- package/es/packages/graph-canvas/graph-model/node/condition-node/images/rhombus.svg +3 -0
- package/es/{common/graph-common/shape/nodes/ConditionJudgment.d.ts → packages/graph-canvas/graph-model/node/condition-node/index.d.ts} +5 -5
- package/es/{common/graph-common/shape/nodes/ConditionJudgment.js → packages/graph-canvas/graph-model/node/condition-node/index.js} +7 -6
- package/es/packages/graph-canvas/graph-model/node/index.d.ts +5 -0
- package/es/packages/graph-canvas/graph-model/node/index.js +5 -0
- package/es/packages/graph-canvas/graph-model/node/logical-node/images/AND.svg +11 -0
- package/es/packages/graph-canvas/graph-model/node/logical-node/images/OR.svg +11 -0
- package/es/packages/graph-canvas/graph-model/node/logical-node/images/XOR.svg +11 -0
- package/es/packages/graph-canvas/graph-model/node/logical-node/images/locking.svg +5 -0
- package/es/packages/graph-canvas/graph-model/node/logical-node/images/unlock.svg +5 -0
- package/es/packages/graph-canvas/graph-model/node/logical-node/index.d.ts +6 -0
- package/es/{common/graph-common/shape/nodes/LogicalNode.js → packages/graph-canvas/graph-model/node/logical-node/index.js} +15 -15
- package/es/packages/graph-canvas/graph-model/node/logical-node/logical-element.d.ts +9 -0
- package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/logical-node}/logical-element.js +36 -19
- package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/logical-node}/logical-element.less +4 -9
- package/es/packages/graph-canvas/graph-model/node/style.less +8 -0
- package/es/{common → packages/graph-canvas}/graph-utils/graph.d.ts +87 -83
- package/es/{common → packages/graph-canvas}/graph-utils/graph.js +8 -4
- package/es/{pages/rx-models/experiment-graph.d.ts → packages/graph-canvas/index.d.ts} +79 -82
- package/es/{pages/rx-models/experiment-graph.js → packages/graph-canvas/index.js} +285 -252
- package/es/packages/graph-canvas/node-types.d.ts +6 -0
- package/es/packages/graph-canvas/node-types.js +54 -0
- package/es/packages/graph-canvas/typings.d.ts +5 -0
- package/es/{common/constants → packages/graph-common}/global.d.ts +1 -1
- package/es/{common/constants → packages/graph-common}/graph.d.ts +12 -10
- package/es/{common/constants → packages/graph-common}/graph.js +4 -2
- package/es/{pages/rx-models → packages/graph-core}/graph-util.d.ts +182 -186
- package/es/{pages/rx-models → packages/graph-core}/graph-util.js +8 -15
- package/es/{pages/rx-models/graph-core.d.ts → packages/graph-core/index.d.ts} +96 -96
- package/es/{pages/rx-models/graph-core.js → packages/graph-core/index.js} +119 -87
- package/es/packages/graph-core/typing.d.ts +107 -0
- package/es/{common/graph-common → packages/graph-model}/connector/index.d.ts +1 -1
- package/es/packages/graph-model/connector/index.js +14 -0
- package/es/packages/graph-model/edge/edge.less +8 -0
- package/es/packages/graph-model/edge/index.d.ts +5 -0
- package/es/{common/graph-common/shape/edge.js → packages/graph-model/edge/index.js} +10 -61
- package/es/packages/graph-model/node/index.d.ts +7 -0
- package/es/{common/graph-common/shape/nodes/BaseNode.js → packages/graph-model/node/index.js} +12 -3
- package/es/{common/graph-common/node-element/common-element.less → packages/graph-model/node/node-basic.less} +1 -0
- package/es/{hooks → packages/hooks}/useObservableState.d.ts +3 -3
- package/es/packages/hooks/withMode.d.ts +3 -0
- package/es/packages/hooks/withMode.js +12 -0
- package/es/style/default.less +8 -0
- package/es/style/svgRaw.d.ts +1 -0
- package/es/style/svgRaw.js +1 -0
- package/es/typings.d.ts +2 -8
- package/es/utils/utils.d.ts +1 -1
- package/lib/assets/AND.svg +11 -0
- package/lib/assets/OR.svg +11 -0
- package/lib/assets/XOR.svg +11 -0
- package/lib/assets/add.svg +13 -0
- package/lib/assets/alarm.svg +11 -0
- package/lib/assets/application.svg +11 -0
- package/lib/assets/cancel.svg +13 -0
- package/lib/assets/check.svg +12 -0
- package/lib/assets/condition.svg +12 -0
- package/lib/assets/control.svg +11 -0
- package/lib/assets/decive.svg +11 -0
- package/lib/assets/delete.svg +11 -0
- package/lib/assets/device.svg +11 -0
- package/lib/assets/edit.svg +11 -0
- package/lib/assets/hand.svg +11 -0
- package/lib/assets/link.svg +11 -0
- package/lib/assets/lock.svg +8 -0
- package/lib/assets/logical.svg +12 -0
- package/lib/assets/notice.svg +11 -0
- package/lib/assets/order.svg +11 -0
- package/lib/assets/relation.svg +11 -0
- package/lib/assets/rhombus.svg +3 -0
- package/lib/assets/save.svg +13 -0
- package/lib/assets/time.svg +11 -0
- package/lib/assets/variate.svg +12 -0
- package/lib/components/canvas/component-tree-panel/category-tree/category-type.d.ts +1 -0
- package/lib/components/canvas/component-tree-panel/category-tree/category-type.js +111 -0
- package/lib/components/canvas/component-tree-panel/category-tree/index.d.ts +17 -0
- package/lib/components/canvas/component-tree-panel/category-tree/index.js +115 -0
- package/lib/components/canvas/component-tree-panel/category-tree/index.less +36 -0
- package/lib/components/canvas/component-tree-panel/category-tree/node-title.d.ts +12 -0
- package/lib/components/canvas/component-tree-panel/category-tree/node-title.js +75 -0
- package/lib/components/canvas/component-tree-panel/category-tree/node-title.less +113 -0
- package/lib/components/canvas/component-tree-panel/index.d.ts +17 -0
- package/lib/components/canvas/component-tree-panel/index.js +33 -0
- package/lib/components/canvas/component-tree-panel/index.less +52 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/data-origin.d.ts +49 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/data-origin.js +229 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/index.d.ts +11 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/index.js +187 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/style.less +13 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/cross-line.d.ts +9 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/cross-line.js +57 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/index.d.ts +10 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/index.js +216 -0
- package/lib/components/canvas/config-panel/components/condition-configuration/style.less +74 -0
- package/lib/components/canvas/config-panel/components/time-trigger/components/cycle-time.d.ts +9 -0
- package/lib/components/canvas/config-panel/components/time-trigger/components/cycle-time.js +108 -0
- package/lib/components/canvas/config-panel/components/time-trigger/components/time-horizon.d.ts +10 -0
- package/lib/components/canvas/config-panel/components/time-trigger/components/time-horizon.js +78 -0
- package/lib/components/canvas/config-panel/components/time-trigger/delay-time.d.ts +9 -0
- package/lib/components/canvas/config-panel/components/time-trigger/delay-time.js +33 -0
- package/lib/components/canvas/config-panel/components/time-trigger/effective-time.d.ts +7 -0
- package/lib/components/canvas/config-panel/components/time-trigger/effective-time.js +58 -0
- package/lib/components/canvas/config-panel/components/time-trigger/index.d.ts +9 -0
- package/lib/components/canvas/config-panel/components/time-trigger/index.js +114 -0
- package/lib/components/canvas/config-panel/components/time-trigger/interval-time.d.ts +9 -0
- package/lib/components/canvas/config-panel/components/time-trigger/interval-time.js +63 -0
- package/lib/components/canvas/config-panel/components/time-trigger/persistent-time.d.ts +9 -0
- package/lib/components/canvas/config-panel/components/time-trigger/persistent-time.js +33 -0
- package/lib/components/canvas/config-panel/components/time-trigger/section-Detail.d.ts +10 -0
- package/lib/components/canvas/config-panel/components/time-trigger/section-Detail.js +140 -0
- package/lib/components/canvas/config-panel/components/time-trigger/section-time.d.ts +9 -0
- package/lib/components/canvas/config-panel/components/time-trigger/section-time.js +96 -0
- package/lib/components/canvas/config-panel/components/time-trigger/timing-time.d.ts +9 -0
- package/lib/components/canvas/config-panel/components/time-trigger/timing-time.js +65 -0
- package/lib/components/canvas/config-panel/config-common.d.ts +38 -0
- package/lib/components/canvas/config-panel/config-common.js +152 -0
- package/lib/components/canvas/config-panel/index.d.ts +14 -0
- package/lib/components/canvas/config-panel/index.js +68 -0
- package/lib/components/canvas/config-panel/node-form.d.ts +23 -0
- package/lib/components/canvas/config-panel/node-form.js +97 -0
- package/lib/components/canvas/config-panel/style.less +90 -0
- package/lib/components/canvas/dag-canvas/canvas-content.d.ts +11 -0
- package/lib/components/canvas/dag-canvas/canvas-content.js +130 -0
- package/lib/components/canvas/dag-canvas/canvas-content.less +5 -0
- package/lib/components/canvas/dag-canvas/index.d.ts +23 -0
- package/lib/components/canvas/dag-canvas/index.js +53 -0
- package/lib/components/canvas/dag-canvas/index.less +11 -0
- package/lib/components/canvas/dag-canvas/preview.d.ts +10 -0
- package/lib/components/canvas/dag-canvas/preview.js +73 -0
- package/lib/components/canvas/index.d.ts +48 -0
- package/lib/components/canvas/index.js +107 -0
- package/lib/components/canvas/index.less +50 -0
- package/lib/components/canvas/strategy-header/index.d.ts +48 -0
- package/lib/components/canvas/strategy-header/index.js +229 -0
- package/lib/components/canvas/strategy-header/style.less +23 -0
- package/lib/components/canvas/strategy-header/theme-switch/index.d.ts +4 -0
- package/lib/components/canvas/strategy-header/theme-switch/index.js +30 -0
- package/lib/components/canvas/strategy-header/theme-switch/style.less +11 -0
- package/lib/index.d.ts +9 -0
- package/lib/index.js +71 -0
- package/lib/packages/graph-canvas/graph-common.d.ts +19 -0
- package/lib/packages/graph-canvas/graph-common.js +27 -0
- package/lib/packages/graph-canvas/graph-model/edge/group-edge/edge.less +8 -0
- package/lib/packages/graph-canvas/graph-model/edge/group-edge/index.d.ts +4 -0
- package/lib/packages/graph-canvas/graph-model/edge/group-edge/index.js +74 -0
- package/lib/packages/graph-canvas/graph-model/edge/index.d.ts +2 -0
- package/lib/packages/graph-canvas/graph-model/edge/index.js +15 -0
- package/lib/packages/graph-canvas/graph-model/node/application-node/application-element.d.ts +9 -0
- package/lib/packages/graph-canvas/graph-model/node/application-node/application-element.js +31 -0
- package/lib/packages/graph-canvas/graph-model/node/application-node/application-element.less +17 -0
- package/lib/packages/graph-canvas/graph-model/node/application-node/index.d.ts +7 -0
- package/lib/packages/graph-canvas/graph-model/node/application-node/index.js +133 -0
- package/lib/packages/graph-canvas/graph-model/node/common-node/index.d.ts +7 -0
- package/lib/packages/graph-canvas/graph-model/node/common-node/index.js +133 -0
- package/lib/packages/graph-canvas/graph-model/node/common-node/node-element.d.ts +9 -0
- package/lib/packages/graph-canvas/graph-model/node/common-node/node-element.js +69 -0
- package/lib/packages/graph-canvas/graph-model/node/common-node/node-element.less +48 -0
- package/{es/common/graph-common/node-element/logical-element.d.ts → lib/packages/graph-canvas/graph-model/node/condition-node/condition-element.d.ts} +9 -9
- package/lib/packages/graph-canvas/graph-model/node/condition-node/condition-element.js +81 -0
- package/lib/packages/graph-canvas/graph-model/node/condition-node/condition-element.less +76 -0
- package/lib/packages/graph-canvas/graph-model/node/condition-node/images/rhombus.svg +3 -0
- package/{es/common/graph-common/shape/nodes/LogicalNode.d.ts → lib/packages/graph-canvas/graph-model/node/condition-node/index.d.ts} +5 -5
- package/lib/packages/graph-canvas/graph-model/node/condition-node/index.js +143 -0
- package/lib/packages/graph-canvas/graph-model/node/index.d.ts +5 -0
- package/lib/packages/graph-canvas/graph-model/node/index.js +39 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/images/AND.svg +11 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/images/OR.svg +11 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/images/XOR.svg +11 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/images/locking.svg +5 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/images/unlock.svg +5 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/index.d.ts +6 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/index.js +143 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/logical-element.d.ts +9 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/logical-element.js +98 -0
- package/lib/packages/graph-canvas/graph-model/node/logical-node/logical-element.less +49 -0
- package/lib/packages/graph-canvas/graph-model/node/style.less +8 -0
- package/lib/packages/graph-canvas/graph-utils/graph.d.ts +87 -0
- package/lib/packages/graph-canvas/graph-utils/graph.js +124 -0
- package/lib/packages/graph-canvas/index.d.ts +79 -0
- package/lib/packages/graph-canvas/index.js +1292 -0
- package/lib/packages/graph-canvas/node-types.d.ts +6 -0
- package/lib/packages/graph-canvas/node-types.js +66 -0
- package/lib/packages/graph-canvas/typings.d.ts +5 -0
- package/lib/packages/graph-common/global.d.ts +1 -0
- package/lib/packages/graph-common/global.js +8 -0
- package/lib/packages/graph-common/graph.d.ts +12 -0
- package/lib/packages/graph-common/graph.js +37 -0
- package/lib/packages/graph-core/graph-util.d.ts +182 -0
- package/lib/packages/graph-core/graph-util.js +368 -0
- package/lib/packages/graph-core/index.d.ts +96 -0
- package/lib/packages/graph-core/index.js +798 -0
- package/lib/packages/graph-core/typing.d.ts +107 -0
- package/lib/packages/graph-model/connector/index.d.ts +1 -0
- package/lib/packages/graph-model/connector/index.js +17 -0
- package/lib/packages/graph-model/edge/edge.less +8 -0
- package/lib/packages/graph-model/edge/index.d.ts +5 -0
- package/lib/packages/graph-model/edge/index.js +73 -0
- package/lib/packages/graph-model/node/index.d.ts +7 -0
- package/lib/packages/graph-model/node/index.js +63 -0
- package/lib/packages/graph-model/node/node-basic.less +118 -0
- package/lib/packages/hooks/useObservableState.d.ts +3 -0
- package/lib/packages/hooks/useObservableState.js +55 -0
- package/lib/packages/hooks/withMode.d.ts +3 -0
- package/lib/packages/hooks/withMode.js +22 -0
- package/lib/style/basic.less +12 -0
- package/lib/style/default.less +10 -0
- package/lib/style/position.less +25 -0
- package/lib/style/svgRaw.d.ts +1 -0
- package/lib/style/svgRaw.js +8 -0
- package/lib/style/theme-light.less +7 -0
- package/lib/style/variable.less +3 -0
- package/lib/typings.d.ts +8 -0
- package/lib/utils/utils.d.ts +1 -0
- package/lib/utils/utils.js +13 -0
- package/package.json +38 -37
- package/tsconfig.json +1 -1
- package/es/common/graph-common/category-type.d.ts +0 -16
- package/es/common/graph-common/connector/index.js +0 -14
- package/es/common/graph-common/node-element/node-group.d.ts +0 -8
- package/es/common/graph-common/node-element/node-group.js +0 -395
- package/es/common/graph-common/node-element/node-group.less +0 -53
- package/es/common/graph-common/node-popover/index.d.ts +0 -7
- package/es/common/graph-common/node-popover/index.js +0 -11
- package/es/common/graph-common/node-popover/index.less +0 -5
- package/es/common/graph-common/node-types.d.ts +0 -28
- package/es/common/graph-common/node-types.js +0 -60
- package/es/common/graph-common/shape/edge.d.ts +0 -10
- package/es/common/graph-common/shape/node.d.ts +0 -6
- package/es/common/graph-common/shape/node.js +0 -6
- package/es/common/graph-common/shape/nodes/BaseNode.d.ts +0 -4
- package/es/common/graph-common/shape/nodes/GroupNode.d.ts +0 -4
- package/es/component/cut.d.ts +0 -10
- package/es/component/cut.js +0 -34
- package/es/component/cut.less +0 -6
- package/es/component/item-name.d.ts +0 -6
- package/es/component/item-name.js +0 -30
- package/es/component/keyword.d.ts +0 -9
- package/es/component/keyword.js +0 -26
- package/es/component/keyword.less +0 -11
- package/es/component/rx-component/rx-input.d.ts +0 -8
- package/es/component/rx-component/rx-input.js +0 -47
- package/es/hooks/withMode.d.ts +0 -1
- package/es/hooks/withMode.js +0 -16
- package/es/pages/dag-canvas/preview.js +0 -42
- package/es/pages/rx-models/graph-core.less +0 -14
- package/es/pages/rx-models/typing.d.ts +0 -126
- package/es/pages/strategy-header/index.js +0 -154
- /package/es/{pages → components/canvas}/component-tree-panel/category-tree/node-title.less +0 -0
- /package/es/{pages → components/canvas}/config-panel/components/time-trigger/delay-time.js +0 -0
- /package/es/{pages → components/canvas}/config-panel/components/time-trigger/persistent-time.js +0 -0
- /package/es/{pages → components/canvas}/dag-canvas/canvas-content.less +0 -0
- /package/es/{pages → components/canvas}/dag-canvas/index.less +0 -0
- /package/es/{pages → components/canvas}/strategy-header/theme-switch/style.less +0 -0
- /package/es/{common/graph-common/shape → packages/graph-canvas/graph-model/edge/group-edge}/edge.less +0 -0
- /package/es/{common/constants → packages/graph-common}/global.js +0 -0
- /package/es/{hooks → packages/hooks}/useObservableState.js +0 -0
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import type { EdgeView } from '@antv/x6';
|
|
2
|
+
|
|
3
|
+
// 实验
|
|
4
|
+
export namespace NExperiment {
|
|
5
|
+
export interface Experiment {
|
|
6
|
+
description: string;
|
|
7
|
+
name: string;
|
|
8
|
+
id: number;
|
|
9
|
+
gmtCreate: string;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
// 实验图
|
|
14
|
+
export namespace NExperimentGraph {
|
|
15
|
+
export interface ExperimentGraph {
|
|
16
|
+
nodes: Node[];
|
|
17
|
+
groups: Group[];
|
|
18
|
+
links: Link[];
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface ModalParams {
|
|
22
|
+
type: string;
|
|
23
|
+
experimentId: string;
|
|
24
|
+
nodeInstanceId?: number;
|
|
25
|
+
node?: Node;
|
|
26
|
+
ctx?: any;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export interface ContextMenuInfo {
|
|
30
|
+
type: 'edge' | 'graph';
|
|
31
|
+
data: EdgeView.PositionEventArgs<any>;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export interface Node {
|
|
35
|
+
outPorts: OutPort[];
|
|
36
|
+
inPorts: InPort[];
|
|
37
|
+
positionX: number;
|
|
38
|
+
positionY: number;
|
|
39
|
+
codeName?: string;
|
|
40
|
+
category?: string;
|
|
41
|
+
name: string;
|
|
42
|
+
id: string;
|
|
43
|
+
nodeInstanceId?: number;
|
|
44
|
+
groupId?: number;
|
|
45
|
+
status?: number;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export interface Port {
|
|
49
|
+
sequence: number;
|
|
50
|
+
id: string;
|
|
51
|
+
description?: string;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export type OutPort = Port;
|
|
55
|
+
|
|
56
|
+
export type InPort = Port;
|
|
57
|
+
|
|
58
|
+
export interface Group {
|
|
59
|
+
isCollapsed: boolean;
|
|
60
|
+
experimentId: number;
|
|
61
|
+
name: string;
|
|
62
|
+
id: number;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export interface Link {
|
|
66
|
+
inputPortId: number;
|
|
67
|
+
outputPortId: number;
|
|
68
|
+
source: number;
|
|
69
|
+
type?: string;
|
|
70
|
+
target: number;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
// 执行状态
|
|
75
|
+
export namespace NExecutionStatus {
|
|
76
|
+
// 当前选中的组件
|
|
77
|
+
export interface ActiveNode {
|
|
78
|
+
type: 'legacy' | 'algo';
|
|
79
|
+
[k: string]: any;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export interface ExecDetail {
|
|
83
|
+
defName: string;
|
|
84
|
+
quickViewData: QuickViewData;
|
|
85
|
+
jobStatus: string;
|
|
86
|
+
percentage: number;
|
|
87
|
+
lastTime: number;
|
|
88
|
+
name: string;
|
|
89
|
+
startTime: string;
|
|
90
|
+
endTime: string;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
// 模型
|
|
95
|
+
export namespace NModel {
|
|
96
|
+
export interface Model {
|
|
97
|
+
codeName: string;
|
|
98
|
+
isNew: boolean;
|
|
99
|
+
catId: number;
|
|
100
|
+
parentId: number;
|
|
101
|
+
category: string;
|
|
102
|
+
owner: string;
|
|
103
|
+
name: string;
|
|
104
|
+
id: number;
|
|
105
|
+
type: string;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _x = require("@antv/x6");
|
|
4
|
+
|
|
5
|
+
_x.Graph.registerConnector('pai', function (s, t) {
|
|
6
|
+
var offset = 4;
|
|
7
|
+
var control = 80;
|
|
8
|
+
var v1 = {
|
|
9
|
+
x: s.x,
|
|
10
|
+
y: s.y + offset + control
|
|
11
|
+
};
|
|
12
|
+
var v2 = {
|
|
13
|
+
x: t.x,
|
|
14
|
+
y: t.y - offset - control
|
|
15
|
+
};
|
|
16
|
+
return "\n M ".concat(s.x, " ").concat(s.y, "\n L ").concat(s.x, " ").concat(s.y + offset, "\n C ").concat(v1.x, " ").concat(v1.y, " ").concat(v2.x, " ").concat(v2.y, " ").concat(t.x, " ").concat(t.y - offset, "\n L ").concat(t.x, " ").concat(t.y, "\n ");
|
|
17
|
+
}, true);
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = void 0;
|
|
9
|
+
|
|
10
|
+
var _x = require("@antv/x6");
|
|
11
|
+
|
|
12
|
+
require("./edge.less");
|
|
13
|
+
|
|
14
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
15
|
+
|
|
16
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
17
|
+
|
|
18
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
19
|
+
|
|
20
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
21
|
+
|
|
22
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
23
|
+
|
|
24
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
25
|
+
|
|
26
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
27
|
+
|
|
28
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
29
|
+
|
|
30
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
31
|
+
|
|
32
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
33
|
+
|
|
34
|
+
var BaseEdge = /*#__PURE__*/function (_Shape$Edge) {
|
|
35
|
+
_inherits(BaseEdge, _Shape$Edge);
|
|
36
|
+
|
|
37
|
+
var _super = _createSuper(BaseEdge);
|
|
38
|
+
|
|
39
|
+
function BaseEdge() {
|
|
40
|
+
_classCallCheck(this, BaseEdge);
|
|
41
|
+
|
|
42
|
+
return _super.apply(this, arguments);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
_createClass(BaseEdge, [{
|
|
46
|
+
key: "isGroupEdge",
|
|
47
|
+
value: function isGroupEdge() {
|
|
48
|
+
return false;
|
|
49
|
+
}
|
|
50
|
+
}]);
|
|
51
|
+
|
|
52
|
+
return BaseEdge;
|
|
53
|
+
}(_x.Shape.Edge);
|
|
54
|
+
|
|
55
|
+
exports.default = BaseEdge;
|
|
56
|
+
BaseEdge.config({
|
|
57
|
+
shape: 'GuideEdge',
|
|
58
|
+
// connector: { name: 'pai' },
|
|
59
|
+
zIndex: 2,
|
|
60
|
+
attrs: {
|
|
61
|
+
line: {
|
|
62
|
+
stroke: '#00A6FF',
|
|
63
|
+
strokeWidth: 1,
|
|
64
|
+
strokeDasharray: 5,
|
|
65
|
+
targetMarker: {
|
|
66
|
+
stroke: 'none',
|
|
67
|
+
fill: 'none'
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
|
|
73
|
+
_x.Graph.registerEdge('GuideEdge', BaseEdge);
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = void 0;
|
|
9
|
+
|
|
10
|
+
var _x6ReactShape = require("@antv/x6-react-shape");
|
|
11
|
+
|
|
12
|
+
require("./node-basic.less");
|
|
13
|
+
|
|
14
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
15
|
+
|
|
16
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
17
|
+
|
|
18
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
19
|
+
|
|
20
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
21
|
+
|
|
22
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
23
|
+
|
|
24
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
25
|
+
|
|
26
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
27
|
+
|
|
28
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
29
|
+
|
|
30
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
31
|
+
|
|
32
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
33
|
+
|
|
34
|
+
var BaseNode = /*#__PURE__*/function (_ReactShape) {
|
|
35
|
+
_inherits(BaseNode, _ReactShape);
|
|
36
|
+
|
|
37
|
+
var _super = _createSuper(BaseNode);
|
|
38
|
+
|
|
39
|
+
function BaseNode() {
|
|
40
|
+
var _this;
|
|
41
|
+
|
|
42
|
+
var metadata = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
43
|
+
|
|
44
|
+
_classCallCheck(this, BaseNode);
|
|
45
|
+
|
|
46
|
+
_this = _super.call(this, metadata);
|
|
47
|
+
|
|
48
|
+
_this.initPorts();
|
|
49
|
+
|
|
50
|
+
return _this;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
_createClass(BaseNode, [{
|
|
54
|
+
key: "isGroup",
|
|
55
|
+
value: function isGroup() {
|
|
56
|
+
return false;
|
|
57
|
+
}
|
|
58
|
+
}]);
|
|
59
|
+
|
|
60
|
+
return BaseNode;
|
|
61
|
+
}(_x6ReactShape.ReactShape);
|
|
62
|
+
|
|
63
|
+
exports.default = BaseNode;
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
@node-element-primary-color: #00A6FF;
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
.x6-node [magnet='true'] {
|
|
5
|
+
cursor: crosshair;
|
|
6
|
+
transition: none;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.x6-node [magnet='true']:hover {
|
|
10
|
+
opacity: 1;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.x6-node [magnet='true'][port-group='in'] {
|
|
14
|
+
cursor: move;
|
|
15
|
+
stroke: none;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.x6-port-body > span {
|
|
19
|
+
display: block;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.ais-port {
|
|
23
|
+
width: 100%;
|
|
24
|
+
height: 100%;
|
|
25
|
+
border: 1px solid #00A6FF;
|
|
26
|
+
border-radius: 100%;
|
|
27
|
+
background: #fff;
|
|
28
|
+
display: block;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.ais-port.connected {
|
|
32
|
+
width: 0;
|
|
33
|
+
height: 0;
|
|
34
|
+
margin-top: 3px;
|
|
35
|
+
margin-left: -1px;
|
|
36
|
+
border-width: 5px 4px 0;
|
|
37
|
+
border-style: solid;
|
|
38
|
+
border-color: #00A6FF transparent transparent;
|
|
39
|
+
border-radius: 0;
|
|
40
|
+
background-color: transparent;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.x6-port-body.available {
|
|
44
|
+
overflow: visible;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.x6-port-body.available body {
|
|
48
|
+
overflow: visible;
|
|
49
|
+
}
|
|
50
|
+
.x6-port-body.available span {
|
|
51
|
+
overflow: visible;
|
|
52
|
+
display: block;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.x6-port-body.available body > span::before {
|
|
56
|
+
content: ' ';
|
|
57
|
+
float: left;
|
|
58
|
+
width: 20px;
|
|
59
|
+
height: 20px;
|
|
60
|
+
margin-top: -6px;
|
|
61
|
+
margin-left: -6px;
|
|
62
|
+
border-radius: 50%;
|
|
63
|
+
background-color: fade(@node-element-primary-color, 60%);
|
|
64
|
+
box-sizing: border-box;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.x6-port-body.available body > span::after {
|
|
68
|
+
content: ' ';
|
|
69
|
+
float: left;
|
|
70
|
+
clear: both;
|
|
71
|
+
width: 10px;
|
|
72
|
+
height: 10px;
|
|
73
|
+
margin-top: -15px;
|
|
74
|
+
margin-left: -1px;
|
|
75
|
+
border-radius: 50%;
|
|
76
|
+
background-color: #fff;
|
|
77
|
+
border: 1px solid @node-element-primary-color;
|
|
78
|
+
// position: relative;
|
|
79
|
+
z-index: 10;
|
|
80
|
+
box-sizing: border-box;
|
|
81
|
+
// transform: translateZ(0);
|
|
82
|
+
// position: relative
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.x6-port-body.adsorbed {
|
|
86
|
+
overflow: visible;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.x6-port-body.adsorbed body {
|
|
90
|
+
overflow: visible;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.x6-port-body.adsorbed body > span::before {
|
|
94
|
+
content: ' ';
|
|
95
|
+
float: left;
|
|
96
|
+
width: 28px;
|
|
97
|
+
height: 28px;
|
|
98
|
+
margin-top: -9px;
|
|
99
|
+
margin-left: -10px;
|
|
100
|
+
border-radius: 50%;
|
|
101
|
+
background-color: fade(@node-element-primary-color, 60%);
|
|
102
|
+
box-sizing: border-box;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.x6-port-body.adsorbed body > span::after {
|
|
106
|
+
content: ' ';
|
|
107
|
+
float: left;
|
|
108
|
+
clear: both;
|
|
109
|
+
width: 10px;
|
|
110
|
+
height: 10px;
|
|
111
|
+
margin-top: -19px;
|
|
112
|
+
border-radius: 50%;
|
|
113
|
+
background-color: #fff;
|
|
114
|
+
border: 1px solid @node-element-primary-color;
|
|
115
|
+
// position: relative;
|
|
116
|
+
z-index: 10;
|
|
117
|
+
box-sizing: border-box;
|
|
118
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.useObservableState = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = require("react");
|
|
9
|
+
|
|
10
|
+
var _rxjs = require("rxjs");
|
|
11
|
+
|
|
12
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
13
|
+
|
|
14
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
15
|
+
|
|
16
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
17
|
+
|
|
18
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
19
|
+
|
|
20
|
+
function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
21
|
+
|
|
22
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
23
|
+
|
|
24
|
+
var useObservableState = function useObservableState(source$, initialState) {
|
|
25
|
+
var source = (0, _react.useMemo)(function () {
|
|
26
|
+
if (typeof source$ === 'function') {
|
|
27
|
+
return source$();
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
return source$;
|
|
31
|
+
}, [source$]);
|
|
32
|
+
|
|
33
|
+
var _useState = (0, _react.useState)(function () {
|
|
34
|
+
if (source instanceof _rxjs.BehaviorSubject) {
|
|
35
|
+
return source.getValue();
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
return initialState;
|
|
39
|
+
}),
|
|
40
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
41
|
+
state = _useState2[0],
|
|
42
|
+
setState = _useState2[1];
|
|
43
|
+
|
|
44
|
+
(0, _react.useEffect)(function () {
|
|
45
|
+
var sub = source.subscribe(function (v) {
|
|
46
|
+
setState(v);
|
|
47
|
+
});
|
|
48
|
+
return function () {
|
|
49
|
+
sub.unsubscribe();
|
|
50
|
+
};
|
|
51
|
+
}, [source]);
|
|
52
|
+
return [state, setState];
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
exports.useObservableState = useObservableState;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.withMode = withMode;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
|
+
|
|
12
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
13
|
+
|
|
14
|
+
function withMode(WrappedComponent, mode) {
|
|
15
|
+
var WithModeComponent = function WithModeComponent(props) {
|
|
16
|
+
return /*#__PURE__*/_react.default.createElement(WrappedComponent.type, props);
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
return /*#__PURE__*/_react.default.createElement(WithModeComponent, _extends({}, (WrappedComponent === null || WrappedComponent === void 0 ? void 0 : WrappedComponent.props) || {}, {
|
|
20
|
+
mode: mode
|
|
21
|
+
}));
|
|
22
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
.pos-btw{
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
justify-content: space-between;
|
|
5
|
+
}
|
|
6
|
+
.pos-end {
|
|
7
|
+
display: flex;
|
|
8
|
+
align-items: center;
|
|
9
|
+
justify-content: flex-end;
|
|
10
|
+
}
|
|
11
|
+
.pos-center{
|
|
12
|
+
display: flex;
|
|
13
|
+
align-items: center;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
}
|
|
16
|
+
.pos-line-center{
|
|
17
|
+
display: flex;
|
|
18
|
+
align-items: center;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.flex-1{
|
|
22
|
+
flex: 1;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const raw = "\n:root {\n --node-element-width: 180px;\n --node-element-height: 43px;\n --node-element-primary-color: #00A6FF;\n --node-element-primary-bg: rgba(0,166,255,.6);\n --node-element-primary-bg-light: rgba(0,166,255,.2);\n --condition-element-width: 260px;\n --condition-element-height: 107px;\n --name-max-width: 144px;\n --logical-bg-edg: 50px;\n --logical-edg: 30px;\n}\n\n.x6-graph-svg-viewport{\n transform: none !important;\n}\n\n.x6-node [magnet='true'][port-group='in'] {\n cursor: move;\n stroke: none;\n}\n\n.ais-port {\n display: none;\n}\n\n.node-rhombus-element{\n display: flex;\n flex-direction: row;\n box-sizing: border-box;\n width: var(--condition-element-width);\n height: var(--condition-element-height);\n overflow: hidden;\n}\n.node-rhombus-element .node-rhombus-element-bg {\n position: absolute;\n z-index: -1;\n}\n.node-rhombus-element .node-rhombus-element-bg div {\n width: var(--condition-element-width);\n height: var(--condition-element-height);\n}\n.node-rhombus-element .node-rhombus-element-bg div svg path {\n width: var(--condition-element-width);\n height: var(--condition-element-height);\n fill: var(--node-element-primary-bg-light);\n stroke: var(--node-element-primary-color)\n}\n.node-rhombus-element .rhombus-inner{\n display: flex;\n flex: 1;\n align-items: center;\n justify-content: center;\n}\n.node-rhombus-element .icon {\n width: 20px;\n height: 20px;\n margin-right: 12px;\n}\n.node-rhombus-element .icon svg {\n width: 20px;\n height: 20px;\n}\n.node-rhombus-element .icon svg path {\n fill: var(--node-element-primary-color);\n}\n.node-rhombus-element .name {\n overflow-x: hidden;\n color: var(--node-element-primary-color);\n white-space: nowrap;\n text-overflow: ellipsis;\n vertical-align: middle;\n max-width: var(--name-max-width);\n}\n\n.logical-element{\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n width: var(--logical-bg-edg);\n height: var(--logical-bg-edg);\n overflow: hidden;\n background-color: var(--node-element-primary-bg-light);\n border: 1px solid var(--node-element-primary-color);\n border-radius: 4px;\n}\n.logical-element .icon {\n width: var(--logical-edg);\n height: var(--logical-edg);\n}\n.logical-element .icon svg {\n width: var(--logical-edg);\n height: var(--logical-edg);\n}\n.logical-element .icon svg path {\n fill: var(--node-element-primary-color);\n}\n.logical-element .name {\n overflow-x: hidden;\n color: var(--node-element-primary-color);\n white-space: nowrap;\n text-overflow: ellipsis;\n vertical-align: middle;\n max-width: var(--name-max-width);\n}\n\n.node-element{\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n width: var(--node-element-width);\n height: var(--node-element-height);\n overflow: hidden;\n background-color: var(--node-element-primary-bg-light);\n border: 1px solid var(--node-element-primary-color);\n border-radius: 4px;\n}\n.node-element .icon {\n width: 20px;\n height: 20px;\n margin-right: 12px;\n}\n.node-element .icon svg {\n width: 20px;\n height: 20px;\n}\n.node-element .icon svg path {\n fill: var(--node-element-primary-color);\n}\n.node-element .name {\n overflow-x: hidden;\n color: var(--node-element-primary-color);\n white-space: nowrap;\n text-overflow: ellipsis;\n vertical-align: middle;\n max-width: var(--name-max-width);\n}\n\n.application-element{\n width: 420px;\n height: 320px;\n padding: 10px;\n background: #fff;\n}\n.application-element .icon{\n width: 400px;\n height: 300px;\n}\n.application-element .application-name{\n position: absolute;\n top: 0;\n left: 10px;\n font-size: 18px;\n}\n";
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.raw = void 0;
|
|
7
|
+
var raw = "\n:root {\n --node-element-width: 180px;\n --node-element-height: 43px;\n --node-element-primary-color: #00A6FF;\n --node-element-primary-bg: rgba(0,166,255,.6);\n --node-element-primary-bg-light: rgba(0,166,255,.2);\n --condition-element-width: 260px;\n --condition-element-height: 107px;\n --name-max-width: 144px;\n --logical-bg-edg: 50px;\n --logical-edg: 30px;\n}\n\n.x6-graph-svg-viewport{\n transform: none !important;\n}\n\n.x6-node [magnet='true'][port-group='in'] {\n cursor: move;\n stroke: none;\n}\n\n.ais-port {\n display: none;\n}\n\n.node-rhombus-element{\n display: flex;\n flex-direction: row;\n box-sizing: border-box;\n width: var(--condition-element-width);\n height: var(--condition-element-height);\n overflow: hidden;\n}\n.node-rhombus-element .node-rhombus-element-bg {\n position: absolute;\n z-index: -1;\n}\n.node-rhombus-element .node-rhombus-element-bg div {\n width: var(--condition-element-width);\n height: var(--condition-element-height);\n}\n.node-rhombus-element .node-rhombus-element-bg div svg path {\n width: var(--condition-element-width);\n height: var(--condition-element-height);\n fill: var(--node-element-primary-bg-light);\n stroke: var(--node-element-primary-color)\n}\n.node-rhombus-element .rhombus-inner{\n display: flex;\n flex: 1;\n align-items: center;\n justify-content: center;\n}\n.node-rhombus-element .icon {\n width: 20px;\n height: 20px;\n margin-right: 12px;\n}\n.node-rhombus-element .icon svg {\n width: 20px;\n height: 20px;\n}\n.node-rhombus-element .icon svg path {\n fill: var(--node-element-primary-color);\n}\n.node-rhombus-element .name {\n overflow-x: hidden;\n color: var(--node-element-primary-color);\n white-space: nowrap;\n text-overflow: ellipsis;\n vertical-align: middle;\n max-width: var(--name-max-width);\n}\n\n.logical-element{\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n width: var(--logical-bg-edg);\n height: var(--logical-bg-edg);\n overflow: hidden;\n background-color: var(--node-element-primary-bg-light);\n border: 1px solid var(--node-element-primary-color);\n border-radius: 4px;\n}\n.logical-element .icon {\n width: var(--logical-edg);\n height: var(--logical-edg);\n}\n.logical-element .icon svg {\n width: var(--logical-edg);\n height: var(--logical-edg);\n}\n.logical-element .icon svg path {\n fill: var(--node-element-primary-color);\n}\n.logical-element .name {\n overflow-x: hidden;\n color: var(--node-element-primary-color);\n white-space: nowrap;\n text-overflow: ellipsis;\n vertical-align: middle;\n max-width: var(--name-max-width);\n}\n\n.node-element{\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n width: var(--node-element-width);\n height: var(--node-element-height);\n overflow: hidden;\n background-color: var(--node-element-primary-bg-light);\n border: 1px solid var(--node-element-primary-color);\n border-radius: 4px;\n}\n.node-element .icon {\n width: 20px;\n height: 20px;\n margin-right: 12px;\n}\n.node-element .icon svg {\n width: 20px;\n height: 20px;\n}\n.node-element .icon svg path {\n fill: var(--node-element-primary-color);\n}\n.node-element .name {\n overflow-x: hidden;\n color: var(--node-element-primary-color);\n white-space: nowrap;\n text-overflow: ellipsis;\n vertical-align: middle;\n max-width: var(--name-max-width);\n}\n\n.application-element{\n width: 420px;\n height: 320px;\n padding: 10px;\n background: #fff;\n}\n.application-element .icon{\n width: 400px;\n height: 300px;\n}\n.application-element .application-name{\n position: absolute;\n top: 0;\n left: 10px;\n font-size: 18px;\n}\n";
|
|
8
|
+
exports.raw = raw;
|
package/lib/typings.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { unescape } from 'lodash-es';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
Object.defineProperty(exports, "unescape", {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: function get() {
|
|
9
|
+
return _lodashEs.unescape;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
|
|
13
|
+
var _lodashEs = require("lodash-es");
|