admin管理员组文章数量:1026182
On the Angular Material stepper there is a stepControl
property on each mat-step
that contains a form. What does the stepControl
property do?
<mat-step [stepControl]="registrationForm">
It seems like the function would be to disallow moving to the next step if the form is not valid, but just wanted to double check.
On the Angular Material stepper there is a stepControl
property on each mat-step
that contains a form. What does the stepControl
property do?
<mat-step [stepControl]="registrationForm">
It seems like the function would be to disallow moving to the next step if the form is not valid, but just wanted to double check.
Share Improve this question asked Feb 10, 2022 at 14:18 OleOle 47.6k70 gold badges238 silver badges447 bronze badges1 Answer
Reset to default 5Correct, however, if any form validation is not pulsory you can use the isOptional
property to ignore that form's validity and proceed to the next step.
<mat-step [stepControl]="registrationForm" [optional]="isOptional">
Similarly if you are not using Reactive Forms you can use another property called pleted
to allow the user to proceed to the next step only if pleted is true
<mat-step [pleted]="isCompleted">
On the Angular Material stepper there is a stepControl
property on each mat-step
that contains a form. What does the stepControl
property do?
<mat-step [stepControl]="registrationForm">
It seems like the function would be to disallow moving to the next step if the form is not valid, but just wanted to double check.
On the Angular Material stepper there is a stepControl
property on each mat-step
that contains a form. What does the stepControl
property do?
<mat-step [stepControl]="registrationForm">
It seems like the function would be to disallow moving to the next step if the form is not valid, but just wanted to double check.
Share Improve this question asked Feb 10, 2022 at 14:18 OleOle 47.6k70 gold badges238 silver badges447 bronze badges1 Answer
Reset to default 5Correct, however, if any form validation is not pulsory you can use the isOptional
property to ignore that form's validity and proceed to the next step.
<mat-step [stepControl]="registrationForm" [optional]="isOptional">
Similarly if you are not using Reactive Forms you can use another property called pleted
to allow the user to proceed to the next step only if pleted is true
<mat-step [pleted]="isCompleted">
本文标签: javascriptWhat is the function of the stepControl property on matstep directivesStack Overflow
版权声明:本文标题:javascript - What is the function of the stepControl property on mat-step directives? - Stack Overflow 内容由热心网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://it.en369.cn/questions/1745629834a2160093.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论