chore(a2ui): generated output should show left#2657
Conversation
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughThe AI Chat Page now displays generated JSON using a read-only, dark-themed CodeMirror editor with JSON language support. Preview messages are stored in React state and exposed to PreviewPanel via a derived previewSource; the previous inline afterBody JSON/QR markup was removed. New CSS styles the JSON viewer container and editor visuals. ChangesGenerated JSON CodeMirror Display
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Merging this PR will not alter performance
|
| Benchmark | BASE |
HEAD |
Efficiency | |
|---|---|---|---|---|
| ⚡ | 004-various-update__main-thread-setAttribute__MT_Ref |
139.3 µs | 129.9 µs | +7.29% |
| ❌ | 002-hello-reactLynx-destroyBackground |
865.2 µs | 917.2 µs | -5.68% |
Tip
Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.
Comparing Sherry-hue:fix/create-json-show (89da870) with main (2061597)
Footnotes
-
26 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩
Web Explorer#9995 Bundle Size — 901.94KiB (0%).89da870(current) vs dae1d41 main#9993(baseline) Bundle metrics
Bundle size by type
|
| Current #9995 |
Baseline #9993 |
|
|---|---|---|
497.56KiB |
497.56KiB |
|
402.16KiB |
402.16KiB |
|
2.22KiB |
2.22KiB |
Bundle analysis report Branch Sherry-hue:fix/create-json-show Project dashboard
Generated by RelativeCI Documentation Report issue
React MTF Example#1554 Bundle Size — 208.12KiB (0%).89da870(current) vs dae1d41 main#1552(baseline) Bundle metrics
|
| Current #1554 |
Baseline #1552 |
|
|---|---|---|
0B |
0B |
|
0B |
0B |
|
0% |
0% |
|
0 |
0 |
|
3 |
3 |
|
193 |
193 |
|
77 |
77 |
|
44.24% |
44.24% |
|
2 |
2 |
|
0 |
0 |
Bundle size by type no changes
| Current #1554 |
Baseline #1552 |
|
|---|---|---|
111.23KiB |
111.23KiB |
|
96.89KiB |
96.89KiB |
Bundle analysis report Branch Sherry-hue:fix/create-json-show Project dashboard
Generated by RelativeCI Documentation Report issue
React Example with Element Template#690 Bundle Size — 200.08KiB (0%).89da870(current) vs dae1d41 main#688(baseline) Bundle metrics
Bundle size by type
|
| Current #690 |
Baseline #688 |
|
|---|---|---|
145.76KiB |
145.76KiB |
|
54.32KiB |
54.32KiB |
Bundle analysis report Branch Sherry-hue:fix/create-json-show Project dashboard
Generated by RelativeCI Documentation Report issue
React Example#8421 Bundle Size — 237.17KiB (0%).89da870(current) vs dae1d41 main#8419(baseline) Bundle metrics
|
| Current #8421 |
Baseline #8419 |
|
|---|---|---|
0B |
0B |
|
0B |
0B |
|
0% |
0% |
|
0 |
0 |
|
4 |
4 |
|
198 |
198 |
|
80 |
80 |
|
44.73% |
44.73% |
|
2 |
2 |
|
0 |
0 |
Bundle size by type no changes
| Current #8421 |
Baseline #8419 |
|
|---|---|---|
145.76KiB |
145.76KiB |
|
91.42KiB |
91.42KiB |
Bundle analysis report Branch Sherry-hue:fix/create-json-show Project dashboard
Generated by RelativeCI Documentation Report issue
React External#1536 Bundle Size — 695.4KiB (0%).89da870(current) vs dae1d41 main#1534(baseline) Bundle metrics
|
| Current #1536 |
Baseline #1534 |
|
|---|---|---|
0B |
0B |
|
0B |
0B |
|
0% |
0% |
|
0 |
0 |
|
3 |
3 |
|
17 |
17 |
|
5 |
5 |
|
8.59% |
8.59% |
|
0 |
0 |
|
0 |
0 |
Bundle analysis report Branch Sherry-hue:fix/create-json-show Project dashboard
Generated by RelativeCI Documentation Report issue
b0c59c7 to
587ae5b
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/genui/a2ui-playground/src/pages/AIChatPage.tsx`:
- Around line 444-445: When starting a new generation the preview state is
cleared with setPreviewMessages(null) but the ref
latestPreviewMessagesRef.current is not reset, so handlePreviewLoad can
republish stale messages; update the start-of-generation flow (the code that
calls setPreviewMessages(null) and setIsGenerating(true)) to also clear
latestPreviewMessagesRef.current (set to null or an empty value) so the iframe
load handler (handlePreviewLoad) cannot access previous-run messages; locate
these symbols (previewMessages, latestPreviewMessagesRef, handlePreviewLoad,
setPreviewMessages, setIsGenerating) and ensure the ref is reset atomically when
beginning generation.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: c74ab5be-78bd-4777-a580-97a93e0683fd
📒 Files selected for processing (2)
packages/genui/a2ui-playground/src/pages/AIChatPage.csspackages/genui/a2ui-playground/src/pages/AIChatPage.tsx
✅ Files skipped from review due to trivial changes (1)
- packages/genui/a2ui-playground/src/pages/AIChatPage.css
587ae5b to
89da870
Compare
Summary by CodeRabbit
Checklist