@globalbrain/sefirot 2.1.2 → 2.1.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/lib/components/SDropdownSectionFilter.vue +3 -3
- package/lib/components/STable.vue +1 -1
- package/lib/components/STableCellAvatars.vue +4 -0
- package/lib/components/STableCellPill.vue +2 -2
- package/lib/components/STableCellText.vue +2 -0
- package/lib/components/STableColumn.vue +6 -2
- package/lib/components/STableFooter.vue +2 -2
- package/lib/composables/Dropdown.ts +1 -1
- package/package.json +22 -22
|
@@ -11,7 +11,7 @@ import SIcon from './SIcon.vue'
|
|
|
11
11
|
const props = defineProps<{
|
|
12
12
|
search?: boolean
|
|
13
13
|
selected: MaybeRef<DropdownSectionFilterSelectedValue>
|
|
14
|
-
options: DropdownSectionFilterOption[]
|
|
14
|
+
options: MaybeRef<DropdownSectionFilterOption[]>
|
|
15
15
|
onClick?(value: string | number | boolean): void
|
|
16
16
|
}>()
|
|
17
17
|
|
|
@@ -19,12 +19,12 @@ const input = ref<HTMLElement | null>(null)
|
|
|
19
19
|
const query = ref('')
|
|
20
20
|
|
|
21
21
|
const fuse = computed(() => {
|
|
22
|
-
return new Fuse(props.options, { keys: ['label'] })
|
|
22
|
+
return new Fuse(unref(props.options), { keys: ['label'] })
|
|
23
23
|
})
|
|
24
24
|
|
|
25
25
|
const filteredOptions = computed(() => {
|
|
26
26
|
return !props.search || !query.value
|
|
27
|
-
? props.options
|
|
27
|
+
? unref(props.options)
|
|
28
28
|
: fuse.value.search(query.value).map((r) => r.item)
|
|
29
29
|
})
|
|
30
30
|
|
|
@@ -192,7 +192,7 @@ function updateColWidth(key: string, value: string) {
|
|
|
192
192
|
&.head {
|
|
193
193
|
position: var(--table-head-position, static);
|
|
194
194
|
top: var(--table-head-top, auto);
|
|
195
|
-
z-index:
|
|
195
|
+
z-index: 100;
|
|
196
196
|
background-color: var(--bg-elv);
|
|
197
197
|
|
|
198
198
|
&::-webkit-scrollbar {
|
|
@@ -32,13 +32,13 @@ const _color = computed(() => {
|
|
|
32
32
|
|
|
33
33
|
<template>
|
|
34
34
|
<div class="STableCellPill" :class="[_color ?? 'mute']">
|
|
35
|
-
<div class="value">{{ _value }}</div>
|
|
35
|
+
<div v-if="_value" class="value">{{ _value }}</div>
|
|
36
36
|
</div>
|
|
37
37
|
</template>
|
|
38
38
|
|
|
39
39
|
<style scoped lang="postcss">
|
|
40
40
|
.STableCellPill {
|
|
41
|
-
padding:
|
|
41
|
+
padding: 7px 16px 9px;
|
|
42
42
|
min-height: 40px;
|
|
43
43
|
}
|
|
44
44
|
|
|
@@ -44,7 +44,7 @@ const active = computed(() => {
|
|
|
44
44
|
return false
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
return item.options.some((option) => {
|
|
47
|
+
return unref(item.options).some((option) => {
|
|
48
48
|
return selected.includes(option.value)
|
|
49
49
|
})
|
|
50
50
|
})
|
|
@@ -93,7 +93,11 @@ async function adjustDialogPosition() {
|
|
|
93
93
|
const position = (window.innerWidth - rect.right) > dialogWidth ? 'right' : 'left'
|
|
94
94
|
|
|
95
95
|
top.value = `${rect.top + rect.height - 8}px`
|
|
96
|
-
left.value =
|
|
96
|
+
left.value =
|
|
97
|
+
Math.max(
|
|
98
|
+
16,
|
|
99
|
+
position === 'right' ? rect.left - 4 : rect.right - dialogWidth - 4
|
|
100
|
+
) + 'px'
|
|
97
101
|
}
|
|
98
102
|
|
|
99
103
|
function startDialogPositionListener() {
|
|
@@ -43,10 +43,10 @@ const hasNext = computed(() => {
|
|
|
43
43
|
<p class="info">{{ format(from) }}–{{ format(to) }} of {{ format(_total) }}</p>
|
|
44
44
|
|
|
45
45
|
<div class="actions">
|
|
46
|
-
<button class="button prev" :class="{ active: hasPrev }" @click="onPrev">
|
|
46
|
+
<button class="button prev" :class="{ active: hasPrev }" @click="() => hasPrev && onPrev?.()">
|
|
47
47
|
<SIcon :icon="IconCaretLeft" class="icon" />
|
|
48
48
|
</button>
|
|
49
|
-
<button class="button next" :class="{ active: hasNext }" @click="onNext">
|
|
49
|
+
<button class="button next" :class="{ active: hasNext }" @click="() => hasNext && onNext?.()">
|
|
50
50
|
<SIcon :icon="IconCaretRight" class="icon" />
|
|
51
51
|
</button>
|
|
52
52
|
</div>
|
|
@@ -24,7 +24,7 @@ export interface DropdownSectionFilter extends DropdownSectionBase {
|
|
|
24
24
|
type: 'filter'
|
|
25
25
|
search?: boolean
|
|
26
26
|
selected: MaybeRef<DropdownSectionFilterSelectedValue>
|
|
27
|
-
options: DropdownSectionFilterOption[]
|
|
27
|
+
options: MaybeRef<DropdownSectionFilterOption[]>
|
|
28
28
|
onClick?(value: string | number | boolean): void
|
|
29
29
|
}
|
|
30
30
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@globalbrain/sefirot",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.4",
|
|
4
4
|
"description": "Vue Components for Global Brain Design System.",
|
|
5
5
|
"files": [
|
|
6
6
|
"lib"
|
|
@@ -23,24 +23,24 @@
|
|
|
23
23
|
"@iconify-icons/ph": "^1.2.2",
|
|
24
24
|
"@iconify/vue": "^4.0.0",
|
|
25
25
|
"@types/body-scroll-lock": "^3.1.0",
|
|
26
|
-
"@types/markdown-it": "^12.2.3",
|
|
27
26
|
"@types/lodash-es": "^4.17.6",
|
|
28
|
-
"@
|
|
29
|
-
"@vuelidate/
|
|
30
|
-
"@
|
|
27
|
+
"@types/markdown-it": "^12.2.3",
|
|
28
|
+
"@vuelidate/core": "^2.0.0",
|
|
29
|
+
"@vuelidate/validators": "^2.0.0",
|
|
30
|
+
"@vueuse/core": "^9.3.0",
|
|
31
31
|
"body-scroll-lock": "^4.0.0-beta.0",
|
|
32
|
-
"dayjs": "^1.11.
|
|
33
|
-
"fuse.js": "^6.
|
|
32
|
+
"dayjs": "^1.11.5",
|
|
33
|
+
"fuse.js": "^6.6.2",
|
|
34
34
|
"lodash-es": "^4.17.21",
|
|
35
35
|
"markdown-it": "^13.0.1",
|
|
36
36
|
"normalize.css": "^8.0.1",
|
|
37
37
|
"pinia": "^2.0.22",
|
|
38
|
-
"postcss": "^8.4.
|
|
38
|
+
"postcss": "^8.4.17",
|
|
39
39
|
"postcss-nested": "^5.0.6",
|
|
40
|
-
"typescript": "^4.
|
|
40
|
+
"typescript": "^4.8.4",
|
|
41
41
|
"v-calendar": "^3.0.0-alpha.8",
|
|
42
|
-
"vue": "^3.2.
|
|
43
|
-
"vue-router": "^4.
|
|
42
|
+
"vue": "^3.2.40",
|
|
43
|
+
"vue-router": "^4.1.5"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
46
|
"@histoire/plugin-vue": "^0.10.7",
|
|
@@ -49,15 +49,15 @@
|
|
|
49
49
|
"@types/body-scroll-lock": "^3.1.0",
|
|
50
50
|
"@types/lodash-es": "^4.17.6",
|
|
51
51
|
"@types/markdown-it": "^12.2.3",
|
|
52
|
-
"@types/node": "^18.
|
|
52
|
+
"@types/node": "^18.8.0",
|
|
53
53
|
"@typescript-eslint/eslint-plugin": "^5.38.0",
|
|
54
54
|
"@typescript-eslint/parser": "^5.38.0",
|
|
55
|
-
"@vitejs/plugin-vue": "^3.1.
|
|
55
|
+
"@vitejs/plugin-vue": "^3.1.2",
|
|
56
56
|
"@vitest/coverage-c8": "^0.23.4",
|
|
57
|
-
"@vue/test-utils": "^2.0
|
|
58
|
-
"@vuelidate/core": "^2.0.0
|
|
59
|
-
"@vuelidate/validators": "^2.0.0
|
|
60
|
-
"@vueuse/core": "^9.
|
|
57
|
+
"@vue/test-utils": "^2.1.0",
|
|
58
|
+
"@vuelidate/core": "^2.0.0",
|
|
59
|
+
"@vuelidate/validators": "^2.0.0",
|
|
60
|
+
"@vueuse/core": "^9.3.0",
|
|
61
61
|
"body-scroll-lock": "^4.0.0-beta.0",
|
|
62
62
|
"chalk": "^4.1.2",
|
|
63
63
|
"conventional-changelog-cli": "^2.2.2",
|
|
@@ -74,15 +74,15 @@
|
|
|
74
74
|
"markdown-it": "^13.0.1",
|
|
75
75
|
"normalize.css": "^8.0.1",
|
|
76
76
|
"pinia": "^2.0.22",
|
|
77
|
-
"postcss": "^8.4.
|
|
77
|
+
"postcss": "^8.4.17",
|
|
78
78
|
"postcss-nested": "^5.0.6",
|
|
79
79
|
"semver": "^7.3.7",
|
|
80
|
-
"typescript": "^4.8.
|
|
80
|
+
"typescript": "^4.8.4",
|
|
81
81
|
"v-calendar": "3.0.0-alpha.8",
|
|
82
|
-
"vite": "^3.1.
|
|
83
|
-
"vitepress": "1.0.0-alpha.
|
|
82
|
+
"vite": "^3.1.4",
|
|
83
|
+
"vitepress": "1.0.0-alpha.19",
|
|
84
84
|
"vitest": "^0.23.4",
|
|
85
|
-
"vue": "^3.2.
|
|
85
|
+
"vue": "^3.2.40",
|
|
86
86
|
"vue-router": "^4.1.5",
|
|
87
87
|
"vue-tsc": "^0.40.13"
|
|
88
88
|
},
|