Skip to content
This repository has been archived by the owner on Oct 8, 2020. It is now read-only.

I18N & Locale API #2

Closed
pleku opened this issue Jul 19, 2018 · 3 comments
Closed

I18N & Locale API #2

pleku opened this issue Jul 19, 2018 · 3 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@pleku
Copy link
Contributor

pleku commented Jul 19, 2018

Add the API and demos for handling localization, both setting of the time format with locale and the I18N object.

@pleku pleku added the enhancement New feature or request label Jul 19, 2018
@pleku pleku added this to the 1.0.0.alpha1 milestone Jul 19, 2018
@ZheSun88 ZheSun88 self-assigned this Aug 2, 2018
@ZheSun88
Copy link
Contributor

ZheSun88 commented Aug 3, 2018

I am returning this ticket to the sprint backlog. because I am not sure what i can do with providing this support:

  • with i18n:
    There are two functions, formatTime and parseTime, in the object, together with property selector, for me it looks this property is not ready to use, as i set it with the webcomponent, i didn't get the expected behavior.
    for the support those two functions, we can put getters and setters for them, but do we want the user the put arbitrary String for it, or what type of parameters should it be?

  • With locale:
    We can provide a similar connector, like the one we used for date-picker, but which js function should we use for it, i found one, Date.prototype.toLocaleTimeString(), which is also similar to the one used in date-picker. But there is one problem with this JS function, it cannot support the time format hh:mm:ss.fff.

@ZheSun88 ZheSun88 removed their assignment Aug 3, 2018
@pleku
Copy link
Contributor Author

pleku commented Aug 7, 2018

As discussed f2f, what we really need in terms of the server side user is:

  • a way to set the desired resolution: hour, minute, second, millisecond (similar to https://github.com/vaadin/vaadin-time-picker/issues/42)
  • a way to set the desired locale, which applies either the 12/24 hours clock to the component
    • by default, the locale is picked up from the UI

@ZheSun88
Copy link
Contributor

ZheSun88 commented Aug 8, 2018

After this, release vaadin-time-picker-flow, 1.0.0.beta1, which is based on flow 1.0.X and flow-component-base 1.0.X

@ZheSun88 ZheSun88 assigned ZheSun88 and unassigned ZheSun88 Aug 8, 2018
@pleku pleku self-assigned this Oct 31, 2018
pleku added a commit that referenced this issue Oct 31, 2018
Support 159 locales from Java with Arabic numerals and Eastern Arabic
numerals. Could add support for other numerals too later.

Next steps are to improve the step API for Java side, and add more tests
for entering time with keyboard input.

Fixes #2
pleku added a commit that referenced this issue Nov 1, 2018
Support 159 locales from Java with Arabic numerals and Eastern Arabic
numerals. Could add support for other numerals too later.

Next steps are to improve the step API for Java side, and add more tests
for entering time with keyboard input.

Fixes #2
pleku added a commit that referenced this issue Nov 1, 2018
Support 159 locales from Java with Arabic numerals and Eastern Arabic
numerals. Could add support for other numerals too later.

Next steps are to improve the step API for Java side, and add more tests
for entering time with keyboard input.

Fixes #2
@pleku pleku closed this as completed in #6 Nov 1, 2018
pleku added a commit that referenced this issue Nov 1, 2018
Support 159 locales from Java with Arabic numerals and Eastern Arabic
numerals. Could add support for numerals in other scripts later on.

Next steps are to improve the step API for Java side, and add more tests
for entering time with keyboard input.

Fixes #2
pleku added a commit that referenced this issue Nov 1, 2018
Support 159 locales from Java with Arabic numerals and Eastern Arabic
numerals. Could add support for other numerals too later.

Next steps are to improve the step API for Java side, and add more tests
for entering time with keyboard input.

Fixes #2
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants