diff --git a/src/components/base/BaseButton.vue b/src/components/base/BaseButton.vue index f2f9e51d..c617c30e 100644 --- a/src/components/base/BaseButton.vue +++ b/src/components/base/BaseButton.vue @@ -5,6 +5,7 @@ :class="{ 'base-button--type-button': isButton }" v-bind="elementBindings" :disabled="disabled || undefined" + ref="button" > @@ -89,6 +90,15 @@ watchEffect(() => { }) const isButton = computed(() => componentNodeName.value === 'button') + +const button = ref() +function focus() { + button.value.focus() +} + +defineExpose({ + focus, +})