@schandlergarcia/sf-web-components 1.9.63 → 1.9.64

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,73 @@
1
+ ---
2
+ name: engine-phase-4-agent
3
+ description: >-
4
+ Phase 4 of the Engine Travel Command Center build. Adds Eva ChatBar to the
5
+ header and Salesforce signals throughout the dashboard.
6
+ Use this when the build prompt says "Phase 4" or "agent".
7
+ ---
8
+
9
+ # Phase 4: Agentforce Integration
10
+
11
+ **Source of truth:** `engine-command-center-prd.md` (sections 9–10)
12
+
13
+ **Goal:** Add Eva as a ChatBar in the header. Add subtle Salesforce signals throughout the dashboard.
14
+
15
+ ## Eva — ChatBar in header
16
+
17
+ Eva surfaces as a `ChatBar` in the header. Not a FAB. Not a sliding panel. Not a `ChatPanel` in the grid.
18
+
19
+ ### Code
20
+
21
+ Define the handler and suggestions at **module scope** (outside the component):
22
+
23
+ ```tsx
24
+ import { ChatBar } from "@/components/library";
25
+
26
+ const CHAT_SUGGESTIONS = [
27
+ "Who's traveling internationally right now?",
28
+ "Show bookings pending approval",
29
+ "What has Eva resolved today?",
30
+ "Travelers returning this week",
31
+ ];
32
+
33
+ function handleChat(message: string) {
34
+ // Agentforce integration or mock response
35
+ return {
36
+ text: `Eva is looking into: "${message}"`,
37
+ components: [],
38
+ };
39
+ }
40
+ ```
41
+
42
+ Add the ChatBar to the header (right side, before the notification bell):
43
+
44
+ ```tsx
45
+ <ChatBar
46
+ title="Eva"
47
+ placeholder="Ask about travelers, bookings, policy, spend…"
48
+ suggestions={CHAT_SUGGESTIONS}
49
+ onSend={handleChat}
50
+ />
51
+ ```
52
+
53
+ ### Agent responses
54
+
55
+ Return structured `components` arrays for data (MetricCard, DataTable, StatusCard) — never markdown tables in text content.
56
+
57
+ ## Salesforce Signals
58
+
59
+ Subtle, contextual indicators — like "Sent from iPhone", not promotional banners.
60
+
61
+ | Signal | Location | Implementation |
62
+ |--------|----------|----------------|
63
+ | "View in Salesforce" | Traveler expanded view, booking rows | Micro-link, muted text (`text-slate-400`) |
64
+ | "Salesforce updated" | After rebook/approve actions | `toast()` with success tone |
65
+ | "Powered by Agentforce" | ChatBar subtitle area | Small badge/chip |
66
+
67
+ ## Constraints (5 only)
68
+
69
+ 1. ChatBar goes in the **header**, not as a floating panel or grid element
70
+ 2. `CHAT_SUGGESTIONS` and `handleChat` defined at **module scope** (outside component body)
71
+ 3. Salesforce signals are subtle micro-text — not banners or badges
72
+ 4. Import ONLY from `@/components/library` and `@heroicons/react`
73
+ 5. DO NOT run `npm run dev` or `npm run validate:dashboard`
@@ -254,7 +254,9 @@ Every dashboard needs a unique layout structure and at least one domain-specific
254
254
 
255
255
  ## Map Layout
256
256
 
257
- GeoMap should be placed in a **wide/narrow grid** (`lg:grid-cols-3` with `lg:col-span-2`), not full-width hero. Full-width maps dominate the page and waste space.
257
+ **Default pattern:** GeoMap in a **wide/narrow grid** (`lg:grid-cols-3` with `lg:col-span-2`). This works well for dashboards where the map is one of several equal-weight sections.
258
+
259
+ **If the PRD specifies a "visualization-hero" layout**, the map is full-width hero with glass overlays. The PRD always overrides this default pattern.
258
260
 
259
261
  **Pattern: Map + sidebar at matched height**
260
262
 
@@ -584,37 +586,11 @@ Before finishing a dashboard page, verify ALL of these:
584
586
  - [ ] **Imports only from `@/components/library`** — no shadcn, no Lucide, no `cn()`
585
587
  - [ ] **Grid patterns match the approved list** — no custom grid layouts
586
588
 
587
- ## Post-Completion Verification (REQUIRED — MUST RUN BEFORE REPORTING DONE)
588
-
589
- After building the dashboard, you MUST run the validator and fix ALL errors before reporting the dashboard as complete:
590
-
591
- ```bash
592
- # Run from the web app directory
593
- npm run validate:dashboard
594
- ```
595
-
596
- **Do NOT run `npm run build` or `tsc`.** The TypeScript build has known issues with platform-only Salesforce packages that are not relevant to dashboard development. Only run the validator.
597
-
598
- The validator (`scripts/validate-dashboard.sh`) automatically checks for:
599
- - Hand-rolled HTML cards, tables, and SVGs (must use library components)
600
- - Forbidden colors (`text-black`, `text-white`, `bg-black`)
601
- - Inline `style={{}}` and `<style>` tags
602
- - Missing `useDataSource` for sample/live mode
603
- - Grid layouts with 5+ columns
604
- - `position: fixed` without `createPortal`
605
- - shadcn/Lucide imports in command center code
606
- - Missing `space-y-6` wrappers
607
- - `.jsx` files where `.tsx` is required (this is a TypeScript project)
608
- - Dashboard navigation (`<nav>` elements)
609
-
610
- **If the validator reports errors, you MUST fix them ALL — zero errors required.** Do not report the dashboard as complete with any errors. Do not dismiss errors as "acceptable", "justified", or "expected". Every error has a fix — usually by switching to the correct library component. The validator exits with code 1 on errors — treat this like a failing test.
589
+ ## Post-Completion Verification
611
590
 
612
- **Common validator errors and their fixes:**
613
- - **Hand-rolled card** → Wrap content in `WidgetCard`, `ListCard`, `BaseCard`, or another library card component. `WidgetCard` with a single section can wrap any arbitrary JSX content.
614
- - **Forbidden colors** (`text-white`, `bg-black`) → Use slate scale (`text-slate-50`, `bg-slate-900`)
615
- - **shadcn/Lucide imports** → Replace with library components and Heroicons
591
+ **DO NOT run `npm run validate:dashboard`, `npm run dev`, `npm run build`, or `tsc` during builds.** These waste time and are not required for phase completion.
616
592
 
617
- **Do not skip or ignore the validator.** Do not run `npm run build` or `tsc` only run `npm run validate:dashboard`.
593
+ Instead, verify correctness by reviewing the code against the Pre-Completion Checklist above. Confirm that all three wiring files are updated (CommandCenter.tsx, Home.tsx, routes.tsx).
618
594
 
619
595
  ## Anti-Patterns (never do these)
620
596
 
@@ -19,37 +19,11 @@ Before finishing a dashboard page, verify ALL of these:
19
19
  - [ ] **Imports only from `@/components/library`** — no shadcn, no Lucide, no `cn()`
20
20
  - [ ] **Grid patterns match the approved list** — no custom grid layouts
21
21
 
22
- ## Post-Completion Verification (REQUIRED — MUST RUN BEFORE REPORTING DONE)
22
+ ## Post-Completion Verification
23
23
 
24
- After building the dashboard, you MUST run the validator and fix ALL errors before reporting the dashboard as complete:
24
+ **DO NOT run `npm run validate:dashboard`, `npm run dev`, `npm run build`, or `tsc` during builds.** These waste time and are not required for phase completion.
25
25
 
26
- ```bash
27
- # Run from the web app directory
28
- npm run validate:dashboard
29
- ```
30
-
31
- **Do NOT run `npm run build` or `tsc`.** The TypeScript build has known issues with platform-only Salesforce packages that are not relevant to dashboard development. Only run the validator.
32
-
33
- The validator (`scripts/validate-dashboard.sh`) automatically checks for:
34
- - Hand-rolled HTML cards, tables, and SVGs (must use library components)
35
- - Forbidden colors (`text-black`, `text-white`, `bg-black`)
36
- - Inline `style={{}}` and `<style>` tags
37
- - Missing `useDataSource` for sample/live mode
38
- - Grid layouts with 5+ columns
39
- - `position: fixed` without `createPortal`
40
- - shadcn/Lucide imports in command center code
41
- - Missing `space-y-6` wrappers
42
- - `.jsx` files where `.tsx` is required (this is a TypeScript project)
43
- - Dashboard navigation (`<nav>` elements)
44
-
45
- **If the validator reports errors, you MUST fix them ALL — zero errors required.** Do not report the dashboard as complete with any errors. Do not dismiss errors as "acceptable", "justified", or "expected". Every error has a fix — usually by switching to the correct library component. The validator exits with code 1 on errors — treat this like a failing test.
46
-
47
- **Common validator errors and their fixes:**
48
- - **Hand-rolled card** → Wrap content in `WidgetCard`, `ListCard`, `BaseCard`, or another library card component. `WidgetCard` with a single section can wrap any arbitrary JSX content.
49
- - **Forbidden colors** (`text-white`, `bg-black`) → Use slate scale (`text-slate-50`, `bg-slate-900`)
50
- - **shadcn/Lucide imports** → Replace with library components and Heroicons
51
-
52
- **Do not skip or ignore the validator.** Do not run `npm run build` or `tsc` — only run `npm run validate:dashboard`.
26
+ Instead, verify correctness by reviewing the code against the Pre-Completion Checklist above. Confirm that all three wiring files are updated (CommandCenter.tsx, Home.tsx, routes.tsx).
53
27
 
54
28
  ## Anti-Patterns (never do these)
55
29
 
@@ -1,341 +1,30 @@
1
- # Improved Dashboard Build Process
1
+ # Dashboard Build Process
2
2
 
3
- ## 4-Phase Build Approach
3
+ ## 4-Phase Build
4
4
 
5
- Build dashboards in 4 distinct phases with clear separation of concerns:
5
+ Build dashboards in 4 distinct phases. Each phase has a dedicated instruction file with a code template in `.a4drules/phases/`:
6
6
 
7
- ### Phase 1: Layout & Structure
8
- **Goal:** Establish layout, spacing, and component placement
9
- **Output:** Skeleton with placeholders, no real data or logic
7
+ | Phase | File | Goal | Output |
8
+ |-------|------|------|--------|
9
+ | 1 | `phase-1-layout.md` | Layout & structure | Skeleton with placeholders |
10
+ | 2 | `phase-2-components.md` | Components & sample data | Fully functional UI with mock data |
11
+ | 3 | `phase-3-live-data.md` | Real data integration | Dashboard connected to Salesforce |
12
+ | 4 | `phase-4-agent.md` | Agentforce integration | Eva agent + Salesforce signals |
10
13
 
11
- ### Phase 2: Components & Sample Data
12
- **Goal:** Build all UI components with realistic mock data
13
- **Output:** Fully functional UI using hardcoded sample data
14
-
15
- ### Phase 3: Real Data Integration
16
- **Goal:** Replace sample data with live Salesforce data
17
- **Output:** Dashboard connected to real data sources
18
-
19
- ### Phase 4: Agentforce Integration
20
- **Goal:** Add AI agent capabilities
21
- **Output:** Eva agent integrated with chat interface
22
-
23
- ---
24
-
25
- ## Example: Engine Travel Command Center
26
-
27
- ### Prompt 1 — Layout & Structure
28
-
29
- > Load skills: command-center-builder, command-center-project, component-library, outer-app.
30
- > Use `docs/engine-command-center-prd.md` as source of truth.
31
- >
32
- > **Phase 1: Layout Only**
33
- >
34
- > Scaffold the Engine Travel Command Center structure:
35
- >
36
- > 1. **Header Layout** - Compact dark header with:
37
- > - Engine logo placeholder (gray box)
38
- > - Wordmark placeholder
39
- > - Theme toggle (functional)
40
- > - Empty space for ChatBar (Phase 4)
41
- >
42
- > 2. **Hero Section** - Full-width map container:
43
- > - Empty GeoMap component (no markers, no data)
44
- > - Placeholder for KPI overlays (gray boxes with labels)
45
- > - Placeholder for flight status strip (gray bar)
46
- >
47
- > 3. **Data Panels Grid** - Layout sections with empty cards:
48
- > - Disruptions panel (left, wide)
49
- > - Active travelers panel (right, narrow)
50
- > - Activity feed + chart row
51
- > - Bookings table section
52
- > - Policy + spend chart row
53
- >
54
- > 4. **Theme Setup** - Update brand palette to Engine teal tokens (section 3 PRD)
55
- >
56
- > 5. **File Structure**:
57
- > - Create `src/pages/EngineDashboard.tsx`
58
- > - Wire into `CommandCenter.tsx`
59
- > - Use placeholder cards: `<BaseCard><div className="h-48 bg-slate-100">Section Name</div></BaseCard>`
60
- >
61
- > **DO NOT:**
62
- > - Add any real data or sample data
63
- > - Build actual components beyond placeholders
64
- > - Add data fetching logic
65
- > - Add interactive features beyond theme toggle
66
- >
67
- > **Deliverable:** A skeleton dashboard with proper layout, spacing, and placeholder cards that shows the structure.
68
-
69
- ---
70
-
71
- ### Prompt 2 — Components & Sample Data
72
-
73
- > Load skills: command-center-builder, command-center-project, component-library.
74
- > Refer to `docs/engine-command-center-prd.md` sections 7, 8, and 12.
75
- >
76
- > **Phase 2: Build All Components with Sample Data**
77
- >
78
- > Replace all placeholders with fully functional components using hardcoded sample data:
79
- >
80
- > 1. **Create Sample Data File** - `src/data/engine-sample-data.ts`:
81
- > - Travelers (10 active travelers with names, flights, hotels)
82
- > - Flights (8 active flights with routes, status, progress %)
83
- > - Disruptions (3 weather events, 2 delays, 1 cancellation)
84
- > - Bookings (20 bookings with all fields)
85
- > - Policy items (5 compliance items with status)
86
- > - Eva actions (15 recent actions)
87
- > - Spend history (12 months of data)
88
- > - Destination stats (top 10 cities)
89
- >
90
- > 2. **Populate Map** - Wire sample data into GeoMap:
91
- > - Show markers at origin/destination cities
92
- > - Draw flight arcs with animated progress dots
93
- > - Add weather overlays for disrupted areas
94
- > - Add 4 glass KPI overlays (flights, travelers, disruptions, bookings count)
95
- > - Add flight status strip with colored status chips
96
- >
97
- > 3. **Build Disruptions Panel**:
98
- > - Use ListCard with disruption items
99
- > - Show severity indicators (red/yellow/blue)
100
- > - Show affected travelers
101
- > - Show Eva's actions
102
- >
103
- > 4. **Build Active Travelers Panel**:
104
- > - Use ListCard with expandable traveler cards
105
- > - Click to expand and show flight, hotel, return date
106
- > - Use Avatar for traveler photos
107
- > - Show status chips
108
- >
109
- > 5. **Build Activity Feed + Chart**:
110
- > - Use FeedPanel for Eva activities
111
- > - Use ChartCard with bar chart of travelers by destination
112
- >
113
- > 6. **Build Bookings Table**:
114
- > - Use TableCard with search, sort, pagination
115
- > - Show all booking fields from section 12
116
- > - Add status chips
117
- >
118
- > 7. **Build Policy + Spend Charts**:
119
- > - Use StatusCard for policy compliance
120
- > - Use ChartCard with line chart of monthly spend
121
- >
122
- > 8. **Add Interactivity**:
123
- > - Click travelers to expand/collapse
124
- > - Search/filter bookings table
125
- > - Sort table columns
126
- > - Hover map markers for tooltips
127
- >
128
- > **DO NOT:**
129
- > - Connect to Salesforce data (use hardcoded data only)
130
- > - Add data fetching hooks
131
- > - Add GraphQL queries
132
- > - Add Agentforce/Eva chat
133
- >
134
- > **Deliverable:** A fully functional dashboard with all components working using sample data. Everything should look and feel complete, just not connected to live data yet.
135
-
136
- ---
137
-
138
- ### Prompt 3 — Real Data Integration
139
-
140
- > Load skills: command-center-builder, command-center-project, component-library, using-salesforce-data.
141
- > Refer to `docs/engine-command-center-prd.md` sections 11 and 13.
142
- >
143
- > **Phase 3: Connect to Salesforce Data**
144
- >
145
- > Replace sample data with live Salesforce data:
146
- >
147
- > 1. **Create Data Hooks** - `src/hooks/`:
148
- > - `useFlights.ts` - Fetch active flights from Flight__c
149
- > - `useTravelers.ts` - Fetch travelers from Contact with flight relationships
150
- > - `useDisruptions.ts` - Fetch disruption cases from Case
151
- > - `useBookings.ts` - Fetch bookings from Booking__c
152
- > - `usePolicyItems.ts` - Fetch policy compliance from Policy__c
153
- > - `useEvaActions.ts` - Fetch Eva activity from Eva_Action__c
154
- > - `useSpendData.ts` - Fetch spend trends from aggregate query
155
- >
156
- > 2. **GraphQL Queries** - For each hook, write GraphQL:
157
- > - Use @optional on all fields (FLS resilience)
158
- > - Include all relationships needed
159
- > - Add proper filters (Active__c = true, etc.)
160
- > - Use proper Salesforce field names from section 13
161
- >
162
- > 3. **Replace Sample Data** - In EngineDashboard.tsx:
163
- > - Replace hardcoded arrays with hook calls
164
- > - Add loading states with CardSkeleton
165
- > - Add error states with EmptyState
166
- > - Add refresh functionality
167
- >
168
- > 4. **Data Transformations** - Create `src/utils/engine-data-transforms.ts`:
169
- > - Transform Salesforce records to map data format
170
- > - Calculate KPI values from live data
171
- > - Aggregate data for charts
172
- > - Format dates, currencies, percentages
173
- >
174
- > 5. **Real-time Updates** - Add DataModeToggle:
175
- > - Toggle between "sample" (Phase 2 data) and "live" (Salesforce data)
176
- > - Store preference in localStorage
177
- > - Show "Last synced" timestamp for live mode
178
- >
179
- > 6. **Error Handling**:
180
- > - Network errors → Show retry button
181
- > - No data → Show EmptyState with action
182
- > - Partial data → Show what's available with warning
183
- >
184
- > **DO NOT:**
185
- > - Add Agentforce/Eva chat yet
186
- > - Add complex AI features
187
- > - Modify component UI (should look same as Phase 2)
188
- >
189
- > **Deliverable:** Dashboard connected to live Salesforce data with loading states, error handling, and ability to toggle between sample/live data for testing.
190
-
191
- ---
192
-
193
- ### Prompt 4 — Agentforce Integration
194
-
195
- > Load skills: command-center-builder, command-center-project, component-library, managing-agentforce-conversation-client.
196
- > Refer to `docs/engine-command-center-prd.md` sections 9 and 10.
197
- >
198
- > **Phase 4: Add Eva Agent**
199
- >
200
- > Integrate Agentforce Eva agent:
201
- >
202
- > 1. **Add ChatBar to Header**:
203
- > - Import ChatBar from @/components/library
204
- > - Position in header (right side, before theme toggle)
205
- > - Add keyboard shortcut (Cmd+K / Ctrl+K)
206
- > - Add starter suggestions:
207
- > - "Which travelers are affected by disruptions?"
208
- > - "Show me all delayed flights"
209
- > - "What's Eva doing right now?"
210
- > - "Summarize today's travel status"
211
- >
212
- > 2. **Configure Eva Agent**:
213
- > - Use Agentforce Eva agent ID from PRD section 9
214
- > - Configure context: current user, visible data, dashboard state
215
- > - Add tool calls for dashboard actions:
216
- > - View traveler details
217
- > - Filter bookings
218
- > - Export data
219
- > - Refresh data
220
- >
221
- > 3. **Add Salesforce Signals**:
222
- > - Header: "Powered by Salesforce Data Cloud" badge
223
- > - Traveler cards: "View in Salesforce" links → open Contact record
224
- > - Booking rows: "View in Salesforce" links → open Booking__c record
225
- > - Success toasts on actions: "Updated by Eva" with undo option
226
- > - Live sync indicator with timestamp
227
- >
228
- > 4. **Eva Integration Points**:
229
- > - ChatBar can filter visible data
230
- > - ChatBar can expand specific travelers
231
- > - ChatBar can open specific bookings
232
- > - ChatBar can trigger refreshes
233
- > - ChatBar shows contextual suggestions based on current view
234
- >
235
- > 5. **Testing Mode**:
236
- > - If no Eva agent configured, show mock responses
237
- > - Add "Configure Eva" EmptyState in ChatBar
238
- > - Link to Agentforce setup docs
239
- >
240
- > **Deliverable:** Fully functional dashboard with Eva agent integrated, able to answer questions about travel data and perform dashboard actions.
241
-
242
- ---
14
+ Each phase file is self-contained it includes the code template, exact imports, and the 5 constraints that matter for that phase. No cross-references needed.
243
15
 
244
16
  ## Why This Works
245
17
 
246
- ### Clear Phases
247
- Each phase has a single focus:
248
- 1. Structure Can review layout before building components
249
- 2. Components Can test UX/interactions before data complexity
250
- 3. Data → Can focus on data fetching/transformation without UI changes
251
- 4. Agent → Can add AI on top of working dashboard
252
-
253
- ### Easy Testing
254
- - Phase 1: Review layout, spacing, branding
255
- - Phase 2: Test all interactions, edge cases with known data
256
- - Phase 3: Test loading states, errors, real data shapes
257
- - Phase 4: Test agent responses, tool calls
258
-
259
- ### Easy Debugging
260
- - UI issues? → Phase 2
261
- - Data issues? → Phase 3
262
- - Agent issues? → Phase 4
263
-
264
- ### Easy Iterations
265
- - Don't like layout? → Go back to Phase 1
266
- - Component not working? → Fix in Phase 2 with sample data
267
- - Data mapping wrong? → Fix Phase 3 transforms
268
- - Agent not helpful? → Improve Phase 4 prompts
269
-
270
- ### Can Stop Early
271
- - Need just the UI mockup? → Stop after Phase 2
272
- - Don't have Salesforce yet? → Stop after Phase 2
273
- - Don't need AI? → Stop after Phase 3
274
-
275
- ---
276
-
277
- ## Phase Checklist Template
278
-
279
- ### Phase 1: Layout ✓
280
- - [ ] Header structure
281
- - [ ] Hero section containers
282
- - [ ] Data panel grid
283
- - [ ] Placeholder cards in place
284
- - [ ] Theme/branding applied
285
- - [ ] Proper spacing and responsive layout
286
-
287
- ### Phase 2: Components ✓
288
- - [ ] Sample data file created
289
- - [ ] All components built
290
- - [ ] All interactions working
291
- - [ ] All visualizations working
292
- - [ ] Charts rendering with sample data
293
- - [ ] Table search/sort/pagination working
294
- - [ ] Dashboard looks and feels complete
295
-
296
- ### Phase 3: Data ✓
297
- - [ ] All data hooks created
298
- - [ ] All GraphQL queries working
299
- - [ ] Loading states added
300
- - [ ] Error states handled
301
- - [ ] Data transformations working
302
- - [ ] Live/sample toggle working
303
- - [ ] Real data rendering correctly
304
-
305
- ### Phase 4: Agent ✓
306
- - [ ] ChatBar in header
307
- - [ ] Eva agent configured
308
- - [ ] Starter suggestions working
309
- - [ ] Agent can answer questions
310
- - [ ] Tool calls working
311
- - [ ] Salesforce signals added
312
- - [ ] Links to Salesforce records working
313
-
314
- ---
315
-
316
- ## Benefits Over Original Approach
317
-
318
- ### Original Approach Issues:
319
- - Mixed layout + components + data in early prompts
320
- - Hard to debug what phase an issue is from
321
- - No clear stopping point
322
- - Can't test UI without data
323
- - Can't review structure before building
324
-
325
- ### New Approach Benefits:
326
- - Clear separation of concerns
327
- - Each phase builds on previous
328
- - Easy to identify issue source
329
- - Can demo/test after each phase
330
- - Can iterate on each phase independently
331
- - Stakeholders can provide feedback earlier
18
+ - Each phase has a single focus
19
+ - Code templates mean less interpretation, faster builds
20
+ - Self-contained files eliminate contradictions
21
+ - Can stop after any phase (Phase 2 is a complete demo on its own)
332
22
 
333
- ---
23
+ ## Build Prompts
334
24
 
335
- ## Notes
25
+ Each phase is triggered by a simple prompt:
336
26
 
337
- - **Always use sample data mode in Phase 2** - DataModeProvider should default to "sample"
338
- - **Keep Phase 2 data file** - Useful for testing and demos
339
- - **Test Phase 3 with sample toggle** - Easy to compare live vs sample
340
- - **Phase 4 is optional** - Many dashboards don't need AI
341
- - **Can split Phase 2** - If many components, do 2a (map/KPIs) and 2b (panels/tables)
27
+ - Phase 1: "Scaffold the Engine Travel Command Center skeleton"
28
+ - Phase 2: "Replace placeholders with library components and sample data"
29
+ - Phase 3: "Connect the dashboard to live Salesforce data"
30
+ - Phase 4: "Add Eva ChatBar and Salesforce signals"
@@ -108,9 +108,11 @@ Every dashboard needs a unique layout structure and at least one domain-specific
108
108
 
109
109
  ## Map Layout
110
110
 
111
- GeoMap should be placed in a **wide/narrow grid** (`lg:grid-cols-3` with `lg:col-span-2`), not full-width hero. Full-width maps dominate the page and waste space.
111
+ **Default pattern:** GeoMap in a **wide/narrow grid** (`lg:grid-cols-3` with `lg:col-span-2`). This works well for dashboards where the map is one of several equal-weight sections.
112
112
 
113
- **Pattern: Map + sidebar at matched height**
113
+ **If the PRD specifies a "visualization-hero" layout**, the map is full-width hero with glass overlays. The PRD always overrides this default pattern.
114
+
115
+ **Default pattern: Map + sidebar at matched height**
114
116
 
115
117
  ```jsx
116
118
  <div className="grid grid-cols-1 gap-4 lg:grid-cols-3">