@riil-frontend/component-topology 10.0.58 → 10.0.59

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 (225) 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 +52 -45
  5. package/es/components/IndexSettingDrawer/index.js +6 -5
  6. package/es/components/MultiResourceDrawer/index.js +22 -26
  7. package/es/components/ResourceList/ResourceSelect.js +55 -58
  8. package/es/components/ResourceSelectDrawer/ResourceSelectDrawer.js +30 -34
  9. package/es/components/SingleResourceDrawer/SelectDrawer.js +24 -28
  10. package/es/core/components/DisplaySettingDrawer/DisplaySettingDrawer.js +29 -33
  11. package/es/core/components/DisplaySettingDrawer/ResourceDisplay/useElementTagTipConfig.js +78 -100
  12. package/es/core/components/DisplaySettingDrawer/hooks/useDisplaySetting.js +92 -108
  13. package/es/core/components/titlebar/widgets/TitleWidget.js +5 -4
  14. package/es/core/editor/components/BackgroundView/UploadDialog/index.js +17 -18
  15. package/es/core/editor/components/BackgroundView/index.js +149 -178
  16. package/es/core/editor/components/CustomIconPlugin/RenameDialog.js +26 -30
  17. package/es/core/editor/components/CustomIconPlugin/UploadIconDialog.js +33 -34
  18. package/es/core/editor/components/CustomIconPlugin/utils/svgToShape.js +20 -24
  19. package/es/core/editor/components/GroupAddResourceDrawerPlugin/GroupAddResourceDrawer.js +13 -17
  20. package/es/core/editor/components/Sidebar/views/CanvasPanel/hooks/useCanvasThemeConfig.js +45 -56
  21. package/es/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundSetting.js +60 -70
  22. package/es/core/editor/components/Toolbar/widgets/FontColorButton.js +60 -70
  23. package/es/core/editor/components/settings/propertyViews/layer/DataTab/DefaultLayerAddResourceDrawer.js +17 -21
  24. package/es/core/editor/components/settings/propertyViews/node/data/BindResourceDrawer.js +27 -31
  25. package/es/core/editor/components/settings/propertyViews/node/data/Data.js +21 -25
  26. package/es/core/editor/components/settings/propertyViews/view/BackgroundSize.js +16 -20
  27. package/es/core/editor/components/titlebar/TopoEditorTitleBar.js +37 -55
  28. package/es/core/editor/hooks/useKeyboardShortcut.js +2 -2
  29. package/es/core/editor/hooks/useNewElementTheme.js +2 -2
  30. package/es/core/editor/store/background.js +8 -10
  31. package/es/core/editor/store/topoEdit.js +4 -6
  32. package/es/core/editor/utils/edgeTypeStyleUtil.js +2 -4
  33. package/es/core/hooks/usePolling.js +110 -122
  34. package/es/core/hooks/useResourceConfig.js +76 -100
  35. package/es/core/hooks/useTopoEdit.js +539 -638
  36. package/es/core/models/Alarm.js +311 -394
  37. package/es/core/models/AttributeMetricDisplay.js +115 -143
  38. package/es/core/models/PluginManager.js +4 -3
  39. package/es/core/models/SelectionModel.js +4 -5
  40. package/es/core/models/TopoApp.js +287 -454
  41. package/es/core/models/TopoGraphView.js +28 -41
  42. package/es/core/models/cache/CiCache.js +34 -39
  43. package/es/core/models/cache/CiTypeCache.js +70 -84
  44. package/es/core/models/cache/DictCache.js +36 -42
  45. package/es/core/models/graph/Background.js +21 -26
  46. package/es/core/models/plugins/resourceWebControllUrl.js +84 -103
  47. package/es/core/models/tagstips/ElementTagTipConfig.js +34 -40
  48. package/es/core/models/topoData.js +73 -77
  49. package/es/core/models/utils/linkUtils.js +46 -51
  50. package/es/core/services/alarm.js +14 -16
  51. package/es/core/services/background.js +59 -67
  52. package/es/core/services/cmdb/metric.js +14 -18
  53. package/es/core/services/cmdb.js +23 -27
  54. package/es/core/services/index.js +48 -68
  55. package/es/core/services/overview.js +131 -151
  56. package/es/core/services/topo/basic.js +11 -13
  57. package/es/core/services/topo/tagtip.js +15 -19
  58. package/es/core/store/models/ciModel.js +58 -62
  59. package/es/core/store/models/customIcon.js +126 -145
  60. package/es/core/store/models/displayConfig.js +15 -19
  61. package/es/core/store/models/selection.js +4 -6
  62. package/es/core/store/models/topoAlarm.js +162 -145
  63. package/es/core/store/models/topoBaseInfoOverview.js +4 -6
  64. package/es/core/store/models/topoBizMod.js +28 -32
  65. package/es/core/store/models/topoConfig.js +217 -233
  66. package/es/core/store/models/topoGraphView.js +4 -6
  67. package/es/core/store/models/topoMod.js +379 -401
  68. package/es/core/utils/imageUtil.js +23 -27
  69. package/es/core/utils/saveSerialize.js +14 -18
  70. package/es/core/viewer/components/plugins/ResourceDetail/components/ClusterMemberTable.js +62 -66
  71. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/EventsCard.js +20 -25
  72. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverview.js +363 -409
  73. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/Configurator/index.js +112 -131
  74. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/LinkTopoCard.js +40 -46
  75. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/services/index.js +219 -275
  76. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useAlarmAndRiskData.js +113 -118
  77. package/es/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useMetricModels.js +63 -68
  78. package/es/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleForm/hooks/useWebConsole.js +45 -54
  79. package/es/core/viewer/components/plugins/ResourceDetail/getCiDisplayMetricModels.js +32 -44
  80. package/es/core/viewer/components/plugins/ResourceDetail/hooks/useUserId.js +36 -43
  81. package/es/core/viewer/components/plugins/ResourceWebControllUrlSettingDialog.js +23 -27
  82. package/es/networkTopo/components/Link/hook.js +85 -96
  83. package/es/networkTopo/components/Link/index copy.js +104 -126
  84. package/es/networkTopo/components/Link/index.js +104 -126
  85. package/es/networkTopo/components/Link/setting.js +48 -52
  86. package/es/networkTopo/getTopoData.js +73 -92
  87. package/es/networkTopo/hooks/viewer/useRelateTopo.js +34 -39
  88. package/es/networkTopo/models/LinkDynamicStyleExecutor.js +2 -2
  89. package/es/networkTopo/models/TopoCenter.js +28 -46
  90. package/es/networkTopo/services/alert.js +18 -22
  91. package/es/networkTopo/services/authorization.js +45 -55
  92. package/es/networkTopo/services/cmdb.js +548 -696
  93. package/es/networkTopo/services/funcAuth.js +22 -24
  94. package/es/networkTopo/services/link.js +107 -117
  95. package/es/networkTopo/services/mdc.js +33 -48
  96. package/es/networkTopo/services/metric.js +38 -47
  97. package/es/networkTopo/services/model.js +616 -809
  98. package/es/networkTopo/services/risk.js +9 -11
  99. package/es/networkTopo/services/topo/auth.js +27 -33
  100. package/es/networkTopo/services/topo/basic.js +274 -314
  101. package/es/networkTopo/services/topo/blacklist.js +20 -24
  102. package/es/networkTopo/services/topo/ciInfo.js +27 -31
  103. package/es/networkTopo/services/topo/icon.js +49 -59
  104. package/es/networkTopo/services/topo/networkLink.js +32 -36
  105. package/es/networkTopo/services/topo/relation.js +9 -11
  106. package/es/networkTopo/services/topo/resourceWebUrl.js +36 -42
  107. package/es/networkTopo/store/functionAuth.js +31 -37
  108. package/es/networkTopo/store/linkDynamicStyle.js +102 -108
  109. package/es/networkTopo/store/linkDynamicStyleConfig.js +42 -44
  110. package/es/networkTopo/store/linkManager.js +4 -6
  111. package/es/networkTopo/store/topoCenter.js +142 -152
  112. package/es/networkTopo/store/topoLinkMod.js +4 -6
  113. package/es/networkTopo/store/topoTreeMod.js +170 -182
  114. package/es/networkTopo/utils/exportData.js +57 -61
  115. package/lib/components/IndexSettingDrawer/index.js +6 -5
  116. package/lib/components/MultiResourceDrawer/index.js +22 -26
  117. package/lib/components/ResourceList/ResourceSelect.js +54 -58
  118. package/lib/components/ResourceSelectDrawer/ResourceSelectDrawer.js +33 -37
  119. package/lib/components/SingleResourceDrawer/SelectDrawer.js +24 -28
  120. package/lib/core/components/DisplaySettingDrawer/DisplaySettingDrawer.js +36 -40
  121. package/lib/core/components/DisplaySettingDrawer/ResourceDisplay/useElementTagTipConfig.js +82 -104
  122. package/lib/core/components/DisplaySettingDrawer/hooks/useDisplaySetting.js +92 -108
  123. package/lib/core/components/titlebar/widgets/TitleWidget.js +5 -4
  124. package/lib/core/editor/components/BackgroundView/UploadDialog/index.js +18 -18
  125. package/lib/core/editor/components/BackgroundView/index.js +148 -177
  126. package/lib/core/editor/components/CustomIconPlugin/RenameDialog.js +28 -32
  127. package/lib/core/editor/components/CustomIconPlugin/UploadIconDialog.js +34 -34
  128. package/lib/core/editor/components/CustomIconPlugin/utils/svgToShape.js +23 -28
  129. package/lib/core/editor/components/GroupAddResourceDrawerPlugin/GroupAddResourceDrawer.js +14 -18
  130. package/lib/core/editor/components/Sidebar/views/CanvasPanel/hooks/useCanvasThemeConfig.js +45 -56
  131. package/lib/core/editor/components/Toolbar/widgets/BoxBackgroundButton/BoxBackgroundSetting.js +60 -70
  132. package/lib/core/editor/components/Toolbar/widgets/FontColorButton.js +60 -70
  133. package/lib/core/editor/components/settings/propertyViews/layer/DataTab/DefaultLayerAddResourceDrawer.js +18 -22
  134. package/lib/core/editor/components/settings/propertyViews/node/data/BindResourceDrawer.js +32 -36
  135. package/lib/core/editor/components/settings/propertyViews/node/data/Data.js +21 -25
  136. package/lib/core/editor/components/settings/propertyViews/view/BackgroundSize.js +18 -22
  137. package/lib/core/editor/components/titlebar/TopoEditorTitleBar.js +41 -59
  138. package/lib/core/editor/hooks/useKeyboardShortcut.js +2 -2
  139. package/lib/core/editor/hooks/useNewElementTheme.js +2 -2
  140. package/lib/core/editor/store/background.js +8 -10
  141. package/lib/core/editor/store/topoEdit.js +4 -6
  142. package/lib/core/editor/utils/edgeTypeStyleUtil.js +2 -4
  143. package/lib/core/hooks/usePolling.js +108 -120
  144. package/lib/core/hooks/useResourceConfig.js +76 -100
  145. package/lib/core/hooks/useTopoEdit.js +530 -629
  146. package/lib/core/models/Alarm.js +308 -391
  147. package/lib/core/models/AttributeMetricDisplay.js +118 -146
  148. package/lib/core/models/PluginManager.js +4 -3
  149. package/lib/core/models/SelectionModel.js +4 -5
  150. package/lib/core/models/TopoApp.js +287 -454
  151. package/lib/core/models/TopoGraphView.js +28 -41
  152. package/lib/core/models/cache/CiCache.js +39 -44
  153. package/lib/core/models/cache/CiTypeCache.js +71 -85
  154. package/lib/core/models/cache/DictCache.js +39 -45
  155. package/lib/core/models/graph/Background.js +22 -27
  156. package/lib/core/models/plugins/resourceWebControllUrl.js +82 -101
  157. package/lib/core/models/tagstips/ElementTagTipConfig.js +34 -40
  158. package/lib/core/models/topoData.js +73 -78
  159. package/lib/core/models/utils/linkUtils.js +45 -51
  160. package/lib/core/services/alarm.js +18 -20
  161. package/lib/core/services/background.js +70 -78
  162. package/lib/core/services/cmdb/metric.js +14 -19
  163. package/lib/core/services/cmdb.js +24 -29
  164. package/lib/core/services/index.js +53 -72
  165. package/lib/core/services/overview.js +131 -151
  166. package/lib/core/services/topo/basic.js +13 -15
  167. package/lib/core/services/topo/tagtip.js +16 -21
  168. package/lib/core/store/models/ciModel.js +66 -70
  169. package/lib/core/store/models/customIcon.js +126 -145
  170. package/lib/core/store/models/displayConfig.js +15 -19
  171. package/lib/core/store/models/selection.js +4 -6
  172. package/lib/core/store/models/topoAlarm.js +163 -145
  173. package/lib/core/store/models/topoBaseInfoOverview.js +4 -6
  174. package/lib/core/store/models/topoBizMod.js +34 -38
  175. package/lib/core/store/models/topoConfig.js +224 -240
  176. package/lib/core/store/models/topoGraphView.js +4 -6
  177. package/lib/core/store/models/topoMod.js +381 -403
  178. package/lib/core/utils/imageUtil.js +26 -31
  179. package/lib/core/utils/saveSerialize.js +13 -18
  180. package/lib/core/viewer/components/plugins/ResourceDetail/components/ClusterMemberTable.js +62 -66
  181. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/EventsCard.js +21 -26
  182. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/ResourceOverview.js +364 -410
  183. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/Configurator/index.js +114 -133
  184. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/LinkTopoCard.js +44 -50
  185. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/components/LinkTopo/services/index.js +220 -274
  186. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useAlarmAndRiskData.js +113 -118
  187. package/lib/core/viewer/components/plugins/ResourceDetail/components/ResourceOverview/hooks/useMetricModels.js +63 -68
  188. package/lib/core/viewer/components/plugins/ResourceDetail/components/WebConsole/WebConsoleForm/hooks/useWebConsole.js +40 -50
  189. package/lib/core/viewer/components/plugins/ResourceDetail/getCiDisplayMetricModels.js +35 -47
  190. package/lib/core/viewer/components/plugins/ResourceDetail/hooks/useUserId.js +36 -43
  191. package/lib/core/viewer/components/plugins/ResourceWebControllUrlSettingDialog.js +24 -28
  192. package/lib/networkTopo/components/Link/hook.js +86 -98
  193. package/lib/networkTopo/components/Link/index copy.js +105 -127
  194. package/lib/networkTopo/components/Link/index.js +105 -127
  195. package/lib/networkTopo/components/Link/setting.js +48 -52
  196. package/lib/networkTopo/getTopoData.js +73 -92
  197. package/lib/networkTopo/hooks/viewer/useRelateTopo.js +35 -40
  198. package/lib/networkTopo/models/LinkDynamicStyleExecutor.js +2 -2
  199. package/lib/networkTopo/models/TopoCenter.js +28 -46
  200. package/lib/networkTopo/services/alert.js +18 -22
  201. package/lib/networkTopo/services/authorization.js +55 -65
  202. package/lib/networkTopo/services/cmdb.js +551 -700
  203. package/lib/networkTopo/services/funcAuth.js +24 -26
  204. package/lib/networkTopo/services/link.js +108 -118
  205. package/lib/networkTopo/services/mdc.js +35 -51
  206. package/lib/networkTopo/services/metric.js +37 -47
  207. package/lib/networkTopo/services/model.js +615 -809
  208. package/lib/networkTopo/services/risk.js +11 -13
  209. package/lib/networkTopo/services/topo/auth.js +27 -33
  210. package/lib/networkTopo/services/topo/basic.js +277 -317
  211. package/lib/networkTopo/services/topo/blacklist.js +20 -24
  212. package/lib/networkTopo/services/topo/ciInfo.js +34 -38
  213. package/lib/networkTopo/services/topo/icon.js +59 -69
  214. package/lib/networkTopo/services/topo/networkLink.js +32 -36
  215. package/lib/networkTopo/services/topo/relation.js +11 -13
  216. package/lib/networkTopo/services/topo/resourceWebUrl.js +44 -50
  217. package/lib/networkTopo/store/functionAuth.js +31 -37
  218. package/lib/networkTopo/store/linkDynamicStyle.js +103 -109
  219. package/lib/networkTopo/store/linkDynamicStyleConfig.js +42 -44
  220. package/lib/networkTopo/store/linkManager.js +4 -6
  221. package/lib/networkTopo/store/topoCenter.js +142 -152
  222. package/lib/networkTopo/store/topoLinkMod.js +4 -6
  223. package/lib/networkTopo/store/topoTreeMod.js +166 -178
  224. package/lib/networkTopo/utils/exportData.js +63 -68
  225. package/package.json +3 -3
@@ -24,19 +24,22 @@ import ElementTagTipConfig from "./tagstips/ElementTagTipConfig";
24
24
  import SelectionModel from "./SelectionModel";
25
25
  import CiCache from "./cache/CiCache"; // eslint-disable-next-line no-undef
26
26
 
27
- var version = typeof "10.0.58" === 'string' ? "10.0.58" : null;
27
+ var version = typeof "10.0.59" === 'string' ? "10.0.59" : null;
28
28
  console.info("\u62D3\u6251\u7248\u672C: " + version);
29
29
  /**
30
30
  * 拓扑显示和编辑
31
31
  */
32
32
 
33
33
  var Topo = /*#__PURE__*/function () {
34
- /**
35
- * @type TopoGraphView
36
- */
34
+ var _exit, _load, _clear, _updateElements, _addElements, _updateData, _open, _close, _refresh, _openViewMode, _onTopoDataLoaded, _enterEditMode, _exitEditMode, _triggerSaveEvent, _save, _exportImage, _loadAttrsAndMetrics, _switchToViewMode, _switchToEditMode;
35
+
37
36
  function Topo(options) {
38
37
  this.options = void 0;
39
38
  this.id = void 0;
39
+
40
+ /**
41
+ * @type TopoGraphView
42
+ */
40
43
  this.view = void 0;
41
44
  this.alarm = new Alarm();
42
45
  this.store = void 0;
@@ -92,95 +95,69 @@ var Topo = /*#__PURE__*/function () {
92
95
  */
93
96
  ;
94
97
 
95
- _proto.exit =
96
- /*#__PURE__*/
97
- function () {
98
- var _exit = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
98
+ _proto.exit = function exit() {
99
+ return (_exit = _exit || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
99
100
  var topoDispatchers;
100
101
  return _regeneratorRuntime.wrap(function _callee$(_context) {
101
- while (1) {
102
- switch (_context.prev = _context.next) {
103
- case 0:
104
- topoDispatchers = this.store.getModelDispatchers('topoMod');
105
- _context.next = 3;
106
- return topoDispatchers.exit();
107
-
108
- case 3:
109
- this.destroy();
110
-
111
- case 4:
112
- case "end":
113
- return _context.stop();
114
- }
102
+ while (1) switch (_context.prev = _context.next) {
103
+ case 0:
104
+ topoDispatchers = this.store.getModelDispatchers('topoMod');
105
+ _context.next = 3;
106
+ return topoDispatchers.exit();
107
+
108
+ case 3:
109
+ this.destroy();
110
+
111
+ case 4:
112
+ case "end":
113
+ return _context.stop();
115
114
  }
116
115
  }, _callee, this);
117
- }));
118
-
119
- function exit() {
120
- return _exit.apply(this, arguments);
121
- }
122
-
123
- return exit;
124
- }();
116
+ }))).apply(this, arguments);
117
+ };
125
118
 
126
- _proto.load = /*#__PURE__*/function () {
127
- var _load = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee2(data, options) {
119
+ _proto.load = function load(_x, _x2) {
120
+ return (_load = _load || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee2(data, options) {
128
121
  var _data$groups, groups, _data$nodes, nodes, links, lines, topoDispatchers;
129
122
 
130
123
  return _regeneratorRuntime.wrap(function _callee2$(_context2) {
131
- while (1) {
132
- switch (_context2.prev = _context2.next) {
133
- case 0:
134
- if (options === void 0) {
135
- options = {};
136
- }
137
-
138
- _data$groups = data.groups, groups = _data$groups === void 0 ? [] : _data$groups, _data$nodes = data.nodes, nodes = _data$nodes === void 0 ? [] : _data$nodes, links = data.links, lines = data.lines;
139
- topoDispatchers = this.store.getModelDispatchers('topoMod');
140
- _context2.next = 5;
141
- return topoDispatchers.openTopoPage(_extends({
142
- data: _extends({}, data, {
143
- groups: groups,
144
- nodes: nodes,
145
- links: links || lines || [],
146
- linkGroups: data.linkGroups || data.lineGroups || []
147
- })
148
- }, options));
149
-
150
- case 5:
151
- case "end":
152
- return _context2.stop();
153
- }
124
+ while (1) switch (_context2.prev = _context2.next) {
125
+ case 0:
126
+ if (options === void 0) {
127
+ options = {};
128
+ }
129
+
130
+ _data$groups = data.groups, groups = _data$groups === void 0 ? [] : _data$groups, _data$nodes = data.nodes, nodes = _data$nodes === void 0 ? [] : _data$nodes, links = data.links, lines = data.lines;
131
+ topoDispatchers = this.store.getModelDispatchers('topoMod');
132
+ _context2.next = 5;
133
+ return topoDispatchers.openTopoPage(_extends({
134
+ data: _extends({}, data, {
135
+ groups: groups,
136
+ nodes: nodes,
137
+ links: links || lines || [],
138
+ linkGroups: data.linkGroups || data.lineGroups || []
139
+ })
140
+ }, options));
141
+
142
+ case 5:
143
+ case "end":
144
+ return _context2.stop();
154
145
  }
155
146
  }, _callee2, this);
156
- }));
157
-
158
- function load(_x, _x2) {
159
- return _load.apply(this, arguments);
160
- }
161
-
162
- return load;
163
- }();
147
+ }))).apply(this, arguments);
148
+ };
164
149
 
165
- _proto.clear = /*#__PURE__*/function () {
166
- var _clear = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee3() {
150
+ _proto.clear = function clear() {
151
+ return (_clear = _clear || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee3() {
167
152
  return _regeneratorRuntime.wrap(function _callee3$(_context3) {
168
- while (1) {
169
- switch (_context3.prev = _context3.next) {
170
- case 0:
171
- case "end":
172
- return _context3.stop();
173
- }
153
+ while (1) switch (_context3.prev = _context3.next) {
154
+ case 0:
155
+ case "end":
156
+ return _context3.stop();
174
157
  }
175
158
  }, _callee3);
176
- }));
177
-
178
- function clear() {
179
- return _clear.apply(this, arguments);
180
- }
181
-
182
- return clear;
183
- }();
159
+ }))).apply(this, arguments);
160
+ };
184
161
 
185
162
  _proto.getId = function getId() {
186
163
  return this.id;
@@ -233,47 +210,37 @@ var Topo = /*#__PURE__*/function () {
233
210
  */
234
211
  ;
235
212
 
236
- _proto.updateElements =
237
- /*#__PURE__*/
238
- function () {
239
- var _updateElements = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee4(data) {
213
+ _proto.updateElements = function updateElements(_x3) {
214
+ return (_updateElements = _updateElements || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee4(data) {
240
215
  var _data$groups2, groups, _data$nodes2, nodes, links, lines;
241
216
 
242
217
  return _regeneratorRuntime.wrap(function _callee4$(_context4) {
243
- while (1) {
244
- switch (_context4.prev = _context4.next) {
245
- case 0:
246
- _data$groups2 = data.groups, groups = _data$groups2 === void 0 ? [] : _data$groups2, _data$nodes2 = data.nodes, nodes = _data$nodes2 === void 0 ? [] : _data$nodes2, links = data.links, lines = data.lines;
247
- this.view.topoClient.updateElements(cloneDeep({
248
- groups: formatGroups(groups),
249
- nodes: nodes.map(function (node) {
250
- return _extends({}, node, {
251
- type: 'node',
252
- dtype: 'device'
253
- });
254
- }),
255
- links: (links || lines || []).map(function (link) {
256
- return _extends({}, link, {
257
- type: 'link',
258
- dtype: 'link'
259
- });
260
- })
261
- })); // TODO 更新store,触发属性、指标模型加载,更新指标
262
-
263
- case 2:
264
- case "end":
265
- return _context4.stop();
266
- }
218
+ while (1) switch (_context4.prev = _context4.next) {
219
+ case 0:
220
+ _data$groups2 = data.groups, groups = _data$groups2 === void 0 ? [] : _data$groups2, _data$nodes2 = data.nodes, nodes = _data$nodes2 === void 0 ? [] : _data$nodes2, links = data.links, lines = data.lines;
221
+ this.view.topoClient.updateElements(cloneDeep({
222
+ groups: formatGroups(groups),
223
+ nodes: nodes.map(function (node) {
224
+ return _extends({}, node, {
225
+ type: 'node',
226
+ dtype: 'device'
227
+ });
228
+ }),
229
+ links: (links || lines || []).map(function (link) {
230
+ return _extends({}, link, {
231
+ type: 'link',
232
+ dtype: 'link'
233
+ });
234
+ })
235
+ })); // TODO 更新store,触发属性、指标模型加载,更新指标
236
+
237
+ case 2:
238
+ case "end":
239
+ return _context4.stop();
267
240
  }
268
241
  }, _callee4, this);
269
- }));
270
-
271
- function updateElements(_x3) {
272
- return _updateElements.apply(this, arguments);
273
- }
274
-
275
- return updateElements;
276
- }()
242
+ }))).apply(this, arguments);
243
+ }
277
244
  /**
278
245
  * 追加元素
279
246
  *
@@ -281,36 +248,26 @@ var Topo = /*#__PURE__*/function () {
281
248
  */
282
249
  ;
283
250
 
284
- _proto.addElements =
285
- /*#__PURE__*/
286
- function () {
287
- var _addElements = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee5(elements) {
251
+ _proto.addElements = function addElements(_x4) {
252
+ return (_addElements = _addElements || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee5(elements) {
288
253
  var data;
289
254
  return _regeneratorRuntime.wrap(function _callee5$(_context5) {
290
- while (1) {
291
- switch (_context5.prev = _context5.next) {
292
- case 0:
293
- data = {
294
- groups: [].concat(this.getGroups(), elements.groups || []),
295
- nodes: [].concat(this.getNodes(), elements.nodes || []),
296
- lines: [].concat(this.getLines(), elements.lines || [])
297
- };
298
- this.updateElements(data); // TODO 更新store,触发属性、指标模型加载,更新指标
299
-
300
- case 2:
301
- case "end":
302
- return _context5.stop();
303
- }
255
+ while (1) switch (_context5.prev = _context5.next) {
256
+ case 0:
257
+ data = {
258
+ groups: [].concat(this.getGroups(), elements.groups || []),
259
+ nodes: [].concat(this.getNodes(), elements.nodes || []),
260
+ lines: [].concat(this.getLines(), elements.lines || [])
261
+ };
262
+ this.updateElements(data); // TODO 更新store,触发属性、指标模型加载,更新指标
263
+
264
+ case 2:
265
+ case "end":
266
+ return _context5.stop();
304
267
  }
305
268
  }, _callee5, this);
306
- }));
307
-
308
- function addElements(_x4) {
309
- return _addElements.apply(this, arguments);
310
- }
311
-
312
- return addElements;
313
- }()
269
+ }))).apply(this, arguments);
270
+ }
314
271
  /**
315
272
  * 全量更新数据
316
273
  *
@@ -318,30 +275,20 @@ var Topo = /*#__PURE__*/function () {
318
275
  */
319
276
  ;
320
277
 
321
- _proto.updateData =
322
- /*#__PURE__*/
323
- function () {
324
- var _updateData = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee6(data) {
278
+ _proto.updateData = function updateData(_x5) {
279
+ return (_updateData = _updateData || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee6(data) {
325
280
  return _regeneratorRuntime.wrap(function _callee6$(_context6) {
326
- while (1) {
327
- switch (_context6.prev = _context6.next) {
328
- case 0:
329
- this.updateElements(data);
330
-
331
- case 1:
332
- case "end":
333
- return _context6.stop();
334
- }
281
+ while (1) switch (_context6.prev = _context6.next) {
282
+ case 0:
283
+ this.updateElements(data);
284
+
285
+ case 1:
286
+ case "end":
287
+ return _context6.stop();
335
288
  }
336
289
  }, _callee6, this);
337
- }));
338
-
339
- function updateData(_x5) {
340
- return _updateData.apply(this, arguments);
341
- }
342
-
343
- return updateData;
344
- }();
290
+ }))).apply(this, arguments);
291
+ };
345
292
 
346
293
  _proto.replaceNode = function replaceNode(id, newNode) {
347
294
  this.view.replaceNode(id, newNode); // TODO 更新store,触发属性、指标模型加载,更新指标
@@ -358,91 +305,67 @@ var Topo = /*#__PURE__*/function () {
358
305
  this.view.fitContent(anim, padding, notZoomIn);
359
306
  };
360
307
 
361
- _proto.open = /*#__PURE__*/function () {
362
- var _open = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee7(id, mode) {
308
+ _proto.open = function open(_x6, _x7) {
309
+ return (_open = _open || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee7(id, mode) {
363
310
  var lastId;
364
311
  return _regeneratorRuntime.wrap(function _callee7$(_context7) {
365
- while (1) {
366
- switch (_context7.prev = _context7.next) {
367
- case 0:
368
- rlog.info('TopoApp.open 打开拓扑图', id); // 如果是切换拓扑图,注销原拓扑图
312
+ while (1) switch (_context7.prev = _context7.next) {
313
+ case 0:
314
+ rlog.info('TopoApp.open 打开拓扑图', id); // 如果是切换拓扑图,注销原拓扑图
369
315
 
370
- lastId = this.id;
371
- this.id = id;
316
+ lastId = this.id;
317
+ this.id = id;
372
318
 
373
- if (lastId && id !== lastId) {
374
- this.alarm.close();
375
- } // 加载新拓扑图
319
+ if (lastId && id !== lastId) {
320
+ this.alarm.close();
321
+ } // 加载新拓扑图
376
322
 
377
323
 
378
- case 4:
379
- case "end":
380
- return _context7.stop();
381
- }
324
+ case 4:
325
+ case "end":
326
+ return _context7.stop();
382
327
  }
383
328
  }, _callee7, this);
384
- }));
385
-
386
- function open(_x6, _x7) {
387
- return _open.apply(this, arguments);
388
- }
389
-
390
- return open;
391
- }();
329
+ }))).apply(this, arguments);
330
+ };
392
331
 
393
- _proto.close = /*#__PURE__*/function () {
394
- var _close = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee8() {
332
+ _proto.close = function close() {
333
+ return (_close = _close || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee8() {
395
334
  return _regeneratorRuntime.wrap(function _callee8$(_context8) {
396
- while (1) {
397
- switch (_context8.prev = _context8.next) {
398
- case 0:
399
- rlog.info('关闭拓扑图', this.id);
335
+ while (1) switch (_context8.prev = _context8.next) {
336
+ case 0:
337
+ rlog.info('关闭拓扑图', this.id);
400
338
 
401
- if (this.id) {
402
- _context8.next = 3;
403
- break;
404
- }
339
+ if (this.id) {
340
+ _context8.next = 3;
341
+ break;
342
+ }
405
343
 
406
- return _context8.abrupt("return");
344
+ return _context8.abrupt("return");
407
345
 
408
- case 3:
409
- this.alarm.close();
410
- this.id = null;
346
+ case 3:
347
+ this.alarm.close();
348
+ this.id = null;
411
349
 
412
- case 5:
413
- case "end":
414
- return _context8.stop();
415
- }
350
+ case 5:
351
+ case "end":
352
+ return _context8.stop();
416
353
  }
417
354
  }, _callee8, this);
418
- }));
419
-
420
- function close() {
421
- return _close.apply(this, arguments);
422
- }
423
-
424
- return close;
425
- }();
355
+ }))).apply(this, arguments);
356
+ };
426
357
 
427
- _proto.refresh = /*#__PURE__*/function () {
428
- var _refresh = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee9() {
358
+ _proto.refresh = function refresh() {
359
+ return (_refresh = _refresh || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee9() {
429
360
  return _regeneratorRuntime.wrap(function _callee9$(_context9) {
430
- while (1) {
431
- switch (_context9.prev = _context9.next) {
432
- case 0:
433
- case "end":
434
- return _context9.stop();
435
- }
361
+ while (1) switch (_context9.prev = _context9.next) {
362
+ case 0:
363
+ case "end":
364
+ return _context9.stop();
436
365
  }
437
366
  }, _callee9);
438
- }));
439
-
440
- function refresh() {
441
- return _refresh.apply(this, arguments);
442
- }
443
-
444
- return refresh;
445
- }();
367
+ }))).apply(this, arguments);
368
+ };
446
369
 
447
370
  _proto.getGraphView = function getGraphView() {
448
371
  return this.view.topoClient.getGraphView();
@@ -469,25 +392,17 @@ var Topo = /*#__PURE__*/function () {
469
392
  this.view.topoClient.searchElements(filterType, value);
470
393
  };
471
394
 
472
- _proto.openViewMode = /*#__PURE__*/function () {
473
- var _openViewMode = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee10(id) {
395
+ _proto.openViewMode = function openViewMode(_x8) {
396
+ return (_openViewMode = _openViewMode || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee10(id) {
474
397
  return _regeneratorRuntime.wrap(function _callee10$(_context10) {
475
- while (1) {
476
- switch (_context10.prev = _context10.next) {
477
- case 0:
478
- case "end":
479
- return _context10.stop();
480
- }
398
+ while (1) switch (_context10.prev = _context10.next) {
399
+ case 0:
400
+ case "end":
401
+ return _context10.stop();
481
402
  }
482
403
  }, _callee10);
483
- }));
484
-
485
- function openViewMode(_x8) {
486
- return _openViewMode.apply(this, arguments);
487
- }
488
-
489
- return openViewMode;
490
- }();
404
+ }))).apply(this, arguments);
405
+ };
491
406
 
492
407
  _proto.isViewMode = function isViewMode() {
493
408
  return !this.isEditMode();
@@ -501,193 +416,147 @@ var Topo = /*#__PURE__*/function () {
501
416
  return this.store.getModelState('topoMod').graphLoaded;
502
417
  };
503
418
 
504
- _proto.onTopoDataLoaded = /*#__PURE__*/function () {
505
- var _onTopoDataLoaded = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee11(topoData) {
419
+ _proto.onTopoDataLoaded = function onTopoDataLoaded(_x9) {
420
+ return (_onTopoDataLoaded = _onTopoDataLoaded || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee11(topoData) {
506
421
  return _regeneratorRuntime.wrap(function _callee11$(_context11) {
507
- while (1) {
508
- switch (_context11.prev = _context11.next) {
509
- case 0:
510
- this.pluginManager.onTopoDataLoaded(topoData);
511
-
512
- case 1:
513
- case "end":
514
- return _context11.stop();
515
- }
422
+ while (1) switch (_context11.prev = _context11.next) {
423
+ case 0:
424
+ this.pluginManager.onTopoDataLoaded(topoData);
425
+
426
+ case 1:
427
+ case "end":
428
+ return _context11.stop();
516
429
  }
517
430
  }, _callee11, this);
518
- }));
519
-
520
- function onTopoDataLoaded(_x9) {
521
- return _onTopoDataLoaded.apply(this, arguments);
522
- }
523
-
524
- return onTopoDataLoaded;
525
- }()
431
+ }))).apply(this, arguments);
432
+ }
526
433
  /**
527
434
  * 进入编辑模式
528
435
  */
529
436
  ;
530
437
 
531
- _proto.enterEditMode =
532
- /*#__PURE__*/
533
- function () {
534
- var _enterEditMode = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee12() {
438
+ _proto.enterEditMode = function enterEditMode() {
439
+ return (_enterEditMode = _enterEditMode || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee12() {
535
440
  var topoDispatchers, iconManageDispatchers;
536
441
  return _regeneratorRuntime.wrap(function _callee12$(_context12) {
537
- while (1) {
538
- switch (_context12.prev = _context12.next) {
539
- case 0:
540
- rlog.info('TopoApp.enterEditMode');
541
-
542
- if (!this.options.onSwitchToEditModeBegin) {
543
- _context12.next = 4;
544
- break;
545
- }
442
+ while (1) switch (_context12.prev = _context12.next) {
443
+ case 0:
444
+ rlog.info('TopoApp.enterEditMode');
546
445
 
446
+ if (!this.options.onSwitchToEditModeBegin) {
547
447
  _context12.next = 4;
548
- return this.options.onSwitchToEditModeBegin(this);
448
+ break;
449
+ }
549
450
 
550
- case 4:
551
- topoDispatchers = this.store.getModelDispatchers('topoMod');
552
- _context12.next = 7;
553
- return topoDispatchers.update({
554
- viewState: 'edit'
555
- });
451
+ _context12.next = 4;
452
+ return this.options.onSwitchToEditModeBegin(this);
556
453
 
557
- case 7:
558
- _context12.next = 9;
559
- return this.view.switchToEditMode();
454
+ case 4:
455
+ topoDispatchers = this.store.getModelDispatchers('topoMod');
456
+ _context12.next = 7;
457
+ return topoDispatchers.update({
458
+ viewState: 'edit'
459
+ });
560
460
 
561
- case 9:
562
- updateEdgeExpanded(this);
461
+ case 7:
462
+ _context12.next = 9;
463
+ return this.view.switchToEditMode();
563
464
 
564
- if (!this.options.onSwitchToEditMode) {
565
- _context12.next = 13;
566
- break;
567
- }
465
+ case 9:
466
+ updateEdgeExpanded(this);
568
467
 
468
+ if (!this.options.onSwitchToEditMode) {
569
469
  _context12.next = 13;
570
- return this.options.onSwitchToEditMode(this);
470
+ break;
471
+ }
472
+
473
+ _context12.next = 13;
474
+ return this.options.onSwitchToEditMode(this);
571
475
 
572
- case 13:
573
- if (this.getDataModel()) {
574
- // 更新节点名称显示隐藏
575
- this.attributeMetricDisplay.updateNodesNameVisible();
576
- } // 加载自定义上传的图标
476
+ case 13:
477
+ if (this.getDataModel()) {
478
+ // 更新节点名称显示隐藏
479
+ this.attributeMetricDisplay.updateNodesNameVisible();
480
+ } // 加载自定义上传的图标
577
481
 
578
482
 
579
- iconManageDispatchers = this.store.getModelDispatchers('customIcon');
580
- iconManageDispatchers.loadEditorIcons();
483
+ iconManageDispatchers = this.store.getModelDispatchers('customIcon');
484
+ iconManageDispatchers.loadEditorIcons();
581
485
 
582
- case 16:
583
- case "end":
584
- return _context12.stop();
585
- }
486
+ case 16:
487
+ case "end":
488
+ return _context12.stop();
586
489
  }
587
490
  }, _callee12, this);
588
- }));
589
-
590
- function enterEditMode() {
591
- return _enterEditMode.apply(this, arguments);
592
- }
593
-
594
- return enterEditMode;
595
- }();
491
+ }))).apply(this, arguments);
492
+ };
596
493
 
597
- _proto.exitEditMode = /*#__PURE__*/function () {
598
- var _exitEditMode = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee13() {
494
+ _proto.exitEditMode = function exitEditMode() {
495
+ return (_exitEditMode = _exitEditMode || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee13() {
599
496
  var editDispatchers;
600
497
  return _regeneratorRuntime.wrap(function _callee13$(_context13) {
601
- while (1) {
602
- switch (_context13.prev = _context13.next) {
603
- case 0:
604
- _context13.next = 2;
605
- return this.view.switchToViewMode();
606
-
607
- case 2:
608
- editDispatchers = this.store.getModelDispatchers('topoConfig');
609
- editDispatchers.switchToViewMode(this.id);
498
+ while (1) switch (_context13.prev = _context13.next) {
499
+ case 0:
500
+ _context13.next = 2;
501
+ return this.view.switchToViewMode();
610
502
 
611
- if (!this.options.onSwitchToViewMode) {
612
- _context13.next = 7;
613
- break;
614
- }
503
+ case 2:
504
+ editDispatchers = this.store.getModelDispatchers('topoConfig');
505
+ editDispatchers.switchToViewMode(this.id);
615
506
 
507
+ if (!this.options.onSwitchToViewMode) {
616
508
  _context13.next = 7;
617
- return this.options.onSwitchToViewMode(this);
509
+ break;
510
+ }
511
+
512
+ _context13.next = 7;
513
+ return this.options.onSwitchToViewMode(this);
618
514
 
619
- case 7:
620
- case "end":
621
- return _context13.stop();
622
- }
515
+ case 7:
516
+ case "end":
517
+ return _context13.stop();
623
518
  }
624
519
  }, _callee13, this);
625
- }));
626
-
627
- function exitEditMode() {
628
- return _exitEditMode.apply(this, arguments);
629
- }
630
-
631
- return exitEditMode;
632
- }()
520
+ }))).apply(this, arguments);
521
+ }
633
522
  /**
634
523
  * 后续待优化,移除该接口,由ht提供原子接口获取相关数据
635
524
  */
636
525
  ;
637
526
 
638
- _proto.triggerSaveEvent =
639
- /*#__PURE__*/
640
- function () {
641
- var _triggerSaveEvent = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee14() {
527
+ _proto.triggerSaveEvent = function triggerSaveEvent() {
528
+ return (_triggerSaveEvent = _triggerSaveEvent || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee14() {
642
529
  return _regeneratorRuntime.wrap(function _callee14$(_context14) {
643
- while (1) {
644
- switch (_context14.prev = _context14.next) {
645
- case 0:
646
- this.view.topoClient.saveExternal();
647
-
648
- case 1:
649
- case "end":
650
- return _context14.stop();
651
- }
530
+ while (1) switch (_context14.prev = _context14.next) {
531
+ case 0:
532
+ this.view.topoClient.saveExternal();
533
+
534
+ case 1:
535
+ case "end":
536
+ return _context14.stop();
652
537
  }
653
538
  }, _callee14, this);
654
- }));
655
-
656
- function triggerSaveEvent() {
657
- return _triggerSaveEvent.apply(this, arguments);
658
- }
659
-
660
- return triggerSaveEvent;
661
- }()
539
+ }))).apply(this, arguments);
540
+ }
662
541
  /**
663
542
  * FIXME 待优化,移除该接口,由ht提供原子接口获取相关数据
664
543
  */
665
544
  ;
666
545
 
667
- _proto.save =
668
- /*#__PURE__*/
669
- function () {
670
- var _save = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee15() {
546
+ _proto.save = function save() {
547
+ return (_save = _save || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee15() {
671
548
  return _regeneratorRuntime.wrap(function _callee15$(_context15) {
672
- while (1) {
673
- switch (_context15.prev = _context15.next) {
674
- case 0:
675
- this.triggerSaveEvent();
676
-
677
- case 1:
678
- case "end":
679
- return _context15.stop();
680
- }
549
+ while (1) switch (_context15.prev = _context15.next) {
550
+ case 0:
551
+ this.triggerSaveEvent();
552
+
553
+ case 1:
554
+ case "end":
555
+ return _context15.stop();
681
556
  }
682
557
  }, _callee15, this);
683
- }));
684
-
685
- function save() {
686
- return _save.apply(this, arguments);
687
- }
688
-
689
- return save;
690
- }()
558
+ }))).apply(this, arguments);
559
+ }
691
560
  /**
692
561
  * 导出为图片
693
562
  *
@@ -695,36 +564,26 @@ var Topo = /*#__PURE__*/function () {
695
564
  */
696
565
  ;
697
566
 
698
- _proto.exportImage =
699
- /*#__PURE__*/
700
- function () {
701
- var _exportImage = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee16(name) {
567
+ _proto.exportImage = function exportImage(_x10) {
568
+ return (_exportImage = _exportImage || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee16(name) {
702
569
  var fileName;
703
570
  return _regeneratorRuntime.wrap(function _callee16$(_context16) {
704
- while (1) {
705
- switch (_context16.prev = _context16.next) {
706
- case 0:
707
- fileName = name;
571
+ while (1) switch (_context16.prev = _context16.next) {
572
+ case 0:
573
+ fileName = name;
708
574
 
709
- if (!name) {// TODO 获取拓扑名称,避免改名重绘拓扑图
710
- }
575
+ if (!name) {// TODO 获取拓扑名称,避免改名重绘拓扑图
576
+ }
711
577
 
712
- this.view.topoClient.exportImage(fileName);
578
+ this.view.topoClient.exportImage(fileName);
713
579
 
714
- case 3:
715
- case "end":
716
- return _context16.stop();
717
- }
580
+ case 3:
581
+ case "end":
582
+ return _context16.stop();
718
583
  }
719
584
  }, _callee16, this);
720
- }));
721
-
722
- function exportImage(_x10) {
723
- return _exportImage.apply(this, arguments);
724
- }
725
-
726
- return exportImage;
727
- }();
585
+ }))).apply(this, arguments);
586
+ };
728
587
 
729
588
  _proto.loadAlarm = function loadAlarm(alarmList) {
730
589
  this.alarm.updateState({
@@ -737,67 +596,41 @@ var Topo = /*#__PURE__*/function () {
737
596
  */
738
597
  ;
739
598
 
740
- _proto.loadAttrsAndMetrics =
741
- /*#__PURE__*/
742
- function () {
743
- var _loadAttrsAndMetrics = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee17(data) {
599
+ _proto.loadAttrsAndMetrics = function loadAttrsAndMetrics(_x11) {
600
+ return (_loadAttrsAndMetrics = _loadAttrsAndMetrics || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee17(data) {
744
601
  return _regeneratorRuntime.wrap(function _callee17$(_context17) {
745
- while (1) {
746
- switch (_context17.prev = _context17.next) {
747
- case 0:
748
- case "end":
749
- return _context17.stop();
750
- }
602
+ while (1) switch (_context17.prev = _context17.next) {
603
+ case 0:
604
+ case "end":
605
+ return _context17.stop();
751
606
  }
752
607
  }, _callee17);
753
- }));
754
-
755
- function loadAttrsAndMetrics(_x11) {
756
- return _loadAttrsAndMetrics.apply(this, arguments);
757
- }
758
-
759
- return loadAttrsAndMetrics;
760
- }();
608
+ }))).apply(this, arguments);
609
+ };
761
610
 
762
- _proto.switchToViewMode = /*#__PURE__*/function () {
763
- var _switchToViewMode = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee18() {
611
+ _proto.switchToViewMode = function switchToViewMode() {
612
+ return (_switchToViewMode = _switchToViewMode || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee18() {
764
613
  return _regeneratorRuntime.wrap(function _callee18$(_context18) {
765
- while (1) {
766
- switch (_context18.prev = _context18.next) {
767
- case 0:
768
- case "end":
769
- return _context18.stop();
770
- }
614
+ while (1) switch (_context18.prev = _context18.next) {
615
+ case 0:
616
+ case "end":
617
+ return _context18.stop();
771
618
  }
772
619
  }, _callee18);
773
- }));
774
-
775
- function switchToViewMode() {
776
- return _switchToViewMode.apply(this, arguments);
777
- }
778
-
779
- return switchToViewMode;
780
- }();
620
+ }))).apply(this, arguments);
621
+ };
781
622
 
782
- _proto.switchToEditMode = /*#__PURE__*/function () {
783
- var _switchToEditMode = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee19() {
623
+ _proto.switchToEditMode = function switchToEditMode() {
624
+ return (_switchToEditMode = _switchToEditMode || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee19() {
784
625
  return _regeneratorRuntime.wrap(function _callee19$(_context19) {
785
- while (1) {
786
- switch (_context19.prev = _context19.next) {
787
- case 0:
788
- case "end":
789
- return _context19.stop();
790
- }
626
+ while (1) switch (_context19.prev = _context19.next) {
627
+ case 0:
628
+ case "end":
629
+ return _context19.stop();
791
630
  }
792
631
  }, _callee19);
793
- }));
794
-
795
- function switchToEditMode() {
796
- return _switchToEditMode.apply(this, arguments);
797
- }
798
-
799
- return switchToEditMode;
800
- }();
632
+ }))).apply(this, arguments);
633
+ };
801
634
 
802
635
  _proto.initStore = function initStore() {
803
636
  var store = createStore(this, this.options.storeModels || {});