We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
.focus()
1 parent 79505ef commit 13be280Copy full SHA for 13be280
src/pages/options/routes/script/ScriptEditor.tsx
@@ -889,12 +889,6 @@ function ScriptEditor() {
889
}}
890
onClick={() => {
891
setShowSearchInput(!showSearchInput);
892
- setTimeout(
893
- () =>
894
- showSearchInput &&
895
- (document.querySelector("#editor_search_scripts_input") as HTMLInputElement)?.focus(),
896
- 1
897
- );
898
899
>
900
<div className="flex justify-between items-center">
@@ -911,7 +905,8 @@ function ScriptEditor() {
911
905
<Input
912
906
placeholder={t("search_scripts")}
913
907
allowClear
914
- value={searchKeyword}
908
+ autoFocus
909
+ defaultValue={searchKeyword}
915
910
onChange={(value) => setSearchKeyword(value)}
916
size="mini"
917
id="editor_search_scripts_input"
0 commit comments