# MOOX — Component & Route Map (handoff)

Bridge from the wireframe prototype to the native iOS + Android build. Wireframe CSS classes / custom elements map to production components; screen files map to routes; product rules must survive the port.

## 1. Class / element → production component

| Wireframe class / element | Production component | Notes |
|---|---|---|
| `<mx-phone os caption>` | (device frame — dev harness only) | Not shipped; replaced by native window. `os` = ios/android. |
| `<mx-appbar back title link>` | `MxTopAppBar` | Back/close + centered title + optional trailing text action. |
| `<mx-topnav active onbrand avatar>` | `MxSegmentedHeader` | Perangkat/Eksplor segmented + avatar. |
| `<mx-fab href>` | `MxFab` | Floating TanyaMoo (AI) trigger. |
| `.btn` `.btn--primary` `.btn--soft` `.btn--ghost` `.btn--google` `.btn--disabled` | `MxButton variant=…` | Disabled = brand-muted fill (matches Figma). |
| `.field` `.input` `.input--trail` | `MxField` / `MxTextInput` | Trailing slot for password eye toggle. |
| `.check` | `MxCheckbox` | Label supports inline links. |
| `.seg` | `MxSegmented` | aria-current marks active. |
| `.chip` `.chips` | `MxChip` / `MxChipGroup` | `aria-pressed` = selected; ink fill when active. |
| `.card` | `MxCard` | `<a>` cards are `display:block` (prevents bg fragmenting). |
| `.device-card` (`--light`) | `MxDeviceCard` | Glasses icon, name, battery, status badge. |
| `.badge` `.badge--ok/--off` | `MxStatusBadge` | Dot + label. |
| `.battery` | `MxBattery` | Bar + % fill. |
| `.media-card` (`[data-state]`, `.is-selected`) | `MxMediaCard state=…` | preview / imported / selected. See §3. |
| `.media-grid` `.media-group` | `MxMediaGrid` / `MxMediaSection` | 3-col grid, date-grouped. |
| `.row` `.rows` | `MxListRow` | Discovery / settings rows. |
| `.banner` (`--light`) | `MxBanner` | Inline notice + trailing action. |
| `.scrim` + `.sheet` (`--card`) | `MxBottomSheet` / `MxDialog` | Modal surfaces. |
| `.steps` `.step` | `MxStepList` | Numbered onboarding steps. |
| `.gesture` | `MxGestureRow` | Calibration gesture explainer. |
| `.glyph` `.glyph__disc` | `MxEmptyState` | Big disc + title + text (search/empty/success). |
| `.msg` `.msg--ai/--me` `.wave` | `MxMessage` / `MxVoiceNote` | TanyaMoo chat bubbles + voice. |
| `.composer` | `MxComposer` | Chat input + mic/send. |
| `.hero` | `MxHero` | Onboarding splash. |

## 2. Screen file → route

| File | Route | Flow |
|---|---|---|
| `onboarding/getting-start.html` | `/welcome` | Onboarding |
| `onboarding/register.html` | `/register` | Onboarding |
| `onboarding/phone.html` | `/register/phone` | Onboarding |
| `onboarding/otp.html` | `/register/otp` | Onboarding |
| `onboarding/login.html` | `/login` | Onboarding |
| `device/type-select.html` | `/pair/type` | Pairing (first step) |
| `pairing/prepare.html` | `/pair/prepare` | Pairing |
| `pairing/searching.html` | `/pair/searching` | Pairing |
| `pairing/device-list.html` | `/pair/devices` | Pairing |
| `pairing/paired.html` | `/pair/success` | Pairing |
| `pairing/not-found.html` | `/pair/not-found` | Pairing |
| `pairing/calibrate.html` | `/pair/calibrate` | Pairing |
| `home/home.html` | `/home` (tab: Perangkat) | Home |
| `home/explore.html` | `/explore` (tab: Eksplor) | Home |
| `home/select.html` | `/home/select` | Home |
| `transfer/import.html` | `/import` | Transfer |
| `transfer/import-warning.html` | `/import?warn=1` | Transfer |
| `ai/tanyamoo.html` | `/ai` | AI |
| `ai/chat.html` | `/ai/chat` | AI |
| `device/active-devices.html` | `/device/active` | Device management |
| `warranty/status.html` | `/device-config/warranty` | Warranty status + claims (F32/F33) |
| `warranty/claim.html` | `/warranty/claim` | Warranty claim form (F33) |

## 3. Product rules to preserve (not just styling)

1. **Preview-vs-imported media.** Media still on the glasses is a **low-res, watermarked preview** (`MxMediaCard state="preview"`): diagonal "MOOX" watermark + lock badge, no share/export. Only after import (`state="imported"`) is the full-resolution, watermark-free file available. The watermark is a *gate*, not decoration — exports must be blocked until import completes.
2. **Auto-clean after import.** On successful import, source files are deleted from the device. The "Jangan tutup aplikasi" sheet warns the user not to background the app mid-transfer (data loss). Honour "Jangan ingatkan lagi".
3. **Connection-gated actions.** Import, calibrate, and live AskAI require `status = Terhubung`. Disable + show reconnect when off.
4. **AI capture gestures** (calibrate): 1 press = photo, 2 presses = video, long-press = TanyaMoo AI. Keep consistent across firmware + app copy.
5. **Settings row semantics.** Actionable = `<a class="row card row--go">` + trailing chevron (`#ic-chevron-right`), content span-wrapped (title `<strong>`, value/hint `<small>`); info-only = `<div class="card">` with the value in `<p>`/`<strong>` and NO href/chevron; toggle = `.choice + .switch`. A display-only row must never advertise a chevron.
6. **Persistent home storage indicator.** The device card always shows storage state (Aman / Hampir penuh + bar); the `.bn-storage` banner is the escalation for the full state, never the signal (F7 AC3).
7. **Warranty is server-owned.** One active record per unit (unique unit key), term = one year from hand-over, claims only for units registered to the signed-in customer, expired units are rejected with their end date shown, and claim tickets are managed by admins in the CMS (never auto-approved in-app) (F32/F33).

## 4. Language

Indonesian-dominant, English-ready. Strings carrying `data-i18n` keys map to `assets/moox.js → I18N`. Extend that dictionary per locale; default `LANG="id"`. EN values already stubbed for: `cta.create`, `cta.login`, `cta.continue`, `nav.devices`, `nav.explore`, `media.title`, `status.connected`.


## 5. Phase 1 route additions

| Design screen | Native route target | Primary components |
|---|---|---|
| `settings/account.html` | `/settings/account` | `MxTopAppBar`, `MxListRow`, `MxButton` |
| `settings/password-reset.html` | `/settings/password-reset` | `MxTopAppBar`, `MxField`, `MxButton`, `MxBanner` |
| `settings/faq.html` | `/settings/faq` | `MxTopAppBar`, `MxCard`, disclosure rows |
| `settings/terms.html` | `/settings/terms` | `MxTopAppBar`, `MxCard`, `MxButton` |
| `settings/feedback.html` | `/settings/feedback` | `MxTopAppBar`, `MxChipGroup`, `MxField`, `MxBottomSheet` |
| `settings/notifications.html` | `/settings/notifications` | `MxTopAppBar`, `MxListRow`, status controls |
| `settings/device.html` | `/settings/device` | `MxDeviceCard`, `MxListRow`, `MxButton` |
| `settings/recording.html` | `/settings/device/recording` | `MxTopAppBar`, `MxSegmented`, `MxButton` |
| `settings/firmware.html` | `/settings/device/firmware` | `MxTopAppBar`, `MxBanner`, `MxProgress`, `MxButton` |
| `device/type-select.html` | `/device/type` | `MxTopAppBar`, `MxCard`, `MxStatusBadge` |
| `device/active-devices.html` | `/device/active` | `MxTopAppBar`, `MxDeviceCard`, `MxListRow` |
| `device/call-overlay.html` | `/device/call` | `MxDialog`, `MxButton`, `MxGestureRow` |
| `media/detail.html` | `/media/detail` | `MxTopAppBar`, `MxMediaCard`, `MxBottomSheet` |
| `media/manage.html` | `/media/manage` | `MxMediaGrid`, `MxChipGroup`, `MxBottomSheet` |
| `translation/mode.html` | `/translation` | `MxTopAppBar`, `MxCard` |
| `translation/on-screen.html` | `/translation/on-screen` | `MxTopAppBar`, `MxMessage`, `MxButton` |
| `translation/simultaneous.html` | `/translation/simultaneous` | `MxTopAppBar`, `MxMessage`, `MxProgress` |
| `insight/detail.html` | `/insight/detail` | `MxTopAppBar`, `MxCard`, `MxButton` |
| `transfer/import-error.html` | `/import/error` | `MxTopAppBar`, `MxBanner`, `MxButton` |
| `transfer/import-retry.html` | `/import/retry` | `MxTopAppBar`, `MxListRow`, `MxButton` |
| `transfer/eis-processing.html` | `/import/eis` | `MxTopAppBar`, `MxProgress`, `MxBanner` |
| `transfer/eis-failed.html` | `/import/eis-failed` | `MxTopAppBar`, `MxBanner`, `MxButton` |

## 6. Phase 1 product state rules

- Unavailable Android/iOS capabilities are shown as unavailable, never as successful actions.
- Media export is gated behind successful import and preserves the original on transfer/EIS failure.
- Device type and active-device state are explicit before capability-specific controls appear.
- Translation and Insight are separate product surfaces with offline/loading/empty states.
- All new pages remain Indonesian-first and English-ready.