TimePicker Integration & Time Format Detection in Shopify App Admin Action

I have a Shopify App Admin Action.

There I need to enter a date and time. Unfortunately, Shopify does not have a TimePicker in @shopify/ui-extensions-react/admin.

  1. do any of you know how I can get a TimePicker into my Admin Action?
  2. how do I get to know what the TimeFormat (11:30PM or 23:30) of the admin user is? Then I could react to it myself if necessary

I would be very happy about help

Hi Rahminat,

It doesn’t look like there’s an easy way to add a time picker to an admin action and there’s no way to get the merchants default time format from the API. You may need to have this within your apps UI instead - would that work?

1 Like

Thank you for your answer.

In the meantime I have my own little timepicker that works for 12h and for the 24h format.

In the app settings, I will offer the option of deciding how the time format is displayed in the app. (In a metafield) I then use this metafield in the action to decide which TimePicker version I will play.

1 Like

Hi again Rahminat - that does sound like the best option for now.