
Segmented control
A row of keys in a tray with one pressed down: pick a view, a range or a mode and it applies at once. It is the kit’s selector without the lamps, with sizes, a full-width row and icon segments.
The segmented control whose selection is one bead of glass. It is the kit’s control: the same tray, native radios and labels. Held, the bead is where the finger is; let go and it settles on the nearest segment without bounce. It stretches behind its head, and a long quick move leaves a drop that it takes back in. The bead is as wide as the segment it is over, so segments of unequal width work.
The bead is a pill of glass drawn by one shader: a dome whose rim bends a painted copy of the control’s own tray and labels, lit from above left, with a soft shadow. The keys’ own raised look is removed under the bead, and if the glass cannot be drawn a frosted CSS bead takes its place.
| Name | Kind | Description |
|---|---|---|
| change | event | The checked radio’s own change event; its value is the selection. |
| data-liquid | attribute | Which bead is showing. Read it, do not write it: the script falls back to frosted when WebGL2 is missing, the context is lost or reduced transparency is set. |
| liquidSegmentedHTML(options) | function | The control as markup. |
| liquidSegmentedStats() | function | What is drawing: WebGL contexts open (0 or 1 for the whole page), controls on the page, and how many of them are glass. |
Drag the bead and let go, or tap a segment. Focus the group and press an arrow key. Without WebGL, or with reduced transparency set, the bead is frosted instead of glass and everything else is the same.

A row of keys in a tray with one pressed down: pick a view, a range or a mode and it applies at once. It is the kit’s selector without the lamps, with sizes, a full-width row and icon segments.
The settings switch whose thumb is a drop of glass. It is the kit’s switch. Held, the thumb is exactly where the finger is; let go and it carries on at the finger’s speed and settles without bounce. It stretches as it travels, and on a quick move it leaves a small drop behind that it takes back in. The glass bends a painted copy of the switch’s own track, so the slot’s colour shows through the thumb.

The segmented control’s keys, each latching on its own, so any number can be down at once: bold and italic, the columns a table shows, the filters on a log. Every key is a checkbox and posts with the form. A lone toggle is a group of one, and a parting line splits clusters of keys in one slot.

A mode switch made of cloth. A row of tiles covered in stretched fabric stands in a machined tray, each with an icon and a word pressed into it. The chosen tile sits a touch lower and a lamp behind it lights its icon and word through the weave. Choose another and the first lamp fades down as the next comes up. Underneath it is a group of native radios, so it posts one value without any script.