Selaa lähdekoodia

1、调整页面bug

yys 3 päivää sitten
vanhempi
commit
6139a2b0e5

+ 19 - 1
src/assets/styles/index.scss

@@ -195,4 +195,22 @@ aside {
 .el-dialog__footer{
   border-top: 1px solid #DCDFE6;
 }
- 
+
+// 主内容区滚动:navbar+tags 占顶部,app-main 占剩余高度并滚动(仅改布局,不影响页面内按钮)
+#app .main-container {
+  display: flex;
+  flex-direction: column;
+  height: 100vh;
+  overflow: hidden;
+}
+
+#app .main-container > div:first-child {
+  flex-shrink: 0;
+}
+
+#app .main-container > .app-main {
+  flex: 1;
+  min-height: 0;
+  overflow-x: hidden;
+  overflow-y: auto;
+}

+ 2 - 3
src/components/RightToolbar/index.vue

@@ -76,9 +76,8 @@ export default {
 </script>
 <style lang="scss" scoped>
 .top-right-btn {
-  float: none;
-  margin-left: auto;
-  flex-shrink: 0;
+  position: relative;
+  float: right;
 }
 ::v-deep .el-transfer__button {
   border-radius: 50%;

+ 2 - 10
src/layout/components/AppMain.vue

@@ -25,24 +25,16 @@ export default {
 <style lang="scss" scoped>
 .app-main {
   background-color: #f0f2f5;
-  /* 50= navbar  50  */
-  min-height: calc(100vh - 50px);
   width: 100%;
   position: relative;
-  overflow: hidden;
 }
 
-.fixed-header+.app-main {
+.fixed-header + .app-main {
   padding-top: 50px;
 }
 
 .hasTagsView {
-  .app-main {
-    /* 84 = navbar + tags-view = 50 + 34 */
-    min-height: calc(100vh - 84px);
-  }
-
-  .fixed-header+.app-main {
+  .fixed-header + .app-main {
     padding-top: 84px;
   }
 }

+ 13 - 2
src/views/live/liveVideo/index.vue

@@ -304,15 +304,26 @@ export default {
           this.download(response.msg);
           this.exportLoading = false;
         }).catch(() => {});
+    },
+    pauseTableVideos() {
+      if (!this.$el) return;
+      this.$el.querySelectorAll('video').forEach((video) => {
+        video.pause();
+        video.removeAttribute('src');
+        video.load();
+      });
     }
+  },
+  deactivated() {
+    this.pauseTableVideos();
   }
 };
 </script>
 
 <style scoped>
 .video-player {
-  width: 100%;
-  height: 100%;
+  width: 200px;
+  height: 120px;
   object-fit: cover;
 }
 </style>