From 4c29804b00a6416d615076b80af52d781dde6a76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tu=C4=9F=C3=A7e=20K=C3=BC=C3=A7=C3=BCko=C4=9Flu?= Date: Thu, 6 Jul 2023 13:12:19 +0300 Subject: [PATCH] Refactor #4103 - FocusTrap and Tooltip fixes --- components/lib/basedirective/BaseDirective.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/lib/basedirective/BaseDirective.js b/components/lib/basedirective/BaseDirective.js index 3b334b535..df15d6be3 100644 --- a/components/lib/basedirective/BaseDirective.js +++ b/components/lib/basedirective/BaseDirective.js @@ -19,7 +19,7 @@ const BaseDirective = { const self = BaseDirective._getOptionValue(obj, key, params); const globalPT = searchInDefaultPT ? BaseDirective._getOptionValue(instance.defaultPT, key, params) : undefined; const merged = mergeProps(self, globalPT, { - ...(key === 'root' && { [`${datasetPrefix}name`]: ObjectUtils.convertToFlatCase(instance.$name) }), + ...(key === 'root' && instance.$name !== 'focustrap' && { [`${datasetPrefix}name`]: ObjectUtils.convertToFlatCase(instance.$name) }), [`${datasetPrefix}section`]: ObjectUtils.convertToFlatCase(key) }); @@ -70,11 +70,11 @@ const BaseDirective = { handleHook('created', el, binding, vnode, prevVnode); }, beforeMount: (el, binding, vnode, prevVnode) => { - loadBaseStyle(); - !el.$instance?.isUnstyled && el.$instance?.$css?.loadStyle(); handleHook('beforeMount', el, binding, vnode, prevVnode); }, mounted: (el, binding, vnode, prevVnode) => { + loadBaseStyle(); + !el.$instance?.isUnstyled && el.$instance?.$css?.loadStyle(); handleHook('mounted', el, binding, vnode, prevVnode); }, beforeUpdate: (el, binding, vnode, prevVnode) => {