- Name
service- Kind
- parameter
- Type
CheckboxService- Requirement
- required
DocsAPI referenceHeadlesscheckbox
checkbox headless API
The core connector and vanilla mount are always visible. Use the framework choice to inspect native composition, props, outputs, context and hooks for the selected adapter.
@grassroot/ui-headless-core/checkbox
Core connector and vanilla API
activateCheckbox
functiondeclare function activateCheckbox(service: CheckboxService, scope: PartScope, options?: CheckboxConnectOptions): () => void;serviceCheckboxServicescopePartScopeoptionsCheckboxConnectOptionsreturn() => void- Name
scope- Kind
- parameter
- Type
PartScope- Requirement
- required
- Name
options- Kind
- parameter
- Type
CheckboxConnectOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
() => void- Requirement
- n/a
checkboxAnatomy
valueexport declare const checkboxAnatomy: readonly ["root", "hidden-input", "control", "indicator", "label", "description"];CheckboxApi
interfaceinterface CheckboxApi { rootProps(): PartProps; hiddenInputProps(): PartProps; controlProps(): PartProps; indicatorProps(): PartProps; labelProps(): PartProps; descriptionProps(): PartProps; /** * Restores the registered hidden input's `checked` AND `indeterminate` * DOM properties from the committed snapshot; a no-op without DOM. The * Checkbox counterpart of Switch's `syncNativeChecked()` * [checkbox.spec.md "Connector differences"]. */ syncNativeState(): void; readonly checked: boolean; readonly indeterminate: boolean; readonly disabled: boolean; readonly readOnly: boolean;}checkedbooleancontrolProps() => PartPropsdescriptionProps() => PartPropsdisabledbooleanindeterminatebooleanindicatorProps() => PartPropslabelProps() => PartPropsreadOnlybooleanrootProps() => PartPropssyncNativeState() => void- Name
checked- Kind
- property
- Type
boolean- Requirement
- required
- Description
- —
- Name
controlProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Description
- —
- Name
descriptionProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Description
- —
- Name
disabled- Kind
- property
- Type
boolean- Requirement
- required
- Description
- —
- Name
hiddenInputProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Description
- —
- Name
indeterminate- Kind
- property
- Type
boolean- Requirement
- required
- Description
- —
- Name
indicatorProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Description
- —
- Name
labelProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Description
- —
- Name
readOnly- Kind
- property
- Type
boolean- Requirement
- required
- Description
- —
- Name
rootProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Description
- —
- Name
syncNativeState- Kind
- method
- Type
() => void- Requirement
- required
- Description
- Restores the registered hidden input's `checked` AND `indeterminate` DOM properties from the committed snapshot; a no-op without DOM. The Checkbox counterpart of Switch's `syncNativeChecked()` [checkbox.spec.md "Connector differences"].
CheckboxChangeDetail
interfaceinterface CheckboxChangeDetail { readonly checked: boolean; readonly reason: CheckboxReason;}checkedbooleanreasonCheckboxReason- Name
checked- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
CheckboxReason- Requirement
- required
CheckboxCheckedValue
typetype CheckboxCheckedValue = boolean | "indeterminate";CheckboxCommand
typetype CheckboxCommand = CommandObject & { readonly type: "CHECKED_CHANGE_REQUEST"; readonly checked: boolean; readonly reason: CheckboxReason;};checkedbooleanreasonCheckboxReasontypestring- Name
checked- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
CheckboxReason- Requirement
- required
- Name
type- Kind
- property
- Type
string- Requirement
- required
CheckboxConnectOptions
interfaceinterface CheckboxConnectOptions { readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; /** Framework-native passthrough [switch.spec.md #6, inherited]. */ readonly onChange?: (event: unknown) => void; readonly name?: string; readonly value?: string; readonly required?: boolean; /** Accessible-name escape hatch [baseline #17, inherited]. */ readonly ariaLabel?: string;}ariaLabelstringnamestringonChange(event: unknown) => voidonCheckedChange(detail: CheckboxChangeDetail) => voidrequiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Description
- Accessible-name escape hatch [baseline #17, inherited].
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Description
- —
- Name
onChange- Kind
- property
- Type
(event: unknown) => void- Requirement
- optional
- Description
- Framework-native passthrough [switch.spec.md #6, inherited].
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
- Description
- —
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Description
- —
- Name
value- Kind
- property
- Type
string- Requirement
- optional
- Description
- —
CheckboxContext
typetype CheckboxContext = { readonly mode: BindingMode;};modeBindingMode- Name
mode- Kind
- property
- Type
BindingMode- Requirement
- required
CheckboxEvent
typetype CheckboxEvent = { readonly type: "TOGGLE"; readonly reason: CheckboxReason;} | { readonly type: "RESET";};CheckboxInput
typetype CheckboxInput = { readonly checked?: CheckboxCheckedValue; readonly defaultChecked?: CheckboxCheckedValue; readonly disabled?: boolean; readonly readOnly?: boolean;};checkedCheckboxCheckedValuedefaultCheckedCheckboxCheckedValuedisabledbooleanreadOnlyboolean- Name
checked- Kind
- property
- Type
CheckboxCheckedValue- Requirement
- optional
- Name
defaultChecked- Kind
- property
- Type
CheckboxCheckedValue- Requirement
- optional
- Name
disabled- Kind
- property
- Type
boolean- Requirement
- optional
- Name
readOnly- Kind
- property
- Type
boolean- Requirement
- optional
checkboxMachine
valueexport declare const checkboxMachine: Machine<CheckboxInput, CheckboxValue, CheckboxContext, CheckboxEvent, CheckboxCommand>;CheckboxMount
interfaceinterface CheckboxMount { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly root: HTMLElement; readonly input: HTMLInputElement; readonly control: HTMLElement; readonly indicator: HTMLElement; readonly label: HTMLElement | null; readonly description: HTMLElement | null; destroy(): void;}connectorCheckboxApicontrolHTMLElementdescriptionHTMLElement | nulldestroy() => voidindicatorHTMLElementinputHTMLInputElementlabelHTMLElement | nullrootHTMLElementserviceCheckboxService- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Name
control- Kind
- property
- Type
HTMLElement- Requirement
- required
- Name
description- Kind
- property
- Type
HTMLElement | null- Requirement
- required
- Name
destroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
indicator- Kind
- property
- Type
HTMLElement- Requirement
- required
- Name
input- Kind
- property
- Type
HTMLInputElement- Requirement
- required
- Name
label- Kind
- property
- Type
HTMLElement | null- Requirement
- required
- Name
root- Kind
- property
- Type
HTMLElement- Requirement
- required
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
CheckboxNativeStateTarget
interfaceDuck-typed hidden-input shape needed to restore both live DOM properties.
interface CheckboxNativeStateTarget { checked: boolean; indeterminate: boolean;}checkedbooleanindeterminateboolean- Name
checked- Kind
- property
- Type
boolean- Requirement
- required
- Name
indeterminate- Kind
- property
- Type
boolean- Requirement
- required
CheckboxPart
typetype CheckboxPart = (typeof checkboxAnatomy)[number];CheckboxReason
typetype CheckboxReason = "pointer" | "keyboard" | "programmatic";checkboxSelectors
valueexport declare const checkboxSelectors: { checked: (snapshot: CheckboxSnapshot) => boolean; indeterminate: (snapshot: CheckboxSnapshot) => boolean; state: (snapshot: CheckboxSnapshot) => CheckboxValue;};checked(snapshot: CheckboxSnapshot) => booleanindeterminate(snapshot: CheckboxSnapshot) => booleanstate(snapshot: CheckboxSnapshot) => CheckboxValue- Name
checked- Kind
- property
- Type
(snapshot: CheckboxSnapshot) => boolean- Requirement
- required
- Name
indeterminate- Kind
- property
- Type
(snapshot: CheckboxSnapshot) => boolean- Requirement
- required
- Name
state- Kind
- property
- Type
(snapshot: CheckboxSnapshot) => CheckboxValue- Requirement
- required
CheckboxService
typetype CheckboxService = Service<CheckboxInput, CheckboxValue, CheckboxContext, CheckboxEvent, CheckboxCommand>;CheckboxSnapshot
typetype CheckboxSnapshot = Snapshot<CheckboxValue, CheckboxContext>;CheckboxValue
typetype CheckboxValue = "unchecked" | "checked" | "indeterminate";connectCheckbox
functiondeclare function connectCheckbox(service: CheckboxService, scope: PartScope, options?: CheckboxConnectOptions): CheckboxApi;serviceCheckboxServicescopePartScopeoptionsCheckboxConnectOptionsreturnCheckboxApi- Name
service- Kind
- parameter
- Type
CheckboxService- Requirement
- required
- Name
scope- Kind
- parameter
- Type
PartScope- Requirement
- required
- Name
options- Kind
- parameter
- Type
CheckboxConnectOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
CheckboxApi- Requirement
- n/a
mountCheckbox
functiondeclare function mountCheckbox(container: HTMLElement, options?: MountCheckboxOptions): CheckboxMount;containerHTMLElementoptionsMountCheckboxOptionsreturnCheckboxMount- Name
container- Kind
- parameter
- Type
HTMLElement- Requirement
- required
- Name
options- Kind
- parameter
- Type
MountCheckboxOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
CheckboxMount- Requirement
- n/a
MountCheckboxOptions
interfaceinterface MountCheckboxOptions extends CheckboxInput { readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; /** Framework-native passthrough. */ readonly onChange?: (event: unknown) => void; readonly name?: string; readonly value?: string; readonly required?: boolean; /** Accessible-name escape hatch. */ readonly ariaLabel?: string; /** Omits the Label/Description parts entirely (the contract's "bare" scenario) — pair with `ariaLabel`. */ readonly bare?: boolean; /** Render callback for the label's content; default = "Checkbox" as textContent. Ignored when `bare`. */ readonly renderLabel?: (label: HTMLElement) => void; /** Render callback for the description's content; default = untouched (empty). Ignored when `bare`. */ readonly renderDescription?: (description: HTMLElement) => void;}ariaLabelstringbarebooleannamestringonChange(event: unknown) => voidonCheckedChange(detail: CheckboxChangeDetail) => voidrenderDescription(description: HTMLElement) => voidrenderLabel(label: HTMLElement) => voidrequiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Description
- Accessible-name escape hatch.
- Name
bare- Kind
- property
- Type
boolean- Requirement
- optional
- Description
- Omits the Label/Description parts entirely (the contract's "bare" scenario) — pair with `ariaLabel`.
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Description
- —
- Name
onChange- Kind
- property
- Type
(event: unknown) => void- Requirement
- optional
- Description
- Framework-native passthrough.
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
- Description
- —
- Name
renderDescription- Kind
- property
- Type
(description: HTMLElement) => void- Requirement
- optional
- Description
- Render callback for the description's content; default = untouched (empty). Ignored when `bare`.
- Name
renderLabel- Kind
- property
- Type
(label: HTMLElement) => void- Requirement
- optional
- Description
- Render callback for the label's content; default = "Checkbox" as textContent. Ignored when `bare`.
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Description
- —
- Name
value- Kind
- property
- Type
string- Requirement
- optional
- Description
- —
restoreNativeCheckboxState
functionSets both `checked` and `indeterminate` from a committed Checkbox value, writing only what actually changed (no churn) — the same discipline `restoreNativeChecked` (Switch, `../hidden-input.js`) uses for its single property. `indeterminate` has no HTML content attribute, so this is the only path that can ever carry it: `connectCheckbox`'s `onChange` handler, `activateCheckbox`'s reset restore, and `mountCheckbox`'s render loop all go through this one function.
declare function restoreNativeCheckboxState(input: CheckboxNativeStateTarget | null, next: { readonly checked: boolean; readonly indeterminate: boolean;}): void;inputCheckboxNativeStateTarget | nullnext{
readonly checked: boolean;
readonly indeterminate: boolean;
}returnvoid- Name
input- Kind
- parameter
- Type
CheckboxNativeStateTarget | null- Requirement
- required
- Name
next- Kind
- parameter
- Type
{ readonly checked: boolean; readonly indeterminate: boolean; }- Requirement
- required
- Name
return- Kind
- return value
- Type
void- Requirement
- n/a
runCheckboxCommand
functionCheckbox-shaped command runner — mirrors `runSwitchCommand`. Pass this as the `runCommand` option when constructing the Checkbox `Service` (never called by `connectCheckbox` itself). Maps `CHECKED_CHANGE_REQUEST` to exactly one `onCheckedChange({ checked, reason })` — no adapter compares snapshots to infer the callback.
declare function runCheckboxCommand(command: CheckboxCommand, options?: CheckboxConnectOptions): void;commandCheckboxCommandoptionsCheckboxConnectOptionsreturnvoid- Name
command- Kind
- parameter
- Type
CheckboxCommand- Requirement
- required
- Name
options- Kind
- parameter
- Type
CheckboxConnectOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
void- Requirement
- n/a
Framework adapters
Each panel keeps its adapter's public vocabulary. React compound exports, Vue composables, standalone Angular declarations, Svelte components, and Solid hooks stay native to their framework.
React imports
import { Checkbox, Control, Description, Indicator, Label, Root, RootProvider } from "@grassroot/ui-headless-react/checkbox";Vue imports
<script setup lang="ts">import { CheckboxControl, CheckboxDescription, CheckboxIndicator, CheckboxLabel, CheckboxRoot, CheckboxRootProvider } from "@grassroot/ui-headless-vue/checkbox";</script>Angular imports
import { Component } from "@angular/core";import { GR_CHECKBOX_DECLARATIONS } from "@grassroot/ui-headless-angular/checkbox"; @Component({ standalone: true, imports: [GR_CHECKBOX_DECLARATIONS], template: `<!-- compose the checkbox parts here -->` })export class Example {}Svelte imports
<script lang="ts"> import { CheckboxControl, CheckboxDescription, CheckboxIndicator, CheckboxLabel, CheckboxRoot, CheckboxRootProvider } from "@grassroot/ui-headless-svelte/checkbox";</script>Solid imports
import { CheckboxControl, CheckboxDescription, CheckboxIndicator, CheckboxLabel, CheckboxRoot, CheckboxRootProvider } from "@grassroot/ui-headless-solid/checkbox";@grassroot/ui-headless-react/checkbox
React adapter
Checkbox
valueexport declare const Checkbox: { Root: import("react").ForwardRefExoticComponent<CheckboxRootProps & import("react").RefAttributes<HTMLLabelElement>>; RootProvider: import("react").ForwardRefExoticComponent<CheckboxRootProviderProps & import("react").RefAttributes<HTMLLabelElement>>; HiddenInput: import("react").ForwardRefExoticComponent<CheckboxHiddenInputProps & import("react").RefAttributes<HTMLInputElement>>; Control: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean; } & import("react").RefAttributes<HTMLSpanElement>>; Indicator: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean; } & import("react").RefAttributes<HTMLSpanElement>>; Label: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean; } & import("react").RefAttributes<HTMLSpanElement>>; Description: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean; } & import("react").RefAttributes<HTMLSpanElement>>;};Controlimport("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
asChild?: boolean;
} & import("react").RefAttributes<HTMLSpanElement>>Descriptionimport("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
asChild?: boolean;
} & import("react").RefAttributes<HTMLSpanElement>>HiddenInputimport("react").ForwardRefExoticComponent<CheckboxHiddenInputProps & import("react").RefAttributes<HTMLInputElement>>Indicatorimport("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
asChild?: boolean;
} & import("react").RefAttributes<HTMLSpanElement>>Labelimport("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
asChild?: boolean;
} & import("react").RefAttributes<HTMLSpanElement>>Rootimport("react").ForwardRefExoticComponent<CheckboxRootProps & import("react").RefAttributes<HTMLLabelElement>>RootProviderimport("react").ForwardRefExoticComponent<CheckboxRootProviderProps & import("react").RefAttributes<HTMLLabelElement>>- Name
Control- Kind
- property
- Type
import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean; } & import("react").RefAttributes<HTMLSpanElement>>- Requirement
- required
- Name
Description- Kind
- property
- Type
import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean; } & import("react").RefAttributes<HTMLSpanElement>>- Requirement
- required
- Name
HiddenInput- Kind
- property
- Type
import("react").ForwardRefExoticComponent<CheckboxHiddenInputProps & import("react").RefAttributes<HTMLInputElement>>- Requirement
- required
- Name
Indicator- Kind
- property
- Type
import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean; } & import("react").RefAttributes<HTMLSpanElement>>- Requirement
- required
- Name
Label- Kind
- property
- Type
import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean; } & import("react").RefAttributes<HTMLSpanElement>>- Requirement
- required
- Name
Root- Kind
- property
- Type
import("react").ForwardRefExoticComponent<CheckboxRootProps & import("react").RefAttributes<HTMLLabelElement>>- Requirement
- required
- Name
RootProvider- Kind
- property
- Type
import("react").ForwardRefExoticComponent<CheckboxRootProviderProps & import("react").RefAttributes<HTMLLabelElement>>- Requirement
- required
CheckboxContext
valueexport declare const CheckboxContext: import("react").Context<CheckboxContextValue | null>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
CheckboxContextValue
interfaceinterface CheckboxContextValue { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope;}connectorCheckboxApiscopePartScopeserviceCheckboxService- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
CheckboxRootProps
interfaceinterface CheckboxRootProps extends Omit<ComponentPropsWithoutRef<"label">, "defaultChecked" | "checked" | "disabled" | "onChange"> { readonly asChild?: boolean; readonly checked?: CheckboxInput["checked"]; readonly defaultChecked?: CheckboxInput["defaultChecked"]; readonly disabled?: CheckboxInput["disabled"]; readonly readOnly?: CheckboxInput["readOnly"]; readonly name?: string; readonly value?: string; readonly required?: boolean; /** Accessible-name escape hatch [inherited from Switch's baseline #17] — see `Checkbox.Label` for the primary path. */ readonly ariaLabel?: string; /** * Seeds the part scope INSTEAD of the generated id when supplied * [inherited from Switch's baseline #10]: `<Checkbox.Root id="terms">` * yields deterministic `hidden-input`/`label`/`description` ids derived * from `"terms"`. Feeds `useCheckbox`'s `id` option — see that hook's doc * comment. Intercepted here rather than left in the native passthrough, so * it configures the scope seed instead of landing on the rendered * `<label>` as a plain HTML `id` attribute. */ readonly id?: string; readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; readonly onChange?: (event: ChangeEvent<HTMLInputElement>) => void; readonly children?: ReactNode;}ariaLabelstringasChildbooleancheckedCheckboxInput["checked"]childrenReactNodedefaultCheckedCheckboxInput["defaultChecked"]disabledCheckboxInput["disabled"]idstringnamestringonChange(event: ChangeEvent<HTMLInputElement>) => voidonCheckedChange(detail: CheckboxChangeDetail) => voidreadOnlyCheckboxInput["readOnly"]requiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Description
- Accessible-name escape hatch [inherited from Switch's baseline #17] — see `Checkbox.Label` for the primary path.
- Name
asChild- Kind
- property
- Type
boolean- Requirement
- optional
- Description
- —
- Name
checked- Kind
- property
- Type
CheckboxInput["checked"]- Requirement
- optional
- Description
- —
- Name
children- Kind
- property
- Type
ReactNode- Requirement
- optional
- Description
- —
- Name
defaultChecked- Kind
- property
- Type
CheckboxInput["defaultChecked"]- Requirement
- optional
- Description
- —
- Name
disabled- Kind
- property
- Type
CheckboxInput["disabled"]- Requirement
- optional
- Description
- —
- Name
id- Kind
- property
- Type
string- Requirement
- optional
- Description
- Seeds the part scope INSTEAD of the generated id when supplied [inherited from Switch's baseline #10]: `<Checkbox.Root id="terms">` yields deterministic `hidden-input`/`label`/`description` ids derived from `"terms"`. Feeds `useCheckbox`'s `id` option — see that hook's doc comment. Intercepted here rather than left in the native passthrough, so it configures the scope seed instead of landing on the rendered `<label>` as a plain HTML `id` attribute.
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Description
- —
- Name
onChange- Kind
- property
- Type
(event: ChangeEvent<HTMLInputElement>) => void- Requirement
- optional
- Description
- —
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
- Description
- —
- Name
readOnly- Kind
- property
- Type
CheckboxInput["readOnly"]- Requirement
- optional
- Description
- —
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Description
- —
- Name
value- Kind
- property
- Type
string- Requirement
- optional
- Description
- —
CheckboxRootProviderProps
interfaceinterface CheckboxRootProviderProps extends Omit<ComponentPropsWithoutRef<"label">, "defaultChecked" | "checked" | "disabled" | "onChange" | "value"> { readonly asChild?: boolean; /** An existing `useCheckbox()` result (advanced composition) — already fully configured. */ readonly value: UseCheckboxResult; readonly children?: ReactNode;}asChildbooleanchildrenReactNodevalueUseCheckboxResult- Name
asChild- Kind
- property
- Type
boolean- Requirement
- optional
- Description
- —
- Name
children- Kind
- property
- Type
ReactNode- Requirement
- optional
- Description
- —
- Name
value- Kind
- property
- Type
UseCheckboxResult- Requirement
- required
- Description
- An existing `useCheckbox()` result (advanced composition) — already fully configured.
Control
valueexport declare const Control: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean;} & import("react").RefAttributes<HTMLSpanElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
Description
valueexport declare const Description: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean;} & import("react").RefAttributes<HTMLSpanElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
Indicator
valueexport declare const Indicator: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean;} & import("react").RefAttributes<HTMLSpanElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
Label
valueexport declare const Label: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & { asChild?: boolean;} & import("react").RefAttributes<HTMLSpanElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
Root
valueexport declare const Root: import("react").ForwardRefExoticComponent<CheckboxRootProps & import("react").RefAttributes<HTMLLabelElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
RootProvider
valueexport declare const RootProvider: import("react").ForwardRefExoticComponent<CheckboxRootProviderProps & import("react").RefAttributes<HTMLLabelElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
useCheckbox
functiondeclare function useCheckbox(input: CheckboxInput, options?: UseCheckboxOptions): UseCheckboxResult;inputCheckboxInputoptionsUseCheckboxOptionsreturnUseCheckboxResult- Name
input- Kind
- parameter
- Type
CheckboxInput- Requirement
- required
- Name
options- Kind
- parameter
- Type
UseCheckboxOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
UseCheckboxResult- Requirement
- n/a
useCheckboxContext
functiondeclare function useCheckboxContext(partName: string): CheckboxContextValue;partNamestringreturnCheckboxContextValue- Name
partName- Kind
- parameter
- Type
string- Requirement
- required
- Name
return- Kind
- return value
- Type
CheckboxContextValue- Requirement
- n/a
UseCheckboxOptions
interfaceinterface UseCheckboxOptions { readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; readonly onChange?: (event: ChangeEvent<HTMLInputElement>) => void; readonly name?: string; readonly value?: string; readonly required?: boolean; readonly ariaLabel?: string; readonly id?: string;}ariaLabelstringidstringnamestringonChange(event: ChangeEvent<HTMLInputElement>) => voidonCheckedChange(detail: CheckboxChangeDetail) => voidrequiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Name
id- Kind
- property
- Type
string- Requirement
- optional
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Name
onChange- Kind
- property
- Type
(event: ChangeEvent<HTMLInputElement>) => void- Requirement
- optional
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Name
value- Kind
- property
- Type
string- Requirement
- optional
UseCheckboxResult
interfaceinterface UseCheckboxResult { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope; readonly snapshot: CheckboxSnapshot;}connectorCheckboxApiscopePartScopeserviceCheckboxServicesnapshotCheckboxSnapshot- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
- Name
snapshot- Kind
- property
- Type
CheckboxSnapshot- Requirement
- required
@grassroot/ui-headless-vue/checkbox
Vue adapter
CheckboxContextKey
valueexport declare const CheckboxContextKey: InjectionKey<CheckboxContextValue>;CheckboxContextValue
interfaceinterface CheckboxContextValue { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope; /** Bumped on every committed machine update; parts read `.value` to establish a reactive dependency. */ readonly snapshot: ShallowRef<CheckboxSnapshot>;}connectorCheckboxApiscopePartScopeserviceCheckboxServicesnapshotShallowRef<CheckboxSnapshot>- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Description
- —
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
- Description
- —
- Name
snapshot- Kind
- property
- Type
ShallowRef<CheckboxSnapshot>- Requirement
- required
- Description
- Bumped on every committed machine update; parts read `.value` to establish a reactive dependency.
CheckboxControl
valueexport declare const CheckboxControl: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;CheckboxDescription
valueexport declare const CheckboxDescription: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;CheckboxIndicator
valueexport declare const CheckboxIndicator: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;CheckboxLabel
valueexport declare const CheckboxLabel: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;CheckboxRoot
valueexport declare const CheckboxRoot: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; }; checked: { type: PropType<CheckboxInput["checked"]>; default: undefined; }; defaultChecked: { type: PropType<CheckboxInput["defaultChecked"]>; default: undefined; }; disabled: { type: PropType<CheckboxInput["disabled"]>; default: undefined; }; readOnly: { type: PropType<CheckboxInput["readOnly"]>; default: undefined; }; name: { type: PropType<string | undefined>; default: undefined; }; value: { type: PropType<string | undefined>; default: undefined; }; required: { type: PropType<boolean | undefined>; default: undefined; }; /** Accessible-name escape hatch [baseline #17, inherited] — see `CheckboxLabel` for the primary path. */ ariaLabel: { type: PropType<string | undefined>; default: undefined; }; /** * Seeds the part scope INSTEAD of the generated id when supplied * [baseline #10, inherited]: `<CheckboxRoot id="terms">` yields * deterministic `hidden-input`/`label`/`description` ids derived from * `"terms"`. Feeds `useCheckbox`'s `id` option — see that composable's * doc comment. Declared as a real prop (not left to fall through to * `attrs`) so it configures the scope seed instead of landing on the * rendered `<label>` as a plain HTML `id` attribute. */ id: { type: PropType<string | undefined>; default: undefined; };}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { checkedChange: (_detail: CheckboxChangeDetail) => true;}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; }; checked: { type: PropType<CheckboxInput["checked"]>; default: undefined; }; defaultChecked: { type: PropType<CheckboxInput["defaultChecked"]>; default: undefined; }; disabled: { type: PropType<CheckboxInput["disabled"]>; default: undefined; }; readOnly: { type: PropType<CheckboxInput["readOnly"]>; default: undefined; }; name: { type: PropType<string | undefined>; default: undefined; }; value: { type: PropType<string | undefined>; default: undefined; }; required: { type: PropType<boolean | undefined>; default: undefined; }; /** Accessible-name escape hatch [baseline #17, inherited] — see `CheckboxLabel` for the primary path. */ ariaLabel: { type: PropType<string | undefined>; default: undefined; }; /** * Seeds the part scope INSTEAD of the generated id when supplied * [baseline #10, inherited]: `<CheckboxRoot id="terms">` yields * deterministic `hidden-input`/`label`/`description` ids derived from * `"terms"`. Feeds `useCheckbox`'s `id` option — see that composable's * doc comment. Declared as a real prop (not left to fall through to * `attrs`) so it configures the scope seed instead of landing on the * rendered `<label>` as a plain HTML `id` attribute. */ id: { type: PropType<string | undefined>; default: undefined; };}>> & Readonly<{ onCheckedChange?: ((_detail: CheckboxChangeDetail) => any) | undefined;}>, { asChild: boolean; checked: import("@grassroot/ui-machines/checkbox").CheckboxCheckedValue | undefined; defaultChecked: import("@grassroot/ui-machines/checkbox").CheckboxCheckedValue | undefined; disabled: boolean | undefined; readOnly: boolean | undefined; name: string | undefined; value: string | undefined; required: boolean | undefined; ariaLabel: string | undefined; id: string | undefined;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;CheckboxRootProvider
valueexport declare const CheckboxRootProvider: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; }; /** An existing `useCheckbox()` result (advanced composition) — already fully configured. */ value: { type: PropType<UseCheckboxResult>; required: true; };}>, () => VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; }; /** An existing `useCheckbox()` result (advanced composition) — already fully configured. */ value: { type: PropType<UseCheckboxResult>; required: true; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;useCheckbox
functiondeclare function useCheckbox(input: CheckboxInput | (() => CheckboxInput), options?: UseCheckboxOptions | (() => UseCheckboxOptions)): UseCheckboxResult;inputCheckboxInput | (() => CheckboxInput)optionsUseCheckboxOptions | (() => UseCheckboxOptions)returnUseCheckboxResult- Name
input- Kind
- parameter
- Type
CheckboxInput | (() => CheckboxInput)- Requirement
- required
- Name
options- Kind
- parameter
- Type
UseCheckboxOptions | (() => UseCheckboxOptions)- Requirement
- optional
- Name
return- Kind
- return value
- Type
UseCheckboxResult- Requirement
- n/a
useCheckboxContext
functiondeclare function useCheckboxContext(partName: string): CheckboxContextValue;partNamestringreturnCheckboxContextValue- Name
partName- Kind
- parameter
- Type
string- Requirement
- required
- Name
return- Kind
- return value
- Type
CheckboxContextValue- Requirement
- n/a
UseCheckboxOptions
interfaceinterface UseCheckboxOptions { readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; readonly onChange?: (event: Event) => void; readonly name?: string; readonly value?: string; readonly required?: boolean; readonly ariaLabel?: string; readonly id?: string;}ariaLabelstringidstringnamestringonChange(event: Event) => voidonCheckedChange(detail: CheckboxChangeDetail) => voidrequiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Name
id- Kind
- property
- Type
string- Requirement
- optional
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Name
onChange- Kind
- property
- Type
(event: Event) => void- Requirement
- optional
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Name
value- Kind
- property
- Type
string- Requirement
- optional
UseCheckboxResult
interfaceinterface UseCheckboxResult { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope; readonly snapshot: ShallowRef<CheckboxSnapshot>;}connectorCheckboxApiscopePartScopeserviceCheckboxServicesnapshotShallowRef<CheckboxSnapshot>- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
- Name
snapshot- Kind
- property
- Type
ShallowRef<CheckboxSnapshot>- Requirement
- required
@grassroot/ui-headless-angular/checkbox
Angular adapter
CHECKBOX_STORE
valueexport declare const CHECKBOX_STORE: InjectionToken<CheckboxStore>;CheckboxChangeDetail
interfaceexport interface CheckboxChangeDetail { readonly checked: boolean; readonly reason: CheckboxReason;}checkedbooleanreasonCheckboxReason- Name
checked- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
CheckboxReason- Requirement
- required
CheckboxConnectOptionsPatch
interfaceexport interface CheckboxConnectOptionsPatch { readonly name?: string; readonly value?: string; readonly required?: boolean; readonly ariaLabel?: string;}ariaLabelstringnamestringrequiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Name
value- Kind
- property
- Type
string- Requirement
- optional
CheckboxStore
interfaceexport interface CheckboxStore { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope; /** * Bumped on every committed machine update — AND, defensively, once by * `GrCheckboxLabel`/`GrCheckboxDescription` right after they self-register * (see `parts.ts`). Effects that read the connector's prop bags must read * this signal first — inside the same `effect()` — so Angular's * reactivity re-runs the effect on every committed change, AND so * `GrCheckboxHiddenInput`'s `aria-labelledby`/`aria-describedby` (resolved * from `scope.get("label"/"description")` at getter-call time) settle * once those parts exist. `GrCheckboxHiddenInput`'s effect also calls * `connector.syncNativeState()` on every one of these bumps — the * `indeterminate` DOM property has no attribute form and cannot travel in * a prop bag, so the render loop, not just the change handler, must own * it (`checkbox.spec.md`'s "Connector differences"). */ readonly version: WritableSignal<number>; /** Starts the underlying service and runs `activateCheckbox` (idempotent) — call from the browser only. */ start(): void; /** Stops the underlying service and releases `activateCheckbox`'s cleanup (idempotent). */ stop(): void; /** Forwards a new committed input to the machine (no-op on the very first call). */ sync(input: CheckboxInput): void; /** * Updates the connector's live `name`/`value`/`required`/`ariaLabel` * reading (see `use-checkbox.ts`'s header comment for why this exists * instead of a one-shot constructor-time value). */ setConnectOptions(next: CheckboxConnectOptionsPatch): void;}connectorCheckboxApiscopePartScopeserviceCheckboxServicesetConnectOptions(next: CheckboxConnectOptionsPatch) => voidstart() => voidstop() => voidsync(input: CheckboxInput) => voidversionWritableSignal<number>- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Description
- —
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
- Description
- —
- Name
setConnectOptions- Kind
- method
- Type
(next: CheckboxConnectOptionsPatch) => void- Requirement
- required
- Description
- Updates the connector's live `name`/`value`/`required`/`ariaLabel` reading (see `use-checkbox.ts`'s header comment for why this exists instead of a one-shot constructor-time value).
- Name
start- Kind
- method
- Type
() => void- Requirement
- required
- Description
- Starts the underlying service and runs `activateCheckbox` (idempotent) — call from the browser only.
- Name
stop- Kind
- method
- Type
() => void- Requirement
- required
- Description
- Stops the underlying service and releases `activateCheckbox`'s cleanup (idempotent).
- Name
sync- Kind
- method
- Type
(input: CheckboxInput) => void- Requirement
- required
- Description
- Forwards a new committed input to the machine (no-op on the very first call).
- Name
version- Kind
- property
- Type
WritableSignal<number>- Requirement
- required
- Description
- Bumped on every committed machine update — AND, defensively, once by `GrCheckboxLabel`/`GrCheckboxDescription` right after they self-register (see `parts.ts`). Effects that read the connector's prop bags must read this signal first — inside the same `effect()` — so Angular's reactivity re-runs the effect on every committed change, AND so `GrCheckboxHiddenInput`'s `aria-labelledby`/`aria-describedby` (resolved from `scope.get("label"/"description")` at getter-call time) settle once those parts exist. `GrCheckboxHiddenInput`'s effect also calls `connector.syncNativeState()` on every one of these bumps — the `indeterminate` DOM property has no attribute form and cannot travel in a prop bag, so the render loop, not just the change handler, must own it (`checkbox.spec.md`'s "Connector differences").
createCheckboxStore
functionexport declare function createCheckboxStore(initialInput: CheckboxInput, options?: CreateCheckboxStoreOptions): CheckboxStore;initialInputCheckboxInputoptionsCreateCheckboxStoreOptionsreturnCheckboxStore- Name
initialInput- Kind
- parameter
- Type
CheckboxInput- Requirement
- required
- Name
options- Kind
- parameter
- Type
CreateCheckboxStoreOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
CheckboxStore- Requirement
- n/a
CreateCheckboxStoreOptions
interfaceexport interface CreateCheckboxStoreOptions { readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; readonly onChange?: (event: unknown) => void; readonly onCommit?: () => void; readonly id?: string;}idstringonChange(event: unknown) => voidonCheckedChange(detail: CheckboxChangeDetail) => voidonCommit() => void- Name
id- Kind
- property
- Type
string- Requirement
- optional
- Name
onChange- Kind
- property
- Type
(event: unknown) => void- Requirement
- optional
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
- Name
onCommit- Kind
- property
- Type
() => void- Requirement
- optional
GR_CHECKBOX_DECLARATIONS
valueexport declare const GR_CHECKBOX_DECLARATIONS: readonly [typeof GrCheckboxRoot, typeof GrCheckboxRootProvider, typeof GrCheckboxHiddenInput, typeof GrCheckboxControl, typeof GrCheckboxIndicator, typeof GrCheckboxLabel, typeof GrCheckboxDescription];GrCheckboxControl
classexport declare class GrCheckboxControl implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrCheckboxControl, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrCheckboxControl, "[grCheckboxControl]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrCheckboxControl, "[grCheckboxControl]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrCheckboxControl, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrCheckboxControl, "[grCheckboxControl]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrCheckboxControl, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrCheckboxDescription
classexport declare class GrCheckboxDescription implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrCheckboxDescription, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrCheckboxDescription, "[grCheckboxDescription]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrCheckboxDescription, "[grCheckboxDescription]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrCheckboxDescription, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrCheckboxDescription, "[grCheckboxDescription]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrCheckboxDescription, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrCheckboxIndicator
classexport declare class GrCheckboxIndicator implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrCheckboxIndicator, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrCheckboxIndicator, "[grCheckboxIndicator]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrCheckboxIndicator, "[grCheckboxIndicator]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrCheckboxIndicator, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrCheckboxIndicator, "[grCheckboxIndicator]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrCheckboxIndicator, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrCheckboxLabel
classexport declare class GrCheckboxLabel implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrCheckboxLabel, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrCheckboxLabel, "[grCheckboxLabel]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrCheckboxLabel, "[grCheckboxLabel]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrCheckboxLabel, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrCheckboxLabel, "[grCheckboxLabel]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrCheckboxLabel, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrCheckboxRoot
classexport declare class GrCheckboxRoot implements OnDestroy { readonly checked: import("@angular/core").InputSignal<import("@grassroot/ui-machines/checkbox").CheckboxCheckedValue | undefined>; readonly defaultChecked: import("@angular/core").InputSignal<import("@grassroot/ui-machines/checkbox").CheckboxCheckedValue | undefined>; readonly disabled: import("@angular/core").InputSignal<boolean | undefined>; readonly readOnly: import("@angular/core").InputSignal<boolean | undefined>; readonly name: import("@angular/core").InputSignal<string | undefined>; readonly value: import("@angular/core").InputSignal<string | undefined>; readonly required: import("@angular/core").InputSignal<boolean | undefined>; /** Accessible-name escape hatch [inherited from Switch's baseline #17] — see `GrCheckboxLabel` for the primary path. */ readonly ariaLabel: import("@angular/core").InputSignal<string | undefined>; /** * Seeds the part scope INSTEAD of the generated id when supplied * [inherited from Switch's baseline #10]: `<gr-checkbox-root id="terms">` * yields deterministic `hidden-input`/`label`/`description` ids derived * from `"terms"`. Feeds `createCheckboxStore`'s `id` option * (constructor-only — see that function's doc comment); read once, in the * constructor below, unlike `name`/`value`/`required`/`ariaLabel`, which * stay live via `setConnectOptions()`. */ readonly id: import("@angular/core").InputSignal<string | undefined>; readonly checkedChange: import("@angular/core").OutputEmitterRef<CheckboxChangeDetail>; private readonly hostElementRef; private readonly injector; private readonly listeners; private lastSynced; readonly store: CheckboxStore; private rootElement; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrCheckboxRoot, never>; static ɵcmp: i0.ɵɵComponentDeclaration<GrCheckboxRoot, "gr-checkbox-root", never, { "checked": { "alias": "checked"; "required": false; "isSignal": true; }; "defaultChecked": { "alias": "defaultChecked"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "readOnly": { "alias": "readOnly"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "id": { "alias": "id"; "required": false; "isSignal": true; }; }, { "checkedChange": "checkedChange"; }, never, ["*"], true, never>;}ariaLabelimport("@angular/core").InputSignal<string | undefined>checkedimport("@angular/core").InputSignal<import("@grassroot/ui-machines/checkbox").CheckboxCheckedValue | undefined>checkedChangeimport("@angular/core").OutputEmitterRef<CheckboxChangeDetail>defaultCheckedimport("@angular/core").InputSignal<import("@grassroot/ui-machines/checkbox").CheckboxCheckedValue | undefined>disabledimport("@angular/core").InputSignal<boolean | undefined>hostElementRefanyidimport("@angular/core").InputSignal<string | undefined>injectoranylastSyncedanylistenersanynameimport("@angular/core").InputSignal<string | undefined>ngOnDestroy() => voidɵcmpi0.ɵɵComponentDeclaration<GrCheckboxRoot, "gr-checkbox-root", never, { "checked": { "alias": "checked"; "required": false; "isSignal": true; }; "defaultChecked": { "alias": "defaultChecked"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "readOnly": { "alias": "readOnly"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "id": { "alias": "id"; "required": false; "isSignal": true; }; }, { "checkedChange": "checkedChange"; }, never, ["*"], true, never>ɵfaci0.ɵɵFactoryDeclaration<GrCheckboxRoot, never>- Name
ariaLabel- Kind
- property
- Type
import("@angular/core").InputSignal<string | undefined>- Requirement
- required
- Description
- Accessible-name escape hatch [inherited from Switch's baseline #17] — see `GrCheckboxLabel` for the primary path.
- Name
checked- Kind
- property
- Type
import("@angular/core").InputSignal<import("@grassroot/ui-machines/checkbox").CheckboxCheckedValue | undefined>- Requirement
- required
- Description
- —
- Name
checkedChange- Kind
- property
- Type
import("@angular/core").OutputEmitterRef<CheckboxChangeDetail>- Requirement
- required
- Description
- —
- Name
defaultChecked- Kind
- property
- Type
import("@angular/core").InputSignal<import("@grassroot/ui-machines/checkbox").CheckboxCheckedValue | undefined>- Requirement
- required
- Description
- —
- Name
disabled- Kind
- property
- Type
import("@angular/core").InputSignal<boolean | undefined>- Requirement
- required
- Description
- —
- Name
hostElementRef- Kind
- property
- Type
any- Requirement
- required
- Description
- —
- Name
id- Kind
- property
- Type
import("@angular/core").InputSignal<string | undefined>- Requirement
- required
- Description
- Seeds the part scope INSTEAD of the generated id when supplied [inherited from Switch's baseline #10]: `<gr-checkbox-root id="terms">` yields deterministic `hidden-input`/`label`/`description` ids derived from `"terms"`. Feeds `createCheckboxStore`'s `id` option (constructor-only — see that function's doc comment); read once, in the constructor below, unlike `name`/`value`/`required`/`ariaLabel`, which stay live via `setConnectOptions()`.
- Name
injector- Kind
- property
- Type
any- Requirement
- required
- Description
- —
- Name
lastSynced- Kind
- property
- Type
any- Requirement
- required
- Description
- —
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Description
- —
- Name
name- Kind
- property
- Type
import("@angular/core").InputSignal<string | undefined>- Requirement
- required
- Description
- —
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Description
- —
- Name
ɵcmp- Kind
- property
- Type
i0.ɵɵComponentDeclaration<GrCheckboxRoot, "gr-checkbox-root", never, { "checked": { "alias": "checked"; "required": false; "isSignal": true; }; "defaultChecked": { "alias": "defaultChecked"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "readOnly": { "alias": "readOnly"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "id": { "alias": "id"; "required": false; "isSignal": true; }; }, { "checkedChange": "checkedChange"; }, never, ["*"], true, never>- Requirement
- required
- Description
- —
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrCheckboxRoot, never>- Requirement
- required
- Description
- —
- Name
readOnly- Kind
- property
- Type
import("@angular/core").InputSignal<boolean | undefined>- Requirement
- required
- Description
- —
- Name
required- Kind
- property
- Type
import("@angular/core").InputSignal<boolean | undefined>- Requirement
- required
- Description
- —
- Name
rootElement- Kind
- property
- Type
any- Requirement
- required
- Description
- —
- Name
store- Kind
- property
- Type
CheckboxStore- Requirement
- required
- Description
- —
- Name
value- Kind
- property
- Type
import("@angular/core").InputSignal<string | undefined>- Requirement
- required
- Description
- —
GrCheckboxRootProvider
classexport declare class GrCheckboxRootProvider implements OnDestroy { private readonly hostElementRef; private readonly injector; private readonly listeners; readonly store: CheckboxStore; private rootElement; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrCheckboxRootProvider, never>; static ɵcmp: i0.ɵɵComponentDeclaration<GrCheckboxRootProvider, "gr-checkbox-root-provider", never, {}, {}, never, ["*"], true, never>;}hostElementRefanyinjectoranylistenersanyngOnDestroy() => voidɵcmpi0.ɵɵComponentDeclaration<GrCheckboxRootProvider, "gr-checkbox-root-provider", never, {}, {}, never, ["*"], true, never>ɵfaci0.ɵɵFactoryDeclaration<GrCheckboxRootProvider, never>rootElementanystoreCheckboxStore- Name
hostElementRef- Kind
- property
- Type
any- Requirement
- required
- Name
injector- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵcmp- Kind
- property
- Type
i0.ɵɵComponentDeclaration<GrCheckboxRootProvider, "gr-checkbox-root-provider", never, {}, {}, never, ["*"], true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrCheckboxRootProvider, never>- Requirement
- required
- Name
rootElement- Kind
- property
- Type
any- Requirement
- required
- Name
store- Kind
- property
- Type
CheckboxStore- Requirement
- required
provideCheckboxStore
functionexport declare function provideCheckboxStore(initialInput?: CheckboxInput, options?: CreateCheckboxStoreOptions): Provider;initialInputCheckboxInputoptionsCreateCheckboxStoreOptionsreturnProvider- Name
initialInput- Kind
- parameter
- Type
CheckboxInput- Requirement
- optional
- Name
options- Kind
- parameter
- Type
CreateCheckboxStoreOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
Provider- Requirement
- n/a
@grassroot/ui-headless-svelte/checkbox
Svelte adapter
CheckboxChangeDetail
interfaceinterface CheckboxChangeDetail { readonly checked: boolean; readonly reason: CheckboxReason;}checkedbooleanreasonCheckboxReason- Name
checked- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
CheckboxReason- Requirement
- required
CheckboxCheckedValue
typetype CheckboxCheckedValue = boolean | "indeterminate";CheckboxCommand
typetype CheckboxCommand = CommandObject & { readonly type: "CHECKED_CHANGE_REQUEST"; readonly checked: boolean; readonly reason: CheckboxReason;};checkedbooleanreasonCheckboxReasontypestring- Name
checked- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
CheckboxReason- Requirement
- required
- Name
type- Kind
- property
- Type
string- Requirement
- required
CheckboxContext
typetype CheckboxContext = { readonly mode: BindingMode;};modeBindingMode- Name
mode- Kind
- property
- Type
BindingMode- Requirement
- required
CheckboxContextValue
interfaceexport interface CheckboxContextValue { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope; /** * Bumped on every committed machine update. Parts must read this * (`ctx.version()`) *inside* the `$derived` that computes their prop * bag — not once at setup — so Svelte's fine-grained reactivity tracks * the dependency and recomputes on every committed change (mirrors the * Switch adapter's equivalent staleness fix). */ readonly version: () => number;}connectorCheckboxApiscopePartScopeserviceCheckboxServiceversion() => number- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Description
- —
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
- Description
- —
- Name
version- Kind
- property
- Type
() => number- Requirement
- required
- Description
- Bumped on every committed machine update. Parts must read this (`ctx.version()`) *inside* the `$derived` that computes their prop bag — not once at setup — so Svelte's fine-grained reactivity tracks the dependency and recomputes on every committed change (mirrors the Switch adapter's equivalent staleness fix).
CheckboxControl
valueexport declare const CheckboxControl: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
CheckboxDescription
valueexport declare const CheckboxDescription: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
CheckboxEvent
typetype CheckboxEvent = { readonly type: "TOGGLE"; readonly reason: CheckboxReason;} | { readonly type: "RESET";};CheckboxIndicator
valueexport declare const CheckboxIndicator: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
CheckboxInput
typetype CheckboxInput = { readonly checked?: CheckboxCheckedValue; readonly defaultChecked?: CheckboxCheckedValue; readonly disabled?: boolean; readonly readOnly?: boolean;};checkedCheckboxCheckedValuedefaultCheckedCheckboxCheckedValuedisabledbooleanreadOnlyboolean- Name
checked- Kind
- property
- Type
CheckboxCheckedValue- Requirement
- optional
- Name
defaultChecked- Kind
- property
- Type
CheckboxCheckedValue- Requirement
- optional
- Name
disabled- Kind
- property
- Type
boolean- Requirement
- optional
- Name
readOnly- Kind
- property
- Type
boolean- Requirement
- optional
CheckboxLabel
valueexport declare const CheckboxLabel: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
CheckboxReason
typetype CheckboxReason = "pointer" | "keyboard" | "programmatic";CheckboxRoot
valueexport declare const CheckboxRoot: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
CheckboxRootProvider
valueexport declare const CheckboxRootProvider: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
CheckboxSnapshot
typetype CheckboxSnapshot = Snapshot<CheckboxValue, CheckboxContext>;CheckboxValue
typetype CheckboxValue = "unchecked" | "checked" | "indeterminate";createCheckbox
functionexport declare function createCheckbox(inputGetter: () => CheckboxInput, optionsGetter?: () => UseCheckboxOptions): UseCheckboxResult;inputGetter() => CheckboxInputoptionsGetter() => UseCheckboxOptionsreturnUseCheckboxResult- Name
inputGetter- Kind
- parameter
- Type
() => CheckboxInput- Requirement
- required
- Name
optionsGetter- Kind
- parameter
- Type
() => UseCheckboxOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
UseCheckboxResult- Requirement
- n/a
useCheckboxContext
functionexport declare function useCheckboxContext(partName: string): CheckboxContextValue;partNamestringreturnCheckboxContextValue- Name
partName- Kind
- parameter
- Type
string- Requirement
- required
- Name
return- Kind
- return value
- Type
CheckboxContextValue- Requirement
- n/a
UseCheckboxOptions
interfaceexport interface UseCheckboxOptions { readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; readonly onChange?: (event: Event) => void; readonly name?: string; readonly value?: string; readonly required?: boolean; readonly ariaLabel?: string; readonly id?: string;}ariaLabelstringidstringnamestringonChange(event: Event) => voidonCheckedChange(detail: CheckboxChangeDetail) => voidrequiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Name
id- Kind
- property
- Type
string- Requirement
- optional
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Name
onChange- Kind
- property
- Type
(event: Event) => void- Requirement
- optional
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Name
value- Kind
- property
- Type
string- Requirement
- optional
UseCheckboxResult
interfaceexport interface UseCheckboxResult { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope; readonly version: () => number;}connectorCheckboxApiscopePartScopeserviceCheckboxServiceversion() => number- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
- Name
version- Kind
- property
- Type
() => number- Requirement
- required
@grassroot/ui-headless-solid/checkbox
Solid adapter
CheckboxConnectConfig
interfaceexport interface CheckboxConnectConfig { readonly name?: string; readonly value?: string; readonly required?: boolean; readonly ariaLabel?: string;}ariaLabelstringnamestringrequiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Name
value- Kind
- property
- Type
string- Requirement
- optional
CheckboxContext
valueexport declare const CheckboxContext: import("solid-js").Context<CheckboxContextValue | undefined>;CheckboxContextValue
interfaceexport interface CheckboxContextValue { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope; /** * Bumped on every committed machine update. Parts must call this * accessor *inside* the JSX/spread thunk that reads the connector's prop * bags — not once at setup — so Solid's fine-grained reactivity tracks * the dependency and re-runs on every committed change. */ readonly snapshot: Accessor<CheckboxSnapshot>; /** * Solid-adapter-internal: `CheckboxHiddenInput` reads this alongside * `snapshot()` to resettle `aria-labelledby`/`aria-describedby` once * `CheckboxLabel`/`CheckboxDescription` (if rendered) have registered, * and to pick up `name`/`value`/`required`/`ariaLabel` changes — see * `use-checkbox.ts`'s `relationshipTick` header comment. */ readonly relationshipTick: Accessor<number>;}connectorCheckboxApirelationshipTickAccessor<number>scopePartScopeserviceCheckboxServicesnapshotAccessor<CheckboxSnapshot>- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Description
- —
- Name
relationshipTick- Kind
- property
- Type
Accessor<number>- Requirement
- required
- Description
- Solid-adapter-internal: `CheckboxHiddenInput` reads this alongside `snapshot()` to resettle `aria-labelledby`/`aria-describedby` once `CheckboxLabel`/`CheckboxDescription` (if rendered) have registered, and to pick up `name`/`value`/`required`/`ariaLabel` changes — see `use-checkbox.ts`'s `relationshipTick` header comment.
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
- Description
- —
- Name
snapshot- Kind
- property
- Type
Accessor<CheckboxSnapshot>- Requirement
- required
- Description
- Bumped on every committed machine update. Parts must call this accessor *inside* the JSX/spread thunk that reads the connector's prop bags — not once at setup — so Solid's fine-grained reactivity tracks the dependency and re-runs on every committed change.
CheckboxControl
valueexport declare const CheckboxControl: (props: CheckboxPartProps) => JSX.Element;propsCheckboxPartPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
CheckboxPartProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
CheckboxDescription
valueexport declare const CheckboxDescription: (props: CheckboxPartProps) => JSX.Element;propsCheckboxPartPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
CheckboxPartProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
CheckboxIndicator
valueexport declare const CheckboxIndicator: (props: CheckboxPartProps) => JSX.Element;propsCheckboxPartPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
CheckboxPartProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
CheckboxLabel
valueexport declare const CheckboxLabel: (props: CheckboxPartProps) => JSX.Element;propsCheckboxPartPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
CheckboxPartProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
CheckboxPartProps
interfaceexport interface CheckboxPartProps extends JSX.HTMLAttributes<HTMLSpanElement> {}CheckboxRoot
functionexport declare function CheckboxRoot(props: CheckboxRootProps): JSX.Element;propsCheckboxRootPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
CheckboxRootProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
CheckboxRootProps
interfaceexport interface CheckboxRootProps extends Omit<JSX.LabelHTMLAttributes<HTMLLabelElement>, "onChange"> { readonly checked?: CheckboxInput["checked"]; readonly defaultChecked?: CheckboxInput["defaultChecked"]; readonly disabled?: CheckboxInput["disabled"]; readonly readOnly?: CheckboxInput["readOnly"]; readonly name?: string; readonly value?: string; readonly required?: boolean; /** Accessible-name escape hatch [baseline #17, inherited] — see `CheckboxLabel` for the primary path. */ readonly ariaLabel?: string; /** * Seeds the part scope INSTEAD of the generated id when supplied * [baseline #10, inherited]: `<CheckboxRoot id="terms">` yields * deterministic `hidden-input`/`label`/`description` ids derived from * `"terms"`. Feeds `useCheckbox`'s `id` option — see that primitive's doc * comment. Intercepted here rather than left in the native passthrough, * so it configures the scope seed instead of landing on the rendered * `<label>` as a plain HTML `id` attribute. */ readonly id?: string; readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; readonly onChange?: (event: Event) => void; readonly children?: JSX.Element;}ariaLabelstringcheckedCheckboxInput["checked"]childrenJSX.ElementdefaultCheckedCheckboxInput["defaultChecked"]disabledCheckboxInput["disabled"]idstringnamestringonChange(event: Event) => voidonCheckedChange(detail: CheckboxChangeDetail) => voidreadOnlyCheckboxInput["readOnly"]requiredbooleanvaluestring- Name
ariaLabel- Kind
- property
- Type
string- Requirement
- optional
- Description
- Accessible-name escape hatch [baseline #17, inherited] — see `CheckboxLabel` for the primary path.
- Name
checked- Kind
- property
- Type
CheckboxInput["checked"]- Requirement
- optional
- Description
- —
- Name
children- Kind
- property
- Type
JSX.Element- Requirement
- optional
- Description
- —
- Name
defaultChecked- Kind
- property
- Type
CheckboxInput["defaultChecked"]- Requirement
- optional
- Description
- —
- Name
disabled- Kind
- property
- Type
CheckboxInput["disabled"]- Requirement
- optional
- Description
- —
- Name
id- Kind
- property
- Type
string- Requirement
- optional
- Description
- Seeds the part scope INSTEAD of the generated id when supplied [baseline #10, inherited]: `<CheckboxRoot id="terms">` yields deterministic `hidden-input`/`label`/`description` ids derived from `"terms"`. Feeds `useCheckbox`'s `id` option — see that primitive's doc comment. Intercepted here rather than left in the native passthrough, so it configures the scope seed instead of landing on the rendered `<label>` as a plain HTML `id` attribute.
- Name
name- Kind
- property
- Type
string- Requirement
- optional
- Description
- —
- Name
onChange- Kind
- property
- Type
(event: Event) => void- Requirement
- optional
- Description
- —
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
- Description
- —
- Name
readOnly- Kind
- property
- Type
CheckboxInput["readOnly"]- Requirement
- optional
- Description
- —
- Name
required- Kind
- property
- Type
boolean- Requirement
- optional
- Description
- —
- Name
value- Kind
- property
- Type
string- Requirement
- optional
- Description
- —
CheckboxRootProvider
functionexport declare function CheckboxRootProvider(props: CheckboxRootProviderProps): JSX.Element;propsCheckboxRootProviderPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
CheckboxRootProviderProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
CheckboxRootProviderProps
interfaceexport interface CheckboxRootProviderProps extends Omit<JSX.LabelHTMLAttributes<HTMLLabelElement>, "onChange"> { /** An existing `useCheckbox()` result (advanced composition) — already fully configured. */ readonly value: UseCheckboxResult; readonly children?: JSX.Element;}childrenJSX.ElementvalueUseCheckboxResult- Name
children- Kind
- property
- Type
JSX.Element- Requirement
- optional
- Description
- —
- Name
value- Kind
- property
- Type
UseCheckboxResult- Requirement
- required
- Description
- An existing `useCheckbox()` result (advanced composition) — already fully configured.
useCheckbox
functionexport declare function useCheckbox(input: Accessor<CheckboxInput>, connectConfig: Accessor<CheckboxConnectConfig>, options?: UseCheckboxOptions): UseCheckboxResult;inputAccessor<CheckboxInput>connectConfigAccessor<CheckboxConnectConfig>optionsUseCheckboxOptionsreturnUseCheckboxResult- Name
input- Kind
- parameter
- Type
Accessor<CheckboxInput>- Requirement
- required
- Name
connectConfig- Kind
- parameter
- Type
Accessor<CheckboxConnectConfig>- Requirement
- required
- Name
options- Kind
- parameter
- Type
UseCheckboxOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
UseCheckboxResult- Requirement
- n/a
useCheckboxContext
functionexport declare function useCheckboxContext(partName: string): CheckboxContextValue;partNamestringreturnCheckboxContextValue- Name
partName- Kind
- parameter
- Type
string- Requirement
- required
- Name
return- Kind
- return value
- Type
CheckboxContextValue- Requirement
- n/a
UseCheckboxOptions
interfaceexport interface UseCheckboxOptions { readonly onCheckedChange?: (detail: CheckboxChangeDetail) => void; readonly onChange?: (event: Event) => void; readonly id?: string;}idstringonChange(event: Event) => voidonCheckedChange(detail: CheckboxChangeDetail) => void- Name
id- Kind
- property
- Type
string- Requirement
- optional
- Name
onChange- Kind
- property
- Type
(event: Event) => void- Requirement
- optional
- Name
onCheckedChange- Kind
- property
- Type
(detail: CheckboxChangeDetail) => void- Requirement
- optional
UseCheckboxResult
interfaceexport interface UseCheckboxResult { readonly service: CheckboxService; readonly connector: CheckboxApi; readonly scope: PartScope; readonly snapshot: Accessor<CheckboxSnapshot>; /** Compatibility accessor; registration invalidation is owned by the shared factory snapshot. */ readonly relationshipTick: Accessor<number>;}connectorCheckboxApirelationshipTickAccessor<number>scopePartScopeserviceCheckboxServicesnapshotAccessor<CheckboxSnapshot>- Name
connector- Kind
- property
- Type
CheckboxApi- Requirement
- required
- Description
- —
- Name
relationshipTick- Kind
- property
- Type
Accessor<number>- Requirement
- required
- Description
- Compatibility accessor; registration invalidation is owned by the shared factory snapshot.
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
CheckboxService- Requirement
- required
- Description
- —
- Name
snapshot- Kind
- property
- Type
Accessor<CheckboxSnapshot>- Requirement
- required
- Description
- —