1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-14 15:13:29 +01:00
invoiceninja/resources/views/portal/ninja2020/layout/app.blade.php

194 lines
7.7 KiB
PHP
Raw Normal View History

2020-03-23 18:10:42 +01:00
<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}">
<head>
<!-- Error: {{ session('error') }} -->
2022-12-07 08:50:36 +01:00
@if ($company && $company->matomo_url && $company->matomo_id)
2022-12-05 15:20:30 +01:00
<script>
var _paq = window._paq = window._paq || [];
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
2023-01-16 12:40:54 +01:00
@if (auth()->guard('contact')->check())
_paq.push(['setUserId', '{{ auth()->guard('contact')->user()->present()->name() }}']);
@endif
2022-12-05 15:20:30 +01:00
(function() {
2022-12-07 08:50:36 +01:00
var u="{{ $company->matomo_url }}";
2022-12-05 15:20:30 +01:00
_paq.push(['setTrackerUrl', u+'matomo.php']);
2022-12-07 08:50:36 +01:00
_paq.push(['setSiteId', '{{ $company->matomo_id }}']);
2022-12-05 15:20:30 +01:00
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
})();
</script>
2022-12-07 08:50:36 +01:00
<noscript><p><img src="{{ auth()->guard('contact')->user()->company->matomo_url }}/matomo.php?idsite={{ auth()->guard('contact')->user()->company->matomo_id }}&amp;rec=1" style="border:0;" alt="" /></p></noscript>
2022-12-05 15:20:30 +01:00
@elseif (config('services.analytics.tracking_id'))
2020-03-23 18:10:42 +01:00
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-122229484-1"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());
gtag('config', '{{ config('services.analytics.tracking_id') }}', {'anonymize_ip': true});
function trackEvent(category, action) {
ga('send', 'event', category, action, this.src);
}
</script>
<script>
Vue.config.devtools = true;
</script>
@else
<script>
function gtag() {
}
</script>
@endif
<!-- Title -->
2022-03-29 02:35:45 +02:00
@if(isset($company->account) && !$company->account->isPaid())
2021-07-29 23:52:58 +02:00
<title>@yield('meta_title', '') Invoice Ninja</title>
@elseif(isset($company) && !is_null($company))
<title>@yield('meta_title', '') {{ $company->present()->name() }}</title>
@else
<title>@yield('meta_title', '')</title>
@endif
2020-03-23 18:10:42 +01:00
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="@yield('meta_description')"/>
2022-12-17 14:13:12 +01:00
2020-03-23 18:10:42 +01:00
<!-- CSRF Token -->
<meta name="csrf-token" content="{{ csrf_token() }}">
<!-- Scripts -->
<script src="{{ mix('js/app.js') }}" defer></script>
2021-10-11 14:58:26 +02:00
<script src="{{ asset('vendor/alpinejs@2.8.2/alpine.js') }}" defer></script>
2020-03-23 18:10:42 +01:00
<!-- Fonts -->
2022-09-30 07:23:18 +02:00
<style>
@font-face {
font-family: 'Open Sans';
font-style: normal;
font-weight: 400;
font-stretch: 100%;
font-display: swap;
src: url( {{asset('css/memSYaGs126MiZpBA-UvWbX2vVnXBbObj2OVZyOOSr4dVJWUgsjZ0B4gaVI.woff2')}}) format('woff2');
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
</style>
2020-03-23 18:10:42 +01:00
<!-- Styles -->
<link href="{{ mix('css/app.css') }}" rel="stylesheet">
2021-02-11 14:26:37 +01:00
@if(auth()->guard('contact')->user() && !auth()->guard('contact')->user()->user->account->isPaid())
2021-02-11 14:26:37 +01:00
<link href="{{ asset('favicon.png') }}" rel="shortcut icon" type="image/png">
@endif
2020-03-23 18:10:42 +01:00
<link rel="canonical" href="{{ config('ninja.site_url') }}/{{ request()->path() }}"/>
@if((bool) \App\Utils\Ninja::isSelfHost())
2020-11-12 12:29:16 +01:00
<style>
{!! $client->getSetting('portal_custom_css') !!}
</style>
@endif
@livewireStyles
2020-03-23 18:10:42 +01:00
{{-- Feel free to push anything to header using @push('header') --}}
@stack('head')
2022-03-29 02:35:17 +02:00
@if((isset($company) && $company->account->isPaid() && !empty($client->getSetting('portal_custom_head'))) || ((bool) \App\Utils\Ninja::isSelfHost() && !empty($client->getSetting('portal_custom_head'))))
<div class="py-1 text-sm text-center text-white bg-primary">
{!! $client->getSetting('portal_custom_head') !!}
</div>
2020-11-12 12:29:16 +01:00
@endif
2020-11-19 13:41:19 +01:00
2021-10-11 14:54:02 +02:00
<link rel="stylesheet" type="text/css" href="{{ asset('vendor/cookieconsent@3/cookieconsent.min.css') }}" />
2020-03-23 18:10:42 +01:00
</head>
@include('portal.ninja2020.components.primary-color')
2020-03-23 18:10:42 +01:00
<body class="antialiased">
@if(session()->has('message'))
2020-11-19 13:41:19 +01:00
<div class="py-1 text-sm text-center text-white bg-primary disposable-alert">
{{ session('message') }}
</div>
@endif
2020-03-23 18:10:42 +01:00
@component('portal.ninja2020.components.general.sidebar.main')
@yield('body')
@endcomponent
@livewireScripts
2020-11-19 13:41:19 +01:00
2021-10-11 14:54:02 +02:00
<script src="{{ asset('vendor/cookieconsent@3/cookieconsent.min.js') }}" data-cfasync="false"></script>
2020-11-19 13:41:19 +01:00
<script>
window.addEventListener("load", function(){
if (! window.cookieconsent) {
return;
}
window.cookieconsent.initialise({
"palette": {
"popup": {
"background": "#000"
},
"button": {
"background": "#f1d600"
},
},
"content": {
2021-10-04 14:29:15 +02:00
"href": "{{ config('ninja.privacy_policy_url.hosted') }}",
2022-12-01 23:45:38 +01:00
"message": "{{ ctrans('texts.cookie_message')}}",
"dismiss": "{{ ctrans('texts.got_it')}}",
"link": "{{ ctrans('texts.learn_more')}}",
2020-11-19 13:41:19 +01:00
}
})}
);
</script>
@if($company && $company->google_analytics_key)
<script>
(function (i, s, o, g, r, a, m) {
i['GoogleAnalyticsObject'] = r;
i[r] = i[r] || function () {
(i[r].q = i[r].q || []).push(arguments)
}, i[r].l = 1 * new Date();
a = s.createElement(o),
m = s.getElementsByTagName(o)[0];
a.async = 1;
a.src = g;
m.parentNode.insertBefore(a, m)
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
ga('create', '{{ $company->google_analytics_key }}', 'auto');
ga('set', 'anonymizeIp', true);
ga('send', 'pageview');
function trackEvent(category, action) {
ga('send', 'event', category, action, this.src);
}
</script>
@endif
2022-12-17 14:13:12 +01:00
2020-03-23 18:10:42 +01:00
</body>
<footer>
@yield('footer')
@stack('footer')
2022-11-19 00:58:32 +01:00
@if($company && $company->account->isPaid() && !empty($client->getSetting('portal_custom_footer')))
<div class="py-1 text-sm text-center text-white bg-primary">
{!! $client->getSetting('portal_custom_footer') !!}
</div>
2020-11-12 12:29:16 +01:00
@endif
2020-03-23 18:10:42 +01:00
</footer>
@if((bool) \App\Utils\Ninja::isSelfHost())
2020-11-12 12:29:16 +01:00
<script>
{!! $client->getSetting('portal_custom_js') !!}
</script>
@endif
2020-03-23 18:10:42 +01:00
</html>