Is there any date time picker component in AUI library?

Could not find a date time picker component in atlassian user interface library. Is there any bundle available for it ?

1 Like

There isn’t a datepicker component in AUI.

If you’re able to use AtlasKit you use the Calendar component https://ak-mk-2-prod.netlify.com/packages/elements/calendar Disclaimer: AtlasKit requires React.

AUI is already dependent on jQuery. You could include the jQuery UI datepicker widget and style it with the ThemeRoller to match the AUI style guidelines.

1 Like

Hey @sanjeev.pande,

AUI has shipped a date picker since version 5.1. You can read the docs for it here: Date picker - AUI Documentation. This date picker is currently backed by jQuery UI’s calendar component.

If what you need is a picker that can select just a time, or a date with a time component to it, then AUI doesn’t support that today as @rwhitbeck said.

Something that you unfortunately need to be aware of: depending on the specific Atlassian product you’re building for, they may ship their own date/time picker. For instance, Jira ships its own Calendar component in JavaScript and binds custom behaviour to its markup pattern for date/time custom fields. They do this because Jira also has its own ideas about how dates and times should be formatted and represented, which unfortunately also affects how the values are sent to and received from the server.

If you’re building your own forms and your own handlers for the data you get back from the UI, using AUI’s date picker should be fine. There may be a bit of wrangling to do on the server side to convert the value to a format that particular product will like, but them’s the breaks.

Hope that helps!

3 Likes