aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/features/webControls/components/WebControls.tsx10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/features/webControls/components/WebControls.tsx b/src/features/webControls/components/WebControls.tsx
index ebcd93c9e..51bf7e541 100644
--- a/src/features/webControls/components/WebControls.tsx
+++ b/src/features/webControls/components/WebControls.tsx
@@ -210,15 +210,19 @@ class WebControls extends Component<IProps, IState> {
210 editUrl: false, 210 editUrl: false,
211 }); 211 });
212 navigate(inputUrl); 212 navigate(inputUrl);
213
214 if (this.inputRef && this.inputRef.current) {
215 this.inputRef.current.blur();
216 }
213 } else if (event.key === 'Escape') { 217 } else if (event.key === 'Escape') {
214 this.setState({ 218 this.setState({
215 editUrl: false, 219 editUrl: false,
216 inputUrl: url, 220 inputUrl: url,
217 }); 221 });
218 }
219 222
220 if (this.inputRef && this.inputRef.current) { 223 if (this.inputRef && this.inputRef.current) {
221 this.inputRef.current.blur(); 224 this.inputRef.current.blur();
225 }
222 } 226 }
223 }} 227 }}
224 ref={this.inputRef} 228 ref={this.inputRef}