5.5 KiB
Phase 8: Engagement User Profile (NEW) - Discussion Log
Audit trail only. Do not use as input to planning, research, or execution agents. Decisions are captured in CONTEXT.md — this log preserves the alternatives considered.
Date: 2026-05-07 Phase: 08-engagement-user-profile-new Areas discussed: Identity header, Key metrics layout, Period default, Activity breakdown, Recent items
Identity header
Avatar source
| Option | Description | Selected |
|---|---|---|
| Initials only (Recommended) | Reuse Phase 7's getInitials(). Zero external calls, consistent with overview row. |
|
| Graph photo with initials fallback | Fetch user.photo from Microsoft Graph; nicer visually if photos exist. |
✓ |
| Graph photo only (no fallback) | Skip avatar entirely if no photo. |
User's choice: Graph photo with initials fallback
Notes: Per D-25/D-26 — new thin endpoint at /api/mobile/engagement/user/[userId]/photo calls Graph; client falls back to initials on <img> error.
Fields under name (multi-select)
| Option | Description | Selected |
|---|---|---|
| Job title | From graph_users.job_title — already on the row card |
✓ |
Tap-to-email on phone (mailto:) |
✓ | |
| Department | From graph_users.department if populated |
✓ |
| Last active timestamp | Most-recent activity (last time entry / last Teams message) | ✓ |
User's choice: All four selected Notes: Renders in stacked order: title → department → email → last active. Department/last-active rows hide if NULL.
Key metrics layout
Layout pattern
| Option | Description | Selected |
|---|---|---|
| 2×2 grid — 4 hero metrics (Recommended) | Mirrors Phase 3 dashboard KPI grid | ✓ |
| Stacked cards — 6 metrics | Mirrors Phase 7 overview summary cards | |
| Compact strip — 6 in horizontal scroll | Saves vertical, breaks Pulse pattern |
User's choice: 2×2 grid
Default period
| Option | Description | Selected |
|---|---|---|
| D30 — match overview default (Recommended) | Consistent with Phase 7 | ✓ |
| D90 — detail-view convention | Heavier data load | |
| D7 — most recent context | Spot-check oriented |
User's choice: D30
Top metrics for the 2×2 grid
| Option | Description | Selected |
|---|---|---|
| Hours worked + Billable hours + Days + Meetings | Time-focused set | ✓ |
| Hours + Billable + Meetings + After-hours% | Time + workload signal | |
| Hours + Meetings + Teams msgs + Emails | Activity-focused | |
| Hours + Billable + Days + Meetings + Teams msgs + Emails (6 stacked) | Full picture, stacked |
User's choice: Hours worked + Billable hours + Days worked + Meetings attended
Activity breakdown
Breakdown structure
| Option | Description | Selected |
|---|---|---|
| Categorized rows — Time / Communication / Meetings (Recommended) | Three labeled subsections, scannable, no charts | ✓ |
| Single mixed list — all metrics flat | Simpler, loses grouping | |
| Per-metric mini-sparklines | Visually rich but heavy | |
| Daily activity timeline | Combined chart, less per-metric detail |
User's choice: Categorized rows
After-hours% placement
| Option | Description | Selected |
|---|---|---|
| Inside Communication section as a row (Recommended) | Tucked but visible | ✓ |
| Standalone row above breakdown | Highlighted callout | |
| Drop — not on mobile v1 | Skip for v1 |
User's choice: Inside Communication section
Recent items
What gets shown
| Option | Description | Selected |
|---|---|---|
| Recent time entries only (Recommended) | Last ~10 from recentEntries |
|
| Recent meetings only | Last ~10 from recentTeamsMeetings |
|
| Mixed feed — interleaved by date | Single timeline | |
| Two separate sections — Time entries + Meetings | Both, kept separate | ✓ |
User's choice: Two separate sections
Scope
| Option | Description | Selected |
|---|---|---|
| Last 10 items (Recommended) | Bounded, fits one screen | ✓ |
| Last 20 items | Fuller history | |
| Last 7 days bounded by date | Time-bounded | |
| Match selected period (D7/D30/D90) | Grows with period |
User's choice: Last 10 items (each section)
Tap behavior
| Option | Description | Selected |
|---|---|---|
| Read-only display, no tap action (Recommended) | Match Phase 7's read-only-on-mobile principle | |
| Tap to open ticket / meeting detail | Adds nav surfaces | |
| Tap to expand inline — show notes, attendees, full details | Stays on profile, reveals more rows | ✓ |
User's choice: Tap to expand inline
Notes: Local component state (Set<string> of expanded IDs); no URL state.
Claude's Discretion
- Exact spacing/typography within Phase 7's established tokens
- Whether to use shadcn
Collapsibleor hand-rolled disclosure - Skeleton component composition
- Toast wording for 500 errors
- Memoization detail of expand-state
- "Last active" relative-vs-absolute threshold (started at ≤7d)
Deferred Ideas
- Peer comparison / radar chart (desktop-only flourish)
- Monthly history view (
/historyendpoint) dailyActivitychart- Tap-to-open ticket/meeting deep links (future enhancement to inline expand)
- D1 "today" period chip (Phase 7 deferral carries forward)
- Zoom client-meeting filter (mobile v1 shows totals)