From f9f1c8e465f81ae14a8bdf40f42d7642f702be4c Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 17 Jun 2026 11:40:58 +0000 Subject: [PATCH] fix(console-crane): close bundle selector dropdown and contain its list #86exzbh61 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The save-phrase bundle selector (a pilotui Select in custom+multiple mode) would not close and its option list spilled out of the modal. - Close: pilotui's only outside-driven close is a document handler that bails whenever the click sits under any `.relative` ancestor — true for nearly every click inside the ConsoleCrane modal, so the dropdown never closed. pilotui exposes no close method or `open` prop, so drive its own Escape handler from a self-managed outside-pointerdown listener and a real closeDropdown() (the latter also wired up the previously no-op after-save close called by SaveWordSectionV2). - Overflow: pilotui only gives the option list an internal scroll in `confirm` mode; in the `custom` mode used here the list grows past the panel's max-height and out of the modal. Make the panel a flex column and let the list region scroll within it. Adds a happy-dom regression test for the close mechanism. Co-Authored-By: Claude Opus 4.8 Claude-Session: https://claude.ai/code/session_01JsGMdHrjQfWRausa9T14kw --- .../components/SelectPhraseBundleV2.vue | 77 +++++++++++- tests/select-phrase-bundle.test.ts | 119 ++++++++++++++++++ 2 files changed, 191 insertions(+), 5 deletions(-) create mode 100644 tests/select-phrase-bundle.test.ts diff --git a/src/console-crane/components/SelectPhraseBundleV2.vue b/src/console-crane/components/SelectPhraseBundleV2.vue index 198564d..727fe62 100644 --- a/src/console-crane/components/SelectPhraseBundleV2.vue +++ b/src/console-crane/components/SelectPhraseBundleV2.vue @@ -1,7 +1,8 @@