From d518e5f691fea8c28978bd4ea7d33c4cbda3232f Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Tue, 13 Oct 2026 10:26:59 +0200 Subject: feat(island): the clock pill opens the calendar panel A click on the pill opens the panel in its capsule, 620px wide, growing left from the gap so the status pill does not move. Focus goes into the panel so its text fields and Escape work; Escape closes the editor before the panel. The Escape hook is back(), not escape(): QML rejects a method named escape with "Illegal method name", since it shadows the global JS function, and the reload failed until it was renamed. Co-Authored-By: Claude Opus 5.5 --- desktop/island/Island.qml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'desktop/island/Island.qml') diff --git a/desktop/island/Island.qml b/desktop/island/Island.qml index 43422dc..61701d8 100644 --- a/desktop/island/Island.qml +++ b/desktop/island/Island.qml @@ -36,7 +36,7 @@ PanelWindow { WlrLayershell.namespace: "quickshell-island" WlrLayershell.keyboardFocus: panel !== "" ? WlrKeyboardFocus.OnDemand : WlrKeyboardFocus.None - // "", "sound" or "controls". + // "", "sound", "controls" or "calendar". property string panel: "" // --- reveal and hide ------------------------------------------------- @@ -57,7 +57,8 @@ PanelWindow { else if (panel === "" && !menuHeld) hideTimer.restart(); } onPanelChanged: { - if (panel !== "") keys.forceActiveFocus(); + if (panel === "calendar") clock.focusPanel(); + else if (panel !== "") keys.forceActiveFocus(); else if (!hovered) hideTimer.restart(); } @@ -140,7 +141,7 @@ PanelWindow { // Key events reach a focused item, not the window (AGENTS.md). Item { id: keys - Keys.onEscapePressed: win.panel = "" + Keys.onEscapePressed: if (!(win.panel === "calendar" && clock.back())) win.panel = "" } // --- geometry -------------------------------------------------------- @@ -202,6 +203,9 @@ PanelWindow { flicking: win.flicking flickWs: win.flickWs flickApp: win.flickApp + panel: win.panel + onOpenCalendar: win.panel = win.panel === "calendar" ? "" : "calendar" + onCloseCalendar: win.panel = "" } StatusPill { -- cgit v1.2.3