From dd586f1d8937f67e95504da167216d5413f05262 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Tue, 29 Sep 2026 07:11:01 -0300 Subject: G8: a notice leaves quicker than it arrives MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The notice chip's motion was mostly there (a drop easing out on the Motion flavour, a dissolve easing in, Lift's shadow in tier 4 at its fade). Its dissolve took 300 ms against a 180 ms fall, the wrong way round for §8.1 (leaving quicker than arriving, 100 to 160 ms): MessageDissolve now defaults to 150. The field comments had the two easings swapped; the stack test pins a longer dissolve for the case it checks. docs/config.md and docs/effects.md say so. Tests: both timings in their bands, leaving quicker. Gates as G7 (no golden moved). Feel review: .scratch/render/notices/. --- src/Messages.zig | 9 +++++++++ src/config.zig | 8 +++++--- 2 files changed, 14 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/Messages.zig b/src/Messages.zig index 7d284e6b..36cd44da 100644 --- a/src/Messages.zig +++ b/src/Messages.zig @@ -768,6 +768,8 @@ test "messages stack, oldest on top, each on its own timing" { const pane = p.panes[p.active].?; try std.testing.expect(p.executeBuiltinLine(p.active, "Verbose off")); try std.testing.expect(p.executeBuiltinLine(p.active, "MessageLinger 160")); + // A dissolve longer than a fall, so the second is caught mid-way. + try std.testing.expect(p.executeBuiltinLine(p.active, "MessageDissolve 300")); // `Verbose off` announced itself before it took effect. pane.msg_len = 0; pane.msg_life = .{}; @@ -968,3 +970,10 @@ test "an idle core wants no wake and a lingering message sleeps to its linger's p.advance(long_due); try std.testing.expectEqual(Pane.MessagePhase.leaving, pane.msg_life.phase); } + +test "a notice leaves quicker than it arrives, each within its §8.1 band" { + const settings: config.Runtime = .{}; + try std.testing.expect(settings.message_dissolve_ms < settings.message_fall_ms); + try std.testing.expect(settings.message_fall_ms >= 150 and settings.message_fall_ms <= 220); + try std.testing.expect(settings.message_dissolve_ms >= 100 and settings.message_dissolve_ms <= 160); +} diff --git a/src/config.zig b/src/config.zig index 43d2cfda..5734cd0c 100644 --- a/src/config.zig +++ b/src/config.zig @@ -658,10 +658,12 @@ pub const Runtime = struct { cursor_blink: bool = true, /// How long a message stays after the key or click that dismisses it. message_linger_ms: u16 = 800, - /// How long its ease-in fall into the row takes. + /// How long its fall into the row takes, easing out (§8.1: arriving, + /// 150 to 220 ms). message_fall_ms: u16 = 180, - /// How long its ease-out dissolve takes. - message_dissolve_ms: u16 = 300, + /// How long its dissolve takes, easing in: leaving is quicker than + /// arriving (§8.1: 100 to 160 ms). + message_dissolve_ms: u16 = 150, /// Where Dump writes and a relative Restore looks; empty is the default /// ($XDG_DATA_HOME/pardes, else ~/.local/share/pardes). dump_dir: Text(limits.host_path_cap) = .{}, -- cgit v1.3