Skip to content
@ng-doc/app / Class

NgDocBooleanControlComponent

The playground control of boolean inputs: a checkbox labelled with the input name.

Decorators
@Component
Selectors
ng-doc-boolean-control
Extends
DIControl<boolean | undefined, boolean | undefined>
Implements
NgDocTypeControl<boolean | undefined>
DeclarationTypeScript
@Component({ … })
export class NgDocBooleanControlComponent
  extends DIControl<boolean | undefined>
  implements NgDocTypeControl<boolean | undefined> { … }

Members

Constructor

1
()
—

Properties

13
change: (value: T | null) => void
protected inherited from DIControlValueAccessor
—
changeDetectorRef: ChangeDetectorRef
protectedreadonly inherited from DIControlValueAccessor
—
config?: DIControlConfig<TModel, TChildModel> | undefined
protectedreadonly inherited from DIControl
—
default: InputSignal<boolean | undefined>
readonly input() implements NgDocTypeControl

Default value of the input; undefined leaves the component's own default.

description: InputSignal<string>
readonly input() implements NgDocTypeControl

Description of the input, shown in a tooltip.

disabledValue: WritableSignal<boolean>
protectedreadonly inherited from DIControlValueAccessor
—
elementRef: ElementRef<HTMLElement>
protectedreadonly inherited from DIControlValueAccessor
—
incomingUpdate?: ((value: T | null) => void) | undefined
protectedreadonly inherited from DIControlValueAccessor
—
model: Signal<T | null>
protectedreadonly inherited from DIControlValueAccessor
—
name: InputSignal<string>
readonly input() implements NgDocTypeControl

Name of the input.

ngControl: NgControl | null
protectedreadonly inherited from DIControlValueAccessor
—
renderer: Renderer2
protectedreadonly inherited from DIControlValueAccessor
—
touch: () => void
protected inherited from DIControl

Function that should be used to make control touched.

Accessors

4
get defaultValue: boolean | undefined

The value an unchecked box stands for.

get disabled: boolean
inherited from DIControlValueAccessor

Returns true if the control is disabled.

set disabled: boolean
inherited from DIControlValueAccessor
—
get hasValue: boolean
inherited from DIControlValueAccessor

Returns true if the control is not empty.

Methods

4
(): void
inherited from DIControl
—
(…): void
inherited from DIControl

Method is called by the forms API.

(…): void
overrides DIControl

Updates the model of the current control. This is the main method that should be used to update the model.

(…): void
inherited from DIControl

Method is called by the forms API to write to the view when programmatic changes from model to view are requested.

Symbol
Kind
Class
Decorators
@Component
Selectors
ng-doc-boolean-control
Extends
DIControl<boolean | undefined, boolean | undefined>
Implements
NgDocTypeControl<boolean | undefined>
Scope
@ng-doc/app
Edit this page