@cloudbase/weda-ui 2.0.9 → 2.0.12

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 (235) hide show
  1. package/README.md +1 -0
  2. package/package.json +13 -5
  3. package/src/configs/components/button.json +60 -13
  4. package/src/configs/components/calendar.json +3 -3
  5. package/src/configs/components/carousel.json +57 -47
  6. package/src/configs/components/chart/bar.json +4 -13
  7. package/src/configs/components/chart/line.json +4 -13
  8. package/src/configs/components/chart/pie.json +3 -10
  9. package/src/configs/components/chart/statisticsCard.json +1 -4
  10. package/src/configs/components/container.json +1 -3
  11. package/src/configs/components/dataView.json +7 -15
  12. package/src/configs/components/drawer.json +24 -6
  13. package/src/configs/components/form/form.json +19 -0
  14. package/src/configs/components/form/input.json +20 -5
  15. package/src/configs/components/form/location.json +51 -48
  16. package/src/configs/components/form/radio.json +1 -3
  17. package/src/configs/components/form/richText.json +14 -14
  18. package/src/configs/components/form/select.json +62 -82
  19. package/src/configs/components/form/textarea.json +6 -1
  20. package/src/configs/components/form/uploader.json +64 -64
  21. package/src/configs/components/form/uploaderFile.json +1 -2
  22. package/src/configs/components/graphicCard.json +43 -44
  23. package/src/configs/components/image.json +44 -40
  24. package/src/configs/components/link.json +5 -10
  25. package/src/configs/components/listView.json +2 -8
  26. package/src/configs/components/lottery.json +7 -3
  27. package/src/configs/components/modal.json +26 -21
  28. package/src/configs/components/navLayout.json +66 -67
  29. package/src/configs/components/navigationBar.json +4 -1
  30. package/src/configs/components/richtextview.json +1 -1
  31. package/src/configs/components/scrollVeiw.json +14 -42
  32. package/src/configs/components/swiper.json +9 -9
  33. package/src/configs/components/wedaVideo.json +86 -0
  34. package/src/configs/components/wxOpenApi/phone.json +7 -21
  35. package/src/configs/components/wxOpenApi/phoneCode.json +7 -19
  36. package/src/configs/components/wxOpenApi/share.json +14 -24
  37. package/src/configs/components/wxOpenApi/userInfo.json +9 -27
  38. package/src/configs/index.js +2 -0
  39. package/src/docs/common/format.tsx +4 -1
  40. package/src/docs/common/tableView.css +3 -3
  41. package/src/docs/common/tableView.tsx +18 -8
  42. package/src/docs/compsdocs/form/FormLocation.mdx +1 -1
  43. package/src/docs/compsdocs/form/FormSelect.mdx +0 -1
  44. package/src/docs/compsdocs/grid/Card.mdx +0 -1
  45. package/src/docs/compsdocs/grid/Container.mdx +0 -1
  46. package/src/docs/compsdocs/grid/GridLayout.mdx +0 -1
  47. package/src/docs/compsdocs/grid/ScrollView.mdx +2 -2
  48. package/src/docs/compsdocs/grid/Swiper.mdx +1 -2
  49. package/src/docs/compsdocs/media/Icon.mdx +1 -1
  50. package/src/docs/compsdocs/media/Image.mdx +6 -6
  51. package/src/docs/compsdocs/model/ModelCreate.mdx +24 -0
  52. package/src/docs/compsdocs/model/ModelDetail.mdx +24 -0
  53. package/src/docs/compsdocs/model/ModelTable.mdx +133 -1
  54. package/src/docs/compsdocs/model/ModelUpdate.mdx +24 -1
  55. package/src/docs/compsdocs/navmenu/Classification.mdx +2 -3
  56. package/src/docs/compsdocs/navmenu/NavBar.mdx +14 -5
  57. package/src/docs/compsdocs/navmenu/NavLayout.mdx +0 -1
  58. package/src/docs/compsdocs/navmenu/TabBar.mdx +3 -3
  59. package/src/docs/compsdocs/navmenu/TabBarItem.mdx +1 -1
  60. package/src/docs/compsdocs/senior/Lottery.mdx +3 -6
  61. package/src/docs/compsdocs/senior/Modal.mdx +2 -3
  62. package/src/docs/compsdocs/senior/SlotMachine.mdx +2 -5
  63. package/src/docs/compsdocs/senior/_category_.json +1 -1
  64. package/src/docs/compsdocs/show/GraphicCard.mdx +0 -1
  65. package/src/docs/compsdocs/show/Item.mdx +0 -1
  66. package/src/docs/compsdocs/show/ItemList.mdx +1 -0
  67. package/src/docs/compsdocs/show/Tabs.mdx +2 -3
  68. package/src/docs/compsdocs/text/Link.mdx +1 -1
  69. package/src/docs/compsdocs/text/RichTextView.mdx +1 -2
  70. package/src/docs/compsdocs/text/Text.mdx +1 -1
  71. package/src/docs/compsdocs/text/Title.mdx +1 -2
  72. package/src/docs/compsdocs/wxOpen/Phone.mdx +1 -2
  73. package/src/docs/compsdocs/wxOpen/Share.mdx +0 -1
  74. package/src/docs/compsdocs/wxOpen/UserInfo.mdx +1 -2
  75. package/src/mp/components/button/index.js +1 -1
  76. package/src/mp/components/button/index.wxml +19 -19
  77. package/src/mp/components/calendar/index.js +64 -37
  78. package/src/mp/components/calendar/index.json +1 -1
  79. package/src/mp/components/calendar/index.wxml +4 -6
  80. package/src/mp/components/carousel/index.json +1 -1
  81. package/src/mp/components/carousel/index.wxml +2 -2
  82. package/src/mp/components/chart/bar/index.js +1 -2
  83. package/src/mp/components/chart/bar/index.wxml +1 -1
  84. package/src/mp/components/chart/common/config/bar.js +1 -1
  85. package/src/mp/components/chart/common/core/eChartBar.js +29 -34
  86. package/src/mp/components/chart/common/core/eChartBase.js +46 -32
  87. package/src/mp/components/chart/common/core/eChartLine.js +34 -40
  88. package/src/mp/components/chart/common/core/eChartPie.js +12 -9
  89. package/src/mp/components/chart/ec-canvas/ec-canvas.json +1 -1
  90. package/src/mp/components/chart/ec-canvas/wx-canvas.js +24 -22
  91. package/src/mp/components/chart/line/index.js +2 -2
  92. package/src/mp/components/chart/line/index.wxml +1 -1
  93. package/src/mp/components/chart/pie/index.js +1 -1
  94. package/src/mp/components/chart/pie/index.wxml +1 -2
  95. package/src/mp/components/dataView/index.wxml +2 -14
  96. package/src/mp/components/form/checkbox/index.js +10 -6
  97. package/src/mp/components/form/checkbox/index.wxml +13 -25
  98. package/src/mp/components/form/form/index.wxml +3 -3
  99. package/src/mp/components/form/formcell/index.wxml +9 -9
  100. package/src/mp/components/form/formcell/index.wxss +6 -1
  101. package/src/mp/components/form/input/index.js +3 -3
  102. package/src/mp/components/form/input/index.wxml +24 -31
  103. package/src/mp/components/form/input/index.wxss +9 -3
  104. package/src/mp/components/form/location/components/mapChoose/index.json +1 -1
  105. package/src/mp/components/form/location/components/mapChoose/index.wxml +6 -6
  106. package/src/mp/components/form/location/index.js +7 -1
  107. package/src/mp/components/form/location/index.json +1 -1
  108. package/src/mp/components/form/location/index.wxml +6 -10
  109. package/src/mp/components/form/radio/index.js +9 -5
  110. package/src/mp/components/form/radio/index.wxml +12 -24
  111. package/src/mp/components/form/select/index.js +156 -97
  112. package/src/mp/components/form/select/index.wxml +11 -39
  113. package/src/mp/components/form/select/index.wxss +14 -3
  114. package/src/mp/components/form/select/region/index.js +18 -12
  115. package/src/mp/components/form/switch/index.wxml +11 -18
  116. package/src/mp/components/form/textarea/index.wxml +2 -17
  117. package/src/mp/components/form/textarea/index.wxss +5 -0
  118. package/src/mp/components/form/tips/index.wxml +1 -3
  119. package/src/mp/components/form/uploader/index.js +1 -1
  120. package/src/mp/components/form/uploader/index.wxml +3 -20
  121. package/src/mp/components/form/uploader/weui-uploader.js +210 -200
  122. package/src/mp/components/form/uploader/weui-uploader.json +6 -6
  123. package/src/mp/components/form/uploader/weui-uploader.wxml +38 -38
  124. package/src/mp/components/form/uploaderFile/index.js +5 -4
  125. package/src/mp/components/form/uploaderFile/index.wxml +40 -41
  126. package/src/mp/components/graphicCard/index.js +35 -35
  127. package/src/mp/components/graphicCard/index.wxml +2 -6
  128. package/src/mp/components/image/index.wxml +9 -20
  129. package/src/mp/components/image/index.wxss +3 -1
  130. package/src/mp/components/listView/index.wxml +5 -7
  131. package/src/mp/components/lottery/index.wxml +1 -3
  132. package/src/mp/components/lottery/index.wxss +31 -25
  133. package/src/mp/components/navLayout/index.js +9 -12
  134. package/src/mp/components/navLayout/index.wxml +2 -4
  135. package/src/mp/components/navigationBar/index.json +1 -2
  136. package/src/mp/components/navigationBar/index.wxml +43 -51
  137. package/src/mp/components/swiper/index.wxml +1 -9
  138. package/src/mp/components/tabs/index.js +14 -10
  139. package/src/mp/components/tabs/index.json +1 -1
  140. package/src/mp/components/tabs/index.wxml +3 -21
  141. package/src/mp/components/text/index.wxml +1 -6
  142. package/src/mp/components/text/index.wxss +1 -1
  143. package/src/mp/components/wedaVideo/index.js +86 -0
  144. package/src/mp/components/wedaVideo/index.json +4 -0
  145. package/src/mp/components/wedaVideo/index.wxml +4 -0
  146. package/src/mp/components/wedaVideo/index.wxss +20 -0
  147. package/src/mp/components/wxOpenApi/phone/index.js +1 -9
  148. package/src/mp/components/wxOpenApi/phone/index.wxml +3 -14
  149. package/src/mp/components/wxOpenApi/phoneCode/index.json +1 -1
  150. package/src/mp/components/wxOpenApi/phoneCode/index.wxml +3 -14
  151. package/src/mp/components/wxOpenApi/share/index.wxml +3 -14
  152. package/src/mp/components/wxOpenApi/userInfo/index.wxml +3 -13
  153. package/src/mp/index.json +1 -0
  154. package/src/mp/style/weda-ui.wxss +20 -7
  155. package/src/mp/utils/deepEqual.js +37 -37
  156. package/src/mp/utils/destr.js +41 -40
  157. package/src/mp/utils/dr_square_point.js +10 -6
  158. package/src/setupTests.js +13 -13
  159. package/src/web/actions/showModal/index.tsx +5 -4
  160. package/src/web/components/button/index.tsx +44 -40
  161. package/src/web/components/calendar/index.css +81 -34
  162. package/src/web/components/carousel/index.tsx +1 -1
  163. package/src/web/components/chart/common/config/bar.js +1 -1
  164. package/src/web/components/chart/common/core/eChartBar.js +28 -34
  165. package/src/web/components/chart/common/core/eChartBase.ts +55 -42
  166. package/src/web/components/chart/common/core/eChartLine.js +34 -40
  167. package/src/web/components/chart/common/core/eChartPie.js +12 -9
  168. package/src/web/components/chart/common/core/type.ts +23 -23
  169. package/src/web/components/chart/common/echart.css +12 -12
  170. package/src/web/components/chart/common/echarts.ts +3 -5
  171. package/src/web/components/chart/common/useChart.tsx +34 -16
  172. package/src/web/components/container/index.tsx +3 -4
  173. package/src/web/components/drawer/index.tsx +15 -4
  174. package/src/web/components/form/checkbox/index.tsx +32 -31
  175. package/src/web/components/form/enumSelect/NormalSelect.tsx +0 -2
  176. package/src/web/components/form/form/index.css +3 -6
  177. package/src/web/components/form/form/index.tsx +7 -6
  178. package/src/web/components/form/formcell/index.css +10 -4
  179. package/src/web/components/form/formcell/index.tsx +3 -7
  180. package/src/web/components/form/input/index.css +4 -4
  181. package/src/web/components/form/input/index.tsx +61 -53
  182. package/src/web/components/form/location/common/selectModal.jsx +2 -11
  183. package/src/web/components/form/location/common/useLocationInfo.js +4 -0
  184. package/src/web/components/form/location/components/LocationH5/index.css +0 -1
  185. package/src/web/components/form/location/components/LocationH5/location.h5.jsx +11 -1
  186. package/src/web/components/form/location/components/LocationPC/Header.jsx +0 -13
  187. package/src/web/components/form/location/components/LocationPC/location.PC.jsx +14 -5
  188. package/src/web/components/form/radio/index.tsx +32 -26
  189. package/src/web/components/form/renderDecorator.tsx +23 -26
  190. package/src/web/components/form/select/h5.tsx +154 -103
  191. package/src/web/components/form/select/index.css +9 -3
  192. package/src/web/components/form/select/index.tsx +75 -48
  193. package/src/web/components/form/select/region/index.ts +101 -80
  194. package/src/web/components/form/select/year.tsx +2 -0
  195. package/src/web/components/form/switch/index.tsx +40 -40
  196. package/src/web/components/form/textarea/index.css +4 -0
  197. package/src/web/components/form/textarea/index.tsx +27 -26
  198. package/src/web/components/form/types.d.ts +10 -10
  199. package/src/web/components/form/uploader/uploader.h5.tsx +26 -20
  200. package/src/web/components/form/uploaderFile/index.jsx +0 -5
  201. package/src/web/components/form/uploaderFile/uploadFile.h5.tsx +15 -11
  202. package/src/web/components/form/uploaderFile/uploadFile.pc.tsx +14 -9
  203. package/src/web/components/image/image.tsx +2 -2
  204. package/src/web/components/image/index.css +9 -7
  205. package/src/web/components/image/index.tsx +29 -12
  206. package/src/web/components/index.js +1 -0
  207. package/src/web/components/link/index.tsx +13 -13
  208. package/src/web/components/lottery/index.css +43 -37
  209. package/src/web/components/lottery/index.tsx +2 -2
  210. package/src/web/components/modal/index.tsx +34 -34
  211. package/src/web/components/navLayout/index.tsx +1 -1
  212. package/src/web/components/navigationBar/index.tsx +2 -2
  213. package/src/web/components/picker/datePicker.tsx +3 -3
  214. package/src/web/components/picker/picker.tsx +3 -3
  215. package/src/web/components/picker/timePicker.tsx +1 -1
  216. package/src/web/components/richText/index.jsx +41 -46
  217. package/src/web/components/richTextView/index.tsx +4 -6
  218. package/src/web/components/scrollView/index.tsx +2 -2
  219. package/src/web/components/slot/index.tsx +3 -4
  220. package/src/web/components/swiper/index.css +1 -1
  221. package/src/web/components/swiper/index.tsx +33 -15
  222. package/src/web/components/tabs/index.css +1 -1
  223. package/src/web/components/tabs/index.tsx +6 -6
  224. package/src/web/components/tabs/tabs.h5.tsx +17 -12
  225. package/src/web/components/tabs/tabs.pc.tsx +45 -34
  226. package/src/web/components/text/index.css +1 -1
  227. package/src/web/components/text/index.tsx +13 -14
  228. package/src/web/components/wedaVideo/index.css +42 -0
  229. package/src/web/components/wedaVideo/index.tsx +198 -0
  230. package/src/web/utils/constant.ts +2 -1
  231. package/src/web/utils/isObjectEqual.js +2 -1
  232. package/src/web/utils/loading-fallback.tsx +2 -2
  233. package/src/web/utils/lodash.ts +1 -1
  234. package/src/web/utils/useSetState.ts +6 -2
  235. package/src/web/weda-ui.css +17 -0
@@ -73,6 +73,12 @@
73
73
  },
74
74
  "iconSrc": {
75
75
  "type": "image",
76
+ "x-rules": [
77
+ {
78
+ "message": "请输入合法的图片地址",
79
+ "pattern": "^(((https?)://)|/resources/)[^\\s]+$"
80
+ }
81
+ ],
76
82
  "title": "",
77
83
  "default": "",
78
84
  "x-index": 35
@@ -102,18 +108,13 @@
102
108
  "icon": "weda-editor-icon-link",
103
109
  "tooltip": [
104
110
  {
105
- "platform": [
106
- "ALL",
107
- "MP"
108
- ],
111
+ "platform": ["ALL", "MP"],
109
112
  "text": "小程序平台不支持跳转外部链接"
110
113
  }
111
114
  ],
112
115
  "disabled": [
113
116
  {
114
- "platform": [
115
- "MP"
116
- ]
117
+ "platform": ["MP"]
117
118
  }
118
119
  ]
119
120
  }
@@ -154,9 +155,7 @@
154
155
  "x-category": "基础属性",
155
156
  "x-index": 120,
156
157
  "x-component-props": {
157
- "hideAddPlatform": [
158
- "MP"
159
- ],
158
+ "hideAddPlatform": ["MP"],
160
159
  "addHidden": true
161
160
  },
162
161
  "x-linkages": [
@@ -230,6 +229,63 @@
230
229
  "x-index": 1,
231
230
  "x-component": "list"
232
231
  },
232
+ "fontWeight": {
233
+ "type": "string",
234
+ "title": "字重",
235
+ "default": "normal",
236
+ "x-category": "高级属性",
237
+ "x-index": 40,
238
+ "enum": [
239
+ {
240
+ "label": "细",
241
+ "value": "lighter"
242
+ },
243
+ {
244
+ "label": "正常",
245
+ "value": "normal"
246
+ },
247
+ {
248
+ "label": "粗",
249
+ "value": "bolder"
250
+ }
251
+ ],
252
+ "remarks": "标题字重"
253
+ },
254
+ "fontSize": {
255
+ "type": "number",
256
+ "title": "字号",
257
+ "default": 14,
258
+ "x-category": "高级属性",
259
+ "x-props": {
260
+ "min": 0,
261
+ "max": 100
262
+ },
263
+ "x-index": 45,
264
+ "remarks": "标题字号"
265
+ },
266
+ "textColor": {
267
+ "title": "标题颜色",
268
+ "type": "string",
269
+ "x-component": "color",
270
+ "x-index": 50,
271
+ "x-category": "高级属性",
272
+ "default": "rgb(0, 0, 0)"
273
+ },
274
+ "lineHeight": {
275
+ "title": "行高",
276
+ "type": "string",
277
+ "x-index": 56,
278
+ "x-category": "高级属性",
279
+ "default": "auto",
280
+ "remarks": "标题行高"
281
+ },
282
+ "maxLines": {
283
+ "title": "标题行数",
284
+ "type": "number",
285
+ "default": 1,
286
+ "x-index": 60,
287
+ "x-category": "高级属性"
288
+ },
233
289
  "mobileCol": {
234
290
  "type": "number",
235
291
  "default": 4,
@@ -295,63 +351,6 @@
295
351
  "value": "big"
296
352
  }
297
353
  ]
298
- },
299
- "textColor": {
300
- "title": "标题颜色",
301
- "type": "string",
302
- "x-component": "color",
303
- "x-index": 50,
304
- "x-category": "高级属性",
305
- "default": "rgb(0, 0, 0)"
306
- },
307
- "fontWeight": {
308
- "type": "string",
309
- "title": "字重",
310
- "default": "normal",
311
- "x-category": "高级属性",
312
- "x-index": 40,
313
- "enum": [
314
- {
315
- "label": "细",
316
- "value": "lighter"
317
- },
318
- {
319
- "label": "正常",
320
- "value": "normal"
321
- },
322
- {
323
- "label": "粗",
324
- "value": "bolder"
325
- }
326
- ],
327
- "remarks": "标题字重"
328
- },
329
- "fontSize": {
330
- "type": "number",
331
- "title": "字号",
332
- "default": 14,
333
- "x-category": "高级属性",
334
- "x-props": {
335
- "min": 0,
336
- "max": 100
337
- },
338
- "x-index": 45,
339
- "remarks": "标题字号"
340
- },
341
- "lineHeight": {
342
- "title": "行高",
343
- "type": "string",
344
- "x-index": 56,
345
- "x-category": "高级属性",
346
- "default": "auto",
347
- "remarks": "标题行高"
348
- },
349
- "maxLines": {
350
- "title": "标题行数",
351
- "type": "number",
352
- "default": 1,
353
- "x-index": 60,
354
- "x-category": "高级属性"
355
354
  }
356
355
  }
357
356
  },
@@ -14,7 +14,10 @@
14
14
  "menuData": {
15
15
  "title": "",
16
16
  "type": "array",
17
- "items": { "type": "object", "properties": {} }
17
+ "items": {
18
+ "type": "object",
19
+ "properties": {}
20
+ }
18
21
  },
19
22
  "navigationStyle": {
20
23
  "title": "",
@@ -9,7 +9,7 @@
9
9
  "default": "<p style='color:red'>这是富文本</p>",
10
10
  "x-category": "基础属性",
11
11
  "x-index": 1,
12
- "remarks":"更改富文本的展示内容,支持使用html语言进行富文本内容的编辑"
12
+ "remarks": "更改富文本的展示内容,支持使用html语言进行富文本内容的编辑"
13
13
  }
14
14
  }
15
15
  },
@@ -64,9 +64,7 @@
64
64
  "title": "在设置滚动条位置时使用动画过渡",
65
65
  "type": "boolean",
66
66
  "default": false,
67
- "x-platforms": [
68
- "MP"
69
- ],
67
+ "x-platforms": ["MP"],
70
68
  "x-category": "高级属性",
71
69
  "remarks": "开启滚动条动画"
72
70
  },
@@ -74,9 +72,7 @@
74
72
  "title": "iOS点击顶部状态栏、安卓双击标题栏时,滚动条返回顶部,只支持竖向",
75
73
  "type": "boolean",
76
74
  "default": false,
77
- "x-platforms": [
78
- "MP"
79
- ],
75
+ "x-platforms": ["MP"],
80
76
  "x-category": "高级属性",
81
77
  "remarks": "开启后当执行对应操作后滚动条将自动返回顶部"
82
78
  },
@@ -84,9 +80,7 @@
84
80
  "title": "启用 flexbox 布局",
85
81
  "type": "boolean",
86
82
  "default": false,
87
- "x-platforms": [
88
- "MP"
89
- ],
83
+ "x-platforms": ["MP"],
90
84
  "x-category": "高级属性",
91
85
  "remarks": "开启flexbox布局"
92
86
  },
@@ -94,9 +88,7 @@
94
88
  "title": "开启 scroll anchoring 特性",
95
89
  "type": "boolean",
96
90
  "default": false,
97
- "x-platforms": [
98
- "MP"
99
- ],
91
+ "x-platforms": ["MP"],
100
92
  "x-category": "高级属性",
101
93
  "remarks": "开启scroll-anchoring特性"
102
94
  },
@@ -111,9 +103,7 @@
111
103
  "condition": "{{ $self.value }}"
112
104
  }
113
105
  ],
114
- "x-platforms": [
115
- "MP"
116
- ],
106
+ "x-platforms": ["MP"],
117
107
  "x-category": "高级属性",
118
108
  "remarks": "开启后可自定义对下拉刷新进行相关配置"
119
109
  },
@@ -121,9 +111,7 @@
121
111
  "title": "设置自定义下拉刷新阈值",
122
112
  "type": "number",
123
113
  "default": 50,
124
- "x-platforms": [
125
- "MP"
126
- ],
114
+ "x-platforms": ["MP"],
127
115
  "x-category": "高级属性"
128
116
  },
129
117
  "refresherDefaultStyle": {
@@ -145,27 +133,21 @@
145
133
  "value": "none"
146
134
  }
147
135
  ],
148
- "x-platforms": [
149
- "MP"
150
- ],
136
+ "x-platforms": ["MP"],
151
137
  "x-category": "高级属性"
152
138
  },
153
139
  "refresherBackground": {
154
140
  "title": "设置自定义下拉刷新区域背景颜色",
155
141
  "type": "color",
156
142
  "default": "#fff",
157
- "x-platforms": [
158
- "MP"
159
- ],
143
+ "x-platforms": ["MP"],
160
144
  "x-category": "高级属性"
161
145
  },
162
146
  "refresherTriggered": {
163
147
  "title": "设置当前下拉刷新状态",
164
148
  "type": "boolean",
165
149
  "default": false,
166
- "x-platforms": [
167
- "MP"
168
- ],
150
+ "x-platforms": ["MP"],
169
151
  "x-category": "高级属性"
170
152
  },
171
153
  "enhanced": {
@@ -179,9 +161,7 @@
179
161
  "condition": "{{ $self.value }}"
180
162
  }
181
163
  ],
182
- "x-platforms": [
183
- "MP"
184
- ],
164
+ "x-platforms": ["MP"],
185
165
  "x-category": "高级属性",
186
166
  "remarks": "开启scroll-view增强特性 "
187
167
  },
@@ -189,18 +169,14 @@
189
169
  "title": "iOS 下 scroll-view 边界弹性控制",
190
170
  "type": "boolean",
191
171
  "default": true,
192
- "x-platforms": [
193
- "MP"
194
- ],
172
+ "x-platforms": ["MP"],
195
173
  "x-category": "高级属性"
196
174
  },
197
175
  "showScrollbar": {
198
176
  "title": "滚动条显隐控制",
199
177
  "type": "boolean",
200
178
  "default": true,
201
- "x-platforms": [
202
- "MP"
203
- ],
179
+ "x-platforms": ["MP"],
204
180
  "x-category": "基础属性",
205
181
  "remarks": "控制滚动条是否显示/隐藏"
206
182
  },
@@ -208,18 +184,14 @@
208
184
  "title": "分页滑动效果",
209
185
  "type": "boolean",
210
186
  "default": false,
211
- "x-platforms": [
212
- "MP"
213
- ],
187
+ "x-platforms": ["MP"],
214
188
  "x-category": "高级属性"
215
189
  },
216
190
  "fastDeceleration": {
217
191
  "title": "滑动减速速率控制",
218
192
  "type": "boolean",
219
193
  "default": false,
220
- "x-platforms": [
221
- "MP"
222
- ],
194
+ "x-platforms": ["MP"],
223
195
  "x-category": "高级属性"
224
196
  }
225
197
  }
@@ -7,49 +7,49 @@
7
7
  "default": true,
8
8
  "type": "boolean",
9
9
  "x-category": "基础属性",
10
- "remarks":"开启后,轮播图将会自动根据配置的时间间隔进行自动滚动,关闭后则轮播图仅支持通过点击锚点的方式进行切换"
10
+ "remarks": "开启后,轮播图将会自动根据配置的时间间隔进行自动滚动,关闭后则轮播图仅支持通过点击锚点的方式进行切换"
11
11
  },
12
12
  "indicatorDots": {
13
13
  "title": "导航锚点",
14
14
  "default": true,
15
15
  "type": "boolean",
16
16
  "x-category": "高级属性",
17
- "remarks":"开启/关闭轮播图锚点"
17
+ "remarks": "开启/关闭轮播图锚点"
18
18
  },
19
19
  "current": {
20
20
  "title": "当前所在滑块的 index",
21
21
  "default": 0,
22
22
  "type": "number",
23
23
  "x-category": "高级属性",
24
- "remarks":"更改轮播图的默认展示位置,0为默认展示第一张轮播图,以此类推"
24
+ "remarks": "更改轮播图的默认展示位置,0为默认展示第一张轮播图,以此类推"
25
25
  },
26
26
  "interval": {
27
27
  "title": "自动切换时间间隔",
28
28
  "default": 5000,
29
29
  "type": "number",
30
30
  "x-category": "基础属性",
31
- "remarks":"配置轮播图滚动的时间间隔,时间单位为ms"
31
+ "remarks": "配置轮播图滚动的时间间隔,时间单位为ms"
32
32
  },
33
33
  "duration": {
34
34
  "title": "滑动动画时长",
35
35
  "default": 500,
36
36
  "type": "number",
37
37
  "x-category": "高级属性",
38
- "remarks":"更改轮播图切换时的滑动动画时长"
38
+ "remarks": "更改轮播图切换时的滑动动画时长"
39
39
  },
40
40
  "circular": {
41
41
  "title": "衔接滑动",
42
42
  "default": true,
43
43
  "type": "boolean",
44
44
  "x-category": "高级属性",
45
- "remarks":"更改轮播图切换时动画的滑动方式"
45
+ "remarks": "更改轮播图切换时动画的滑动方式"
46
46
  },
47
47
  "vertical": {
48
48
  "title": "纵向轮播",
49
49
  "default": false,
50
50
  "type": "boolean",
51
51
  "x-category": "基础属性",
52
- "remarks":"开启后,轮播的滚动方式将会由横向滚动变更为纵向滚动"
52
+ "remarks": "开启后,轮播的滚动方式将会由横向滚动变更为纵向滚动"
53
53
  },
54
54
  "indicatorColor": {
55
55
  "title": "锚点颜色",
@@ -57,7 +57,7 @@
57
57
  "x-component": "color",
58
58
  "default": "rgba(200, 200, 200, 0.9)",
59
59
  "x-category": "高级属性",
60
- "remarks":"更改锚点普通状态下的颜色"
60
+ "remarks": "更改锚点普通状态下的颜色"
61
61
  },
62
62
  "indicatorActiveColor": {
63
63
  "title": "锚点激活色",
@@ -65,7 +65,7 @@
65
65
  "x-component": "color",
66
66
  "default": "rgba(0, 0, 0, 0.9)",
67
67
  "x-category": "高级属性",
68
- "remarks":"更改锚点选中时的颜色"
68
+ "remarks": "更改锚点选中时的颜色"
69
69
  }
70
70
  }
71
71
  },
@@ -0,0 +1,86 @@
1
+ {
2
+ "$schema": "https://comp-public-1303824488.cos.ap-shanghai.myqcloud.com/schema/lcds_component.json",
3
+ "data": {
4
+ "properties": {
5
+ "videoDataSource": {
6
+ "title": "视频资源",
7
+ "default": "https://qcloudimg.tencent-cloud.cn/raw/472043e1e13e1cc06e4afc46407e8c4d.mp4",
8
+ "type": "string",
9
+ "x-category": "基础属性",
10
+ "x-index": 10,
11
+ "x-rules": [
12
+ {
13
+ "message": "请输入合法的视频资源",
14
+ "pattern": "^(((https?)://)|/resources/)[^\\s]+$"
15
+ }
16
+ ]
17
+ },
18
+ "posterImage": {
19
+ "title": "封面图片",
20
+ "default": "",
21
+ "type": "string",
22
+ "x-component": "image",
23
+ "x-category": "基础属性",
24
+ "x-index": 20,
25
+ "x-rules": [
26
+ {
27
+ "message": "请输入合法的图片地址",
28
+ "pattern": "^(((https?)://)|/resources/)[^\\s]+$"
29
+ }
30
+ ]
31
+ },
32
+ "autoPlay": {
33
+ "title": "自动播放",
34
+ "default": false,
35
+ "type": "boolean",
36
+ "x-category": "基础属性",
37
+ "x-index": 30
38
+ },
39
+ "loopPlay": {
40
+ "title": "循环播放",
41
+ "default": false,
42
+ "type": "boolean",
43
+ "x-category": "基础属性",
44
+ "x-index": 40
45
+ },
46
+ "mutePlay": {
47
+ "title": "静音播放",
48
+ "default": false,
49
+ "type": "boolean",
50
+ "x-category": "基础属性",
51
+ "x-index": 50
52
+ },
53
+ "controlBarStatus": {
54
+ "title": "播放控件",
55
+ "default": true,
56
+ "type": "boolean",
57
+ "x-category": "基础属性",
58
+ "x-index": 60
59
+ },
60
+ "startTime": {
61
+ "title": "初始播放时间(秒)",
62
+ "default": 0,
63
+ "type": "number",
64
+ "x-category": "高级属性",
65
+ "x-index": 70
66
+ },
67
+ "endTime": {
68
+ "title": "指定视频时长(秒)",
69
+ "default": 0,
70
+ "type": "number",
71
+ "x-category": "高级属性",
72
+ "x-index": 80
73
+ }
74
+ }
75
+ },
76
+ "meta": {
77
+ "name": "wedaVideo",
78
+ "title": "视频播放",
79
+ "description": "视频播放",
80
+ "icon": "https://qcloudimg.tencent-cloud.cn/raw/c622c16cc4841ef7e99cfe3c05c76f2f.svg",
81
+ "category": "展示",
82
+ "categoryOrder": 1,
83
+ "componentOrder": 1,
84
+ "visible": ["APP"]
85
+ }
86
+ }
@@ -8,9 +8,7 @@
8
8
  "remarks": "按钮组件的标题",
9
9
  "type": "string",
10
10
  "x-category": "基础属性",
11
- "x-platforms": [
12
- "MP"
13
- ],
11
+ "x-platforms": ["MP"],
14
12
  "x-index": 1
15
13
  },
16
14
  "type": {
@@ -37,9 +35,7 @@
37
35
  }
38
36
  ],
39
37
  "x-category": "基础属性",
40
- "x-platforms": [
41
- "MP"
42
- ],
38
+ "x-platforms": ["MP"],
43
39
  "x-index": 2
44
40
  },
45
41
  "size": {
@@ -62,9 +58,7 @@
62
58
  }
63
59
  ],
64
60
  "x-category": "基础属性",
65
- "x-platforms": [
66
- "MP"
67
- ],
61
+ "x-platforms": ["MP"],
68
62
  "x-index": 3
69
63
  }
70
64
  }
@@ -74,9 +68,7 @@
74
68
  "title": "手机号授权成功",
75
69
  "name": "phonesuccess",
76
70
  "remarks": "弹窗中点击了允许按钮后触发的事件",
77
- "x-platforms": [
78
- "MP"
79
- ],
71
+ "x-platforms": ["MP"],
80
72
  "detail": {
81
73
  "phoneNumber": {
82
74
  "type": "string",
@@ -104,9 +96,7 @@
104
96
  "title": "手机号授权失败",
105
97
  "remarks": "弹窗中点击了拒绝按钮后触发的事件",
106
98
  "name": "phonefail",
107
- "x-platforms": [
108
- "MP"
109
- ]
99
+ "x-platforms": ["MP"]
110
100
  }
111
101
  ],
112
102
  "meta": {
@@ -116,12 +106,8 @@
116
106
  "category": "微信开放能力",
117
107
  "categoryOrder": 100,
118
108
  "componentOrder": 2,
119
- "platform": [
120
- "MP"
121
- ],
122
- "visible": [
123
- "APP"
124
- ],
109
+ "platform": ["MP"],
110
+ "visible": ["APP"],
125
111
  "validate": [
126
112
  {
127
113
  "rule": "checkBusiness",
@@ -8,9 +8,7 @@
8
8
  "remarks": "按钮组件的标题",
9
9
  "type": "string",
10
10
  "x-category": "基础属性",
11
- "x-platforms": [
12
- "MP"
13
- ],
11
+ "x-platforms": ["MP"],
14
12
  "x-index": 1
15
13
  },
16
14
  "type": {
@@ -37,9 +35,7 @@
37
35
  }
38
36
  ],
39
37
  "x-category": "基础属性",
40
- "x-platforms": [
41
- "MP"
42
- ],
38
+ "x-platforms": ["MP"],
43
39
  "x-index": 2
44
40
  },
45
41
  "size": {
@@ -62,9 +58,7 @@
62
58
  }
63
59
  ],
64
60
  "x-category": "基础属性",
65
- "x-platforms": [
66
- "MP"
67
- ],
61
+ "x-platforms": ["MP"],
68
62
  "x-index": 3
69
63
  }
70
64
  }
@@ -74,9 +68,7 @@
74
68
  "title": "获取手机号授权令牌成功",
75
69
  "name": "phoneCodeSuccess",
76
70
  "remarks": "弹窗中点击了允许按钮后触发的事件",
77
- "x-platforms": [
78
- "MP"
79
- ],
71
+ "x-platforms": ["MP"],
80
72
  "detail": {
81
73
  "code": {
82
74
  "type": "string",
@@ -89,9 +81,7 @@
89
81
  "title": "获取手机号授权令牌失败",
90
82
  "remarks": "弹窗中点击了拒绝按钮后触发的事件",
91
83
  "name": "phoneCodeFail",
92
- "x-platforms": [
93
- "MP"
94
- ]
84
+ "x-platforms": ["MP"]
95
85
  }
96
86
  ],
97
87
  "meta": {
@@ -101,9 +91,7 @@
101
91
  "category": "微信开放能力",
102
92
  "categoryOrder": 100,
103
93
  "componentOrder": 2,
104
- "platform": [
105
- "MP"
106
- ],
94
+ "platform": ["MP"],
107
95
  "visible": [],
108
96
  "validate": [
109
97
  {
@@ -118,4 +106,4 @@
118
106
  }
119
107
  ]
120
108
  }
121
- }
109
+ }