@lingxiteam/assets 4.2.1-alpha.2 → 4.3.2-alpha.3

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 (175) hide show
  1. package/es/IconSvg/index.js +8 -7
  2. package/es/error/errorCatch/index.js +1 -1
  3. package/es/error/errorDisplay/Mobile/Drawer/Drawer.js +99 -77
  4. package/es/error/errorDisplay/Mobile/Drawer/index.js +26 -26
  5. package/es/error/errorDisplay/Mobile/ErrorMsg/index.js +127 -129
  6. package/es/error/errorDisplay/Mobile/Modal/Modal.js +46 -31
  7. package/es/error/errorDisplay/Mobile/Modal/index.js +24 -24
  8. package/es/error/errorDisplay/Mobile/defaultGlobalConfig.js +2 -2
  9. package/es/error/errorDisplay/Web/Drawer/Drawer.js +183 -145
  10. package/es/error/errorDisplay/Web/Drawer/DrawerConnect.js +43 -46
  11. package/es/error/errorDisplay/Web/Drawer/index.js +15 -15
  12. package/es/error/errorDisplay/Web/ErrorMsg/index.js +341 -327
  13. package/es/error/errorDisplay/Web/Notification/Notice.js +78 -65
  14. package/es/error/errorDisplay/Web/Notification/Notification.js +15 -15
  15. package/es/error/errorDisplay/Web/Notification/index.js +36 -38
  16. package/es/error/errorDisplay/Web/defaultGlobalConfig.js +2 -2
  17. package/es/error/errorDisplay/compUtils.js +6 -6
  18. package/es/error/errorDisplay/http.js +7 -7
  19. package/es/error/index.js +6 -6
  20. package/es/index.js +5 -5
  21. package/es/rootConfig/index.d.ts +1 -1
  22. package/es/rootConfig/index.js +5 -5
  23. package/es/rootConfig/locales/enus/config-locales-es.d.ts +2 -0
  24. package/es/rootConfig/locales/enus/config-locales-es.js +13 -0
  25. package/es/rootConfig/locales/enus/config-locales-es.mobile.d.ts +2 -0
  26. package/es/rootConfig/locales/enus/config-locales-es.mobile.js +106 -0
  27. package/es/rootConfig/locales/enus/config-locales-es.pc.d.ts +2 -0
  28. package/es/rootConfig/locales/enus/config-locales-es.pc.js +42 -0
  29. package/es/rootConfig/locales/enus/config-locales-es.todo-actionList.d.ts +2 -0
  30. package/es/rootConfig/locales/enus/config-locales-es.todo-actionList.js +865 -0
  31. package/es/rootConfig/locales/enus/config-locales-es.todo-callback.d.ts +2 -0
  32. package/es/rootConfig/locales/enus/config-locales-es.todo-callback.js +20 -0
  33. package/es/rootConfig/locales/enus/config-locales-es.todo-optionList.d.ts +2 -0
  34. package/es/rootConfig/locales/enus/config-locales-es.todo-optionList.js +266 -0
  35. package/es/rootConfig/locales/zhcn/config-locales-cn.d.ts +2 -0
  36. package/es/rootConfig/locales/zhcn/config-locales-cn.js +13 -0
  37. package/es/rootConfig/locales/zhcn/config-locales-cn.mobile.d.ts +2 -0
  38. package/es/rootConfig/locales/zhcn/config-locales-cn.mobile.js +57 -0
  39. package/es/rootConfig/locales/zhcn/config-locales-cn.pc.d.ts +2 -0
  40. package/es/rootConfig/locales/zhcn/config-locales-cn.pc.js +97 -0
  41. package/es/rootConfig/locales/zhcn/config-locales-cn.todo-actionList.d.ts +2 -0
  42. package/es/rootConfig/locales/zhcn/config-locales-cn.todo-actionList.js +583 -0
  43. package/es/rootConfig/locales/zhcn/config-locales-cn.todo-callback.d.ts +2 -0
  44. package/es/rootConfig/locales/zhcn/config-locales-cn.todo-callback.js +13 -0
  45. package/es/rootConfig/locales/zhcn/config-locales-cn.todo-optionList.d.ts +2 -0
  46. package/es/rootConfig/locales/zhcn/config-locales-cn.todo-optionList.js +127 -0
  47. package/es/rootConfig/locales/zhhk/config-locales-hk.d.ts +2 -0
  48. package/es/rootConfig/locales/zhhk/config-locales-hk.js +13 -0
  49. package/es/rootConfig/locales/zhhk/config-locales-hk.mobile.d.ts +2 -0
  50. package/es/rootConfig/locales/zhhk/config-locales-hk.mobile.js +106 -0
  51. package/es/rootConfig/locales/zhhk/config-locales-hk.pc.d.ts +2 -0
  52. package/es/rootConfig/locales/zhhk/config-locales-hk.pc.js +174 -0
  53. package/es/rootConfig/locales/zhhk/config-locales-hk.todo-actionList.d.ts +2 -0
  54. package/es/rootConfig/locales/zhhk/config-locales-hk.todo-actionList.js +869 -0
  55. package/es/rootConfig/locales/zhhk/config-locales-hk.todo-callback.d.ts +2 -0
  56. package/es/rootConfig/locales/zhhk/config-locales-hk.todo-callback.js +20 -0
  57. package/es/rootConfig/locales/zhhk/config-locales-hk.todo-optionList.d.ts +2 -0
  58. package/es/rootConfig/locales/zhhk/config-locales-hk.todo-optionList.js +266 -0
  59. package/es/rootConfig/mobile/BusiComp.d.ts +0 -1
  60. package/es/rootConfig/mobile/BusiComp.js +13 -10
  61. package/es/rootConfig/mobile/MobileModal.js +32 -27
  62. package/es/rootConfig/mobile/MobilePopover.d.ts +0 -2
  63. package/es/rootConfig/mobile/MobilePopover.js +16 -13
  64. package/es/rootConfig/mobile/index.js +4 -4
  65. package/es/rootConfig/mobile/page.d.ts +17 -2
  66. package/es/rootConfig/mobile/page.js +45 -38
  67. package/es/rootConfig/pc/BusiComp.js +82 -12
  68. package/es/rootConfig/pc/Drawer.d.ts +8 -9
  69. package/es/rootConfig/pc/Drawer.js +116 -46
  70. package/es/rootConfig/pc/Modal.d.ts +0 -1
  71. package/es/rootConfig/pc/Modal.js +90 -20
  72. package/es/rootConfig/pc/Popover.d.ts +0 -1
  73. package/es/rootConfig/pc/Popover.js +85 -15
  74. package/es/rootConfig/pc/index.js +5 -5
  75. package/es/rootConfig/pc/page.d.ts +0 -2
  76. package/es/rootConfig/pc/page.js +91 -22
  77. package/es/rootConfig/todoActionList.d.ts +1 -0
  78. package/es/rootConfig/todoActionList.js +1845 -719
  79. package/es/rootConfig/todoCallback.d.ts +12 -1
  80. package/es/rootConfig/todoCallback.js +175 -103
  81. package/es/rootConfig/todoOptionList.d.ts +0 -66
  82. package/es/rootConfig/todoOptionList.js +197 -198
  83. package/es/theme/index.js +18 -20
  84. package/es/theme/src/default/index.js +7 -7
  85. package/es/theme/utils/renderColors.js +1 -1
  86. package/es/utils/url.js +8 -7
  87. package/lib/IconSvg/index.js +10 -9
  88. package/lib/error/errorCatch/index.js +2 -3
  89. package/lib/error/errorDisplay/Mobile/Drawer/Drawer.js +99 -79
  90. package/lib/error/errorDisplay/Mobile/Drawer/index.js +25 -26
  91. package/lib/error/errorDisplay/Mobile/ErrorMsg/index.js +123 -126
  92. package/lib/error/errorDisplay/Mobile/Modal/Modal.js +45 -33
  93. package/lib/error/errorDisplay/Mobile/Modal/index.js +23 -24
  94. package/lib/error/errorDisplay/Mobile/defaultGlobalConfig.js +3 -5
  95. package/lib/error/errorDisplay/SVGstring.js +6 -12
  96. package/lib/error/errorDisplay/Web/Drawer/Drawer.js +181 -146
  97. package/lib/error/errorDisplay/Web/Drawer/DrawerConnect.js +44 -48
  98. package/lib/error/errorDisplay/Web/Drawer/index.js +18 -20
  99. package/lib/error/errorDisplay/Web/ErrorMsg/index.js +336 -324
  100. package/lib/error/errorDisplay/Web/Notification/Notice.js +79 -68
  101. package/lib/error/errorDisplay/Web/Notification/Notification.js +15 -16
  102. package/lib/error/errorDisplay/Web/Notification/index.js +37 -41
  103. package/lib/error/errorDisplay/Web/defaultGlobalConfig.js +3 -5
  104. package/lib/error/errorDisplay/compUtils.js +9 -12
  105. package/lib/error/errorDisplay/const.js +7 -13
  106. package/lib/error/errorDisplay/http.js +8 -9
  107. package/lib/index.js +3 -6
  108. package/lib/rootConfig/index.d.ts +1 -1
  109. package/lib/rootConfig/index.js +9 -3
  110. package/lib/rootConfig/locales/enus/config-locales-es.d.ts +2 -0
  111. package/lib/rootConfig/locales/enus/config-locales-es.js +19 -0
  112. package/lib/rootConfig/locales/enus/config-locales-es.mobile.d.ts +2 -0
  113. package/lib/rootConfig/locales/enus/config-locales-es.mobile.js +112 -0
  114. package/lib/rootConfig/locales/enus/config-locales-es.pc.d.ts +2 -0
  115. package/lib/rootConfig/locales/enus/config-locales-es.pc.js +48 -0
  116. package/lib/rootConfig/locales/enus/config-locales-es.todo-actionList.d.ts +2 -0
  117. package/lib/rootConfig/locales/enus/config-locales-es.todo-actionList.js +871 -0
  118. package/lib/rootConfig/locales/enus/config-locales-es.todo-callback.d.ts +2 -0
  119. package/lib/rootConfig/locales/enus/config-locales-es.todo-callback.js +26 -0
  120. package/lib/rootConfig/locales/enus/config-locales-es.todo-optionList.d.ts +2 -0
  121. package/lib/rootConfig/locales/enus/config-locales-es.todo-optionList.js +272 -0
  122. package/lib/rootConfig/locales/zhcn/config-locales-cn.d.ts +2 -0
  123. package/lib/rootConfig/locales/zhcn/config-locales-cn.js +19 -0
  124. package/lib/rootConfig/locales/zhcn/config-locales-cn.mobile.d.ts +2 -0
  125. package/lib/rootConfig/locales/zhcn/config-locales-cn.mobile.js +63 -0
  126. package/lib/rootConfig/locales/zhcn/config-locales-cn.pc.d.ts +2 -0
  127. package/lib/rootConfig/locales/zhcn/config-locales-cn.pc.js +103 -0
  128. package/lib/rootConfig/locales/zhcn/config-locales-cn.todo-actionList.d.ts +2 -0
  129. package/lib/rootConfig/locales/zhcn/config-locales-cn.todo-actionList.js +589 -0
  130. package/lib/rootConfig/locales/zhcn/config-locales-cn.todo-callback.d.ts +2 -0
  131. package/lib/rootConfig/locales/zhcn/config-locales-cn.todo-callback.js +19 -0
  132. package/lib/rootConfig/locales/zhcn/config-locales-cn.todo-optionList.d.ts +2 -0
  133. package/lib/rootConfig/locales/zhcn/config-locales-cn.todo-optionList.js +133 -0
  134. package/lib/rootConfig/locales/zhhk/config-locales-hk.d.ts +2 -0
  135. package/lib/rootConfig/locales/zhhk/config-locales-hk.js +19 -0
  136. package/lib/rootConfig/locales/zhhk/config-locales-hk.mobile.d.ts +2 -0
  137. package/lib/rootConfig/locales/zhhk/config-locales-hk.mobile.js +112 -0
  138. package/lib/rootConfig/locales/zhhk/config-locales-hk.pc.d.ts +2 -0
  139. package/lib/rootConfig/locales/zhhk/config-locales-hk.pc.js +180 -0
  140. package/lib/rootConfig/locales/zhhk/config-locales-hk.todo-actionList.d.ts +2 -0
  141. package/lib/rootConfig/locales/zhhk/config-locales-hk.todo-actionList.js +875 -0
  142. package/lib/rootConfig/locales/zhhk/config-locales-hk.todo-callback.d.ts +2 -0
  143. package/lib/rootConfig/locales/zhhk/config-locales-hk.todo-callback.js +26 -0
  144. package/lib/rootConfig/locales/zhhk/config-locales-hk.todo-optionList.d.ts +2 -0
  145. package/lib/rootConfig/locales/zhhk/config-locales-hk.todo-optionList.js +272 -0
  146. package/lib/rootConfig/mobile/BusiComp.d.ts +0 -1
  147. package/lib/rootConfig/mobile/BusiComp.js +14 -12
  148. package/lib/rootConfig/mobile/MobileModal.js +33 -29
  149. package/lib/rootConfig/mobile/MobilePopover.d.ts +0 -2
  150. package/lib/rootConfig/mobile/MobilePopover.js +17 -15
  151. package/lib/rootConfig/mobile/page.d.ts +17 -2
  152. package/lib/rootConfig/mobile/page.js +46 -40
  153. package/lib/rootConfig/pc/BusiComp.js +83 -14
  154. package/lib/rootConfig/pc/Drawer.d.ts +8 -9
  155. package/lib/rootConfig/pc/Drawer.js +117 -48
  156. package/lib/rootConfig/pc/Modal.d.ts +0 -1
  157. package/lib/rootConfig/pc/Modal.js +91 -22
  158. package/lib/rootConfig/pc/Popover.d.ts +0 -1
  159. package/lib/rootConfig/pc/Popover.js +86 -17
  160. package/lib/rootConfig/pc/page.d.ts +0 -2
  161. package/lib/rootConfig/pc/page.js +92 -24
  162. package/lib/rootConfig/todoActionList.d.ts +1 -0
  163. package/lib/rootConfig/todoActionList.js +1815 -695
  164. package/lib/rootConfig/todoCallback.d.ts +12 -1
  165. package/lib/rootConfig/todoCallback.js +182 -116
  166. package/lib/rootConfig/todoOptionList.d.ts +0 -66
  167. package/lib/rootConfig/todoOptionList.js +198 -200
  168. package/lib/theme/bin/default/modalWidth.js +1 -2
  169. package/lib/theme/index.js +19 -22
  170. package/lib/theme/src/default/index.js +7 -7
  171. package/lib/theme/utils/renderColors.js +1 -1
  172. package/lib/utils/cookieUtil.js +1 -2
  173. package/lib/utils/img.js +2 -3
  174. package/lib/utils/url.js +13 -16
  175. package/package.json +3 -4
@@ -10,10 +10,15 @@ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread n
10
10
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
11
11
  function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
12
12
  function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
13
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
14
- var _default = {
13
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
14
+ var PC_DRAWER_LOCALE_PREFIX = 'pc.drawer';
15
+ var localeKey = function localeKey(suffix) {
16
+ return "".concat(PC_DRAWER_LOCALE_PREFIX, ".").concat(suffix);
17
+ };
18
+ var _default = exports.default = {
15
19
  compLib: 'root',
16
20
  compType: -1,
21
+ // 根节点
17
22
  isBusiObjContainer: false,
18
23
  isContainer: false,
19
24
  label: '抽屉',
@@ -22,7 +27,6 @@ var _default = {
22
27
  height: 300,
23
28
  placement: 'right',
24
29
  footer: 1,
25
- layout: 'BlankLayout',
26
30
  closeOnClickOverlay: false,
27
31
  compState: [{
28
32
  name: '业务主键',
@@ -42,14 +46,80 @@ var _default = {
42
46
  description: '',
43
47
  image: '',
44
48
  groupsName: 'root',
45
- todoActionList: [].concat(_toConsumableArray((0, _todoActionList.getSystemTodoActionList)('pc', 'Drawer')), [{
49
+ todoActionList: [{
50
+ key: 'showMessage',
51
+ label: '消息提示',
52
+ todoOptions: [{
53
+ key: 'type',
54
+ label: '类型',
55
+ type: 'Select',
56
+ defaultValue: 'success',
57
+ props: {
58
+ options: [{
59
+ title: '成功',
60
+ value: 'success'
61
+ }, {
62
+ title: '提示',
63
+ value: 'info'
64
+ }, {
65
+ title: '警告',
66
+ value: 'warn'
67
+ }, {
68
+ title: '错误',
69
+ value: 'error'
70
+ }, {
71
+ title: '加载动画',
72
+ value: 'loading'
73
+ }]
74
+ }
75
+ }, {
76
+ key: 'icon',
77
+ label: '自定义图标',
78
+ type: 'ChooseIcon',
79
+ props: {
80
+ placeholder: '请选择图标'
81
+ }
82
+ }, {
83
+ key: 'value',
84
+ label: '内容',
85
+ type: 'SetExpression'
86
+ }, {
87
+ key: 'duration',
88
+ label: '加载时长',
89
+ type: 'InputNumber',
90
+ props: {
91
+ addonAfter: '秒',
92
+ step: '0.01',
93
+ formatter: function formatter(val) {
94
+ return val ? val.match(/^\d+(?:\.\d{0,2})?/) : undefined;
95
+ }
96
+ }
97
+ }, {
98
+ key: 'okText',
99
+ label: localeKey('todoActionList.showMessage.todoOptions.okText.label'),
100
+ type: 'Input'
101
+ }, {
102
+ key: 'cancelText',
103
+ label: localeKey('todoActionList.showMessage.todoOptions.cancelText.label'),
104
+ type: 'Input'
105
+ }],
106
+ todoCallbacks: ['callback1', 'callback2'],
107
+ classification: [{
108
+ label: localeKey('todoActionList.showMessage.classification.modal.label'),
109
+ value: 'modal'
110
+ }],
111
+ remarks: [{
112
+ label: '注意事项',
113
+ content: localeKey('todoActionList.showMessage.remarks.0.content')
114
+ }]
115
+ }].concat(_toConsumableArray((0, _todoActionList.getSystemTodoActionList)('pc', 'Drawer')), [{
46
116
  key: 'previewFile',
47
117
  label: '文件预览',
48
118
  todoOptions: [{
49
119
  key: 'fileId',
50
- label: '文件ID/URL',
120
+ label: localeKey('todoActionList.previewFile.todoOptions.fileId.label'),
51
121
  type: 'SetExpression',
52
- labelTip: '文件预览格式支持:pdf、jpg、jpeg、png、svg、mp4、mov、txt、html、js、doc、xlsx、docx、wps、ppt等 注意:如果是外部URL,有可能存在跨域现象!'
122
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.fileId.labelTip')
53
123
  }, {
54
124
  key: 'viewMode',
55
125
  label: '预览方式',
@@ -73,7 +143,7 @@ var _default = {
73
143
  type: 'SetExpression',
74
144
  defaultValue: '960',
75
145
  visibleFlag: 'viewMode',
76
- labelTip: '不同浏览器有不同的最小限制,请避免设置过小尺寸,当不设置宽高时,默认为全屏',
146
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.modalWidth.labelTip'),
77
147
  visibleFlagValue: ['window']
78
148
  }, {
79
149
  key: 'modalHeight',
@@ -81,7 +151,7 @@ var _default = {
81
151
  type: 'SetExpression',
82
152
  defaultValue: '648',
83
153
  visibleFlag: 'viewMode',
84
- labelTip: '不同浏览器有不同的最小限制,请避免设置过小尺寸,当不设置宽高时,默认为全屏',
154
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.modalHeight.labelTip'),
85
155
  visibleFlagValue: ['window']
86
156
  }],
87
157
  classification: [{
@@ -91,7 +161,7 @@ var _default = {
91
161
  }]),
92
162
  todoEvents: [{
93
163
  value: 'useEffect',
94
- label: '推拉门打开后'
164
+ label: localeKey('todoEvents.useEffect.label')
95
165
  }, {
96
166
  value: 'onOk',
97
167
  label: '点击确认'
@@ -100,19 +170,19 @@ var _default = {
100
170
  label: '点击取消'
101
171
  }, {
102
172
  value: 'stateChange',
103
- label: '组件状态变化后'
173
+ label: localeKey('todoEvents.stateChange.label')
104
174
  }, {
105
175
  value: 'willUnmount',
106
- label: '推拉门关闭前'
176
+ label: localeKey('todoEvents.willUnmount.label')
107
177
  }, {
108
178
  value: 'usePageEndRequest',
109
- label: '页面加载请求结束',
179
+ label: localeKey('todoEvents.usePageEndRequest.label'),
110
180
  remarks: [{
111
181
  label: '场景描述',
112
- content: '在页面加载完成事件中,所有的事件执行结束后进行回掉(包含页面加载完成事件中的异步请求(注意:定时器相关动作不计算回掉时间))'
182
+ content: localeKey('todoEvents.usePageEndRequest.remarks.0.content')
113
183
  }, {
114
184
  label: '适用场景',
115
- content: '在复杂的表单页面中,你可以在页面加载完成事件中进行页面loading的动作设置,在页面加载完成请求结束事件中取消loading,保障在复杂请求中,因异步导致数据未能及时回填,用户提交错误数据问题。'
185
+ content: localeKey('todoEvents.usePageEndRequest.remarks.1.content')
116
186
  }]
117
187
  }],
118
188
  todoProps: {
@@ -130,11 +200,11 @@ var _default = {
130
200
  groupsName: '基础',
131
201
  props: {
132
202
  required: true,
133
- placeholder: '如:/user/list',
203
+ placeholder: localeKey('todoProps.pagePath.props.placeholder'),
134
204
  regex: {
135
205
  // eslint-disable-next-line
136
206
  pattern: /^(\/[0-9A-Za-z]([_-]+[0-9A-Za-z]|[0-9A-Za-z])*)+$/i,
137
- message: '必须为/xx/yy/..格式'
207
+ message: localeKey('todoProps.pagePath.props.regex.message')
138
208
  }
139
209
  }
140
210
  },
@@ -158,6 +228,26 @@ var _default = {
158
228
  props: {},
159
229
  enableI18n: true
160
230
  },
231
+ placement: {
232
+ label: '抽屉方向',
233
+ type: 'Select',
234
+ groupsName: '基础',
235
+ props: {
236
+ options: [{
237
+ value: 'top',
238
+ title: '上'
239
+ }, {
240
+ value: 'right',
241
+ title: '右'
242
+ }, {
243
+ value: 'bottom',
244
+ title: '下'
245
+ }, {
246
+ value: 'left',
247
+ title: '左'
248
+ }]
249
+ }
250
+ },
161
251
  width: {
162
252
  label: '推拉门宽度',
163
253
  type: 'Select',
@@ -168,16 +258,16 @@ var _default = {
168
258
  },
169
259
  options: [{
170
260
  value: 560,
171
- title: 's'
261
+ title: localeKey('todoProps.width.props.options.0.title')
172
262
  }, {
173
263
  value: 624,
174
- title: 'm'
264
+ title: localeKey('todoProps.width.props.options.1.title')
175
265
  }, {
176
266
  value: 1008,
177
- title: 'l'
267
+ title: localeKey('todoProps.width.props.options.2.title')
178
268
  }, {
179
269
  value: 1200,
180
- title: 'xl'
270
+ title: localeKey('todoProps.width.props.options.3.title')
181
271
  }]
182
272
  }
183
273
  },
@@ -191,36 +281,16 @@ var _default = {
191
281
  },
192
282
  options: [{
193
283
  value: 200,
194
- title: 's'
284
+ title: localeKey('todoProps.height.props.options.0.title')
195
285
  }, {
196
286
  value: 300,
197
- title: 'm'
287
+ title: localeKey('todoProps.height.props.options.1.title')
198
288
  }, {
199
289
  value: 400,
200
- title: 'l'
290
+ title: localeKey('todoProps.height.props.options.2.title')
201
291
  }, {
202
292
  value: 500,
203
- title: 'xl'
204
- }]
205
- }
206
- },
207
- placement: {
208
- label: '抽屉方向',
209
- type: 'Select',
210
- groupsName: '基础',
211
- props: {
212
- options: [{
213
- value: 'top',
214
- title: '上'
215
- }, {
216
- value: 'right',
217
- title: '右'
218
- }, {
219
- value: 'bottom',
220
- title: '下'
221
- }, {
222
- value: 'left',
223
- title: '左'
293
+ title: localeKey('todoProps.height.props.options.3.title')
224
294
  }]
225
295
  }
226
296
  },
@@ -265,10 +335,10 @@ var _default = {
265
335
  props: {
266
336
  inhibitBtn: true,
267
337
  options: [{
268
- title: '点击蒙罩关闭窗口',
338
+ title: localeKey('todoProps.closeOnClickOverlay.props.options.0.title'),
269
339
  value: true
270
340
  }, {
271
- title: '点击蒙罩不关闭窗口',
341
+ title: localeKey('todoProps.closeOnClickOverlay.props.options.1.title'),
272
342
  value: false
273
343
  }]
274
344
  }
@@ -291,5 +361,4 @@ var _default = {
291
361
  }
292
362
  },
293
363
  todoStyles: {}
294
- };
295
- exports.default = _default;
364
+ };
@@ -11,7 +11,6 @@ declare const _default: {
11
11
  customHeight: number;
12
12
  closeOnClickOverlay: boolean;
13
13
  footer: number;
14
- layout: string;
15
14
  compState: {
16
15
  name: string;
17
16
  code: string;
@@ -10,10 +10,15 @@ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread n
10
10
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
11
11
  function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
12
12
  function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
13
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
14
- var _default = {
13
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
14
+ var PC_MODAL_LOCALE_PREFIX = 'pc.modal';
15
+ var localeKey = function localeKey(suffix) {
16
+ return "".concat(PC_MODAL_LOCALE_PREFIX, ".").concat(suffix);
17
+ };
18
+ var _default = exports.default = {
15
19
  compLib: 'root',
16
20
  compType: -1,
21
+ // 根节点
17
22
  isBusiObjContainer: false,
18
23
  isContainer: false,
19
24
  label: '弹窗',
@@ -24,7 +29,6 @@ var _default = {
24
29
  customHeight: 500,
25
30
  closeOnClickOverlay: false,
26
31
  footer: 1,
27
- layout: 'BlankLayout',
28
32
  compState: [{
29
33
  name: '业务主键',
30
34
  code: 'bizId'
@@ -43,14 +47,80 @@ var _default = {
43
47
  description: '',
44
48
  image: '',
45
49
  groupsName: 'root',
46
- todoActionList: [].concat(_toConsumableArray((0, _todoActionList.getSystemTodoActionList)('pc', 'Modal')), [{
50
+ todoActionList: [{
51
+ key: 'showMessage',
52
+ label: '消息提示',
53
+ todoOptions: [{
54
+ key: 'type',
55
+ label: '类型',
56
+ type: 'Select',
57
+ defaultValue: 'success',
58
+ props: {
59
+ options: [{
60
+ title: '成功',
61
+ value: 'success'
62
+ }, {
63
+ title: '提示',
64
+ value: 'info'
65
+ }, {
66
+ title: '警告',
67
+ value: 'warn'
68
+ }, {
69
+ title: '错误',
70
+ value: 'error'
71
+ }, {
72
+ title: '加载动画',
73
+ value: 'loading'
74
+ }]
75
+ }
76
+ }, {
77
+ key: 'icon',
78
+ label: '自定义图标',
79
+ type: 'ChooseIcon',
80
+ props: {
81
+ placeholder: '请选择图标'
82
+ }
83
+ }, {
84
+ key: 'value',
85
+ label: '内容',
86
+ type: 'SetExpression'
87
+ }, {
88
+ key: 'duration',
89
+ label: '加载时长',
90
+ type: 'InputNumber',
91
+ props: {
92
+ addonAfter: '秒',
93
+ step: '0.01',
94
+ formatter: function formatter(val) {
95
+ return val ? val.match(/^\d+(?:\.\d{0,2})?/) : undefined;
96
+ }
97
+ }
98
+ }, {
99
+ key: 'okText',
100
+ label: localeKey('todoActionList.showMessage.todoOptions.okText.label'),
101
+ type: 'Input'
102
+ }, {
103
+ key: 'cancelText',
104
+ label: localeKey('todoActionList.showMessage.todoOptions.cancelText.label'),
105
+ type: 'Input'
106
+ }],
107
+ todoCallbacks: ['callback1', 'callback2'],
108
+ classification: [{
109
+ label: localeKey('todoActionList.showMessage.classification.modal.label'),
110
+ value: 'modal'
111
+ }],
112
+ remarks: [{
113
+ label: '注意事项',
114
+ content: localeKey('todoActionList.showMessage.remarks.0.content')
115
+ }]
116
+ }].concat(_toConsumableArray((0, _todoActionList.getSystemTodoActionList)('pc', 'Modal')), [{
47
117
  key: 'previewFile',
48
118
  label: '文件预览',
49
119
  todoOptions: [{
50
120
  key: 'fileId',
51
- label: '文件ID/URL',
121
+ label: localeKey('todoActionList.previewFile.todoOptions.fileId.label'),
52
122
  type: 'SetExpression',
53
- labelTip: '文件预览格式支持:pdf、jpg、jpeg、png、svg、mp4、mov、txt、html、js、doc、xlsx、docx、wps、ppt等 注意:如果是外部URL,有可能存在跨域现象!'
123
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.fileId.labelTip')
54
124
  }, {
55
125
  key: 'viewMode',
56
126
  label: '预览方式',
@@ -74,7 +144,7 @@ var _default = {
74
144
  type: 'SetExpression',
75
145
  defaultValue: '960',
76
146
  visibleFlag: 'viewMode',
77
- labelTip: '不同浏览器有不同的最小限制,请避免设置过小尺寸,当不设置宽高时,默认为全屏',
147
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.modalWidth.labelTip'),
78
148
  visibleFlagValue: ['window']
79
149
  }, {
80
150
  key: 'modalHeight',
@@ -82,7 +152,7 @@ var _default = {
82
152
  type: 'SetExpression',
83
153
  defaultValue: '648',
84
154
  visibleFlag: 'viewMode',
85
- labelTip: '不同浏览器有不同的最小限制,请避免设置过小尺寸,当不设置宽高时,默认为全屏',
155
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.modalHeight.labelTip'),
86
156
  visibleFlagValue: ['window']
87
157
  }],
88
158
  classification: [{
@@ -104,16 +174,16 @@ var _default = {
104
174
  label: '点击取消'
105
175
  }, {
106
176
  value: 'stateChange',
107
- label: '组件状态变化后'
177
+ label: localeKey('todoEvents.stateChange.label')
108
178
  }, {
109
179
  value: 'usePageEndRequest',
110
- label: '页面加载请求结束',
180
+ label: localeKey('todoEvents.usePageEndRequest.label'),
111
181
  remarks: [{
112
182
  label: '场景描述',
113
- content: '在页面加载完成事件中,所有的事件执行结束后进行回掉(包含页面加载完成事件中的异步请求(注意:定时器相关动作不计算回掉时间))'
183
+ content: localeKey('todoEvents.usePageEndRequest.remarks.0.content')
114
184
  }, {
115
185
  label: '适用场景',
116
- content: '在复杂的表单页面中,你可以在页面加载完成事件中进行页面loading的动作设置,在页面加载完成请求结束事件中取消loading,保障在复杂请求中,因异步导致数据未能及时回填,用户提交错误数据问题。'
186
+ content: localeKey('todoEvents.usePageEndRequest.remarks.1.content')
117
187
  }]
118
188
  }],
119
189
  todoProps: {
@@ -131,11 +201,11 @@ var _default = {
131
201
  groupsName: '基础',
132
202
  props: {
133
203
  required: true,
134
- placeholder: '如:/user/list',
204
+ placeholder: localeKey('todoProps.pagePath.props.placeholder'),
135
205
  regex: {
136
206
  // eslint-disable-next-line
137
207
  pattern: /^(\/[0-9A-Za-z]([_-]+[0-9A-Za-z]|[0-9A-Za-z])*)+$/i,
138
- message: '必须为/xx/yy/..格式'
208
+ message: localeKey('todoProps.pagePath.props.regex.message')
139
209
  }
140
210
  }
141
211
  },
@@ -166,16 +236,16 @@ var _default = {
166
236
  props: {
167
237
  options: [{
168
238
  value: 560,
169
- title: 's(560*auto)'
239
+ title: localeKey('todoProps.width.props.options.0.title')
170
240
  }, {
171
241
  value: 624,
172
- title: 'm(624*auto)'
242
+ title: localeKey('todoProps.width.props.options.1.title')
173
243
  }, {
174
244
  value: 1008,
175
- title: 'l(1008*auto)'
245
+ title: localeKey('todoProps.width.props.options.2.title')
176
246
  }, {
177
247
  value: 1200,
178
- title: 'xl(1200*auto)'
248
+ title: localeKey('todoProps.width.props.options.3.title')
179
249
  }, {
180
250
  value: 'custom',
181
251
  title: '自定义'
@@ -245,10 +315,10 @@ var _default = {
245
315
  props: {
246
316
  inhibitBtn: true,
247
317
  options: [{
248
- title: '点击蒙罩关闭窗口',
318
+ title: localeKey('todoProps.closeOnClickOverlay.props.options.0.title'),
249
319
  value: true
250
320
  }, {
251
- title: '点击蒙罩不关闭窗口',
321
+ title: localeKey('todoProps.closeOnClickOverlay.props.options.1.title'),
252
322
  value: false
253
323
  }]
254
324
  }
@@ -271,5 +341,4 @@ var _default = {
271
341
  }
272
342
  },
273
343
  todoStyles: {}
274
- };
275
- exports.default = _default;
344
+ };
@@ -11,7 +11,6 @@ declare const _default: {
11
11
  customHeight: number;
12
12
  closeOnClickOverlay: boolean;
13
13
  footer: number;
14
- layout: string;
15
14
  compState: {
16
15
  name: string;
17
16
  code: string;
@@ -10,10 +10,15 @@ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread n
10
10
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
11
11
  function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
12
12
  function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
13
- function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
14
- var _default = {
13
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
14
+ var PC_POPOVER_LOCALE_PREFIX = 'pc.popover';
15
+ var localeKey = function localeKey(suffix) {
16
+ return "".concat(PC_POPOVER_LOCALE_PREFIX, ".").concat(suffix);
17
+ };
18
+ var _default = exports.default = {
15
19
  compLib: 'root',
16
20
  compType: -1,
21
+ // 根节点
17
22
  isBusiObjContainer: false,
18
23
  isContainer: false,
19
24
  label: '气泡卡片',
@@ -24,7 +29,6 @@ var _default = {
24
29
  customHeight: 500,
25
30
  closeOnClickOverlay: true,
26
31
  footer: 1,
27
- layout: 'BlankLayout',
28
32
  compState: [{
29
33
  name: '业务主键',
30
34
  code: 'bizId'
@@ -37,14 +41,80 @@ var _default = {
37
41
  description: '',
38
42
  image: '',
39
43
  groupsName: 'root',
40
- todoActionList: [].concat(_toConsumableArray((0, _todoActionList.getSystemTodoActionList)('pc')), [{
44
+ todoActionList: [{
45
+ key: 'showMessage',
46
+ label: '消息提示',
47
+ todoOptions: [{
48
+ key: 'type',
49
+ label: '类型',
50
+ type: 'Select',
51
+ defaultValue: 'success',
52
+ props: {
53
+ options: [{
54
+ title: '成功',
55
+ value: 'success'
56
+ }, {
57
+ title: '提示',
58
+ value: 'info'
59
+ }, {
60
+ title: '警告',
61
+ value: 'warn'
62
+ }, {
63
+ title: '错误',
64
+ value: 'error'
65
+ }, {
66
+ title: '加载动画',
67
+ value: 'loading'
68
+ }]
69
+ }
70
+ }, {
71
+ key: 'icon',
72
+ label: '自定义图标',
73
+ type: 'ChooseIcon',
74
+ props: {
75
+ placeholder: '请选择图标'
76
+ }
77
+ }, {
78
+ key: 'value',
79
+ label: '内容',
80
+ type: 'SetExpression'
81
+ }, {
82
+ key: 'duration',
83
+ label: '加载时长',
84
+ type: 'InputNumber',
85
+ props: {
86
+ addonAfter: '秒',
87
+ step: '0.01',
88
+ formatter: function formatter(val) {
89
+ return val ? val.match(/^\d+(?:\.\d{0,2})?/) : undefined;
90
+ }
91
+ }
92
+ }, {
93
+ key: 'okText',
94
+ label: localeKey('todoActionList.showMessage.todoOptions.okText.label'),
95
+ type: 'Input'
96
+ }, {
97
+ key: 'cancelText',
98
+ label: localeKey('todoActionList.showMessage.todoOptions.cancelText.label'),
99
+ type: 'Input'
100
+ }],
101
+ todoCallbacks: ['callback1', 'callback2'],
102
+ classification: [{
103
+ label: localeKey('todoActionList.showMessage.classification.modal.label'),
104
+ value: 'modal'
105
+ }],
106
+ remarks: [{
107
+ label: '注意事项',
108
+ content: localeKey('todoActionList.showMessage.remarks.0.content')
109
+ }]
110
+ }].concat(_toConsumableArray((0, _todoActionList.getSystemTodoActionList)('pc')), [{
41
111
  key: 'previewFile',
42
112
  label: '文件预览',
43
113
  todoOptions: [{
44
114
  key: 'fileId',
45
- label: '文件ID/URL',
115
+ label: localeKey('todoActionList.previewFile.todoOptions.fileId.label'),
46
116
  type: 'SetExpression',
47
- labelTip: '文件预览格式支持:pdf、jpg、jpeg、png、svg、mp4、mov、txt、html、js、doc、xlsx、docx、wps、ppt等 注意:如果是外部URL,有可能存在跨域现象!'
117
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.fileId.labelTip')
48
118
  }, {
49
119
  key: 'viewMode',
50
120
  label: '预览方式',
@@ -68,7 +138,7 @@ var _default = {
68
138
  type: 'SetExpression',
69
139
  defaultValue: '960',
70
140
  visibleFlag: 'viewMode',
71
- labelTip: '不同浏览器有不同的最小限制,请避免设置过小尺寸,当不设置宽高时,默认为全屏',
141
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.modalWidth.labelTip'),
72
142
  visibleFlagValue: ['window']
73
143
  }, {
74
144
  key: 'modalHeight',
@@ -76,7 +146,7 @@ var _default = {
76
146
  type: 'SetExpression',
77
147
  defaultValue: '648',
78
148
  visibleFlag: 'viewMode',
79
- labelTip: '不同浏览器有不同的最小限制,请避免设置过小尺寸,当不设置宽高时,默认为全屏',
149
+ labelTip: localeKey('todoActionList.previewFile.todoOptions.modalHeight.labelTip'),
80
150
  visibleFlagValue: ['window']
81
151
  }],
82
152
  classification: [{
@@ -86,22 +156,22 @@ var _default = {
86
156
  }]),
87
157
  todoEvents: [{
88
158
  value: 'useEffect',
89
- label: '浮窗加载完成'
159
+ label: localeKey('todoEvents.useEffect.label')
90
160
  }, {
91
161
  value: 'stateChange',
92
- label: '组件状态变化后'
162
+ label: localeKey('todoEvents.stateChange.label')
93
163
  }, {
94
164
  value: 'willUnmount',
95
165
  label: '浮窗关闭'
96
166
  }, {
97
167
  value: 'usePageEndRequest',
98
- label: '页面加载请求结束',
168
+ label: localeKey('todoEvents.usePageEndRequest.label'),
99
169
  remarks: [{
100
170
  label: '场景描述',
101
- content: '在页面加载完成事件中,所有的事件执行结束后进行回掉(包含页面加载完成事件中的异步请求(注意:定时器相关动作不计算回掉时间))'
171
+ content: localeKey('todoEvents.usePageEndRequest.remarks.0.content')
102
172
  }, {
103
173
  label: '适用场景',
104
- content: '在复杂的表单页面中,你可以在页面加载完成事件中进行页面loading的动作设置,在页面加载完成请求结束事件中取消loading,保障在复杂请求中,因异步导致数据未能及时回填,用户提交错误数据问题。'
174
+ content: localeKey('todoEvents.usePageEndRequest.remarks.1.content')
105
175
  }]
106
176
  }],
107
177
  todoProps: {
@@ -124,11 +194,11 @@ var _default = {
124
194
  groupsName: '基础',
125
195
  props: {
126
196
  required: true,
127
- placeholder: '如:/user/list',
197
+ placeholder: localeKey('todoProps.pagePath.props.placeholder'),
128
198
  regex: {
129
199
  // eslint-disable-next-line
130
200
  pattern: /^(\/[0-9A-Za-z]([_-]+[0-9A-Za-z]|[0-9A-Za-z])*)+$/i,
131
- message: '必须为/xx/yy/..格式'
201
+ message: localeKey('todoProps.pagePath.props.regex.message')
132
202
  }
133
203
  }
134
204
  },
@@ -170,5 +240,4 @@ var _default = {
170
240
  }
171
241
  },
172
242
  todoStyles: {}
173
- };
174
- exports.default = _default;
243
+ };