sprintify-ui 0.6.48 → 0.6.50
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.
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ClassNameValue } from 'tailwind-merge';
|
|
2
2
|
import { RouteLocationRaw } from 'vue-router';
|
|
3
|
+
declare function focus(): void;
|
|
3
4
|
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
4
5
|
class: {
|
|
5
6
|
type: import("vue").PropType<string | false | 0 | ClassNameValue[] | null>;
|
|
@@ -41,7 +42,9 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
41
42
|
type: import("vue").PropType<"start" | "end">;
|
|
42
43
|
default: string;
|
|
43
44
|
};
|
|
44
|
-
}, {
|
|
45
|
+
}, {
|
|
46
|
+
focus: typeof focus;
|
|
47
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
45
48
|
click: (...args: any[]) => void;
|
|
46
49
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
47
50
|
class: {
|
package/package.json
CHANGED
|
@@ -75,7 +75,8 @@ const classes = computed(() => {
|
|
|
75
75
|
md: 'px-1.5 py-0.5 text-xs',
|
|
76
76
|
lg: 'px-1.5 py-0.5 text-sm',
|
|
77
77
|
}[sizeInternal.value];
|
|
78
|
-
|
|
78
|
+
|
|
79
|
+
const wrap = props.wrap ? '' : 'whitespace-nowrap';
|
|
79
80
|
|
|
80
81
|
return twMerge(base, wrap, size, props.class);
|
|
81
82
|
})
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<component
|
|
3
3
|
:is="as"
|
|
4
|
-
ref="
|
|
4
|
+
ref="buttonRef"
|
|
5
5
|
:class="classes"
|
|
6
6
|
:style="styles"
|
|
7
7
|
:to="to"
|
|
@@ -205,4 +205,16 @@ const iconClass = computed(() => {
|
|
|
205
205
|
return classes;
|
|
206
206
|
});
|
|
207
207
|
|
|
208
|
+
const buttonRef = ref<HTMLElement | undefined>(undefined);
|
|
209
|
+
|
|
210
|
+
function focus() {
|
|
211
|
+
if (buttonRef.value) {
|
|
212
|
+
buttonRef.value.focus();
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
defineExpose({
|
|
217
|
+
focus,
|
|
218
|
+
});
|
|
219
|
+
|
|
208
220
|
</script>
|