@archvisioninc/canvas 2.8.1 → 2.8.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -622,8 +622,8 @@ export const takePreviewScreenshots = () => {
|
|
|
622
622
|
const axesVisible = xAxisMesh?.isVisible;
|
|
623
623
|
const skyBoxVisible = hdrSkyBox?.isVisible;
|
|
624
624
|
const frameVisible = outerFrame?.isVisible;
|
|
625
|
-
const groundVisible = ground
|
|
626
|
-
const mirrorGroundVisible = mirrorGround
|
|
625
|
+
const groundVisible = ground?.isVisible;
|
|
626
|
+
const mirrorGroundVisible = mirrorGround?.isVisible;
|
|
627
627
|
const {
|
|
628
628
|
positionGizmoEnabled,
|
|
629
629
|
rotationGizmoEnabled,
|
|
@@ -631,13 +631,13 @@ export const takePreviewScreenshots = () => {
|
|
|
631
631
|
scaleGizmoEnabled
|
|
632
632
|
} = gizmoManager;
|
|
633
633
|
const toggleUI = restore => {
|
|
634
|
-
mirrorGround.isVisible = restore ? mirrorGroundVisible : false;
|
|
635
|
-
ground.isVisible = restore ? groundVisible : false;
|
|
636
|
-
xAxisMesh.isVisible = restore ? axesVisible : false;
|
|
637
|
-
yAxisMesh.isVisible = restore ? axesVisible : false;
|
|
638
|
-
zAxisMesh.isVisible = restore ? axesVisible : false;
|
|
639
|
-
hdrSkyBox.isVisible = restore ? skyBoxVisible : false;
|
|
640
|
-
outerFrame.isVisible = restore ? frameVisible : false;
|
|
634
|
+
if (mirrorGround !== undefined) mirrorGround.isVisible = restore ? mirrorGroundVisible : false;
|
|
635
|
+
if (ground !== undefined) ground.isVisible = restore ? groundVisible : false;
|
|
636
|
+
if (xAxisMesh !== undefined) xAxisMesh.isVisible = restore ? axesVisible : false;
|
|
637
|
+
if (yAxisMesh !== undefined) yAxisMesh.isVisible = restore ? axesVisible : false;
|
|
638
|
+
if (zAxisMesh !== undefined) zAxisMesh.isVisible = restore ? axesVisible : false;
|
|
639
|
+
if (hdrSkyBox !== undefined) hdrSkyBox.isVisible = restore ? skyBoxVisible : false;
|
|
640
|
+
if (outerFrame !== undefined) outerFrame.isVisible = restore ? frameVisible : false;
|
|
641
641
|
gizmoManager.positionGizmoEnabled = restore ? positionGizmoEnabled : false;
|
|
642
642
|
gizmoManager.rotationGizmoEnabled = restore ? rotationGizmoEnabled : false;
|
|
643
643
|
gizmoManager.boundingBoxGizmoEnabled = restore ? boundingBoxGizmoEnabled : false;
|
package/package.json
CHANGED
|
@@ -686,8 +686,8 @@ export const takePreviewScreenshots = () => {
|
|
|
686
686
|
const axesVisible = xAxisMesh?.isVisible;
|
|
687
687
|
const skyBoxVisible = hdrSkyBox?.isVisible;
|
|
688
688
|
const frameVisible = outerFrame?.isVisible;
|
|
689
|
-
const groundVisible = ground
|
|
690
|
-
const mirrorGroundVisible = mirrorGround
|
|
689
|
+
const groundVisible = ground?.isVisible;
|
|
690
|
+
const mirrorGroundVisible = mirrorGround?.isVisible;
|
|
691
691
|
const {
|
|
692
692
|
positionGizmoEnabled,
|
|
693
693
|
rotationGizmoEnabled,
|
|
@@ -696,13 +696,14 @@ export const takePreviewScreenshots = () => {
|
|
|
696
696
|
} = gizmoManager;
|
|
697
697
|
|
|
698
698
|
const toggleUI = restore => {
|
|
699
|
-
mirrorGround.isVisible = restore ? mirrorGroundVisible : false;
|
|
700
|
-
ground.isVisible = restore ? groundVisible : false;
|
|
701
|
-
xAxisMesh.isVisible = restore ? axesVisible : false;
|
|
702
|
-
yAxisMesh.isVisible = restore ? axesVisible : false;
|
|
703
|
-
zAxisMesh.isVisible = restore ? axesVisible : false;
|
|
704
|
-
hdrSkyBox.isVisible = restore ? skyBoxVisible : false;
|
|
705
|
-
outerFrame.isVisible = restore ? frameVisible : false;
|
|
699
|
+
if (mirrorGround !== undefined) mirrorGround.isVisible = restore ? mirrorGroundVisible : false;
|
|
700
|
+
if (ground !== undefined) ground.isVisible = restore ? groundVisible : false;
|
|
701
|
+
if (xAxisMesh !== undefined) xAxisMesh.isVisible = restore ? axesVisible : false;
|
|
702
|
+
if (yAxisMesh !== undefined) yAxisMesh.isVisible = restore ? axesVisible : false;
|
|
703
|
+
if (zAxisMesh !== undefined) zAxisMesh.isVisible = restore ? axesVisible : false;
|
|
704
|
+
if (hdrSkyBox !== undefined) hdrSkyBox.isVisible = restore ? skyBoxVisible : false;
|
|
705
|
+
if (outerFrame !== undefined) outerFrame.isVisible = restore ? frameVisible : false;
|
|
706
|
+
|
|
706
707
|
gizmoManager.positionGizmoEnabled = restore ? positionGizmoEnabled : false;
|
|
707
708
|
gizmoManager.rotationGizmoEnabled = restore ? rotationGizmoEnabled : false;
|
|
708
709
|
gizmoManager.boundingBoxGizmoEnabled = restore ? boundingBoxGizmoEnabled : false;
|