From b364f08bbd75bade8f58fea61287b1b4b8280020 Mon Sep 17 00:00:00 2001 From: B_head Date: Sat, 21 Mar 2026 11:08:04 +0900 Subject: [PATCH] Remove duplicate AUTOHIDEABLE capability registration in Flydown Flyout.prototype.init already registers the AUTOHIDEABLE capability via addComponent, so the subsequent addCapability call in Flydown.prototype.init was redundant and could trigger a warning. Co-Authored-By: Claude Opus 4.6 (1M context) --- block-lexical-variables/src/fields/flydown.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/block-lexical-variables/src/fields/flydown.js b/block-lexical-variables/src/fields/flydown.js index a2707ff..561d7a0 100644 --- a/block-lexical-variables/src/fields/flydown.js +++ b/block-lexical-variables/src/fields/flydown.js @@ -84,10 +84,10 @@ Flydown.prototype.setCSSClass = function(newCSSClassName) { */ Flydown.prototype.init = function(workspace) { // Flydowns have no scrollbar + // Note: Flyout.prototype.init already registers AUTOHIDEABLE capability + // via addComponent, so we do not need to call addCapability again. Blockly.Flyout.prototype.init.call(this, workspace, false); this.workspace_.setTheme(workspace.getTheme()); - workspace.getComponentManager().addCapability(this.id, - Blockly.ComponentManager.Capability.AUTOHIDEABLE); }; /**