@bagelink/vue 0.0.427 → 0.0.431

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.
Files changed (37) hide show
  1. package/dist/components/Alert.vue.d.ts +4 -1
  2. package/dist/components/Alert.vue.d.ts.map +1 -1
  3. package/dist/components/TableSchema.vue.d.ts +2 -5
  4. package/dist/components/TableSchema.vue.d.ts.map +1 -1
  5. package/dist/components/form/inputs/DatePicker.vue.d.ts +4 -0
  6. package/dist/components/form/inputs/DatePicker.vue.d.ts.map +1 -1
  7. package/dist/components/form/inputs/FileUpload.vue.d.ts +6 -2
  8. package/dist/components/form/inputs/FileUpload.vue.d.ts.map +1 -1
  9. package/dist/components/form/inputs/RadioPillsInput.vue.d.ts.map +1 -1
  10. package/dist/components/form/inputs/SelectInput.vue.d.ts.map +1 -1
  11. package/dist/components/form/inputs/TextInput.vue.d.ts +0 -3
  12. package/dist/components/form/inputs/TextInput.vue.d.ts.map +1 -1
  13. package/dist/components/layout/Tabs.vue.d.ts +6 -2
  14. package/dist/components/layout/Tabs.vue.d.ts.map +1 -1
  15. package/dist/components/layout/TabsNav.vue.d.ts.map +1 -1
  16. package/dist/index.cjs +193 -113
  17. package/dist/index.mjs +194 -114
  18. package/dist/plugins/bagel.d.ts +3 -0
  19. package/dist/plugins/bagel.d.ts.map +1 -1
  20. package/dist/style.css +145 -127
  21. package/dist/utils/index.d.ts +1 -0
  22. package/dist/utils/index.d.ts.map +1 -1
  23. package/dist/utils/lang.d.ts +7 -0
  24. package/dist/utils/lang.d.ts.map +1 -0
  25. package/package.json +1 -1
  26. package/src/components/Alert.vue +4 -2
  27. package/src/components/TableSchema.vue +19 -9
  28. package/src/components/form/inputs/DatePicker.vue +8 -2
  29. package/src/components/form/inputs/FileUpload.vue +54 -23
  30. package/src/components/form/inputs/RadioPillsInput.vue +5 -4
  31. package/src/components/form/inputs/SelectInput.vue +212 -204
  32. package/src/components/form/inputs/TextInput.vue +1 -1
  33. package/src/components/layout/Tabs.vue +14 -5
  34. package/src/components/layout/TabsNav.vue +34 -14
  35. package/src/plugins/bagel.ts +13 -4
  36. package/src/utils/index.ts +2 -0
  37. package/src/utils/lang.ts +39 -0
@@ -1,294 +1,302 @@
1
1
  <template>
2
- <Dropdown
3
- @click.stop
4
- @hide="updateOpen(false)"
5
- ref="dropdown"
6
- placement="bottom-start"
7
- class="bagel-input selectinput">
8
- <label>
9
- {{ label }}
10
- <button
11
- @keydown="openOptions"
12
- @click="updateOpen(true)"
13
- :disabled="disabled"
14
- type="button"
15
- class="selectinput-btn"
16
- :class="{ isEmpty: selectedItems.length === 0 }">
17
- <p>{{ selectedLabel }}</p>
18
- <Icon
19
- v-if="!disabled"
20
- v-bind="{ icon: open ? 'unfold_less' : 'unfold_more' }" />
21
- </button>
22
- <input
23
- tabindex="-1"
24
- style="width: 0; height: 0; position: absolute; opacity: 0; z-index: -1"
25
- v-if="required"
26
- @input="updateOpen(true)"
27
- :value="selectedItems"
28
- required />
29
- </label>
30
- <template #popper>
31
- <Card
32
- class="selectinput-options p-05"
33
- :style="{ width: fullWidth ? '100%' : 'auto' }">
34
- <TextInput
35
- v-if="searchable"
36
- ref="searchInput"
37
- dense
38
- :placeholder="'Search'"
39
- icon="search"
40
- v-model="search" />
41
- <div
42
- class="selectinput-option hover gap-1"
43
- v-for="(option, i) in filteredOptions"
44
- :key="`${option}${i}`"
45
- @click="select(option)"
46
- :class="{ selected: isSelected(option) }">
47
- <Icon v-if="isSelected(option)" icon="check" />
48
- <Icon
49
- class="opacity-3"
50
- v-if="!isSelected(option)"
51
- icon="fiber_manual_record" />
52
- <span>
53
- {{ getLabel(option) }}
54
- </span>
55
- </div>
56
- <slot name="last" />
57
- </Card>
58
- </template>
59
- </Dropdown>
2
+ <Dropdown
3
+ @click.stop
4
+ @hide="updateOpen(false)"
5
+ ref="dropdown"
6
+ placement="bottom-start"
7
+ class="bagel-input selectinput"
8
+ >
9
+ <label>
10
+ {{ label }}
11
+ <button
12
+ @keydown="openOptions"
13
+ @click="updateOpen(true)"
14
+ :disabled="disabled"
15
+ type="button"
16
+ class="selectinput-btn"
17
+ :class="{ isEmpty: selectedItems.length === 0 }"
18
+ >
19
+ <p>{{ selectedLabel }}</p>
20
+ <Icon
21
+ v-if="!disabled"
22
+ v-bind="{ icon: open ? 'unfold_less' : 'unfold_more' }"
23
+ />
24
+ </button>
25
+ <input
26
+ tabindex="-1"
27
+ style="width: 0; height: 0; position: absolute; opacity: 0; z-index: -1"
28
+ v-if="required"
29
+ @input="updateOpen(true)"
30
+ :value="selectedItems"
31
+ required
32
+ />
33
+ </label>
34
+ <template #popper>
35
+ <Card
36
+ class="selectinput-options p-05"
37
+ :style="{ width: fullWidth ? '100%' : 'auto' }"
38
+ >
39
+ <TextInput
40
+ v-if="searchable"
41
+ ref="searchInput"
42
+ dense
43
+ :placeholder="'Search'"
44
+ icon="search"
45
+ v-model="search"
46
+ />
47
+ <div
48
+ class="selectinput-option hover gap-1"
49
+ v-for="(option, i) in filteredOptions"
50
+ :key="`${option}${i}`"
51
+ @click="select(option)"
52
+ :class="{ selected: isSelected(option) }"
53
+ >
54
+ <Icon v-if="isSelected(option)" icon="check" />
55
+ <Icon
56
+ class="opacity-3"
57
+ v-if="!isSelected(option)"
58
+ icon="fiber_manual_record"
59
+ />
60
+ <span>
61
+ {{ getLabel(option) }}
62
+ </span>
63
+ </div>
64
+ <slot name="last" />
65
+ </Card>
66
+ </template>
67
+ </Dropdown>
60
68
  </template>
61
69
 
62
70
  <script lang="ts" setup>
63
- import { watch } from 'vue';
64
- import { Dropdown } from 'floating-vue';
65
- import 'floating-vue/style.css';
66
- import { TextInput, Card, Icon } from '@bagelink/vue';
71
+ import { watch } from "vue";
72
+ import { Dropdown } from "floating-vue";
73
+ import "floating-vue/style.css";
74
+ import { TextInput, Card, Icon } from "@bagelink/vue";
67
75
 
68
76
  type Option =
69
- | string
70
- | number
71
- | Record<string, any>
72
- | { label: string; value: string | number };
77
+ | string
78
+ | number
79
+ | Record<string, any>
80
+ | { label: string; value: string | number };
73
81
 
74
82
  const searchInput = $ref<HTMLInputElement | null>(null);
75
83
 
76
84
  const props = defineProps<{
77
- options: Option[];
78
- placeholder?: string;
79
- disabled?: boolean;
80
- modelValue?: Option;
81
- searchable?: boolean;
82
- required?: boolean;
83
- label?: string;
84
- fullWidth?: boolean;
85
- multiselect?: boolean;
85
+ options: Option[];
86
+ placeholder?: string;
87
+ disabled?: boolean;
88
+ modelValue?: Option;
89
+ searchable?: boolean;
90
+ required?: boolean;
91
+ label?: string;
92
+ fullWidth?: boolean;
93
+ multiselect?: boolean;
86
94
  }>();
87
95
 
88
96
  let selectedItems = $ref<Option[]>([]);
89
- let search = $ref('');
97
+ let search = $ref("");
90
98
 
91
99
  const dropdown = $ref<InstanceType<typeof Dropdown> | null>(null);
92
100
 
93
101
  let open = $ref(false);
94
102
 
95
103
  function openOptions() {
96
- dropdown?.show();
97
- // updateOpen(true);
104
+ dropdown?.show();
105
+ // updateOpen(true);
98
106
  }
99
107
 
100
108
  function updateOpen(visible: boolean) {
101
- open = visible;
102
- if (!open) search = '';
103
- else {
104
- setTimeout(
105
- () => (searchInput as any)?.$el?.querySelector('input')?.focus(),
106
- 100
107
- );
108
- }
109
+ open = visible;
110
+ if (!open) search = "";
111
+ else {
112
+ setTimeout(
113
+ () => (searchInput as any)?.$el?.querySelector("input")?.focus(),
114
+ 100
115
+ );
116
+ }
109
117
  }
110
118
 
111
119
  const selectedLabel = $computed(() => {
112
- if (selectedItems.length === 0) return props.placeholder || 'Select';
113
- if (selectedItems.length > 4) {
114
- const str = selectedItems
115
- .slice(0, 4)
116
- .map((item) => getLabel(item))
117
- .join(', ');
118
- return `${str}... +${selectedItems.length - 4}`;
119
- }
120
- return selectedItems.map((item) => getLabel(item)).join(', ');
120
+ if (selectedItems.length === 0) return props.placeholder || "Select";
121
+ if (selectedItems.length > 4) {
122
+ const str = selectedItems
123
+ .slice(0, 4)
124
+ .map((item) => getLabel(item))
125
+ .join(", ");
126
+ return `${str}... +${selectedItems.length - 4}`;
127
+ }
128
+ return selectedItems.map((item) => getLabel(item)).join(", ");
121
129
  });
122
130
 
123
- const emit = defineEmits(['update:modelValue']);
131
+ const emit = defineEmits(["update:modelValue"]);
124
132
 
125
133
  const getLabel = (option: Option) => {
126
- if (!option) return '';
127
- if (typeof option === 'string') return option;
128
- if (typeof option === 'number') return `${option}`;
129
- return option.label;
134
+ if (!option) return "";
135
+ if (typeof option === "string") return option;
136
+ if (typeof option === "number") return `${option}`;
137
+ return option.label;
130
138
  };
131
139
 
132
140
  const getValue = (option: Option) => {
133
- if (!option) return '';
134
- if (typeof option === 'string') return option;
135
- if (typeof option === 'number') return option;
136
- return option.value;
141
+ if (!option) return "";
142
+ if (typeof option === "string") return option;
143
+ if (typeof option === "number") return option;
144
+ return option.value;
137
145
  };
138
146
 
139
147
  const isSelected = (option: Option) =>
140
- !!selectedItems.find((item) => getValue(option) === getValue(item));
148
+ !!selectedItems.find((item) => getValue(option) === getValue(item));
141
149
 
142
150
  const filteredOptions = $computed(() =>
143
- props.options.filter((option) => {
144
- const searchTerm = search
145
- .split(/\s+/)
146
- .filter(Boolean)
147
- .map((t) => new RegExp(t, 'gi'));
148
- return (
149
- Boolean(option) &&
150
- (searchTerm.every((s) => getLabel(option).match(s)) ||
151
- searchTerm.length === 0)
152
- );
153
- })
151
+ props.options.filter((option) => {
152
+ const searchTerm = search
153
+ .split(/\s+/)
154
+ .filter(Boolean)
155
+ .map((t) => new RegExp(t, "gi"));
156
+ return (
157
+ Boolean(option) &&
158
+ (searchTerm.every((s) => getLabel(option).match(s)) ||
159
+ searchTerm.length === 0)
160
+ );
161
+ })
154
162
  );
155
163
 
156
164
  const select = (option: Option) => {
157
- const existingIndex = selectedItems.findIndex(
158
- (item) => getValue(item) === getValue(option)
159
- );
160
- if (existingIndex > -1) selectedItems.splice(existingIndex, 1);
161
- else if (props.multiselect) {
162
- const current = [...selectedItems];
163
- current.push(option);
164
-
165
- selectedItems = current;
166
- } else selectedItems.splice(0, selectedItems.length, option);
167
-
168
- if (!props.multiselect) dropdown?.hide();
169
- emitUpdate();
165
+ const existingIndex = selectedItems.findIndex(
166
+ (item) => getValue(item) === getValue(option)
167
+ );
168
+ if (existingIndex > -1) selectedItems.splice(existingIndex, 1);
169
+ else if (props.multiselect) {
170
+ const current = [...selectedItems];
171
+ current.push(option);
172
+
173
+ selectedItems = current;
174
+ } else selectedItems.splice(0, selectedItems.length, option);
175
+
176
+ if (!props.multiselect) dropdown?.hide();
177
+ emitUpdate();
170
178
  };
171
179
 
172
180
  function emitUpdate() {
173
- if (props.multiselect) {
174
- emit('update:modelValue', selectedItems.map(getValue).filter(Boolean));
175
- } else {
176
- selectedItems.splice(1, selectedItems.length - 1);
177
- const [item] = selectedItems;
178
- emit('update:modelValue', item ? getValue(item) : null);
179
- }
181
+ if (props.multiselect) {
182
+ emit("update:modelValue", selectedItems.map(getValue).filter(Boolean));
183
+ } else {
184
+ selectedItems.splice(1, selectedItems.length - 1);
185
+ const [item] = selectedItems;
186
+ emit("update:modelValue", item ? getValue(item) : null);
187
+ }
180
188
  }
181
189
 
182
190
  function compareArrays(arr1: Option[], arr2: Option[]) {
183
- const arr1Values = [...arr1].map((a) => getValue(a)).filter(Boolean);
184
- const arr2Values = [...arr2].map((a) => getValue(a)).filter(Boolean);
185
- const isSame = arr1Values.every((item: Option) => arr2Values.includes(item));
186
- return isSame;
191
+ const arr1Values = [...arr1].map((a) => getValue(a)).filter(Boolean);
192
+ const arr2Values = [...arr2].map((a) => getValue(a)).filter(Boolean);
193
+ const isSame = arr1Values.every((item: Option) => arr2Values.includes(item));
194
+ return isSame;
187
195
  }
188
196
 
189
197
  watch(
190
- () => props.modelValue,
191
- (newVal: Option | Option[]) => {
192
- if (!props.multiselect) {
193
- const newOption =
194
- props.options.find((o) => getValue(o) === newVal) || newVal;
195
- if (newOption && !isSelected(newOption)) selectedItems = [newOption];
196
- } else {
197
- const isSame = compareArrays([newVal].flat(), selectedItems);
198
- if (!isSame) {
199
- selectedItems.splice(0, selectedItems.length, ...[newVal].flat());
200
- }
201
- }
202
- },
203
- { immediate: true }
198
+ () => props.modelValue,
199
+ (newVal: Option | Option[]) => {
200
+ if (!props.multiselect) {
201
+ const newOption =
202
+ props.options.find((o) => getValue(o) === newVal) || newVal;
203
+ if (newOption && !isSelected(newOption)) selectedItems = [newOption];
204
+ } else {
205
+ const isSame = compareArrays([newVal].flat(), selectedItems);
206
+ if (!isSame) {
207
+ selectedItems.splice(0, selectedItems.length, ...[newVal].flat());
208
+ }
209
+ }
210
+ },
211
+ { immediate: true }
204
212
  );
205
213
 
206
214
  watch(
207
- () => props.options,
208
- () => {
209
- selectedItems.forEach((option, i) => {
210
- const exists = props.options.find(
211
- (o) => getValue(o) === getValue(option)
212
- );
213
- if (!exists) selectedItems.splice(i, 1);
214
- else selectedItems.splice(i, 1, exists);
215
- });
216
- // const original = JSON.stringify(props.options.map(getValue));
217
- // const newSelection = JSON.stringify(selectedItems.map(getValue));
218
- // if (original !== newSelection) emitUpdate();
219
- },
220
- { deep: true, immediate: true }
215
+ () => props.options,
216
+ () => {
217
+ selectedItems.forEach((option, i) => {
218
+ const exists = props.options.find(
219
+ (o) => getValue(o) === getValue(option)
220
+ );
221
+ if (!exists) selectedItems.splice(i, 1);
222
+ else selectedItems.splice(i, 1, exists);
223
+ });
224
+ // const original = JSON.stringify(props.options.map(getValue));
225
+ // const newSelection = JSON.stringify(selectedItems.map(getValue));
226
+ // if (original !== newSelection) emitUpdate();
227
+ },
228
+ { deep: true, immediate: true }
221
229
  );
222
230
  </script>
223
231
 
224
232
  <style scoped>
225
233
  .selectinput {
226
- width: 100%;
234
+ width: 100%;
227
235
  }
228
236
 
229
237
  .selectinput-option {
230
- padding: 6px 12px;
231
- cursor: pointer;
232
- border-radius: 5px;
233
- transition: all 0.2s;
234
- display: grid;
235
- grid-template-columns: 10px 1fr;
236
- justify-content: space-between;
237
- width: 100%;
238
- font-size: var(--input-font-size);
238
+ padding: 6px 12px;
239
+ cursor: pointer;
240
+ border-radius: 5px;
241
+ transition: all 0.2s;
242
+ display: grid;
243
+ grid-template-columns: 10px 1fr;
244
+ justify-content: space-between;
245
+ width: 100%;
246
+ font-size: var(--input-font-size);
239
247
  }
240
248
 
241
249
  .selectinput-options {
242
- max-height: 300px;
243
- overflow-y: auto;
250
+ max-height: 300px;
251
+ overflow-y: auto;
244
252
  }
245
253
 
246
254
  .selectinput-option:hover {
247
- background: var(--bgl-gray-20);
255
+ background: var(--bgl-gray-20);
248
256
  }
249
257
  .isEmpty p {
250
- opacity: 0.3;
258
+ opacity: 0.3;
251
259
  }
252
260
  </style>
253
261
 
254
262
  <style>
255
263
  .bagel-input label {
256
- font-size: var(--label-font-size);
264
+ font-size: var(--label-font-size);
257
265
  }
258
266
 
259
267
  .selectinput-btn {
260
- display: flex;
261
- justify-content: space-between;
262
- align-items: center;
263
- height: var(--input-height);
264
- border-radius: var(--input-border-radius);
265
- border: none;
266
- background: var(--input-bg);
267
- padding: 0.7rem;
268
- color: var(--input-color);
269
- width: 100%;
270
- font-family: inherit;
271
- font-size: var(--input-font-size);
268
+ display: flex;
269
+ justify-content: space-between;
270
+ align-items: center;
271
+ height: var(--input-height);
272
+ border-radius: var(--input-border-radius);
273
+ border: none;
274
+ background: var(--input-bg);
275
+ padding: 0.7rem;
276
+ color: var(--input-color);
277
+ width: 100%;
278
+ font-family: inherit;
279
+ font-size: var(--input-font-size);
272
280
  }
273
281
 
274
282
  .selectinput-btn:disabled {
275
- color: var(--input-disabled-color);
276
- background-color: transparent;
283
+ color: var(--input-disabled-color);
284
+ background-color: transparent;
277
285
  }
278
286
 
279
287
  .selectinput-btn:focus {
280
- outline: none;
281
- box-shadow: inset 0 0 10px #00000012;
288
+ outline: none;
289
+ box-shadow: inset 0 0 10px #00000012;
282
290
  }
283
291
 
284
292
  .v-popper__arrow-container {
285
- display: none;
293
+ display: none;
286
294
  }
287
295
 
288
296
  .v-popper--theme-dropdown .v-popper__inner {
289
- border: none;
290
- /* background: transparent; if anyone is changing this please talk to me first*/
291
- border-radius: var(--card-border-radius);
292
- color: var(--input-color);
297
+ border: none;
298
+ /* background: transparent; if anyone is changing this please talk to me first*/
299
+ border-radius: var(--card-border-radius);
300
+ color: var(--input-color);
293
301
  }
294
302
  </style>
@@ -96,6 +96,7 @@ const props = withDefaults(
96
96
  autoheight?: boolean;
97
97
  code?: boolean;
98
98
  lines?: number;
99
+ // eslint-disable-next-line max-len
99
100
  autocomplete?: string;
100
101
  autofocus?: boolean;
101
102
  }>(),
@@ -103,7 +104,6 @@ const props = withDefaults(
103
104
  type: 'text',
104
105
  toggleEdit: false,
105
106
  modelValue: '',
106
- autocomplete: 'off',
107
107
  },
108
108
  );
109
109
  let inputVal = $ref<string | number>();
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <TabsNav :tabs="tabs" :group="group" class="mb-05" />
2
+ <TabsNav v-model="slctTab" :tabs="tabs" :group="group" class="mb-05" />
3
3
  <div v-if="currentTab">
4
4
  <template v-if="slots[currentTab]">
5
5
  <slot :name="currentTab" />
@@ -9,10 +9,11 @@
9
9
  </template>
10
10
  </div>
11
11
  </template>
12
-
12
+ z
13
13
  <script setup lang="ts">
14
14
  import { TabsNav, type Tab } from '@bagelink/vue';
15
- import { defineProps, useSlots, h, defineComponent } from 'vue';
15
+ import { defineProps, useSlots, h, type VNode, defineComponent } from 'vue';
16
+
16
17
  import { useTabs } from './tabsManager';
17
18
 
18
19
  const props = defineProps<{
@@ -26,13 +27,21 @@ const { currentTab } = useTabs(group);
26
27
 
27
28
  const tabValue = (tab: Tab) => (typeof tab === 'string' ? tab : tab.id);
28
29
 
30
+ const emit = defineEmits(['update:modelValue']);
31
+
32
+ const slctTab = $computed({
33
+ get: () => props.modelValue || tabValue(props.tabs[0]),
34
+ set: (value) => emit('update:modelValue', value),
35
+ });
36
+
29
37
  const tabComponent = defineComponent({
30
38
  render() {
31
39
  const currentTabIndex = props.tabs.findIndex(
32
- (tab) => tabValue(tab) === currentTab.value
40
+ (tab) => tabValue(tab) === currentTab.value,
33
41
  );
34
42
  const slotChildren = slots?.default?.()?.[1]?.children;
35
- return h('div', slotChildren?.[currentTabIndex]);
43
+
44
+ return h('div', (slotChildren as VNode[])[currentTabIndex]);
36
45
  },
37
46
  });
38
47
  </script>
@@ -6,7 +6,8 @@
6
6
  @click="selectTab(tab)"
7
7
  class="bgl_tab"
8
8
  v-for="(tab, i) in tabs"
9
- :key="i">
9
+ :key="i"
10
+ >
10
11
  <Icon v-if="typeof tab !== 'string' && tab.icon" :icon="tab.icon" />
11
12
  {{ tabLabel(tab) }}
12
13
  </button>
@@ -15,6 +16,7 @@
15
16
 
16
17
  <script setup lang="ts">
17
18
  import { type Tab, Icon } from '@bagelink/vue';
19
+ import { watch } from 'vue';
18
20
  import { useTabs } from './tabsManager';
19
21
 
20
22
  const props = defineProps<{
@@ -41,39 +43,57 @@ const isActive = (tab: Tab) => {
41
43
  if (typeof tab === 'string') return currentTab.value === tab;
42
44
  return currentTab.value === tab.id;
43
45
  };
46
+
44
47
  const tabLabel = (tab: Tab) => {
45
48
  if (typeof tab === 'string') return tab;
46
49
  return tab.label;
47
50
  };
51
+
52
+ watch(
53
+ () => props.modelValue,
54
+ (value) => {
55
+ if (value && !isActive(value)) currentTab.value = value;
56
+ },
57
+ { immediate: true },
58
+ );
48
59
  </script>
49
60
 
50
61
  <style scoped>
51
62
  .bgl_tabs_wrap {
63
+ background: var(--input-bg);
64
+ border-radius: calc(var(--input-border-radius) * 1.4);
65
+ padding-inline: calc(var(--btn-padding) / 8);
66
+ padding-block: calc(var(--btn-padding) / 8);
67
+ box-shadow: inset 0 0 10px #00000012;
68
+ gap: 0.25rem;
52
69
  }
53
70
  .bgl_tab {
54
71
  border: none;
55
- border-bottom: 2px solid var(--border-color);
56
72
  background: transparent;
73
+ cursor: pointer;
57
74
  font-size: var(--input-font-size);
58
75
  font-family: inherit;
59
- cursor: pointer;
60
76
  transition: var(--bgl-transition);
61
- padding-inline-start: calc(var(--btn-padding) / 2);
62
- padding-inline-end: calc(var(--btn-padding) / 2);
63
- padding-bottom: calc(var(--btn-padding) / 4);
77
+ padding-inline: calc(var(--btn-padding) / 2);
78
+ padding-block: calc(var(--btn-padding) / 8);
79
+ border-radius: var(--input-border-radius);
64
80
  }
65
-
66
- .bgl_tab.currentTab {
67
- border-bottom: 2px solid var(--primary-color);
68
- }
69
-
81
+ .bgl_tab.currentTab,
70
82
  .bgl_tab.active {
71
- color: var(--bgl-primary);
72
- border-bottom: 2px solid var(--bgl-primary);
83
+ background: var(--bgl-white);
84
+ box-shadow: 0 0 10px #00000011;
85
+ position: relative;
73
86
  }
74
87
 
75
88
  .bgl_tab:hover {
76
- color: var(--bgl-primary);
89
+ background: var(--input-bg);
90
+ filter: brightness(95%);
91
+ }
92
+ .bgl_tab.currentTab:hover,
93
+ .bgl_tab.active:hover {
94
+ background: var(--bgl-white);
95
+ filter: brightness(100%);
96
+ box-shadow: 0 0 10px #00000022;
77
97
  }
78
98
 
79
99
  .bgl_tab:active {