From 5295f9ae91d13280111f6765ed9a77d3d723ecc2 Mon Sep 17 00:00:00 2001 From: Aria Minaei Date: Sun, 5 Sep 2021 23:33:17 +0200 Subject: [PATCH] r3f sheets are now re-usable --- packages/playground/src/r3f/App.tsx | 6 +++--- .../playground/src/space-exploration/App.tsx | 6 +++--- .../src/{Wrapper.tsx => SheetProvider.tsx} | 20 +++++++++++++------ .../plugin-r3f/src/components/editable.tsx | 11 ++-------- packages/plugin-r3f/src/index.tsx | 2 +- 5 files changed, 23 insertions(+), 22 deletions(-) rename packages/plugin-r3f/src/{Wrapper.tsx => SheetProvider.tsx} (66%) diff --git a/packages/playground/src/r3f/App.tsx b/packages/playground/src/r3f/App.tsx index b020777..51f435c 100644 --- a/packages/playground/src/r3f/App.tsx +++ b/packages/playground/src/r3f/App.tsx @@ -1,4 +1,4 @@ -import {editable as e, Wrapper} from '@theatre/plugin-r3f' +import {editable as e, SheetProvider} from '@theatre/plugin-r3f' import {getProject} from '@theatre/core' import * as THREE from 'three' import React, {useState, useEffect, useRef} from 'react' @@ -90,7 +90,7 @@ function App() { // @ts-ignore shadowMap > - getProject('Playground - R3F').sheet('R3F-Canvas')} > {/* @ts-ignore */} @@ -140,7 +140,7 @@ function App() { />