修复编辑模式进入组件报错的问题
This commit is contained in:
parent
e369ebe87b
commit
c5f97495e8
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "material-editor",
|
||||
"private": true,
|
||||
"version": "1.0.30",
|
||||
"version": "1.0.31",
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
|
@ -200,7 +200,7 @@ const uploading = ref(false);
|
||||
// });
|
||||
const materialInfo = reactive({
|
||||
dirId: DirectoryId.MaterialDir, // 正常来说是2
|
||||
materialName: props.name || Textures.value?.[0].name || '材质',
|
||||
materialName: props.name || Textures.value[0]?.name || '材质',
|
||||
inputText: '',
|
||||
});
|
||||
|
||||
@ -210,7 +210,7 @@ watch(Textures, async (val) => {
|
||||
});
|
||||
|
||||
watch(() => props.name, () => {
|
||||
materialInfo.materialName = props.name || Textures.value?.[0].name || '材质';
|
||||
materialInfo.materialName = props.name || Textures.value[0]?.name || '材质';
|
||||
});
|
||||
|
||||
watch(textureAdjustment, async (val) => {
|
||||
|
Loading…
Reference in New Issue
Block a user