From ab3a9a1c4b5b05afcb2e229fa61979d4066fa739 Mon Sep 17 00:00:00 2001 From: Richard Knoll Date: Mon, 23 Sep 2024 14:19:36 -0700 Subject: [PATCH] remove id from blockly search input (#10198) --- theme/toolbox.less | 2 +- webapp/src/blocks.tsx | 2 +- webapp/src/toolbox.tsx | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/theme/toolbox.less b/theme/toolbox.less index 50e59edc2eb5..01ee97f796b8 100644 --- a/theme/toolbox.less +++ b/theme/toolbox.less @@ -441,7 +441,7 @@ div.blocklyTreeIcon span { font-size: 3rem; } /* Hide the blockly toolbox search */ - #blocklySearchInput.ui.icon.input { + .blocklySearchInput.ui.icon.input { input { padding-right: 0 !important; padding-left: 0.2rem; diff --git a/webapp/src/blocks.tsx b/webapp/src/blocks.tsx index 8dd3435eacf4..d72b077c50a9 100644 --- a/webapp/src/blocks.tsx +++ b/webapp/src/blocks.tsx @@ -1076,7 +1076,7 @@ export class Editor extends toolboxeditor.ToolboxEditor { } this.currFile = file; // Clear the search field if a value exists - let searchField = document.getElementById('blocklySearchInputField') as HTMLInputElement; + let searchField = document.querySelector("input.blocklySearchInput") as HTMLInputElement; if (searchField && searchField.value) { searchField.value = ''; } diff --git a/webapp/src/toolbox.tsx b/webapp/src/toolbox.tsx index 2a2542e1bea3..204cf7ad50b8 100644 --- a/webapp/src/toolbox.tsx +++ b/webapp/src/toolbox.tsx @@ -1092,7 +1092,6 @@ export class ToolboxSearch extends data.Component