unused developments ejected

This commit is contained in:
Burak Civan 2022-10-18 17:18:32 +03:00
parent 3ab2129a35
commit eb7dcbfb05
8 changed files with 13 additions and 62 deletions

View File

@ -1,32 +0,0 @@
<?php
namespace App\View\Components;
use App\Abstracts\View\Component;
use Illuminate\Support\Str;
class MargueeText extends Component
{
public $width;
/**
* Create a new component instance.
*
* @return void
*/
public function __construct(
string $width = 'auto'
) {
$this->width = $width;
}
/**
* Get the view / contents that represent the component.
*
* @return \Illuminate\Contracts\View\View|string
*/
public function render()
{
return view('components.marguee-text');
}
}

View File

@ -359,7 +359,7 @@ if (navigator.userAgent.search("Firefox") >= 0) {
//Firefox show modal for icon set //Firefox show modal for icon set
//margue animation for truncated text //margue animation for truncated text
document.querySelectorAll('[data-truncate]').forEach((truncate) => { function marqueeAnimation(truncate) {
if (truncate.offsetWidth > truncate.parentElement.clientWidth || truncate.offsetWidth > truncate.parentElement.parentElement.clientWidth) { if (truncate.offsetWidth > truncate.parentElement.clientWidth || truncate.offsetWidth > truncate.parentElement.parentElement.clientWidth) {
truncate.addEventListener('mouseover', function () { truncate.addEventListener('mouseover', function () {
truncate.parentElement.style.animationPlayState = 'running'; truncate.parentElement.style.animationPlayState = 'running';
@ -379,6 +379,10 @@ document.querySelectorAll('[data-truncate]').forEach((truncate) => {
truncate.classList.add('truncate'); truncate.classList.add('truncate');
truncate.parentElement.classList.add('truncate'); truncate.parentElement.classList.add('truncate');
} }
}
document.querySelectorAll('[data-truncate]').forEach((truncate) => {
marqueeAnimation(truncate);
}); });
//disable/enable icons ejected from data-truncate //disable/enable icons ejected from data-truncate

View File

@ -78,9 +78,9 @@
<x-table.td class="w-3/12" hidden-mobile> <x-table.td class="w-3/12" hidden-mobile>
<x-slot name="first" class="flex" override="class"> <x-slot name="first" class="flex" override="class">
<span class="font-bold"> <div class="font-bold truncate">
<x-date date="{{ $item->created_at }}" /> <x-date date="{{ $item->created_at }}" />
</span> </div>
@if (! $item->reconciled) @if (! $item->reconciled)
<x-index.disable text="{{ trans('reconciliations.in_progress') }}" /> <x-index.disable text="{{ trans('reconciliations.in_progress') }}" />

View File

@ -153,7 +153,7 @@
<x-slot name="first"> <x-slot name="first">
{{ $item->type_title }} {{ $item->type_title }}
</x-slot> </x-slot>
<x-slot name="second"> <x-slot name="second" class="flex items-center">
<div class="flex items-center"> <div class="flex items-center">
<x-index.category :model="$item->category" /> <x-index.category :model="$item->category" />
</div> </div>

View File

@ -1,21 +0,0 @@
@php
$slot_text_length = strlen($slot);
$slot_isHtml = strlen(strip_tags($slot)) < strlen($slot);
@endphp
@if ($slot_text_length >= '30' && ! $slot_isHtml)
<div data-truncate-parent class="flex lg:block truncate">
<div
@class([
$width,
'truncate',
])
data-truncate
>
{!! $slot !!}
</div>
</div>
@else
{!! $slot !!}
@endif

View File

@ -1,4 +1,4 @@
<td data-truncate-table class="{{ $class }}" {{ $attributes }}> <td class="{{ $class }}" {{ $attributes }}>
@if (!empty($first)) @if (!empty($first))
@php @php
$first_attributes = $first->attributes; $first_attributes = $first->attributes;

View File

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

View File

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