responsive navbar (#14)

collapse navbar on smaller screens. #9

Co-authored-by: Michael DiLeo <michael.dileo@oakstreethealth.com>
Reviewed-on: #14
This commit was merged in pull request #14.
This commit is contained in:
2025-08-14 19:43:30 +00:00
parent 8e19c2ee20
commit f2b47f38b4
4 changed files with 148 additions and 10 deletions

View File

@@ -51,7 +51,14 @@ async function createOptimizedBuild() {
'video-container',
'photo-gallery',
'photo-item',
'dark'
'dark',
// Responsive navigation classes
'desktop-nav',
'mobile-nav',
'dropdown',
// Button classes
'secondary',
'outline'
],
deep: [
/^--pico-/,
@@ -60,7 +67,12 @@ async function createOptimizedBuild() {
/:hover/,
/:focus/,
/:active/,
/:visited/
/:visited/,
// Dropdown and interactive states
/\[open\]/,
/\[role=/,
/details/,
/summary/
],
// Keep base typography selectors that are essential for proper font rendering
greedy: [
@@ -78,7 +90,14 @@ async function createOptimizedBuild() {
/^a$/,
/^a:/, // Add anchor pseudo-classes like a:hover, a:focus
/^a\./, // Add anchor with classes like a.secondary
/^a\[/ // Add anchor with attributes like a[role=button]
/^a\[/, // Add anchor with attributes like a[role=button]
// Dropdown and button elements
/^details$/,
/^summary$/,
/^button$/,
/^button:/,
/^button\./,
/^button\[/
]
},
variables: true,
@@ -239,7 +258,7 @@ async function bundleAndMinifyJS() {
hoist_vars: false,
if_return: true,
join_vars: true,
cascade: true,
side_effects: true
},
mangle: {