{"version":"v1.0","client_state":{"Studio.default":{"fields":{"primary":"#682747","secondary":"#3a52b0","success":"#2f9e64","warning":"#f0a91b","error":"#e5484d","info":"#0e9bc4","background":"#fafafa","surface":"#ffffff","interface":"#f0f0f1","text":"#171717","muted":"#6b6b6e","d_primary":"#682747","d_secondary":"#3a52b0","d_success":"#2f9e64","d_warning":"#f0a91b","d_error":"#e5484d","d_info":"#0e9bc4","d_background":"#0a0a0a","d_surface":"#151515","d_interface":"#212121","d_text":"#f5f5f5","d_muted":"#a0a0a3","spacing":0.1875,"box":0.75,"field_":0.75,"selector":0.375,"stroke":1.0,"font":"ui-sans-serif, system-ui, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Noto Color Emoji'"},"persist":"local","send_to_server":true},"ColorScheme.default":{"fields":{"mode":"system"},"persist":"local","send_to_server":true}},"endpoints":{"action":"/_bretzel/action","sse":"/_bretzel/sse","refetch":"/_bretzel/refetch"},"csrf":"43ff57591466fb5c3f6152b581f14bfd","page_id":"a83379886bf84923be5f23ee15b686fd","address":""}
ui.stack

Stack & flex

Rows and columns with a spacing scale — vstack and hstack for the everyday case, flex for the full axis API.

A vertical list

ui.vstack puts its children one under the other, with a gap from the theme's spacing scale.
Inbox
Drafts
Scheduled
Archive

A horizontal row

ui.hstack centres its children vertically by default — the usual intent for a row.

Distribute along the row

justify="start"
justify="center"
justify="end"
justify="between"

Let it wrap

wrap=True sends the overflow to the next line instead of squeezing the tags.
PythonFastAPIPostgreSQLRedisTailwindHTMXDockerPlaywrightServer-sent events

A filter bar that shares the width

grow="16rem" gives each field a 16rem basis, then shares what is left; below that they wrap.

Change direction with the window

ui.flex takes a breakpoint dict: a column on a phone, a row from md upwards.
SidebarStacks on top on a phone.
Main contentTakes the remaining width once the window is wide enough for two columns.