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.
Files changed (341) hide show
  1. package/.fatherrc.ts +11 -26
  2. package/.umirc.ts +4 -0
  3. package/README.md +33 -33
  4. package/es/assets/decive.svg +1 -1
  5. package/es/assets/hand.svg +1 -1
  6. package/es/assets/lock.svg +8 -0
  7. package/es/components/canvas/component-tree-panel/category-tree/category-type.d.ts +1 -0
  8. package/es/{common/graph-common → components/canvas/component-tree-panel/category-tree}/category-type.js +28 -12
  9. package/es/{pages → components/canvas}/component-tree-panel/category-tree/index.d.ts +17 -16
  10. package/es/{pages → components/canvas}/component-tree-panel/category-tree/index.js +14 -14
  11. package/es/{pages → components/canvas}/component-tree-panel/category-tree/index.less +36 -36
  12. package/es/{pages → components/canvas}/component-tree-panel/category-tree/node-title.d.ts +12 -12
  13. package/es/{pages → components/canvas}/component-tree-panel/category-tree/node-title.js +5 -3
  14. package/es/{pages → components/canvas}/component-tree-panel/index.d.ts +17 -17
  15. package/es/{pages → components/canvas}/component-tree-panel/index.js +1 -0
  16. package/es/{pages → components/canvas}/component-tree-panel/index.less +1 -0
  17. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/data-origin.d.ts +49 -49
  18. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/data-origin.js +26 -34
  19. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/index.d.ts +11 -11
  20. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/index.js +15 -23
  21. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/configure-modal/style.less +1 -1
  22. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/cross-line.d.ts +9 -9
  23. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/cross-line.js +6 -10
  24. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/index.d.ts +10 -9
  25. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/index.js +17 -13
  26. package/es/{pages → components/canvas}/config-panel/components/condition-configuration/style.less +74 -74
  27. package/es/{pages → components/canvas}/config-panel/components/time-trigger/components/cycle-time.d.ts +9 -9
  28. package/es/{pages → components/canvas}/config-panel/components/time-trigger/components/cycle-time.js +24 -33
  29. package/es/{pages → components/canvas}/config-panel/components/time-trigger/components/time-horizon.d.ts +10 -10
  30. package/es/{pages → components/canvas}/config-panel/components/time-trigger/components/time-horizon.js +18 -28
  31. package/es/{pages → components/canvas}/config-panel/components/time-trigger/delay-time.d.ts +9 -9
  32. package/es/components/canvas/config-panel/components/time-trigger/effective-time.d.ts +7 -0
  33. package/es/components/canvas/config-panel/components/time-trigger/effective-time.js +43 -0
  34. package/es/{pages → components/canvas}/config-panel/components/time-trigger/index.d.ts +9 -8
  35. package/es/{pages → components/canvas}/config-panel/components/time-trigger/index.js +18 -17
  36. package/es/{pages → components/canvas}/config-panel/components/time-trigger/interval-time.d.ts +9 -9
  37. package/es/{pages → components/canvas}/config-panel/components/time-trigger/interval-time.js +4 -8
  38. package/es/{pages → components/canvas}/config-panel/components/time-trigger/persistent-time.d.ts +9 -9
  39. package/es/components/canvas/config-panel/components/time-trigger/section-Detail.d.ts +10 -0
  40. package/es/components/canvas/config-panel/components/time-trigger/section-Detail.js +125 -0
  41. package/es/components/canvas/config-panel/components/time-trigger/section-time.d.ts +9 -0
  42. package/es/components/canvas/config-panel/components/time-trigger/section-time.js +81 -0
  43. package/es/{pages → components/canvas}/config-panel/components/time-trigger/timing-time.d.ts +9 -9
  44. package/es/{pages → components/canvas}/config-panel/components/time-trigger/timing-time.js +7 -11
  45. package/es/{pages → components/canvas}/config-panel/config-common.d.ts +38 -37
  46. package/es/{pages → components/canvas}/config-panel/config-common.js +9 -15
  47. package/es/{pages → components/canvas}/config-panel/index.d.ts +14 -13
  48. package/es/{pages → components/canvas}/config-panel/index.js +2 -2
  49. package/es/{pages → components/canvas}/config-panel/node-form.d.ts +23 -22
  50. package/es/{pages → components/canvas}/config-panel/node-form.js +14 -16
  51. package/es/{pages → components/canvas}/config-panel/style.less +90 -81
  52. package/es/{pages → components/canvas}/dag-canvas/canvas-content.d.ts +11 -10
  53. package/es/{pages → components/canvas}/dag-canvas/canvas-content.js +23 -12
  54. package/es/{pages → components/canvas}/dag-canvas/index.d.ts +23 -18
  55. package/es/{pages → components/canvas}/dag-canvas/index.js +5 -2
  56. package/es/{pages → components/canvas}/dag-canvas/preview.d.ts +10 -10
  57. package/es/components/canvas/dag-canvas/preview.js +53 -0
  58. package/es/{pages → components/canvas}/index.d.ts +48 -42
  59. package/es/{pages → components/canvas}/index.js +20 -10
  60. package/es/{pages → components/canvas}/index.less +2 -2
  61. package/es/{pages → components/canvas}/strategy-header/index.d.ts +48 -56
  62. package/es/components/canvas/strategy-header/index.js +210 -0
  63. package/es/{pages → components/canvas}/strategy-header/style.less +4 -3
  64. package/es/{pages → components/canvas}/strategy-header/theme-switch/index.d.ts +4 -4
  65. package/es/{pages → components/canvas}/strategy-header/theme-switch/index.js +2 -3
  66. package/es/index.d.ts +9 -8
  67. package/es/index.js +8 -7
  68. package/es/packages/graph-canvas/graph-common.d.ts +19 -0
  69. package/es/packages/graph-canvas/graph-common.js +19 -0
  70. package/es/packages/graph-canvas/graph-model/edge/group-edge/index.d.ts +4 -0
  71. package/es/packages/graph-canvas/graph-model/edge/group-edge/index.js +63 -0
  72. package/es/packages/graph-canvas/graph-model/edge/index.d.ts +2 -0
  73. package/es/packages/graph-canvas/graph-model/edge/index.js +2 -0
  74. package/es/packages/graph-canvas/graph-model/node/application-node/application-element.d.ts +9 -0
  75. package/es/packages/graph-canvas/graph-model/node/application-node/application-element.js +20 -0
  76. package/es/packages/graph-canvas/graph-model/node/application-node/application-element.less +17 -0
  77. package/es/packages/graph-canvas/graph-model/node/application-node/index.d.ts +7 -0
  78. package/es/{common/graph-common/shape/nodes/GroupNode.js → packages/graph-canvas/graph-model/node/application-node/index.js} +42 -22
  79. package/es/{common/graph-common/shape/nodes/CommonNode.d.ts → packages/graph-canvas/graph-model/node/common-node/index.d.ts} +7 -5
  80. package/es/{common/graph-common/shape/nodes/CommonNode.js → packages/graph-canvas/graph-model/node/common-node/index.js} +8 -7
  81. package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/common-node}/node-element.d.ts +9 -9
  82. package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/common-node}/node-element.js +16 -14
  83. package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/common-node}/node-element.less +4 -4
  84. package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/condition-node}/condition-element.d.ts +9 -9
  85. package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/condition-node}/condition-element.js +20 -15
  86. package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/condition-node}/condition-element.less +76 -81
  87. package/es/packages/graph-canvas/graph-model/node/condition-node/images/rhombus.svg +3 -0
  88. package/es/{common/graph-common/shape/nodes/ConditionJudgment.d.ts → packages/graph-canvas/graph-model/node/condition-node/index.d.ts} +5 -5
  89. package/es/{common/graph-common/shape/nodes/ConditionJudgment.js → packages/graph-canvas/graph-model/node/condition-node/index.js} +7 -6
  90. package/es/packages/graph-canvas/graph-model/node/index.d.ts +5 -0
  91. package/es/packages/graph-canvas/graph-model/node/index.js +5 -0
  92. package/es/packages/graph-canvas/graph-model/node/logical-node/images/AND.svg +11 -0
  93. package/es/packages/graph-canvas/graph-model/node/logical-node/images/OR.svg +11 -0
  94. package/es/packages/graph-canvas/graph-model/node/logical-node/images/XOR.svg +11 -0
  95. package/es/packages/graph-canvas/graph-model/node/logical-node/images/locking.svg +5 -0
  96. package/es/packages/graph-canvas/graph-model/node/logical-node/images/unlock.svg +5 -0
  97. package/es/packages/graph-canvas/graph-model/node/logical-node/index.d.ts +6 -0
  98. package/es/{common/graph-common/shape/nodes/LogicalNode.js → packages/graph-canvas/graph-model/node/logical-node/index.js} +15 -15
  99. package/es/packages/graph-canvas/graph-model/node/logical-node/logical-element.d.ts +9 -0
  100. package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/logical-node}/logical-element.js +36 -19
  101. package/es/{common/graph-common/node-element → packages/graph-canvas/graph-model/node/logical-node}/logical-element.less +4 -9
  102. package/es/packages/graph-canvas/graph-model/node/style.less +8 -0
  103. package/es/{common → packages/graph-canvas}/graph-utils/graph.d.ts +87 -83
  104. package/es/{common → packages/graph-canvas}/graph-utils/graph.js +8 -4
  105. package/es/{pages/rx-models/experiment-graph.d.ts → packages/graph-canvas/index.d.ts} +79 -82
  106. package/es/{pages/rx-models/experiment-graph.js → packages/graph-canvas/index.js} +285 -252
  107. package/es/packages/graph-canvas/node-types.d.ts +6 -0
  108. package/es/packages/graph-canvas/node-types.js +54 -0
  109. package/es/packages/graph-canvas/typings.d.ts +5 -0
  110. package/es/{common/constants → packages/graph-common}/global.d.ts +1 -1
  111. package/es/{common/constants → packages/graph-common}/graph.d.ts +12 -10
  112. package/es/{common/constants → packages/graph-common}/graph.js +4 -2
  113. package/es/{pages/rx-models → packages/graph-core}/graph-util.d.ts +182 -186
  114. package/es/{pages/rx-models → packages/graph-core}/graph-util.js +8 -15
  115. package/es/{pages/rx-models/graph-core.d.ts → packages/graph-core/index.d.ts} +96 -96
  116. package/es/{pages/rx-models/graph-core.js → packages/graph-core/index.js} +119 -87
  117. package/es/packages/graph-core/typing.d.ts +107 -0
  118. package/es/{common/graph-common → packages/graph-model}/connector/index.d.ts +1 -1
  119. package/es/packages/graph-model/connector/index.js +14 -0
  120. package/es/packages/graph-model/edge/edge.less +8 -0
  121. package/es/packages/graph-model/edge/index.d.ts +5 -0
  122. package/es/{common/graph-common/shape/edge.js → packages/graph-model/edge/index.js} +10 -61
  123. package/es/packages/graph-model/node/index.d.ts +7 -0
  124. package/es/{common/graph-common/shape/nodes/BaseNode.js → packages/graph-model/node/index.js} +12 -3
  125. package/es/{common/graph-common/node-element/common-element.less → packages/graph-model/node/node-basic.less} +1 -0
  126. package/es/{hooks → packages/hooks}/useObservableState.d.ts +3 -3
  127. package/es/packages/hooks/withMode.d.ts +3 -0
  128. package/es/packages/hooks/withMode.js +12 -0
  129. package/es/style/default.less +8 -0
  130. package/es/style/svgRaw.d.ts +1 -0
  131. package/es/style/svgRaw.js +1 -0
  132. package/es/typings.d.ts +2 -8
  133. package/es/utils/utils.d.ts +1 -1
  134. package/lib/assets/AND.svg +11 -0
  135. package/lib/assets/OR.svg +11 -0
  136. package/lib/assets/XOR.svg +11 -0
  137. package/lib/assets/add.svg +13 -0
  138. package/lib/assets/alarm.svg +11 -0
  139. package/lib/assets/application.svg +11 -0
  140. package/lib/assets/cancel.svg +13 -0
  141. package/lib/assets/check.svg +12 -0
  142. package/lib/assets/condition.svg +12 -0
  143. package/lib/assets/control.svg +11 -0
  144. package/lib/assets/decive.svg +11 -0
  145. package/lib/assets/delete.svg +11 -0
  146. package/lib/assets/device.svg +11 -0
  147. package/lib/assets/edit.svg +11 -0
  148. package/lib/assets/hand.svg +11 -0
  149. package/lib/assets/link.svg +11 -0
  150. package/lib/assets/lock.svg +8 -0
  151. package/lib/assets/logical.svg +12 -0
  152. package/lib/assets/notice.svg +11 -0
  153. package/lib/assets/order.svg +11 -0
  154. package/lib/assets/relation.svg +11 -0
  155. package/lib/assets/rhombus.svg +3 -0
  156. package/lib/assets/save.svg +13 -0
  157. package/lib/assets/time.svg +11 -0
  158. package/lib/assets/variate.svg +12 -0
  159. package/lib/components/canvas/component-tree-panel/category-tree/category-type.d.ts +1 -0
  160. package/lib/components/canvas/component-tree-panel/category-tree/category-type.js +111 -0
  161. package/lib/components/canvas/component-tree-panel/category-tree/index.d.ts +17 -0
  162. package/lib/components/canvas/component-tree-panel/category-tree/index.js +115 -0
  163. package/lib/components/canvas/component-tree-panel/category-tree/index.less +36 -0
  164. package/lib/components/canvas/component-tree-panel/category-tree/node-title.d.ts +12 -0
  165. package/lib/components/canvas/component-tree-panel/category-tree/node-title.js +75 -0
  166. package/lib/components/canvas/component-tree-panel/category-tree/node-title.less +113 -0
  167. package/lib/components/canvas/component-tree-panel/index.d.ts +17 -0
  168. package/lib/components/canvas/component-tree-panel/index.js +33 -0
  169. package/lib/components/canvas/component-tree-panel/index.less +52 -0
  170. package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/data-origin.d.ts +49 -0
  171. package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/data-origin.js +229 -0
  172. package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/index.d.ts +11 -0
  173. package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/index.js +187 -0
  174. package/lib/components/canvas/config-panel/components/condition-configuration/configure-modal/style.less +13 -0
  175. package/lib/components/canvas/config-panel/components/condition-configuration/cross-line.d.ts +9 -0
  176. package/lib/components/canvas/config-panel/components/condition-configuration/cross-line.js +57 -0
  177. package/lib/components/canvas/config-panel/components/condition-configuration/index.d.ts +10 -0
  178. package/lib/components/canvas/config-panel/components/condition-configuration/index.js +216 -0
  179. package/lib/components/canvas/config-panel/components/condition-configuration/style.less +74 -0
  180. package/lib/components/canvas/config-panel/components/time-trigger/components/cycle-time.d.ts +9 -0
  181. package/lib/components/canvas/config-panel/components/time-trigger/components/cycle-time.js +108 -0
  182. package/lib/components/canvas/config-panel/components/time-trigger/components/time-horizon.d.ts +10 -0
  183. package/lib/components/canvas/config-panel/components/time-trigger/components/time-horizon.js +78 -0
  184. package/lib/components/canvas/config-panel/components/time-trigger/delay-time.d.ts +9 -0
  185. package/lib/components/canvas/config-panel/components/time-trigger/delay-time.js +33 -0
  186. package/lib/components/canvas/config-panel/components/time-trigger/effective-time.d.ts +7 -0
  187. package/lib/components/canvas/config-panel/components/time-trigger/effective-time.js +58 -0
  188. package/lib/components/canvas/config-panel/components/time-trigger/index.d.ts +9 -0
  189. package/lib/components/canvas/config-panel/components/time-trigger/index.js +114 -0
  190. package/lib/components/canvas/config-panel/components/time-trigger/interval-time.d.ts +9 -0
  191. package/lib/components/canvas/config-panel/components/time-trigger/interval-time.js +63 -0
  192. package/lib/components/canvas/config-panel/components/time-trigger/persistent-time.d.ts +9 -0
  193. package/lib/components/canvas/config-panel/components/time-trigger/persistent-time.js +33 -0
  194. package/lib/components/canvas/config-panel/components/time-trigger/section-Detail.d.ts +10 -0
  195. package/lib/components/canvas/config-panel/components/time-trigger/section-Detail.js +140 -0
  196. package/lib/components/canvas/config-panel/components/time-trigger/section-time.d.ts +9 -0
  197. package/lib/components/canvas/config-panel/components/time-trigger/section-time.js +96 -0
  198. package/lib/components/canvas/config-panel/components/time-trigger/timing-time.d.ts +9 -0
  199. package/lib/components/canvas/config-panel/components/time-trigger/timing-time.js +65 -0
  200. package/lib/components/canvas/config-panel/config-common.d.ts +38 -0
  201. package/lib/components/canvas/config-panel/config-common.js +152 -0
  202. package/lib/components/canvas/config-panel/index.d.ts +14 -0
  203. package/lib/components/canvas/config-panel/index.js +68 -0
  204. package/lib/components/canvas/config-panel/node-form.d.ts +23 -0
  205. package/lib/components/canvas/config-panel/node-form.js +97 -0
  206. package/lib/components/canvas/config-panel/style.less +90 -0
  207. package/lib/components/canvas/dag-canvas/canvas-content.d.ts +11 -0
  208. package/lib/components/canvas/dag-canvas/canvas-content.js +130 -0
  209. package/lib/components/canvas/dag-canvas/canvas-content.less +5 -0
  210. package/lib/components/canvas/dag-canvas/index.d.ts +23 -0
  211. package/lib/components/canvas/dag-canvas/index.js +53 -0
  212. package/lib/components/canvas/dag-canvas/index.less +11 -0
  213. package/lib/components/canvas/dag-canvas/preview.d.ts +10 -0
  214. package/lib/components/canvas/dag-canvas/preview.js +73 -0
  215. package/lib/components/canvas/index.d.ts +48 -0
  216. package/lib/components/canvas/index.js +107 -0
  217. package/lib/components/canvas/index.less +50 -0
  218. package/lib/components/canvas/strategy-header/index.d.ts +48 -0
  219. package/lib/components/canvas/strategy-header/index.js +229 -0
  220. package/lib/components/canvas/strategy-header/style.less +23 -0
  221. package/lib/components/canvas/strategy-header/theme-switch/index.d.ts +4 -0
  222. package/lib/components/canvas/strategy-header/theme-switch/index.js +30 -0
  223. package/lib/components/canvas/strategy-header/theme-switch/style.less +11 -0
  224. package/lib/index.d.ts +9 -0
  225. package/lib/index.js +71 -0
  226. package/lib/packages/graph-canvas/graph-common.d.ts +19 -0
  227. package/lib/packages/graph-canvas/graph-common.js +27 -0
  228. package/lib/packages/graph-canvas/graph-model/edge/group-edge/edge.less +8 -0
  229. package/lib/packages/graph-canvas/graph-model/edge/group-edge/index.d.ts +4 -0
  230. package/lib/packages/graph-canvas/graph-model/edge/group-edge/index.js +74 -0
  231. package/lib/packages/graph-canvas/graph-model/edge/index.d.ts +2 -0
  232. package/lib/packages/graph-canvas/graph-model/edge/index.js +15 -0
  233. package/lib/packages/graph-canvas/graph-model/node/application-node/application-element.d.ts +9 -0
  234. package/lib/packages/graph-canvas/graph-model/node/application-node/application-element.js +31 -0
  235. package/lib/packages/graph-canvas/graph-model/node/application-node/application-element.less +17 -0
  236. package/lib/packages/graph-canvas/graph-model/node/application-node/index.d.ts +7 -0
  237. package/lib/packages/graph-canvas/graph-model/node/application-node/index.js +133 -0
  238. package/lib/packages/graph-canvas/graph-model/node/common-node/index.d.ts +7 -0
  239. package/lib/packages/graph-canvas/graph-model/node/common-node/index.js +133 -0
  240. package/lib/packages/graph-canvas/graph-model/node/common-node/node-element.d.ts +9 -0
  241. package/lib/packages/graph-canvas/graph-model/node/common-node/node-element.js +69 -0
  242. package/lib/packages/graph-canvas/graph-model/node/common-node/node-element.less +48 -0
  243. 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
  244. package/lib/packages/graph-canvas/graph-model/node/condition-node/condition-element.js +81 -0
  245. package/lib/packages/graph-canvas/graph-model/node/condition-node/condition-element.less +76 -0
  246. package/lib/packages/graph-canvas/graph-model/node/condition-node/images/rhombus.svg +3 -0
  247. package/{es/common/graph-common/shape/nodes/LogicalNode.d.ts → lib/packages/graph-canvas/graph-model/node/condition-node/index.d.ts} +5 -5
  248. package/lib/packages/graph-canvas/graph-model/node/condition-node/index.js +143 -0
  249. package/lib/packages/graph-canvas/graph-model/node/index.d.ts +5 -0
  250. package/lib/packages/graph-canvas/graph-model/node/index.js +39 -0
  251. package/lib/packages/graph-canvas/graph-model/node/logical-node/images/AND.svg +11 -0
  252. package/lib/packages/graph-canvas/graph-model/node/logical-node/images/OR.svg +11 -0
  253. package/lib/packages/graph-canvas/graph-model/node/logical-node/images/XOR.svg +11 -0
  254. package/lib/packages/graph-canvas/graph-model/node/logical-node/images/locking.svg +5 -0
  255. package/lib/packages/graph-canvas/graph-model/node/logical-node/images/unlock.svg +5 -0
  256. package/lib/packages/graph-canvas/graph-model/node/logical-node/index.d.ts +6 -0
  257. package/lib/packages/graph-canvas/graph-model/node/logical-node/index.js +143 -0
  258. package/lib/packages/graph-canvas/graph-model/node/logical-node/logical-element.d.ts +9 -0
  259. package/lib/packages/graph-canvas/graph-model/node/logical-node/logical-element.js +98 -0
  260. package/lib/packages/graph-canvas/graph-model/node/logical-node/logical-element.less +49 -0
  261. package/lib/packages/graph-canvas/graph-model/node/style.less +8 -0
  262. package/lib/packages/graph-canvas/graph-utils/graph.d.ts +87 -0
  263. package/lib/packages/graph-canvas/graph-utils/graph.js +124 -0
  264. package/lib/packages/graph-canvas/index.d.ts +79 -0
  265. package/lib/packages/graph-canvas/index.js +1292 -0
  266. package/lib/packages/graph-canvas/node-types.d.ts +6 -0
  267. package/lib/packages/graph-canvas/node-types.js +66 -0
  268. package/lib/packages/graph-canvas/typings.d.ts +5 -0
  269. package/lib/packages/graph-common/global.d.ts +1 -0
  270. package/lib/packages/graph-common/global.js +8 -0
  271. package/lib/packages/graph-common/graph.d.ts +12 -0
  272. package/lib/packages/graph-common/graph.js +37 -0
  273. package/lib/packages/graph-core/graph-util.d.ts +182 -0
  274. package/lib/packages/graph-core/graph-util.js +368 -0
  275. package/lib/packages/graph-core/index.d.ts +96 -0
  276. package/lib/packages/graph-core/index.js +798 -0
  277. package/lib/packages/graph-core/typing.d.ts +107 -0
  278. package/lib/packages/graph-model/connector/index.d.ts +1 -0
  279. package/lib/packages/graph-model/connector/index.js +17 -0
  280. package/lib/packages/graph-model/edge/edge.less +8 -0
  281. package/lib/packages/graph-model/edge/index.d.ts +5 -0
  282. package/lib/packages/graph-model/edge/index.js +73 -0
  283. package/lib/packages/graph-model/node/index.d.ts +7 -0
  284. package/lib/packages/graph-model/node/index.js +63 -0
  285. package/lib/packages/graph-model/node/node-basic.less +118 -0
  286. package/lib/packages/hooks/useObservableState.d.ts +3 -0
  287. package/lib/packages/hooks/useObservableState.js +55 -0
  288. package/lib/packages/hooks/withMode.d.ts +3 -0
  289. package/lib/packages/hooks/withMode.js +22 -0
  290. package/lib/style/basic.less +12 -0
  291. package/lib/style/default.less +10 -0
  292. package/lib/style/position.less +25 -0
  293. package/lib/style/svgRaw.d.ts +1 -0
  294. package/lib/style/svgRaw.js +8 -0
  295. package/lib/style/theme-light.less +7 -0
  296. package/lib/style/variable.less +3 -0
  297. package/lib/typings.d.ts +8 -0
  298. package/lib/utils/utils.d.ts +1 -0
  299. package/lib/utils/utils.js +13 -0
  300. package/package.json +38 -37
  301. package/tsconfig.json +1 -1
  302. package/es/common/graph-common/category-type.d.ts +0 -16
  303. package/es/common/graph-common/connector/index.js +0 -14
  304. package/es/common/graph-common/node-element/node-group.d.ts +0 -8
  305. package/es/common/graph-common/node-element/node-group.js +0 -395
  306. package/es/common/graph-common/node-element/node-group.less +0 -53
  307. package/es/common/graph-common/node-popover/index.d.ts +0 -7
  308. package/es/common/graph-common/node-popover/index.js +0 -11
  309. package/es/common/graph-common/node-popover/index.less +0 -5
  310. package/es/common/graph-common/node-types.d.ts +0 -28
  311. package/es/common/graph-common/node-types.js +0 -60
  312. package/es/common/graph-common/shape/edge.d.ts +0 -10
  313. package/es/common/graph-common/shape/node.d.ts +0 -6
  314. package/es/common/graph-common/shape/node.js +0 -6
  315. package/es/common/graph-common/shape/nodes/BaseNode.d.ts +0 -4
  316. package/es/common/graph-common/shape/nodes/GroupNode.d.ts +0 -4
  317. package/es/component/cut.d.ts +0 -10
  318. package/es/component/cut.js +0 -34
  319. package/es/component/cut.less +0 -6
  320. package/es/component/item-name.d.ts +0 -6
  321. package/es/component/item-name.js +0 -30
  322. package/es/component/keyword.d.ts +0 -9
  323. package/es/component/keyword.js +0 -26
  324. package/es/component/keyword.less +0 -11
  325. package/es/component/rx-component/rx-input.d.ts +0 -8
  326. package/es/component/rx-component/rx-input.js +0 -47
  327. package/es/hooks/withMode.d.ts +0 -1
  328. package/es/hooks/withMode.js +0 -16
  329. package/es/pages/dag-canvas/preview.js +0 -42
  330. package/es/pages/rx-models/graph-core.less +0 -14
  331. package/es/pages/rx-models/typing.d.ts +0 -126
  332. package/es/pages/strategy-header/index.js +0 -154
  333. /package/es/{pages → components/canvas}/component-tree-panel/category-tree/node-title.less +0 -0
  334. /package/es/{pages → components/canvas}/config-panel/components/time-trigger/delay-time.js +0 -0
  335. /package/es/{pages → components/canvas}/config-panel/components/time-trigger/persistent-time.js +0 -0
  336. /package/es/{pages → components/canvas}/dag-canvas/canvas-content.less +0 -0
  337. /package/es/{pages → components/canvas}/dag-canvas/index.less +0 -0
  338. /package/es/{pages → components/canvas}/strategy-header/theme-switch/style.less +0 -0
  339. /package/es/{common/graph-common/shape → packages/graph-canvas/graph-model/edge/group-edge}/edge.less +0 -0
  340. /package/es/{common/constants → packages/graph-common}/global.js +0 -0
  341. /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,8 @@
1
+ .x6-edge {
2
+ &-selected,
3
+ &:hover {
4
+ path[stroke-width='1'] {
5
+ stroke-width: 3px;
6
+ }
7
+ }
8
+ }
@@ -0,0 +1,5 @@
1
+ import { Shape } from '@antv/x6';
2
+ import './edge.less';
3
+ export default class BaseEdge extends Shape.Edge {
4
+ isGroupEdge(): boolean;
5
+ }
@@ -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,7 @@
1
+ import { ReactShape } from '@antv/x6-react-shape';
2
+ import type { Node } from '@antv/x6/src/model/node';
3
+ import './node-basic.less';
4
+ export default class BaseNode extends ReactShape {
5
+ constructor(metadata?: Node.Metadata);
6
+ isGroup(): boolean;
7
+ }
@@ -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,3 @@
1
+ import type React from 'react';
2
+ import type { Observable } from 'rxjs';
3
+ export declare const useObservableState: <T extends unknown>(source$: Observable<T> | (() => Observable<T>), initialState?: T | undefined) => [T, React.Dispatch<React.SetStateAction<T>>];
@@ -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,3 @@
1
+ declare type ModeType = 'platform' | 'view';
2
+ export declare function withMode(WrappedComponent: any, mode: ModeType): JSX.Element;
3
+ export {};
@@ -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,12 @@
1
+ .mr-5{
2
+ margin-right: 5px;
3
+ }
4
+ .mr-10{
5
+ margin-right: 10px;
6
+ }
7
+ .mr-15{
8
+ margin-right: 15px;
9
+ }
10
+ .mb-10{
11
+ margin-bottom: 10px;
12
+ }
@@ -0,0 +1,10 @@
1
+ @import "basic.less";
2
+ @import "position.less";
3
+
4
+
5
+ .safari-disabled{
6
+ width: fit-content;
7
+ margin: 100px auto;
8
+ font-size: 22px;
9
+ font-weight: 600;
10
+ }
@@ -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;
@@ -0,0 +1,7 @@
1
+ @import "./variable.less";
2
+
3
+ @light-gray-bg: #F1F2F3;
4
+ @light-gray-text-color: #323232;
5
+
6
+
7
+ @info-color: ~'var(--@light-gray-bg)';
@@ -0,0 +1,3 @@
1
+ html {
2
+
3
+ }
@@ -0,0 +1,8 @@
1
+ declare module '*.css';
2
+ declare module '*.less';
3
+ declare module '*.json';
4
+ declare module '*.svg';
5
+
6
+ type Window = {
7
+ requestIdleCallback: (callback: () => void) => void;
8
+ };
@@ -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");