@zat-design/sisyphus-react 3.4.2 → 3.4.3-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.css +303 -267
- package/dist/less.esm.css +5024 -0
- package/dist/less.esm.js +3 -0
- package/es/ProConfigProvider/index.d.ts +1 -1
- package/es/ProConfigProvider/index.js +24 -2
- package/es/ProEditLabel/style/index.less +1 -2
- package/es/ProEditTable/components/RenderField/index.js +32 -21
- package/es/ProEditTable/index.js +3 -3
- package/es/ProEditTable/propsType.d.ts +1 -1
- package/es/ProEditTable/style/index.less +1 -1
- package/es/ProEditTable/utils/config.js +5 -5
- package/es/ProEditTable/utils/index.js +67 -30
- package/es/ProEditTable/utils/tools.js +3 -1
- package/es/ProEnum/components/Group.d.ts +2 -0
- package/es/ProEnum/components/Group.js +20 -19
- package/es/ProEnum/index.js +4 -3
- package/es/ProEnum/style/index.less +12 -3
- package/es/ProForm/components/base/DatePicker/index.js +2 -2
- package/es/ProForm/components/combination/FormList/index.js +6 -3
- package/es/ProForm/components/combination/FormList/utils.d.ts +2 -1
- package/es/ProForm/components/combination/FormList/utils.js +5 -3
- package/es/ProForm/components/combination/Group/index.js +31 -17
- package/es/ProForm/components/combination/Group/propsType.d.ts +6 -0
- package/es/ProForm/components/combination/Group/style/index.less +4 -4
- package/es/ProForm/components/combination/Group/utils.d.ts +2 -0
- package/es/ProForm/components/combination/Group/utils.js +10 -0
- package/es/ProForm/components/combination/ProTimeLimit/index.js +8 -2
- package/es/ProForm/components/combination/ProTimeLimit/style/index.less +1 -1
- package/es/ProForm/components/index.d.ts +0 -1
- package/es/ProForm/components/index.js +1 -1
- package/es/ProForm/components/render/ConfirmWrapper.js +1 -1
- package/es/ProForm/components/render/Render.js +21 -13
- package/es/ProForm/components/render/RenderFields.d.ts +3 -2
- package/es/ProForm/components/render/RenderFields.js +7 -3
- package/es/ProForm/components/render/propsType.d.ts +2 -5
- package/es/ProForm/index.js +12 -11
- package/es/ProForm/propsType.d.ts +7 -3
- package/es/ProForm/style/index.less +17 -13
- package/es/ProForm/utils/{contrastOriginal.d.ts → diffOriginal.d.ts} +2 -1
- package/es/ProForm/utils/diffOriginal.js +61 -0
- package/es/ProForm/utils/index.d.ts +2 -2
- package/es/ProForm/utils/index.js +7 -2
- package/es/ProForm/utils/rulesCreator.d.ts +7 -1
- package/es/ProForm/utils/rulesCreator.js +33 -3
- package/es/ProForm/utils/transformNames.d.ts +1 -1
- package/es/ProForm/utils/transformNames.js +11 -4
- package/es/ProForm/utils/transformValue.js +2 -2
- package/es/ProForm/utils/useChanged.js +4 -3
- package/es/ProForm/utils/useListChanged.d.ts +1 -1
- package/es/ProForm/utils/useListChanged.js +5 -3
- package/es/ProForm/utils/useRules.js +36 -11
- package/es/ProForm/utils/useShouldUpdate.js +4 -4
- package/es/ProForm/utils/valueType.d.ts +10 -5
- package/es/ProForm/utils/valueType.js +20 -10
- package/es/ProIcon/config/index.d.ts +2 -1
- package/es/ProIcon/config/index.js +191 -133
- package/es/ProIcon/index.d.ts +0 -1
- package/es/ProIcon/index.js +21 -36
- package/es/ProIcon/propsTypes.d.ts +2 -1
- package/es/ProLayout/components/Layout/Header/style/index.less +1 -1
- package/es/ProLayout/components/Layout/Menu/OpenMenu/style/index.less +58 -55
- package/es/ProLayout/components/Layout/Menu/SideMenu/style/index.less +25 -20
- package/es/ProLayout/components/Layout/Menu/style/index.less +52 -56
- package/es/ProLayout/components/ProCollapse/PropTypes.d.ts +5 -0
- package/es/ProLayout/components/ProCollapse/index.js +45 -4
- package/es/ProLayout/components/ProCollapse/style/index.less +29 -11
- package/es/ProLayout/components/ProFooter/index.js +1 -1
- package/es/ProLayout/components/ProFooter/style/index.less +1 -1
- package/es/ProLayout/components/ProHeader/style/index.less +6 -5
- package/es/ProLayout/style/index.less +176 -88
- package/es/ProStep/components/Item/index.js +2 -1
- package/es/ProStep/style/index.less +71 -70
- package/es/ProTable/components/RenderColumn/index.d.ts +1 -1
- package/es/ProTable/components/RenderColumn/index.js +3 -3
- package/es/ProTable/propsType.d.ts +1 -1
- package/es/ProTable/style/index.less +2 -2
- package/es/ProTable/utils.js +9 -9
- package/es/ProTabs/style/index.less +3 -1
- package/es/ProThemeTools/component/PrdTools/index.d.ts +1 -1
- package/es/ProThemeTools/component/PrdTools/index.js +14 -28
- package/es/ProThemeTools/component/PrdTools/style/index.less +1 -1
- package/es/ProThemeTools/index.js +21 -29
- package/es/ProThemeTools/propsType.d.ts +1 -1
- package/es/ProThemeTools/style/index.less +25 -8
- package/es/{ProTreeSelect → ProTree/components/ProTreeSelect}/index.js +7 -11
- package/es/{ProTreeSelect → ProTree/components/ProTreeSelect}/propsType.d.ts +1 -1
- package/es/{ProTreeSelect → ProTree/components/ProTreeSelect}/style/index.less +1 -1
- package/es/ProTree/index.js +1 -1
- package/es/ProTree/style/index.less +5 -0
- package/es/ProTreeModal/style/index.less +2 -2
- package/es/ProUpload/style/fileItem.less +2 -2
- package/es/ProUpload/style/index.less +2 -2
- package/es/assets/catalog.svg +30 -1
- package/es/assets/fold.svg +27 -0
- package/es/assets/setting.svg +14 -0
- package/es/locale/en_US.d.ts +4 -0
- package/es/locale/en_US.js +4 -0
- package/es/locale/zh_CN.d.ts +4 -0
- package/es/locale/zh_CN.js +4 -0
- package/es/style/components.less +0 -1
- package/es/style/less.less +2 -0
- package/es/style/theme/antd.less +14 -29
- package/es/style/theme/index.less +2 -2
- package/es/style/theme/tokens.less +2 -2
- package/es/tokens.js +2 -2
- package/lib/ProConfigProvider/index.d.ts +1 -1
- package/lib/ProConfigProvider/index.js +23 -1
- package/lib/ProEditLabel/style/index.less +1 -2
- package/lib/ProEditTable/components/RenderField/index.js +31 -20
- package/lib/ProEditTable/index.js +3 -3
- package/lib/ProEditTable/propsType.d.ts +1 -1
- package/lib/ProEditTable/style/index.less +1 -1
- package/lib/ProEditTable/utils/config.js +5 -5
- package/lib/ProEditTable/utils/index.js +67 -30
- package/lib/ProEditTable/utils/tools.js +3 -1
- package/lib/ProEnum/components/Group.d.ts +2 -0
- package/lib/ProEnum/components/Group.js +20 -19
- package/lib/ProEnum/index.js +4 -3
- package/lib/ProEnum/style/index.less +12 -3
- package/lib/ProForm/components/base/DatePicker/index.js +1 -1
- package/lib/ProForm/components/combination/FormList/index.js +6 -3
- package/lib/ProForm/components/combination/FormList/utils.d.ts +2 -1
- package/lib/ProForm/components/combination/FormList/utils.js +5 -3
- package/lib/ProForm/components/combination/Group/index.js +28 -14
- package/lib/ProForm/components/combination/Group/propsType.d.ts +6 -0
- package/lib/ProForm/components/combination/Group/style/index.less +4 -4
- package/lib/ProForm/components/combination/Group/utils.d.ts +2 -0
- package/lib/ProForm/components/combination/Group/utils.js +11 -1
- package/lib/ProForm/components/combination/ProTimeLimit/index.js +7 -1
- package/lib/ProForm/components/combination/ProTimeLimit/style/index.less +1 -1
- package/lib/ProForm/components/index.d.ts +0 -1
- package/lib/ProForm/components/index.js +0 -7
- package/lib/ProForm/components/render/ConfirmWrapper.js +1 -1
- package/lib/ProForm/components/render/Render.js +21 -13
- package/lib/ProForm/components/render/RenderFields.d.ts +3 -2
- package/lib/ProForm/components/render/RenderFields.js +7 -3
- package/lib/ProForm/components/render/propsType.d.ts +2 -5
- package/lib/ProForm/index.js +11 -10
- package/lib/ProForm/propsType.d.ts +7 -3
- package/lib/ProForm/style/index.less +17 -13
- package/lib/ProForm/utils/{contrastOriginal.d.ts → diffOriginal.d.ts} +2 -1
- package/lib/ProForm/utils/diffOriginal.js +68 -0
- package/lib/ProForm/utils/index.d.ts +2 -2
- package/lib/ProForm/utils/index.js +8 -3
- package/lib/ProForm/utils/rulesCreator.d.ts +7 -1
- package/lib/ProForm/utils/rulesCreator.js +33 -2
- package/lib/ProForm/utils/transformNames.d.ts +1 -1
- package/lib/ProForm/utils/transformNames.js +10 -3
- package/lib/ProForm/utils/transformValue.js +1 -1
- package/lib/ProForm/utils/useChanged.js +4 -3
- package/lib/ProForm/utils/useListChanged.d.ts +1 -1
- package/lib/ProForm/utils/useListChanged.js +5 -3
- package/lib/ProForm/utils/useRules.js +36 -11
- package/lib/ProForm/utils/useShouldUpdate.js +4 -4
- package/lib/ProForm/utils/valueType.d.ts +10 -5
- package/lib/ProForm/utils/valueType.js +20 -10
- package/lib/ProIcon/config/index.d.ts +2 -1
- package/lib/ProIcon/config/index.js +191 -133
- package/lib/ProIcon/index.d.ts +0 -1
- package/lib/ProIcon/index.js +21 -37
- package/lib/ProIcon/propsTypes.d.ts +2 -1
- package/lib/ProLayout/components/Layout/Header/style/index.less +1 -1
- package/lib/ProLayout/components/Layout/Menu/OpenMenu/style/index.less +58 -55
- package/lib/ProLayout/components/Layout/Menu/SideMenu/style/index.less +25 -20
- package/lib/ProLayout/components/Layout/Menu/style/index.less +52 -56
- package/lib/ProLayout/components/ProCollapse/PropTypes.d.ts +5 -0
- package/lib/ProLayout/components/ProCollapse/index.js +43 -4
- package/lib/ProLayout/components/ProCollapse/style/index.less +29 -11
- package/lib/ProLayout/components/ProFooter/index.js +1 -1
- package/lib/ProLayout/components/ProFooter/style/index.less +1 -1
- package/lib/ProLayout/components/ProHeader/style/index.less +6 -5
- package/lib/ProLayout/style/index.less +176 -88
- package/lib/ProStep/components/Item/index.js +2 -1
- package/lib/ProStep/style/index.less +71 -70
- package/lib/ProTable/components/RenderColumn/index.d.ts +1 -1
- package/lib/ProTable/components/RenderColumn/index.js +3 -3
- package/lib/ProTable/propsType.d.ts +1 -1
- package/lib/ProTable/style/index.less +2 -2
- package/lib/ProTable/utils.js +9 -9
- package/lib/ProTabs/style/index.less +3 -1
- package/lib/ProThemeTools/component/PrdTools/index.d.ts +1 -1
- package/lib/ProThemeTools/component/PrdTools/index.js +14 -28
- package/lib/ProThemeTools/component/PrdTools/style/index.less +1 -1
- package/lib/ProThemeTools/index.js +19 -28
- package/lib/ProThemeTools/propsType.d.ts +1 -1
- package/lib/ProThemeTools/style/index.less +25 -8
- package/lib/{ProTreeSelect → ProTree/components/ProTreeSelect}/index.js +7 -11
- package/lib/{ProTreeSelect → ProTree/components/ProTreeSelect}/propsType.d.ts +1 -1
- package/lib/{ProTreeSelect → ProTree/components/ProTreeSelect}/style/index.less +1 -1
- package/lib/ProTree/index.js +1 -1
- package/lib/ProTree/style/index.less +5 -0
- package/lib/ProTreeModal/style/index.less +2 -2
- package/lib/ProUpload/style/fileItem.less +2 -2
- package/lib/ProUpload/style/index.less +2 -2
- package/lib/assets/catalog.svg +30 -1
- package/lib/assets/fold.svg +27 -0
- package/lib/assets/setting.svg +14 -0
- package/lib/locale/en_US.d.ts +4 -0
- package/lib/locale/en_US.js +4 -0
- package/lib/locale/zh_CN.d.ts +4 -0
- package/lib/locale/zh_CN.js +4 -0
- package/lib/style/components.less +0 -1
- package/lib/style/less.less +2 -0
- package/lib/style/theme/antd.less +14 -29
- package/lib/style/theme/index.less +2 -2
- package/lib/style/theme/tokens.less +2 -2
- package/lib/tokens.js +2 -2
- package/package.json +1 -1
- package/es/ProForm/utils/contrastOriginal.js +0 -24
- package/es/ProIcon/symbolIcon.js +0 -43
- package/lib/ProForm/utils/contrastOriginal.js +0 -30
- package/lib/ProIcon/symbolIcon.js +0 -45
- /package/es/{ProTreeSelect → ProTree/components/ProTreeSelect}/index.d.ts +0 -0
- /package/es/{ProTreeSelect → ProTree/components/ProTreeSelect}/propsType.js +0 -0
- /package/lib/{ProTreeSelect → ProTree/components/ProTreeSelect}/index.d.ts +0 -0
- /package/lib/{ProTreeSelect → ProTree/components/ProTreeSelect}/propsType.js +0 -0
|
@@ -1,199 +1,257 @@
|
|
|
1
1
|
export var iconMap = [{
|
|
2
2
|
type: 'view',
|
|
3
|
-
text: '查看'
|
|
3
|
+
'text-cn': '查看',
|
|
4
|
+
'text-en': 'view'
|
|
4
5
|
}, {
|
|
5
|
-
type: '',
|
|
6
|
-
text: '编辑'
|
|
6
|
+
type: 'edit',
|
|
7
|
+
'text-cn': '编辑',
|
|
8
|
+
'text-en': 'edit'
|
|
7
9
|
}, {
|
|
8
|
-
type: '',
|
|
9
|
-
text: '查看上传结果'
|
|
10
|
+
type: 'chakanshangchuanjieguo',
|
|
11
|
+
'text-cn': '查看上传结果',
|
|
12
|
+
'text-en': 'view upload results'
|
|
10
13
|
}, {
|
|
11
|
-
type: '',
|
|
12
|
-
text: '操作日志'
|
|
14
|
+
type: 'caozuorizhi',
|
|
15
|
+
'text-cn': '操作日志',
|
|
16
|
+
'text-en': 'operation log'
|
|
13
17
|
}, {
|
|
14
|
-
type: '',
|
|
15
|
-
text: '监管停售'
|
|
18
|
+
type: 'jianguantingshou',
|
|
19
|
+
'text-cn': '监管停售',
|
|
20
|
+
'text-en': 'regulatory suspension'
|
|
16
21
|
}, {
|
|
17
|
-
type: '',
|
|
18
|
-
text: '下架'
|
|
22
|
+
type: 'xiajia',
|
|
23
|
+
'text-cn': '下架',
|
|
24
|
+
'text-en': 'delist'
|
|
19
25
|
}, {
|
|
20
|
-
type: '',
|
|
21
|
-
text: '上架'
|
|
26
|
+
type: 'shangjia',
|
|
27
|
+
'text-cn': '上架',
|
|
28
|
+
'text-en': 'listing'
|
|
22
29
|
}, {
|
|
23
|
-
type: '',
|
|
24
|
-
text: '解锁'
|
|
30
|
+
type: 'jiesuo',
|
|
31
|
+
'text-cn': '解锁',
|
|
32
|
+
'text-en': 'unlock'
|
|
25
33
|
}, {
|
|
26
|
-
type: '',
|
|
27
|
-
text: '审核'
|
|
34
|
+
type: 'shenhe',
|
|
35
|
+
'text-cn': '审核',
|
|
36
|
+
'text-en': 'check'
|
|
28
37
|
}, {
|
|
29
|
-
type: '',
|
|
30
|
-
text: '下载导入文件'
|
|
38
|
+
type: 'xiazaidaoruwenjian',
|
|
39
|
+
'text-cn': '下载导入文件',
|
|
40
|
+
'text-en': 'download import file'
|
|
31
41
|
}, {
|
|
32
|
-
type: '',
|
|
33
|
-
text: '删除'
|
|
42
|
+
type: 'shanchu',
|
|
43
|
+
'text-cn': '删除',
|
|
44
|
+
'text-en': 'delete'
|
|
34
45
|
}, {
|
|
35
|
-
type: '',
|
|
36
|
-
text: '撤回'
|
|
46
|
+
type: 'chehui',
|
|
47
|
+
'text-cn': '撤回',
|
|
48
|
+
'text-en': 'revocation'
|
|
37
49
|
}, {
|
|
38
|
-
type: '',
|
|
39
|
-
text: '再次询价'
|
|
50
|
+
type: 'zaicixunjia',
|
|
51
|
+
'text-cn': '再次询价',
|
|
52
|
+
'text-en': 'reinquiry'
|
|
40
53
|
}, {
|
|
41
|
-
type: '',
|
|
42
|
-
text: '复制'
|
|
54
|
+
type: 'fuzhi',
|
|
55
|
+
'text-cn': '复制',
|
|
56
|
+
'text-en': 'copy'
|
|
43
57
|
}, {
|
|
44
|
-
type: '',
|
|
45
|
-
text: '撤回登记'
|
|
58
|
+
type: 'chehuidengji',
|
|
59
|
+
'text-cn': '撤回登记',
|
|
60
|
+
'text-en': 'withdrawal of registration'
|
|
46
61
|
}, {
|
|
47
|
-
type: '',
|
|
48
|
-
text: '占号补录'
|
|
62
|
+
type: 'zhanhaobulu',
|
|
63
|
+
'text-cn': '占号补录',
|
|
64
|
+
'text-en': 'fill in the number'
|
|
49
65
|
}, {
|
|
50
|
-
type: '',
|
|
51
|
-
text: '处理'
|
|
66
|
+
type: 'chuli',
|
|
67
|
+
'text-cn': '处理',
|
|
68
|
+
'text-en': 'handle'
|
|
52
69
|
}, {
|
|
53
|
-
type: '',
|
|
54
|
-
text: '释放'
|
|
70
|
+
type: 'shifang',
|
|
71
|
+
'text-cn': '释放',
|
|
72
|
+
'text-en': 'release'
|
|
55
73
|
}, {
|
|
56
|
-
type: '',
|
|
57
|
-
text: '关闭'
|
|
74
|
+
type: 'guanbi',
|
|
75
|
+
'text-cn': '关闭',
|
|
76
|
+
'text-en': 'close'
|
|
58
77
|
}, {
|
|
59
|
-
type: '',
|
|
60
|
-
text: '认领'
|
|
78
|
+
type: 'renling',
|
|
79
|
+
'text-cn': '认领',
|
|
80
|
+
'text-en': 'claim'
|
|
61
81
|
}, {
|
|
62
|
-
type: '',
|
|
63
|
-
text: '缴费登记'
|
|
82
|
+
type: 'jiaofeidengji',
|
|
83
|
+
'text-cn': '缴费登记',
|
|
84
|
+
'text-en': 'payment registration'
|
|
64
85
|
}, {
|
|
65
|
-
type: '',
|
|
66
|
-
text: '补传资料'
|
|
86
|
+
type: 'buchuanziliao',
|
|
87
|
+
'text-cn': '补传资料',
|
|
88
|
+
'text-en': 'supplementary data'
|
|
67
89
|
}, {
|
|
68
|
-
type: '',
|
|
69
|
-
text: '资料补传确认'
|
|
90
|
+
type: 'ziliaobuchuanqueren',
|
|
91
|
+
'text-cn': '资料补传确认',
|
|
92
|
+
'text-en': 'data retransmission confirmed'
|
|
70
93
|
}, {
|
|
71
|
-
type: '',
|
|
72
|
-
text: '启用'
|
|
94
|
+
type: 'qiyong',
|
|
95
|
+
'text-cn': '启用',
|
|
96
|
+
'text-en': 'enable'
|
|
73
97
|
}, {
|
|
74
|
-
type: '',
|
|
75
|
-
text: '查勘'
|
|
98
|
+
type: 'chakan',
|
|
99
|
+
'text-cn': '查勘',
|
|
100
|
+
'text-en': 'survey'
|
|
76
101
|
}, {
|
|
77
|
-
type: '',
|
|
78
|
-
text: '会签处理'
|
|
102
|
+
type: 'huiqianchuli',
|
|
103
|
+
'text-cn': '会签处理',
|
|
104
|
+
'text-en': 'countersign processing'
|
|
79
105
|
}, {
|
|
80
|
-
type: '',
|
|
81
|
-
text: '已阅'
|
|
106
|
+
type: 'yiyue',
|
|
107
|
+
'text-cn': '已阅',
|
|
108
|
+
'text-en': 'have read'
|
|
82
109
|
}, {
|
|
83
|
-
type: '',
|
|
84
|
-
text: '下载'
|
|
110
|
+
type: 'xiazai',
|
|
111
|
+
'text-cn': '下载',
|
|
112
|
+
'text-en': 'download'
|
|
85
113
|
}, {
|
|
86
|
-
type: '',
|
|
87
|
-
text: '发送'
|
|
114
|
+
type: 'fasong',
|
|
115
|
+
'text-cn': '发送',
|
|
116
|
+
'text-en': 'send'
|
|
88
117
|
}, {
|
|
89
|
-
type: '',
|
|
90
|
-
text: '导出'
|
|
118
|
+
type: 'daochu',
|
|
119
|
+
'text-cn': '导出',
|
|
120
|
+
'text-en': 'export'
|
|
91
121
|
}, {
|
|
92
|
-
type: '',
|
|
93
|
-
text: '设为失效'
|
|
122
|
+
type: 'sheweishixiao',
|
|
123
|
+
'text-cn': '设为失效',
|
|
124
|
+
'text-en': 'set invalidate'
|
|
94
125
|
}, {
|
|
95
|
-
type: '',
|
|
96
|
-
text: '
|
|
126
|
+
type: 'qingkong',
|
|
127
|
+
'text-cn': '清空',
|
|
128
|
+
'text-en': 'clear'
|
|
97
129
|
}, {
|
|
98
|
-
type: '',
|
|
99
|
-
text: '
|
|
130
|
+
type: 'shixiao',
|
|
131
|
+
'text-cn': '失效',
|
|
132
|
+
'text-en': 'lose effectiveness'
|
|
100
133
|
}, {
|
|
101
|
-
type: '',
|
|
102
|
-
text: '
|
|
134
|
+
type: 'zhongzhi',
|
|
135
|
+
'text-cn': '中止',
|
|
136
|
+
'text-en': 'stop'
|
|
103
137
|
}, {
|
|
104
|
-
type: '',
|
|
105
|
-
text: '
|
|
138
|
+
type: 'wangdian',
|
|
139
|
+
'text-cn': '网点',
|
|
140
|
+
'text-en': 'site'
|
|
106
141
|
}, {
|
|
107
|
-
type: '',
|
|
108
|
-
text: '
|
|
142
|
+
type: 'fuwuwangdian',
|
|
143
|
+
'text-cn': '服务网点',
|
|
144
|
+
'text-en': 'server site'
|
|
109
145
|
}, {
|
|
110
|
-
type: '',
|
|
111
|
-
text: '
|
|
146
|
+
type: 'rukoupeizhi',
|
|
147
|
+
'text-cn': '入口配置',
|
|
148
|
+
'text-en': 'entry config'
|
|
112
149
|
}, {
|
|
113
|
-
type: '',
|
|
114
|
-
text: '
|
|
150
|
+
type: 'yemianpeizhi',
|
|
151
|
+
'text-cn': '页面配置',
|
|
152
|
+
'text-en': 'page config'
|
|
115
153
|
}, {
|
|
116
|
-
type: '',
|
|
117
|
-
text: '
|
|
154
|
+
type: 'bianjifenpei',
|
|
155
|
+
'text-cn': '编辑分配',
|
|
156
|
+
'text-en': 'edit assignment'
|
|
118
157
|
}, {
|
|
119
|
-
type: '',
|
|
120
|
-
text: '
|
|
158
|
+
type: 'chakanxiangqing',
|
|
159
|
+
'text-cn': '查看详情',
|
|
160
|
+
'text-en': 'view detail'
|
|
121
161
|
}, {
|
|
122
|
-
type: '',
|
|
123
|
-
text: '
|
|
162
|
+
type: 'toubaopeizhi',
|
|
163
|
+
'text-cn': '投保配置',
|
|
164
|
+
'text-en': 'insurance config'
|
|
124
165
|
}, {
|
|
125
|
-
type: '',
|
|
126
|
-
text: '
|
|
166
|
+
type: 'tuiguangweipeizhi',
|
|
167
|
+
'text-cn': '推广位配置',
|
|
168
|
+
'text-en': 'promotion bit config'
|
|
127
169
|
}, {
|
|
128
|
-
type: '',
|
|
129
|
-
text: '
|
|
170
|
+
type: 'kaishihezuo',
|
|
171
|
+
'text-cn': '开始合作',
|
|
172
|
+
'text-en': 'start cooperation'
|
|
130
173
|
}, {
|
|
131
|
-
type: '',
|
|
132
|
-
text: '
|
|
174
|
+
type: 'tingzhihezuo',
|
|
175
|
+
'text-cn': '停止合作',
|
|
176
|
+
'text-en': 'stop cooperation'
|
|
133
177
|
}, {
|
|
134
|
-
type: '',
|
|
135
|
-
text: '
|
|
178
|
+
type: 'fuzhilianjie',
|
|
179
|
+
'text-cn': '复制链接',
|
|
180
|
+
'text-en': 'copy link'
|
|
136
181
|
}, {
|
|
137
|
-
type: '',
|
|
138
|
-
text: '
|
|
182
|
+
type: 'jinyong',
|
|
183
|
+
'text-cn': '禁用',
|
|
184
|
+
'text-en': 'disabled'
|
|
139
185
|
}, {
|
|
140
|
-
type: '',
|
|
141
|
-
text: '
|
|
186
|
+
type: 'bianjipeizhi',
|
|
187
|
+
'text-cn': '编辑配置',
|
|
188
|
+
'text-en': 'edit config'
|
|
142
189
|
}, {
|
|
143
|
-
type: '',
|
|
144
|
-
text: '
|
|
190
|
+
type: 'yulan',
|
|
191
|
+
'text-cn': '预览',
|
|
192
|
+
'text-en': 'preview'
|
|
145
193
|
}, {
|
|
146
|
-
type: '',
|
|
147
|
-
text: '
|
|
194
|
+
type: 'daochumoban',
|
|
195
|
+
'text-cn': '导出模板',
|
|
196
|
+
'text-en': 'export template'
|
|
148
197
|
}, {
|
|
149
|
-
type: '',
|
|
150
|
-
text: '
|
|
198
|
+
type: 'xiangqing',
|
|
199
|
+
'text-cn': '详情',
|
|
200
|
+
'text-en': 'detail'
|
|
151
201
|
}, {
|
|
152
|
-
type: '',
|
|
153
|
-
text: '
|
|
202
|
+
type: 'zhongzhiqudao',
|
|
203
|
+
'text-cn': '终止渠道',
|
|
204
|
+
'text-en': 'stop channel'
|
|
154
205
|
}, {
|
|
155
|
-
type: '',
|
|
156
|
-
text: '
|
|
206
|
+
type: 'chakanfapiao',
|
|
207
|
+
'text-cn': '查看发票',
|
|
208
|
+
'text-en': 'view invoice'
|
|
157
209
|
}, {
|
|
158
|
-
type: '',
|
|
159
|
-
text: '
|
|
210
|
+
type: 'qiyerenzheng',
|
|
211
|
+
'text-cn': '企业认证',
|
|
212
|
+
'text-en': 'enterprise certification'
|
|
160
213
|
}, {
|
|
161
|
-
type: '',
|
|
162
|
-
text: '
|
|
214
|
+
type: 'apishouquan',
|
|
215
|
+
'text-cn': 'API授权',
|
|
216
|
+
'text-en': 'api accredit'
|
|
163
217
|
}, {
|
|
164
|
-
type: '',
|
|
165
|
-
text: '
|
|
218
|
+
type: 'chanpinshouquan',
|
|
219
|
+
'text-cn': '产品授权',
|
|
220
|
+
'text-en': 'product accredit'
|
|
166
221
|
}, {
|
|
167
|
-
type: '',
|
|
168
|
-
text: '
|
|
222
|
+
type: 'chongzhimima',
|
|
223
|
+
'text-cn': '重置密码',
|
|
224
|
+
'text-en': 'reset password'
|
|
169
225
|
}, {
|
|
170
|
-
type: '',
|
|
171
|
-
text: '
|
|
226
|
+
type: 'tingyong',
|
|
227
|
+
'text-cn': '停用',
|
|
228
|
+
'text-en': 'disuse'
|
|
172
229
|
}, {
|
|
173
|
-
type: '',
|
|
174
|
-
text: '
|
|
230
|
+
type: 'apiquanxian',
|
|
231
|
+
'text-cn': 'API权限',
|
|
232
|
+
'text-en': 'api authorization'
|
|
175
233
|
}, {
|
|
176
|
-
type: '',
|
|
177
|
-
text: '
|
|
234
|
+
type: 'ipbaimingdan',
|
|
235
|
+
'text-cn': 'IP白名单',
|
|
236
|
+
'text-en': 'ip whitelist'
|
|
178
237
|
}, {
|
|
179
|
-
type: '',
|
|
180
|
-
text: '
|
|
238
|
+
type: 'yulanmoban',
|
|
239
|
+
'text-cn': '预览模板',
|
|
240
|
+
'text-en': 'preview template'
|
|
181
241
|
}, {
|
|
182
|
-
type: '',
|
|
183
|
-
text: '
|
|
242
|
+
type: 'queren',
|
|
243
|
+
'text-cn': '确认',
|
|
244
|
+
'text-en': 'confirm'
|
|
184
245
|
}, {
|
|
185
|
-
type: '',
|
|
186
|
-
text: '
|
|
246
|
+
type: 'xiugai',
|
|
247
|
+
'text-cn': '修改',
|
|
248
|
+
'text-en': 'edit'
|
|
187
249
|
}, {
|
|
188
|
-
type: '',
|
|
189
|
-
text: '
|
|
250
|
+
type: 'chakanlishipeizhi',
|
|
251
|
+
'text-cn': '查看历史配置',
|
|
252
|
+
'text-en': 'view history conifg'
|
|
190
253
|
}, {
|
|
191
|
-
type: '',
|
|
192
|
-
text: '
|
|
193
|
-
|
|
194
|
-
type: '',
|
|
195
|
-
text: '查看历史配置'
|
|
196
|
-
}, {
|
|
197
|
-
type: '',
|
|
198
|
-
text: '调整序号'
|
|
254
|
+
type: 'tiaozhengxuhao',
|
|
255
|
+
'text-cn': '调整序号',
|
|
256
|
+
'text-en': 'adjust order'
|
|
199
257
|
}];
|
package/es/ProIcon/index.d.ts
CHANGED
package/es/ProIcon/index.js
CHANGED
|
@@ -4,38 +4,12 @@ import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutPr
|
|
|
4
4
|
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
5
5
|
var _excluded = ["type", "onClick", "size", "color", "className", "style", "spin", "rotate", "theme", "disabled", "mode", "buttonProps", "children", "mapList"];
|
|
6
6
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
import { useExternal } from 'ahooks';
|
|
7
8
|
import classNames from 'classnames';
|
|
8
9
|
import { uniqBy } from 'lodash';
|
|
9
|
-
import { iconMap } from './config';
|
|
10
|
-
import symbolIcon from './symbolIcon';
|
|
11
10
|
import { useProConfig } from '../ProConfigProvider';
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
return Boolean(typeof scriptUrl === 'string' && scriptUrl.length && !customCache.has(scriptUrl));
|
|
15
|
-
}
|
|
16
|
-
export function createScriptUrlElements(scriptUrls) {
|
|
17
|
-
var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
|
18
|
-
var currentScriptUrl = scriptUrls[index];
|
|
19
|
-
if (isValidCustomScriptUrl(currentScriptUrl)) {
|
|
20
|
-
var script = document.createElement('script');
|
|
21
|
-
script.setAttribute('src', currentScriptUrl);
|
|
22
|
-
script.setAttribute('data-namespace', currentScriptUrl);
|
|
23
|
-
if (scriptUrls.length > index + 1) {
|
|
24
|
-
script.onload = function () {
|
|
25
|
-
createScriptUrlElements(scriptUrls, index + 1);
|
|
26
|
-
};
|
|
27
|
-
script.onerror = function () {
|
|
28
|
-
createScriptUrlElements(scriptUrls, index + 1);
|
|
29
|
-
};
|
|
30
|
-
}
|
|
31
|
-
customCache.add(currentScriptUrl);
|
|
32
|
-
document.body.appendChild(script);
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
// 加载内部icon
|
|
36
|
-
if (symbolIcon && typeof document !== 'undefined' && typeof window !== 'undefined' && typeof document.createElement === 'function') {
|
|
37
|
-
createScriptUrlElements([symbolIcon]);
|
|
38
|
-
}
|
|
11
|
+
import { iconMap } from './config';
|
|
12
|
+
import locale from '../locale';
|
|
39
13
|
var ProIcon = function ProIcon(props) {
|
|
40
14
|
var config = useProConfig('ProIcon') || {};
|
|
41
15
|
var _config = _objectSpread(_objectSpread({}, config), props !== null && props !== void 0 ? props : {});
|
|
@@ -62,6 +36,13 @@ var ProIcon = function ProIcon(props) {
|
|
|
62
36
|
_config$mapList = _config.mapList,
|
|
63
37
|
mapList = _config$mapList === void 0 ? [] : _config$mapList,
|
|
64
38
|
reset = _objectWithoutProperties(_config, _excluded);
|
|
39
|
+
// 语言
|
|
40
|
+
var language = locale.ProIcon.language;
|
|
41
|
+
// 加载内部icon
|
|
42
|
+
var status = useExternal('https://at.alicdn.com/t/c/font_4063056_jmnz9g5uycp.js');
|
|
43
|
+
if (status !== 'ready') {
|
|
44
|
+
return null;
|
|
45
|
+
}
|
|
65
46
|
var rotateStyle = rotate ? {
|
|
66
47
|
msTransform: "rotate(".concat(rotate, "deg)"),
|
|
67
48
|
transform: "rotate(".concat(rotate, "deg)")
|
|
@@ -73,32 +54,36 @@ var ProIcon = function ProIcon(props) {
|
|
|
73
54
|
'pro-icon-btn': disabled
|
|
74
55
|
});
|
|
75
56
|
var _mode = mode || 'icon';
|
|
57
|
+
// 特殊情况,如果指定了type,并且没有接收到组件内的mode,那模式就是icon
|
|
58
|
+
if (type && !props.mode) {
|
|
59
|
+
_mode = 'icon';
|
|
60
|
+
}
|
|
61
|
+
var targetTextFill = "text-".concat(language); // text-cn text-en
|
|
76
62
|
var isIconMode = _mode === 'icon';
|
|
77
63
|
var isExtendButtonMode = !isIconMode || isIconMode && disabled;
|
|
78
|
-
var mergedMapList = uniqBy(mapList.concat(iconMap),
|
|
64
|
+
var mergedMapList = uniqBy(mapList.concat(iconMap), targetTextFill);
|
|
79
65
|
var _type = type;
|
|
80
66
|
var _text = children;
|
|
81
|
-
var textIsExistAndIncludeChinese = _text && /[\u4e00-\u9fa5]/.test(String(_text));
|
|
82
67
|
var typeIsExistAndIncludeEnglish = _type && /[a-zA-Z]/.test(_type);
|
|
83
|
-
// 模式为icon下,对传入的text
|
|
68
|
+
// 模式为icon下,对传入的text进行指定语言-icon 映射
|
|
84
69
|
if (isIconMode && !type) {
|
|
85
|
-
if (
|
|
70
|
+
if (_text) {
|
|
86
71
|
var target = mergedMapList.find(function (item) {
|
|
87
|
-
return item
|
|
72
|
+
return item['text-cn'] === _text || item['text-en'] === _text;
|
|
88
73
|
});
|
|
89
74
|
if (target) {
|
|
90
75
|
_type = target === null || target === void 0 ? void 0 : target.type;
|
|
91
76
|
}
|
|
92
77
|
}
|
|
93
78
|
}
|
|
94
|
-
// 模式为button下,对传入的type进行icon
|
|
79
|
+
// 模式为button下,对传入的type进行icon-指定语言 映射
|
|
95
80
|
if (!isIconMode) {
|
|
96
81
|
if (typeIsExistAndIncludeEnglish) {
|
|
97
82
|
var _target = mergedMapList.find(function (item) {
|
|
98
83
|
return item.type === _type;
|
|
99
84
|
});
|
|
100
85
|
if (_target) {
|
|
101
|
-
_text = _target
|
|
86
|
+
_text = _target[targetTextFill];
|
|
102
87
|
}
|
|
103
88
|
}
|
|
104
89
|
}
|