@cloudbase/weda-ui 2.0.10 → 2.0.26
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/README.md +1 -0
- package/package.json +47 -36
- package/src/configs/components/button.json +60 -13
- package/src/configs/components/calendar.json +3 -3
- package/src/configs/components/carousel.json +57 -47
- package/src/configs/components/chart/bar.json +4 -13
- package/src/configs/components/chart/line.json +4 -13
- package/src/configs/components/chart/pie.json +3 -10
- package/src/configs/components/chart/statisticsCard.json +1 -4
- package/src/configs/components/container.json +1 -3
- package/src/configs/components/dataView.json +7 -15
- package/src/configs/components/drawer.json +24 -6
- package/src/configs/components/form/form.json +19 -0
- package/src/configs/components/form/input.json +20 -5
- package/src/configs/components/form/location.json +51 -48
- package/src/configs/components/form/radio.json +1 -3
- package/src/configs/components/form/richText.json +14 -14
- package/src/configs/components/form/select.json +62 -82
- package/src/configs/components/form/textarea.json +14 -1
- package/src/configs/components/form/uploader.json +64 -64
- package/src/configs/components/form/uploaderFile.json +1 -2
- package/src/configs/components/graphicCard.json +44 -45
- package/src/configs/components/image.json +44 -40
- package/src/configs/components/link.json +5 -10
- package/src/configs/components/listView.json +2 -8
- package/src/configs/components/lottery.json +7 -3
- package/src/configs/components/modal.json +26 -21
- package/src/configs/components/navLayout.json +68 -68
- package/src/configs/components/navigationBar.json +4 -1
- package/src/configs/components/richtextview.json +1 -1
- package/src/configs/components/scrollVeiw.json +14 -42
- package/src/configs/components/swiper.json +9 -9
- package/src/configs/components/wedaVideo.json +89 -0
- package/src/configs/components/wxOpenApi/phone.json +7 -21
- package/src/configs/components/wxOpenApi/phoneCode.json +7 -19
- package/src/configs/components/wxOpenApi/share.json +14 -24
- package/src/configs/components/wxOpenApi/userInfo.json +9 -27
- package/src/configs/index.js +2 -0
- package/src/mp/components/button/index.js +1 -1
- package/src/mp/components/button/index.wxml +19 -19
- package/src/mp/components/calendar/index.js +68 -38
- package/src/mp/components/calendar/index.json +3 -2
- package/src/mp/components/calendar/index.wxml +5 -7
- package/src/mp/components/calendar/index.wxss +17 -16
- package/src/mp/components/carousel/index.json +1 -1
- package/src/mp/components/carousel/index.wxml +2 -2
- package/src/mp/components/chart/bar/index.js +1 -2
- package/src/mp/components/chart/bar/index.wxml +1 -1
- package/src/mp/components/chart/common/config/bar.js +1 -1
- package/src/mp/components/chart/common/core/eChartBar.js +29 -34
- package/src/mp/components/chart/common/core/eChartBase.js +46 -32
- package/src/mp/components/chart/common/core/eChartLine.js +34 -40
- package/src/mp/components/chart/common/core/eChartPie.js +12 -9
- package/src/mp/components/chart/ec-canvas/ec-canvas.json +1 -1
- package/src/mp/components/chart/ec-canvas/wx-canvas.js +24 -22
- package/src/mp/components/chart/line/index.js +2 -2
- package/src/mp/components/chart/line/index.wxml +1 -1
- package/src/mp/components/chart/pie/index.js +1 -1
- package/src/mp/components/chart/pie/index.wxml +1 -2
- package/src/mp/components/chart/statisticsCard/index.wxss +7 -10
- package/src/mp/components/dataView/index.wxml +2 -14
- package/src/mp/components/form/checkbox/index.js +15 -7
- package/src/mp/components/form/checkbox/index.wxml +13 -25
- package/src/mp/components/form/form/index.wxml +3 -3
- package/src/mp/components/form/formcell/index.wxml +9 -9
- package/src/mp/components/form/formcell/index.wxss +6 -1
- package/src/mp/components/form/input/index.js +4 -4
- package/src/mp/components/form/input/index.wxml +24 -31
- package/src/mp/components/form/input/index.wxss +9 -3
- package/src/mp/components/form/location/components/mapChoose/index.json +1 -1
- package/src/mp/components/form/location/components/mapChoose/index.wxml +6 -6
- package/src/mp/components/form/location/index.js +7 -1
- package/src/mp/components/form/location/index.json +1 -1
- package/src/mp/components/form/location/index.wxml +6 -10
- package/src/mp/components/form/radio/index.js +14 -6
- package/src/mp/components/form/radio/index.wxml +12 -24
- package/src/mp/components/form/select/index.js +157 -98
- package/src/mp/components/form/select/index.wxml +11 -39
- package/src/mp/components/form/select/index.wxss +10 -1
- package/src/mp/components/form/select/region/index.js +18 -12
- package/src/mp/components/form/switch/index.wxml +11 -18
- package/src/mp/components/form/textarea/index.js +6 -0
- package/src/mp/components/form/textarea/index.wxml +2 -17
- package/src/mp/components/form/textarea/index.wxss +5 -0
- package/src/mp/components/form/tips/index.wxml +1 -3
- package/src/mp/components/form/uploader/index.js +1 -1
- package/src/mp/components/form/uploader/index.wxml +3 -20
- package/src/mp/components/form/uploader/weui-uploader.js +210 -200
- package/src/mp/components/form/uploader/weui-uploader.json +6 -6
- package/src/mp/components/form/uploader/weui-uploader.wxml +38 -38
- package/src/mp/components/form/uploaderFile/index.js +5 -4
- package/src/mp/components/form/uploaderFile/index.wxml +40 -41
- package/src/mp/components/graphicCard/index.js +35 -35
- package/src/mp/components/graphicCard/index.wxml +2 -6
- package/src/mp/components/graphicCard/index.wxss +6 -6
- package/src/mp/components/image/index.wxml +9 -20
- package/src/mp/components/image/index.wxss +3 -1
- package/src/mp/components/listView/index.wxml +5 -7
- package/src/mp/components/listView/index.wxss +2 -2
- package/src/mp/components/lottery/index.wxml +1 -3
- package/src/mp/components/lottery/index.wxss +31 -25
- package/src/mp/components/navLayout/index.js +9 -12
- package/src/mp/components/navLayout/index.wxml +2 -4
- package/src/mp/components/navLayout/index.wxss +10 -10
- package/src/mp/components/navigationBar/index.json +1 -2
- package/src/mp/components/navigationBar/index.wxml +43 -51
- package/src/mp/components/navigationBar/index.wxss +10 -10
- package/src/mp/components/richText/index.wxml +1 -1
- package/src/mp/components/richText/index.wxss +7 -5
- package/src/mp/components/swiper/index.wxml +1 -9
- package/src/mp/components/tabs/index.js +14 -10
- package/src/mp/components/tabs/index.json +1 -1
- package/src/mp/components/tabs/index.wxml +3 -21
- package/src/mp/components/tabs/index.wxss +1 -2
- package/src/mp/components/text/index.wxml +1 -6
- package/src/mp/components/text/index.wxss +1 -1
- package/src/mp/components/wedaVideo/index.js +86 -0
- package/src/mp/components/wedaVideo/index.json +4 -0
- package/src/mp/components/wedaVideo/index.wxml +4 -0
- package/src/mp/components/wedaVideo/index.wxss +20 -0
- package/src/mp/components/wxOpenApi/phone/index.js +1 -9
- package/src/mp/components/wxOpenApi/phone/index.wxml +3 -14
- package/src/mp/components/wxOpenApi/phoneCode/index.json +1 -1
- package/src/mp/components/wxOpenApi/phoneCode/index.wxml +3 -14
- package/src/mp/components/wxOpenApi/share/index.wxml +3 -14
- package/src/mp/components/wxOpenApi/userInfo/index.wxml +3 -13
- package/src/mp/index.json +1 -0
- package/src/mp/style/weda-ui.wxss +24 -9
- package/src/mp/utils/deepEqual.js +37 -37
- package/src/mp/utils/destr.js +41 -40
- package/src/mp/utils/dr_square_point.js +10 -6
- package/src/setupTests.js +13 -13
- package/src/web/actions/showModal/index.tsx +5 -4
- package/src/web/components/button/index.tsx +44 -40
- package/src/web/components/calendar/index.css +99 -65
- package/src/web/components/carousel/index.tsx +1 -1
- package/src/web/components/chart/common/config/bar.js +1 -1
- package/src/web/components/chart/common/core/eChartBar.js +28 -34
- package/src/web/components/chart/common/core/eChartBase.ts +55 -42
- package/src/web/components/chart/common/core/eChartLine.js +34 -40
- package/src/web/components/chart/common/core/eChartPie.js +12 -9
- package/src/web/components/chart/common/core/type.ts +23 -23
- package/src/web/components/chart/common/echart.css +12 -12
- package/src/web/components/chart/common/echarts.ts +3 -5
- package/src/web/components/chart/common/useChart.tsx +34 -16
- package/src/web/components/chart/statisticsCard/index.css +9 -8
- package/src/web/components/container/index.tsx +3 -4
- package/src/web/components/drawer/index.tsx +15 -4
- package/src/web/components/form/checkbox/index.tsx +32 -31
- package/src/web/components/form/enumSelect/NormalSelect.tsx +0 -2
- package/src/web/components/form/form/index.css +3 -6
- package/src/web/components/form/form/index.tsx +7 -6
- package/src/web/components/form/formcell/index.css +11 -18
- package/src/web/components/form/formcell/index.tsx +3 -7
- package/src/web/components/form/input/index.css +8 -4
- package/src/web/components/form/input/index.tsx +61 -53
- package/src/web/components/form/location/common/mapChoose.css +13 -11
- package/src/web/components/form/location/common/selectModal.jsx +2 -11
- package/src/web/components/form/location/common/useLocationInfo.js +4 -0
- package/src/web/components/form/location/components/LocationH5/index.css +19 -20
- package/src/web/components/form/location/components/LocationH5/location.h5.jsx +11 -1
- package/src/web/components/form/location/components/LocationPC/Header.jsx +0 -13
- package/src/web/components/form/location/components/LocationPC/location.PC.jsx +14 -5
- package/src/web/components/form/radio/index.tsx +32 -26
- package/src/web/components/form/renderDecorator.tsx +23 -26
- package/src/web/components/form/select/h5.tsx +155 -104
- package/src/web/components/form/select/index.css +9 -3
- package/src/web/components/form/select/index.tsx +76 -49
- package/src/web/components/form/select/region/index.ts +101 -80
- package/src/web/components/form/select/year.tsx +2 -0
- package/src/web/components/form/switch/index.tsx +40 -40
- package/src/web/components/form/textarea/index.css +4 -0
- package/src/web/components/form/textarea/index.tsx +39 -26
- package/src/web/components/form/types.d.ts +10 -10
- package/src/web/components/form/uploader/index.css +10 -0
- package/src/web/components/form/uploader/uploader.h5.tsx +29 -26
- package/src/web/components/form/uploader/uploader.pc.tsx +3 -6
- package/src/web/components/form/uploaderFile/index.css +24 -23
- package/src/web/components/form/uploaderFile/index.jsx +0 -5
- package/src/web/components/form/uploaderFile/uploadFile.h5.tsx +24 -15
- package/src/web/components/form/uploaderFile/uploadFile.pc.tsx +21 -13
- package/src/web/components/graphicCard/index.css +6 -6
- package/src/web/components/image/image.tsx +2 -2
- package/src/web/components/image/index.css +9 -7
- package/src/web/components/image/index.tsx +29 -12
- package/src/web/components/index.js +1 -0
- package/src/web/components/link/index.tsx +13 -13
- package/src/web/components/listView/index.css +8 -8
- package/src/web/components/lottery/index.css +43 -37
- package/src/web/components/lottery/index.tsx +3 -3
- package/src/web/components/modal/index.tsx +34 -34
- package/src/web/components/navLayout/index.css +25 -25
- package/src/web/components/navLayout/index.tsx +1 -1
- package/src/web/components/navigationBar/index.css +26 -26
- package/src/web/components/navigationBar/index.tsx +2 -2
- package/src/web/components/picker/datePicker.tsx +3 -3
- package/src/web/components/picker/picker.tsx +3 -3
- package/src/web/components/picker/timePicker.tsx +1 -1
- package/src/web/components/richText/index.jsx +41 -46
- package/src/web/components/richTextView/index.css +7 -3
- package/src/web/components/richTextView/index.tsx +4 -6
- package/src/web/components/scrollView/index.tsx +2 -2
- package/src/web/components/slot/index.tsx +3 -4
- package/src/web/components/swiper/index.css +1 -1
- package/src/web/components/swiper/index.tsx +33 -15
- package/src/web/components/tabs/index.css +2 -3
- package/src/web/components/tabs/index.tsx +6 -6
- package/src/web/components/tabs/tabs.h5.tsx +17 -12
- package/src/web/components/tabs/tabs.pc.tsx +45 -34
- package/src/web/components/text/index.css +1 -1
- package/src/web/components/text/index.tsx +13 -14
- package/src/web/components/wedaVideo/index.css +42 -0
- package/src/web/components/wedaVideo/index.tsx +208 -0
- package/src/web/utils/constant.ts +2 -1
- package/src/web/utils/isObjectEqual.js +2 -1
- package/src/web/utils/loading-fallback.tsx +2 -2
- package/src/web/utils/lodash.ts +1 -1
- package/src/web/utils/platform.js +13 -0
- package/src/web/utils/useSetState.ts +6 -2
- package/src/web/weda-ui.css +23 -8
- package/src/docs/common/format.tsx +0 -112
- package/src/docs/common/tableView.css +0 -164
- package/src/docs/common/tableView.tsx +0 -273
- package/src/docs/compsdocs/chart/Bar.mdx +0 -159
- package/src/docs/compsdocs/chart/Line.mdx +0 -100
- package/src/docs/compsdocs/chart/Pie.mdx +0 -83
- package/src/docs/compsdocs/chart/_category_.json +0 -1
- package/src/docs/compsdocs/chart/statisticsCard.mdx +0 -51
- package/src/docs/compsdocs/database/DataView.mdx +0 -33
- package/src/docs/compsdocs/database/ListView.mdx +0 -33
- package/src/docs/compsdocs/database/_category_.json +0 -1
- package/src/docs/compsdocs/form/Form.mdx +0 -35
- package/src/docs/compsdocs/form/FormCheckbox.mdx +0 -35
- package/src/docs/compsdocs/form/FormDate.mdx +0 -30
- package/src/docs/compsdocs/form/FormEmail.mdx +0 -30
- package/src/docs/compsdocs/form/FormImageUploader.mdx +0 -31
- package/src/docs/compsdocs/form/FormInput.mdx +0 -30
- package/src/docs/compsdocs/form/FormLocation.mdx +0 -64
- package/src/docs/compsdocs/form/FormPhone.mdx +0 -30
- package/src/docs/compsdocs/form/FormRadio.mdx +0 -35
- package/src/docs/compsdocs/form/FormRegion.mdx +0 -30
- package/src/docs/compsdocs/form/FormSelect.mdx +0 -36
- package/src/docs/compsdocs/form/FormSwitch.mdx +0 -30
- package/src/docs/compsdocs/form/FormTextarea.mdx +0 -30
- package/src/docs/compsdocs/form/FormTime.mdx +0 -30
- package/src/docs/compsdocs/form/FormUploadFile.mdx +0 -30
- package/src/docs/compsdocs/form/FormUrl.mdx +0 -30
- package/src/docs/compsdocs/form/_category_.json +0 -1
- package/src/docs/compsdocs/grid/Card.mdx +0 -32
- package/src/docs/compsdocs/grid/Container.mdx +0 -42
- package/src/docs/compsdocs/grid/Footer.mdx +0 -31
- package/src/docs/compsdocs/grid/GridLayout.mdx +0 -32
- package/src/docs/compsdocs/grid/Header.mdx +0 -31
- package/src/docs/compsdocs/grid/Layout.mdx +0 -25
- package/src/docs/compsdocs/grid/List.mdx +0 -31
- package/src/docs/compsdocs/grid/ScrollView.mdx +0 -37
- package/src/docs/compsdocs/grid/Swiper.mdx +0 -58
- package/src/docs/compsdocs/grid/_category_.json +0 -1
- package/src/docs/compsdocs/media/Icon.mdx +0 -31
- package/src/docs/compsdocs/media/Image.mdx +0 -55
- package/src/docs/compsdocs/media/_category_.json +0 -1
- package/src/docs/compsdocs/model/ModelCreate.mdx +0 -20
- package/src/docs/compsdocs/model/ModelDetail.mdx +0 -20
- package/src/docs/compsdocs/model/ModelTable.mdx +0 -24
- package/src/docs/compsdocs/model/ModelUpdate.mdx +0 -21
- package/src/docs/compsdocs/model/PageLayout.mdx +0 -21
- package/src/docs/compsdocs/model/_category_.json +0 -1
- package/src/docs/compsdocs/navmenu/Classification.mdx +0 -38
- package/src/docs/compsdocs/navmenu/NavBar.mdx +0 -43
- package/src/docs/compsdocs/navmenu/NavLayout.mdx +0 -30
- package/src/docs/compsdocs/navmenu/TabBar.mdx +0 -43
- package/src/docs/compsdocs/navmenu/TabBarItem.mdx +0 -29
- package/src/docs/compsdocs/navmenu/_category_.json +0 -1
- package/src/docs/compsdocs/senior/Lottery.mdx +0 -48
- package/src/docs/compsdocs/senior/Modal.mdx +0 -58
- package/src/docs/compsdocs/senior/SlotMachine.mdx +0 -52
- package/src/docs/compsdocs/senior/_category_.json +0 -1
- package/src/docs/compsdocs/show/Calendar.mdx +0 -29
- package/src/docs/compsdocs/show/Divider.mdx +0 -31
- package/src/docs/compsdocs/show/GraphicCard.mdx +0 -30
- package/src/docs/compsdocs/show/Item.mdx +0 -32
- package/src/docs/compsdocs/show/ItemList.mdx +0 -47
- package/src/docs/compsdocs/show/Media.mdx +0 -25
- package/src/docs/compsdocs/show/StatusTip.mdx +0 -25
- package/src/docs/compsdocs/show/Swiper.mdx +0 -33
- package/src/docs/compsdocs/show/Tabs.mdx +0 -38
- package/src/docs/compsdocs/show/_category_.json +0 -1
- package/src/docs/compsdocs/show/button.mdx +0 -25
- package/src/docs/compsdocs/text/Link.mdx +0 -43
- package/src/docs/compsdocs/text/RichTextView.mdx +0 -36
- package/src/docs/compsdocs/text/Text.mdx +0 -31
- package/src/docs/compsdocs/text/Title.mdx +0 -32
- package/src/docs/compsdocs/text/_category_.json +0 -1
- package/src/docs/compsdocs/wxOpen/Phone.mdx +0 -60
- package/src/docs/compsdocs/wxOpen/Share.mdx +0 -46
- package/src/docs/compsdocs/wxOpen/UserInfo.mdx +0 -60
- package/src/docs/compsdocs/wxOpen/_category_.json +0 -4
|
@@ -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
|
"title": {
|
|
@@ -75,19 +69,21 @@
|
|
|
75
69
|
"description": "",
|
|
76
70
|
"remarks": "分享(转发)卡片的标题",
|
|
77
71
|
"x-component": "textarea",
|
|
78
|
-
"x-platforms": [
|
|
79
|
-
"MP"
|
|
80
|
-
],
|
|
72
|
+
"x-platforms": ["MP"],
|
|
81
73
|
"x-index": 4
|
|
82
74
|
},
|
|
83
75
|
"image": {
|
|
84
76
|
"title": "{{text('分享图片', help('分享(转发)卡片的图片'))}}",
|
|
85
77
|
"type": "string",
|
|
86
78
|
"x-component": "image",
|
|
87
|
-
"
|
|
88
|
-
|
|
89
|
-
|
|
79
|
+
"x-rules": [
|
|
80
|
+
{
|
|
81
|
+
"message": "请输入合法的图片地址",
|
|
82
|
+
"pattern": "^(((https?)://)|/resources/)[^\\s]+$"
|
|
83
|
+
}
|
|
90
84
|
],
|
|
85
|
+
"default": "",
|
|
86
|
+
"x-platforms": ["MP"],
|
|
91
87
|
"description": "",
|
|
92
88
|
"remarks": "分享(转发)卡片的图片",
|
|
93
89
|
"x-category": "基础属性",
|
|
@@ -114,9 +110,7 @@
|
|
|
114
110
|
"description": "",
|
|
115
111
|
"x-component": "page-list",
|
|
116
112
|
"x-component-props": {
|
|
117
|
-
"hideAddPlatform": [
|
|
118
|
-
"MP"
|
|
119
|
-
]
|
|
113
|
+
"hideAddPlatform": ["MP"]
|
|
120
114
|
}
|
|
121
115
|
},
|
|
122
116
|
"withParams": {
|
|
@@ -154,12 +148,8 @@
|
|
|
154
148
|
"category": "微信开放能力",
|
|
155
149
|
"categoryOrder": 100,
|
|
156
150
|
"componentOrder": 3,
|
|
157
|
-
"platform": [
|
|
158
|
-
|
|
159
|
-
],
|
|
160
|
-
"visible": [
|
|
161
|
-
"APP"
|
|
162
|
-
]
|
|
151
|
+
"platform": ["MP"],
|
|
152
|
+
"visible": ["APP"]
|
|
163
153
|
},
|
|
164
154
|
"configMeta": {
|
|
165
155
|
"docsUrl": "https://docs.cloudbase.net/lowcode/components/wedaUI/src/docs/compsdocs/wxOpen/Share"
|
|
@@ -8,9 +8,7 @@
|
|
|
8
8
|
"type": "string",
|
|
9
9
|
"x-category": "基础属性",
|
|
10
10
|
"remarks": "按钮组件的标题",
|
|
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
|
"usage": {
|
|
@@ -86,9 +80,7 @@
|
|
|
86
80
|
],
|
|
87
81
|
"description": "声明获取用户个人信息的用途,不超过30个字符,若不填写将导致功能失效",
|
|
88
82
|
"x-component": "textarea",
|
|
89
|
-
"x-platforms": [
|
|
90
|
-
"MP"
|
|
91
|
-
],
|
|
83
|
+
"x-platforms": ["MP"],
|
|
92
84
|
"x-index": 4
|
|
93
85
|
},
|
|
94
86
|
"language": {
|
|
@@ -112,9 +104,7 @@
|
|
|
112
104
|
}
|
|
113
105
|
],
|
|
114
106
|
"x-category": "基础属性",
|
|
115
|
-
"x-platforms": [
|
|
116
|
-
"MP"
|
|
117
|
-
],
|
|
107
|
+
"x-platforms": ["MP"],
|
|
118
108
|
"x-index": 5
|
|
119
109
|
}
|
|
120
110
|
}
|
|
@@ -124,9 +114,7 @@
|
|
|
124
114
|
"title": "用户信息授权成功",
|
|
125
115
|
"name": "userinfosuccess",
|
|
126
116
|
"remarks": "弹窗中点击了允许按钮后触发的事件",
|
|
127
|
-
"x-platforms": [
|
|
128
|
-
"MP"
|
|
129
|
-
],
|
|
117
|
+
"x-platforms": ["MP"],
|
|
130
118
|
"detail": {
|
|
131
119
|
"avatarUrl": {
|
|
132
120
|
"type": "string",
|
|
@@ -149,9 +137,7 @@
|
|
|
149
137
|
"title": "用户信息授权失败",
|
|
150
138
|
"name": "userinfofail",
|
|
151
139
|
"remarks": "弹窗中点击了拒绝按钮后触发的事件",
|
|
152
|
-
"x-platforms": [
|
|
153
|
-
"MP"
|
|
154
|
-
]
|
|
140
|
+
"x-platforms": ["MP"]
|
|
155
141
|
}
|
|
156
142
|
],
|
|
157
143
|
"meta": {
|
|
@@ -161,12 +147,8 @@
|
|
|
161
147
|
"category": "微信开放能力",
|
|
162
148
|
"categoryOrder": 100,
|
|
163
149
|
"componentOrder": 1,
|
|
164
|
-
"platform": [
|
|
165
|
-
|
|
166
|
-
],
|
|
167
|
-
"visible": [
|
|
168
|
-
"APP"
|
|
169
|
-
]
|
|
150
|
+
"platform": ["MP"],
|
|
151
|
+
"visible": ["APP"]
|
|
170
152
|
},
|
|
171
153
|
"configMeta": {
|
|
172
154
|
"docsUrl": "https://docs.cloudbase.net/lowcode/components/wedaUI/src/docs/compsdocs/wxOpen/UserInfo"
|
package/src/configs/index.js
CHANGED
|
@@ -30,6 +30,7 @@ import RichTextView from './components/richtextview.json';
|
|
|
30
30
|
import Tabs from './components/tabs.json';
|
|
31
31
|
import Calendar from './components/calendar.json';
|
|
32
32
|
import NavLayout from './components/navLayout.json';
|
|
33
|
+
import WedaVideo from './components/wedaVideo.json';
|
|
33
34
|
|
|
34
35
|
import showToast from './actions/showToast.json';
|
|
35
36
|
import showModal from './actions/showModal.json';
|
|
@@ -64,6 +65,7 @@ export const components = {
|
|
|
64
65
|
Form,
|
|
65
66
|
Textarea,
|
|
66
67
|
Location,
|
|
68
|
+
WedaVideo,
|
|
67
69
|
// Cells,
|
|
68
70
|
Select,
|
|
69
71
|
Auth,
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
<button
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
2
|
+
class="{{cls}}"
|
|
3
|
+
style="{{style}}"
|
|
4
|
+
size="{{size}}"
|
|
5
|
+
loading="{{loading}}"
|
|
6
|
+
disabled="{{disabled}}"
|
|
7
|
+
open-type="{{openType}}"
|
|
8
|
+
form-type="{{formType}}"
|
|
9
|
+
bind:tap="tap"
|
|
10
|
+
bindcontact="contact"
|
|
11
|
+
bindlaunchapp="launchApp"
|
|
12
|
+
bindopensetting="openSetting"
|
|
13
|
+
session-from="{{sessionFrom}}"
|
|
14
|
+
send-message-title="{{sendMessageTitle}}"
|
|
15
|
+
send-message-path="{{sendMessagePath}}"
|
|
16
|
+
send-message-img="{{sendMessageImg}}"
|
|
17
|
+
show-message-card="{{showMessageCard}}"
|
|
18
|
+
app-parameter="{{appParameter}}"
|
|
19
19
|
>
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
<block>{{text ? text : ''}}</block>
|
|
21
|
+
<slot name="contentSlot" wx:if="{{!text}}" />
|
|
22
22
|
</button>
|
|
@@ -3,31 +3,34 @@ import dayjs from '../../utils/dayjs.min.js';
|
|
|
3
3
|
// import dayjs from 'dayjs'
|
|
4
4
|
Component({
|
|
5
5
|
externalClasses: ['ext-class'],
|
|
6
|
+
options: {
|
|
7
|
+
virtualHost: true,
|
|
8
|
+
},
|
|
6
9
|
/** 传入的props */
|
|
7
10
|
properties: {
|
|
8
11
|
className: {
|
|
9
12
|
type: String,
|
|
10
|
-
value: ''
|
|
13
|
+
value: '',
|
|
11
14
|
},
|
|
12
15
|
style: {
|
|
13
|
-
type:
|
|
14
|
-
value: {}
|
|
16
|
+
type: String,
|
|
17
|
+
value: {},
|
|
15
18
|
},
|
|
16
19
|
// 控制器显示隐藏
|
|
17
20
|
initVisible: {
|
|
18
21
|
type: String,
|
|
19
|
-
value: 'true'
|
|
22
|
+
value: 'true',
|
|
20
23
|
},
|
|
21
24
|
// 初始化日历值
|
|
22
25
|
initValue: {
|
|
23
26
|
type: String,
|
|
24
|
-
value: ''
|
|
27
|
+
value: '',
|
|
25
28
|
},
|
|
26
29
|
// 展示配置
|
|
27
30
|
configData: {
|
|
28
31
|
type: Array,
|
|
29
32
|
value: [],
|
|
30
|
-
}
|
|
33
|
+
},
|
|
31
34
|
},
|
|
32
35
|
/** 页面的初始数据 */
|
|
33
36
|
data: {
|
|
@@ -45,18 +48,17 @@ Component({
|
|
|
45
48
|
year: 0,
|
|
46
49
|
month: 0,
|
|
47
50
|
datalist: [],
|
|
48
|
-
headerlist: []
|
|
51
|
+
headerlist: [],
|
|
49
52
|
},
|
|
50
53
|
|
|
51
54
|
lifetimes: {
|
|
52
|
-
created: function () {
|
|
53
|
-
},
|
|
55
|
+
created: function () {},
|
|
54
56
|
attached: function () {
|
|
55
|
-
const {initVisible, initValue} = this.properties;
|
|
56
|
-
const {firstDayOfWeek, initFormat} = this.data;
|
|
57
|
+
const { initVisible, initValue } = this.properties;
|
|
58
|
+
const { firstDayOfWeek, initFormat } = this.data;
|
|
57
59
|
if (initVisible !== null) {
|
|
58
60
|
this.setData({
|
|
59
|
-
visible: initVisible
|
|
61
|
+
visible: initVisible,
|
|
60
62
|
});
|
|
61
63
|
}
|
|
62
64
|
if (initValue !== null && initValue !== '') {
|
|
@@ -67,8 +69,14 @@ Component({
|
|
|
67
69
|
value,
|
|
68
70
|
year,
|
|
69
71
|
month,
|
|
70
|
-
datalist: this.getDateLis(
|
|
71
|
-
|
|
72
|
+
datalist: this.getDateLis(
|
|
73
|
+
year,
|
|
74
|
+
month,
|
|
75
|
+
firstDayOfWeek,
|
|
76
|
+
value,
|
|
77
|
+
initFormat
|
|
78
|
+
),
|
|
79
|
+
headerlist: this.colHeaderList(),
|
|
72
80
|
});
|
|
73
81
|
} else {
|
|
74
82
|
const _dayjsDate = dayjs(dayjs().format('YYYY-MM-DD'));
|
|
@@ -79,16 +87,28 @@ Component({
|
|
|
79
87
|
value,
|
|
80
88
|
year,
|
|
81
89
|
month,
|
|
82
|
-
datalist: this.getDateLis(
|
|
83
|
-
|
|
90
|
+
datalist: this.getDateLis(
|
|
91
|
+
year,
|
|
92
|
+
month,
|
|
93
|
+
firstDayOfWeek,
|
|
94
|
+
value,
|
|
95
|
+
initFormat
|
|
96
|
+
),
|
|
97
|
+
headerlist: this.colHeaderList(),
|
|
84
98
|
});
|
|
85
99
|
}
|
|
86
|
-
}
|
|
100
|
+
},
|
|
87
101
|
},
|
|
88
102
|
methods: {
|
|
89
103
|
// 传入参数,修改展示列表
|
|
90
104
|
getDateLis: function (year, month, firstDayOfWeek, value, initFormat) {
|
|
91
|
-
const datalist = this.createDateList(
|
|
105
|
+
const datalist = this.createDateList(
|
|
106
|
+
year,
|
|
107
|
+
month,
|
|
108
|
+
firstDayOfWeek,
|
|
109
|
+
value,
|
|
110
|
+
initFormat
|
|
111
|
+
);
|
|
92
112
|
return this._dataList(datalist);
|
|
93
113
|
},
|
|
94
114
|
// 获取一个日期是周几(1~7)
|
|
@@ -100,13 +120,7 @@ Component({
|
|
|
100
120
|
return day;
|
|
101
121
|
},
|
|
102
122
|
// 获取日期数组
|
|
103
|
-
createDateList: function (
|
|
104
|
-
year,
|
|
105
|
-
month,
|
|
106
|
-
firstDayOfWeek,
|
|
107
|
-
value,
|
|
108
|
-
initFormat
|
|
109
|
-
) {
|
|
123
|
+
createDateList: function (year, month, firstDayOfWeek, value, initFormat) {
|
|
110
124
|
const createCellData = (belongTo, isCurrent, date, weekOrder) => {
|
|
111
125
|
const day = this.getDay(date);
|
|
112
126
|
return {
|
|
@@ -132,7 +146,8 @@ Component({
|
|
|
132
146
|
|
|
133
147
|
// 添加上个月中会在本月显示的最后几天日期
|
|
134
148
|
// getDay(monthFirstDay.toDate()) 获取每月第一天是周几
|
|
135
|
-
const lastMonthDaysCount =
|
|
149
|
+
const lastMonthDaysCount =
|
|
150
|
+
(this.getDay(monthFirstDay.toDate()) - firstDayOfWeek + 7) % 7;
|
|
136
151
|
for (let i = 0; i < lastMonthDaysCount; i++) {
|
|
137
152
|
// 获取显示在当前月的日历中,上月日期数据
|
|
138
153
|
// monthFirstDay.subtract(num, 'day' | 'month' | 'year') 表示以当月第一天日期为基准,在 日|月|年 数字上减去num
|
|
@@ -144,7 +159,9 @@ Component({
|
|
|
144
159
|
const monthDaysCount = monthFirstDay.endOf('month').daysInMonth();
|
|
145
160
|
for (let i = 0; i < monthDaysCount; i++) {
|
|
146
161
|
const dayObj = monthFirstDay.add(i, 'day');
|
|
147
|
-
list.push(
|
|
162
|
+
list.push(
|
|
163
|
+
createCellData(0, value.isSame(dayObj), dayObj.toDate(), weekCount)
|
|
164
|
+
);
|
|
148
165
|
if (list.length === 7) {
|
|
149
166
|
rowList.push(list);
|
|
150
167
|
list = [];
|
|
@@ -168,17 +185,18 @@ Component({
|
|
|
168
185
|
},
|
|
169
186
|
// 混合数据
|
|
170
187
|
_dataList: function (configList) {
|
|
171
|
-
const {configData} = this.properties;
|
|
188
|
+
const { configData } = this.properties;
|
|
172
189
|
const _map = new Map();
|
|
173
190
|
for (const item of configData) {
|
|
174
191
|
_map.set(item.matchDate, item);
|
|
175
192
|
}
|
|
176
|
-
return configList.map(item => {
|
|
193
|
+
return configList.map((item) => {
|
|
177
194
|
return item.reduce((res, i) => {
|
|
178
195
|
if (_map.has(i.formattedDate)) {
|
|
179
196
|
const _disabled = _map.get(i.formattedDate)['disabled'];
|
|
180
197
|
const _marked = _map.get(i.formattedDate)['marked'];
|
|
181
|
-
i['disabled'] =
|
|
198
|
+
i['disabled'] =
|
|
199
|
+
_disabled !== undefined ? JSON.parse(_disabled) : false;
|
|
182
200
|
i['marked'] = _marked;
|
|
183
201
|
}
|
|
184
202
|
res.push(i);
|
|
@@ -188,7 +206,7 @@ Component({
|
|
|
188
206
|
},
|
|
189
207
|
// 表头数组
|
|
190
208
|
colHeaderList: function () {
|
|
191
|
-
const {week, firstDayOfWeek, isShowWeekend} = this.data;
|
|
209
|
+
const { week, firstDayOfWeek, isShowWeekend } = this.data;
|
|
192
210
|
const list = [];
|
|
193
211
|
for (let i = firstDayOfWeek; i <= 7; i++) {
|
|
194
212
|
if (!isShowWeekend && i > 5) {
|
|
@@ -214,25 +232,37 @@ Component({
|
|
|
214
232
|
},
|
|
215
233
|
// 上一个月
|
|
216
234
|
handlePrevMonth: function () {
|
|
217
|
-
const {year, month, firstDayOfWeek, value, initFormat} = this.data;
|
|
235
|
+
const { year, month, firstDayOfWeek, value, initFormat } = this.data;
|
|
218
236
|
const _month = month == 1 ? 12 : month - 1;
|
|
219
237
|
const _year = month === 1 ? year - 1 : year;
|
|
220
238
|
this.setData({
|
|
221
239
|
year: _year,
|
|
222
240
|
month: _month,
|
|
223
|
-
datalist: this.getDateLis(
|
|
241
|
+
datalist: this.getDateLis(
|
|
242
|
+
_year,
|
|
243
|
+
_month,
|
|
244
|
+
firstDayOfWeek,
|
|
245
|
+
value,
|
|
246
|
+
initFormat
|
|
247
|
+
),
|
|
224
248
|
});
|
|
225
249
|
},
|
|
226
250
|
// 下一个月
|
|
227
251
|
handleNextMonth: function () {
|
|
228
|
-
const {year, month, firstDayOfWeek, value, initFormat} = this.data;
|
|
252
|
+
const { year, month, firstDayOfWeek, value, initFormat } = this.data;
|
|
229
253
|
const _month = month == 12 ? 1 : month + 1;
|
|
230
254
|
const _year = month === 12 ? year + 1 : year;
|
|
231
255
|
this.setData({
|
|
232
256
|
year: _year,
|
|
233
257
|
month: _month,
|
|
234
|
-
datalist: this.getDateLis(
|
|
235
|
-
|
|
236
|
-
|
|
258
|
+
datalist: this.getDateLis(
|
|
259
|
+
_year,
|
|
260
|
+
_month,
|
|
261
|
+
firstDayOfWeek,
|
|
262
|
+
value,
|
|
263
|
+
initFormat
|
|
264
|
+
),
|
|
265
|
+
});
|
|
266
|
+
},
|
|
237
267
|
},
|
|
238
|
-
});
|
|
268
|
+
});
|
|
@@ -1,20 +1,18 @@
|
|
|
1
|
-
<view class="{{className}} weda-calendar
|
|
1
|
+
<view class="{{className}} weda-calendar" style="{{style}}">
|
|
2
2
|
<view class="weda-calendar__control">
|
|
3
3
|
<view class="weda-calendar__prevMonth" wx:if="{{visible}}" bindtap="handlePrevMonth">
|
|
4
|
-
<image class="weda-calendar__prevMonth-icon" src=
|
|
4
|
+
<image class="weda-calendar__prevMonth-icon" src="arrowright--line.svg" />
|
|
5
5
|
</view>
|
|
6
6
|
<view class="weda-calendar__current-date">{{year}}年{{month}}月</view>
|
|
7
7
|
<view class="weda-calendar__nextMonth" wx:if="{{visible}}" bindtap="handleNextMonth">
|
|
8
|
-
<image class="weda-calendar__nextMonth-icon" src=
|
|
8
|
+
<image class="weda-calendar__nextMonth-icon" src="arrowright--line.svg" />
|
|
9
9
|
</view>
|
|
10
10
|
</view>
|
|
11
11
|
<view class="weda-calendar__panel">
|
|
12
12
|
<view class="weda-calendar__table">
|
|
13
13
|
<view class="weda-calendar__table-head">
|
|
14
14
|
<view class="weda-calendar__table-head-row">
|
|
15
|
-
<view class="weda-calendar__table-head-cell" wx:for="{{headerlist}}" wx:for-index="index" wx:for-item="item" wx:key="index">
|
|
16
|
-
{{item.text}}
|
|
17
|
-
</view>
|
|
15
|
+
<view class="weda-calendar__table-head-cell" wx:for="{{headerlist}}" wx:for-index="index" wx:for-item="item" wx:key="index"> {{item.text}} </view>
|
|
18
16
|
</view>
|
|
19
17
|
</view>
|
|
20
18
|
<view class="weda-calendar__table-body">
|
|
@@ -34,4 +32,4 @@
|
|
|
34
32
|
</view>
|
|
35
33
|
</view>
|
|
36
34
|
</view>
|
|
37
|
-
</view>
|
|
35
|
+
</view>
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
background: rgb(255, 255, 255);
|
|
6
6
|
width: 100%;
|
|
7
7
|
opacity: 0.9;
|
|
8
|
+
font-size: 28rpx;
|
|
8
9
|
}
|
|
9
10
|
|
|
10
11
|
.weda-calendar .weda-calendar__control {
|
|
@@ -17,15 +18,15 @@
|
|
|
17
18
|
|
|
18
19
|
.weda-calendar .weda-calendar__current-date {
|
|
19
20
|
font-weight: bold;
|
|
20
|
-
font-size:
|
|
21
|
-
line-height:
|
|
21
|
+
font-size: inherit;
|
|
22
|
+
line-height: 1.57142em;
|
|
22
23
|
}
|
|
23
24
|
|
|
24
25
|
.weda-calendar .weda-calendar__prevMonth,
|
|
25
26
|
.weda-calendar .weda-calendar__nextMonth {
|
|
26
27
|
position: absolute;
|
|
27
|
-
width:
|
|
28
|
-
height:
|
|
28
|
+
width: 1.14285em;
|
|
29
|
+
height: 1.14285em;
|
|
29
30
|
vertical-align: middle;
|
|
30
31
|
top: 34rpx;
|
|
31
32
|
display: flex;
|
|
@@ -49,7 +50,7 @@
|
|
|
49
50
|
}
|
|
50
51
|
|
|
51
52
|
.weda-calendar .weda-calendar__panel {
|
|
52
|
-
height:
|
|
53
|
+
height: 21.85714em;
|
|
53
54
|
padding: 40rpx 32rpx 32rpx 32rpx;
|
|
54
55
|
width: 100%;
|
|
55
56
|
box-sizing: border-box;
|
|
@@ -62,6 +63,7 @@
|
|
|
62
63
|
flex-direction: column;
|
|
63
64
|
justify-self: start;
|
|
64
65
|
align-items: flex-start;
|
|
66
|
+
font-size: inherit;
|
|
65
67
|
}
|
|
66
68
|
|
|
67
69
|
.weda-calendar .weda-calendar__table-head {
|
|
@@ -84,8 +86,8 @@
|
|
|
84
86
|
width: 100%;
|
|
85
87
|
height: 100%;
|
|
86
88
|
justify-content: center;
|
|
87
|
-
font-size:
|
|
88
|
-
line-height:
|
|
89
|
+
font-size: 1em;
|
|
90
|
+
line-height: 1.42857em;
|
|
89
91
|
box-sizing: border-box;
|
|
90
92
|
}
|
|
91
93
|
|
|
@@ -109,8 +111,8 @@
|
|
|
109
111
|
position: relative;
|
|
110
112
|
width: 100%;
|
|
111
113
|
height: 100%;
|
|
112
|
-
font-size:
|
|
113
|
-
line-height:
|
|
114
|
+
font-size: 1em;
|
|
115
|
+
line-height: 1.42857em;
|
|
114
116
|
box-sizing: border-box;
|
|
115
117
|
justify-content: center;
|
|
116
118
|
display: flex;
|
|
@@ -119,13 +121,12 @@
|
|
|
119
121
|
}
|
|
120
122
|
|
|
121
123
|
.weda-calendar .weda-calendar__table-body-cell-value {
|
|
122
|
-
font-size:
|
|
124
|
+
font-size: 1em;
|
|
123
125
|
text-align: center;
|
|
124
126
|
border-radius: 50%;
|
|
125
127
|
width: 80rpx;
|
|
126
|
-
line-height:
|
|
128
|
+
line-height: 2.85714em;
|
|
127
129
|
box-sizing: border-box;
|
|
128
|
-
font-weight: 400;
|
|
129
130
|
color: rgba(0, 0, 0, 0.9);
|
|
130
131
|
position: relative;
|
|
131
132
|
}
|
|
@@ -157,12 +158,12 @@
|
|
|
157
158
|
.weda-calendar__table-body-cell.is-now
|
|
158
159
|
.weda-calendar__table-body-cell-bg {
|
|
159
160
|
position: absolute;
|
|
160
|
-
width:
|
|
161
|
-
height:
|
|
161
|
+
width: 1.714285em;
|
|
162
|
+
height: 1.714285em;
|
|
162
163
|
background: #0052d9;
|
|
163
164
|
border-radius: 100%;
|
|
164
|
-
left: calc(50% -
|
|
165
|
-
top: calc(50% -
|
|
165
|
+
left: calc(50% - 0.85714em);
|
|
166
|
+
top: calc(50% - 0.85714em);
|
|
166
167
|
z-index: -1;
|
|
167
168
|
}
|
|
168
169
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<!--components/carousel/index.wxml-->
|
|
2
2
|
<swiper id="{{id}}" class="weda-ui {{className}}" style="{{style}}" indicator-dots="{{indicatorDots}}" autoplay="{{autoplay}}" current="{{current}}" interval="{{interval}}" duration="{{duration}}" circular="{{circular}}" vertical="{{vertical}}" indicator-color="{{indicatorColor}}" indicator-active-color="{{indicatorActiveColor}}" bindchange="changeCurrent">
|
|
3
|
-
<swiper-item class="carousle-swiper-item" bindtap="tapImg" wx:for="{{images}}" wx:key="index" data-tapMode="{{item.tapMode}}" data-insideUrl="{{item.insideUrl}}" data-params="{{item.params}}"
|
|
4
|
-
<
|
|
3
|
+
<swiper-item class="carousle-swiper-item" bindtap="tapImg" wx:for="{{images}}" wx:key="index" data-tapMode="{{item.tapMode}}" data-insideUrl="{{item.insideUrl}}" data-params="{{item.params}}">
|
|
4
|
+
<img class="carousle-image" src="{{item.image}}" fit="{{item.fit}}" style="{{'height:'+item.height+';'+'width:'+item.width}}" />
|
|
5
5
|
</swiper-item>
|
|
6
6
|
</swiper>
|
|
@@ -195,7 +195,6 @@ Component({
|
|
|
195
195
|
type: String,
|
|
196
196
|
value: '',
|
|
197
197
|
},
|
|
198
|
-
|
|
199
198
|
},
|
|
200
199
|
data: {
|
|
201
200
|
ec: {},
|
|
@@ -223,7 +222,7 @@ Component({
|
|
|
223
222
|
},
|
|
224
223
|
observers: {
|
|
225
224
|
// 当参数变化时
|
|
226
|
-
'**': async function() {
|
|
225
|
+
'**': async function () {
|
|
227
226
|
const objEChartBar = new EchartBar();
|
|
228
227
|
await objEChartBar.setOptions(this.properties);
|
|
229
228
|
const options = await objEChartBar.getOptions();
|