view fix
This commit is contained in:
+124
-102
@@ -1,57 +1,15 @@
|
|||||||
<x-layouts.app :title="__('Module Control')">
|
<x-layouts.app :title="__('Module Control')">
|
||||||
<section class="overflow-hidden rounded-[1.35rem] border border-blue-400/20 bg-[radial-gradient(circle_at_18%_25%,rgba(14,165,233,0.20),transparent_34%),linear-gradient(135deg,#061024_0%,#0b1b48_54%,#071225_100%)] px-8 py-9 shadow-2xl shadow-black/20 sm:px-10 lg:px-12">
|
@php
|
||||||
<div class="flex flex-col gap-8 lg:flex-row lg:items-center lg:justify-between">
|
$installedCount = (int) ($stats['installed'] ?? 0);
|
||||||
<div class="max-w-2xl">
|
$enabledCount = (int) ($stats['enabled'] ?? 0);
|
||||||
<p class="text-[0.72rem] font-black uppercase tracking-[0.34em] text-emerald-300">
|
$disabledCount = (int) ($stats['disabled'] ?? 0);
|
||||||
{{ __('Platform Administration') }}
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<h1 class="mt-5 text-4xl font-black tracking-tight text-white sm:text-5xl">
|
|
||||||
{{ __('Module Control') }}
|
|
||||||
</h1>
|
|
||||||
|
|
||||||
<p class="mt-5 max-w-xl text-base font-semibold leading-7 text-slate-200 sm:text-lg">
|
|
||||||
{{ __('Manage installed modules, database metadata, dependencies and activation state.') }}
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="w-full max-w-[31rem] rounded-2xl border border-white/15 bg-slate-950/25 p-5 shadow-xl shadow-black/10 backdrop-blur lg:self-start">
|
|
||||||
<div class="flex items-start justify-between gap-4">
|
|
||||||
<span class="inline-flex h-16 w-16 items-center justify-center rounded-2xl border border-emerald-300/55 bg-emerald-400/10 text-emerald-200 shadow-sm">
|
|
||||||
<i class="fa-solid fa-puzzle-piece text-2xl" aria-hidden="true"></i>
|
|
||||||
</span>
|
|
||||||
|
|
||||||
<span class="inline-flex rounded-full border border-white/25 bg-white/10 px-5 py-2 text-[0.68rem] font-black uppercase tracking-[0.22em] text-slate-100">
|
|
||||||
{{ __('Database Backed') }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="mt-8 grid grid-cols-3 divide-x divide-white/15">
|
|
||||||
<div class="pr-5">
|
|
||||||
<div class="text-4xl font-black text-white">{{ $stats['installed'] }}</div>
|
|
||||||
<div class="mt-2 text-xs font-black uppercase tracking-wide text-slate-200">{{ __('Installed') }}</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="px-5">
|
|
||||||
<div class="text-4xl font-black text-emerald-300">{{ $stats['enabled'] }}</div>
|
|
||||||
<div class="mt-2 text-xs font-black uppercase tracking-wide text-slate-200">{{ __('Enabled') }}</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="pl-5">
|
|
||||||
<div class="text-4xl font-black text-red-300">{{ $stats['disabled'] }}</div>
|
|
||||||
<div class="mt-2 text-xs font-black uppercase tracking-wide text-slate-200">{{ __('Disabled') }}</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
@php
|
|
||||||
$filterCards = [
|
$filterCards = [
|
||||||
['key' => 'all', 'label' => 'Installed', 'value' => $stats['installed'], 'icon' => 'fa-puzzle-piece', 'tone' => 'blue', 'hint' => 'All modules'],
|
['key' => 'all', 'label' => 'Installed', 'value' => $installedCount, 'icon' => 'fa-puzzle-piece', 'tone' => 'blue', 'hint' => 'All modules'],
|
||||||
['key' => 'enabled', 'label' => 'Enabled', 'value' => $stats['enabled'], 'icon' => 'fa-circle-check', 'tone' => 'emerald', 'hint' => 'Active modules'],
|
['key' => 'enabled', 'label' => 'Enabled', 'value' => $enabledCount, 'icon' => 'fa-circle-check', 'tone' => 'emerald', 'hint' => 'Active modules'],
|
||||||
['key' => 'disabled', 'label' => 'Disabled', 'value' => $stats['disabled'], 'icon' => 'fa-circle-pause', 'tone' => 'red', 'hint' => 'Inactive modules'],
|
['key' => 'disabled', 'label' => 'Disabled', 'value' => $disabledCount, 'icon' => 'fa-circle-pause', 'tone' => 'red', 'hint' => 'Inactive modules'],
|
||||||
['key' => 'updates', 'label' => 'Updates Available', 'value' => $stats['updates'], 'icon' => 'fa-arrow-up-from-bracket', 'tone' => 'amber', 'hint' => 'Disk version newer'],
|
['key' => 'updates', 'label' => 'Updates Available', 'value' => $stats['updates'] ?? 0, 'icon' => 'fa-arrow-up-from-bracket', 'tone' => 'sky', 'hint' => 'Disk version newer'],
|
||||||
['key' => 'missing-dependencies', 'label' => 'Dependencies Missing', 'value' => $stats['missing'], 'icon' => 'fa-triangle-exclamation', 'tone' => 'orange', 'hint' => 'Requires attention'],
|
['key' => 'missing-dependencies', 'label' => 'Dependencies Missing', 'value' => $stats['missing'] ?? 0, 'icon' => 'fa-triangle-exclamation', 'tone' => 'amber', 'hint' => 'Requires attention'],
|
||||||
];
|
];
|
||||||
|
|
||||||
$secondaryFilters = [
|
$secondaryFilters = [
|
||||||
@@ -61,19 +19,83 @@
|
|||||||
'third-party' => 'Third-party',
|
'third-party' => 'Third-party',
|
||||||
];
|
];
|
||||||
|
|
||||||
$toneClasses = [
|
$cardTone = [
|
||||||
'blue' => 'border-blue-500/40 bg-blue-500/10 text-blue-700 dark:text-blue-300',
|
'blue' => 'border-blue-400/70 bg-blue-500/10 text-blue-300',
|
||||||
'emerald' => 'border-emerald-500/40 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300',
|
'emerald' => 'border-emerald-400/60 bg-emerald-500/10 text-emerald-300',
|
||||||
'red' => 'border-red-500/40 bg-red-500/10 text-red-700 dark:text-red-300',
|
'red' => 'border-red-400/60 bg-red-500/10 text-red-300',
|
||||||
'amber' => 'border-amber-500/40 bg-amber-500/10 text-amber-700 dark:text-amber-300',
|
'sky' => 'border-sky-400/60 bg-sky-500/10 text-sky-300',
|
||||||
'orange' => 'border-orange-500/40 bg-orange-500/10 text-orange-700 dark:text-orange-300',
|
'amber' => 'border-amber-400/60 bg-amber-500/10 text-amber-300',
|
||||||
];
|
];
|
||||||
@endphp
|
@endphp
|
||||||
|
|
||||||
|
<style>
|
||||||
|
.mc-row,
|
||||||
|
.mc-row:hover,
|
||||||
|
.mc-row:focus-within {
|
||||||
|
background: rgb(24 24 27 / 0.68) !important;
|
||||||
|
color: inherit !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mc-row:hover {
|
||||||
|
background: linear-gradient(90deg, rgb(24 24 27 / 0.92), rgb(9 24 43 / 0.78)) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mc-view-button,
|
||||||
|
.mc-view-button:hover,
|
||||||
|
.mc-view-button:focus {
|
||||||
|
background: rgb(5 150 105) !important;
|
||||||
|
border-color: rgb(16 185 129 / 0.65) !important;
|
||||||
|
color: #fff !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mc-view-button:hover {
|
||||||
|
background: rgb(4 120 87) !important;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
<div class="space-y-6">
|
<div class="space-y-6">
|
||||||
|
<section class="overflow-hidden rounded-[1.35rem] border border-blue-400/20 bg-[radial-gradient(circle_at_30%_15%,rgba(22,163,184,0.25),transparent_32%),linear-gradient(135deg,#050b21_0%,#0b1a47_48%,#07111f_100%)] px-8 py-9 shadow-2xl shadow-black/30 sm:px-10 lg:px-12">
|
||||||
|
<div class="grid gap-8 lg:grid-cols-[minmax(0,1fr)_minmax(30rem,36rem)] lg:items-start">
|
||||||
|
<div class="max-w-3xl">
|
||||||
|
<p class="text-xs font-black uppercase tracking-[0.35em] text-emerald-300">Platform Administration</p>
|
||||||
|
<h1 class="mt-6 text-4xl font-black tracking-tight text-white sm:text-5xl">Module Control</h1>
|
||||||
|
<p class="mt-5 max-w-2xl text-lg font-semibold leading-8 text-slate-200">
|
||||||
|
Manage installed modules, database metadata, dependencies and activation state.
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="rounded-[1.35rem] border border-white/20 bg-slate-950/25 p-6 shadow-2xl shadow-black/20 ring-1 ring-white/10 backdrop-blur">
|
||||||
|
<div class="flex items-start justify-between gap-4">
|
||||||
|
<span class="inline-flex h-16 w-16 items-center justify-center rounded-2xl border border-emerald-300/70 bg-emerald-400/10 text-emerald-200 shadow-sm">
|
||||||
|
<i class="fa-solid fa-puzzle-piece text-3xl" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<span class="inline-flex items-center rounded-full border border-white/25 bg-white/10 px-5 py-2 text-xs font-black uppercase tracking-[0.22em] text-slate-100">
|
||||||
|
Database backed
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="mt-8 grid grid-cols-3 gap-0">
|
||||||
|
<div class="border-r border-white/20 pr-6">
|
||||||
|
<div class="text-4xl font-black text-white">{{ $installedCount }}</div>
|
||||||
|
<div class="mt-1 text-sm font-black uppercase tracking-wide text-slate-200">Installed</div>
|
||||||
|
</div>
|
||||||
|
<div class="border-r border-white/20 px-6">
|
||||||
|
<div class="text-4xl font-black text-emerald-300">{{ $enabledCount }}</div>
|
||||||
|
<div class="mt-1 text-sm font-black uppercase tracking-wide text-slate-200">Enabled</div>
|
||||||
|
</div>
|
||||||
|
<div class="pl-6">
|
||||||
|
<div class="text-4xl font-black text-red-300">{{ $disabledCount }}</div>
|
||||||
|
<div class="mt-1 text-sm font-black uppercase tracking-wide text-slate-200">Disabled</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
@foreach (['status' => 'emerald', 'warning' => 'amber', 'error' => 'red'] as $flash => $tone)
|
@foreach (['status' => 'emerald', 'warning' => 'amber', 'error' => 'red'] as $flash => $tone)
|
||||||
@if (session($flash))
|
@if (session($flash))
|
||||||
<div class="rounded-2xl border px-4 py-3 text-sm font-medium {{ $toneClasses[$tone] ?? $toneClasses['blue'] }}">
|
<div class="rounded-2xl border border-{{ $tone }}-500/40 bg-{{ $tone }}-500/10 px-4 py-3 text-sm font-medium text-{{ $tone }}-300">
|
||||||
{{ session($flash) }}
|
{{ session($flash) }}
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
@@ -83,15 +105,15 @@
|
|||||||
@foreach ($filterCards as $card)
|
@foreach ($filterCards as $card)
|
||||||
<a
|
<a
|
||||||
href="{{ route('modules.control.index', array_filter(['filter' => $card['key'] === 'all' ? null : $card['key'], 'search' => $search, 'sort' => $sort === 'order' ? null : $sort])) }}"
|
href="{{ route('modules.control.index', array_filter(['filter' => $card['key'] === 'all' ? null : $card['key'], 'search' => $search, 'sort' => $sort === 'order' ? null : $sort])) }}"
|
||||||
class="group rounded-2xl border p-5 shadow-sm transition hover:-translate-y-0.5 hover:shadow-md {{ $filter === $card['key'] ? ($toneClasses[$card['tone']] ?? $toneClasses['blue']) : 'border-zinc-200 bg-white text-zinc-900 dark:border-zinc-800 dark:bg-zinc-900 dark:text-zinc-100' }}"
|
class="group rounded-2xl border p-5 shadow-sm transition hover:-translate-y-0.5 hover:bg-zinc-900/90 hover:shadow-md {{ $filter === $card['key'] ? ($cardTone[$card['tone']] ?? $cardTone['blue']) : 'border-zinc-800 bg-zinc-900 text-zinc-100' }}"
|
||||||
>
|
>
|
||||||
<div class="flex items-start justify-between gap-3">
|
<div class="flex items-start justify-between gap-3">
|
||||||
<div>
|
<div>
|
||||||
<div class="text-xs font-semibold uppercase tracking-wide text-zinc-500 dark:text-zinc-400">{{ $card['label'] }}</div>
|
<div class="text-xs font-black uppercase tracking-wide text-zinc-400">{{ $card['label'] }}</div>
|
||||||
<div class="mt-2 text-3xl font-bold">{{ $card['value'] }}</div>
|
<div class="mt-2 text-4xl font-black {{ $card['tone'] === 'emerald' ? 'text-emerald-300' : ($card['tone'] === 'red' ? 'text-red-300' : ($card['tone'] === 'amber' ? 'text-amber-300' : 'text-blue-300')) }}">{{ $card['value'] }}</div>
|
||||||
<div class="mt-1 text-xs text-zinc-500 dark:text-zinc-400">{{ $card['hint'] }}</div>
|
<div class="mt-1 text-sm text-zinc-400">{{ $card['hint'] }}</div>
|
||||||
</div>
|
</div>
|
||||||
<span class="rounded-xl border border-zinc-200 bg-white/70 p-3 text-zinc-600 dark:border-zinc-700 dark:bg-zinc-950/60 dark:text-zinc-300">
|
<span class="rounded-xl border border-zinc-700 bg-zinc-950/70 p-3 text-zinc-200">
|
||||||
<i class="fa-solid {{ $card['icon'] }}" aria-hidden="true"></i>
|
<i class="fa-solid {{ $card['icon'] }}" aria-hidden="true"></i>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
@@ -99,11 +121,11 @@
|
|||||||
@endforeach
|
@endforeach
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-5 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<div class="rounded-2xl border border-zinc-800 bg-zinc-900 p-5 shadow-sm">
|
||||||
<div class="flex flex-col gap-5 xl:flex-row xl:items-end xl:justify-between">
|
<div class="flex flex-col gap-5 xl:flex-row xl:items-end xl:justify-between">
|
||||||
<div>
|
<div>
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">Installed modules</h2>
|
<h2 class="text-lg font-semibold text-zinc-100">Installed modules</h2>
|
||||||
<p class="mt-1 text-sm text-zinc-500 dark:text-zinc-400">
|
<p class="mt-1 text-sm text-zinc-400">
|
||||||
Descriptions, versions, display metadata and sort order are stored in the database only.
|
Descriptions, versions, display metadata and sort order are stored in the database only.
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
@@ -118,11 +140,11 @@
|
|||||||
name="search"
|
name="search"
|
||||||
value="{{ $search }}"
|
value="{{ $search }}"
|
||||||
placeholder="Search name, description, version, author..."
|
placeholder="Search name, description, version, author..."
|
||||||
class="w-full rounded-xl border border-zinc-300 bg-white px-4 py-2 text-sm text-zinc-900 placeholder:text-zinc-400 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100 dark:placeholder:text-zinc-500 sm:w-80"
|
class="w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm text-zinc-100 placeholder:text-zinc-500 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20 sm:w-80"
|
||||||
/>
|
/>
|
||||||
<select
|
<select
|
||||||
name="sort"
|
name="sort"
|
||||||
class="rounded-xl border border-zinc-300 bg-white px-3 py-2 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100"
|
class="rounded-xl border border-zinc-700 bg-zinc-950 px-3 py-2 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20"
|
||||||
>
|
>
|
||||||
<option value="order" @selected($sort === 'order')>Sort: Order</option>
|
<option value="order" @selected($sort === 'order')>Sort: Order</option>
|
||||||
<option value="name" @selected($sort === 'name')>Sort: Name</option>
|
<option value="name" @selected($sort === 'name')>Sort: Name</option>
|
||||||
@@ -130,14 +152,14 @@
|
|||||||
<option value="version" @selected($sort === 'version')>Sort: Version</option>
|
<option value="version" @selected($sort === 'version')>Sort: Version</option>
|
||||||
<option value="updated" @selected($sort === 'updated')>Sort: Last updated</option>
|
<option value="updated" @selected($sort === 'updated')>Sort: Last updated</option>
|
||||||
</select>
|
</select>
|
||||||
<button type="submit" class="rounded-xl border border-blue-500/40 bg-blue-600 px-4 py-2 text-sm font-semibold text-white shadow-sm hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-blue-500/30">
|
<button type="submit" class="rounded-xl border border-emerald-500/40 bg-emerald-600 px-4 py-2 text-sm font-semibold text-white shadow-sm hover:bg-emerald-700 focus:outline-none focus:ring-2 focus:ring-emerald-500/30">
|
||||||
Search
|
Search
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<form method="POST" action="{{ route('modules.control.sync') }}">
|
<form method="POST" action="{{ route('modules.control.sync') }}">
|
||||||
@csrf
|
@csrf
|
||||||
<button type="submit" class="rounded-xl border border-zinc-300 px-4 py-2 text-sm font-semibold text-zinc-800 hover:bg-zinc-50 dark:border-zinc-700 dark:text-zinc-100 dark:hover:bg-zinc-800">
|
<button type="submit" class="rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm font-semibold text-zinc-100 hover:bg-zinc-800">
|
||||||
Sync Database
|
Sync Database
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
@@ -148,25 +170,25 @@
|
|||||||
@foreach ($secondaryFilters as $key => $label)
|
@foreach ($secondaryFilters as $key => $label)
|
||||||
<a
|
<a
|
||||||
href="{{ route('modules.control.index', array_filter(['filter' => $key, 'search' => $search, 'sort' => $sort === 'order' ? null : $sort])) }}"
|
href="{{ route('modules.control.index', array_filter(['filter' => $key, 'search' => $search, 'sort' => $sort === 'order' ? null : $sort])) }}"
|
||||||
class="rounded-full border px-3 py-1 text-xs font-semibold transition {{ $filter === $key ? 'border-blue-500/40 bg-blue-500/10 text-blue-700 dark:text-blue-300' : 'border-zinc-300 text-zinc-600 hover:bg-zinc-50 dark:border-zinc-700 dark:text-zinc-300 dark:hover:bg-zinc-800' }}"
|
class="rounded-full border px-3 py-1 text-xs font-semibold transition {{ $filter === $key ? 'border-emerald-500/40 bg-emerald-500/10 text-emerald-300' : 'border-zinc-700 text-zinc-300 hover:bg-zinc-800' }}"
|
||||||
>
|
>
|
||||||
{{ $label }}
|
{{ $label }}
|
||||||
</a>
|
</a>
|
||||||
@endforeach
|
@endforeach
|
||||||
|
|
||||||
@if ($filter !== 'all' || $search !== '')
|
@if ($filter !== 'all' || $search !== '')
|
||||||
<a href="{{ route('modules.control.index') }}" class="rounded-full border border-zinc-300 px-3 py-1 text-xs font-semibold text-zinc-600 hover:bg-zinc-50 dark:border-zinc-700 dark:text-zinc-300 dark:hover:bg-zinc-800">
|
<a href="{{ route('modules.control.index') }}" class="rounded-full border border-zinc-700 px-3 py-1 text-xs font-semibold text-zinc-300 hover:bg-zinc-800">
|
||||||
Clear filters
|
Clear filters
|
||||||
</a>
|
</a>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="flex flex-col gap-1 text-sm text-zinc-500 dark:text-zinc-400 sm:flex-row sm:items-center sm:justify-between">
|
<div class="flex flex-col gap-1 text-sm text-zinc-400 sm:flex-row sm:items-center sm:justify-between">
|
||||||
<div>
|
<div>
|
||||||
Showing {{ $modules->firstItem() ?? 0 }}-{{ $modules->lastItem() ?? 0 }} of {{ $modules->total() }} modules.
|
Showing {{ $modules->firstItem() ?? 0 }}-{{ $modules->lastItem() ?? 0 }} of {{ $modules->total() }} modules.
|
||||||
@if ($search !== '')
|
@if ($search !== '')
|
||||||
Search: <span class="font-semibold text-zinc-800 dark:text-zinc-200">{{ $search }}</span>
|
Search: <span class="font-semibold text-zinc-200">{{ $search }}</span>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
<div>4 modules per page</div>
|
<div>4 modules per page</div>
|
||||||
@@ -175,27 +197,27 @@
|
|||||||
<form method="POST" action="{{ route('modules.control.bulk') }}" class="space-y-4">
|
<form method="POST" action="{{ route('modules.control.bulk') }}" class="space-y-4">
|
||||||
@csrf
|
@csrf
|
||||||
|
|
||||||
<div class="flex flex-col gap-3 rounded-2xl border border-zinc-200 bg-white p-4 shadow-sm dark:border-zinc-800 dark:bg-zinc-900 sm:flex-row sm:items-center sm:justify-between">
|
<div class="flex flex-col gap-3 rounded-2xl border border-zinc-800 bg-zinc-900 p-4 shadow-sm sm:flex-row sm:items-center sm:justify-between">
|
||||||
<div class="text-sm text-zinc-600 dark:text-zinc-400">
|
<div class="text-sm text-zinc-400">
|
||||||
Select modules on this page and apply a bulk action.
|
Select modules on this page and apply a bulk action.
|
||||||
</div>
|
</div>
|
||||||
<div class="flex flex-wrap gap-2">
|
<div class="flex flex-wrap gap-2">
|
||||||
<select name="action" class="rounded-xl border border-zinc-300 bg-white px-3 py-2 text-sm text-zinc-900 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100">
|
<select name="action" class="rounded-xl border border-zinc-700 bg-zinc-950 px-3 py-2 text-sm text-zinc-100">
|
||||||
<option value="enable">Enable selected</option>
|
<option value="enable">Enable selected</option>
|
||||||
<option value="disable">Disable selected</option>
|
<option value="disable">Disable selected</option>
|
||||||
</select>
|
</select>
|
||||||
<button type="submit" class="rounded-xl border border-zinc-300 px-4 py-2 text-sm font-semibold text-zinc-800 hover:bg-zinc-50 dark:border-zinc-700 dark:text-zinc-100 dark:hover:bg-zinc-800">
|
<button type="submit" class="rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm font-semibold text-zinc-100 hover:bg-zinc-800">
|
||||||
Apply
|
Apply
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="overflow-hidden rounded-2xl border border-zinc-200 bg-white shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<div class="overflow-hidden rounded-2xl border border-zinc-800 bg-zinc-900 shadow-sm">
|
||||||
<div class="overflow-x-auto">
|
<div class="overflow-x-auto">
|
||||||
<table class="min-w-full divide-y divide-zinc-200 dark:divide-zinc-800">
|
<table class="min-w-full divide-y divide-zinc-800">
|
||||||
<thead class="bg-zinc-50 dark:bg-zinc-950/70">
|
<thead class="bg-zinc-950/70">
|
||||||
<tr>
|
<tr>
|
||||||
<th class="w-10 px-4 py-3 text-left"><span class="sr-only">Select</span></th>
|
<th class="w-12 px-4 py-3 text-left"><span class="sr-only">Select</span></th>
|
||||||
<th class="px-4 py-3 text-left text-xs font-semibold uppercase tracking-wide text-zinc-500">Module</th>
|
<th class="px-4 py-3 text-left text-xs font-semibold uppercase tracking-wide text-zinc-500">Module</th>
|
||||||
<th class="px-4 py-3 text-left text-xs font-semibold uppercase tracking-wide text-zinc-500">Description</th>
|
<th class="px-4 py-3 text-left text-xs font-semibold uppercase tracking-wide text-zinc-500">Description</th>
|
||||||
<th class="px-4 py-3 text-left text-xs font-semibold uppercase tracking-wide text-zinc-500">Version</th>
|
<th class="px-4 py-3 text-left text-xs font-semibold uppercase tracking-wide text-zinc-500">Version</th>
|
||||||
@@ -205,64 +227,64 @@
|
|||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
|
||||||
<tbody class="divide-y divide-zinc-200 dark:divide-zinc-800">
|
<tbody class="divide-y divide-zinc-800">
|
||||||
@forelse ($modules as $module)
|
@forelse ($modules as $module)
|
||||||
<tr class="align-top transition hover:bg-zinc-50 dark:hover:bg-zinc-950/50">
|
<tr class="mc-row align-top transition">
|
||||||
<td class="px-4 py-4">
|
<td class="px-4 py-4">
|
||||||
<input type="checkbox" name="modules[]" value="{{ $module['name'] }}" class="rounded border-zinc-300 text-blue-600 focus:ring-blue-500 dark:border-zinc-700 dark:bg-zinc-950" />
|
<input type="checkbox" name="modules[]" value="{{ $module['name'] }}" class="rounded border-zinc-700 bg-zinc-950 text-emerald-600 focus:ring-emerald-500" />
|
||||||
</td>
|
</td>
|
||||||
<td class="px-4 py-4">
|
<td class="px-4 py-4">
|
||||||
<div class="flex gap-3">
|
<div class="flex gap-3">
|
||||||
<div class="flex h-11 w-11 shrink-0 items-center justify-center rounded-xl border border-zinc-200 bg-zinc-50 text-zinc-700 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-200">
|
<div class="flex h-11 w-11 shrink-0 items-center justify-center rounded-xl border border-zinc-700 bg-zinc-950 text-zinc-200">
|
||||||
<i class="fa-solid {{ $module['icon'] ?: 'fa-puzzle-piece' }}" aria-hidden="true"></i>
|
<i class="fa-solid {{ $module['icon'] ?: 'fa-puzzle-piece' }}" aria-hidden="true"></i>
|
||||||
</div>
|
</div>
|
||||||
<div class="min-w-0">
|
<div class="min-w-0">
|
||||||
<div class="font-semibold text-zinc-950 dark:text-zinc-100">{{ $module['name'] }}</div>
|
<div class="font-semibold text-zinc-100">{{ $module['name'] }}</div>
|
||||||
<div class="mt-1 text-xs text-zinc-500">{{ $module['alias'] }}</div>
|
<div class="mt-1 text-xs text-zinc-500">{{ $module['alias'] }}</div>
|
||||||
<div class="mt-2 flex flex-wrap gap-1.5">
|
<div class="mt-2 flex flex-wrap gap-1.5">
|
||||||
<span class="rounded-full border border-zinc-300 px-2 py-0.5 text-[11px] font-semibold text-zinc-600 dark:border-zinc-700 dark:text-zinc-300">{{ $module['category'] }}</span>
|
<span class="rounded-full border border-zinc-700 px-2 py-0.5 text-[11px] font-semibold text-zinc-300">{{ $module['category'] }}</span>
|
||||||
<span class="rounded-full border border-zinc-300 px-2 py-0.5 text-[11px] font-semibold text-zinc-600 dark:border-zinc-700 dark:text-zinc-300">{{ $module['vendor_type'] }}</span>
|
<span class="rounded-full border border-zinc-700 px-2 py-0.5 text-[11px] font-semibold text-zinc-300">{{ $module['vendor_type'] }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td class="max-w-md px-4 py-4">
|
<td class="max-w-md px-4 py-4">
|
||||||
<p class="line-clamp-3 text-sm leading-6 text-zinc-700 dark:text-zinc-300">
|
<p class="line-clamp-3 text-sm leading-6 text-zinc-300">
|
||||||
{{ $module['description'] ?: 'No database description saved.' }}
|
{{ $module['description'] ?: 'No database description saved.' }}
|
||||||
</p>
|
</p>
|
||||||
@if ($module['has_missing_dependencies'])
|
@if ($module['has_missing_dependencies'])
|
||||||
<div class="mt-2 rounded-lg border border-orange-500/30 bg-orange-500/10 px-2 py-1 text-xs font-semibold text-orange-700 dark:text-orange-300">
|
<div class="mt-2 rounded-lg border border-orange-500/30 bg-orange-500/10 px-2 py-1 text-xs font-semibold text-orange-300">
|
||||||
Missing: {{ implode(', ', $module['missing_dependencies']) }}
|
Missing: {{ implode(', ', $module['missing_dependencies']) }}
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
</td>
|
</td>
|
||||||
<td class="px-4 py-4 text-sm text-zinc-700 dark:text-zinc-300">
|
<td class="px-4 py-4 text-sm text-zinc-300">
|
||||||
<div>{{ $module['version'] ?: '—' }}</div>
|
<div>{{ $module['version'] ?: '—' }}</div>
|
||||||
@if ($module['has_update'])
|
@if ($module['has_update'])
|
||||||
<span class="mt-1 inline-flex rounded-full border border-amber-500/30 bg-amber-500/10 px-2 py-0.5 text-xs font-semibold text-amber-700 dark:text-amber-300">Update available</span>
|
<span class="mt-1 inline-flex rounded-full border border-amber-500/30 bg-amber-500/10 px-2 py-0.5 text-xs font-semibold text-amber-300">Update available</span>
|
||||||
@elseif ($module['database_version'])
|
@elseif ($module['database_version'])
|
||||||
<span class="mt-1 inline-flex text-xs text-blue-600 dark:text-blue-300">Database</span>
|
<span class="mt-1 inline-flex text-xs text-emerald-300">Database</span>
|
||||||
@endif
|
@endif
|
||||||
</td>
|
</td>
|
||||||
<td class="px-4 py-4">
|
<td class="px-4 py-4">
|
||||||
@if ($module['enabled'])
|
@if ($module['enabled'])
|
||||||
<span class="inline-flex items-center gap-1.5 rounded-full border border-emerald-500/30 bg-emerald-500/10 px-3 py-1 text-xs font-semibold text-emerald-700 dark:text-emerald-300">
|
<span class="inline-flex items-center gap-1.5 rounded-full border border-emerald-500/30 bg-emerald-500/10 px-3 py-1 text-xs font-semibold text-emerald-300">
|
||||||
<i class="fa-solid fa-circle-check" aria-hidden="true"></i> Enabled
|
<i class="fa-solid fa-circle-check" aria-hidden="true"></i> Enabled
|
||||||
</span>
|
</span>
|
||||||
@else
|
@else
|
||||||
<span class="inline-flex items-center gap-1.5 rounded-full border border-red-500/30 bg-red-500/10 px-3 py-1 text-xs font-semibold text-red-700 dark:text-red-300">
|
<span class="inline-flex items-center gap-1.5 rounded-full border border-red-500/30 bg-red-500/10 px-3 py-1 text-xs font-semibold text-red-300">
|
||||||
<i class="fa-solid fa-circle-pause" aria-hidden="true"></i> Disabled
|
<i class="fa-solid fa-circle-pause" aria-hidden="true"></i> Disabled
|
||||||
</span>
|
</span>
|
||||||
@endif
|
@endif
|
||||||
</td>
|
</td>
|
||||||
<td class="px-4 py-4 text-sm text-zinc-600 dark:text-zinc-400">
|
<td class="px-4 py-4 text-sm text-zinc-400">
|
||||||
{{ $module['updated_at']?->format('d M Y H:i') ?? '—' }}
|
{{ $module['updated_at']?->format('d M Y H:i') ?? '—' }}
|
||||||
</td>
|
</td>
|
||||||
<td class="px-4 py-4">
|
<td class="px-4 py-4">
|
||||||
<div class="flex justify-end gap-2">
|
<div class="flex justify-end gap-2">
|
||||||
<a href="{{ route('modules.control.show', $module['name']) }}" class="rounded-lg border border-zinc-300 px-3 py-1.5 text-sm font-semibold text-zinc-800 hover:bg-zinc-50 dark:border-zinc-700 dark:text-zinc-100 dark:hover:bg-zinc-800">View</a>
|
<a href="{{ route('modules.control.show', $module['name']) }}" class="mc-view-button rounded-lg border px-3 py-1.5 text-sm font-semibold shadow-sm">View</a>
|
||||||
@if ($module['enabled'])
|
@if ($module['enabled'])
|
||||||
<button type="submit" formaction="{{ route('modules.control.disable', $module['name']) }}" class="rounded-lg border border-red-500/40 bg-red-600 px-3 py-1.5 text-sm font-semibold text-white hover:bg-red-700" @disabled(! $module['can_disable'])>
|
<button type="submit" formaction="{{ route('modules.control.disable', $module['name']) }}" class="rounded-lg border border-red-500/40 bg-red-600 px-3 py-1.5 text-sm font-semibold text-white hover:bg-red-700 disabled:cursor-not-allowed disabled:opacity-50" @disabled(! $module['can_disable'])>
|
||||||
Disable
|
Disable
|
||||||
</button>
|
</button>
|
||||||
@else
|
@else
|
||||||
@@ -276,11 +298,11 @@
|
|||||||
@empty
|
@empty
|
||||||
<tr>
|
<tr>
|
||||||
<td colspan="7" class="px-4 py-12 text-center">
|
<td colspan="7" class="px-4 py-12 text-center">
|
||||||
<div class="mx-auto flex h-12 w-12 items-center justify-center rounded-full border border-zinc-200 bg-zinc-50 text-zinc-500 dark:border-zinc-800 dark:bg-zinc-950">
|
<div class="mx-auto flex h-12 w-12 items-center justify-center rounded-full border border-zinc-800 bg-zinc-950 text-zinc-500">
|
||||||
<i class="fa-solid fa-magnifying-glass" aria-hidden="true"></i>
|
<i class="fa-solid fa-magnifying-glass" aria-hidden="true"></i>
|
||||||
</div>
|
</div>
|
||||||
<div class="mt-3 font-semibold text-zinc-900 dark:text-zinc-100">No modules found</div>
|
<div class="mt-3 font-semibold text-zinc-100">No modules found</div>
|
||||||
<div class="mt-1 text-sm text-zinc-500 dark:text-zinc-400">Adjust the search or filter and try again.</div>
|
<div class="mt-1 text-sm text-zinc-400">Adjust the search or filter and try again.</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforelse
|
@endforelse
|
||||||
|
|||||||
+192
-122
@@ -1,52 +1,5 @@
|
|||||||
<x-layouts.app :title="$module['name'].' Module'">
|
<x-layouts.app :title="$module['name'].' Module'">
|
||||||
<section class="overflow-hidden rounded-[1.35rem] border border-blue-400/20 bg-[radial-gradient(circle_at_18%_25%,rgba(14,165,233,0.18),transparent_34%),linear-gradient(135deg,#061024_0%,#0b1b48_54%,#071225_100%)] px-8 py-9 shadow-2xl shadow-black/20 sm:px-10 lg:px-12">
|
@php
|
||||||
<div class="flex flex-col gap-8 lg:flex-row lg:items-start lg:justify-between">
|
|
||||||
<div class="max-w-2xl">
|
|
||||||
<p class="text-[0.72rem] font-black uppercase tracking-[0.34em] text-emerald-300">
|
|
||||||
{{ __('Module Control') }}
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<h1 class="mt-5 text-4xl font-black tracking-tight text-white sm:text-5xl">
|
|
||||||
{{ $module['name'] }} {{ __('Module') }}
|
|
||||||
</h1>
|
|
||||||
|
|
||||||
<p class="mt-5 max-w-xl text-base font-semibold leading-7 text-slate-200 sm:text-lg">
|
|
||||||
{{ __('Database metadata, dependencies, developer information and activation controls.') }}
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="w-full max-w-[31rem] lg:self-start">
|
|
||||||
<div class="flex items-center justify-end gap-6">
|
|
||||||
<span class="inline-flex h-16 w-16 items-center justify-center rounded-2xl border border-emerald-300/55 bg-emerald-400/10 text-emerald-200 shadow-sm">
|
|
||||||
<i class="fa-solid {{ $module['icon'] ?: 'fa-chart-line' }} text-2xl" aria-hidden="true"></i>
|
|
||||||
</span>
|
|
||||||
|
|
||||||
<div class="h-16 w-px bg-white/15"></div>
|
|
||||||
|
|
||||||
<a href="{{ route('modules.control.index') }}" wire:navigate
|
|
||||||
class="inline-flex min-h-16 items-center justify-center gap-4 rounded-2xl border border-emerald-400/60 bg-emerald-500/5 px-8 text-sm font-black text-emerald-300 shadow-sm transition hover:border-emerald-300 hover:bg-emerald-500/15 hover:text-emerald-200 focus:outline-none focus:ring-2 focus:ring-emerald-400/40">
|
|
||||||
<i class="fa-solid fa-arrow-left" aria-hidden="true"></i>
|
|
||||||
{{ __('Back to Module Control') }}
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="mt-7 grid grid-cols-2 divide-x divide-white/15 rounded-2xl border border-white/15 bg-slate-950/20 p-6 shadow-xl shadow-black/10 backdrop-blur">
|
|
||||||
<div class="pr-8">
|
|
||||||
<div class="text-xs font-black uppercase tracking-[0.22em] text-slate-300">{{ __('Status') }}</div>
|
|
||||||
<div class="mt-4 text-2xl font-black {{ $module['enabled'] ? 'text-emerald-300' : 'text-red-300' }}">
|
|
||||||
{{ $module['enabled'] ? __('Enabled') : __('Disabled') }}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="pl-8">
|
|
||||||
<div class="text-xs font-black uppercase tracking-[0.22em] text-slate-300">{{ __('Requires') }}</div>
|
|
||||||
<div class="mt-4 text-2xl font-black text-white">{{ count($module['requires']) }}</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
@php
|
|
||||||
$fileGroups = [
|
$fileGroups = [
|
||||||
'Routes' => $module['routes'] ?? [],
|
'Routes' => $module['routes'] ?? [],
|
||||||
'Migrations' => $module['migrations'] ?? [],
|
'Migrations' => $module['migrations'] ?? [],
|
||||||
@@ -57,21 +10,76 @@
|
|||||||
@endphp
|
@endphp
|
||||||
|
|
||||||
<div class="space-y-6">
|
<div class="space-y-6">
|
||||||
|
<section class="overflow-hidden rounded-[1.35rem] border border-blue-400/20 bg-[radial-gradient(circle_at_25%_12%,rgba(22,163,184,0.18),transparent_30%),linear-gradient(135deg,#050b21_0%,#0b1a47_52%,#07111f_100%)] px-8 py-9 shadow-2xl shadow-black/30 sm:px-10 lg:px-12">
|
||||||
|
<div class="grid gap-8 lg:grid-cols-[minmax(0,1fr)_minmax(29rem,36rem)] lg:items-start">
|
||||||
|
<div class="max-w-3xl">
|
||||||
|
<p class="text-xs font-black uppercase tracking-[0.35em] text-emerald-300">Module Control</p>
|
||||||
|
<h1 class="mt-6 text-4xl font-black tracking-tight text-white sm:text-5xl">{{ $module['name'] }} Module</h1>
|
||||||
|
<p class="mt-5 max-w-2xl text-lg font-semibold leading-8 text-slate-200">
|
||||||
|
Database metadata, dependencies, developer information and activation controls.
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="space-y-6">
|
||||||
|
<div class="flex items-center justify-end gap-6">
|
||||||
|
<span class="inline-flex h-16 w-16 items-center justify-center rounded-2xl border border-emerald-300/55 bg-emerald-400/10 text-emerald-200 shadow-sm">
|
||||||
|
<i class="fa-solid fa-chart-line text-3xl" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<div class="h-16 w-px bg-white/20"></div>
|
||||||
|
|
||||||
|
<a href="{{ route('modules.control.index') }}" wire:navigate
|
||||||
|
class="inline-flex min-h-14 items-center justify-center gap-3 rounded-2xl border border-emerald-400/55 bg-emerald-500/5 px-8 py-3 text-sm font-black text-emerald-300 shadow-sm transition hover:border-emerald-300 hover:bg-emerald-500/15 hover:text-emerald-200 focus:outline-none focus:ring-2 focus:ring-emerald-400/40">
|
||||||
|
<i class="fa-solid fa-arrow-left" aria-hidden="true"></i>
|
||||||
|
{{ __('Back to Module Control') }}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="rounded-[1.35rem] border border-white/15 bg-slate-950/25 p-6 shadow-2xl shadow-black/20 ring-1 ring-white/10 backdrop-blur">
|
||||||
|
<div class="grid grid-cols-2 gap-0">
|
||||||
|
<div class="border-r border-white/20 pr-8">
|
||||||
|
<div class="text-xs font-black uppercase tracking-[0.22em] text-slate-300">Status</div>
|
||||||
|
<div class="mt-4 text-2xl font-black {{ $module['enabled'] ? 'text-emerald-300' : 'text-red-300' }}">
|
||||||
|
{{ $module['enabled'] ? 'Enabled' : 'Disabled' }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="pl-8">
|
||||||
|
<div class="text-xs font-black uppercase tracking-[0.22em] text-slate-300">Requires</div>
|
||||||
|
<div class="mt-4 text-2xl font-black text-white">{{ count($module['requires']) }}</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
@foreach (['status' => 'emerald', 'warning' => 'amber', 'error' => 'red'] as $flash => $tone)
|
@foreach (['status' => 'emerald', 'warning' => 'amber', 'error' => 'red'] as $flash => $tone)
|
||||||
@if (session($flash))
|
@if (session($flash))
|
||||||
<div class="rounded-2xl border px-4 py-3 text-sm font-medium {{ $tone === 'emerald' ? 'border-emerald-500/40 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300' : ($tone === 'amber' ? 'border-amber-500/40 bg-amber-500/10 text-amber-700 dark:text-amber-300' : 'border-red-500/40 bg-red-500/10 text-red-700 dark:text-red-300') }}">
|
<div class="rounded-2xl border border-{{ $tone }}-500/40 bg-{{ $tone }}-500/10 px-4 py-3 text-sm font-medium text-{{ $tone }}-300">
|
||||||
{{ session($flash) }}
|
{{ session($flash) }}
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
@endforeach
|
@endforeach
|
||||||
|
|
||||||
<div class="grid gap-6 xl:grid-cols-3">
|
<div class="grid gap-6 xl:grid-cols-3">
|
||||||
<div class="space-y-6 xl:col-span-2">
|
<div class="space-y-6 xl:col-span-2">
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-6 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<div class="rounded-2xl border border-zinc-800 bg-zinc-900 p-6 shadow-sm">
|
||||||
<div class="flex items-start justify-between gap-4">
|
<div class="flex items-start gap-4">
|
||||||
<div>
|
<div class="flex h-14 w-14 shrink-0 items-center justify-center rounded-xl border border-zinc-700 bg-zinc-950 text-zinc-100">
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">Database metadata</h2>
|
<i class="fa-solid {{ $module['icon'] ?: 'fa-puzzle-piece' }} text-xl" aria-hidden="true"></i>
|
||||||
<p class="mt-1 text-sm text-zinc-500 dark:text-zinc-400">These fields are saved only in the module_statuses table.</p>
|
|
||||||
</div>
|
</div>
|
||||||
|
<div class="min-w-0">
|
||||||
|
<div class="text-xs font-semibold uppercase text-zinc-500">Module</div>
|
||||||
|
<h2 class="mt-1 text-2xl font-black text-zinc-100">{{ $module['name'] }}</h2>
|
||||||
|
<p class="mt-1 text-sm text-zinc-400">{{ $module['alias'] }}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="rounded-2xl border border-zinc-800 bg-zinc-900 p-6 shadow-sm">
|
||||||
|
<div>
|
||||||
|
<h2 class="text-lg font-semibold text-zinc-100">Database metadata</h2>
|
||||||
|
<p class="mt-1 text-sm text-zinc-400">These fields are saved only in the module_statuses table.</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<form method="POST" action="{{ route('modules.control.update', $module['name']) }}" class="mt-6 space-y-5">
|
<form method="POST" action="{{ route('modules.control.update', $module['name']) }}" class="mt-6 space-y-5">
|
||||||
@@ -79,90 +87,94 @@
|
|||||||
@method('PUT')
|
@method('PUT')
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label for="description" class="block text-sm font-semibold text-zinc-800 dark:text-zinc-200">Description</label>
|
<label for="description" class="block text-sm font-semibold text-zinc-200">Description</label>
|
||||||
<textarea id="description" name="description" rows="5" class="mt-2 w-full rounded-xl border border-zinc-300 bg-white px-4 py-3 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100" placeholder="Add the database-only module description...">{{ old('description', $module['database_description'] ?? $module['description']) }}</textarea>
|
<textarea id="description" name="description" rows="5" class="mt-2 w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-3 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20" placeholder="Add the database-only module description...">{{ old('description', $module['database_description'] ?? $module['description']) }}</textarea>
|
||||||
@error('description')<p class="mt-2 text-sm text-red-600">{{ $message }}</p>@enderror
|
@error('description')<p class="mt-2 text-sm text-red-400">{{ $message }}</p>@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="grid gap-5 md:grid-cols-2">
|
<div class="grid gap-5 md:grid-cols-2">
|
||||||
<div>
|
<div>
|
||||||
<label for="version" class="block text-sm font-semibold text-zinc-800 dark:text-zinc-200">Version</label>
|
<label for="version" class="block text-sm font-semibold text-zinc-200">Version</label>
|
||||||
<input id="version" name="version" type="text" maxlength="50" value="{{ old('version', $module['database_version'] ?? $module['version']) }}" class="mt-2 w-full rounded-xl border border-zinc-300 bg-white px-4 py-2 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100" placeholder="Example: 1.0.0" />
|
<input id="version" name="version" type="text" maxlength="50" value="{{ old('version', $module['database_version'] ?? $module['version']) }}" class="mt-2 w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20" placeholder="Example: 1.0.0" />
|
||||||
<p class="mt-2 text-xs text-zinc-500 dark:text-zinc-400">Disk version: {{ $module['disk_version'] ?: '—' }}</p>
|
<p class="mt-2 text-xs text-zinc-400">Disk version: {{ $module['disk_version'] ?: '—' }}</p>
|
||||||
@error('version')<p class="mt-2 text-sm text-red-600">{{ $message }}</p>@enderror
|
@error('version')<p class="mt-2 text-sm text-red-400">{{ $message }}</p>@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label for="sort_order" class="block text-sm font-semibold text-zinc-800 dark:text-zinc-200">Sort order</label>
|
<label for="sort_order" class="block text-sm font-semibold text-zinc-200">Sort order</label>
|
||||||
<input id="sort_order" name="sort_order" type="number" min="0" value="{{ old('sort_order', $module['sort_order']) }}" class="mt-2 w-full rounded-xl border border-zinc-300 bg-white px-4 py-2 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100" />
|
<input id="sort_order" name="sort_order" type="number" min="0" value="{{ old('sort_order', $module['sort_order']) }}" class="mt-2 w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20" />
|
||||||
@error('sort_order')<p class="mt-2 text-sm text-red-600">{{ $message }}</p>@enderror
|
@error('sort_order')<p class="mt-2 text-sm text-red-400">{{ $message }}</p>@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label for="icon" class="block text-sm font-semibold text-zinc-800 dark:text-zinc-200">Font Awesome icon</label>
|
<label for="icon" class="block text-sm font-semibold text-zinc-200">Font Awesome icon</label>
|
||||||
<input id="icon" name="icon" type="text" maxlength="80" value="{{ old('icon', $module['icon']) }}" class="mt-2 w-full rounded-xl border border-zinc-300 bg-white px-4 py-2 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100" placeholder="fa-puzzle-piece" />
|
<input id="icon" name="icon" type="text" maxlength="80" value="{{ old('icon', $module['icon']) }}" class="mt-2 w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20" placeholder="fa-puzzle-piece" />
|
||||||
@error('icon')<p class="mt-2 text-sm text-red-600">{{ $message }}</p>@enderror
|
@error('icon')<p class="mt-2 text-sm text-red-400">{{ $message }}</p>@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label for="category" class="block text-sm font-semibold text-zinc-800 dark:text-zinc-200">Category</label>
|
<label for="category" class="block text-sm font-semibold text-zinc-200">Category</label>
|
||||||
<select id="category" name="category" class="mt-2 w-full rounded-xl border border-zinc-300 bg-white px-4 py-2 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100">
|
<select id="category" name="category" class="mt-2 w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20">
|
||||||
@foreach (['Core', 'Optional'] as $option)
|
@foreach (['Core', 'Optional'] as $option)
|
||||||
<option value="{{ $option }}" @selected(old('category', $module['category']) === $option)>{{ $option }}</option>
|
<option value="{{ $option }}" @selected(old('category', $module['category']) === $option)>{{ $option }}</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
</select>
|
</select>
|
||||||
@error('category')<p class="mt-2 text-sm text-red-600">{{ $message }}</p>@enderror
|
@error('category')<p class="mt-2 text-sm text-red-400">{{ $message }}</p>@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label for="vendor_type" class="block text-sm font-semibold text-zinc-800 dark:text-zinc-200">Vendor type</label>
|
<label for="vendor_type" class="block text-sm font-semibold text-zinc-200">Vendor type</label>
|
||||||
<select id="vendor_type" name="vendor_type" class="mt-2 w-full rounded-xl border border-zinc-300 bg-white px-4 py-2 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100">
|
<select id="vendor_type" name="vendor_type" class="mt-2 w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20">
|
||||||
@foreach (['MPBA', 'Third-party'] as $option)
|
@foreach (['MPBA', 'Third-party'] as $option)
|
||||||
<option value="{{ $option }}" @selected(old('vendor_type', $module['vendor_type']) === $option)>{{ $option }}</option>
|
<option value="{{ $option }}" @selected(old('vendor_type', $module['vendor_type']) === $option)>{{ $option }}</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
</select>
|
</select>
|
||||||
@error('vendor_type')<p class="mt-2 text-sm text-red-600">{{ $message }}</p>@enderror
|
@error('vendor_type')<p class="mt-2 text-sm text-red-400">{{ $message }}</p>@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label for="author" class="block text-sm font-semibold text-zinc-800 dark:text-zinc-200">Author</label>
|
<label for="author" class="block text-sm font-semibold text-zinc-200">Author</label>
|
||||||
<input id="author" name="author" type="text" maxlength="120" value="{{ old('author', $module['author']) }}" class="mt-2 w-full rounded-xl border border-zinc-300 bg-white px-4 py-2 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100" />
|
<input id="author" name="author" type="text" maxlength="120" value="{{ old('author', $module['author']) }}" class="mt-2 w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-2 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20" />
|
||||||
@error('author')<p class="mt-2 text-sm text-red-600">{{ $message }}</p>@enderror
|
@error('author')<p class="mt-2 text-sm text-red-400">{{ $message }}</p>@enderror
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<label for="notes" class="block text-sm font-semibold text-zinc-800 dark:text-zinc-200">Internal notes</label>
|
<label for="notes" class="block text-sm font-semibold text-zinc-200">Notes</label>
|
||||||
<textarea id="notes" name="notes" rows="4" class="mt-2 w-full rounded-xl border border-zinc-300 bg-white px-4 py-3 text-sm text-zinc-900 shadow-sm focus:border-blue-500 focus:outline-none focus:ring-2 focus:ring-blue-500/20 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100">{{ old('notes', $module['notes']) }}</textarea>
|
<textarea id="notes" name="notes" rows="4" class="mt-2 w-full rounded-xl border border-zinc-700 bg-zinc-950 px-4 py-3 text-sm text-zinc-100 shadow-sm focus:border-emerald-500 focus:outline-none focus:ring-2 focus:ring-emerald-500/20" placeholder="Internal notes...">{{ old('notes', $module['notes']) }}</textarea>
|
||||||
@error('notes')<p class="mt-2 text-sm text-red-600">{{ $message }}</p>@enderror
|
@error('notes')<p class="mt-2 text-sm text-red-400">{{ $message }}</p>@enderror
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<button type="submit" class="rounded-xl border border-blue-500/40 bg-blue-600 px-4 py-2 text-sm font-semibold text-white shadow-sm hover:bg-blue-700 focus:outline-none focus:ring-2 focus:ring-blue-500/30">Save Module Metadata</button>
|
<div class="flex justify-end">
|
||||||
|
<button type="submit" class="rounded-xl border border-emerald-500/40 bg-emerald-600 px-5 py-2 text-sm font-semibold text-white shadow-sm hover:bg-emerald-700 focus:outline-none focus:ring-2 focus:ring-emerald-500/30">
|
||||||
|
Save Metadata
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="grid gap-6 lg:grid-cols-2">
|
<div class="grid gap-6 lg:grid-cols-2">
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-6 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<div class="rounded-2xl border border-zinc-800 bg-zinc-900 p-6 shadow-sm">
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">Dependencies</h2>
|
<h2 class="text-lg font-semibold text-zinc-100">Dependency safety</h2>
|
||||||
<div class="mt-4 space-y-3 text-sm">
|
<div class="mt-5 space-y-4 text-sm">
|
||||||
<div>
|
<div>
|
||||||
<div class="text-xs font-semibold uppercase text-zinc-500">Required modules</div>
|
<div class="text-xs font-semibold uppercase text-zinc-500">Requires</div>
|
||||||
<div class="mt-1 text-zinc-800 dark:text-zinc-200">{{ empty($module['requires']) ? 'None' : implode(', ', $module['requires']) }}</div>
|
<div class="mt-1 text-zinc-200">{{ empty($module['requires']) ? 'None' : implode(', ', $module['requires']) }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="text-xs font-semibold uppercase text-zinc-500">Missing dependencies</div>
|
<div class="text-xs font-semibold uppercase text-zinc-500">Missing dependencies</div>
|
||||||
<div class="mt-1 {{ $module['has_missing_dependencies'] ? 'text-orange-700 dark:text-orange-300' : 'text-zinc-800 dark:text-zinc-200' }}">{{ empty($module['missing_dependencies']) ? 'None' : implode(', ', $module['missing_dependencies']) }}</div>
|
<div class="mt-1 {{ $module['has_missing_dependencies'] ? 'text-orange-300' : 'text-zinc-200' }}">{{ empty($module['missing_dependencies']) ? 'None' : implode(', ', $module['missing_dependencies']) }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="text-xs font-semibold uppercase text-zinc-500">Enabled dependents</div>
|
<div class="text-xs font-semibold uppercase text-zinc-500">Enabled dependents</div>
|
||||||
<div class="mt-1 {{ $module['can_disable'] ? 'text-zinc-800 dark:text-zinc-200' : 'text-orange-700 dark:text-orange-300' }}">{{ empty($module['enabled_dependents']) ? 'None' : implode(', ', $module['enabled_dependents']) }}</div>
|
<div class="mt-1 {{ $module['can_disable'] ? 'text-zinc-200' : 'text-orange-300' }}">{{ empty($module['enabled_dependents']) ? 'None' : implode(', ', $module['enabled_dependents']) }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-6 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<div class="rounded-2xl border border-zinc-800 bg-zinc-900 p-6 shadow-sm">
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">Activation</h2>
|
<h2 class="text-lg font-semibold text-zinc-100">Activation</h2>
|
||||||
<p class="mt-2 text-sm text-zinc-500 dark:text-zinc-400">Disabling is blocked when another enabled module depends on this module.</p>
|
<p class="mt-2 text-sm text-zinc-400">Disabling is blocked when another enabled module depends on this module.</p>
|
||||||
<div class="mt-5">
|
<div class="mt-5">
|
||||||
@if ($module['enabled'])
|
@if ($module['enabled'])
|
||||||
<form method="POST" action="{{ route('modules.control.disable', $module['name']) }}">
|
<form method="POST" action="{{ route('modules.control.disable', $module['name']) }}">
|
||||||
@@ -179,16 +191,30 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-6 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<details class="group overflow-hidden rounded-2xl border border-zinc-800 bg-zinc-900 shadow-sm">
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">Developer files</h2>
|
<summary class="flex cursor-pointer list-none items-center justify-between gap-3 bg-gradient-to-r from-slate-950 via-blue-950 to-slate-900 px-5 py-4 text-white marker:hidden">
|
||||||
<div class="mt-5 grid gap-4 md:grid-cols-2 xl:grid-cols-3">
|
<div class="flex min-w-0 items-center gap-3">
|
||||||
|
<span class="inline-flex h-10 w-10 shrink-0 items-center justify-center rounded-xl bg-blue-500/25 text-white ring-1 ring-white/20">
|
||||||
|
<i class="fa-solid fa-code text-sm" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
<div class="min-w-0">
|
||||||
|
<p class="text-[0.65rem] font-black uppercase tracking-[0.18em] text-blue-200">Developer</p>
|
||||||
|
<h2 class="truncate text-base font-extrabold tracking-tight">Developer files</h2>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<span class="inline-flex shrink-0 items-center gap-2 rounded-xl bg-white/15 px-3 py-1.5 text-xs font-extrabold ring-1 ring-white/20">
|
||||||
|
{{ collect($fileGroups)->flatten()->count() }} files
|
||||||
|
<i class="fa-solid fa-chevron-right text-xs transition group-open:rotate-90" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
</summary>
|
||||||
|
<div class="grid gap-4 p-5 md:grid-cols-2 xl:grid-cols-3">
|
||||||
@foreach ($fileGroups as $label => $files)
|
@foreach ($fileGroups as $label => $files)
|
||||||
<div class="rounded-xl border border-zinc-200 bg-zinc-50 p-4 dark:border-zinc-800 dark:bg-zinc-950/60">
|
<div class="rounded-xl border border-zinc-800 bg-zinc-950/60 p-4">
|
||||||
<div class="flex items-center justify-between gap-3">
|
<div class="flex items-center justify-between gap-3">
|
||||||
<h3 class="text-sm font-semibold text-zinc-900 dark:text-zinc-100">{{ $label }}</h3>
|
<h3 class="text-sm font-semibold text-zinc-100">{{ $label }}</h3>
|
||||||
<span class="rounded-full border border-zinc-300 px-2 py-0.5 text-xs font-semibold text-zinc-600 dark:border-zinc-700 dark:text-zinc-300">{{ count($files) }}</span>
|
<span class="rounded-full border border-zinc-700 px-2 py-0.5 text-xs font-semibold text-zinc-300">{{ count($files) }}</span>
|
||||||
</div>
|
</div>
|
||||||
<ul class="mt-3 max-h-36 space-y-1 overflow-auto text-xs text-zinc-600 dark:text-zinc-400">
|
<ul class="mt-3 max-h-36 space-y-1 overflow-auto text-xs text-zinc-400">
|
||||||
@forelse ($files as $file)
|
@forelse ($files as $file)
|
||||||
<li class="break-all">{{ $file }}</li>
|
<li class="break-all">{{ $file }}</li>
|
||||||
@empty
|
@empty
|
||||||
@@ -198,41 +224,85 @@
|
|||||||
</div>
|
</div>
|
||||||
@endforeach
|
@endforeach
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</details>
|
||||||
|
|
||||||
<div class="grid gap-6 lg:grid-cols-2">
|
<details class="group overflow-hidden rounded-2xl border border-zinc-800 bg-zinc-900 shadow-sm">
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-6 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<summary class="flex cursor-pointer list-none items-center justify-between gap-3 bg-gradient-to-r from-slate-950 via-blue-950 to-slate-900 px-5 py-4 text-white marker:hidden">
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">README preview</h2>
|
<div class="flex min-w-0 items-center gap-3">
|
||||||
<pre class="mt-4 max-h-96 overflow-auto whitespace-pre-wrap rounded-xl border border-zinc-200 bg-zinc-50 p-4 text-xs leading-6 text-zinc-700 dark:border-zinc-800 dark:bg-zinc-950 dark:text-zinc-300">{{ $module['readme'] ?: 'No README found.' }}</pre>
|
<span class="inline-flex h-10 w-10 shrink-0 items-center justify-center rounded-xl bg-blue-500/25 text-white ring-1 ring-white/20">
|
||||||
|
<i class="fa-solid fa-book-open text-sm" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
<div class="min-w-0">
|
||||||
|
<p class="text-[0.65rem] font-black uppercase tracking-[0.18em] text-blue-200">Documentation</p>
|
||||||
|
<h2 class="truncate text-base font-extrabold tracking-tight">README preview</h2>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<span class="inline-flex shrink-0 items-center gap-2 rounded-xl bg-white/15 px-3 py-1.5 text-xs font-extrabold ring-1 ring-white/20">
|
||||||
|
Preview
|
||||||
|
<i class="fa-solid fa-chevron-right text-xs transition group-open:rotate-90" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
</summary>
|
||||||
|
<div class="p-5">
|
||||||
|
<pre class="max-h-96 overflow-auto whitespace-pre-wrap rounded-xl border border-zinc-800 bg-zinc-950 p-4 text-xs leading-6 text-zinc-300">{{ $module['readme'] ?: 'No README found.' }}</pre>
|
||||||
</div>
|
</div>
|
||||||
|
</details>
|
||||||
|
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-6 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<details class="group overflow-hidden rounded-2xl border border-zinc-800 bg-zinc-900 shadow-sm">
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">Changelog preview</h2>
|
<summary class="flex cursor-pointer list-none items-center justify-between gap-3 bg-gradient-to-r from-slate-950 via-blue-950 to-slate-900 px-5 py-4 text-white marker:hidden">
|
||||||
<pre class="mt-4 max-h-96 overflow-auto whitespace-pre-wrap rounded-xl border border-zinc-200 bg-zinc-50 p-4 text-xs leading-6 text-zinc-700 dark:border-zinc-800 dark:bg-zinc-950 dark:text-zinc-300">{{ $module['changelog'] ?: 'No changelog found.' }}</pre>
|
<div class="flex min-w-0 items-center gap-3">
|
||||||
|
<span class="inline-flex h-10 w-10 shrink-0 items-center justify-center rounded-xl bg-blue-500/25 text-white ring-1 ring-white/20">
|
||||||
|
<i class="fa-solid fa-list-check text-sm" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
<div class="min-w-0">
|
||||||
|
<p class="text-[0.65rem] font-black uppercase tracking-[0.18em] text-blue-200">Release history</p>
|
||||||
|
<h2 class="truncate text-base font-extrabold tracking-tight">Changelog preview</h2>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<span class="inline-flex shrink-0 items-center gap-2 rounded-xl bg-white/15 px-3 py-1.5 text-xs font-extrabold ring-1 ring-white/20">
|
||||||
|
Preview
|
||||||
|
<i class="fa-solid fa-chevron-right text-xs transition group-open:rotate-90" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
</summary>
|
||||||
|
<div class="p-5">
|
||||||
|
<pre class="max-h-96 overflow-auto whitespace-pre-wrap rounded-xl border border-zinc-800 bg-zinc-950 p-4 text-xs leading-6 text-zinc-300">{{ $module['changelog'] ?: 'No changelog found.' }}</pre>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</details>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<aside class="space-y-6">
|
<aside class="space-y-6">
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-6 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<details class="group overflow-hidden rounded-2xl border border-zinc-800 bg-zinc-900 shadow-sm">
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">Developer information</h2>
|
<summary class="flex cursor-pointer list-none items-center justify-between gap-3 bg-gradient-to-r from-slate-950 via-blue-950 to-slate-900 px-5 py-4 text-white marker:hidden">
|
||||||
<dl class="mt-5 space-y-4 text-sm">
|
<div class="flex min-w-0 items-center gap-3">
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Installed path</dt><dd class="mt-1 break-all text-zinc-900 dark:text-zinc-100">{{ $module['path'] }}</dd></div>
|
<span class="inline-flex h-10 w-10 shrink-0 items-center justify-center rounded-xl bg-blue-500/25 text-white ring-1 ring-white/20">
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Namespace</dt><dd class="mt-1 break-all text-zinc-900 dark:text-zinc-100">{{ $module['namespace'] ?: '—' }}</dd></div>
|
<i class="fa-solid fa-circle-info text-sm" aria-hidden="true"></i>
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Composer package</dt><dd class="mt-1 break-all text-zinc-900 dark:text-zinc-100">{{ $module['composer_name'] ?: '—' }}</dd></div>
|
</span>
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Git commit</dt><dd class="mt-1 text-zinc-900 dark:text-zinc-100">{{ $module['git_commit'] ?: '—' }}</dd></div>
|
<div class="min-w-0">
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Build date</dt><dd class="mt-1 text-zinc-900 dark:text-zinc-100">{{ $module['build_date'] ?: '—' }}</dd></div>
|
<p class="text-[0.65rem] font-black uppercase tracking-[0.18em] text-blue-200">Developer</p>
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Database record</dt><dd class="mt-1 text-zinc-900 dark:text-zinc-100">ID {{ $module['status_record']?->id ?? '—' }}</dd></div>
|
<h2 class="truncate text-base font-extrabold tracking-tight">Developer information</h2>
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Last updated</dt><dd class="mt-1 text-zinc-900 dark:text-zinc-100">{{ $module['updated_at']?->format('d M Y H:i') ?? '—' }}</dd></div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<span class="inline-flex shrink-0 items-center gap-2 rounded-xl bg-white/15 px-3 py-1.5 text-xs font-extrabold ring-1 ring-white/20">
|
||||||
|
Details
|
||||||
|
<i class="fa-solid fa-chevron-right text-xs transition group-open:rotate-90" aria-hidden="true"></i>
|
||||||
|
</span>
|
||||||
|
</summary>
|
||||||
|
<dl class="space-y-4 p-5 text-sm">
|
||||||
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Installed path</dt><dd class="mt-1 break-all text-zinc-100">{{ $module['path'] }}</dd></div>
|
||||||
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Namespace</dt><dd class="mt-1 break-all text-zinc-100">{{ $module['namespace'] ?: '—' }}</dd></div>
|
||||||
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Composer package</dt><dd class="mt-1 break-all text-zinc-100">{{ $module['composer_name'] ?: '—' }}</dd></div>
|
||||||
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Git commit</dt><dd class="mt-1 text-zinc-100">{{ $module['git_commit'] ?: '—' }}</dd></div>
|
||||||
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Build date</dt><dd class="mt-1 text-zinc-100">{{ $module['build_date'] ?: '—' }}</dd></div>
|
||||||
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Database record</dt><dd class="mt-1 text-zinc-100">ID {{ $module['status_record']?->id ?? '—' }}</dd></div>
|
||||||
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Last updated</dt><dd class="mt-1 text-zinc-100">{{ $module['updated_at']?->format('d M Y H:i') ?? '—' }}</dd></div>
|
||||||
</dl>
|
</dl>
|
||||||
</div>
|
</details>
|
||||||
|
|
||||||
<div class="rounded-2xl border border-zinc-200 bg-white p-6 shadow-sm dark:border-zinc-800 dark:bg-zinc-900">
|
<div class="rounded-2xl border border-zinc-800 bg-zinc-900 p-6 shadow-sm">
|
||||||
<h2 class="text-lg font-semibold text-zinc-950 dark:text-zinc-100">Disk metadata</h2>
|
<h2 class="text-lg font-semibold text-zinc-100">Disk metadata</h2>
|
||||||
<dl class="mt-5 space-y-4 text-sm">
|
<dl class="mt-5 space-y-4 text-sm">
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Alias</dt><dd class="mt-1 text-zinc-900 dark:text-zinc-100">{{ $module['alias'] }}</dd></div>
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Alias</dt><dd class="mt-1 text-zinc-100">{{ $module['alias'] }}</dd></div>
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Disk version</dt><dd class="mt-1 text-zinc-900 dark:text-zinc-100">{{ $module['disk_version'] ?: '—' }}</dd></div>
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Disk version</dt><dd class="mt-1 text-zinc-100">{{ $module['disk_version'] ?: '—' }}</dd></div>
|
||||||
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Disk description</dt><dd class="mt-1 text-zinc-900 dark:text-zinc-100">{{ $module['disk_description'] ?: '—' }}</dd></div>
|
<div><dt class="text-xs font-semibold uppercase text-zinc-500">Disk description</dt><dd class="mt-1 text-zinc-100">{{ $module['disk_description'] ?: '—' }}</dd></div>
|
||||||
</dl>
|
</dl>
|
||||||
</div>
|
</div>
|
||||||
</aside>
|
</aside>
|
||||||
|
|||||||
Reference in New Issue
Block a user