@extends('layouts.app') @section('site_title', formatTitle([$link->alias, __('Overview'), __('Stats'), config('settings.title')])) @section('head_content') @if (count(request()->all()) > 0) @endif @endsection @section('content')
@if (config('settings.ad_stats_header')) @if(!Auth::check() || !Auth::user()->active_plan->features->no_ads)
{!! config('settings.ad_stats_header') !!}
@endif @endif @include('stats.partials.header') @if($link->user->can('linkStats', [App\Models\User::class]) || (Auth::check() && Auth::user()->isAdmin()))
{{ __('Clicks') }}
@include('icons.info', ['class' => 'w-4 h-4 fill-current text-muted'])
@include('stats.partials.growth', ['growthCurrent' => $totalClicks, 'growthPrevious' => $totalClicksOld])
{{ number_format($totalClicks, 0, __('.'), __(',')) }}
{{ __('Original link') }}
@include('icons.info', ['class' => 'w-4 h-4 fill-current text-muted'])
{{ mb_strlen($link->url) }}
{{ __('Shortened link') }}
@include('icons.info', ['class' => 'w-4 h-4 fill-current text-muted'])
{{ mb_strlen($link->shortUrl) }}
{{ __('Referrers') }}
@if(count($referrers) == 0) {{ __('No data') }}. @else
{{ __('Website') }}
{{ __('Clicks') }}
@foreach($referrers as $referrer)
@if($referrer->value)
@else
{{ __('Direct, Email, SMS') }}
@endif
{{ number_format($referrer->count, 0, __('.'), __(',')) }}
@endforeach
@endif
@if(count($referrers) > 0) @endif
{{ __('Countries') }}
@if(count($countries) == 0) {{ __('No data') }}. @else
{{ __('Name') }}
{{ __('Clicks') }}
@foreach($countries as $country)
@if(!empty(explode(':', $country->value)[1])) {{ explode(':', $country->value)[1] }} @else {{ __('Unknown') }} @endif
{{ number_format($country->count, 0, __('.'), __(',')) }}
@endforeach
@endif
@if(count($countries) > 0) @endif
{{ __('Browsers') }}
@if(count($browsers) == 0) {{ __('No data') }}. @else
{{ __('Name') }}
{{ __('Clicks') }}
@foreach($browsers as $browser)
@if($browser->value) {{ $browser->value }} @else {{ __('Unknown') }} @endif
{{ number_format($browser->count, 0, __('.'), __(',')) }}
@endforeach
@endif
@if(count($browsers) > 0) @endif
{{ __('Operating systems') }}
@if(count($operatingSystems) == 0) {{ __('No data') }}. @else
{{ __('Name') }}
{{ __('Clicks') }}
@foreach($operatingSystems as $operatingSystem)
@if($operatingSystem->value) {{ $operatingSystem->value }} @else {{ __('Unknown') }} @endif
{{ number_format($operatingSystem->count, 0, __('.'), __(',')) }}
@endforeach
@endif
@if(count($operatingSystems) > 0) @endif
@else
@if(enabledPaymentProcessors()) @if(Auth::check() && $link->user->id == Auth::user()->id) @include('shared.features.locked') @else @include('shared.features.unavailable') @endif @else @include('shared.features.unavailable') @endif
@endif
{{ __('Report generated on :date at :time (UTC :offset).', ['date' => (clone $now)->tz(Auth::user()->timezone ?? config('settings.timezone'))->format(__('Y-m-d')), 'time' => (clone $now)->tz(Auth::user()->timezone ?? config('settings.timezone'))->format('H:i:s'), 'offset' => (clone $now)->tz(Auth::user()->timezone ?? config('settings.timezone'))->getOffsetString()]) }} {{ __('Refresh report') }}
@if (config('settings.ad_stats_footer')) @if(!Auth::check() || !Auth::user()->active_plan->features->no_ads)
{!! config('settings.ad_stats_footer') !!}
@endif @endif @include('shared.modals.share-link')
@endsection @include('shared.sidebars.user')