m8-mcp-server 1.0.4 → 1.0.5
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 +184 -14
- package/dist/generator/vue-template.d.ts +21 -0
- package/dist/generator/vue-template.d.ts.map +1 -1
- package/dist/generator/vue-template.js +497 -33
- package/dist/generator/vue-template.js.map +1 -1
- package/package.json +2 -1
- package/resources/components/actionsheet.json +199 -0
- package/resources/components/amap.json +66 -0
- package/resources/components/area.json +158 -0
- package/resources/components/badge.json +93 -0
- package/resources/components/button.json +260 -74
- package/resources/components/calendar.json +225 -0
- package/resources/components/cascader.json +115 -0
- package/resources/components/cell.json +85 -69
- package/resources/components/chart.json +55 -0
- package/resources/components/checkbox.json +158 -0
- package/resources/components/circle.json +138 -0
- package/resources/components/collapse.json +88 -0
- package/resources/components/countdown.json +105 -0
- package/resources/components/datepicker.json +216 -0
- package/resources/components/dialog.json +250 -0
- package/resources/components/divider.json +82 -0
- package/resources/components/dragsort.json +67 -0
- package/resources/components/dropdownmenu.json +129 -0
- package/resources/components/easycalendar.json +84 -0
- package/resources/components/empty.json +90 -0
- package/resources/components/field.json +423 -88
- package/resources/components/form.json +156 -0
- package/resources/components/grid.json +131 -0
- package/resources/components/header.json +147 -0
- package/resources/components/icon.json +104 -0
- package/resources/components/image.json +169 -0
- package/resources/components/imagepreview.json +150 -0
- package/resources/components/imagescale.json +245 -0
- package/resources/components/indexbar.json +83 -0
- package/resources/components/layout.json +74 -0
- package/resources/components/lazyload.json +46 -0
- package/resources/components/loading.json +103 -0
- package/resources/components/minirefresh.json +341 -0
- package/resources/components/noticebar.json +148 -0
- package/resources/components/notify.json +60 -0
- package/resources/components/numberkeyboard.json +216 -0
- package/resources/components/overlay.json +78 -0
- package/resources/components/pagination.json +137 -0
- package/resources/components/panel.json +87 -0
- package/resources/components/passwordinput.json +103 -0
- package/resources/components/picker.json +195 -0
- package/resources/components/popover.json +161 -0
- package/resources/components/popup.json +229 -0
- package/resources/components/progress.json +111 -0
- package/resources/components/qrcode.json +128 -0
- package/resources/components/radio.json +139 -0
- package/resources/components/rate.json +157 -0
- package/resources/components/rtc.json +35 -0
- package/resources/components/search.json +234 -0
- package/resources/components/selectperson.json +175 -0
- package/resources/components/sidebar.json +74 -0
- package/resources/components/skeleton.json +110 -0
- package/resources/components/slider.json +159 -0
- package/resources/components/stepper.json +241 -0
- package/resources/components/steps.json +108 -0
- package/resources/components/sticky.json +72 -0
- package/resources/components/swipe.json +146 -0
- package/resources/components/swipecell.json +118 -0
- package/resources/components/switch.json +123 -0
- package/resources/components/switchcell.json +123 -0
- package/resources/components/tab.json +257 -0
- package/resources/components/tabbar.json +137 -0
- package/resources/components/table.json +149 -0
- package/resources/components/tag.json +149 -0
- package/resources/components/toast.json +70 -0
- package/resources/components/treeselect.json +106 -0
- package/resources/components/uploader.json +283 -0
- package/resources/components/verifycode.json +94 -0
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "cascader",
|
|
3
|
+
"name": "em-cascader",
|
|
4
|
+
"title": "级联选择",
|
|
5
|
+
"description": "级联选择框,用于多层级数据的选择,典型场景为省市区选择, M8 框架`8.2.10`版本以上支持。",
|
|
6
|
+
"props": [
|
|
7
|
+
{
|
|
8
|
+
"name": "v-model",
|
|
9
|
+
"type": "boolean",
|
|
10
|
+
"default": "false",
|
|
11
|
+
"required": false,
|
|
12
|
+
"description": "级联选择组件的显隐"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"name": "title",
|
|
16
|
+
"type": "string",
|
|
17
|
+
"default": "-",
|
|
18
|
+
"required": false,
|
|
19
|
+
"description": "顶部标题"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"name": "selected-value",
|
|
23
|
+
"type": "string / number",
|
|
24
|
+
"default": "-",
|
|
25
|
+
"required": false,
|
|
26
|
+
"description": "选中项的值"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"name": "options",
|
|
30
|
+
"type": "Option[]",
|
|
31
|
+
"default": "[]",
|
|
32
|
+
"required": false,
|
|
33
|
+
"description": "可选项数据源"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"name": "placeholder",
|
|
37
|
+
"type": "string",
|
|
38
|
+
"default": "请选择",
|
|
39
|
+
"required": false,
|
|
40
|
+
"description": "未选中时的提示文案"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"name": "active-color",
|
|
44
|
+
"type": "string",
|
|
45
|
+
"default": "#2e6be5",
|
|
46
|
+
"required": false,
|
|
47
|
+
"description": "选中状态的高亮颜色"
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"name": "closeable",
|
|
51
|
+
"type": "boolean",
|
|
52
|
+
"default": "true",
|
|
53
|
+
"required": false,
|
|
54
|
+
"description": "是否显示关闭图标"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"name": "field-names",
|
|
58
|
+
"type": "object",
|
|
59
|
+
"default": "{ text: 'text', value: 'value', children: 'children' }",
|
|
60
|
+
"required": false,
|
|
61
|
+
"description": "自定义 `options` 结构中的字段"
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"events": [
|
|
65
|
+
{
|
|
66
|
+
"name": "close",
|
|
67
|
+
"parameters": "关闭弹出层时触发",
|
|
68
|
+
"description": "`value`: 当前弹出层是否展开"
|
|
69
|
+
}
|
|
70
|
+
],
|
|
71
|
+
"slots": [
|
|
72
|
+
{
|
|
73
|
+
"name": "title",
|
|
74
|
+
"description": "自定义顶部标题"
|
|
75
|
+
}
|
|
76
|
+
],
|
|
77
|
+
"examples": {
|
|
78
|
+
"vue2": [
|
|
79
|
+
{
|
|
80
|
+
"title": "基础用法",
|
|
81
|
+
"code": "<em-field v-model=\"fieldValue\" is-link readonly label=\"地区\" placeholder=\"请选择所在地区\" @click=\"show = true\" />\n<em-cascader\n v-model=\"show\"\n title=\"请选择所在地区\"\n :selected-value=\"cascaderValue\"\n :options=\"options\"\n @close=\"show = false\"\n @finish=\"onFinish\"\n/>"
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"title": "自定义颜色",
|
|
85
|
+
"code": "<em-cascader\n v-model=\"show\"\n title=\"请选择所在地区\"\n active-color=\"#1989fa\"\n :options=\"options\"\n @close=\"show = false\"\n @finish=\"onFinish\"\n/>"
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
"title": "异步加载选项",
|
|
89
|
+
"code": "<em-field v-model=\"fieldValue\" is-link readonly label=\"地区\" placeholder=\"请选择所在地区\" @click=\"show = true\" />\n<em-cascader\n v-model=\"show\"\n :selected-value=\"cascaderValue\"\n title=\"请选择所在地区\"\n :options=\"options\"\n @close=\"show = false\"\n @finish=\"onFinish\"\n @change=\"onChange\"\n/>"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"title": "自定义字段名",
|
|
93
|
+
"code": "<em-cascader\n v-model=\"show\"\n title=\"请选择所在地区\"\n :options=\"options\"\n :field-names=\"fieldNames\"\n @close=\"show = false\"\n @finish=\"onFinish\"\n/>"
|
|
94
|
+
}
|
|
95
|
+
],
|
|
96
|
+
"vue3": [
|
|
97
|
+
{
|
|
98
|
+
"title": "基础用法",
|
|
99
|
+
"code": "<em-field v-model=\"fieldValue\" is-link readonly label=\"地区\" placeholder=\"请选择所在地区\" @click=\"show = true\" />\n<em-cascader\n v-model=\"show\"\n title=\"请选择所在地区\"\n :selected-value=\"cascaderValue\"\n :options=\"options\"\n @close=\"show = false\"\n @finish=\"onFinish\"\n/>"
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"title": "自定义颜色",
|
|
103
|
+
"code": "<em-cascader\n v-model=\"show\"\n title=\"请选择所在地区\"\n active-color=\"#1989fa\"\n :options=\"options\"\n @close=\"show = false\"\n @finish=\"onFinish\"\n/>"
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
"title": "异步加载选项",
|
|
107
|
+
"code": "<em-field v-model=\"fieldValue\" is-link readonly label=\"地区\" placeholder=\"请选择所在地区\" @click=\"show = true\" />\n<em-cascader\n v-model=\"show\"\n :selected-value=\"cascaderValue\"\n title=\"请选择所在地区\"\n :options=\"options\"\n @close=\"show = false\"\n @finish=\"onFinish\"\n @change=\"onChange\"\n/>"
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
"title": "自定义字段名",
|
|
111
|
+
"code": "<em-cascader\n v-model=\"show\"\n title=\"请选择所在地区\"\n :options=\"options\"\n :field-names=\"fieldNames\"\n @close=\"show = false\"\n @finish=\"onFinish\"\n/>"
|
|
112
|
+
}
|
|
113
|
+
]
|
|
114
|
+
}
|
|
115
|
+
}
|
|
@@ -1,69 +1,85 @@
|
|
|
1
|
-
{
|
|
2
|
-
"id": "cell",
|
|
3
|
-
"name": "em-cell",
|
|
4
|
-
"title": "单元格",
|
|
5
|
-
"description": "
|
|
6
|
-
"props": [
|
|
7
|
-
{
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
{
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
{
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
{
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
"
|
|
43
|
-
"
|
|
44
|
-
},
|
|
45
|
-
{
|
|
46
|
-
"title": "
|
|
47
|
-
"code": "<em-cell title=\"单元格\"
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
"
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
{
|
|
58
|
-
"title": "
|
|
59
|
-
"code": "<em-cell-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
"
|
|
65
|
-
"
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
1
|
+
{
|
|
2
|
+
"id": "cell",
|
|
3
|
+
"name": "em-cell",
|
|
4
|
+
"title": "单元格",
|
|
5
|
+
"description": "单元格组件。",
|
|
6
|
+
"props": [
|
|
7
|
+
{
|
|
8
|
+
"name": "title",
|
|
9
|
+
"type": "string",
|
|
10
|
+
"default": "-",
|
|
11
|
+
"required": false,
|
|
12
|
+
"description": "分组标题"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"name": "border",
|
|
16
|
+
"type": "boolean",
|
|
17
|
+
"default": "true",
|
|
18
|
+
"required": false,
|
|
19
|
+
"description": "是否显示外边框"
|
|
20
|
+
}
|
|
21
|
+
],
|
|
22
|
+
"events": [
|
|
23
|
+
{
|
|
24
|
+
"name": "click",
|
|
25
|
+
"parameters": "点击单元格时触发",
|
|
26
|
+
"description": "event: Event"
|
|
27
|
+
}
|
|
28
|
+
],
|
|
29
|
+
"slots": [
|
|
30
|
+
{
|
|
31
|
+
"name": "default",
|
|
32
|
+
"description": "默认插槽"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"name": "title",
|
|
36
|
+
"description": "自定义分组标题"
|
|
37
|
+
}
|
|
38
|
+
],
|
|
39
|
+
"examples": {
|
|
40
|
+
"vue2": [
|
|
41
|
+
{
|
|
42
|
+
"title": "基础用法",
|
|
43
|
+
"code": "<em-cell-group>\n <em-cell title=\"单元格\" value=\"内容\" />\n <em-cell title=\"单元格\" value=\"内容\" label=\"描述信息\" :border=\"false\" />\n</em-cell-group>"
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
"title": "单元格大小",
|
|
47
|
+
"code": "<em-cell title=\"单元格\" value=\"内容\" size=\"large\" />\n<em-cell title=\"单元格\" value=\"内容\" size=\"large\" label=\"描述信息\" />"
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"title": "展示图标",
|
|
51
|
+
"code": "<em-cell title=\"单元格\" icon=\"location-o\" />"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"title": "只设置 value",
|
|
55
|
+
"code": "<em-cell value=\"内容\" />"
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"title": "展示箭头",
|
|
59
|
+
"code": "<em-cell title=\"单元格\" is-link />\n<em-cell title=\"单元格\" is-link value=\"内容\" />\n<em-cell title=\"单元格\" is-link arrow-direction=\"down\" value=\"内容\" />"
|
|
60
|
+
}
|
|
61
|
+
],
|
|
62
|
+
"vue3": [
|
|
63
|
+
{
|
|
64
|
+
"title": "基础用法",
|
|
65
|
+
"code": "<em-cell-group>\n <em-cell title=\"单元格\" value=\"内容\" />\n <em-cell title=\"单元格\" value=\"内容\" label=\"描述信息\" :border=\"false\" />\n</em-cell-group>"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"title": "单元格大小",
|
|
69
|
+
"code": "<em-cell title=\"单元格\" value=\"内容\" size=\"large\" />\n<em-cell title=\"单元格\" value=\"内容\" size=\"large\" label=\"描述信息\" />"
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
"title": "展示图标",
|
|
73
|
+
"code": "<em-cell title=\"单元格\" icon=\"location-o\" />"
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
"title": "只设置 value",
|
|
77
|
+
"code": "<em-cell value=\"内容\" />"
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
"title": "展示箭头",
|
|
81
|
+
"code": "<em-cell title=\"单元格\" is-link />\n<em-cell title=\"单元格\" is-link value=\"内容\" />\n<em-cell title=\"单元格\" is-link arrow-direction=\"down\" value=\"内容\" />"
|
|
82
|
+
}
|
|
83
|
+
]
|
|
84
|
+
}
|
|
85
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "chart",
|
|
3
|
+
"name": "em-chart",
|
|
4
|
+
"title": "图表",
|
|
5
|
+
"description": "参考[`echarts-for-weixin`](https://github.com/ecomfe/echarts-for-weixin),基于[`Echarts`图表库](https://echarts.apache.org/handbook/zh/concepts/chart-size)封装的跨端组件。该组件自`v8.3.9`版本开始支持。",
|
|
6
|
+
"props": [
|
|
7
|
+
{
|
|
8
|
+
"name": "disable-touch",
|
|
9
|
+
"type": "boolean",
|
|
10
|
+
"default": "false",
|
|
11
|
+
"required": false,
|
|
12
|
+
"description": "禁用`touch`事件"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"name": "width",
|
|
16
|
+
"type": "string/number",
|
|
17
|
+
"default": "300px",
|
|
18
|
+
"required": false,
|
|
19
|
+
"description": "组件宽度,默认单位`px`"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"name": "height",
|
|
23
|
+
"type": "string/number",
|
|
24
|
+
"default": "200px",
|
|
25
|
+
"required": false,
|
|
26
|
+
"description": "组件高度,默认单位`px`"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"name": "lazyLoad",
|
|
30
|
+
"type": "boolean",
|
|
31
|
+
"default": "true",
|
|
32
|
+
"required": false,
|
|
33
|
+
"description": "是否手动初始化图表"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"name": "option",
|
|
37
|
+
"type": "object",
|
|
38
|
+
"default": "-",
|
|
39
|
+
"required": false,
|
|
40
|
+
"description": "自动初始化图表时,传入的图表配置项,见官方文档 [`ECharts`配置项手册](https://echarts.apache.org/zh/option.html#title)"
|
|
41
|
+
}
|
|
42
|
+
],
|
|
43
|
+
"events": [
|
|
44
|
+
{
|
|
45
|
+
"name": "loaded",
|
|
46
|
+
"parameters": "图表组件`mounted`生命周期触发,用于异步化分包时进行初始化操作",
|
|
47
|
+
"description": "-"
|
|
48
|
+
}
|
|
49
|
+
],
|
|
50
|
+
"slots": [],
|
|
51
|
+
"examples": {
|
|
52
|
+
"vue2": [],
|
|
53
|
+
"vue3": []
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "checkbox",
|
|
3
|
+
"name": "em-checkbox",
|
|
4
|
+
"title": "复选框",
|
|
5
|
+
"description": "复选框。",
|
|
6
|
+
"props": [
|
|
7
|
+
{
|
|
8
|
+
"name": "v-model",
|
|
9
|
+
"type": "boolean",
|
|
10
|
+
"default": "false",
|
|
11
|
+
"required": false,
|
|
12
|
+
"description": "是否为选中状态"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"name": "name",
|
|
16
|
+
"type": "any",
|
|
17
|
+
"default": "-",
|
|
18
|
+
"required": false,
|
|
19
|
+
"description": "标识符,注意微信小程序请传递字符串"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"name": "shape",
|
|
23
|
+
"type": "string",
|
|
24
|
+
"default": "square",
|
|
25
|
+
"required": false,
|
|
26
|
+
"description": "形状,可选值为 `round`"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"name": "indeterminate",
|
|
30
|
+
"type": "boolean",
|
|
31
|
+
"default": "false",
|
|
32
|
+
"required": false,
|
|
33
|
+
"description": "启用中选框"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"name": "disabled",
|
|
37
|
+
"type": "boolean",
|
|
38
|
+
"default": "false",
|
|
39
|
+
"required": false,
|
|
40
|
+
"description": "是否禁用复选框"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"name": "label-disabled",
|
|
44
|
+
"type": "boolean",
|
|
45
|
+
"default": "false",
|
|
46
|
+
"required": false,
|
|
47
|
+
"description": "是否禁用复选框文本点击"
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"name": "label-position",
|
|
51
|
+
"type": "string",
|
|
52
|
+
"default": "right",
|
|
53
|
+
"required": false,
|
|
54
|
+
"description": "文本位置,可选值为 `left`"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"name": "icon-size",
|
|
58
|
+
"type": "number / string",
|
|
59
|
+
"default": "20px",
|
|
60
|
+
"required": false,
|
|
61
|
+
"description": "图标大小,默认单位为`px`"
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"name": "icon",
|
|
65
|
+
"type": "boolean",
|
|
66
|
+
"default": "false",
|
|
67
|
+
"required": false,
|
|
68
|
+
"description": "自定义图标依赖该属性用于兼容微信和支付宝小程序"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"name": "checked-color",
|
|
72
|
+
"type": "string",
|
|
73
|
+
"default": "#1989fa",
|
|
74
|
+
"required": false,
|
|
75
|
+
"description": "选中状态颜色"
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
"name": "bind-group",
|
|
79
|
+
"type": "boolean",
|
|
80
|
+
"default": "true",
|
|
81
|
+
"required": false,
|
|
82
|
+
"description": "是否与复选框组绑定"
|
|
83
|
+
}
|
|
84
|
+
],
|
|
85
|
+
"events": [
|
|
86
|
+
{
|
|
87
|
+
"name": "change",
|
|
88
|
+
"parameters": "当绑定值变化时触发的事件",
|
|
89
|
+
"description": "checked: boolean"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"name": "click",
|
|
93
|
+
"parameters": "点击复选框时触发",
|
|
94
|
+
"description": "event: Event"
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
"name": "update:checked",
|
|
98
|
+
"parameters": "用于同步 checked 事件",
|
|
99
|
+
"description": "checked: boolean"
|
|
100
|
+
}
|
|
101
|
+
],
|
|
102
|
+
"slots": [
|
|
103
|
+
{
|
|
104
|
+
"name": "default",
|
|
105
|
+
"description": "自定义文本"
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
"name": "icon",
|
|
109
|
+
"description": "自定义图标"
|
|
110
|
+
}
|
|
111
|
+
],
|
|
112
|
+
"examples": {
|
|
113
|
+
"vue2": [
|
|
114
|
+
{
|
|
115
|
+
"title": "基础用法",
|
|
116
|
+
"code": "<em-checkbox v-model=\"checked\">复选框</em-checkbox>"
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"title": "禁用状态",
|
|
120
|
+
"code": "<em-checkbox v-model=\"checked\" disabled>复选框</em-checkbox>"
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"title": "自定义形状",
|
|
124
|
+
"code": "<em-checkbox v-model=\"checked\" shape=\"round\">复选框</em-checkbox>"
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
"title": "自定义颜色",
|
|
128
|
+
"code": "<em-checkbox v-model=\"checked\" checked-color=\"#07c160\">复选框</em-checkbox>"
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
"title": "自定义大小",
|
|
132
|
+
"code": "<em-checkbox v-model=\"checked\" icon-size=\"24px\">复选框</em-checkbox>"
|
|
133
|
+
}
|
|
134
|
+
],
|
|
135
|
+
"vue3": [
|
|
136
|
+
{
|
|
137
|
+
"title": "基础用法",
|
|
138
|
+
"code": "<em-checkbox v-model=\"checked\">复选框</em-checkbox>"
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
"title": "禁用状态",
|
|
142
|
+
"code": "<em-checkbox v-model=\"checked\" disabled>复选框</em-checkbox>"
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
"title": "自定义形状",
|
|
146
|
+
"code": "<em-checkbox v-model=\"checked\" shape=\"round\">复选框</em-checkbox>"
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
"title": "自定义颜色",
|
|
150
|
+
"code": "<em-checkbox v-model=\"checked\" checked-color=\"#07c160\">复选框</em-checkbox>"
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
"title": "自定义大小",
|
|
154
|
+
"code": "<em-checkbox v-model=\"checked\" icon-size=\"24px\">复选框</em-checkbox>"
|
|
155
|
+
}
|
|
156
|
+
]
|
|
157
|
+
}
|
|
158
|
+
}
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "circle",
|
|
3
|
+
"name": "em-circle",
|
|
4
|
+
"title": "环形进度条",
|
|
5
|
+
"description": "环形进度条组件。",
|
|
6
|
+
"props": [
|
|
7
|
+
{
|
|
8
|
+
"name": "v-model",
|
|
9
|
+
"type": "number",
|
|
10
|
+
"default": "-",
|
|
11
|
+
"required": false,
|
|
12
|
+
"description": "当前进度"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"name": "rate",
|
|
16
|
+
"type": "number / string",
|
|
17
|
+
"default": "100",
|
|
18
|
+
"required": false,
|
|
19
|
+
"description": "目标进度"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"name": "size",
|
|
23
|
+
"type": "number / string",
|
|
24
|
+
"default": "100px",
|
|
25
|
+
"required": false,
|
|
26
|
+
"description": "圆环直径,默认单位为 `px`"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"name": "color",
|
|
30
|
+
"type": "string / object",
|
|
31
|
+
"default": "#2e6be5",
|
|
32
|
+
"required": false,
|
|
33
|
+
"description": "进度条颜色,传入对象格式可以定义渐变色"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"name": "layer-color",
|
|
37
|
+
"type": "string",
|
|
38
|
+
"default": "white",
|
|
39
|
+
"required": false,
|
|
40
|
+
"description": "轨道颜色"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"name": "fill",
|
|
44
|
+
"type": "string",
|
|
45
|
+
"default": "-",
|
|
46
|
+
"required": false,
|
|
47
|
+
"description": "填充颜色"
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"name": "speed",
|
|
51
|
+
"type": "number / string",
|
|
52
|
+
"default": "0",
|
|
53
|
+
"required": false,
|
|
54
|
+
"description": "动画速度(单位为 `rate/s`)"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"name": "text",
|
|
58
|
+
"type": "string",
|
|
59
|
+
"default": "-",
|
|
60
|
+
"required": false,
|
|
61
|
+
"description": "文字"
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"name": "stroke-width",
|
|
65
|
+
"type": "number / string",
|
|
66
|
+
"default": "4",
|
|
67
|
+
"required": false,
|
|
68
|
+
"description": "进度条宽度"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"name": "stroke-linecap",
|
|
72
|
+
"type": "string",
|
|
73
|
+
"default": "round",
|
|
74
|
+
"required": false,
|
|
75
|
+
"description": "进度条端点的形状,可选值为`sqaure` `butt`"
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
"name": "clockwise",
|
|
79
|
+
"type": "boolean",
|
|
80
|
+
"default": "true",
|
|
81
|
+
"required": false,
|
|
82
|
+
"description": "是否顺时针增加"
|
|
83
|
+
}
|
|
84
|
+
],
|
|
85
|
+
"events": [],
|
|
86
|
+
"slots": [
|
|
87
|
+
{
|
|
88
|
+
"name": "default",
|
|
89
|
+
"description": "自定义文字内容"
|
|
90
|
+
}
|
|
91
|
+
],
|
|
92
|
+
"examples": {
|
|
93
|
+
"vue2": [
|
|
94
|
+
{
|
|
95
|
+
"title": "基础用法",
|
|
96
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"30\" :speed=\"100\" :text=\"text\" />"
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"title": "宽度定制",
|
|
100
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"rate\" :stroke-width=\"6\" text=\"宽度定制\" />"
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
"title": "颜色定制",
|
|
104
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"rate\" layer-color=\"#ebedf0\" color=\"#ee0a24\" text=\"颜色定制\" />"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"title": "渐变色",
|
|
108
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"rate\" :color=\"gradientColor\" text=\"渐变色\" />"
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"title": "逆时针方向",
|
|
112
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"rate\" :clockwise=\"false\" text=\"逆时针方向\" />"
|
|
113
|
+
}
|
|
114
|
+
],
|
|
115
|
+
"vue3": [
|
|
116
|
+
{
|
|
117
|
+
"title": "基础用法",
|
|
118
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"30\" :speed=\"100\" :text=\"text\" />"
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
"title": "宽度定制",
|
|
122
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"rate\" :stroke-width=\"6\" text=\"宽度定制\" />"
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
"title": "颜色定制",
|
|
126
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"rate\" layer-color=\"#ebedf0\" color=\"#ee0a24\" text=\"颜色定制\" />"
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
"title": "渐变色",
|
|
130
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"rate\" :color=\"gradientColor\" text=\"渐变色\" />"
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
"title": "逆时针方向",
|
|
134
|
+
"code": "<em-circle v-model=\"currentRate\" :rate=\"rate\" :clockwise=\"false\" text=\"逆时针方向\" />"
|
|
135
|
+
}
|
|
136
|
+
]
|
|
137
|
+
}
|
|
138
|
+
}
|