a2ui-project / a2ui-project/a2ui

DateTimeInput date parsing is not great.

Offen
#1,673 3 Kommentare 0 Reaktionen 1 zugewiesene Person Beansprucht von @Varun-S10 Auf GitHub ansehen
component: angular renderer component: lit renderer component: react renderer P2 type: feature/enhancement
Vorherrschende Sprache
TypeScript
Sterne
16.4k
Forks
1.3k
Ø Merge
2 T. 13 Std.
Gemergte PRs (30 T.)
134

Beschreibung

The Date parsing on the DateTimeInput is not super flexible and because of how browsers work, may "clear" values when rendering them.

Our basic catalog implementation should be a little bit more [robust](https://github.com/a2ui-project/a2ui/blob/main/renderers/angular/src/v0_9/catalog/basic/date-time-input.component.ts#L108-L118) [than](https://github.com/a2ui-project/a2ui/blob/main/renderers/lit/src/v0_9/catalogs/basic/components/DateTimeInput.ts#L31-L52) [this](https://github.com/a2ui-project/a2ui/blob/main/renderers/react/src/v0_9/catalog/basic/components/DateTimeInput.tsx#L22-L40).

There's some cool libraries that we could use (like `any-date-parser` backed by Intl?), but as an MVP, we should guarantee that we can parse exactly what the spec says (and add tests to prove it)

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.