Ver código fonte

地图线粗细适配/热点图标修改

shaogen1995 2 anos atrás
pai
commit
74efed9ff6

BIN
web/public/static/images/4dagePoint.png


BIN
web/public/static/images/4dagePoint2.png


+ 6 - 0
web/src/assets/style/reset.css

@@ -285,6 +285,12 @@ img {
 #ele1 path {
   fill: #165491;
 }
+.bodyMap1 #cad path {
+  stroke-width: 0.5;
+}
+.bodyMap2 #cad path {
+  stroke-width: 0.2;
+}
 .viewer-title {
   display: none !important;
 }

+ 24 - 8
web/src/assets/style/reset.less

@@ -328,35 +328,51 @@ img {
   image-rendering: -webkit-optimize-contrast;
   /*Webkit (non-standard naming) */
   image-rendering: crisp-edges;
- -ms-interpolation-mode: nearest-neighbor;
+  -ms-interpolation-mode: nearest-neighbor;
   /* IE (non-standard property) */
 }
 
 // 小地图指示器的颜色
 #ele1 circle {
   fill: #165491;
-  r:0.4692307692307692;
+  r: 0.4692307692307692;
 }
-#ele1 path{
+
+#ele1 path {
   fill: #165491;
 }
+
 // // 地图的线
 // #cad path {
 //   stroke-width: 0.5;
 // }
+.bodyMap1 {
+  #cad path {
+    stroke-width: 0.5;
+  }
+}
+.bodyMap2 {
+  #cad path {
+    stroke-width: 0.2;
+  }
+}
 
-.viewer-title{
+.viewer-title {
   display: none !important;
 }
-.viewer-prev{
+
+.viewer-prev {
   display: none !important;
 }
-.viewer-next{
+
+.viewer-next {
   display: none !important;
 }
-.viewer-navbar{
+
+.viewer-navbar {
   display: none !important;
 }
-.viewer-close{
+
+.viewer-close {
   display: none !important;
 }

+ 9 - 5
web/src/components/exhibition/index.vue

@@ -84,11 +84,15 @@ export default {
       if (window.location.href.includes(v.Logo)) {
         this.current = v;
         this.$nextTick(() => {
-          const mapDom = document.querySelector("#cad");
-          console.log("pppppp", mapDom);
-          // if (v.id === 3) mapDom.style.strokeWidth = 0.2;
-          // // 二楼的线粗细
-          // else mapDom.style.strokeWidth = 0.5; // 负一楼和一楼的地图线 粗细
+          if (v.id === 3) {
+            // 二楼的线粗细
+            $("body").addClass("bodyMap2");
+            $("body").removeClass("bodyMap1");
+          } else {
+            // 负一楼和一楼的地图线 粗细
+            $("body").addClass("bodyMap1");
+            $("body").removeClass("bodyMap2");
+          }
         });
       }
     });