19 lines
559 B
TypeScript
19 lines
559 B
TypeScript
import { Tldraw } from 'tldraw'
|
|
import 'tldraw/tldraw.css'
|
|
import './shapes/shape-types' // Type-Augmentation für Custom Shapes
|
|
import { PufferShapeUtil } from './shapes/PufferShapeUtil'
|
|
import { KreiselShapeUtil } from './shapes/KreiselShapeUtil'
|
|
import { ShapePanel } from './components/ShapePanel'
|
|
|
|
const customShapeUtils = [PufferShapeUtil, KreiselShapeUtil]
|
|
|
|
export default function App() {
|
|
return (
|
|
<div style={{ position: 'fixed', inset: 0 }}>
|
|
<Tldraw shapeUtils={customShapeUtils}>
|
|
<ShapePanel />
|
|
</Tldraw>
|
|
</div>
|
|
)
|
|
}
|