Topic: form-outline with fixed active input?
davesmacer pro premium priority asked a year ago
I was wondering if there's a way to have the label always active for form-label in form-outline ?
I'm using in js:
$('.form-outline .form-control').on('blur', function () {
var label = $(this).siblings('.form-label');
if (!label.hasClass('active')) {
label.addClass('active');
}
if (!$(this).hasClass('active')) {
$(this).addClass('active');
}
});
but maybe there's an already built-in way that I can't seem to find?
Kamila Pieńkowska staff answered a year ago
There is no built-in way.
But you can do it following this code snippet: https://mdbootstrap.com/snippets/standard/kpienkowska/5627382
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- User: Pro
- Premium support: Yes
- Technology: MDB Standard
- MDB Version: MDB5 6.4.1
- Device: Laptop
- Browser: Chrome
- OS: Windows
- Provided sample code: No
- Provided link: No