Skip to content

Commit ae485db

Browse files
committed
ui updates
1 parent 7ed921f commit ae485db

11 files changed

Lines changed: 2178 additions & 1178 deletions
Lines changed: 282 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,282 @@
1+
# Content Generation UI Improvement Plan
2+
3+
## Overview
4+
This plan aligns the main content generation flow UI with the Figma design, incorporating Coral UI patterns from `coralUIComponents`.
5+
6+
---
7+
8+
## 1. Task Header Banner
9+
**Location**: Top of chat panel
10+
**Current State**: No task header
11+
**Target State**: Purple/blue gradient banner showing current task
12+
13+
### Changes Required:
14+
- [ ] Add a `TaskHeader` component that displays above messages
15+
- [ ] Style: Purple/blue gradient background (#5c3d91 to #6366f1)
16+
- [ ] Show task description: "Generate an ad copy and image ideas for a Facebook campaign promoting 'Paint for Home Decor'"
17+
- [ ] Conditionally display based on conversation state
18+
19+
### Files to Modify:
20+
- `ChatPanel.tsx` - Add TaskHeader component integration
21+
22+
---
23+
24+
## 2. Message Bubbles Styling
25+
**Location**: `ChatPanel.tsx` - `MessageBubble` component
26+
**Current State**: Basic card styling with Fluent UI
27+
**Target State**: Coral-style message bubbles matching Figma
28+
29+
### Changes Required:
30+
- [ ] **User Messages**:
31+
- Background: `var(--colorNeutralBackground2)` (light gray, similar to Coral)
32+
- Align: Right-aligned, rounded corners (6px)
33+
- Max-width: 80%
34+
- Remove avatar for user messages (match Figma simplicity)
35+
36+
- [ ] **Assistant Messages**:
37+
- Background: White/transparent
38+
- Full width, no avatar circle (match Coral pattern)
39+
- Clean markdown rendering with proper list styling
40+
- Footer: "AI generated content may be incorrect" text + thumbs up/down icons
41+
42+
- [ ] **Markdown Rendering Improvements**:
43+
- Import Coral's markdown styles (bullet points, code blocks)
44+
- Add proper spacing between paragraphs
45+
- Style inline code and code blocks
46+
47+
### Files to Modify:
48+
- `ChatPanel.tsx` - Refactor MessageBubble component
49+
- `global.css` - Add Coral markdown styles
50+
51+
---
52+
53+
## 3. Brief Review Card (BriefReview.tsx)
54+
**Current State**: Card with bot avatar and sections
55+
**Target State**: Cleaner card matching Figma's brief format
56+
57+
### Changes Required:
58+
- [ ] Remove bot avatar (inline with messages)
59+
- [ ] Update card layout to show:
60+
- Campaign Objective
61+
- Audience
62+
- Create instructions ("Create a square image of a living space...")
63+
- Tone & Style
64+
- Deliverables
65+
- [ ] Section styling:
66+
- Bold section labels (e.g., "Tone & Style:")
67+
- Clean gray background sections
68+
- Modern, warm tone indicators
69+
- [ ] Button styling:
70+
- "Start over" - outline style button
71+
- "Confirm brief" - filled primary button
72+
73+
### Files to Modify:
74+
- `BriefReview.tsx` - Restructure layout and styling
75+
76+
---
77+
78+
## 4. Product Selection Cards
79+
**Location**: New component or update `ProductReview.tsx`
80+
**Current State**: Basic product list with images
81+
**Target State**: Two display modes - List and Grid (like Figma)
82+
83+
### Changes Required:
84+
- [ ] **List View (Style 1)**:
85+
- Product color circle on left (shows actual paint color)
86+
- Product name (bold), description, price vertically stacked
87+
- "Select" button on right (outlined, blue on hover/selected)
88+
- Hover state: subtle background highlight
89+
- Click to select/deselect
90+
91+
- [ ] **Grid View (Style 2)**:
92+
- 2x2 grid layout
93+
- Color circle, name, description, price in each cell
94+
- Card-like appearance with subtle borders
95+
96+
- [ ] **View Toggle Links**:
97+
- "list style 1" / "list style 2" links to switch between views
98+
- Style as blue links with parentheses styling
99+
100+
- [ ] **Selection State**:
101+
- Visual indicator when product is selected
102+
- Support for multi-select or single-select based on context
103+
104+
### Files to Modify:
105+
- `ProductReview.tsx` - Major refactor for dual display modes
106+
- Create `ProductCard.tsx` - Reusable product card component
107+
- Create `ProductGrid.tsx` - Grid layout component
108+
109+
---
110+
111+
## 5. Generated Content Preview (InlineContentPreview.tsx)
112+
**Current State**: Grid layout with images and copy
113+
**Target State**: Figma-style content display with text overlay images
114+
115+
### Changes Required:
116+
- [ ] **Header Section**:
117+
- Sparkle emoji with headline: "✨ Discover the serene elegance of Snow Veil (EEEFEA) ✨"
118+
119+
- [ ] **Body Copy Section**:
120+
- Clean paragraph formatting
121+
- Proper line height and spacing
122+
- Hashtags in brand blue color at bottom
123+
124+
- [ ] **Image Preview**:
125+
- Single large image OR side-by-side images
126+
- Product name overlay on image (top-left, white text with shadow)
127+
- Subtitle text below product name
128+
- Clean rounded corners (8px)
129+
130+
- [ ] **Action Chips/Buttons**:
131+
- "Create an other image with same paint color, but a modern kitchen area, with no text on it"
132+
- Styled as clickable blue pill/chip
133+
134+
- [ ] **Footer Actions**:
135+
- Thumbs up/down feedback
136+
- "AI generated content may be incorrect" disclaimer
137+
138+
### Files to Modify:
139+
- `InlineContentPreview.tsx` - Refactor content layout
140+
- Add request chip/quick action component
141+
142+
---
143+
144+
## 6. Input Box Styling
145+
**Location**: Bottom of `ChatPanel.tsx`
146+
**Current State**: Simple input with + and send icons
147+
**Target State**: Coral-style input wrapper with focus animation
148+
149+
### Changes Required:
150+
- [ ] **Container**:
151+
- White background with subtle border
152+
- Rounded corners (4px like current, or 8px for more modern)
153+
- Focus state: animated underline indicator (purple/blue)
154+
155+
- [ ] **Input Field**:
156+
- Auto-expanding textarea (from Coral Chat.tsx pattern)
157+
- "Type a message" placeholder
158+
- Transparent background
159+
160+
- [ ] **Action Buttons**:
161+
- Attach/Plus icon on bottom-left area
162+
- Send icon on bottom-right
163+
- Vertical divider between attachment and send
164+
- AI-Generated tag/tooltip
165+
166+
- [ ] **Disclaimer**:
167+
- "AI generated content may be incorrect. Check for mistakes."
168+
- Positioned below input OR as tooltip on AI-Generated tag
169+
170+
### Files to Modify:
171+
- `ChatPanel.tsx` - Update input area styling
172+
- `global.css` - Add focus indicator animation
173+
174+
---
175+
176+
## 7. Chat History Panel (ChatHistory.tsx)
177+
**Current State**: Simplified list with "See all" link
178+
**Target State**: Coral-style history panel
179+
180+
### Changes Required:
181+
- [ ] Ensure consistent styling with Coral's ChatHistory component
182+
- [ ] Loading states with spinner
183+
- [ ] Selection state styling
184+
- [ ] Date formatting (Today, Yesterday, X days ago)
185+
186+
### Files to Modify:
187+
- `ChatHistory.tsx` - Minor alignment tweaks
188+
- `ChatHistory.css` (if needed)
189+
190+
---
191+
192+
## 8. Loading/Typing States
193+
**Current State**: Basic spinner with text
194+
**Target State**: Coral-style "Thinking..." indicator
195+
196+
### Changes Required:
197+
- [ ] Update loading indicator to match Coral's typing-indicator style
198+
- [ ] Animated dots or subtle pulse animation
199+
- [ ] "Thinking..." text styling
200+
201+
### Files to Modify:
202+
- `ChatPanel.tsx` - Update loading state UI
203+
204+
---
205+
206+
## 9. Global Styles & CSS Variables
207+
**Location**: `global.css`
208+
**Current State**: Basic Fluent UI integration
209+
**Target State**: Full Coral CSS patterns
210+
211+
### Changes Required:
212+
- [ ] Import/merge Coral's CSS patterns:
213+
- Input wrapper styles with focus indicator
214+
- Message styling (.user, .assistant classes)
215+
- Custom scrollbar styling
216+
- Markdown content styling
217+
- Animation keyframes
218+
219+
### Files to Modify:
220+
- `global.css` - Merge Coral patterns
221+
222+
---
223+
224+
## 10. Component Structure Improvements
225+
226+
### New Components to Create:
227+
1. `TaskHeader.tsx` - Task description banner
228+
2. `ProductCard.tsx` - Reusable product display card
229+
3. `ActionChip.tsx` - Clickable action pill/chip for quick requests
230+
4. `ViewToggle.tsx` - List/Grid view toggle links
231+
232+
### Components to Refactor:
233+
1. `MessageBubble` (in ChatPanel.tsx) - Coral-style messages
234+
2. `BriefReview.tsx` - Cleaner brief display
235+
3. `ProductReview.tsx` - Dual view mode support
236+
4. `InlineContentPreview.tsx` - Better content layout
237+
238+
---
239+
240+
## Implementation Priority
241+
242+
### Phase 1: Core Chat Experience (High Priority)
243+
1. Message bubble styling (user/assistant)
244+
2. Input box with Coral patterns
245+
3. Loading states
246+
247+
### Phase 2: Content Generation Flow (High Priority)
248+
4. Brief review card improvements
249+
5. Product selection cards (list + grid views)
250+
6. Generated content preview
251+
252+
### Phase 3: Polish & Enhancement (Medium Priority)
253+
7. Task header banner
254+
8. Action chips for quick requests
255+
9. Chat history alignment
256+
10. Global CSS cleanup
257+
258+
---
259+
260+
## Dependencies
261+
262+
### From Coral UI (`coralUIComponents/src/frontend/App/`):
263+
- `modules/Chat.css` - Input wrapper, message styles
264+
- `index.css` - Global styles, scrollbar
265+
- `modules/Chat.tsx` - Input pattern reference
266+
- `components/ChatHistory/ChatHistory.css` - History styling
267+
268+
### Fluent UI Components Used:
269+
- Button, Card, Text, Badge, Tooltip, Divider, Spinner
270+
- Icons: Send, Add, ThumbLike, ThumbDislike, Bot, Person
271+
272+
---
273+
274+
## Success Criteria
275+
1. ✅ Message bubbles match Figma styling (user right, assistant left/full-width)
276+
2. ✅ Input box has Coral-style focus animation
277+
3. ✅ Brief review card shows all sections cleanly
278+
4. ✅ Product selection has both list and grid view options
279+
5. ✅ Generated content shows images with text overlays
280+
6. ✅ Action chips allow quick follow-up requests
281+
7. ✅ Consistent spacing, fonts, and colors throughout
282+
8. ✅ Responsive design maintained for all screen sizes

0 commit comments

Comments
 (0)