From 5834be870f64d084d077be1ecb590a9039b8d5e3 Mon Sep 17 00:00:00 2001 From: jamey Date: Thu, 19 Feb 2026 08:30:02 +0000 Subject: [PATCH] add providers, LiveDashboard, errors links to admin sidebar Providers was a hidden page with no nav link. Also adds LiveDashboard and ErrorTracker to the sidebar footer, and styles the provider dropdown menu items. Co-Authored-By: Claude Opus 4.6 --- assets/css/admin/components.css | 22 +++++++++++++++++++ .../components/layouts/admin.html.heex | 18 +++++++++++++++ 2 files changed, 40 insertions(+) diff --git a/assets/css/admin/components.css b/assets/css/admin/components.css index d060229..a758c20 100644 --- a/assets/css/admin/components.css +++ b/assets/css/admin/components.css @@ -472,6 +472,7 @@ box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1); z-index: 50; padding: 0.25rem; + list-style: none; } &:focus-within .admin-dropdown-content, @@ -480,6 +481,27 @@ } } +.admin-dropdown-content li a, +.admin-dropdown-content li button { + display: flex; + align-items: center; + gap: 0.5rem; + padding: 0.5rem 0.75rem; + border-radius: 0.375rem; + font-size: 0.875rem; + color: var(--color-base-content); + text-decoration: none; + cursor: pointer; + background: none; + border: none; + width: 100%; + text-align: left; + + &:hover { + background-color: var(--color-base-200); + } +} + /* ── Spinner ── */ @keyframes admin-spin { diff --git a/lib/berrypod_web/components/layouts/admin.html.heex b/lib/berrypod_web/components/layouts/admin.html.heex index f480237..96702db 100644 --- a/lib/berrypod_web/components/layouts/admin.html.heex +++ b/lib/berrypod_web/components/layouts/admin.html.heex @@ -75,6 +75,14 @@ <.icon name="hero-cube" class="size-5" /> Products +
  • + <.link + navigate={~p"/admin/providers"} + class={admin_nav_active?(@current_path, "/admin/providers")} + > + <.icon name="hero-link" class="size-5" /> Providers + +
  • <.link href={~p"/admin/theme"} @@ -102,6 +110,16 @@ <.icon name="hero-arrow-top-right-on-square" class="size-5" /> View shop
  • +
  • + <.link href={~p"/admin/dashboard"}> + <.icon name="hero-chart-bar" class="size-5" /> LiveDashboard + +
  • +
  • + <.link href={~p"/admin/errors"}> + <.icon name="hero-bug-ant" class="size-5" /> Errors + +
  • <.link href={~p"/users/log-out"} method="delete"> <.icon name="hero-arrow-right-start-on-rectangle" class="size-5" /> Log out