diff --git a/content/includes/analytics.blade.php b/content/includes/analytics.blade.php new file mode 100644 index 0000000..b2cde9a --- /dev/null +++ b/content/includes/analytics.blade.php @@ -0,0 +1,87 @@ +@if(App::environment('production')) + @if(isset($_COOKIE["cookies-consent"]) && $_COOKIE["cookies-consent"]) + @if (!empty(config('settings.facebook'))) + + + @endif + + + + @if (!empty(config('settings.hotjar'))) + + @endif + + + + @if (!empty(config('settings.analytics'))) + + + @endif + + @if (!empty(config('settings.intercom')) && !empty(config('settings.intercom_key'))) + @if(Auth::check()) + @php ($hash_hmac = hash_hmac('sha256', Auth::user()->id, config('settings.intercom_key'))) + + @elseif(isset($invitedUser) && $invitedUser->invite != null) + @php ($hash_hmac = hash_hmac('sha256', $invitedUser->id, config('settings.intercom_key'))) + + @else + + @endif + + @endif + @endif +@endif \ No newline at end of file diff --git a/content/includes/meta.blade.php b/content/includes/meta.blade.php index fbd057e..1228f51 100644 --- a/content/includes/meta.blade.php +++ b/content/includes/meta.blade.php @@ -2,45 +2,34 @@ {{config('settings.name')}} - - - - @if(Route::currentRouteName() == 'index') - - - - - - - - - - - - - - - - + + + + + + + + + + + @elseif(str_starts_with(Route::currentRouteName(), 'page.')) - - - - - - - - - - - - + + + + + + + + + + @elseif(Route::currentRouteName() == 'lists.show' and isset($content)) diff --git a/content/master.blade.php b/content/master.blade.php index 8e21c72..19483ca 100644 --- a/content/master.blade.php +++ b/content/master.blade.php @@ -5,6 +5,7 @@ @include('template.'.config('settings.template').'.content.includes.meta') @include('template.'.config('settings.template').'.content.includes.css') + @include('template.'.config('settings.template').'.content.analytics.css') @yield('head')