소스 검색

编辑器-基础:开场动画和自定义遮罩功能兼容旧版本作品

任一存 3 년 전
부모
커밋
633d22e230
2개의 변경된 파일15개의 추가작업 그리고 2개의 파일을 삭제
  1. 9 1
      packages/code/src/views/base/customMaskSettings.vue
  2. 6 1
      packages/code/src/views/base/openingAnimationSettings.vue

+ 9 - 1
packages/code/src/views/base/customMaskSettings.vue

@@ -97,7 +97,15 @@ export default {
     onCancelSelection(cancelFor) {
       this.info.customMask[cancelFor] = ''
     },
-  }
+  },
+  mounted() {
+    if (!this.info.customMask) {
+      this.info.customMask = {
+        earth: '',
+        sky: '',
+      }
+    }
+  },
 }
 </script>
 

+ 6 - 1
packages/code/src/views/base/openingAnimationSettings.vue

@@ -49,7 +49,12 @@ export default {
     })
   },
   methods: {
-  }
+  },
+  mounted() {
+    if (!this.info.openingAnimationType) {
+      this.$set(this.info, 'openingAnimationType', this.openingTypeList[0])
+    }
+  },
 }
 </script>