backdrop / backdrop-issues

Issue tracker for Backdrop core.
144 stars 38 forks source link

Update the jQuery Time Entry plugin #6249

Open klonos opened 9 months ago

klonos commented 9 months ago

Splitting this task off of #6248, where this was brought up by @argiepiano:

Additionally the date module uses a minified version of the jQuery Time Entry plug in, which is very old and contains some deprecated jQuery methods. The last release of that plugin seems 2014!

indigoxela commented 9 months ago

@klonos many thanks for creating this issue.

The big question is: how to continue here. Obviously the library's dead. Fork? Deprecate?

argiepiano commented 9 months ago

This little library is used to enter times, often in combination with the jquery date picker. It's a bit of an annoying library that confuses people - I wouldn't mind if it went away. What does D9/10 use in its place?

indigoxela commented 9 months ago

@argiepiano personally, I also avoid that library and wouldn't mind if it were gone, but that's not really "backwards compatible". :wink:

No idea, which discussions happened in Drupal-land re that. They usually don't hesitate to ditch old stuff, and only have html5 datetime elements.

klonos commented 9 months ago

I was looking at https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/time in order to try to figure out the advantages of using this jQuery plugin over what vanilla HTML5 offers. It seems that the main thing is support for mouse wheel and spinner right?

indigoxela commented 9 months ago

@klonos I think, the point here is, that Backdrop still ships with old-school date fields (actually input type text). And these date fields can use that jQuery plugin to add "convenience" (or confusion). That's why this dry-aged library's still around.

Note that core does provide html5 date(time) elements via form API, and the widget for fields, we just didn't rip out the old (type text) ones.