Skip to content

Commit 5587e4f

Browse files
committed
code improve
1 parent 4d409de commit 5587e4f

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/composables/useLoad3dViewer.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -172,11 +172,7 @@ export const useLoad3dViewer = (node: LGraphNode) => {
172172
const cameraConfig = node.properties['Camera Config'] as any
173173
const lightConfig = node.properties['Light Config'] as any
174174

175-
const widthWidget = node.widgets?.find((w) => w.name === 'width')
176-
const heightWidget = node.widgets?.find((w) => w.name === 'height')
177-
if (!(widthWidget && heightWidget)) {
178-
isPreview.value = true
179-
}
175+
isPreview.value = node.type === 'Preview3D'
180176

181177
if (sceneConfig) {
182178
backgroundColor.value =

0 commit comments

Comments
 (0)