Compose Lab

Design system

Bolt, by Thunderbird

Thunderbird for Android builds its screens from Bolt: tokens and components on top of Material 3, shared by Thunderbird and K-9 Mail. Here is its catalog, then an inbox made from it, parsed from the unchanged Kotlin source and rendered live, with no compiler or emulator.

Kotlin files, parsed in your browser
207Kotlin files, parsed in your browser
brands on one set of components
2brands on one set of components
layers: theme, atoms, molecules, organisms
4layers: theme, atoms, molecules, organisms
Brand
Mode

The brand switch edits ui/theme/AppTheme.kt, the one file that picks it.

Part 1

The catalogue

The pages of Bolt’s own catalog app, rendered from its Kotlin source. Each one is a preview in ui/catalog/CatalogPages.kt that runs the catalog’s items unchanged. Scroll inside a page: buttons, fields, switches and tabs respond.

Theme

The tokens every component reads: a palette for each brand and mode, and one type scale.

Colors

Material roles plus info, success and warning.

Source

Typography

Display to label, plain, colored and annotated.

Source

Atoms

The smallest parts, each a thin layer over Material 3 that only takes Bolt’s tokens.

Buttons

Filled, tonal, elevated, outlined, text, icon and segmented.

Source

Selection controls

Checkboxes, radio buttons, switches and a dropdown.

Source

Text fields

Outlined fields for text, email, passwords, numbers and choices.

Source

Cards

Filled, outlined and elevated.

Source

Molecules

Atoms put together for one job, such as a labeled input with its error.

Inputs

Fields with a label, help and error messages.

Source

Tab rows

Primary and secondary tabs, with icons and badges.

Source

States

Loading, error and content views.

Source

Organisms

Whole sections of a screen.

App bars

Top app bars with menu, back and actions.

Source

Banners

Global and inline notifications in four tones.

Source

Part 2

In a screen

An inbox made from the same parts. Our code is 5 files. The other 202, Bolt and Thunderbird’s message list, come unchanged from thunderbird-android.

Built from the catalogue

Theme
AppTheme, on ThunderbirdBoltTheme or K9MailBoltTheme
Template
Scaffold
Organisms
TopAppBarWithMenuButton, and Thunderbird’s NewMessageItem, UnreadMessageItem and ReadMessageItem
Molecules
TabRowPrimary
Atoms
ButtonIcon, TabPrimary, DividerHorizontal, TextTitleMedium, TextBodyLarge

The screen sets no color, font or size of its own, so it follows the brand and the mode with no change. It is showing Thunderbird, light.

Try it

  • Open a message: it turns from unread to read. Star one, then look under Starred.
  • Switch the brand to K-9 Mail above: the inbox and every page of the catalogue change together.
  • Open the code and edit a token in Bolt, such as a color in thunderbird/bolt/theme/thunderbird/ThemeColors.kt.

From thunderbird/thunderbird-android, under the Apache 2.0 license.