aprs.me/lib/aprsme_web/components/layouts/app.html.heex
Graham McIntire 4de48294c6
Remove DaisyUI, migrate to pure Tailwind CSS with TailwindUI patterns
Replace all DaisyUI component classes with pure Tailwind CSS utility
classes following TailwindUI conventions. Use dark: variants for dark
mode instead of DaisyUI's data-theme semantic color system.

- Remove DaisyUI plugin and theme vendor files
- Configure Tailwind v4 custom dark variant for data-theme attribute
- Migrate all components: cards, tables, badges, buttons, forms,
  navigation, dropdowns, modals, alerts, star ratings, spinners
- Update all auth pages (login, register, settings, password reset,
  confirmation) to TailwindUI card layout
- Update content pages (about, API docs, status, packets, bad packets,
  info, weather) to TailwindUI patterns
- Replace opacity-based text styling with semantic gray colors
- Update test assertions to match new class names
2026-02-19 10:07:50 -06:00

176 lines
4.9 KiB
Text

<% assigns = assign_new(assigns, :map_page, fn -> false end) %>
<style>
/* Default scrolling behavior for all pages */
html, body {
overflow: auto !important;
height: auto !important;
min-height: 100vh !important;
}
/* Reset constraints for non-map pages */
body:not(:has(#main-content[data-map-page="true"])) main,
body:not(:has(#main-content[data-map-page="true"])) .phx-main,
body:not(:has(#main-content[data-map-page="true"])) div[data-phx-main="true"] {
overflow: visible !important;
height: auto !important;
max-height: none !important;
min-height: 100vh !important;
}
/* Ensure proper scrolling for non-map pages */
body:not(:has(#main-content[data-map-page="true"])) {
overflow-y: auto !important;
height: auto !important;
}
/* Only apply map constraints to map pages */
body:has(#main-content[data-map-page="true"]) {
overflow: hidden !important;
height: 100vh !important;
}
/* Map page specific styles - hide site header */
body:has(#main-content[data-map-page="true"]) .site-header {
display: none;
}
body:has(#main-content[data-map-page="true"]) main {
padding: 0;
max-width: none;
height: 100vh;
overflow: hidden;
}
body:has(#main-content[data-map-page="true"]) main > div {
max-width: none;
height: 100%;
}
body:has(#main-content[data-map-page="true"]) .phx-main {
position: relative;
height: 100vh;
overflow: hidden;
}
body:has(#main-content[data-map-page="true"]) div[data-phx-main="true"] {
height: 100vh;
overflow: hidden;
}
/* Full page map for APRS home page and callsign pages */
body:has(#main-content[data-map-page="true"]) #aprs-map {
position: fixed !important;
top: 0 !important;
left: 0 !important;
right: 0 !important;
bottom: 0 !important;
height: 100vh !important;
z-index: 1 !important;
transition: right 0.3s ease-in-out !important;
}
/* Desktop slideover behavior for map */
@media (min-width: 1024px) {
body:has(#main-content[data-map-page="true"]) #aprs-map.slideover-open {
right: 352px !important;
}
body:has(#main-content[data-map-page="true"]) #aprs-map.slideover-closed {
right: 0 !important;
}
}
/* Mobile slideover behavior for map */
@media (max-width: 1023px) {
body:has(#main-content[data-map-page="true"]) #aprs-map {
right: 0 !important;
}
}
/* Slideover panel responsive styles */
body:has(#main-content[data-map-page="true"]) .slideover-panel {
position: fixed;
top: 0;
right: 0;
height: 100vh;
width: 352px;
background: white;
box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15);
z-index: 1000;
transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
overflow-y: auto;
}
/* Desktop slideover behavior */
@media (min-width: 1024px) {
body:has(#main-content[data-map-page="true"]) .slideover-panel.slideover-open {
transform: translateX(0);
}
body:has(#main-content[data-map-page="true"]) .slideover-panel.slideover-closed {
transform: translateX(100%);
}
}
/* Mobile slideover behavior */
@media (max-width: 1023px) {
body:has(#main-content[data-map-page="true"]) .slideover-panel {
width: 100vw;
max-width: 400px;
box-shadow: -8px 0 32px rgba(0, 0, 0, 0.2);
}
body:has(#main-content[data-map-page="true"]) .slideover-panel.slideover-open {
transform: translateX(0);
}
body:has(#main-content[data-map-page="true"]) .slideover-panel.slideover-closed {
transform: translateX(100%);
}
}
/* Mobile panel improvements */
@media (max-width: 1023px) {
body:has(#main-content[data-map-page="true"]) .slideover-panel {
display: flex;
flex-direction: column;
}
}
/* Improve scrolling on mobile */
@media (max-width: 1023px) {
body:has(#main-content[data-map-page="true"]) .slideover-panel {
-webkit-overflow-scrolling: touch;
overscroll-behavior: contain;
}
body:has(#main-content[data-map-page="true"]) .slideover-panel .flex-1 {
min-height: 0;
}
}
</style>
<.header dev_mode={Application.get_env(:aprsme, :dev_routes, false)} current_user={@current_user} />
<main
id="main-content"
class={if assigns[:map_page], do: "min-h-screen", else: ""}
data-map-page={to_string(assigns[:map_page] || false)}
>
<div>
<.flash kind={:info} title={gettext("Success!")} flash={@flash} />
<.flash kind={:error} title={gettext("Error!")} flash={@flash} />
<.flash
id="disconnected"
kind={:error}
title={gettext("We can't find the internet")}
close={false}
autoshow={false}
phx-disconnected={show("#disconnected")}
phx-connected={hide("#disconnected")}
>
{gettext("Attempting to reconnect")}
<.icon name="arrow-path" outline={true} class="ml-1 w-3 h-3 inline animate-spin" />
</.flash>
{@inner_content}
</div>
</main>