Topic: Broken dynamic input
Damian Gemza staff answered 6 years ago
Dear Mobtex,
You're missing mdbInputDirective on input element in your code. This directive is used to move label to the top of the input element when it got some value.
Your code should look like below:
<div class="col-12" *ngFor="let item of items; let i = index">
<div class="md-form form-group">
<input type="text" class="form-control" value="{{item.value}}" mdbInputDirective id="{{item}}-i">
<label for="{{item}}-i">{{item.label}}</label>
</div>
</div>
Best Regards,
Damian
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Resolved
- User: Pro
- Premium support: No
- Technology: MDB Angular
- MDB Version: 6.2.3
- Device: Browser
- Browser: Firefox
- OS: Mac
- Provided sample code: No
- Provided link: No