Skip to content

Commit

Permalink
fix(defaults): allow null component and global values (#19842)
Browse files Browse the repository at this point in the history
fixes #19783
  • Loading branch information
webdevnerdstuff committed May 21, 2024
1 parent 905eb63 commit 9342288
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/vuetify/src/composables/defaults.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,9 @@ export function internalUseDefaults (
if (prop === 'class' || prop === 'style') {
return [componentDefaults.value?.[prop], propValue].filter(v => v != null)
} else if (typeof prop === 'string' && !propIsDefined(vm.vnode, prop)) {
return componentDefaults.value?.[prop] ?? defaults.value?.global?.[prop] ?? propValue
return componentDefaults.value?.[prop] !== undefined ? componentDefaults.value?.[prop]
: defaults.value?.global?.[prop] !== undefined ? defaults.value?.global?.[prop]
: propValue
}
return propValue
},
Expand Down

0 comments on commit 9342288

Please sign in to comment.