tremble 3 năm trước cách đây
mục cha
commit
84a9927cdb

+ 1 - 0
src/components/hotspot/image.vue

@@ -143,6 +143,7 @@ export default {
 .hotspot {
  
  .vhotspotcon{
+  width: 100%;
  }
 }
 

+ 19 - 8
src/components/hotspot/index.vue

@@ -72,7 +72,7 @@ export default {
 </script>
 
 <style lang="less" scoped>
-@w: 75%;
+@w: 100%;
 @titleH:100px;
 .hotspotconf {
   position: fixed;
@@ -99,8 +99,9 @@ export default {
       .vtitle {
         font-size: 30px;
         font-weight: bold;
-        width: 100%;
+        width: 80%;
         height: @titleH;
+        margin: 0 auto;
         display: flex;
         align-items: center;
         color: #ffffff;
@@ -160,7 +161,7 @@ export default {
           transform: translate(-50%);
         }
         .desc {
-          width: 90%;
+          width: 80%;
           height: 14%;
           font-size: 20px;
           text-align: justify;
@@ -193,11 +194,21 @@ export default {
       }
     }
 
-    .aa {
-      width: 50px;
-      height: auto;
-      cursor: pointer;
-    }
+     @pos: 50px;
+      .aa {
+        position: absolute;
+        width: 50px;
+        height: auto;
+        cursor: pointer;
+        top: 50%;
+        transform: translateY(-50%);
+        left: @pos;
+        z-index: 999;
+        &:last-of-type {
+          right: @pos;
+          left: unset;
+        }
+      }
     .vtitle {
       font-size: 30px;
       font-weight: bold;

+ 10 - 0
src/pages/scene/zhanxiang/index.vue

@@ -50,6 +50,16 @@ export default {
     swiper: directive,
   },
 
+  watch:{
+    currentPanoid(newVal){
+
+      let idx = this.zxdata.company.findIndex(item=>newVal == item.panoId)
+      console.log(idx);
+      this.swiper.slideTo(idx);
+
+    }
+  },
+
   computed: {
     swiper() {
       return this.$refs.bgsw.swiper;