@robot-admin/naive-ui-components 0.31.5 → 0.33.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/CHANGELOG.md +18 -0
- package/README.md +11 -5
- package/README_EN.md +11 -5
- package/dist/C_AutoComplete.cjs +1 -0
- package/dist/C_AutoComplete.css +36 -0
- package/dist/C_AutoComplete.d.cts +4 -0
- package/dist/C_AutoComplete.d.ts +4 -0
- package/dist/C_AutoComplete.js +1 -0
- package/dist/C_AutoComplete2.cjs +1 -0
- package/dist/C_AutoComplete2.js +1 -0
- package/dist/C_AvatarGroup.d.cts +1 -1
- package/dist/C_AvatarGroup.d.ts +1 -1
- package/dist/C_Barcode.d.cts +1 -1
- package/dist/C_Barcode.d.ts +1 -1
- package/dist/C_BatchResult.d.cts +1 -1
- package/dist/C_BatchResult.d.ts +1 -1
- package/dist/C_Breadcrumb.d.cts +2 -2
- package/dist/C_Breadcrumb.d.ts +1 -1
- package/dist/C_Cascade.d.cts +1 -1
- package/dist/C_Cascade.d.ts +1 -1
- package/dist/C_Chat.d.cts +1 -1
- package/dist/C_Chat.d.ts +1 -1
- package/dist/C_City.d.cts +1 -1
- package/dist/C_City.d.ts +1 -1
- package/dist/C_Code.d.cts +1 -1
- package/dist/C_Code.d.ts +1 -1
- package/dist/C_ContextMenu.d.cts +1 -1
- package/dist/C_ContextMenu.d.ts +1 -1
- package/dist/C_DataPicker.css +235 -31
- package/dist/C_DataPicker.d.cts +2 -2
- package/dist/C_DataPicker.d.ts +2 -2
- package/dist/C_Date.d.cts +1 -1
- package/dist/C_Date.d.ts +1 -1
- package/dist/C_Density.d.cts +1 -1
- package/dist/C_Density.d.ts +1 -1
- package/dist/C_Editor.d.cts +1 -1
- package/dist/C_Editor.d.ts +1 -1
- package/dist/C_ErrorSummary.d.cts +1 -1
- package/dist/C_ErrorSummary.d.ts +1 -1
- package/dist/C_Form.base.css +68 -1
- package/dist/C_Form.cjs +1 -1
- package/dist/C_Form.css +68 -1
- package/dist/C_Form.d.cts +3 -3
- package/dist/C_Form.d.ts +5 -3
- package/dist/C_Form.js +1 -1
- package/dist/C_FormModal.cjs +1 -1
- package/dist/C_FormModal.d.cts +1 -1
- package/dist/C_FormModal.d.ts +3 -1
- package/dist/C_FormModal.js +1 -1
- package/dist/C_FormModal2.cjs +1 -1
- package/dist/C_FormModal2.js +1 -1
- package/dist/C_FormSearch.css +160 -72
- package/dist/C_FormSearch.d.cts +3 -3
- package/dist/C_FormSearch.d.ts +3 -3
- package/dist/C_GlobalSearch2.cjs +1 -1
- package/dist/C_GlobalSearch2.js +1 -1
- package/dist/C_Guide.d.cts +1 -1
- package/dist/C_Guide.d.ts +1 -1
- package/dist/C_Icon.d.cts +1 -1
- package/dist/C_Icon.d.ts +1 -1
- package/dist/C_Language.d.cts +1 -1
- package/dist/C_Language.d.ts +1 -1
- package/dist/C_Loading.d.cts +1 -1
- package/dist/C_Loading.d.ts +1 -1
- package/dist/C_Login.d.cts +1 -1
- package/dist/C_Login.d.ts +1 -1
- package/dist/C_Markdown.d.cts +1 -1
- package/dist/C_Markdown.d.ts +1 -1
- package/dist/C_Menu.d.cts +2 -2
- package/dist/C_Menu.d.ts +1 -1
- package/dist/C_OrgChart.d.cts +1 -1
- package/dist/C_OrgChart.d.ts +1 -1
- package/dist/C_Progress.d.cts +1 -1
- package/dist/C_Progress.d.ts +1 -1
- package/dist/C_SectionNav.d.cts +1 -1
- package/dist/C_SectionNav.d.ts +1 -1
- package/dist/C_Select.css +32 -1
- package/dist/C_Select.d.cts +4 -2
- package/dist/C_Select.d.ts +4 -2
- package/dist/C_Select2.cjs +1 -1
- package/dist/C_Select2.js +1 -1
- package/dist/C_Skeleton.d.cts +1 -1
- package/dist/C_Skeleton.d.ts +1 -1
- package/dist/C_Steps.d.cts +1 -1
- package/dist/C_Steps.d.ts +1 -1
- package/dist/C_Table.base.css +214 -147
- package/dist/C_Table.cjs +1 -1
- package/dist/C_Table.css +146 -146
- package/dist/C_Table.d.cts +3 -3
- package/dist/C_Table.d.ts +13 -10
- package/dist/C_Table.js +1 -1
- package/dist/C_Table2.cjs +4 -3
- package/dist/C_Table2.js +4 -3
- package/dist/C_TagsView.css +51 -51
- package/dist/C_TagsView.d.cts +2 -2
- package/dist/C_TagsView.d.ts +1 -1
- package/dist/C_TagsView2.cjs +1 -1
- package/dist/C_TagsView2.js +1 -1
- package/dist/C_Theme.d.cts +1 -1
- package/dist/C_Theme.d.ts +1 -1
- package/dist/C_Timeline.d.cts +1 -1
- package/dist/C_Timeline.d.ts +1 -1
- package/dist/C_Transfer.d.cts +1 -1
- package/dist/C_Transfer.d.ts +1 -1
- package/dist/C_Tree.cjs +1 -1
- package/dist/C_Tree.css +60 -23
- package/dist/C_Tree.d.cts +2 -2
- package/dist/C_Tree.d.ts +12 -9
- package/dist/C_Tree.js +1 -1
- package/dist/C_Tree2.cjs +1 -1
- package/dist/C_Tree2.js +1 -1
- package/dist/OptionStatus.cjs +1 -0
- package/dist/OptionStatus.js +1 -0
- package/dist/SearchFieldSettings.cjs +1 -0
- package/dist/SearchFieldSettings.js +1 -0
- package/dist/constants4.d.cts +9 -9
- package/dist/constants4.d.ts +9 -9
- package/dist/constants5.d.cts +2 -2
- package/dist/constants5.d.ts +2 -2
- package/dist/data.d.cts +2 -1
- package/dist/data.d.ts +2 -1
- package/dist/data2.d.cts +7 -7
- package/dist/data2.d.ts +7 -7
- package/dist/dateRange.d.cts +52 -7
- package/dist/dateRange.d.ts +52 -7
- package/dist/editors.cjs +1 -0
- package/dist/{useTableQuery.d.cts → editors.d.cts} +120 -13
- package/dist/{useTableQuery.d.ts → editors.d.ts} +120 -13
- package/dist/editors.js +1 -0
- package/dist/fieldRenderers.cjs +1 -0
- package/dist/fieldRenderers.js +1 -0
- package/dist/formField.cjs +1 -1
- package/dist/formField.d.cts +79 -29
- package/dist/formField.d.ts +79 -29
- package/dist/formField.js +1 -1
- package/dist/helpers.cjs +1 -1
- package/dist/helpers.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +63 -59
- package/dist/index.d.ts +63 -58
- package/dist/index.js +1 -1
- package/dist/index.vue.d.cts +5 -5
- package/dist/index.vue.d.ts +5 -5
- package/dist/index10.vue.d.cts +27 -35
- package/dist/index10.vue.d.ts +37 -80
- package/dist/index11.vue.d.cts +37 -80
- package/dist/index11.vue.d.ts +83 -16
- package/dist/index12.vue.d.cts +83 -16
- package/dist/index12.vue.d.ts +16 -59
- package/dist/index13.vue.d.cts +16 -59
- package/dist/index13.vue.d.ts +57 -17
- package/dist/index14.vue.d.cts +57 -17
- package/dist/index14.vue.d.ts +18 -55
- package/dist/index15.vue.d.cts +18 -55
- package/dist/index15.vue.d.ts +53 -124
- package/dist/index16.vue.d.cts +53 -124
- package/dist/index16.vue.d.ts +123 -51
- package/dist/index17.vue.d.cts +123 -51
- package/dist/index17.vue.d.ts +52 -25
- package/dist/index18.vue.d.cts +52 -25
- package/dist/index18.vue.d.ts +25 -12
- package/dist/index19.vue.d.cts +25 -12
- package/dist/index19.vue.d.ts +13 -129
- package/dist/index2.vue.d.cts +26 -82
- package/dist/index2.vue.d.ts +26 -82
- package/dist/index20.vue.d.cts +13 -129
- package/dist/index20.vue.d.ts +129 -76
- package/dist/index21.vue.d.cts +129 -76
- package/dist/index21.vue.d.ts +78 -72
- package/dist/index22.vue.d.cts +75 -97
- package/dist/index22.vue.d.ts +68 -96
- package/dist/index23.vue.d.cts +91 -40
- package/dist/index23.vue.d.ts +91 -40
- package/dist/index24.vue.d.cts +49 -23
- package/dist/index24.vue.d.ts +49 -23
- package/dist/index25.vue.d.cts +19 -46
- package/dist/index25.vue.d.ts +19 -46
- package/dist/index26.vue.d.cts +25 -98
- package/dist/index26.vue.d.ts +25 -98
- package/dist/index27.vue.d.cts +95 -37
- package/dist/index27.vue.d.ts +95 -37
- package/dist/index28.vue.d.cts +34 -8
- package/dist/index28.vue.d.ts +34 -8
- package/dist/index29.vue.d.cts +9 -86
- package/dist/index29.vue.d.ts +9 -86
- package/dist/index3.vue.d.cts +80 -30
- package/dist/index3.vue.d.ts +80 -30
- package/dist/index30.vue.d.cts +85 -99
- package/dist/index30.vue.d.ts +85 -99
- package/dist/index31.vue.d.cts +94 -63
- package/dist/index31.vue.d.ts +94 -63
- package/dist/index32.vue.d.cts +79 -0
- package/dist/index32.vue.d.ts +79 -0
- package/dist/index4.vue.d.cts +30 -19
- package/dist/index4.vue.d.ts +30 -19
- package/dist/index5.vue.d.cts +19 -128
- package/dist/index5.vue.d.ts +17 -34
- package/dist/index6.vue.d.cts +127 -35
- package/dist/index6.vue.d.ts +30 -22
- package/dist/index7.vue.d.cts +30 -22
- package/dist/index7.vue.d.ts +25 -118
- package/dist/index8.vue.d.cts +25 -118
- package/dist/index8.vue.d.ts +112 -21
- package/dist/index9.vue.d.cts +112 -21
- package/dist/index9.vue.d.ts +27 -35
- package/dist/mapUtils.d.cts +3 -3
- package/dist/mapUtils.d.ts +3 -3
- package/dist/optionSource.d.cts +30 -0
- package/dist/optionSource.d.ts +30 -0
- package/dist/public.d.ts +2 -0
- package/dist/resolver.cjs +1 -1
- package/dist/resolver.d.cts +1 -1
- package/dist/resolver.d.ts +1 -1
- package/dist/resolver.js +1 -1
- package/dist/selectPresentation.cjs +1 -1
- package/dist/selectPresentation.js +1 -1
- package/dist/serializeSearch.cjs +1 -1
- package/dist/serializeSearch.js +1 -1
- package/dist/sourceControls.cjs +1 -0
- package/dist/sourceControls.js +1 -0
- package/dist/style.css +513 -324
- package/dist/types2.d.cts +29 -103
- package/dist/types2.d.ts +30 -55
- package/dist/types3.d.cts +106 -55
- package/dist/types3.d.ts +60 -0
- package/dist/types4.d.cts +60 -0
- package/dist/types4.d.ts +50 -0
- package/dist/types5.d.cts +50 -0
- package/dist/useCalendarEvents.d.cts +1 -1
- package/dist/useCalendarEvents.d.ts +1 -1
- package/dist/useCollapsePanel.d.cts +3 -3
- package/dist/useCollapsePanel.d.ts +3 -3
- package/dist/useComponentLocale.cjs +1 -1
- package/dist/useComponentLocale.js +1 -1
- package/dist/useCropperCore.d.cts +9 -9
- package/dist/useCropperCore.d.ts +9 -9
- package/dist/useDataResource.cjs +1 -1
- package/dist/useDataResource.js +1 -1
- package/dist/useDraggableLayout.d.cts +2 -2
- package/dist/useDraggableLayout.d.ts +2 -2
- package/dist/useDynamicFormState.d.cts +17 -3
- package/dist/useDynamicFormState.d.ts +17 -3
- package/dist/useEdgeInteraction.d.cts +2 -2
- package/dist/useEdgeInteraction.d.ts +2 -2
- package/dist/useFormConfig.d.cts +5 -2
- package/dist/useFormConfig.d.ts +5 -2
- package/dist/useFormRenderer.d.cts +1 -1
- package/dist/useFormRenderer.d.ts +1 -1
- package/dist/useFullscreen.d.cts +2 -2
- package/dist/useFullscreen.d.ts +2 -2
- package/dist/useGlobalSearch.d.cts +8 -0
- package/dist/useGlobalSearch.d.ts +8 -0
- package/dist/useInfiniteScroll.d.cts +2 -2
- package/dist/useInfiniteScroll.d.ts +2 -2
- package/dist/useQRCode.d.cts +3 -3
- package/dist/useQRCode.d.ts +3 -3
- package/dist/useSignatureHistory.d.cts +4 -4
- package/dist/useSignatureHistory.d.ts +4 -4
- package/dist/useSplitResize.d.cts +7 -7
- package/dist/useSplitResize.d.ts +7 -7
- package/dist/useWorkflowValidation.d.cts +4 -4
- package/dist/useWorkflowValidation.d.ts +4 -4
- package/dist/verification.d.cts +6 -6
- package/dist/verification.d.ts +6 -6
- package/docs/architecture.md +3 -1
- package/docs/components.en.md +2 -1
- package/docs/components.md +2 -1
- package/docs/engineering.en.md +11 -1
- package/docs/engineering.md +11 -1
- package/docs/guides/component-contracts.md +72 -0
- package/docs/guides/data-picker.md +37 -1
- package/docs/guides/remote-options.md +117 -0
- package/docs/guides/search-workflows.md +162 -2
- package/docs/guides/table-editing.md +79 -0
- package/docs/guides/tree.en.md +41 -0
- package/docs/guides/tree.md +80 -1
- package/docs/search-selection-coverage.md +59 -0
- package/docs/wl-ui-produce-coverage.md +2 -0
- package/package.json +6 -3
- package/dist/helpers2.cjs +0 -1
- package/dist/helpers2.js +0 -1
- package/dist/temporalField.cjs +0 -1
- package/dist/temporalField.js +0 -1
- package/dist/useTableQuery.cjs +0 -1
- package/dist/useTableQuery.js +0 -1
package/dist/C_TagsView.css
CHANGED
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
* 标签组件样式 - 精简版
|
|
69
69
|
* =========================================== */
|
|
70
70
|
/* --------- 标签视图容器 --------- */
|
|
71
|
-
.tags-view-container[data-v-
|
|
71
|
+
.tags-view-container[data-v-22e190cf] {
|
|
72
72
|
border-bottom: 1px solid var(--color-border);
|
|
73
73
|
padding: 8px 16px 0;
|
|
74
74
|
position: relative;
|
|
@@ -76,14 +76,14 @@
|
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
/* --------- 滚动轨道容器 --------- */
|
|
79
|
-
.tags-track[data-v-
|
|
79
|
+
.tags-track[data-v-22e190cf] {
|
|
80
80
|
width: 100%;
|
|
81
81
|
overflow: hidden;
|
|
82
82
|
position: relative;
|
|
83
83
|
}
|
|
84
84
|
|
|
85
85
|
/* --------- 滚动容器 --------- */
|
|
86
|
-
.tags-container[data-v-
|
|
86
|
+
.tags-container[data-v-22e190cf] {
|
|
87
87
|
display: flex;
|
|
88
88
|
overflow-x: auto;
|
|
89
89
|
overflow-y: hidden;
|
|
@@ -93,12 +93,12 @@
|
|
|
93
93
|
align-items: center;
|
|
94
94
|
min-height: 40px;
|
|
95
95
|
}
|
|
96
|
-
.tags-container[data-v-
|
|
96
|
+
.tags-container[data-v-22e190cf]::-webkit-scrollbar {
|
|
97
97
|
display: none;
|
|
98
98
|
}
|
|
99
99
|
|
|
100
100
|
/* --------- 现代化标签样式 --------- */
|
|
101
|
-
.n-tag[data-v-
|
|
101
|
+
.n-tag[data-v-22e190cf] {
|
|
102
102
|
position: relative;
|
|
103
103
|
display: inline-flex;
|
|
104
104
|
align-items: center;
|
|
@@ -115,7 +115,7 @@
|
|
|
115
115
|
white-space: nowrap;
|
|
116
116
|
/* 内部高光效果 */
|
|
117
117
|
}
|
|
118
|
-
.n-tag[data-v-
|
|
118
|
+
.n-tag[data-v-22e190cf]::before {
|
|
119
119
|
content: "";
|
|
120
120
|
position: absolute;
|
|
121
121
|
top: 1px;
|
|
@@ -127,67 +127,67 @@
|
|
|
127
127
|
opacity: 0.5;
|
|
128
128
|
transition: opacity 0.22s ease;
|
|
129
129
|
}
|
|
130
|
-
.n-tag[data-v-
|
|
130
|
+
.n-tag[data-v-22e190cf] {
|
|
131
131
|
/* --------- 悬停效果 --------- */
|
|
132
132
|
}
|
|
133
|
-
.n-tag[data-v-
|
|
133
|
+
.n-tag[data-v-22e190cf]:hover:not([type=primary]) {
|
|
134
134
|
color: var(--color-primary) !important;
|
|
135
135
|
border-color: var(--color-primary);
|
|
136
136
|
transform: scale(1.02);
|
|
137
137
|
}
|
|
138
|
-
.n-tag[data-v-
|
|
138
|
+
.n-tag[data-v-22e190cf]:hover:not([type=primary])::before {
|
|
139
139
|
opacity: 0.8;
|
|
140
140
|
}
|
|
141
|
-
.n-tag[data-v-
|
|
142
|
-
.n-tag[data-v-
|
|
141
|
+
.n-tag[data-v-22e190cf]:hover:not([type=primary]) .c-icon,
|
|
142
|
+
.n-tag[data-v-22e190cf]:hover:not([type=primary]) [class*='c-icon'] {
|
|
143
143
|
color: var(--color-primary) !important;
|
|
144
144
|
}
|
|
145
|
-
.n-tag:hover:not([type=primary]) i[data-v-
|
|
146
|
-
.n-tag:hover:not([type=primary]) .icon[data-v-
|
|
145
|
+
.n-tag:hover:not([type=primary]) i[data-v-22e190cf],
|
|
146
|
+
.n-tag:hover:not([type=primary]) .icon[data-v-22e190cf] {
|
|
147
147
|
color: var(--color-primary) !important;
|
|
148
148
|
}
|
|
149
|
-
.n-tag[data-v-
|
|
149
|
+
.n-tag[data-v-22e190cf]:hover:not([type=primary]) .n-tag__close {
|
|
150
150
|
color: var(--color-primary) !important;
|
|
151
151
|
opacity: 0.8;
|
|
152
152
|
transform: scale(1.05);
|
|
153
153
|
}
|
|
154
|
-
.n-tag[data-v-
|
|
154
|
+
.n-tag[data-v-22e190cf] {
|
|
155
155
|
/* --------- 激活状态 --------- */
|
|
156
156
|
}
|
|
157
|
-
.n-tag[type=primary][data-v-
|
|
157
|
+
.n-tag[type=primary][data-v-22e190cf] {
|
|
158
158
|
background: var(--tag-active-bg, rgba(32, 128, 240, 0.08)) !important;
|
|
159
159
|
color: var(--color-primary) !important;
|
|
160
160
|
border-color: var(--color-primary) !important;
|
|
161
161
|
font-weight: 600;
|
|
162
162
|
transform: scale(1.02);
|
|
163
163
|
}
|
|
164
|
-
.n-tag[type=primary][data-v-
|
|
164
|
+
.n-tag[type=primary][data-v-22e190cf]::before {
|
|
165
165
|
opacity: 0.6;
|
|
166
166
|
}
|
|
167
|
-
.n-tag[type=primary][data-v-
|
|
168
|
-
.n-tag[type=primary][data-v-
|
|
167
|
+
.n-tag[type=primary][data-v-22e190cf] .n-tag__content,
|
|
168
|
+
.n-tag[type=primary][data-v-22e190cf] *:not(.n-tag__close) {
|
|
169
169
|
color: var(--color-primary) !important;
|
|
170
170
|
}
|
|
171
|
-
.n-tag[type=primary][data-v-
|
|
172
|
-
.n-tag[type=primary][data-v-
|
|
171
|
+
.n-tag[type=primary][data-v-22e190cf] .c-icon,
|
|
172
|
+
.n-tag[type=primary][data-v-22e190cf] [class*='c-icon'] {
|
|
173
173
|
color: var(--color-primary) !important;
|
|
174
174
|
}
|
|
175
|
-
.n-tag[type=primary] i[data-v-
|
|
176
|
-
.n-tag[type=primary] .icon[data-v-
|
|
175
|
+
.n-tag[type=primary] i[data-v-22e190cf],
|
|
176
|
+
.n-tag[type=primary] .icon[data-v-22e190cf] {
|
|
177
177
|
color: var(--color-primary) !important;
|
|
178
178
|
}
|
|
179
|
-
.n-tag[type=primary][data-v-
|
|
179
|
+
.n-tag[type=primary][data-v-22e190cf]:hover {
|
|
180
180
|
background: var(--tag-active-hover-bg, rgba(32, 128, 240, 0.12)) !important;
|
|
181
181
|
transform: scale(1.03);
|
|
182
182
|
}
|
|
183
|
-
.n-tag[type=primary][data-v-
|
|
183
|
+
.n-tag[type=primary][data-v-22e190cf] .n-tag__close {
|
|
184
184
|
color: var(--color-primary) !important;
|
|
185
185
|
opacity: 0.8;
|
|
186
186
|
}
|
|
187
|
-
.n-tag[data-v-
|
|
187
|
+
.n-tag[data-v-22e190cf] {
|
|
188
188
|
/* --------- 关闭按钮 --------- */
|
|
189
189
|
}
|
|
190
|
-
.n-tag[data-v-
|
|
190
|
+
.n-tag[data-v-22e190cf] .n-tag__close {
|
|
191
191
|
width: 16px !important;
|
|
192
192
|
height: 16px !important;
|
|
193
193
|
border-radius: 8px !important;
|
|
@@ -202,10 +202,10 @@
|
|
|
202
202
|
background: rgba(0, 0, 0, 0.02) !important;
|
|
203
203
|
border: 1px solid transparent;
|
|
204
204
|
}
|
|
205
|
-
.n-tag[data-v-
|
|
205
|
+
.n-tag[data-v-22e190cf] .n-tag__close:not(:hover) {
|
|
206
206
|
transform: scale(0.9);
|
|
207
207
|
}
|
|
208
|
-
.n-tag[data-v-
|
|
208
|
+
.n-tag[data-v-22e190cf] .n-tag__close:hover {
|
|
209
209
|
background: linear-gradient(135deg, rgba(248, 113, 113, 0.1), rgba(239, 68, 68, 0.08)) !important;
|
|
210
210
|
border-color: rgba(239, 68, 68, 0.15) !important;
|
|
211
211
|
color: #ef4444 !important;
|
|
@@ -213,13 +213,13 @@
|
|
|
213
213
|
transform: scale(0.6) !important;
|
|
214
214
|
box-shadow: 0 2px 6px rgba(239, 68, 68, 0.2) !important;
|
|
215
215
|
}
|
|
216
|
-
.n-tag[data-v-
|
|
216
|
+
.n-tag[data-v-22e190cf] .n-tag__close:active {
|
|
217
217
|
transform: scale(0.95) !important;
|
|
218
218
|
transition-duration: 0.1s !important;
|
|
219
219
|
}
|
|
220
220
|
|
|
221
221
|
/* --------- C_Icon --------- */
|
|
222
|
-
[data-v-
|
|
222
|
+
[data-v-22e190cf] .c-icon {
|
|
223
223
|
margin-right: 4px;
|
|
224
224
|
font-size: 12px;
|
|
225
225
|
transition: color 0.22s ease;
|
|
@@ -229,63 +229,63 @@
|
|
|
229
229
|
|
|
230
230
|
/* --------- 响应式 --------- */
|
|
231
231
|
@media (max-width: 768px) {
|
|
232
|
-
.tags-view-container[data-v-
|
|
232
|
+
.tags-view-container[data-v-22e190cf] {
|
|
233
233
|
padding: 6px 12px 0;
|
|
234
234
|
}
|
|
235
|
-
.n-tag[data-v-
|
|
235
|
+
.n-tag[data-v-22e190cf] {
|
|
236
236
|
height: 26px;
|
|
237
237
|
padding: 0 10px;
|
|
238
238
|
font-size: 11px;
|
|
239
239
|
margin-right: 3px;
|
|
240
240
|
border-radius: 13px;
|
|
241
241
|
}
|
|
242
|
-
.n-tag[data-v-
|
|
242
|
+
.n-tag[data-v-22e190cf] .n-tag__close {
|
|
243
243
|
width: 14px;
|
|
244
244
|
height: 14px;
|
|
245
245
|
font-size: 11px;
|
|
246
246
|
margin-left: 4px;
|
|
247
247
|
}
|
|
248
|
-
.tags-container[data-v-
|
|
248
|
+
.tags-container[data-v-22e190cf] {
|
|
249
249
|
padding: 0 12px;
|
|
250
250
|
min-height: 36px;
|
|
251
251
|
}
|
|
252
|
-
[data-v-
|
|
252
|
+
[data-v-22e190cf] .c-icon {
|
|
253
253
|
font-size: 11px;
|
|
254
254
|
margin-right: 3px;
|
|
255
255
|
}
|
|
256
256
|
}
|
|
257
257
|
/* --------- 暗色主题 --------- */
|
|
258
|
-
[data-theme=dark] .n-tag[data-v-
|
|
258
|
+
[data-theme=dark] .n-tag[data-v-22e190cf] .n-tag__close {
|
|
259
259
|
background: rgba(255, 255, 255, 0.03) !important;
|
|
260
260
|
}
|
|
261
|
-
[data-theme=dark] .n-tag[data-v-
|
|
261
|
+
[data-theme=dark] .n-tag[data-v-22e190cf] .n-tag__close:hover {
|
|
262
262
|
background: linear-gradient(135deg, rgba(248, 113, 113, 0.12), rgba(239, 68, 68, 0.1)) !important;
|
|
263
263
|
box-shadow: 0 2px 6px rgba(239, 68, 68, 0.25) !important;
|
|
264
264
|
}
|
|
265
265
|
|
|
266
266
|
/* layer: icons */
|
|
267
|
-
.i-mdi\:align-horizontal-left[data-v-
|
|
268
|
-
.i-mdi\:align-horizontal-right[data-v-
|
|
269
|
-
.i-mdi\:arrow-left-right-bold[data-v-
|
|
270
|
-
.i-mdi\:close[data-v-
|
|
271
|
-
.i-mdi\:tally-mark-5[data-v-
|
|
267
|
+
.i-mdi\:align-horizontal-left[data-v-22e190cf]{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1em' height='1em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M4 22H2V2h2zM22 7H6v3h16zm-6 7H6v3h10z'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1em;height:1em;}
|
|
268
|
+
.i-mdi\:align-horizontal-right[data-v-22e190cf]{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1em' height='1em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M20 2h2v20h-2zM2 10h16V7H2zm6 7h10v-3H8z'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1em;height:1em;}
|
|
269
|
+
.i-mdi\:arrow-left-right-bold[data-v-22e190cf]{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1em' height='1em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M8 14v4l-6-6l6-6v4h8V6l6 6l-6 6v-4z'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1em;height:1em;}
|
|
270
|
+
.i-mdi\:close[data-v-22e190cf]{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1em' height='1em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M19 6.41L17.59 5L12 10.59L6.41 5L5 6.41L10.59 12L5 17.59L6.41 19L12 13.41L17.59 19L19 17.59L13.41 12z'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1em;height:1em;}
|
|
271
|
+
.i-mdi\:tally-mark-5[data-v-22e190cf]{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' width='1em' height='1em' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M19 10.73V19h-2v-7.64L15 12v7h-2v-6.38l-2 .64V19H9v-5.11l-2 .61V19H5v-3.85l-2.43.77L2 14l3-.95V5h2v7.42l2-.63V5h2v6.16l2-.63V5h2v4.9l2-.64V5h2v3.63L21 8l.57 1.92z'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;display:inline-block;vertical-align:middle;width:1em;height:1em;}
|
|
272
272
|
/* layer: shortcuts */
|
|
273
|
-
.container[data-v-
|
|
273
|
+
.container[data-v-22e190cf]{width:100%;}
|
|
274
274
|
@media (min-width: 640px){
|
|
275
|
-
.container[data-v-
|
|
275
|
+
.container[data-v-22e190cf]{max-width:640px;}
|
|
276
276
|
}
|
|
277
277
|
@media (min-width: 768px){
|
|
278
|
-
.container[data-v-
|
|
278
|
+
.container[data-v-22e190cf]{max-width:768px;}
|
|
279
279
|
}
|
|
280
280
|
@media (min-width: 1024px){
|
|
281
|
-
.container[data-v-
|
|
281
|
+
.container[data-v-22e190cf]{max-width:1024px;}
|
|
282
282
|
}
|
|
283
283
|
@media (min-width: 1280px){
|
|
284
|
-
.container[data-v-
|
|
284
|
+
.container[data-v-22e190cf]{max-width:1280px;}
|
|
285
285
|
}
|
|
286
286
|
@media (min-width: 1536px){
|
|
287
|
-
.container[data-v-
|
|
287
|
+
.container[data-v-22e190cf]{max-width:1536px;}
|
|
288
288
|
}
|
|
289
289
|
/* layer: default */
|
|
290
|
-
.inline[data-v-
|
|
291
|
-
.block[data-v-
|
|
290
|
+
.inline[data-v-22e190cf]{display:inline;}
|
|
291
|
+
.block[data-v-22e190cf]{display:block;}
|
package/dist/C_TagsView.d.cts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { i as TagItem } from "./
|
|
2
|
-
import { i as useTagsView, n as ContextMenuLabels, r as UseTagsViewOptions, t as _default } from "./
|
|
1
|
+
import { i as TagItem } from "./types3.cjs";
|
|
2
|
+
import { i as useTagsView, n as ContextMenuLabels, r as UseTagsViewOptions, t as _default } from "./index30.vue.cjs";
|
|
3
3
|
export { _default as C_TagsView, type ContextMenuLabels, type TagItem, type UseTagsViewOptions, useTagsView };
|
package/dist/C_TagsView.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { s as TagItem } from "./public.js";
|
|
2
|
-
import { i as useTagsView, n as ContextMenuLabels, r as UseTagsViewOptions, t as _default } from "./
|
|
2
|
+
import { i as useTagsView, n as ContextMenuLabels, r as UseTagsViewOptions, t as _default } from "./index30.vue.js";
|
|
3
3
|
export { _default as C_TagsView, type ContextMenuLabels, type TagItem, type UseTagsViewOptions, useTagsView };
|
package/dist/C_TagsView2.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
require(`./chunk.cjs`);const e=require(`./C_Icon2.cjs`),t=require(`./export-helper.cjs`);let n=require(`vue`),r=require(`naive-ui`),i=require(`vue-router`);const a=e=>{if(!e||typeof e!=`object`)return!1;let t=e;return
|
|
1
|
+
require(`./chunk.cjs`);const e=require(`./C_Icon2.cjs`),t=require(`./export-helper.cjs`);let n=require(`vue`),r=require(`naive-ui`),i=require(`vue-router`);const a=e=>typeof e==`string`&&e.startsWith(`/`)&&!e.startsWith(`//`)&&!e.includes(`\\`)&&!Array.from(e).some(e=>e.charCodeAt(0)<32);function o(e){return a(e.fullPath)&&e.fullPath.split(/[?#]/,1)[0]===e.path?e.fullPath:e.path}const s=e=>{if(!e||typeof e!=`object`)return!1;let t=e;return a(t.path)&&typeof t.title==`string`},c=e=>{if(!(!e||typeof e!=`object`||Array.isArray(e)))return Object.fromEntries(Object.entries(e).filter(([e,t])=>![`__proto__`,`prototype`,`constructor`].includes(e)&&(e!==`affix`||typeof t==`boolean`)))};function l(e){if(!e)return[];try{let t=JSON.parse(e);return Array.isArray(t)?t.flatMap(e=>s(e)?[{path:e.path,...typeof e.fullPath==`string`&&o({path:e.path,fullPath:e.fullPath})===e.fullPath?{fullPath:e.fullPath}:{},title:e.title,originalTitle:typeof e.originalTitle==`string`?e.originalTitle:void 0,icon:typeof e.icon==`string`?e.icon:void 0,meta:c(e.meta)}]:[]):[]}catch{return[]}}function u(e={}){let{persistKey:t=`__tags_view_list__`,homePath:r=`/home`}=e,i=()=>{if(!t)return[];try{return l(localStorage.getItem(t))}catch{return[]}},a=e=>{if(t)try{localStorage.setItem(t,JSON.stringify(e))}catch{}},s=(0,n.ref)(i()),c=(0,n.ref)(``),u=()=>a(s.value),d=e=>{e?s.value=e:s.value=[...new Map(s.value.map(e=>[e.path,e])).values()],u()},f=e=>{c.value=e};return{tagsViewList:s,activeTag:c,homePath:r,initTags:d,setActiveTag:f,addTag:e=>{let t=s.value.findIndex(t=>t.path===e.path);if(t===-1)s.value.push(e);else{let n=s.value[t];e.fullPath!==void 0&&(n.fullPath=o(e)),(n.title!==e.title||!n.originalTitle)&&(n.title=e.title,n.originalTitle=e.originalTitle||n.originalTitle)}f(e.path),u()},removeTag:e=>{if(e>=0&&e<s.value.length){let t=s.value.splice(e,1)[0]?.path??null;return u(),t}return null},removeOtherTags:e=>{s.value=s.value.filter((t,n)=>n===0||t.meta?.affix||n===e),u()},removeLeftTags:e=>{s.value=s.value.filter((t,n)=>n===0||t.meta?.affix||n>=e),u()},removeRightTags:e=>{s.value=s.value.filter((t,n)=>t.meta?.affix||n<=e),u()},removeAllTags:()=>{s.value=s.value.filter(e=>e.meta?.affix),u()}}}const d={class:`tags-view-container`},f=(0,n.defineComponent)({name:`C_TagsView`,__name:`index`,props:{labelFormatter:{},homePath:{default:`/home`},homeTitle:{default:`首页`},homeIcon:{default:`mdi:home`},persistKey:{default:`__tags_view_list__`},contextMenuLabels:{default:()=>({close:`关闭`,closeOthers:`关闭其他`,closeLeft:`关闭左侧`,closeRight:`关闭右侧`,closeAll:`关闭所有`})},tagsViewOptions:{}},emits:[`close`,`closeAll`],setup(t,{expose:a,emit:s}){let c=t,l=s,f=(0,i.useRoute)(),p=(0,i.useRouter)(),m=u(c.tagsViewOptions??{persistKey:c.persistKey,homePath:c.homePath});if(m.tagsViewList.value.length>0&&c.labelFormatter){let e=p.getRoutes(),t=m.tagsViewList.value.map(t=>{let n=e.find(e=>e.path===t.path),r=t.originalTitle||n?.meta?.title||t.title;return{...t,originalTitle:r,title:c.labelFormatter(r)}});m.initTags(t)}let h=e=>c.labelFormatter?c.labelFormatter(e):e,g=()=>{let e=f.path===c.homePath,t=e?c.homeTitle:f.meta.title||`Unnamed Page`;return{path:f.path,fullPath:f.fullPath,originalTitle:t,title:h(t),icon:e?c.homeIcon:f.meta.icon,meta:{affix:f.meta.affix}}},_=(0,n.ref)(!1),v=(0,n.ref)(0),y=(0,n.ref)(0),b=(0,n.ref)(null),x=(0,n.ref)(),S=(0,n.ref)(),C=e=>e.path===f.path,w=e=>e.meta?.affix,T=e=>{let t=S.value;t&&(e.preventDefault(),t.scrollTo({left:t.scrollLeft+e.deltaY,behavior:`smooth`}))},E=e=>{(0,n.nextTick)(()=>{let t=[...S.value?.querySelectorAll(`[data-path]`)??[]].find(t=>t.dataset.path===e);t&&t.scrollIntoView({behavior:`smooth`,block:`nearest`,inline:`center`})})},D=e=>{let t=o(e);t!==f.fullPath&&p.push(t).catch(()=>void 0),E(e.path)},O=0,k=!1,A=async e=>{try{let t=await p.push(e);return!(0,i.isNavigationFailure)(t)||(0,i.isNavigationFailure)(t,i.NavigationFailureType.duplicated)}catch{return!1}},j=async(e,t,n=!1)=>{let r=++O,i=n||!e.some(e=>e.path===f.path),a=e.find(e=>e.path===t),s=a?o(a):t;if(i&&!await A(s)||k||r!==O)return!1;let c=m.tagsViewList.value.find(e=>e.path===f.path)??g();return m.initTags(e.some(e=>e.path===c.path)?e:[...e,c]),m.setActiveTag(f.path),E(f.path),!0},M=async e=>{if(w(e))return;let t=m.tagsViewList.value,n=t.findIndex(t=>t.path===e.path);if(n===-1)return;let r=C(e),i=t.filter(t=>t.path!==e.path),a=n===t.length-1?i[n-1]?.path||c.homePath:i[i.length-1]?.path||c.homePath;await j(i,a)&&r&&l(`close`,a)};(0,n.onBeforeUnmount)(()=>{k=!0,O+=1});let N=(e,t)=>{e.preventDefault(),b.value=t,_.value=!0,v.value=e.clientX,y.value=e.clientY},P=()=>_.value=!1,F=(0,n.computed)(()=>{let e=c.contextMenuLabels;return[{type:`option`,label:e.close??`关闭`,key:`close`,disabled:w(b.value),icon:()=>(0,n.h)(`span`,{class:`i-mdi:close`})},{type:`option`,label:e.closeOthers??`关闭其他`,key:`closeOthers`,icon:()=>(0,n.h)(`span`,{class:`i-mdi:arrow-left-right-bold`})},{type:`option`,label:e.closeLeft??`关闭左侧`,key:`closeLeft`,icon:()=>(0,n.h)(`span`,{class:`i-mdi:align-horizontal-left`})},{type:`option`,label:e.closeRight??`关闭右侧`,key:`closeRight`,icon:()=>(0,n.h)(`span`,{class:`i-mdi:align-horizontal-right`})},{type:`option`,label:e.closeAll??`关闭所有`,key:`closeAll`,icon:()=>(0,n.h)(`span`,{class:`i-mdi:tally-mark-5`})}]}),I=async e=>{let t=b.value,n=m.tagsViewList.value,r=n.findIndex(e=>e.path===t?.path);if(P(),!t||r===-1)return;if(e===`close`){await M(t);return}let i=n.filter((t,n)=>t.meta?.affix?!0:e===`closeOthers`?n===0||n===r:e===`closeLeft`?n===0||n>=r:e===`closeRight`?n<=r:e!==`closeAll`);[`closeOthers`,`closeLeft`,`closeRight`,`closeAll`].includes(e)&&await j(i,e===`closeAll`?c.homePath:t.path,e===`closeAll`)&&e===`closeAll`&&l(`closeAll`)};return(0,n.watch)(()=>f.fullPath,()=>{m.addTag(g()),m.setActiveTag(f.path),E(f.path)},{immediate:!0}),a({tags:m,scrollToTag:E}),(t,i)=>{let a=r.NTag,o=r.NDropdown;return(0,n.openBlock)(),(0,n.createElementBlock)(`div`,d,[(0,n.createElementVNode)(`div`,{class:`tags-track`,ref_key:`tagsTrack`,ref:x,onWheel:T},[(0,n.createElementVNode)(`div`,{class:`tags-container`,ref_key:`tagsContainer`,ref:S},[((0,n.openBlock)(!0),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)((0,n.unref)(m).tagsViewList.value,t=>((0,n.openBlock)(),(0,n.createBlock)(a,{key:t.path,type:C(t)?`primary`:`default`,closable:!w(t),"data-path":t.path,onClose:(0,n.withModifiers)(e=>M(t),[`stop`]),onClick:e=>D(t),onContextmenu:(0,n.withModifiers)(e=>N(e,t),[`prevent`])},{icon:(0,n.withCtx)(()=>[t.icon?((0,n.openBlock)(),(0,n.createBlock)((0,n.unref)(e.t),{key:0,name:t.icon,size:12},null,8,[`name`])):(0,n.createCommentVNode)(`v-if`,!0)]),default:(0,n.withCtx)(()=>[(0,n.createTextVNode)(` `+(0,n.toDisplayString)(t.title),1)]),_:2},1032,[`type`,`closable`,`data-path`,`onClose`,`onClick`,`onContextmenu`]))),128))],512)],544),_.value?((0,n.openBlock)(),(0,n.createBlock)(o,{key:0,show:_.value,options:F.value,x:v.value,y:y.value,onClickoutside:P,onSelect:I},null,8,[`show`,`options`,`x`,`y`])):(0,n.createCommentVNode)(`v-if`,!0)])}}});var p=t.t(f,[[`__scopeId`,`data-v-22e190cf`]]);Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return u}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return p}});
|
package/dist/C_TagsView2.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./C_Icon2.js";import{t}from"./export-helper.js";import{Fragment as n,computed as r,createBlock as i,createCommentVNode as a,createElementBlock as o,createElementVNode as s,createTextVNode as c,defineComponent as l,h as u,nextTick as d,onBeforeUnmount as f,openBlock as p,ref as m,renderList as h,resolveComponent as g,toDisplayString as
|
|
1
|
+
import{t as e}from"./C_Icon2.js";import{t}from"./export-helper.js";import{Fragment as n,computed as r,createBlock as i,createCommentVNode as a,createElementBlock as o,createElementVNode as s,createTextVNode as c,defineComponent as l,h as u,nextTick as d,onBeforeUnmount as f,openBlock as p,ref as m,renderList as h,resolveComponent as g,toDisplayString as _,unref as v,watch as y,withCtx as b,withModifiers as x}from"vue";import{NDropdown as ee,NTag as S}from"naive-ui";import{NavigationFailureType as C,isNavigationFailure as w,useRoute as T,useRouter as E}from"vue-router";const D=e=>typeof e==`string`&&e.startsWith(`/`)&&!e.startsWith(`//`)&&!e.includes(`\\`)&&!Array.from(e).some(e=>e.charCodeAt(0)<32);function O(e){return D(e.fullPath)&&e.fullPath.split(/[?#]/,1)[0]===e.path?e.fullPath:e.path}const k=e=>{if(!e||typeof e!=`object`)return!1;let t=e;return D(t.path)&&typeof t.title==`string`},A=e=>{if(!(!e||typeof e!=`object`||Array.isArray(e)))return Object.fromEntries(Object.entries(e).filter(([e,t])=>![`__proto__`,`prototype`,`constructor`].includes(e)&&(e!==`affix`||typeof t==`boolean`)))};function j(e){if(!e)return[];try{let t=JSON.parse(e);return Array.isArray(t)?t.flatMap(e=>k(e)?[{path:e.path,...typeof e.fullPath==`string`&&O({path:e.path,fullPath:e.fullPath})===e.fullPath?{fullPath:e.fullPath}:{},title:e.title,originalTitle:typeof e.originalTitle==`string`?e.originalTitle:void 0,icon:typeof e.icon==`string`?e.icon:void 0,meta:A(e.meta)}]:[]):[]}catch{return[]}}function M(e={}){let{persistKey:t=`__tags_view_list__`,homePath:n=`/home`}=e,r=()=>{if(!t)return[];try{return j(localStorage.getItem(t))}catch{return[]}},i=e=>{if(t)try{localStorage.setItem(t,JSON.stringify(e))}catch{}},a=m(r()),o=m(``),s=()=>i(a.value),c=e=>{e?a.value=e:a.value=[...new Map(a.value.map(e=>[e.path,e])).values()],s()},l=e=>{o.value=e};return{tagsViewList:a,activeTag:o,homePath:n,initTags:c,setActiveTag:l,addTag:e=>{let t=a.value.findIndex(t=>t.path===e.path);if(t===-1)a.value.push(e);else{let n=a.value[t];e.fullPath!==void 0&&(n.fullPath=O(e)),(n.title!==e.title||!n.originalTitle)&&(n.title=e.title,n.originalTitle=e.originalTitle||n.originalTitle)}l(e.path),s()},removeTag:e=>{if(e>=0&&e<a.value.length){let t=a.value.splice(e,1)[0]?.path??null;return s(),t}return null},removeOtherTags:e=>{a.value=a.value.filter((t,n)=>n===0||t.meta?.affix||n===e),s()},removeLeftTags:e=>{a.value=a.value.filter((t,n)=>n===0||t.meta?.affix||n>=e),s()},removeRightTags:e=>{a.value=a.value.filter((t,n)=>t.meta?.affix||n<=e),s()},removeAllTags:()=>{a.value=a.value.filter(e=>e.meta?.affix),s()}}}const N={class:`tags-view-container`};var P=t(l({name:`C_TagsView`,__name:`index`,props:{labelFormatter:{},homePath:{default:`/home`},homeTitle:{default:`首页`},homeIcon:{default:`mdi:home`},persistKey:{default:`__tags_view_list__`},contextMenuLabels:{default:()=>({close:`关闭`,closeOthers:`关闭其他`,closeLeft:`关闭左侧`,closeRight:`关闭右侧`,closeAll:`关闭所有`})},tagsViewOptions:{}},emits:[`close`,`closeAll`],setup(t,{expose:l,emit:g}){let D=t,k=g,A=T(),j=E(),P=M(D.tagsViewOptions??{persistKey:D.persistKey,homePath:D.homePath});if(P.tagsViewList.value.length>0&&D.labelFormatter){let e=j.getRoutes(),t=P.tagsViewList.value.map(t=>{let n=e.find(e=>e.path===t.path),r=t.originalTitle||n?.meta?.title||t.title;return{...t,originalTitle:r,title:D.labelFormatter(r)}});P.initTags(t)}let F=e=>D.labelFormatter?D.labelFormatter(e):e,I=()=>{let e=A.path===D.homePath,t=e?D.homeTitle:A.meta.title||`Unnamed Page`;return{path:A.path,fullPath:A.fullPath,originalTitle:t,title:F(t),icon:e?D.homeIcon:A.meta.icon,meta:{affix:A.meta.affix}}},L=m(!1),R=m(0),z=m(0),B=m(null),V=m(),H=m(),U=e=>e.path===A.path,W=e=>e.meta?.affix,G=e=>{let t=H.value;t&&(e.preventDefault(),t.scrollTo({left:t.scrollLeft+e.deltaY,behavior:`smooth`}))},K=e=>{d(()=>{let t=[...H.value?.querySelectorAll(`[data-path]`)??[]].find(t=>t.dataset.path===e);t&&t.scrollIntoView({behavior:`smooth`,block:`nearest`,inline:`center`})})},q=e=>{let t=O(e);t!==A.fullPath&&j.push(t).catch(()=>void 0),K(e.path)},J=0,Y=!1,X=async e=>{try{let t=await j.push(e);return!w(t)||w(t,C.duplicated)}catch{return!1}},Z=async(e,t,n=!1)=>{let r=++J,i=n||!e.some(e=>e.path===A.path),a=e.find(e=>e.path===t),o=a?O(a):t;if(i&&!await X(o)||Y||r!==J)return!1;let s=P.tagsViewList.value.find(e=>e.path===A.path)??I();return P.initTags(e.some(e=>e.path===s.path)?e:[...e,s]),P.setActiveTag(A.path),K(A.path),!0},Q=async e=>{if(W(e))return;let t=P.tagsViewList.value,n=t.findIndex(t=>t.path===e.path);if(n===-1)return;let r=U(e),i=t.filter(t=>t.path!==e.path),a=n===t.length-1?i[n-1]?.path||D.homePath:i[i.length-1]?.path||D.homePath;await Z(i,a)&&r&&k(`close`,a)};f(()=>{Y=!0,J+=1});let te=(e,t)=>{e.preventDefault(),B.value=t,L.value=!0,R.value=e.clientX,z.value=e.clientY},$=()=>L.value=!1,ne=r(()=>{let e=D.contextMenuLabels;return[{type:`option`,label:e.close??`关闭`,key:`close`,disabled:W(B.value),icon:()=>u(`span`,{class:`i-mdi:close`})},{type:`option`,label:e.closeOthers??`关闭其他`,key:`closeOthers`,icon:()=>u(`span`,{class:`i-mdi:arrow-left-right-bold`})},{type:`option`,label:e.closeLeft??`关闭左侧`,key:`closeLeft`,icon:()=>u(`span`,{class:`i-mdi:align-horizontal-left`})},{type:`option`,label:e.closeRight??`关闭右侧`,key:`closeRight`,icon:()=>u(`span`,{class:`i-mdi:align-horizontal-right`})},{type:`option`,label:e.closeAll??`关闭所有`,key:`closeAll`,icon:()=>u(`span`,{class:`i-mdi:tally-mark-5`})}]}),re=async e=>{let t=B.value,n=P.tagsViewList.value,r=n.findIndex(e=>e.path===t?.path);if($(),!t||r===-1)return;if(e===`close`){await Q(t);return}let i=n.filter((t,n)=>t.meta?.affix?!0:e===`closeOthers`?n===0||n===r:e===`closeLeft`?n===0||n>=r:e===`closeRight`?n<=r:e!==`closeAll`);[`closeOthers`,`closeLeft`,`closeRight`,`closeAll`].includes(e)&&await Z(i,e===`closeAll`?D.homePath:t.path,e===`closeAll`)&&e===`closeAll`&&k(`closeAll`)};return y(()=>A.fullPath,()=>{P.addTag(I()),P.setActiveTag(A.path),K(A.path)},{immediate:!0}),l({tags:P,scrollToTag:K}),(t,r)=>{let l=S,u=ee;return p(),o(`div`,N,[s(`div`,{class:`tags-track`,ref_key:`tagsTrack`,ref:V,onWheel:G},[s(`div`,{class:`tags-container`,ref_key:`tagsContainer`,ref:H},[(p(!0),o(n,null,h(v(P).tagsViewList.value,t=>(p(),i(l,{key:t.path,type:U(t)?`primary`:`default`,closable:!W(t),"data-path":t.path,onClose:x(e=>Q(t),[`stop`]),onClick:e=>q(t),onContextmenu:x(e=>te(e,t),[`prevent`])},{icon:b(()=>[t.icon?(p(),i(v(e),{key:0,name:t.icon,size:12},null,8,[`name`])):a(`v-if`,!0)]),default:b(()=>[c(` `+_(t.title),1)]),_:2},1032,[`type`,`closable`,`data-path`,`onClose`,`onClick`,`onContextmenu`]))),128))],512)],544),L.value?(p(),i(u,{key:0,show:L.value,options:ne.value,x:R.value,y:z.value,onClickoutside:$,onSelect:re},null,8,[`show`,`options`,`x`,`y`])):a(`v-if`,!0)])}}}),[[`__scopeId`,`data-v-22e190cf`]]);export{M as n,P as t};
|
package/dist/C_Theme.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as ThemeMode, t as _default } from "./
|
|
1
|
+
import { n as ThemeMode, t as _default } from "./index29.vue.cjs";
|
|
2
2
|
export { _default as C_Theme, type ThemeMode };
|
package/dist/C_Theme.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as ThemeMode, t as _default } from "./
|
|
1
|
+
import { n as ThemeMode, t as _default } from "./index29.vue.js";
|
|
2
2
|
export { _default as C_Theme, type ThemeMode };
|
package/dist/C_Timeline.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TimelineProps, i as TimelineItem, n as DEFAULT_TIMELINE_PROPS, r as STATUS_COLOR_MAP, t as _default } from "./
|
|
1
|
+
import { a as TimelineProps, i as TimelineItem, n as DEFAULT_TIMELINE_PROPS, r as STATUS_COLOR_MAP, t as _default } from "./index31.vue.cjs";
|
|
2
2
|
export { _default as C_Timeline, DEFAULT_TIMELINE_PROPS, STATUS_COLOR_MAP as TIMELINE_STATUS_COLOR_MAP, type TimelineItem, type TimelineProps };
|
package/dist/C_Timeline.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TimelineProps, i as TimelineItem, n as DEFAULT_TIMELINE_PROPS, r as STATUS_COLOR_MAP, t as _default } from "./
|
|
1
|
+
import { a as TimelineProps, i as TimelineItem, n as DEFAULT_TIMELINE_PROPS, r as STATUS_COLOR_MAP, t as _default } from "./index31.vue.js";
|
|
2
2
|
export { _default as C_Timeline, DEFAULT_TIMELINE_PROPS, STATUS_COLOR_MAP as TIMELINE_STATUS_COLOR_MAP, type TimelineItem, type TimelineProps };
|
package/dist/C_Transfer.d.cts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TransferProps, i as TransferItem, n as DEFAULT_TRANSFER_PROPS, r as TransferEmits, t as _default } from "./
|
|
1
|
+
import { a as TransferProps, i as TransferItem, n as DEFAULT_TRANSFER_PROPS, r as TransferEmits, t as _default } from "./index32.vue.cjs";
|
|
2
2
|
export { _default as C_Transfer, DEFAULT_TRANSFER_PROPS, type TransferEmits, type TransferItem, type TransferProps };
|
package/dist/C_Transfer.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TransferProps, i as TransferItem, n as DEFAULT_TRANSFER_PROPS, r as TransferEmits, t as _default } from "./
|
|
1
|
+
import { a as TransferProps, i as TransferItem, n as DEFAULT_TRANSFER_PROPS, r as TransferEmits, t as _default } from "./index32.vue.js";
|
|
2
2
|
export { _default as C_Transfer, DEFAULT_TRANSFER_PROPS, type TransferEmits, type TransferItem, type TransferProps };
|
package/dist/C_Tree.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require(`./C_Icon2.cjs`);const e=require(`./C_Tree2.cjs`);exports.C_Tree=e.t,exports.treePresetConfigs=e.
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`}),require(`./C_Icon2.cjs`);const e=require(`./C_Tree2.cjs`);exports.C_Tree=e.t,exports.treePresetConfigs=e.i,exports.useTreeOperations=e.r;
|
package/dist/C_Tree.css
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
@import "./shared-tokens.css";
|
|
2
|
-
.c-tree[data-v-
|
|
2
|
+
.c-tree[data-v-d7f39843] {
|
|
3
3
|
--c-tree-padding: 12px;
|
|
4
4
|
--c-tree-gap: 10px;
|
|
5
5
|
display: flex;
|
|
@@ -9,15 +9,15 @@
|
|
|
9
9
|
height: 100%;
|
|
10
10
|
gap: var(--c-tree-gap);
|
|
11
11
|
}
|
|
12
|
-
.c-tree--compact[data-v-
|
|
12
|
+
.c-tree--compact[data-v-d7f39843] {
|
|
13
13
|
--c-tree-padding: 8px;
|
|
14
14
|
--c-tree-gap: 8px;
|
|
15
15
|
}
|
|
16
|
-
.c-tree--comfortable[data-v-
|
|
16
|
+
.c-tree--comfortable[data-v-d7f39843] {
|
|
17
17
|
--c-tree-padding: 16px;
|
|
18
18
|
--c-tree-gap: 14px;
|
|
19
19
|
}
|
|
20
|
-
.c-tree .c-tree-toolbar[data-v-
|
|
20
|
+
.c-tree .c-tree-toolbar[data-v-d7f39843] {
|
|
21
21
|
display: flex;
|
|
22
22
|
flex-wrap: wrap;
|
|
23
23
|
align-items: center;
|
|
@@ -27,21 +27,21 @@
|
|
|
27
27
|
border-radius: var(--c-tree-radius);
|
|
28
28
|
flex-shrink: 0;
|
|
29
29
|
}
|
|
30
|
-
.c-tree .toolbar-left[data-v-
|
|
30
|
+
.c-tree .toolbar-left[data-v-d7f39843] {
|
|
31
31
|
flex: 1 1 140px;
|
|
32
32
|
min-width: 0;
|
|
33
33
|
}
|
|
34
|
-
.c-tree .toolbar-left .search-input[data-v-
|
|
34
|
+
.c-tree .toolbar-left .search-input[data-v-d7f39843] {
|
|
35
35
|
width: 100%;
|
|
36
36
|
}
|
|
37
|
-
.c-tree .toolbar-right[data-v-
|
|
37
|
+
.c-tree .toolbar-right[data-v-d7f39843] {
|
|
38
38
|
display: flex;
|
|
39
39
|
flex-wrap: wrap;
|
|
40
40
|
align-items: center;
|
|
41
41
|
gap: 6px;
|
|
42
42
|
margin-left: auto;
|
|
43
43
|
}
|
|
44
|
-
.c-tree .c-tree-container[data-v-
|
|
44
|
+
.c-tree .c-tree-container[data-v-d7f39843] {
|
|
45
45
|
flex: 1 1 auto;
|
|
46
46
|
min-width: 0;
|
|
47
47
|
min-height: 0;
|
|
@@ -51,33 +51,49 @@
|
|
|
51
51
|
overflow: auto;
|
|
52
52
|
scrollbar-width: thin;
|
|
53
53
|
}
|
|
54
|
-
.c-tree
|
|
54
|
+
.c-tree .c-tree-search-status[data-v-d7f39843] {
|
|
55
|
+
display: flex;
|
|
56
|
+
align-items: center;
|
|
57
|
+
justify-content: space-between;
|
|
58
|
+
flex-wrap: wrap;
|
|
59
|
+
gap: 8px;
|
|
60
|
+
padding-inline: var(--c-tree-padding);
|
|
61
|
+
font-size: 12px;
|
|
62
|
+
color: var(--c-tree-text-secondary);
|
|
63
|
+
flex-shrink: 0;
|
|
64
|
+
}
|
|
65
|
+
.c-tree .c-tree-search-navigation[data-v-d7f39843] {
|
|
66
|
+
display: inline-flex;
|
|
67
|
+
align-items: center;
|
|
68
|
+
gap: 12px;
|
|
69
|
+
}
|
|
70
|
+
.c-tree--virtual .c-tree-container[data-v-d7f39843] {
|
|
55
71
|
overflow: hidden;
|
|
56
72
|
}
|
|
57
|
-
.c-tree--virtual .tree-instance[data-v-
|
|
73
|
+
.c-tree--virtual .tree-instance[data-v-d7f39843] {
|
|
58
74
|
height: 100%;
|
|
59
75
|
}
|
|
60
|
-
.c-tree[data-v-
|
|
61
|
-
.c-tree[data-v-
|
|
76
|
+
.c-tree[data-v-d7f39843] .n-tree-node-content,
|
|
77
|
+
.c-tree[data-v-d7f39843] .n-tree-node-content__text {
|
|
62
78
|
min-width: 0;
|
|
63
79
|
}
|
|
64
|
-
.c-tree[data-v-
|
|
80
|
+
.c-tree[data-v-d7f39843] .c-tree-node-label {
|
|
65
81
|
display: flex;
|
|
66
82
|
align-items: center;
|
|
67
83
|
min-width: 0;
|
|
68
84
|
width: 100%;
|
|
69
85
|
gap: 6px;
|
|
70
86
|
}
|
|
71
|
-
.c-tree[data-v-
|
|
87
|
+
.c-tree[data-v-d7f39843] .c-tree-node-title {
|
|
72
88
|
overflow: hidden;
|
|
73
89
|
white-space: nowrap;
|
|
74
90
|
text-overflow: ellipsis;
|
|
75
91
|
}
|
|
76
|
-
.c-tree[data-v-
|
|
77
|
-
.c-tree[data-v-
|
|
92
|
+
.c-tree[data-v-d7f39843] .c-tree-node-status,
|
|
93
|
+
.c-tree[data-v-d7f39843] .c-tree-node-icon {
|
|
78
94
|
flex-shrink: 0;
|
|
79
95
|
}
|
|
80
|
-
.c-tree[data-v-
|
|
96
|
+
.c-tree[data-v-d7f39843] .tree-actions {
|
|
81
97
|
display: inline-flex;
|
|
82
98
|
align-items: center;
|
|
83
99
|
gap: 2px;
|
|
@@ -85,21 +101,42 @@
|
|
|
85
101
|
opacity: 0;
|
|
86
102
|
transition: opacity 0.15s ease;
|
|
87
103
|
}
|
|
88
|
-
.c-tree[data-v-
|
|
89
|
-
|
|
90
|
-
|
|
104
|
+
.c-tree[data-v-d7f39843] .c-tree-suffix {
|
|
105
|
+
display: inline-flex;
|
|
106
|
+
align-items: center;
|
|
107
|
+
gap: 6px;
|
|
108
|
+
}
|
|
109
|
+
.c-tree[data-v-d7f39843] .c-tree-node-loading {
|
|
110
|
+
width: 12px;
|
|
111
|
+
height: 12px;
|
|
112
|
+
border: 2px solid currentColor;
|
|
113
|
+
border-right-color: transparent;
|
|
114
|
+
border-radius: 50%;
|
|
115
|
+
animation: c-tree-spin-d7f39843 0.8s linear infinite;
|
|
116
|
+
}
|
|
117
|
+
.c-tree[data-v-d7f39843] .n-tree-node:hover .tree-actions,
|
|
118
|
+
.c-tree[data-v-d7f39843] .n-tree-node:focus-within .tree-actions,
|
|
119
|
+
.c-tree[data-v-d7f39843] .tree-actions:focus-within {
|
|
91
120
|
opacity: 1;
|
|
92
121
|
}
|
|
93
122
|
@media (hover: none), (max-width: 640px) {
|
|
94
|
-
.c-tree[data-v-
|
|
123
|
+
.c-tree[data-v-d7f39843] .tree-actions {
|
|
95
124
|
opacity: 1;
|
|
96
125
|
}
|
|
97
126
|
}
|
|
98
127
|
@media (prefers-reduced-motion: reduce) {
|
|
99
|
-
.c-tree[data-v-
|
|
128
|
+
.c-tree[data-v-d7f39843] .tree-actions {
|
|
100
129
|
transition: none;
|
|
101
130
|
}
|
|
131
|
+
.c-tree[data-v-d7f39843] .c-tree-node-loading {
|
|
132
|
+
animation: none;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
@keyframes c-tree-spin-d7f39843 {
|
|
136
|
+
to {
|
|
137
|
+
transform: rotate(360deg);
|
|
138
|
+
}
|
|
102
139
|
}
|
|
103
140
|
|
|
104
141
|
/* layer: default */
|
|
105
|
-
.filter[data-v-
|
|
142
|
+
.filter[data-v-d7f39843]{filter:var(--un-blur) var(--un-brightness) var(--un-contrast) var(--un-drop-shadow) var(--un-grayscale) var(--un-hue-rotate) var(--un-invert) var(--un-saturate) var(--un-sepia);}
|
package/dist/C_Tree.d.cts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { t as ComponentDensity } from "./density.cjs";
|
|
2
|
-
import { C as
|
|
3
|
-
export { type ActionConfig, type ButtonType, _default as C_Tree, type ComponentDensity, type DropInfo, type IconConfig, type StatusConfig, type StatusType, type TreeEmits, type TreeExpose, type TreeKey, type TreeMode, type TreeNativeProps, type TreeNodeData, type TreeOption, type TreeProps, type TreeRenderContext, type TreeSlots, type TreeUpdateMeta, presetConfigs as treePresetConfigs, useTreeOperations };
|
|
2
|
+
import { A as TreeSearchSource, C as TreeKey, D as TreeOption, E as TreeNodeData, M as TreeUpdateMeta, O as TreeProps, S as TreeExpose, T as TreeNativeProps, _ as DropInfo, b as StatusType, f as useTreeOperations, g as ButtonType, h as ActionConfig, j as TreeSlots, k as TreeRenderContext, m as _default, p as presetConfigs, v as IconConfig, w as TreeMode, x as TreeEmits, y as StatusConfig } from "./editors.cjs";
|
|
3
|
+
export { type ActionConfig, type ButtonType, _default as C_Tree, type ComponentDensity, type DropInfo, type IconConfig, type StatusConfig, type StatusType, type TreeEmits, type TreeExpose, type TreeKey, type TreeMode, type TreeNativeProps, type TreeNodeData, type TreeOption, type TreeProps, type TreeRenderContext, type TreeSearchSource, type TreeSlots, type TreeUpdateMeta, presetConfigs as treePresetConfigs, useTreeOperations };
|
package/dist/C_Tree.d.ts
CHANGED
|
@@ -1,24 +1,27 @@
|
|
|
1
1
|
import "./types.js";
|
|
2
2
|
import "./presets.js";
|
|
3
3
|
import "./useEdgeInteraction.js";
|
|
4
|
+
import { t as ComponentDensity } from "./density.js";
|
|
5
|
+
import "./types2.js";
|
|
6
|
+
import "./index2.vue.js";
|
|
4
7
|
import "./public.js";
|
|
5
|
-
import "./
|
|
8
|
+
import "./index6.vue.js";
|
|
6
9
|
import "./useFormConfig.js";
|
|
7
|
-
import { t as ComponentDensity } from "./density.js";
|
|
8
10
|
import "./config2.js";
|
|
9
11
|
import "./verification.js";
|
|
10
12
|
import "./formField.js";
|
|
11
13
|
import "./useFormRenderer.js";
|
|
12
14
|
import "./useDraggableLayout.js";
|
|
13
15
|
import "./useDynamicFormState.js";
|
|
14
|
-
import "./
|
|
16
|
+
import "./types4.js";
|
|
17
|
+
import "./index15.vue.js";
|
|
15
18
|
import "./dateRange.js";
|
|
16
|
-
import "./
|
|
19
|
+
import "./index20.vue.js";
|
|
17
20
|
import "./mapUtils.js";
|
|
18
|
-
import "./
|
|
19
|
-
import "./
|
|
20
|
-
import { C as
|
|
21
|
+
import "./index22.vue.js";
|
|
22
|
+
import "./index26.vue.js";
|
|
23
|
+
import { A as TreeSearchSource, C as TreeKey, D as TreeOption, E as TreeNodeData, M as TreeUpdateMeta, O as TreeProps, S as TreeExpose, T as TreeNativeProps, _ as DropInfo, b as StatusType, f as useTreeOperations, g as ButtonType, h as ActionConfig, j as TreeSlots, k as TreeRenderContext, m as _default, p as presetConfigs, v as IconConfig, w as TreeMode, x as TreeEmits, y as StatusConfig } from "./editors.js";
|
|
21
24
|
import "./constants5.js";
|
|
22
25
|
import "./useWorkflowValidation.js";
|
|
23
|
-
import "./
|
|
24
|
-
export { type ActionConfig, type ButtonType, _default as C_Tree, type ComponentDensity, type DropInfo, type IconConfig, type StatusConfig, type StatusType, type TreeEmits, type TreeExpose, type TreeKey, type TreeMode, type TreeNativeProps, type TreeNodeData, type TreeOption, type TreeProps, type TreeRenderContext, type TreeSlots, type TreeUpdateMeta, presetConfigs as treePresetConfigs, useTreeOperations };
|
|
26
|
+
import "./index30.vue.js";
|
|
27
|
+
export { type ActionConfig, type ButtonType, _default as C_Tree, type ComponentDensity, type DropInfo, type IconConfig, type StatusConfig, type StatusType, type TreeEmits, type TreeExpose, type TreeKey, type TreeMode, type TreeNativeProps, type TreeNodeData, type TreeOption, type TreeProps, type TreeRenderContext, type TreeSearchSource, type TreeSlots, type TreeUpdateMeta, presetConfigs as treePresetConfigs, useTreeOperations };
|
package/dist/C_Tree.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./C_Icon2.js";import{
|
|
1
|
+
import"./C_Icon2.js";import{i as e,r as t,t as n}from"./C_Tree2.js";export{n as C_Tree,e as treePresetConfigs,t as useTreeOperations};
|