shui

🎨 Theming

Built-in themes, icon sets, custom themes, and the token reference.

🌈 Built-in themes

ThemeDescription
default256-colour with automatic 16-colour fallback
minimalClean 16-colour ANSI palette
plainNo colour — text and ASCII icons only
SHUI_THEME=minimal source shui.zsh
# or export it so all scripts pick it up
export SHUI_THEME=minimal

NO_COLOR

shui respects the NO_COLOR convention. When $NO_COLOR is set, inline components fall back to ASCII and no colour codes are emitted.

🔣 Icon sets

SetRequiresDescription
nerdNerd FontRich glyphicons (default)
emojiNothingUnicode emoji, works everywhere
noneNothingNo icons — text only
unicodeNothingBase layer — always loaded automatically
SHUI_ICONS=emoji source shui.zsh
SHUI_THEME=plain SHUI_ICONS=none source shui.zsh   # fully plain

🛠️ Custom themes

Generate a new theme pre-filled with all tokens:

shui theme create mytheme
# → src/themes/mytheme.zsh

A custom theme sources default.zsh first — only override the tokens you want:

# src/themes/mytheme.zsh
source "${SHUI_DIR}/src/themes/default.zsh"

SHUI_COLOR_PRIMARY=$(_shui_color "38;5;135" "0;35")  # purple
SHUI_COLOR_ACCENT=$(_shui_color  "38;5;135" "0;35")
shui theme list       # list available themes
shui theme validate   # check all required tokens are defined

📖 Token reference

TokenPurpose
SHUI_RESETReset all styles
SHUI_BOLD SHUI_DIM SHUI_ITALIC SHUI_UNDERLINEText styles
SHUI_COLOR_PRIMARYPrimary accent colour
SHUI_COLOR_SUCCESS SHUI_COLOR_WARNING SHUI_COLOR_ERRORStatus colours
SHUI_COLOR_INFO SHUI_COLOR_MUTED SHUI_COLOR_ACCENTInfo / muted / accent
SHUI_BG_SUCCESSSHUI_BG_MUTEDBadge background colours
SHUI_ICON_SUCCESS SHUI_ICON_ERRORStatus & UI icons

On this page