From 4d9c1e120b93f2d8914cf8dc820bdb94d6d2cf15 Mon Sep 17 00:00:00 2001 From: Julian Prieber <60265788+JulianPrieber@users.noreply.github.com> Date: Wed, 7 Sep 2022 19:32:36 +0200 Subject: [PATCH] Implemented updates for themes v2 --- config/view.php | 1 + resources/views/littlelink.blade.php | 49 +++++++++++++++++++++------- 2 files changed, 39 insertions(+), 11 deletions(-) diff --git a/config/view.php b/config/view.php index 22b8a18..1a27ed6 100755 --- a/config/view.php +++ b/config/view.php @@ -15,6 +15,7 @@ return [ 'paths' => [ resource_path('views'), + base_path('themes'), ], /* diff --git a/resources/views/littlelink.blade.php b/resources/views/littlelink.blade.php index 44811c5..d15f533 100644 --- a/resources/views/littlelink.blade.php +++ b/resources/views/littlelink.blade.php @@ -3,6 +3,28 @@ +@foreach($information as $info) @php $GLOBALS['themeName'] = $info->theme; @endphp @endforeach + + + +@if(theme('enable_custom_code') == "true" and theme('enable_custom_head') == "true")@include($GLOBALS['themeName'] . '.extra.custom-head')@endif + @include('layouts.analytics') @if(config('advanced-config.littlelink_title') != '' and env('HOME_URL') === '') @@ -102,6 +124,8 @@ +@if(theme('enable_custom_code') == "true" and theme('enable_custom_body') == "true")@include($GLOBALS['themeName'] . '.extra.custom-body')@endif + @if($info->theme != '' and $info->theme != 'default')
@@ -202,7 +226,7 @@ function get_operating_system() { @else - + @endif @@ -235,19 +259,19 @@ function get_operating_system() { @foreach($links as $link) @php $linkName = str_replace('default ','',$link->name) @endphp @if($link->button_id === 0) -
{{ $link->title }}
+
{{ $link->title }}
@elseif($link->name === "phone") -
button-icon{{ $link->title }}
- @elseif($link->name === "custom" and $link->custom_css === "" or $link->custom_css === "NULL") -
{{ $link->title }}
+
button-icon{{ $link->title }}
+ @elseif($link->name === "custom" and $link->custom_css === "" or $link->custom_css === "NULL" or theme('allow_custom_buttons') == "false") +
{{ $link->title }}
@elseif($link->name === "custom" and $link->custom_css != "") -
{{ $link->title }}
+
{{ $link->title }}
@elseif($link->name === "buy me a coffee") -
button-iconBuy me a Coffee
- @elseif($link->name === "custom_website"and $link->custom_css === "" or $link->custom_css === "NULL") -
button-icon{{ $link->title }}
+
button-iconBuy me a Coffee
+ @elseif($link->name === "custom_website"and $link->custom_css === "" or $link->custom_css === "NULL" or theme('allow_custom_buttons') == "false") +
button-icon{{ $link->title }}
@elseif($link->name === "custom_website" and $link->custom_css != "") -
button-icon{{ $link->title }}
+
button-icon{{ $link->title }}
@elseif($link->name === "space") title) and $link->title < 10) @@ -260,7 +284,7 @@ function get_operating_system() { @elseif($link->name === "heading")

{{ $link->title }}

@else -
button-icon{{ ucfirst($linkName) }}
+
button-icon{{ ucfirst($linkName) }}
@endif @endforeach @@ -269,5 +293,8 @@ function get_operating_system() {
+ +@if(theme('enable_custom_code') == "true" and theme('enable_custom_body_end') == "true")@include($GLOBALS['themeName'] . '.extra.custom-body-end')@endif +