Skip to content

Commit

Permalink
fix(Link): check disabled prop before navigating (#1321)
Browse files Browse the repository at this point in the history
  • Loading branch information
solamichealolawale authored Feb 6, 2024
1 parent c3ed940 commit ac42ec1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/runtime/components/elements/Link.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
:rel="rel"
:target="target"
:class="active !== undefined ? (active ? activeClass : inactiveClass) : resolveLinkClass(route, $route, { isActive, isExactActive })"
@click="(e) => !isExternal && navigate(e)"
@click="(e) => (!isExternal && !disabled) && navigate(e)"
>
<slot v-bind="{ isActive: active !== undefined ? active : (exact ? isExactActive : isActive) }" />
</a>
Expand Down

0 comments on commit ac42ec1

Please sign in to comment.