@meith/theme-phasebook 0.33.2 → 0.33.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/src/slots/header.tsx +43 -26
- package/src/theme.ts +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@meith/theme-phasebook",
|
|
3
|
-
"version": "0.33.
|
|
3
|
+
"version": "0.33.4",
|
|
4
4
|
"description": "A theme for Meith with a familiar social shape, built on the default theme's slots.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -20,9 +20,9 @@
|
|
|
20
20
|
"access": "public"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@meith/theme-default": "^0.33.
|
|
24
|
-
"@meith/theme-kit": "^0.33.
|
|
25
|
-
"@meith/ui": "^0.33.
|
|
23
|
+
"@meith/theme-default": "^0.33.4",
|
|
24
|
+
"@meith/theme-kit": "^0.33.4",
|
|
25
|
+
"@meith/ui": "^0.33.4"
|
|
26
26
|
},
|
|
27
27
|
"peerDependencies": {
|
|
28
28
|
"react": "^19.2.0"
|
package/src/slots/header.tsx
CHANGED
|
@@ -121,6 +121,23 @@ function MobileNavItem({ item }: { item: HeaderModel['navigation'][number] }) {
|
|
|
121
121
|
)
|
|
122
122
|
}
|
|
123
123
|
|
|
124
|
+
function MenuGlyph() {
|
|
125
|
+
return (
|
|
126
|
+
<svg
|
|
127
|
+
aria-hidden="true"
|
|
128
|
+
viewBox="0 0 20 20"
|
|
129
|
+
className="size-5"
|
|
130
|
+
fill="none"
|
|
131
|
+
stroke="currentColor"
|
|
132
|
+
strokeWidth="1.75"
|
|
133
|
+
strokeLinecap="round"
|
|
134
|
+
>
|
|
135
|
+
<path className="group-open/menu:hidden" d="M3 5.5h14M3 10h14M3 14.5h14" />
|
|
136
|
+
<path className="hidden group-open/menu:block" d="m5 5 10 10M15 5 5 15" />
|
|
137
|
+
</svg>
|
|
138
|
+
)
|
|
139
|
+
}
|
|
140
|
+
|
|
124
141
|
export function Header({
|
|
125
142
|
boardTitle,
|
|
126
143
|
homeHref,
|
|
@@ -150,13 +167,13 @@ export function Header({
|
|
|
150
167
|
data-nav-view="desktop"
|
|
151
168
|
className="hidden min-w-0 flex-1 justify-center lg:flex"
|
|
152
169
|
>
|
|
153
|
-
<ul className="flex items-center gap-
|
|
170
|
+
<ul className="flex items-center gap-0.5 whitespace-nowrap">
|
|
154
171
|
{navigation.map((item) => (
|
|
155
|
-
<li key={item.href} className="group relative">
|
|
172
|
+
<li key={item.href} className="group relative shrink-0">
|
|
156
173
|
<a
|
|
157
174
|
href={item.href}
|
|
158
175
|
{...linkTarget(item)}
|
|
159
|
-
className="inline-flex h-
|
|
176
|
+
className="inline-flex h-10 items-center rounded-lg px-3.5 text-sm font-medium text-muted-foreground transition-colors hover:bg-accent hover:text-foreground xl:px-5"
|
|
160
177
|
>
|
|
161
178
|
{item.label}
|
|
162
179
|
</a>
|
|
@@ -167,30 +184,30 @@ export function Header({
|
|
|
167
184
|
</nav>
|
|
168
185
|
)}
|
|
169
186
|
|
|
170
|
-
<div className="flex shrink-0 items-center justify-end">
|
|
171
|
-
|
|
187
|
+
<div className="flex shrink-0 items-center justify-end gap-2">
|
|
188
|
+
{children}
|
|
189
|
+
{navigation.length > 0 && (
|
|
190
|
+
<nav aria-label={c('sectionsAriaLabel')} data-nav-view="mobile" className="lg:hidden">
|
|
191
|
+
<details data-nav-disclosure className="group/menu">
|
|
192
|
+
<summary
|
|
193
|
+
className={`rounded-full text-foreground transition-colors hover:bg-accent group-open/menu:bg-accent flex size-10 cursor-default list-none items-center justify-center select-none [&::-webkit-details-marker]:hidden [&::marker]:content-none`}
|
|
194
|
+
>
|
|
195
|
+
<MenuGlyph />
|
|
196
|
+
<span className="sr-only">{c('sectionsAriaLabel')}</span>
|
|
197
|
+
</summary>
|
|
172
198
|
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
<ul className="flex flex-col gap-0.5 pb-2">
|
|
186
|
-
{navigation.map((item) => (
|
|
187
|
-
<MobileNavItem key={item.href} item={item} />
|
|
188
|
-
))}
|
|
189
|
-
</ul>
|
|
190
|
-
</details>
|
|
191
|
-
</div>
|
|
192
|
-
</nav>
|
|
193
|
-
)}
|
|
199
|
+
<div className="absolute inset-x-0 top-full z-30 max-h-[calc(100dvh-4rem)] overflow-y-auto border-b border-border bg-card shadow-elevation">
|
|
200
|
+
<ul className={`${PAGE} flex flex-col gap-0.5 py-2`}>
|
|
201
|
+
{navigation.map((item) => (
|
|
202
|
+
<MobileNavItem key={item.href} item={item} />
|
|
203
|
+
))}
|
|
204
|
+
</ul>
|
|
205
|
+
</div>
|
|
206
|
+
</details>
|
|
207
|
+
</nav>
|
|
208
|
+
)}
|
|
209
|
+
</div>
|
|
210
|
+
</div>
|
|
194
211
|
</header>
|
|
195
212
|
)
|
|
196
213
|
}
|
package/src/theme.ts
CHANGED