sprintify-ui 0.0.99 → 0.0.100
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/sprintify-ui.es.js +5 -5
- package/dist/types/src/components/BaseAutocomplete.vue.d.ts +1 -1
- package/dist/types/src/components/BaseAutocompleteFetch.vue.d.ts +1 -1
- package/dist/types/src/components/BaseBelongsTo.vue.d.ts +1 -1
- package/dist/types/src/components/BaseDatePicker.vue.d.ts +1 -1
- package/dist/types/src/components/BaseTagAutocomplete.vue.d.ts +1 -1
- package/package.json +1 -1
- package/src/components/BaseAutocompleteDropdown.vue +9 -4
package/dist/sprintify-ui.es.js
CHANGED
|
@@ -2300,13 +2300,13 @@ const Ql = /* @__PURE__ */ ht(Ju, [["render", rc]]), ic = { class: "relative w-f
|
|
|
2300
2300
|
);
|
|
2301
2301
|
});
|
|
2302
2302
|
function d() {
|
|
2303
|
-
if (!i.value)
|
|
2303
|
+
if (!r.value || !i.value)
|
|
2304
2304
|
return;
|
|
2305
2305
|
const s = i.value[a.value] ?? null;
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2306
|
+
if (!s)
|
|
2307
|
+
return;
|
|
2308
|
+
const t = r.value.clientHeight, x = s.offsetTop, y = s.clientHeight;
|
|
2309
|
+
r.value.scrollTop = x - t / 2 + y / 2;
|
|
2310
2310
|
}
|
|
2311
2311
|
ze(
|
|
2312
2312
|
() => n.options,
|
|
@@ -158,11 +158,11 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
158
158
|
loading: boolean;
|
|
159
159
|
loadingBottom: boolean;
|
|
160
160
|
size: "base" | "xs" | "sm";
|
|
161
|
-
inline: boolean;
|
|
162
161
|
modelValue: Option | null | undefined;
|
|
163
162
|
placeholder: string;
|
|
164
163
|
disabled: boolean;
|
|
165
164
|
hasError: boolean;
|
|
165
|
+
inline: boolean;
|
|
166
166
|
dropdownShow: "focus" | "always";
|
|
167
167
|
modelValueShow: boolean;
|
|
168
168
|
visibleFocus: boolean;
|
|
@@ -132,11 +132,11 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
132
132
|
required: boolean;
|
|
133
133
|
name: string;
|
|
134
134
|
size: "base" | "xs" | "sm";
|
|
135
|
-
inline: boolean;
|
|
136
135
|
modelValue: Option | null | undefined;
|
|
137
136
|
placeholder: string;
|
|
138
137
|
disabled: boolean;
|
|
139
138
|
hasError: boolean;
|
|
139
|
+
inline: boolean;
|
|
140
140
|
dropdownShow: "focus" | "always";
|
|
141
141
|
modelValueShow: boolean;
|
|
142
142
|
visibleFocus: boolean;
|
|
@@ -136,11 +136,11 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
136
136
|
required: boolean;
|
|
137
137
|
name: string;
|
|
138
138
|
size: "base" | "xs" | "sm";
|
|
139
|
-
inline: boolean;
|
|
140
139
|
modelValue: string | number | null | undefined;
|
|
141
140
|
placeholder: string;
|
|
142
141
|
disabled: boolean;
|
|
143
142
|
hasError: boolean;
|
|
143
|
+
inline: boolean;
|
|
144
144
|
dropdownShow: "focus" | "always";
|
|
145
145
|
modelValueShow: boolean;
|
|
146
146
|
visibleFocus: boolean;
|
|
@@ -78,10 +78,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
78
78
|
}, {
|
|
79
79
|
required: boolean;
|
|
80
80
|
name: string;
|
|
81
|
-
inline: boolean;
|
|
82
81
|
modelValue: string | null | undefined;
|
|
83
82
|
disabled: boolean;
|
|
84
83
|
hasError: boolean;
|
|
84
|
+
inline: boolean;
|
|
85
85
|
minDate: Date;
|
|
86
86
|
maxDate: Date;
|
|
87
87
|
yearRange: number | [number, number];
|
|
@@ -149,10 +149,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
149
149
|
loading: boolean;
|
|
150
150
|
loadingBottom: boolean;
|
|
151
151
|
size: "base" | "xs" | "sm";
|
|
152
|
-
inline: boolean;
|
|
153
152
|
placeholder: string;
|
|
154
153
|
disabled: boolean;
|
|
155
154
|
hasError: boolean;
|
|
155
|
+
inline: boolean;
|
|
156
156
|
dropdownShow: "focus" | "always";
|
|
157
157
|
max: number;
|
|
158
158
|
}>, {
|
package/package.json
CHANGED
|
@@ -234,6 +234,10 @@ onMounted(() => {
|
|
|
234
234
|
});
|
|
235
235
|
|
|
236
236
|
function scrollToFocus() {
|
|
237
|
+
if (!dropdown.value) {
|
|
238
|
+
return;
|
|
239
|
+
}
|
|
240
|
+
|
|
237
241
|
if (!optionRefs.value) {
|
|
238
242
|
return;
|
|
239
243
|
}
|
|
@@ -244,10 +248,11 @@ function scrollToFocus() {
|
|
|
244
248
|
return;
|
|
245
249
|
}
|
|
246
250
|
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
+
const dropdownHeight = dropdown.value.clientHeight;
|
|
252
|
+
const offsetTop = option.offsetTop;
|
|
253
|
+
const optionHeight = option.clientHeight;
|
|
254
|
+
|
|
255
|
+
dropdown.value.scrollTop = offsetTop - dropdownHeight / 2 + optionHeight / 2;
|
|
251
256
|
}
|
|
252
257
|
|
|
253
258
|
// Validate focus index
|