Pulastya B commited on
Commit
154fb5a
·
1 Parent(s): 55d3b25

debug: Add visible debug section for plots

Browse files

- Show yellow debug box when message has Visualizations text
- Display whether msg.plots exists
- Show plots array length and data
- Will help see if plots are in message object

FRRONTEEEND/components/ChatInterface.tsx CHANGED
@@ -509,6 +509,19 @@ export const ChatInterface: React.FC<{ onBack: () => void }> = ({ onBack }) => {
509
  })}
510
  </div>
511
  )}
 
 
 
 
 
 
 
 
 
 
 
 
 
512
  {msg.plots && msg.plots.length > 0 && (
513
  <>
514
  {console.log('🎨 Rendering plots for message:', msg.id, msg.plots)}
 
509
  })}
510
  </div>
511
  )}
512
+ {/* DEBUG: Force show plots section */}
513
+ {msg.role === 'assistant' && msg.content?.includes('Visualizations') && (
514
+ <div className="mt-4 space-y-3 border-2 border-yellow-500">
515
+ <div className="text-xs font-semibold text-yellow-400 mb-2">
516
+ 🐛 DEBUG: Plots section (should appear if msg has Visualizations in content)
517
+ </div>
518
+ <div className="text-xs text-white/60">
519
+ msg.plots exists: {msg.plots ? 'YES' : 'NO'}<br/>
520
+ msg.plots length: {msg.plots?.length || 0}<br/>
521
+ msg.plots data: {JSON.stringify(msg.plots)}
522
+ </div>
523
+ </div>
524
+ )}
525
  {msg.plots && msg.plots.length > 0 && (
526
  <>
527
  {console.log('🎨 Rendering plots for message:', msg.id, msg.plots)}