@extends('layouts.landing-page') @section('content') @php $bgUrl = app(\App\Services\UserServices::class)->getBgProfile($artist, 'lg'); $avatarUrl = app(\App\Services\UserServices::class)->getAvatar($artist, 'md'); $genres = app(\App\Services\UserServices::class)->getAllGenre($artist); $roleArray = $artist->getRoleNames(); $roleContent = ''; foreach ($roleArray as $role) { if ($role == 'Composer') { $roleContent = $roleContent . ' 🎵 Composer '; } if ($role == 'Artist') { $roleContent = $roleContent . ' 🎤 Artist '; } if ($role == 'Cover Creator') { $roleContent = $roleContent . ' 📹 Cover Creator '; } } @endphp
{{-- {{ $artist->name }} Banner --}} @if (isset($banner) && $banner && $banner->picture) {{ $banner->title ?? 'Featured artist' }} @else Featured artist default @endif
{{ $artist->name }}

{{ $artist->name }}

@if ($artist->hasRole('Artist'))
@endif
{!! $roleContent !!}
@if (auth()->check() && auth()->user()->id !== $artist->id) @php $isFollowingClass = $isFollowing ? 'following' : ''; $iconClass = $isFollowing ? 'ti-check' : 'ti-user-plus'; $buttonText = $isFollowing ? 'Following' : 'Follow'; @endphp @endif
@foreach ($socialMedia as $media) {!! $media['icon'] !!} @endforeach
@php $biography = 'Belum terdapat biografi'; if ($artist->profile) { $biography = $artist->profile->bio; } $maxLength = 255; $isLong = strlen($biography) > $maxLength; $shortBio = $isLong ? substr($biography, 0, $maxLength) : $biography; @endphp {{--

{{ $shortBio }}@if ($isLong) ... @endif

@if ($isLong) @endif
--}} {{-- Div ini akan menampung data biografi --}}

{{ $shortBio }}

@if ($isLong) @endif

Lagu Yang dirilis

@php $index = 0; $totalViews = 0; @endphp @forelse ($songPerforms as $song) @php $index++; $imgUrl = app(\App\Services\SongServices::class)->getCoverImageS3($song->song, 'sm'); $penayangan = app(\App\Services\SongServices::class)->totalViews($song->song->id); $totalPenayangan = app(\App\Services\SongServices::class)->getRawPlayCount($song->song->id); $totalViews += $totalPenayangan; @endphp
{{ $song->song->title ?? '' }}
{{ $song->song->title ?? '' }}
{{ $index }}
{{ $song->song->genre->name ?? '' }}
@empty
belum terdapat lagu
@endforelse
@if ($totalSongs > 5) @endif
{{ $totalSongs }} Lagu
{{ number_format($totalViews) }} Total Penayangan

Lagu Yang Di Nyanyikan (Official)

@php @endphp @forelse ($songOfficial as $song) @php $imgUrl = app(\App\Services\SongServices::class)->getCoverImageS3($song->song, 'md'); @endphp
{{ $song->song->title }}

{{ $song->song->title ?? '' }}

{{ $song->song->album ? $song->song->album->title : 'no album' }} • {{ $song->song->created_at->format('Y') }}

@empty belum terdapat lagu @endforelse

Lagu Yang di Cover

@php @endphp @forelse ($songCover as $song) @php $imgUrl = app(\App\Services\SongServices::class)->getCoverImageS3($song->song, 'md'); @endphp
{{ $song->song->title ?? '' }}

{{ $song->song->title ?? '' }}

{{ $song->song->album ? $song->song->album->title : 'no album' }} • {{ $song->song->created_at->format('Y') }}

@empty belum terdapat cover @endforelse
@endsection @section('scripts') @endsection