ep-craft 0.1.22 → 0.1.23
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/affix/affix.d.ts +19 -19
- package/dist/components/affix/affix.js +61 -53
- package/dist/components/alert/alert.d.ts +71 -17
- package/dist/components/alert/alert.js +99 -43
- package/dist/components/anchor/anchor.d.ts +19 -19
- package/dist/components/anchor/anchor.js +166 -102
- package/dist/components/anchor/constants.d.ts +15 -0
- package/dist/components/anchor/constants.js +4 -0
- package/dist/components/anchor-link/anchor-link.d.ts +1 -1
- package/dist/components/anchor-link/anchor-link.js +39 -26
- package/dist/components/button/EpButton.vue.d.ts +8 -8
- package/dist/components/button/EpButton.vue.js +5 -5
- package/dist/components/button/constants.d.ts +7 -0
- package/dist/components/button/constants.js +6 -0
- package/dist/components/check-tag/EpCheckTag.vue.d.ts +1 -1
- package/dist/components/collapse-transition/index.js +2 -2
- package/dist/components/config-provider/src/constants.js +4 -0
- package/dist/components/config-provider/src/hooks/use-global-config.d.ts +1 -1
- package/dist/components/config-provider/src/hooks/use-global-config.js +24 -0
- package/dist/components/form/src/constants.js +2 -1
- package/dist/components/form/src/hooks/use-form-common-props.d.ts +2 -2
- package/dist/components/form/src/hooks/use-form-common-props.js +17 -0
- package/dist/components/form/src/hooks/use-form-item.js +51 -0
- package/dist/components/icon/index.js +5 -5
- package/dist/components/menu/menu-collapse-transition.vue.js +10 -6
- package/dist/components/menu/menu.d.ts +47 -47
- package/dist/components/menu/menu.js +59 -52
- package/dist/components/menu/use-menu-color.d.ts +2 -0
- package/dist/components/menu/use-menu-color.js +11 -0
- package/dist/components/menu/use-menu-css-var.d.ts +2 -0
- package/dist/components/menu/use-menu-css-var.js +30 -0
- package/dist/components/menu/utils/menu-bar.d.ts +7 -0
- package/dist/components/menu/utils/menu-bar.js +15 -0
- package/dist/components/menu/utils/menu-item.d.ts +9 -0
- package/dist/components/menu/utils/menu-item.js +50 -0
- package/dist/components/menu/utils/submenu.d.ts +11 -0
- package/dist/components/menu/utils/submenu.js +49 -0
- package/dist/components/menu-item/EpMenuItem.vue.js +17 -13
- package/dist/components/menu-item-group/EpMenuItemGroup.vue.js +1 -1
- package/dist/components/popper/src/composables/use-content.d.ts +6 -6
- package/dist/components/popper/src/content.vue.d.ts +6 -6
- package/dist/components/popper/src/popper.d.ts +2 -2
- package/dist/components/radio/constants.d.ts +64 -0
- package/dist/components/radio/constants.js +4 -0
- package/dist/components/radio/radio.d.ts +98 -19
- package/dist/components/radio/radio.js +101 -43
- package/dist/components/radio/use-radio.d.ts +13 -0
- package/dist/components/radio/use-radio.js +43 -0
- package/dist/components/radio-button/radio-button.d.ts +46 -16
- package/dist/components/radio-button/radio-button.js +37 -29
- package/dist/components/radio-group/radio-group.d.ts +142 -28
- package/dist/components/radio-group/radio-group.js +136 -55
- package/dist/components/sub-menu/sub-menu.d.ts +19 -19
- package/dist/components/sub-menu/sub-menu.js +65 -58
- package/dist/components/tab-pane/tab-pane.d.ts +45 -8
- package/dist/components/tab-pane/tab-pane.js +66 -32
- package/dist/components/tabs/composables/use-tab-nav-touch.d.ts +19 -0
- package/dist/components/tabs/composables/use-tab-nav-touch.js +58 -0
- package/dist/components/tabs/constants.d.ts +63 -0
- package/dist/components/tabs/constants.js +4 -0
- package/dist/components/tabs/tab-bar.d.ts +97 -0
- package/dist/components/tabs/tab-bar.vue.d.ts +14 -0
- package/dist/components/tabs/tab-bar.vue.js +80 -0
- package/dist/components/tabs/tab-bar2.vue.js +4 -0
- package/dist/components/tabs/tab-nav.d.ts +295 -0
- package/dist/components/tabs/tab-nav.js +297 -0
- package/dist/components/tabs/tabs.d.ts +71 -28
- package/dist/components/tabs/tabs.js +165 -93
- package/dist/components/tag/EpTag.vue.d.ts +3 -3
- package/dist/components/tag/EpTag.vue.js +3 -3
- package/dist/components/tooltip/index.d.ts +34 -34
- package/dist/components/tooltip/index.js +12 -12
- package/dist/components/tooltip/src/content.vue.d.ts +8 -8
- package/dist/components/tooltip/src/tooltip.d.ts +2 -2
- package/dist/components/tooltip/src/tooltip.vue.d.ts +12 -12
- package/dist/components/tooltip/src/trigger.d.ts +1 -1
- package/dist/constants/event.js +5 -0
- package/dist/directives/click-outside/index.js +49 -0
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/use-deprecated/index.js +25 -0
- package/dist/hooks/use-locale/index.js +24 -0
- package/dist/hooks/use-ordered-children/index.js +53 -0
- package/dist/hooks/use-popper/index.d.ts +6 -6
- package/dist/hooks/use-prop/index.js +11 -0
- package/dist/hooks/use-size/index.d.ts +3 -3
- package/dist/hooks/use-size/index.js +14 -6
- package/dist/hooks/use-wheel/defaults.d.ts +27 -0
- package/dist/hooks/use-wheel/defaults.js +4 -0
- package/dist/hooks/use-wheel/index.d.ts +13 -0
- package/dist/hooks/use-wheel/index.js +26 -0
- package/dist/utils/browser.js +6 -5
- package/dist/utils/dom/aria.js +13 -6
- package/dist/utils/dom/element.js +16 -0
- package/dist/utils/dom/position.js +18 -0
- package/dist/utils/dom/scroll.js +50 -0
- package/dist/utils/dom/style.js +40 -13
- package/dist/utils/easings.js +7 -0
- package/dist/utils/error.js +11 -7
- package/dist/utils/numbers.js +6 -0
- package/dist/utils/objects.js +7 -0
- package/dist/utils/raf.js +6 -0
- package/dist/utils/strings.js +8 -0
- package/dist/utils/throttleByRaf.js +15 -0
- package/dist/utils/types.js +19 -16
- package/dist/utils/typescript.js +4 -0
- package/dist/utils/vue/icon.js +20 -0
- package/dist/utils/vue/vnode.d.ts +4 -4
- package/dist/utils/vue/vnode.js +17 -0
- package/dist/vendored-components.d.ts +6 -3
- package/dist/vendored-components.js +11 -5
- package/package.json +1 -1
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import type { ExtractPublicPropTypes } from 'vue';
|
|
2
|
+
import type { TabPaneName, TabsPaneContext } from './constants';
|
|
3
|
+
import type TabBar from './tab-bar.vue';
|
|
4
|
+
/**
|
|
5
|
+
* @deprecated Removed after 3.0.0, Use `TabBarProps` instead.
|
|
6
|
+
*/
|
|
7
|
+
export declare const tabBarProps: {
|
|
8
|
+
readonly tabs: import("@element-plus/utils").EpPropFinalized<(new (...args: any[]) => {
|
|
9
|
+
uid: number;
|
|
10
|
+
getVnode: () => import("vue").VNode;
|
|
11
|
+
slots: import("vue").Slots;
|
|
12
|
+
props: {
|
|
13
|
+
label?: string | undefined;
|
|
14
|
+
name?: string | number | undefined;
|
|
15
|
+
closable?: boolean | undefined;
|
|
16
|
+
disabled?: boolean | undefined;
|
|
17
|
+
lazy?: boolean | undefined;
|
|
18
|
+
};
|
|
19
|
+
paneName: TabPaneName | undefined;
|
|
20
|
+
active: boolean;
|
|
21
|
+
index: string | undefined;
|
|
22
|
+
isClosable: boolean;
|
|
23
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
24
|
+
}[]) | (() => {
|
|
25
|
+
uid: number;
|
|
26
|
+
getVnode: () => import("vue").VNode;
|
|
27
|
+
slots: import("vue").Slots;
|
|
28
|
+
props: {
|
|
29
|
+
label?: string | undefined;
|
|
30
|
+
name?: string | number | undefined;
|
|
31
|
+
closable?: boolean | undefined;
|
|
32
|
+
disabled?: boolean | undefined;
|
|
33
|
+
lazy?: boolean | undefined;
|
|
34
|
+
};
|
|
35
|
+
paneName: TabPaneName | undefined;
|
|
36
|
+
active: boolean;
|
|
37
|
+
index: string | undefined;
|
|
38
|
+
isClosable: boolean;
|
|
39
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
40
|
+
}[]) | (((new (...args: any[]) => {
|
|
41
|
+
uid: number;
|
|
42
|
+
getVnode: () => import("vue").VNode;
|
|
43
|
+
slots: import("vue").Slots;
|
|
44
|
+
props: {
|
|
45
|
+
label?: string | undefined;
|
|
46
|
+
name?: string | number | undefined;
|
|
47
|
+
closable?: boolean | undefined;
|
|
48
|
+
disabled?: boolean | undefined;
|
|
49
|
+
lazy?: boolean | undefined;
|
|
50
|
+
};
|
|
51
|
+
paneName: TabPaneName | undefined;
|
|
52
|
+
active: boolean;
|
|
53
|
+
index: string | undefined;
|
|
54
|
+
isClosable: boolean;
|
|
55
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
56
|
+
}[]) | (() => {
|
|
57
|
+
uid: number;
|
|
58
|
+
getVnode: () => import("vue").VNode;
|
|
59
|
+
slots: import("vue").Slots;
|
|
60
|
+
props: {
|
|
61
|
+
label?: string | undefined;
|
|
62
|
+
name?: string | number | undefined;
|
|
63
|
+
closable?: boolean | undefined;
|
|
64
|
+
disabled?: boolean | undefined;
|
|
65
|
+
lazy?: boolean | undefined;
|
|
66
|
+
};
|
|
67
|
+
paneName: TabPaneName | undefined;
|
|
68
|
+
active: boolean;
|
|
69
|
+
index: string | undefined;
|
|
70
|
+
isClosable: boolean;
|
|
71
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
72
|
+
}[])) | null)[], unknown, unknown, () => [], boolean>;
|
|
73
|
+
readonly tabRefs: import("@element-plus/utils").EpPropFinalized<(new (...args: any[]) => {
|
|
74
|
+
[key: string]: HTMLDivElement;
|
|
75
|
+
[key: number]: HTMLDivElement;
|
|
76
|
+
}) | (() => {
|
|
77
|
+
[key: string]: HTMLDivElement;
|
|
78
|
+
[key: number]: HTMLDivElement;
|
|
79
|
+
}) | (((new (...args: any[]) => {
|
|
80
|
+
[key: string]: HTMLDivElement;
|
|
81
|
+
[key: number]: HTMLDivElement;
|
|
82
|
+
}) | (() => {
|
|
83
|
+
[key: string]: HTMLDivElement;
|
|
84
|
+
[key: number]: HTMLDivElement;
|
|
85
|
+
})) | null)[], unknown, unknown, () => import("@element-plus/utils").Mutable<{}>, boolean>;
|
|
86
|
+
};
|
|
87
|
+
export type TabBarProps = {
|
|
88
|
+
tabs?: TabsPaneContext[];
|
|
89
|
+
tabRefs?: {
|
|
90
|
+
[key: TabPaneName]: HTMLDivElement;
|
|
91
|
+
};
|
|
92
|
+
};
|
|
93
|
+
/**
|
|
94
|
+
* @deprecated Removed after 3.0.0, Use `TabBarProps` instead.
|
|
95
|
+
*/
|
|
96
|
+
export type TabBarPropsPublic = ExtractPublicPropTypes<typeof tabBarProps>;
|
|
97
|
+
export type TabBarInstance = InstanceType<typeof TabBar> & unknown;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { TabBarProps } from './tab-bar';
|
|
2
|
+
import type { CSSProperties } from 'vue';
|
|
3
|
+
declare const _default: import("vue").DefineComponent<TabBarProps, {
|
|
4
|
+
/** @description tab root html element */
|
|
5
|
+
ref: import("vue").Ref<HTMLDivElement | undefined, HTMLDivElement | undefined>;
|
|
6
|
+
/** @description method to manually update tab bar style, return the updated style */
|
|
7
|
+
update: () => CSSProperties;
|
|
8
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<TabBarProps> & Readonly<{}>, {
|
|
9
|
+
tabs: import("./constants").TabsPaneContext[];
|
|
10
|
+
tabRefs: {
|
|
11
|
+
[key: import("./constants").TabPaneName]: HTMLDivElement;
|
|
12
|
+
};
|
|
13
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
14
|
+
export default _default;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { defineComponent as B, inject as C, ref as h, computed as O, watch as S, nextTick as $, onBeforeUnmount as k, openBlock as T, createElementBlock as F, normalizeStyle as P, normalizeClass as j, unref as c, createCommentVNode as A } from "vue";
|
|
2
|
+
import { useResizeObserver as v } from "@vueuse/core";
|
|
3
|
+
import { isUndefined as y } from "../../utils/types.js";
|
|
4
|
+
import "lodash-unified";
|
|
5
|
+
import { throwError as L } from "../../utils/error.js";
|
|
6
|
+
import "@vue/shared";
|
|
7
|
+
import { capitalize as b } from "../../utils/strings.js";
|
|
8
|
+
import "@element-plus/icons-vue";
|
|
9
|
+
import { useNamespace as M } from "../../hooks/use-namespace/index.js";
|
|
10
|
+
import "../../hooks/use-size/index.js";
|
|
11
|
+
import "@popperjs/core";
|
|
12
|
+
import "../../hooks/use-z-index/index.js";
|
|
13
|
+
import "../../hooks/use-delayed-toggle/index.js";
|
|
14
|
+
import "../../hooks/use-aria/index.js";
|
|
15
|
+
import "../../hooks/use-model-toggle/index.js";
|
|
16
|
+
import "../../hooks/use-empty-values/index.js";
|
|
17
|
+
import { tabsRootContextKey as U } from "./constants.js";
|
|
18
|
+
const N = "ElTabBar", ae = /* @__PURE__ */ B({
|
|
19
|
+
name: N,
|
|
20
|
+
__name: "tab-bar",
|
|
21
|
+
props: {
|
|
22
|
+
tabs: { default: () => [] },
|
|
23
|
+
tabRefs: { default: () => ({}) }
|
|
24
|
+
},
|
|
25
|
+
setup(g, { expose: x }) {
|
|
26
|
+
const r = g, o = C(U);
|
|
27
|
+
o || L(N, "<el-tabs><el-tab-bar /></el-tabs>");
|
|
28
|
+
const u = M("tabs"), p = h(), m = h(), w = O(
|
|
29
|
+
() => {
|
|
30
|
+
var e;
|
|
31
|
+
return y(o.props.defaultValue) || !!((e = m.value) != null && e.transform);
|
|
32
|
+
}
|
|
33
|
+
), E = () => {
|
|
34
|
+
let e = 0, s = 0;
|
|
35
|
+
const n = ["top", "bottom"].includes(o.props.tabPosition) ? "width" : "height", d = n === "width" ? "x" : "y", z = d === "x" ? "left" : "top";
|
|
36
|
+
return r.tabs.every((l) => {
|
|
37
|
+
if (y(l.paneName)) return !1;
|
|
38
|
+
const i = r.tabRefs[l.paneName];
|
|
39
|
+
if (!i) return !1;
|
|
40
|
+
if (!l.active)
|
|
41
|
+
return !0;
|
|
42
|
+
e = i[`offset${b(z)}`], s = i[`client${b(n)}`];
|
|
43
|
+
const f = window.getComputedStyle(i);
|
|
44
|
+
return n === "width" && (s -= Number.parseFloat(f.paddingLeft) + Number.parseFloat(f.paddingRight), e += Number.parseFloat(f.paddingLeft)), !1;
|
|
45
|
+
}), {
|
|
46
|
+
[n]: `${s}px`,
|
|
47
|
+
transform: `translate${b(d)}(${e}px)`
|
|
48
|
+
};
|
|
49
|
+
}, a = () => m.value = E(), t = [], R = () => {
|
|
50
|
+
t.forEach((e) => e.stop()), t.length = 0, Object.values(r.tabRefs).forEach((e) => {
|
|
51
|
+
t.push(v(e, a));
|
|
52
|
+
});
|
|
53
|
+
};
|
|
54
|
+
S(
|
|
55
|
+
() => r.tabs,
|
|
56
|
+
async () => {
|
|
57
|
+
await $(), a(), R();
|
|
58
|
+
},
|
|
59
|
+
{ immediate: !0 }
|
|
60
|
+
);
|
|
61
|
+
const _ = v(p, () => a());
|
|
62
|
+
return k(() => {
|
|
63
|
+
t.forEach((e) => e.stop()), t.length = 0, _.stop();
|
|
64
|
+
}), x({
|
|
65
|
+
/** @description tab root html element */
|
|
66
|
+
ref: p,
|
|
67
|
+
/** @description method to manually update tab bar style, return the updated style */
|
|
68
|
+
update: a
|
|
69
|
+
}), (e, s) => w.value ? (T(), F("div", {
|
|
70
|
+
key: 0,
|
|
71
|
+
ref_key: "barRef",
|
|
72
|
+
ref: p,
|
|
73
|
+
class: j([c(u).e("active-bar"), c(u).is(c(o).props.tabPosition)]),
|
|
74
|
+
style: P(m.value)
|
|
75
|
+
}, null, 6)) : A("", !0);
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
export {
|
|
79
|
+
ae as default
|
|
80
|
+
};
|
|
@@ -0,0 +1,295 @@
|
|
|
1
|
+
import type { ExtractPropTypes, ExtractPublicPropTypes } from 'vue';
|
|
2
|
+
import type { TabBarInstance } from './tab-bar';
|
|
3
|
+
import type { TabPaneName, TabsPaneContext } from './constants';
|
|
4
|
+
export declare const tabNavProps: {
|
|
5
|
+
readonly panes: import("@element-plus/utils").EpPropFinalized<(new (...args: any[]) => {
|
|
6
|
+
uid: number;
|
|
7
|
+
getVnode: () => import("vue").VNode;
|
|
8
|
+
slots: import("vue").Slots;
|
|
9
|
+
props: {
|
|
10
|
+
label?: string | undefined;
|
|
11
|
+
name?: string | number | undefined;
|
|
12
|
+
closable?: boolean | undefined;
|
|
13
|
+
disabled?: boolean | undefined;
|
|
14
|
+
lazy?: boolean | undefined;
|
|
15
|
+
};
|
|
16
|
+
paneName: TabPaneName | undefined;
|
|
17
|
+
active: boolean;
|
|
18
|
+
index: string | undefined;
|
|
19
|
+
isClosable: boolean;
|
|
20
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
21
|
+
}[]) | (() => {
|
|
22
|
+
uid: number;
|
|
23
|
+
getVnode: () => import("vue").VNode;
|
|
24
|
+
slots: import("vue").Slots;
|
|
25
|
+
props: {
|
|
26
|
+
label?: string | undefined;
|
|
27
|
+
name?: string | number | undefined;
|
|
28
|
+
closable?: boolean | undefined;
|
|
29
|
+
disabled?: boolean | undefined;
|
|
30
|
+
lazy?: boolean | undefined;
|
|
31
|
+
};
|
|
32
|
+
paneName: TabPaneName | undefined;
|
|
33
|
+
active: boolean;
|
|
34
|
+
index: string | undefined;
|
|
35
|
+
isClosable: boolean;
|
|
36
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
37
|
+
}[]) | (((new (...args: any[]) => {
|
|
38
|
+
uid: number;
|
|
39
|
+
getVnode: () => import("vue").VNode;
|
|
40
|
+
slots: import("vue").Slots;
|
|
41
|
+
props: {
|
|
42
|
+
label?: string | undefined;
|
|
43
|
+
name?: string | number | undefined;
|
|
44
|
+
closable?: boolean | undefined;
|
|
45
|
+
disabled?: boolean | undefined;
|
|
46
|
+
lazy?: boolean | undefined;
|
|
47
|
+
};
|
|
48
|
+
paneName: TabPaneName | undefined;
|
|
49
|
+
active: boolean;
|
|
50
|
+
index: string | undefined;
|
|
51
|
+
isClosable: boolean;
|
|
52
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
53
|
+
}[]) | (() => {
|
|
54
|
+
uid: number;
|
|
55
|
+
getVnode: () => import("vue").VNode;
|
|
56
|
+
slots: import("vue").Slots;
|
|
57
|
+
props: {
|
|
58
|
+
label?: string | undefined;
|
|
59
|
+
name?: string | number | undefined;
|
|
60
|
+
closable?: boolean | undefined;
|
|
61
|
+
disabled?: boolean | undefined;
|
|
62
|
+
lazy?: boolean | undefined;
|
|
63
|
+
};
|
|
64
|
+
paneName: TabPaneName | undefined;
|
|
65
|
+
active: boolean;
|
|
66
|
+
index: string | undefined;
|
|
67
|
+
isClosable: boolean;
|
|
68
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
69
|
+
}[])) | null)[], unknown, unknown, () => [], boolean>;
|
|
70
|
+
readonly currentName: import("@element-plus/utils").EpPropFinalized<readonly [StringConstructor, NumberConstructor], unknown, unknown, "", boolean>;
|
|
71
|
+
readonly editable: BooleanConstructor;
|
|
72
|
+
readonly type: import("@element-plus/utils").EpPropFinalized<StringConstructor, "" | "card" | "border-card", unknown, "", boolean>;
|
|
73
|
+
readonly stretch: BooleanConstructor;
|
|
74
|
+
readonly tabindex: import("@element-plus/utils").EpPropFinalized<readonly [StringConstructor, NumberConstructor], unknown, unknown, undefined, boolean>;
|
|
75
|
+
};
|
|
76
|
+
export declare const tabNavEmits: {
|
|
77
|
+
tabClick: (tab: TabsPaneContext, tabName: TabPaneName, ev: Event) => boolean;
|
|
78
|
+
tabRemove: (tab: TabsPaneContext, ev: Event) => boolean;
|
|
79
|
+
};
|
|
80
|
+
export type TabNavProps = ExtractPropTypes<typeof tabNavProps>;
|
|
81
|
+
export type TabNavPropsPublic = ExtractPublicPropTypes<typeof tabNavProps>;
|
|
82
|
+
export type TabNavEmits = typeof tabNavEmits;
|
|
83
|
+
declare const TabNav: import("vue").DefineComponent<ExtractPropTypes<{
|
|
84
|
+
readonly panes: import("@element-plus/utils").EpPropFinalized<(new (...args: any[]) => {
|
|
85
|
+
uid: number;
|
|
86
|
+
getVnode: () => import("vue").VNode;
|
|
87
|
+
slots: import("vue").Slots;
|
|
88
|
+
props: {
|
|
89
|
+
label?: string | undefined;
|
|
90
|
+
name?: string | number | undefined;
|
|
91
|
+
closable?: boolean | undefined;
|
|
92
|
+
disabled?: boolean | undefined;
|
|
93
|
+
lazy?: boolean | undefined;
|
|
94
|
+
};
|
|
95
|
+
paneName: TabPaneName | undefined;
|
|
96
|
+
active: boolean;
|
|
97
|
+
index: string | undefined;
|
|
98
|
+
isClosable: boolean;
|
|
99
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
100
|
+
}[]) | (() => {
|
|
101
|
+
uid: number;
|
|
102
|
+
getVnode: () => import("vue").VNode;
|
|
103
|
+
slots: import("vue").Slots;
|
|
104
|
+
props: {
|
|
105
|
+
label?: string | undefined;
|
|
106
|
+
name?: string | number | undefined;
|
|
107
|
+
closable?: boolean | undefined;
|
|
108
|
+
disabled?: boolean | undefined;
|
|
109
|
+
lazy?: boolean | undefined;
|
|
110
|
+
};
|
|
111
|
+
paneName: TabPaneName | undefined;
|
|
112
|
+
active: boolean;
|
|
113
|
+
index: string | undefined;
|
|
114
|
+
isClosable: boolean;
|
|
115
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
116
|
+
}[]) | (((new (...args: any[]) => {
|
|
117
|
+
uid: number;
|
|
118
|
+
getVnode: () => import("vue").VNode;
|
|
119
|
+
slots: import("vue").Slots;
|
|
120
|
+
props: {
|
|
121
|
+
label?: string | undefined;
|
|
122
|
+
name?: string | number | undefined;
|
|
123
|
+
closable?: boolean | undefined;
|
|
124
|
+
disabled?: boolean | undefined;
|
|
125
|
+
lazy?: boolean | undefined;
|
|
126
|
+
};
|
|
127
|
+
paneName: TabPaneName | undefined;
|
|
128
|
+
active: boolean;
|
|
129
|
+
index: string | undefined;
|
|
130
|
+
isClosable: boolean;
|
|
131
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
132
|
+
}[]) | (() => {
|
|
133
|
+
uid: number;
|
|
134
|
+
getVnode: () => import("vue").VNode;
|
|
135
|
+
slots: import("vue").Slots;
|
|
136
|
+
props: {
|
|
137
|
+
label?: string | undefined;
|
|
138
|
+
name?: string | number | undefined;
|
|
139
|
+
closable?: boolean | undefined;
|
|
140
|
+
disabled?: boolean | undefined;
|
|
141
|
+
lazy?: boolean | undefined;
|
|
142
|
+
};
|
|
143
|
+
paneName: TabPaneName | undefined;
|
|
144
|
+
active: boolean;
|
|
145
|
+
index: string | undefined;
|
|
146
|
+
isClosable: boolean;
|
|
147
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
148
|
+
}[])) | null)[], unknown, unknown, () => [], boolean>;
|
|
149
|
+
readonly currentName: import("@element-plus/utils").EpPropFinalized<readonly [StringConstructor, NumberConstructor], unknown, unknown, "", boolean>;
|
|
150
|
+
readonly editable: BooleanConstructor;
|
|
151
|
+
readonly type: import("@element-plus/utils").EpPropFinalized<StringConstructor, "" | "card" | "border-card", unknown, "", boolean>;
|
|
152
|
+
readonly stretch: BooleanConstructor;
|
|
153
|
+
readonly tabindex: import("@element-plus/utils").EpPropFinalized<readonly [StringConstructor, NumberConstructor], unknown, unknown, undefined, boolean>;
|
|
154
|
+
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
155
|
+
tabClick: (tab: TabsPaneContext, tabName: TabPaneName, ev: Event) => boolean;
|
|
156
|
+
tabRemove: (tab: TabsPaneContext, ev: Event) => boolean;
|
|
157
|
+
}, string, import("vue").PublicProps, Readonly<ExtractPropTypes<{
|
|
158
|
+
readonly panes: import("@element-plus/utils").EpPropFinalized<(new (...args: any[]) => {
|
|
159
|
+
uid: number;
|
|
160
|
+
getVnode: () => import("vue").VNode;
|
|
161
|
+
slots: import("vue").Slots;
|
|
162
|
+
props: {
|
|
163
|
+
label?: string | undefined;
|
|
164
|
+
name?: string | number | undefined;
|
|
165
|
+
closable?: boolean | undefined;
|
|
166
|
+
disabled?: boolean | undefined;
|
|
167
|
+
lazy?: boolean | undefined;
|
|
168
|
+
};
|
|
169
|
+
paneName: TabPaneName | undefined;
|
|
170
|
+
active: boolean;
|
|
171
|
+
index: string | undefined;
|
|
172
|
+
isClosable: boolean;
|
|
173
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
174
|
+
}[]) | (() => {
|
|
175
|
+
uid: number;
|
|
176
|
+
getVnode: () => import("vue").VNode;
|
|
177
|
+
slots: import("vue").Slots;
|
|
178
|
+
props: {
|
|
179
|
+
label?: string | undefined;
|
|
180
|
+
name?: string | number | undefined;
|
|
181
|
+
closable?: boolean | undefined;
|
|
182
|
+
disabled?: boolean | undefined;
|
|
183
|
+
lazy?: boolean | undefined;
|
|
184
|
+
};
|
|
185
|
+
paneName: TabPaneName | undefined;
|
|
186
|
+
active: boolean;
|
|
187
|
+
index: string | undefined;
|
|
188
|
+
isClosable: boolean;
|
|
189
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
190
|
+
}[]) | (((new (...args: any[]) => {
|
|
191
|
+
uid: number;
|
|
192
|
+
getVnode: () => import("vue").VNode;
|
|
193
|
+
slots: import("vue").Slots;
|
|
194
|
+
props: {
|
|
195
|
+
label?: string | undefined;
|
|
196
|
+
name?: string | number | undefined;
|
|
197
|
+
closable?: boolean | undefined;
|
|
198
|
+
disabled?: boolean | undefined;
|
|
199
|
+
lazy?: boolean | undefined;
|
|
200
|
+
};
|
|
201
|
+
paneName: TabPaneName | undefined;
|
|
202
|
+
active: boolean;
|
|
203
|
+
index: string | undefined;
|
|
204
|
+
isClosable: boolean;
|
|
205
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
206
|
+
}[]) | (() => {
|
|
207
|
+
uid: number;
|
|
208
|
+
getVnode: () => import("vue").VNode;
|
|
209
|
+
slots: import("vue").Slots;
|
|
210
|
+
props: {
|
|
211
|
+
label?: string | undefined;
|
|
212
|
+
name?: string | number | undefined;
|
|
213
|
+
closable?: boolean | undefined;
|
|
214
|
+
disabled?: boolean | undefined;
|
|
215
|
+
lazy?: boolean | undefined;
|
|
216
|
+
};
|
|
217
|
+
paneName: TabPaneName | undefined;
|
|
218
|
+
active: boolean;
|
|
219
|
+
index: string | undefined;
|
|
220
|
+
isClosable: boolean;
|
|
221
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
222
|
+
}[])) | null)[], unknown, unknown, () => [], boolean>;
|
|
223
|
+
readonly currentName: import("@element-plus/utils").EpPropFinalized<readonly [StringConstructor, NumberConstructor], unknown, unknown, "", boolean>;
|
|
224
|
+
readonly editable: BooleanConstructor;
|
|
225
|
+
readonly type: import("@element-plus/utils").EpPropFinalized<StringConstructor, "" | "card" | "border-card", unknown, "", boolean>;
|
|
226
|
+
readonly stretch: BooleanConstructor;
|
|
227
|
+
readonly tabindex: import("@element-plus/utils").EpPropFinalized<readonly [StringConstructor, NumberConstructor], unknown, unknown, undefined, boolean>;
|
|
228
|
+
}>> & Readonly<{
|
|
229
|
+
onTabClick?: ((tab: {
|
|
230
|
+
uid: number;
|
|
231
|
+
getVnode: () => import("vue").VNode;
|
|
232
|
+
slots: import("vue").Slots;
|
|
233
|
+
props: {
|
|
234
|
+
label?: string | undefined;
|
|
235
|
+
name?: string | number | undefined;
|
|
236
|
+
closable?: boolean | undefined;
|
|
237
|
+
disabled?: boolean | undefined;
|
|
238
|
+
lazy?: boolean | undefined;
|
|
239
|
+
};
|
|
240
|
+
paneName: TabPaneName | undefined;
|
|
241
|
+
active: boolean;
|
|
242
|
+
index: string | undefined;
|
|
243
|
+
isClosable: boolean;
|
|
244
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
245
|
+
}, tabName: TabPaneName, ev: Event) => any) | undefined;
|
|
246
|
+
onTabRemove?: ((tab: {
|
|
247
|
+
uid: number;
|
|
248
|
+
getVnode: () => import("vue").VNode;
|
|
249
|
+
slots: import("vue").Slots;
|
|
250
|
+
props: {
|
|
251
|
+
label?: string | undefined;
|
|
252
|
+
name?: string | number | undefined;
|
|
253
|
+
closable?: boolean | undefined;
|
|
254
|
+
disabled?: boolean | undefined;
|
|
255
|
+
lazy?: boolean | undefined;
|
|
256
|
+
};
|
|
257
|
+
paneName: TabPaneName | undefined;
|
|
258
|
+
active: boolean;
|
|
259
|
+
index: string | undefined;
|
|
260
|
+
isClosable: boolean;
|
|
261
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
262
|
+
}, ev: Event) => any) | undefined;
|
|
263
|
+
}>, {
|
|
264
|
+
readonly stretch: boolean;
|
|
265
|
+
readonly tabindex: import("@element-plus/utils").EpPropMergeType<readonly [StringConstructor, NumberConstructor], unknown, unknown>;
|
|
266
|
+
readonly type: import("@element-plus/utils").EpPropMergeType<StringConstructor, "" | "card" | "border-card", unknown>;
|
|
267
|
+
readonly editable: boolean;
|
|
268
|
+
readonly panes: {
|
|
269
|
+
uid: number;
|
|
270
|
+
getVnode: () => import("vue").VNode;
|
|
271
|
+
slots: import("vue").Slots;
|
|
272
|
+
props: {
|
|
273
|
+
label?: string | undefined;
|
|
274
|
+
name?: string | number | undefined;
|
|
275
|
+
closable?: boolean | undefined;
|
|
276
|
+
disabled?: boolean | undefined;
|
|
277
|
+
lazy?: boolean | undefined;
|
|
278
|
+
};
|
|
279
|
+
paneName: TabPaneName | undefined;
|
|
280
|
+
active: boolean;
|
|
281
|
+
index: string | undefined;
|
|
282
|
+
isClosable: boolean;
|
|
283
|
+
isFocusInsidePane: () => boolean | undefined;
|
|
284
|
+
}[];
|
|
285
|
+
readonly currentName: import("@element-plus/utils").EpPropMergeType<readonly [StringConstructor, NumberConstructor], unknown, unknown>;
|
|
286
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
287
|
+
export type TabNavInstance = InstanceType<typeof TabNav> & {
|
|
288
|
+
scrollToActiveTab: () => Promise<void>;
|
|
289
|
+
removeFocus: () => void;
|
|
290
|
+
focusActiveTab: () => void;
|
|
291
|
+
scheduleRender: () => void;
|
|
292
|
+
tabListRef: HTMLDivElement | undefined;
|
|
293
|
+
tabBarRef: TabBarInstance | undefined;
|
|
294
|
+
};
|
|
295
|
+
export default TabNav;
|