mirror of
https://github.com/HolgerHatGarKeineNode/einundzwanzig-app.git
synced 2025-12-13 23:56:47 +00:00
- Updated settings route links to include `country` parameter dynamically resolved from session. - Improved relational queries by adding `city.country` to meetups map and `coursesEvents.course` to lecturers data.
179 lines
7.3 KiB
PHP
179 lines
7.3 KiB
PHP
<!DOCTYPE html>
|
|
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" class="dark">
|
|
<head>
|
|
@include('partials.head')
|
|
</head>
|
|
<body class="min-h-screen bg-white dark:bg-zinc-800">
|
|
<flux:toast.group>
|
|
<flux:toast/>
|
|
</flux:toast.group>
|
|
<flux:header container class="border-b border-zinc-200 bg-zinc-50 dark:border-zinc-700 dark:bg-zinc-900">
|
|
<flux:sidebar.toggle class="lg:hidden" icon="bars-2" inset="left"/>
|
|
|
|
<a href="{{ route('dashboard', ['country' => str(session('lang_country', 'de'))->after('-')->lower()]) }}" class="ms-2 me-5 flex items-center space-x-2 rtl:space-x-reverse lg:ms-0"
|
|
wire:navigate>
|
|
<x-app-logo/>
|
|
</a>
|
|
|
|
<flux:navbar class="-mb-px max-lg:hidden">
|
|
<flux:navbar.item icon="layout-grid" :href="route('dashboard', ['country' => str(session('lang_country', 'de'))->after('-')->lower()])"
|
|
:current="request()->routeIs('dashboard')" wire:navigate>
|
|
{{ __('Dashboard') }}
|
|
</flux:navbar.item>
|
|
</flux:navbar>
|
|
|
|
<flux:spacer/>
|
|
|
|
<flux:navbar class="me-1.5 space-x-0.5 rtl:space-x-reverse py-0!">
|
|
<flux:tooltip :content="__('Search')" position="bottom">
|
|
<flux:navbar.item class="!h-10 [&>div>svg]:size-5" icon="magnifying-glass" href="#" :label="__('Search')"/>
|
|
</flux:tooltip>
|
|
<flux:tooltip :content="__('Repository')" position="bottom">
|
|
<flux:navbar.item
|
|
class="h-10 max-lg:hidden [&>div>svg]:size-5"
|
|
icon="folder-git-2"
|
|
href="https://gitworkshop.dev/holgerhatgarkeinenode@einundzwanzig.space/einundzwanzig-app"
|
|
target="_blank"
|
|
:label="__('Repository')"
|
|
/>
|
|
</flux:tooltip>
|
|
<flux:tooltip :content="__('Documentation')" position="bottom">
|
|
<flux:navbar.item
|
|
class="h-10 max-lg:hidden [&>div>svg]:size-5"
|
|
icon="book-open-text"
|
|
href="https://laravel.com/docs/starter-kits#livewire"
|
|
target="_blank"
|
|
label="Documentation"
|
|
/>
|
|
</flux:tooltip>
|
|
</flux:navbar>
|
|
|
|
<!-- Desktop User Menu -->
|
|
<flux:dropdown position="top" align="end">
|
|
<flux:profile
|
|
class="cursor-pointer"
|
|
:initials="auth()->user()->initials()"
|
|
/>
|
|
|
|
<flux:menu>
|
|
<flux:menu.radio.group>
|
|
<div class="p-0 text-sm font-normal">
|
|
<div class="flex items-center gap-2 px-1 py-1.5 text-start text-sm">
|
|
<span class="relative flex h-8 w-8 shrink-0 overflow-hidden rounded-lg">
|
|
<span
|
|
class="flex h-full w-full items-center justify-center rounded-lg bg-neutral-200 text-black dark:bg-neutral-700 dark:text-white"
|
|
>
|
|
{{ auth()->user()->initials() }}
|
|
</span>
|
|
</span>
|
|
|
|
<div class="grid flex-1 text-start text-sm leading-tight">
|
|
<span class="truncate font-semibold">{{ auth()->user()?->name }}</span>
|
|
<span class="truncate text-xs">{{ auth()->user()?->email }}</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</flux:menu.radio.group>
|
|
|
|
<flux:menu.separator/>
|
|
|
|
<flux:menu.radio.group>
|
|
<flux:menu.item :href="route('settings.profile', ['country' => str(session('lang_country', 'de'))->after('-')->lower()])" icon="cog"
|
|
wire:navigate>{{ __('Settings') }}</flux:menu.item>
|
|
</flux:menu.radio.group>
|
|
|
|
<flux:menu.separator/>
|
|
|
|
<form method="POST" action="{{ route('logout') }}" class="w-full">
|
|
@csrf
|
|
<flux:menu.item as="button" type="submit" icon="arrow-right-start-on-rectangle" class="w-full">
|
|
{{ __('Log Out') }}
|
|
</flux:menu.item>
|
|
</form>
|
|
</flux:menu>
|
|
</flux:dropdown>
|
|
</flux:header>
|
|
|
|
<!-- Mobile Menu -->
|
|
<flux:sidebar stashable sticky
|
|
class="lg:hidden border-e border-zinc-200 bg-zinc-50 dark:border-zinc-700 dark:bg-zinc-900">
|
|
<flux:sidebar.toggle class="lg:hidden" icon="x-mark"/>
|
|
|
|
<a href="{{ route('dashboard', ['country' => str(session('lang_country', 'de'))->after('-')->lower()]) }}" class="ms-1 flex items-center space-x-2 rtl:space-x-reverse"
|
|
wire:navigate>
|
|
<x-app-logo/>
|
|
</a>
|
|
|
|
<flux:navlist variant="outline">
|
|
<flux:navlist.group :heading="__('Platform')">
|
|
<flux:navlist.item icon="layout-grid" :href="route('dashboard', ['country' => str(session('lang_country', 'de'))->after('-')->lower()])"
|
|
:current="request()->routeIs('dashboard')" wire:navigate>
|
|
{{ __('Dashboard') }}
|
|
</flux:navlist.item>
|
|
</flux:navlist.group>
|
|
</flux:navlist>
|
|
|
|
<flux:spacer/>
|
|
|
|
<flux:navlist variant="outline">
|
|
<flux:navlist.item icon="folder-git-2"
|
|
href="https://gitworkshop.dev/holgerhatgarkeinenode@einundzwanzig.space/einundzwanzig-app"
|
|
target="_blank">
|
|
{{ __('Repository') }}
|
|
</flux:navlist.item>
|
|
|
|
<flux:navlist.item icon="book-open-text" href="https://laravel.com/docs/starter-kits#livewire" target="_blank">
|
|
{{ __('Documentation') }}
|
|
</flux:navlist.item>
|
|
</flux:navlist>
|
|
</flux:sidebar>
|
|
|
|
{{ $slot }}
|
|
|
|
@fluxScripts
|
|
|
|
<script>
|
|
if (!localStorage.getItem('flux.appearance')) {
|
|
localStorage.setItem('flux.appearance', 'dark');
|
|
}
|
|
document.addEventListener('alpine:init', () => {
|
|
Alpine.directive('copy-to-clipboard', (el, {expression}, {evaluate}) => {
|
|
el.addEventListener('click', () => {
|
|
const text = evaluate(expression);
|
|
console.log(text);
|
|
|
|
navigator.clipboard.writeText(text).then(() => {
|
|
Flux.toast({
|
|
heading: '{{ __('Success!') }}',
|
|
text: '{{ __('Copied into clipboard') }}',
|
|
variant: 'success',
|
|
duration: 3000
|
|
});
|
|
}).catch(err => console.error(err));
|
|
});
|
|
});
|
|
});
|
|
</script>
|
|
<script>
|
|
window.wnjParams = {
|
|
position: 'bottom',
|
|
// The only accepted value is 'bottom', default is top
|
|
accent: 'orange',
|
|
// Supported values: cyan (default), green, purple, red, orange, neutral, stone
|
|
startHidden: false,
|
|
// If the host page has a button that call `getPublicKey` to start a
|
|
// login procedure, the minimized widget can be hidden until connected
|
|
compactMode: false,
|
|
// Show the minimized widget in a compact form
|
|
disableOverflowFix: false,
|
|
// If the host page on mobile has an horizontal scrolling, the floating
|
|
// element/modal are pushed to the extreme right/bottom and exit the
|
|
// viewport. A style is injected in the html/body elements fix this.
|
|
// This option permit to disable this default behavior
|
|
}
|
|
</script>
|
|
<script src="https://cdn.jsdelivr.net/npm/window.nostr.js/dist/window.nostr.min.js"></script>
|
|
|
|
</body>
|
|
</html>
|