瀏覽代碼

feat: 增加翻译

gemercheung 1 年之前
父節點
當前提交
2d4f4f56c7

+ 8 - 2
packages/qjkankan-editor/src/lang/_en.json

@@ -102,7 +102,8 @@
       "__name": "初始画面",
       "current": "Current cover",
       "current_set": "Set as scene cover",
-      "tips": "Drag the screen, click and save your scene cover."
+      "tips": "Drag the screen, click and save your scene cover.",
+      "v_angle_re": "Vertical viewing angle restrictions"
     },
     "hotspot": {
       "__name": "添加热点",
@@ -944,7 +945,12 @@
   },
   "mask": {
     "cover_tips": "You can add a mask to the current panorama.",
-    "select_image": "select"
+    "select_image": "select",
+    "apply_to_all_pano": " Apply to all panos",
+    "follow_the_scene": "Follow the scene",
+    "scaling_ratio": "Scaling Ratio",
+    "unit": "",
+    "is_apply_to_all_pano": "Apply to all panoramas?"
   },
   "style_key": {
     "menu_width": "88px",

+ 8 - 2
packages/qjkankan-editor/src/lang/_zh.json

@@ -102,7 +102,8 @@
       "__name": "初始画面",
       "current": "当前初始视角",
       "current_set": "设置为初始画面",
-      "tips": "移动屏幕,点击保存您的初始画面。"
+      "tips": "移动屏幕,点击保存您的初始画面。",
+      "v_angle_re": "垂直视角限制"
     },
     "hotspot": {
       "__name": "添加热点",
@@ -928,7 +929,12 @@
   },
   "mask": {
     "cover_tips": "您可以为当前全景图添加遮罩。",
-    "select_image": "选择图片"
+    "select_image": "选择图片",
+    "apply_to_all_pano": " 应用到全部全景图",
+    "follow_the_scene": " 跟随场景转动",
+    "scaling_ratio": "缩放比例",
+    "unit": "倍",
+    "is_apply_to_all_pano": "是否应用到全部全景图?"
   },
   "style_key": {
     "menu_width": "58px",

+ 11 - 11
packages/qjkankan-editor/src/views/mask/setting.vue

@@ -41,7 +41,7 @@
       </div>
 
       <div class="up-col">
-        <span> 缩放比例 </span>
+        <span> {{ $i18n.t(`mask.scaling_ratio`) }} </span>
 
         <slider
           v-model="sky.scale"
@@ -53,14 +53,14 @@
         />
       </div>
       <div class="swi-col">
-        <span> 跟随场景转动 </span>
+        <span> {{ $i18n.t("mask.follow_the_scene") }} </span>
         <switcher
           :value="sky.antidistorted"
           @change="(sa) => (sky.antidistorted = Boolean(sa))"
         ></switcher>
       </div>
       <div class="swi-col">
-        <span> 应用到全部全景图 </span>
+        <span> {{ $i18n.t("mask.apply_to_all_pano") }} </span>
         <switcher
           :value="isApplySkyToAll"
           @change="(sat) => (isApplySkyToAll = Boolean(sat))"
@@ -96,7 +96,7 @@
       </div>
 
       <div class="up-col">
-        <span> 缩放比例 </span>
+        <span> {{ $i18n.t(`mask.scaling_ratio`) }} </span>
         <slider
           v-model="earth.scale"
           show-stops
@@ -107,14 +107,14 @@
         />
       </div>
       <div class="swi-col">
-        <span> 跟随场景转动 </span>
+        <span> {{ $i18n.t("mask.follow_the_scene") }} </span>
         <switcher
           :value="earth.antidistorted"
           @change="(ve) => (earth.antidistorted = Boolean(ve))"
         ></switcher>
       </div>
       <div class="swi-col">
-        <span> 应用到全部全景图 </span>
+        <span> {{ $i18n.t("mask.apply_to_all_pano") }} </span>
         <switcher
           :value="isApplyEarthToAll"
           @change="(vet) => (isApplyEarthToAll = Boolean(vet))"
@@ -176,9 +176,9 @@ export default {
       isShowSelectionWindow: false,
       isSelect: "",
       scaleMarks: {
-        0.52: "0.5倍",
-        1: "1倍",
-        1.99: "2倍",
+        0.52: "0.5" + this.$i18n.t("mask.unit"),
+        1: "1" + this.$i18n.t("mask.unit"),
+        1.99: "2" + this.$i18n.t("mask.unit"),
       },
       sky: {
         isShow: false,
@@ -227,7 +227,7 @@ export default {
       handler: function (val) {
         if (val) {
           this.$confirm({
-            content: "是否应用到全部全景图?",
+            content: this.$i18n.t('mask.is_apply_to_all_pano'),
             ok: () => {
               this.$store.dispatch("scene/applycustomMaskToAll", "sky");
             },
@@ -243,7 +243,7 @@ export default {
       handler: function (val) {
         if (val) {
           this.$confirm({
-            content: "是否应用到全部全景图?",
+            content: this.$i18n.t('mask.is_apply_to_all_pano'),
             ok: () => {
               this.$store.dispatch("scene/applycustomMaskToAll", "earth");
             },

+ 4 - 4
packages/qjkankan-editor/src/views/screen/Setting.vue

@@ -21,7 +21,7 @@
         alt=""
       />
       <div class="item">
-        <div class="">垂直视角限制</div>
+        <div class="">{{ $i18n.t("modules.screen.v_angle_re") }}</div>
         <slider
           v-model="vlookat"
           range
@@ -34,7 +34,7 @@
       </div>
 
       <div class="col">
-        <span>应用到全部全景图</span>
+        <span>{{ $i18n.t("mask.apply_to_all_pano") }}</span>
         <Switcher :value="applyToAll" @change="onSwitcherChange"></Switcher>
       </div>
     </template>
@@ -120,11 +120,11 @@ export default {
       handler: function (val) {
         if (val) {
           const kr = this.$getKrpano();
-          const vlookat =kr.get("view.vlookat");
+          const vlookat = kr.get("view.vlookat");
           const hlookat = kr.get("view.hlookat");
           console.log("当前视野", vlookat, hlookat);
           this.$confirm({
-            content: "是否应用到全部全景图?",
+            content: this.$i18n.t("mask.is_apply_to_all_pano"),
             ok: () => {
               this.$store.dispatch("scene/applyInitVisualToAll", {
                 vlookat,