ep-craft 0.1.41 → 0.2.0
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/dist/components/input-number/EpInputNumber.vue.js +62 -63
- package/dist/components/input-number/input-number.d.ts +5 -0
- package/dist/components/input-number/input-number.js +6 -6
- package/dist/components/select/index.d.ts +6 -3
- package/dist/components/select/select.d.ts +1 -0
- package/dist/components/select/select.js +3 -3
- package/dist/components/select/select.vue.d.ts +3 -1
- package/dist/components/select/select.vue.js +9 -9
- package/dist/components/select/select2.vue.js +73 -75
- package/dist/components/select-v2/src/defaults.d.ts +1 -0
- package/dist/components/select-v2/src/defaults.js +1 -1
- package/dist/components/select-v2/src/select.vue.d.ts +3 -1
- package/dist/components/select-v2/src/select.vue.js +21 -21
- package/dist/components/select-v2/src/select2.vue.js +27 -29
- package/dist/components/tree-select/src/tree-select.vue.d.ts +2 -0
- package/dist-ai/components/affix.json +152 -0
- package/dist-ai/components/affix.md +73 -0
- package/dist-ai/components/alert.json +186 -0
- package/dist-ai/components/alert.md +89 -0
- package/dist-ai/components/anchor-link.json +102 -0
- package/dist-ai/components/anchor-link.md +67 -0
- package/dist-ai/components/anchor.json +179 -0
- package/dist-ai/components/anchor.md +87 -0
- package/dist-ai/components/aside.json +87 -0
- package/dist-ai/components/aside.md +63 -0
- package/dist-ai/components/autocomplete.json +613 -0
- package/dist-ai/components/autocomplete.md +140 -0
- package/dist-ai/components/avatar.json +163 -0
- package/dist-ai/components/avatar.md +83 -0
- package/dist-ai/components/backtop.json +118 -0
- package/dist-ai/components/backtop.md +66 -0
- package/dist-ai/components/badge.json +186 -0
- package/dist-ai/components/badge.md +85 -0
- package/dist-ai/components/breadcrumb-item.json +97 -0
- package/dist-ai/components/breadcrumb-item.md +65 -0
- package/dist-ai/components/breadcrumb.json +100 -0
- package/dist-ai/components/breadcrumb.md +68 -0
- package/dist-ai/components/button-group.json +123 -0
- package/dist-ai/components/button-group.md +65 -0
- package/dist-ai/components/button.json +349 -0
- package/dist-ai/components/button.md +124 -0
- package/dist-ai/components/calendar.json +148 -0
- package/dist-ai/components/calendar.md +74 -0
- package/dist-ai/components/card.json +168 -0
- package/dist-ai/components/card.md +87 -0
- package/dist-ai/components/carousel-item.json +99 -0
- package/dist-ai/components/carousel-item.md +68 -0
- package/dist-ai/components/carousel.json +245 -0
- package/dist-ai/components/carousel.md +97 -0
- package/dist-ai/components/cascader-panel.json +242 -0
- package/dist-ai/components/cascader-panel.md +108 -0
- package/dist-ai/components/cascader.json +531 -0
- package/dist-ai/components/cascader.md +146 -0
- package/dist-ai/components/check-tag.json +133 -0
- package/dist-ai/components/check-tag.md +72 -0
- package/dist-ai/components/checkbox-button.json +279 -0
- package/dist-ai/components/checkbox-button.md +94 -0
- package/dist-ai/components/checkbox-group.json +236 -0
- package/dist-ai/components/checkbox-group.md +90 -0
- package/dist-ai/components/checkbox.json +278 -0
- package/dist-ai/components/checkbox.md +91 -0
- package/dist-ai/components/col.json +168 -0
- package/dist-ai/components/col.md +72 -0
- package/dist-ai/components/collapse-item.json +133 -0
- package/dist-ai/components/collapse-item.md +75 -0
- package/dist-ai/components/collapse-transition.json +75 -0
- package/dist-ai/components/collapse-transition.md +59 -0
- package/dist-ai/components/collapse.json +129 -0
- package/dist-ai/components/collapse.md +76 -0
- package/dist-ai/components/color-picker.json +280 -0
- package/dist-ai/components/color-picker.md +85 -0
- package/dist-ai/components/config-provider.json +222 -0
- package/dist-ai/components/config-provider.md +76 -0
- package/dist-ai/components/container.json +95 -0
- package/dist-ai/components/container.md +70 -0
- package/dist-ai/components/countdown.json +155 -0
- package/dist-ai/components/countdown.md +73 -0
- package/dist-ai/components/date-picker-panel.json +346 -0
- package/dist-ai/components/date-picker-panel.md +91 -0
- package/dist-ai/components/date-picker.json +574 -0
- package/dist-ai/components/date-picker.md +153 -0
- package/dist-ai/components/descriptions-item.json +175 -0
- package/dist-ai/components/descriptions-item.md +73 -0
- package/dist-ai/components/descriptions.json +171 -0
- package/dist-ai/components/descriptions.md +78 -0
- package/dist-ai/components/dialog.json +403 -0
- package/dist-ai/components/dialog.md +108 -0
- package/dist-ai/components/divider.json +102 -0
- package/dist-ai/components/divider.md +59 -0
- package/dist-ai/components/drawer.json +468 -0
- package/dist-ai/components/drawer.md +115 -0
- package/dist-ai/components/dropdown-item.json +156 -0
- package/dist-ai/components/dropdown-item.md +84 -0
- package/dist-ai/components/dropdown-menu.json +92 -0
- package/dist-ai/components/dropdown-menu.md +70 -0
- package/dist-ai/components/dropdown.json +374 -0
- package/dist-ai/components/dropdown.md +108 -0
- package/dist-ai/components/empty.json +116 -0
- package/dist-ai/components/empty.md +62 -0
- package/dist-ai/components/footer.json +86 -0
- package/dist-ai/components/footer.md +63 -0
- package/dist-ai/components/form-item.json +242 -0
- package/dist-ai/components/form-item.md +93 -0
- package/dist-ai/components/form.json +277 -0
- package/dist-ai/components/form.md +117 -0
- package/dist-ai/components/header.json +86 -0
- package/dist-ai/components/header.md +63 -0
- package/dist-ai/components/icon.json +95 -0
- package/dist-ai/components/icon.md +61 -0
- package/dist-ai/components/image-viewer.json +235 -0
- package/dist-ai/components/image-viewer.md +88 -0
- package/dist-ai/components/image.json +299 -0
- package/dist-ai/components/image.md +96 -0
- package/dist-ai/components/input-number.json +370 -0
- package/dist-ai/components/input-number.md +127 -0
- package/dist-ai/components/input.json +545 -0
- package/dist-ai/components/input.md +166 -0
- package/dist-ai/components/link.json +162 -0
- package/dist-ai/components/link.md +72 -0
- package/dist-ai/components/main.json +77 -0
- package/dist-ai/components/main.md +58 -0
- package/dist-ai/components/mention.json +598 -0
- package/dist-ai/components/mention.md +136 -0
- package/dist-ai/components/menu-item-group.json +101 -0
- package/dist-ai/components/menu-item-group.md +69 -0
- package/dist-ai/components/menu-item.json +131 -0
- package/dist-ai/components/menu-item.md +76 -0
- package/dist-ai/components/menu.json +314 -0
- package/dist-ai/components/menu.md +104 -0
- package/dist-ai/components/option-group.json +113 -0
- package/dist-ai/components/option-group.md +79 -0
- package/dist-ai/components/option.json +122 -0
- package/dist-ai/components/option.md +70 -0
- package/dist-ai/components/page-header.json +131 -0
- package/dist-ai/components/page-header.md +70 -0
- package/dist-ai/components/pagination.json +325 -0
- package/dist-ai/components/pagination.md +115 -0
- package/dist-ai/components/popconfirm.json +240 -0
- package/dist-ai/components/popconfirm.md +89 -0
- package/dist-ai/components/popover.json +351 -0
- package/dist-ai/components/popover.md +99 -0
- package/dist-ai/components/popper.json +93 -0
- package/dist-ai/components/popper.md +66 -0
- package/dist-ai/components/progress.json +219 -0
- package/dist-ai/components/progress.md +74 -0
- package/dist-ai/components/radio-button.json +142 -0
- package/dist-ai/components/radio-button.md +76 -0
- package/dist-ai/components/radio-group.json +219 -0
- package/dist-ai/components/radio-group.md +88 -0
- package/dist-ai/components/radio.json +177 -0
- package/dist-ai/components/radio.md +83 -0
- package/dist-ai/components/rate.json +286 -0
- package/dist-ai/components/rate.md +83 -0
- package/dist-ai/components/result.json +118 -0
- package/dist-ai/components/result.md +66 -0
- package/dist-ai/components/row.json +115 -0
- package/dist-ai/components/row.md +68 -0
- package/dist-ai/components/scrollbar.json +280 -0
- package/dist-ai/components/scrollbar.md +89 -0
- package/dist-ai/components/segmented.json +204 -0
- package/dist-ai/components/segmented.md +81 -0
- package/dist-ai/components/select-v2.json +729 -0
- package/dist-ai/components/select-v2.md +193 -0
- package/dist-ai/components/select.json +697 -0
- package/dist-ai/components/select.md +188 -0
- package/dist-ai/components/skeleton-item.json +80 -0
- package/dist-ai/components/skeleton-item.md +57 -0
- package/dist-ai/components/skeleton.json +134 -0
- package/dist-ai/components/skeleton.md +65 -0
- package/dist-ai/components/slider.json +326 -0
- package/dist-ai/components/slider.md +88 -0
- package/dist-ai/components/space.json +178 -0
- package/dist-ai/components/space.md +73 -0
- package/dist-ai/components/statistic.json +167 -0
- package/dist-ai/components/statistic.md +66 -0
- package/dist-ai/components/step.json +124 -0
- package/dist-ai/components/step.md +69 -0
- package/dist-ai/components/steps.json +157 -0
- package/dist-ai/components/steps.md +79 -0
- package/dist-ai/components/sub-menu.json +211 -0
- package/dist-ai/components/sub-menu.md +88 -0
- package/dist-ai/components/switch.json +292 -0
- package/dist-ai/components/switch.md +88 -0
- package/dist-ai/components/tab-pane.json +137 -0
- package/dist-ai/components/tab-pane.md +72 -0
- package/dist-ai/components/table-column.json +368 -0
- package/dist-ai/components/table-column.md +103 -0
- package/dist-ai/components/table-v2.json +486 -0
- package/dist-ai/components/table-v2.md +123 -0
- package/dist-ai/components/table.json +734 -0
- package/dist-ai/components/table.md +205 -0
- package/dist-ai/components/tabs.json +231 -0
- package/dist-ai/components/tabs.md +127 -0
- package/dist-ai/components/tag.json +205 -0
- package/dist-ai/components/tag.md +105 -0
- package/dist-ai/components/text.json +143 -0
- package/dist-ai/components/text.md +66 -0
- package/dist-ai/components/time-picker.json +555 -0
- package/dist-ai/components/time-picker.md +123 -0
- package/dist-ai/components/time-select.json +321 -0
- package/dist-ai/components/time-select.md +93 -0
- package/dist-ai/components/timeline-item.json +186 -0
- package/dist-ai/components/timeline-item.md +78 -0
- package/dist-ai/components/timeline.json +99 -0
- package/dist-ai/components/timeline.md +65 -0
- package/dist-ai/components/tooltip.json +599 -0
- package/dist-ai/components/tooltip.md +137 -0
- package/dist-ai/components/tour-step.json +219 -0
- package/dist-ai/components/tour-step.md +88 -0
- package/dist-ai/components/tour.json +258 -0
- package/dist-ai/components/tour.md +96 -0
- package/dist-ai/components/transfer.json +275 -0
- package/dist-ai/components/transfer.md +95 -0
- package/dist-ai/components/tree-select.json +945 -0
- package/dist-ai/components/tree-select.md +181 -0
- package/dist-ai/components/tree-v2.json +395 -0
- package/dist-ai/components/tree-v2.md +113 -0
- package/dist-ai/components/tree.json +485 -0
- package/dist-ai/components/tree.md +131 -0
- package/dist-ai/components/upload.json +382 -0
- package/dist-ai/components/upload.md +130 -0
- package/dist-ai/components/watermark.json +157 -0
- package/dist-ai/components/watermark.md +66 -0
- package/dist-ai/directives/click-outside.json +61 -0
- package/dist-ai/directives/click-outside.md +50 -0
- package/dist-ai/directives/infinite-scroll.json +83 -0
- package/dist-ai/directives/infinite-scroll.md +62 -0
- package/dist-ai/directives/loading.json +89 -0
- package/dist-ai/directives/loading.md +69 -0
- package/dist-ai/directives/mousewheel.json +54 -0
- package/dist-ai/directives/mousewheel.md +48 -0
- package/dist-ai/directives/repeat-click.json +68 -0
- package/dist-ai/directives/repeat-click.md +49 -0
- package/dist-ai/directives/trap-focus.json +46 -0
- package/dist-ai/directives/trap-focus.md +46 -0
- package/dist-ai/icons.json +1 -0
- package/dist-ai/index.json +1 -0
- package/dist-ai/llms.txt +170 -0
- package/dist-ai/manifest.json +26590 -0
- package/dist-ai/schema/manifest.schema.json +793 -0
- package/dist-ai/services/infinite-scroll.json +80 -0
- package/dist-ai/services/infinite-scroll.md +71 -0
- package/dist-ai/services/loading.json +108 -0
- package/dist-ai/services/loading.md +58 -0
- package/dist-ai/services/message-box.json +159 -0
- package/dist-ai/services/message-box.md +78 -0
- package/dist-ai/services/message.json +137 -0
- package/dist-ai/services/message.md +72 -0
- package/dist-ai/services/notification.json +136 -0
- package/dist-ai/services/notification.md +73 -0
- package/package.json +12 -2
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
# EpMention
|
|
2
|
+
|
|
3
|
+
`ep-mention` · form(表单) · `component:mention`
|
|
4
|
+
|
|
5
|
+
## 摘要
|
|
6
|
+
|
|
7
|
+
提及,表单数据录入控件
|
|
8
|
+
|
|
9
|
+
## 适用场景
|
|
10
|
+
|
|
11
|
+
- 适用:表单中收集或编辑提及数据
|
|
12
|
+
- 适用:与 EpForm、EpFormItem 组合完成校验
|
|
13
|
+
- 不适用:仅展示静态文本或只读数据时
|
|
14
|
+
|
|
15
|
+
## 关键词
|
|
16
|
+
|
|
17
|
+
- 中文:提及、表单
|
|
18
|
+
- English: mention, autocomplete, at, form
|
|
19
|
+
|
|
20
|
+
## 变体
|
|
21
|
+
|
|
22
|
+
- state: loading(通过布尔属性切换禁用、加载或选中状态)
|
|
23
|
+
|
|
24
|
+
## Props
|
|
25
|
+
|
|
26
|
+
- options (MentionOption[],默认 []):提及选项列表
|
|
27
|
+
- prefix (string | string[],默认 @):触发提及的前缀字符,长度必须为 1
|
|
28
|
+
- split (string,默认 见文档):分隔提及的字符,长度必须为 1
|
|
29
|
+
- filterOption (false | ((pattern, option) => boolean),默认 内置过滤):自定义过滤逻辑,传 false 时关闭过滤
|
|
30
|
+
- placement ('bottom' | 'top',默认 bottom):下拉面板位置
|
|
31
|
+
- showArrow (boolean):下拉面板是否显示箭头
|
|
32
|
+
- offset (number,默认 0):下拉面板偏移量
|
|
33
|
+
- whole (boolean):退格删除时是否整体删除提及内容
|
|
34
|
+
- checkIsWhole ((pattern: string, prefix: string) => boolean):退格删除时判断提及是否为整体的函数
|
|
35
|
+
- modelValue(别名 v-model) (string,默认 见文档):输入值
|
|
36
|
+
- loading (boolean):下拉面板是否处于加载中
|
|
37
|
+
- popperClass (string):下拉面板自定义类名
|
|
38
|
+
- popperStyle (string | object | array):下拉面板自定义样式
|
|
39
|
+
- popperOptions (Partial<Options>,默认 {}):popper.js 配置项
|
|
40
|
+
- props ({ value?: string; label?: string; disabled?: string },默认 { value: 'value', label: 'label', disabled: 'disabled' }):选项字段映射
|
|
41
|
+
- id (unknown)
|
|
42
|
+
- size (unknown)
|
|
43
|
+
- disabled (unknown,默认 见文档)
|
|
44
|
+
- modelModifiers (unknown,默认 见文档)
|
|
45
|
+
- maxlength (unknown)
|
|
46
|
+
- minlength (unknown)
|
|
47
|
+
- type (unknown,默认 见文档)
|
|
48
|
+
- resize (unknown)
|
|
49
|
+
- autosize (unknown)
|
|
50
|
+
- autocomplete (unknown,默认 见文档)
|
|
51
|
+
- formatter (unknown)
|
|
52
|
+
- parser (unknown)
|
|
53
|
+
- placeholder (unknown)
|
|
54
|
+
- form (unknown)
|
|
55
|
+
- readonly (unknown)
|
|
56
|
+
- clearable (unknown)
|
|
57
|
+
- clearIcon (unknown,默认 见文档)
|
|
58
|
+
- showPassword (unknown)
|
|
59
|
+
- showWordLimit (unknown)
|
|
60
|
+
- wordLimitPosition (unknown,默认 见文档)
|
|
61
|
+
- suffixIcon (unknown)
|
|
62
|
+
- prefixIcon (unknown)
|
|
63
|
+
- containerRole (unknown)
|
|
64
|
+
- tabindex (unknown,默认 见文档)
|
|
65
|
+
- validateEvent (unknown,默认 见文档)
|
|
66
|
+
- inputStyle (unknown,默认 见文档)
|
|
67
|
+
- autofocus (unknown)
|
|
68
|
+
- rows (unknown,默认 见文档)
|
|
69
|
+
- ariaLabel (unknown)
|
|
70
|
+
- inputmode (unknown)
|
|
71
|
+
- name (unknown)
|
|
72
|
+
- countGraphemes (unknown)
|
|
73
|
+
- floatLabel (unknown)
|
|
74
|
+
|
|
75
|
+
## Events
|
|
76
|
+
|
|
77
|
+
- update:modelValue((value: string)):输入值变化时触发
|
|
78
|
+
- wholeRemove((pattern: string, prefix: string)):整体删除提及内容时触发
|
|
79
|
+
- input((value: string)):输入时触发
|
|
80
|
+
- search((pattern: string, prefix: string)):搜索提及内容时触发
|
|
81
|
+
- select((option: MentionOption, prefix: string)):选中选项时触发
|
|
82
|
+
- focus((evt: FocusEvent)):聚焦时触发
|
|
83
|
+
- blur((evt: FocusEvent)):失焦时触发
|
|
84
|
+
|
|
85
|
+
## Slots
|
|
86
|
+
|
|
87
|
+
- default:自定义选项内容,参数为 `{ item, index }`
|
|
88
|
+
- header:下拉面板头部
|
|
89
|
+
- footer:下拉面板底部
|
|
90
|
+
- loading:自定义加载中内容
|
|
91
|
+
- prefix:输入框前缀内容
|
|
92
|
+
- suffix:输入框后缀内容
|
|
93
|
+
- prepend:输入框前置内容
|
|
94
|
+
- append:输入框后置内容
|
|
95
|
+
|
|
96
|
+
## Exposes
|
|
97
|
+
|
|
98
|
+
- input(InputInstance | undefined):内部 ep-input 实例
|
|
99
|
+
- tooltip(TooltipInstance | undefined):内部 Tooltip 实例
|
|
100
|
+
- dropdownVisible(boolean):下拉面板是否可见
|
|
101
|
+
|
|
102
|
+
## 视觉提示
|
|
103
|
+
|
|
104
|
+
- 形状:矩形输入框
|
|
105
|
+
- 密度:中等
|
|
106
|
+
- 插槽内容:default:自定义选项内容,参数为 `{ item, index }`;header:下拉面板头部;footer:下拉面板底部
|
|
107
|
+
- CSS 变量:--el-border-color、--el-border-radius-base、--el-color-primary、--el-font-size-base
|
|
108
|
+
|
|
109
|
+
## 示例
|
|
110
|
+
|
|
111
|
+
### 提及输入
|
|
112
|
+
|
|
113
|
+
```vue
|
|
114
|
+
<script setup lang="ts">
|
|
115
|
+
import { ref } from 'vue'
|
|
116
|
+
import { EpMention } from 'ep-craft'
|
|
117
|
+
|
|
118
|
+
const value = ref('')
|
|
119
|
+
const options = [
|
|
120
|
+
{ value: 'zhangsan', label: '张三' },
|
|
121
|
+
{ value: 'lisi', label: '李四' },
|
|
122
|
+
]
|
|
123
|
+
</script>
|
|
124
|
+
|
|
125
|
+
<template>
|
|
126
|
+
<ep-mention v-model="value" :options="options" placeholder="输入 @ 提及成员" />
|
|
127
|
+
</template>
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
## 相关条目
|
|
131
|
+
|
|
132
|
+
- EpInput
|
|
133
|
+
|
|
134
|
+
---
|
|
135
|
+
|
|
136
|
+
ep-craft 0.2.0
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
{
|
|
2
|
+
"entry": {
|
|
3
|
+
"category": "navigation",
|
|
4
|
+
"events": [],
|
|
5
|
+
"exampleOmittedReason": null,
|
|
6
|
+
"examples": [
|
|
7
|
+
{
|
|
8
|
+
"code": "<script setup lang=\"ts\">\nimport { EpMenu, EpMenuItem, EpMenuItemGroup } from 'ep-craft'\n</script>\n\n<template>\n <ep-menu default-active=\"profile\">\n <ep-menu-item-group title=\"账号\">\n <ep-menu-item index=\"profile\">个人资料</ep-menu-item>\n <ep-menu-item index=\"security\">安全设置</ep-menu-item>\n </ep-menu-item-group>\n </ep-menu>\n</template>",
|
|
9
|
+
"id": "menu-item-group-1",
|
|
10
|
+
"language": "vue",
|
|
11
|
+
"title": "菜单分组"
|
|
12
|
+
}
|
|
13
|
+
],
|
|
14
|
+
"exposes": [],
|
|
15
|
+
"hot": false,
|
|
16
|
+
"id": "component:menu-item-group",
|
|
17
|
+
"keywords": {
|
|
18
|
+
"en": [
|
|
19
|
+
"menu-item-group",
|
|
20
|
+
"menu",
|
|
21
|
+
"item",
|
|
22
|
+
"group",
|
|
23
|
+
"navigation"
|
|
24
|
+
],
|
|
25
|
+
"zh": [
|
|
26
|
+
"菜单分组",
|
|
27
|
+
"导航"
|
|
28
|
+
]
|
|
29
|
+
},
|
|
30
|
+
"kind": "component",
|
|
31
|
+
"name": "EpMenuItemGroup",
|
|
32
|
+
"nonUseCases": [
|
|
33
|
+
"单步无层级的简单跳转时"
|
|
34
|
+
],
|
|
35
|
+
"props": [
|
|
36
|
+
{
|
|
37
|
+
"alias": null,
|
|
38
|
+
"defaultText": null,
|
|
39
|
+
"description": "分组标题",
|
|
40
|
+
"hasDefault": false,
|
|
41
|
+
"name": "title",
|
|
42
|
+
"required": false,
|
|
43
|
+
"type": "string"
|
|
44
|
+
}
|
|
45
|
+
],
|
|
46
|
+
"related": [
|
|
47
|
+
"EpMenu",
|
|
48
|
+
"EpSubMenu",
|
|
49
|
+
"EpMenuItem"
|
|
50
|
+
],
|
|
51
|
+
"relations": {
|
|
52
|
+
"children": [
|
|
53
|
+
"EpMenuItem"
|
|
54
|
+
],
|
|
55
|
+
"combos": [
|
|
56
|
+
"EpMenu + EpMenuItemGroup",
|
|
57
|
+
"EpSubMenu + EpMenuItemGroup",
|
|
58
|
+
"EpMenuItemGroup + EpMenuItem"
|
|
59
|
+
],
|
|
60
|
+
"parents": [
|
|
61
|
+
"EpMenu",
|
|
62
|
+
"EpSubMenu"
|
|
63
|
+
],
|
|
64
|
+
"requiredChildren": []
|
|
65
|
+
},
|
|
66
|
+
"slots": [
|
|
67
|
+
{
|
|
68
|
+
"description": "分组内容",
|
|
69
|
+
"name": "default"
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
"description": "自定义分组标题",
|
|
73
|
+
"name": "title"
|
|
74
|
+
}
|
|
75
|
+
],
|
|
76
|
+
"slug": "menu-item-group",
|
|
77
|
+
"summary": "菜单分组,页面导航与定位",
|
|
78
|
+
"tag": "ep-menu-item-group",
|
|
79
|
+
"useCases": [
|
|
80
|
+
"在页面或模块间使用菜单分组导航",
|
|
81
|
+
"指示当前位置与层级"
|
|
82
|
+
],
|
|
83
|
+
"variants": [],
|
|
84
|
+
"visual": {
|
|
85
|
+
"cssVars": [
|
|
86
|
+
"--el-color-primary",
|
|
87
|
+
"--el-text-color-regular",
|
|
88
|
+
"--el-bg-color"
|
|
89
|
+
],
|
|
90
|
+
"density": "中等",
|
|
91
|
+
"shape": "条状或列表",
|
|
92
|
+
"slotContent": [
|
|
93
|
+
"default:分组内容",
|
|
94
|
+
"title:自定义分组标题"
|
|
95
|
+
]
|
|
96
|
+
}
|
|
97
|
+
},
|
|
98
|
+
"generatedAt": "2026-11-03T03:09:12.050Z",
|
|
99
|
+
"libraryVersion": "0.2.0",
|
|
100
|
+
"schemaVersion": 1
|
|
101
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
# EpMenuItemGroup
|
|
2
|
+
|
|
3
|
+
`ep-menu-item-group` · navigation(导航) · `component:menu-item-group`
|
|
4
|
+
|
|
5
|
+
## 摘要
|
|
6
|
+
|
|
7
|
+
菜单分组,页面导航与定位
|
|
8
|
+
|
|
9
|
+
## 适用场景
|
|
10
|
+
|
|
11
|
+
- 适用:在页面或模块间使用菜单分组导航
|
|
12
|
+
- 适用:指示当前位置与层级
|
|
13
|
+
- 不适用:单步无层级的简单跳转时
|
|
14
|
+
|
|
15
|
+
## 关键词
|
|
16
|
+
|
|
17
|
+
- 中文:菜单分组、导航
|
|
18
|
+
- English: menu-item-group, menu, item, group, navigation
|
|
19
|
+
|
|
20
|
+
## Props
|
|
21
|
+
|
|
22
|
+
- title (string):分组标题
|
|
23
|
+
|
|
24
|
+
## Slots
|
|
25
|
+
|
|
26
|
+
- default:分组内容
|
|
27
|
+
- title:自定义分组标题
|
|
28
|
+
|
|
29
|
+
## 关系
|
|
30
|
+
|
|
31
|
+
- 父级:EpMenu、EpSubMenu
|
|
32
|
+
- 子级:EpMenuItem
|
|
33
|
+
- 常用组合:EpMenu + EpMenuItemGroup、EpSubMenu + EpMenuItemGroup、EpMenuItemGroup + EpMenuItem
|
|
34
|
+
|
|
35
|
+
## 视觉提示
|
|
36
|
+
|
|
37
|
+
- 形状:条状或列表
|
|
38
|
+
- 密度:中等
|
|
39
|
+
- 插槽内容:default:分组内容;title:自定义分组标题
|
|
40
|
+
- CSS 变量:--el-color-primary、--el-text-color-regular、--el-bg-color
|
|
41
|
+
|
|
42
|
+
## 示例
|
|
43
|
+
|
|
44
|
+
### 菜单分组
|
|
45
|
+
|
|
46
|
+
```vue
|
|
47
|
+
<script setup lang="ts">
|
|
48
|
+
import { EpMenu, EpMenuItem, EpMenuItemGroup } from 'ep-craft'
|
|
49
|
+
</script>
|
|
50
|
+
|
|
51
|
+
<template>
|
|
52
|
+
<ep-menu default-active="profile">
|
|
53
|
+
<ep-menu-item-group title="账号">
|
|
54
|
+
<ep-menu-item index="profile">个人资料</ep-menu-item>
|
|
55
|
+
<ep-menu-item index="security">安全设置</ep-menu-item>
|
|
56
|
+
</ep-menu-item-group>
|
|
57
|
+
</ep-menu>
|
|
58
|
+
</template>
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## 相关条目
|
|
62
|
+
|
|
63
|
+
- EpMenu
|
|
64
|
+
- EpSubMenu
|
|
65
|
+
- EpMenuItem
|
|
66
|
+
|
|
67
|
+
---
|
|
68
|
+
|
|
69
|
+
ep-craft 0.2.0
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
{
|
|
2
|
+
"entry": {
|
|
3
|
+
"category": "navigation",
|
|
4
|
+
"events": [
|
|
5
|
+
{
|
|
6
|
+
"description": "点击菜单项时触发",
|
|
7
|
+
"name": "click",
|
|
8
|
+
"params": "(item: { index: string; indexPath: string[] })"
|
|
9
|
+
}
|
|
10
|
+
],
|
|
11
|
+
"exampleOmittedReason": null,
|
|
12
|
+
"examples": [
|
|
13
|
+
{
|
|
14
|
+
"code": "<script setup lang=\"ts\">\nimport { EpMenu, EpMenuItem } from 'ep-craft'\n</script>\n\n<template>\n <ep-menu default-active=\"1\">\n <ep-menu-item index=\"1\">选项一</ep-menu-item>\n <ep-menu-item index=\"2\" disabled>选项二(禁用)</ep-menu-item>\n </ep-menu>\n</template>",
|
|
15
|
+
"id": "menu-item-1",
|
|
16
|
+
"language": "vue",
|
|
17
|
+
"title": "菜单项"
|
|
18
|
+
}
|
|
19
|
+
],
|
|
20
|
+
"exposes": [],
|
|
21
|
+
"hot": false,
|
|
22
|
+
"id": "component:menu-item",
|
|
23
|
+
"keywords": {
|
|
24
|
+
"en": [
|
|
25
|
+
"menu-item",
|
|
26
|
+
"menu",
|
|
27
|
+
"item",
|
|
28
|
+
"navigation"
|
|
29
|
+
],
|
|
30
|
+
"zh": [
|
|
31
|
+
"菜单项",
|
|
32
|
+
"导航"
|
|
33
|
+
]
|
|
34
|
+
},
|
|
35
|
+
"kind": "component",
|
|
36
|
+
"name": "EpMenuItem",
|
|
37
|
+
"nonUseCases": [
|
|
38
|
+
"单步无层级的简单跳转时"
|
|
39
|
+
],
|
|
40
|
+
"props": [
|
|
41
|
+
{
|
|
42
|
+
"alias": null,
|
|
43
|
+
"defaultText": null,
|
|
44
|
+
"description": "唯一标识(必填)",
|
|
45
|
+
"hasDefault": false,
|
|
46
|
+
"name": "index",
|
|
47
|
+
"required": true,
|
|
48
|
+
"type": "string"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"alias": null,
|
|
52
|
+
"defaultText": null,
|
|
53
|
+
"description": "Vue Router 路由对象",
|
|
54
|
+
"hasDefault": false,
|
|
55
|
+
"name": "route",
|
|
56
|
+
"required": false,
|
|
57
|
+
"type": "string | object"
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"alias": null,
|
|
61
|
+
"defaultText": "false",
|
|
62
|
+
"description": "是否禁用",
|
|
63
|
+
"hasDefault": false,
|
|
64
|
+
"name": "disabled",
|
|
65
|
+
"required": false,
|
|
66
|
+
"type": "boolean"
|
|
67
|
+
}
|
|
68
|
+
],
|
|
69
|
+
"related": [
|
|
70
|
+
"EpMenu",
|
|
71
|
+
"EpSubMenu",
|
|
72
|
+
"EpMenuItemGroup"
|
|
73
|
+
],
|
|
74
|
+
"relations": {
|
|
75
|
+
"children": [],
|
|
76
|
+
"combos": [
|
|
77
|
+
"EpMenu + EpMenuItem",
|
|
78
|
+
"EpSubMenu + EpMenuItem",
|
|
79
|
+
"EpMenuItemGroup + EpMenuItem"
|
|
80
|
+
],
|
|
81
|
+
"parents": [
|
|
82
|
+
"EpMenu",
|
|
83
|
+
"EpSubMenu",
|
|
84
|
+
"EpMenuItemGroup"
|
|
85
|
+
],
|
|
86
|
+
"requiredChildren": []
|
|
87
|
+
},
|
|
88
|
+
"slots": [
|
|
89
|
+
{
|
|
90
|
+
"description": "菜单项内容",
|
|
91
|
+
"name": "default"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"description": "自定义菜单项标题",
|
|
95
|
+
"name": "title"
|
|
96
|
+
}
|
|
97
|
+
],
|
|
98
|
+
"slug": "menu-item",
|
|
99
|
+
"summary": "菜单项,页面导航与定位",
|
|
100
|
+
"tag": "ep-menu-item",
|
|
101
|
+
"useCases": [
|
|
102
|
+
"在页面或模块间使用菜单项导航",
|
|
103
|
+
"指示当前位置与层级"
|
|
104
|
+
],
|
|
105
|
+
"variants": [
|
|
106
|
+
{
|
|
107
|
+
"dimension": "state",
|
|
108
|
+
"values": [
|
|
109
|
+
"disabled"
|
|
110
|
+
],
|
|
111
|
+
"when": "通过布尔属性切换禁用、加载或选中状态"
|
|
112
|
+
}
|
|
113
|
+
],
|
|
114
|
+
"visual": {
|
|
115
|
+
"cssVars": [
|
|
116
|
+
"--el-color-primary",
|
|
117
|
+
"--el-text-color-regular",
|
|
118
|
+
"--el-bg-color"
|
|
119
|
+
],
|
|
120
|
+
"density": "中等",
|
|
121
|
+
"shape": "条状或列表",
|
|
122
|
+
"slotContent": [
|
|
123
|
+
"default:菜单项内容",
|
|
124
|
+
"title:自定义菜单项标题"
|
|
125
|
+
]
|
|
126
|
+
}
|
|
127
|
+
},
|
|
128
|
+
"generatedAt": "2026-11-03T03:09:12.050Z",
|
|
129
|
+
"libraryVersion": "0.2.0",
|
|
130
|
+
"schemaVersion": 1
|
|
131
|
+
}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# EpMenuItem
|
|
2
|
+
|
|
3
|
+
`ep-menu-item` · navigation(导航) · `component:menu-item`
|
|
4
|
+
|
|
5
|
+
## 摘要
|
|
6
|
+
|
|
7
|
+
菜单项,页面导航与定位
|
|
8
|
+
|
|
9
|
+
## 适用场景
|
|
10
|
+
|
|
11
|
+
- 适用:在页面或模块间使用菜单项导航
|
|
12
|
+
- 适用:指示当前位置与层级
|
|
13
|
+
- 不适用:单步无层级的简单跳转时
|
|
14
|
+
|
|
15
|
+
## 关键词
|
|
16
|
+
|
|
17
|
+
- 中文:菜单项、导航
|
|
18
|
+
- English: menu-item, menu, item, navigation
|
|
19
|
+
|
|
20
|
+
## 变体
|
|
21
|
+
|
|
22
|
+
- state: disabled(通过布尔属性切换禁用、加载或选中状态)
|
|
23
|
+
|
|
24
|
+
## Props
|
|
25
|
+
|
|
26
|
+
- index (string,必填):唯一标识(必填)
|
|
27
|
+
- route (string | object):Vue Router 路由对象
|
|
28
|
+
- disabled (boolean):是否禁用
|
|
29
|
+
|
|
30
|
+
## Events
|
|
31
|
+
|
|
32
|
+
- click((item: { index: string; indexPath: string[] })):点击菜单项时触发
|
|
33
|
+
|
|
34
|
+
## Slots
|
|
35
|
+
|
|
36
|
+
- default:菜单项内容
|
|
37
|
+
- title:自定义菜单项标题
|
|
38
|
+
|
|
39
|
+
## 关系
|
|
40
|
+
|
|
41
|
+
- 父级:EpMenu、EpSubMenu、EpMenuItemGroup
|
|
42
|
+
- 常用组合:EpMenu + EpMenuItem、EpSubMenu + EpMenuItem、EpMenuItemGroup + EpMenuItem
|
|
43
|
+
|
|
44
|
+
## 视觉提示
|
|
45
|
+
|
|
46
|
+
- 形状:条状或列表
|
|
47
|
+
- 密度:中等
|
|
48
|
+
- 插槽内容:default:菜单项内容;title:自定义菜单项标题
|
|
49
|
+
- CSS 变量:--el-color-primary、--el-text-color-regular、--el-bg-color
|
|
50
|
+
|
|
51
|
+
## 示例
|
|
52
|
+
|
|
53
|
+
### 菜单项
|
|
54
|
+
|
|
55
|
+
```vue
|
|
56
|
+
<script setup lang="ts">
|
|
57
|
+
import { EpMenu, EpMenuItem } from 'ep-craft'
|
|
58
|
+
</script>
|
|
59
|
+
|
|
60
|
+
<template>
|
|
61
|
+
<ep-menu default-active="1">
|
|
62
|
+
<ep-menu-item index="1">选项一</ep-menu-item>
|
|
63
|
+
<ep-menu-item index="2" disabled>选项二(禁用)</ep-menu-item>
|
|
64
|
+
</ep-menu>
|
|
65
|
+
</template>
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## 相关条目
|
|
69
|
+
|
|
70
|
+
- EpMenu
|
|
71
|
+
- EpSubMenu
|
|
72
|
+
- EpMenuItemGroup
|
|
73
|
+
|
|
74
|
+
---
|
|
75
|
+
|
|
76
|
+
ep-craft 0.2.0
|