45 lines
1.4 KiB
PHP
Raw Normal View History

2022-10-18 17:18:32 +03:00
<td class="{{ $class }}" {{ $attributes }}>
2022-06-01 10:15:55 +03:00
@if (!empty($first))
@php
$first_attributes = $first->attributes;
if ((! $first->attributes->has('override')) || ($first->attributes->has('override') && ! in_array('class', explode(',', $first->attributes->get('override'))))) {
$first_attributes = $first->attributes->merge(['class' => 'font-medium truncate']);
}
@endphp
<div {{ $first_attributes }}>
2022-10-21 10:56:33 +03:00
<!--so that the animation does not overflow the width. With javascript will add (overflow-x-hidden) class name-->
2022-10-18 16:29:28 +03:00
<div>
2022-10-21 10:56:33 +03:00
<!-- this tag use for calculate width of text and parent element -->
<span data-truncate-marquee>
{!! $first !!}
</span>
2022-10-18 16:29:28 +03:00
</div>
2022-06-01 10:15:55 +03:00
</div>
@endif
@if (!empty($second))
@php
$second_attributes = $second->attributes;
if ((! $second->attributes->has('override')) || ($second->attributes->has('override') && ! in_array('class', explode(',', $second->attributes->get('override'))))) {
$second_attributes = $second->attributes->merge(['class' => 'font-normal truncate']);
}
@endphp
<div {{ $second_attributes }}>
2022-10-18 16:29:28 +03:00
<div>
2022-10-21 10:56:33 +03:00
<span data-truncate-marquee>
{!! $second !!}
</span>
2022-10-18 16:29:28 +03:00
</div>
2022-10-21 10:56:33 +03:00
2022-06-01 10:15:55 +03:00
</div>
@endif
2022-10-18 16:50:27 +03:00
2022-10-18 16:29:28 +03:00
<div>
2022-10-21 10:56:33 +03:00
<span data-truncate-marquee>
{{ $slot }}
</span>
2022-10-18 16:29:28 +03:00
</div>
2022-06-01 10:15:55 +03:00
</td>