Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: React 19 support #2284

Open
wants to merge 39 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
49bc2bf
feat: R3F v9, React 19 support
CodyJasonBennett Jan 1, 2025
681f2f9
chore: raise three peer dep
CodyJasonBennett Jan 2, 2025
5d07ec9
fix: use new instance shape
CodyJasonBennett Jan 2, 2025
ab23b76
fix: use new instance shape
CodyJasonBennett Jan 3, 2025
4500e15
experiment: remove unsupported deps
CodyJasonBennett Jan 3, 2025
b8c4041
chore: use React 19 stable
CodyJasonBennett Jan 3, 2025
8cbdb6c
Revert "experiment: remove unsupported deps"
CodyJasonBennett Jan 3, 2025
bcd48dc
experiment: use Yarn v1
CodyJasonBennett Jan 4, 2025
405c4ed
chore: downgrade rimraf
CodyJasonBennett Jan 4, 2025
a91e428
chore: upgrade CSB version
CodyJasonBennett Jan 4, 2025
62f4f7b
chore(Caustics): lint
CodyJasonBennett Jan 4, 2025
3787e03
experiment: upgrade React in CI
CodyJasonBennett Jan 4, 2025
2cc899b
experiment: use RC in CI
CodyJasonBennett Jan 4, 2025
0cb59e9
fix: more omission of args in props
CodyJasonBennett Jan 4, 2025
d38d935
fix: more omission of args in props
CodyJasonBennett Jan 4, 2025
e187dcd
chore(stories): remove use of deprecated types
CodyJasonBennett Jan 4, 2025
f9d9138
fix: remove remaining incompatible deps
CodyJasonBennett Jan 4, 2025
f771f39
chore: resolve conflicts
CodyJasonBennett Jan 9, 2025
61adfe6
chore(CI): install latest react
CodyJasonBennett Jan 9, 2025
cfc912f
experiment: add frame delay to e2e snapshot
CodyJasonBennett Jan 10, 2025
b7104dd
experiment: add frame delay to e2e snapshot
CodyJasonBennett Jan 10, 2025
f61247b
experiment: add another frame delay to e2e
CodyJasonBennett Jan 10, 2025
44ccb32
experiment: set arbitrary delay in e2e
CodyJasonBennett Jan 10, 2025
42e2330
chore: restore e2e app
CodyJasonBennett Jan 10, 2025
9052f74
experiment: preserve drawing buffer in e2e
CodyJasonBennett Jan 10, 2025
c8ed068
Revert "experiment: preserve drawing buffer in e2e"
CodyJasonBennett Jan 10, 2025
816e93b
experiment: use R3F v9 unreleased
CodyJasonBennett Jan 10, 2025
e514875
experiment: fix R3F install path
CodyJasonBennett Jan 10, 2025
0533402
experiment: fix R3F install path
CodyJasonBennett Jan 10, 2025
72d300c
experiment: fix R3F install path
CodyJasonBennett Jan 10, 2025
13e7da4
chore: cleanup
CodyJasonBennett Jan 10, 2025
0607ba9
remove react-spring in favour of maath
drcmda Jan 10, 2025
353ef09
chore: upgrade to rc.2
CodyJasonBennett Jan 10, 2025
3e6d2bc
chore(CI): drop legacy peer deps
CodyJasonBennett Jan 10, 2025
e45bf69
experiment: set peer dep against rc.2
CodyJasonBennett Jan 10, 2025
e2fa3de
chore: upgrade lockfile
CodyJasonBennett Jan 10, 2025
4d37b89
chore: pin to rc.2
CodyJasonBennett Jan 10, 2025
9d7d36a
chore: upgrade to rc.3
CodyJasonBennett Jan 10, 2025
d2d2560
Merge branch 'master' into feat/react-19
CodyJasonBennett Jan 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .codesandbox/ci.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"sandboxes": ["4nc1u", "bfplr", "1wh6f"],
"packages": ["dist"],
"node": "18"
"node": "20"
}
4 changes: 2 additions & 2 deletions .storybook/stories/AccumulativeShadows.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as THREE from 'three'
import * as React from 'react'
import { ComponentProps } from 'react'
import { FlakesTexture } from 'three/examples/jsm/textures/FlakesTexture'
import { FlakesTexture } from 'three-stdlib'
import { Meta, StoryObj } from '@storybook/react'

import { Setup } from '../Setup'
Expand Down Expand Up @@ -48,7 +48,7 @@ function Suzi(props: ComponentProps<'group'>) {
material.color.set('orange')
material.roughness = 0
material.normalMap = new THREE.CanvasTexture(
new FlakesTexture(),
new FlakesTexture() as HTMLCanvasElement,
THREE.UVMapping,
THREE.RepeatWrapping,
THREE.RepeatWrapping
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/ArcballControls.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const CustomCamera = ({ ...props }: ComponentProps<typeof ArcballControls>) => {
* we will render our scene in a render target and use it as a map.
*/
const fbo = useFBO(400, 400)
const virtualCamera = useRef<OrthographicCamera | PerspectiveCameraType>()
const virtualCamera = useRef<PerspectiveCameraType>(null!)
const [virtualScene] = useState(() => new Scene())

useFrame(({ gl }) => {
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/BBAnchor.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ function BBAnchorScene({
drawBoundingBox: boolean
children?: React.ReactNode
}) {
const ref = React.useRef(null)
const ref = React.useRef<THREE.Mesh<THREE.IcosahedronGeometry>>(null!)

useHelper(drawBoundingBox && ref, BoxHelper, 'cyan')

Expand Down
4 changes: 2 additions & 2 deletions .storybook/stories/Bvh.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export default {
type Story = StoryObj<typeof Bvh>

function TorusBVH({ z = 0, ...props }: { z: number } & React.ComponentProps<typeof Bvh>) {
const mesh = React.useRef<React.ElementRef<typeof TorusKnot>>(null!)
const mesh = React.useRef<React.ComponentRef<typeof TorusKnot>>(null!)

useHelper(mesh, MeshBVHHelper)

Expand Down Expand Up @@ -122,7 +122,7 @@ const DebugRayCast = ({ grp }) => {
}

function Scene(props: React.ComponentProps<typeof Bvh>) {
const grp = React.useRef<React.ElementRef<'group'>>(null)
const grp = React.useRef<React.ComponentRef<'group'>>(null)

const { raycaster } = useThree()
raycaster.firstHitOnly = true
Expand Down
8 changes: 4 additions & 4 deletions .storybook/stories/CameraControls.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { createPortal, useFrame } from '@react-three/fiber'
import React, { ComponentProps, useRef, useState } from 'react'
import { Scene } from 'three'
import * as THREE from 'three'
import { Meta, StoryObj } from '@storybook/react'

import { Setup } from '../Setup'
Expand Down Expand Up @@ -47,9 +47,9 @@ const CameraControlsScene2 = (props: ComponentProps<typeof CameraControls>) => {
* we will render our scene in a render target and use it as a map.
*/
const fbo = useFBO(400, 400)
const virtualCamera = useRef<CameraControls['camera']>()
const [virtualScene] = useState(() => new Scene())
const cameraControlRef = useRef<CameraControls>(null)
const virtualCamera = useRef<THREE.PerspectiveCamera>(null!)
const [virtualScene] = useState(() => new THREE.Scene())
const cameraControlRef = useRef<CameraControls>(null!)

useFrame(({ gl }) => {
if (virtualCamera.current) {
Expand Down
12 changes: 5 additions & 7 deletions .storybook/stories/CubeCamera.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,16 @@ export default {

type Story = StoryObj<typeof CubeCamera>

declare global {
namespace JSX {
interface IntrinsicElements {
axisHelper: object
}
declare module '@react-three/fiber' {
interface ThreeElements {
axisHelper: object
}
}

function Sphere({ offset = 0, ...props }: ComponentProps<typeof CubeCamera> & { offset?: number }) {
const ref = React.useRef<React.ElementRef<'mesh'>>(null)
const ref = React.useRef<THREE.Mesh>(null!)
useFrame(({ clock }) => {
ref.current!.position.y = Math.sin(offset + clock.elapsedTime) * 5
ref.current.position.y = Math.sin(offset + clock.elapsedTime) * 5
})

return (
Expand Down
10 changes: 4 additions & 6 deletions .storybook/stories/CurveModifier.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,13 @@ import { CurveModifier, CurveModifierRef } from '../../src'

extend({ StdText: TextGeometry })

type TextGeometryImpl = JSX.IntrinsicElements['extrudeGeometry'] & {
type TextGeometryImpl = ThreeElements['extrudeGeometry'] & {
args: [string, TextGeometryParameters]
}

declare global {
namespace JSX {
interface IntrinsicElements {
stdText: TextGeometryImpl
}
declare module '@react-three/fiber' {
interface ThreeElements {
stdText: TextGeometryImpl
}
}

Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/Extrude.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export default {
type Story = StoryObj<typeof Extrude>

function ExtrudeScene(props: React.ComponentProps<typeof Extrude>) {
const ref = useTurntable<React.ElementRef<typeof Extrude>>()
const ref = useTurntable<React.ComponentRef<typeof Extrude>>()

return (
<>
Expand Down
8 changes: 4 additions & 4 deletions .storybook/stories/FaceControls.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import * as easing from 'maath/easing'
import { Setup } from '../Setup'

import { FaceLandmarker, FaceControls, Box, WebcamVideoTexture } from '../../src'
import { ComponentProps, ElementRef, useRef, useState } from 'react'
import { ComponentProps, ComponentRef, useRef, useState } from 'react'
import { FaceLandmarkerResult } from '@mediapipe/tasks-vision'
import { useFrame, useThree } from '@react-three/fiber'

Expand Down Expand Up @@ -55,8 +55,8 @@ export const FaceControlsSt = {
//

function FaceControlsScene2(props: ComponentProps<typeof FaceControls>) {
const faceLandmarkerRef = useRef<ElementRef<typeof FaceLandmarker>>(null)
const videoTextureRef = useRef<ElementRef<typeof WebcamVideoTexture>>(null)
const faceLandmarkerRef = useRef<ComponentRef<typeof FaceLandmarker>>(null)
const videoTextureRef = useRef<ComponentRef<typeof WebcamVideoTexture>>(null)

const [faceLandmarkerResult, setFaceLandmarkerResult] = useState<FaceLandmarkerResult>()

Expand Down Expand Up @@ -99,7 +99,7 @@ export const FaceControlsSt2 = {
//

function FaceControlsScene3(props: ComponentProps<typeof FaceControls>) {
const faceControlsRef = useRef<ElementRef<typeof FaceControls>>(null)
const faceControlsRef = useRef<ComponentRef<typeof FaceControls>>(null)

const camera = useThree((state) => state.camera)
const [current] = useState(() => new THREE.Object3D())
Expand Down
4 changes: 2 additions & 2 deletions .storybook/stories/Fbo.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export default {
type Story = StoryObj<typeof Fbo>

function SpinningThing() {
const mesh = React.useRef<React.ElementRef<typeof TorusKnot>>(null!)
const mesh = React.useRef<React.ComponentRef<typeof TorusKnot>>(null!)

useFrame(() => {
mesh.current.rotation.x = mesh.current.rotation.y = mesh.current.rotation.z += 0.01
Expand All @@ -40,7 +40,7 @@ function FboScene(props: React.ComponentProps<typeof Fbo>) {
}

function TargetWrapper({ target }: { target: THREE.WebGLRenderTarget }) {
const cam = React.useRef<React.ElementRef<typeof PerspectiveCamera>>(null!)
const cam = React.useRef<React.ComponentRef<typeof PerspectiveCamera>>(null!)

const scene = React.useMemo(() => {
const scene = new THREE.Scene()
Expand Down
6 changes: 3 additions & 3 deletions .storybook/stories/HTML.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ function HTMLScene({
color?: React.ComponentProps<'meshBasicMaterial'>['color']
children?: React.ReactNode
} & HtmlProps) {
const ref = useTurntable<React.ElementRef<'group'>>()
const ref = useTurntable<React.ComponentRef<'group'>>()

return (
<group ref={ref}>
Expand Down Expand Up @@ -164,8 +164,8 @@ export const HTMLCalculatePositionSt = {
//

function HTMLOccluderScene(props: HtmlProps) {
const turntableRef = useTurntable<React.ElementRef<'group'>>()
const occluderRef = React.useRef<React.ElementRef<typeof Icosahedron>>(null)
const turntableRef = useTurntable<React.ComponentRef<'group'>>()
const occluderRef = React.useRef<React.ComponentRef<typeof Icosahedron>>(null)

return (
<>
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/Lathe.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export default {
type Story = StoryObj<typeof Lathe>

function LatheScene(props: React.ComponentProps<typeof Lathe>) {
const ref = useTurntable<React.ElementRef<typeof Lathe>>()
const ref = useTurntable<React.ComponentRef<typeof Lathe>>()

return (
<Lathe ref={ref} {...props}>
Expand Down
4 changes: 2 additions & 2 deletions .storybook/stories/MarchingCubes.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ function MarchingCubesScene({
planeY?: boolean
planeZ?: boolean
} & React.ComponentProps<typeof MarchingCubes>) {
const cubeRefOne = React.useRef<React.ElementRef<typeof MarchingCube>>(null)
const cubeRefTwo = React.useRef<React.ElementRef<typeof MarchingCube>>(null)
const cubeRefOne = React.useRef<React.ComponentRef<typeof MarchingCube>>(null)
const cubeRefTwo = React.useRef<React.ComponentRef<typeof MarchingCube>>(null)

useFrame(({ clock }) => {
if (!cubeRefOne.current || !cubeRefTwo.current) return
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/MeshDistortMaterial.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export const MeshDistortMaterialSt = {
//

function MeshDistortMaterialRefScene(props: React.ComponentProps<typeof MeshDistortMaterial>) {
const material = React.useRef<React.ElementRef<typeof MeshDistortMaterial>>(null!)
const material = React.useRef<React.ComponentRef<typeof MeshDistortMaterial>>(null!)

useFrame(({ clock }) => {
material.current.distort = Math.sin(clock.getElapsedTime())
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/MeshRefractionMaterial.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ function Diamond({
rotation: React.ComponentProps<'mesh'>['rotation']
position: React.ComponentProps<'mesh'>['position']
} & React.ComponentProps<typeof MeshRefractionMaterial>) {
const ref = React.useRef<React.ElementRef<'mesh'>>(null)
const ref = React.useRef<React.ComponentRef<'mesh'>>(null)
const { nodes } = useGLTF('/dflat.glb') as any
// Use a custom envmap/scene-backdrop for the diamond material
// This way we can have a clear BG while cube-cam can still film other objects
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/MeshWobbleMaterial.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ export const MeshWobbleMaterialSt = {
//

function MeshWobbleMaterialRefScene(props: React.ComponentProps<typeof MeshWobbleMaterial>) {
const material = React.useRef<React.ElementRef<typeof MeshWobbleMaterial>>(null)
const material = React.useRef<React.ComponentRef<typeof MeshWobbleMaterial>>(null)

useFrame(({ clock }) => {
if (material.current === null) return
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/OrbitControls.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ const CustomCamera = (props: OrbitControlsProps) => {
* we will render our scene in a render target and use it as a map.
*/
const fbo = useFBO(400, 400)
const virtualCamera = useRef<React.ElementRef<typeof PerspectiveCamera> | null>(null)
const virtualCamera = useRef<React.ComponentRef<typeof PerspectiveCamera> | null>(null)
const [virtualScene] = useState(() => new Scene())

useFrame(({ gl }) => {
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/Reflector.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ function ReflectorScene({
const roughnessMap = useTexture('roughness_floor.jpeg')
const normalMap = useTexture('NORM.jpg')
const distortionMap = useTexture('dist_map.jpeg')
const $box = React.useRef<React.ElementRef<typeof TorusKnot>>(null!)
const $box = React.useRef<React.ComponentRef<typeof TorusKnot>>(null!)

React.useEffect(() => {
distortionMap.wrapS = distortionMap.wrapT = RepeatWrapping
Expand Down
4 changes: 2 additions & 2 deletions .storybook/stories/RoundedBox.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export default {
type Story = StoryObj<typeof RoundedBox>

function RoundedBoxScene(props: React.ComponentProps<typeof RoundedBox>) {
const ref = useTurntable<React.ElementRef<typeof RoundedBox>>()
const ref = useTurntable<React.ComponentRef<typeof RoundedBox>>()

return (
<RoundedBox ref={ref} {...props}>
Expand All @@ -44,7 +44,7 @@ export const RoundedBoxSt = {
//

function RoundedBoxScene2(props: React.ComponentProps<typeof RoundedBox>) {
const ref = useTurntable<React.ElementRef<typeof RoundedBox>>()
const ref = useTurntable<React.ComponentRef<typeof RoundedBox>>()

return (
<>
Expand Down
6 changes: 3 additions & 3 deletions .storybook/stories/Sampler.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { Meta, StoryObj } from '@storybook/react'
import { Setup } from '../Setup'

import { Sampler, ComputedAttribute, TransformFn } from '../../src'
import { BufferAttribute, Vector3 } from 'three'
import { BufferAttribute, InstancedMesh, Mesh, Vector3 } from 'three'

export default {
title: 'Misc/Sampler',
Expand Down Expand Up @@ -49,8 +49,8 @@ export const SamplerSt = {
//

function RefAPIScene(props: React.ComponentProps<typeof Sampler>) {
const meshRef = React.useRef(null)
const instancesRef = React.useRef(null)
const meshRef = React.useRef<Mesh>(null!)
const instancesRef = React.useRef<InstancedMesh>(null!)

return (
<>
Expand Down
18 changes: 7 additions & 11 deletions .storybook/stories/ScreenQuad.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import * as React from 'react'
import * as THREE from 'three'
import { extend, useThree, useFrame } from '@react-three/fiber'
import { extend, useThree, useFrame, ThreeElements } from '@react-three/fiber'
import { Meta, StoryObj } from '@storybook/react'

import { Setup } from '../Setup'
Expand Down Expand Up @@ -47,22 +47,18 @@ const ColorShiftMaterial = shaderMaterial(

extend({ ColorShiftMaterial })

type ColorShiftMaterialImpl = {
time: number
resolution: number[]
} & JSX.IntrinsicElements['shaderMaterial']

declare global {
namespace JSX {
interface IntrinsicElements {
colorShiftMaterial: ColorShiftMaterialImpl
declare module '@react-three/fiber' {
interface ThreeElements {
colorShiftMaterial: ThreeElements['shaderMaterial'] & {
time: number
resolution: number[]
}
}
}

function ScreenQuadScene(props: React.ComponentProps<typeof ScreenQuad>) {
const size = useThree((state) => state.size)
const ref = React.useRef<React.ElementRef<'colorShiftMaterial'>>(null!)
const ref = React.useRef<ThreeElements['colorShiftMaterial']>(null!)

useFrame((state) => {
if (ref.current.uniforms) {
Expand Down
13 changes: 11 additions & 2 deletions .storybook/stories/Segments.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export const BasicSegmentsSt = {
//

function AnimatedSegments(props: React.ComponentProps<typeof Segments>) {
const ref = React.useRef<React.ElementRef<typeof Segment>[]>([])
const ref = React.useRef<React.ComponentRef<typeof Segment>[]>([])
useFrame(({ clock }) => {
ref.current.forEach((r, i) => {
const time = clock.elapsedTime
Expand All @@ -64,7 +64,16 @@ function AnimatedSegments(props: React.ComponentProps<typeof Segments>) {
return (
<Segments {...props}>
{Array.from({ length: 10000 }).map((_, i) => (
<Segment key={i} ref={(r) => (ref.current[i] = r!)} color="orange" start={[0, 0, 0]} end={[0, 0, 0]} />
<Segment
key={i}
ref={(r) => {
ref.current[i] = r!
return () => void (ref.current[i] = null!)
}}
color="orange"
start={[0, 0, 0]}
end={[0, 0, 0]}
/>
))}
</Segments>
)
Expand Down
4 changes: 2 additions & 2 deletions .storybook/stories/Shadow.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ export default {
type Story = StoryObj<typeof Shadow>

function ShadowScene(props: React.ComponentProps<typeof Shadow>) {
const shadow = React.useRef<React.ElementRef<typeof Shadow>>(null!)
const mesh = React.useRef<React.ElementRef<typeof Icosahedron>>(null!)
const shadow = React.useRef<React.ComponentRef<typeof Shadow>>(null!)
const mesh = React.useRef<React.ComponentRef<typeof Icosahedron>>(null!)

useFrame(({ clock }) => {
shadow.current.scale.x = Math.sin(clock.getElapsedTime()) + 3
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/Shapes.Box.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export default {
type Story = StoryObj<typeof Box>

function BoxScene(props: React.ComponentProps<typeof Box>) {
const ref = useTurntable<React.ElementRef<typeof Box>>()
const ref = useTurntable<React.ComponentRef<typeof Box>>()

return (
<Box ref={ref} {...props}>
Expand Down
2 changes: 1 addition & 1 deletion .storybook/stories/Shapes.Circle.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export default {
type Story = StoryObj<typeof Circle>

function CircleScene(props: React.ComponentProps<typeof Circle>) {
const ref = useTurntable<React.ElementRef<typeof Circle>>()
const ref = useTurntable<React.ComponentRef<typeof Circle>>()

return (
<Circle ref={ref} {...props}>
Expand Down
Loading
Loading