Open HendrikThePendric opened 5 years ago
@larshelge Could you please give your opinion about the proposed approach? Do you see this as a way forward, or do you think we should have a fully client-side implementation of several calendars too?
I had a meeting with @larshelge last week. He is more inclined to have a common JS library and we agreed to tackle this from two angles:
I will be looking into 1 - pure period library. For this I am wondering if we can build on Int.DateTimeFormat
?
Latest browser's are coming with Internationalization API support and we should be able to capitalize on that. Do we have list of browser versions that we support and do not support?
@abyot I was wondering if there are any existing solutions out there that we can leverage, or build on for 1. Do you know of any? I can imagine it'd be nice to contribute to something existing if possible.
@ismay not really much. I am thinking of building on Int.DateTimeFormat
and probably Luxon for manipulating date and times which we need for generating periods.
@abyot so, just to confirm: we'll need to build these components with full support for all calendar systems, including Nepalese, etc?
yes, will have to support all the calendars out there.
I know Int.DateTimeFormat
does not have support to Nepalese. I don't know may be because Nepalese calendar works with a mapping table than a generic algorithm? ... still better to build on native browser and probably fill the missing ones ourselves.
still better to build on native browser and probably fill the missing ones ourselves.
Yeah quite likely. It's something I'd really have to dive into a bit to make any suggestions.
I did a tiny little bit of research into this and while I couldn't find any Date pickers, or date utility libs, with direct support for Nepalese, I did find some converters for various calendars incl. Nepalese. Perhaps we could utilise base our solution around Int.DateTimeFormat
+ one of these converters....
Context
On Wednesday, June 12th 2019 a meeting took place to discuss how we are currently working with dates and periods in DHIS2 and ways to improve this. The main reason for organising the meeting was the fact that the current implementation in the front-end is fragmented and incomplete.
Several people were present:
Current situation
Problem analysis
Proposed approach