Skip to content
API reference

components/icon-lamp

Import
import * as api from "@fungi.computer/caps/components/icon-lamp";
Kind Export Description
type alias IconLampProps Props accepted by IconLamp.
type alias IconLampItem One lamp in an IconLamps row.
type alias IconLampsProps Props accepted by IconLamps.
constant IconLamp A read-only icon state: an icon key’s face with no input, for rights or settings shown but not changed here. It reads as “Label: state”.
constant IconLamps A named row of read-only icon lamps; name it with aria-label(ledby).

IconLampPropstype alias

Section titled “IconLampProps”
Signature
type IconLampProps = object & Omit<HTMLAttributes<HTMLElement>, "children">;

Props accepted by IconLamp.

Name Type Description
label string The full name read with the state, such as “Read files”.
icon ReactNode -
caption? string A short visible legend; it does not replace the accessible label.
on boolean Lit: the icon in colour with the ink lamp. Off: the grey silhouette.
stateLabels? readonly [string, string] How the state reads aloud, as [on, off].

IconLampItemtype alias

Section titled “IconLampItem”
Signature
type IconLampItem = Omit<IconLampProps, "stateLabels"> & object;

One lamp in an IconLamps row.

Name Type
id string

IconLampsPropstype alias

Section titled “IconLampsProps”
Signature
type IconLampsProps = object &
Omit<HTMLAttributes<HTMLUListElement>, "children">;

Props accepted by IconLamps.

Name Type
items readonly IconLampItem[]
stateLabels? readonly [string, string]

IconLampconstant

Section titled “IconLamp”
Signature
const IconLamp: ForwardRefExoticComponent<
object &
Omit<HTMLAttributes<HTMLElement>, "children"> &
RefAttributes<HTMLElement>
>;

A read-only icon state: an icon key’s face with no input, for rights or settings shown but not changed here. It reads as “Label: state”.


IconLampsconstant

Section titled “IconLamps”
Signature
const IconLamps: ForwardRefExoticComponent<
object &
Omit<HTMLAttributes<HTMLUListElement>, "children"> &
RefAttributes<HTMLUListElement>
>;

A named row of read-only icon lamps; name it with aria-label(ledby).