king-design-analyzer 2.2.1 → 2.2.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.
- package/components/aside.json +100 -0
- package/components/body.json +43 -0
- package/components/dropdown.json +9 -0
- package/components/footer.json +40 -0
- package/components/layout.json +53 -0
- package/components/layoutheader.json +113 -0
- package/components/popover.json +23 -0
- package/components/select.json +9 -0
- package/components/spinner.json +5 -1
- package/components/tour.json +16 -0
- package/components/transfer.json +11 -0
- package/components/upload.json +16 -0
- package/components/virtuallist.json +9 -0
- package/dist/ast/index.d.mts +7 -2
- package/dist/ast/index.d.ts +7 -2
- package/dist/ast/index.js +3 -3
- package/dist/ast/index.mjs +1 -1
- package/dist/{chunk-4WXOYU2N.js → chunk-7CSMAJZ2.js} +2 -2
- package/dist/{chunk-IPJJMPOO.mjs → chunk-7YBUXYUI.mjs} +75 -42
- package/dist/{chunk-JNRGUR3O.js → chunk-K6UQSWLC.js} +75 -42
- package/dist/{chunk-LRTDTFFQ.mjs → chunk-RJQMTGRE.mjs} +1 -1
- package/dist/full/index.js +4 -4
- package/dist/full/index.mjs +2 -2
- package/dist/index.js +6 -6
- package/dist/index.mjs +2 -2
- package/docs_for_llm/aside.doc.md +62 -0
- package/docs_for_llm/body.doc.md +44 -0
- package/docs_for_llm/dropdown.doc.md +17 -0
- package/docs_for_llm/footer.doc.md +46 -0
- package/docs_for_llm/layout-header.doc.md +61 -0
- package/docs_for_llm/layout.doc.md +53 -0
- package/docs_for_llm/popover.doc.md +34 -0
- package/docs_for_llm/select.doc.md +15 -0
- package/docs_for_llm/tour.doc.md +24 -0
- package/docs_for_llm/transfer.doc.md +1 -0
- package/docs_for_llm/upload.doc.md +21 -0
- package/docs_for_llm/virtuallist.doc.md +14 -0
- package/package.json +1 -1
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "aside",
|
|
3
|
+
"name": "Aside",
|
|
4
|
+
"displayName": "侧边栏",
|
|
5
|
+
"category": "layout",
|
|
6
|
+
"description": "布局侧边栏组件,适合承载导航菜单或辅助信息区域,可配置固定定位和折叠宽度。",
|
|
7
|
+
"importStatement": "import { Aside } from '@king-design/vue';",
|
|
8
|
+
"props": [
|
|
9
|
+
{
|
|
10
|
+
"name": "collapse",
|
|
11
|
+
"description": "是否处于折叠状态。",
|
|
12
|
+
"type": {
|
|
13
|
+
"raw": "boolean",
|
|
14
|
+
"kind": "boolean"
|
|
15
|
+
},
|
|
16
|
+
"required": false,
|
|
17
|
+
"default": "false",
|
|
18
|
+
"usageExample": "<Aside collapse>折叠菜单</Aside>"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"name": "fixed",
|
|
22
|
+
"description": "是否固定在页面左侧。",
|
|
23
|
+
"type": {
|
|
24
|
+
"raw": "boolean",
|
|
25
|
+
"kind": "boolean"
|
|
26
|
+
},
|
|
27
|
+
"required": false,
|
|
28
|
+
"default": "false",
|
|
29
|
+
"usageExample": "<Aside fixed>固定侧边栏</Aside>"
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
"name": "theme",
|
|
33
|
+
"description": "侧边栏主题,沿用 Menu 组件的主题配置。",
|
|
34
|
+
"type": {
|
|
35
|
+
"raw": "MenuProps['theme']",
|
|
36
|
+
"kind": "custom"
|
|
37
|
+
},
|
|
38
|
+
"required": false,
|
|
39
|
+
"default": "\"light\"",
|
|
40
|
+
"usageExample": "<Aside theme=\"dark\">深色侧边栏</Aside>"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"name": "width",
|
|
44
|
+
"description": "侧边栏宽度,支持数字或带单位的字符串。",
|
|
45
|
+
"type": {
|
|
46
|
+
"raw": "number | string",
|
|
47
|
+
"kind": "union"
|
|
48
|
+
},
|
|
49
|
+
"required": false,
|
|
50
|
+
"default": "240",
|
|
51
|
+
"usageExample": "<Aside :width=\"220\">自定义宽度</Aside>"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"name": "collapsedWidth",
|
|
55
|
+
"description": "折叠状态下的宽度。",
|
|
56
|
+
"type": {
|
|
57
|
+
"raw": "number | string",
|
|
58
|
+
"kind": "union"
|
|
59
|
+
},
|
|
60
|
+
"required": false,
|
|
61
|
+
"default": "64",
|
|
62
|
+
"usageExample": "<Aside :collapsedWidth=\"56\" collapse>折叠侧边栏</Aside>"
|
|
63
|
+
}
|
|
64
|
+
],
|
|
65
|
+
"events": [],
|
|
66
|
+
"slots": [
|
|
67
|
+
{
|
|
68
|
+
"name": "default",
|
|
69
|
+
"description": "侧边栏内容,通常放置菜单、品牌信息或辅助操作。",
|
|
70
|
+
"bindingType": "none",
|
|
71
|
+
"vueTemplate": "#default",
|
|
72
|
+
"usageExample": "<Aside>\n <Menu>\n <MenuItem key=\"1\">概览</MenuItem>\n </Menu>\n</Aside>"
|
|
73
|
+
}
|
|
74
|
+
],
|
|
75
|
+
"methods": [],
|
|
76
|
+
"examples": [
|
|
77
|
+
{
|
|
78
|
+
"id": "aside_basic",
|
|
79
|
+
"title": "基础侧边栏",
|
|
80
|
+
"description": "在布局中放置导航菜单。",
|
|
81
|
+
"difficulty": "easy",
|
|
82
|
+
"code": "<script setup lang=\"ts\">\nimport { Layout, Aside, Body, Menu, MenuItem } from '@king-design/vue';\n</script>\n<template>\n <Layout>\n <Aside :width=\"220\">\n <Menu>\n <MenuItem key=\"overview\">概览</MenuItem>\n <MenuItem key=\"instance\">实例列表</MenuItem>\n </Menu>\n </Aside>\n <Body>\n <div style=\"padding: 16px;\">内容区域</div>\n </Body>\n </Layout>\n</template>",
|
|
83
|
+
"tags": [
|
|
84
|
+
"aside",
|
|
85
|
+
"menu"
|
|
86
|
+
],
|
|
87
|
+
"usedProps": [
|
|
88
|
+
"width"
|
|
89
|
+
],
|
|
90
|
+
"usedEvents": [],
|
|
91
|
+
"usedMethods": [],
|
|
92
|
+
"scenario": "在后台布局中承载主导航菜单。"
|
|
93
|
+
}
|
|
94
|
+
],
|
|
95
|
+
"relatedComponents": [
|
|
96
|
+
"Layout",
|
|
97
|
+
"Body",
|
|
98
|
+
"Menu"
|
|
99
|
+
]
|
|
100
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "body",
|
|
3
|
+
"name": "Body",
|
|
4
|
+
"displayName": "布局主体",
|
|
5
|
+
"category": "layout",
|
|
6
|
+
"description": "布局主体容器,用于承载页面主要内容区域,通常与 Header、Aside 组合使用。",
|
|
7
|
+
"importStatement": "import { Body } from '@king-design/vue';",
|
|
8
|
+
"props": [],
|
|
9
|
+
"events": [],
|
|
10
|
+
"slots": [
|
|
11
|
+
{
|
|
12
|
+
"name": "default",
|
|
13
|
+
"description": "主体内容区域。",
|
|
14
|
+
"bindingType": "none",
|
|
15
|
+
"vueTemplate": "#default",
|
|
16
|
+
"usageExample": "<Body>\n <div style=\"padding: 16px;\">页面主体内容</div>\n</Body>"
|
|
17
|
+
}
|
|
18
|
+
],
|
|
19
|
+
"methods": [],
|
|
20
|
+
"examples": [
|
|
21
|
+
{
|
|
22
|
+
"id": "body_basic",
|
|
23
|
+
"title": "主体内容区",
|
|
24
|
+
"description": "在布局中承载页面正文。",
|
|
25
|
+
"difficulty": "easy",
|
|
26
|
+
"code": "<script setup lang=\"ts\">\nimport { Layout, Header, Body } from '@king-design/vue';\n</script>\n<template>\n <Layout>\n <Header>实例管理</Header>\n <Body>\n <div style=\"padding: 16px;\">这里放页面内容</div>\n </Body>\n </Layout>\n</template>",
|
|
27
|
+
"tags": [
|
|
28
|
+
"body",
|
|
29
|
+
"content"
|
|
30
|
+
],
|
|
31
|
+
"usedProps": [],
|
|
32
|
+
"usedEvents": [],
|
|
33
|
+
"usedMethods": [],
|
|
34
|
+
"scenario": "作为后台页面的主要内容承载区域。"
|
|
35
|
+
}
|
|
36
|
+
],
|
|
37
|
+
"relatedComponents": [
|
|
38
|
+
"Layout",
|
|
39
|
+
"Header",
|
|
40
|
+
"Aside",
|
|
41
|
+
"Footer"
|
|
42
|
+
]
|
|
43
|
+
}
|
package/components/dropdown.json
CHANGED
|
@@ -173,6 +173,15 @@
|
|
|
173
173
|
"handlerExample": "const handlePositioned = (feedback: Feedback) => {\n console.log('最终位置', feedback.placement);\n};"
|
|
174
174
|
}
|
|
175
175
|
],
|
|
176
|
+
"slots": [
|
|
177
|
+
{
|
|
178
|
+
"name": "menu",
|
|
179
|
+
"description": "自定义下拉菜单内容,通常放置 DropdownMenu 和 DropdownItem。",
|
|
180
|
+
"bindingType": "none",
|
|
181
|
+
"vueTemplate": "<template #menu>...</template>",
|
|
182
|
+
"usageExample": "<Dropdown>\n <Button>更多操作</Button>\n <template #menu>\n <DropdownMenu>\n <DropdownItem>查看详情</DropdownItem>\n </DropdownMenu>\n </template>\n</Dropdown>"
|
|
183
|
+
}
|
|
184
|
+
],
|
|
176
185
|
"methods": [
|
|
177
186
|
{
|
|
178
187
|
"name": "show",
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "footer",
|
|
3
|
+
"name": "Footer",
|
|
4
|
+
"displayName": "布局底部",
|
|
5
|
+
"category": "layout",
|
|
6
|
+
"description": "布局底部组件,适合展示版权、说明信息或页面级辅助操作。",
|
|
7
|
+
"importStatement": "import { Footer } from '@king-design/vue';",
|
|
8
|
+
"props": [],
|
|
9
|
+
"events": [],
|
|
10
|
+
"slots": [
|
|
11
|
+
{
|
|
12
|
+
"name": "default",
|
|
13
|
+
"description": "底部内容区域。",
|
|
14
|
+
"bindingType": "none",
|
|
15
|
+
"vueTemplate": "#default",
|
|
16
|
+
"usageExample": "<Footer>\n Copyright 2026 Kingsoft Cloud\n</Footer>"
|
|
17
|
+
}
|
|
18
|
+
],
|
|
19
|
+
"methods": [],
|
|
20
|
+
"examples": [
|
|
21
|
+
{
|
|
22
|
+
"id": "footer_basic",
|
|
23
|
+
"title": "基础底部",
|
|
24
|
+
"description": "展示底部版权或补充说明。",
|
|
25
|
+
"difficulty": "easy",
|
|
26
|
+
"code": "<script setup lang=\"ts\">\nimport { Layout, Body, Footer } from '@king-design/vue';\n</script>\n<template>\n <Layout>\n <Body>\n <div style=\"padding: 16px; min-height: 200px;\">内容区域</div>\n </Body>\n <Footer>\n Copyright 2026 Kingsoft Cloud\n </Footer>\n </Layout>\n</template>",
|
|
27
|
+
"tags": [
|
|
28
|
+
"footer"
|
|
29
|
+
],
|
|
30
|
+
"usedProps": [],
|
|
31
|
+
"usedEvents": [],
|
|
32
|
+
"usedMethods": [],
|
|
33
|
+
"scenario": "在控制台页面底部展示版权或补充提示。"
|
|
34
|
+
}
|
|
35
|
+
],
|
|
36
|
+
"relatedComponents": [
|
|
37
|
+
"Layout",
|
|
38
|
+
"Body"
|
|
39
|
+
]
|
|
40
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "layout",
|
|
3
|
+
"name": "Layout",
|
|
4
|
+
"displayName": "布局容器",
|
|
5
|
+
"category": "layout",
|
|
6
|
+
"description": "页面整体布局容器,用于组合 Header、Aside、Body、Footer 等区域,构建后台或工作台页面结构。",
|
|
7
|
+
"importStatement": "import { Layout } from '@king-design/vue';",
|
|
8
|
+
"props": [],
|
|
9
|
+
"events": [],
|
|
10
|
+
"slots": [
|
|
11
|
+
{
|
|
12
|
+
"name": "default",
|
|
13
|
+
"description": "布局内容区域,通常放置 Header、Aside、Body、Footer 组件。",
|
|
14
|
+
"bindingType": "none",
|
|
15
|
+
"vueTemplate": "#default",
|
|
16
|
+
"usageExample": "<Layout>\n <Header />\n <Body>内容区</Body>\n</Layout>"
|
|
17
|
+
}
|
|
18
|
+
],
|
|
19
|
+
"methods": [],
|
|
20
|
+
"examples": [
|
|
21
|
+
{
|
|
22
|
+
"id": "layout_basic",
|
|
23
|
+
"title": "基础布局",
|
|
24
|
+
"description": "组合头部、侧边栏和内容区,构建典型后台页面布局。",
|
|
25
|
+
"difficulty": "easy",
|
|
26
|
+
"code": "<script setup lang=\"ts\">\nimport { Layout, Header, Aside, Body, Footer } from '@king-design/vue';\n</script>\n<template>\n <Layout>\n <Header>控制台</Header>\n <Layout>\n <Aside>导航菜单</Aside>\n <Body>\n <div style=\"padding: 16px;\">页面内容</div>\n </Body>\n </Layout>\n <Footer>Copyright 2026</Footer>\n </Layout>\n</template>",
|
|
27
|
+
"tags": [
|
|
28
|
+
"layout",
|
|
29
|
+
"basic"
|
|
30
|
+
],
|
|
31
|
+
"usedProps": [],
|
|
32
|
+
"usedEvents": [],
|
|
33
|
+
"usedMethods": [],
|
|
34
|
+
"scenario": "用于管理后台和工作台页面的整体结构搭建。"
|
|
35
|
+
}
|
|
36
|
+
],
|
|
37
|
+
"searchKeywords": [
|
|
38
|
+
"layout",
|
|
39
|
+
"页面布局",
|
|
40
|
+
"布局容器"
|
|
41
|
+
],
|
|
42
|
+
"useCases": [
|
|
43
|
+
"后台布局",
|
|
44
|
+
"控制台页面",
|
|
45
|
+
"工作台页面"
|
|
46
|
+
],
|
|
47
|
+
"relatedComponents": [
|
|
48
|
+
"Header",
|
|
49
|
+
"Aside",
|
|
50
|
+
"Body",
|
|
51
|
+
"Footer"
|
|
52
|
+
]
|
|
53
|
+
}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "layout-header",
|
|
3
|
+
"name": "Header",
|
|
4
|
+
"displayName": "布局头部",
|
|
5
|
+
"category": "layout",
|
|
6
|
+
"description": "布局头部组件,常用于放置站点标题、全局导航和操作入口,可配置固定定位、主题和毛玻璃效果。",
|
|
7
|
+
"importStatement": "import { Header } from '@king-design/vue';",
|
|
8
|
+
"props": [
|
|
9
|
+
{
|
|
10
|
+
"name": "fixed",
|
|
11
|
+
"description": "是否固定在页面顶部。",
|
|
12
|
+
"type": {
|
|
13
|
+
"raw": "boolean",
|
|
14
|
+
"kind": "boolean"
|
|
15
|
+
},
|
|
16
|
+
"required": false,
|
|
17
|
+
"default": "false",
|
|
18
|
+
"usageExample": "<Header fixed>固定头部</Header>"
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"name": "height",
|
|
22
|
+
"description": "头部高度,支持数字或带单位的字符串。",
|
|
23
|
+
"type": {
|
|
24
|
+
"raw": "number | string",
|
|
25
|
+
"kind": "union"
|
|
26
|
+
},
|
|
27
|
+
"required": false,
|
|
28
|
+
"default": "64",
|
|
29
|
+
"usageExample": "<Header :height=\"56\">紧凑头部</Header>"
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
"name": "style",
|
|
33
|
+
"description": "自定义内联样式。",
|
|
34
|
+
"type": {
|
|
35
|
+
"raw": "string | Record<string, string>",
|
|
36
|
+
"kind": "union"
|
|
37
|
+
},
|
|
38
|
+
"required": false,
|
|
39
|
+
"default": "undefined",
|
|
40
|
+
"usageExample": "<Header :style=\"{ background: '#fff' }\">自定义样式</Header>"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"name": "theme",
|
|
44
|
+
"description": "头部主题,沿用 Menu 组件的主题配置。",
|
|
45
|
+
"type": {
|
|
46
|
+
"raw": "MenuProps['theme']",
|
|
47
|
+
"kind": "custom"
|
|
48
|
+
},
|
|
49
|
+
"required": false,
|
|
50
|
+
"default": "\"light\"",
|
|
51
|
+
"usageExample": "<Header theme=\"dark\">深色头部</Header>"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"name": "blur",
|
|
55
|
+
"description": "是否开启毛玻璃背景效果。",
|
|
56
|
+
"type": {
|
|
57
|
+
"raw": "boolean",
|
|
58
|
+
"kind": "boolean"
|
|
59
|
+
},
|
|
60
|
+
"required": false,
|
|
61
|
+
"default": "false",
|
|
62
|
+
"usageExample": "<Header blur>毛玻璃头部</Header>"
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"name": "boxShadow",
|
|
66
|
+
"description": "是否展示底部阴影。",
|
|
67
|
+
"type": {
|
|
68
|
+
"raw": "boolean",
|
|
69
|
+
"kind": "boolean"
|
|
70
|
+
},
|
|
71
|
+
"required": false,
|
|
72
|
+
"default": "false",
|
|
73
|
+
"usageExample": "<Header boxShadow>带阴影头部</Header>"
|
|
74
|
+
}
|
|
75
|
+
],
|
|
76
|
+
"events": [],
|
|
77
|
+
"slots": [
|
|
78
|
+
{
|
|
79
|
+
"name": "default",
|
|
80
|
+
"description": "头部内容区域,通常放置 Logo、导航或操作按钮。",
|
|
81
|
+
"bindingType": "none",
|
|
82
|
+
"vueTemplate": "#default",
|
|
83
|
+
"usageExample": "<Header>\n <div style=\"display: flex; justify-content: space-between;\">控制台<header-actions /></div>\n</Header>"
|
|
84
|
+
}
|
|
85
|
+
],
|
|
86
|
+
"methods": [],
|
|
87
|
+
"examples": [
|
|
88
|
+
{
|
|
89
|
+
"id": "layout_header_basic",
|
|
90
|
+
"title": "基础布局头部",
|
|
91
|
+
"description": "作为站点或控制台的全局顶部栏。",
|
|
92
|
+
"difficulty": "easy",
|
|
93
|
+
"code": "<script setup lang=\"ts\">\nimport { Layout, Header, Body, Button } from '@king-design/vue';\n</script>\n<template>\n <Layout>\n <Header fixed theme=\"dark\" :height=\"56\">\n <div style=\"display: flex; align-items: center; justify-content: space-between; height: 100%; padding: 0 16px;\">\n <span>控制台</span>\n <Button type=\"primary\">新建资源</Button>\n </div>\n </Header>\n <Body>\n <div style=\"padding: 16px;\">页面内容</div>\n </Body>\n </Layout>\n</template>",
|
|
94
|
+
"tags": [
|
|
95
|
+
"header",
|
|
96
|
+
"layout"
|
|
97
|
+
],
|
|
98
|
+
"usedProps": [
|
|
99
|
+
"fixed",
|
|
100
|
+
"theme",
|
|
101
|
+
"height"
|
|
102
|
+
],
|
|
103
|
+
"usedEvents": [],
|
|
104
|
+
"usedMethods": [],
|
|
105
|
+
"scenario": "用于后台系统的全局固定顶部栏。"
|
|
106
|
+
}
|
|
107
|
+
],
|
|
108
|
+
"relatedComponents": [
|
|
109
|
+
"Layout",
|
|
110
|
+
"Body",
|
|
111
|
+
"Aside"
|
|
112
|
+
]
|
|
113
|
+
}
|
package/components/popover.json
CHANGED
|
@@ -274,6 +274,29 @@
|
|
|
274
274
|
"handlerExample": "const handleCancel = () => {\n console.log('已取消');\n};"
|
|
275
275
|
}
|
|
276
276
|
],
|
|
277
|
+
"slots": [
|
|
278
|
+
{
|
|
279
|
+
"name": "title",
|
|
280
|
+
"description": "自定义确认提示标题区域内容。",
|
|
281
|
+
"bindingType": "none",
|
|
282
|
+
"vueTemplate": "<template #title>...</template>",
|
|
283
|
+
"usageExample": "<Popover>\n <template #title>删除实例</template>\n <Button>删除</Button>\n</Popover>"
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
"name": "content",
|
|
287
|
+
"description": "自定义确认提示主体内容。",
|
|
288
|
+
"bindingType": "none",
|
|
289
|
+
"vueTemplate": "<template #content>...</template>",
|
|
290
|
+
"usageExample": "<Popover>\n <template #content>\n 删除后将无法恢复,请确认操作。\n </template>\n <Button>删除</Button>\n</Popover>"
|
|
291
|
+
},
|
|
292
|
+
{
|
|
293
|
+
"name": "footer",
|
|
294
|
+
"description": "自定义底部操作区内容,可覆盖默认的确认/取消按钮。",
|
|
295
|
+
"bindingType": "none",
|
|
296
|
+
"vueTemplate": "<template #footer>...</template>",
|
|
297
|
+
"usageExample": "<Popover>\n <template #footer>\n <Button size=\"small\">稍后处理</Button>\n <Button type=\"danger\" size=\"small\">立即删除</Button>\n </template>\n <Button>删除</Button>\n</Popover>"
|
|
298
|
+
}
|
|
299
|
+
],
|
|
277
300
|
"methods": [],
|
|
278
301
|
"typeDefinitions": [
|
|
279
302
|
{
|
package/components/select.json
CHANGED
|
@@ -495,6 +495,15 @@
|
|
|
495
495
|
"default": "undefined",
|
|
496
496
|
"usageExample": "<OptionGroup label=\"水果\">\n <Option value=\"apple\" label=\"苹果\" />\n</OptionGroup>"
|
|
497
497
|
}
|
|
498
|
+
],
|
|
499
|
+
"slots": [
|
|
500
|
+
{
|
|
501
|
+
"name": "label",
|
|
502
|
+
"description": "自定义选项分组标题内容。",
|
|
503
|
+
"bindingType": "none",
|
|
504
|
+
"vueTemplate": "#label",
|
|
505
|
+
"usageExample": "<OptionGroup>\n <template #label>\n <span>水果分组</span>\n </template>\n <Option value=\"apple\" label=\"苹果\" />\n</OptionGroup>"
|
|
506
|
+
}
|
|
498
507
|
]
|
|
499
508
|
}
|
|
500
509
|
],
|
package/components/spinner.json
CHANGED
|
@@ -76,6 +76,10 @@
|
|
|
76
76
|
"required": false,
|
|
77
77
|
"default": "\"default\"",
|
|
78
78
|
"allowedValues": [{
|
|
79
|
+
"value": "large",
|
|
80
|
+
"label": "大尺寸"
|
|
81
|
+
},
|
|
82
|
+
{
|
|
79
83
|
"value": "default",
|
|
80
84
|
"label": "默认尺寸",
|
|
81
85
|
"isDefault": true
|
|
@@ -428,4 +432,4 @@
|
|
|
428
432
|
"Input",
|
|
429
433
|
"Slider"
|
|
430
434
|
]
|
|
431
|
-
}
|
|
435
|
+
}
|
package/components/tour.json
CHANGED
|
@@ -265,6 +265,22 @@
|
|
|
265
265
|
"default": "\"上一步\"",
|
|
266
266
|
"usageExample": "<TourStep prevText=\"返回\">"
|
|
267
267
|
}
|
|
268
|
+
],
|
|
269
|
+
"slots": [
|
|
270
|
+
{
|
|
271
|
+
"name": "header",
|
|
272
|
+
"description": "自定义步骤头部内容,可覆盖标题区域。",
|
|
273
|
+
"bindingType": "none",
|
|
274
|
+
"vueTemplate": "#header",
|
|
275
|
+
"usageExample": "<TourStep>\n <template #header>\n <strong>欢迎使用控制台</strong>\n </template>\n</TourStep>"
|
|
276
|
+
},
|
|
277
|
+
{
|
|
278
|
+
"name": "footer",
|
|
279
|
+
"description": "自定义步骤底部操作区,可覆盖默认的步骤指示和按钮。",
|
|
280
|
+
"bindingType": "none",
|
|
281
|
+
"vueTemplate": "#footer",
|
|
282
|
+
"usageExample": "<TourStep>\n <template #footer>\n <Button size=\"small\">跳过引导</Button>\n <Button type=\"primary\" size=\"small\">继续</Button>\n </template>\n</TourStep>"
|
|
283
|
+
}
|
|
268
284
|
]
|
|
269
285
|
}
|
|
270
286
|
],
|
package/components/transfer.json
CHANGED
|
@@ -172,6 +172,17 @@
|
|
|
172
172
|
"required": false,
|
|
173
173
|
"default": "undefined",
|
|
174
174
|
"usageExample": "<Transfer :enableRemove=\"canRemove\"></Transfer>"
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
"name": "pagination",
|
|
178
|
+
"description": "是否启用左右面板分页,也可以传入 Pagination 的配置对象来自定义页码和每页条数。",
|
|
179
|
+
"type": {
|
|
180
|
+
"raw": "boolean | PaginationProps",
|
|
181
|
+
"kind": "union"
|
|
182
|
+
},
|
|
183
|
+
"required": false,
|
|
184
|
+
"default": "false",
|
|
185
|
+
"usageExample": "<Transfer :pagination=\"{ value: 1, limit: 10 }\"></Transfer>"
|
|
175
186
|
}
|
|
176
187
|
],
|
|
177
188
|
"events": [
|
package/components/upload.json
CHANGED
|
@@ -299,6 +299,22 @@
|
|
|
299
299
|
"handlerExample": "const handleError = (err, file, files) => {\n Message.error(err.message);\n};"
|
|
300
300
|
}
|
|
301
301
|
],
|
|
302
|
+
"slots": [
|
|
303
|
+
{
|
|
304
|
+
"name": "content",
|
|
305
|
+
"description": "自定义上传触发区域内容,例如按钮、拖拽提示文案等。",
|
|
306
|
+
"bindingType": "none",
|
|
307
|
+
"vueTemplate": "<template #content>...</template>",
|
|
308
|
+
"usageExample": "<Upload action=\"/api/upload\">\n <template #content>\n <Button type=\"primary\">选择文件</Button>\n </template>\n</Upload>"
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
"name": "tip",
|
|
312
|
+
"description": "自定义底部提示内容,通常用于说明支持的文件类型、大小或数量限制。",
|
|
313
|
+
"bindingType": "none",
|
|
314
|
+
"vueTemplate": "<template #tip>...</template>",
|
|
315
|
+
"usageExample": "<Upload action=\"/api/upload\">\n <template #tip>只能上传 JPG/PNG 文件,且不超过 500KB</template>\n</Upload>"
|
|
316
|
+
}
|
|
317
|
+
],
|
|
302
318
|
"methods": [
|
|
303
319
|
{
|
|
304
320
|
"name": "submit",
|
|
@@ -19,6 +19,15 @@
|
|
|
19
19
|
}
|
|
20
20
|
],
|
|
21
21
|
"events": [],
|
|
22
|
+
"slots": [
|
|
23
|
+
{
|
|
24
|
+
"name": "default",
|
|
25
|
+
"description": "列表项渲染内容,通常配合 v-for 渲染大量行。",
|
|
26
|
+
"bindingType": "none",
|
|
27
|
+
"vueTemplate": "#default",
|
|
28
|
+
"usageExample": "<VirtualList style=\"height: 400px;\">\n <template #default>\n <div v-for=\"item in data\" :key=\"item.value\">{{ item.label }}</div>\n </template>\n</VirtualList>"
|
|
29
|
+
}
|
|
30
|
+
],
|
|
22
31
|
"methods": [],
|
|
23
32
|
"subComponents": [
|
|
24
33
|
{
|
package/dist/ast/index.d.mts
CHANGED
|
@@ -84,6 +84,9 @@ interface ComponentSubComponent {
|
|
|
84
84
|
interface ComponentMetadata {
|
|
85
85
|
id?: string;
|
|
86
86
|
name: string;
|
|
87
|
+
fileName?: string;
|
|
88
|
+
source?: string;
|
|
89
|
+
importSource?: string;
|
|
87
90
|
props: ComponentProp[];
|
|
88
91
|
events: ComponentEvent[];
|
|
89
92
|
slots: ComponentSlot[];
|
|
@@ -117,6 +120,7 @@ declare class ComponentRegistry {
|
|
|
117
120
|
* 重新加载所有组件元数据
|
|
118
121
|
*/
|
|
119
122
|
reload(): Promise<void>;
|
|
123
|
+
private appendComponent;
|
|
120
124
|
/**
|
|
121
125
|
* 开始监听文件变化
|
|
122
126
|
*/
|
|
@@ -125,9 +129,10 @@ declare class ComponentRegistry {
|
|
|
125
129
|
* 停止监听
|
|
126
130
|
*/
|
|
127
131
|
stopWatching(): void;
|
|
128
|
-
getComponent(name: string): ComponentMetadata | undefined;
|
|
132
|
+
getComponent(name: string, importSource?: string): ComponentMetadata | undefined;
|
|
133
|
+
getComponents(name: string): ComponentMetadata[];
|
|
129
134
|
getAllComponentNames(): string[];
|
|
130
|
-
isKnownComponent(name: string): boolean;
|
|
135
|
+
isKnownComponent(name: string, importSource?: string): boolean;
|
|
131
136
|
}
|
|
132
137
|
declare const componentRegistry: ComponentRegistry;
|
|
133
138
|
|
package/dist/ast/index.d.ts
CHANGED
|
@@ -84,6 +84,9 @@ interface ComponentSubComponent {
|
|
|
84
84
|
interface ComponentMetadata {
|
|
85
85
|
id?: string;
|
|
86
86
|
name: string;
|
|
87
|
+
fileName?: string;
|
|
88
|
+
source?: string;
|
|
89
|
+
importSource?: string;
|
|
87
90
|
props: ComponentProp[];
|
|
88
91
|
events: ComponentEvent[];
|
|
89
92
|
slots: ComponentSlot[];
|
|
@@ -117,6 +120,7 @@ declare class ComponentRegistry {
|
|
|
117
120
|
* 重新加载所有组件元数据
|
|
118
121
|
*/
|
|
119
122
|
reload(): Promise<void>;
|
|
123
|
+
private appendComponent;
|
|
120
124
|
/**
|
|
121
125
|
* 开始监听文件变化
|
|
122
126
|
*/
|
|
@@ -125,9 +129,10 @@ declare class ComponentRegistry {
|
|
|
125
129
|
* 停止监听
|
|
126
130
|
*/
|
|
127
131
|
stopWatching(): void;
|
|
128
|
-
getComponent(name: string): ComponentMetadata | undefined;
|
|
132
|
+
getComponent(name: string, importSource?: string): ComponentMetadata | undefined;
|
|
133
|
+
getComponents(name: string): ComponentMetadata[];
|
|
129
134
|
getAllComponentNames(): string[];
|
|
130
|
-
isKnownComponent(name: string): boolean;
|
|
135
|
+
isKnownComponent(name: string, importSource?: string): boolean;
|
|
131
136
|
}
|
|
132
137
|
declare const componentRegistry: ComponentRegistry;
|
|
133
138
|
|
package/dist/ast/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
require('../chunk-YTEYDSDW.js');
|
|
4
|
-
var
|
|
4
|
+
var chunkK6UQSWLC_js = require('../chunk-K6UQSWLC.js');
|
|
5
5
|
require('../chunk-KF5YBEM5.js');
|
|
6
6
|
require('../chunk-JSBRDJBE.js');
|
|
7
7
|
|
|
@@ -9,9 +9,9 @@ require('../chunk-JSBRDJBE.js');
|
|
|
9
9
|
|
|
10
10
|
Object.defineProperty(exports, "analyzeCodeWithAST", {
|
|
11
11
|
enumerable: true,
|
|
12
|
-
get: function () { return
|
|
12
|
+
get: function () { return chunkK6UQSWLC_js.analyzeCodeWithAST; }
|
|
13
13
|
});
|
|
14
14
|
Object.defineProperty(exports, "componentRegistry", {
|
|
15
15
|
enumerable: true,
|
|
16
|
-
get: function () { return
|
|
16
|
+
get: function () { return chunkK6UQSWLC_js.componentRegistry; }
|
|
17
17
|
});
|
package/dist/ast/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkK6UQSWLC_js = require('./chunk-K6UQSWLC.js');
|
|
4
4
|
var chunkV5N65MRP_js = require('./chunk-V5N65MRP.js');
|
|
5
5
|
var chunkDHLWNT53_js = require('./chunk-DHLWNT53.js');
|
|
6
6
|
|
|
@@ -64,7 +64,7 @@ function validateCompilation(code) {
|
|
|
64
64
|
}
|
|
65
65
|
async function validateAST(code) {
|
|
66
66
|
try {
|
|
67
|
-
const violations = await
|
|
67
|
+
const violations = await chunkK6UQSWLC_js.analyzeCodeWithAST(code);
|
|
68
68
|
if (violations.length > 0) {
|
|
69
69
|
return {
|
|
70
70
|
name: "AST\u89C4\u5219\u68C0\u67E5",
|