Port · Calendar: a real exit clears the preview after a key

The calendar's grid clears its preview on leave, and ignores a leave
that follows a key. gpui records the exit a key makes before the
handler runs, so the guard swallowed it and a real exit afterwards
had no change left to report: the stale day stayed the preview. The
grid now listens independently of input, while its days keep the
default, so a key is no leave and a real exit is. A test leaves the
grid after an arrow, a letter and a month key.

shaped()'s doc goes back to its one line; AGENTS.md keeps the why.
This commit is contained in:
ZacharyZhang-NY committed 2026-09-28 20:54:25 -04:00
1 parent 4c3ed1bbb9
commit 05bd22b7f0
5 files changed
+28 -5

No files matched your search

+1 -1
View File
@@ -15,7 +15,7 @@ use crate::{
typography::{Ellipsis, format::file_size},
};
/// A box in a picture's own shape: as wide as the picture, but no wider than `widest` or its container. Hand it to a flex column inside a block: taffy 0.13 sizes the column by its width before its cap.
/// A box in a picture's own shape: as wide as the picture, but no wider than `widest` or its container.
pub(crate) fn shaped(width: f32, height: f32, widest: Pixels) -> Div {
assert!(
width > 0.0 && height > 0.0,