Topic: Datepicker on readonly input

szaiftamas priority asked 2 weeks ago

Expected behavior After I remove the readonly from the input element, I can use the Datepicker

Actual behavior If the input element is readonly when initialize the Datepicker, the Datepicker doesn't work when I remove the readonly from the input element.

I realize that, the button get a style="pointer-events: none;" option, which doesn't remove when I remove the readonly from the input element.

If I add the readonly attribute only after the Datepicker initialization, everything is working then expected, but in that case the readonly can not come from the HTML code!

This topic can be a remark, if you can not solve this problem easily, because it is not a difficult task to work around the problem.

Resources (screenshots, code snippets etc.)

<div id="end_date_div" class="form-outline mt-1">
        <input id="end_date" type="text" class="form-control form-icon-trailing" readonly="readonly">
        <label for="end_date" class="form-label" style="margin-left: 0px;">Záró Dátum (éééé-hh-nn)</label>
      <div class="form-notch"><div class="form-notch-leading" style="width: 9px;"></div><div class="form-notch-middle" style="width: 149.6px;"></div><div class="form-notch-trailing"></div></div>
    <button id="datepicker-toggle-485075" type="button" class="datepicker-toggle-button" data-mdb-toggle="datepicker" style="pointer-events: none;">
      <i class="far fa-calendar datepicker-toggle-icon"></i>

Grzegorz Bujański staff answered 2 weeks ago

Thanks for reporting. We'll try to fix it.

Please insert min. 20 characters.


Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.



Specification of the issue

  • ForumUser: Priority
  • Premium support: Yes
  • Technology: MDB Standard
  • MDB Version: MDB5 6.0.1
  • Device: Laptop
  • Browser: Firefox
  • OS: Linux
  • Provided sample code: No
  • Provided link: No