@dolanske/vui 1.1.1 → 1.1.3
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/LICENSE +1 -1
- package/dist/components/Grid/Grid.vue.d.ts +1 -0
- package/dist/vui.css +1 -1
- package/dist/vui.js +943 -941
- package/package.json +1 -1
- package/src/components/Card/card.scss +2 -0
- package/src/components/Divider/Divider.vue +1 -7
- package/src/components/Divider/divider.scss +9 -7
- package/src/components/Grid/Grid.vue +5 -0
- package/src/components/Select/Select.vue +0 -1
- package/src/components/Select/select.scss +4 -0
- package/src/components/Spinner/spinner.scss +1 -1
- package/src/examples/ExampleTabs.vue +17 -0
- package/src/style/layout.scss +3 -0
- package/src/vite-env.d.ts +1 -1
package/package.json
CHANGED
|
@@ -19,7 +19,6 @@ const {
|
|
|
19
19
|
|
|
20
20
|
const h = computed(() => formatUnitValue(size))
|
|
21
21
|
const w = computed(() => vertical ? h.value : 'initial')
|
|
22
|
-
const bW = computed(() => `${thickness}px`)
|
|
23
22
|
const m = computed(() => formatUnitValue(margin))
|
|
24
23
|
</script>
|
|
25
24
|
|
|
@@ -31,14 +30,9 @@ const m = computed(() => formatUnitValue(margin))
|
|
|
31
30
|
height: h,
|
|
32
31
|
}"
|
|
33
32
|
>
|
|
33
|
+
<hr :style="{ [vertical ? 'borderRightWidth' : 'borderBottomWidth']: `${thickness}px` }">
|
|
34
34
|
<div v-if="$slots.default" class="vui-divider-slot">
|
|
35
35
|
<slot />
|
|
36
36
|
</div>
|
|
37
37
|
</div>
|
|
38
38
|
</template>
|
|
39
|
-
|
|
40
|
-
<style lang="scss" scoped>
|
|
41
|
-
.vui-divider:before {
|
|
42
|
-
border-width: v-bind(bW);
|
|
43
|
-
}
|
|
44
|
-
</style>
|
|
@@ -6,20 +6,22 @@
|
|
|
6
6
|
height: 32px;
|
|
7
7
|
width: 100%;
|
|
8
8
|
|
|
9
|
-
&.vertical
|
|
10
|
-
border-bottom: none;
|
|
11
|
-
border-right: 1px solid var(--color-border);
|
|
9
|
+
&.vertical hr {
|
|
12
10
|
transform: translateX(-50%);
|
|
13
11
|
width: 1px;
|
|
14
12
|
height: 100%;
|
|
13
|
+
border-right-color: var(--color-border);
|
|
14
|
+
border-right-style: solid;
|
|
15
15
|
}
|
|
16
16
|
|
|
17
|
-
|
|
18
|
-
content: '';
|
|
17
|
+
hr {
|
|
19
18
|
display: block;
|
|
20
19
|
transform: translateY(-50%);
|
|
21
20
|
width: 100%;
|
|
22
|
-
|
|
21
|
+
height: 1px;
|
|
22
|
+
border: none;
|
|
23
|
+
border-bottom-color: var(--color-border);
|
|
24
|
+
border-bottom-style: solid;
|
|
23
25
|
}
|
|
24
26
|
|
|
25
27
|
.vui-divider-slot {
|
|
@@ -28,7 +30,7 @@
|
|
|
28
30
|
left: 50%;
|
|
29
31
|
transform: translate(-50%, -50%);
|
|
30
32
|
|
|
31
|
-
& > *:first-child {
|
|
33
|
+
& > *:first-child {
|
|
32
34
|
outline: 3px solid var(--color-bg);
|
|
33
35
|
}
|
|
34
36
|
}
|
|
@@ -19,6 +19,8 @@ interface Props {
|
|
|
19
19
|
yStart?: boolean
|
|
20
20
|
yEnd?: boolean
|
|
21
21
|
yBaseline?: boolean
|
|
22
|
+
|
|
23
|
+
expand?: boolean
|
|
22
24
|
}
|
|
23
25
|
|
|
24
26
|
const props = withDefaults(defineProps<Props>(), {
|
|
@@ -62,6 +64,8 @@ const aA = computed(() => {
|
|
|
62
64
|
})
|
|
63
65
|
|
|
64
66
|
const aD = computed(() => props.inline ? 'inline-grid' : 'grid')
|
|
67
|
+
|
|
68
|
+
const aH = computed(() => props.expand ? '100%' : 'auto')
|
|
65
69
|
</script>
|
|
66
70
|
|
|
67
71
|
<template>
|
|
@@ -72,6 +76,7 @@ const aD = computed(() => props.inline ? 'inline-grid' : 'grid')
|
|
|
72
76
|
gridTemplateColumns: aTC,
|
|
73
77
|
gridTemplateRows: aTR,
|
|
74
78
|
alignItems: aA,
|
|
79
|
+
width: aH,
|
|
75
80
|
}"
|
|
76
81
|
>
|
|
77
82
|
<slot />
|
|
@@ -4,8 +4,13 @@ import { ref } from 'vue'
|
|
|
4
4
|
import Button from '../components/Button/Button.vue'
|
|
5
5
|
import Tab from '../components/Tabs/Tab.vue'
|
|
6
6
|
import Tabs from '../components/Tabs/Tabs.vue'
|
|
7
|
+
// import Flex from '../components/Flex/Flex.vue'
|
|
7
8
|
|
|
8
9
|
const activeTab = ref('Home')
|
|
10
|
+
|
|
11
|
+
// Dynamic test
|
|
12
|
+
// const dynamicTabs = ref(['First', 'Second', "Third"])
|
|
13
|
+
// const activeDynamic = ref(dynamicTabs.value[0])
|
|
9
14
|
</script>
|
|
10
15
|
|
|
11
16
|
<template>
|
|
@@ -113,6 +118,18 @@ const activeTab = ref('Home')
|
|
|
113
118
|
</Tabs>
|
|
114
119
|
</td>
|
|
115
120
|
</tr>
|
|
121
|
+
<!-- <tr>
|
|
122
|
+
<th>Dynamic</th>
|
|
123
|
+
<td>
|
|
124
|
+
<Flex>
|
|
125
|
+
<Button @click="dynamicTabs.push(`Tab ${dynamicTabs.length}`)">Add</Button>
|
|
126
|
+
<Button @click="dynamicTabs.shift()">Remove</Button>
|
|
127
|
+
</Flex>
|
|
128
|
+
<Tabs v-model="dynamicTabs">
|
|
129
|
+
<Tab v-for="tab in dynamicTabs" />
|
|
130
|
+
</Tabs>
|
|
131
|
+
</td>
|
|
132
|
+
</tr> -->
|
|
116
133
|
</tbody>
|
|
117
134
|
</table>
|
|
118
135
|
</div>
|
package/src/style/layout.scss
CHANGED
package/src/vite-env.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
/// <reference types="vite/client" />
|
|
1
|
+
/// <reference types="vite/client" />
|