# Portfolio Advisor / TrueWealth-Ersatz in JARVIS Command Dashboard

Use when extending the sensitive Finance area toward a TrueWealth-style portfolio advisor while keeping the global Command Center safe.

## Pattern proven in session

1. Keep the Command Center finance page as a **read-only, amount-free cockpit** unless an explicit protected-detail/session concept exists.
2. Replace generic module shell content with a Finance-specific cockpit only if it still avoids exact amounts, account identifiers, transaction rows, files, Drive links, and executable order actions.
3. Model the first Phase-8 UI as safe structure and workflow, not live execution:
   - Hero: `TrueWealth-Ersatz / Finanzdashboard` + clear read-only safety mode.
   - Asset allocation donut using percentages only.
   - Ist-vs-Ziel rows for high-level classes: Aktien, Cash, Immobilien, Rohstoffe, Crypto, Obligationen.
   - Drift labels and diversification scorecards.
   - Tabs prepared for `Allokation`, `Positionen`, `Risiko & Rendite`, `Strategie`.
   - Masked position model (`ISIN/Ticker: maskiert`) until protected local data is explicitly wired.
   - Preview → Confirm → Audit workflow visible, but no action buttons for buy/sell/order execution.
4. Keep specialist dashboard handoff as a safe external link only (`target=_blank`, `rel=noopener`), with text such as `Fachdashboard öffnen · FinanceManager Workspace` and `Aktionen gesperrt`.
5. If the dashboard store only loads fallback fixtures in test/demo mode, run local UI browser smokes with `VITE_JARVIS_DEMO_MODE=1 npm run dev ...` so the page renders without needing a live gateway.

## Test/verification expectations

Add focused frontend tests for the finance page that prove:

- the Phase-8 cockpit renders;
- all expected high-level allocation rows exist;
- no exact amounts/account identifiers/files/secrets/order-execution copy appear;
- no iframe is used;
- external Finance link is link-only and noopener-protected;
- not-configured handoff shows a disabled state;
- tabs switch to positions/risk/strategy sections.

Then run:

```bash
npm run test -- src/views/__tests__/financePortfolioAdvisor.test.ts
npm run test
npm run build
```

For browser smoke:

```bash
VITE_JARVIS_DEMO_MODE=1 npm run dev -- --host 127.0.0.1 --port 5174
# open /finance, check no console errors and visually inspect hero, donut/allocation rows, tabs, Preview/Confirm/Audit
```

## Pitfalls

- Existing tests may assert operator-handoff wording from earlier generic detail pages. Preserve durable phrases such as `Aktuelle JARVIS-Zusammenfassung`, `Fachdashboard öffnen`, `FinanceManager Workspace`, and `Aktionen gesperrt` unless intentionally updating those tests.
- Do not commit/push if the repo already has broad unrelated uncommitted changes; report only the touched files and verification evidence.
- Do not encode sample percentages as real financial facts. They are layout/demo percentages until the protected local data pipeline is implemented.
