appearance

package
v0.46.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 18, 2026 License: MIT Imports: 15 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package appearance is the look showcase: palettes, surfaces, glyphs and the components whose subject is how they are drawn, so a change that breaks an older look shows up where you can see it.

Look     palette, surface and glyph pickers that redraw the whole app
         live (rule 35), beside what each kind of component is handed —
         a list (the surface), an input and a toggle (its field form), a
         modal (its overlay form), and a pane pinned to Outlined
Form     a pkg/form wizard holding every field kind on one card: notes,
         validation on leaving a step, a select that must be picked, a
         multi-select, a text area, and typed values in wells
Text     pkg/textview: a document to read, search and wrap
Panes    border styles, title positions and slot brackets side by side
Layouts  pkg/layout trees — VStack, HStack, ZStack, Center, Fixed, Flex —
         each pushed as its own screen (rule 2)

The tabs are pkg/tab (rule 21): shift+←/→ or 1–5 switch. Each tab is its own package beside this one.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(t theme.Theme) screen.Screen

New returns the appearance screen.

func Palettes

func Palettes() []palette.Palette

Palettes is what the palette picker offers. An app hosting the picker passes the same list as app.Options.Palettes, so every name it sends resolves.

func Surfaces

func Surfaces() []surface.Surface

Surfaces is what the surface picker offers, two custom surfaces among them; pass it as app.Options.Surfaces for the same reason.

Types

type Screen

type Screen struct {
	// contains filtered or unexported fields
}

Screen holds each body so a theme rebuild reuses it — the swap is what the Look tab exists to cause, so every other tab is rebuilt in place under it.

func (*Screen) Help

func (s *Screen) Help() []key.Binding

func (*Screen) HelpSections

func (s *Screen) HelpSections() []help.Section

func (*Screen) Init

func (s *Screen) Init() tea.Cmd

func (*Screen) IsCapturingKeys

func (s *Screen) IsCapturingKeys() bool

func (*Screen) Layout

func (s *Screen) Layout() layout.Node

func (*Screen) OnEnter

func (s *Screen) OnEnter(r any) tea.Cmd

func (*Screen) SetTheme

func (s *Screen) SetTheme(t theme.Theme)

func (*Screen) Title

func (s *Screen) Title() string

func (*Screen) Update

func (s *Screen) Update(msg tea.Msg) (screen.Screen, tea.Cmd)

Directories

Path Synopsis
Package form is the pkg/form showcase: a two-step sign-up wizard holding every field kind on one card.
Package form is the pkg/form showcase: a two-step sign-up wizard holding every field kind on one card.
Package layouts demonstrates that pkg/layout can describe arbitrary compositions without the caller doing "m.h-2" math.
Package layouts demonstrates that pkg/layout can describe arbitrary compositions without the caller doing "m.h-2" math.
Package look is the live look picker: moving a cursor redraws the whole app in that palette (app.SetPalette) or that surface (app.SetSurface) — line border, filled card, header band, drop shadow — and the glyph picker swaps the marks this screen draws with.
Package look is the live look picker: moving a cursor redraws the whole app in that palette (app.SetPalette) or that surface (app.SetSurface) — line border, filled card, header band, drop shadow — and the glyph picker swaps the marks this screen draws with.
Package pane demonstrates pane border styles, title positions, and slot-bracket variants in a single screen.
Package pane demonstrates pane border styles, title positions, and slot-bracket variants in a single screen.
Package textview demonstrates pkg/textview: a read-only viewer for static text content with search, wrap toggle, and vim-style navigation.
Package textview demonstrates pkg/textview: a read-only viewer for static text content with search, wrap toggle, and vim-style navigation.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL