From cef6ae23fd92b38a214283dd1f6c23c21682a774 Mon Sep 17 00:00:00 2001 From: howard Date: Fri, 23 Apr 2021 11:31:16 -0700 Subject: [PATCH] change demo parts to s3 --- extlib/trackball.js | 5 ++--- src/react/dropDown.jsx | 3 +-- src/react/navBar.jsx | 6 +++--- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/extlib/trackball.js b/extlib/trackball.js index f7e000f..949742d 100644 --- a/extlib/trackball.js +++ b/extlib/trackball.js @@ -4,7 +4,7 @@ import { Quaternion, Vector2, Vector3 -} from 'three/src/Three'; +} from '../node_modules/three/src/Three'; var TrackballControls = function ( object, domElement ) { @@ -194,8 +194,7 @@ var TrackballControls = function ( object, domElement ) { if ( _state === STATE.TOUCH_ZOOM_PAN ) { - // factor = _touchZoomDistanceStart / _touchZoomDistanceEnd; - factor = _touchZoomDistanceEnd / _touchZoomDistanceStart; + factor = _touchZoomDistanceEnd / _touchZoomDistanceStart; _touchZoomDistanceStart = _touchZoomDistanceEnd; if ( scope.object.isPerspectiveCamera ) { diff --git a/src/react/dropDown.jsx b/src/react/dropDown.jsx index a611ba4..7f0fb0f 100644 --- a/src/react/dropDown.jsx +++ b/src/react/dropDown.jsx @@ -6,8 +6,7 @@ import { useDispatch, useSelector } from 'react-redux' export const DropDown = () => { const arr = [ - ['https://raw.githubusercontent.com/twpride/threeCAD/master/demo_parts/test2.json', 'test2'], - ['https://raw.githubusercontent.com/twpride/threeCAD/master/demo_parts/headphone-stand.json', 'headphone-stand'], + ['https://howardhwang.s3-us-west-1.amazonaws.com/headphone-stand.json', 'headphone-stand'], ] const dispatch = useDispatch() diff --git a/src/react/navBar.jsx b/src/react/navBar.jsx index 7828a36..e91894c 100644 --- a/src/react/navBar.jsx +++ b/src/react/navBar.jsx @@ -1,6 +1,6 @@ -import React, { useEffect, useReducer, useState } from 'react'; +import React, { useEffect, useReducer } from 'react'; import { useDispatch, useSelector } from 'react-redux' @@ -168,7 +168,7 @@ export const NavBar = () => { {/*
*/}
-
+
three.cad
@@ -187,7 +187,7 @@ export const NavBar = () => { )) }
-
+