shapes folder, move tools into shape defs (#1574)
This diff adds a new property to `defineShape`: `tool`. The tool prop allows shapes to bring a tool along with them as part of their definition. E.g. the draw shape isn't much use without the draw tool, so adding the draw shape to your app gives you the draw tool tool. As part of this, i renamed the `shapeutils` folder to just `shapes`, and moved a bunch of shape-specific tools from the tools folder into the shapes folder. This more closely reflects how things will be once we move our default shapes out of core for tldraw-zero. ### Change Type - [x] `patch` — Bug fix ### Test Plan Tested locally ### Release Notes n/a
This commit is contained in:
parent
8d409462c0
commit
7b03ef9d0c
127 changed files with 352 additions and 253 deletions
|
@ -8,7 +8,7 @@ import {
|
|||
} from 'signia-react'
|
||||
import { useEditor } from '../..'
|
||||
import type { Editor } from '../editor/Editor'
|
||||
import { ShapeUtil } from '../editor/shapeutils/ShapeUtil'
|
||||
import { ShapeUtil } from '../editor/shapes/ShapeUtil'
|
||||
import { useEditorComponents } from '../hooks/useEditorComponents'
|
||||
import { OptionalErrorBoundary } from './ErrorBoundary'
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue