NEURALNG

PUBLIC API

Checkbox contracts

Canonical symbols are NeuralCheckbox and NeuralTriStateCheckbox. Their value models remain deliberately separate.

Binary inputs

NeuralCheckbox implements FormCheckboxControl and accepts the shared inputs below.

InputTypeDefaultPurpose
indeterminate (NeuralCheckbox)booleanfalse Presentation-only mixed state for partial collection selection.
disabledbooleanfalse Disables the native input and removes interaction.
readonlybooleanfalse Keeps focus while preventing mutation.
requiredbooleanfalse Applies native and accessible required state.
invalidbooleanfalse Exposes invalid visual and ARIA state.
pendingbooleanfalse Exposes aria-busy during validation.
touchedbooleanfalse Forms/Field state contract.
dirtybooleanfalse Forms/Field state contract.
fluidbooleanfalse Fills the available inline width.
unstyledbooleanfalse Removes all NeuralNg visual classes.
inputIdstring'' Native input id; generated when omitted.
namestring'' Native form submission name.
inputValuestring'on' Native checked submission value.
ariaLabelstring'' Accessible name when no visible label exists.
checkboxClassstring'' Additive class on the label root.
inputClassstring'' Additive class on the native input.
labelClassstring'' Additive class on projected label text.
classesNeuralCheckboxClasses | NeuralTriStateCheckboxClasses{} Typed additive classes for structure and value states.

Tri-state inputs

NeuralTriStateCheckbox implements FormValueControl<boolean | null>, accepts every shared input, and extends classes with mixedControl.

Models

checkedModelSignal<boolean> · false

Binary value; generates checkedChange.

valueModelSignal<boolean | null> · false

Tri-state value; generates valueChange.

Events

checkedChangeboolean

Generated by the binary checked model for two-way binding.

valueChangeboolean | null

Generated by the tri-state value model for two-way binding.

stateChangeNeuralCheckboxChange

Binary user action with current and previous values.

stateChangeNeuralTriStateCheckboxChange

Tri-state user action with current and previous values.

touchvoid

Native input lost focus.

Methods

focus(options?: FocusOptions) => void

Focuses the native input.

reset() => void

Resets binary or tri-state value to false.

Typed class slots

Binary slots

rootinputcontrolcheckedControllabel

Tri-state slots

rootinputcontrolcheckedControllabelmixedControl

Public types

NeuralCheckboxChange

{ checked, previousChecked, nativeEvent }

NeuralTriStateCheckboxValue

boolean | null

NeuralTriStateCheckboxChange

{ value, previousValue, nativeEvent }

NeuralCheckboxClasses

{ root?, input?, control?, checkedControl?, label? }

NeuralTriStateCheckboxClasses

NeuralCheckboxClasses & { mixedControl? }