hzzt-plus 0.0.8 → 0.0.9
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/index.css +1 -1
- package/dist/index.full.js +47 -33
- package/dist/index.full.min.js +6 -6
- package/dist/index.full.min.js.map +1 -1
- package/dist/index.full.min.mjs +5 -5
- package/dist/index.full.min.mjs.map +1 -1
- package/dist/index.full.mjs +47 -33
- package/es/components/tab/index.d.ts +161 -3
- package/es/components/tab/src/index.mjs +19 -4
- package/es/components/tab/src/index.mjs.map +1 -1
- package/es/components/tab/src/index.vue.d.ts +162 -3
- package/lib/components/tab/index.d.ts +161 -3
- package/lib/components/tab/src/index.js +18 -3
- package/lib/components/tab/src/index.js.map +1 -1
- package/lib/components/tab/src/index.vue.d.ts +162 -3
- package/package.json +1 -1
- package/theme/hzzt-collapse.css +1 -1
- package/theme/hzzt-tab.css +1 -1
- package/theme/index.css +1 -1
- package/theme/src/collapse.scss +1 -0
- package/theme/src/tab.scss +24 -6
|
@@ -6,6 +6,10 @@ export declare const HzztTab: import("hzzt-plus/es/utils").SFCWithInstall<import
|
|
|
6
6
|
modelValue: {
|
|
7
7
|
type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
|
|
8
8
|
};
|
|
9
|
+
closable: {
|
|
10
|
+
type: BooleanConstructor;
|
|
11
|
+
default: () => boolean;
|
|
12
|
+
};
|
|
9
13
|
}, {
|
|
10
14
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
11
15
|
tabList: {
|
|
@@ -15,11 +19,16 @@ export declare const HzztTab: import("hzzt-plus/es/utils").SFCWithInstall<import
|
|
|
15
19
|
modelValue: {
|
|
16
20
|
type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
|
|
17
21
|
};
|
|
22
|
+
closable: {
|
|
23
|
+
type: BooleanConstructor;
|
|
24
|
+
default: () => boolean;
|
|
25
|
+
};
|
|
18
26
|
}>> & {
|
|
19
27
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
20
28
|
"onTab-click"?: ((...args: any[]) => any) | undefined;
|
|
29
|
+
"onTab-close"?: ((...args: any[]) => any) | undefined;
|
|
21
30
|
}>>;
|
|
22
|
-
emit: (event: "update:modelValue" | "tab-click", ...args: any[]) => void;
|
|
31
|
+
emit: (event: "update:modelValue" | "tab-click" | "tab-close", ...args: any[]) => void;
|
|
23
32
|
customTabList: import("vue").ComputedRef<{
|
|
24
33
|
number: number;
|
|
25
34
|
hide: boolean;
|
|
@@ -27,8 +36,151 @@ export declare const HzztTab: import("hzzt-plus/es/utils").SFCWithInstall<import
|
|
|
27
36
|
label: string;
|
|
28
37
|
key: string;
|
|
29
38
|
}[]>;
|
|
30
|
-
tabClick: (tab:
|
|
31
|
-
|
|
39
|
+
tabClick: (tab: {
|
|
40
|
+
name: string;
|
|
41
|
+
label: string;
|
|
42
|
+
number: number;
|
|
43
|
+
hide: boolean;
|
|
44
|
+
}, event: Event) => void;
|
|
45
|
+
close: (index: number, event: Event) => void;
|
|
46
|
+
HzztIcon: import("vue").DefineComponent<{
|
|
47
|
+
name: {
|
|
48
|
+
type: StringConstructor;
|
|
49
|
+
required: true;
|
|
50
|
+
};
|
|
51
|
+
type: {
|
|
52
|
+
type: StringConstructor;
|
|
53
|
+
default: string;
|
|
54
|
+
};
|
|
55
|
+
}, {
|
|
56
|
+
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
57
|
+
name: {
|
|
58
|
+
type: StringConstructor;
|
|
59
|
+
required: true;
|
|
60
|
+
};
|
|
61
|
+
type: {
|
|
62
|
+
type: StringConstructor;
|
|
63
|
+
default: string;
|
|
64
|
+
};
|
|
65
|
+
}>> & {
|
|
66
|
+
[x: string & `on${string}`]: ((...args: any[]) => any) | ((...args: unknown[]) => any) | undefined;
|
|
67
|
+
}>>;
|
|
68
|
+
attrs: {
|
|
69
|
+
[x: string]: unknown;
|
|
70
|
+
};
|
|
71
|
+
componentName: import("vue").ComputedRef<string>;
|
|
72
|
+
ElIcon: import("element-plus/es/utils").SFCWithInstall<{
|
|
73
|
+
new (...args: any[]): {
|
|
74
|
+
$: import("vue").ComponentInternalInstance;
|
|
75
|
+
$data: {};
|
|
76
|
+
$props: Partial<{}> & Omit<Readonly<import("vue").ExtractPropTypes<{
|
|
77
|
+
readonly size: {
|
|
78
|
+
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
79
|
+
readonly required: false;
|
|
80
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
81
|
+
__epPropKey: true;
|
|
82
|
+
};
|
|
83
|
+
readonly color: {
|
|
84
|
+
readonly type: import("vue").PropType<string>;
|
|
85
|
+
readonly required: false;
|
|
86
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
87
|
+
__epPropKey: true;
|
|
88
|
+
};
|
|
89
|
+
}>> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>;
|
|
90
|
+
$attrs: {
|
|
91
|
+
[x: string]: unknown;
|
|
92
|
+
};
|
|
93
|
+
$refs: {
|
|
94
|
+
[x: string]: unknown;
|
|
95
|
+
};
|
|
96
|
+
$slots: Readonly<{
|
|
97
|
+
[name: string]: import("vue").Slot | undefined;
|
|
98
|
+
}>;
|
|
99
|
+
$root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null;
|
|
100
|
+
$parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null;
|
|
101
|
+
$emit: (event: string, ...args: any[]) => void;
|
|
102
|
+
$el: any;
|
|
103
|
+
$options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
|
104
|
+
readonly size: {
|
|
105
|
+
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
106
|
+
readonly required: false;
|
|
107
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
108
|
+
__epPropKey: true;
|
|
109
|
+
};
|
|
110
|
+
readonly color: {
|
|
111
|
+
readonly type: import("vue").PropType<string>;
|
|
112
|
+
readonly required: false;
|
|
113
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
114
|
+
__epPropKey: true;
|
|
115
|
+
};
|
|
116
|
+
}>>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, {}> & {
|
|
117
|
+
beforeCreate?: ((() => void) | (() => void)[]) | undefined;
|
|
118
|
+
created?: ((() => void) | (() => void)[]) | undefined;
|
|
119
|
+
beforeMount?: ((() => void) | (() => void)[]) | undefined;
|
|
120
|
+
mounted?: ((() => void) | (() => void)[]) | undefined;
|
|
121
|
+
beforeUpdate?: ((() => void) | (() => void)[]) | undefined;
|
|
122
|
+
updated?: ((() => void) | (() => void)[]) | undefined;
|
|
123
|
+
activated?: ((() => void) | (() => void)[]) | undefined;
|
|
124
|
+
deactivated?: ((() => void) | (() => void)[]) | undefined;
|
|
125
|
+
beforeDestroy?: ((() => void) | (() => void)[]) | undefined;
|
|
126
|
+
beforeUnmount?: ((() => void) | (() => void)[]) | undefined;
|
|
127
|
+
destroyed?: ((() => void) | (() => void)[]) | undefined;
|
|
128
|
+
unmounted?: ((() => void) | (() => void)[]) | undefined;
|
|
129
|
+
renderTracked?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
|
|
130
|
+
renderTriggered?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
|
|
131
|
+
errorCaptured?: (((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null, info: string) => boolean | void)[]) | undefined;
|
|
132
|
+
};
|
|
133
|
+
$forceUpdate: () => void;
|
|
134
|
+
$nextTick: typeof import("vue").nextTick;
|
|
135
|
+
$watch(source: string | Function, cb: Function, options?: import("vue").WatchOptions<boolean> | undefined): import("vue").WatchStopHandle;
|
|
136
|
+
} & Readonly<import("vue").ExtractPropTypes<{
|
|
137
|
+
readonly size: {
|
|
138
|
+
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
139
|
+
readonly required: false;
|
|
140
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
141
|
+
__epPropKey: true;
|
|
142
|
+
};
|
|
143
|
+
readonly color: {
|
|
144
|
+
readonly type: import("vue").PropType<string>;
|
|
145
|
+
readonly required: false;
|
|
146
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
147
|
+
__epPropKey: true;
|
|
148
|
+
};
|
|
149
|
+
}>> & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties;
|
|
150
|
+
__isFragment?: undefined;
|
|
151
|
+
__isTeleport?: undefined;
|
|
152
|
+
__isSuspense?: undefined;
|
|
153
|
+
} & import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
|
154
|
+
readonly size: {
|
|
155
|
+
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
156
|
+
readonly required: false;
|
|
157
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
158
|
+
__epPropKey: true;
|
|
159
|
+
};
|
|
160
|
+
readonly color: {
|
|
161
|
+
readonly type: import("vue").PropType<string>;
|
|
162
|
+
readonly required: false;
|
|
163
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
164
|
+
__epPropKey: true;
|
|
165
|
+
};
|
|
166
|
+
}>>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, {}> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
|
|
167
|
+
$slots: {
|
|
168
|
+
default?(_: {}): any;
|
|
169
|
+
};
|
|
170
|
+
})>;
|
|
171
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
172
|
+
name: {
|
|
173
|
+
type: StringConstructor;
|
|
174
|
+
required: true;
|
|
175
|
+
};
|
|
176
|
+
type: {
|
|
177
|
+
type: StringConstructor;
|
|
178
|
+
default: string;
|
|
179
|
+
};
|
|
180
|
+
}>>, {
|
|
181
|
+
type: string;
|
|
182
|
+
}>;
|
|
183
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "tab-click" | "tab-close")[], "update:modelValue" | "tab-click" | "tab-close", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
32
184
|
tabList: {
|
|
33
185
|
type: ArrayConstructor;
|
|
34
186
|
default: () => never[];
|
|
@@ -36,10 +188,16 @@ export declare const HzztTab: import("hzzt-plus/es/utils").SFCWithInstall<import
|
|
|
36
188
|
modelValue: {
|
|
37
189
|
type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
|
|
38
190
|
};
|
|
191
|
+
closable: {
|
|
192
|
+
type: BooleanConstructor;
|
|
193
|
+
default: () => boolean;
|
|
194
|
+
};
|
|
39
195
|
}>> & {
|
|
40
196
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
41
197
|
"onTab-click"?: ((...args: any[]) => any) | undefined;
|
|
198
|
+
"onTab-close"?: ((...args: any[]) => any) | undefined;
|
|
42
199
|
}, {
|
|
43
200
|
tabList: unknown[];
|
|
201
|
+
closable: boolean;
|
|
44
202
|
}>> & Record<string, any>;
|
|
45
203
|
export default HzztTab;
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var vue = require('vue');
|
|
6
|
+
var index = require('../../icon/src/index.js');
|
|
6
7
|
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
|
|
7
8
|
|
|
8
9
|
const _hoisted_1 = { class: "hzzt-tab flex align-items-center justify-content-between wrap" };
|
|
@@ -27,9 +28,13 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
27
28
|
},
|
|
28
29
|
modelValue: {
|
|
29
30
|
type: [Number, String, Array]
|
|
31
|
+
},
|
|
32
|
+
closable: {
|
|
33
|
+
type: Boolean,
|
|
34
|
+
default: () => false
|
|
30
35
|
}
|
|
31
36
|
},
|
|
32
|
-
emits: ["update:modelValue", "tab-click"],
|
|
37
|
+
emits: ["update:modelValue", "tab-click", "tab-close"],
|
|
33
38
|
setup(__props, { emit }) {
|
|
34
39
|
const props = __props;
|
|
35
40
|
const customTabList = vue.computed(() => props.tabList.map((value) => {
|
|
@@ -47,11 +52,15 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
47
52
|
emit("update:modelValue", tab.name);
|
|
48
53
|
emit("tab-click", tab, event);
|
|
49
54
|
}
|
|
55
|
+
function close(index, event) {
|
|
56
|
+
event.stopPropagation();
|
|
57
|
+
emit("tab-close", index);
|
|
58
|
+
}
|
|
50
59
|
return (_ctx, _cache) => {
|
|
51
60
|
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
|
|
52
61
|
vue.createElementVNode("div", _hoisted_2, [
|
|
53
62
|
vue.createElementVNode("div", _hoisted_3, [
|
|
54
|
-
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(vue.unref(customTabList), (tab) => {
|
|
63
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(vue.unref(customTabList), (tab, index$1) => {
|
|
55
64
|
return vue.openBlock(), vue.createElementBlock("div", {
|
|
56
65
|
key: tab.key,
|
|
57
66
|
class: "hzzt-tab-pane",
|
|
@@ -61,7 +70,13 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
61
70
|
vue.createElementVNode("p", {
|
|
62
71
|
class: vue.normalizeClass([{ active: __props.modelValue === tab.name }, "hzzt-tab-badge-text"])
|
|
63
72
|
}, vue.toDisplayString(tab.label), 3),
|
|
64
|
-
tab.number && tab.number !== 0 ? (vue.openBlock(), vue.createElementBlock("p", _hoisted_6, vue.toDisplayString(tab.number > 999 ? "999+" : tab.number), 1)) : vue.createCommentVNode("v-if", true)
|
|
73
|
+
tab.number && tab.number !== 0 ? (vue.openBlock(), vue.createElementBlock("p", _hoisted_6, vue.toDisplayString(tab.number > 999 ? "999+" : tab.number), 1)) : vue.createCommentVNode("v-if", true),
|
|
74
|
+
__props.closable ? (vue.openBlock(), vue.createBlock(index["default"], {
|
|
75
|
+
key: 1,
|
|
76
|
+
class: "is-icon-close",
|
|
77
|
+
name: "close",
|
|
78
|
+
onClick: ($event) => close(index$1, $event)
|
|
79
|
+
}, null, 8, ["onClick"])) : vue.createCommentVNode("v-if", true)
|
|
65
80
|
])
|
|
66
81
|
], 8, _hoisted_4);
|
|
67
82
|
}), 128))
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../../../../packages/components/tab/src/index.vue"],"sourcesContent":["<template>\n <div class=\"hzzt-tab flex align-items-center justify-content-between wrap\">\n <div class=\"flex align-items-center\">\n <div class=\"flex\">\n <div\n v-for=\"tab in customTabList\"\n :key=\"tab.key\"\n class=\"hzzt-tab-pane\"\n @click=\"tabClick(tab, $event)\"\n >\n <div class=\"hzzt-tab-badge\">\n <p\n :class=\"{ active: modelValue === tab.name }\"\n class=\"hzzt-tab-badge-text\"\n >\n {{ tab.label }}\n </p>\n <p\n v-if=\"tab.number && tab.number !== 0\"\n class=\"hzzt-tab-badge-count\"\n >\n {{ tab.number > 999 ? '999+' : tab.number }}\n </p>\n </div>\n </div>\n </div>\n <slot name=\"filter\" />\n <slot name=\"extra\" />\n </div>\n <div class=\"flex wrap\">\n <slot name=\"right\" />\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed } from 'vue'\n\ndefineOptions({\n name: 'HzztTab',\n})\n\ndeclare type Tab = {\n name: string\n label: string\n number: number\n hide: boolean\n}\n\nconst props = defineProps({\n tabList: {\n type: Array,\n default: () => [],\n },\n modelValue: {\n type: [Number, String, Array],\n },\n})\n\nconst emit = defineEmits(['update:modelValue', 'tab-click'])\n\nconst customTabList = computed(() =>\n props.tabList\n .map((value) => {\n const tab = value as Tab\n return {\n key: `${tab.name}-${tab.number}` as string,\n ...tab,\n number: Number(tab.number || 0),\n hide: tab.hide,\n }\n })\n .filter((tab) => !tab.hide)\n)\n\nfunction tabClick(tab, event) {\n if (tab.name === props.modelValue) return\n emit('update:modelValue', tab.name)\n emit('tab-click', tab, event)\n}\n</script>\n"],"names":["computed","_openBlock","_createElementBlock"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../../packages/components/tab/src/index.vue"],"sourcesContent":["<template>\n <div class=\"hzzt-tab flex align-items-center justify-content-between wrap\">\n <div class=\"flex align-items-center\">\n <div class=\"flex\">\n <div\n v-for=\"(tab, index) in customTabList\"\n :key=\"tab.key\"\n class=\"hzzt-tab-pane\"\n @click=\"tabClick(tab, $event)\"\n >\n <div class=\"hzzt-tab-badge\">\n <p\n :class=\"{ active: modelValue === tab.name }\"\n class=\"hzzt-tab-badge-text\"\n >\n {{ tab.label }}\n </p>\n <p\n v-if=\"tab.number && tab.number !== 0\"\n class=\"hzzt-tab-badge-count\"\n >\n {{ tab.number > 999 ? '999+' : tab.number }}\n </p>\n <hzzt-icon\n v-if=\"closable\"\n class=\"is-icon-close\"\n name=\"close\"\n @click=\"close(index, $event)\"\n />\n </div>\n </div>\n </div>\n <slot name=\"filter\" />\n <slot name=\"extra\" />\n </div>\n <div class=\"flex wrap\">\n <slot name=\"right\" />\n </div>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed } from 'vue'\nimport HzztIcon from '@hzzt-plus/components/icon/src/index.vue'\n\ndefineOptions({\n name: 'HzztTab',\n})\n\ndeclare type Tab = {\n name: string\n label: string\n number: number\n hide: boolean\n}\n\nconst props = defineProps({\n tabList: {\n type: Array,\n default: () => [],\n },\n modelValue: {\n type: [Number, String, Array],\n },\n closable: {\n type: Boolean,\n default: () => false,\n },\n})\n\nconst emit = defineEmits(['update:modelValue', 'tab-click', 'tab-close'])\n\nconst customTabList = computed(() =>\n props.tabList\n .map((value) => {\n const tab = value as Tab\n return {\n key: `${tab.name}-${tab.number}` as string,\n ...tab,\n number: Number(tab.number || 0),\n hide: tab.hide,\n }\n })\n .filter((tab) => !tab.hide)\n)\n\nfunction tabClick(tab: Tab, event: Event) {\n if (tab.name === props.modelValue) return\n emit('update:modelValue', tab.name)\n emit('tab-click', tab, event)\n}\n\nfunction close(index: number, event: Event) {\n event.stopPropagation()\n emit('tab-close', index)\n}\n</script>\n"],"names":["computed","_openBlock","_createElementBlock"],"mappings":";;;;;;;;;;;;;;;;;;uCA6Cc,CAAA;AAAA,EACZ,IAAM,EAAA,SAAA;AACR,CAAA,CAAA,CAAA;;;;;;;;;;;;;;;;;;;AAyBA,IAAA,MAAM,aAAgB,GAAAA,YAAA,CAAA,MAAA,KAAA,CAAA,OAAA,CAAA,GAAA,CAAA,CAAA,KAAA,KAAA;AAAA,MAAS,MAC7B,GAAA,GAAM,KACH,CAAA;AACC,MAAA,OAAA;AACA,QAAO,GAAA,EAAA,CAAA,EAAA,GAAA,CAAA,IAAA,CAAA,CAAA,EAAA,GAAA,CAAA,MAAA,CAAA,CAAA;AAAA,QAAA;AACyB,QAAA,MAC3B,EAAA,MAAA,CAAA,GAAA,CAAA,MAAA,IAAA,CAAA,CAAA;AAAA,QAAA,IACK,EAAA,GAAA,CAAA,IAAA;AAAsB,OAAA,CAAA;AACpB,KACZ,CAAA,CAAA,MAAA,CAAA,CAAA,GAAA,KAAA,CAAA,GAAA,CAAA,IAAA,CAAA,CAAA,CAAA;AAAA,IAAA,SAED,QAAgB,CAAA,GAAA,OAAS,EAAA;AAAA,MAC9B,IAAA,GAAA,CAAA,IAAA,KAAA,KAAA,CAAA,UAAA;AAEA,QAAS,OAAA;AACP,MAAI,IAAA,CAAA,mBAAmB,EAAA,GAAA,CAAA,IAAA,CAAA,CAAA;AAAY,MAAA,IAAA,CAAA,WAAA,EAAA,GAAA,EAAA,KAAA,CAAA,CAAA;AACnC,KAAK;AACL,IAAK,SAAA,KAAA,CAAA,KAAa,OAAU,EAAA;AAAA,MAC9B,KAAA,CAAA,eAAA,EAAA,CAAA;AAEA,MAAS,IAAA,CAAA,kBAAmC,CAAA,CAAA;AAC1C,KAAA;AACA,IAAA,OAAK,aAAa,KAAK;AAAA,MACzB,OAAAC,aAAA,EAAA,EAAAC,sBAAA,CAAA,KAAA,EAAA,UAAA,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
declare type Tab = {
|
|
2
|
+
name: string;
|
|
3
|
+
label: string;
|
|
4
|
+
number: number;
|
|
5
|
+
hide: boolean;
|
|
6
|
+
};
|
|
1
7
|
declare const _default: import("vue").DefineComponent<{
|
|
2
8
|
tabList: {
|
|
3
9
|
type: ArrayConstructor;
|
|
@@ -6,6 +12,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
6
12
|
modelValue: {
|
|
7
13
|
type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
|
|
8
14
|
};
|
|
15
|
+
closable: {
|
|
16
|
+
type: BooleanConstructor;
|
|
17
|
+
default: () => boolean;
|
|
18
|
+
};
|
|
9
19
|
}, {
|
|
10
20
|
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
11
21
|
tabList: {
|
|
@@ -15,11 +25,16 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
15
25
|
modelValue: {
|
|
16
26
|
type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
|
|
17
27
|
};
|
|
28
|
+
closable: {
|
|
29
|
+
type: BooleanConstructor;
|
|
30
|
+
default: () => boolean;
|
|
31
|
+
};
|
|
18
32
|
}>> & {
|
|
19
33
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
20
34
|
"onTab-click"?: ((...args: any[]) => any) | undefined;
|
|
35
|
+
"onTab-close"?: ((...args: any[]) => any) | undefined;
|
|
21
36
|
}>>;
|
|
22
|
-
emit: (event: "update:modelValue" | "tab-click", ...args: any[]) => void;
|
|
37
|
+
emit: (event: "update:modelValue" | "tab-click" | "tab-close", ...args: any[]) => void;
|
|
23
38
|
customTabList: import("vue").ComputedRef<{
|
|
24
39
|
number: number;
|
|
25
40
|
hide: boolean;
|
|
@@ -27,8 +42,146 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
27
42
|
label: string;
|
|
28
43
|
key: string;
|
|
29
44
|
}[]>;
|
|
30
|
-
tabClick: (tab:
|
|
31
|
-
|
|
45
|
+
tabClick: (tab: Tab, event: Event) => void;
|
|
46
|
+
close: (index: number, event: Event) => void;
|
|
47
|
+
HzztIcon: import("vue").DefineComponent<{
|
|
48
|
+
name: {
|
|
49
|
+
type: StringConstructor;
|
|
50
|
+
required: true;
|
|
51
|
+
};
|
|
52
|
+
type: {
|
|
53
|
+
type: StringConstructor;
|
|
54
|
+
default: string;
|
|
55
|
+
};
|
|
56
|
+
}, {
|
|
57
|
+
props: Readonly<import("@vue/shared").LooseRequired<Readonly<import("vue").ExtractPropTypes<{
|
|
58
|
+
name: {
|
|
59
|
+
type: StringConstructor;
|
|
60
|
+
required: true;
|
|
61
|
+
};
|
|
62
|
+
type: {
|
|
63
|
+
type: StringConstructor;
|
|
64
|
+
default: string;
|
|
65
|
+
};
|
|
66
|
+
}>> & {
|
|
67
|
+
[x: string & `on${string}`]: ((...args: any[]) => any) | ((...args: unknown[]) => any) | undefined;
|
|
68
|
+
}>>;
|
|
69
|
+
attrs: {
|
|
70
|
+
[x: string]: unknown;
|
|
71
|
+
};
|
|
72
|
+
componentName: import("vue").ComputedRef<string>;
|
|
73
|
+
ElIcon: import("element-plus/es/utils").SFCWithInstall<{
|
|
74
|
+
new (...args: any[]): {
|
|
75
|
+
$: import("vue").ComponentInternalInstance;
|
|
76
|
+
$data: {};
|
|
77
|
+
$props: Partial<{}> & Omit<Readonly<import("vue").ExtractPropTypes<{
|
|
78
|
+
readonly size: {
|
|
79
|
+
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
80
|
+
readonly required: false;
|
|
81
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
82
|
+
__epPropKey: true;
|
|
83
|
+
};
|
|
84
|
+
readonly color: {
|
|
85
|
+
readonly type: import("vue").PropType<string>;
|
|
86
|
+
readonly required: false;
|
|
87
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
88
|
+
__epPropKey: true;
|
|
89
|
+
};
|
|
90
|
+
}>> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, never>;
|
|
91
|
+
$attrs: {
|
|
92
|
+
[x: string]: unknown;
|
|
93
|
+
};
|
|
94
|
+
$refs: {
|
|
95
|
+
[x: string]: unknown;
|
|
96
|
+
};
|
|
97
|
+
$slots: Readonly<{
|
|
98
|
+
[name: string]: import("vue").Slot | undefined;
|
|
99
|
+
}>;
|
|
100
|
+
$root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null;
|
|
101
|
+
$parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null;
|
|
102
|
+
$emit: (event: string, ...args: any[]) => void;
|
|
103
|
+
$el: any;
|
|
104
|
+
$options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
|
105
|
+
readonly size: {
|
|
106
|
+
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
107
|
+
readonly required: false;
|
|
108
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
109
|
+
__epPropKey: true;
|
|
110
|
+
};
|
|
111
|
+
readonly color: {
|
|
112
|
+
readonly type: import("vue").PropType<string>;
|
|
113
|
+
readonly required: false;
|
|
114
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
115
|
+
__epPropKey: true;
|
|
116
|
+
};
|
|
117
|
+
}>>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, {}> & {
|
|
118
|
+
beforeCreate?: ((() => void) | (() => void)[]) | undefined;
|
|
119
|
+
created?: ((() => void) | (() => void)[]) | undefined;
|
|
120
|
+
beforeMount?: ((() => void) | (() => void)[]) | undefined;
|
|
121
|
+
mounted?: ((() => void) | (() => void)[]) | undefined;
|
|
122
|
+
beforeUpdate?: ((() => void) | (() => void)[]) | undefined;
|
|
123
|
+
updated?: ((() => void) | (() => void)[]) | undefined;
|
|
124
|
+
activated?: ((() => void) | (() => void)[]) | undefined;
|
|
125
|
+
deactivated?: ((() => void) | (() => void)[]) | undefined;
|
|
126
|
+
beforeDestroy?: ((() => void) | (() => void)[]) | undefined;
|
|
127
|
+
beforeUnmount?: ((() => void) | (() => void)[]) | undefined;
|
|
128
|
+
destroyed?: ((() => void) | (() => void)[]) | undefined;
|
|
129
|
+
unmounted?: ((() => void) | (() => void)[]) | undefined;
|
|
130
|
+
renderTracked?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
|
|
131
|
+
renderTriggered?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
|
|
132
|
+
errorCaptured?: (((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null, info: string) => boolean | void)[]) | undefined;
|
|
133
|
+
};
|
|
134
|
+
$forceUpdate: () => void;
|
|
135
|
+
$nextTick: typeof import("vue").nextTick;
|
|
136
|
+
$watch(source: string | Function, cb: Function, options?: import("vue").WatchOptions<boolean> | undefined): import("vue").WatchStopHandle;
|
|
137
|
+
} & Readonly<import("vue").ExtractPropTypes<{
|
|
138
|
+
readonly size: {
|
|
139
|
+
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
140
|
+
readonly required: false;
|
|
141
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
142
|
+
__epPropKey: true;
|
|
143
|
+
};
|
|
144
|
+
readonly color: {
|
|
145
|
+
readonly type: import("vue").PropType<string>;
|
|
146
|
+
readonly required: false;
|
|
147
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
148
|
+
__epPropKey: true;
|
|
149
|
+
};
|
|
150
|
+
}>> & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties;
|
|
151
|
+
__isFragment?: undefined;
|
|
152
|
+
__isTeleport?: undefined;
|
|
153
|
+
__isSuspense?: undefined;
|
|
154
|
+
} & import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
|
|
155
|
+
readonly size: {
|
|
156
|
+
readonly type: import("vue").PropType<import("element-plus/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
|
|
157
|
+
readonly required: false;
|
|
158
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
159
|
+
__epPropKey: true;
|
|
160
|
+
};
|
|
161
|
+
readonly color: {
|
|
162
|
+
readonly type: import("vue").PropType<string>;
|
|
163
|
+
readonly required: false;
|
|
164
|
+
readonly validator: ((val: unknown) => boolean) | undefined;
|
|
165
|
+
__epPropKey: true;
|
|
166
|
+
};
|
|
167
|
+
}>>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, {}> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
|
|
168
|
+
$slots: {
|
|
169
|
+
default?(_: {}): any;
|
|
170
|
+
};
|
|
171
|
+
})>;
|
|
172
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
173
|
+
name: {
|
|
174
|
+
type: StringConstructor;
|
|
175
|
+
required: true;
|
|
176
|
+
};
|
|
177
|
+
type: {
|
|
178
|
+
type: StringConstructor;
|
|
179
|
+
default: string;
|
|
180
|
+
};
|
|
181
|
+
}>>, {
|
|
182
|
+
type: string;
|
|
183
|
+
}>;
|
|
184
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "tab-click" | "tab-close")[], "update:modelValue" | "tab-click" | "tab-close", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
32
185
|
tabList: {
|
|
33
186
|
type: ArrayConstructor;
|
|
34
187
|
default: () => never[];
|
|
@@ -36,10 +189,16 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
36
189
|
modelValue: {
|
|
37
190
|
type: (ArrayConstructor | NumberConstructor | StringConstructor)[];
|
|
38
191
|
};
|
|
192
|
+
closable: {
|
|
193
|
+
type: BooleanConstructor;
|
|
194
|
+
default: () => boolean;
|
|
195
|
+
};
|
|
39
196
|
}>> & {
|
|
40
197
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
41
198
|
"onTab-click"?: ((...args: any[]) => any) | undefined;
|
|
199
|
+
"onTab-close"?: ((...args: any[]) => any) | undefined;
|
|
42
200
|
}, {
|
|
43
201
|
tabList: unknown[];
|
|
202
|
+
closable: boolean;
|
|
44
203
|
}>;
|
|
45
204
|
export default _default;
|
package/package.json
CHANGED
package/theme/hzzt-collapse.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.hzzt-collapse{color:#000;position:relative}.hzzt-collapse .hzzt-collapse-header{height:28px}.hzzt-collapse .hzzt-collapse-header .hzzt-collapse-title{color:#606266;font-size:16px;font-weight:800;height:26px;line-height:26px;min-width:85px;padding-left:20px;z-index:99}.hzzt-collapse .hzzt-collapse-header .hzzt-collapse-title-block{background-color:rgba(43,83,193,.1);height:14px;left:0;position:absolute;top:12px;width:85px}.hzzt-collapse .hzzt-collapse-header .hzzt-collapse-line{border-bottom:1px solid #d5e1f3;height:1px;width:100%}.hzzt-collapse .hzzt-collapse-header .hzzt-collapse-text{color:var(--hzzt-color-primary);cursor:pointer;font-size:14px;position:absolute;right:10px;top:-6px}.hzzt-collapse .hzzt-collapse-icon{width:18px}html.dark .hzzt-collapse-title{color:var(--hzzt-text-color-primary)}
|
|
1
|
+
.hzzt-collapse{color:#000;position:relative}.hzzt-collapse .hzzt-collapse-header{height:28px}.hzzt-collapse .hzzt-collapse-header .hzzt-collapse-title{color:#606266;font-size:16px;font-weight:800;height:26px;line-height:26px;min-width:85px;padding-left:20px;white-space:nowrap;z-index:99}.hzzt-collapse .hzzt-collapse-header .hzzt-collapse-title-block{background-color:rgba(43,83,193,.1);height:14px;left:0;position:absolute;top:12px;width:85px}.hzzt-collapse .hzzt-collapse-header .hzzt-collapse-line{border-bottom:1px solid #d5e1f3;height:1px;width:100%}.hzzt-collapse .hzzt-collapse-header .hzzt-collapse-text{color:var(--hzzt-color-primary);cursor:pointer;font-size:14px;position:absolute;right:10px;top:-6px}.hzzt-collapse .hzzt-collapse-icon{width:18px}html.dark .hzzt-collapse-title{color:var(--hzzt-text-color-primary)}
|
package/theme/hzzt-tab.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.hzzt-tab{font-size:14px;margin-bottom:
|
|
1
|
+
.hzzt-tab{font-size:14px;margin-bottom:4px}.hzzt-tab p{margin:0}.hzzt-tab .hzzt-tab-pane{cursor:pointer;font-size:14px;padding-right:12px}.hzzt-tab .hzzt-tab-pane:hover{color:var(--hzzt-color-primary)}.hzzt-tab .hzzt-tab-badge{align-items:center;display:flex;white-space:nowrap}.hzzt-tab .hzzt-tab-badge .hzzt-tab-badge-text{font-size:14px;line-height:28px;margin:0;position:relative}.hzzt-tab .hzzt-tab-badge .hzzt-tab-badge-text.active{color:var(--hzzt-color-primary);font-weight:bold}.hzzt-tab .hzzt-tab-badge .hzzt-tab-badge-text.active:before{background-color:var(--hzzt-color-primary);bottom:0;content:"";height:2PX;left:0;position:absolute;right:0}.hzzt-tab .hzzt-tab-badge .hzzt-tab-badge-count{background-color:var(--hzzt-color-danger);border-radius:15px;color:#fff;font-size:10px;line-height:1;margin:0 0 0 1px;min-width:20px;padding:2px 6px;text-align:center}.hzzt-tab .hzzt-tab-badge .is-icon-close{border-radius:50%;margin-left:4px}.hzzt-tab .hzzt-tab-badge .is-icon-close:hover{background-color:var(--hzzt-text-color-placeholder);color:#fff}
|