fix: chart/diagram fond cohérent avec le thème + slides strictement proportionnels
- slides-renderer: chart et diagram utilisent bg/text/muted du thème (plus de fond #111827 forcé) - slides.tool: prompt ultra-clair (<50 mots = max 3 slides) + cappedSlides.slice(0,8) côté serveur comme filet de sécurité Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -390,10 +390,11 @@ function SlideContent({ slide, index, palette, radius }: { slide: SlideSpec; ind
|
||||
// ── CHART ────────────────────────────────────────────────────────────
|
||||
case 'chart':
|
||||
return (
|
||||
<div style={{ width: '100%', height: '100%', display: 'flex', flexDirection: 'column', padding: '48px 60px', background: isDark ? palette.bg : '#111827', textAlign: 'left' }}>
|
||||
<h2 style={{ margin: 0, fontSize: 30, fontWeight: 800, letterSpacing: '-0.04em', color: '#fff' }}>{slide.title}</h2>
|
||||
{slide.subtitle && <p style={{ margin: '6px 0 0', fontSize: 15, color: 'rgba(255,255,255,0.5)' }}>{slide.subtitle}</p>}
|
||||
<div style={{ flex: 1, marginTop: 24 }}>
|
||||
<div style={{ width: '100%', height: '100%', display: 'flex', flexDirection: 'column', padding: '48px 60px', textAlign: 'left' }}>
|
||||
<h2 style={{ margin: 0, fontSize: 30, fontWeight: 800, letterSpacing: '-0.04em', color: text }}>{slide.title}</h2>
|
||||
{slide.subtitle && <p style={{ margin: '6px 0 0', fontSize: 15, color: muted }}>{slide.subtitle}</p>}
|
||||
<div style={accentBar} />
|
||||
<div style={{ flex: 1 }}>
|
||||
<SlideChart slide={slide} />
|
||||
</div>
|
||||
</div>
|
||||
@@ -402,11 +403,12 @@ function SlideContent({ slide, index, palette, radius }: { slide: SlideSpec; ind
|
||||
// ── DIAGRAM ──────────────────────────────────────────────────────────
|
||||
case 'diagram':
|
||||
return (
|
||||
<div style={{ width: '100%', height: '100%', display: 'flex', flexDirection: 'column', padding: '48px 60px', background: isDark ? palette.bg : '#111827', textAlign: 'left' }}>
|
||||
<h2 style={{ margin: 0, fontSize: 30, fontWeight: 800, letterSpacing: '-0.04em', color: '#fff' }}>{slide.title}</h2>
|
||||
{slide.subtitle && <p style={{ margin: '6px 0 0', fontSize: 15, color: 'rgba(255,255,255,0.5)' }}>{slide.subtitle}</p>}
|
||||
<div style={{ flex: 1, marginTop: 20, overflow: 'hidden', display: 'flex', alignItems: 'center', justifyContent: 'center' }}>
|
||||
{slide.mermaid ? <MermaidDiagram chart={slide.mermaid} isDark={true} /> : <p style={{ color: 'rgba(255,255,255,0.3)' }}>No diagram</p>}
|
||||
<div style={{ width: '100%', height: '100%', display: 'flex', flexDirection: 'column', padding: '48px 60px', textAlign: 'left' }}>
|
||||
<h2 style={{ margin: 0, fontSize: 30, fontWeight: 800, letterSpacing: '-0.04em', color: text }}>{slide.title}</h2>
|
||||
{slide.subtitle && <p style={{ margin: '6px 0 0', fontSize: 15, color: muted }}>{slide.subtitle}</p>}
|
||||
<div style={accentBar} />
|
||||
<div style={{ flex: 1, overflow: 'hidden', display: 'flex', alignItems: 'center', justifyContent: 'center' }}>
|
||||
{slide.mermaid ? <MermaidDiagram chart={slide.mermaid} isDark={isDark} /> : <p style={{ color: muted }}>No diagram</p>}
|
||||
</div>
|
||||
</div>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user