gemercheung 2 năm trước cách đây
mục cha
commit
e2caa40643

+ 1 - 1
packages/qjkankan-editor/.env.testprod

@@ -7,4 +7,4 @@ VUE_APP_PROXY_URL_ROOT='https://test.4dkankan.com'
 VUE_APP_PROXY_URL='https://test.4dkankan.com/qjkankan/'
 VUE_APP_ORIGIN=
 VUE_APP_URL_FILL=/qjkankan
-VUE_APP_DEBBUG_FLAG=0427-01
+VUE_APP_DEBBUG_FLAG=0428-01

+ 1 - 2
packages/qjkankan-editor/public/static/template/customTooltip.xml

@@ -1,7 +1,7 @@
 <krpano>
     <!-- 1.20. 新热点模式 -->
     <action name="addJQHotspot">
-        showlog();
+        <!-- showlog(); -->
         set(hsp_name,%1); 
         set(hsp_type,%2); 
         txtadd(iconUrl,'',%4);
@@ -445,7 +445,6 @@
 
     <!-- 编辑热点 -->
     <action name="editJQHotspot">
-      showlog();
       set(hsp_name,%1); 
       set(hsp_type,%2); 
       set(dImage,'static/panoassets/images/hotspot/image_place_holder.png');

+ 30 - 29
packages/qjkankan-editor/src/lang/_en.json

@@ -579,8 +579,8 @@
     "audio": "Audio",
     "video": "Video",
     "scene": "3D Scene",
-    "siweikankan": "四维看看",
-    "siweikanjian": "四维看见",
+    "siweikankan": "4DKanKan",
+    "siweikanjian": "4DMinion",
     "keywords": "Enter keywords",
     "how_to_shoot": "How to shoot a 3D scene?",
     "pano_size": "Support 2:1 jpg files ≤ 120MB",
@@ -601,8 +601,8 @@
     "folder_name_already_used": "Folder already exists",
     "move_folder": "Move",
     "move_folder_to": "Move to",
-    "no_folder_need_create": "暂无文件夹,请先创建文件夹",
-    "rename_folder_placeholder": "请输入文件夹名,限15字",
+    "no_folder_need_create": "Please create a folder first",
+    "rename_folder_placeholder": "Please enter a folder name up to 50 characters in length",
     "video_size": "Support MP4 files: ≤ 200MB",
     "video_limit": "The file is too large.Support MP4 files: ≤ 200MB",
     "video_fail": "Format error. Support MP4 files: ≤ 200MB",
@@ -647,8 +647,8 @@
     "exitVr": "Exit VR",
     "dir": "目录",
     "root_dir": "Root Directory",
-    "no_more_data": "没有更多数据了",
-    "converinfo_no_valid": "请将开场封面内容填写完整!"
+    "no_more_data": "no more results.",
+    "converinfo_no_valid": "Please fill out the content for the opening cover."
   },
   "personal_center": {
     "personal_center": "Personal Center",
@@ -678,20 +678,20 @@
     "coverUpTit1":"1920*1080 pixels, within 2M, jpg/gif/png format is recommended",
     "coverUpTit2":"750*1624 pixels ,within 1M, jpg/gif/png format is recommended",
     "coverUpTit3":"300*300 pixels, within 100kb, jpg format is recommended",
-    "coverUpTit4":"建议1920*1080px,5M以内,mp4格式",
-    "coverUpTit5":"建议750*1624px,5M以内,mp4格式",
+    "coverUpTit4":"1920*1080 pixels, within 5M, MP4 format is recommended",
+    "coverUpTit5":"750*1624 pixels, within 5M, MP4 format is recommended",
     "coverImgLoc1":"Center",
-    "coverImgLoc2":"Full Screen",
+    "coverImgLoc2":"Full",
     "coverImgBacTit":"Background Settings",
     "coverImgBacSelec1":"Fill Color",
     "coverImgBacSelec2":"Background-repeat",
     "coverVideoTit":"Video Settings",
     "select_video":"Select Video",
-    "coverImageInWay":"Entry method",
+    "coverImageInWay":"Entry Method",
     "coverImageInWayTit":"Automatic entry after 3 seconds countdown",
-    "coverVideoInWay":"Entry method",
+    "coverVideoInWay":"Entry Method",
     "coverVideoInWayTit":"Auto-entry after video playback",
-    "coverVideoControl":"视频控件",
+    "coverVideoControl":"Video Control",
     "coverVideoControlTit":"Display the video control or not",
     "coverImageOrder":"Displaying Order",
     "coverImageOrderTit1":"Images will appear before the video begins to play",
@@ -707,8 +707,8 @@
     "hide": "Hide",
     "show": "Display",
     "button_name": "Button name",
-    "button_type":"按钮类型",
-    "button_open_method": "打开方式",
+    "button_type":"Button type",
+    "button_open_method": "Open methods",
     "button_placeholder": "Please enter the button name",
     "please_input": "Please enter",
     "phone": "Phone",
@@ -749,8 +749,8 @@
   "zh_key": {
     "电话": "Tel",
     "链接": "Link",
-    "弹出层打开": "弹出层打开",
-    "新窗口打开": "新窗口打开",
+    "弹出层打开": "Pop-up Notification",
+    "新窗口打开": "New Tab",
     "小行星开场": "Start with asteroid",
     "小行星巡游开场": "Start with asteroid cruise",
     "小行星缩放开场": "Start with asteroid zoom",
@@ -811,10 +811,11 @@
     "init_screen": "Start screen",
     "screen_tips": "The start screen is the initial screen that appears when entering a scene; please drag the panorama to select the appropriate screen setting.",
     "setting_screen": "Set the current view to the start screen",
-    "goto_4dkk_edit_tips": "请前往四维时代个人中心编辑~"
+    "goto_4dkk_edit_tips": "4Dage Personal Center~"
+
   },
   "hotspot": {
-    "hotspot_type": "热点类型",
+    "hotspot_type": "Hotspots Style",
     "img_size":"Upload up to 20 images",
     "hotspot_tips": "Add icon hotspots to the panorama and configure their effect",
     "add_hotspot": "Add hotspot",
@@ -841,7 +842,7 @@
     "frame_duration": "Total Play Time",
     "select_icon": "Choose Icon",
     "if_show_marking_line": "Display dimension line or not",
-    "shape_filling_color": "形状填充",
+    "shape_filling_color": "Shape Fill",
     "shape_border_color": "Stroke",
     "text_color": "Color",
     "text_direction": "文字排序",
@@ -905,17 +906,17 @@
     "add_video": "Add a video",
     "select_video": "Add a video",
     "change_video": "Change a video",
-    "MB_limit": "不超过{value}MB",
-    "text_content": "文字内容",
+    "MB_limit": "Undering {value}MB",
+    "text_content": "Text",
     "apply_to_all": "应用到所有",
-    "phone_placeholder": "请输入电话号码",
-    "phone_error_tip": "请输入正确的电话号码",
-    "select_pdf": "添加PDF",
-    "change_pdf": "更换PDF",
-    "pdf_invalid_tip": "请选择50MB以内、PDF格式的文件",
-    "add_article": "添加文章内容",
-    "edit_article":"编辑文章内容",
-    "cancel_add_hotspot": "已编辑内容将不会保存,确定要关闭吗?"
+    "phone_placeholder": "Please enter the telephone number",
+    "phone_error_tip": "Please enter the correct telephone number",
+    "select_pdf": "Add a PDF",
+    "change_pdf": "Change the PDF",
+    "pdf_invalid_tip": "Please upload PDF files within 50M",
+    "add_article": "Add Paragraph",
+    "edit_article":"Edit paragraph",
+    "cancel_add_hotspot": "The edited content will not be saved, confirm to close it"
     
   },
   "explanation": {

+ 2 - 2
packages/qjkankan-editor/src/views/explanation/explanationSettings.vue

@@ -53,9 +53,9 @@
         />
       </div>
     </template>
-    <div class="disabled-tip" v-if="currentScene.type === '4dkk'">
+    <!-- <div class="disabled-tip" v-if="currentScene.type === '4dkk'">
       {{$i18n.t('explanation.disabled_tip')}}
-    </div>
+    </div> -->
   </div>
 </template>
 

+ 2 - 2
packages/qjkankan-view/public/showviewer/lib/krpano/tooltip.xml

@@ -1,7 +1,7 @@
 <krpano>
     <!-- 1.20. 新热点模式 -->
     <action name="addJQHotspot">
-        showlog();
+        <!-- showlog(); -->
         set(hsp_name,%1); 
         set(hsp_type,%2); 
         txtadd(iconUrl,'',%4);
@@ -331,7 +331,7 @@
         if( get(lineDirection) == 'left-top',
         <!-- newx = distance * Math.cos(direction) + x
         newy = distance * Math.sin(direction) + y -->
-            showlog();
+            <!-- showlog(); -->
             if(get(dir)==0,set(hotspot[get(dirItem)].rotate,-35));
             if(get(dir)==1,
             add(allHeight,labelHeight,80);

+ 96 - 56
packages/qjkankan-view/src/components/assembly/MobileTags/metas/fixaudio.vue

@@ -1,27 +1,36 @@
 <template>
   <div class="audioinner">
-    <audio id="audioTag" class="noshow" autoplay :src="hotspot.audio.ossPath"></audio>
-    <div class="audio-pan" :class="{rotatepan:isPlaying}">
-
+    <audio
+      id="audioTag"
+      class="noshow"
+      autoplay
+      :src="hotspot.audio.ossPath"
+    ></audio>
+    <div class="audio-pan" :class="{ rotatepan: isPlaying }">
       <img :src="require('@/assets/images/icon/player_pic01.png')" alt="" />
     </div>
 
     <div class="audio-content">
-
       <div class="ad-div">
-        <img @click="bofang" :src="require(`@/assets/images/icon/${isPlay?'pause':'preview'}.png`)" alt="" />
+        <img
+          @click="playing"
+          :src="
+            require(`@/assets/images/icon/${isPlay ? 'pause' : 'preview'}.png`)
+          "
+          alt=""
+        />
         <div class="adcon">
           <div class="bar">
             <div class="activeLine" @click="seekTime"></div>
             <div :style="{ width: currentPosi + '%' }" class="dot"></div>
           </div>
           <div class="time">
-            <span>{{ time }}</span><span> / {{ allTime }}</span>
+            <span>{{ time }}</span
+            ><span> / {{ allTime }}</span>
           </div>
         </div>
       </div>
     </div>
-
   </div>
 </template>
 
@@ -38,21 +47,29 @@ export default {
       volumePosi: 100,
       allTime: 0,
       timer: null,
-      isPlaying:false,
-      isMute: false
+      isPlaying: false,
+      isMute: false,
+      isDraging: false,
+      touchPointX: null,
     };
   },
   methods: {
-    bofang() {
+    playing() {
       if (this.i_audio.paused) {
-        this.i_audio.play();
-        this.isPlay = true;
+        this.play();
       } else {
-        this.i_audio.pause();
-        this.isPlay = false;
-        this.timer && clearInterval(this.timer);
+        this.pause();
       }
     },
+    play() {
+      this.i_audio.play();
+      this.isPlay = true;
+    },
+    pause() {
+      this.i_audio.pause();
+      this.isPlay = false;
+      this.timer && clearInterval(this.timer);
+    },
     transTime(time) {
       var duration = parseInt(time);
       var minute = parseInt(duration / 60);
@@ -69,7 +86,8 @@ export default {
       return minute + isM0 + sec;
     },
     updateProgress() {
-      this.currentPosi = (this.i_audio.currentTime / this.i_audio.duration) * 100;
+      this.currentPosi =
+        (this.i_audio.currentTime / this.i_audio.duration) * 100;
       this.time = this.transTime(this.i_audio.currentTime);
     },
 
@@ -88,34 +106,51 @@ export default {
 
     handleVolume(e) {
       var rate = e.offsetX / e.target.clientWidth;
-      this.i_audio.volume = rate
-      this.volumePosi = rate * 100
+      this.i_audio.volume = rate;
+      this.volumePosi = rate * 100;
     },
 
     handleMute() {
-      this.isMute = !this.isMute
-    }
+      this.isMute = !this.isMute;
+    },
+    handleDotStart(event) {
+      if (!this.isDraging) {
+        this.isDraging = true;
+        // this.pause();
+        this.touchPointX = event.touches[0].clientX;
+        
+      }
+    },
+    handleDotDraging(event) {
+      if (this.isDraging) {
+        const totalWidth = document.querySelector(".activeLine").clientWidth;
+        let dx = event.touches[0].clientX - this.touchPointX;
+
+        // const startWidth = this.touchPointX ? this.touchPointX / totalWidth : 0;
+        console.log("startWidth", this.touchPointX);
+        // dx = dx >= totalWidth ? totalWidth : dx;
+        // const dxWidth = dx / totalWidth;
+        // const lastWidth = originWidth.toFixed(2) + (dxWidth * 100).toFixed(2);
+        // console.log("dxWidth", lastWidth);
+        // document.querySelector(".dot").style.width = lastWidth + "%";
+      }
+    },
+    handleDotDragEnd() {
+      this.isDraging = false;
+      this.touchPointX = null;
+    },
   },
   watch: {
     isMute(newVal) {
-      this.i_audio.muted = newVal
-    }
+      this.i_audio.muted = newVal;
+    },
   },
   mounted() {
     this.$nextTick(() => {
       this.i_audio = $("#audioTag")[0];
-      // $("#audioTag").on("loadedmetadata", (e) => {
-      //   window.alert('音频-loadedmetadata');
-      //   console.log('e',e);
-      //   console.log('e1',e.deletateTarget);
-      //   console.log('duration',e.currentTarget.duration);
-      //   this.time = this.transTime(e.currentTarget.duration);
-      //   this.allTime = this.transTime(e.currentTarget.duration);
-      //   this.i_audio.play();
-      //   this.isPlay = true;
-      // });
+
       $("#audioTag").on("durationchange ", (e) => {
-        console.log('duration',e.target.duration);
+        console.log("duration", e.target.duration);
         this.time = this.transTime(e.target.duration);
         this.allTime = this.transTime(e.target.duration);
         this.i_audio.play();
@@ -133,13 +168,13 @@ export default {
       $("#audioTag").on("playing", () => {
         if (!this.isPlaying) {
           console.log(this.isPlaying);
-          this.isPlaying = true
+          this.isPlaying = true;
         }
       });
 
       $("#audioTag").on("pause", () => {
         if (this.isPlaying) {
-          this.isPlaying = false
+          this.isPlaying = false;
         }
       });
 
@@ -151,9 +186,18 @@ export default {
         this.audioEnded();
       });
     });
+    console.log("dot", document.querySelector(".dot"));
+    document
+      .querySelector(".dot")
+      .addEventListener("touchstart", this.handleDotStart, false);
+    document
+      .querySelector(".dot")
+      .addEventListener("touchmove", this.handleDotDraging, false);
+    document
+      .querySelector(".dot")
+      .addEventListener("touchend", this.handleDotDragEnd, false);
   },
-  beforeDestroy() {
-  },
+  beforeDestroy() {},
 };
 </script>
 
@@ -171,19 +215,18 @@ export default {
     top: 40%;
     transform: translate(-50%, -50%);
     text-align: center;
-    >img {
+    > img {
       width: 100%;
       height: auto;
       max-width: 236px;
     }
   }
 
-  .rotatepan{
-    >img {
+  .rotatepan {
+    > img {
       animation: rotatete infinite linear 10s;
       transform-origin: center;
     }
-
   }
 
   .audio-content {
@@ -201,7 +244,7 @@ export default {
       width: 90%;
       align-items: center;
 
-      >img {
+      > img {
         margin-right: 20px;
         width: 36px;
       }
@@ -225,8 +268,8 @@ export default {
             top: 50%;
             transform: translateY(-50%);
             width: 100%;
-            background: rgba(0,0,0,0.4);
-            border: 1px solid rgba(255,255,255,0.1);
+            background: rgba(0, 0, 0, 0.4);
+            border: 1px solid rgba(255, 255, 255, 0.1);
             backdrop-filter: blur(1px);
           }
 
@@ -240,10 +283,11 @@ export default {
             left: 0;
             height: 100%;
             cursor: pointer;
-            pointer-events: none;
+            // pointer-events: none;
             border-radius: 3px;
-            &::before,&::after{
-              content: '';
+            &::before,
+            &::after {
+              content: "";
               display: inline-block;
               width: 10px;
               height: 10px;
@@ -254,8 +298,8 @@ export default {
               transform: translateY(-50%);
               background-color: var(--editor-main-color);
             }
-            &::after{
-              content: '';
+            &::after {
+              content: "";
               display: inline-block;
               width: 12px;
               height: 12px;
@@ -270,17 +314,14 @@ export default {
           width: 100px;
           margin-top: 6px;
 
-          >span {
+          > span {
             font-size: 12px;
             color: rgba(255, 255, 255, 1);
           }
         }
       }
     }
-
   }
-
-
 }
 
 .noshow {
@@ -291,12 +332,11 @@ export default {
   pointer-events: none !important;
 }
 
-
-@keyframes rotatete{
+@keyframes rotatete {
   0% {
     transform: rotate(0);
   }
-  100%{
+  100% {
     transform: rotate(360deg);
   }
 }

+ 2 - 2
packages/qjkankan-view/src/locales/en.json

@@ -29,8 +29,8 @@
     "exit_vr": "Exit VR",
     "no_title": "No title",
     "name":"4DPano",
-    "jumpTips":"跳过({second}s)",
-    "jump":"跳过"
+    "jumpTips":"Skip({second}s)",
+    "jump":"Skip"
 
   },
   "menu":{

+ 1 - 1
packages/qjkankan-view/src/pages/show.vue

@@ -226,7 +226,7 @@ onMounted(async () => {
               ? JSON.parse(currentScene.value.someData).hotspots
               : currentScene.value.someData.hotspots;
         }
-        console.log(hotspots, "hotspotshotspotshotspotshotspots");
+        console.log(hotspots, "hotspots");
         app.Tags.initHotspot(hotspots, false);
       });
     }