From 5747e979afa29c3a6f55f2edcef70fde67517792 Mon Sep 17 00:00:00 2001 From: Phillip Rak Date: Fri, 8 Nov 2024 11:24:40 -0700 Subject: [PATCH 1/2] Fix `clean-tooltip` directive in Vue3 The interface for custom directives has changed in some important ways in Vue3. - `bind` is now `beforeMount` - `update` has been removed and `updated` is recommended Signed-off-by: Phillip Rak --- shell/directives/clean-tooltip.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/shell/directives/clean-tooltip.js b/shell/directives/clean-tooltip.js index 59bd3f28a45..bfb868deba2 100644 --- a/shell/directives/clean-tooltip.js +++ b/shell/directives/clean-tooltip.js @@ -13,10 +13,10 @@ function purifyContent(value) { } } -function bind(el, { value, oldValue, modifiers }) { +function beforeMount(el, { value, oldValue, modifiers }) { const purifiedValue = purifyContent(value); - VTooltip.bind( + VTooltip.beforeMount( el, { value: purifiedValue, oldValue, modifiers @@ -25,8 +25,8 @@ function bind(el, { value, oldValue, modifiers }) { const cleanTooltipDirective = { ...VTooltip, - bind, - update: bind, + beforeMount, + updated: beforeMount, }; export default cleanTooltipDirective; From ba5c899e6d2abe472c03348f43fc7b2d44dadbc8 Mon Sep 17 00:00:00 2001 From: Phillip Rak Date: Fri, 8 Nov 2024 11:27:07 -0700 Subject: [PATCH 2/2] Replace all usages of `v-tooltip` with `v-clean-tooltip` Signed-off-by: Phillip Rak --- pkg/aks/components/AksNodePool.vue | 4 ++-- shell/components/SideNav.vue | 2 +- shell/components/TableDataUserIcon.vue | 2 +- shell/components/nav/TopLevelMenu.vue | 22 +++++++++++----------- 4 files changed, 15 insertions(+), 15 deletions(-) diff --git a/pkg/aks/components/AksNodePool.vue b/pkg/aks/components/AksNodePool.vue index f81abf459ba..e293eb3e484 100644 --- a/pkg/aks/components/AksNodePool.vue +++ b/pkg/aks/components/AksNodePool.vue @@ -379,7 +379,7 @@ export default defineComponent({
{{ t('aks.nodePools.taints.label') }}
@@ -455,7 +455,7 @@ export default defineComponent({
{{ t('labels.labels.title') }}
diff --git a/shell/components/SideNav.vue b/shell/components/SideNav.vue index 237f191d8cd..e69e3b05512 100644 --- a/shell/components/SideNav.vue +++ b/shell/components/SideNav.vue @@ -482,7 +482,7 @@ export default {