This document is a current implementation map for Navet's major product areas. It is intended to help contributors understand where behavior lives, which sections are active, and where story/test coverage is expected to exist.
Current active feature folders under
src/app/features/:
authcalendarclimatedashboardenergylightingmedianotificationspersonrssscenessecuritysensorssettingstasksvacuumweather
Additional notes:
- cross-feature imports should prefer a feature's root
index.tswhen that entrypoint exists notificationsis a supporting feature surfaced through shared app-shell UI rather than a top-level section
src/app/App.tsx assembles:
- the i18n provider
- the global error display
- the authenticated split between login and dashboard shell
- the PWA update prompt
- the network status surface
- the notification/toast layer
- theme- and viewport-related DOM synchronization
Shared app-shell composition lives primarily under
src/app/components/layout/.
Current layout ownership includes:
- header and sidebar
- room navigation
- section navigation helpers
- section customization shell/button
- mobile command, search, and section sheets
- reusable section layouts such as locks, media, and security
Navet uses Zustand for all shared reactive state.
Current store files:
auth-store.tsconfig-store.tsedit-mode-store.tserror-store.tshome-assistant-store.tsnavigation-store.tssearch-store.tssettings-store.tstheme-store.ts
Shared selectors live in
src/app/stores/selectors.ts
and should be preferred over full-store subscriptions.
src/app/services/home-assistant.service.ts
is the public Home Assistant facade. It composes:
src/app/services/ha-connection.service.tssrc/app/services/ha-entity-service.tssrc/app/services/ha-registry.service.ts
The facade emits typed updates for:
- entities
- config
- registries
- connection
The store updates only the affected slices for each event. Avoid broad "copy the whole service state" sync patterns.
Navigation keeps currentRoom persisted in the store while activeSection is derived from the URL
through src/app/navigation/sections.ts.
The current primary section model is:
homeenergysecuritytaskslockslightsmediasettings
Section routing and lazy loading are coordinated by
src/app/features/dashboard/components/dashboard-section-router.tsx.
home: room-driven dashboard overview, editable zone-based home canvas, and home widgetsenergy: energy dashboard, setup wizard, drilldown flow, and energy-only custom widget bandsecurity: camera-first section built on the shared device-section shelltasks: Home Assistant automation/task summaries grouped into sectionslocks: lock-focused section built on the shared device-section shelllights: all-lights overview using the dashboard all-view grid in custom grouping modemedia: grouped media section with audio and TV-specific presentationsettings: appearance, localization, dashboard, interaction, project, and system settings
The dashboard feature owns:
- card registration
- entity visibility
- custom-card placement
- room ordering
- card ordering
- dashboard-specific persisted layout state
- home overview layout state
- sectioned and flow layout behavior
Important paths:
src/app/features/dashboard/utils/card-renderer.tsxsrc/app/features/dashboard/hooks/src/app/features/dashboard/stores/custom-cards-store.tssrc/app/features/dashboard/stores/dashboard-entities-store.tssrc/app/features/dashboard/stores/home-dashboard-layout-store.ts
Current CardType values for dashboard/section widgets:
rssphotonotebatteryenergy-nowbuttonmap
Home-widget implementations currently live under
src/app/features/dashboard/components/widgets/.
The widget store also uses special room sentinels:
__home__for widgets attached to the home overview__energy__for widgets attached to the energy section band
Home widgets may additionally persist zone overrides via
src/app/features/dashboard/zones/.
Home-room navigation is assembled from two sources:
- Home Assistant areas via
src/app/hooks/use-area-rooms.ts - discovered device rooms via
src/app/hooks/use-devices.ts
This keeps the room list stable when registry-backed area names exist while still surfacing devices whose room can only be inferred from entity metadata.
The All home view is grouped into four named zones:
heroactionsstatusanalytics
Default placement and fallback resolution live in:
src/app/features/dashboard/zones/zone-types.tssrc/app/features/dashboard/zones/resolve-card-zone.tssrc/app/features/dashboard/zones/use-zone-layout.ts
- weather-like schedule surfaces with selectable sources and multiple display modes
- key path:
src/app/features/calendar/components/calendar/
- HVAC card presentation, controls, status labels, and settings dialogs
- key path:
src/app/features/climate/components/hvac-card/
- setup wizard, statistics services, dashboard-page composition, and energy widgets
- key paths:
- light card behavior, settings dialogs, and grouped lighting controls
- key path:
src/app/features/lighting/components/light-card/
- artwork-aware media cards, controller hooks, volume/playback behavior, and TV-specific views
- key paths:
- persistent-notification and repair/update notification surfaces used by the app shell
- key path:
src/app/features/notifications/components/notifications/
- RSS/news card logic, source resolution, and item rendering
- key path:
src/app/features/rss/components/rss-feed-card/
- camera cards, cover cards, lock card, and security-specific surface tokens
- key path:
src/app/features/security/components/
- sectioned settings UI for appearance, localization, dashboard, interaction, project, and system controls
- key path:
src/app/features/settings/components/
- Home Assistant automation grouping and task-row presentation
- key paths:
- vacuum cards, status utilities, controls, and settings dialogs
- key path:
src/app/features/vacuum/components/
- weather card controller, overlays, icons, and settings dialog
- key path:
src/app/features/weather/components/weather-card/
primitives/: low-level reusable UI such as shared buttons, card shells, header parts, and compact textpatterns/: composed shared structuressystem/: curated export and token-story surfaceui-kit/: canonical shared import surface for docs, stories, and stable shared consumersshared/: app-specific shared UI and compatibility shimslayout/: app-shell and section-level compositionui/: wrappers around library primitives and dropdown/dialog infrastructure
See ../README.md and README.md for the higher-level explanation.
Storybook is the review surface for:
- token and theme stories
- shared primitives and patterns
- layout and navigation surfaces
- entity cards
- dashboard widgets
- settings sections
- energy-specific visuals
Shared story helpers live in
src/app/storybook/story-frames.tsx
and
src/app/storybook/story-docs.ts.
Vitest is the preferred path for:
- shared utility logic
- persisted store behavior
- controller composition
- browser-dependent hooks
- token and entity-mapping helpers
- dashboard actions and feature-specific logic seams
Current co-located __tests__/ directories:
src/app/components/layout/__tests__/src/app/components/shared/theme/__tests__/src/app/components/system/tokens/__tests__/src/app/features/calendar/components/calendar/__tests__/src/app/features/dashboard/components/__tests__/src/app/features/dashboard/hooks/__tests__/src/app/features/dashboard/stores/__tests__/src/app/features/energy/components/dashboard/__tests__/src/app/features/energy/components/energy-setup-wizard/__tests__/src/app/features/energy/services/__tests__/src/app/features/energy/utils/__tests__/src/app/features/lighting/components/__tests__/src/app/features/lighting/components/light-card/__tests__/src/app/features/media/components/media-card/__tests__/src/app/features/media/components/media/__tests__/src/app/features/rss/components/rss-feed-card/__tests__/src/app/features/tasks/components/__tests__/src/app/features/tasks/utils/__tests__/src/app/features/vacuum/components/vacuum/__tests__/src/app/hooks/__tests__/src/app/stores/__tests__/src/app/utils/__tests__/
Shared test harness support lives in src/test/.
- Update this file when top-level sections, feature ownership, widget types, or test locations change
- Remove references to deleted feature folders or moved paths instead of leaving historical hints in active docs
- Prefer describing the actual current tree over describing an intended future architecture