Skip to content

Commit

Permalink
remove id from blockly search input (#10198)
Browse files Browse the repository at this point in the history
  • Loading branch information
riknoll authored Sep 23, 2024
1 parent 1e22ec7 commit ab3a9a1
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion theme/toolbox.less
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down
2 changes: 1 addition & 1 deletion webapp/src/blocks.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -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 = '';
}
Expand Down
1 change: 0 additions & 1 deletion webapp/src/toolbox.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1092,7 +1092,6 @@ export class ToolboxSearch extends data.Component<ToolboxSearchProps, ToolboxSea
onFocus={this.searchImmediate}
onKeyDown={this.handleKeyDown}
onChange={this.handleChange}
id="blocklySearchInputField"
className="blocklySearchInputField"
aria-label={lf("Search")}
autoComplete="off"
Expand Down

0 comments on commit ab3a9a1

Please sign in to comment.