@riil-frontend/component-topology 11.0.29 → 11.0.30

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 (943) hide show
  1. package/build/1.js +2 -2
  2. package/build/2.js +1 -1
  3. package/build/index.css +4 -2
  4. package/build/index.js +50 -35
  5. package/es/common/components/ColorPicker/ColorPicker.js +18 -9
  6. package/es/common/components/ResourceTable/ResourceTable.js +9 -6
  7. package/es/common/plugins/useSelectionPlugin.js +23 -14
  8. package/es/components/BatchAttrMetric/constant.js +2 -2
  9. package/es/components/BatchAttrMetric/index.js +17 -10
  10. package/es/components/BatchAttrMetric/setting.js +52 -30
  11. package/es/components/BatchAttrMetric/utils.js +4 -2
  12. package/es/components/BooleanRadio.js +7 -5
  13. package/es/components/ColorPanel/components/ColorBlock/index.js +4 -3
  14. package/es/components/ColorPanel/components/FontColorRange/index.js +13 -9
  15. package/es/components/ColorPanel/index.js +40 -18
  16. package/es/components/Drawer/Drawer.js +18 -14
  17. package/es/components/FormTable/index.js +18 -13
  18. package/es/components/FullheightTab/FullheightTab.js +2 -0
  19. package/es/components/LayoutDirectionSelect/LayoutDirectionSelect.js +3 -6
  20. package/es/components/LayoutSelect/LayoutSelect.js +3 -6
  21. package/es/components/ModelAttrSelectDrawer/components/ModelAttrSelectDrawer.js +4 -4
  22. package/es/components/ModelAttrSelectDrawer/components/MultipleTypeAttributeSelectDrawer.js +20 -15
  23. package/es/components/MultiResourceDrawer/Content.js +22 -12
  24. package/es/components/MultiResourceDrawer/Dynamic.js +4 -2
  25. package/es/components/MultiResourceDrawer/ResourceCard/index.js +6 -4
  26. package/es/components/MultiResourceDrawer/ResourceSelect.js +4 -2
  27. package/es/components/MultiResourceDrawer/Static.js +4 -2
  28. package/es/components/MultiResourceDrawer/index.js +16 -8
  29. package/es/components/ResourceList/ResourceSelect.js +44 -27
  30. package/es/components/ResourceList/ResourceSelectConnect.js +7 -3
  31. package/es/components/ResourceSelect/ResourceSelectDrawer.js +11 -7
  32. package/es/components/ResourceSelectDrawer/ResourceSelectDrawer.js +27 -14
  33. package/es/components/ResourceSelectDrawer/ResourceSelectList.js +8 -4
  34. package/es/components/SingleResourceDrawer/SelectDrawer.js +15 -6
  35. package/es/components/SingleResourceDrawer/SingleResourceDrawer.js +14 -7
  36. package/es/components/TagImageSelect/index.js +11 -8
  37. package/es/components/TagSelect/index.js +12 -8
  38. package/es/components/TemplateButton/Icon.js +7 -5
  39. package/es/components/TemplateButton/index.js +9 -6
  40. package/es/components/VerticalIconTab/VerticalIconTab.js +11 -7
  41. package/es/components/collapse/Collapse.js +8 -4
  42. package/es/components/collapse/Panel.js +17 -7
  43. package/es/constants/ResourceInfoDisplay.js +6 -6
  44. package/es/constants/ResourceTypeLimit.js +11 -20
  45. package/es/contextmenu/createMenuCommands.js +8 -7
  46. package/es/core/common/contextmenu/mergeContextmenu.js +2 -2
  47. package/es/core/common/hooks/ht/useDataModelDataPropertyChange.js +2 -0
  48. package/es/core/common/hooks/useHtElement.js +2 -1
  49. package/es/core/common/hooks/useHtElements.js +6 -5
  50. package/es/core/common/icons/icon.js +18 -17
  51. package/es/core/common/icons/useIcons.js +4 -1
  52. package/es/core/components/AlarmListPanel/components/AlarmListItem.js +13 -4
  53. package/es/core/components/AlarmListPanel/hooks/useAlarmList.js +7 -2
  54. package/es/core/components/AlarmListPanel/index.js +4 -2
  55. package/es/core/components/DisplaySettingDrawer/DisplaySetting.js +17 -11
  56. package/es/core/components/DisplaySettingDrawer/DisplaySettingDrawer.js +23 -13
  57. package/es/core/components/DisplaySettingDrawer/EdgeFlow.js +3 -1
  58. package/es/core/components/DisplaySettingDrawer/EdgeFlowDirection.js +3 -1
  59. package/es/core/components/DisplaySettingDrawer/LineExpandAllRadioGroup.js +25 -14
  60. package/es/core/components/DisplaySettingDrawer/LinkTag.js +3 -3
  61. package/es/core/components/DisplaySettingDrawer/NodeTag.js +1 -1
  62. package/es/core/components/DisplaySettingDrawer/NodeTip.js +1 -1
  63. package/es/core/components/DisplaySettingDrawer/ResourceDisplay/BasicConfig.js +32 -25
  64. package/es/core/components/DisplaySettingDrawer/ResourceDisplay/CommonCheckboxGroup.js +7 -3
  65. package/es/core/components/DisplaySettingDrawer/components/NodeAttrSettingDrawer.js +9 -6
  66. package/es/core/components/DisplaySettingDrawer/demo/Demo.js +3 -4
  67. package/es/core/components/DisplaySettingDrawer/hooks/useDisplaySetting.js +33 -10
  68. package/es/core/components/DisplaySettingDrawer/tagtip/CustomSettingDrawer/CustomSetting.js +5 -3
  69. package/es/core/components/DisplaySettingDrawer/tagtip/CustomSettingDrawer/CustomSettingDrawer.js +2 -0
  70. package/es/core/components/ResourceViewAttributeSetting/Setting.js +12 -7
  71. package/es/core/components/ResourceViewAttributeSetting/nodeCiTypeAttrUtil.js +25 -7
  72. package/es/core/components/TopoView/GraphViewPanel.js +15 -10
  73. package/es/core/components/TopoView/topoView.js +62 -38
  74. package/es/core/components/titlebar/TitleBar.js +12 -4
  75. package/es/core/components/titlebar/widgets/TitleWidget.js +4 -2
  76. package/es/core/createTopoApp.js +1 -1
  77. package/es/core/editor/components/BackgroundView/UploadDialog/index.js +53 -21
  78. package/es/core/editor/components/BackgroundView/index.js +65 -24
  79. package/es/core/editor/components/BottomFloatTool/HelpIcon.js +15 -8
  80. package/es/core/editor/components/CustomIconPlugin/CustomIconPlugin.js +2 -5
  81. package/es/core/editor/components/CustomIconPlugin/RenameDialog.js +19 -7
  82. package/es/core/editor/components/CustomIconPlugin/UploadIconDialog.js +67 -24
  83. package/es/core/editor/components/CustomIconPlugin/UploadIconDialogWrapper.js +5 -3
  84. package/es/core/editor/components/CustomIconPlugin/utils/svgToShape.js +8 -3
  85. package/es/core/editor/components/EditorPlugin.js +8 -4
  86. package/es/core/editor/components/GroupAddResourceDrawerPlugin/GroupAddResourceDrawer.js +12 -6
  87. package/es/core/editor/components/GroupAddResourceDrawerPlugin/index.js +6 -6
  88. package/es/core/editor/components/Sidebar/Sidebar.js +17 -8
  89. package/es/core/editor/components/Sidebar/views/CanvasPanel/CanvasPanel.js +7 -5
  90. package/es/core/editor/components/Sidebar/views/CanvasPanel/hooks/useCanvasThemeConfig.js +30 -14
  91. package/es/core/editor/components/Sidebar/views/ComponentPanel.js +7 -7
  92. package/es/core/editor/components/Sidebar/views/ImagePanel/CiTypeImagePanel.js +2 -2
  93. package/es/core/editor/components/Sidebar/views/ImagePanel/CustomImagePanel.js +2 -2
  94. package/es/core/editor/components/Sidebar/views/ImagePanel/HtCustomImagePanel.js +10 -7
  95. package/es/core/editor/components/Sidebar/views/ImagePanel/HtImagePalette.js +10 -7
  96. package/es/core/editor/components/Sidebar/views/ImagePanel/ImagePalette.js +7 -7
  97. package/es/core/editor/components/Sidebar/views/ImagePanel/ImagePanel.js +12 -4
  98. package/es/core/editor/components/Sidebar/views/LinkPanel.js +8 -7
  99. package/es/core/editor/components/Toolbar/EditorToolbar.js +7 -2
  100. package/es/core/editor/components/Toolbar/Toolbar.js +2 -0
  101. package/es/core/editor/components/Toolbar/buttons.js +15 -30
  102. package/es/core/editor/components/Toolbar/components/Tooltip.js +3 -2
  103. package/es/core/editor/components/Toolbar/widgets/AddResourceButton.js +11 -8
  104. package/es/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundButton.js +13 -7
  105. package/es/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundSetting.js +42 -19
  106. package/es/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundUtil.js +29 -9
  107. package/es/core/editor/components/Toolbar/widgets/CanvasMoveWidget.js +7 -3
  108. package/es/core/editor/components/Toolbar/widgets/CanvasSelectWidget.js +7 -3
  109. package/es/core/editor/components/Toolbar/widgets/Divider.js +2 -0
  110. package/es/core/editor/components/Toolbar/widgets/EdgeColorButton/Content.js +8 -6
  111. package/es/core/editor/components/Toolbar/widgets/EdgeColorButton/EdgeColorButton.js +27 -13
  112. package/es/core/editor/components/Toolbar/widgets/EdgeTypeButton/EdgeType.js +17 -10
  113. package/es/core/editor/components/Toolbar/widgets/EdgeTypeButton/LineType.js +6 -5
  114. package/es/core/editor/components/Toolbar/widgets/EdgeTypeButton/constants.js +3 -2
  115. package/es/core/editor/components/Toolbar/widgets/EdgeTypeButton/index.js +27 -14
  116. package/es/core/editor/components/Toolbar/widgets/FontColorButton.js +44 -24
  117. package/es/core/editor/components/Toolbar/widgets/FontFamilyWidget.js +7 -4
  118. package/es/core/editor/components/Toolbar/widgets/FontSizeWidget.js +10 -8
  119. package/es/core/editor/components/Toolbar/widgets/FontStyleButton.js +27 -16
  120. package/es/core/editor/components/Toolbar/widgets/HistoryRedoButton.js +6 -2
  121. package/es/core/editor/components/Toolbar/widgets/HistoryUndoButton.js +8 -4
  122. package/es/core/editor/components/Toolbar/widgets/IconSelect/IconSelect.js +23 -9
  123. package/es/core/editor/components/Toolbar/widgets/IconSelect/index.js +23 -9
  124. package/es/core/editor/components/Toolbar/widgets/IconSelect/index.module.scss +1 -1
  125. package/es/core/editor/components/Toolbar/widgets/IconSelect/popUpContent.js +6 -2
  126. package/es/core/editor/components/Toolbar/widgets/Layout/components/LayoutSettings.js +14 -10
  127. package/es/core/editor/components/Toolbar/widgets/Layout/components/LayoutTagImageSelect/index.js +12 -9
  128. package/es/core/editor/components/Toolbar/widgets/Layout/components/LayoutTagSelect/index.js +16 -12
  129. package/es/core/editor/components/Toolbar/widgets/Layout/components/LayoutTemplateButton/Icon.js +7 -5
  130. package/es/core/editor/components/Toolbar/widgets/Layout/components/LayoutTemplateButton/index.js +9 -6
  131. package/es/core/editor/components/Toolbar/widgets/Layout/index.js +46 -27
  132. package/es/core/editor/components/Toolbar/widgets/NodeAlignWidget.js +33 -20
  133. package/es/core/editor/components/Toolbar/widgets/NodeImageButton/BoxBackgroundSetting.js +4 -2
  134. package/es/core/editor/components/Toolbar/widgets/NodeImageButton/NodeImageButton.js +18 -12
  135. package/es/core/editor/components/Toolbar/widgets/NodeSizeButton/BoxBackgroundSetting.js +2 -0
  136. package/es/core/editor/components/Toolbar/widgets/NodeSizeButton/NodeSizeButton.js +25 -16
  137. package/es/core/editor/components/Toolbar/widgets/SearchWidget.js +5 -1
  138. package/es/core/editor/components/Toolbar/widgets/WidgetBox.js +11 -6
  139. package/es/core/editor/components/Toolbar/widgets/components/ArrowButton.js +4 -2
  140. package/es/core/editor/components/Toolbar/widgets/components/ArrowPopup.js +4 -2
  141. package/es/core/editor/components/Toolbar/widgets/components/ButtonBox.js +9 -5
  142. package/es/core/editor/components/Toolbar/widgets/components/DropdownButton.js +18 -9
  143. package/es/core/editor/components/Toolbar/widgets/components/DropdownMenu.js +10 -5
  144. package/es/core/editor/components/Toolbar/widgets/components/MenuSelect.js +4 -2
  145. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/ElementTextStyleSetting.js +11 -5
  146. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/colorUtil.js +9 -4
  147. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/box.js +6 -3
  148. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/edgeTag.js +15 -6
  149. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/groupTitle.js +10 -5
  150. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/layerTitle.js +13 -6
  151. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/nodeTag.js +17 -7
  152. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/text.js +6 -2
  153. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/textStyleUtil.js +22 -6
  154. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/GlobalTagStyleSetting/GlobalTagStyleSetting.js +7 -3
  155. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/GlobalTagStyleSetting/globalTag.js +32 -13
  156. package/es/core/editor/components/Toolbar/widgets/components/textStyleSetting/textStyleSettingRouter.js +2 -0
  157. package/es/core/editor/components/plugins/AddElementThemePlugin.js +2 -0
  158. package/es/core/editor/components/plugins/CorePlugin.js +5 -3
  159. package/es/core/editor/components/plugins/SaveLoading.js +4 -2
  160. package/es/core/editor/components/settings/CloseablePanel.js +5 -3
  161. package/es/core/editor/components/settings/PropertyView.js +17 -7
  162. package/es/core/editor/components/settings/Settings.js +13 -7
  163. package/es/core/editor/components/settings/common/AddResourceButton.js +2 -0
  164. package/es/core/editor/components/settings/common/AlignSetting/AlignTypeList.js +14 -11
  165. package/es/core/editor/components/settings/common/AlignSetting/index.js +11 -5
  166. package/es/core/editor/components/settings/common/GroupNodeList/ResourceList.js +10 -2
  167. package/es/core/editor/components/settings/common/LayoutSettings.js +15 -12
  168. package/es/core/editor/components/settings/common/LineType/index.js +2 -0
  169. package/es/core/editor/components/settings/common/NameInput.js +3 -1
  170. package/es/core/editor/components/settings/common/NodeSizeInput/NodeSizeInput.js +28 -9
  171. package/es/core/editor/components/settings/common/SizeInput/NodeSizeInput.js +20 -12
  172. package/es/core/editor/components/settings/common/SizeInput/NodeSizeNumberPicker.js +21 -10
  173. package/es/core/editor/components/settings/common/tab/TabView.js +2 -0
  174. package/es/core/editor/components/settings/common/text/FontStyleCheckbox.js +5 -1
  175. package/es/core/editor/components/settings/common/text/TextStyle.js +7 -2
  176. package/es/core/editor/components/settings/common/text/fontStyleUtil.js +6 -2
  177. package/es/core/editor/components/settings/core/PropertyViewManager.js +19 -0
  178. package/es/core/editor/components/settings/core/edgePropertyViewAdapter.js +2 -0
  179. package/es/core/editor/components/settings/core/getPropertyViewType.js +4 -0
  180. package/es/core/editor/components/settings/core/updateElementProperty.js +1 -0
  181. package/es/core/editor/components/settings/propertyViews/PropertyViewFactory.js +1 -0
  182. package/es/core/editor/components/settings/propertyViews/box/BoxPropertyView.js +9 -3
  183. package/es/core/editor/components/settings/propertyViews/box/BoxPropertyViewV1.js +8 -2
  184. package/es/core/editor/components/settings/propertyViews/box/NameInput.js +11 -3
  185. package/es/core/editor/components/settings/propertyViews/edge/CommonEdgePropertyView.js +13 -5
  186. package/es/core/editor/components/settings/propertyViews/edge/EdgeGroupPropertyView.js +2 -0
  187. package/es/core/editor/components/settings/propertyViews/edge/EdgePropertyView.js +10 -4
  188. package/es/core/editor/components/settings/propertyViews/edge/edgeGroup/EdgeGroupSetting.js +9 -3
  189. package/es/core/editor/components/settings/propertyViews/group/DataTab/GroupAddResourceButton.js +4 -2
  190. package/es/core/editor/components/settings/propertyViews/group/DataTab/GroupNodeList.js +8 -7
  191. package/es/core/editor/components/settings/propertyViews/group/DataTab/GroupRelateData/GroupRelateData.js +10 -4
  192. package/es/core/editor/components/settings/propertyViews/group/DataTab/RelateData.js +4 -4
  193. package/es/core/editor/components/settings/propertyViews/group/DataTab/hoooks/useGroupRelateResource.js +12 -11
  194. package/es/core/editor/components/settings/propertyViews/group/GroupPropertyView.js +3 -3
  195. package/es/core/editor/components/settings/propertyViews/group/GroupPropertyViewV1.js +3 -3
  196. package/es/core/editor/components/settings/propertyViews/group/SettingTab/GroupBasicSetting.js +11 -7
  197. package/es/core/editor/components/settings/propertyViews/group/SettingTab/GroupExpandSetting.js +19 -17
  198. package/es/core/editor/components/settings/propertyViews/group/SettingTab/GroupExpandStatus.js +5 -3
  199. package/es/core/editor/components/settings/propertyViews/group/SettingTab/GroupIconSelect.js +4 -2
  200. package/es/core/editor/components/settings/propertyViews/group/SettingTab/Setting.js +15 -6
  201. package/es/core/editor/components/settings/propertyViews/group/cluster/ClusterGroupRelateData.js +6 -4
  202. package/es/core/editor/components/settings/propertyViews/index.js +2 -0
  203. package/es/core/editor/components/settings/propertyViews/layer/BasicSetting.js +7 -3
  204. package/es/core/editor/components/settings/propertyViews/layer/DataTab/DefaultLayerAddResourceDrawer.js +13 -7
  205. package/es/core/editor/components/settings/propertyViews/layer/DataTab/LayerAddResourceButton.js +6 -4
  206. package/es/core/editor/components/settings/propertyViews/layer/DataTab/LayerAddResourceDrawer.js +4 -2
  207. package/es/core/editor/components/settings/propertyViews/layer/DataTab/NodeList.js +2 -2
  208. package/es/core/editor/components/settings/propertyViews/layer/DataTab/RelateData.js +6 -4
  209. package/es/core/editor/components/settings/propertyViews/layer/LayerPropertyView.js +6 -6
  210. package/es/core/editor/components/settings/propertyViews/layer/LayerPropertyViewV1.js +6 -6
  211. package/es/core/editor/components/settings/propertyViews/layer/SettingTab/Setting.js +16 -9
  212. package/es/core/editor/components/settings/propertyViews/layer/SettingTab/Setting_bak.js +18 -16
  213. package/es/core/editor/components/settings/propertyViews/multipleElements/BatchSetNodeIcon.js +2 -2
  214. package/es/core/editor/components/settings/propertyViews/multipleElements/BatchSetNodeSize/BatchSetNodeSize.js +35 -13
  215. package/es/core/editor/components/settings/propertyViews/multipleElements/MultipleElementLineType.js +2 -0
  216. package/es/core/editor/components/settings/propertyViews/multipleElements/MultipleElementPropertyView.js +11 -7
  217. package/es/core/editor/components/settings/propertyViews/node/NodeIconSelect.js +6 -4
  218. package/es/core/editor/components/settings/propertyViews/node/NodeIconSelectTest.js +2 -2
  219. package/es/core/editor/components/settings/propertyViews/node/NodePropertyView.js +9 -7
  220. package/es/core/editor/components/settings/propertyViews/node/NodePropertyViewV1.js +12 -7
  221. package/es/core/editor/components/settings/propertyViews/node/Setting/BasicSetting.js +11 -6
  222. package/es/core/editor/components/settings/propertyViews/node/Setting/NameInput.js +11 -3
  223. package/es/core/editor/components/settings/propertyViews/node/Setting/Setting.js +14 -6
  224. package/es/core/editor/components/settings/propertyViews/node/data/BindIpInput.js +23 -18
  225. package/es/core/editor/components/settings/propertyViews/node/data/BindResourceDrawer.js +17 -8
  226. package/es/core/editor/components/settings/propertyViews/node/data/Data.js +29 -19
  227. package/es/core/editor/components/settings/propertyViews/node/data/NodeRelateResourceButton.js +10 -7
  228. package/es/core/editor/components/settings/propertyViews/node/data/PlatformDisplay.js +5 -1
  229. package/es/core/editor/components/settings/propertyViews/text/TextPropertyView.js +17 -5
  230. package/es/core/editor/components/settings/propertyViews/view/BackgroundSize.js +10 -5
  231. package/es/core/editor/components/settings/propertyViews/view/BatchSetNodeSize.js +3 -5
  232. package/es/core/editor/components/settings/propertyViews/view/GlobalEdgeToggle.js +11 -5
  233. package/es/core/editor/components/settings/propertyViews/view/GlobalLayout.js +7 -6
  234. package/es/core/editor/components/settings/propertyViews/view/GlobalNodeLabelStyle.js +7 -2
  235. package/es/core/editor/components/settings/propertyViews/view/ViewLineTypeSetting.js +3 -0
  236. package/es/core/editor/components/settings/propertyViews/view/ViewPropertyView.js +3 -3
  237. package/es/core/editor/components/settings/propertyViews/view/ViewPropertyViewV2.js +3 -3
  238. package/es/core/editor/components/settings/propertyViews/view/hooks/useBackgroundConfig.js +4 -3
  239. package/es/core/editor/components/settings/propertyViews/view/hooks/useBackgroundSizeConfig.js +12 -4
  240. package/es/core/editor/components/settings/useSettingRuntimeState.js +6 -2
  241. package/es/core/editor/components/titlebar/TopoEditorTitleBar.js +26 -12
  242. package/es/core/editor/components/titlebar/widgets/DebugTools.js +4 -1
  243. package/es/core/editor/config/themes.js +7 -8
  244. package/es/core/editor/contextmenu/buildContextmenu.js +1 -2
  245. package/es/core/editor/hooks/useKeyboardShortcut.js +10 -7
  246. package/es/core/editor/hooks/useLayerAddResource.js +6 -4
  247. package/es/core/editor/hooks/useNewElementTheme.js +14 -7
  248. package/es/core/editor/hooks/useUpdateHtTopoDefaultTagStyle.js +3 -2
  249. package/es/core/editor/store/background.js +8 -4
  250. package/es/core/editor/store/historyManager.js +1 -0
  251. package/es/core/editor/store/topoEdit.js +4 -3
  252. package/es/core/editor/utils/edgeTypeStyleUtil.js +15 -9
  253. package/es/core/editor/utils/themeUtil.js +3 -0
  254. package/es/core/event/topoEventListener.js +2 -0
  255. package/es/core/hooks/ht/useHtDataPropertyChangeListener.js +7 -3
  256. package/es/core/hooks/useAlarm.js +24 -12
  257. package/es/core/hooks/useCanvasTheme.js +10 -9
  258. package/es/core/hooks/useCanvasThemeConfig.js +4 -2
  259. package/es/core/hooks/useCiAttributeChange.js +10 -3
  260. package/es/core/hooks/useEventData.js +4 -2
  261. package/es/core/hooks/useGraphAlarmDisplay.js +27 -11
  262. package/es/core/hooks/useGroupAddResource.js +5 -2
  263. package/es/core/hooks/useManageStatus.js +1 -1
  264. package/es/core/hooks/usePolling.js +61 -33
  265. package/es/core/hooks/useResourceConfig.js +57 -22
  266. package/es/core/hooks/useRouterAdapter.js +4 -2
  267. package/es/core/hooks/useSelection.js +4 -1
  268. package/es/core/hooks/useTopoEdit.js +261 -112
  269. package/es/core/hooks/useTopoEventListener.js +1 -1
  270. package/es/core/hooks/useTopoFullscreen.js +8 -7
  271. package/es/core/models/Alarm.js +139 -50
  272. package/es/core/models/AttributeMetricDisplay.js +166 -89
  273. package/es/core/models/DataModel.js +37 -4
  274. package/es/core/models/EdgeGroup.js +7 -2
  275. package/es/core/models/GraphDataModel.js +7 -0
  276. package/es/core/models/HistoryManager.js +52 -21
  277. package/es/core/models/PluginManager.js +9 -0
  278. package/es/core/models/SelectionModel.js +36 -11
  279. package/es/core/models/TopoApp.js +178 -74
  280. package/es/core/models/TopoGraphView.js +30 -8
  281. package/es/core/models/TopoViewer.js +5 -1
  282. package/es/core/models/attributeFormatter/formatter/ciTypeAttrTransform.js +3 -2
  283. package/es/core/models/attributeFormatter/formatter/commonTransform.js +8 -6
  284. package/es/core/models/attributeFormatter/formatter/graphTransform.js +5 -2
  285. package/es/core/models/attributeFormatter/index.js +8 -1
  286. package/es/core/models/cache/CiCache.js +17 -4
  287. package/es/core/models/cache/CiTypeCache.js +35 -8
  288. package/es/core/models/cache/DictCache.js +19 -4
  289. package/es/core/models/common/ContextMenu.js +9 -0
  290. package/es/core/models/graph/Background.js +16 -3
  291. package/es/core/models/plugins/index.js +1 -3
  292. package/es/core/models/plugins/resourceWebControllUrl.js +39 -9
  293. package/es/core/models/tagstips/ElementTagTipConfig.js +55 -16
  294. package/es/core/models/tagstips/utils.js +4 -4
  295. package/es/core/models/topoData.js +24 -8
  296. package/es/core/models/topoFactory.js +6 -0
  297. package/es/core/models/utils/linkUtils.js +35 -24
  298. package/es/core/models/utils/nodeNameVisibleUtil.js +25 -16
  299. package/es/core/services/alarm.js +5 -3
  300. package/es/core/services/background.js +24 -9
  301. package/es/core/services/cmdb/metric.js +5 -3
  302. package/es/core/services/cmdb.js +6 -3
  303. package/es/core/services/index.js +18 -7
  304. package/es/core/services/overview.js +58 -25
  305. package/es/core/services/topo/basic.js +5 -3
  306. package/es/core/services/topo/tagtip.js +6 -3
  307. package/es/core/store/coreModels.js +2 -4
  308. package/es/core/store/createStore.js +3 -0
  309. package/es/core/store/models/ciModel.js +16 -5
  310. package/es/core/store/models/customIcon.js +55 -19
  311. package/es/core/store/models/displayConfig.js +11 -5
  312. package/es/core/store/models/selection.js +5 -4
  313. package/es/core/store/models/topoAlarm.js +42 -10
  314. package/es/core/store/models/topoBaseInfoOverview.js +5 -4
  315. package/es/core/store/models/topoBizMod.js +14 -5
  316. package/es/core/store/models/topoConfig.js +85 -39
  317. package/es/core/store/models/topoGraphView.js +7 -5
  318. package/es/core/store/models/topoMod.js +111 -38
  319. package/es/core/store/models/viewer/lock.js +1 -0
  320. package/es/core/store/models/viewer/resourceDetail.js +5 -2
  321. package/es/core/store/models/viewer/resourceWebControllUrlSetting.js +1 -0
  322. package/es/core/test/Test.js +13 -10
  323. package/es/core/upgrade/v140UpgradeSerializeNodeImageSize.js +5 -0
  324. package/es/core/utils/backgroundUtil.js +7 -5
  325. package/es/core/utils/edgeUtil.js +11 -4
  326. package/es/core/utils/graphLinkUtil.js +8 -5
  327. package/es/core/utils/imageUtil.js +9 -3
  328. package/es/core/utils/metricUtil.js +1 -1
  329. package/es/core/utils/resourceUtil.js +3 -3
  330. package/es/core/utils/saveSerialize.js +6 -3
  331. package/es/core/utils/showGraphManageStatusUtil.js +18 -14
  332. package/es/core/utils/showMessage.js +2 -0
  333. package/es/core/viewer/components/plugins/ElementDetailDrawer/components/DetailDrawer.js +2 -0
  334. package/es/core/viewer/components/plugins/ElementDetailDrawer/hooks/useElementDetailManager.js +59 -32
  335. package/es/core/viewer/components/plugins/ResourceDetail/DefaultDetailContent.js +14 -8
  336. package/es/core/viewer/components/plugins/ResourceDetail/ResourceDetail.js +11 -6
  337. package/es/core/viewer/components/plugins/ResourceDetail/ResourceDetailDrawer.js +12 -9
  338. package/es/core/viewer/components/plugins/ResourceDetail/ResourceDetailPlugin.js +7 -2
  339. package/es/core/viewer/components/plugins/ResourceDetail/components/ClusterMemberTable.js +22 -10
  340. package/es/core/viewer/components/plugins/ResourceDetail/components/DrawerTitle.js +16 -7
  341. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/BaseInfo.js +23 -18
  342. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/BaseInfoBlock.js +10 -10
  343. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/BlockBox.js +2 -2
  344. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/EventsCard.js +17 -10
  345. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/NetworkBaseInfo.js +27 -19
  346. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverview.js +200 -90
  347. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverviewMetric.js +29 -25
  348. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/SingleResourceStrategyLink.js +6 -6
  349. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/Configurator/index.js +70 -33
  350. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/LinkTopo.js +4 -2
  351. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/LinkTopoCard.js +27 -13
  352. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/constants.js +4 -8
  353. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/hooks/useMetricPolling.js +18 -14
  354. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/services/index.js +62 -23
  355. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useAlarmAndRiskData.js +37 -24
  356. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useMetricModels.js +43 -22
  357. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/useCiAttrAndMetricData.js +4 -2
  358. package/es/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleContainer.js +4 -1
  359. package/es/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleForm/WebConsoleForm.js +15 -8
  360. package/es/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleForm/hooks/useWebConsole.js +24 -10
  361. package/es/core/viewer/components/plugins/ResourceDetail/getCiDisplayMetricModels.js +12 -5
  362. package/es/core/viewer/components/plugins/ResourceDetail/hooks/useUserId.js +16 -7
  363. package/es/core/viewer/components/plugins/ResourceWebControllUrlSettingDialog.js +18 -6
  364. package/es/core/viewer/components/plugins/ViewerPlugin.js +1 -1
  365. package/es/core/viewer/components/titlebar/BasicTools.js +3 -3
  366. package/es/core/viewer/components/titlebar/TopoViewerTitleBar.js +4 -4
  367. package/es/core/viewer/components/titlebar/widgets/AlarmButton.js +6 -2
  368. package/es/core/viewer/components/titlebar/widgets/AlarmListShowButton.js +16 -14
  369. package/es/core/viewer/components/titlebar/widgets/EditButton.js +8 -4
  370. package/es/core/viewer/components/titlebar/widgets/MoreButtonMenu.js +1 -1
  371. package/es/core/viewer/components/titlebar/widgets/NodesDragSwitch.js +18 -14
  372. package/es/core/viewer/components/titlebar/widgets/NodesDragSwitchWrapper.js +5 -1
  373. package/es/core/viewer/components/titlebar/widgets/SearchWidget.js +17 -9
  374. package/es/core/viewer/components/titlebar/widgets/SettingButton.js +10 -7
  375. package/es/core/viewer/components/titlebar/widgets/SettingButtonWidget.js +5 -5
  376. package/es/core/viewer/contextmenu/buildLinkContextmenu.js +1 -2
  377. package/es/core/viewer/contextmenu/buildNodeContextmenu.js +2 -8
  378. package/es/createTopo.js +1 -2
  379. package/es/mock/mock.js +4 -6
  380. package/es/networkTopo/components/Link/form.js +41 -25
  381. package/es/networkTopo/components/Link/hook.js +86 -48
  382. package/es/networkTopo/components/Link/index.js +63 -33
  383. package/es/networkTopo/components/Link/setting.js +65 -45
  384. package/es/networkTopo/components/TopoView.js +20 -14
  385. package/es/networkTopo/getTopoData.js +37 -21
  386. package/es/networkTopo/hooks/useEdgeExpand.js +3 -2
  387. package/es/networkTopo/hooks/useGroupResources.js +4 -2
  388. package/es/networkTopo/hooks/useLinkDynamicStyle.js +4 -2
  389. package/es/networkTopo/hooks/viewer/useEdgeFlow.js +7 -6
  390. package/es/networkTopo/hooks/viewer/useRelateTopo.js +23 -8
  391. package/es/networkTopo/models/EdgeGroupTagTipBuilder.js +10 -2
  392. package/es/networkTopo/models/ExtElementTagTipBuilder.js +5 -0
  393. package/es/networkTopo/models/IpNodeTagsTipsBuilder.js +11 -2
  394. package/es/networkTopo/models/LinkDynamicStyleExecutor.js +49 -28
  395. package/es/networkTopo/models/LinkTagsTipsBuilder.js +51 -41
  396. package/es/networkTopo/models/TopoCenter.js +26 -8
  397. package/es/networkTopo/services/alert.js +10 -5
  398. package/es/networkTopo/services/authorization.js +25 -11
  399. package/es/networkTopo/services/cmdb.js +165 -80
  400. package/es/networkTopo/services/funcAuth.js +5 -3
  401. package/es/networkTopo/services/link.js +34 -11
  402. package/es/networkTopo/services/mdc.js +17 -10
  403. package/es/networkTopo/services/metric.js +12 -6
  404. package/es/networkTopo/services/model.js +223 -92
  405. package/es/networkTopo/services/risk.js +5 -3
  406. package/es/networkTopo/services/topo/auth.js +13 -7
  407. package/es/networkTopo/services/topo/basic.js +137 -57
  408. package/es/networkTopo/services/topo/blacklist.js +11 -5
  409. package/es/networkTopo/services/topo/ciInfo.js +13 -5
  410. package/es/networkTopo/services/topo/icon.js +24 -11
  411. package/es/networkTopo/services/topo/networkLink.js +11 -5
  412. package/es/networkTopo/services/topo/relation.js +5 -3
  413. package/es/networkTopo/services/topo/resourceWebUrl.js +17 -7
  414. package/es/networkTopo/store/functionAuth.js +16 -7
  415. package/es/networkTopo/store/topoCenter.js +53 -18
  416. package/es/networkTopo/store/topoLinkMod.js +4 -3
  417. package/es/networkTopo/store/topoTreeMod.js +71 -19
  418. package/es/networkTopo/utils/SortResourcesUtil.js +3 -1
  419. package/es/networkTopo/utils/__tests__/resourcePermissionUtil.test.js +7 -4
  420. package/es/networkTopo/utils/edgeGroupTagUtil.js +15 -8
  421. package/es/networkTopo/utils/exitLinkUtil.js +54 -38
  422. package/es/networkTopo/utils/exportData.js +16 -10
  423. package/es/networkTopo/utils/linPermissionUtil.js +2 -4
  424. package/es/networkTopo/utils/resourcePermissionUtil.js +6 -4
  425. package/es/networkTopo/utils/storage.js +3 -2
  426. package/es/networkTopo/viewer/components/TopologyViewer.js +4 -3
  427. package/es/networkTopo/viewer/index.js +1 -2
  428. package/es/utils/ResourceConfigUtil.js +23 -18
  429. package/es/utils/SpecialCharacterValidateUtil.js +1 -0
  430. package/es/utils/ciType.js +5 -1
  431. package/es/utils/clusterUtil.js +20 -15
  432. package/es/utils/format.js +26 -12
  433. package/es/utils/htElementUtils.js +51 -25
  434. package/es/utils/template.js +7 -6
  435. package/es/utils/topoData.js +64 -52
  436. package/es/utils/topoMocks.js +4 -3
  437. package/es/utils/tree.js +33 -14
  438. package/es/utils/treeUtil.js +1 -0
  439. package/lib/common/components/ColorPicker/ColorPicker.js +30 -9
  440. package/lib/common/components/ColorPicker/index.js +3 -0
  441. package/lib/common/components/ResourceTable/ResourceTable.js +18 -6
  442. package/lib/common/plugins/useSelectionPlugin.js +24 -13
  443. package/lib/components/BatchAttrMetric/SelectTable.js +3 -0
  444. package/lib/components/BatchAttrMetric/constant.js +2 -2
  445. package/lib/components/BatchAttrMetric/index.js +27 -9
  446. package/lib/components/BatchAttrMetric/setting.js +72 -30
  447. package/lib/components/BatchAttrMetric/utils.js +9 -1
  448. package/lib/components/BooleanRadio.js +15 -5
  449. package/lib/components/ColorPanel/components/ColorBlock/index.js +8 -2
  450. package/lib/components/ColorPanel/components/FontColorRange/index.js +19 -9
  451. package/lib/components/ColorPanel/index.js +50 -17
  452. package/lib/components/Drawer/Drawer.js +25 -14
  453. package/lib/components/Drawer/index.js +3 -0
  454. package/lib/components/FormTable/index.js +32 -13
  455. package/lib/components/FullheightTab/FullheightTab.js +7 -0
  456. package/lib/components/FullheightTab/index.js +3 -0
  457. package/lib/components/LayoutDirectionSelect/Item.js +9 -0
  458. package/lib/components/LayoutDirectionSelect/LayoutDirectionSelect.js +13 -5
  459. package/lib/components/LayoutDirectionSelect/index.js +3 -0
  460. package/lib/components/LayoutSelect/LayoutSelect.js +12 -5
  461. package/lib/components/LayoutSelect/index.js +3 -0
  462. package/lib/components/Link.js +7 -0
  463. package/lib/components/ModelAttrSelectDrawer/components/ModelAttrSelectDrawer.js +11 -4
  464. package/lib/components/ModelAttrSelectDrawer/components/MultipleTypeAttributeSelectDrawer.js +27 -15
  465. package/lib/components/ModelAttrSelectDrawer/index.js +3 -0
  466. package/lib/components/MultiResourceDrawer/Content.js +31 -11
  467. package/lib/components/MultiResourceDrawer/Dynamic.js +10 -2
  468. package/lib/components/MultiResourceDrawer/ResourceCard/index.js +11 -4
  469. package/lib/components/MultiResourceDrawer/ResourceSelect.js +10 -2
  470. package/lib/components/MultiResourceDrawer/Static.js +10 -2
  471. package/lib/components/MultiResourceDrawer/index.js +23 -8
  472. package/lib/components/NetworkTopoResourceSelectDrawer/NetworkTopoResourceSelectDrawer.js +6 -0
  473. package/lib/components/NetworkTopoResourceSelectDrawer/index.js +3 -0
  474. package/lib/components/ResourceList/ResourceSelect.js +64 -27
  475. package/lib/components/ResourceList/ResourceSelectConnect.js +17 -3
  476. package/lib/components/ResourceList/index.js +3 -0
  477. package/lib/components/ResourceSelect/ResourceSelectDrawer.js +21 -6
  478. package/lib/components/ResourceSelectDrawer/ResourceSelectDrawer.js +39 -13
  479. package/lib/components/ResourceSelectDrawer/ResourceSelectList.js +15 -4
  480. package/lib/components/ResourceSelectDrawer/index.js +3 -0
  481. package/lib/components/SingleResourceDrawer/SelectDrawer.js +23 -6
  482. package/lib/components/SingleResourceDrawer/SingleResourceDrawer.js +22 -6
  483. package/lib/components/SingleResourceDrawer/index.js +3 -0
  484. package/lib/components/TagImageSelect/index.js +18 -8
  485. package/lib/components/TagSelect/index.js +22 -8
  486. package/lib/components/TemplateButton/Icon.js +10 -5
  487. package/lib/components/TemplateButton/assets/index.js +5 -0
  488. package/lib/components/TemplateButton/index.js +16 -6
  489. package/lib/components/VerticalIconTab/VerticalIconTab.js +23 -6
  490. package/lib/components/VerticalIconTab/index.js +3 -0
  491. package/lib/components/collapse/Collapse.js +16 -4
  492. package/lib/components/collapse/Panel.js +33 -7
  493. package/lib/components/collapse/index.js +3 -0
  494. package/lib/constants/ResourceInfoDisplay.js +6 -6
  495. package/lib/constants/ResourceTypeLimit.js +20 -20
  496. package/lib/contextmenu/createMenuCommands.js +11 -6
  497. package/lib/core/common/contextmenu/mergeContextmenu.js +6 -2
  498. package/lib/core/common/hooks/ht/useDataModelDataPropertyChange.js +5 -0
  499. package/lib/core/common/hooks/useHtElement.js +4 -1
  500. package/lib/core/common/hooks/useHtElements.js +8 -5
  501. package/lib/core/common/icons/icon.js +36 -16
  502. package/lib/core/common/icons/useIcons.js +10 -1
  503. package/lib/core/components/AlarmListPanel/components/AlarmListItem.js +22 -4
  504. package/lib/core/components/AlarmListPanel/constants/uicbb.js +1 -0
  505. package/lib/core/components/AlarmListPanel/hooks/useAlarmList.js +9 -2
  506. package/lib/core/components/AlarmListPanel/index.js +18 -2
  507. package/lib/core/components/DisplaySettingDrawer/DisplaySetting.js +34 -10
  508. package/lib/core/components/DisplaySettingDrawer/DisplaySettingDrawer.js +38 -13
  509. package/lib/core/components/DisplaySettingDrawer/EdgeFlow.js +8 -1
  510. package/lib/core/components/DisplaySettingDrawer/EdgeFlowDirection.js +8 -1
  511. package/lib/core/components/DisplaySettingDrawer/LineExpandAllRadioGroup.js +38 -14
  512. package/lib/core/components/DisplaySettingDrawer/LinkTag.js +10 -1
  513. package/lib/core/components/DisplaySettingDrawer/NodeTag.js +10 -1
  514. package/lib/core/components/DisplaySettingDrawer/NodeTip.js +10 -1
  515. package/lib/core/components/DisplaySettingDrawer/ResourceDisplay/BasicConfig.js +46 -24
  516. package/lib/core/components/DisplaySettingDrawer/ResourceDisplay/CommonCheckboxGroup.js +14 -3
  517. package/lib/core/components/DisplaySettingDrawer/components/NodeAttrSettingDrawer.js +21 -5
  518. package/lib/core/components/DisplaySettingDrawer/demo/Demo.js +6 -4
  519. package/lib/core/components/DisplaySettingDrawer/hooks/useDisplaySetting.js +39 -10
  520. package/lib/core/components/DisplaySettingDrawer/index.js +3 -0
  521. package/lib/core/components/DisplaySettingDrawer/tagtip/CustomSettingDrawer/CustomSetting.js +11 -3
  522. package/lib/core/components/DisplaySettingDrawer/tagtip/CustomSettingDrawer/CustomSettingDrawer.js +5 -0
  523. package/lib/core/components/ResourceViewAttributeSetting/Setting.js +22 -6
  524. package/lib/core/components/ResourceViewAttributeSetting/nodeCiTypeAttrUtil.js +27 -6
  525. package/lib/core/components/TopoAppProvider.js +5 -0
  526. package/lib/core/components/TopoView/GraphViewPanel.js +24 -10
  527. package/lib/core/components/TopoView/index.js +3 -0
  528. package/lib/core/components/TopoView/topoView.js +97 -35
  529. package/lib/core/components/buildProvider.js +5 -0
  530. package/lib/core/components/titlebar/TitleBar.js +21 -4
  531. package/lib/core/components/titlebar/index.js +17 -0
  532. package/lib/core/components/titlebar/widgets/TitleWidget.js +9 -2
  533. package/lib/core/createTopoApp.js +5 -0
  534. package/lib/core/editor/components/BackgroundView/UploadDialog/index.js +69 -21
  535. package/lib/core/editor/components/BackgroundView/index.js +87 -24
  536. package/lib/core/editor/components/BottomFloatTool/HelpIcon.js +25 -8
  537. package/lib/core/editor/components/CustomIconPlugin/CustomIconPlugin.js +10 -5
  538. package/lib/core/editor/components/CustomIconPlugin/RenameDialog.js +35 -7
  539. package/lib/core/editor/components/CustomIconPlugin/UploadIconDialog.js +87 -24
  540. package/lib/core/editor/components/CustomIconPlugin/UploadIconDialogWrapper.js +11 -3
  541. package/lib/core/editor/components/CustomIconPlugin/index.js +3 -0
  542. package/lib/core/editor/components/CustomIconPlugin/utils/svgToShape.js +13 -3
  543. package/lib/core/editor/components/EditorPlugin.js +23 -4
  544. package/lib/core/editor/components/GroupAddResourceDrawerPlugin/GroupAddResourceDrawer.js +19 -6
  545. package/lib/core/editor/components/GroupAddResourceDrawerPlugin/index.js +11 -5
  546. package/lib/core/editor/components/Sidebar/Sidebar.js +26 -8
  547. package/lib/core/editor/components/Sidebar/panes.js +7 -0
  548. package/lib/core/editor/components/Sidebar/views/BackgroundPanel/BackgroundPanel.js +4 -0
  549. package/lib/core/editor/components/Sidebar/views/BackgroundPanel/index.js +3 -0
  550. package/lib/core/editor/components/Sidebar/views/CanvasPanel/CanvasPanel.js +15 -5
  551. package/lib/core/editor/components/Sidebar/views/CanvasPanel/hooks/useCanvasThemeConfig.js +38 -14
  552. package/lib/core/editor/components/Sidebar/views/CanvasPanel/index.js +3 -0
  553. package/lib/core/editor/components/Sidebar/views/ComponentPanel.js +12 -6
  554. package/lib/core/editor/components/Sidebar/views/ImagePanel/CiTypeImagePanel.js +8 -1
  555. package/lib/core/editor/components/Sidebar/views/ImagePanel/CustomImagePanel.js +9 -1
  556. package/lib/core/editor/components/Sidebar/views/ImagePanel/HtCustomImagePanel.js +17 -6
  557. package/lib/core/editor/components/Sidebar/views/ImagePanel/HtImagePalette.js +17 -6
  558. package/lib/core/editor/components/Sidebar/views/ImagePanel/ImagePalette.js +12 -6
  559. package/lib/core/editor/components/Sidebar/views/ImagePanel/ImagePanel.js +29 -4
  560. package/lib/core/editor/components/Sidebar/views/ImagePanel/index.js +3 -0
  561. package/lib/core/editor/components/Sidebar/views/LinkPanel.js +13 -6
  562. package/lib/core/editor/components/Toolbar/EditorToolbar.js +17 -2
  563. package/lib/core/editor/components/Toolbar/Toolbar.js +5 -0
  564. package/lib/core/editor/components/Toolbar/buttons.js +35 -30
  565. package/lib/core/editor/components/Toolbar/components/Tooltip.js +8 -2
  566. package/lib/core/editor/components/Toolbar/widgets/AddResourceButton.js +21 -8
  567. package/lib/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundButton.js +21 -7
  568. package/lib/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundSetting.js +52 -19
  569. package/lib/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundUtil.js +37 -9
  570. package/lib/core/editor/components/Toolbar/widgets/BoxBackgroundButton/index.js +3 -0
  571. package/lib/core/editor/components/Toolbar/widgets/CanvasMoveWidget.js +13 -3
  572. package/lib/core/editor/components/Toolbar/widgets/CanvasSelectWidget.js +11 -3
  573. package/lib/core/editor/components/Toolbar/widgets/Divider.js +5 -0
  574. package/lib/core/editor/components/Toolbar/widgets/EdgeColorButton/Content.js +12 -6
  575. package/lib/core/editor/components/Toolbar/widgets/EdgeColorButton/EdgeColorButton.js +36 -12
  576. package/lib/core/editor/components/Toolbar/widgets/EdgeColorButton/index.js +3 -0
  577. package/lib/core/editor/components/Toolbar/widgets/EdgeTypeButton/EdgeType.js +28 -10
  578. package/lib/core/editor/components/Toolbar/widgets/EdgeTypeButton/LineType.js +16 -4
  579. package/lib/core/editor/components/Toolbar/widgets/EdgeTypeButton/constants.js +3 -2
  580. package/lib/core/editor/components/Toolbar/widgets/EdgeTypeButton/index.js +37 -13
  581. package/lib/core/editor/components/Toolbar/widgets/FontColorButton.js +57 -24
  582. package/lib/core/editor/components/Toolbar/widgets/FontFamilyWidget.js +15 -4
  583. package/lib/core/editor/components/Toolbar/widgets/FontSizeWidget.js +18 -8
  584. package/lib/core/editor/components/Toolbar/widgets/FontStyleButton.js +39 -16
  585. package/lib/core/editor/components/Toolbar/widgets/HistoryRedoButton.js +10 -2
  586. package/lib/core/editor/components/Toolbar/widgets/HistoryUndoButton.js +10 -3
  587. package/lib/core/editor/components/Toolbar/widgets/IconSelect/IconSelect.js +32 -9
  588. package/lib/core/editor/components/Toolbar/widgets/IconSelect/index.js +31 -9
  589. package/lib/core/editor/components/Toolbar/widgets/IconSelect/index.module.scss +1 -1
  590. package/lib/core/editor/components/Toolbar/widgets/IconSelect/popUpContent.js +12 -2
  591. package/lib/core/editor/components/Toolbar/widgets/Layout/components/LayoutSettings.js +23 -10
  592. package/lib/core/editor/components/Toolbar/widgets/Layout/components/LayoutTagImageSelect/index.js +19 -9
  593. package/lib/core/editor/components/Toolbar/widgets/Layout/components/LayoutTagSelect/index.js +26 -13
  594. package/lib/core/editor/components/Toolbar/widgets/Layout/components/LayoutTemplateButton/Icon.js +10 -5
  595. package/lib/core/editor/components/Toolbar/widgets/Layout/components/LayoutTemplateButton/assets/index.js +6 -0
  596. package/lib/core/editor/components/Toolbar/widgets/Layout/components/LayoutTemplateButton/index.js +16 -6
  597. package/lib/core/editor/components/Toolbar/widgets/Layout/index.js +55 -28
  598. package/lib/core/editor/components/Toolbar/widgets/NodeAlignWidget.js +44 -20
  599. package/lib/core/editor/components/Toolbar/widgets/NodeImageButton/BoxBackgroundSetting.js +10 -2
  600. package/lib/core/editor/components/Toolbar/widgets/NodeImageButton/NodeImageButton.js +26 -12
  601. package/lib/core/editor/components/Toolbar/widgets/NodeImageButton/index.js +3 -0
  602. package/lib/core/editor/components/Toolbar/widgets/NodeSizeButton/BoxBackgroundSetting.js +4 -0
  603. package/lib/core/editor/components/Toolbar/widgets/NodeSizeButton/NodeSizeButton.js +33 -13
  604. package/lib/core/editor/components/Toolbar/widgets/NodeSizeButton/index.js +3 -0
  605. package/lib/core/editor/components/Toolbar/widgets/SearchWidget.js +12 -1
  606. package/lib/core/editor/components/Toolbar/widgets/WidgetBox.js +20 -6
  607. package/lib/core/editor/components/Toolbar/widgets/components/ArrowButton.js +11 -2
  608. package/lib/core/editor/components/Toolbar/widgets/components/ArrowPopup.js +11 -1
  609. package/lib/core/editor/components/Toolbar/widgets/components/ButtonBox.js +17 -5
  610. package/lib/core/editor/components/Toolbar/widgets/components/DropdownButton.js +27 -9
  611. package/lib/core/editor/components/Toolbar/widgets/components/DropdownMenu.js +16 -5
  612. package/lib/core/editor/components/Toolbar/widgets/components/MenuSelect.js +8 -2
  613. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/ElementTextStyleSetting.js +17 -5
  614. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/colorUtil.js +14 -2
  615. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/box.js +14 -3
  616. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/edgeTag.js +24 -6
  617. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/groupTitle.js +24 -5
  618. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/index.js +8 -0
  619. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/layerTitle.js +21 -6
  620. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/nodeTag.js +26 -7
  621. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/elements/text.js +14 -2
  622. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/ElementTextStyleSetting/textStyleUtil.js +30 -6
  623. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/GlobalTagStyleSetting/GlobalTagStyleSetting.js +14 -3
  624. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/GlobalTagStyleSetting/globalTag.js +36 -13
  625. package/lib/core/editor/components/Toolbar/widgets/components/textStyleSetting/textStyleSettingRouter.js +7 -0
  626. package/lib/core/editor/components/plugins/AddElementThemePlugin.js +5 -0
  627. package/lib/core/editor/components/plugins/CorePlugin.js +9 -3
  628. package/lib/core/editor/components/plugins/SaveLoading.js +11 -2
  629. package/lib/core/editor/components/settings/CloseablePanel.js +12 -3
  630. package/lib/core/editor/components/settings/PropertyView.js +27 -7
  631. package/lib/core/editor/components/settings/Settings.js +20 -7
  632. package/lib/core/editor/components/settings/common/AddResourceButton.js +7 -0
  633. package/lib/core/editor/components/settings/common/AlignSetting/AlignTypeList.js +25 -11
  634. package/lib/core/editor/components/settings/common/AlignSetting/index.js +18 -5
  635. package/lib/core/editor/components/settings/common/GroupNodeList/ResourceList.js +18 -2
  636. package/lib/core/editor/components/settings/common/LayoutSettings.js +24 -12
  637. package/lib/core/editor/components/settings/common/LineType/index.js +7 -0
  638. package/lib/core/editor/components/settings/common/NameInput.js +11 -1
  639. package/lib/core/editor/components/settings/common/NodeAlignType.js +8 -0
  640. package/lib/core/editor/components/settings/common/NodeSizeInput/NodeSizeInput.js +42 -9
  641. package/lib/core/editor/components/settings/common/SizeInput/NodeSizeInput.js +32 -12
  642. package/lib/core/editor/components/settings/common/SizeInput/NodeSizeNumberPicker.js +29 -10
  643. package/lib/core/editor/components/settings/common/SizeInput/index.js +3 -0
  644. package/lib/core/editor/components/settings/common/tab/TabView.js +6 -0
  645. package/lib/core/editor/components/settings/common/text/FontStyleCheckbox.js +18 -1
  646. package/lib/core/editor/components/settings/common/text/TextStyle.js +19 -2
  647. package/lib/core/editor/components/settings/common/text/fontStyleUtil.js +8 -2
  648. package/lib/core/editor/components/settings/core/PropertyViewManager.js +23 -0
  649. package/lib/core/editor/components/settings/core/edgePropertyViewAdapter.js +5 -0
  650. package/lib/core/editor/components/settings/core/getPropertyViewType.js +5 -0
  651. package/lib/core/editor/components/settings/core/updateElementProperty.js +3 -0
  652. package/lib/core/editor/components/settings/propertyViews/PropertyViewFactory.js +2 -0
  653. package/lib/core/editor/components/settings/propertyViews/box/BoxPropertyView.js +20 -3
  654. package/lib/core/editor/components/settings/propertyViews/box/BoxPropertyViewV1.js +19 -2
  655. package/lib/core/editor/components/settings/propertyViews/box/NameInput.js +19 -3
  656. package/lib/core/editor/components/settings/propertyViews/edge/CommonEdgePropertyView.js +29 -5
  657. package/lib/core/editor/components/settings/propertyViews/edge/EdgeGroupPropertyView.js +7 -0
  658. package/lib/core/editor/components/settings/propertyViews/edge/EdgePropertyView.js +16 -4
  659. package/lib/core/editor/components/settings/propertyViews/edge/edgeGroup/EdgeGroupSetting.js +19 -3
  660. package/lib/core/editor/components/settings/propertyViews/group/DataTab/GroupAddResourceButton.js +9 -2
  661. package/lib/core/editor/components/settings/propertyViews/group/DataTab/GroupNodeList.js +14 -7
  662. package/lib/core/editor/components/settings/propertyViews/group/DataTab/GroupRelateData/GroupRelateData.js +20 -4
  663. package/lib/core/editor/components/settings/propertyViews/group/DataTab/RelateData.js +10 -4
  664. package/lib/core/editor/components/settings/propertyViews/group/DataTab/hoooks/useGroupRelateResource.js +17 -11
  665. package/lib/core/editor/components/settings/propertyViews/group/GroupPropertyView.js +11 -3
  666. package/lib/core/editor/components/settings/propertyViews/group/GroupPropertyViewV1.js +13 -3
  667. package/lib/core/editor/components/settings/propertyViews/group/SettingTab/GroupBasicSetting.js +27 -7
  668. package/lib/core/editor/components/settings/propertyViews/group/SettingTab/GroupExpandSetting.js +29 -15
  669. package/lib/core/editor/components/settings/propertyViews/group/SettingTab/GroupExpandStatus.js +10 -3
  670. package/lib/core/editor/components/settings/propertyViews/group/SettingTab/GroupIconSelect.js +11 -2
  671. package/lib/core/editor/components/settings/propertyViews/group/SettingTab/Setting.js +31 -6
  672. package/lib/core/editor/components/settings/propertyViews/group/cluster/ClusterGroupRelateData.js +19 -4
  673. package/lib/core/editor/components/settings/propertyViews/group/hooks/useGroup.js +4 -0
  674. package/lib/core/editor/components/settings/propertyViews/index.js +10 -0
  675. package/lib/core/editor/components/settings/propertyViews/layer/BasicSetting.js +18 -3
  676. package/lib/core/editor/components/settings/propertyViews/layer/DataTab/DefaultLayerAddResourceDrawer.js +20 -7
  677. package/lib/core/editor/components/settings/propertyViews/layer/DataTab/LayerAddResourceButton.js +13 -4
  678. package/lib/core/editor/components/settings/propertyViews/layer/DataTab/LayerAddResourceDrawer.js +8 -2
  679. package/lib/core/editor/components/settings/propertyViews/layer/DataTab/NodeList.js +9 -1
  680. package/lib/core/editor/components/settings/propertyViews/layer/DataTab/RelateData.js +14 -4
  681. package/lib/core/editor/components/settings/propertyViews/layer/LayerPropertyView.js +13 -6
  682. package/lib/core/editor/components/settings/propertyViews/layer/LayerPropertyViewV1.js +14 -6
  683. package/lib/core/editor/components/settings/propertyViews/layer/SettingTab/Setting.js +31 -7
  684. package/lib/core/editor/components/settings/propertyViews/layer/SettingTab/Setting_bak.js +35 -16
  685. package/lib/core/editor/components/settings/propertyViews/multipleElements/BatchSetNodeIcon.js +7 -2
  686. package/lib/core/editor/components/settings/propertyViews/multipleElements/BatchSetNodeSize/BatchSetNodeSize.js +44 -13
  687. package/lib/core/editor/components/settings/propertyViews/multipleElements/MultipleElementLineType.js +7 -0
  688. package/lib/core/editor/components/settings/propertyViews/multipleElements/MultipleElementPropertyView.js +25 -7
  689. package/lib/core/editor/components/settings/propertyViews/node/NodeIconSelect.js +11 -3
  690. package/lib/core/editor/components/settings/propertyViews/node/NodeIconSelectTest.js +9 -2
  691. package/lib/core/editor/components/settings/propertyViews/node/NodePropertyView.js +17 -8
  692. package/lib/core/editor/components/settings/propertyViews/node/NodePropertyViewV1.js +22 -7
  693. package/lib/core/editor/components/settings/propertyViews/node/Setting/BasicSetting.js +19 -6
  694. package/lib/core/editor/components/settings/propertyViews/node/Setting/NameInput.js +19 -3
  695. package/lib/core/editor/components/settings/propertyViews/node/Setting/Setting.js +26 -6
  696. package/lib/core/editor/components/settings/propertyViews/node/Setting/index.js +3 -0
  697. package/lib/core/editor/components/settings/propertyViews/node/TopoTreeSelect.js +8 -0
  698. package/lib/core/editor/components/settings/propertyViews/node/data/BindIpInput.js +32 -18
  699. package/lib/core/editor/components/settings/propertyViews/node/data/BindResourceDrawer.js +25 -7
  700. package/lib/core/editor/components/settings/propertyViews/node/data/Data.js +47 -19
  701. package/lib/core/editor/components/settings/propertyViews/node/data/NodeRelateResourceButton.js +19 -6
  702. package/lib/core/editor/components/settings/propertyViews/node/data/PlatformDisplay.js +7 -1
  703. package/lib/core/editor/components/settings/propertyViews/text/TextPropertyView.js +29 -5
  704. package/lib/core/editor/components/settings/propertyViews/view/BackgroundSize.js +18 -5
  705. package/lib/core/editor/components/settings/propertyViews/view/BatchSetNodeSize.js +9 -3
  706. package/lib/core/editor/components/settings/propertyViews/view/GlobalEdgeToggle.js +15 -4
  707. package/lib/core/editor/components/settings/propertyViews/view/GlobalLayout.js +12 -5
  708. package/lib/core/editor/components/settings/propertyViews/view/GlobalNodeLabelStyle.js +17 -2
  709. package/lib/core/editor/components/settings/propertyViews/view/ViewLineTypeSetting.js +8 -0
  710. package/lib/core/editor/components/settings/propertyViews/view/ViewPropertyView.js +19 -3
  711. package/lib/core/editor/components/settings/propertyViews/view/ViewPropertyViewV2.js +11 -3
  712. package/lib/core/editor/components/settings/propertyViews/view/hooks/useBackgroundConfig.js +6 -3
  713. package/lib/core/editor/components/settings/propertyViews/view/hooks/useBackgroundSizeConfig.js +19 -4
  714. package/lib/core/editor/components/settings/useSettingRuntimeState.js +10 -2
  715. package/lib/core/editor/components/titlebar/TopoEditorTitleBar.js +42 -12
  716. package/lib/core/editor/components/titlebar/widgets/DebugTools.js +8 -1
  717. package/lib/core/editor/components/titlebar/widgets/SaveButton.js +5 -0
  718. package/lib/core/editor/config/themes.js +10 -8
  719. package/lib/core/editor/contextmenu/buildContextmenu.js +2 -2
  720. package/lib/core/editor/hooks/useKeyboardShortcut.js +14 -7
  721. package/lib/core/editor/hooks/useLayerAddResource.js +8 -4
  722. package/lib/core/editor/hooks/useNewElementTheme.js +20 -7
  723. package/lib/core/editor/hooks/useUpdateHtTopoDefaultTagStyle.js +6 -1
  724. package/lib/core/editor/store/background.js +16 -6
  725. package/lib/core/editor/store/historyManager.js +6 -1
  726. package/lib/core/editor/store/topoEdit.js +13 -5
  727. package/lib/core/editor/utils/edgeTypeStyleUtil.js +22 -9
  728. package/lib/core/editor/utils/themeUtil.js +6 -0
  729. package/lib/core/event/topoEventListener.js +3 -0
  730. package/lib/core/hooks/ht/useHtDataPropertyChangeListener.js +11 -3
  731. package/lib/core/hooks/useAlarm.js +33 -11
  732. package/lib/core/hooks/useCanvasTheme.js +16 -9
  733. package/lib/core/hooks/useCanvasThemeConfig.js +8 -2
  734. package/lib/core/hooks/useCiAttributeChange.js +14 -3
  735. package/lib/core/hooks/useEventData.js +7 -2
  736. package/lib/core/hooks/useGraphAlarmDisplay.js +34 -11
  737. package/lib/core/hooks/useGroupAddResource.js +7 -2
  738. package/lib/core/hooks/useManageStatus.js +6 -1
  739. package/lib/core/hooks/usePolling.js +74 -32
  740. package/lib/core/hooks/useResourceConfig.js +66 -22
  741. package/lib/core/hooks/useRouterAdapter.js +6 -1
  742. package/lib/core/hooks/useSelection.js +5 -1
  743. package/lib/core/hooks/useTopoEdit.js +301 -112
  744. package/lib/core/hooks/useTopoEventListener.js +4 -1
  745. package/lib/core/hooks/useTopoFullscreen.js +12 -7
  746. package/lib/core/index.js +2 -0
  747. package/lib/core/models/Alarm.js +159 -49
  748. package/lib/core/models/AttributeMetricDisplay.js +173 -89
  749. package/lib/core/models/DataModel.js +39 -4
  750. package/lib/core/models/EdgeGroup.js +8 -2
  751. package/lib/core/models/GraphDataModel.js +8 -0
  752. package/lib/core/models/HistoryManager.js +64 -21
  753. package/lib/core/models/PluginManager.js +11 -0
  754. package/lib/core/models/SelectionModel.js +44 -11
  755. package/lib/core/models/TopoApp.js +204 -72
  756. package/lib/core/models/TopoGraphView.js +35 -7
  757. package/lib/core/models/TopoViewer.js +7 -0
  758. package/lib/core/models/attributeFormatter/formatter/attributeTransform.js +3 -0
  759. package/lib/core/models/attributeFormatter/formatter/ciTypeAttrTransform.js +4 -2
  760. package/lib/core/models/attributeFormatter/formatter/commonTransform.js +10 -6
  761. package/lib/core/models/attributeFormatter/formatter/graphTransform.js +8 -2
  762. package/lib/core/models/attributeFormatter/formatter/metricTransform.js +3 -0
  763. package/lib/core/models/attributeFormatter/index.js +14 -0
  764. package/lib/core/models/cache/CiCache.js +22 -3
  765. package/lib/core/models/cache/CiTypeCache.js +43 -7
  766. package/lib/core/models/cache/DictCache.js +29 -3
  767. package/lib/core/models/common/ContextMenu.js +10 -0
  768. package/lib/core/models/graph/Background.js +19 -3
  769. package/lib/core/models/plugins/index.js +1 -2
  770. package/lib/core/models/plugins/resourceWebControllUrl.js +47 -9
  771. package/lib/core/models/tagstips/ElementTagTipConfig.js +64 -15
  772. package/lib/core/models/tagstips/utils.js +9 -3
  773. package/lib/core/models/topoData.js +36 -8
  774. package/lib/core/models/topoFactory.js +6 -0
  775. package/lib/core/models/utils/getRelationDetailByIds.js +1 -0
  776. package/lib/core/models/utils/linkUtils.js +48 -19
  777. package/lib/core/models/utils/nodeNameVisibleUtil.js +30 -15
  778. package/lib/core/services/alarm.js +14 -3
  779. package/lib/core/services/background.js +29 -9
  780. package/lib/core/services/cmdb/metric.js +10 -3
  781. package/lib/core/services/cmdb.js +12 -3
  782. package/lib/core/services/index.js +24 -7
  783. package/lib/core/services/overview.js +63 -23
  784. package/lib/core/services/topo/basic.js +11 -3
  785. package/lib/core/services/topo/index.js +6 -0
  786. package/lib/core/services/topo/tagtip.js +11 -3
  787. package/lib/core/store/coreModels.js +16 -0
  788. package/lib/core/store/createStore.js +7 -0
  789. package/lib/core/store/models/ciModel.js +23 -5
  790. package/lib/core/store/models/customIcon.js +72 -21
  791. package/lib/core/store/models/displayConfig.js +21 -7
  792. package/lib/core/store/models/selection.js +13 -6
  793. package/lib/core/store/models/topoAlarm.js +52 -12
  794. package/lib/core/store/models/topoBaseInfoOverview.js +14 -6
  795. package/lib/core/store/models/topoBizMod.js +22 -5
  796. package/lib/core/store/models/topoConfig.js +109 -41
  797. package/lib/core/store/models/topoGraphView.js +16 -7
  798. package/lib/core/store/models/topoMod.js +131 -36
  799. package/lib/core/store/models/viewer/lock.js +4 -0
  800. package/lib/core/store/models/viewer/resourceDetail.js +8 -2
  801. package/lib/core/store/models/viewer/resourceWebControllUrlSetting.js +5 -0
  802. package/lib/core/test/Test.js +14 -10
  803. package/lib/core/upgrade/v140UpgradeSerializeNodeImageSize.js +6 -0
  804. package/lib/core/utils/backgroundUtil.js +9 -5
  805. package/lib/core/utils/edgeUtil.js +17 -3
  806. package/lib/core/utils/graphLinkUtil.js +9 -4
  807. package/lib/core/utils/imageUtil.js +12 -3
  808. package/lib/core/utils/linkUtil.js +1 -0
  809. package/lib/core/utils/manageStatusUtil.js +1 -0
  810. package/lib/core/utils/metricUtil.js +4 -0
  811. package/lib/core/utils/resourceUtil.js +4 -2
  812. package/lib/core/utils/saveSerialize.js +9 -3
  813. package/lib/core/utils/showGraphManageStatusUtil.js +23 -14
  814. package/lib/core/utils/showMessage.js +9 -0
  815. package/lib/core/viewer/components/plugins/ElementDetailDrawer/components/DetailDrawer.js +7 -0
  816. package/lib/core/viewer/components/plugins/ElementDetailDrawer/hooks/useElementDetailManager.js +64 -32
  817. package/lib/core/viewer/components/plugins/MetricPollingPlugin.js +4 -0
  818. package/lib/core/viewer/components/plugins/ResourceDetail/DefaultDetailContent.js +23 -8
  819. package/lib/core/viewer/components/plugins/ResourceDetail/ResourceDetail.js +20 -6
  820. package/lib/core/viewer/components/plugins/ResourceDetail/ResourceDetailDrawer.js +21 -9
  821. package/lib/core/viewer/components/plugins/ResourceDetail/ResourceDetailPlugin.js +11 -2
  822. package/lib/core/viewer/components/plugins/ResourceDetail/components/ClusterMemberTable.js +36 -10
  823. package/lib/core/viewer/components/plugins/ResourceDetail/components/DrawerTitle.js +24 -7
  824. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/BaseInfo.js +24 -15
  825. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/BaseInfoBlock.js +17 -10
  826. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/BlockBox.js +7 -2
  827. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/EventsCard.js +29 -10
  828. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/NetworkBaseInfo.js +36 -17
  829. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverview.js +229 -88
  830. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverviewMetric.js +40 -25
  831. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/SingleResourceStrategyLink.js +8 -5
  832. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/Configurator/index.js +87 -32
  833. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/LinkTopo.js +12 -2
  834. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/LinkTopoCard.js +38 -13
  835. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/constants.js +4 -8
  836. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/hooks/useMetricPolling.js +31 -12
  837. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/services/index.js +83 -19
  838. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useAlarmAndRiskData.js +44 -23
  839. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useMetricModels.js +49 -21
  840. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/index.js +3 -0
  841. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/useCiAttrAndMetricData.js +5 -2
  842. package/lib/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleContainer.js +8 -1
  843. package/lib/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleForm/WebConsoleForm.js +27 -8
  844. package/lib/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleForm/hooks/useWebConsole.js +33 -10
  845. package/lib/core/viewer/components/plugins/ResourceDetail/getCiDisplayMetricModels.js +17 -5
  846. package/lib/core/viewer/components/plugins/ResourceDetail/hooks/useUserId.js +23 -7
  847. package/lib/core/viewer/components/plugins/ResourceDetail/index.js +3 -0
  848. package/lib/core/viewer/components/plugins/ResourceWebControllUrlSettingDialog.js +33 -6
  849. package/lib/core/viewer/components/plugins/ViewerPlugin.js +9 -1
  850. package/lib/core/viewer/components/titlebar/BasicTools.js +12 -3
  851. package/lib/core/viewer/components/titlebar/TopoViewerTitleBar.js +14 -4
  852. package/lib/core/viewer/components/titlebar/ViewerTools.js +5 -0
  853. package/lib/core/viewer/components/titlebar/widgets/AlarmButton.js +11 -2
  854. package/lib/core/viewer/components/titlebar/widgets/AlarmListShowButton.js +28 -15
  855. package/lib/core/viewer/components/titlebar/widgets/EditButton.js +14 -3
  856. package/lib/core/viewer/components/titlebar/widgets/MoreButtonMenu.js +10 -1
  857. package/lib/core/viewer/components/titlebar/widgets/NodesDragSwitch.js +26 -13
  858. package/lib/core/viewer/components/titlebar/widgets/NodesDragSwitchWrapper.js +10 -1
  859. package/lib/core/viewer/components/titlebar/widgets/SearchWidget.js +25 -9
  860. package/lib/core/viewer/components/titlebar/widgets/SettingButton.js +18 -6
  861. package/lib/core/viewer/components/titlebar/widgets/SettingButtonWidget.js +9 -4
  862. package/lib/core/viewer/contextmenu/buildContextmenu.js +5 -0
  863. package/lib/core/viewer/contextmenu/buildLinkContextmenu.js +2 -2
  864. package/lib/core/viewer/contextmenu/buildNodeContextmenu.js +3 -8
  865. package/lib/core/viewer/contextmenu/buildViewContextmenu.js +1 -0
  866. package/lib/createTopo.js +8 -2
  867. package/lib/index.js +19 -0
  868. package/lib/mock/mock.js +4 -5
  869. package/lib/networkTopo/components/Link/form.js +57 -25
  870. package/lib/networkTopo/components/Link/hook.js +100 -48
  871. package/lib/networkTopo/components/Link/index.js +77 -32
  872. package/lib/networkTopo/components/Link/setting.js +86 -45
  873. package/lib/networkTopo/components/Topo404.js +9 -0
  874. package/lib/networkTopo/components/TopoNoPermission.js +9 -0
  875. package/lib/networkTopo/components/TopoView.js +37 -13
  876. package/lib/networkTopo/createTopo.js +6 -0
  877. package/lib/networkTopo/getTopoData.js +43 -16
  878. package/lib/networkTopo/hooks/useEdgeExpand.js +6 -1
  879. package/lib/networkTopo/hooks/useGroupResources.js +5 -2
  880. package/lib/networkTopo/hooks/useLinkDynamicStyle.js +7 -1
  881. package/lib/networkTopo/hooks/viewer/useEdgeFlow.js +8 -5
  882. package/lib/networkTopo/hooks/viewer/useRelateTopo.js +31 -7
  883. package/lib/networkTopo/index.js +7 -0
  884. package/lib/networkTopo/models/EdgeGroupTagTipBuilder.js +12 -2
  885. package/lib/networkTopo/models/ExtElementTagTipBuilder.js +8 -0
  886. package/lib/networkTopo/models/IpNodeTagsTipsBuilder.js +15 -2
  887. package/lib/networkTopo/models/LinkDynamicStyleExecutor.js +54 -26
  888. package/lib/networkTopo/models/LinkTagsTipsBuilder.js +55 -40
  889. package/lib/networkTopo/models/TopoCenter.js +39 -8
  890. package/lib/networkTopo/services/alert.js +15 -5
  891. package/lib/networkTopo/services/authorization.js +35 -16
  892. package/lib/networkTopo/services/cmdb.js +211 -72
  893. package/lib/networkTopo/services/funcAuth.js +10 -3
  894. package/lib/networkTopo/services/index.js +7 -0
  895. package/lib/networkTopo/services/link.js +47 -11
  896. package/lib/networkTopo/services/mdc.js +26 -9
  897. package/lib/networkTopo/services/metric.js +20 -6
  898. package/lib/networkTopo/services/model.js +291 -89
  899. package/lib/networkTopo/services/risk.js +10 -3
  900. package/lib/networkTopo/services/topo/auth.js +19 -7
  901. package/lib/networkTopo/services/topo/basic.js +154 -57
  902. package/lib/networkTopo/services/topo/blacklist.js +17 -5
  903. package/lib/networkTopo/services/topo/ciInfo.js +20 -5
  904. package/lib/networkTopo/services/topo/icon.js +30 -11
  905. package/lib/networkTopo/services/topo/index.js +15 -0
  906. package/lib/networkTopo/services/topo/networkLink.js +17 -5
  907. package/lib/networkTopo/services/topo/relation.js +11 -3
  908. package/lib/networkTopo/services/topo/resourceWebUrl.js +25 -9
  909. package/lib/networkTopo/store/functionAuth.js +24 -9
  910. package/lib/networkTopo/store/index.js +6 -0
  911. package/lib/networkTopo/store/topoCenter.js +63 -22
  912. package/lib/networkTopo/store/topoLinkMod.js +12 -5
  913. package/lib/networkTopo/store/topoTreeMod.js +83 -19
  914. package/lib/networkTopo/utils/SortResourcesUtil.js +4 -1
  915. package/lib/networkTopo/utils/__tests__/resourcePermissionUtil.test.js +7 -4
  916. package/lib/networkTopo/utils/edgeGroupTagUtil.js +19 -7
  917. package/lib/networkTopo/utils/exitLinkUtil.js +58 -38
  918. package/lib/networkTopo/utils/exportData.js +25 -10
  919. package/lib/networkTopo/utils/linPermissionUtil.js +3 -3
  920. package/lib/networkTopo/utils/linkUtil.js +2 -0
  921. package/lib/networkTopo/utils/resourcePermissionUtil.js +14 -4
  922. package/lib/networkTopo/utils/storage.js +5 -3
  923. package/lib/networkTopo/viewer/components/TitleBar.js +6 -0
  924. package/lib/networkTopo/viewer/components/TopologyViewer.js +12 -3
  925. package/lib/networkTopo/viewer/createTopoViewer.js +5 -0
  926. package/lib/networkTopo/viewer/index.js +9 -0
  927. package/lib/utils/ResourceConfigUtil.js +31 -17
  928. package/lib/utils/SpecialCharacterValidateUtil.js +2 -0
  929. package/lib/utils/ciType.js +7 -1
  930. package/lib/utils/clusterUtil.js +35 -15
  931. package/lib/utils/copyUtil.js +2 -0
  932. package/lib/utils/format.js +38 -12
  933. package/lib/utils/htElementDataUtil.js +12 -0
  934. package/lib/utils/htElementUtils.js +87 -26
  935. package/lib/utils/listToTree.js +3 -0
  936. package/lib/utils/resourceElementUtil.js +2 -0
  937. package/lib/utils/template.js +7 -6
  938. package/lib/utils/topoData.js +97 -51
  939. package/lib/utils/topoMocks.js +4 -3
  940. package/lib/utils/topoPermissionUtil.js +1 -0
  941. package/lib/utils/tree.js +46 -14
  942. package/lib/utils/treeUtil.js +3 -0
  943. package/package.json +3 -3
package/build/2.js CHANGED
@@ -1,2 +1,2 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[2],{1463:function(e,t,n){
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[2],{1529:function(e,t,n){
2
2
  /*! @license DOMPurify 2.3.3 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.3.3/LICENSE */var r,o;r=this,o=function(){"use strict";function e(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var t=Object.hasOwnProperty,n=Object.setPrototypeOf,r=Object.isFrozen,o=Object.getPrototypeOf,i=Object.getOwnPropertyDescriptor,a=Object.freeze,l=Object.seal,c=Object.create,s="undefined"!=typeof Reflect&&Reflect,u=s.apply,m=s.construct;u||(u=function e(t,n,r){return t.apply(n,r)}),a||(a=function e(t){return t}),l||(l=function e(t){return t}),m||(m=function t(n,r){return new(Function.prototype.bind.apply(n,[null].concat(e(r))))});var f=x(Array.prototype.forEach),p=x(Array.prototype.pop),d=x(Array.prototype.push),h=x(String.prototype.toLowerCase),g=x(String.prototype.match),y=x(String.prototype.replace),v=x(String.prototype.indexOf),b=x(String.prototype.trim),T=x(RegExp.prototype.test),A=w(TypeError);function x(e){return function(t){for(var n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return u(e,t,r)}}function w(e){return function(){for(var t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];return m(e,n)}}function S(e,t){n&&n(e,null);for(var o=t.length;o--;){var i=t[o];if("string"==typeof i){var a=h(i);a!==i&&(r(t)||(t[o]=a),i=a)}e[i]=!0}return e}function E(e){var n=c(null),r=void 0;for(r in e)u(t,e,[r])&&(n[r]=e[r]);return n}function R(e,t){for(;null!==e;){var n=i(e,t);if(n){if(n.get)return x(n.get);if("function"==typeof n.value)return x(n.value)}e=o(e)}function r(e){return console.warn("fallback value for",e),null}return r}var _=a(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),k=a(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),N=a(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),D=a(["animate","color-profile","cursor","discard","fedropshadow","feimage","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),O=a(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),M=a(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),L=a(["#text"]),F=a(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),I=a(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),C=a(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),z=a(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),H=l(/\{\{[\s\S]*|[\s\S]*\}\}/gm),U=l(/<%[\s\S]*|[\s\S]*%>/gm),P=l(/^data-[\-\w.\u00B7-\uFFFF]/),B=l(/^aria-[\-\w]+$/),j=l(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),W=l(/^(?:\w+script|data):/i),G=l(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),q="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function Y(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var K=function e(){return"undefined"==typeof window?null:window},V=function e(t,n){if("object"!==(void 0===t?"undefined":q(t))||"function"!=typeof t.createPolicy)return null;var r=null,o="data-tt-policy-suffix";n.currentScript&&n.currentScript.hasAttribute(o)&&(r=n.currentScript.getAttribute(o));var i="dompurify"+(r?"#"+r:"");try{return t.createPolicy(i,{createHTML:function e(t){return t}})}catch(e){return console.warn("TrustedTypes policy "+i+" could not be created."),null}},J;function X(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:K(),t=function e(t){return X(t)};if(t.version="2.3.3",t.removed=[],!e||!e.document||9!==e.document.nodeType)return t.isSupported=!1,t;var n=e.document,r=e.document,o=e.DocumentFragment,i=e.HTMLTemplateElement,l=e.Node,c=e.Element,s=e.NodeFilter,u=e.NamedNodeMap,m=void 0===u?e.NamedNodeMap||e.MozNamedAttrMap:u,x=e.Text,w=e.Comment,J=e.DOMParser,$=e.trustedTypes,Z=c.prototype,Q=R(Z,"cloneNode"),ee=R(Z,"nextSibling"),te=R(Z,"childNodes"),ne=R(Z,"parentNode");if("function"==typeof i){var re=r.createElement("template");re.content&&re.content.ownerDocument&&(r=re.content.ownerDocument)}var oe=V($,n),ie=oe&&ze?oe.createHTML(""):"",ae=r,le=ae.implementation,ce=ae.createNodeIterator,se=ae.createDocumentFragment,ue=ae.getElementsByTagName,me=n.importNode,fe={};try{fe=E(r).documentMode?r.documentMode:{}}catch(e){}var pe={};t.isSupported="function"==typeof ne&&le&&void 0!==le.createHTMLDocument&&9!==fe;var de=H,he=U,ge=P,ye=B,ve=W,be=G,Te=j,Ae=null,xe=S({},[].concat(Y(_),Y(k),Y(N),Y(O),Y(L))),we=null,Se=S({},[].concat(Y(F),Y(I),Y(C),Y(z))),Ee=null,Re=null,_e=!0,ke=!0,Ne=!1,De=!1,Oe=!1,Me=!1,Le=!1,Fe=!1,Ie=!1,Ce=!0,ze=!1,He=!0,Ue=!0,Pe=!1,Be={},je=null,We=S({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),Ge=null,qe=S({},["audio","video","img","source","image","track"]),Ye=null,Ke=S({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Ve="http://www.w3.org/1998/Math/MathML",Je="http://www.w3.org/2000/svg",Xe="http://www.w3.org/1999/xhtml",$e=Xe,Ze=!1,Qe=void 0,et=["application/xhtml+xml","text/html"],tt="text/html",nt=void 0,rt=null,ot=r.createElement("form"),it=function e(t){rt&&rt===t||(t&&"object"===(void 0===t?"undefined":q(t))||(t={}),t=E(t),Ae="ALLOWED_TAGS"in t?S({},t.ALLOWED_TAGS):xe,we="ALLOWED_ATTR"in t?S({},t.ALLOWED_ATTR):Se,Ye="ADD_URI_SAFE_ATTR"in t?S(E(Ke),t.ADD_URI_SAFE_ATTR):Ke,Ge="ADD_DATA_URI_TAGS"in t?S(E(qe),t.ADD_DATA_URI_TAGS):qe,je="FORBID_CONTENTS"in t?S({},t.FORBID_CONTENTS):We,Ee="FORBID_TAGS"in t?S({},t.FORBID_TAGS):{},Re="FORBID_ATTR"in t?S({},t.FORBID_ATTR):{},Be="USE_PROFILES"in t&&t.USE_PROFILES,_e=!1!==t.ALLOW_ARIA_ATTR,ke=!1!==t.ALLOW_DATA_ATTR,Ne=t.ALLOW_UNKNOWN_PROTOCOLS||!1,De=t.SAFE_FOR_TEMPLATES||!1,Oe=t.WHOLE_DOCUMENT||!1,Fe=t.RETURN_DOM||!1,Ie=t.RETURN_DOM_FRAGMENT||!1,Ce=!1!==t.RETURN_DOM_IMPORT,ze=t.RETURN_TRUSTED_TYPE||!1,Le=t.FORCE_BODY||!1,He=!1!==t.SANITIZE_DOM,Ue=!1!==t.KEEP_CONTENT,Pe=t.IN_PLACE||!1,Te=t.ALLOWED_URI_REGEXP||Te,$e=t.NAMESPACE||Xe,Qe=Qe=-1===et.indexOf(t.PARSER_MEDIA_TYPE)?tt:t.PARSER_MEDIA_TYPE,nt="application/xhtml+xml"===Qe?function(e){return e}:h,De&&(ke=!1),Ie&&(Fe=!0),Be&&(Ae=S({},[].concat(Y(L))),we=[],!0===Be.html&&(S(Ae,_),S(we,F)),!0===Be.svg&&(S(Ae,k),S(we,I),S(we,z)),!0===Be.svgFilters&&(S(Ae,N),S(we,I),S(we,z)),!0===Be.mathMl&&(S(Ae,O),S(we,C),S(we,z))),t.ADD_TAGS&&(Ae===xe&&(Ae=E(Ae)),S(Ae,t.ADD_TAGS)),t.ADD_ATTR&&(we===Se&&(we=E(we)),S(we,t.ADD_ATTR)),t.ADD_URI_SAFE_ATTR&&S(Ye,t.ADD_URI_SAFE_ATTR),t.FORBID_CONTENTS&&(je===We&&(je=E(je)),S(je,t.FORBID_CONTENTS)),Ue&&(Ae["#text"]=!0),Oe&&S(Ae,["html","head","body"]),Ae.table&&(S(Ae,["tbody"]),delete Ee.tbody),a&&a(t),rt=t)},at=S({},["mi","mo","mn","ms","mtext"]),lt=S({},["foreignobject","desc","title","annotation-xml"]),ct=S({},k);S(ct,N),S(ct,D);var st=S({},O);S(st,M);var ut=function e(t){var n=ne(t);n&&n.tagName||(n={namespaceURI:Xe,tagName:"template"});var r=h(t.tagName),o=h(n.tagName);if(t.namespaceURI===Je)return n.namespaceURI===Xe?"svg"===r:n.namespaceURI===Ve?"svg"===r&&("annotation-xml"===o||at[o]):Boolean(ct[r]);if(t.namespaceURI===Ve)return n.namespaceURI===Xe?"math"===r:n.namespaceURI===Je?"math"===r&&lt[o]:Boolean(st[r]);if(t.namespaceURI===Xe){if(n.namespaceURI===Je&&!lt[o])return!1;if(n.namespaceURI===Ve&&!at[o])return!1;var i=S({},["title","style","font","a","script"]);return!st[r]&&(i[r]||!ct[r])}return!1},mt=function e(n){d(t.removed,{element:n});try{n.parentNode.removeChild(n)}catch(e){try{n.outerHTML=ie}catch(e){n.remove()}}},ft=function e(n,r){try{d(t.removed,{attribute:r.getAttributeNode(n),from:r})}catch(e){d(t.removed,{attribute:null,from:r})}if(r.removeAttribute(n),"is"===n&&!we[n])if(Fe||Ie)try{mt(r)}catch(e){}else try{r.setAttribute(n,"")}catch(e){}},pt=function e(t){var n=void 0,o=void 0;if(Le)t="<remove></remove>"+t;else{var i=g(t,/^[\r\n\t ]+/);o=i&&i[0]}"application/xhtml+xml"===Qe&&(t='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+t+"</body></html>");var a=oe?oe.createHTML(t):t;if($e===Xe)try{n=(new J).parseFromString(a,Qe)}catch(e){}if(!n||!n.documentElement){n=le.createDocument($e,"template",null);try{n.documentElement.innerHTML=Ze?"":a}catch(e){}}var l=n.body||n.documentElement;return t&&o&&l.insertBefore(r.createTextNode(o),l.childNodes[0]||null),$e===Xe?ue.call(n,Oe?"html":"body")[0]:Oe?n.documentElement:l},dt=function e(t){return ce.call(t.ownerDocument||t,t,s.SHOW_ELEMENT|s.SHOW_COMMENT|s.SHOW_TEXT,null,!1)},ht=function e(t){return!(t instanceof x||t instanceof w||"string"==typeof t.nodeName&&"string"==typeof t.textContent&&"function"==typeof t.removeChild&&t.attributes instanceof m&&"function"==typeof t.removeAttribute&&"function"==typeof t.setAttribute&&"string"==typeof t.namespaceURI&&"function"==typeof t.insertBefore)},gt=function e(t){return"object"===(void 0===l?"undefined":q(l))?t instanceof l:t&&"object"===(void 0===t?"undefined":q(t))&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName},yt=function e(n,r,o){pe[n]&&f(pe[n],(function(e){e.call(t,r,o,rt)}))},vt=function e(n){var r=void 0;if(yt("beforeSanitizeElements",n,null),ht(n))return mt(n),!0;if(g(n.nodeName,/[\u0080-\uFFFF]/))return mt(n),!0;var o=nt(n.nodeName);if(yt("uponSanitizeElement",n,{tagName:o,allowedTags:Ae}),!gt(n.firstElementChild)&&(!gt(n.content)||!gt(n.content.firstElementChild))&&T(/<[/\w]/g,n.innerHTML)&&T(/<[/\w]/g,n.textContent))return mt(n),!0;if("select"===o&&T(/<template/i,n.innerHTML))return mt(n),!0;if(!Ae[o]||Ee[o]){if(Ue&&!je[o]){var i=ne(n)||n.parentNode,a=te(n)||n.childNodes;if(a&&i)for(var l,s=a.length-1;s>=0;--s)i.insertBefore(Q(a[s],!0),ee(n))}return mt(n),!0}return n instanceof c&&!ut(n)?(mt(n),!0):"noscript"!==o&&"noembed"!==o||!T(/<\/no(script|embed)/i,n.innerHTML)?(De&&3===n.nodeType&&(r=n.textContent,r=y(r,de," "),r=y(r,he," "),n.textContent!==r&&(d(t.removed,{element:n.cloneNode()}),n.textContent=r)),yt("afterSanitizeElements",n,null),!1):(mt(n),!0)},bt=function e(t,n,o){if(He&&("id"===n||"name"===n)&&(o in r||o in ot))return!1;if(ke&&!Re[n]&&T(ge,n));else if(_e&&T(ye,n));else{if(!we[n]||Re[n])return!1;if(Ye[n]);else if(T(Te,y(o,be,"")));else if("src"!==n&&"xlink:href"!==n&&"href"!==n||"script"===t||0!==v(o,"data:")||!Ge[t])if(Ne&&!T(ve,y(o,be,"")));else if(o)return!1}return!0},Tt=function e(n){var r=void 0,o=void 0,i=void 0,a=void 0;yt("beforeSanitizeAttributes",n,null);var l=n.attributes;if(l){var c={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:we};for(a=l.length;a--;){var s=r=l[a],u=s.name,m=s.namespaceURI;if(o=b(r.value),i=nt(u),c.attrName=i,c.attrValue=o,c.keepAttr=!0,c.forceKeepAttr=void 0,yt("uponSanitizeAttribute",n,c),o=c.attrValue,!c.forceKeepAttr&&(ft(u,n),c.keepAttr))if(T(/\/>/i,o))ft(u,n);else{De&&(o=y(o,de," "),o=y(o,he," "));var f=nt(n.nodeName);if(bt(f,i,o))try{m?n.setAttributeNS(m,u,o):n.setAttribute(u,o),p(t.removed)}catch(e){}}}yt("afterSanitizeAttributes",n,null)}},At=function e(t){var n=void 0,r=dt(t);for(yt("beforeSanitizeShadowDOM",t,null);n=r.nextNode();)yt("uponSanitizeShadowNode",n,null),vt(n)||(n.content instanceof o&&e(n.content),Tt(n));yt("afterSanitizeShadowDOM",t,null)};return t.sanitize=function(r,i){var a=void 0,c=void 0,s=void 0,u=void 0,m=void 0;if((Ze=!r)&&(r="\x3c!--\x3e"),"string"!=typeof r&&!gt(r)){if("function"!=typeof r.toString)throw A("toString is not a function");if("string"!=typeof(r=r.toString()))throw A("dirty is not a string, aborting")}if(!t.isSupported){if("object"===q(e.toStaticHTML)||"function"==typeof e.toStaticHTML){if("string"==typeof r)return e.toStaticHTML(r);if(gt(r))return e.toStaticHTML(r.outerHTML)}return r}if(Me||it(i),t.removed=[],"string"==typeof r&&(Pe=!1),Pe);else if(r instanceof l)1===(c=(a=pt("\x3c!----\x3e")).ownerDocument.importNode(r,!0)).nodeType&&"BODY"===c.nodeName||"HTML"===c.nodeName?a=c:a.appendChild(c);else{if(!Fe&&!De&&!Oe&&-1===r.indexOf("<"))return oe&&ze?oe.createHTML(r):r;if(!(a=pt(r)))return Fe?null:ie}a&&Le&&mt(a.firstChild);for(var f=dt(Pe?r:a);s=f.nextNode();)3===s.nodeType&&s===u||vt(s)||(s.content instanceof o&&At(s.content),Tt(s),u=s);if(u=null,Pe)return r;if(Fe){if(Ie)for(m=se.call(a.ownerDocument);a.firstChild;)m.appendChild(a.firstChild);else m=a;return Ce&&(m=me.call(n,m,!0)),m}var p=Oe?a.outerHTML:a.innerHTML;return De&&(p=y(p,de," "),p=y(p,he," ")),oe&&ze?oe.createHTML(p):p},t.setConfig=function(e){it(e),Me=!0},t.clearConfig=function(){rt=null,Me=!1},t.isValidAttribute=function(e,t,n){rt||it({});var r=nt(e),o=nt(t);return bt(r,o,n)},t.addHook=function(e,t){"function"==typeof t&&(pe[e]=pe[e]||[],d(pe[e],t))},t.removeHook=function(e){pe[e]&&p(pe[e])},t.removeHooks=function(e){pe[e]&&(pe[e]=[])},t.removeAllHooks=function(){pe={}},t}return X()},e.exports=o()}}]);