@bagelink/vue 1.4.155 → 1.4.161
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/components/ListItem.vue.d.ts +2 -2
- package/dist/components/ListItem.vue.d.ts.map +1 -1
- package/dist/components/Loading.vue.d.ts +3 -2
- package/dist/components/Loading.vue.d.ts.map +1 -1
- package/dist/components/Modal.vue.d.ts.map +1 -1
- package/dist/components/calendar/CalendarPopover.vue.d.ts +2 -0
- package/dist/components/calendar/CalendarPopover.vue.d.ts.map +1 -1
- package/dist/components/calendar/CalendarTypes.d.ts +2 -0
- package/dist/components/calendar/CalendarTypes.d.ts.map +1 -1
- package/dist/components/calendar/views/WeekView.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/ColorInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/NumberInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/RadioGroup.vue.d.ts +6 -0
- package/dist/components/form/inputs/RadioGroup.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/RichText/index.vue.d.ts +1 -0
- package/dist/components/form/inputs/RichText/index.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/SelectInput.vue.d.ts.map +1 -1
- package/dist/components/layout/AppSidebar.vue.d.ts +1 -1
- package/dist/components/layout/AppSidebar.vue.d.ts.map +1 -1
- package/dist/components/layout/TabsNav.vue.d.ts.map +1 -1
- package/dist/components/lightbox/Lightbox.vue.d.ts.map +1 -1
- package/dist/index.cjs +21 -21
- package/dist/index.mjs +21 -21
- package/dist/style.css +1 -1
- package/dist/types/BtnOptions.d.ts +3 -0
- package/dist/types/BtnOptions.d.ts.map +1 -1
- package/dist/utils/sizeParsing.d.ts +3 -0
- package/dist/utils/sizeParsing.d.ts.map +1 -0
- package/package.json +1 -1
- package/src/components/ListItem.vue +42 -35
- package/src/components/Loading.vue +73 -25
- package/src/components/Modal.vue +5 -1
- package/src/components/calendar/CalendarPopover.vue +20 -24
- package/src/components/calendar/CalendarTypes.ts +2 -0
- package/src/components/calendar/Index.vue +1 -1
- package/src/components/calendar/views/WeekView.vue +7 -1
- package/src/components/form/inputs/ColorInput.vue +5 -5
- package/src/components/form/inputs/NumberInput.vue +2 -2
- package/src/components/form/inputs/RadioGroup.vue +22 -6
- package/src/components/form/inputs/RichText/index.vue +4 -2
- package/src/components/form/inputs/SelectInput.vue +2 -2
- package/src/components/layout/AppSidebar.vue +1 -1
- package/src/components/layout/TabsNav.vue +24 -22
- package/src/components/lightbox/Lightbox.vue +1 -0
- package/src/styles/appearance.css +10 -1
- package/src/styles/colors.css +502 -3
- package/src/styles/inputs.css +12 -4
- package/src/styles/layout.css +2 -1
- package/src/styles/mobileColors.css +4167 -3739
- package/src/styles/theme.css +1 -0
- package/src/types/BtnOptions.ts +4 -0
- package/src/utils/sizeParsing.ts +26 -0
|
@@ -35,9 +35,15 @@ function updateIndicator() {
|
|
|
35
35
|
if (!tabsWrap.value) return
|
|
36
36
|
const activeTab = tabs.value.find(tab => tab.classList.contains('active'))
|
|
37
37
|
if (activeTab) {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
38
|
+
// Wait a bit more to ensure CSS is fully loaded and elements are properly sized
|
|
39
|
+
setTimeout(() => {
|
|
40
|
+
const { offsetLeft, offsetWidth } = activeTab
|
|
41
|
+
if (offsetLeft >= 0 && offsetWidth > 0) { // Ensure valid measurements
|
|
42
|
+
tabsWrap.value?.style.setProperty('--indicator-left', `${offsetLeft}px`)
|
|
43
|
+
tabsWrap.value?.style.setProperty('--indicator-width', `${offsetWidth}px`)
|
|
44
|
+
tabsWrap.value?.style.setProperty('--indicator-opacity', '1')
|
|
45
|
+
}
|
|
46
|
+
}, 10)
|
|
41
47
|
}
|
|
42
48
|
})
|
|
43
49
|
}
|
|
@@ -69,7 +75,12 @@ watch(
|
|
|
69
75
|
|
|
70
76
|
onMounted(() => {
|
|
71
77
|
tabs.value = Array.from(tabsWrap.value?.querySelectorAll('.bgl_tab') || [])
|
|
72
|
-
|
|
78
|
+
|
|
79
|
+
// Wait for the next frame to ensure all CSS and layout calculations are done
|
|
80
|
+
requestAnimationFrame(() => {
|
|
81
|
+
updateIndicator()
|
|
82
|
+
})
|
|
83
|
+
|
|
73
84
|
window.addEventListener('resize', updateIndicator)
|
|
74
85
|
})
|
|
75
86
|
|
|
@@ -86,24 +97,14 @@ onBeforeUnmount(() => {
|
|
|
86
97
|
</script>
|
|
87
98
|
|
|
88
99
|
<template>
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
v-for="(tab, i) in props.tabs"
|
|
96
|
-
:key="i"
|
|
97
|
-
type="button"
|
|
98
|
-
:class="{ active: isActive(tab) }"
|
|
99
|
-
class="bgl_tab relative z-1"
|
|
100
|
-
@click="selectTab(tab)"
|
|
101
|
-
>
|
|
102
|
-
<Icon v-if="typeof tab !== 'string' && tab.icon" :icon="tab.icon" />
|
|
103
|
-
{{ tabLabel(tab) }}
|
|
104
|
-
</button>
|
|
100
|
+
<div ref="tabsWrap" class="grid auto-flow-columns relative fit-content bgl_tabs_wrap overflow-hidden" :class="{ 'bgl_flat-tabs': flat, 'bgl_vertical-tabs': vertical }">
|
|
101
|
+
<slot name="tabs" v-bind="{ selectTab, isActive, tabLabel, tabs }">
|
|
102
|
+
<button v-for="(tab, i) in props.tabs" :key="i" type="button" :class="{ active: isActive(tab) }" class="bgl_tab relative z-1" @click="selectTab(tab)">
|
|
103
|
+
<Icon v-if="typeof tab !== 'string' && tab.icon" :icon="tab.icon" />
|
|
104
|
+
{{ tabLabel(tab) }}
|
|
105
|
+
</button>
|
|
105
106
|
</slot>
|
|
106
|
-
|
|
107
|
+
</div>
|
|
107
108
|
</template>
|
|
108
109
|
|
|
109
110
|
<style scoped>
|
|
@@ -127,7 +128,6 @@ onBeforeUnmount(() => {
|
|
|
127
128
|
border-radius: var(--input-border-radius);
|
|
128
129
|
transition: var(--bgl-transition);
|
|
129
130
|
color: inherit
|
|
130
|
-
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
.bgl_tab:hover {
|
|
@@ -145,6 +145,8 @@ onBeforeUnmount(() => {
|
|
|
145
145
|
border-radius: var(--input-border-radius);
|
|
146
146
|
transition: var(--bgl-transition);
|
|
147
147
|
z-index: 0;
|
|
148
|
+
/* Hide indicator initially until position is calculated */
|
|
149
|
+
opacity: var(--indicator-opacity, 0);
|
|
148
150
|
}
|
|
149
151
|
.bgl_flat-tabs.bgl_tabs_wrap {
|
|
150
152
|
background: transparent;
|
|
@@ -165,6 +165,14 @@
|
|
|
165
165
|
border-inline-end: 1px solid var(--border-color)
|
|
166
166
|
}
|
|
167
167
|
|
|
168
|
+
.border-input input {
|
|
169
|
+
border: 1px solid var(--border-color) !important;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
.border-input-none input {
|
|
173
|
+
border: none !important;
|
|
174
|
+
}
|
|
175
|
+
|
|
168
176
|
.border-inner-bottom>* {
|
|
169
177
|
border-bottom: 1px solid var(--border-color)
|
|
170
178
|
}
|
|
@@ -428,7 +436,8 @@
|
|
|
428
436
|
|
|
429
437
|
.m_border-color-unset {
|
|
430
438
|
border-color: unset !important;
|
|
431
|
-
}
|
|
439
|
+
}
|
|
440
|
+
|
|
432
441
|
.m_border-bottom {
|
|
433
442
|
border-bottom: 1px solid var(--border-color)
|
|
434
443
|
}
|