Colour picker
The native colour input cut down to a square of input fill, with the swatch inset by one step.
Examples
Colour picker
Anatomy
input.input[type=color] | A square, --ae-space-6 on each side, with the swatch inset by --ae-space-1. A click opens the system colour picker. |
API
| Attribute | Values | Description |
|---|---|---|
value | <hex> | Native: the chosen colour as #rrggbb. Default #000000. |
Accessibility
- The swatch shows the colour, not its name. Label the input, and show the value as text beside it when the exact colour matters.
- For a fixed set of colours, a swatch picker is quicker and announces each choice by name.
| Key | Effect |
|---|---|
| Enter / Space | Opens the system colour picker (native). |