Sunstone::Docs::B_AUTHORING::Layouts
Semantic Slide Layouts
Executive Summary & Key Topics
| Topic | Method / Anchor | Description |
|---|---|---|
| Layout Gallery | .topic_01_layout_gallery |
Overview of layout types and their use cases. |
| Two-Column Slide Syntax | .topic_02_two_column_syntax |
Example YAML syntax for a two-column code and notes slide. |
Class methods
topic_01_layout_gallery
Layout Gallery: Overview of layout types and their use cases.
Sunstone provides 15 specialized layout renderers:
- intro: Hero title slide with large badges, subtitle, author credentials, and strategic pillar pills.
- chapter: Section divider featuring a chapter number and topic pillars.
- two-column: Flexible split layout supporting code, cards, and text in ratios
1:1,3:2,2:3,1:2, and2:1. - code-comparison: Side-by-side or two-step critique revealing bad patterns followed by improved solutions.
- three-column: Three equal or weighted informational cards.
- four-column: Four-card grid for quadrants or comparisons.
- matrix: 2x2 quadrant analysis with custom labels and colors.
- timeline: Horizontal milestone rail with status indicators and dates.
- architecture: Multi-tier technology stack with CSS flow indicators.
- media: Images, video, or embedded Asciinema terminal recordings.
- profile: Speaker or team bio with avatar, social links, and credentials.
- dual-mode: Interactive tabbed comparison.
- demo-roadmap: Interactive live-demo checklist.
- closing: Outro slide with takeaways, key quote, and contact links.
- quote: High-impact typographic quote or testimonial slide.
topic_02_two_column_syntax
Two-Column Slide Syntax: Example YAML syntax for a two-column code and notes slide.
id: "channels_example"
layout: "two-column"
badge: "CONCURRENCY"
badge_color: "accent"
palette: "emerald_matrix"
ratio: "3:2"
title: "Buffered Channels"
subtitle: "Non-blocking message passing between fibers"
code_title: "channel.cr"
code_lang: "crystal"
code: |
ch = Channel(Int32).new(capacity: 10)
spawn do
10.times { |i| ch.send(i) }
ch.close
end
while val = ch.receive?
puts val
end
cards:
- title: "Key Principles"
color: "emerald"
items:
- "Channel buffers prevent producer backpressure"
- "Fibers yield cooperatively upon buffer saturation"
notes: |
Explain how Crystal channels compare with Go channels.