@riil-frontend/component-topology 2.3.20-dev.1 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/1.js +2 -2
- package/build/2.js +1 -1
- package/build/index.css +2 -2
- package/build/index.js +28 -28
- package/demo/5/345/205/266/344/273/226/347/273/204/344/273/266//345/233/276/346/240/207/351/200/211/346/213/251.md +5 -5
- package/es/components/BatchAttrMetric/index.js +1 -1
- package/es/components/BatchAttrMetric/setting.js +4 -4
- package/es/components/BatchAttrMetric/utils.js +2 -2
- package/es/components/Drawer/index.js +4 -3
- package/es/components/Drawer/index.module.scss +13 -0
- package/es/components/FormTable/index.js +3 -3
- package/es/components/IndexSettingDrawer/CiList.js +1 -1
- package/es/components/IndexSettingDrawer/CiListItem.js +1 -1
- package/es/components/IndexSettingDrawer/IndexList.js +1 -1
- package/es/components/IndexSettingDrawer/index.js +1 -1
- package/es/components/Link/form.js +6 -6
- package/es/components/Link/index.js +2 -2
- package/es/components/Link/setting.js +4 -4
- package/es/components/MultiResourceDrawer/Content.js +1 -1
- package/es/components/MultiResourceDrawer/ResourceCard/index.js +2 -2
- package/es/components/ResourceList/ResourceSelect.js +3 -2
- package/es/components/ResourceList/ResourceSelect.module.scss +7 -0
- package/es/components/ResourceSelect/ResourceSelectDrawer.js +3 -1
- package/es/components/SingleResourceDrawer/index.js +1 -1
- package/es/core/{editor/components/settings/group/GroupNodeList → common}/icons/defaultIcons.d.ts +15 -0
- package/es/core/{editor/components/settings/group/GroupNodeList → common}/icons/defaultIcons.js +62 -0
- package/es/core/common/text.module.scss +5 -0
- package/es/core/components/TopoView/Topo.js +0 -6
- package/es/core/components/TopoView/TopoContent.js +1 -1
- package/es/core/editor/components/EditorPlugin.js +1 -1
- package/es/core/editor/components/LinkDynamicStyleSettingDrawer/RuleSetting.js +2 -2
- package/es/core/editor/components/LinkDynamicStyleSettingDrawer/rule/ColorPicker.js +1 -1
- package/es/core/editor/components/LinkDynamicStyleSettingDrawer/rule/ColorPicker.module.scss +7 -3
- package/es/core/editor/components/LinkDynamicStyleSettingDrawer/rule/Rule.js +1 -1
- package/es/core/editor/components/LinkDynamicStyleSettingDrawer/rule/RuleCondition.js +2 -2
- package/es/core/editor/components/LinkDynamicStyleSettingDrawer/rule/RuleStyle.js +4 -4
- package/es/core/editor/components/iconManage/RenameDialog.js +4 -4
- package/es/core/editor/components/iconManage/UploadIconDialog.js +6 -6
- package/es/core/editor/components/settings/README.md +2 -0
- package/es/core/editor/components/settings/Settings.js +47 -42
- package/es/core/editor/components/settings/Settings.module.scss +6 -1
- package/es/core/editor/components/settings/SettingsForm.js +2 -2
- package/es/core/editor/components/settings/Style.js +7 -7
- package/es/core/editor/components/settings/common/LayoutSettings.js +1 -1
- package/es/core/editor/components/settings/common/LineType.js +2 -2
- package/es/core/editor/components/settings/common/NodeAlignType.js +2 -2
- package/es/core/editor/components/settings/common/{NodeSizeInput.d.ts → NodeSizeInput/NodeSizeInput.d.ts} +0 -0
- package/es/core/editor/components/settings/common/{NodeSizeInput.js → NodeSizeInput/NodeSizeInput.js} +6 -4
- package/es/core/editor/components/settings/common/NodeSizeInput/img/icon_/350/247/243/351/224/201.svg +16 -0
- package/es/core/editor/components/settings/common/NodeSizeInput/img/icon_/351/224/201.svg +15 -0
- package/es/core/editor/components/settings/common/text/FontStyleCheckbox.d.ts +1 -0
- package/es/core/editor/components/settings/common/text/FontStyleCheckbox.js +50 -0
- package/es/core/editor/components/settings/common/text/FontStyleCheckbox.module.scss +31 -0
- package/es/core/editor/components/settings/common/text/TextStyle.d.ts +1 -0
- package/es/core/editor/components/settings/common/text/TextStyle.js +133 -0
- package/es/core/editor/components/settings/common/text/fontStyleUtil.d.ts +19 -0
- package/es/core/editor/components/settings/common/text/fontStyleUtil.js +53 -0
- package/es/core/editor/components/settings/common/text/img/bold.svg +12 -0
- package/es/core/editor/components/settings/common/text/img/italics.svg +10 -0
- package/es/core/editor/components/settings/common/text/img/underline.svg +12 -0
- package/es/core/editor/components/settings/group/GroupNodeList/ResourceList.js +23 -7
- package/es/core/editor/components/settings/group/GroupNodeList/ResourceList.module.scss +16 -0
- package/es/core/editor/components/settings/group/GroupNodeList/ResourceSelectButton.js +1 -1
- package/es/core/editor/components/settings/group/GroupNodeList/icon.d.ts +10 -0
- package/es/core/editor/components/settings/group/GroupNodeList/icon.js +20 -1
- package/es/core/editor/components/settings/layer/LayerSettingsForm.js +8 -8
- package/es/core/editor/components/settings/link/LinkPropertyView.js +8 -8
- package/es/core/editor/components/settings/node/NodeIconSelect.d.ts +1 -0
- package/es/core/editor/components/settings/node/NodeIconSelect.js +42 -0
- package/es/core/editor/components/settings/node/NodePropertyView.d.ts +1 -1
- package/es/core/editor/components/settings/node/NodePropertyView.js +128 -133
- package/es/core/editor/components/settings/node/NodeRelateResourceButton.d.ts +4 -0
- package/es/core/editor/components/settings/node/NodeRelateResourceButton.js +22 -0
- package/es/core/editor/components/settings/node/TopoTreeSelect.d.ts +1 -0
- package/es/core/editor/components/settings/node/TopoTreeSelect.js +40 -0
- package/es/core/editor/components/settings/text/TextPropertyView.js +32 -146
- package/es/core/editor/components/settings/view/ViewPropertyView.js +7 -7
- package/es/core/editor/components/titlebar/TopoEditorTitleBar.js +3 -4
- package/es/core/editor/{buildContextmenu.d.ts → contextmenu/buildContextmenu.d.ts} +1 -4
- package/es/core/editor/contextmenu/buildContextmenu.js +10 -0
- package/es/core/models/plugins/resourceWebControllUrl.js +1 -1
- package/es/core/utils/showMessage.js +1 -1
- package/es/core/viewer/components/plugins/ResourceDetail/topoDrawer.js +3 -3
- package/es/core/viewer/components/plugins/ResourceWebControllUrlSettingDialog.js +5 -5
- package/es/core/viewer/components/titlebar/TopoViewerTitleBar.js +1 -1
- package/es/core/viewer/components/titlebar/ViewerTools.js +4 -4
- package/es/core/viewer/components/titlebar/widgets/EditButton.js +1 -1
- package/es/core/viewer/components/titlebar/widgets/SearchWidget.js +1 -1
- package/es/hooks/usePolling.js +0 -1
- package/es/hooks/useSelection.js +9 -3
- package/es/hooks/useTopoEdit.js +2 -2
- package/es/models/iconManage.js +2 -2
- package/es/models/linkDynamicStyleConfig.js +1 -1
- package/es/models/topoBizMod.js +1 -1
- package/es/plugins/useSelectionPlugin.d.ts +23 -0
- package/es/plugins/useSelectionPlugin.js +84 -0
- package/es/style.js +30 -42
- package/es/topoCenter/components/Topology.js +2 -2
- package/es/topoCenter/viewer/index.js +2 -2
- package/es/utils/htElementDataUtil.js +1 -1
- package/es/utils/topoData.js +1 -1
- package/es/utils/tree.js +1 -1
- package/lib/common/components/ResourceTable/ResourceTable.js +2 -4
- package/lib/components/BatchAttrMetric/index.js +2 -4
- package/lib/components/BatchAttrMetric/setting.js +2 -4
- package/lib/components/Drawer/index.js +2 -1
- package/lib/components/Drawer/index.module.scss +13 -0
- package/lib/components/IndexSettingDrawer/IndexList.js +2 -4
- package/lib/components/IndexSettingDrawer/index.js +2 -4
- package/lib/components/Link/form.js +2 -4
- package/lib/components/Link/hook.js +2 -4
- package/lib/components/Link/index.js +2 -4
- package/lib/components/Link/setting.js +2 -4
- package/lib/components/MultiResourceDrawer/Content.js +2 -4
- package/lib/components/MultiResourceDrawer/index.js +2 -4
- package/lib/components/ResourceList/ResourceSelect.js +5 -5
- package/lib/components/ResourceList/ResourceSelect.module.scss +7 -0
- package/lib/components/ResourceList/ResourceSelectConnect.js +2 -4
- package/lib/components/ResourceSelect/DefaultResourceSelectDrawer.js +2 -4
- package/lib/components/ResourceSelect/ResourceSelectDrawer.js +5 -5
- package/lib/components/SingleResourceDrawer/index.js +2 -4
- package/lib/core/{editor/components/settings/group/GroupNodeList → common}/icons/defaultIcons.d.ts +15 -0
- package/lib/core/{editor/components/settings/group/GroupNodeList → common}/icons/defaultIcons.js +68 -1
- package/lib/core/common/text.module.scss +5 -0
- package/lib/core/components/TopoApp.js +2 -4
- package/lib/core/components/TopoAppProvider.js +2 -4
- package/lib/core/components/TopoAppView.js +2 -4
- package/lib/core/components/TopoView/Topo.js +2 -16
- package/lib/core/components/TopoView/Topo404.js +2 -4
- package/lib/core/components/TopoView/TopoContent.js +2 -4
- package/lib/core/components/TopoView/TopoNoPermission.js +2 -4
- package/lib/core/components/TopoView/topoView.js +2 -4
- package/lib/core/components/buildProvider.js +2 -4
- package/lib/core/components/titlebar/TitleBar.js +2 -4
- package/lib/core/components/titlebar/widgets/TitleWidget.js +2 -4
- package/lib/core/editor/components/LinkDynamicStyleSettingDrawer/RuleSetting.js +2 -4
- package/lib/core/editor/components/LinkDynamicStyleSettingDrawer/index.js +2 -4
- package/lib/core/editor/components/LinkDynamicStyleSettingDrawer/rule/ColorPicker.js +2 -4
- package/lib/core/editor/components/LinkDynamicStyleSettingDrawer/rule/ColorPicker.module.scss +7 -3
- package/lib/core/editor/components/LinkDynamicStyleSettingDrawer/rule/RuleCondition.js +2 -4
- package/lib/core/editor/components/LinkDynamicStyleSettingDrawer/rule/RuleStyle.js +2 -4
- package/lib/core/editor/components/ResourceViewAttributeSetting/ResourceViewAttributeSettingPlugin.js +2 -4
- package/lib/core/editor/components/ResourceViewAttributeSetting/Setting.js +2 -4
- package/lib/core/editor/components/iconManage/IconManage.js +2 -4
- package/lib/core/editor/components/iconManage/RenameDialog.js +2 -4
- package/lib/core/editor/components/iconManage/UploadIconDialog.js +2 -2
- package/lib/core/editor/components/iconManage/UploadIconDialogWrapper.js +2 -4
- package/lib/core/editor/components/settings/README.md +2 -0
- package/lib/core/editor/components/settings/Settings.js +45 -44
- package/lib/core/editor/components/settings/Settings.module.scss +6 -1
- package/lib/core/editor/components/settings/SettingsForm.js +2 -4
- package/lib/core/editor/components/settings/Style.js +2 -4
- package/lib/core/editor/components/settings/common/LayoutSettings.js +2 -4
- package/lib/core/editor/components/settings/common/LineType.js +2 -4
- package/lib/core/editor/components/settings/common/NodeAlignType.js +2 -4
- package/lib/core/editor/components/settings/common/{NodeSizeInput.d.ts → NodeSizeInput/NodeSizeInput.d.ts} +0 -0
- package/lib/core/editor/components/settings/common/{NodeSizeInput.js → NodeSizeInput/NodeSizeInput.js} +4 -4
- package/lib/core/editor/components/settings/common/NodeSizeInput/img/icon_/350/247/243/351/224/201.svg +16 -0
- package/lib/core/editor/components/settings/common/NodeSizeInput/img/icon_/351/224/201.svg +15 -0
- package/lib/core/editor/components/settings/common/text/FontStyleCheckbox.d.ts +1 -0
- package/lib/core/editor/components/settings/common/text/FontStyleCheckbox.js +68 -0
- package/lib/core/editor/components/settings/common/text/FontStyleCheckbox.module.scss +31 -0
- package/lib/core/editor/components/settings/common/text/TextStyle.d.ts +1 -0
- package/lib/core/editor/components/settings/common/text/TextStyle.js +150 -0
- package/lib/core/editor/components/settings/common/text/fontStyleUtil.d.ts +19 -0
- package/lib/core/editor/components/settings/common/text/fontStyleUtil.js +58 -0
- package/lib/core/editor/components/settings/common/text/img/bold.svg +12 -0
- package/lib/core/editor/components/settings/common/text/img/italics.svg +10 -0
- package/lib/core/editor/components/settings/common/text/img/underline.svg +12 -0
- package/lib/core/editor/components/settings/group/GroupNodeList/GroupNodeList.js +2 -4
- package/lib/core/editor/components/settings/group/GroupNodeList/ResourceList.js +24 -11
- package/lib/core/editor/components/settings/group/GroupNodeList/ResourceList.module.scss +16 -0
- package/lib/core/editor/components/settings/group/GroupNodeList/ResourceSelectButton.js +2 -4
- package/lib/core/editor/components/settings/group/GroupNodeList/icon.d.ts +10 -0
- package/lib/core/editor/components/settings/group/GroupNodeList/icon.js +23 -1
- package/lib/core/editor/components/settings/layer/LayerSettingsForm.js +2 -4
- package/lib/core/editor/components/settings/link/LinkPropertyView.js +2 -4
- package/lib/core/editor/components/settings/node/NodeIconSelect.d.ts +1 -0
- package/lib/core/editor/components/settings/node/NodeIconSelect.js +57 -0
- package/lib/core/editor/components/settings/node/NodePropertyView.d.ts +1 -1
- package/lib/core/editor/components/settings/node/NodePropertyView.js +127 -131
- package/lib/core/editor/components/settings/node/NodeRelateResourceButton.d.ts +4 -0
- package/lib/core/editor/components/settings/node/NodeRelateResourceButton.js +31 -0
- package/lib/core/editor/components/settings/node/TopoTreeSelect.d.ts +1 -0
- package/lib/core/editor/components/settings/node/TopoTreeSelect.js +53 -0
- package/lib/core/editor/components/settings/text/TextPropertyView.js +31 -153
- package/lib/core/editor/components/settings/view/ViewPropertyView.js +3 -5
- package/lib/core/editor/components/titlebar/TopoEditorTitleBar.js +4 -7
- package/lib/core/editor/components/titlebar/widgets/SaveButton.js +2 -4
- package/lib/core/editor/{buildContextmenu.d.ts → contextmenu/buildContextmenu.d.ts} +1 -4
- package/lib/core/editor/{buildContextmenu.js → contextmenu/buildContextmenu.js} +3 -7
- package/lib/core/models/cache/DictCache.js +2 -4
- package/lib/core/viewer/components/plugins/ResourceDetail/ResourceDetailDrawerPlugin.js +2 -4
- package/lib/core/viewer/components/plugins/ResourceDetail/topoDrawer.js +2 -4
- package/lib/core/viewer/components/plugins/ResourceWebControllUrlSettingDialog.js +2 -4
- package/lib/core/viewer/components/titlebar/TopoViewerTitleBar.js +2 -4
- package/lib/core/viewer/components/titlebar/ViewerTools.js +2 -4
- package/lib/core/viewer/components/titlebar/widgets/EditButton.js +2 -4
- package/lib/core/viewer/components/titlebar/widgets/SearchWidget.js +2 -4
- package/lib/hooks/usePolling.js +0 -1
- package/lib/hooks/useSelection.js +9 -3
- package/lib/hooks/useTopoEdit.js +2 -4
- package/lib/models/topoBizMod.js +1 -1
- package/lib/models/topoCreateMod.js +2 -4
- package/lib/plugins/useSelectionPlugin.d.ts +23 -0
- package/lib/plugins/useSelectionPlugin.js +90 -0
- package/lib/style.js +3 -15
- package/lib/topoCenter/components/Topology.js +2 -4
- package/lib/topoCenter/viewer/components/TopologyViewer.js +2 -4
- package/lib/utils/htElementDataUtil.js +1 -1
- package/lib/utils/topoData.js +1 -1
- package/lib/utils/tree.js +1 -1
- package/package.json +6 -6
- package/es/core/editor/buildContextmenu.js +0 -14
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import _Tab from "@alifd/next/
|
|
2
|
-
import _NumberPicker from "@alifd/next/
|
|
3
|
-
import _Input from "@alifd/next/
|
|
4
|
-
import _Field from "@alifd/next/
|
|
5
|
-
import _Select from "@alifd/next/
|
|
6
|
-
import _Grid from "@alifd/next/
|
|
7
|
-
import _Form from "@alifd/next/
|
|
1
|
+
import _Tab from "@alifd/next/lib/tab";
|
|
2
|
+
import _NumberPicker from "@alifd/next/lib/number-picker";
|
|
3
|
+
import _Input from "@alifd/next/lib/input";
|
|
4
|
+
import _Field from "@alifd/next/lib/field";
|
|
5
|
+
import _Select from "@alifd/next/lib/select";
|
|
6
|
+
import _Grid from "@alifd/next/lib/grid";
|
|
7
|
+
import _Form from "@alifd/next/lib/form";
|
|
8
8
|
import React, { useEffect } from 'react';
|
|
9
9
|
import isEqual from 'lodash/isEqual';
|
|
10
10
|
import ColorPicker from "../LinkDynamicStyleSettingDrawer/rule/ColorPicker";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import _Button from "@alifd/next/
|
|
2
|
-
import _Icon from "@alifd/next/
|
|
1
|
+
import _Button from "@alifd/next/lib/button";
|
|
2
|
+
import _Icon from "@alifd/next/lib/icon";
|
|
3
3
|
import React, { useState, useEffect, useRef, useCallback } from 'react';
|
|
4
4
|
export default function LineType(props) {
|
|
5
5
|
return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(_Button, null, /*#__PURE__*/React.createElement(_Icon, {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import _Button from "@alifd/next/
|
|
2
|
-
import _Icon from "@alifd/next/
|
|
1
|
+
import _Button from "@alifd/next/lib/button";
|
|
2
|
+
import _Icon from "@alifd/next/lib/icon";
|
|
3
3
|
import React, { useState, useEffect, useRef, useCallback } from 'react';
|
|
4
4
|
export default function NodeAlignType(props) {
|
|
5
5
|
return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(_Button, null, /*#__PURE__*/React.createElement(_Icon, {
|
|
File without changes
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import _NumberPicker from "@alifd/next/
|
|
2
|
-
import _Field from "@alifd/next/
|
|
3
|
-
import _Grid from "@alifd/next/
|
|
4
|
-
import _Form from "@alifd/next/
|
|
1
|
+
import _NumberPicker from "@alifd/next/lib/number-picker";
|
|
2
|
+
import _Field from "@alifd/next/lib/field";
|
|
3
|
+
import _Grid from "@alifd/next/lib/grid";
|
|
4
|
+
import _Form from "@alifd/next/lib/form";
|
|
5
5
|
import React, { useState, useEffect, useRef, useCallback } from 'react';
|
|
6
6
|
var FormItem = _Form.Item;
|
|
7
7
|
var Row = _Grid.Row,
|
|
@@ -33,6 +33,7 @@ export default function NodeSizeInput(props) {
|
|
|
33
33
|
}, /*#__PURE__*/React.createElement(_NumberPicker, {
|
|
34
34
|
name: "width",
|
|
35
35
|
min: 1,
|
|
36
|
+
max: 2000,
|
|
36
37
|
placeholder: "\u8BF7\u8F93\u5165",
|
|
37
38
|
style: {
|
|
38
39
|
width: '100%'
|
|
@@ -43,6 +44,7 @@ export default function NodeSizeInput(props) {
|
|
|
43
44
|
}, /*#__PURE__*/React.createElement(_NumberPicker, {
|
|
44
45
|
name: "height",
|
|
45
46
|
min: 1,
|
|
47
|
+
max: 2000,
|
|
46
48
|
placeholder: "\u8BF7\u8F93\u5165",
|
|
47
49
|
style: {
|
|
48
50
|
width: '100%'
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
+
<!-- Generator: Sketch 63.1 (92452) - https://sketch.com -->
|
|
4
|
+
<title>topo/source/Icon/解锁</title>
|
|
5
|
+
<desc>Created with Sketch.</desc>
|
|
6
|
+
<g id="topo/source/Icon/解锁" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
7
|
+
<g id="Icon-HTSCIT_lianjieduankai" fill-rule="nonzero">
|
|
8
|
+
<g id="编组">
|
|
9
|
+
<rect id="矩形" fill="#000000" opacity="0" x="0" y="0" width="16" height="16"></rect>
|
|
10
|
+
<path d="M12.16836,11.80814 L4.69432,4.33403 L5.41203,3.61632 L12.88607,11.09043 L12.16836,11.80814 Z M6.20072,10.5109 L5.48301,9.79326 L6.9976,8.27867 L7.71531,8.99638 L6.20072,10.5109 Z" id="形状" fill="#4D6277"></path>
|
|
11
|
+
<polygon id="路径" fill="#4D6277" points="9.79536 5.48126 10.51307 6.19897 8.99848 7.71363 8.28077 6.99592"></polygon>
|
|
12
|
+
<path d="M9.729,3.303 L12.704,6.271 L10.128,8.847 L10.842,9.554 L13.775,6.621 L14.132,6.264 L13.775,5.907 L10.086,2.225 L9.729,1.868 L9.379,2.225 L6.439,5.158 L7.16,5.872 L9.729,3.303 Z M6.264,12.711 L3.296,9.743 L5.879,7.16 L5.158,6.439 L2.225,9.372 L1.868,9.729 L2.225,10.086 L5.914,13.775 L6.271,14.132 L6.621,13.775 L9.561,10.842 L8.847,10.128 L6.264,12.711 Z" id="形状" fill="#4D6277"></path>
|
|
13
|
+
</g>
|
|
14
|
+
</g>
|
|
15
|
+
</g>
|
|
16
|
+
</svg>
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
+
<!-- Generator: Sketch 63.1 (92452) - https://sketch.com -->
|
|
4
|
+
<title>topo/source/Icon/锁</title>
|
|
5
|
+
<desc>Created with Sketch.</desc>
|
|
6
|
+
<g id="topo/source/Icon/锁" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
7
|
+
<g id="Icon-HTSCIT_lianjie" fill-rule="nonzero">
|
|
8
|
+
<g id="编组">
|
|
9
|
+
<rect id="矩形" fill="#000000" opacity="0" x="0" y="0" width="16" height="16"></rect>
|
|
10
|
+
<path d="M6.264,12.711 L3.296,9.743 L5.879,7.16 L5.158,6.439 L2.225,9.372 L1.868,9.729 L2.225,10.086 L5.914,13.775 L6.271,14.132 L6.621,13.775 L9.561,10.842 L8.847,10.128 L6.264,12.711 Z M9.729,3.303 L12.704,6.271 L10.128,8.847 L10.842,9.554 L13.775,6.621 L14.132,6.264 L13.775,5.907 L10.086,2.225 L9.729,1.868 L9.379,2.225 L6.439,5.158 L7.16,5.872 L9.729,3.303 Z" id="形状" fill="#4D6277"></path>
|
|
11
|
+
<polygon id="路径" fill="#4D6277" points="10.51846 6.20114 6.20226 10.51727 5.48462 9.79956 9.80075 5.48336"></polygon>
|
|
12
|
+
</g>
|
|
13
|
+
</g>
|
|
14
|
+
</g>
|
|
15
|
+
</svg>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function FontStyleCheckbox(props: any): JSX.Element;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import _Button from "@alifd/next/lib/button";
|
|
2
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
3
|
+
import React, { useState, useEffect, useRef, useCallback } from 'react';
|
|
4
|
+
import classnames from 'classnames';
|
|
5
|
+
import styles from "./FontStyleCheckbox.module.scss";
|
|
6
|
+
import b from "./img/bold.svg";
|
|
7
|
+
import i from "./img/italics.svg";
|
|
8
|
+
import u from "./img/underline.svg";
|
|
9
|
+
export default function FontStyleCheckbox(props) {
|
|
10
|
+
var value = props.value,
|
|
11
|
+
onChange = props.onChange;
|
|
12
|
+
var options = [{
|
|
13
|
+
name: 'bold',
|
|
14
|
+
img: b,
|
|
15
|
+
title: '粗体'
|
|
16
|
+
}, {
|
|
17
|
+
name: 'italic',
|
|
18
|
+
img: i,
|
|
19
|
+
title: '斜体'
|
|
20
|
+
}, {
|
|
21
|
+
name: 'underline',
|
|
22
|
+
img: u,
|
|
23
|
+
title: '下划线'
|
|
24
|
+
}];
|
|
25
|
+
|
|
26
|
+
var handleClick = function handleClick(name) {
|
|
27
|
+
var _extends2;
|
|
28
|
+
|
|
29
|
+
onChange(_extends({}, value, (_extends2 = {}, _extends2[name] = !value[name], _extends2)));
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
return /*#__PURE__*/React.createElement(_Button.Group, {
|
|
33
|
+
className: styles.buttonGroup
|
|
34
|
+
}, options.map(function (item) {
|
|
35
|
+
var _classnames;
|
|
36
|
+
|
|
37
|
+
return /*#__PURE__*/React.createElement(_Button, {
|
|
38
|
+
key: item.name,
|
|
39
|
+
className: classnames(styles.button, (_classnames = {}, _classnames[styles.checked] = value[item.name], _classnames)),
|
|
40
|
+
onClick: function onClick() {
|
|
41
|
+
handleClick(item.name);
|
|
42
|
+
},
|
|
43
|
+
title: item.title
|
|
44
|
+
}, /*#__PURE__*/React.createElement("img", {
|
|
45
|
+
src: item.img,
|
|
46
|
+
alt: ""
|
|
47
|
+
}));
|
|
48
|
+
}));
|
|
49
|
+
}
|
|
50
|
+
;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
@import "@alifd/theme-19926/variables";
|
|
2
|
+
|
|
3
|
+
.buttonGroup {
|
|
4
|
+
display: flex;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.button {
|
|
8
|
+
flex: 1;
|
|
9
|
+
display: flex;
|
|
10
|
+
align-items: center;
|
|
11
|
+
justify-content: center;
|
|
12
|
+
|
|
13
|
+
&:global {
|
|
14
|
+
&.next-btn.next-btn-normal:hover {
|
|
15
|
+
background: #F2F7FD;
|
|
16
|
+
border: 1px solid $input-border-color;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.checked {
|
|
23
|
+
|
|
24
|
+
&:global {
|
|
25
|
+
&.next-btn.next-btn-normal {
|
|
26
|
+
background: #F2F7FD;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
}
|
|
31
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function TextStyle(props: any): JSX.Element;
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import _NumberPicker from "@alifd/next/lib/number-picker";
|
|
2
|
+
import _Form from "@alifd/next/lib/form";
|
|
3
|
+
import _Field from "@alifd/next/lib/field";
|
|
4
|
+
import _Select from "@alifd/next/lib/select";
|
|
5
|
+
import React, { useState, useEffect, useRef, useCallback } from 'react';
|
|
6
|
+
import ColorPicker from "../../../LinkDynamicStyleSettingDrawer/rule/ColorPicker";
|
|
7
|
+
import FontStyleCheckbox from "./FontStyleCheckbox";
|
|
8
|
+
var Option = _Select.Option;
|
|
9
|
+
|
|
10
|
+
function parseValue(value) {
|
|
11
|
+
return {
|
|
12
|
+
fontFamily: value.font.fontFamily || '黑体',
|
|
13
|
+
fontSize: value.font.fontSize || 12,
|
|
14
|
+
color: value.color || '#000000',
|
|
15
|
+
fontStyleChecked: {
|
|
16
|
+
underline: value.underline,
|
|
17
|
+
bold: value.font.bold,
|
|
18
|
+
italic: value.font.italic
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export default function TextStyle(props) {
|
|
24
|
+
var value = props.value,
|
|
25
|
+
_onChange = props.onChange;
|
|
26
|
+
|
|
27
|
+
var field = _Field.useField({
|
|
28
|
+
autoUnmount: false,
|
|
29
|
+
values: parseValue(value),
|
|
30
|
+
onChange: function onChange(name, value) {
|
|
31
|
+
var values = field.getValues();
|
|
32
|
+
var aValues = {
|
|
33
|
+
color: values.color,
|
|
34
|
+
underline: values.fontStyleChecked.underline,
|
|
35
|
+
font: {
|
|
36
|
+
fontFamily: values.fontFamily,
|
|
37
|
+
fontSize: values.fontSize,
|
|
38
|
+
bold: values.fontStyleChecked.bold,
|
|
39
|
+
italic: values.fontStyleChecked.italic
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
_onChange && _onChange(aValues);
|
|
43
|
+
}
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
useEffect(function () {
|
|
47
|
+
field.setValues(parseValue(value));
|
|
48
|
+
}, [value]);
|
|
49
|
+
return /*#__PURE__*/React.createElement(_Form, {
|
|
50
|
+
field: field,
|
|
51
|
+
labelAlign: "top",
|
|
52
|
+
component: "div"
|
|
53
|
+
}, /*#__PURE__*/React.createElement(_Form.Item, null, /*#__PURE__*/React.createElement("div", {
|
|
54
|
+
style: {
|
|
55
|
+
display: 'flex'
|
|
56
|
+
}
|
|
57
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
58
|
+
style: {
|
|
59
|
+
flex: 1,
|
|
60
|
+
paddingRight: 12
|
|
61
|
+
}
|
|
62
|
+
}, /*#__PURE__*/React.createElement(_Form.Item, {
|
|
63
|
+
label: "\u5B57\u4F53"
|
|
64
|
+
}, /*#__PURE__*/React.createElement(_Select, {
|
|
65
|
+
defaultValue: "\u9ED1\u4F53",
|
|
66
|
+
name: "fontFamily",
|
|
67
|
+
style: {
|
|
68
|
+
width: '100%',
|
|
69
|
+
marginRight: 8
|
|
70
|
+
}
|
|
71
|
+
}, /*#__PURE__*/React.createElement(Option, {
|
|
72
|
+
value: "\u5B8B\u4F53"
|
|
73
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
74
|
+
style: {
|
|
75
|
+
fontFamily: '宋体'
|
|
76
|
+
}
|
|
77
|
+
}, "\u5B8B\u4F53")), /*#__PURE__*/React.createElement(Option, {
|
|
78
|
+
value: "\u9ED1\u4F53"
|
|
79
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
80
|
+
style: {
|
|
81
|
+
fontFamily: '黑体'
|
|
82
|
+
}
|
|
83
|
+
}, "\u9ED1\u4F53")), /*#__PURE__*/React.createElement(Option, {
|
|
84
|
+
value: "Arial"
|
|
85
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
86
|
+
style: {
|
|
87
|
+
fontFamily: 'Arial'
|
|
88
|
+
}
|
|
89
|
+
}, "Arial"))))), /*#__PURE__*/React.createElement("div", {
|
|
90
|
+
style: {
|
|
91
|
+
width: 70
|
|
92
|
+
}
|
|
93
|
+
}, /*#__PURE__*/React.createElement(_Form.Item, {
|
|
94
|
+
label: "\u5B57\u53F7",
|
|
95
|
+
hasFeedback: true,
|
|
96
|
+
required: true,
|
|
97
|
+
requiredMessage: "\u4E0D\u80FD\u4E3A\u7A7A",
|
|
98
|
+
requiredTrigger: "onBlur",
|
|
99
|
+
asterisk: false
|
|
100
|
+
}, /*#__PURE__*/React.createElement(_NumberPicker, {
|
|
101
|
+
name: "fontSize",
|
|
102
|
+
min: 8,
|
|
103
|
+
max: 36,
|
|
104
|
+
style: {
|
|
105
|
+
width: '100%',
|
|
106
|
+
marginRight: 8
|
|
107
|
+
},
|
|
108
|
+
placeholder: "\u8BF7\u8F93\u5165"
|
|
109
|
+
})))), /*#__PURE__*/React.createElement("div", {
|
|
110
|
+
style: {
|
|
111
|
+
display: 'flex'
|
|
112
|
+
}
|
|
113
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
114
|
+
style: {
|
|
115
|
+
flex: 1,
|
|
116
|
+
paddingRight: 12
|
|
117
|
+
}
|
|
118
|
+
}, /*#__PURE__*/React.createElement(_Form.Item, {
|
|
119
|
+
label: "\u6837\u5F0F"
|
|
120
|
+
}, /*#__PURE__*/React.createElement(FontStyleCheckbox, {
|
|
121
|
+
name: "fontStyleChecked"
|
|
122
|
+
}))), /*#__PURE__*/React.createElement("div", {
|
|
123
|
+
style: {
|
|
124
|
+
width: 70
|
|
125
|
+
}
|
|
126
|
+
}, /*#__PURE__*/React.createElement(_Form.Item, {
|
|
127
|
+
label: "\u989C\u8272"
|
|
128
|
+
}, /*#__PURE__*/React.createElement(ColorPicker, {
|
|
129
|
+
name: "color",
|
|
130
|
+
align: "br"
|
|
131
|
+
}))))));
|
|
132
|
+
}
|
|
133
|
+
;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export default fontStyleUtil;
|
|
2
|
+
declare namespace fontStyleUtil {
|
|
3
|
+
export function toMap(font?: string): {
|
|
4
|
+
fontFamily: string;
|
|
5
|
+
fontSize: number;
|
|
6
|
+
bold: boolean;
|
|
7
|
+
italic: boolean;
|
|
8
|
+
};
|
|
9
|
+
export function toMap(font?: string): {
|
|
10
|
+
fontFamily: string;
|
|
11
|
+
fontSize: number;
|
|
12
|
+
bold: boolean;
|
|
13
|
+
italic: boolean;
|
|
14
|
+
};
|
|
15
|
+
export function build(style: any): string;
|
|
16
|
+
export function build(style: any): string;
|
|
17
|
+
export function getFontStyleMap(obj: any, prefix: any): {};
|
|
18
|
+
export function getFontStyleMap(obj: any, prefix: any): {};
|
|
19
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
var fontStyleUtil = {
|
|
2
|
+
// 字体样式格式: bold italic 12px 黑体 或 12px 黑体
|
|
3
|
+
toMap: function toMap(font) {
|
|
4
|
+
if (font === void 0) {
|
|
5
|
+
font = '';
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
var arr = font.trim().split(' ');
|
|
9
|
+
var bold = font.indexOf('bold') > -1;
|
|
10
|
+
var italic = font.indexOf('italic') > -1;
|
|
11
|
+
var fontFamily, fontSize;
|
|
12
|
+
|
|
13
|
+
if (arr.length) {
|
|
14
|
+
fontFamily = arr[arr.length - 1];
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
if (arr.length >= 2) {
|
|
18
|
+
fontSize = parseInt(arr[arr.length - 2].replace('px', ''), 10);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
return {
|
|
22
|
+
fontFamily: fontFamily,
|
|
23
|
+
fontSize: fontSize,
|
|
24
|
+
bold: bold,
|
|
25
|
+
italic: italic
|
|
26
|
+
};
|
|
27
|
+
},
|
|
28
|
+
// 字体样式格式: bold italic 12px 黑体 或 12px 黑体
|
|
29
|
+
build: function build(style) {
|
|
30
|
+
var font = '';
|
|
31
|
+
|
|
32
|
+
if (style.font.bold) {
|
|
33
|
+
font += 'bold ';
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
if (style.font.italic) {
|
|
37
|
+
font += 'italic ';
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
return "" + font + style.font.fontSize + "px " + style.font.fontFamily;
|
|
41
|
+
},
|
|
42
|
+
getFontStyleMap: function getFontStyleMap(obj, prefix) {
|
|
43
|
+
var map = {};
|
|
44
|
+
Object.keys(obj).forEach(function (key) {
|
|
45
|
+
if (key.startsWith(prefix)) {
|
|
46
|
+
map[key.replace(prefix, '')] = obj[key];
|
|
47
|
+
}
|
|
48
|
+
});
|
|
49
|
+
console.error(obj, prefix, map);
|
|
50
|
+
return map;
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
export default fontStyleUtil;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
+
<!-- Generator: Sketch 63.1 (92452) - https://sketch.com -->
|
|
4
|
+
<title>topo/source/Icon/bold</title>
|
|
5
|
+
<desc>Created with Sketch.</desc>
|
|
6
|
+
<g id="topo/source/Icon/bold" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
7
|
+
<rect id="矩形" fill="#000000" fill-rule="nonzero" opacity="0" x="0" y="0" width="16" height="16"></rect>
|
|
8
|
+
<g id="Icon-zitijiacu" transform="translate(4.000000, 3.000000)" fill="#4D6277" fill-rule="nonzero">
|
|
9
|
+
<path d="M7.01125,5.739125 C6.75175,5.339375 6.368875,5.0735 5.863,4.941875 L5.863,4.916375 C6.131125,4.788875 6.3565,4.646375 6.539125,4.488875 C6.722125,4.34 6.862375,4.1825 6.96025,4.01675 C7.1515,3.668 7.243,3.302375 7.234375,2.9195 C7.234375,2.171 7.002625,1.569125 6.539125,1.113875 C6.07975,0.663125 5.39275,0.433625 4.4785,0.425 L0.52225,0.425 L0.52225,9.7265 L4.79125,9.7265 C5.522875,9.7265 6.133,9.482 6.622375,8.992625 C7.115875,8.524625 7.36675,7.889 7.375,7.085375 C7.375,6.6005 7.253875,6.151625 7.01125,5.739125 Z M2.035,1.681625 L4.319125,1.681625 C4.833625,1.69025 5.212375,1.8155 5.454625,2.058125 C5.701375,2.317625 5.82475,2.6345 5.82475,3.00875 C5.82475,3.383 5.701375,3.6935 5.454625,3.94025 C5.212375,4.208 4.833625,4.34225 4.319125,4.34225 L2.035,4.34225 L2.035,1.681625 Z M5.601625,7.965875 C5.359375,8.24225 4.9765,8.38475 4.453375,8.393375 L2.035,8.393375 L2.035,5.59925 L4.453,5.59925 C4.976125,5.6075 5.359,5.745875 5.60125,6.014 C5.8435,6.28625 5.965,6.613625 5.965,6.9965 C5.965,7.370375 5.843875,7.693625 5.601625,7.965875 L5.601625,7.965875 Z" id="形状"></path>
|
|
10
|
+
</g>
|
|
11
|
+
</g>
|
|
12
|
+
</svg>
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
+
<!-- Generator: Sketch 63.1 (92452) - https://sketch.com -->
|
|
4
|
+
<title>topo/source/Icon/italics</title>
|
|
5
|
+
<desc>Created with Sketch.</desc>
|
|
6
|
+
<g id="topo/source/Icon/italics" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
7
|
+
<rect id="矩形" fill="#000000" fill-rule="nonzero" opacity="0" x="2" y="2" width="12" height="12"></rect>
|
|
8
|
+
<polygon id="路径" fill="#4D6277" fill-rule="nonzero" points="8.77666667 4.29166666 7.19333333 12.2083333 8.77666667 12.2083333 8.77666667 13 4.02666667 13 4.02666667 12.2083333 5.60999999 12.2083333 7.19333333 4.29166666 5.60999999 4.29166666 5.60999999 3.5 10.36 3.5 10.36 4.29166666"></polygon>
|
|
9
|
+
</g>
|
|
10
|
+
</svg>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<svg width="16px" height="16px" viewBox="0 0 16 16" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
3
|
+
<!-- Generator: Sketch 63.1 (92452) - https://sketch.com -->
|
|
4
|
+
<title>topo/source/Icon/underline</title>
|
|
5
|
+
<desc>Created with Sketch.</desc>
|
|
6
|
+
<g id="topo/source/Icon/underline" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
|
7
|
+
<rect id="矩形" fill="#000000" fill-rule="nonzero" opacity="0" x="0" y="0" width="16" height="16"></rect>
|
|
8
|
+
<g id="Icon-zitixiahuaxian" transform="translate(3.000000, 3.000000)" fill="#4D6277" fill-rule="nonzero">
|
|
9
|
+
<path d="M5,8.507375 C7.01929112,8.507375 8.65625,6.87041612 8.65625,4.851125 L8.65625,0.05 L7.34375,0.05 L7.34375,4.851125 C7.34375,6.14554238 6.29441738,7.194875 5,7.194875 C3.70558262,7.194875 2.65625,6.14554238 2.65625,4.851125 L2.65625,0.05 L1.34375,0.05 L1.34375,4.851125 C1.34375,6.87041612 2.98070888,8.507375 5,8.507375 Z M9.125,9.380375 L0.875,9.380375 C0.667893219,9.380375 0.5,9.54826822 0.5,9.755375 C0.5,9.96248178 0.667893219,10.130375 0.875,10.130375 L9.125,10.130375 C9.33210678,10.130375 9.5,9.96248178 9.5,9.755375 C9.5,9.54826822 9.33210678,9.380375 9.125,9.380375 Z" id="形状"></path>
|
|
10
|
+
</g>
|
|
11
|
+
</g>
|
|
12
|
+
</svg>
|
|
@@ -1,10 +1,30 @@
|
|
|
1
|
-
import _List from "@alifd/next/
|
|
2
|
-
import _Avatar from "@alifd/next/es/avatar";
|
|
1
|
+
import _List from "@alifd/next/lib/list";
|
|
3
2
|
import React, { useState, useEffect, useRef, useCallback } from 'react';
|
|
4
3
|
import styles from "./ResourceList.module.scss";
|
|
5
4
|
|
|
6
5
|
function ResourceList(props) {
|
|
7
6
|
var data = props.data;
|
|
7
|
+
|
|
8
|
+
var renderIcon = function renderIcon(src) {
|
|
9
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
10
|
+
style: {
|
|
11
|
+
width: 28,
|
|
12
|
+
height: 28,
|
|
13
|
+
background: "url(" + src + ") no-repeat center center"
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
var renderIcon2 = function renderIcon2(src) {
|
|
19
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
20
|
+
className: styles.iconWarp
|
|
21
|
+
}, /*#__PURE__*/React.createElement("img", {
|
|
22
|
+
src: src,
|
|
23
|
+
className: styles.iconImg,
|
|
24
|
+
alt: ""
|
|
25
|
+
}));
|
|
26
|
+
};
|
|
27
|
+
|
|
8
28
|
return /*#__PURE__*/React.createElement("div", {
|
|
9
29
|
className: styles.list
|
|
10
30
|
}, /*#__PURE__*/React.createElement(_List, {
|
|
@@ -14,11 +34,7 @@ function ResourceList(props) {
|
|
|
14
34
|
return /*#__PURE__*/React.createElement(_List.Item, {
|
|
15
35
|
key: i,
|
|
16
36
|
extra: item.money,
|
|
17
|
-
media:
|
|
18
|
-
src: item.img,
|
|
19
|
-
shape: "square",
|
|
20
|
-
size: "small"
|
|
21
|
-
})
|
|
37
|
+
media: renderIcon2(item.img)
|
|
22
38
|
}, item.title);
|
|
23
39
|
}
|
|
24
40
|
}));
|
|
@@ -13,3 +13,19 @@
|
|
|
13
13
|
}
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
|
+
|
|
17
|
+
.iconWarp {
|
|
18
|
+
width: 28px;
|
|
19
|
+
height: 28px;
|
|
20
|
+
line-height: 28px;
|
|
21
|
+
text-align: center;
|
|
22
|
+
|
|
23
|
+
.iconImg {
|
|
24
|
+
display: inline-block;
|
|
25
|
+
width: auto;
|
|
26
|
+
height: auto;
|
|
27
|
+
max-width: 28px;
|
|
28
|
+
max-height: 100%;
|
|
29
|
+
vertical-align: middle;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import _Button from "@alifd/next/
|
|
1
|
+
import _Button from "@alifd/next/lib/button";
|
|
2
2
|
import React, { useState, useEffect, useRef, useCallback } from 'react';
|
|
3
3
|
import ResourceSelectDrawer from "../../../../../../components/ResourceSelect/ResourceSelectDrawer";
|
|
4
4
|
export default function ResourceSelectButton(props) {
|
|
@@ -66,4 +66,14 @@ export function getIconMap(topo: any): {
|
|
|
66
66
|
'editor.icon.balanc.small': string;
|
|
67
67
|
'editor.icon.calendar.small': string;
|
|
68
68
|
};
|
|
69
|
+
/**
|
|
70
|
+
*
|
|
71
|
+
* @param topo
|
|
72
|
+
* @param type {'node' | 'container'}
|
|
73
|
+
* @return {{label: string, icons: *[]}[]}
|
|
74
|
+
*/
|
|
75
|
+
export function getIconGroups(topo: any, type: 'node' | 'container'): {
|
|
76
|
+
label: string;
|
|
77
|
+
icons: any[];
|
|
78
|
+
}[];
|
|
69
79
|
export function getIconById(id: any, topo: any): any;
|
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import defaultIcons from "
|
|
2
|
+
import defaultIcons, { DEFAULT_NODE_ICONS } from "../../../../../common/icons/defaultIcons";
|
|
3
|
+
|
|
4
|
+
function getUserCustomIcons(topo) {
|
|
5
|
+
var uploadIcons = topo.store.getModelState('iconManage').icons;
|
|
6
|
+
return [];
|
|
7
|
+
}
|
|
8
|
+
|
|
3
9
|
export function getIconMap(topo) {
|
|
4
10
|
var bizIconMap = {};
|
|
5
11
|
var uploadIcons = topo.store.getModelState('iconManage').icons.node;
|
|
@@ -8,6 +14,19 @@ export function getIconMap(topo) {
|
|
|
8
14
|
});
|
|
9
15
|
return _extends({}, defaultIcons, bizIconMap);
|
|
10
16
|
}
|
|
17
|
+
/**
|
|
18
|
+
*
|
|
19
|
+
* @param topo
|
|
20
|
+
* @param type {'node' | 'container'}
|
|
21
|
+
* @return {{label: string, icons: *[]}[]}
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
export function getIconGroups(topo, type) {
|
|
25
|
+
return [{
|
|
26
|
+
label: '默认',
|
|
27
|
+
icons: [].concat(DEFAULT_NODE_ICONS, topo.options.icons || [])
|
|
28
|
+
}];
|
|
29
|
+
}
|
|
11
30
|
export function getIconById(id, topo) {
|
|
12
31
|
var iconMap = getIconMap(topo);
|
|
13
32
|
var icon = iconMap[id];
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import _NumberPicker from "@alifd/next/
|
|
2
|
-
import _Input from "@alifd/next/
|
|
3
|
-
import _Field from "@alifd/next/
|
|
1
|
+
import _NumberPicker from "@alifd/next/lib/number-picker";
|
|
2
|
+
import _Input from "@alifd/next/lib/input";
|
|
3
|
+
import _Field from "@alifd/next/lib/field";
|
|
4
4
|
import _extends from "@babel/runtime/helpers/extends";
|
|
5
|
-
import _Radio from "@alifd/next/
|
|
6
|
-
import _Collapse from "@alifd/next/
|
|
7
|
-
import _Select from "@alifd/next/
|
|
8
|
-
import _Grid from "@alifd/next/
|
|
9
|
-
import _Form from "@alifd/next/
|
|
5
|
+
import _Radio from "@alifd/next/lib/radio";
|
|
6
|
+
import _Collapse from "@alifd/next/lib/collapse";
|
|
7
|
+
import _Select from "@alifd/next/lib/select";
|
|
8
|
+
import _Grid from "@alifd/next/lib/grid";
|
|
9
|
+
import _Form from "@alifd/next/lib/form";
|
|
10
10
|
import React, { useState, useEffect } from 'react';
|
|
11
11
|
import ColorPicker from "../../LinkDynamicStyleSettingDrawer/rule/ColorPicker";
|
|
12
12
|
import GroupNodeList from "../group/GroupNodeList/GroupNodeList";
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import _Tab from "@alifd/next/
|
|
2
|
-
import _Input from "@alifd/next/
|
|
3
|
-
import _Field from "@alifd/next/
|
|
1
|
+
import _Tab from "@alifd/next/lib/tab";
|
|
2
|
+
import _Input from "@alifd/next/lib/input";
|
|
3
|
+
import _Field from "@alifd/next/lib/field";
|
|
4
4
|
import _extends from "@babel/runtime/helpers/extends";
|
|
5
|
-
import _Radio from "@alifd/next/
|
|
6
|
-
import _Collapse from "@alifd/next/
|
|
7
|
-
import _Select from "@alifd/next/
|
|
8
|
-
import _Grid from "@alifd/next/
|
|
9
|
-
import _Form from "@alifd/next/
|
|
5
|
+
import _Radio from "@alifd/next/lib/radio";
|
|
6
|
+
import _Collapse from "@alifd/next/lib/collapse";
|
|
7
|
+
import _Select from "@alifd/next/lib/select";
|
|
8
|
+
import _Grid from "@alifd/next/lib/grid";
|
|
9
|
+
import _Form from "@alifd/next/lib/form";
|
|
10
10
|
import React, { useState, useEffect } from 'react';
|
|
11
11
|
import ColorPicker from "../../LinkDynamicStyleSettingDrawer/rule/ColorPicker";
|
|
12
12
|
import GroupNodeList from "../group/GroupNodeList/GroupNodeList";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function NodeIconSelect(props: any): JSX.Element;
|