|
Server : Apache/2.4.41 (Ubuntu) System : Linux vmi1525618.contaboserver.net 5.4.0-105-generic #119-Ubuntu SMP Mon Mar 7 18:49:24 UTC 2022 x86_64 User : www-data ( 33) PHP Version : 8.2.12 Disable Function : NONE Directory : /var/www/erp.theinteractive.co.in/resources/views/vendor/Chatify/layouts/ |
Upload File : |
{{-- -------------------- The default card (white) -------------------- --}}
@if($viewType == 'default')
@if($from_id != $to_id)
<div class="message-card" data-id="{{ $id }}">
<p>{!! ($message == null && $attachment != null && @$attachment[2] != 'file') ? $attachment[1] : nl2br($message) !!}
<sub title="{{ $fullTime }}">{{ $time }}</sub>
{{-- If attachment is a file --}}
@if(@$attachment[2] == 'file')
<a href="{{ route(config('chatify.attachments.download_route_name'),['fileName'=>$attachment[0]]) }}" style="color: #595959;" class="file-download">
<span class="ti ti-file"></span> {{$attachment[1]}}</a>
@endif
</p>
</div>
{{-- If attachment is an image --}}
@if(@$attachment[2] == 'image')
<div>
<div class="message-card">
<div class="image-file chat-image" style="width: 250px; height: 150px;background-image: url('{{ asset('storage/'.config('chatify.attachments.folder').'/'.$attachment[0]) }}')">
</div>
</div>
</div>
@endif
@endif
@endif
{{-- -------------------- Sender card (owner) -------------------- --}}
@if($viewType == 'sender')
<div class="message-card mc-sender" data-id="{{ $id }}">
<p>{!! ($message == null && $attachment != null && @$attachment[2] != 'file') ? $attachment[1] : nl2br($message) !!}
<sub title="{{ $fullTime }}" class="message-time">
<span class="ti ti-{{ $seen > 0 ? 'check-double' : 'check' }} seen"></span> {{ $time }}</sub>
{{-- If attachment is a file --}}
@if(@$attachment[2] == 'file')
<a href="{{ route(config('chatify.attachments.download_route_name'),['fileName'=>$attachment[0]]) }}" class="file-download">
<span class="ti ti-file"></span> {{$attachment[1]}}</a>
@endif
</p>
</div>
{{-- If attachment is an image --}}
@if(@$attachment[2] == 'image')
<div>
<div class="message-card mc-sender">
<div class="image-file chat-image" style="width: 250px; height: 150px;background-image: url('{{ \App\Models\Utility::get_file(config('chatify.attachments.folder').'/'.$attachment[0]) }}')">
</div>
</div>
</div>
@endif
@endif