Skip to content

Commit ecebb3d

Browse files
committed
fix: fix tooltip for the "Remove selection" button
1 parent a921354 commit ecebb3d

File tree

2 files changed

+15
-16
lines changed

2 files changed

+15
-16
lines changed

adminforth/spa/src/afcl/Tooltip.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
</div>
55
<div
66
role="tooltip"
7-
class="absolute z-10 invisible inline-block px-3 py-2 text-sm font-medium text-white transition-opacity duration-300 bg-gray-900 rounded-lg shadow-sm opacity-0 tooltip dark:bg-gray-700"
7+
class="absolute z-20 invisible inline-block px-3 py-2 text-sm font-medium text-white transition-opacity duration-300 bg-gray-900 rounded-lg shadow-sm opacity-0 tooltip dark:bg-gray-700"
88
ref="tooltip"
99
>
1010
<slot name="tooltip"></slot>

adminforth/spa/src/views/ListView.vue

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,19 @@
1717
/>
1818

1919
<BreadcrumbsWithButtons>
20-
<button
21-
@click="()=>{checkboxes = []}"
22-
v-if="checkboxes.length"
23-
data-tooltip-target="tooltip-remove-all"
24-
class="flex gap-1 items-center py-1 px-3 me-2 text-sm font-medium text-gray-900 focus:outline-none bg-white rounded border border-gray-300 hover:bg-gray-100 hover:text-lightPrimary focus:z-10 focus:ring-4 focus:ring-gray-100 dark:focus:ring-gray-700 dark:bg-darkListTable dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700 rounded-default"
25-
>
26-
<IconBanOutline class="w-5 h-5 "/>
27-
28-
<div id="tooltip-remove-all" role="tooltip"
29-
class="absolute z-10 invisible inline-block px-3 py-2 text-sm font-medium text-white transition-opacity duration-300 bg-gray-900 rounded-lg shadow-sm opacity-0 tooltip dark:bg-gray-700">
30-
{{ $t('Remove selection') }}
31-
<div class="tooltip-arrow" data-popper-arrow></div>
32-
</div>
33-
</button>
20+
<button
21+
@click="()=>{checkboxes = []}"
22+
v-if="checkboxes.length"
23+
data-tooltip-target="tooltip-remove-all"
24+
class="flex gap-1 items-center py-1 px-3 me-2 text-sm font-medium text-gray-900 focus:outline-none bg-white rounded border border-gray-300 hover:bg-gray-100 hover:text-lightPrimary focus:z-10 focus:ring-4 focus:ring-gray-100 dark:focus:ring-gray-700 dark:bg-darkListTable dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700 rounded-default"
25+
>
26+
<Tooltip>
27+
<IconBanOutline class="w-5 h-5 "/>
28+
<template #tooltip >
29+
Remove selection
30+
</template>
31+
</Tooltip>
32+
</button>
3433

3534
<button
3635
v-if="checkboxes.length"
@@ -165,7 +164,7 @@ import { useRoute } from 'vue-router';
165164
import { showErrorTost } from '@/composables/useFrontendApi'
166165
import { getCustomComponent, initThreeDotsDropdown } from '@/utils';
167166
import ThreeDotsMenu from '@/components/ThreeDotsMenu.vue';
168-
167+
import { Tooltip } from '@/afcl'
169168
170169
import {
171170
IconBanOutline,

0 commit comments

Comments
 (0)