Skip to content

Commit f909bb1

Browse files
AlexElinmmalerba
authored andcommitted
docs: use BooleanInput in examples for custom control (#21913)
(cherry picked from commit ddb206e)
1 parent e1dd9f3 commit f909bb1

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/components-examples/material-experimental/mdc-form-field/mdc-form-field-custom-control/form-field-custom-control-example.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import {FocusMonitor} from '@angular/cdk/a11y';
2-
import {coerceBooleanProperty} from '@angular/cdk/coercion';
2+
import {BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';
33
import {Component, ElementRef, Inject, Input, OnDestroy, Optional, Self} from '@angular/core';
44
import {ControlValueAccessor, FormBuilder, FormGroup, NgControl, Validators} from '@angular/forms';
55
import {MatFormField, MatFormFieldControl} from '@angular/material-experimental/mdc-form-field';
@@ -153,6 +153,6 @@ export class MyTelInput implements ControlValueAccessor, MatFormFieldControl<MyT
153153
this.onChange(this.value);
154154
}
155155

156-
static ngAcceptInputType_disabled: boolean | string | null | undefined;
157-
static ngAcceptInputType_required: boolean | string | null | undefined;
156+
static ngAcceptInputType_disabled: BooleanInput;
157+
static ngAcceptInputType_required: BooleanInput;
158158
}

src/components-examples/material/form-field/form-field-custom-control/form-field-custom-control-example.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import {FocusMonitor} from '@angular/cdk/a11y';
2-
import {coerceBooleanProperty} from '@angular/cdk/coercion';
2+
import {BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';
33
import {
44
Component,
55
ElementRef,
@@ -224,6 +224,6 @@ export class MyTelInput
224224
this.onChange(this.value);
225225
}
226226

227-
static ngAcceptInputType_disabled: boolean | string | null | undefined;
228-
static ngAcceptInputType_required: boolean | string | null | undefined;
227+
static ngAcceptInputType_disabled: BooleanInput;
228+
static ngAcceptInputType_required: BooleanInput;
229229
}

0 commit comments

Comments
 (0)