lotusui the ikaito design language for Gio — desktop, mobile, web
GitHub

Stack

VStack and HStack: children size themselves, the gap is the whole job.

A lotusui extension: the stacking primitives that stop screens hand-weaving spacer children between rows. VStack stacks vertically, HStack horizontally with children centered on the cross axis. For flowing chips that wrap to the next line, see Wrap. For 1dp rules, see Separator.

Installation

Use the module import (the default), or own the source: lotusui add vendors the component into your app and lotusui update keeps the copy mergeable — see Registry.

Go
go get github.com/ikaito-com/lotusui

# or vendor the source into your app:
go run github.com/ikaito-com/lotusui/cmd/lotusui add stack

VStack

Go
lotusui.VStack(th.Space.SM, first, second, third)

HStack

Children center on the cross axis, so a switch and its label sit on one visual line. Never wraps — under a narrow Max.X, Rigid children are squeezed; use Wrap instead.

Go
lotusui.HStack(th.Space.SM, one, two, three)

Spacers

Spacer/HSpacer are fixed gaps for ad-hoc composition when you are not using a Stack.

Go
lotusui.Spacer(th.Space.MD)   // vertical
lotusui.HSpacer(th.Space.SM)  // horizontal

API

OptionTypeDescription
VStack(gap, children...)unit.DpVertical stack; the gap is the whole job.
HStack(gap, children...)unit.DpHorizontal stack, children centered on the cross axis. Never wraps.
Spacer(h) / HSpacer(w)unit.DpFixed gaps for ad-hoc composition.

Every demo on this site is the real Go component compiled to WebAssembly — one gallery app, one bundle, addressed by URL hash.