Skip to content

Fix/datepicker typed entry - #104

Merged
LBU4SH merged 3 commits into
mainfrom
fix/datepicker-typed-entry
Aug 27, 2026
Merged

Fix/datepicker typed entry#104
LBU4SH merged 3 commits into
mainfrom
fix/datepicker-typed-entry

Conversation

@LBU4SH

Copy link
Copy Markdown
Collaborator

No description provided.

… in-place edits
Day and month swapped as soon as the entry ended: `dateFieldOrder` only ever
looked at the resolved locale, never at `dateFormat`. A `fr-FR` formatter under
an unconfigured `LOCALE_ID` (so `en-US`) displayed "08/07/2026" but read it back
month-first — the auto-derived placeholder already advertised the formatter's own
order. The order is now probed from that formatter's output for an illustrative
date, and drives the parser, the live mask and the placeholder alike; the locale
takes over when the format isn't numeric enough to probe.
Correcting an already-typed segment shifted everything after it: replacing the
month "07" with a single digit re-sliced the whole digit stream, turning
"08/07/2026" into "08/12/026". The mask can only re-derive the field from a flat
stream when typing forward (or deleting from the tail), so it now steps aside for
the rest of the entry as soon as a keystroke lands anywhere but the tail — plain
text, parsed on blur/Enter, exactly what already applied once a value existed.
It re-arms on the next commit, or as soon as the field reads empty.
…anel
`allowInput` is true by default, so the field is a text field first — but the
whole trigger wrapper carried `(click)="open()"`, label and format hint included.
Combined with the overlay's permanent backdrop, that made the field unusable with
a mouse: the first click placed the caret, the next one was swallowed by the
backdrop and lost focus without moving the caret, so correcting a single segment
was impossible; a click on the label opened a panel `Escape` could no longer
close (focus was nowhere inside the wrapper); and opening live-committed the
typed text through `previewTyped`, disarming the auto-"/" mask mid-entry.
The icon, `↓` and typing are unchanged. The click keeps opening the panel exactly
where it's the affordance: a non-typeable trigger (`allowInput="false"`,
`readonly`, `timeOnly`) and `showIcon="false"`, which leaves no icon to click.
@LBU4SH
LBU4SH merged commit 5a2be0b into mainAug 27, 2026
3 checks passed
@LBU4SH
LBU4SH deleted the fix/datepicker-typed-entry branch August 27, 2026 09:51
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@LBU4SH