Search code examples
htmlgoogle-chromejqgriddatepickerfree-jqgrid

How to avoid continuous scroll on native datapicker in free jqgrid


Clicking in spinner in Chrome datapicker causes continuous scroll in Chrome.

To reproduce, open latest demo

http://www.ok-soft-gmbh.com/jqGrid/OK/dateInput_48_bootstrap.htm

from answer

How to use native date picker in both form and row editing in free jqgrid

in Chrome , click in date to edit.

Click in up or down spinner and keep cursor in this spinner. Date scrolls indefinitely.

How to fix this so that single click increments or decrement value only by +1 or -1 ?


Solution

  • I think that one have to use use ::-webkit-inner-spin-button which allows to customize input spinners in CSS3 (see here). The problem is just it's really difficult to find the documentation of CSS properties which can be used in the case. The only well-known setting is

    input[type=date]::-webkit-inner-spin-button {
        display: none;
    }
    

    which just remove the spinner. No spinner - no problem. It's probably exist a better way to customize the spinner, but I didn't found it.