jonthornton/jquery-timepicker

Time Picker with Duration shows horizontal scroll bar when using step:15

mdolnik-eelzee opened this issue · 1 comments

When using the same code as the demo for Datepair Plugin Example with the only difference being that the step value is set to 15 then the width of the dropdown is too narrow for the duration text causing a horizonal scrollbar to appear.

2021-09-21_11h44_26

In the CSS code there seems to be provisions for step 30 and step 60, but not 15 or any other values.

.ui-timepicker-wrapper.ui-timepicker-with-duration {
width: 13em;
}
.ui-timepicker-wrapper.ui-timepicker-with-duration.ui-timepicker-step-30,
.ui-timepicker-wrapper.ui-timepicker-with-duration.ui-timepicker-step-60 {
width: 11em;
}

Rather than having .ui-timepicker-wrapper.ui-timepicker-with-duration set to width: 13em; is it possible to set it to width: auto? This resolves the issue for me.

2021-09-21_11h46_39

Also: The above solution works on Chrome, on Firefox I also need to add:

.ui-timepicker-wrapper .ui-timepicker-list li {
    padding-right: 2rem;
}

Thank you for the comprehensive bug report! This fix will go out with the next release.