2021-05-10 22:23:25 +02:00
|
|
|
import { Canvas } from '@react-three/fiber'
|
|
|
|
import { OrbitControls } from '@react-three/drei'
|
|
|
|
import Box from '../components/Box'
|
2020-02-07 16:41:19 +01:00
|
|
|
|
2021-05-10 22:23:25 +02:00
|
|
|
export default function BoxesPage() {
|
2020-02-07 16:41:19 +01:00
|
|
|
return (
|
2021-05-10 22:23:25 +02:00
|
|
|
<>
|
|
|
|
<h1>Click on me - Hover me :)</h1>
|
|
|
|
<Canvas camera={{ position: [0, 0, 35] }}>
|
|
|
|
<ambientLight intensity={2} />
|
|
|
|
<pointLight position={[40, 40, 40]} />
|
|
|
|
<Box position={[10, 0, 0]} />
|
|
|
|
<Box position={[-10, 0, 0]} />
|
|
|
|
<Box position={[0, 10, 0]} />
|
|
|
|
<Box position={[0, -10, 0]} />
|
|
|
|
<OrbitControls />
|
|
|
|
</Canvas>
|
|
|
|
</>
|
2020-02-07 16:41:19 +01:00
|
|
|
)
|
|
|
|
}
|