@mc-markets/ui 1.0.90 → 1.0.92
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/README.md +243 -40
- package/USAGE_GUIDE.md +339 -0
- package/dist/404.html +22 -22
- package/dist/components/Tag/Tag.vue.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +10 -11
- package/dist/index.mjs.map +1 -1
- package/dist/resolver.d.ts +26 -0
- package/dist/resolver.d.ts.map +1 -0
- package/dist/style.css +1 -1
- package/package.json +8 -5
- package/packages/components/Alert/Alert.vue +139 -139
- package/packages/components/Banner/Banner.vue +299 -299
- package/packages/components/Breadcrumb/Breadcrumb.vue +113 -113
- package/packages/components/Breadcrumb/BreadcrumbSeparator.vue +31 -31
- package/packages/components/Button/Button.vue +17 -17
- package/packages/components/DatePicker/DatePicker.vue +85 -85
- package/packages/components/Dialog/Dialog.vue +61 -61
- package/packages/components/Empty/Empty.vue +73 -73
- package/packages/components/Form/Form.vue +30 -30
- package/packages/components/FormItem/FormItem.vue +19 -19
- package/packages/components/Icon/Icon.vue +210 -210
- package/packages/components/Input/Input.vue +15 -15
- package/packages/components/Message/Message.vue +503 -503
- package/packages/components/NotifiMessage/NotifiMessage.vue +293 -293
- package/packages/components/Notification/Notification.vue +19 -19
- package/packages/components/Option/Option.vue +13 -13
- package/packages/components/OptionGroup/OptionGroup.vue +13 -13
- package/packages/components/Pagination/Pagination.vue +61 -61
- package/packages/components/Radio/Radio.vue +67 -67
- package/packages/components/RadioButton/RadioButton.vue +110 -110
- package/packages/components/RadioGroup/RadioGroup.vue +155 -155
- package/packages/components/Select/Select.vue +22 -22
- package/packages/components/Switch/Switch.vue +47 -47
- package/packages/components/TabCard/TabCard.vue +107 -107
- package/packages/components/TabCard/TabCardItem.vue +105 -105
- package/packages/components/Table/Table.vue +17 -17
- package/packages/components/Table/TableColumn.vue +20 -20
- package/packages/components/Tabs/TabPane.vue +79 -79
- package/packages/components/Tabs/Tabs.vue +267 -267
- package/packages/components/Tag/Tag.vue +208 -211
- package/packages/components/Tooltip/Tooltip.vue +58 -58
- package/packages/hooks/useClassName.js +23 -23
- package/packages/resolver.js +179 -0
- package/packages/styles/README.md +129 -129
- package/packages/styles/colorfont/iconfont.css +1 -0
- package/packages/styles/components/button.scss +121 -121
- package/packages/styles/components/checkbox.scss +18 -18
- package/packages/styles/components/dialog.scss +47 -47
- package/packages/styles/components/form.scss +18 -18
- package/packages/styles/components/input.scss +14 -14
- package/packages/styles/components/select.scss +62 -62
- package/packages/styles/components/table.scss +37 -37
- package/packages/styles/components/tabs.scss +76 -76
- package/packages/styles/components/tag.scss +142 -142
- package/packages/styles/font/iconfont.scss +363 -363
- package/packages/styles/index.scss +94 -94
- package/packages/styles/variables/border-mode.css +6 -6
- package/packages/styles/variables/color-modes-dark.css +143 -143
- package/packages/styles/variables/index.scss +5 -5
- package/packages/styles/variables/primitives-style.css +112 -112
- package/packages/styles/variables/radius-mode.css +14 -14
- package/packages/styles/variables/spacing-mode.css +20 -20
- package/packages/styles/variables/typography-desktop.css +40 -40
- package/packages/styles/variables/typography-mobile.css +40 -40
- package/packages/utils/classNames.js +23 -23
- package/packages/utils/styleUtils.js +105 -105
|
@@ -1,113 +1,113 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<nav class="m-breadcrumb" aria-label="Breadcrumb">
|
|
3
|
-
<template v-for="(item, index) in items" :key="index">
|
|
4
|
-
<span
|
|
5
|
-
:class="['m-breadcrumb__item', { 'is-link': item.to }]"
|
|
6
|
-
@click="handleItemClick(item)"
|
|
7
|
-
>
|
|
8
|
-
{{ item.label }}
|
|
9
|
-
</span>
|
|
10
|
-
<BreadcrumbSeparator
|
|
11
|
-
v-if="index < items.length - 1"
|
|
12
|
-
class="m-breadcrumb__separator"
|
|
13
|
-
/>
|
|
14
|
-
</template>
|
|
15
|
-
</nav>
|
|
16
|
-
</template>
|
|
17
|
-
|
|
18
|
-
<script setup>
|
|
19
|
-
import BreadcrumbSeparator from './BreadcrumbSeparator.vue'
|
|
20
|
-
|
|
21
|
-
defineOptions({
|
|
22
|
-
name: "MBreadcrumb",
|
|
23
|
-
})
|
|
24
|
-
|
|
25
|
-
const props = defineProps({
|
|
26
|
-
items: {
|
|
27
|
-
type: Array,
|
|
28
|
-
default: () => [],
|
|
29
|
-
validator: (items) => {
|
|
30
|
-
return items.every(item =>
|
|
31
|
-
typeof item === 'object' &&
|
|
32
|
-
item.label !== undefined
|
|
33
|
-
)
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
})
|
|
37
|
-
|
|
38
|
-
const emit = defineEmits(['click'])
|
|
39
|
-
|
|
40
|
-
const handleItemClick = (item) => {
|
|
41
|
-
if (!item.to) return
|
|
42
|
-
|
|
43
|
-
emit('click', item)
|
|
44
|
-
|
|
45
|
-
// 处理路由跳转
|
|
46
|
-
if (typeof item.to === 'string') {
|
|
47
|
-
if (item.to.startsWith('http://') || item.to.startsWith('https://')) {
|
|
48
|
-
window.location.href = item.to
|
|
49
|
-
} else {
|
|
50
|
-
if (item.replace) {
|
|
51
|
-
window.history.replaceState({}, '', item.to)
|
|
52
|
-
} else {
|
|
53
|
-
window.history.pushState({}, '', item.to)
|
|
54
|
-
}
|
|
55
|
-
window.dispatchEvent(new PopStateEvent('popstate'))
|
|
56
|
-
}
|
|
57
|
-
} else if (typeof item.to === 'object' && item.to.path) {
|
|
58
|
-
const path = item.to.path
|
|
59
|
-
if (item.replace) {
|
|
60
|
-
window.history.replaceState({}, '', path)
|
|
61
|
-
} else {
|
|
62
|
-
window.history.pushState({}, '', path)
|
|
63
|
-
}
|
|
64
|
-
window.dispatchEvent(new PopStateEvent('popstate'))
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
</script>
|
|
68
|
-
|
|
69
|
-
<style lang="scss" scoped>
|
|
70
|
-
.m-breadcrumb {
|
|
71
|
-
display: inline-flex;
|
|
72
|
-
align-items: center;
|
|
73
|
-
font-size: 14px;
|
|
74
|
-
line-height: 20px;
|
|
75
|
-
height: 20px;
|
|
76
|
-
|
|
77
|
-
&__item {
|
|
78
|
-
color: var(--text-secondary, #909399);
|
|
79
|
-
transition: color 0.2s;
|
|
80
|
-
white-space: nowrap;
|
|
81
|
-
line-height: 20px;
|
|
82
|
-
height: 20px;
|
|
83
|
-
display: inline-flex;
|
|
84
|
-
align-items: center;
|
|
85
|
-
|
|
86
|
-
&.is-link {
|
|
87
|
-
color: var(--text-primary, #303133);
|
|
88
|
-
cursor: pointer;
|
|
89
|
-
font-weight: 500;
|
|
90
|
-
|
|
91
|
-
&:hover {
|
|
92
|
-
color: var(--bg-brand, #ffd700);
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
&:last-child {
|
|
97
|
-
color: var(--text-tertiary, #c0c4cc);
|
|
98
|
-
cursor: default;
|
|
99
|
-
font-weight: normal;
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
&__separator {
|
|
104
|
-
margin: 0 8px;
|
|
105
|
-
color: var(--text-tertiary, #c0c4cc);
|
|
106
|
-
flex-shrink: 0;
|
|
107
|
-
display: inline-flex;
|
|
108
|
-
align-items: center;
|
|
109
|
-
height: 20px;
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
</style>
|
|
113
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<nav class="m-breadcrumb" aria-label="Breadcrumb">
|
|
3
|
+
<template v-for="(item, index) in items" :key="index">
|
|
4
|
+
<span
|
|
5
|
+
:class="['m-breadcrumb__item', { 'is-link': item.to }]"
|
|
6
|
+
@click="handleItemClick(item)"
|
|
7
|
+
>
|
|
8
|
+
{{ item.label }}
|
|
9
|
+
</span>
|
|
10
|
+
<BreadcrumbSeparator
|
|
11
|
+
v-if="index < items.length - 1"
|
|
12
|
+
class="m-breadcrumb__separator"
|
|
13
|
+
/>
|
|
14
|
+
</template>
|
|
15
|
+
</nav>
|
|
16
|
+
</template>
|
|
17
|
+
|
|
18
|
+
<script setup>
|
|
19
|
+
import BreadcrumbSeparator from './BreadcrumbSeparator.vue'
|
|
20
|
+
|
|
21
|
+
defineOptions({
|
|
22
|
+
name: "MBreadcrumb",
|
|
23
|
+
})
|
|
24
|
+
|
|
25
|
+
const props = defineProps({
|
|
26
|
+
items: {
|
|
27
|
+
type: Array,
|
|
28
|
+
default: () => [],
|
|
29
|
+
validator: (items) => {
|
|
30
|
+
return items.every(item =>
|
|
31
|
+
typeof item === 'object' &&
|
|
32
|
+
item.label !== undefined
|
|
33
|
+
)
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
})
|
|
37
|
+
|
|
38
|
+
const emit = defineEmits(['click'])
|
|
39
|
+
|
|
40
|
+
const handleItemClick = (item) => {
|
|
41
|
+
if (!item.to) return
|
|
42
|
+
|
|
43
|
+
emit('click', item)
|
|
44
|
+
|
|
45
|
+
// 处理路由跳转
|
|
46
|
+
if (typeof item.to === 'string') {
|
|
47
|
+
if (item.to.startsWith('http://') || item.to.startsWith('https://')) {
|
|
48
|
+
window.location.href = item.to
|
|
49
|
+
} else {
|
|
50
|
+
if (item.replace) {
|
|
51
|
+
window.history.replaceState({}, '', item.to)
|
|
52
|
+
} else {
|
|
53
|
+
window.history.pushState({}, '', item.to)
|
|
54
|
+
}
|
|
55
|
+
window.dispatchEvent(new PopStateEvent('popstate'))
|
|
56
|
+
}
|
|
57
|
+
} else if (typeof item.to === 'object' && item.to.path) {
|
|
58
|
+
const path = item.to.path
|
|
59
|
+
if (item.replace) {
|
|
60
|
+
window.history.replaceState({}, '', path)
|
|
61
|
+
} else {
|
|
62
|
+
window.history.pushState({}, '', path)
|
|
63
|
+
}
|
|
64
|
+
window.dispatchEvent(new PopStateEvent('popstate'))
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
</script>
|
|
68
|
+
|
|
69
|
+
<style lang="scss" scoped>
|
|
70
|
+
.m-breadcrumb {
|
|
71
|
+
display: inline-flex;
|
|
72
|
+
align-items: center;
|
|
73
|
+
font-size: 14px;
|
|
74
|
+
line-height: 20px;
|
|
75
|
+
height: 20px;
|
|
76
|
+
|
|
77
|
+
&__item {
|
|
78
|
+
color: var(--text-secondary, #909399);
|
|
79
|
+
transition: color 0.2s;
|
|
80
|
+
white-space: nowrap;
|
|
81
|
+
line-height: 20px;
|
|
82
|
+
height: 20px;
|
|
83
|
+
display: inline-flex;
|
|
84
|
+
align-items: center;
|
|
85
|
+
|
|
86
|
+
&.is-link {
|
|
87
|
+
color: var(--text-primary, #303133);
|
|
88
|
+
cursor: pointer;
|
|
89
|
+
font-weight: 500;
|
|
90
|
+
|
|
91
|
+
&:hover {
|
|
92
|
+
color: var(--bg-brand, #ffd700);
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
&:last-child {
|
|
97
|
+
color: var(--text-tertiary, #c0c4cc);
|
|
98
|
+
cursor: default;
|
|
99
|
+
font-weight: normal;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
&__separator {
|
|
104
|
+
margin: 0 8px;
|
|
105
|
+
color: var(--text-tertiary, #c0c4cc);
|
|
106
|
+
flex-shrink: 0;
|
|
107
|
+
display: inline-flex;
|
|
108
|
+
align-items: center;
|
|
109
|
+
height: 20px;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
</style>
|
|
113
|
+
|
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<svg
|
|
3
|
-
class="breadcrumb-separator-icon"
|
|
4
|
-
width="6"
|
|
5
|
-
height="10"
|
|
6
|
-
viewBox="0 0 6 10"
|
|
7
|
-
fill="none"
|
|
8
|
-
xmlns="http://www.w3.org/2000/svg"
|
|
9
|
-
>
|
|
10
|
-
<path
|
|
11
|
-
fill-rule="evenodd"
|
|
12
|
-
clip-rule="evenodd"
|
|
13
|
-
d="M0.52827 0.529247C0.788619 0.268897 1.21073 0.268897 1.47108 0.529247L5.47108 4.52925C5.73143 4.7896 5.73143 5.21171 5.47108 5.47206L1.47108 9.47206C1.21073 9.73241 0.788619 9.73241 0.52827 9.47206C0.26792 9.21171 0.26792 8.7896 0.52827 8.52925L4.05687 5.00065L0.52827 1.47206C0.26792 1.21171 0.26792 0.789596 0.52827 0.529247Z"
|
|
14
|
-
fill="currentColor"
|
|
15
|
-
/>
|
|
16
|
-
</svg>
|
|
17
|
-
</template>
|
|
18
|
-
|
|
19
|
-
<script setup>
|
|
20
|
-
defineOptions({
|
|
21
|
-
name: "BreadcrumbSeparator",
|
|
22
|
-
})
|
|
23
|
-
</script>
|
|
24
|
-
|
|
25
|
-
<style lang="scss" scoped>
|
|
26
|
-
.breadcrumb-separator-icon {
|
|
27
|
-
display: inline-block;
|
|
28
|
-
vertical-align: middle;
|
|
29
|
-
}
|
|
30
|
-
</style>
|
|
31
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<svg
|
|
3
|
+
class="breadcrumb-separator-icon"
|
|
4
|
+
width="6"
|
|
5
|
+
height="10"
|
|
6
|
+
viewBox="0 0 6 10"
|
|
7
|
+
fill="none"
|
|
8
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
9
|
+
>
|
|
10
|
+
<path
|
|
11
|
+
fill-rule="evenodd"
|
|
12
|
+
clip-rule="evenodd"
|
|
13
|
+
d="M0.52827 0.529247C0.788619 0.268897 1.21073 0.268897 1.47108 0.529247L5.47108 4.52925C5.73143 4.7896 5.73143 5.21171 5.47108 5.47206L1.47108 9.47206C1.21073 9.73241 0.788619 9.73241 0.52827 9.47206C0.26792 9.21171 0.26792 8.7896 0.52827 8.52925L4.05687 5.00065L0.52827 1.47206C0.26792 1.21171 0.26792 0.789596 0.52827 0.529247Z"
|
|
14
|
+
fill="currentColor"
|
|
15
|
+
/>
|
|
16
|
+
</svg>
|
|
17
|
+
</template>
|
|
18
|
+
|
|
19
|
+
<script setup>
|
|
20
|
+
defineOptions({
|
|
21
|
+
name: "BreadcrumbSeparator",
|
|
22
|
+
})
|
|
23
|
+
</script>
|
|
24
|
+
|
|
25
|
+
<style lang="scss" scoped>
|
|
26
|
+
.breadcrumb-separator-icon {
|
|
27
|
+
display: inline-block;
|
|
28
|
+
vertical-align: middle;
|
|
29
|
+
}
|
|
30
|
+
</style>
|
|
31
|
+
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<el-button v-bind="$attrs" class="m-button">
|
|
3
|
-
<template v-for="(_, name) in $slots" :key="name" #[name]>
|
|
4
|
-
<slot :name="name" />
|
|
5
|
-
</template>
|
|
6
|
-
</el-button>
|
|
7
|
-
</template>
|
|
8
|
-
|
|
9
|
-
<script setup>
|
|
10
|
-
defineOptions({
|
|
11
|
-
name: 'MButton'
|
|
12
|
-
})
|
|
13
|
-
</script>
|
|
14
|
-
|
|
15
|
-
<style lang="scss" scoped>
|
|
16
|
-
// Button 组件样式 - 使用高优先级选择器确保不被全局样式覆盖
|
|
17
|
-
|
|
1
|
+
<template>
|
|
2
|
+
<el-button v-bind="$attrs" class="m-button">
|
|
3
|
+
<template v-for="(_, name) in $slots" :key="name" #[name]>
|
|
4
|
+
<slot :name="name" />
|
|
5
|
+
</template>
|
|
6
|
+
</el-button>
|
|
7
|
+
</template>
|
|
8
|
+
|
|
9
|
+
<script setup>
|
|
10
|
+
defineOptions({
|
|
11
|
+
name: 'MButton'
|
|
12
|
+
})
|
|
13
|
+
</script>
|
|
14
|
+
|
|
15
|
+
<style lang="scss" scoped>
|
|
16
|
+
// Button 组件样式 - 使用高优先级选择器确保不被全局样式覆盖
|
|
17
|
+
|
|
18
18
|
</style>
|
|
@@ -1,85 +1,85 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<el-date-picker v-bind="mergedAttrs" class="m-datepicker" :popper-class="popperClass" :class="{ 'style-type-solid': styleType === 'solid' }">
|
|
3
|
-
<template v-for="(_, name) in $slots" :key="name" #[name]>
|
|
4
|
-
<slot :name="name" />
|
|
5
|
-
</template>
|
|
6
|
-
</el-date-picker>
|
|
7
|
-
</template>
|
|
8
|
-
|
|
9
|
-
<script setup>
|
|
10
|
-
import { useClassName } from "@packages/hooks/useClassName.js";
|
|
11
|
-
|
|
12
|
-
defineOptions({
|
|
13
|
-
name: "MDatePicker",
|
|
14
|
-
});
|
|
15
|
-
|
|
16
|
-
// 定义 props,提供默认的 type 值
|
|
17
|
-
const props = defineProps({
|
|
18
|
-
popperClass: {
|
|
19
|
-
type: String,
|
|
20
|
-
default: "",
|
|
21
|
-
},
|
|
22
|
-
styleType: {
|
|
23
|
-
type: String,
|
|
24
|
-
},
|
|
25
|
-
});
|
|
26
|
-
|
|
27
|
-
// 使用类名 Hook,排除 type 和 popperClass 属性
|
|
28
|
-
const { mergedAttrs, className: popperClass } = useClassName(
|
|
29
|
-
"mc-datepicker-popper",
|
|
30
|
-
"popperClass"
|
|
31
|
-
);
|
|
32
|
-
</script>
|
|
33
|
-
<style lang="scss">
|
|
34
|
-
.m-datepicker{
|
|
35
|
-
&.style-type-solid{
|
|
36
|
-
&.el-date-editor.el-input__wrapper, .el-input__wrapper{
|
|
37
|
-
box-shadow: none ;
|
|
38
|
-
background-color: var(--bg-tertiary-hover);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
&.el-input--small{
|
|
42
|
-
--el-input-height: 40px;
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
.mc-datepicker-popper {
|
|
46
|
-
.el-picker-panel {
|
|
47
|
-
border: 1px solid var(--border-primary);
|
|
48
|
-
border-radius: 6px;
|
|
49
|
-
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
|
50
|
-
.current,
|
|
51
|
-
// .today:not(.in-range),
|
|
52
|
-
.start-date,
|
|
53
|
-
.end-date {
|
|
54
|
-
.el-date-table-cell {
|
|
55
|
-
.el-date-table-cell__text {
|
|
56
|
-
color: var(--text-quaternary);
|
|
57
|
-
border-radius: 3px;
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
.start-date {
|
|
63
|
-
.el-date-table-cell {
|
|
64
|
-
border-top-left-radius: 3px;
|
|
65
|
-
border-bottom-left-radius: 3px;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
.end-date {
|
|
70
|
-
.el-date-table-cell {
|
|
71
|
-
border-top-right-radius: 3px;
|
|
72
|
-
border-bottom-right-radius: 3px;
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
.el-button.is-text {
|
|
77
|
-
color: var(--text-brand);
|
|
78
|
-
}
|
|
79
|
-
.el-button.is-plain {
|
|
80
|
-
background: var(--bg-brand);
|
|
81
|
-
color: var(--text-quaternary);
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<el-date-picker v-bind="mergedAttrs" class="m-datepicker" :popper-class="popperClass" :class="{ 'style-type-solid': styleType === 'solid' }">
|
|
3
|
+
<template v-for="(_, name) in $slots" :key="name" #[name]>
|
|
4
|
+
<slot :name="name" />
|
|
5
|
+
</template>
|
|
6
|
+
</el-date-picker>
|
|
7
|
+
</template>
|
|
8
|
+
|
|
9
|
+
<script setup>
|
|
10
|
+
import { useClassName } from "@packages/hooks/useClassName.js";
|
|
11
|
+
|
|
12
|
+
defineOptions({
|
|
13
|
+
name: "MDatePicker",
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
// 定义 props,提供默认的 type 值
|
|
17
|
+
const props = defineProps({
|
|
18
|
+
popperClass: {
|
|
19
|
+
type: String,
|
|
20
|
+
default: "",
|
|
21
|
+
},
|
|
22
|
+
styleType: {
|
|
23
|
+
type: String,
|
|
24
|
+
},
|
|
25
|
+
});
|
|
26
|
+
|
|
27
|
+
// 使用类名 Hook,排除 type 和 popperClass 属性
|
|
28
|
+
const { mergedAttrs, className: popperClass } = useClassName(
|
|
29
|
+
"mc-datepicker-popper",
|
|
30
|
+
"popperClass"
|
|
31
|
+
);
|
|
32
|
+
</script>
|
|
33
|
+
<style lang="scss">
|
|
34
|
+
.m-datepicker{
|
|
35
|
+
&.style-type-solid{
|
|
36
|
+
&.el-date-editor.el-input__wrapper, .el-input__wrapper{
|
|
37
|
+
box-shadow: none ;
|
|
38
|
+
background-color: var(--bg-tertiary-hover);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
&.el-input--small{
|
|
42
|
+
--el-input-height: 40px;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
.mc-datepicker-popper {
|
|
46
|
+
.el-picker-panel {
|
|
47
|
+
border: 1px solid var(--border-primary);
|
|
48
|
+
border-radius: 6px;
|
|
49
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
|
50
|
+
.current,
|
|
51
|
+
// .today:not(.in-range),
|
|
52
|
+
.start-date,
|
|
53
|
+
.end-date {
|
|
54
|
+
.el-date-table-cell {
|
|
55
|
+
.el-date-table-cell__text {
|
|
56
|
+
color: var(--text-quaternary);
|
|
57
|
+
border-radius: 3px;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.start-date {
|
|
63
|
+
.el-date-table-cell {
|
|
64
|
+
border-top-left-radius: 3px;
|
|
65
|
+
border-bottom-left-radius: 3px;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.end-date {
|
|
70
|
+
.el-date-table-cell {
|
|
71
|
+
border-top-right-radius: 3px;
|
|
72
|
+
border-bottom-right-radius: 3px;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.el-button.is-text {
|
|
77
|
+
color: var(--text-brand);
|
|
78
|
+
}
|
|
79
|
+
.el-button.is-plain {
|
|
80
|
+
background: var(--bg-brand);
|
|
81
|
+
color: var(--text-quaternary);
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
</style>
|
|
@@ -1,61 +1,61 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<el-dialog
|
|
4
|
-
v-model="dialogVisible"
|
|
5
|
-
:width="width"
|
|
6
|
-
:title="title"
|
|
7
|
-
:draggable="draggable"
|
|
8
|
-
:close-on-click-modal="closeOnClickModal"
|
|
9
|
-
:center="center"
|
|
10
|
-
v-bind="$attrs"
|
|
11
|
-
class="m-dialog"
|
|
12
|
-
header-class="m-header"
|
|
13
|
-
>
|
|
14
|
-
<template v-if="$slots.header" #header="{ close, titleId, titleClass }">
|
|
15
|
-
<slot name="header" v-bind="{ close, titleId, titleClass }"></slot>
|
|
16
|
-
</template>
|
|
17
|
-
<slot name="default"></slot>
|
|
18
|
-
<template v-if="$slots.footer" #footer class="m-footer">
|
|
19
|
-
<slot name="footer"></slot>
|
|
20
|
-
</template>
|
|
21
|
-
</el-dialog>
|
|
22
|
-
</div>
|
|
23
|
-
</template>
|
|
24
|
-
|
|
25
|
-
<script setup>
|
|
26
|
-
defineOptions({
|
|
27
|
-
name: 'MDialog'
|
|
28
|
-
})
|
|
29
|
-
const props = defineProps({
|
|
30
|
-
width: {
|
|
31
|
-
type: String,
|
|
32
|
-
default: '440px'
|
|
33
|
-
},
|
|
34
|
-
center: {
|
|
35
|
-
type: Boolean,
|
|
36
|
-
default: true
|
|
37
|
-
},
|
|
38
|
-
draggable: {
|
|
39
|
-
type: Boolean,
|
|
40
|
-
default: true
|
|
41
|
-
},
|
|
42
|
-
closeOnClickModal: {
|
|
43
|
-
type: Boolean,
|
|
44
|
-
default: false
|
|
45
|
-
},
|
|
46
|
-
title: {
|
|
47
|
-
type: String,
|
|
48
|
-
default: ''
|
|
49
|
-
}
|
|
50
|
-
})
|
|
51
|
-
const emit = defineEmits(['close'])
|
|
52
|
-
const dialogVisible = defineModel('modelValue', {
|
|
53
|
-
type: Boolean,
|
|
54
|
-
default: false
|
|
55
|
-
})
|
|
56
|
-
|
|
57
|
-
</script>
|
|
58
|
-
|
|
59
|
-
<style scoped lang="scss">
|
|
60
|
-
|
|
61
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<el-dialog
|
|
4
|
+
v-model="dialogVisible"
|
|
5
|
+
:width="width"
|
|
6
|
+
:title="title"
|
|
7
|
+
:draggable="draggable"
|
|
8
|
+
:close-on-click-modal="closeOnClickModal"
|
|
9
|
+
:center="center"
|
|
10
|
+
v-bind="$attrs"
|
|
11
|
+
class="m-dialog"
|
|
12
|
+
header-class="m-header"
|
|
13
|
+
>
|
|
14
|
+
<template v-if="$slots.header" #header="{ close, titleId, titleClass }">
|
|
15
|
+
<slot name="header" v-bind="{ close, titleId, titleClass }"></slot>
|
|
16
|
+
</template>
|
|
17
|
+
<slot name="default"></slot>
|
|
18
|
+
<template v-if="$slots.footer" #footer class="m-footer">
|
|
19
|
+
<slot name="footer"></slot>
|
|
20
|
+
</template>
|
|
21
|
+
</el-dialog>
|
|
22
|
+
</div>
|
|
23
|
+
</template>
|
|
24
|
+
|
|
25
|
+
<script setup>
|
|
26
|
+
defineOptions({
|
|
27
|
+
name: 'MDialog'
|
|
28
|
+
})
|
|
29
|
+
const props = defineProps({
|
|
30
|
+
width: {
|
|
31
|
+
type: String,
|
|
32
|
+
default: '440px'
|
|
33
|
+
},
|
|
34
|
+
center: {
|
|
35
|
+
type: Boolean,
|
|
36
|
+
default: true
|
|
37
|
+
},
|
|
38
|
+
draggable: {
|
|
39
|
+
type: Boolean,
|
|
40
|
+
default: true
|
|
41
|
+
},
|
|
42
|
+
closeOnClickModal: {
|
|
43
|
+
type: Boolean,
|
|
44
|
+
default: false
|
|
45
|
+
},
|
|
46
|
+
title: {
|
|
47
|
+
type: String,
|
|
48
|
+
default: ''
|
|
49
|
+
}
|
|
50
|
+
})
|
|
51
|
+
const emit = defineEmits(['close'])
|
|
52
|
+
const dialogVisible = defineModel('modelValue', {
|
|
53
|
+
type: Boolean,
|
|
54
|
+
default: false
|
|
55
|
+
})
|
|
56
|
+
|
|
57
|
+
</script>
|
|
58
|
+
|
|
59
|
+
<style scoped lang="scss">
|
|
60
|
+
|
|
61
|
+
</style>
|