Przeglądaj źródła

Поправка goToLink

Book Pauk 4 lat temu
rodzic
commit
21df6c1d21
1 zmienionych plików z 5 dodań i 1 usunięć
  1. 5 1
      client/components/ExternalLibs/ExternalLibs.vue

+ 5 - 1
client/components/ExternalLibs/ExternalLibs.vue

@@ -324,8 +324,9 @@ class ExternalLibs extends Vue {
     }
 
     openBookUrlInFrame() {
-        if (this.bookUrl)
+        if (this.bookUrl) {
             this.goToLink(this.addProtocol(this.bookUrl));
+        }
     }
 
     goToLink(link) {
@@ -336,6 +337,9 @@ class ExternalLibs extends Vue {
         this.frameVisible = false;
         this.$nextTick(() => {
             this.frameVisible = true;
+            this.$nextTick(() => {
+                this.$refs.frame.contentWindow.focus();
+            });
         });
     }