View on GitHub
๐ฅ๏ธ Terminal Session Web Component Demo
Basic Example
A simple terminal showing a git workflow session:
Light Theme Example
Same session with light theme:
Custom Colors Example
Terminal with custom color scheme:
Customizable Toolbar & Header
Fine-grained control over all UI elements:
No Window Buttons
No Control Buttons
Play Button Only
No Header At All
Tabbed Terminal with Background Processing
Tabs continue processing in the background when you switch between
them:
๐ก Try switching between tabs - they continue running in the
background!
Minimal Tabbed Terminal
Tabs below header without any control buttons for a clean interface:
Completely Minimal - No Toolbar
Terminal without any header or controls, just the content:
๐ก Perfect for embedding in documentation or tutorials
Rich Text Colorization
Terminal with colorized output similar to real terminal applications:
Interactive Controls
Features
๐จ Themeable
Light/dark themes with custom color overrides
โถ๏ธ Playback Control
Play, pause, and reset session recordings
๐ฏ Step Types
Command, output, error, warning, info, success
โก Performant
Built with Svelte 5 for optimal performance
๐ฆ Web Component
Works with any framework or vanilla JS
๐ง Customizable
Configurable speed, colors, and behavior
๐๏ธ Full UI Control
Show/hide header, window buttons, and control buttons individually
โจ๏ธ Typing Effect
Realistic typing animation with variable speed
๐ Advanced Tabs
Background processing, closable tabs, top/bottom position
๐๏ธ Smart Autoplay
Autoplay on visibility, tab switch, or manual trigger
๐ State Persistence
Tabs maintain state when switching
๐ฏ Web Component
HTML attributes with proper type conversion
Usage Examples
<!-- Basic terminal with custom controls -->
<terminal-session theme="dark" autoplay="true" playback-speed="1.5"
title="My Terminal" show-window-buttons="false"
show-reset-button="false" ></terminal-session> <!--
Minimal terminal without header --> <terminal-session
show-header="false" autoplay="true" ></terminal-session>
<!-- Tabbed terminal with bottom tabs --> <terminal-session
show-tabs="true" tab-bar-position="bottom" allow-tab-close="true"
></terminal-session> <script> const terminal =
document.querySelector('terminal-session'); // Set a simple session
terminal.session = [ { type: 'command', content: 'npm install', delay:
500 }, { type: 'output', content: 'Installing...', delay: 1000 }, {
type: 'success', content: 'Done!', delay: 500 } ]; // Or set tabs for
multiple sessions terminal.tabs = [ { id: 'tab1', title: 'Server',
icon: '๐ฅ๏ธ', session: serverSession, closable: true }, { id: 'tab2',
title: 'Tests', icon: '๐งช', session: testSession } ]; </script>