Closed JesusSilva closed 2 years ago
Make it disabled=true, instead. Simply remove the brackets and it works.
我也遇到了相同的问题,希望尽快修复!
plz check the angular form best practice, you can not use both ReactiveForm and TemplateForm in the same component.
plz check the angular form best practice, you can not use both ReactiveForm and TemplateForm in the same component.
我的组件中一样出现了这个问题,并没有使用模板驱动。用的响应式表单来实现的。[disabled]="true"这个属性是input元素本身的属性,也并不是模板驱动独有。angular官方也是支持这样用的
Reproduction link
https://stackblitz.com/edit/ng-zorro-antd-ivy-5mgejm?file=src/app/app.component.ts
Steps to reproduce
Add the formControlName property to a field with [disabled]="true".
What is expected?
The input is expected to be disabled when the disabled is set to true.
What is actually happening?
Currently not disabled