@ditari/bsui 1.0.2 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/index.cjs.js +1 -1
- package/dist/cjs/components/index.d.ts +10 -2
- package/dist/cjs/components/layout/Breadcrumb.vue.cjs2.js +1 -1
- package/dist/cjs/components/layout/List.vue.cjs2.js +1 -1
- package/dist/cjs/components/layout/Main.vue.cjs.js +1 -1
- package/dist/cjs/components/layout/Main.vue.cjs2.js +1 -1
- package/dist/cjs/components/layout/NavTabs.vue.cjs.js +1 -1
- package/dist/cjs/components/layout/NavTabs.vue.cjs2.js +1 -1
- package/dist/cjs/components/layout/Show.vue.cjs2.js +1 -1
- package/dist/cjs/components/layout/index.cjs.js +1 -1
- package/dist/cjs/components/menu/Menu.cjs.js +1 -0
- package/dist/cjs/store/modules/User.cjs.js +1 -1
- package/dist/cjs/store/modules/User.d.ts +14 -8
- package/dist/css/index.css +1 -1
- package/dist/css/layout/style/breadcrumb.css +1 -0
- package/dist/css/layout/style/index.css +1 -0
- package/dist/css/layout/style/list.css +1 -0
- package/dist/css/layout/style/main.css +1 -0
- package/dist/css/layout/style/navtab.css +1 -0
- package/dist/css/layout/style/show.css +1 -0
- package/dist/css/menu/style/index.css +1 -1
- package/dist/esm/components/index.d.ts +10 -2
- package/dist/esm/components/index.esm.js +17 -17
- package/dist/esm/components/layout/Breadcrumb.vue.esm2.js +2 -2
- package/dist/esm/components/layout/List.vue.esm2.js +2 -2
- package/dist/esm/components/layout/Main.vue.esm.js +20 -22
- package/dist/esm/components/layout/Main.vue.esm2.js +2 -2
- package/dist/esm/components/layout/NavTabs.vue.esm.js +44 -39
- package/dist/esm/components/layout/NavTabs.vue.esm2.js +2 -2
- package/dist/esm/components/layout/Show.vue.esm2.js +2 -2
- package/dist/esm/components/layout/index.esm.js +5 -9
- package/dist/esm/components/menu/Menu.esm.js +71 -0
- package/dist/esm/store/modules/User.d.ts +14 -8
- package/dist/esm/store/modules/User.esm.js +13 -8
- package/dist/esm/style.css +1 -1
- package/dist/style/index.scss +2 -1
- package/dist/style/layout/style/breadcrumb.scss +57 -0
- package/dist/style/layout/style/index.scss +6 -0
- package/dist/style/layout/style/list.scss +26 -0
- package/dist/style/layout/style/main.scss +100 -0
- package/dist/style/layout/style/navtab.scss +118 -0
- package/dist/style/layout/style/show.scss +37 -0
- package/dist/style/menu/style/index.scss +12 -4
- package/dist/style/theme/variable.scss +23 -6
- package/package.json +7 -3
- package/src/components/index.scss +2 -1
- package/src/components/index.ts +10 -2
- package/src/components/layout/Breadcrumb.vue +0 -76
- package/src/components/layout/List.vue +1 -27
- package/src/components/layout/Main.vue +2 -102
- package/src/components/layout/NavTabs.vue +6 -95
- package/src/components/layout/Show.vue +1 -39
- package/src/components/layout/style/breadcrumb.scss +57 -0
- package/src/components/layout/style/index.scss +6 -0
- package/src/components/layout/style/list.scss +26 -0
- package/src/components/layout/style/main.scss +100 -0
- package/src/components/layout/style/navtab.scss +118 -0
- package/src/components/layout/style/show.scss +37 -0
- package/src/components/{layout/Menu.jsx → menu/Menu-bak.jsx} +36 -34
- package/src/components/menu/Menu.jsx +88 -47
- package/src/components/menu/style/index.scss +12 -4
- package/src/components/theme/variable.scss +23 -6
- package/src/store/modules/User.ts +16 -9
- package/dist/cjs/components/layout/Breadcrumb.vue.cjs3.js +0 -1
- package/dist/cjs/components/layout/List.vue.cjs3.js +0 -1
- package/dist/cjs/components/layout/Main.vue.cjs3.js +0 -1
- package/dist/cjs/components/layout/Menu.cjs.js +0 -1
- package/dist/cjs/components/layout/NavTabs.vue.cjs3.js +0 -1
- package/dist/cjs/components/layout/Show.vue.cjs3.js +0 -1
- package/dist/esm/components/layout/Breadcrumb.vue.esm3.js +0 -5
- package/dist/esm/components/layout/List.vue.esm3.js +0 -5
- package/dist/esm/components/layout/Main.vue.esm3.js +0 -5
- package/dist/esm/components/layout/Menu.esm.js +0 -52
- package/dist/esm/components/layout/NavTabs.vue.esm3.js +0 -5
- package/dist/esm/components/layout/Show.vue.esm3.js +0 -5
- /package/dist/cjs/components/{layout → menu}/Menu.d.ts +0 -0
- /package/dist/esm/components/{layout → menu}/Menu.d.ts +0 -0
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { defineComponent as y, inject as C, ref as d, createVNode as n, resolveComponent as l, isVNode as K, Fragment as s, withDirectives as M, vShow as j, h as k } from "vue";
|
|
2
|
+
import { storeToRefs as N } from "pinia";
|
|
3
|
+
import "@ant-design/icons-vue";
|
|
4
|
+
import { useMenuStore as w } from "../../store/modules/Menu.esm.js";
|
|
5
|
+
import { useSettingsStore as I } from "../../store/modules/Settings.esm.js";
|
|
6
|
+
function D(o) {
|
|
7
|
+
return typeof o == "function" || Object.prototype.toString.call(o) === "[object Object]" && !K(o);
|
|
8
|
+
}
|
|
9
|
+
const _ = /* @__PURE__ */ y({
|
|
10
|
+
name: "DMenu",
|
|
11
|
+
setup() {
|
|
12
|
+
const {
|
|
13
|
+
componentName: o,
|
|
14
|
+
prop: H
|
|
15
|
+
} = C("menuIcon"), {
|
|
16
|
+
list: p
|
|
17
|
+
} = w(), f = I(), {
|
|
18
|
+
getCollapsed: m
|
|
19
|
+
} = N(f), c = d(["/labelList", "/label"]), i = d(["/label"]), v = ({
|
|
20
|
+
item: e,
|
|
21
|
+
key: t,
|
|
22
|
+
keyPath: r
|
|
23
|
+
}) => {
|
|
24
|
+
console.log(e, t, r), c.value = r, i.value = [t];
|
|
25
|
+
}, h = (e) => n(s, null, [n(l("a-menu-item"), {
|
|
26
|
+
key: e.url
|
|
27
|
+
}, {
|
|
28
|
+
icon: () => u(e),
|
|
29
|
+
default: () => e.title
|
|
30
|
+
})]), b = ["anticon", "anticon-menu", "ant-menu-item-icon"], u = (e) => n(s, null, [e.icon ? S(e.icon) : M(n("div", {
|
|
31
|
+
className: b
|
|
32
|
+
}, [e.title.substring(0, 1)]), [[j, m.value]])]), S = (e) => o === "nativeHtml" ? n("span", {
|
|
33
|
+
innerHTML: e
|
|
34
|
+
}, null) : k(l(o), {
|
|
35
|
+
prop: e
|
|
36
|
+
}), a = (e) => n(s, null, [n(l("a-sub-menu"), {
|
|
37
|
+
key: e.url
|
|
38
|
+
}, {
|
|
39
|
+
title: () => e.title,
|
|
40
|
+
icon: () => u(e),
|
|
41
|
+
default: () => e.children.map(
|
|
42
|
+
(t) => !t.children || t.children.length === 0 ? g(t) : a(t)
|
|
43
|
+
// 递归调用
|
|
44
|
+
)
|
|
45
|
+
})]), g = (e) => n(s, null, [n(l("a-menu-item"), {
|
|
46
|
+
key: e.url
|
|
47
|
+
}, {
|
|
48
|
+
default: () => e.title
|
|
49
|
+
})]);
|
|
50
|
+
return () => {
|
|
51
|
+
let e;
|
|
52
|
+
return n(l("a-menu"), {
|
|
53
|
+
mode: "inline",
|
|
54
|
+
theme: "dark",
|
|
55
|
+
openKeys: c.value,
|
|
56
|
+
"onUpdate:openKeys": (t) => c.value = t,
|
|
57
|
+
selectedKeys: i.value,
|
|
58
|
+
"onUpdate:selectedKeys": (t) => i.value = t,
|
|
59
|
+
onClick: v
|
|
60
|
+
}, D(e = p.map((t) => {
|
|
61
|
+
var r;
|
|
62
|
+
return !t.children || ((r = t.children) == null ? void 0 : r.length) === 0 ? h(t) : a(t);
|
|
63
|
+
})) ? e : {
|
|
64
|
+
default: () => [e]
|
|
65
|
+
});
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
});
|
|
69
|
+
export {
|
|
70
|
+
_ as default
|
|
71
|
+
};
|
|
@@ -1,15 +1,21 @@
|
|
|
1
|
-
export
|
|
2
|
-
token: undefined;
|
|
3
|
-
|
|
1
|
+
export interface State {
|
|
2
|
+
token: string | undefined;
|
|
3
|
+
userInfo: any;
|
|
4
|
+
}
|
|
5
|
+
export declare const useUserStore: import("pinia").StoreDefinition<string, State, {
|
|
4
6
|
getToken: (state: {
|
|
5
|
-
token: undefined;
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
token: string | undefined;
|
|
8
|
+
userInfo: any;
|
|
9
|
+
} & import("pinia").PiniaCustomStateProperties<State>) => string | undefined;
|
|
10
|
+
getUserInfo: (state: {
|
|
11
|
+
token: string | undefined;
|
|
12
|
+
userInfo: any;
|
|
13
|
+
} & import("pinia").PiniaCustomStateProperties<State>) => any;
|
|
9
14
|
}, {
|
|
10
15
|
/**
|
|
11
16
|
* 保存token
|
|
12
17
|
* @param token
|
|
13
18
|
*/
|
|
14
|
-
saveToken(token:
|
|
19
|
+
saveToken(token: string): void;
|
|
20
|
+
saveUserInfo(data: any): void;
|
|
15
21
|
}>;
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { defineStore as
|
|
2
|
-
import { USER_ID as
|
|
3
|
-
const
|
|
1
|
+
import { defineStore as o } from "pinia";
|
|
2
|
+
import { USER_ID as t } from "../types.esm.js";
|
|
3
|
+
const n = o(t, {
|
|
4
4
|
state: () => ({
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
token: void 0,
|
|
6
|
+
userInfo: void 0
|
|
7
7
|
}),
|
|
8
8
|
getters: {
|
|
9
|
-
getToken: (e) => e.token
|
|
9
|
+
getToken: (e) => e.token,
|
|
10
|
+
getUserInfo: (e) => e.userInfo
|
|
10
11
|
},
|
|
11
12
|
actions: {
|
|
12
13
|
/**
|
|
@@ -15,9 +16,13 @@ const s = t(o, {
|
|
|
15
16
|
*/
|
|
16
17
|
saveToken(e) {
|
|
17
18
|
this.token = e;
|
|
19
|
+
},
|
|
20
|
+
saveUserInfo(e) {
|
|
21
|
+
this.userInfo = e;
|
|
18
22
|
}
|
|
19
|
-
}
|
|
23
|
+
},
|
|
24
|
+
persist: !0
|
|
20
25
|
});
|
|
21
26
|
export {
|
|
22
|
-
|
|
27
|
+
n as useUserStore
|
|
23
28
|
};
|
package/dist/esm/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
.xi-pagination{margin-top:24px;text-align:center}
|
package/dist/style/index.scss
CHANGED
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
@import "../../theme/variable.scss";
|
|
2
|
+
.ditari-breadcrumb {
|
|
3
|
+
|
|
4
|
+
.ant-breadcrumb-separator {
|
|
5
|
+
display: none;
|
|
6
|
+
}
|
|
7
|
+
.breadcrumb {
|
|
8
|
+
display: flex;
|
|
9
|
+
|
|
10
|
+
.breadcrumb-item {
|
|
11
|
+
&:first-child {
|
|
12
|
+
.breadcrumb-link {
|
|
13
|
+
border-radius: 6px 0 0 6px;
|
|
14
|
+
clip-path: polygon(
|
|
15
|
+
0 0,
|
|
16
|
+
calc(100% - 8px) 0,
|
|
17
|
+
100% 50%,
|
|
18
|
+
calc(100% - 8px) 100%,
|
|
19
|
+
0 100%
|
|
20
|
+
);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
&:last-child {
|
|
24
|
+
&:not(:last-child) {
|
|
25
|
+
.breadcrumb-link {
|
|
26
|
+
border-radius: 0 6px 6px 0;
|
|
27
|
+
clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 8px 50%);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.breadcrumb-link {
|
|
35
|
+
display: block;
|
|
36
|
+
padding: 4px 12px;
|
|
37
|
+
background: #f0f2f5;
|
|
38
|
+
clip-path: polygon(
|
|
39
|
+
0 0,
|
|
40
|
+
calc(100% - 8px) 0,
|
|
41
|
+
100% 50%,
|
|
42
|
+
calc(100% - 8px) 100%,
|
|
43
|
+
0 100%,
|
|
44
|
+
8px 50%
|
|
45
|
+
);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.breadcrumb-enter-active {
|
|
50
|
+
transition: all 0.25s;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.breadcrumb-enter-from,
|
|
54
|
+
.breadcrumb-leave-active {
|
|
55
|
+
opacity: 0;
|
|
56
|
+
transform: translateX(30px) skewX(-50deg);
|
|
57
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
@import "../../theme/variable.scss";
|
|
2
|
+
.ditari-list-layout {
|
|
3
|
+
padding: 20px;
|
|
4
|
+
height: 100%;
|
|
5
|
+
.wrapper {
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-direction: column;
|
|
8
|
+
}
|
|
9
|
+
.ditari-list-table {
|
|
10
|
+
flex: 1;
|
|
11
|
+
.ant-card-body {
|
|
12
|
+
display: flex;
|
|
13
|
+
flex-direction: column;
|
|
14
|
+
height: 100%;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
.ditari-list-form {
|
|
18
|
+
.ant-card-body {
|
|
19
|
+
padding-bottom: 0;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.wrapper {
|
|
24
|
+
height: 100%;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
@import "../../theme/variable.scss";
|
|
2
|
+
.ditari-ant-back-top {
|
|
3
|
+
right: 4px;
|
|
4
|
+
bottom: 120px;
|
|
5
|
+
}
|
|
6
|
+
.ditari-layout {
|
|
7
|
+
height: 100%;
|
|
8
|
+
.ditari-layout-sider {
|
|
9
|
+
position: fixed;
|
|
10
|
+
left: 0;
|
|
11
|
+
top: 0;
|
|
12
|
+
bottom: 0;
|
|
13
|
+
z-index: 1;
|
|
14
|
+
}
|
|
15
|
+
.ditari-top-layout {
|
|
16
|
+
position: fixed;
|
|
17
|
+
left: 200px;
|
|
18
|
+
right: 0;
|
|
19
|
+
z-index: 210;
|
|
20
|
+
}
|
|
21
|
+
.ditari-layout-content {
|
|
22
|
+
margin-left: 200px;
|
|
23
|
+
margin-top: 84px;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
.fade-enter-active,
|
|
27
|
+
.fade-leave-active {
|
|
28
|
+
transition: opacity 0.1s ease;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.fade-enter-from,
|
|
32
|
+
.fade-leave-to {
|
|
33
|
+
opacity: 0;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.main-enter-active {
|
|
37
|
+
transition: 0.2s;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.main-leave-active {
|
|
41
|
+
transition: 0.15s;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.main-enter-from {
|
|
45
|
+
opacity: 0;
|
|
46
|
+
margin-left: -20px;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.main-leave-to {
|
|
50
|
+
opacity: 0;
|
|
51
|
+
margin-left: 20px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.ditari-layout-header {
|
|
55
|
+
display: flex;
|
|
56
|
+
justify-content: space-between;
|
|
57
|
+
align-items: center;
|
|
58
|
+
padding: 0 15px;
|
|
59
|
+
height: 42px;
|
|
60
|
+
border-bottom: 1px solid #f0f2f5;
|
|
61
|
+
background-color: #fff;
|
|
62
|
+
.ditari-layout-header-left {
|
|
63
|
+
display: flex;
|
|
64
|
+
justify-content: center;
|
|
65
|
+
.ditari-side-collapsed {
|
|
66
|
+
margin-right: 20px;
|
|
67
|
+
cursor: pointer;
|
|
68
|
+
width: 42px;
|
|
69
|
+
line-height: 30px;
|
|
70
|
+
text-align: center;
|
|
71
|
+
transition-duration: 0.2s;
|
|
72
|
+
&:hover {
|
|
73
|
+
background-color: #f0f2f5;
|
|
74
|
+
border-radius: 4px;
|
|
75
|
+
}
|
|
76
|
+
.icon {
|
|
77
|
+
transition-duration: 0.2s;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
.ditari-user-menu {
|
|
83
|
+
display: flex;
|
|
84
|
+
align-items: center;
|
|
85
|
+
height: 100%;
|
|
86
|
+
.ditari-operation-items {
|
|
87
|
+
margin-left: 10px;
|
|
88
|
+
height: 100%;
|
|
89
|
+
.ant-dropdown-link {
|
|
90
|
+
display: flex;
|
|
91
|
+
align-items: center;
|
|
92
|
+
justify-content: center;
|
|
93
|
+
height: 100%;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.collapsed-animation {
|
|
99
|
+
transform: rotate(-180deg);
|
|
100
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
@import "../../theme/variable.scss";
|
|
2
|
+
|
|
3
|
+
/*分割线*/
|
|
4
|
+
@mixin tab-dividers {
|
|
5
|
+
.tab-dividers {
|
|
6
|
+
&::before {
|
|
7
|
+
opacity: 0;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.ditari-nav {
|
|
13
|
+
background: $nav-tab-bg-color;
|
|
14
|
+
.ant-tabs-nav {
|
|
15
|
+
margin: 0;
|
|
16
|
+
}
|
|
17
|
+
.ant-tabs-content-holder {
|
|
18
|
+
display: none;
|
|
19
|
+
}
|
|
20
|
+
.ant-tabs-tab {
|
|
21
|
+
position: relative;
|
|
22
|
+
margin-left: 0 !important;
|
|
23
|
+
border: 0 !important;
|
|
24
|
+
transition: none !important;
|
|
25
|
+
border-radius: 10px 10px 0 0 !important;
|
|
26
|
+
color: $nav-tab-text-color;
|
|
27
|
+
&:first-child,
|
|
28
|
+
&.ant-tabs-tab-active {
|
|
29
|
+
.tab-dividers {
|
|
30
|
+
&::before {
|
|
31
|
+
opacity: 0;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
&:not(.ant-tabs-tab-active) {
|
|
36
|
+
background: transparent;
|
|
37
|
+
}
|
|
38
|
+
&:hover {
|
|
39
|
+
&:not(.ant-tabs-tab-active) {
|
|
40
|
+
background: $nav-tab-hover-bg-color;
|
|
41
|
+
@include tab-dividers;
|
|
42
|
+
& + .ant-tabs-tab {
|
|
43
|
+
@include tab-dividers;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.ant-tabs-tab-btn {
|
|
49
|
+
display: flex;
|
|
50
|
+
align-items: center;
|
|
51
|
+
}
|
|
52
|
+
.anticon {
|
|
53
|
+
margin-right: 0;
|
|
54
|
+
margin-left: 10px;
|
|
55
|
+
&:hover {
|
|
56
|
+
//color: red;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
.ant-tabs-tab-active + .ant-tabs-tab {
|
|
61
|
+
@include tab-dividers;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.ant-tabs-nav-wrap {
|
|
65
|
+
padding: 4px 8px 0;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.ant-tabs-tab::before,
|
|
69
|
+
.ant-tabs-tab::after {
|
|
70
|
+
position: absolute;
|
|
71
|
+
bottom: 0;
|
|
72
|
+
content: "";
|
|
73
|
+
width: 20px;
|
|
74
|
+
height: 20px;
|
|
75
|
+
border-radius: 100%;
|
|
76
|
+
box-shadow: 0 0 0 40px transparent;
|
|
77
|
+
}
|
|
78
|
+
.ant-tabs-tab::before {
|
|
79
|
+
left: -20px;
|
|
80
|
+
clip-path: inset(50% -10px 0 50%);
|
|
81
|
+
}
|
|
82
|
+
.ant-tabs-tab::after {
|
|
83
|
+
right: -20px;
|
|
84
|
+
clip-path: inset(50% 50% 0 -10px);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.ant-tabs-tab:hover::before,
|
|
88
|
+
.ant-tabs-tab:hover::after {
|
|
89
|
+
box-shadow: 0 0 0 30px $nav-tab-hover-bg-color;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.ant-tabs-tab.ant-tabs-tab-active::before,
|
|
93
|
+
.ant-tabs-tab.ant-tabs-tab-active::after {
|
|
94
|
+
z-index: 10;
|
|
95
|
+
box-shadow: 0 0 0 30px #fff;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.tab-dividers {
|
|
99
|
+
position: absolute;
|
|
100
|
+
z-index: 0;
|
|
101
|
+
height: 14px;
|
|
102
|
+
top: 50%;
|
|
103
|
+
left: 0;
|
|
104
|
+
margin-top: -7px;
|
|
105
|
+
&::before {
|
|
106
|
+
content: "";
|
|
107
|
+
display: block;
|
|
108
|
+
position: absolute;
|
|
109
|
+
top: 0;
|
|
110
|
+
left: 1px;
|
|
111
|
+
bottom: 0;
|
|
112
|
+
width: 1px;
|
|
113
|
+
opacity: 1;
|
|
114
|
+
background-color: $nav-tab-dividers-color;
|
|
115
|
+
transition: opacity 0.2s ease, background-color 0.3s;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
@import "../../theme/variable.scss";
|
|
2
|
+
.ditari-show-layout {
|
|
3
|
+
position: relative;
|
|
4
|
+
.ant-card {
|
|
5
|
+
margin-bottom: 10px;
|
|
6
|
+
.ant-card-head {
|
|
7
|
+
padding: 10px 24px;
|
|
8
|
+
.ant-card-head-title {
|
|
9
|
+
padding: 0;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
&:last-child {
|
|
13
|
+
margin-bottom: 0;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
.ditari-page-header {
|
|
17
|
+
position: sticky;
|
|
18
|
+
top: 84px;
|
|
19
|
+
z-index: 1;
|
|
20
|
+
padding: 4px 24px;
|
|
21
|
+
transition: all 0.3s;
|
|
22
|
+
&.active {
|
|
23
|
+
box-shadow: 1px 5px 20px 2px $box-shadow-color;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
.ditari-show-content {
|
|
27
|
+
}
|
|
28
|
+
.ditari-show-footer {
|
|
29
|
+
position: fixed;
|
|
30
|
+
right: 0;
|
|
31
|
+
bottom: 0;
|
|
32
|
+
left: 200px;
|
|
33
|
+
padding: 10px;
|
|
34
|
+
background: #fff;
|
|
35
|
+
box-shadow: 0px 0px 5px 3px $box-shadow-color;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
@@ -10,9 +10,17 @@
|
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
12
|
|
|
13
|
-
.ditari-layout {
|
|
14
|
-
background-color:
|
|
15
|
-
.
|
|
16
|
-
background-color:
|
|
13
|
+
.ditari-layout-sider {
|
|
14
|
+
background-color: $side-bg-color;
|
|
15
|
+
.ant-menu-dark {
|
|
16
|
+
background-color: $side-bg-color;
|
|
17
|
+
.ant-menu-inline.ant-menu-sub {
|
|
18
|
+
background-color: $side-menu-sub-bg-color;
|
|
19
|
+
}
|
|
20
|
+
.ant-menu{
|
|
21
|
+
&:before,&:after{
|
|
22
|
+
//display: none;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
17
25
|
}
|
|
18
26
|
}
|
|
@@ -6,16 +6,33 @@ $bg-color: #f0f2f5;
|
|
|
6
6
|
$logo-height: 240px !default;
|
|
7
7
|
/******======网格变量======******/
|
|
8
8
|
//网格边框颜色
|
|
9
|
-
$grid-border-color: #4e4e4e;
|
|
9
|
+
$grid-border-color: #4e4e4e !default;
|
|
10
10
|
// 网格里面输入框获取焦点时的边框颜色
|
|
11
|
-
$grid-input-focus-border-color: #1890ff;
|
|
11
|
+
$grid-input-focus-border-color: #1890ff !default;
|
|
12
12
|
//输入框校验不通过时候的颜色
|
|
13
|
-
$grid-input-error-border-color: #ff4d4f;
|
|
13
|
+
$grid-input-error-border-color: #ff4d4f !default;
|
|
14
14
|
// 网格输入框边框宽度
|
|
15
|
-
$grid-input-border-width: 2px;
|
|
15
|
+
$grid-input-border-width: 2px !default;
|
|
16
16
|
// 网格边框宽度
|
|
17
|
-
$gird-border-width: 1px;
|
|
17
|
+
$gird-border-width: 1px !default;
|
|
18
18
|
|
|
19
|
+
// show头部阴影
|
|
20
|
+
$box-shadow-color: #e0e0e0 !default;
|
|
21
|
+
|
|
22
|
+
/******======左侧菜单======******/
|
|
19
23
|
// 左侧菜单
|
|
20
|
-
|
|
24
|
+
|
|
21
25
|
$logo-height: 40px !default;
|
|
26
|
+
//左侧菜单北京颜色
|
|
27
|
+
$side-bg-color: #162157 !default;
|
|
28
|
+
//子菜单展开后的背景颜色
|
|
29
|
+
$side-menu-sub-bg-color: #101847 !default;
|
|
30
|
+
|
|
31
|
+
/******======多标签======******/
|
|
32
|
+
$nav-tab-bg-color: linear-gradient(270deg, #019cfe 0%, #0165fe 100%) !default;
|
|
33
|
+
//分割符颜色
|
|
34
|
+
$nav-tab-dividers-color: #fff !default;
|
|
35
|
+
// 字体颜色
|
|
36
|
+
$nav-tab-text-color: #fff !default;
|
|
37
|
+
// 悬浮的背景色
|
|
38
|
+
$nav-tab-hover-bg-color: #065de1 !default;
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ditari/bsui",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"files": [
|
|
5
|
-
"dist
|
|
6
|
-
"src
|
|
5
|
+
"dist",
|
|
6
|
+
"src"
|
|
7
7
|
],
|
|
8
8
|
"private": false,
|
|
9
9
|
"publishConfig": {
|
|
@@ -27,5 +27,9 @@
|
|
|
27
27
|
},
|
|
28
28
|
"./css/*": "./dist/css/*",
|
|
29
29
|
"./theme/*": "./dist/style/*"
|
|
30
|
+
},
|
|
31
|
+
"devDependencies": {
|
|
32
|
+
"@ant-design/icons-vue": "^6.1.0",
|
|
33
|
+
"ant-design-vue": "^3.2.15"
|
|
30
34
|
}
|
|
31
35
|
}
|
package/src/components/index.ts
CHANGED
|
@@ -5,15 +5,22 @@ import { createPersistedState } from "pinia-plugin-persistedstate";
|
|
|
5
5
|
import * as components from "./components";
|
|
6
6
|
export * from "./components";
|
|
7
7
|
|
|
8
|
+
export interface MenuIcon {
|
|
9
|
+
componentName: string | "nativeHtml";
|
|
10
|
+
type: string;
|
|
11
|
+
}
|
|
12
|
+
export interface Options {
|
|
13
|
+
menuIcon: MenuIcon;
|
|
14
|
+
prop: string;
|
|
15
|
+
}
|
|
8
16
|
const c: any = components;
|
|
9
|
-
export const install = function (app: App, opts:
|
|
17
|
+
export const install = function (app: App, opts: Options) {
|
|
10
18
|
Object.keys(c).forEach((key) => {
|
|
11
19
|
const component = c[key];
|
|
12
20
|
if (component.install) {
|
|
13
21
|
app.use(component);
|
|
14
22
|
}
|
|
15
23
|
});
|
|
16
|
-
|
|
17
24
|
//注册pinia
|
|
18
25
|
const pinia = createPinia();
|
|
19
26
|
//pinia启用持久化
|
|
@@ -23,6 +30,7 @@ export const install = function (app: App, opts: any) {
|
|
|
23
30
|
})
|
|
24
31
|
);
|
|
25
32
|
app.use(pinia);
|
|
33
|
+
app.provide("menuIcon", opts.menuIcon);
|
|
26
34
|
console.log("options", opts);
|
|
27
35
|
};
|
|
28
36
|
|