mirror of
https://github.com/LibreTranslate/LibreTranslate.git
synced 2024-11-28 10:50:59 +00:00
Merge pull request #326 from dingedi/feature/swap-langs-fix
fix swap lang
This commit is contained in:
commit
e68ec8411d
1 changed files with 5 additions and 4 deletions
|
@ -166,7 +166,7 @@ document.addEventListener('DOMContentLoaded', function(){
|
||||||
this.targetLang = t;
|
this.targetLang = t;
|
||||||
this.inputText = this.translatedText;
|
this.inputText = this.translatedText;
|
||||||
this.translatedText = "";
|
this.translatedText = "";
|
||||||
this.handleInput();
|
this.handleInput(e);
|
||||||
},
|
},
|
||||||
dismissError: function(){
|
dismissError: function(){
|
||||||
this.error = '';
|
this.error = '';
|
||||||
|
@ -269,9 +269,10 @@ document.addEventListener('DOMContentLoaded', function(){
|
||||||
this.isSuggesting = true;
|
this.isSuggesting = true;
|
||||||
},
|
},
|
||||||
closeSuggestTranslation: function(e) {
|
closeSuggestTranslation: function(e) {
|
||||||
this.translatedText = this.savedTanslatedText
|
if(this.isSuggesting) {
|
||||||
|
e.preventDefault();
|
||||||
e.preventDefault();
|
this.translatedText = this.savedTanslatedText
|
||||||
|
}
|
||||||
|
|
||||||
this.isSuggesting = false;
|
this.isSuggesting = false;
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in a new issue