Upgrade deps
This commit is contained in:
parent
a8df97a06a
commit
5d37c15173
10 changed files with 666 additions and 994 deletions
|
@ -6,11 +6,11 @@
|
|||
"dependencies": {
|
||||
"@theatre/core": "workspace:*",
|
||||
"@theatre/studio": "workspace:*",
|
||||
"@types/react": "^17.0.9",
|
||||
"@types/react-dom": "^17.0.6",
|
||||
"@types/react": "^17.0.19",
|
||||
"@types/react-dom": "^17.0.9",
|
||||
"parcel-bundler": "^1.12.5",
|
||||
"react": "^17.0.2",
|
||||
"react-dom": "^17.0.2",
|
||||
"typescript": "^4.3.5"
|
||||
"typescript": "^4.4.2"
|
||||
}
|
||||
}
|
||||
|
|
32
package.json
32
package.json
|
@ -22,28 +22,28 @@
|
|||
]
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.14.3",
|
||||
"@babel/plugin-proposal-class-properties": "^7.13.0",
|
||||
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.14.2",
|
||||
"@babel/plugin-proposal-optional-chaining": "^7.14.2",
|
||||
"@babel/preset-env": "^7.14.4",
|
||||
"@babel/preset-react": "^7.13.13",
|
||||
"@babel/preset-typescript": "^7.13.0",
|
||||
"@typescript-eslint/eslint-plugin": "^4.29.0",
|
||||
"@typescript-eslint/parser": "^4.29.0",
|
||||
"esbuild": "^0.12.15",
|
||||
"@babel/core": "^7.15.0",
|
||||
"@babel/plugin-proposal-class-properties": "^7.14.5",
|
||||
"@babel/plugin-proposal-nullish-coalescing-operator": "^7.14.5",
|
||||
"@babel/plugin-proposal-optional-chaining": "^7.14.5",
|
||||
"@babel/preset-env": "^7.15.0",
|
||||
"@babel/preset-react": "^7.14.5",
|
||||
"@babel/preset-typescript": "^7.15.0",
|
||||
"@typescript-eslint/eslint-plugin": "^4.30.0",
|
||||
"@typescript-eslint/parser": "^4.30.0",
|
||||
"esbuild": "^0.12.24",
|
||||
"esbuild-jest": "^0.5.0",
|
||||
"eslint": "^7.32.0",
|
||||
"eslint-plugin-jsx-a11y": "^6.4.1",
|
||||
"eslint-plugin-react": "^7.24.0",
|
||||
"eslint-plugin-react": "^7.25.1",
|
||||
"eslint-plugin-react-hooks": "^4.2.0",
|
||||
"eslint-plugin-unused-imports": "^1.1.2",
|
||||
"eslint-plugin-unused-imports": "^1.1.4",
|
||||
"husky": "^6.0.0",
|
||||
"jest": "^27.0.3",
|
||||
"jest": "^27.1.0",
|
||||
"lerna": "^4.0.0",
|
||||
"lint-staged": "^11.0.0",
|
||||
"prettier": "^2.3.1",
|
||||
"typescript": "^4.3.5",
|
||||
"lint-staged": "^11.1.2",
|
||||
"prettier": "^2.3.2",
|
||||
"typescript": "^4.4.2",
|
||||
"zx": "^2.0.0"
|
||||
},
|
||||
"dependencies": {
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
"esbuild": "^0.12.15",
|
||||
"esbuild-register": "^2.5.0",
|
||||
"npm-run-all": "^4.1.5",
|
||||
"typescript": "^4.3.5"
|
||||
"typescript": "^4.4.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@theatre/dataverse": "workspace:*",
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
"esbuild": "^0.12.15",
|
||||
"esbuild-register": "^2.5.0",
|
||||
"npm-run-all": "^4.1.5",
|
||||
"typescript": "^4.3.5"
|
||||
"typescript": "^4.4.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"lodash-es": "^4.17.21"
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
"@types/lodash-es": "^4.17.4",
|
||||
"@types/node": "^15.6.2",
|
||||
"@types/react": "^17.0.9",
|
||||
"typescript": "^4.3.5"
|
||||
"typescript": "^4.4.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"lodash-es": "^4.17.21"
|
||||
|
|
|
@ -25,6 +25,6 @@
|
|||
"esbuild": "^0.12.15",
|
||||
"esbuild-register": "^2.5.0",
|
||||
"three": "^0.130.1",
|
||||
"typescript": "^4.3.5"
|
||||
"typescript": "^4.4.2"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import {editable as e, RefreshSnapshot, Wrapper} from '@theatre/plugin-r3f'
|
||||
import {OrbitControls, Stars} from '@react-three/drei'
|
||||
import {getProject} from '@theatre/core'
|
||||
import React, {Suspense} from 'react'
|
||||
import React, {Suspense, useState} from 'react'
|
||||
import {Canvas} from '@react-three/fiber'
|
||||
import {useGLTF} from '@react-three/drei'
|
||||
import sceneGLB from './scene.glb'
|
||||
|
@ -49,12 +49,36 @@ function Model({url}: {url: string}) {
|
|||
}
|
||||
|
||||
function App() {
|
||||
const bg = '#272730'
|
||||
const bgs = ['#272730', '#b7c5d1']
|
||||
const [bgIndex, setBgIndex] = useState(0)
|
||||
const bg = bgs[bgIndex]
|
||||
return (
|
||||
<div>
|
||||
<div onClick={() => setBgIndex((bgIndex) => (bgIndex + 1) % bgs.length)}>
|
||||
<Canvas dpr={[1.5, 2]} linear shadows frameloop="demand">
|
||||
<Wrapper
|
||||
getSheet={() => getProject('Example project').sheet('R3F-Canvas')}
|
||||
getSheet={() =>
|
||||
getProject('Space', {
|
||||
state: {
|
||||
sheetsById: {
|
||||
'R3F-Canvas': {
|
||||
staticOverrides: {
|
||||
byObject: {
|
||||
'Light 1': {
|
||||
position: {
|
||||
x: -60,
|
||||
y: -63,
|
||||
z: -79,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
definitionVersion: '0.3.0-dev',
|
||||
revisionHistory: ['1__HCrX_ol8j4wK3-Pi'],
|
||||
},
|
||||
}).sheet('Scene')
|
||||
}
|
||||
>
|
||||
<fog attach="fog" args={[bg, 16, 30]} />
|
||||
<color attach="background" args={[bg]} />
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
"@types/react": "^17.0.9",
|
||||
"@types/styled-components": "^5.1.9",
|
||||
"npm-run-all": "^4.1.5",
|
||||
"typescript": "^4.3.5"
|
||||
"typescript": "^4.4.2"
|
||||
},
|
||||
"dependencies": {
|
||||
"@react-three/drei": "^7.3.1",
|
||||
|
|
|
@ -84,7 +84,7 @@
|
|||
"timing-function": "^0.2.3",
|
||||
"ts-node": "^10.0.0",
|
||||
"tslib": "^2.2.0",
|
||||
"typescript": "^4.3.5",
|
||||
"typescript": "^4.4.2",
|
||||
"url-loader": "^4.1.1",
|
||||
"uuid": "^8.3.2"
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue