Hi there,
I am using the credit card mask but i keep receveing the error Cannot read property 'classList' of null every time i change the input. (check the attached image)
My implementation is exactly the same as the one from Demo provided.
Any insights?
Temporary solution!
In the FindClosest action, at line 19 of JS, add the check before: [element.parentElement !== null && ...]
Corrected line:
if(element.parentElement !== null && !element.parentElement.classList.contains('screen')) {
Maurilio Macedo wrote:
Thank you for your solution, it's work!
Hi,
In my Reactive application, every time I access the page, it shows that null error and the input field is always non-editable, even when it's dynamically enabled.
Where exactly can I find that 'FindClosest' action? Also, would it resolve the issue regarding the input field being non-editable?
Thank you.
Hello,
I've talked with Pedro Domingues, and the issue is being caused by the fact that the component was used in an empty screen, without any layout. With the layout, the problem stopped.
Nevertheless, we will add this to our backlog to improve the component.
Also, Maurilio is right: changing that line will prevent the issue from happening. However, in this particular case, since the screen class was never there, the functionality would still be impacted.
Cheers,
Samuel Jesus
Samuel Jesus wrote:
Hi!
I'm having the same problem and I'm using the component with layout.
But the Maurilio Macedo solution works fine.
Thanks
Just downloaded this component and it still has the error :)
I've managed to find that action and changed that specific line. However, the input still remains non-editable. Do you know why?
Hi, I have the same issue, but in my case, I'm trying to use it in the currency format. Adding the code "element.parentElement !== null && " the error message doesn't appear but the input become "disable".