vft 0.0.503 → 0.0.504
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/es/components/cascader/cascader.vue2.js +217 -211
- package/es/components/multiple-tabs/multiple-tabs.vue2.js +87 -83
- package/es/components/multiple-tabs/use/use-tab-dropdown.js +55 -39
- package/es/package.json.d.ts +1 -1
- package/es/package.json.js +1 -1
- package/lib/components/cascader/cascader.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
- package/lib/components/multiple-tabs/use/use-tab-dropdown.cjs +1 -1
- package/lib/package.json.cjs +1 -1
- package/lib/package.json.d.ts +1 -1
- package/package.json +5 -5
- package/theme-style/dark/css-vars.css +1 -1
- package/theme-style/display.css +1 -1
- package/theme-style/src/common/icon.scss +3 -0
- package/theme-style/src/multiple-tabs.scss +8 -0
- package/theme-style/vft-affix.css +1 -1
- package/theme-style/vft-alert.css +1 -1
- package/theme-style/vft-aside.css +1 -1
- package/theme-style/vft-autocomplete.css +1 -1
- package/theme-style/vft-avatar-stack.css +1 -1
- package/theme-style/vft-avatar.css +1 -1
- package/theme-style/vft-backtop.css +1 -1
- package/theme-style/vft-badge.css +1 -1
- package/theme-style/vft-breadcrumb.css +1 -1
- package/theme-style/vft-button-group.css +1 -1
- package/theme-style/vft-button.css +1 -1
- package/theme-style/vft-calendar.css +1 -1
- package/theme-style/vft-card.css +1 -1
- package/theme-style/vft-carousel-item.css +1 -1
- package/theme-style/vft-carousel.css +1 -1
- package/theme-style/vft-cascader-panel.css +1 -1
- package/theme-style/vft-cascader.css +1 -1
- package/theme-style/vft-check-tag.css +1 -1
- package/theme-style/vft-checkbox-button.css +1 -1
- package/theme-style/vft-checkbox-group.css +1 -1
- package/theme-style/vft-checkbox.css +1 -1
- package/theme-style/vft-clamp-toggle.css +1 -1
- package/theme-style/vft-col.css +1 -1
- package/theme-style/vft-collapse.css +1 -1
- package/theme-style/vft-color-picker.css +1 -1
- package/theme-style/vft-container.css +1 -1
- package/theme-style/vft-date-picker.css +1 -1
- package/theme-style/vft-date-time-select.css +1 -1
- package/theme-style/vft-descriptions-item.css +1 -1
- package/theme-style/vft-descriptions.css +1 -1
- package/theme-style/vft-dialog.css +1 -1
- package/theme-style/vft-divider.css +1 -1
- package/theme-style/vft-drawer.css +1 -1
- package/theme-style/vft-dropdown.css +1 -1
- package/theme-style/vft-empty.css +1 -1
- package/theme-style/vft-footer-layout.css +1 -1
- package/theme-style/vft-footer.css +1 -1
- package/theme-style/vft-form.css +1 -1
- package/theme-style/vft-full-screen.css +1 -1
- package/theme-style/vft-header-layout.css +1 -1
- package/theme-style/vft-header.css +1 -1
- package/theme-style/vft-horizontal-menu.css +1 -1
- package/theme-style/vft-icon-text.css +1 -1
- package/theme-style/vft-icon.css +1 -1
- package/theme-style/vft-iframe-layout.css +1 -1
- package/theme-style/vft-image-viewer.css +1 -1
- package/theme-style/vft-image.css +1 -1
- package/theme-style/vft-input-number.css +1 -1
- package/theme-style/vft-input-tag.css +1 -1
- package/theme-style/vft-input.css +1 -1
- package/theme-style/vft-link.css +1 -1
- package/theme-style/vft-list-cell.css +1 -1
- package/theme-style/vft-loading.css +1 -1
- package/theme-style/vft-logo.css +1 -1
- package/theme-style/vft-main.css +1 -1
- package/theme-style/vft-md-code-demo.css +1 -1
- package/theme-style/vft-md-code-tabs.css +1 -1
- package/theme-style/vft-md-comment.css +1 -1
- package/theme-style/vft-md-container.css +1 -1
- package/theme-style/vft-md-tabs.css +1 -1
- package/theme-style/vft-md-vue-playground.css +1 -1
- package/theme-style/vft-menu.css +1 -1
- package/theme-style/vft-message-box.css +1 -1
- package/theme-style/vft-message.css +1 -1
- package/theme-style/vft-multiple-tabs.css +1 -1
- package/theme-style/vft-notification.css +1 -1
- package/theme-style/vft-option-group.css +1 -1
- package/theme-style/vft-option-item.css +1 -1
- package/theme-style/vft-option.css +1 -1
- package/theme-style/vft-overlay.css +1 -1
- package/theme-style/vft-page-wrapper.css +1 -1
- package/theme-style/vft-pagination.css +1 -1
- package/theme-style/vft-popconfirm.css +1 -1
- package/theme-style/vft-popover.css +1 -1
- package/theme-style/vft-popper.css +1 -1
- package/theme-style/vft-progress.css +1 -1
- package/theme-style/vft-radio-button.css +1 -1
- package/theme-style/vft-radio-group.css +1 -1
- package/theme-style/vft-rate.css +1 -1
- package/theme-style/vft-result.css +1 -1
- package/theme-style/vft-row.css +1 -1
- package/theme-style/vft-scrollbar.css +1 -1
- package/theme-style/vft-search.css +1 -1
- package/theme-style/vft-segmented.css +1 -1
- package/theme-style/vft-select-dropdown-v2.css +1 -1
- package/theme-style/vft-select-dropdown.css +1 -1
- package/theme-style/vft-select.css +1 -1
- package/theme-style/vft-side-menu.css +1 -1
- package/theme-style/vft-skeleton-item.css +1 -1
- package/theme-style/vft-skeleton.css +1 -1
- package/theme-style/vft-slider.css +1 -1
- package/theme-style/vft-space.css +1 -1
- package/theme-style/vft-spinner.css +1 -1
- package/theme-style/vft-statistic.css +1 -1
- package/theme-style/vft-step.css +1 -1
- package/theme-style/vft-steps.css +1 -1
- package/theme-style/vft-super-form.css +1 -1
- package/theme-style/vft-switch.css +1 -1
- package/theme-style/vft-table.css +1 -1
- package/theme-style/vft-tabs.css +1 -1
- package/theme-style/vft-tag.css +1 -1
- package/theme-style/vft-time-picker.css +1 -1
- package/theme-style/vft-time-select.css +1 -1
- package/theme-style/vft-timeline-item.css +1 -1
- package/theme-style/vft-timeline.css +1 -1
- package/theme-style/vft-transfer.css +1 -1
- package/theme-style/vft-tree-select.css +1 -1
- package/theme-style/vft-tree.css +1 -1
- package/theme-style/vft-virtual-list.css +1 -1
- package/web-types.json +1 -1
|
@@ -1,76 +1,80 @@
|
|
|
1
|
-
import { defineComponent as B, getCurrentInstance as
|
|
2
|
-
import { VftTabs as
|
|
3
|
-
import { VftIcon as
|
|
4
|
-
import { isClient as
|
|
1
|
+
import { defineComponent as B, getCurrentInstance as q, computed as d, ref as v, watchEffect as G, unref as t, onMounted as J, createElementBlock as P, openBlock as g, normalizeStyle as O, normalizeClass as V, createVNode as h, createSlots as Q, withCtx as T, Fragment as X, renderList as Y, createBlock as Z, renderSlot as ee, createElementVNode as te } from "vue";
|
|
2
|
+
import { VftTabs as ae, VftTabPane as ne } from "../tabs/index.js";
|
|
3
|
+
import { VftIcon as w } from "../icon/index.js";
|
|
4
|
+
import { isClient as oe } from "@vueuse/core";
|
|
5
5
|
import "@vft/utils";
|
|
6
6
|
import { addUnit as o } from "../../utils/helper.js";
|
|
7
|
-
import { generateCssVars as
|
|
7
|
+
import { generateCssVars as M } from "../../utils/ns-cover.js";
|
|
8
8
|
import "lodash-es";
|
|
9
9
|
import "../form/index.js";
|
|
10
|
-
import { useNamespace as
|
|
10
|
+
import { useNamespace as le } from "../../hooks/use-namespace/index.js";
|
|
11
11
|
import "../../hooks/use-model-toggle/index.js";
|
|
12
12
|
import "@popperjs/core";
|
|
13
13
|
import "../../hooks/use-z-index/index.js";
|
|
14
|
-
import { useRouterHelper as
|
|
15
|
-
import { useMultipleTabStore as
|
|
16
|
-
import { useRefs as
|
|
17
|
-
import
|
|
18
|
-
import { onBeforeRouteLeave as
|
|
19
|
-
import
|
|
20
|
-
import { initAffixTabs as
|
|
14
|
+
import { useRouterHelper as ie, getRouterKeyPath as b, listenerRouteChange as re } from "@vft/router";
|
|
15
|
+
import { useMultipleTabStore as se, isTabPinned as $, useTabs as ue } from "@vft/store";
|
|
16
|
+
import { useRefs as ce } from "@vft/use";
|
|
17
|
+
import fe from "hotkeys-js";
|
|
18
|
+
import { onBeforeRouteLeave as me } from "vue-router";
|
|
19
|
+
import de from "./tab-content.vue2.js";
|
|
20
|
+
import { initAffixTabs as ve, useTabsDrag as he } from "./use/use-multiple-tabs.js";
|
|
21
21
|
import "../context-menu/context-menu.vue2.js";
|
|
22
|
-
const
|
|
22
|
+
const be = B({
|
|
23
23
|
name: "vft-multiple-tabs"
|
|
24
|
-
}),
|
|
25
|
-
...
|
|
24
|
+
}), ze = /* @__PURE__ */ B({
|
|
25
|
+
...be,
|
|
26
26
|
props: {
|
|
27
27
|
tabsStyle: {},
|
|
28
28
|
contextMenuStyle: {},
|
|
29
29
|
canDrag: { type: Boolean },
|
|
30
30
|
showNavRight: { type: Boolean, default: !0 },
|
|
31
|
-
fixTabCount: {},
|
|
31
|
+
fixTabCount: { default: 0 },
|
|
32
32
|
fixExtraScrollWidth: {}
|
|
33
33
|
},
|
|
34
34
|
setup(u) {
|
|
35
|
-
const
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
35
|
+
const R = le("multiple-tabs"), s = q().appContext.config.globalProperties.$router, I = ve(s), l = se(), f = d(
|
|
36
|
+
() => l.getTabList.filter((e) => !e.meta?.hideTab && $(e)).length
|
|
37
|
+
), L = d(
|
|
38
|
+
() => Math.max(u.fixTabCount, f.value)
|
|
39
|
+
), r = v(""), i = v(0), p = v(), { go: C } = ie(s), m = d(() => l.getTabList.filter((e) => !e.meta?.hideTab));
|
|
40
|
+
G(() => {
|
|
41
|
+
if (r.value) {
|
|
42
|
+
const e = m.value.findIndex((n) => b(n) === r.value);
|
|
43
|
+
e === -1 ? i.value = m.value?.length - 1 : i.value = e, i.value = i.value < f.value ? f.value - 1 : i.value;
|
|
40
44
|
}
|
|
41
|
-
}),
|
|
42
|
-
|
|
43
|
-
}),
|
|
45
|
+
}), oe && me(() => {
|
|
46
|
+
p.value = t(s.currentRoute);
|
|
47
|
+
}), re(({ route: e }) => {
|
|
44
48
|
if (!e || e.meta?.hasTokenToRoot)
|
|
45
49
|
return;
|
|
46
|
-
const { meta: n = {} } = e, { currentActivePath: a, hideTab: c } = n,
|
|
47
|
-
if (
|
|
48
|
-
const
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
t(
|
|
52
|
-
|
|
50
|
+
const { meta: n = {} } = e, { currentActivePath: a, hideTab: c } = n, W = c ? a : null, S = b(e);
|
|
51
|
+
if (r.value !== S && (r.value = S), W) {
|
|
52
|
+
const k = s.getRoutes().find((j) => j.path === a);
|
|
53
|
+
k && l.addTab(
|
|
54
|
+
k,
|
|
55
|
+
t(p),
|
|
56
|
+
i.value,
|
|
53
57
|
e
|
|
54
58
|
);
|
|
55
|
-
} else c || l.addTab(t(e), t(
|
|
59
|
+
} else c || l.addTab(t(e), t(p), i.value);
|
|
56
60
|
});
|
|
57
|
-
function
|
|
58
|
-
if (
|
|
61
|
+
function N(e) {
|
|
62
|
+
if (r.value === e.paneName)
|
|
59
63
|
return;
|
|
60
64
|
const n = m.value[e.attrs.index];
|
|
61
|
-
|
|
65
|
+
r.value = e.paneName;
|
|
62
66
|
const a = n?.meta?.hideActiveRoute?.fullPath;
|
|
63
|
-
|
|
67
|
+
C(a || n.fullPath || n.path);
|
|
64
68
|
}
|
|
65
|
-
function
|
|
69
|
+
function _(e) {
|
|
66
70
|
l.closeTabByKey(e, s);
|
|
67
71
|
}
|
|
68
|
-
const { refs:
|
|
69
|
-
function
|
|
72
|
+
const { refs: E, setRefs: F } = ce();
|
|
73
|
+
function A(e) {
|
|
70
74
|
const n = e.pane.attrs.index, a = e.event;
|
|
71
|
-
|
|
75
|
+
E.value[n].handleContext(a);
|
|
72
76
|
}
|
|
73
|
-
const
|
|
77
|
+
const z = d(() => {
|
|
74
78
|
const e = {
|
|
75
79
|
padding: "4px 0 0",
|
|
76
80
|
"border-bottom": "none",
|
|
@@ -85,9 +89,9 @@ const de = B({
|
|
|
85
89
|
"item-border-radius": `${o(5)} ${o(5)} 0 0`,
|
|
86
90
|
"item-border": "none"
|
|
87
91
|
};
|
|
88
|
-
return {
|
|
89
|
-
}), { closeCurrent:
|
|
90
|
-
|
|
92
|
+
return { ...M(e, "tabs"), ...u.tabsStyle };
|
|
93
|
+
}), { closeCurrent: D } = ue(), H = {
|
|
94
|
+
...M(
|
|
91
95
|
{
|
|
92
96
|
"sub-item-height": o(40),
|
|
93
97
|
"item-min-width": o(150)
|
|
@@ -95,44 +99,44 @@ const de = B({
|
|
|
95
99
|
"menu"
|
|
96
100
|
),
|
|
97
101
|
...u.contextMenuStyle
|
|
98
|
-
},
|
|
99
|
-
l.toggleFullScreen(l.getTabList[
|
|
100
|
-
},
|
|
102
|
+
}, K = () => {
|
|
103
|
+
l.toggleFullScreen(l.getTabList[i.value], s);
|
|
104
|
+
}, x = v(!1);
|
|
101
105
|
let y;
|
|
102
|
-
const
|
|
103
|
-
clearInterval(y),
|
|
104
|
-
|
|
106
|
+
const U = () => {
|
|
107
|
+
clearInterval(y), x.value = !0, l.refreshPage(0, s, l.getTabList[i.value]), y = setTimeout(() => {
|
|
108
|
+
x.value = !1;
|
|
105
109
|
}, 500);
|
|
106
110
|
};
|
|
107
|
-
return
|
|
108
|
-
u.canDrag &&
|
|
111
|
+
return J(() => {
|
|
112
|
+
u.canDrag && he(I), fe("command+e, ctrl+e", () => (D(), !1));
|
|
109
113
|
}), (e, n) => (g(), P("div", {
|
|
110
|
-
class:
|
|
111
|
-
style:
|
|
114
|
+
class: V(t(R).b()),
|
|
115
|
+
style: O(z.value)
|
|
112
116
|
}, [
|
|
113
|
-
h(t(
|
|
117
|
+
h(t(ae), {
|
|
114
118
|
"show-bar": !1,
|
|
115
|
-
"fix-tab-count":
|
|
119
|
+
"fix-tab-count": L.value,
|
|
116
120
|
"fix-extra-scroll-width": u.fixExtraScrollWidth,
|
|
117
|
-
modelValue:
|
|
118
|
-
"onUpdate:modelValue": n[0] || (n[0] = (a) =>
|
|
119
|
-
onTabClick:
|
|
120
|
-
onTabRemove:
|
|
121
|
-
onTabContextMenu:
|
|
122
|
-
},
|
|
123
|
-
default:
|
|
124
|
-
(g(!0), P(
|
|
125
|
-
key: t(
|
|
126
|
-
closable: !a
|
|
121
|
+
modelValue: r.value,
|
|
122
|
+
"onUpdate:modelValue": n[0] || (n[0] = (a) => r.value = a),
|
|
123
|
+
onTabClick: N,
|
|
124
|
+
onTabRemove: _,
|
|
125
|
+
onTabContextMenu: A
|
|
126
|
+
}, Q({
|
|
127
|
+
default: T(() => [
|
|
128
|
+
(g(!0), P(X, null, Y(m.value, (a, c) => (g(), Z(t(ne), {
|
|
129
|
+
key: t(b)(a) + c,
|
|
130
|
+
closable: !t($)(a),
|
|
127
131
|
index: c,
|
|
128
|
-
name: t(
|
|
132
|
+
name: t(b)(a)
|
|
129
133
|
}, {
|
|
130
|
-
label:
|
|
131
|
-
h(
|
|
132
|
-
"context-menu-style":
|
|
133
|
-
"affix-num":
|
|
134
|
+
label: T(() => [
|
|
135
|
+
h(de, {
|
|
136
|
+
"context-menu-style": H,
|
|
137
|
+
"affix-num": f.value,
|
|
134
138
|
ref_for: !0,
|
|
135
|
-
ref: t(
|
|
139
|
+
ref: t(F)(c),
|
|
136
140
|
"tab-item": a
|
|
137
141
|
}, null, 8, ["affix-num", "tab-item"])
|
|
138
142
|
]),
|
|
@@ -143,20 +147,20 @@ const de = B({
|
|
|
143
147
|
}, [
|
|
144
148
|
u.showNavRight ? {
|
|
145
149
|
name: "navRight",
|
|
146
|
-
fn:
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
class:
|
|
150
|
+
fn: T(() => [
|
|
151
|
+
ee(e.$slots, "nav-right", {}, () => [
|
|
152
|
+
te("div", {
|
|
153
|
+
class: V(t(R).e("nav-right"))
|
|
150
154
|
}, [
|
|
151
|
-
h(t(
|
|
152
|
-
rotate:
|
|
155
|
+
h(t(w), {
|
|
156
|
+
rotate: x.value,
|
|
153
157
|
"rotate-speed": 1,
|
|
154
|
-
onClick:
|
|
158
|
+
onClick: U,
|
|
155
159
|
icon: "icon-refresh-right",
|
|
156
160
|
pointer: ""
|
|
157
161
|
}, null, 8, ["rotate"]),
|
|
158
|
-
h(t(
|
|
159
|
-
onClick:
|
|
162
|
+
h(t(w), {
|
|
163
|
+
onClick: K,
|
|
160
164
|
icon: t(l).isFullScreen ? "icon-collapse" : "icon-expand",
|
|
161
165
|
pointer: ""
|
|
162
166
|
}, null, 8, ["icon"])
|
|
@@ -170,5 +174,5 @@ const de = B({
|
|
|
170
174
|
}
|
|
171
175
|
});
|
|
172
176
|
export {
|
|
173
|
-
|
|
177
|
+
ze as default
|
|
174
178
|
};
|
|
@@ -1,97 +1,113 @@
|
|
|
1
|
-
import { getRouterKeyPath as
|
|
2
|
-
import { useMultipleTabStore as
|
|
1
|
+
import { getRouterKeyPath as a } from "@vft/router";
|
|
2
|
+
import { useMultipleTabStore as S, useTabs as O, isTabPinned as U } from "@vft/store";
|
|
3
3
|
import "@vft/utils";
|
|
4
|
-
import { reactive as
|
|
4
|
+
import { reactive as q, computed as y } from "vue";
|
|
5
5
|
import "../../context-menu/context-menu.vue2.js";
|
|
6
6
|
import "../../icon/index.js";
|
|
7
7
|
import "vue-router";
|
|
8
|
-
function
|
|
9
|
-
const
|
|
8
|
+
function F(e, o) {
|
|
9
|
+
const s = q({
|
|
10
10
|
current: null,
|
|
11
11
|
currentIndex: 0
|
|
12
|
-
}), n =
|
|
13
|
-
refreshPage:
|
|
14
|
-
closeAll:
|
|
15
|
-
close:
|
|
16
|
-
closeLeft:
|
|
12
|
+
}), n = S(), {
|
|
13
|
+
refreshPage: g,
|
|
14
|
+
closeAll: u,
|
|
15
|
+
close: h,
|
|
16
|
+
closeLeft: p,
|
|
17
17
|
closeOther: f,
|
|
18
|
-
closeRight:
|
|
19
|
-
newWinTab:
|
|
20
|
-
fullScreen:
|
|
21
|
-
alonePage:
|
|
22
|
-
|
|
18
|
+
closeRight: x,
|
|
19
|
+
newWinTab: b,
|
|
20
|
+
fullScreen: T,
|
|
21
|
+
alonePage: C,
|
|
22
|
+
pinTab: L,
|
|
23
|
+
unpinTab: v
|
|
24
|
+
} = O(), D = y(() => {
|
|
23
25
|
if (!e)
|
|
24
26
|
return;
|
|
25
|
-
const { meta:
|
|
27
|
+
const { meta: i } = e, t = s.currentIndex, r = U(e), c = !r, l = !!i?.userPinned, w = t === 0 || t <= o, M = n.getTabList.length <= o || t === n.getTabList.length - 1 && n.getLastDragEndIndex >= 0, R = n.getTabList.length === o || n.getTabList.length === o + 1 && t === o, d = n.getTabList.length === o;
|
|
26
28
|
return [
|
|
27
29
|
{
|
|
28
30
|
iconCfg: { icon: "icon-refresh-right" },
|
|
29
31
|
text: "刷新",
|
|
30
|
-
handler: () =>
|
|
32
|
+
handler: () => g(e)
|
|
31
33
|
},
|
|
32
34
|
{
|
|
33
35
|
iconCfg: { icon: "icon-new-tab" },
|
|
34
36
|
text: "新页面打开",
|
|
35
|
-
handler: () =>
|
|
37
|
+
handler: () => b(e),
|
|
36
38
|
divider: !0
|
|
37
39
|
},
|
|
38
40
|
{
|
|
39
41
|
iconCfg: { icon: "icon-close-tab" },
|
|
40
42
|
text: "关闭标签页",
|
|
41
|
-
disabled:
|
|
42
|
-
handler: () =>
|
|
43
|
+
disabled: r || d,
|
|
44
|
+
handler: () => h(e)
|
|
43
45
|
},
|
|
44
46
|
{
|
|
45
47
|
iconCfg: { icon: "icon-arrow-close-left" },
|
|
46
48
|
text: "关闭左侧标签页",
|
|
47
|
-
disabled:
|
|
48
|
-
handler: () =>
|
|
49
|
+
disabled: w,
|
|
50
|
+
handler: () => p(e)
|
|
49
51
|
},
|
|
50
52
|
{
|
|
51
53
|
iconCfg: { icon: "icon-arrow-close-right" },
|
|
52
54
|
text: "关闭右侧标签页",
|
|
53
|
-
disabled:
|
|
55
|
+
disabled: M,
|
|
54
56
|
divider: !0,
|
|
55
|
-
handler: () =>
|
|
57
|
+
handler: () => x(e)
|
|
56
58
|
},
|
|
57
59
|
{
|
|
58
60
|
iconCfg: { icon: "icon-close-box-multiple-outline" },
|
|
59
61
|
text: "关闭其它标签页",
|
|
60
|
-
disabled:
|
|
62
|
+
disabled: R,
|
|
61
63
|
handler: () => f(e)
|
|
62
64
|
},
|
|
63
65
|
{
|
|
64
66
|
iconCfg: { icon: "icon-vector-square-delete" },
|
|
65
67
|
text: "关闭所有标签页",
|
|
66
|
-
disabled:
|
|
68
|
+
disabled: d,
|
|
67
69
|
divider: !0,
|
|
68
|
-
handler: () =>
|
|
70
|
+
handler: () => u()
|
|
69
71
|
},
|
|
70
72
|
{
|
|
71
73
|
iconCfg: { icon: "icon-full-screen" },
|
|
72
74
|
text: "全屏",
|
|
73
|
-
handler: () =>
|
|
75
|
+
handler: () => T(e)
|
|
74
76
|
},
|
|
75
77
|
{
|
|
76
78
|
iconCfg: { icon: "icon-separate" },
|
|
77
79
|
text: "独立页面",
|
|
78
|
-
handler: () =>
|
|
79
|
-
|
|
80
|
+
handler: () => C(e),
|
|
81
|
+
divider: c || l
|
|
82
|
+
},
|
|
83
|
+
...c ? [
|
|
84
|
+
{
|
|
85
|
+
iconCfg: { icon: "icon-tab-pin" },
|
|
86
|
+
text: "固定",
|
|
87
|
+
handler: () => L(e)
|
|
88
|
+
}
|
|
89
|
+
] : l ? [
|
|
90
|
+
{
|
|
91
|
+
iconCfg: { icon: "icon-tab-unpin" },
|
|
92
|
+
text: "取消固定",
|
|
93
|
+
handler: () => v(e)
|
|
94
|
+
}
|
|
95
|
+
] : []
|
|
80
96
|
];
|
|
81
97
|
});
|
|
82
|
-
function
|
|
83
|
-
return (
|
|
84
|
-
if (!
|
|
98
|
+
function P(i) {
|
|
99
|
+
return (t) => {
|
|
100
|
+
if (!i)
|
|
85
101
|
return;
|
|
86
|
-
|
|
87
|
-
const
|
|
88
|
-
(
|
|
102
|
+
t?.preventDefault();
|
|
103
|
+
const r = n.getTabList.findIndex(
|
|
104
|
+
(c) => a(c) === a(i)
|
|
89
105
|
);
|
|
90
|
-
|
|
106
|
+
s.current = i, s.currentIndex = r;
|
|
91
107
|
};
|
|
92
108
|
}
|
|
93
|
-
return { getDropMenuList:
|
|
109
|
+
return { getDropMenuList: D, handleContextMenu: P };
|
|
94
110
|
}
|
|
95
111
|
export {
|
|
96
|
-
|
|
112
|
+
F as useTabDropdown
|
|
97
113
|
};
|
package/es/package.json.d.ts
CHANGED
package/es/package.json.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),oe=require("lodash-es"),se=require("@vueuse/core"),ne=require("../../utils/dom/aria.cjs"),ae=require("@vft/utils"),Oe=require("../../utils/error.cjs");require("../config-provider/hooks/use-global-config.cjs");const p=require("../../constants/aria.cjs"),re=require("../../constants/event.cjs");require("../form/index.cjs");const Fe=require("../cascader-panel/index.cjs"),Me=require("../input/index.cjs"),ie=require("../tooltip/index.cjs"),ue=require("../scrollbar/index.cjs"),ce=require("../tag/index.cjs"),A=require("../icon/index.cjs"),He=require("@vft/directives"),pe=require("../../hooks/use-namespace/index.cjs");require("../../hooks/use-model-toggle/index.cjs");require("@popperjs/core");require("../../hooks/use-z-index/index.cjs");const Ke=require("../../hooks/use-composition/index.cjs"),Ae=require("../../hooks/use-empty-values/index.cjs"),de=require("./cascader.cjs"),Le=require("../form/hooks/use-form-item.cjs"),Re=require("../form/hooks/use-form-common-props.cjs"),We={key:0},Ue=["placeholder"],je=["onClick"],Ge="VftCascader",Je=e.defineComponent({name:Ge}),Qe=e.defineComponent({...Je,props:de.cascaderProps,emits:de.cascaderEmits,setup(fe,{expose:ve,emit:me}){const a=fe,f=me,ge={modifiers:[{name:"arrowPosition",enabled:!0,phase:"main",fn:({state:t})=>{const{modifiersData:l,placement:o}=t;["right","left","bottom","top"].includes(o)||l.arrow&&(l.arrow.x=35)},requires:["arrow"]}]},L=e.useAttrs();let C=0,x=0;const n=pe.useNamespace("cascader"),D=pe.useNamespace("input"),{form:he,formItem:R}=Le.useFormItem(),{valueOnClear:ke}=Ae.useEmptyValues(a),{isComposing:W,handleComposition:d}=Ke.useComposition({afterComposition(t){const l=t.target?.value;K(l)}}),q=e.ref(null),E=e.ref(null),U=e.ref(null),u=e.ref(null),b=e.ref(null),c=e.ref(!1),z=e.ref(!1),v=e.ref(!1),P=e.ref(!1),V=e.ref(""),h=e.ref(""),k=e.ref([]),w=e.ref([]),I=e.ref([]),Ce=e.computed(()=>L.style),m=e.computed(()=>a.disabled||he?.disabled),j=e.computed(()=>a.placeholder??"请选择"),Ee=e.computed(()=>h.value||k.value.length>0||W.value?"":j.value),T=Re.useFormSize(),G=e.computed(()=>T.value==="small"?"small":"default"),g=e.computed(()=>!!a.props.multiple),J=e.computed(()=>!a.filterable||g.value),Q=e.computed(()=>g.value?h.value:V.value),N=e.computed(()=>u.value?.checkedNodes||[]),ye=e.computed(()=>!a.clearable||m.value||v.value||!z.value?!1:!!N.value.length),B=e.computed(()=>{const{showAllLevels:t,separator:l}=a,o=N.value;return o.length?g.value?"":o[0].calcText(t,l):""}),be=e.computed(()=>R?.validateState||""),X=e.computed({get(){return oe.cloneDeep(a.modelValue)},set(t){const l=t??ke.value;f(re.UPDATE_MODEL_EVENT,l),f(re.CHANGE_EVENT,l),a.validateEvent&&R?.validate("change").catch(o=>Oe.debugWarn(o))}}),Ve=e.computed(()=>[n.b(),n.m(T.value),n.is("disabled",m.value),L.class]),we=e.computed(()=>[D.e("icon"),n.is("reverse",c.value)]),Te=e.computed(()=>n.is("focus",c.value||P.value)),Y=e.computed(()=>q.value?.popperRef?.contentRef),i=t=>{m.value||(t=t??!c.value,t!==c.value&&(c.value=t,E.value?.input?.setAttribute("aria-expanded",`${t}`),t?(y(),e.nextTick(u.value?.scrollToExpandingNode)):a.filterable&&H(),f("visibleChange",t)))},y=()=>{e.nextTick(()=>{q.value?.updatePopper()})},O=()=>{v.value=!1},F=t=>{const{showAllLevels:l,separator:o}=a;return{node:t,key:t.uid,text:t.calcText(l,o),hitState:!1,closable:!m.value&&!t.isDisabled,isCollapseTag:!1}},S=t=>{const l=t.node;l.doCheck(!1),u.value?.calculateCheckedValue(),f("removeTag",l.valueByOption)},Ne=()=>{switch(a.showCheckedStrategy){case"child":return N.value;case"parent":{const t=_(!1),l=t.map(s=>s.value);return t.filter(s=>!s.parent||!l.includes(s.parent.value))}default:return[]}},Be=()=>{if(!g.value)return;const t=Ne(),l=[],o=[];if(t.forEach(s=>o.push(F(s))),w.value=o,t.length){t.slice(0,a.maxCollapseTags).forEach($=>l.push(F($)));const s=t.slice(a.maxCollapseTags),r=s.length;r&&(a.collapseTags?l.push({key:-1,text:`+ ${r}`,closable:!1,isCollapseTag:!0}):s.forEach($=>l.push(F($))))}k.value=l},Z=()=>{const{filterMethod:t,showAllLevels:l,separator:o}=a,s=u.value?.getFlattedNodes(!a.props.checkStrictly)?.filter(r=>r.isDisabled?!1:(r.calcText(l,o),t(r,Q.value)));g.value&&(k.value.forEach(r=>{r.hitState=!1}),w.value.forEach(r=>{r.hitState=!1})),v.value=!0,I.value=s,y()},Se=()=>{let t;v.value&&b.value?t=b.value.$el.querySelector(`.${n.e("suggestion-item")}`):t=u.value?.$el.querySelector(`.${n.b("node")}[tabindex="-1"]`),t&&(t.focus(),!v.value&&t.click())},M=()=>{const t=E.value?.input,l=U.value,o=b.value?.$el;if(!(!ae.isClient||!t)){if(o){const s=o.querySelector(`.${n.e("suggestion-list")}`);s.style.minWidth=`${t.offsetWidth}px`}if(l){const{offsetHeight:s}=l,r=k.value.length>0?`${Math.max(s,C)-2}px`:`${C}px`;t.style.height=r,y()}}},_=t=>u.value?.getCheckedNodes(t),$e=t=>{y(),f("expandChange",t)},xe=t=>{if(!W.value)switch(t.code){case p.EVENT_CODE.enter:case p.EVENT_CODE.numpadEnter:i();break;case p.EVENT_CODE.down:i(!0),e.nextTick(Se),t.preventDefault();break;case p.EVENT_CODE.esc:c.value===!0&&(t.preventDefault(),t.stopPropagation(),i(!1));break;case p.EVENT_CODE.tab:i(!1);break}},De=()=>{u.value?.clearCheckedNodes(),!c.value&&a.filterable&&H(),i(!1),f("clear")},H=()=>{const{value:t}=B;V.value=t,h.value=t},qe=t=>{const{checked:l}=t;g.value?u.value?.handleCheckChange(t,!l,!1):(!l&&u.value?.handleCheckChange(t,!0,!1),i(!1))},ze=t=>{const l=t.target,{code:o}=t;switch(o){case p.EVENT_CODE.up:case p.EVENT_CODE.down:{t.preventDefault();const s=o===p.EVENT_CODE.up?-1:1;ne.focusNode(ne.getSibling(l,s,`.${n.e("suggestion-item")}[tabindex="-1"]`));break}case p.EVENT_CODE.enter:case p.EVENT_CODE.numpadEnter:l.click();break}},Pe=()=>{const t=k.value,l=t[t.length-1];x=h.value?0:x+1,!(!l||!x||a.collapseTags&&t.length>1)&&(l.hitState?S(l):l.hitState=!0)},ee=t=>{const l=t.target,o=n.e("search-input");l.className===o&&(P.value=!0),f("focus",t)},te=t=>{P.value=!1,f("blur",t)},Ie=oe.debounce(()=>{const{value:t}=Q;if(!t)return;const l=a.beforeFilter(t);ae.isPromise(l)?l.then(Z).catch(()=>{}):l!==!1?Z():O()},a.debounce),K=(t,l)=>{!c.value&&i(!0),!l?.isComposing&&(t?Ie():O())},le=t=>Number.parseFloat(se.useCssVar(D.cssVarName("input-height"),t).value)-2;return e.watch(v,y),e.watch([N,m,()=>a.collapseTags],Be),e.watch(k,()=>{e.nextTick(()=>M())}),e.watch(T,async()=>{await e.nextTick();const t=E.value.input;C=le(t)||C,M()}),e.watch(B,H,{immediate:!0}),e.onMounted(()=>{const t=E.value.input,l=le(t);C=t.offsetHeight||l,se.useResizeObserver(t,M)}),ve({getCheckedNodes:_,cascaderPanelRef:u,togglePopperVisible:i,contentRef:Y,presentText:B}),(t,l)=>(e.openBlock(),e.createBlock(e.unref(ie.VftTooltip),{ref_key:"tooltipRef",ref:q,visible:c.value,teleported:t.teleported,"popper-class":[e.unref(n).e("dropdown"),t.popperClass],"popper-options":ge,"fallback-placements":t.fallbackPlacements,"stop-popper-mouse-event":!1,"gpu-acceleration":!1,placement:t.placement,transition:`${e.unref(n).namespace.value}-zoom-in-top`,effect:t.effect,pure:"",persistent:t.persistent,onHide:O},{default:e.withCtx(()=>[e.withDirectives((e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(Ve.value),style:e.normalizeStyle(Ce.value),onClick:l[8]||(l[8]=()=>i(J.value?void 0:!0)),onKeydown:xe,onMouseenter:l[9]||(l[9]=o=>z.value=!0),onMouseleave:l[10]||(l[10]=o=>z.value=!1)},[e.createVNode(e.unref(Me.VftInput),{ref_key:"input",ref:E,modelValue:V.value,"onUpdate:modelValue":l[1]||(l[1]=o=>V.value=o),placeholder:Ee.value,readonly:J.value,disabled:m.value,"validate-event":!1,size:e.unref(T),class:e.normalizeClass(Te.value),tabindex:g.value&&t.filterable&&!m.value?-1:void 0,onCompositionstart:e.unref(d),onCompositionupdate:e.unref(d),onCompositionend:e.unref(d),onFocus:ee,onBlur:te,onInput:K},e.createSlots({suffix:e.withCtx(()=>[ye.value?(e.openBlock(),e.createBlock(e.unref(A.VftIcon),{key:"clear",icon:"icon-circle-close",class:e.normalizeClass(["icon-circle-close",[e.unref(D).e("icon")]]),onClick:e.withModifiers(De,["stop"])},null,8,["class"])):(e.openBlock(),e.createBlock(e.unref(A.VftIcon),{icon:"icon-arrow-down",key:"arrow-down",class:e.normalizeClass(we.value),onClick:l[0]||(l[0]=e.withModifiers(o=>i(),["stop"]))},null,8,["class"]))]),_:2},[t.$slots.prefix?{name:"prefix",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"prefix")]),key:"0"}:void 0]),1032,["modelValue","placeholder","readonly","disabled","size","class","tabindex","onCompositionstart","onCompositionupdate","onCompositionend"]),g.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"tagWrapper",ref:U,class:e.normalizeClass([e.unref(n).e("tags"),e.unref(n).is("validate",!!be.value)])},[e.renderSlot(t.$slots,"tag",{data:w.value,deleteTag:S},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,o=>(e.openBlock(),e.createBlock(e.unref(ce.VftTag),{key:o.key,type:t.tagType,size:G.value,effect:t.tagEffect,hit:o.hitState,closable:o.closable,"disable-transitions":"",onClose:s=>S(o)},{default:e.withCtx(()=>[o.isCollapseTag===!1?(e.openBlock(),e.createElementBlock("span",We,e.toDisplayString(o.text),1)):(e.openBlock(),e.createBlock(e.unref(ie.VftTooltip),{key:1,disabled:c.value||!t.collapseTagsTooltip,"fallback-placements":["bottom","top","right","left"],placement:"bottom",effect:t.effect},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(o.text),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(ue.VftScrollbar),{"max-height":t.maxCollapseTagsTooltipHeight},{default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(e.unref(n).e("collapse-tags"))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value.slice(t.maxCollapseTags),(s,r)=>(e.openBlock(),e.createElementBlock("div",{key:r,class:e.normalizeClass(e.unref(n).e("collapse-tag"))},[(e.openBlock(),e.createBlock(e.unref(ce.VftTag),{key:s.key,class:"in-tooltip",type:t.tagType,size:G.value,effect:t.tagEffect,hit:s.hitState,closable:s.closable,"disable-transitions":"",onClose:$=>S(s)},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(s.text),1)]),_:2},1032,["type","size","effect","hit","closable","onClose"]))],2))),128))],2)]),_:1},8,["max-height"])]),_:2},1032,["disabled","effect"]))]),_:2},1032,["type","size","effect","hit","closable","onClose"]))),128))]),t.filterable&&!m.value?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:0,"onUpdate:modelValue":l[2]||(l[2]=o=>h.value=o),type:"text",class:e.normalizeClass(e.unref(n).e("search-input")),placeholder:B.value?"":j.value,onInput:l[3]||(l[3]=o=>K(h.value,o)),onClick:l[4]||(l[4]=e.withModifiers(o=>i(!0),["stop"])),onKeydown:e.withKeys(Pe,["delete"]),onCompositionstart:l[5]||(l[5]=(...o)=>e.unref(d)&&e.unref(d)(...o)),onCompositionupdate:l[6]||(l[6]=(...o)=>e.unref(d)&&e.unref(d)(...o)),onCompositionend:l[7]||(l[7]=(...o)=>e.unref(d)&&e.unref(d)(...o)),onFocus:ee,onBlur:te},null,42,Ue)),[[e.vModelText,h.value]]):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)],38)),[[e.unref(He.ClickOutside),()=>i(!1),Y.value]])]),content:e.withCtx(()=>[t.$slots.header?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(e.unref(n).e("header")),onClick:l[11]||(l[11]=e.withModifiers(()=>{},["stop"]))},[e.renderSlot(t.$slots,"header")],2)):e.createCommentVNode("",!0),e.withDirectives(e.createVNode(e.unref(Fe.VftCascaderPanel),{ref_key:"cascaderPanelRef",ref:u,modelValue:X.value,"onUpdate:modelValue":l[12]||(l[12]=o=>X.value=o),options:t.options,props:a.props,border:!1,"render-label":t.$slots.default,onExpandChange:$e,onClose:l[13]||(l[13]=o=>t.$nextTick(()=>i(!1)))},{empty:e.withCtx(()=>[e.renderSlot(t.$slots,"empty")]),_:3},8,["modelValue","options","props","render-label"]),[[e.vShow,!v.value]]),t.filterable?e.withDirectives((e.openBlock(),e.createBlock(e.unref(ue.VftScrollbar),{key:1,ref_key:"suggestionPanel",ref:b,tag:"ul",class:e.normalizeClass(e.unref(n).e("suggestion-panel")),"view-class":e.unref(n).e("suggestion-list"),onKeydown:ze},{default:e.withCtx(()=>[I.value.length?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(I.value,o=>(e.openBlock(),e.createElementBlock("li",{key:o.uid,class:e.normalizeClass([e.unref(n).e("suggestion-item"),e.unref(n).is("checked",o.checked)]),tabindex:-1,onClick:s=>qe(o)},[e.renderSlot(t.$slots,"suggestion-item",{item:o},()=>[e.createElementVNode("span",null,e.toDisplayString(o.text),1),o.checked?(e.openBlock(),e.createBlock(e.unref(A.VftIcon),{key:0,icon:"icon-check"})):e.createCommentVNode("",!0)])],10,je))),128)):e.renderSlot(t.$slots,"empty",{key:1},()=>[e.createElementVNode("li",{class:e.normalizeClass(e.unref(n).e("empty-text"))},"无匹配数据",2)])]),_:3},8,["class","view-class"])),[[e.vShow,v.value]]):e.createCommentVNode("",!0),t.$slots.footer?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(e.unref(n).e("footer")),onClick:l[14]||(l[14]=e.withModifiers(()=>{},["stop"]))},[e.renderSlot(t.$slots,"footer")],2)):e.createCommentVNode("",!0)]),_:3},8,["visible","teleported","popper-class","fallback-placements","placement","transition","effect","persistent"]))}});exports.default=Qe;
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),se=require("lodash-es"),ne=require("@vueuse/core"),ae=require("../../utils/dom/aria.cjs"),re=require("@vft/utils"),Fe=require("../../utils/error.cjs");require("../config-provider/hooks/use-global-config.cjs");const p=require("../../constants/aria.cjs"),ie=require("../../constants/event.cjs");require("../form/index.cjs");const Me=require("../cascader-panel/index.cjs"),Ae=require("../input/index.cjs"),ue=require("../tooltip/index.cjs"),ce=require("../scrollbar/index.cjs"),pe=require("../tag/index.cjs"),K=require("../icon/index.cjs"),Ke=require("@vft/directives"),de=require("../../hooks/use-namespace/index.cjs");require("../../hooks/use-model-toggle/index.cjs");require("@popperjs/core");require("../../hooks/use-z-index/index.cjs");const He=require("../../hooks/use-composition/index.cjs"),Le=require("../../hooks/use-empty-values/index.cjs"),fe=require("./cascader.cjs"),Re=require("../form/hooks/use-form-item.cjs"),We=require("../form/hooks/use-form-common-props.cjs"),Ue={key:0},je=["placeholder"],Ge=["onClick"],Je="VftCascader",Qe=e.defineComponent({name:Je}),Xe=e.defineComponent({...Qe,props:fe.cascaderProps,emits:fe.cascaderEmits,setup(ve,{expose:me,emit:ge}){const n=ve,f=ge,he={modifiers:[{name:"arrowPosition",enabled:!0,phase:"main",fn:({state:t})=>{const{modifiersData:l,placement:o}=t;["right","left","bottom","top"].includes(o)||l.arrow&&(l.arrow.x=35)},requires:["arrow"]}]},H=e.useAttrs();let E=0,D=0;const a=de.useNamespace("cascader"),q=de.useNamespace("input"),{form:ke,formItem:L}=Re.useFormItem(),{valueOnClear:Ce}=Le.useEmptyValues(n),{isComposing:R,handleComposition:d}=He.useComposition({afterComposition(t){const l=t.target?.value;A(l)}}),b=e.ref(null),C=e.ref(null),W=e.ref(null),u=e.ref(null),V=e.ref(null),c=e.ref(!1),U=e.ref(!1),v=e.ref(!1),z=e.ref(!1),w=e.ref(""),h=e.ref(""),k=e.ref([]),T=e.ref([]),P=e.ref([]),Ee=e.computed(()=>H.style),m=e.computed(()=>n.disabled||ke?.disabled),j=e.computed(()=>n.placeholder??"请选择"),ye=e.computed(()=>h.value||k.value.length>0||R.value?"":j.value),N=We.useFormSize(),G=e.computed(()=>N.value==="small"?"small":"default"),g=e.computed(()=>!!n.props.multiple),J=e.computed(()=>!n.filterable||g.value),Q=e.computed(()=>g.value?h.value:w.value),X=[],B=e.computed(()=>{const t=u.value;if(!t)return X;const l=t.checkedNodes,o=e.unref(l);return Array.isArray(o)&&o.length?o:X}),be=e.computed(()=>!n.clearable||m.value||v.value?!1:!!B.value.length),S=e.computed(()=>{const{showAllLevels:t,separator:l}=n,o=B.value;return o.length?g.value?"":o[0].calcText(t,l):""}),Ve=e.computed(()=>L?.validateState||""),Y=e.computed({get(){return se.cloneDeep(n.modelValue)},set(t){const l=t??Ce.value;f(ie.UPDATE_MODEL_EVENT,l),f(ie.CHANGE_EVENT,l),n.validateEvent&&L?.validate("change").catch(o=>Fe.debugWarn(o))}}),we=e.computed(()=>[a.b(),a.m(N.value),a.is("disabled",m.value),H.class]),Te=e.computed(()=>[q.e("icon"),a.is("reverse",c.value)]),Ne=e.computed(()=>a.is("focus",c.value||z.value)),Z=e.computed(()=>b.value?.popperRef?.contentRef),i=t=>{m.value||(t=t??!c.value,t!==c.value&&(c.value=t,C.value?.input?.setAttribute("aria-expanded",`${t}`),t?(y(),e.nextTick(u.value?.scrollToExpandingNode)):n.filterable&&M(),f("visibleChange",t)))},y=()=>{e.nextTick(()=>{b.value?.updatePopper()})},I=()=>{v.value=!1},O=t=>{const{showAllLevels:l,separator:o}=n;return{node:t,key:t.uid,text:t.calcText(l,o),hitState:!1,closable:!m.value&&!t.isDisabled,isCollapseTag:!1}},$=t=>{const l=t.node;l.doCheck(!1),u.value?.calculateCheckedValue(),f("removeTag",l.valueByOption)},Be=()=>{switch(n.showCheckedStrategy){case"child":return B.value;case"parent":{const t=ee(!1),l=t.map(s=>s.value);return t.filter(s=>!s.parent||!l.includes(s.parent.value))}default:return[]}},Se=()=>{if(!g.value)return;const t=Be(),l=[],o=[];if(t.forEach(s=>o.push(O(s))),T.value=o,t.length){t.slice(0,n.maxCollapseTags).forEach(x=>l.push(O(x)));const s=t.slice(n.maxCollapseTags),r=s.length;r&&(n.collapseTags?l.push({key:-1,text:`+ ${r}`,closable:!1,isCollapseTag:!0}):s.forEach(x=>l.push(O(x))))}k.value=l},_=()=>{const{filterMethod:t,showAllLevels:l,separator:o}=n,s=u.value?.getFlattedNodes(!n.props.checkStrictly)?.filter(r=>r.isDisabled?!1:(r.calcText(l,o),t(r,Q.value)));g.value&&(k.value.forEach(r=>{r.hitState=!1}),T.value.forEach(r=>{r.hitState=!1})),v.value=!0,P.value=s,y()},$e=()=>{let t;v.value&&V.value?t=V.value.$el.querySelector(`.${a.e("suggestion-item")}`):t=u.value?.$el.querySelector(`.${a.b("node")}[tabindex="-1"]`),t&&(t.focus(),!v.value&&t.click())},F=()=>{const t=C.value?.input,l=W.value,o=V.value?.$el;if(!(!re.isClient||!t)){if(o){const s=o.querySelector(`.${a.e("suggestion-list")}`);s.style.minWidth=`${t.offsetWidth}px`}if(l){const{offsetHeight:s}=l,r=k.value.length>0?`${Math.max(s,E)-2}px`:`${E}px`;t.style.height=r,y()}}},ee=t=>u.value?.getCheckedNodes(t),xe=t=>{y(),f("expandChange",t)},De=t=>{if(!R.value)switch(t.code){case p.EVENT_CODE.enter:case p.EVENT_CODE.numpadEnter:i();break;case p.EVENT_CODE.down:i(!0),e.nextTick($e),t.preventDefault();break;case p.EVENT_CODE.esc:c.value===!0&&(t.preventDefault(),t.stopPropagation(),i(!1));break;case p.EVENT_CODE.tab:i(!1);break}},qe=()=>{u.value?.clearCheckedNodes(),!c.value&&n.filterable&&M(),i(!1),f("clear")},M=()=>{const{value:t}=S;w.value=t,h.value=t},ze=t=>{const{checked:l}=t;g.value?u.value?.handleCheckChange(t,!l,!1):(!l&&u.value?.handleCheckChange(t,!0,!1),i(!1))},Pe=t=>{const l=t.target,{code:o}=t;switch(o){case p.EVENT_CODE.up:case p.EVENT_CODE.down:{t.preventDefault();const s=o===p.EVENT_CODE.up?-1:1;ae.focusNode(ae.getSibling(l,s,`.${a.e("suggestion-item")}[tabindex="-1"]`));break}case p.EVENT_CODE.enter:case p.EVENT_CODE.numpadEnter:l.click();break}},Ie=()=>{const t=k.value,l=t[t.length-1];D=h.value?0:D+1,!(!l||!D||n.collapseTags&&t.length>1)&&(l.hitState?$(l):l.hitState=!0)},te=t=>{z.value=!0,f("focus",t)},le=t=>{e.nextTick(()=>{const l=C.value?.$el,o=document.activeElement;l?.contains(o)||b.value?.isFocusInsideContent?.(t)||(z.value=!1)}),f("blur",t)},Oe=se.debounce(()=>{const{value:t}=Q;if(!t)return;const l=n.beforeFilter(t);re.isPromise(l)?l.then(_).catch(()=>{}):l!==!1?_():I()},n.debounce),A=(t,l)=>{!c.value&&i(!0),!l?.isComposing&&(t?Oe():I())},oe=t=>Number.parseFloat(ne.useCssVar(q.cssVarName("input-height"),t).value)-2;return e.watch(v,y),e.watch([B,m,()=>n.collapseTags],Se),e.watch(k,()=>{e.nextTick(()=>F())}),e.watch(N,async()=>{await e.nextTick();const t=C.value.input;E=oe(t)||E,F()}),e.watch(S,M,{immediate:!0}),e.onMounted(()=>{const t=C.value.input,l=oe(t);E=t.offsetHeight||l,ne.useResizeObserver(t,F)}),me({getCheckedNodes:ee,cascaderPanelRef:u,togglePopperVisible:i,contentRef:Z,presentText:S}),(t,l)=>(e.openBlock(),e.createBlock(e.unref(ue.VftTooltip),{ref_key:"tooltipRef",ref:b,visible:c.value,teleported:t.teleported,"popper-class":[e.unref(a).e("dropdown"),t.popperClass],"popper-options":he,"fallback-placements":t.fallbackPlacements,"stop-popper-mouse-event":!1,"gpu-acceleration":!1,placement:t.placement,transition:`${e.unref(a).namespace.value}-zoom-in-top`,effect:t.effect,pure:"",persistent:t.persistent,onHide:I},{default:e.withCtx(()=>[e.withDirectives((e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(we.value),style:e.normalizeStyle(Ee.value),onClick:l[8]||(l[8]=()=>i(J.value?void 0:!0)),onKeydown:De,onMouseenter:l[9]||(l[9]=o=>U.value=!0),onMouseleave:l[10]||(l[10]=o=>U.value=!1)},[e.createVNode(e.unref(Ae.VftInput),{ref_key:"input",ref:C,modelValue:w.value,"onUpdate:modelValue":l[1]||(l[1]=o=>w.value=o),placeholder:ye.value,readonly:J.value,disabled:m.value,"validate-event":!1,size:e.unref(N),class:e.normalizeClass(Ne.value),tabindex:g.value&&t.filterable&&!m.value?-1:void 0,onCompositionstart:e.unref(d),onCompositionupdate:e.unref(d),onCompositionend:e.unref(d),onFocus:te,onBlur:le,onInput:A},e.createSlots({suffix:e.withCtx(()=>[be.value?(e.openBlock(),e.createBlock(e.unref(K.VftIcon),{key:"clear",icon:"icon-circle-close",class:e.normalizeClass(["icon-circle-close",[e.unref(q).e("icon")]]),onClick:e.withModifiers(qe,["stop"])},null,8,["class"])):(e.openBlock(),e.createBlock(e.unref(K.VftIcon),{icon:"icon-arrow-down",key:"arrow-down",class:e.normalizeClass(Te.value),onClick:l[0]||(l[0]=e.withModifiers(o=>i(),["stop"]))},null,8,["class"]))]),_:2},[t.$slots.prefix?{name:"prefix",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"prefix")]),key:"0"}:void 0]),1032,["modelValue","placeholder","readonly","disabled","size","class","tabindex","onCompositionstart","onCompositionupdate","onCompositionend"]),g.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"tagWrapper",ref:W,class:e.normalizeClass([e.unref(a).e("tags"),e.unref(a).is("validate",!!Ve.value)])},[e.renderSlot(t.$slots,"tag",{data:T.value,deleteTag:$},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,o=>(e.openBlock(),e.createBlock(e.unref(pe.VftTag),{key:o.key,type:t.tagType,size:G.value,effect:t.tagEffect,hit:o.hitState,closable:o.closable,"disable-transitions":"",onClose:s=>$(o)},{default:e.withCtx(()=>[o.isCollapseTag===!1?(e.openBlock(),e.createElementBlock("span",Ue,e.toDisplayString(o.text),1)):(e.openBlock(),e.createBlock(e.unref(ue.VftTooltip),{key:1,disabled:c.value||!t.collapseTagsTooltip,"fallback-placements":["bottom","top","right","left"],placement:"bottom",effect:t.effect},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(o.text),1)]),content:e.withCtx(()=>[e.createVNode(e.unref(ce.VftScrollbar),{"max-height":t.maxCollapseTagsTooltipHeight},{default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(e.unref(a).e("collapse-tags"))},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.value.slice(t.maxCollapseTags),(s,r)=>(e.openBlock(),e.createElementBlock("div",{key:r,class:e.normalizeClass(e.unref(a).e("collapse-tag"))},[(e.openBlock(),e.createBlock(e.unref(pe.VftTag),{key:s.key,class:"in-tooltip",type:t.tagType,size:G.value,effect:t.tagEffect,hit:s.hitState,closable:s.closable,"disable-transitions":"",onClose:x=>$(s)},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(s.text),1)]),_:2},1032,["type","size","effect","hit","closable","onClose"]))],2))),128))],2)]),_:1},8,["max-height"])]),_:2},1032,["disabled","effect"]))]),_:2},1032,["type","size","effect","hit","closable","onClose"]))),128))]),t.filterable&&!m.value?e.withDirectives((e.openBlock(),e.createElementBlock("input",{key:0,"onUpdate:modelValue":l[2]||(l[2]=o=>h.value=o),type:"text",class:e.normalizeClass(e.unref(a).e("search-input")),placeholder:S.value?"":j.value,onInput:l[3]||(l[3]=o=>A(h.value,o)),onClick:l[4]||(l[4]=e.withModifiers(o=>i(!0),["stop"])),onKeydown:e.withKeys(Ie,["delete"]),onCompositionstart:l[5]||(l[5]=(...o)=>e.unref(d)&&e.unref(d)(...o)),onCompositionupdate:l[6]||(l[6]=(...o)=>e.unref(d)&&e.unref(d)(...o)),onCompositionend:l[7]||(l[7]=(...o)=>e.unref(d)&&e.unref(d)(...o)),onFocus:te,onBlur:le},null,42,je)),[[e.vModelText,h.value]]):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)],38)),[[e.unref(Ke.ClickOutside),()=>i(!1),Z.value]])]),content:e.withCtx(()=>[t.$slots.header?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(e.unref(a).e("header")),onClick:l[11]||(l[11]=e.withModifiers(()=>{},["stop"]))},[e.renderSlot(t.$slots,"header")],2)):e.createCommentVNode("",!0),e.withDirectives(e.createVNode(e.unref(Me.VftCascaderPanel),{ref_key:"cascaderPanelRef",ref:u,modelValue:Y.value,"onUpdate:modelValue":l[12]||(l[12]=o=>Y.value=o),options:t.options,props:n.props,border:!1,"render-label":t.$slots.default,onExpandChange:xe,onClose:l[13]||(l[13]=o=>t.$nextTick(()=>i(!1)))},{empty:e.withCtx(()=>[e.renderSlot(t.$slots,"empty")]),_:3},8,["modelValue","options","props","render-label"]),[[e.vShow,!v.value]]),t.filterable?e.withDirectives((e.openBlock(),e.createBlock(e.unref(ce.VftScrollbar),{key:1,ref_key:"suggestionPanel",ref:V,tag:"ul",class:e.normalizeClass(e.unref(a).e("suggestion-panel")),"view-class":e.unref(a).e("suggestion-list"),onKeydown:Pe},{default:e.withCtx(()=>[P.value.length?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(P.value,o=>(e.openBlock(),e.createElementBlock("li",{key:o.uid,class:e.normalizeClass([e.unref(a).e("suggestion-item"),e.unref(a).is("checked",o.checked)]),tabindex:-1,onClick:s=>ze(o)},[e.renderSlot(t.$slots,"suggestion-item",{item:o},()=>[e.createElementVNode("span",null,e.toDisplayString(o.text),1),o.checked?(e.openBlock(),e.createBlock(e.unref(K.VftIcon),{key:0,icon:"icon-check"})):e.createCommentVNode("",!0)])],10,Ge))),128)):e.renderSlot(t.$slots,"empty",{key:1},()=>[e.createElementVNode("li",{class:e.normalizeClass(e.unref(a).e("empty-text"))},"无匹配数据",2)])]),_:3},8,["class","view-class"])),[[e.vShow,v.value]]):e.createCommentVNode("",!0),t.$slots.footer?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(e.unref(a).e("footer")),onClick:l[14]||(l[14]=e.withModifiers(()=>{},["stop"]))},[e.renderSlot(t.$slots,"footer")],2)):e.createCommentVNode("",!0)]),_:3},8,["visible","teleported","popper-class","fallback-placements","placement","transition","effect","persistent"]))}});exports.default=Xe;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),R=require("../tabs/index.cjs"),y=require("../icon/index.cjs"),K=require("@vueuse/core");require("@vft/utils");const r=require("../../utils/helper.cjs"),q=require("../../utils/ns-cover.cjs");require("lodash-es");require("../form/index.cjs");const z=require("../../hooks/use-namespace/index.cjs");require("../../hooks/use-model-toggle/index.cjs");require("@popperjs/core");require("../../hooks/use-z-index/index.cjs");const d=require("@vft/router"),h=require("@vft/store"),A=require("@vft/use"),D=require("hotkeys-js"),H=require("vue-router"),W=require("./tab-content.vue2.cjs"),S=require("./use/use-multiple-tabs.cjs");require("../context-menu/context-menu.vue2.cjs");const j=e.defineComponent({name:"vft-multiple-tabs"}),O=e.defineComponent({...j,props:{tabsStyle:{},contextMenuStyle:{},canDrag:{type:Boolean},showNavRight:{type:Boolean,default:!0},fixTabCount:{default:0},fixExtraScrollWidth:{}},setup(s){const g=z.useNamespace("multiple-tabs"),l=e.getCurrentInstance().appContext.config.globalProperties.$router,P=S.initAffixTabs(l),o=h.useMultipleTabStore(),f=e.computed(()=>o.getTabList.filter(t=>!t.meta?.hideTab&&h.isTabPinned(t)).length),k=e.computed(()=>Math.max(s.fixTabCount,f.value)),u=e.ref(""),i=e.ref(0),b=e.ref(),{go:x}=d.useRouterHelper(l),v=e.computed(()=>o.getTabList.filter(t=>!t.meta?.hideTab));e.watchEffect(()=>{if(u.value){const t=v.value.findIndex(a=>d.getRouterKeyPath(a)===u.value);t===-1?i.value=v.value?.length-1:i.value=t,i.value=i.value<f.value?f.value-1:i.value}}),K.isClient&&H.onBeforeRouteLeave(()=>{b.value=e.unref(l.currentRoute)}),d.listenerRouteChange(({route:t})=>{if(!t||t.meta?.hasTokenToRoot)return;const{meta:a={}}=t,{currentActivePath:n,hideTab:c}=a,E=c?n:null,T=d.getRouterKeyPath(t);if(u.value!==T&&(u.value=T),E){const C=l.getRoutes().find(F=>F.path===n);C&&o.addTab(C,e.unref(b),i.value,t)}else c||o.addTab(e.unref(t),e.unref(b),i.value)});function V(t){if(u.value===t.paneName)return;const a=v.value[t.attrs.index];u.value=t.paneName;const n=a?.meta?.hideActiveRoute?.fullPath;x(n||a.fullPath||a.path)}function _(t){o.closeTabByKey(t,l)}const{refs:U,setRefs:w}=A.useRefs();function M(t){const a=t.pane.attrs.index,n=t.event;U.value[a].handleContext(n)}const B=e.computed(()=>{const t={padding:"4px 0 0","border-bottom":"none","header-height":r.addUnit(26),"font-size":r.addUnit(13),"item-padding":`0 ${r.addUnit(10)}`,"close-icon-left":r.addUnit(8),"item-distance":"1px","item-max-width":r.addUnit(180),"scroll-padding":`0 ${r.addUnit(20)}`,"header-margin":`0 0 0 ${r.addUnit(10)}`,"item-border-radius":`${r.addUnit(5)} ${r.addUnit(5)} 0 0`,"item-border":"none"};return{...q.generateCssVars(t,"tabs"),...s.tabsStyle}}),{closeCurrent:N}=h.useTabs(),$={...q.generateCssVars({"sub-item-height":r.addUnit(40),"item-min-width":r.addUnit(150)},"menu"),...s.contextMenuStyle},I=()=>{o.toggleFullScreen(o.getTabList[i.value],l)},m=e.ref(!1);let p;const L=()=>{clearInterval(p),m.value=!0,o.refreshPage(0,l,o.getTabList[i.value]),p=setTimeout(()=>{m.value=!1},500)};return e.onMounted(()=>{s.canDrag&&S.useTabsDrag(P),D("command+e, ctrl+e",()=>(N(),!1))}),(t,a)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(e.unref(g).b()),style:e.normalizeStyle(B.value)},[e.createVNode(e.unref(R.VftTabs),{"show-bar":!1,"fix-tab-count":k.value,"fix-extra-scroll-width":s.fixExtraScrollWidth,modelValue:u.value,"onUpdate:modelValue":a[0]||(a[0]=n=>u.value=n),onTabClick:V,onTabRemove:_,onTabContextMenu:M},e.createSlots({default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(v.value,(n,c)=>(e.openBlock(),e.createBlock(e.unref(R.VftTabPane),{key:e.unref(d.getRouterKeyPath)(n)+c,closable:!e.unref(h.isTabPinned)(n),index:c,name:e.unref(d.getRouterKeyPath)(n)},{label:e.withCtx(()=>[e.createVNode(W.default,{"context-menu-style":$,"affix-num":f.value,ref_for:!0,ref:e.unref(w)(c),"tab-item":n},null,8,["affix-num","tab-item"])]),_:2},1032,["closable","index","name"]))),128))]),_:2},[s.showNavRight?{name:"navRight",fn:e.withCtx(()=>[e.renderSlot(t.$slots,"nav-right",{},()=>[e.createElementVNode("div",{class:e.normalizeClass(e.unref(g).e("nav-right"))},[e.createVNode(e.unref(y.VftIcon),{rotate:m.value,"rotate-speed":1,onClick:L,icon:"icon-refresh-right",pointer:""},null,8,["rotate"]),e.createVNode(e.unref(y.VftIcon),{onClick:I,icon:e.unref(o).isFullScreen?"icon-collapse":"icon-expand",pointer:""},null,8,["icon"])],2)])]),key:"0"}:void 0]),1032,["fix-tab-count","fix-extra-scroll-width","modelValue"])],6))}});exports.default=O;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("@vft/router"),l=require("@vft/store");require("@vft/utils");const g=require("vue");require("../../context-menu/context-menu.vue2.cjs");require("../../icon/index.cjs");require("vue-router");function R(e,t){const s=g.reactive({current:null,currentIndex:0}),n=l.useMultipleTabStore(),{refreshPage:h,closeAll:p,close:b,closeLeft:f,closeOther:x,closeRight:T,newWinTab:C,fullScreen:L,alonePage:v,pinTab:q,unpinTab:D}=l.useTabs(),P=g.computed(()=>{if(!e)return;const{meta:r}=e,o=s.currentIndex,i=l.isTabPinned(e),c=!i,d=!!r?.userPinned,M=o===0||o<=t,S=n.getTabList.length<=t||o===n.getTabList.length-1&&n.getLastDragEndIndex>=0,y=n.getTabList.length===t||n.getTabList.length===t+1&&o===t,u=n.getTabList.length===t;return[{iconCfg:{icon:"icon-refresh-right"},text:"刷新",handler:()=>h(e)},{iconCfg:{icon:"icon-new-tab"},text:"新页面打开",handler:()=>C(e),divider:!0},{iconCfg:{icon:"icon-close-tab"},text:"关闭标签页",disabled:i||u,handler:()=>b(e)},{iconCfg:{icon:"icon-arrow-close-left"},text:"关闭左侧标签页",disabled:M,handler:()=>f(e)},{iconCfg:{icon:"icon-arrow-close-right"},text:"关闭右侧标签页",disabled:S,divider:!0,handler:()=>T(e)},{iconCfg:{icon:"icon-close-box-multiple-outline"},text:"关闭其它标签页",disabled:y,handler:()=>x(e)},{iconCfg:{icon:"icon-vector-square-delete"},text:"关闭所有标签页",disabled:u,divider:!0,handler:()=>p()},{iconCfg:{icon:"icon-full-screen"},text:"全屏",handler:()=>L(e)},{iconCfg:{icon:"icon-separate"},text:"独立页面",handler:()=>v(e),divider:c||d},...c?[{iconCfg:{icon:"icon-tab-pin"},text:"固定",handler:()=>q(e)}]:d?[{iconCfg:{icon:"icon-tab-unpin"},text:"取消固定",handler:()=>D(e)}]:[]]});function w(r){return o=>{if(!r)return;o?.preventDefault();const i=n.getTabList.findIndex(c=>a.getRouterKeyPath(c)===a.getRouterKeyPath(r));s.current=r,s.currentIndex=i}}return{getDropMenuList:P,handleContextMenu:w}}exports.useTabDropdown=R;
|
package/lib/package.json.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e="0.0.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e="0.0.504";exports.version=e;
|
package/lib/package.json.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vft",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.504",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "lib/index.cjs",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -56,12 +56,12 @@
|
|
|
56
56
|
"resize-detector": "0.3.0",
|
|
57
57
|
"sortablejs": "1.15.0",
|
|
58
58
|
"photoswipe": "5.4.4",
|
|
59
|
-
"@vft/constants": "0.0.83",
|
|
60
59
|
"@vft/router": "0.0.73",
|
|
61
|
-
"@vft/store": "0.0.75",
|
|
62
60
|
"@vft/use": "0.0.96",
|
|
63
|
-
"@vft/
|
|
64
|
-
"@vft/
|
|
61
|
+
"@vft/constants": "0.0.83",
|
|
62
|
+
"@vft/store": "0.0.78",
|
|
63
|
+
"@vft/utils": "0.0.161",
|
|
64
|
+
"@vft/directives": "0.0.36"
|
|
65
65
|
},
|
|
66
66
|
"vetur": {
|
|
67
67
|
"tags": "tags.json",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
html.dark{color-scheme:dark;--vft-primary-color-light-3:rgb(29.1, 111, 176.1);--vft-primary-color-light-5:rgb(26.5, 85, 131.5);--vft-primary-color-light-7:rgb(23.9, 59, 86.9);--vft-primary-color-light-8:rgb(22.6, 46, 64.6);--vft-primary-color-light-9:rgb(21.3, 33, 42.3);--vft-primary-color:#2196f3;--vft-primary-color-dark-2:rgb(77.4, 171, 245.4);--vft-success-color-light-3:rgb(49.4, 128.5, 92.8);--vft-success-color-light-5:rgb(41, 97.5, 72);--vft-success-color-light-7:rgb(32.6, 66.5, 51.2);--vft-success-color-light-8:rgb(28.4, 51, 40.8);--vft-success-color-light-9:rgb(24.2, 35.5, 30.4);--vft-success-color:#3eaf7c;--vft-success-color-dark-2:rgb(100.6, 191, 150.2);--vft-warning-color-light-3:rgb(181.7, 114.5, 72.5);--vft-warning-color-light-5:rgb(135.5, 87.5, 57.5);--vft-warning-color-light-7:rgb(89.3, 60.5, 42.5);--vft-warning-color-light-8:rgb(66.2, 47, 35);--vft-warning-color-light-9:rgb(43.1, 33.5, 27.5);--vft-warning-color:#fb9b5f;--vft-warning-color-dark-2:rgb(251.8, 175, 127);--vft-danger-color-light-3:rgb(175.4, 82.3, 82.3);--vft-danger-color-light-5:rgb(131, 64.5, 64.5);--vft-danger-color-light-7:rgb(86.6, 46.7, 46.7);--vft-danger-color-light-8:rgb(64.4, 37.8, 37.8);--vft-danger-color-light-9:rgb(42.2, 28.9, 28.9);--vft-danger-color:#f26d6d;--vft-danger-color-dark-2:rgb(244.6, 138.2, 138.2);--vft-error-color-light-3:rgb(175.4, 82.3, 82.3);--vft-error-color-light-5:rgb(131, 64.5, 64.5);--vft-error-color-light-7:rgb(86.6, 46.7, 46.7);--vft-error-color-light-8:rgb(64.4, 37.8, 37.8);--vft-error-color-light-9:rgb(42.2, 28.9, 28.9);--vft-error-color:#f26d6d;--vft-error-color-dark-2:rgb(244.6, 138.2, 138.2);--vft-info-color-light-3:rgb(106.8, 108.9, 113.1);--vft-info-color-light-5:rgb(82, 83.5, 86.5);--vft-info-color-light-7:rgb(57.2, 58.1, 59.9);--vft-info-color-light-8:rgb(44.8, 45.4, 46.6);--vft-info-color-light-9:rgb(32.4, 32.7, 33.3);--vft-info-color:#909399;--vft-info-color-dark-2:rgb(166.2, 168.6, 173.4);--vft-box-shadow:0 12px 32px 4px rgba(0, 0, 0, 0.36),0 8px 20px rgba(0, 0, 0, 0.72);--vft-box-shadow-light:0 0 12px rgba(0, 0, 0, 0.72);--vft-box-shadow-lighter:0 0 6px rgba(0, 0, 0, 0.72);--vft-box-shadow-dark:0 16px 48px 16px rgba(0, 0, 0, 0.72),0 12px 32px #000,0 8px 16px -8px #000;--vft-bg-color-page:#0a0a0a;--vft-bg-color:#141414;--vft-bg-color-overlay:#1d1e1f;--vft-text-primary-color:#F6F6F6;--vft-text-regular-color:#DCDCDC;--vft-text-secondary-color:#ADADAD;--vft-text-placeholder-color:#959595;--vft-text-disabled-color:#727272;--vft-border-color-darker:#636466;--vft-border-color-dark:#58585B;--vft-border-color:#4C4D4F;--vft-border-color-light:#414243;--vft-border-color-lighter:#363637;--vft-border-color-extra-light:#2B2B2C;--vft-fill-color-darker:#424243;--vft-fill-color-dark:#39393A;--vft-fill-color:#303030;--vft-fill-color-light:#262727;--vft-fill-color-lighter:#1D1D1D;--vft-fill-color-extra-light:#191919;--vft-fill-color-blank:transparent;--vft-mask-color:rgba(0, 0, 0, 0.5);--vft-mask-color-extra-light:rgba(255, 255, 255, 0.3);--vft-reverse-color:#fff;--vft-color-rgb:0,0,0;--vft-reverse-color-rgb:255,255,255;--vxe-ui-font-color:#a0a3a7;--vxe-ui-font-tinge-color:#33353b;--vxe-ui-font-lighten-color:#797b80;--vxe-ui-font-darken-color:#47494c;--vxe-ui-font-disabled-color:#464646;--vxe-ui-font-primary-color:var(--vft-primary-color);--vxe-ui-base-popup-border-color:#424242;--vxe-ui-base-popup-box-shadow:0 12px 30px 8px rgba(0, 0, 0, 0.5);--vxe-ui-layout-background-color:#121212;--vxe-ui-input-border-color:#424242;--vxe-ui-input-placeholder-color:#8d9095;--vxe-ui-input-disabled-background-color:#262727;--vxe-ui-loading-background-color:hsla(0deg, 0%, 100%, 0.1);--vxe-ui-table-header-background-color:#28282a;--vxe-ui-table-column-to-row-background-color:#28282a;--vxe-ui-table-column-hover-background-color:#242f3b;--vxe-ui-table-column-current-background-color:#18222c;--vxe-ui-table-column-hover-current-background-color:#242f3b;--vxe-ui-table-border-color:#37373a;--vxe-ui-table-row-hover-background-color:#262727;--vxe-ui-table-row-striped-background-color:#1d1d1d;--vxe-ui-table-row-hover-striped-background-color:#262727;--vxe-ui-table-row-radio-checked-background-color:#604820;--vxe-ui-table-row-hover-radio-checked-background-color:#6e5326;--vxe-ui-table-row-checkbox-checked-background-color:#604820;--vxe-ui-table-row-hover-checkbox-checked-background-color:#6e5326;--vxe-ui-table-row-current-background-color:#18222c;--vxe-ui-table-row-hover-current-background-color:#242f3b;--vxe-ui-table-fixed-scrolling-box-shadow-color:rgba(0, 0, 0, 0.8);--vxe-ui-table-drag-over-background-color:rgba(48, 48, 0, 0.3)}html.dark .vft-button{--vft-button-disabled-text-color:rgba(255, 255, 255, 0.5)}html.dark .vft-card{--vft-card-bg-color:var(--vft-bg-color-overlay)}html.dark .vft-empty{--vft-empty-fill-color-0:var(--vft-color-black);--vft-empty-fill-color-1:#4b4b52;--vft-empty-fill-color-2:#36383d;--vft-empty-fill-color-3:#1e1e20;--vft-empty-fill-color-4:#262629;--vft-empty-fill-color-5:#202124;--vft-empty-fill-color-6:#212224;--vft-empty-fill-color-7:#1b1c1f;--vft-empty-fill-color-8:#1c1d1f;--vft-empty-fill-color-9:#18181a}html.dark .vft-header-layout{--vft-header-layout-bg-color:#21263e}html.dark .vft-multiple-tabs{--vft-multiple-tabs-bg-color:#21263e}html.dark .vft-tabs{--vft-tabs-item-color:var(--vft-text-primary-color);--vft-tabs-item-color-active:#262626;--vft-tabs-item-color-hover:#262626}html.dark .vft-menu{--vft-menu-hover-bg-color:var(--vft-primary-color-light-7);--vft-menu-focus-bg-color:var(--vft-primary-color-light-7);--vft-menu-item-hover-fill:var(--vft-primary-color-light-7)}html.dark .vft-footer-layout{--vft-footer-layout-bg-color:#21263e}html.dark .vft-md-container{--vft-md-container-code-color:#f85959;--vft-md-container-code-bg-color:hsla(0, 0%, 100%, 0.08)}html.dark .vft-table{--vft-table-header-bg-color:#1d1d1d;--vft-table-header-color:var(--vft-text-primary-color);--vft-table-stripe-bg-color:#1d1d1d;--vft-table-stripe-active-bg-color:#18222c;--vft-table-row-hover-bg-color:#262727;--vft-table-body-color:#141414;--vft-table-border:1px solid #262727;--vft-table-border-fixed:1px solid #262727}html.dark .vft-context-menu{background-color:#000}html.dark .vft-message{background:#303032;color:#fff}
|
|
1
|
+
@charset "UTF-8";html.dark{color-scheme:dark;--vft-primary-color-light-3:rgb(29.1, 111, 176.1);--vft-primary-color-light-5:rgb(26.5, 85, 131.5);--vft-primary-color-light-7:rgb(23.9, 59, 86.9);--vft-primary-color-light-8:rgb(22.6, 46, 64.6);--vft-primary-color-light-9:rgb(21.3, 33, 42.3);--vft-primary-color:#2196f3;--vft-primary-color-dark-2:rgb(77.4, 171, 245.4);--vft-success-color-light-3:rgb(49.4, 128.5, 92.8);--vft-success-color-light-5:rgb(41, 97.5, 72);--vft-success-color-light-7:rgb(32.6, 66.5, 51.2);--vft-success-color-light-8:rgb(28.4, 51, 40.8);--vft-success-color-light-9:rgb(24.2, 35.5, 30.4);--vft-success-color:#3eaf7c;--vft-success-color-dark-2:rgb(100.6, 191, 150.2);--vft-warning-color-light-3:rgb(181.7, 114.5, 72.5);--vft-warning-color-light-5:rgb(135.5, 87.5, 57.5);--vft-warning-color-light-7:rgb(89.3, 60.5, 42.5);--vft-warning-color-light-8:rgb(66.2, 47, 35);--vft-warning-color-light-9:rgb(43.1, 33.5, 27.5);--vft-warning-color:#fb9b5f;--vft-warning-color-dark-2:rgb(251.8, 175, 127);--vft-danger-color-light-3:rgb(175.4, 82.3, 82.3);--vft-danger-color-light-5:rgb(131, 64.5, 64.5);--vft-danger-color-light-7:rgb(86.6, 46.7, 46.7);--vft-danger-color-light-8:rgb(64.4, 37.8, 37.8);--vft-danger-color-light-9:rgb(42.2, 28.9, 28.9);--vft-danger-color:#f26d6d;--vft-danger-color-dark-2:rgb(244.6, 138.2, 138.2);--vft-error-color-light-3:rgb(175.4, 82.3, 82.3);--vft-error-color-light-5:rgb(131, 64.5, 64.5);--vft-error-color-light-7:rgb(86.6, 46.7, 46.7);--vft-error-color-light-8:rgb(64.4, 37.8, 37.8);--vft-error-color-light-9:rgb(42.2, 28.9, 28.9);--vft-error-color:#f26d6d;--vft-error-color-dark-2:rgb(244.6, 138.2, 138.2);--vft-info-color-light-3:rgb(106.8, 108.9, 113.1);--vft-info-color-light-5:rgb(82, 83.5, 86.5);--vft-info-color-light-7:rgb(57.2, 58.1, 59.9);--vft-info-color-light-8:rgb(44.8, 45.4, 46.6);--vft-info-color-light-9:rgb(32.4, 32.7, 33.3);--vft-info-color:#909399;--vft-info-color-dark-2:rgb(166.2, 168.6, 173.4);--vft-box-shadow:0 12px 32px 4px rgba(0, 0, 0, 0.36),0 8px 20px rgba(0, 0, 0, 0.72);--vft-box-shadow-light:0 0 12px rgba(0, 0, 0, 0.72);--vft-box-shadow-lighter:0 0 6px rgba(0, 0, 0, 0.72);--vft-box-shadow-dark:0 16px 48px 16px rgba(0, 0, 0, 0.72),0 12px 32px #000,0 8px 16px -8px #000;--vft-bg-color-page:#0a0a0a;--vft-bg-color:#141414;--vft-bg-color-overlay:#1d1e1f;--vft-text-primary-color:#F6F6F6;--vft-text-regular-color:#DCDCDC;--vft-text-secondary-color:#ADADAD;--vft-text-placeholder-color:#959595;--vft-text-disabled-color:#727272;--vft-border-color-darker:#636466;--vft-border-color-dark:#58585B;--vft-border-color:#4C4D4F;--vft-border-color-light:#414243;--vft-border-color-lighter:#363637;--vft-border-color-extra-light:#2B2B2C;--vft-fill-color-darker:#424243;--vft-fill-color-dark:#39393A;--vft-fill-color:#303030;--vft-fill-color-light:#262727;--vft-fill-color-lighter:#1D1D1D;--vft-fill-color-extra-light:#191919;--vft-fill-color-blank:transparent;--vft-mask-color:rgba(0, 0, 0, 0.5);--vft-mask-color-extra-light:rgba(255, 255, 255, 0.3);--vft-reverse-color:#fff;--vft-color-rgb:0,0,0;--vft-reverse-color-rgb:255,255,255;--vxe-ui-font-color:#a0a3a7;--vxe-ui-font-tinge-color:#33353b;--vxe-ui-font-lighten-color:#797b80;--vxe-ui-font-darken-color:#47494c;--vxe-ui-font-disabled-color:#464646;--vxe-ui-font-primary-color:var(--vft-primary-color);--vxe-ui-base-popup-border-color:#424242;--vxe-ui-base-popup-box-shadow:0 12px 30px 8px rgba(0, 0, 0, 0.5);--vxe-ui-layout-background-color:#121212;--vxe-ui-input-border-color:#424242;--vxe-ui-input-placeholder-color:#8d9095;--vxe-ui-input-disabled-background-color:#262727;--vxe-ui-loading-background-color:hsla(0deg, 0%, 100%, 0.1);--vxe-ui-table-header-background-color:#28282a;--vxe-ui-table-column-to-row-background-color:#28282a;--vxe-ui-table-column-hover-background-color:#242f3b;--vxe-ui-table-column-current-background-color:#18222c;--vxe-ui-table-column-hover-current-background-color:#242f3b;--vxe-ui-table-border-color:#37373a;--vxe-ui-table-row-hover-background-color:#262727;--vxe-ui-table-row-striped-background-color:#1d1d1d;--vxe-ui-table-row-hover-striped-background-color:#262727;--vxe-ui-table-row-radio-checked-background-color:#604820;--vxe-ui-table-row-hover-radio-checked-background-color:#6e5326;--vxe-ui-table-row-checkbox-checked-background-color:#604820;--vxe-ui-table-row-hover-checkbox-checked-background-color:#6e5326;--vxe-ui-table-row-current-background-color:#18222c;--vxe-ui-table-row-hover-current-background-color:#242f3b;--vxe-ui-table-fixed-scrolling-box-shadow-color:rgba(0, 0, 0, 0.8);--vxe-ui-table-drag-over-background-color:rgba(48, 48, 0, 0.3)}html.dark .vft-button{--vft-button-disabled-text-color:rgba(255, 255, 255, 0.5)}html.dark .vft-card{--vft-card-bg-color:var(--vft-bg-color-overlay)}html.dark .vft-empty{--vft-empty-fill-color-0:var(--vft-color-black);--vft-empty-fill-color-1:#4b4b52;--vft-empty-fill-color-2:#36383d;--vft-empty-fill-color-3:#1e1e20;--vft-empty-fill-color-4:#262629;--vft-empty-fill-color-5:#202124;--vft-empty-fill-color-6:#212224;--vft-empty-fill-color-7:#1b1c1f;--vft-empty-fill-color-8:#1c1d1f;--vft-empty-fill-color-9:#18181a}html.dark .vft-header-layout{--vft-header-layout-bg-color:#21263e}html.dark .vft-multiple-tabs{--vft-multiple-tabs-bg-color:#21263e}html.dark .vft-tabs{--vft-tabs-item-color:var(--vft-text-primary-color);--vft-tabs-item-color-active:#262626;--vft-tabs-item-color-hover:#262626}html.dark .vft-menu{--vft-menu-hover-bg-color:var(--vft-primary-color-light-7);--vft-menu-focus-bg-color:var(--vft-primary-color-light-7);--vft-menu-item-hover-fill:var(--vft-primary-color-light-7)}html.dark .vft-footer-layout{--vft-footer-layout-bg-color:#21263e}html.dark .vft-md-container{--vft-md-container-code-color:#f85959;--vft-md-container-code-bg-color:hsla(0, 0%, 100%, 0.08)}html.dark .vft-table{--vft-table-header-bg-color:#1d1d1d;--vft-table-header-color:var(--vft-text-primary-color);--vft-table-stripe-bg-color:#1d1d1d;--vft-table-stripe-active-bg-color:#18222c;--vft-table-row-hover-bg-color:#262727;--vft-table-body-color:#141414;--vft-table-border:1px solid #262727;--vft-table-border-fixed:1px solid #262727}html.dark .vft-context-menu{background-color:#000}html.dark .vft-message{background:#303032;color:#fff}
|
package/theme-style/display.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@media only screen and (max-width:767px){.hidden-xs-only{display:none!important}}@media only screen and (min-width:768px){.hidden-sm-and-up{display:none!important}}@media only screen and (min-width:768px) and (max-width:991px){.hidden-sm-only{display:none!important}}@media only screen and (max-width:991px){.hidden-sm-and-down{display:none!important}}@media only screen and (min-width:992px){.hidden-md-and-up{display:none!important}}@media only screen and (min-width:992px) and (max-width:1199px){.hidden-md-only{display:none!important}}@media only screen and (max-width:1199px){.hidden-md-and-down{display:none!important}}@media only screen and (min-width:1200px){.hidden-lg-and-up{display:none!important}}@media only screen and (min-width:1200px) and (max-width:1919px){.hidden-lg-only{display:none!important}}@media only screen and (max-width:1919px){.hidden-lg-and-down{display:none!important}}@media only screen and (min-width:1920px){.hidden-xl-only{display:none!important}}
|
|
1
|
+
@charset "UTF-8";@media only screen and (max-width:767px){.hidden-xs-only{display:none!important}}@media only screen and (min-width:768px){.hidden-sm-and-up{display:none!important}}@media only screen and (min-width:768px) and (max-width:991px){.hidden-sm-only{display:none!important}}@media only screen and (max-width:991px){.hidden-sm-and-down{display:none!important}}@media only screen and (min-width:992px){.hidden-md-and-up{display:none!important}}@media only screen and (min-width:992px) and (max-width:1199px){.hidden-md-only{display:none!important}}@media only screen and (max-width:1199px){.hidden-md-and-down{display:none!important}}@media only screen and (min-width:1200px){.hidden-lg-and-up{display:none!important}}@media only screen and (min-width:1200px) and (max-width:1919px){.hidden-lg-only{display:none!important}}@media only screen and (max-width:1919px){.hidden-lg-and-down{display:none!important}}@media only screen and (min-width:1920px){.hidden-xl-only{display:none!important}}
|