vft 0.0.61 → 0.0.62
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/attributes.json +1 -1
- package/dist/index.css +1 -1
- package/es/component.js +26 -22
- package/es/components/back-top/back-top.vue2.js +4 -2
- package/es/components/color-picker/color-picker.vue.d.ts +3 -1
- package/es/components/color-picker/color-picker.vue2.js +31 -30
- package/es/components/color-picker/index.d.ts +3 -1
- package/es/components/context-menu/context-menu.vue2.js +4 -2
- package/es/components/dialog/dialog.vue.d.ts +1 -1
- package/es/components/dialog/dialog.vue2.js +52 -53
- package/es/components/dialog/index.d.ts +3 -3
- package/es/components/dialog/index.js +1 -1
- package/es/components/dialog/style/css.js +1 -1
- package/es/components/dropdown/dropdown.vue.d.ts +5 -5
- package/es/components/dropdown/index.d.ts +5 -5
- package/es/components/icon-text/icon-text.vue.d.ts +10 -4
- package/es/components/icon-text/icon-text.vue2.js +28 -26
- package/es/components/icon-text/index.d.ts +10 -4
- package/es/components/index.d.ts +2 -0
- package/es/components/index.js +117 -109
- package/es/components/list-cell/index.d.ts +38 -0
- package/es/components/list-cell/index.js +12 -0
- package/es/components/list-cell/list-cell.vue.d.ts +53 -0
- package/es/components/list-cell/list-cell.vue.js +4 -0
- package/es/components/list-cell/list-cell.vue2.js +68 -0
- package/es/components/list-cell/style/css.d.ts +0 -0
- package/es/components/list-cell/style/css.js +2 -0
- package/es/components/list-cell/style/index.d.ts +0 -0
- package/es/components/list-cell/style/index.js +2 -0
- package/es/components/md-container/md-container.vue2.js +4 -2
- package/es/components/menu/index.d.ts +2 -2
- package/es/components/menu/menu-item.vue2.js +14 -12
- package/es/components/menu/menu.vue.d.ts +2 -2
- package/es/components/menu/sub-menu.vue2.js +4 -2
- package/es/components/multiple-tabs/multiple-tabs.vue2.js +5 -3
- package/es/components/multiple-tabs/tab-content.vue.d.ts +8 -0
- package/es/components/multiple-tabs/tab-content.vue2.js +13 -12
- package/es/components/multiple-tabs/use/use-tab-dropdown.js +12 -12
- package/es/components/result/result.vue2.js +4 -2
- package/es/components/search/search.vue2.js +4 -2
- package/es/components/select-v2/defaults.d.ts +1 -1
- package/es/components/select-v2/index.d.ts +16 -16
- package/es/components/select-v2/select.vue.d.ts +8 -8
- package/es/components/select-v2/useSelect.d.ts +5 -5
- package/es/components/side-menu/index.d.ts +38 -1
- package/es/components/side-menu/side-menu.vue.d.ts +38 -1
- package/es/components/side-menu/side-menu.vue2.js +144 -113
- package/es/components/side-menu/use-drag-line.d.ts +10 -0
- package/es/components/side-menu/use-drag-line.js +51 -0
- package/es/components/switch/index.d.ts +1 -1
- package/es/components/switch/switch.vue.d.ts +1 -1
- package/es/components/tabs/tab-nav.vue2.js +4 -2
- package/es/components/tooltip/index.d.ts +2 -2
- package/es/components/tooltip/tooltip.vue.d.ts +2 -2
- package/es/components/virtual-list/builders/build-list.d.ts +38 -38
- package/es/components/virtual-list/components/scrollbar.d.ts +1 -1
- package/es/defaults.d.ts +1 -1
- package/es/index.d.ts +1 -1
- package/es/index.js +248 -239
- package/es/package.json.js +1 -1
- package/es/utils/index.js +31 -30
- package/es/utils/ns-cover.d.ts +6 -3
- package/es/utils/ns-cover.js +25 -15
- package/global.d.ts +2 -70
- package/lib/component.cjs +1 -1
- package/lib/components/back-top/back-top.vue2.cjs +1 -1
- package/lib/components/color-picker/color-picker.vue.d.ts +3 -1
- package/lib/components/color-picker/color-picker.vue2.cjs +1 -1
- package/lib/components/color-picker/index.d.ts +3 -1
- package/lib/components/context-menu/context-menu.vue2.cjs +1 -1
- package/lib/components/dialog/dialog.vue.d.ts +1 -1
- package/lib/components/dialog/dialog.vue2.cjs +1 -1
- package/lib/components/dialog/index.cjs +1 -1
- package/lib/components/dialog/index.d.ts +3 -3
- package/lib/components/dialog/style/css.cjs +1 -1
- package/lib/components/dropdown/dropdown.vue.d.ts +5 -5
- package/lib/components/dropdown/index.d.ts +5 -5
- package/lib/components/icon-text/icon-text.vue.d.ts +10 -4
- package/lib/components/icon-text/icon-text.vue2.cjs +1 -1
- package/lib/components/icon-text/index.d.ts +10 -4
- package/lib/components/index.cjs +1 -1
- package/lib/components/index.d.ts +2 -0
- package/lib/components/list-cell/index.cjs +1 -0
- package/lib/components/list-cell/index.d.ts +38 -0
- package/lib/components/list-cell/list-cell.vue.cjs +1 -0
- package/lib/components/list-cell/list-cell.vue.d.ts +53 -0
- package/lib/components/list-cell/list-cell.vue2.cjs +1 -0
- package/lib/components/list-cell/style/css.cjs +1 -0
- package/lib/components/list-cell/style/css.d.ts +0 -0
- package/lib/components/list-cell/style/index.cjs +1 -0
- package/lib/components/list-cell/style/index.d.ts +0 -0
- package/lib/components/md-container/md-container.vue2.cjs +1 -1
- package/lib/components/menu/index.d.ts +2 -2
- package/lib/components/menu/menu-item.vue2.cjs +1 -1
- package/lib/components/menu/menu.vue.d.ts +2 -2
- package/lib/components/menu/sub-menu.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/tab-content.vue.d.ts +8 -0
- package/lib/components/multiple-tabs/tab-content.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/use/use-tab-dropdown.cjs +1 -1
- package/lib/components/result/result.vue2.cjs +1 -1
- package/lib/components/search/search.vue2.cjs +1 -1
- package/lib/components/select-v2/defaults.d.ts +1 -1
- package/lib/components/select-v2/index.d.ts +16 -16
- package/lib/components/select-v2/select.vue.d.ts +8 -8
- package/lib/components/select-v2/useSelect.d.ts +5 -5
- package/lib/components/side-menu/index.d.ts +38 -1
- package/lib/components/side-menu/side-menu.vue.d.ts +38 -1
- package/lib/components/side-menu/side-menu.vue2.cjs +1 -1
- package/lib/components/side-menu/use-drag-line.cjs +1 -0
- package/lib/components/side-menu/use-drag-line.d.ts +10 -0
- package/lib/components/switch/index.d.ts +1 -1
- package/lib/components/switch/switch.vue.d.ts +1 -1
- package/lib/components/tabs/tab-nav.vue2.cjs +1 -1
- package/lib/components/tooltip/index.d.ts +2 -2
- package/lib/components/tooltip/tooltip.vue.d.ts +2 -2
- package/lib/components/virtual-list/builders/build-list.d.ts +38 -38
- package/lib/components/virtual-list/components/scrollbar.d.ts +1 -1
- package/lib/defaults.d.ts +1 -1
- package/lib/index.cjs +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/package.json.cjs +1 -1
- package/lib/utils/index.cjs +1 -1
- package/lib/utils/ns-cover.cjs +1 -1
- package/lib/utils/ns-cover.d.ts +6 -3
- package/package.json +1 -1
- package/tags.json +1 -1
- package/theme-style/base.css +1 -1
- package/theme-style/dark/css-vars.css +1 -1
- package/theme-style/index.css +1 -1
- package/theme-style/src/common/var.scss +13 -2
- package/theme-style/src/dark/var.scss +3 -3
- package/theme-style/src/dialog.scss +6 -4
- package/theme-style/src/footer-layout.scss +1 -0
- package/theme-style/src/index.scss +1 -0
- package/theme-style/src/list-cell.scss +55 -0
- package/theme-style/src/loading.scss +1 -1
- package/theme-style/src/md-container.scss +2 -3
- package/theme-style/src/menu.scss +5 -1
- package/theme-style/src/multiple-tabs.scss +1 -1
- package/theme-style/src/pagination.scss +1 -5
- package/theme-style/src/popover.scss +3 -3
- package/theme-style/src/side-menu.scss +21 -5
- package/theme-style/src/var.scss +0 -2
- package/theme-style/vft-back-top.css +1 -1
- package/theme-style/vft-dialog.css +1 -1
- package/theme-style/vft-footer-layout.css +1 -1
- package/theme-style/vft-list-cell.css +1 -0
- package/theme-style/vft-loading.css +1 -1
- package/theme-style/vft-md-container.css +1 -1
- package/theme-style/vft-menu.css +1 -1
- package/theme-style/vft-popover.css +1 -1
- package/theme-style/vft-side-menu.css +1 -1
- package/theme-style/vft-var.css +1 -1
- package/web-types.json +1 -1
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import type { PropType as __PropType } from 'vue';
|
|
2
|
+
import { type IconProps } from 'vft/es/components/icon';
|
|
3
|
+
export type ListItem = {
|
|
4
|
+
text: string;
|
|
5
|
+
leftIcon?: string | IconProps;
|
|
6
|
+
rightIcon?: string | IconProps;
|
|
7
|
+
rightContent?: any;
|
|
8
|
+
[key: string]: any;
|
|
9
|
+
};
|
|
10
|
+
export interface ListCellProps {
|
|
11
|
+
list: Array<ListItem>;
|
|
12
|
+
cellHeight?: string | number;
|
|
13
|
+
leftTextDistance?: string | number;
|
|
14
|
+
activeIndex?: number;
|
|
15
|
+
}
|
|
16
|
+
declare const _sfc_main: import("vue").DefineComponent<{
|
|
17
|
+
list: {
|
|
18
|
+
type: __PropType<ListItem[]>;
|
|
19
|
+
required: true;
|
|
20
|
+
};
|
|
21
|
+
cellHeight: {
|
|
22
|
+
type: __PropType<string | number | undefined>;
|
|
23
|
+
required: false;
|
|
24
|
+
};
|
|
25
|
+
leftTextDistance: {
|
|
26
|
+
type: __PropType<string | number | undefined>;
|
|
27
|
+
required: false;
|
|
28
|
+
};
|
|
29
|
+
activeIndex: {
|
|
30
|
+
type: __PropType<number | undefined>;
|
|
31
|
+
required: false;
|
|
32
|
+
};
|
|
33
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "item-click"[], "item-click", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
34
|
+
list: {
|
|
35
|
+
type: __PropType<ListItem[]>;
|
|
36
|
+
required: true;
|
|
37
|
+
};
|
|
38
|
+
cellHeight: {
|
|
39
|
+
type: __PropType<string | number | undefined>;
|
|
40
|
+
required: false;
|
|
41
|
+
};
|
|
42
|
+
leftTextDistance: {
|
|
43
|
+
type: __PropType<string | number | undefined>;
|
|
44
|
+
required: false;
|
|
45
|
+
};
|
|
46
|
+
activeIndex: {
|
|
47
|
+
type: __PropType<number | undefined>;
|
|
48
|
+
required: false;
|
|
49
|
+
};
|
|
50
|
+
}>> & {
|
|
51
|
+
"onItem-click"?: ((...args: any[]) => any) | undefined;
|
|
52
|
+
}, {}>;
|
|
53
|
+
export default _sfc_main;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { defineComponent as k, ref as _, computed as m, openBlock as o, createElementBlock as a, normalizeStyle as z, unref as t, normalizeClass as c, Fragment as V, renderList as N, createElementVNode as u, createVNode as b, normalizeProps as d, guardReactiveProps as B, toDisplayString as D, createBlock as p, mergeProps as P } from "vue";
|
|
2
|
+
import { VftIcon as g } from "../icon/index.js";
|
|
3
|
+
import { useNamespace as T } from "../../hooks/use-namespace/index.js";
|
|
4
|
+
import "@popperjs/core";
|
|
5
|
+
import "lodash";
|
|
6
|
+
import "../../hooks/use-z-index/index.js";
|
|
7
|
+
import "@vueuse/core";
|
|
8
|
+
import { singleAttrToObj as h, addUnit as v, VNode as E } from "@vft/utils";
|
|
9
|
+
import { generateCssVars as H } from "../../utils/ns-cover.js";
|
|
10
|
+
import "@vue/reactivity";
|
|
11
|
+
import "@vue/shared";
|
|
12
|
+
const S = ["onClick"], l = (
|
|
13
|
+
/* hoist-static*/
|
|
14
|
+
T("list-cell")
|
|
15
|
+
), j = k({
|
|
16
|
+
name: l.b()
|
|
17
|
+
}), M = /* @__PURE__ */ k({
|
|
18
|
+
...j,
|
|
19
|
+
props: {
|
|
20
|
+
list: { default: [] },
|
|
21
|
+
cellHeight: { default: 50 },
|
|
22
|
+
leftTextDistance: { default: 8 },
|
|
23
|
+
activeIndex: null
|
|
24
|
+
},
|
|
25
|
+
emits: ["item-click"],
|
|
26
|
+
setup(r, { emit: I }) {
|
|
27
|
+
const f = _(r.activeIndex), C = m(() => r.list.map((e) => (e.leftIcon = h(e.leftIcon, "icon", { size: 16 }), e.rightIcon = h(e.rightIcon, "icon", {
|
|
28
|
+
icon: "ico-ep:arrow-right",
|
|
29
|
+
size: 16
|
|
30
|
+
}), e))), x = m(() => H({
|
|
31
|
+
height: v(r.cellHeight),
|
|
32
|
+
"left-text-distance": v(r.leftTextDistance)
|
|
33
|
+
}, "list-cell"));
|
|
34
|
+
function y(e, i) {
|
|
35
|
+
f.value = i, I("item-click", e, i);
|
|
36
|
+
}
|
|
37
|
+
return (e, i) => (o(), a("div", {
|
|
38
|
+
style: z(t(x)),
|
|
39
|
+
class: c(t(l).b())
|
|
40
|
+
}, [
|
|
41
|
+
(o(!0), a(V, null, N(t(C), (n, s) => (o(), a("div", {
|
|
42
|
+
onClick: (w) => y(n, s),
|
|
43
|
+
key: s,
|
|
44
|
+
class: c([t(l).e("item"), t(l).is("active", f.value === s)])
|
|
45
|
+
}, [
|
|
46
|
+
u("div", {
|
|
47
|
+
class: c(t(l).m("left"))
|
|
48
|
+
}, [
|
|
49
|
+
b(t(g), d(B(n.leftIcon)), null, 16),
|
|
50
|
+
u("span", {
|
|
51
|
+
class: c(t(l).e("text"))
|
|
52
|
+
}, D(n.text), 3)
|
|
53
|
+
], 2),
|
|
54
|
+
u("div", {
|
|
55
|
+
class: c(t(l).m("right"))
|
|
56
|
+
}, [
|
|
57
|
+
n != null && n.rightContent ? (o(), p(t(E), {
|
|
58
|
+
key: 0,
|
|
59
|
+
content: n.rightContent
|
|
60
|
+
}, null, 8, ["content"])) : (o(), p(t(g), d(P({ key: 1 }, n.rightIcon)), null, 16))
|
|
61
|
+
], 2)
|
|
62
|
+
], 10, S))), 128))
|
|
63
|
+
], 6));
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
export {
|
|
67
|
+
M as default
|
|
68
|
+
};
|
|
File without changes
|
|
File without changes
|
|
@@ -57,6 +57,8 @@ import "../select-v2/index.js";
|
|
|
57
57
|
import "../verify-code/index.js";
|
|
58
58
|
import "../table/index.js";
|
|
59
59
|
import "../image-viewer/index.js";
|
|
60
|
+
import "../list-cell/index.js";
|
|
61
|
+
import "../dialog/index.js";
|
|
60
62
|
import "./index.js";
|
|
61
63
|
import { VftMdComment as X } from "../md-comment/index.js";
|
|
62
64
|
import "../md-tabs/index.js";
|
|
@@ -87,7 +89,7 @@ const mt = { class: "info-container" }, pt = {
|
|
|
87
89
|
Z("md-container")
|
|
88
90
|
), ct = T({
|
|
89
91
|
name: r.b()
|
|
90
|
-
}),
|
|
92
|
+
}), $o = /* @__PURE__ */ T({
|
|
91
93
|
...ct,
|
|
92
94
|
setup(lt, { expose: V }) {
|
|
93
95
|
const w = P(), { initPhotoSwipe: D } = G(`.${r.e("content")} img`);
|
|
@@ -185,5 +187,5 @@ const mt = { class: "info-container" }, pt = {
|
|
|
185
187
|
}
|
|
186
188
|
});
|
|
187
189
|
export {
|
|
188
|
-
|
|
190
|
+
$o as default
|
|
189
191
|
};
|
|
@@ -51,7 +51,7 @@ export declare const VftMenu: import("vft/es/utils").SFCWithInstall<import("vue"
|
|
|
51
51
|
open: (index: string) => void;
|
|
52
52
|
close: (index: string, indexPath: string[]) => void;
|
|
53
53
|
handleResize: () => void;
|
|
54
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("
|
|
54
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("open" | "close" | "select")[], "open" | "close" | "select", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
55
55
|
mode: {
|
|
56
56
|
type: import("vue").PropType<"horizontal" | "vertical" | undefined>;
|
|
57
57
|
required: false;
|
|
@@ -101,8 +101,8 @@ export declare const VftMenu: import("vft/es/utils").SFCWithInstall<import("vue"
|
|
|
101
101
|
required: false;
|
|
102
102
|
};
|
|
103
103
|
}>> & {
|
|
104
|
-
onClose?: ((...args: any[]) => any) | undefined;
|
|
105
104
|
onOpen?: ((...args: any[]) => any) | undefined;
|
|
105
|
+
onClose?: ((...args: any[]) => any) | undefined;
|
|
106
106
|
onSelect?: ((...args: any[]) => any) | undefined;
|
|
107
107
|
}, {}>> & {
|
|
108
108
|
MenuItem: import("vue").DefineComponent<{
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as S, getCurrentInstance as M, inject as V, computed as l, reactive as Y, onMounted as D, onBeforeUnmount as F, openBlock as m, createElementBlock as
|
|
1
|
+
import { defineComponent as S, getCurrentInstance as M, inject as V, computed as l, reactive as Y, onMounted as D, onBeforeUnmount as F, openBlock as m, createElementBlock as a, Fragment as c, createBlock as p, unref as e, createCommentVNode as d, createElementVNode as u, normalizeClass as $, withCtx as j, renderSlot as f, normalizeProps as O, mergeProps as q, createVNode as G } from "vue";
|
|
2
2
|
import { singleAttrToObj as H, renderTNode as J, VNode as K } from "@vft/utils";
|
|
3
3
|
import { throwError as P } from "../../utils/error.js";
|
|
4
4
|
import "lodash";
|
|
@@ -67,6 +67,8 @@ import "../select-v2/index.js";
|
|
|
67
67
|
import "../verify-code/index.js";
|
|
68
68
|
import "../table/index.js";
|
|
69
69
|
import "../image-viewer/index.js";
|
|
70
|
+
import "../list-cell/index.js";
|
|
71
|
+
import "../dialog/index.js";
|
|
70
72
|
import "../md-container/index.js";
|
|
71
73
|
import "../md-comment/index.js";
|
|
72
74
|
import "../md-tabs/index.js";
|
|
@@ -79,7 +81,7 @@ const W = ["title"], k = (
|
|
|
79
81
|
v("menu-item")
|
|
80
82
|
), X = S({
|
|
81
83
|
name: k.b()
|
|
82
|
-
}),
|
|
84
|
+
}), Ue = /* @__PURE__ */ S({
|
|
83
85
|
...X,
|
|
84
86
|
props: {
|
|
85
87
|
index: null,
|
|
@@ -94,7 +96,7 @@ const W = ["title"], k = (
|
|
|
94
96
|
},
|
|
95
97
|
emits: ["click"],
|
|
96
98
|
setup(t, { emit: T }) {
|
|
97
|
-
const b = M(), w = v("menu"),
|
|
99
|
+
const b = M(), w = v("menu"), s = v("menu-item"), i = t.isAloneUse ? null : V("rootMenu");
|
|
98
100
|
!i && !t.isAloneUse && P(k.b(), "can not inject root menu");
|
|
99
101
|
const { parentMenu: y, indexPath: g } = L(
|
|
100
102
|
b,
|
|
@@ -118,18 +120,18 @@ const W = ["title"], k = (
|
|
|
118
120
|
t.isAloneUse || (o == null || o.removeSubMenu(r), i == null || i.removeMenuItem(r));
|
|
119
121
|
}), (n, Z) => {
|
|
120
122
|
var U, B, C, N, I;
|
|
121
|
-
return m(),
|
|
122
|
-
t.reverse && t.divider ? (m(),
|
|
123
|
+
return m(), a(c, null, [
|
|
124
|
+
t.reverse && t.divider ? (m(), p(e(E), {
|
|
123
125
|
key: 0,
|
|
124
126
|
marginY: "0"
|
|
125
127
|
})) : d("", !0),
|
|
126
128
|
u("li", {
|
|
127
|
-
class: $([t.className, e(
|
|
129
|
+
class: $([t.className, e(s).b(), e(s).is("active", t.isAloneUse ? !1 : e(h)), e(s).is("disabled", t.disabled)]),
|
|
128
130
|
role: "menuitem",
|
|
129
131
|
tabindex: "-1",
|
|
130
132
|
onClick: z
|
|
131
133
|
}, [
|
|
132
|
-
((B = (U = e(y)) == null ? void 0 : U.type) == null ? void 0 : B.name) === "vft-menu" && ((C = e(i)) != null && C.props.collapse) && n.$slots.title ? (m(),
|
|
134
|
+
((B = (U = e(y)) == null ? void 0 : U.type) == null ? void 0 : B.name) === "vft-menu" && ((C = e(i)) != null && C.props.collapse) && n.$slots.title ? (m(), p(e(R), {
|
|
133
135
|
key: 0,
|
|
134
136
|
placement: "right",
|
|
135
137
|
"fallback-placements": ["left"],
|
|
@@ -146,16 +148,16 @@ const W = ["title"], k = (
|
|
|
146
148
|
], 2)
|
|
147
149
|
]),
|
|
148
150
|
_: 3
|
|
149
|
-
})) : (m(),
|
|
150
|
-
(N = n.$slots) != null && N.default ? f(n.$slots, "default", { key: 0 }) : (m(),
|
|
151
|
-
(I = e(x)) != null && I.icon ? (m(),
|
|
151
|
+
})) : (m(), a(c, { key: 1 }, [
|
|
152
|
+
(N = n.$slots) != null && N.default ? f(n.$slots, "default", { key: 0 }) : (m(), a(c, { key: 1 }, [
|
|
153
|
+
(I = e(x)) != null && I.icon ? (m(), p(e(Q), O(q({ key: 0 }, e(x))), null, 16)) : d("", !0),
|
|
152
154
|
u("span", { title: e(A) }, [
|
|
153
155
|
G(e(K), { content: e(A) }, null, 8, ["content"])
|
|
154
156
|
], 8, W)
|
|
155
157
|
], 64))
|
|
156
158
|
], 64))
|
|
157
159
|
], 2),
|
|
158
|
-
!t.reverse && t.divider ? (m(),
|
|
160
|
+
!t.reverse && t.divider ? (m(), p(e(E), {
|
|
159
161
|
key: 1,
|
|
160
162
|
marginY: "0"
|
|
161
163
|
})) : d("", !0)
|
|
@@ -164,5 +166,5 @@ const W = ["title"], k = (
|
|
|
164
166
|
}
|
|
165
167
|
});
|
|
166
168
|
export {
|
|
167
|
-
|
|
169
|
+
Ue as default
|
|
168
170
|
};
|
|
@@ -52,7 +52,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
52
52
|
open: (index: string) => void;
|
|
53
53
|
close: (index: string, indexPath: string[]) => void;
|
|
54
54
|
handleResize: () => void;
|
|
55
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("
|
|
55
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("open" | "close" | "select")[], "open" | "close" | "select", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
56
56
|
mode: {
|
|
57
57
|
type: __PropType<"horizontal" | "vertical" | undefined>;
|
|
58
58
|
required: false;
|
|
@@ -102,8 +102,8 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
102
102
|
required: false;
|
|
103
103
|
};
|
|
104
104
|
}>> & {
|
|
105
|
-
onClose?: ((...args: any[]) => any) | undefined;
|
|
106
105
|
onOpen?: ((...args: any[]) => any) | undefined;
|
|
106
|
+
onClose?: ((...args: any[]) => any) | undefined;
|
|
107
107
|
onSelect?: ((...args: any[]) => any) | undefined;
|
|
108
108
|
}, {}>;
|
|
109
109
|
export default _sfc_main;
|
|
@@ -57,6 +57,8 @@ import "../select-v2/index.js";
|
|
|
57
57
|
import "../verify-code/index.js";
|
|
58
58
|
import "../table/index.js";
|
|
59
59
|
import "../image-viewer/index.js";
|
|
60
|
+
import "../list-cell/index.js";
|
|
61
|
+
import "../dialog/index.js";
|
|
60
62
|
import "../md-container/index.js";
|
|
61
63
|
import "../md-comment/index.js";
|
|
62
64
|
import "../md-tabs/index.js";
|
|
@@ -80,7 +82,7 @@ const S = (
|
|
|
80
82
|
I("sub-menu")
|
|
81
83
|
), ve = Z({
|
|
82
84
|
name: S.b()
|
|
83
|
-
}),
|
|
85
|
+
}), Ho = /* @__PURE__ */ Z({
|
|
84
86
|
...ve,
|
|
85
87
|
props: {
|
|
86
88
|
index: null,
|
|
@@ -281,5 +283,5 @@ const S = (
|
|
|
281
283
|
}
|
|
282
284
|
});
|
|
283
285
|
export {
|
|
284
|
-
|
|
286
|
+
Ho as default
|
|
285
287
|
};
|
|
@@ -66,6 +66,8 @@ import "../select-v2/index.js";
|
|
|
66
66
|
import "../verify-code/index.js";
|
|
67
67
|
import "../table/index.js";
|
|
68
68
|
import "../image-viewer/index.js";
|
|
69
|
+
import "../list-cell/index.js";
|
|
70
|
+
import "../dialog/index.js";
|
|
69
71
|
import "../md-container/index.js";
|
|
70
72
|
import "../md-comment/index.js";
|
|
71
73
|
import "../md-tabs/index.js";
|
|
@@ -79,7 +81,7 @@ const M = (
|
|
|
79
81
|
X("multiple-tabs")
|
|
80
82
|
), rt = P({
|
|
81
83
|
name: M.b()
|
|
82
|
-
}),
|
|
84
|
+
}), ke = /* @__PURE__ */ P({
|
|
83
85
|
...rt,
|
|
84
86
|
props: {
|
|
85
87
|
tabsStyle: null,
|
|
@@ -137,7 +139,7 @@ const M = (
|
|
|
137
139
|
"item-padding": "0 10px",
|
|
138
140
|
"close-icon-left": "8px",
|
|
139
141
|
"item-distance": "10px",
|
|
140
|
-
"item-max-width": "
|
|
142
|
+
"item-max-width": "180px",
|
|
141
143
|
"scroll-padding": "0 20px",
|
|
142
144
|
"header-margin": "0 0 0 8px",
|
|
143
145
|
"item-border": "none"
|
|
@@ -194,5 +196,5 @@ const M = (
|
|
|
194
196
|
}
|
|
195
197
|
});
|
|
196
198
|
export {
|
|
197
|
-
|
|
199
|
+
ke as default
|
|
198
200
|
};
|
|
@@ -13,6 +13,10 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
13
13
|
type: __PropType<Record<string, Numberish> | undefined>;
|
|
14
14
|
required: false;
|
|
15
15
|
};
|
|
16
|
+
visible: {
|
|
17
|
+
type: __PropType<boolean | undefined>;
|
|
18
|
+
required: false;
|
|
19
|
+
};
|
|
16
20
|
}, {
|
|
17
21
|
handleContext: (e: MouseEvent) => void;
|
|
18
22
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
@@ -28,5 +32,9 @@ declare const _sfc_main: import("vue").DefineComponent<{
|
|
|
28
32
|
type: __PropType<Record<string, Numberish> | undefined>;
|
|
29
33
|
required: false;
|
|
30
34
|
};
|
|
35
|
+
visible: {
|
|
36
|
+
type: __PropType<boolean | undefined>;
|
|
37
|
+
required: false;
|
|
38
|
+
};
|
|
31
39
|
}>>, {}>;
|
|
32
40
|
export default _sfc_main;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as r, computed as c, openBlock as s, createElementBlock as f, unref as
|
|
1
|
+
import { defineComponent as r, computed as c, openBlock as s, createElementBlock as f, unref as i, withModifiers as p, toDisplayString as x } from "vue";
|
|
2
2
|
import "@vft/utils";
|
|
3
3
|
import "../context-menu/context-menu.vue2.js";
|
|
4
4
|
import { useContextMenu as b } from "../context-menu/useContextMenu.js";
|
|
@@ -6,31 +6,32 @@ import { useTabDropdown as d } from "./use/use-tab-dropdown.js";
|
|
|
6
6
|
import "@vft/use";
|
|
7
7
|
import "vue-router";
|
|
8
8
|
import "@vft/store";
|
|
9
|
-
const C = ["title", "onContextmenu"],
|
|
9
|
+
const C = ["title", "onContextmenu"], k = /* @__PURE__ */ r({
|
|
10
10
|
__name: "tab-content",
|
|
11
11
|
props: {
|
|
12
12
|
tabItem: null,
|
|
13
13
|
affixNum: null,
|
|
14
|
-
contextMenuStyle: null
|
|
14
|
+
contextMenuStyle: null,
|
|
15
|
+
visible: { type: Boolean }
|
|
15
16
|
},
|
|
16
|
-
setup(t, { expose:
|
|
17
|
-
const [
|
|
17
|
+
setup(t, { expose: m }) {
|
|
18
|
+
const [l] = b(), n = c(() => t.tabItem.meta && t.tabItem.meta.title), { getDropMenuList: a, handleContextMenu: u } = d(t.tabItem, t.affixNum);
|
|
18
19
|
function o(e) {
|
|
19
|
-
u(t.tabItem)(e),
|
|
20
|
+
u(t.tabItem)(e), l({
|
|
20
21
|
event: e,
|
|
21
22
|
styles: t.contextMenuStyle,
|
|
22
|
-
items:
|
|
23
|
+
items: a.value
|
|
23
24
|
});
|
|
24
25
|
}
|
|
25
|
-
return
|
|
26
|
+
return m({
|
|
26
27
|
handleContext: o
|
|
27
28
|
}), (e, M) => (s(), f("span", {
|
|
28
|
-
title:
|
|
29
|
+
title: i(n),
|
|
29
30
|
class: "vft-multiple-tabs__title",
|
|
30
|
-
onContextmenu:
|
|
31
|
-
},
|
|
31
|
+
onContextmenu: p(o, ["stop"])
|
|
32
|
+
}, x(i(n)), 41, C));
|
|
32
33
|
}
|
|
33
34
|
});
|
|
34
35
|
export {
|
|
35
|
-
|
|
36
|
+
k as default
|
|
36
37
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { getRouterKeyPath as d } from "@vft/router";
|
|
2
2
|
import { reactive as C, computed as D } from "vue";
|
|
3
|
-
import { useMultipleTabStore as
|
|
4
|
-
function
|
|
5
|
-
const
|
|
3
|
+
import { useMultipleTabStore as v, useTabs as w } from "@vft/store";
|
|
4
|
+
function S(e, r) {
|
|
5
|
+
const i = C({
|
|
6
6
|
current: null,
|
|
7
7
|
currentIndex: 0
|
|
8
|
-
}), t =
|
|
8
|
+
}), t = v(), { refreshPage: g, closeAll: a, close: u, closeLeft: h, closeOther: b, closeRight: f, newWinTab: p } = w(), x = D(() => {
|
|
9
9
|
if (!e)
|
|
10
10
|
return;
|
|
11
|
-
const { meta: o } = e, n =
|
|
11
|
+
const { meta: o } = e, n = i.currentIndex, c = n === 0 || n <= r, s = t.getTabList.length <= r || n === t.getTabList.length - 1 && t.getLastDragEndIndex >= 0, T = t.getTabList.length === r || t.getTabList.length === r + 1 && n === r, l = t.getTabList.length === r;
|
|
12
12
|
return [
|
|
13
13
|
{
|
|
14
14
|
iconCfg: { icon: "ico-ep:refresh-right" },
|
|
@@ -18,11 +18,11 @@ function P(e, i) {
|
|
|
18
18
|
{
|
|
19
19
|
iconCfg: { icon: "ico-carbon:new-tab" },
|
|
20
20
|
text: "新页面打开",
|
|
21
|
-
handler: () =>
|
|
21
|
+
handler: () => p(e),
|
|
22
22
|
divider: !0
|
|
23
23
|
},
|
|
24
24
|
{
|
|
25
|
-
iconCfg: { icon: "ico-
|
|
25
|
+
iconCfg: { icon: "ico-zondicons:close" },
|
|
26
26
|
text: "关闭标签页",
|
|
27
27
|
disabled: !!(o != null && o.affix) || l,
|
|
28
28
|
handler: () => u(e)
|
|
@@ -38,16 +38,16 @@ function P(e, i) {
|
|
|
38
38
|
text: "关闭右侧标签页",
|
|
39
39
|
disabled: s,
|
|
40
40
|
divider: !0,
|
|
41
|
-
handler: () =>
|
|
41
|
+
handler: () => f(e)
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
44
|
iconCfg: { icon: "ico-mdi:close-box-multiple-outline" },
|
|
45
45
|
text: "关闭其它标签页",
|
|
46
46
|
disabled: T,
|
|
47
|
-
handler: () =>
|
|
47
|
+
handler: () => b(e)
|
|
48
48
|
},
|
|
49
49
|
{
|
|
50
|
-
iconCfg: { icon: "ico-
|
|
50
|
+
iconCfg: { icon: "ico-mdi:vector-square-delete" },
|
|
51
51
|
text: "关闭所有标签页",
|
|
52
52
|
disabled: l,
|
|
53
53
|
handler: () => a()
|
|
@@ -60,11 +60,11 @@ function P(e, i) {
|
|
|
60
60
|
return;
|
|
61
61
|
n == null || n.preventDefault();
|
|
62
62
|
const c = t.getTabList.findIndex((s) => d(s) === d(o));
|
|
63
|
-
|
|
63
|
+
i.current = o, i.currentIndex = c;
|
|
64
64
|
};
|
|
65
65
|
}
|
|
66
66
|
return { getDropMenuList: x, handleContextMenu: L };
|
|
67
67
|
}
|
|
68
68
|
export {
|
|
69
|
-
|
|
69
|
+
S as useTabDropdown
|
|
70
70
|
};
|
|
@@ -65,6 +65,8 @@ import "../select-v2/index.js";
|
|
|
65
65
|
import "../verify-code/index.js";
|
|
66
66
|
import "../table/index.js";
|
|
67
67
|
import "../image-viewer/index.js";
|
|
68
|
+
import "../list-cell/index.js";
|
|
69
|
+
import "../dialog/index.js";
|
|
68
70
|
import "../md-container/index.js";
|
|
69
71
|
import "../md-comment/index.js";
|
|
70
72
|
import "../md-tabs/index.js";
|
|
@@ -77,7 +79,7 @@ const i = (
|
|
|
77
79
|
x("result")
|
|
78
80
|
), I = l({
|
|
79
81
|
name: i.b()
|
|
80
|
-
}),
|
|
82
|
+
}), Lt = /* @__PURE__ */ l({
|
|
81
83
|
...I,
|
|
82
84
|
props: {
|
|
83
85
|
title: null,
|
|
@@ -116,5 +118,5 @@ const i = (
|
|
|
116
118
|
}
|
|
117
119
|
});
|
|
118
120
|
export {
|
|
119
|
-
|
|
121
|
+
Lt as default
|
|
120
122
|
};
|
|
@@ -57,6 +57,8 @@ import "../select-v2/index.js";
|
|
|
57
57
|
import "../verify-code/index.js";
|
|
58
58
|
import "../table/index.js";
|
|
59
59
|
import "../image-viewer/index.js";
|
|
60
|
+
import "../list-cell/index.js";
|
|
61
|
+
import "../dialog/index.js";
|
|
60
62
|
import "../md-container/index.js";
|
|
61
63
|
import "../md-comment/index.js";
|
|
62
64
|
import "../md-tabs/index.js";
|
|
@@ -77,7 +79,7 @@ const u = (
|
|
|
77
79
|
W("search")
|
|
78
80
|
), U = C({
|
|
79
81
|
name: u.b()
|
|
80
|
-
}),
|
|
82
|
+
}), fo = /* @__PURE__ */ C({
|
|
81
83
|
...U,
|
|
82
84
|
props: {
|
|
83
85
|
modelValue: { default: "" },
|
|
@@ -205,5 +207,5 @@ const u = (
|
|
|
205
207
|
}
|
|
206
208
|
});
|
|
207
209
|
export {
|
|
208
|
-
|
|
210
|
+
fo as default
|
|
209
211
|
};
|
|
@@ -4,7 +4,7 @@ import type { Options, Placement } from 'vft/es/components/popper';
|
|
|
4
4
|
export declare const SelectProps: {
|
|
5
5
|
allowCreate: BooleanConstructor;
|
|
6
6
|
autocomplete: {
|
|
7
|
-
type: PropType<"
|
|
7
|
+
type: PropType<"inline" | "none" | "list" | "both">;
|
|
8
8
|
default: string;
|
|
9
9
|
};
|
|
10
10
|
automaticDropdown: BooleanConstructor;
|