qodesmith / datepicker

Get a date with JavaScript! A datepicker with no dependencies.
344 stars 101 forks source link

Allow setting custom location #116

Closed YZirkind closed 3 years ago

YZirkind commented 3 years ago

Currently the position option only allows setting the position directly relative to the associated input, or fixed to the center of the screen.

It would be nice to have the ability to set a custom fixed position anywhere on the screen. My use case is that I have set the inputs to be hidden, so the picker only shows up in the top left corner of the screen.

qodesmith commented 3 years ago

Check this fiddle out to see how you can position the calendar fixed on the page. You mentioned you were hiding the input so I used a regular <div> instead.

YZirkind commented 3 years ago

Thanks! I tried it using a <div> as in your fiddle and it worked, so I really didn't need to use hidden inputs for it.