disable/default icon control

This commit is contained in:
Burak Civan 2022-10-17 12:44:22 +03:00
parent e9aa7f81f4
commit f755efa947
5 changed files with 23 additions and 14 deletions

View File

@ -385,4 +385,11 @@ document.querySelectorAll('[data-truncate]').forEach((truncate) => {
}
});
});
//disable/enable icons ejected from data-truncate
document.querySelectorAll('[data-index-icon]').forEach((defaultText) => {
defaultText.parentElement.parentElement.parentElement.appendChild(defaultText);
});
//disable/enable icons ejected from data-truncate
//margue animation for truncated text

View File

@ -64,9 +64,7 @@
<x-table.td class="w-6/12 sm:w-5/12">
<x-slot name="first" class="flex font-bold">
<div class="truncate">
{{ $item->name }}
</div>
{{ $item->name }}
@if (! $item->enabled)
<x-index.disable text="{{ trans_choice('general.accounts', 1) }}" />

View File

@ -1,5 +1,7 @@
<x-tooltip id="{{ $id }}" placement="{{ $position }}" message="{{ $text }}">
<span class="material-icons{{ $iconType }} text-purple text-sm ml-2">
{{ $icon }}
</span>
</x-tooltip>
<div data-index-icon>
<x-tooltip id="{{ $id }}" placement="{{ $position }}" message="{{ $text }}">
<span class="material-icons{{ $iconType }} text-purple text-sm ml-2">
{{ $icon }}
</span>
</x-tooltip>
</div>

View File

@ -1,5 +1,7 @@
<x-tooltip id="{{ $id }}" placement="{{ $position }}" message="{{ $disableText }}">
<span class="material-icons{{ $iconType }} text-red text-sm ml-2">
{{ $icon }}
</span>
</x-tooltip>
<div data-index-icon>
<x-tooltip id="{{ $id }}" placement="{{ $position }}" message="{{ $disableText }}">
<span class="material-icons{{ $iconType }} text-red text-sm ml-2">
{{ $icon }}
</span>
</x-tooltip>
</div>

View File

@ -1,4 +1,4 @@
<div class="flex lg:block truncate">
<div data-truncate-parent class="flex lg:block truncate">
<div
@class([ $width ])
data-truncate