Skip to content

Commit

Permalink
fix(useShortcuts): invalid code after #1159
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamincanac committed Dec 25, 2023
1 parent 648eec3 commit 56e1fed
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/runtime/composables/useShortcuts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,10 @@ export const _useShortcuts = () => {

const activeElement = useActiveElement()
const usingInput = computed(() => {
const tagName = activeElement.value?.tagName
const contentEditable = activeElement.value?.contentEditable

return !!(activeElement.value?.tagName === 'INPUT' || activeElement.value?.tagName === 'TEXTAREA' || contentEditable === 'true' || contentEditable === 'plaintext-only')
const usingInput = !!(tagName === 'INPUT' || tagName === 'TEXTAREA' || contentEditable === 'true' || contentEditable === 'plaintext-only')

if (usingInput) {
return ((activeElement.value as any)?.name as string) || true
Expand Down

1 comment on commit 56e1fed

@vercel
Copy link

@vercel vercel bot commented on 56e1fed Dec 25, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

ui – ./

ui-git-dev-nuxt-js.vercel.app
ui-nuxt-js.vercel.app
ui.nuxt.com

Please sign in to comment.