Skip to content

Commit ef12332

Browse files
committed
We're defeated, wait for the bug to be fixed on @gouvfr/dsfr side
1 parent 3ba68ff commit ef12332

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

stories/Header.stories.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,10 @@ function MySearchInput(props: MySearchInputProps) {
284284
type={type}
285285
value={search}
286286
onChange={event => onSearchChange(event.currentTarget.value)}
287+
// A bug in @gouvfr/dsfr is currently preventing the escape key event to be propagated to the input element.
288+
// As a result this onKeyDown is never called when the user press escape and thus is useless.
289+
// In the current state of thing there is no way to clear the search input and lost focus in controlled mode.
290+
// We hope this issue will be resolved soon.
287291
onKeyDown={event => {
288292
if (event.key === "Escape") {
289293
onSearchChange("");

0 commit comments

Comments
 (0)