sprintify-ui 0.0.46 → 0.0.47

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.
@@ -284,6 +284,7 @@ declare const _default: {
284
284
  footer: (_: {
285
285
  options: NormalizedOption[];
286
286
  keywords: string;
287
+ hideDropdown: () => void;
287
288
  }) => any;
288
289
  };
289
290
  });
@@ -264,6 +264,7 @@ declare const _default: {
264
264
  footer: (_: {
265
265
  options: import("@/types").NormalizedOption[];
266
266
  keywords: string;
267
+ hideDropdown: () => void;
267
268
  } & {
268
269
  keywords: string;
269
270
  }) => any;
@@ -273,6 +273,7 @@ declare const _default: {
273
273
  footer: (_: {
274
274
  options: import("@/types").NormalizedOption[];
275
275
  keywords: string;
276
+ hideDropdown: () => void;
276
277
  } & {
277
278
  keywords: string;
278
279
  }) => any;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sprintify-ui",
3
- "version": "0.0.46",
3
+ "version": "0.0.47",
4
4
  "scripts": {
5
5
  "build": "rimraf dist && vue-tsc && vite build",
6
6
  "build-fast": "rimraf dist && vite build",
@@ -98,6 +98,7 @@
98
98
  <slot
99
99
  :options="filteredNormalizedOptions"
100
100
  :keywords="keywords"
101
+ :hide-dropdown="hideDropdown"
101
102
  name="footer"
102
103
  />
103
104
  </div>
@@ -367,9 +368,12 @@ const clear = () => {
367
368
 
368
369
  const onSelect = (normalizedModelValue: Option | null | undefined) => {
369
370
  update(normalizedModelValue);
370
- inputElement.value?.blur();
371
371
  };
372
372
 
373
+ function hideDropdown() {
374
+ inputElement.value?.blur();
375
+ }
376
+
373
377
  const update = (normalizedSelection: Option | null | undefined) => {
374
378
  const selection = normalizedSelection ? normalizedSelection.option : null;
375
379
  if (normalizedSelection) {
@@ -22,7 +22,8 @@ defineProps({
22
22
  },
23
23
  });
24
24
 
25
- const windowWidth = ref(0);
25
+ // windowWidth should not be equal to width when the card is mounted
26
+ const windowWidth = ref(1);
26
27
  const width = ref(0);
27
28
  const card = ref(null) as Ref<HTMLElement | null>;
28
29