@flyanra/vue-core 0.1.0
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 +176 -0
- package/dist/types/components/AppButton/AppButton.types.d.ts +8 -0
- package/dist/types/components/AppButton/AppButton.vue.d.ts +20 -0
- package/dist/types/components/AppButton/index.d.ts +4 -0
- package/dist/types/components/AppCard/AppCard.types.d.ts +5 -0
- package/dist/types/components/AppCard/AppCard.vue.d.ts +17 -0
- package/dist/types/components/AppCard/index.d.ts +4 -0
- package/dist/types/components/basic/fly-button/FlyButton.types.d.ts +25 -0
- package/dist/types/components/basic/fly-button/FlyButton.vue.d.ts +26 -0
- package/dist/types/components/basic/fly-button/index.d.ts +4 -0
- package/dist/types/components/basic/index.d.ts +2 -0
- package/dist/types/components/feedback/index.d.ts +2 -0
- package/dist/types/components/feedback/tooltip/FlyTooltip.types.d.ts +4 -0
- package/dist/types/components/feedback/tooltip/FlyTooltip.vue.d.ts +16 -0
- package/dist/types/components/feedback/tooltip/index.d.ts +4 -0
- package/dist/types/components/general/fly-icon/FlyIcon.types.d.ts +7 -0
- package/dist/types/components/general/fly-icon/FlyIcon.vue.d.ts +6 -0
- package/dist/types/components/general/fly-icon/index.d.ts +4 -0
- package/dist/types/components/general/index.d.ts +2 -0
- package/dist/types/components/index.d.ts +9 -0
- package/dist/types/components/navigation/index.d.ts +1 -0
- package/dist/types/components/navigation/menu/fly-mini-sidebar/FlyMiniSidebar.types.d.ts +7 -0
- package/dist/types/components/navigation/menu/fly-mini-sidebar/FlyMiniSidebar.vue.d.ts +8 -0
- package/dist/types/components/navigation/menu/fly-mini-sidebar/FlyMiniSidebarItem.vue.d.ts +7 -0
- package/dist/types/components/navigation/menu/fly-mini-sidebar/index.d.ts +4 -0
- package/dist/types/components/navigation/menu/fly-sidebar/FlySidebar.types.d.ts +29 -0
- package/dist/types/components/navigation/menu/fly-sidebar/FlySidebar.vue.d.ts +8 -0
- package/dist/types/components/navigation/menu/fly-sidebar/FlySidebarNode.vue.d.ts +7 -0
- package/dist/types/components/navigation/menu/fly-sidebar/index.d.ts +4 -0
- package/dist/types/components/navigation/menu/index.d.ts +4 -0
- package/dist/types/index.d.ts +1 -0
- package/package.json +123 -0
- package/src/components/AppButton/AppButton.element.scss +2 -0
- package/src/components/AppButton/AppButton.types.ts +10 -0
- package/src/components/AppButton/AppButton.vue +65 -0
- package/src/components/AppButton/index.ts +6 -0
- package/src/components/AppCard/AppCard.types.ts +5 -0
- package/src/components/AppCard/AppCard.vue +58 -0
- package/src/components/AppCard/index.ts +6 -0
- package/src/components/basic/fly-button/FlyButton.element.scss +3 -0
- package/src/components/basic/fly-button/FlyButton.mixins.scss +58 -0
- package/src/components/basic/fly-button/FlyButton.types.ts +29 -0
- package/src/components/basic/fly-button/FlyButton.vue +180 -0
- package/src/components/basic/fly-button/index.ts +11 -0
- package/src/components/basic/index.ts +2 -0
- package/src/components/feedback/index.ts +2 -0
- package/src/components/feedback/tooltip/FlyTooltip.element.scss +4 -0
- package/src/components/feedback/tooltip/FlyTooltip.types.ts +5 -0
- package/src/components/feedback/tooltip/FlyTooltip.vue +59 -0
- package/src/components/feedback/tooltip/index.ts +6 -0
- package/src/components/general/fly-icon/FlyIcon.types.ts +12 -0
- package/src/components/general/fly-icon/FlyIcon.vue +24 -0
- package/src/components/general/fly-icon/index.ts +6 -0
- package/src/components/general/index.ts +2 -0
- package/src/components/index.ts +12 -0
- package/src/components/navigation/index.ts +1 -0
- package/src/components/navigation/menu/fly-mini-sidebar/FlyMiniSidebar.element.scss +2 -0
- package/src/components/navigation/menu/fly-mini-sidebar/FlyMiniSidebar.types.ts +8 -0
- package/src/components/navigation/menu/fly-mini-sidebar/FlyMiniSidebar.vue +46 -0
- package/src/components/navigation/menu/fly-mini-sidebar/FlyMiniSidebarItem.vue +55 -0
- package/src/components/navigation/menu/fly-mini-sidebar/index.ts +6 -0
- package/src/components/navigation/menu/fly-sidebar/FlySidebar.element.scss +9 -0
- package/src/components/navigation/menu/fly-sidebar/FlySidebar.types.ts +36 -0
- package/src/components/navigation/menu/fly-sidebar/FlySidebar.vue +150 -0
- package/src/components/navigation/menu/fly-sidebar/FlySidebarNode.vue +47 -0
- package/src/components/navigation/menu/fly-sidebar/index.ts +12 -0
- package/src/components/navigation/menu/index.ts +5 -0
- package/src/index.ts +1 -0
- package/src/styles/_scss-tokens.scss +76 -0
- package/src/styles/element/common.scss +57 -0
- package/src/styles/element/config.scss +3 -0
- package/src/styles/element/dark.scss +39 -0
- package/src/styles/index.d.ts +1 -0
- package/src/styles/index.scss +5 -0
- package/src/styles/mixins/shadows.scss +15 -0
- package/src/styles/tokens.scss +83 -0
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<router-link :to="menu.path" class="anra-sidebar-item" active-class="anra-sidebar-item--active">
|
|
3
|
+
<span class="anra-sidebar-item__icon">
|
|
4
|
+
<FlyIcon :icon="menu.icon.icon" :type="menu.icon.type" />
|
|
5
|
+
</span>
|
|
6
|
+
|
|
7
|
+
<span class="anra-sidebar-item__label">{{ menu.label }}</span>
|
|
8
|
+
</router-link>
|
|
9
|
+
</template>
|
|
10
|
+
|
|
11
|
+
<script setup lang="ts">
|
|
12
|
+
import FlyIcon from '../../../general/fly-icon/FlyIcon.vue'
|
|
13
|
+
|
|
14
|
+
import type { T_FlyMiniSidebarItem } from './FlyMiniSidebar.types'
|
|
15
|
+
|
|
16
|
+
defineProps<{
|
|
17
|
+
menu: T_FlyMiniSidebarItem
|
|
18
|
+
}>()
|
|
19
|
+
</script>
|
|
20
|
+
|
|
21
|
+
<style lang="scss">
|
|
22
|
+
.anra-sidebar-item {
|
|
23
|
+
text-align: center;
|
|
24
|
+
padding-left: 0.5rem;
|
|
25
|
+
padding-right: 0.5rem;
|
|
26
|
+
padding-top: 0.25rem;
|
|
27
|
+
padding-bottom: 0.25rem;
|
|
28
|
+
transition: all 0.2s ease;
|
|
29
|
+
color: var(--anra-text-subtle);
|
|
30
|
+
display: flex;
|
|
31
|
+
flex-direction: column;
|
|
32
|
+
|
|
33
|
+
&--active {
|
|
34
|
+
background-color: var(--anra-primary);
|
|
35
|
+
color: var(--anra-text-on-primary);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
&__icon {
|
|
39
|
+
display: flex;
|
|
40
|
+
justify-content: center;
|
|
41
|
+
flex-shrink: 0;
|
|
42
|
+
|
|
43
|
+
svg {
|
|
44
|
+
width: 1em;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
&__label {
|
|
49
|
+
display: inline-block;
|
|
50
|
+
font-size: 0.75rem;
|
|
51
|
+
letter-spacing: 0;
|
|
52
|
+
line-height: 1.5;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
</style>
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
@use '../../../../styles/element/common.scss' as *;
|
|
2
|
+
@use 'element-plus/theme-chalk/src/menu.scss' as *;
|
|
3
|
+
@use 'element-plus/theme-chalk/src/sub-menu.scss' as *;
|
|
4
|
+
@use 'element-plus/theme-chalk/src/menu-item.scss' as *;
|
|
5
|
+
@use 'element-plus/theme-chalk/src/menu-item-group.scss' as *;
|
|
6
|
+
@use 'element-plus/theme-chalk/src/popper.scss' as *;
|
|
7
|
+
@use 'element-plus/theme-chalk/src/tooltip.scss' as *;
|
|
8
|
+
@use 'element-plus/theme-chalk/src/icon.scss' as *;
|
|
9
|
+
@use 'element-plus/theme-chalk/src/scrollbar.scss' as *;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import type { T_FlyIconProps } from '../../../general/fly-icon/FlyIcon.types'
|
|
2
|
+
|
|
3
|
+
export type T_FlySidebarBase = {
|
|
4
|
+
index: string
|
|
5
|
+
label?: string
|
|
6
|
+
icon?: T_FlyIconProps
|
|
7
|
+
disabled?: boolean
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export type T_FlySidebarItem = T_FlySidebarBase & {
|
|
11
|
+
type: 'item'
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export type T_FlySidebarSubMenu = T_FlySidebarBase & {
|
|
15
|
+
type: 'submenu'
|
|
16
|
+
children: T_FlySidebarNode[]
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export type T_FlySidebarGroup = {
|
|
20
|
+
index: string
|
|
21
|
+
type: 'group'
|
|
22
|
+
label?: string
|
|
23
|
+
children: T_FlySidebarItem[]
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export type T_FlySidebarNode = T_FlySidebarItem | T_FlySidebarSubMenu | T_FlySidebarGroup
|
|
27
|
+
|
|
28
|
+
export type T_FlySidebar = T_FlySidebarNode[]
|
|
29
|
+
|
|
30
|
+
export type T_FlySidebarProps = {
|
|
31
|
+
isCollapsed?: boolean
|
|
32
|
+
router?: boolean
|
|
33
|
+
defaultActive?: string
|
|
34
|
+
menu: T_FlySidebarNode[]
|
|
35
|
+
height?: string
|
|
36
|
+
}
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="fly-sidebar">
|
|
3
|
+
<el-scrollbar :height="height">
|
|
4
|
+
<el-menu
|
|
5
|
+
:default-active="defaultActive"
|
|
6
|
+
:collapse="isCollapsed"
|
|
7
|
+
:router="router"
|
|
8
|
+
popper-class="fly-sidebar-popper"
|
|
9
|
+
>
|
|
10
|
+
<FlySidebarNode v-for="node in menu" :key="node.index" :node="node" />
|
|
11
|
+
</el-menu>
|
|
12
|
+
</el-scrollbar>
|
|
13
|
+
|
|
14
|
+
<div class="fly_sidebar__collapse-trigger" role="button" @click="toggleCollapse">
|
|
15
|
+
<FlyIcon :icon="isCollapsed ? mdiChevronRight : mdiChevronLeft" type="mdi" />
|
|
16
|
+
</div>
|
|
17
|
+
</div>
|
|
18
|
+
</template>
|
|
19
|
+
|
|
20
|
+
<script lang="ts" setup>
|
|
21
|
+
import { ref } from 'vue'
|
|
22
|
+
|
|
23
|
+
import { ElMenu, ElScrollbar } from 'element-plus'
|
|
24
|
+
|
|
25
|
+
import { mdiChevronLeft, mdiChevronRight } from '@mdi/js'
|
|
26
|
+
|
|
27
|
+
import FlyIcon from '../../../general/fly-icon/FlyIcon.vue'
|
|
28
|
+
|
|
29
|
+
import './FlySidebar.element.scss'
|
|
30
|
+
import type { T_FlySidebarProps } from './FlySidebar.types'
|
|
31
|
+
import FlySidebarNode from './FlySidebarNode.vue'
|
|
32
|
+
|
|
33
|
+
const props = withDefaults(defineProps<T_FlySidebarProps>(), {
|
|
34
|
+
localStorageKey: 'fly-sidebar-collapsed',
|
|
35
|
+
router: true,
|
|
36
|
+
defaultActive: undefined
|
|
37
|
+
})
|
|
38
|
+
|
|
39
|
+
const isCollapsed = ref(props.isCollapsed ?? false)
|
|
40
|
+
|
|
41
|
+
function toggleCollapse() {
|
|
42
|
+
isCollapsed.value = !isCollapsed.value
|
|
43
|
+
}
|
|
44
|
+
</script>
|
|
45
|
+
|
|
46
|
+
<style lang="scss" scoped>
|
|
47
|
+
$radius: 9999px;
|
|
48
|
+
$height: 30px;
|
|
49
|
+
$trigger-height: 20px;
|
|
50
|
+
|
|
51
|
+
.fly-sidebar {
|
|
52
|
+
position: relative;
|
|
53
|
+
display: inline-block;
|
|
54
|
+
height: 100%;
|
|
55
|
+
background-color: var(--ep-menu-bg-color);
|
|
56
|
+
border-inline-end: 1px solid var(--anra-border-color);
|
|
57
|
+
|
|
58
|
+
:deep(.ep-menu) {
|
|
59
|
+
border-right: 0;
|
|
60
|
+
&.ep-menu--vertical {
|
|
61
|
+
--ep-menu-item-height: #{$height};
|
|
62
|
+
--ep-menu-sub-item-height: calc(var(--ep-menu-item-height) - 6px);
|
|
63
|
+
|
|
64
|
+
padding-inline-end: 1rem;
|
|
65
|
+
padding-top: calc(#{$trigger-height} + 10px);
|
|
66
|
+
padding-bottom: 1rem;
|
|
67
|
+
min-height: auto;
|
|
68
|
+
height: 100%;
|
|
69
|
+
|
|
70
|
+
&.ep-menu--collapse {
|
|
71
|
+
padding-inline-end: 0.3rem;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
&:not(.ep-menu--collapse) {
|
|
75
|
+
width: 200px;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.fly_sidebar__collapse-trigger {
|
|
82
|
+
position: absolute;
|
|
83
|
+
top: 5px;
|
|
84
|
+
inset-inline-end: 0;
|
|
85
|
+
width: calc(#{$trigger-height} + 5px);
|
|
86
|
+
height: $trigger-height;
|
|
87
|
+
display: flex;
|
|
88
|
+
align-items: center;
|
|
89
|
+
justify-content: center;
|
|
90
|
+
border-top: 1px solid var(--anra-border-color);
|
|
91
|
+
border-left: 1px solid var(--anra-border-color);
|
|
92
|
+
border-bottom: 1px solid var(--anra-border-color);
|
|
93
|
+
color: var(--dynamic-light);
|
|
94
|
+
border-start-start-radius: 5px;
|
|
95
|
+
border-end-start-radius: 5px;
|
|
96
|
+
cursor: pointer;
|
|
97
|
+
transition: all 0.2s ease;
|
|
98
|
+
|
|
99
|
+
&:hover {
|
|
100
|
+
background-color: var(--anra-primary);
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
</style>
|
|
104
|
+
|
|
105
|
+
<style lang="scss">
|
|
106
|
+
$radius: 9999px;
|
|
107
|
+
$height: 30px;
|
|
108
|
+
|
|
109
|
+
.fly-sidebar .ep-menu.ep-menu--vertical,
|
|
110
|
+
.fly-sidebar-popper {
|
|
111
|
+
--ep-menu-item-height: #{$height};
|
|
112
|
+
--ep-menu-sub-item-height: calc(var(--ep-menu-item-height) - 2px);
|
|
113
|
+
|
|
114
|
+
& > li:not(:last-child),
|
|
115
|
+
.ep-sub-menu .ep-menu .ep-menu-item {
|
|
116
|
+
margin-bottom: 4px;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.ep-sub-menu {
|
|
120
|
+
--ep-menu-item-height: #{$height};
|
|
121
|
+
|
|
122
|
+
.ep-menu {
|
|
123
|
+
padding-top: 0.25rem;
|
|
124
|
+
padding-bottom: 0.25rem;
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
.ep-sub-menu__title,
|
|
129
|
+
.ep-menu-item {
|
|
130
|
+
border-top-right-radius: $radius;
|
|
131
|
+
border-bottom-right-radius: $radius;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.ep-menu-item.is-active {
|
|
135
|
+
font-weight: 500;
|
|
136
|
+
background-color: var(--anra-primary);
|
|
137
|
+
color: var(--anra-text-on-primary);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.fly-sidebar {
|
|
142
|
+
--ep-menu-base-level-padding: 10px;
|
|
143
|
+
|
|
144
|
+
.ep-menu-item [class^='ep-icon'],
|
|
145
|
+
.ep-sub-menu__title [class^='ep-icon']:not(.ep-sub-menu__icon-arrow) {
|
|
146
|
+
margin-right: 10px;
|
|
147
|
+
font-size: 15px;
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
</style>
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<el-menu-item v-if="node.type === 'item'" :index="node.index" :disabled="node.disabled">
|
|
3
|
+
<template v-if="node.icon">
|
|
4
|
+
<i class="ep-icon">
|
|
5
|
+
<FlyIcon :icon="node.icon.icon" :type="node.icon.type" />
|
|
6
|
+
</i>
|
|
7
|
+
</template>
|
|
8
|
+
|
|
9
|
+
<template #title>
|
|
10
|
+
{{ node.label }}
|
|
11
|
+
</template>
|
|
12
|
+
</el-menu-item>
|
|
13
|
+
|
|
14
|
+
<el-sub-menu v-else-if="node.type === 'submenu'" :index="node.index">
|
|
15
|
+
<template #title>
|
|
16
|
+
<template v-if="node.icon">
|
|
17
|
+
<i class="ep-icon">
|
|
18
|
+
<FlyIcon :icon="node.icon.icon" :type="node.icon.type" />
|
|
19
|
+
</i>
|
|
20
|
+
</template>
|
|
21
|
+
|
|
22
|
+
<span>{{ node.label }}</span>
|
|
23
|
+
</template>
|
|
24
|
+
|
|
25
|
+
<FlySidebarNode v-for="child in node.children" :key="child.index" :node="child" />
|
|
26
|
+
</el-sub-menu>
|
|
27
|
+
|
|
28
|
+
<el-menu-item-group v-else>
|
|
29
|
+
<template v-if="node.label" #title>
|
|
30
|
+
<span>{{ node.label }}</span>
|
|
31
|
+
</template>
|
|
32
|
+
|
|
33
|
+
<FlySidebarNode v-for="child in node.children" :key="child.index" :node="child" />
|
|
34
|
+
</el-menu-item-group>
|
|
35
|
+
</template>
|
|
36
|
+
|
|
37
|
+
<script lang="ts" setup>
|
|
38
|
+
import { ElMenuItem, ElMenuItemGroup, ElSubMenu } from 'element-plus'
|
|
39
|
+
|
|
40
|
+
import FlyIcon from '../../../general/fly-icon/FlyIcon.vue'
|
|
41
|
+
|
|
42
|
+
import type { T_FlySidebarNode } from './FlySidebar.types'
|
|
43
|
+
|
|
44
|
+
defineProps<{
|
|
45
|
+
node: T_FlySidebarNode
|
|
46
|
+
}>()
|
|
47
|
+
</script>
|
package/src/index.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
// global colors
|
|
2
|
+
$anra-primary: #58baa8;
|
|
3
|
+
$anra-primary-dark: #15826e;
|
|
4
|
+
$anra-primary-accent: #57baa7;
|
|
5
|
+
$anra-black: #000000;
|
|
6
|
+
$anra-white: #ffffff;
|
|
7
|
+
|
|
8
|
+
// dark theme
|
|
9
|
+
$anra-dark-dynamic-light: #ffffff;
|
|
10
|
+
$anra-dark-dynamic-dark: #000000;
|
|
11
|
+
$anra-dark-default-text-color: #cfd3dc;
|
|
12
|
+
$anra-dark-bg-10: #29555a;
|
|
13
|
+
$anra-dark-bg-15: #274452;
|
|
14
|
+
$anra-dark-bg-15-accent: #253e4a;
|
|
15
|
+
$anra-dark-bg-15-accent-1: #395969;
|
|
16
|
+
$anra-dark-bg-20: #18323f;
|
|
17
|
+
$anra-dark-bg-20-rgb: 24, 50, 63;
|
|
18
|
+
$anra-dark-bg-20-subtitle: #c7c7c7;
|
|
19
|
+
$anra-dark-bg-25: #19282f;
|
|
20
|
+
$anra-dark-bg-blue-50: #293470;
|
|
21
|
+
$anra-dark-state-danger: #ff0e0e;
|
|
22
|
+
$anra-dark-state-error: #ff0e0e;
|
|
23
|
+
$anra-dark-state-error-lighter: #e76f6f;
|
|
24
|
+
$anra-dark-state-error-lighter-50: #ffa5a5;
|
|
25
|
+
$anra-dark-state-success: #068c53;
|
|
26
|
+
$anra-dark-state-info: #6a7174;
|
|
27
|
+
$anra-dark-state-info-lighter: #c0c9cd;
|
|
28
|
+
$anra-dark-state-warning: #ffc427;
|
|
29
|
+
$anra-dark-state-warning-50: #896a3d;
|
|
30
|
+
$anra-dark-text-placeholder: #b3b7bf;
|
|
31
|
+
$anra-dark-border-color: #4f626c;
|
|
32
|
+
$anra-dark-border-color-light: #616161;
|
|
33
|
+
$anra-dark-fill-color-light: #405661;
|
|
34
|
+
$anra-dark-mask-color: rgba(24, 50, 63, 0.79);
|
|
35
|
+
$anra-dark-scroll-shadow: #02020224;
|
|
36
|
+
$anra-dark-disabled-bg: #1f3845;
|
|
37
|
+
$anra-dark-form-item-error-color: #ffcac9;
|
|
38
|
+
$anra-dark-tag-info-bg: #344b56;
|
|
39
|
+
$anra-dark-form-input-border: #979797;
|
|
40
|
+
$anra-dark-text-on-primary: black;
|
|
41
|
+
$anra-dark-text-subtle: #99a1af;
|
|
42
|
+
|
|
43
|
+
// light theme
|
|
44
|
+
$anra-light-dynamic-light: #000000;
|
|
45
|
+
$anra-light-dynamic-dark: #ffffff;
|
|
46
|
+
$anra-light-default-text-color: #1a1f24;
|
|
47
|
+
$anra-light-bg-10: #f1f5f6;
|
|
48
|
+
$anra-light-bg-15: #ffffff;
|
|
49
|
+
$anra-light-bg-15-accent: #f2f2f2;
|
|
50
|
+
$anra-light-bg-15-accent-1: #d9e3e6;
|
|
51
|
+
$anra-light-bg-20: #f4f5f7;
|
|
52
|
+
$anra-light-bg-20-rgb: 244, 245, 247;
|
|
53
|
+
$anra-light-bg-20-subtitle: #4c5a66;
|
|
54
|
+
$anra-light-bg-25: #c7d3d8;
|
|
55
|
+
$anra-light-bg-blue-50: #dbe3f0;
|
|
56
|
+
$anra-light-state-danger: #d60000;
|
|
57
|
+
$anra-light-state-error: #d60000;
|
|
58
|
+
$anra-light-state-error-lighter: #ef7a7a;
|
|
59
|
+
$anra-light-state-error-lighter-50: #f7bcbc;
|
|
60
|
+
$anra-light-state-success: #068c53;
|
|
61
|
+
$anra-light-state-info: #5a6367;
|
|
62
|
+
$anra-light-state-info-lighter: #5b6164;
|
|
63
|
+
$anra-light-state-warning: #dca217;
|
|
64
|
+
$anra-light-state-warning-50: #b88c3c;
|
|
65
|
+
$anra-light-text-placeholder: #8a929a;
|
|
66
|
+
$anra-light-border-color: #cad4d9;
|
|
67
|
+
$anra-light-border-color-light: #e0e4e5;
|
|
68
|
+
$anra-light-fill-color-light: #f3f6f7;
|
|
69
|
+
$anra-light-mask-color: rgba(208, 218, 222, 0.6);
|
|
70
|
+
$anra-light-scroll-shadow: #00000012;
|
|
71
|
+
$anra-light-disabled-bg: #e6ecef;
|
|
72
|
+
$anra-light-form-item-error-color: #d68080;
|
|
73
|
+
$anra-light-tag-info-bg: #e4ecef;
|
|
74
|
+
$anra-light-form-input-border: #969696;
|
|
75
|
+
$anra-light-text-on-primary: black;
|
|
76
|
+
$anra-light-text-subtle: #000000;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
@use '../scss-tokens' as *;
|
|
2
|
+
|
|
3
|
+
@use './config.scss' as *;
|
|
4
|
+
@forward 'element-plus/theme-chalk/src/common/var.scss' with (
|
|
5
|
+
$colors: (
|
|
6
|
+
'primary': (
|
|
7
|
+
'base': $anra-primary-dark
|
|
8
|
+
)
|
|
9
|
+
),
|
|
10
|
+
$border-color: (
|
|
11
|
+
'': $anra-light-border-color
|
|
12
|
+
),
|
|
13
|
+
$fill-color: (
|
|
14
|
+
'light': $anra-light-fill-color-light
|
|
15
|
+
),
|
|
16
|
+
$date-editor: (
|
|
17
|
+
'width': 100%
|
|
18
|
+
),
|
|
19
|
+
$select-dropdown: (
|
|
20
|
+
'border': 1px solid var(--anra-border-color)
|
|
21
|
+
),
|
|
22
|
+
$datepicker: (
|
|
23
|
+
'inner-border-color': var(--anra-border-color)
|
|
24
|
+
),
|
|
25
|
+
$collapse: (
|
|
26
|
+
'border-color': var(--anra-border-color),
|
|
27
|
+
'header-height': auto
|
|
28
|
+
),
|
|
29
|
+
$table: (
|
|
30
|
+
'header-bg-color': transparent,
|
|
31
|
+
'tr-bg-color': transparent,
|
|
32
|
+
'border-color': var(--dark-15-accent-1)
|
|
33
|
+
),
|
|
34
|
+
$checkbox: (
|
|
35
|
+
'checked-icon-color': var(--anra-black),
|
|
36
|
+
'bg-color': var(--anra-bg-20)
|
|
37
|
+
),
|
|
38
|
+
$radio-button: (
|
|
39
|
+
'checked-text-color': var(--anra-black)
|
|
40
|
+
),
|
|
41
|
+
$disabled: (
|
|
42
|
+
'bg-color': var(--anra-disabled-bg)
|
|
43
|
+
),
|
|
44
|
+
$loading: (
|
|
45
|
+
'fullscreen-spinner-size': 30px
|
|
46
|
+
),
|
|
47
|
+
$dialog: (
|
|
48
|
+
'bg-color': var(--anra-bg-15)
|
|
49
|
+
),
|
|
50
|
+
$input: (
|
|
51
|
+
'bg-color': var(--anra-bg-20),
|
|
52
|
+
'border-color': var(--anra-form-input-border)
|
|
53
|
+
),
|
|
54
|
+
$menu: (
|
|
55
|
+
'bg-color': var(--anra-bg-20)
|
|
56
|
+
)
|
|
57
|
+
);
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
@use './config.scss' as *;
|
|
2
|
+
@use '../scss-tokens' as *;
|
|
3
|
+
|
|
4
|
+
@forward 'element-plus/theme-chalk/src/dark/var.scss' with (
|
|
5
|
+
$colors: (
|
|
6
|
+
'primary': (
|
|
7
|
+
'base': $anra-primary
|
|
8
|
+
),
|
|
9
|
+
'danger': (
|
|
10
|
+
'base': $anra-dark-state-danger
|
|
11
|
+
),
|
|
12
|
+
'error': (
|
|
13
|
+
'base': $anra-dark-state-error
|
|
14
|
+
),
|
|
15
|
+
'info': (
|
|
16
|
+
'base': $anra-dark-state-info
|
|
17
|
+
),
|
|
18
|
+
'success': (
|
|
19
|
+
'base': $anra-dark-state-success
|
|
20
|
+
)
|
|
21
|
+
),
|
|
22
|
+
$bg-color: (
|
|
23
|
+
'': $anra-dark-bg-20,
|
|
24
|
+
'overlay': $anra-dark-bg-20
|
|
25
|
+
),
|
|
26
|
+
$border-color: (
|
|
27
|
+
'': $anra-dark-border-color,
|
|
28
|
+
'light': $anra-dark-border-color-light
|
|
29
|
+
),
|
|
30
|
+
$fill-color: (
|
|
31
|
+
'light': $anra-dark-fill-color-light
|
|
32
|
+
),
|
|
33
|
+
$text-color: (
|
|
34
|
+
'placeholder': $anra-dark-text-placeholder
|
|
35
|
+
),
|
|
36
|
+
$mask-color: (
|
|
37
|
+
'': $anra-dark-mask-color
|
|
38
|
+
)
|
|
39
|
+
);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
// Type declaration for side-effect style import
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
@mixin shadow {
|
|
2
|
+
box-shadow:
|
|
3
|
+
0 0 #0000,
|
|
4
|
+
0 0 #0000,
|
|
5
|
+
0 1px 3px 0 rgb(0 0 0 / 0.1),
|
|
6
|
+
0 1px 2px -1px rgb(0 0 0 / 0.1);
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
@mixin shadow-lg {
|
|
10
|
+
box-shadow:
|
|
11
|
+
0 0 #0000,
|
|
12
|
+
0 0 #0000,
|
|
13
|
+
0 10px 15px -3px rgb(0 0 0 / 0.1),
|
|
14
|
+
0 4px 6px -4px rgb(0 0 0 / 0.1);
|
|
15
|
+
}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
@use './scss-tokens' as vars;
|
|
2
|
+
|
|
3
|
+
// Apply SCSS variables
|
|
4
|
+
:root {
|
|
5
|
+
--anra-primary: #{vars.$anra-primary};
|
|
6
|
+
--anra-primary-accent: #{vars.$anra-primary-accent};
|
|
7
|
+
--anra-black: #{vars.$anra-black};
|
|
8
|
+
--anra-white: #{vars.$anra-white};
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
html.dark {
|
|
12
|
+
--anra-primary-theme: #{vars.$anra-primary};
|
|
13
|
+
--dynamic-light: #{vars.$anra-dark-dynamic-light};
|
|
14
|
+
--dynamic-dark: #{vars.$anra-dark-dynamic-dark};
|
|
15
|
+
--default-text-color: #{vars.$anra-dark-default-text-color};
|
|
16
|
+
--anra-bg-10: #{vars.$anra-dark-bg-10};
|
|
17
|
+
--anra-bg-15: #{vars.$anra-dark-bg-15};
|
|
18
|
+
--anra-bg-15-accent: #{vars.$anra-dark-bg-15-accent};
|
|
19
|
+
--anra-bg-15-accent-1: #{vars.$anra-dark-bg-15-accent-1};
|
|
20
|
+
--anra-bg-20: #{vars.$anra-dark-bg-20};
|
|
21
|
+
--anra-bg-20-rgb: #{vars.$anra-dark-bg-20-rgb};
|
|
22
|
+
--anra-bg-20-subtitle: #{vars.$anra-dark-bg-20-subtitle};
|
|
23
|
+
--anra-bg-25: #{vars.$anra-dark-bg-25};
|
|
24
|
+
--anra-bg-blue-50: #{vars.$anra-dark-bg-blue-50};
|
|
25
|
+
--anra-state-danger: #{vars.$anra-dark-state-danger};
|
|
26
|
+
--anra-state-error: #{vars.$anra-dark-state-error};
|
|
27
|
+
--anra-state-error-lighter: #{vars.$anra-dark-state-error-lighter};
|
|
28
|
+
--anra-state-error-lighter-50: #{vars.$anra-dark-state-error-lighter-50};
|
|
29
|
+
--anra-state-success: #{vars.$anra-dark-state-success};
|
|
30
|
+
--anra-state-info: #{vars.$anra-dark-state-info};
|
|
31
|
+
--anra-state-info-lighter: #{vars.$anra-dark-state-info-lighter};
|
|
32
|
+
--anra-state-warning: #{vars.$anra-dark-state-warning};
|
|
33
|
+
--anra-state-warning-50: #{vars.$anra-dark-state-warning-50};
|
|
34
|
+
--anra-text-placeholder: #{vars.$anra-dark-text-placeholder};
|
|
35
|
+
--anra-border-color: #{vars.$anra-dark-border-color};
|
|
36
|
+
--anra-border-color-light: #{vars.$anra-dark-border-color-light};
|
|
37
|
+
--anra-fill-color-light: #{vars.$anra-dark-fill-color-light};
|
|
38
|
+
--anra-mask-color: #{vars.$anra-dark-mask-color};
|
|
39
|
+
--anra-scroll-shadow: #{vars.$anra-dark-scroll-shadow};
|
|
40
|
+
--anra-disabled-bg: #{vars.$anra-dark-disabled-bg};
|
|
41
|
+
--anra-form-item-error-color: #{vars.$anra-dark-form-item-error-color};
|
|
42
|
+
--anra-info-bg: #{vars.$anra-dark-tag-info-bg};
|
|
43
|
+
--anra-form-input-border: #{vars.$anra-dark-form-input-border};
|
|
44
|
+
--anra-text-on-primary: #{vars.$anra-dark-text-on-primary};
|
|
45
|
+
--anra-text-subtle: #{vars.$anra-dark-text-subtle};
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
html.light {
|
|
49
|
+
--anra-primary-theme: #{vars.$anra-primary-dark};
|
|
50
|
+
--dynamic-light: #{vars.$anra-light-dynamic-light};
|
|
51
|
+
--dynamic-dark: #{vars.$anra-light-dynamic-dark};
|
|
52
|
+
--default-text-color: #{vars.$anra-light-default-text-color};
|
|
53
|
+
--anra-bg-10: #{vars.$anra-light-bg-10};
|
|
54
|
+
--anra-bg-15: #{vars.$anra-light-bg-15};
|
|
55
|
+
--anra-bg-15-accent: #{vars.$anra-light-bg-15-accent};
|
|
56
|
+
--anra-bg-15-accent-1: #{vars.$anra-light-bg-15-accent-1};
|
|
57
|
+
--anra-bg-20: #{vars.$anra-light-bg-20};
|
|
58
|
+
--anra-bg-20-rgb: #{vars.$anra-light-bg-20-rgb};
|
|
59
|
+
--anra-bg-20-subtitle: #{vars.$anra-light-bg-20-subtitle};
|
|
60
|
+
--anra-bg-25: #{vars.$anra-light-bg-25};
|
|
61
|
+
--anra-bg-blue-50: #{vars.$anra-light-bg-blue-50};
|
|
62
|
+
--anra-state-danger: #{vars.$anra-light-state-danger};
|
|
63
|
+
--anra-state-error: #{vars.$anra-light-state-error};
|
|
64
|
+
--anra-state-error-lighter: #{vars.$anra-light-state-error-lighter};
|
|
65
|
+
--anra-state-error-lighter-50: #{vars.$anra-light-state-error-lighter-50};
|
|
66
|
+
--anra-state-success: #{vars.$anra-light-state-success};
|
|
67
|
+
--anra-state-info: #{vars.$anra-light-state-info};
|
|
68
|
+
--anra-state-info-lighter: #{vars.$anra-light-state-info-lighter};
|
|
69
|
+
--anra-state-warning: #{vars.$anra-light-state-warning};
|
|
70
|
+
--anra-state-warning-50: #{vars.$anra-light-state-warning-50};
|
|
71
|
+
--anra-text-placeholder: #{vars.$anra-light-text-placeholder};
|
|
72
|
+
--anra-border-color: #{vars.$anra-light-border-color};
|
|
73
|
+
--anra-border-color-light: #{vars.$anra-light-border-color-light};
|
|
74
|
+
--anra-fill-color-light: #{vars.$anra-light-fill-color-light};
|
|
75
|
+
--anra-mask-color: #{vars.$anra-light-mask-color};
|
|
76
|
+
--anra-scroll-shadow: #{vars.$anra-light-scroll-shadow};
|
|
77
|
+
--anra-disabled-bg: #{vars.$anra-light-disabled-bg};
|
|
78
|
+
--anra-form-item-error-color: #{vars.$anra-light-form-item-error-color};
|
|
79
|
+
--anra-info-bg: #{vars.$anra-light-tag-info-bg};
|
|
80
|
+
--anra-form-input-border: #{vars.$anra-light-form-input-border};
|
|
81
|
+
--anra-text-on-primary: #{vars.$anra-light-text-on-primary};
|
|
82
|
+
--anra-text-subtle: #{vars.$anra-light-text-subtle};
|
|
83
|
+
}
|