feat(layout): unified app-shell primitives (Phase A) #51
No reviewers
Labels
No labels
app:activities
app:chat
app:events
app:forum
app:libra
app:market
app:restaurant
app:tasks
app:wallet
app:webapp
bug
enhancement
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
aiolabs/webapp!51
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feat/unified-app-shell"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Phase A of the unified bottom-nav UX. Pure groundwork — no consumer is wired up yet, so this PR is additive: 7 new files + i18n / env updates, no
App.vueorHub.vuechanges. Phase B refactors consumers in the order chat/wallet/tasks → forum/libra/market/activities → hub last.Resolves the design phase of the unified-bottom-nav effort that surfaced issue #41 follow-ups: #45 (currency picker), #46 (notification badges), #47 (desktop side-rail), #48 (standalone→hub SSO), #49 (long-press), #50 (per-app SettingsPage cleanup).
What this adds
Components (
src/components/layout/)AppShell.vue— outer wrapper composingBottomNav+HubPill+Toaster. StandaloneApp.vues become thin consumers:<AppShell :tabs="appTabs" :is-active="isActiveTab" />.BottomNav.vue— renders consumer-provided tabs and appends<ProfileSheetTrigger>as the rightmost slot (always-on, can't be skipped).BottomTabinterface includes optionalbadgefor unread/cart counts.ProfileSheetTrigger.vue— bottom-row Profile button. Authed → opens<Sheet>with<ProfileSheetContent>; unauth → either opens the sheet (Hub, so prefs are reachable when logged out) or routes to/login(standalones).ProfileSheetContent.vue— identity card (avatar + display name + npub), "Back to hub" link,<PreferencesRow layout="list" />, and<ProfileSettings />for authed users (or a prominent log-in CTA for unauth).PreferencesRow.vue— extracted theme/language/currency triad with alayout: 'row' | 'list'prop. Hub usesrow; the profile sheet useslist.HubPill.vue— fixed top-right back-to-hub link, safe-area-aware. ReadsVITE_HUB_ROOT_URL(defaults to/for path-mount).Composable (
src/composables/useCurrentUserAvatar.ts){ pictureUrl, displayName, fallbackInitial, isAuthenticated }from the auth user object — used by both the bottom-row trigger and the in-sheet identity card. No new service needed: the LNbitsextraobject already mirrors the kind-0 fields we care about.i18n (
src/i18n/locales/{en,es,fr}.ts+types.ts)common.nav.*sub-namespace:profile,preferences,profileDescription,profileLoggedOutDescription,login,backToHub,hub,theme,themeLight,themeDark,themeSystem,language,currency,currencyComingSoon,currencyComingSoonDescription. Type-checked.Env (
.env.example)VITE_HUB_ROOT_URLwith path-mount / subdomain / local-dev guidance. Path-mount: leave empty (falls back to/). Subdomain: full URL. Local dev:http://localhost:5173/.Verification
vue-tsc -b --noEmitpasses — no TypeScript regressions.Out of scope
App.vueshells → Phase B (separate PR).Hub.vueadoption of the new primitives → Phase D (separate PR, no visual change expected).SettingsPage.vue— #50.🤖 Generated with Claude Code