瀏覽代碼

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

任一存 3 年之前
父節點
當前提交
633d22e230

+ 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>