From 51fbc3e5c630cadadd83dfec823bebaeb148ca9b Mon Sep 17 00:00:00 2001 From: Christian Gil Date: Fri, 15 Sep 2023 19:54:25 -0600 Subject: [PATCH] fix: Fix button click event not emitting --- src/runtime/components/elements/Link.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/runtime/components/elements/Link.ts b/src/runtime/components/elements/Link.ts index df6d4d4..507b01c 100644 --- a/src/runtime/components/elements/Link.ts +++ b/src/runtime/components/elements/Link.ts @@ -49,8 +49,6 @@ export default defineComponent({ inactiveClass: { type: String, default: undefined }, }, - emits: ["click"], - // We extract the "custom" prop to avoid overrides // eslint-disable-next-line @typescript-eslint/no-unused-vars setup({ custom, ...props }, ctx) { @@ -114,6 +112,7 @@ export default defineComponent({ role: props.disabled ? undefined : "link", onClick: (e: Event) => { !isExternal && navigate(e); + // eslint-disable-next-line vue/require-explicit-emits ctx.emit("click", e); }, ariaDisabled: props.disabled ? "true" : undefined,