Add admin user management and improve UX
Features: - Add user management for admins (CRUD operations) - Add is_admin column to users table - Add AdminMiddleware for authorization - Add admin routes and views - Add artisan command: user:set-admin Improvements: - Fix Quick Switcher: add x-data for Alpine.js dispatch - Fix Quick Switcher: close on outside click - Redirect non-admin users to front page after login - Add Knowledge Base link in dashboard navigation - Change app logo from Laravel to book icon
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
<div
|
||||
x-data="{ open: false }"
|
||||
@open-quick-switcher.window="console.log('Event received'); open = true; $nextTick(() => $refs.searchInput.focus())"
|
||||
@open-quick-switcher.window="open = true; $nextTick(() => $refs.searchInput.focus())"
|
||||
@keydown.escape.window="open = false"
|
||||
@keydown.ctrl.k.window.prevent="console.log('Ctrl+K pressed'); open = true; $nextTick(() => $refs.searchInput.focus())"
|
||||
@keydown.meta.k.window.prevent="console.log('Cmd+K pressed'); open = true; $nextTick(() => $refs.searchInput.focus())"
|
||||
@keydown.ctrl.k.window.prevent="open = true; $nextTick(() => $refs.searchInput.focus())"
|
||||
@keydown.meta.k.window.prevent="open = true; $nextTick(() => $refs.searchInput.focus())"
|
||||
>
|
||||
<!-- Modal Overlay -->
|
||||
<div
|
||||
@@ -30,6 +30,7 @@ class="fixed inset-0 z-50 bg-gray-900 bg-opacity-50"
|
||||
x-transition:leave-end="opacity-0 translate-y-4"
|
||||
class="fixed inset-0 z-50 overflow-y-auto"
|
||||
style="display: none;"
|
||||
@click="open = false"
|
||||
>
|
||||
<div class="flex min-h-full items-start justify-center p-4 pt-[10vh]">
|
||||
<div
|
||||
@@ -54,10 +55,6 @@ class="w-full pl-10 pr-4 py-3 border-0 focus:ring-0 text-lg"
|
||||
autocomplete="off"
|
||||
>
|
||||
</div>
|
||||
<!-- Debug Info -->
|
||||
<div class="text-xs text-gray-500 mt-2">
|
||||
Search value: "{{ $search }}" | Results count: {{ count($this->results) }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Results -->
|
||||
|
||||
Reference in New Issue
Block a user