Add client open mode preference (same tab / new window) to user settings

This commit is contained in:
root
2026-06-26 19:53:32 +02:00
parent 6add7cdfb1
commit 9c92cd297a
8 changed files with 200 additions and 37 deletions
@@ -37,12 +37,13 @@
</div>
<div class="self-start lg:ml-14 w-full lg:w-64">
<a href="{{ route('nitro-client') }}">
<button type="submit" class="cms-button w-full text-white bg-yellow-500 border-2 border-yellow-300 w-full rounded transition duration-300 ease-in-out hover:scale-[102%] py-2 px-4">
{{ __('Go to :hotel', ['hotel' => setting('hotel_name')]) }}
</button>
</a>
</div>
@php $openMode = auth()->user()->preferences['client_open_mode'] ?? 'same'; @endphp
<a href="{{ route('nitro-client') }}" @if($openMode === 'new_window') target="_blank" rel="noopener" @endif>
<button type="submit" class="cms-button w-full text-white bg-yellow-500 border-2 border-yellow-300 w-full rounded transition duration-300 ease-in-out hover:scale-[102%] py-2 px-4">
{{ __('Go to :hotel', ['hotel' => setting('hotel_name')]) }}
</button>
</a>
</div>
</div>
<div class="absolute w-full bottom-0 left-0 h-20 bg-gray-900 py-4 lg:pl-64 px-4 lg:px-0">