Initial commit: Pireon Admin — headless admin panel and public API

Laravel 13 + Filament 5 admin panel and REST API for a non-profit developer
collective, backed by the Pireon OAuth identity server. The public site is a
separate, server-rendered application consuming /api/public/v1.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
2026-08-19 17:55:27 +02:00
commit 3897113313
534 changed files with 64050 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
{{-- Rendered at the very top of every page in the panel, on every install.
The failure this exists for runs in one direction only: mistaking a real
deployment for a throwaway copy, not the other way round. Nobody edits a
local clone carefully because they think it is production — the mistake
that costs something is the reverse. So `local` stays silent, and
anything else says so, loudly in the one case that matters. --}}
@unless (app()->environment('local'))
<div
role="status"
@class([
'w-full py-1 text-center text-xs font-semibold tracking-wide text-white uppercase',
'bg-danger-600' => app()->environment('production'),
'bg-warning-600' => ! app()->environment('production'),
])
>
{{ app()->environment('production')
? __('panel.environment.production')
: __('panel.environment.other', ['name' => app()->environment()]) }}
</div>
@endunless

View File

@@ -0,0 +1,30 @@
@php
$locales = config('locales.supported');
$current = app()->getLocale();
@endphp
<x-filament::dropdown placement="bottom-end" teleport>
<x-slot name="trigger">
<button
type="button"
title="{{ __('panel.language.switch') }}"
class="fi-icon-btn relative flex items-center justify-center rounded-lg p-2 text-sm text-gray-400 outline-none transition duration-75 hover:bg-gray-50 hover:text-gray-500 focus-visible:bg-gray-50 dark:text-gray-500 dark:hover:bg-white/5 dark:hover:text-gray-400"
>
<span class="text-base leading-none">{{ $locales[$current]['flag'] ?? '🌐' }}</span>
<span class="sr-only">{{ __('panel.language.switch') }}</span>
</button>
</x-slot>
<x-filament::dropdown.list>
@foreach ($locales as $code => $meta)
<x-filament::dropdown.list.item
:href="route('locale.switch', $code)"
tag="a"
:icon="$code === $current ? 'heroicon-m-check' : null"
:color="$code === $current ? 'primary' : 'gray'"
>
{{ $meta['flag'] }} {{ $meta['native'] }}
</x-filament::dropdown.list.item>
@endforeach
</x-filament::dropdown.list>
</x-filament::dropdown>

View File

@@ -0,0 +1,30 @@
{{-- Rendered under the sign-in form.
Two things belong here and nowhere else: whatever the identity server had
to say about a redirect that failed (those routes still exist), and the
language picker — the one place it is needed before there is a user whose
preference we could read. --}}
@if (session('error'))
<div
role="alert"
class="mb-6 rounded-lg border border-danger-300 bg-danger-50 p-4 text-sm text-danger-700 dark:border-danger-700/50 dark:bg-danger-500/10 dark:text-danger-400"
>
{{ session('error') }}
</div>
@endif
<div class="flex items-center justify-center gap-3 border-t border-gray-200 pt-6 dark:border-white/10">
@foreach (config('locales.supported') as $code => $meta)
<a
href="{{ route('locale.switch', $code) }}"
@class([
'text-xs transition',
'font-semibold text-primary-600 dark:text-primary-400' => app()->getLocale() === $code,
'text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200' => app()->getLocale() !== $code,
])
>
{{ $meta['flag'] }} {{ $meta['native'] }}
</a>
@endforeach
</div>

View File

@@ -0,0 +1,23 @@
{{-- One link per language: a draft translated into two has two addresses, and
whoever is reviewing the Catalan one needs that one. --}}
<div class="space-y-3">
@foreach ($links as $language => $url)
<div class="space-y-1">
<p class="text-sm font-medium text-gray-700 dark:text-gray-200">{{ $language }}</p>
<div class="flex items-center gap-2">
<input
type="text"
readonly
value="{{ $url }}"
onclick="this.select()"
class="fi-input w-full rounded-lg border-gray-300 bg-gray-50 px-3 py-2 font-mono text-xs text-gray-700 dark:border-white/10 dark:bg-white/5 dark:text-gray-300"
/>
<x-filament::button tag="a" href="{{ $url }}" target="_blank" size="sm" color="gray">
{{ __('panel.preview.open') }}
</x-filament::button>
</div>
</div>
@endforeach
</div>