Skip to content

DocsFormsRadio

PT

Forms

Radio

Pick one option from a group, with the dot growing when checked.

CSS only

Example

Installation

Radio ships in the full package, in unslop.css:

curl -fsSL unslop.leallabs.dev/i | sh

No build It's just CSS: with unslop.css on the page, the classes already work.

Classes and variants

ClassWhat it does
u-radioThe label that wraps the input and the dot.
u-radio__dotThe drawn circle.

Accessibility and keyboard

State and roles

WhereAttributeWhat it says
namenative attributeThe same name groups the options.
checkednative attributeChecked option.

Keyboard

KeyDoes
Tabenters the group
Arrowschange the checked option (native)

Type to search. Arrows pick, Enter opens.