[Beta]: The Date calendar ignores the first Escape and the first click outside it
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 84/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- playwright, react, typescript
Direzione di ricerca
Leggi apps/www/src/registry/components/editor/date.tsx nella parte relativa al gestore del cambiamento di apertura e al flag del gesto descritto nell’issue. Poi estendi apps/www/src/registry/components/editor/date.spec.tsx o apps/www/tests/browser/inline-void-first-click.spec.ts per coprire Escape e i clic all’esterno, inclusa l’apertura con Enter. Il lavoro è completato quando ogni richiesta di chiusura chiude il calendario al primo tentativo nei casi segnalati.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Testing lane
- Repository:
udecode/plate - Branch:
next - Release channel: Beta
- Exact commit/package version:
NOT_ENOUGH_INFO
Summary
On https://beta.platejs.org/docs/date, the calendar that opens from a date ignores the first request to close it. The first Escape and the first click outside the calendar leave it open, and the second one closes it. On https://platejs.org/docs/date, one Escape or one click outside closes the calendar.
Reproduction
natamox found this by hand in Chrome on macOS on 2026-10-25 and confirmed it in a retest the same day.
Repro 1: Escape and a click outside, Chromium
An agent recorded this on the live Beta in headless Chromium 149 (Playwright) on 2026-10-25, and recorded the same steps on platejs.org as a reference.
- Open https://beta.platejs.org/docs/date.
- In the line
Try selecting January 1, 2024 or May 8, 2025., clickJanuary 1, 2024. The calendar opens. - Press Escape.
- Press Escape again.
- Click
January 1, 2024again. The calendar opens. - Click once in the text
Insert and display dates, outside the calendar. - Click the same spot again.
Result: after step 3 and after step 6 the calendar is still open. It closes at step 4 and at step 7. On platejs.org it closes at step 3 and at step 6.
Repro 2: WebKit, after picking a day, and the keyboard
An agent ran these in headless Chromium 149 and WebKit 26.5 (Playwright) on 2026-10-25. There is no recording. Both engines gave the same results:
- The steps of Repro 1 give its result in WebKit too.
- After a day is picked in the calendar, one Escape leaves the calendar open.
- A click on the page's
Featuresheading, below the editor, also needs a second click to close the calendar. - With focus on the date, Enter opens the calendar, and one Escape leaves it open.
Expected
One Escape or one click outside the calendar closes it, as on platejs.org/docs/date.
Actual
The first Escape or click outside does nothing, and only the second one closes the calendar.
Environment
- Exact
nextcommit/Beta package version:NOT_ENOUGH_INFO. The page does not show its build. - Repro 1: Chromium 149.0.7827.55 (Playwright, headless) on macOS, 2026-10-25.
- Repro 2: Chromium 149.0.7827.55 and WebKit 26.5 (Playwright, headless) on macOS, 2026-10-25.
- natamox's report: Chrome on macOS, 2026-10-25.
- Not tried in Firefox or on a phone.
Caveat
This comes from reading apps/www/src/registry/components/editor/date.tsx on next a6e4322f7f, without trying a code change:
- A click on the date sets
ignoreCloseFromOpeningGestureRef(:71), so that the popover ignores a close request from the same gesture that opened it. - Only a key press or a pointer press on the date itself clears the flag (
:74to:80). Escape and a click outside happen elsewhere, so the flag is still set when the popover asks to close.onOpenChangethen drops that close and clears the flag (:103to:106), and the next close goes through. - Enter on the date clears the flag at its key press, but the click that Enter fires sets it again, which is why the keyboard case behaves the same way.
The flag came with 665b2bb598, which fixed opening the calendar on the first click. apps/www/tests/browser/inline-void-first-click.spec.ts and apps/www/src/registry/components/editor/date.spec.tsx check opening and reopening, and no test closes the calendar with Escape or a click outside.
Evidence
- Repro 1: the agent's recording on Beta, 0:21, with an English step panel on the right. The two Escape presses are at 0:04 and 0:06, and the two clicks outside at 0:11 and 0:13. The dark box at the bottom left is drawn by the test script. It shows whether the calendar is open and counts Escape presses and clicks off the date.
- Reference: the same steps on platejs.org, 0:21.
Repro 1 — Chromium 149, /docs/date (Beta)
https://github.com/user-attachments/assets/986e9e57-cca3-411a-8747-94412f75aac1
Reference — Chromium 149, /docs/date on platejs.org
https://github.com/user-attachments/assets/4941489a-6439-4748-9c44-324d8d9cbaed
- Lingua principale
- TypeScript
- Stelle
- 16.6k
- Fork
- 993
- Merge medio
- 20h 1m
- PR unite (30g)
- 60
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di udecode/plate
-
bug plugin:link target:beta triaged
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno
-
bug mobile target:beta triaged
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
bug target:beta triaged
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
I maintainer di solito rispondono entro 1 giorno
-
bug target:beta triaged
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
bug target:beta triaged
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di udecode/plate
Issue simili
-
Native Web
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 80/100
digitalfabrik/integreat-app#4517 ·
I maintainer di solito rispondono entro 2 giorni
-
TLS guide repeats certs/ in the certificate directoryForse già presa @maheshrijal l’ha presa oggi. Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 92/100
prometheus/docs#3156 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 83/100
medusajs/dtc-starter#90 ·
I maintainer di solito rispondono entro 1 giorno
-
usability
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
inmanta/web-console#7632 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
zaidmukaddam/scira#261 ·