tldraw 3.15.0-next.d30ed5ad740e → 3.15.0-next.f1dfcef63951
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/index.d.ts +84 -77
- package/dist-cjs/index.js +30 -31
- package/dist-cjs/index.js.map +2 -2
- package/dist-cjs/lib/shapes/frame/FrameShapeUtil.js +5 -5
- package/dist-cjs/lib/shapes/frame/FrameShapeUtil.js.map +2 -2
- package/dist-cjs/lib/shapes/text/TextShapeUtil.js +11 -5
- package/dist-cjs/lib/shapes/text/TextShapeUtil.js.map +2 -2
- package/dist-cjs/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.js +1 -11
- package/dist-cjs/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.js.map +2 -2
- package/dist-cjs/lib/ui/components/MainMenu/DefaultMainMenuContent.js +0 -1
- package/dist-cjs/lib/ui/components/MainMenu/DefaultMainMenuContent.js.map +2 -2
- package/dist-cjs/lib/ui/components/menu-items.js +0 -16
- package/dist-cjs/lib/ui/components/menu-items.js.map +2 -2
- package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuItem.js +2 -0
- package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuItem.js.map +2 -2
- package/dist-cjs/lib/ui/context/actions.js +1 -28
- package/dist-cjs/lib/ui/context/actions.js.map +2 -2
- package/dist-cjs/lib/ui/context/events.js.map +2 -2
- package/dist-cjs/lib/ui/hooks/useClipboardEvents.js +7 -24
- package/dist-cjs/lib/ui/hooks/useClipboardEvents.js.map +2 -2
- package/dist-cjs/lib/ui/hooks/useKeyboardShortcuts.js +2 -2
- package/dist-cjs/lib/ui/hooks/useKeyboardShortcuts.js.map +2 -2
- package/dist-cjs/lib/ui/hooks/useTranslation/TLUiTranslationKey.js.map +1 -1
- package/dist-cjs/lib/ui/hooks/useTranslation/defaultTranslation.js +0 -4
- package/dist-cjs/lib/ui/hooks/useTranslation/defaultTranslation.js.map +2 -2
- package/dist-cjs/lib/ui/version.js +3 -3
- package/dist-cjs/lib/ui/version.js.map +1 -1
- package/dist-esm/index.d.mts +84 -77
- package/dist-esm/index.mjs +132 -134
- package/dist-esm/index.mjs.map +2 -2
- package/dist-esm/lib/shapes/frame/FrameShapeUtil.mjs +5 -5
- package/dist-esm/lib/shapes/frame/FrameShapeUtil.mjs.map +2 -2
- package/dist-esm/lib/shapes/text/TextShapeUtil.mjs +11 -5
- package/dist-esm/lib/shapes/text/TextShapeUtil.mjs.map +2 -2
- package/dist-esm/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.mjs +1 -11
- package/dist-esm/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.mjs.map +2 -2
- package/dist-esm/lib/ui/components/MainMenu/DefaultMainMenuContent.mjs +0 -2
- package/dist-esm/lib/ui/components/MainMenu/DefaultMainMenuContent.mjs.map +2 -2
- package/dist-esm/lib/ui/components/menu-items.mjs +0 -16
- package/dist-esm/lib/ui/components/menu-items.mjs.map +2 -2
- package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuItem.mjs +2 -0
- package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuItem.mjs.map +2 -2
- package/dist-esm/lib/ui/context/actions.mjs +1 -28
- package/dist-esm/lib/ui/context/actions.mjs.map +2 -2
- package/dist-esm/lib/ui/context/events.mjs.map +2 -2
- package/dist-esm/lib/ui/hooks/useClipboardEvents.mjs +7 -24
- package/dist-esm/lib/ui/hooks/useClipboardEvents.mjs.map +2 -2
- package/dist-esm/lib/ui/hooks/useKeyboardShortcuts.mjs +2 -2
- package/dist-esm/lib/ui/hooks/useKeyboardShortcuts.mjs.map +2 -2
- package/dist-esm/lib/ui/hooks/useTranslation/defaultTranslation.mjs +0 -4
- package/dist-esm/lib/ui/hooks/useTranslation/defaultTranslation.mjs.map +2 -2
- package/dist-esm/lib/ui/version.mjs +3 -3
- package/dist-esm/lib/ui/version.mjs.map +1 -1
- package/package.json +3 -3
- package/src/index.ts +158 -159
- package/src/lib/shapes/frame/FrameShapeUtil.tsx +7 -5
- package/src/lib/shapes/text/TextShapeUtil.tsx +12 -5
- package/src/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.tsx +0 -8
- package/src/lib/ui/components/MainMenu/DefaultMainMenuContent.tsx +0 -2
- package/src/lib/ui/components/menu-items.tsx +0 -17
- package/src/lib/ui/components/primitives/menus/TldrawUiMenuItem.tsx +2 -0
- package/src/lib/ui/context/actions.tsx +1 -29
- package/src/lib/ui/context/events.tsx +0 -2
- package/src/lib/ui/hooks/useClipboardEvents.ts +10 -31
- package/src/lib/ui/hooks/useKeyboardShortcuts.ts +2 -3
- package/src/lib/ui/hooks/useTranslation/TLUiTranslationKey.ts +0 -4
- package/src/lib/ui/hooks/useTranslation/defaultTranslation.ts +0 -4
- package/src/lib/ui/version.ts +3 -3
- package/src/test/Editor.test.tsx +1 -68
- package/src/test/commands/clipboard.test.ts +1 -1
- package/src/test/editor.test.ts +77 -0
package/dist-esm/index.mjs
CHANGED
|
@@ -7,6 +7,7 @@ import { usePrefersReducedMotion } from "./lib/shapes/shared/usePrefersReducedMo
|
|
|
7
7
|
import { DefaultA11yAnnouncer, useSelectedShapesAnnouncer } from "./lib/ui/components/A11y.mjs";
|
|
8
8
|
import { ColorSchemeMenu } from "./lib/ui/components/ColorSchemeMenu.mjs";
|
|
9
9
|
import { DefaultDialogs } from "./lib/ui/components/Dialogs.mjs";
|
|
10
|
+
import { DefaultToasts } from "./lib/ui/components/Toasts.mjs";
|
|
10
11
|
import {
|
|
11
12
|
TldrawUiMenuActionCheckboxItem
|
|
12
13
|
} from "./lib/ui/components/primitives/menus/TldrawUiMenuActionCheckboxItem.mjs";
|
|
@@ -16,9 +17,10 @@ import {
|
|
|
16
17
|
import {
|
|
17
18
|
TldrawUiMenuToolItem
|
|
18
19
|
} from "./lib/ui/components/primitives/menus/TldrawUiMenuToolItem.mjs";
|
|
19
|
-
import { DefaultToasts } from "./lib/ui/components/Toasts.mjs";
|
|
20
20
|
import { TldrawUiTranslationProvider } from "./lib/ui/hooks/useTranslation/useTranslation.mjs";
|
|
21
21
|
export * from "@tldraw/editor";
|
|
22
|
+
import { Tldraw } from "./lib/Tldraw.mjs";
|
|
23
|
+
import { TldrawImage } from "./lib/TldrawImage.mjs";
|
|
22
24
|
import { ArrowBindingUtil } from "./lib/bindings/arrow/ArrowBindingUtil.mjs";
|
|
23
25
|
import { TldrawHandles } from "./lib/canvas/TldrawHandles.mjs";
|
|
24
26
|
import { TldrawArrowHints, TldrawOverlays } from "./lib/canvas/TldrawOverlays.mjs";
|
|
@@ -31,11 +33,11 @@ import {
|
|
|
31
33
|
embedShapePermissionDefaults
|
|
32
34
|
} from "./lib/defaultEmbedDefinitions.mjs";
|
|
33
35
|
import {
|
|
36
|
+
DEFAULT_MAX_ASSET_SIZE,
|
|
37
|
+
DEFAULT_MAX_IMAGE_DIMENSION,
|
|
34
38
|
centerSelectionAroundPoint,
|
|
35
39
|
createEmptyBookmarkShape,
|
|
36
40
|
createShapesForAssets,
|
|
37
|
-
DEFAULT_MAX_ASSET_SIZE,
|
|
38
|
-
DEFAULT_MAX_IMAGE_DIMENSION,
|
|
39
41
|
defaultHandleExternalEmbedContent,
|
|
40
42
|
defaultHandleExternalExcalidrawContent,
|
|
41
43
|
defaultHandleExternalFileAsset,
|
|
@@ -76,6 +78,14 @@ import { LineShapeTool } from "./lib/shapes/line/LineShapeTool.mjs";
|
|
|
76
78
|
import { LineShapeUtil } from "./lib/shapes/line/LineShapeUtil.mjs";
|
|
77
79
|
import { NoteShapeTool } from "./lib/shapes/note/NoteShapeTool.mjs";
|
|
78
80
|
import { NoteShapeUtil } from "./lib/shapes/note/NoteShapeUtil.mjs";
|
|
81
|
+
import {
|
|
82
|
+
PlainTextLabel,
|
|
83
|
+
TextLabel
|
|
84
|
+
} from "./lib/shapes/shared/PlainTextLabel.mjs";
|
|
85
|
+
import {
|
|
86
|
+
RichTextLabel,
|
|
87
|
+
RichTextSVG
|
|
88
|
+
} from "./lib/shapes/shared/RichTextLabel.mjs";
|
|
79
89
|
import {
|
|
80
90
|
ASPECT_RATIO_OPTIONS,
|
|
81
91
|
ASPECT_RATIO_TO_VALUE,
|
|
@@ -92,17 +102,9 @@ import {
|
|
|
92
102
|
TEXT_PROPS
|
|
93
103
|
} from "./lib/shapes/shared/default-shape-constants.mjs";
|
|
94
104
|
import {
|
|
95
|
-
|
|
96
|
-
|
|
105
|
+
DefaultFontFaces,
|
|
106
|
+
allDefaultFontFaces
|
|
97
107
|
} from "./lib/shapes/shared/defaultFonts.mjs";
|
|
98
|
-
import {
|
|
99
|
-
PlainTextLabel,
|
|
100
|
-
TextLabel
|
|
101
|
-
} from "./lib/shapes/shared/PlainTextLabel.mjs";
|
|
102
|
-
import {
|
|
103
|
-
RichTextLabel,
|
|
104
|
-
RichTextSVG
|
|
105
|
-
} from "./lib/shapes/shared/RichTextLabel.mjs";
|
|
106
108
|
import { useDefaultColorTheme } from "./lib/shapes/shared/useDefaultColorTheme.mjs";
|
|
107
109
|
import { useEditablePlainText, useEditableText } from "./lib/shapes/shared/useEditablePlainText.mjs";
|
|
108
110
|
import { useEditableRichText } from "./lib/shapes/shared/useEditableRichText.mjs";
|
|
@@ -115,13 +117,12 @@ import { RichTextArea } from "./lib/shapes/text/RichTextArea.mjs";
|
|
|
115
117
|
import { TextShapeTool } from "./lib/shapes/text/TextShapeTool.mjs";
|
|
116
118
|
import { TextShapeUtil } from "./lib/shapes/text/TextShapeUtil.mjs";
|
|
117
119
|
import { VideoShapeUtil } from "./lib/shapes/video/VideoShapeUtil.mjs";
|
|
118
|
-
import { Tldraw } from "./lib/Tldraw.mjs";
|
|
119
|
-
import { TldrawImage } from "./lib/TldrawImage.mjs";
|
|
120
120
|
import { EraserTool } from "./lib/tools/EraserTool/EraserTool.mjs";
|
|
121
121
|
import { HandTool } from "./lib/tools/HandTool/HandTool.mjs";
|
|
122
122
|
import { LaserTool } from "./lib/tools/LaserTool/LaserTool.mjs";
|
|
123
123
|
import { SelectTool } from "./lib/tools/SelectTool/SelectTool.mjs";
|
|
124
124
|
import { ZoomTool } from "./lib/tools/ZoomTool/ZoomTool.mjs";
|
|
125
|
+
import { TldrawUi } from "./lib/ui/TldrawUi.mjs";
|
|
125
126
|
import {
|
|
126
127
|
setDefaultUiAssetUrls
|
|
127
128
|
} from "./lib/ui/assetUrls.mjs";
|
|
@@ -153,10 +154,6 @@ import {
|
|
|
153
154
|
FeatureFlags
|
|
154
155
|
} from "./lib/ui/components/DebugMenu/DefaultDebugMenuContent.mjs";
|
|
155
156
|
import { DefaultMenuPanel } from "./lib/ui/components/DefaultMenuPanel.mjs";
|
|
156
|
-
import {
|
|
157
|
-
DefaultHelperButtons
|
|
158
|
-
} from "./lib/ui/components/HelperButtons/DefaultHelperButtons.mjs";
|
|
159
|
-
import { DefaultHelperButtonsContent } from "./lib/ui/components/HelperButtons/DefaultHelperButtonsContent.mjs";
|
|
160
157
|
import {
|
|
161
158
|
DefaultHelpMenu
|
|
162
159
|
} from "./lib/ui/components/HelpMenu/DefaultHelpMenu.mjs";
|
|
@@ -164,6 +161,10 @@ import {
|
|
|
164
161
|
DefaultHelpMenuContent,
|
|
165
162
|
KeyboardShortcutsMenuItem
|
|
166
163
|
} from "./lib/ui/components/HelpMenu/DefaultHelpMenuContent.mjs";
|
|
164
|
+
import {
|
|
165
|
+
DefaultHelperButtons
|
|
166
|
+
} from "./lib/ui/components/HelperButtons/DefaultHelperButtons.mjs";
|
|
167
|
+
import { DefaultHelperButtonsContent } from "./lib/ui/components/HelperButtons/DefaultHelperButtonsContent.mjs";
|
|
167
168
|
import {
|
|
168
169
|
DefaultKeyboardShortcutsDialog
|
|
169
170
|
} from "./lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialog.mjs";
|
|
@@ -182,6 +183,99 @@ import {
|
|
|
182
183
|
UndoRedoGroup,
|
|
183
184
|
ViewSubmenu
|
|
184
185
|
} from "./lib/ui/components/MainMenu/DefaultMainMenuContent.mjs";
|
|
186
|
+
import { DefaultMinimap } from "./lib/ui/components/Minimap/DefaultMinimap.mjs";
|
|
187
|
+
import { MobileStylePanel } from "./lib/ui/components/MobileStylePanel.mjs";
|
|
188
|
+
import { DefaultNavigationPanel } from "./lib/ui/components/NavigationPanel/DefaultNavigationPanel.mjs";
|
|
189
|
+
import { OfflineIndicator } from "./lib/ui/components/OfflineIndicator/OfflineIndicator.mjs";
|
|
190
|
+
import { DefaultPageMenu } from "./lib/ui/components/PageMenu/DefaultPageMenu.mjs";
|
|
191
|
+
import { PageItemInput } from "./lib/ui/components/PageMenu/PageItemInput.mjs";
|
|
192
|
+
import {
|
|
193
|
+
PageItemSubmenu
|
|
194
|
+
} from "./lib/ui/components/PageMenu/PageItemSubmenu.mjs";
|
|
195
|
+
import {
|
|
196
|
+
DefaultQuickActions
|
|
197
|
+
} from "./lib/ui/components/QuickActions/DefaultQuickActions.mjs";
|
|
198
|
+
import { DefaultQuickActionsContent } from "./lib/ui/components/QuickActions/DefaultQuickActionsContent.mjs";
|
|
199
|
+
import { DefaultSharePanel } from "./lib/ui/components/SharePanel/DefaultSharePanel.mjs";
|
|
200
|
+
import { PeopleMenu } from "./lib/ui/components/SharePanel/PeopleMenu.mjs";
|
|
201
|
+
import { Spinner } from "./lib/ui/components/Spinner.mjs";
|
|
202
|
+
import {
|
|
203
|
+
DefaultStylePanel
|
|
204
|
+
} from "./lib/ui/components/StylePanel/DefaultStylePanel.mjs";
|
|
205
|
+
import {
|
|
206
|
+
ArrowheadStylePickerSet,
|
|
207
|
+
CommonStylePickerSet,
|
|
208
|
+
DefaultStylePanelContent,
|
|
209
|
+
GeoStylePickerSet,
|
|
210
|
+
OpacitySlider,
|
|
211
|
+
SplineStylePickerSet,
|
|
212
|
+
TextStylePickerSet
|
|
213
|
+
} from "./lib/ui/components/StylePanel/DefaultStylePanelContent.mjs";
|
|
214
|
+
import {
|
|
215
|
+
DefaultImageToolbar
|
|
216
|
+
} from "./lib/ui/components/Toolbar/DefaultImageToolbar.mjs";
|
|
217
|
+
import {
|
|
218
|
+
DefaultImageToolbarContent
|
|
219
|
+
} from "./lib/ui/components/Toolbar/DefaultImageToolbarContent.mjs";
|
|
220
|
+
import {
|
|
221
|
+
DefaultRichTextToolbar
|
|
222
|
+
} from "./lib/ui/components/Toolbar/DefaultRichTextToolbar.mjs";
|
|
223
|
+
import {
|
|
224
|
+
DefaultRichTextToolbarContent
|
|
225
|
+
} from "./lib/ui/components/Toolbar/DefaultRichTextToolbarContent.mjs";
|
|
226
|
+
import {
|
|
227
|
+
DefaultToolbar
|
|
228
|
+
} from "./lib/ui/components/Toolbar/DefaultToolbar.mjs";
|
|
229
|
+
import {
|
|
230
|
+
ArrowDownToolbarItem,
|
|
231
|
+
ArrowLeftToolbarItem,
|
|
232
|
+
ArrowRightToolbarItem,
|
|
233
|
+
ArrowToolbarItem,
|
|
234
|
+
ArrowUpToolbarItem,
|
|
235
|
+
AssetToolbarItem,
|
|
236
|
+
CheckBoxToolbarItem,
|
|
237
|
+
CloudToolbarItem,
|
|
238
|
+
DefaultToolbarContent,
|
|
239
|
+
DiamondToolbarItem,
|
|
240
|
+
DrawToolbarItem,
|
|
241
|
+
EllipseToolbarItem,
|
|
242
|
+
EraserToolbarItem,
|
|
243
|
+
FrameToolbarItem,
|
|
244
|
+
HandToolbarItem,
|
|
245
|
+
HexagonToolbarItem,
|
|
246
|
+
HighlightToolbarItem,
|
|
247
|
+
LaserToolbarItem,
|
|
248
|
+
LineToolbarItem,
|
|
249
|
+
NoteToolbarItem,
|
|
250
|
+
OvalToolbarItem,
|
|
251
|
+
RectangleToolbarItem,
|
|
252
|
+
RhombusToolbarItem,
|
|
253
|
+
SelectToolbarItem,
|
|
254
|
+
StarToolbarItem,
|
|
255
|
+
TextToolbarItem,
|
|
256
|
+
ToolbarItem,
|
|
257
|
+
TrapezoidToolbarItem,
|
|
258
|
+
TriangleToolbarItem,
|
|
259
|
+
XBoxToolbarItem,
|
|
260
|
+
useIsToolSelected
|
|
261
|
+
} from "./lib/ui/components/Toolbar/DefaultToolbarContent.mjs";
|
|
262
|
+
import {
|
|
263
|
+
DefaultVideoToolbar
|
|
264
|
+
} from "./lib/ui/components/Toolbar/DefaultVideoToolbar.mjs";
|
|
265
|
+
import {
|
|
266
|
+
DefaultVideoToolbarContent
|
|
267
|
+
} from "./lib/ui/components/Toolbar/DefaultVideoToolbarContent.mjs";
|
|
268
|
+
import {
|
|
269
|
+
OverflowingToolbar
|
|
270
|
+
} from "./lib/ui/components/Toolbar/OverflowingToolbar.mjs";
|
|
271
|
+
import {
|
|
272
|
+
CenteredTopPanelContainer
|
|
273
|
+
} from "./lib/ui/components/TopPanel/CenteredTopPanelContainer.mjs";
|
|
274
|
+
import { DefaultTopPanel } from "./lib/ui/components/TopPanel/DefaultTopPanel.mjs";
|
|
275
|
+
import {
|
|
276
|
+
DefaultZoomMenu
|
|
277
|
+
} from "./lib/ui/components/ZoomMenu/DefaultZoomMenu.mjs";
|
|
278
|
+
import { DefaultZoomMenuContent } from "./lib/ui/components/ZoomMenu/DefaultZoomMenuContent.mjs";
|
|
185
279
|
import {
|
|
186
280
|
ArrangeMenuSubmenu,
|
|
187
281
|
ClipboardMenuGroup,
|
|
@@ -210,7 +304,6 @@ import {
|
|
|
210
304
|
ToggleEdgeScrollingItem,
|
|
211
305
|
ToggleFocusModeItem,
|
|
212
306
|
ToggleGridItem,
|
|
213
|
-
ToggleKeyboardShortcutsItem,
|
|
214
307
|
ToggleLockMenuItem,
|
|
215
308
|
TogglePasteAtCursorItem,
|
|
216
309
|
ToggleReduceMotionItem,
|
|
@@ -224,15 +317,6 @@ import {
|
|
|
224
317
|
ZoomToFitMenuItem,
|
|
225
318
|
ZoomToSelectionMenuItem
|
|
226
319
|
} from "./lib/ui/components/menu-items.mjs";
|
|
227
|
-
import { DefaultMinimap } from "./lib/ui/components/Minimap/DefaultMinimap.mjs";
|
|
228
|
-
import { MobileStylePanel } from "./lib/ui/components/MobileStylePanel.mjs";
|
|
229
|
-
import { DefaultNavigationPanel } from "./lib/ui/components/NavigationPanel/DefaultNavigationPanel.mjs";
|
|
230
|
-
import { OfflineIndicator } from "./lib/ui/components/OfflineIndicator/OfflineIndicator.mjs";
|
|
231
|
-
import { DefaultPageMenu } from "./lib/ui/components/PageMenu/DefaultPageMenu.mjs";
|
|
232
|
-
import { PageItemInput } from "./lib/ui/components/PageMenu/PageItemInput.mjs";
|
|
233
|
-
import {
|
|
234
|
-
PageItemSubmenu
|
|
235
|
-
} from "./lib/ui/components/PageMenu/PageItemSubmenu.mjs";
|
|
236
320
|
import {
|
|
237
321
|
TldrawUiButton
|
|
238
322
|
} from "./lib/ui/components/primitives/Button/TldrawUiButton.mjs";
|
|
@@ -245,21 +329,6 @@ import {
|
|
|
245
329
|
import {
|
|
246
330
|
TldrawUiButtonLabel
|
|
247
331
|
} from "./lib/ui/components/primitives/Button/TldrawUiButtonLabel.mjs";
|
|
248
|
-
import {
|
|
249
|
-
TldrawUiMenuCheckboxItem
|
|
250
|
-
} from "./lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem.mjs";
|
|
251
|
-
import {
|
|
252
|
-
TldrawUiMenuContextProvider
|
|
253
|
-
} from "./lib/ui/components/primitives/menus/TldrawUiMenuContext.mjs";
|
|
254
|
-
import {
|
|
255
|
-
TldrawUiMenuGroup
|
|
256
|
-
} from "./lib/ui/components/primitives/menus/TldrawUiMenuGroup.mjs";
|
|
257
|
-
import {
|
|
258
|
-
TldrawUiMenuItem
|
|
259
|
-
} from "./lib/ui/components/primitives/menus/TldrawUiMenuItem.mjs";
|
|
260
|
-
import {
|
|
261
|
-
TldrawUiMenuSubmenu
|
|
262
|
-
} from "./lib/ui/components/primitives/menus/TldrawUiMenuSubmenu.mjs";
|
|
263
332
|
import {
|
|
264
333
|
TldrawUiButtonPicker
|
|
265
334
|
} from "./lib/ui/components/primitives/TldrawUiButtonPicker.mjs";
|
|
@@ -300,90 +369,24 @@ import {
|
|
|
300
369
|
TldrawUiToolbarToggleItem
|
|
301
370
|
} from "./lib/ui/components/primitives/TldrawUiToolbar.mjs";
|
|
302
371
|
import {
|
|
303
|
-
|
|
304
|
-
} from "./lib/ui/components/
|
|
305
|
-
import { DefaultQuickActionsContent } from "./lib/ui/components/QuickActions/DefaultQuickActionsContent.mjs";
|
|
306
|
-
import { DefaultSharePanel } from "./lib/ui/components/SharePanel/DefaultSharePanel.mjs";
|
|
307
|
-
import { PeopleMenu } from "./lib/ui/components/SharePanel/PeopleMenu.mjs";
|
|
308
|
-
import { Spinner } from "./lib/ui/components/Spinner.mjs";
|
|
309
|
-
import {
|
|
310
|
-
DefaultStylePanel
|
|
311
|
-
} from "./lib/ui/components/StylePanel/DefaultStylePanel.mjs";
|
|
312
|
-
import {
|
|
313
|
-
ArrowheadStylePickerSet,
|
|
314
|
-
CommonStylePickerSet,
|
|
315
|
-
DefaultStylePanelContent,
|
|
316
|
-
GeoStylePickerSet,
|
|
317
|
-
OpacitySlider,
|
|
318
|
-
SplineStylePickerSet,
|
|
319
|
-
TextStylePickerSet
|
|
320
|
-
} from "./lib/ui/components/StylePanel/DefaultStylePanelContent.mjs";
|
|
321
|
-
import {
|
|
322
|
-
DefaultImageToolbar
|
|
323
|
-
} from "./lib/ui/components/Toolbar/DefaultImageToolbar.mjs";
|
|
324
|
-
import {
|
|
325
|
-
DefaultImageToolbarContent
|
|
326
|
-
} from "./lib/ui/components/Toolbar/DefaultImageToolbarContent.mjs";
|
|
327
|
-
import {
|
|
328
|
-
DefaultRichTextToolbar
|
|
329
|
-
} from "./lib/ui/components/Toolbar/DefaultRichTextToolbar.mjs";
|
|
330
|
-
import {
|
|
331
|
-
DefaultRichTextToolbarContent
|
|
332
|
-
} from "./lib/ui/components/Toolbar/DefaultRichTextToolbarContent.mjs";
|
|
333
|
-
import {
|
|
334
|
-
DefaultToolbar
|
|
335
|
-
} from "./lib/ui/components/Toolbar/DefaultToolbar.mjs";
|
|
336
|
-
import {
|
|
337
|
-
ArrowDownToolbarItem,
|
|
338
|
-
ArrowLeftToolbarItem,
|
|
339
|
-
ArrowRightToolbarItem,
|
|
340
|
-
ArrowToolbarItem,
|
|
341
|
-
ArrowUpToolbarItem,
|
|
342
|
-
AssetToolbarItem,
|
|
343
|
-
CheckBoxToolbarItem,
|
|
344
|
-
CloudToolbarItem,
|
|
345
|
-
DefaultToolbarContent,
|
|
346
|
-
DiamondToolbarItem,
|
|
347
|
-
DrawToolbarItem,
|
|
348
|
-
EllipseToolbarItem,
|
|
349
|
-
EraserToolbarItem,
|
|
350
|
-
FrameToolbarItem,
|
|
351
|
-
HandToolbarItem,
|
|
352
|
-
HexagonToolbarItem,
|
|
353
|
-
HighlightToolbarItem,
|
|
354
|
-
LaserToolbarItem,
|
|
355
|
-
LineToolbarItem,
|
|
356
|
-
NoteToolbarItem,
|
|
357
|
-
OvalToolbarItem,
|
|
358
|
-
RectangleToolbarItem,
|
|
359
|
-
RhombusToolbarItem,
|
|
360
|
-
SelectToolbarItem,
|
|
361
|
-
StarToolbarItem,
|
|
362
|
-
TextToolbarItem,
|
|
363
|
-
ToolbarItem,
|
|
364
|
-
TrapezoidToolbarItem,
|
|
365
|
-
TriangleToolbarItem,
|
|
366
|
-
useIsToolSelected,
|
|
367
|
-
XBoxToolbarItem
|
|
368
|
-
} from "./lib/ui/components/Toolbar/DefaultToolbarContent.mjs";
|
|
369
|
-
import {
|
|
370
|
-
DefaultVideoToolbar
|
|
371
|
-
} from "./lib/ui/components/Toolbar/DefaultVideoToolbar.mjs";
|
|
372
|
+
TldrawUiMenuCheckboxItem
|
|
373
|
+
} from "./lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem.mjs";
|
|
372
374
|
import {
|
|
373
|
-
|
|
374
|
-
} from "./lib/ui/components/
|
|
375
|
+
TldrawUiMenuContextProvider
|
|
376
|
+
} from "./lib/ui/components/primitives/menus/TldrawUiMenuContext.mjs";
|
|
375
377
|
import {
|
|
376
|
-
|
|
377
|
-
} from "./lib/ui/components/
|
|
378
|
+
TldrawUiMenuGroup
|
|
379
|
+
} from "./lib/ui/components/primitives/menus/TldrawUiMenuGroup.mjs";
|
|
378
380
|
import {
|
|
379
|
-
|
|
380
|
-
} from "./lib/ui/components/
|
|
381
|
-
import { DefaultTopPanel } from "./lib/ui/components/TopPanel/DefaultTopPanel.mjs";
|
|
381
|
+
TldrawUiMenuItem
|
|
382
|
+
} from "./lib/ui/components/primitives/menus/TldrawUiMenuItem.mjs";
|
|
382
383
|
import {
|
|
383
|
-
|
|
384
|
-
} from "./lib/ui/components/
|
|
385
|
-
import { DefaultZoomMenuContent } from "./lib/ui/components/ZoomMenu/DefaultZoomMenuContent.mjs";
|
|
384
|
+
TldrawUiMenuSubmenu
|
|
385
|
+
} from "./lib/ui/components/primitives/menus/TldrawUiMenuSubmenu.mjs";
|
|
386
386
|
import { PORTRAIT_BREAKPOINT } from "./lib/ui/constants.mjs";
|
|
387
|
+
import {
|
|
388
|
+
TldrawUiContextProvider
|
|
389
|
+
} from "./lib/ui/context/TldrawUiContextProvider.mjs";
|
|
387
390
|
import {
|
|
388
391
|
TldrawUiA11yProvider,
|
|
389
392
|
useA11y
|
|
@@ -409,9 +412,6 @@ import {
|
|
|
409
412
|
TldrawUiEventsProvider,
|
|
410
413
|
useUiEvents
|
|
411
414
|
} from "./lib/ui/context/events.mjs";
|
|
412
|
-
import {
|
|
413
|
-
TldrawUiContextProvider
|
|
414
|
-
} from "./lib/ui/context/TldrawUiContextProvider.mjs";
|
|
415
415
|
import {
|
|
416
416
|
TldrawUiToastsProvider,
|
|
417
417
|
useToasts
|
|
@@ -437,7 +437,6 @@ import {
|
|
|
437
437
|
useTranslation
|
|
438
438
|
} from "./lib/ui/hooks/useTranslation/useTranslation.mjs";
|
|
439
439
|
import { useDefaultHelpers } from "./lib/ui/overrides.mjs";
|
|
440
|
-
import { TldrawUi } from "./lib/ui/TldrawUi.mjs";
|
|
441
440
|
import { containBoxSize, downsizeImage } from "./lib/utils/assets/assets.mjs";
|
|
442
441
|
import { preloadFont } from "./lib/utils/assets/preload-font.mjs";
|
|
443
442
|
import { getEmbedInfo } from "./lib/utils/embeds/embeds.mjs";
|
|
@@ -451,8 +450,8 @@ import {
|
|
|
451
450
|
setDefaultEditorAssetUrls
|
|
452
451
|
} from "./lib/utils/static-assets/assetUrls.mjs";
|
|
453
452
|
import {
|
|
454
|
-
defaultAddFontsFromNode,
|
|
455
453
|
KeyboardShiftEnterTweakExtension,
|
|
454
|
+
defaultAddFontsFromNode,
|
|
456
455
|
renderHtmlFromRichText,
|
|
457
456
|
renderHtmlFromRichTextForMeasurement,
|
|
458
457
|
renderPlaintextFromRichText,
|
|
@@ -462,7 +461,6 @@ import {
|
|
|
462
461
|
import { truncateStringWithEllipsis } from "./lib/utils/text/text.mjs";
|
|
463
462
|
import { TextDirection } from "./lib/utils/text/textDirection.mjs";
|
|
464
463
|
import {
|
|
465
|
-
buildFromV1Document,
|
|
466
464
|
TLV1AlignStyle,
|
|
467
465
|
TLV1AssetType,
|
|
468
466
|
TLV1ColorStyle,
|
|
@@ -470,18 +468,19 @@ import {
|
|
|
470
468
|
TLV1Decoration,
|
|
471
469
|
TLV1FontStyle,
|
|
472
470
|
TLV1ShapeType,
|
|
473
|
-
TLV1SizeStyle
|
|
471
|
+
TLV1SizeStyle,
|
|
472
|
+
buildFromV1Document
|
|
474
473
|
} from "./lib/utils/tldr/buildFromV1Document.mjs";
|
|
475
474
|
import {
|
|
475
|
+
TLDRAW_FILE_EXTENSION,
|
|
476
476
|
parseAndLoadDocument,
|
|
477
477
|
parseTldrawJsonFile,
|
|
478
478
|
serializeTldrawJson,
|
|
479
|
-
serializeTldrawJsonBlob
|
|
480
|
-
TLDRAW_FILE_EXTENSION
|
|
479
|
+
serializeTldrawJsonBlob
|
|
481
480
|
} from "./lib/utils/tldr/file.mjs";
|
|
482
481
|
registerTldrawLibraryVersion(
|
|
483
482
|
"tldraw",
|
|
484
|
-
"3.15.0-next.
|
|
483
|
+
"3.15.0-next.f1dfcef63951",
|
|
485
484
|
"esm"
|
|
486
485
|
);
|
|
487
486
|
export {
|
|
@@ -719,7 +718,6 @@ export {
|
|
|
719
718
|
ToggleEdgeScrollingItem,
|
|
720
719
|
ToggleFocusModeItem,
|
|
721
720
|
ToggleGridItem,
|
|
722
|
-
ToggleKeyboardShortcutsItem,
|
|
723
721
|
ToggleLockMenuItem,
|
|
724
722
|
TogglePasteAtCursorItem,
|
|
725
723
|
ToggleReduceMotionItem,
|
package/dist-esm/index.mjs.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/index.ts"],
|
|
4
|
-
"sourcesContent": ["/// <reference types=\"react\" />\n\nimport { registerTldrawLibraryVersion } from '@tldraw/editor'\nexport {\n\tPathBuilder,\n\tPathBuilderGeometry2d,\n\ttype BasePathBuilderOpts,\n\ttype CubicBezierToPathBuilderCommand,\n\ttype DashedPathBuilderOpts,\n\ttype DrawPathBuilderDOpts,\n\ttype DrawPathBuilderOpts,\n\ttype LineToPathBuilderCommand,\n\ttype MoveToPathBuilderCommand,\n\ttype PathBuilderCommand,\n\ttype PathBuilderCommandBase,\n\ttype PathBuilderCommandInfo,\n\ttype PathBuilderCommandOpts,\n\ttype PathBuilderLineOpts,\n\ttype PathBuilderOpts,\n\ttype PathBuilderToDOpts,\n\ttype SolidPathBuilderOpts,\n} from './lib/shapes/shared/PathBuilder'\nexport { usePrefersReducedMotion } from './lib/shapes/shared/usePrefersReducedMotion'\nexport { DefaultA11yAnnouncer, useSelectedShapesAnnouncer } from './lib/ui/components/A11y'\nexport { ColorSchemeMenu } from './lib/ui/components/ColorSchemeMenu'\nexport { DefaultDialogs } from './lib/ui/components/Dialogs'\nexport {\n\tTldrawUiMenuActionCheckboxItem,\n\ttype TLUiMenuActionCheckboxItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuActionCheckboxItem'\nexport {\n\tTldrawUiMenuActionItem,\n\ttype TLUiMenuActionItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuActionItem'\nexport {\n\tTldrawUiMenuToolItem,\n\ttype TLUiMenuToolItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuToolItem'\nexport { DefaultToasts } from './lib/ui/components/Toasts'\nexport { TldrawUiTranslationProvider } from './lib/ui/hooks/useTranslation/useTranslation'\n// eslint-disable-next-line local/no-export-star\nexport * from '@tldraw/editor'\nexport { ArrowBindingUtil } from './lib/bindings/arrow/ArrowBindingUtil'\nexport { TldrawHandles } from './lib/canvas/TldrawHandles'\nexport { TldrawArrowHints, TldrawOverlays } from './lib/canvas/TldrawOverlays'\nexport { TldrawScribble } from './lib/canvas/TldrawScribble'\nexport { TldrawSelectionForeground } from './lib/canvas/TldrawSelectionForeground'\nexport { TldrawShapeIndicators } from './lib/canvas/TldrawShapeIndicators'\nexport { defaultBindingUtils } from './lib/defaultBindingUtils'\nexport {\n\tDEFAULT_EMBED_DEFINITIONS,\n\tembedShapePermissionDefaults,\n\ttype CustomEmbedDefinition,\n\ttype DefaultEmbedDefinitionType,\n\ttype EmbedDefinition,\n\ttype TLEmbedDefinition,\n\ttype TLEmbedShapePermissions,\n} from './lib/defaultEmbedDefinitions'\nexport {\n\tcenterSelectionAroundPoint,\n\tcreateEmptyBookmarkShape,\n\tcreateShapesForAssets,\n\tDEFAULT_MAX_ASSET_SIZE,\n\tDEFAULT_MAX_IMAGE_DIMENSION,\n\tdefaultHandleExternalEmbedContent,\n\tdefaultHandleExternalExcalidrawContent,\n\tdefaultHandleExternalFileAsset,\n\tdefaultHandleExternalFileContent,\n\tdefaultHandleExternalSvgTextContent,\n\tdefaultHandleExternalTextContent,\n\tdefaultHandleExternalTldrawContent,\n\tdefaultHandleExternalUrlAsset,\n\tdefaultHandleExternalUrlContent,\n\tgetMediaAssetInfoPartial,\n\tregisterDefaultExternalContentHandlers,\n\ttype TLDefaultExternalContentHandlerOpts,\n\ttype TLExternalContentProps,\n} from './lib/defaultExternalContentHandlers'\nexport { defaultShapeTools } from './lib/defaultShapeTools'\nexport { defaultShapeUtils } from './lib/defaultShapeUtils'\nexport { registerDefaultSideEffects } from './lib/defaultSideEffects'\nexport { defaultTools } from './lib/defaultTools'\nexport {\n\ttype ArrowShapeOptions,\n\ttype TLArcArrowInfo,\n\ttype TLArcInfo,\n\ttype TLArrowInfo,\n\ttype TLArrowPoint,\n\ttype TLElbowArrowInfo,\n\ttype TLStraightArrowInfo,\n} from './lib/shapes/arrow/arrow-types'\nexport { ArrowShapeTool } from './lib/shapes/arrow/ArrowShapeTool'\nexport { ArrowShapeUtil } from './lib/shapes/arrow/ArrowShapeUtil'\nexport {\n\ttype ElbowArrowBox,\n\ttype ElbowArrowBoxEdges,\n\ttype ElbowArrowBoxes,\n\ttype ElbowArrowEdge,\n\ttype ElbowArrowInfo,\n\ttype ElbowArrowInfoWithoutRoute,\n\ttype ElbowArrowMidpointHandle,\n\ttype ElbowArrowOptions,\n\ttype ElbowArrowRange,\n\ttype ElbowArrowRoute,\n\ttype ElbowArrowSide,\n\ttype ElbowArrowSideReason,\n\ttype ElbowArrowTargetBox,\n} from './lib/shapes/arrow/elbow/definitions'\nexport {\n\tgetArrowBindings,\n\tgetArrowInfo,\n\tgetArrowTerminalsInArrowSpace,\n\ttype TLArrowBindings,\n} from './lib/shapes/arrow/shared'\nexport { BookmarkShapeUtil } from './lib/shapes/bookmark/BookmarkShapeUtil'\nexport { DrawShapeTool } from './lib/shapes/draw/DrawShapeTool'\nexport { DrawShapeUtil, type DrawShapeOptions } from './lib/shapes/draw/DrawShapeUtil'\nexport { EmbedShapeUtil } from './lib/shapes/embed/EmbedShapeUtil'\nexport { FrameShapeTool } from './lib/shapes/frame/FrameShapeTool'\nexport { FrameShapeUtil, type FrameShapeOptions } from './lib/shapes/frame/FrameShapeUtil'\nexport { GeoShapeTool } from './lib/shapes/geo/GeoShapeTool'\nexport { GeoShapeUtil } from './lib/shapes/geo/GeoShapeUtil'\nexport { HighlightShapeTool } from './lib/shapes/highlight/HighlightShapeTool'\nexport {\n\tHighlightShapeUtil,\n\ttype HighlightShapeOptions,\n} from './lib/shapes/highlight/HighlightShapeUtil'\nexport { ImageShapeUtil } from './lib/shapes/image/ImageShapeUtil'\nexport { LineShapeTool } from './lib/shapes/line/LineShapeTool'\nexport { LineShapeUtil } from './lib/shapes/line/LineShapeUtil'\nexport { NoteShapeTool } from './lib/shapes/note/NoteShapeTool'\nexport { NoteShapeUtil, type NoteShapeOptions } from './lib/shapes/note/NoteShapeUtil'\nexport {\n\tASPECT_RATIO_OPTIONS,\n\tASPECT_RATIO_TO_VALUE,\n\tgetCropBox,\n\tgetDefaultCrop,\n\tgetUncroppedSize,\n\ttype ASPECT_RATIO_OPTION,\n\ttype CropBoxOptions,\n} from './lib/shapes/shared/crop'\nexport {\n\tARROW_LABEL_FONT_SIZES,\n\tFONT_FAMILIES,\n\tFONT_SIZES,\n\tLABEL_FONT_SIZES,\n\tSTROKE_SIZES,\n\tTEXT_PROPS,\n} from './lib/shapes/shared/default-shape-constants'\nexport {\n\tallDefaultFontFaces,\n\tDefaultFontFaces,\n\ttype TLDefaultFont,\n\ttype TLDefaultFonts,\n} from './lib/shapes/shared/defaultFonts'\nexport {\n\tPlainTextLabel,\n\tTextLabel,\n\ttype PlainTextLabelProps,\n} from './lib/shapes/shared/PlainTextLabel'\nexport {\n\tRichTextLabel,\n\tRichTextSVG,\n\ttype RichTextLabelProps,\n\ttype RichTextSVGProps,\n} from './lib/shapes/shared/RichTextLabel'\nexport { useDefaultColorTheme } from './lib/shapes/shared/useDefaultColorTheme'\nexport { useEditablePlainText, useEditableText } from './lib/shapes/shared/useEditablePlainText'\nexport { useEditableRichText } from './lib/shapes/shared/useEditableRichText'\nexport {\n\tuseAsset,\n\tuseImageOrVideoAsset,\n\ttype UseImageOrVideoAssetOptions,\n} from './lib/shapes/shared/useImageOrVideoAsset'\nexport { PlainTextArea } from './lib/shapes/text/PlainTextArea'\nexport { RichTextArea, type TextAreaProps } from './lib/shapes/text/RichTextArea'\nexport { TextShapeTool } from './lib/shapes/text/TextShapeTool'\nexport { TextShapeUtil, type TextShapeOptions } from './lib/shapes/text/TextShapeUtil'\nexport { VideoShapeUtil, type VideoShapeOptions } from './lib/shapes/video/VideoShapeUtil'\nexport { type StyleValuesForUi } from './lib/styles'\nexport { Tldraw, type TLComponents, type TldrawBaseProps, type TldrawProps } from './lib/Tldraw'\nexport { TldrawImage, type TldrawImageProps } from './lib/TldrawImage'\nexport { EraserTool } from './lib/tools/EraserTool/EraserTool'\nexport { HandTool } from './lib/tools/HandTool/HandTool'\nexport { LaserTool } from './lib/tools/LaserTool/LaserTool'\nexport { SelectTool } from './lib/tools/SelectTool/SelectTool'\nexport { ZoomTool } from './lib/tools/ZoomTool/ZoomTool'\nexport {\n\tsetDefaultUiAssetUrls,\n\ttype TLUiAssetUrlOverrides,\n\ttype TLUiAssetUrls,\n} from './lib/ui/assetUrls'\nexport {\n\tDefaultActionsMenu,\n\ttype TLUiActionsMenuProps,\n} from './lib/ui/components/ActionsMenu/DefaultActionsMenu'\nexport {\n\tAlignMenuItems,\n\tDefaultActionsMenuContent,\n\tDistributeMenuItems,\n\tGroupOrUngroupMenuItem,\n\tReorderMenuItems,\n\tRotateCWMenuItem,\n\tStackMenuItems,\n\tZoomOrRotateMenuItem,\n} from './lib/ui/components/ActionsMenu/DefaultActionsMenuContent'\nexport {\n\tDefaultContextMenu as ContextMenu,\n\tDefaultContextMenu,\n\ttype TLUiContextMenuProps,\n} from './lib/ui/components/ContextMenu/DefaultContextMenu'\nexport { DefaultContextMenuContent } from './lib/ui/components/ContextMenu/DefaultContextMenuContent'\nexport {\n\tDefaultDebugMenu,\n\ttype TLUiDebugMenuProps,\n} from './lib/ui/components/DebugMenu/DefaultDebugMenu'\nexport {\n\tDebugFlags,\n\tDefaultDebugMenuContent,\n\tExampleDialog,\n\tFeatureFlags,\n\ttype ExampleDialogProps,\n} from './lib/ui/components/DebugMenu/DefaultDebugMenuContent'\nexport { DefaultMenuPanel } from './lib/ui/components/DefaultMenuPanel'\nexport {\n\tDefaultHelperButtons,\n\ttype TLUiHelperButtonsProps,\n} from './lib/ui/components/HelperButtons/DefaultHelperButtons'\nexport { DefaultHelperButtonsContent } from './lib/ui/components/HelperButtons/DefaultHelperButtonsContent'\nexport {\n\tDefaultHelpMenu,\n\ttype TLUiHelpMenuProps,\n} from './lib/ui/components/HelpMenu/DefaultHelpMenu'\nexport {\n\tDefaultHelpMenuContent,\n\tKeyboardShortcutsMenuItem,\n} from './lib/ui/components/HelpMenu/DefaultHelpMenuContent'\nexport {\n\tDefaultKeyboardShortcutsDialog,\n\ttype TLUiKeyboardShortcutsDialogProps,\n} from './lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialog'\nexport { DefaultKeyboardShortcutsDialogContent } from './lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent'\nexport { LanguageMenu } from './lib/ui/components/LanguageMenu'\nexport {\n\tDefaultMainMenu,\n\ttype TLUiMainMenuProps,\n} from './lib/ui/components/MainMenu/DefaultMainMenu'\nexport {\n\tDefaultMainMenuContent,\n\tEditSubmenu,\n\tExportFileContentSubMenu,\n\tExtrasGroup,\n\tMiscMenuGroup,\n\tPreferencesGroup,\n\tUndoRedoGroup,\n\tViewSubmenu,\n} from './lib/ui/components/MainMenu/DefaultMainMenuContent'\nexport {\n\tArrangeMenuSubmenu,\n\tClipboardMenuGroup,\n\tConversionsMenuGroup,\n\tConvertToBookmarkMenuItem,\n\tConvertToEmbedMenuItem,\n\tCopyAsMenuGroup,\n\tCopyMenuItem,\n\tCursorChatItem,\n\tCutMenuItem,\n\tDeleteMenuItem,\n\tDuplicateMenuItem,\n\tEditLinkMenuItem,\n\tEditMenuSubmenu,\n\tFitFrameToContentMenuItem,\n\tGroupMenuItem,\n\tMoveToPageMenu,\n\tPasteMenuItem,\n\tPrintItem,\n\tRemoveFrameMenuItem,\n\tReorderMenuSubmenu,\n\tSelectAllMenuItem,\n\tToggleAutoSizeMenuItem,\n\tToggleDebugModeItem,\n\tToggleDynamicSizeModeItem,\n\tToggleEdgeScrollingItem,\n\tToggleFocusModeItem,\n\tToggleGridItem,\n\tToggleKeyboardShortcutsItem,\n\tToggleLockMenuItem,\n\tTogglePasteAtCursorItem,\n\tToggleReduceMotionItem,\n\tToggleSnapModeItem,\n\tToggleToolLockItem,\n\tToggleTransparentBgMenuItem,\n\tToggleWrapModeItem,\n\tUngroupMenuItem,\n\tUnlockAllMenuItem,\n\tZoomTo100MenuItem,\n\tZoomToFitMenuItem,\n\tZoomToSelectionMenuItem,\n} from './lib/ui/components/menu-items'\nexport { DefaultMinimap } from './lib/ui/components/Minimap/DefaultMinimap'\nexport { MobileStylePanel } from './lib/ui/components/MobileStylePanel'\nexport { DefaultNavigationPanel } from './lib/ui/components/NavigationPanel/DefaultNavigationPanel'\nexport { OfflineIndicator } from './lib/ui/components/OfflineIndicator/OfflineIndicator'\nexport { DefaultPageMenu } from './lib/ui/components/PageMenu/DefaultPageMenu'\nexport { PageItemInput, type PageItemInputProps } from './lib/ui/components/PageMenu/PageItemInput'\nexport {\n\tPageItemSubmenu,\n\ttype PageItemSubmenuProps,\n} from './lib/ui/components/PageMenu/PageItemSubmenu'\nexport {\n\tTldrawUiButton,\n\ttype TLUiButtonProps,\n} from './lib/ui/components/primitives/Button/TldrawUiButton'\nexport {\n\tTldrawUiButtonCheck,\n\ttype TLUiButtonCheckProps,\n} from './lib/ui/components/primitives/Button/TldrawUiButtonCheck'\nexport {\n\tTldrawUiButtonIcon,\n\ttype TLUiButtonIconProps,\n} from './lib/ui/components/primitives/Button/TldrawUiButtonIcon'\nexport {\n\tTldrawUiButtonLabel,\n\ttype TLUiButtonLabelProps,\n} from './lib/ui/components/primitives/Button/TldrawUiButtonLabel'\nexport {\n\tTldrawUiMenuCheckboxItem,\n\ttype TLUiMenuCheckboxItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem'\nexport {\n\tTldrawUiMenuContextProvider,\n\ttype TLUiMenuContextProviderProps,\n\ttype TLUiMenuContextType,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuContext'\nexport {\n\tTldrawUiMenuGroup,\n\ttype TLUiMenuGroupProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuGroup'\nexport {\n\tTldrawUiMenuItem,\n\ttype TLUiMenuItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuItem'\nexport {\n\tTldrawUiMenuSubmenu,\n\ttype TLUiMenuSubmenuProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuSubmenu'\nexport {\n\tTldrawUiButtonPicker,\n\ttype TLUiButtonPickerProps,\n} from './lib/ui/components/primitives/TldrawUiButtonPicker'\nexport {\n\tTldrawUiContextualToolbar,\n\ttype TLUiContextualToolbarProps,\n} from './lib/ui/components/primitives/TldrawUiContextualToolbar'\nexport {\n\tTldrawUiDialogBody,\n\tTldrawUiDialogCloseButton,\n\tTldrawUiDialogFooter,\n\tTldrawUiDialogHeader,\n\tTldrawUiDialogTitle,\n\ttype TLUiDialogBodyProps,\n\ttype TLUiDialogFooterProps,\n\ttype TLUiDialogHeaderProps,\n\ttype TLUiDialogTitleProps,\n} from './lib/ui/components/primitives/TldrawUiDialog'\nexport {\n\tTldrawUiDropdownMenuCheckboxItem,\n\tTldrawUiDropdownMenuContent,\n\tTldrawUiDropdownMenuGroup,\n\tTldrawUiDropdownMenuIndicator,\n\tTldrawUiDropdownMenuItem,\n\tTldrawUiDropdownMenuRoot,\n\tTldrawUiDropdownMenuSub,\n\tTldrawUiDropdownMenuSubTrigger,\n\tTldrawUiDropdownMenuTrigger,\n\ttype TLUiDropdownMenuCheckboxItemProps,\n\ttype TLUiDropdownMenuContentProps,\n\ttype TLUiDropdownMenuGroupProps,\n\ttype TLUiDropdownMenuItemProps,\n\ttype TLUiDropdownMenuRootProps,\n\ttype TLUiDropdownMenuSubProps,\n\ttype TLUiDropdownMenuSubTriggerProps,\n\ttype TLUiDropdownMenuTriggerProps,\n} from './lib/ui/components/primitives/TldrawUiDropdownMenu'\nexport { TldrawUiIcon, type TLUiIconProps } from './lib/ui/components/primitives/TldrawUiIcon'\nexport { TldrawUiInput, type TLUiInputProps } from './lib/ui/components/primitives/TldrawUiInput'\nexport { TldrawUiKbd, type TLUiKbdProps } from './lib/ui/components/primitives/TldrawUiKbd'\nexport {\n\tTldrawUiPopover,\n\tTldrawUiPopoverContent,\n\tTldrawUiPopoverTrigger,\n\ttype TLUiPopoverContentProps,\n\ttype TLUiPopoverProps,\n\ttype TLUiPopoverTriggerProps,\n} from './lib/ui/components/primitives/TldrawUiPopover'\nexport { TldrawUiSlider, type TLUiSliderProps } from './lib/ui/components/primitives/TldrawUiSlider'\nexport {\n\tTldrawUiToolbar,\n\tTldrawUiToolbarButton,\n\tTldrawUiToolbarToggleGroup,\n\tTldrawUiToolbarToggleItem,\n\ttype TLUiToolbarButtonProps,\n\ttype TLUiToolbarProps,\n\ttype TLUiToolbarToggleGroupProps,\n\ttype TLUiToolbarToggleItemProps,\n} from './lib/ui/components/primitives/TldrawUiToolbar'\nexport {\n\tDefaultQuickActions,\n\ttype TLUiQuickActionsProps,\n} from './lib/ui/components/QuickActions/DefaultQuickActions'\nexport { DefaultQuickActionsContent } from './lib/ui/components/QuickActions/DefaultQuickActionsContent'\nexport { DefaultSharePanel } from './lib/ui/components/SharePanel/DefaultSharePanel'\nexport { PeopleMenu, type PeopleMenuProps } from './lib/ui/components/SharePanel/PeopleMenu'\nexport { Spinner } from './lib/ui/components/Spinner'\nexport {\n\tDefaultStylePanel,\n\ttype TLUiStylePanelProps,\n} from './lib/ui/components/StylePanel/DefaultStylePanel'\nexport {\n\tArrowheadStylePickerSet,\n\tCommonStylePickerSet,\n\tDefaultStylePanelContent,\n\tGeoStylePickerSet,\n\tOpacitySlider,\n\tSplineStylePickerSet,\n\tTextStylePickerSet,\n\ttype StylePickerSetProps,\n\ttype ThemeStylePickerSetProps,\n\ttype TLUiStylePanelContentProps,\n} from './lib/ui/components/StylePanel/DefaultStylePanelContent'\nexport {\n\tDefaultImageToolbar,\n\ttype TLUiImageToolbarProps,\n} from './lib/ui/components/Toolbar/DefaultImageToolbar'\nexport {\n\tDefaultImageToolbarContent,\n\ttype DefaultImageToolbarContentProps,\n} from './lib/ui/components/Toolbar/DefaultImageToolbarContent'\nexport {\n\tDefaultRichTextToolbar,\n\ttype TLUiRichTextToolbarProps,\n} from './lib/ui/components/Toolbar/DefaultRichTextToolbar'\nexport {\n\tDefaultRichTextToolbarContent,\n\ttype DefaultRichTextToolbarContentProps,\n} from './lib/ui/components/Toolbar/DefaultRichTextToolbarContent'\nexport {\n\tDefaultToolbar,\n\ttype DefaultToolbarProps,\n} from './lib/ui/components/Toolbar/DefaultToolbar'\nexport {\n\tArrowDownToolbarItem,\n\tArrowLeftToolbarItem,\n\tArrowRightToolbarItem,\n\tArrowToolbarItem,\n\tArrowUpToolbarItem,\n\tAssetToolbarItem,\n\tCheckBoxToolbarItem,\n\tCloudToolbarItem,\n\tDefaultToolbarContent,\n\tDiamondToolbarItem,\n\tDrawToolbarItem,\n\tEllipseToolbarItem,\n\tEraserToolbarItem,\n\tFrameToolbarItem,\n\tHandToolbarItem,\n\tHexagonToolbarItem,\n\tHighlightToolbarItem,\n\tLaserToolbarItem,\n\tLineToolbarItem,\n\tNoteToolbarItem,\n\tOvalToolbarItem,\n\tRectangleToolbarItem,\n\tRhombusToolbarItem,\n\tSelectToolbarItem,\n\tStarToolbarItem,\n\tTextToolbarItem,\n\tToolbarItem,\n\tTrapezoidToolbarItem,\n\tTriangleToolbarItem,\n\tuseIsToolSelected,\n\tXBoxToolbarItem,\n\ttype ToolbarItemProps,\n} from './lib/ui/components/Toolbar/DefaultToolbarContent'\nexport {\n\tDefaultVideoToolbar,\n\ttype TLUiVideoToolbarProps,\n} from './lib/ui/components/Toolbar/DefaultVideoToolbar'\nexport {\n\tDefaultVideoToolbarContent,\n\ttype DefaultVideoToolbarContentProps,\n} from './lib/ui/components/Toolbar/DefaultVideoToolbarContent'\nexport {\n\tOverflowingToolbar,\n\ttype OverflowingToolbarProps,\n} from './lib/ui/components/Toolbar/OverflowingToolbar'\nexport {\n\tCenteredTopPanelContainer,\n\ttype CenteredTopPanelContainerProps,\n} from './lib/ui/components/TopPanel/CenteredTopPanelContainer'\nexport { DefaultTopPanel } from './lib/ui/components/TopPanel/DefaultTopPanel'\nexport {\n\tDefaultZoomMenu,\n\ttype TLUiZoomMenuProps,\n} from './lib/ui/components/ZoomMenu/DefaultZoomMenu'\nexport { DefaultZoomMenuContent } from './lib/ui/components/ZoomMenu/DefaultZoomMenuContent'\nexport { PORTRAIT_BREAKPOINT } from './lib/ui/constants'\nexport {\n\tTldrawUiA11yProvider,\n\tuseA11y,\n\ttype A11yPriority,\n\ttype A11yProviderProps,\n\ttype TLUiA11y,\n\ttype TLUiA11yContextType,\n} from './lib/ui/context/a11y'\nexport {\n\tunwrapLabel,\n\tuseActions,\n\ttype ActionsProviderProps,\n\ttype TLUiActionItem,\n\ttype TLUiActionsContextType,\n} from './lib/ui/context/actions'\nexport { AssetUrlsProvider, useAssetUrls } from './lib/ui/context/asset-urls'\nexport {\n\tBreakPointProvider,\n\tuseBreakpoint,\n\ttype BreakPointProviderProps,\n} from './lib/ui/context/breakpoints'\nexport {\n\tTldrawUiComponentsProvider,\n\tuseTldrawUiComponents,\n\ttype TLUiComponents,\n\ttype TLUiComponentsProviderProps,\n} from './lib/ui/context/components'\nexport {\n\tTldrawUiDialogsProvider,\n\tuseDialogs,\n\ttype TLUiDialog,\n\ttype TLUiDialogProps,\n\ttype TLUiDialogsContextType,\n\ttype TLUiDialogsProviderProps,\n} from './lib/ui/context/dialogs'\nexport {\n\tTldrawUiEventsProvider,\n\tuseUiEvents,\n\ttype EventsProviderProps,\n\ttype TLUiEventContextType,\n\ttype TLUiEventData,\n\ttype TLUiEventHandler,\n\ttype TLUiEventMap,\n\ttype TLUiEventSource,\n} from './lib/ui/context/events'\nexport {\n\tTldrawUiContextProvider,\n\ttype TLUiContextProviderProps,\n} from './lib/ui/context/TldrawUiContextProvider'\nexport {\n\tTldrawUiToastsProvider,\n\tuseToasts,\n\ttype AlertSeverity,\n\ttype TLUiToast,\n\ttype TLUiToastAction,\n\ttype TLUiToastsContextType,\n\ttype TLUiToastsProviderProps,\n} from './lib/ui/context/toasts'\nexport { useCanRedo, useCanUndo } from './lib/ui/hooks/menu-hooks'\nexport { useMenuClipboardEvents, useNativeClipboardEvents } from './lib/ui/hooks/useClipboardEvents'\nexport {\n\tuseCollaborationStatus,\n\tuseShowCollaborationUi,\n} from './lib/ui/hooks/useCollaborationStatus'\nexport { useCopyAs } from './lib/ui/hooks/useCopyAs'\nexport { useExportAs } from './lib/ui/hooks/useExportAs'\nexport { useKeyboardShortcuts } from './lib/ui/hooks/useKeyboardShortcuts'\nexport { useLocalStorageState } from './lib/ui/hooks/useLocalStorageState'\nexport { useMenuIsOpen } from './lib/ui/hooks/useMenuIsOpen'\nexport { useReadonly } from './lib/ui/hooks/useReadonly'\nexport { useRelevantStyles } from './lib/ui/hooks/useRelevantStyles'\nexport {\n\tuseTools,\n\ttype TLUiToolItem,\n\ttype TLUiToolsContextType,\n\ttype TLUiToolsProviderProps,\n} from './lib/ui/hooks/useTools'\nexport { type TLUiTranslationKey } from './lib/ui/hooks/useTranslation/TLUiTranslationKey'\nexport { type TLUiTranslation } from './lib/ui/hooks/useTranslation/translations'\nexport {\n\tuseCurrentTranslation,\n\tuseTranslation,\n\ttype TLUiTranslationContextType,\n\ttype TLUiTranslationProviderProps,\n} from './lib/ui/hooks/useTranslation/useTranslation'\nexport { type TLUiIconType } from './lib/ui/icon-types'\nexport { useDefaultHelpers, type TLUiOverrideHelpers, type TLUiOverrides } from './lib/ui/overrides'\nexport { TldrawUi, type TldrawUiProps } from './lib/ui/TldrawUi'\nexport { containBoxSize, downsizeImage, type BoxWidthHeight } from './lib/utils/assets/assets'\nexport { preloadFont, type TLTypeFace } from './lib/utils/assets/preload-font'\nexport { getEmbedInfo, type TLEmbedResult } from './lib/utils/embeds/embeds'\nexport { putExcalidrawContent } from './lib/utils/excalidraw/putExcalidrawContent'\nexport { copyAs, type CopyAsOptions, type TLCopyType } from './lib/utils/export/copyAs'\nexport { exportToBlob } from './lib/utils/export/export'\nexport { downloadFile, exportAs, type ExportAsOptions } from './lib/utils/export/exportAs'\nexport { fitFrameToContent, removeFrame } from './lib/utils/frames/frames'\nexport {\n\tdefaultEditorAssetUrls,\n\tsetDefaultEditorAssetUrls,\n\ttype TLEditorAssetUrls,\n} from './lib/utils/static-assets/assetUrls'\nexport {\n\tdefaultAddFontsFromNode,\n\tKeyboardShiftEnterTweakExtension,\n\trenderHtmlFromRichText,\n\trenderHtmlFromRichTextForMeasurement,\n\trenderPlaintextFromRichText,\n\trenderRichTextFromHTML,\n\ttipTapDefaultExtensions,\n} from './lib/utils/text/richText'\nexport { truncateStringWithEllipsis } from './lib/utils/text/text'\nexport { TextDirection } from './lib/utils/text/textDirection'\nexport {\n\tbuildFromV1Document,\n\tTLV1AlignStyle,\n\tTLV1AssetType,\n\tTLV1ColorStyle,\n\tTLV1DashStyle,\n\tTLV1Decoration,\n\tTLV1FontStyle,\n\tTLV1ShapeType,\n\tTLV1SizeStyle,\n\ttype TLV1ArrowBinding,\n\ttype TLV1ArrowShape,\n\ttype TLV1Asset,\n\ttype TLV1BaseAsset,\n\ttype TLV1BaseBinding,\n\ttype TLV1BaseShape,\n\ttype TLV1Binding,\n\ttype TLV1Bounds,\n\ttype TLV1Document,\n\ttype TLV1DrawShape,\n\ttype TLV1EllipseShape,\n\ttype TLV1GroupShape,\n\ttype TLV1Handle,\n\ttype TLV1ImageAsset,\n\ttype TLV1ImageShape,\n\ttype TLV1Page,\n\ttype TLV1PageState,\n\ttype TLV1RectangleShape,\n\ttype TLV1Shape,\n\ttype TLV1ShapeStyles,\n\ttype TLV1StickyShape,\n\ttype TLV1TextShape,\n\ttype TLV1TriangleShape,\n\ttype TLV1VideoAsset,\n\ttype TLV1VideoShape,\n} from './lib/utils/tldr/buildFromV1Document'\nexport {\n\tparseAndLoadDocument,\n\tparseTldrawJsonFile,\n\tserializeTldrawJson,\n\tserializeTldrawJsonBlob,\n\tTLDRAW_FILE_EXTENSION,\n\ttype TldrawFile,\n\ttype TldrawFileParseError,\n} from './lib/utils/tldr/file'\n\nregisterTldrawLibraryVersion(\n\t(globalThis as any).TLDRAW_LIBRARY_NAME,\n\t(globalThis as any).TLDRAW_LIBRARY_VERSION,\n\t(globalThis as any).TLDRAW_LIBRARY_MODULES\n)\n"],
|
|
5
|
-
"mappings": "AAEA,SAAS,oCAAoC;AAC7C;AAAA,EACC;AAAA,EACA;AAAA,OAgBM;AACP,SAAS,+BAA+B;AACxC,SAAS,sBAAsB,kCAAkC;AACjE,SAAS,uBAAuB;AAChC,SAAS,sBAAsB;AAC/B;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP,SAAS,
|
|
4
|
+
"sourcesContent": ["/// <reference types=\"react\" />\n\nimport { registerTldrawLibraryVersion } from '@tldraw/editor'\nexport {\n\tPathBuilder,\n\tPathBuilderGeometry2d,\n\ttype BasePathBuilderOpts,\n\ttype CubicBezierToPathBuilderCommand,\n\ttype DashedPathBuilderOpts,\n\ttype DrawPathBuilderDOpts,\n\ttype DrawPathBuilderOpts,\n\ttype LineToPathBuilderCommand,\n\ttype MoveToPathBuilderCommand,\n\ttype PathBuilderCommand,\n\ttype PathBuilderCommandBase,\n\ttype PathBuilderCommandInfo,\n\ttype PathBuilderCommandOpts,\n\ttype PathBuilderLineOpts,\n\ttype PathBuilderOpts,\n\ttype PathBuilderToDOpts,\n\ttype SolidPathBuilderOpts,\n} from './lib/shapes/shared/PathBuilder'\nexport { usePrefersReducedMotion } from './lib/shapes/shared/usePrefersReducedMotion'\nexport { DefaultA11yAnnouncer, useSelectedShapesAnnouncer } from './lib/ui/components/A11y'\nexport { ColorSchemeMenu } from './lib/ui/components/ColorSchemeMenu'\nexport { DefaultDialogs } from './lib/ui/components/Dialogs'\nexport { DefaultToasts } from './lib/ui/components/Toasts'\nexport {\n\tTldrawUiMenuActionCheckboxItem,\n\ttype TLUiMenuActionCheckboxItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuActionCheckboxItem'\nexport {\n\tTldrawUiMenuActionItem,\n\ttype TLUiMenuActionItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuActionItem'\nexport {\n\tTldrawUiMenuToolItem,\n\ttype TLUiMenuToolItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuToolItem'\nexport { TldrawUiTranslationProvider } from './lib/ui/hooks/useTranslation/useTranslation'\n// eslint-disable-next-line local/no-export-star\nexport * from '@tldraw/editor'\nexport { Tldraw, type TLComponents, type TldrawBaseProps, type TldrawProps } from './lib/Tldraw'\nexport { TldrawImage, type TldrawImageProps } from './lib/TldrawImage'\nexport { ArrowBindingUtil } from './lib/bindings/arrow/ArrowBindingUtil'\nexport { TldrawHandles } from './lib/canvas/TldrawHandles'\nexport { TldrawArrowHints, TldrawOverlays } from './lib/canvas/TldrawOverlays'\nexport { TldrawScribble } from './lib/canvas/TldrawScribble'\nexport { TldrawSelectionForeground } from './lib/canvas/TldrawSelectionForeground'\nexport { TldrawShapeIndicators } from './lib/canvas/TldrawShapeIndicators'\nexport { defaultBindingUtils } from './lib/defaultBindingUtils'\nexport {\n\tDEFAULT_EMBED_DEFINITIONS,\n\tembedShapePermissionDefaults,\n\ttype CustomEmbedDefinition,\n\ttype DefaultEmbedDefinitionType,\n\ttype EmbedDefinition,\n\ttype TLEmbedDefinition,\n\ttype TLEmbedShapePermissions,\n} from './lib/defaultEmbedDefinitions'\nexport {\n\tDEFAULT_MAX_ASSET_SIZE,\n\tDEFAULT_MAX_IMAGE_DIMENSION,\n\tcenterSelectionAroundPoint,\n\tcreateEmptyBookmarkShape,\n\tcreateShapesForAssets,\n\tdefaultHandleExternalEmbedContent,\n\tdefaultHandleExternalExcalidrawContent,\n\tdefaultHandleExternalFileAsset,\n\tdefaultHandleExternalFileContent,\n\tdefaultHandleExternalSvgTextContent,\n\tdefaultHandleExternalTextContent,\n\tdefaultHandleExternalTldrawContent,\n\tdefaultHandleExternalUrlAsset,\n\tdefaultHandleExternalUrlContent,\n\tgetMediaAssetInfoPartial,\n\tregisterDefaultExternalContentHandlers,\n\ttype TLDefaultExternalContentHandlerOpts,\n\ttype TLExternalContentProps,\n} from './lib/defaultExternalContentHandlers'\nexport { defaultShapeTools } from './lib/defaultShapeTools'\nexport { defaultShapeUtils } from './lib/defaultShapeUtils'\nexport { registerDefaultSideEffects } from './lib/defaultSideEffects'\nexport { defaultTools } from './lib/defaultTools'\nexport { ArrowShapeTool } from './lib/shapes/arrow/ArrowShapeTool'\nexport { ArrowShapeUtil } from './lib/shapes/arrow/ArrowShapeUtil'\nexport {\n\ttype ArrowShapeOptions,\n\ttype TLArcArrowInfo,\n\ttype TLArcInfo,\n\ttype TLArrowInfo,\n\ttype TLArrowPoint,\n\ttype TLElbowArrowInfo,\n\ttype TLStraightArrowInfo,\n} from './lib/shapes/arrow/arrow-types'\nexport {\n\ttype ElbowArrowBox,\n\ttype ElbowArrowBoxEdges,\n\ttype ElbowArrowBoxes,\n\ttype ElbowArrowEdge,\n\ttype ElbowArrowInfo,\n\ttype ElbowArrowInfoWithoutRoute,\n\ttype ElbowArrowMidpointHandle,\n\ttype ElbowArrowOptions,\n\ttype ElbowArrowRange,\n\ttype ElbowArrowRoute,\n\ttype ElbowArrowSide,\n\ttype ElbowArrowSideReason,\n\ttype ElbowArrowTargetBox,\n} from './lib/shapes/arrow/elbow/definitions'\nexport {\n\tgetArrowBindings,\n\tgetArrowInfo,\n\tgetArrowTerminalsInArrowSpace,\n\ttype TLArrowBindings,\n} from './lib/shapes/arrow/shared'\nexport { BookmarkShapeUtil } from './lib/shapes/bookmark/BookmarkShapeUtil'\nexport { DrawShapeTool } from './lib/shapes/draw/DrawShapeTool'\nexport { DrawShapeUtil, type DrawShapeOptions } from './lib/shapes/draw/DrawShapeUtil'\nexport { EmbedShapeUtil } from './lib/shapes/embed/EmbedShapeUtil'\nexport { FrameShapeTool } from './lib/shapes/frame/FrameShapeTool'\nexport { FrameShapeUtil, type FrameShapeOptions } from './lib/shapes/frame/FrameShapeUtil'\nexport { GeoShapeTool } from './lib/shapes/geo/GeoShapeTool'\nexport { GeoShapeUtil } from './lib/shapes/geo/GeoShapeUtil'\nexport { HighlightShapeTool } from './lib/shapes/highlight/HighlightShapeTool'\nexport {\n\tHighlightShapeUtil,\n\ttype HighlightShapeOptions,\n} from './lib/shapes/highlight/HighlightShapeUtil'\nexport { ImageShapeUtil } from './lib/shapes/image/ImageShapeUtil'\nexport { LineShapeTool } from './lib/shapes/line/LineShapeTool'\nexport { LineShapeUtil } from './lib/shapes/line/LineShapeUtil'\nexport { NoteShapeTool } from './lib/shapes/note/NoteShapeTool'\nexport { NoteShapeUtil, type NoteShapeOptions } from './lib/shapes/note/NoteShapeUtil'\nexport {\n\tPlainTextLabel,\n\tTextLabel,\n\ttype PlainTextLabelProps,\n} from './lib/shapes/shared/PlainTextLabel'\nexport {\n\tRichTextLabel,\n\tRichTextSVG,\n\ttype RichTextLabelProps,\n\ttype RichTextSVGProps,\n} from './lib/shapes/shared/RichTextLabel'\nexport {\n\tASPECT_RATIO_OPTIONS,\n\tASPECT_RATIO_TO_VALUE,\n\tgetCropBox,\n\tgetDefaultCrop,\n\tgetUncroppedSize,\n\ttype ASPECT_RATIO_OPTION,\n\ttype CropBoxOptions,\n} from './lib/shapes/shared/crop'\nexport {\n\tARROW_LABEL_FONT_SIZES,\n\tFONT_FAMILIES,\n\tFONT_SIZES,\n\tLABEL_FONT_SIZES,\n\tSTROKE_SIZES,\n\tTEXT_PROPS,\n} from './lib/shapes/shared/default-shape-constants'\nexport {\n\tDefaultFontFaces,\n\tallDefaultFontFaces,\n\ttype TLDefaultFont,\n\ttype TLDefaultFonts,\n} from './lib/shapes/shared/defaultFonts'\nexport { useDefaultColorTheme } from './lib/shapes/shared/useDefaultColorTheme'\nexport { useEditablePlainText, useEditableText } from './lib/shapes/shared/useEditablePlainText'\nexport { useEditableRichText } from './lib/shapes/shared/useEditableRichText'\nexport {\n\tuseAsset,\n\tuseImageOrVideoAsset,\n\ttype UseImageOrVideoAssetOptions,\n} from './lib/shapes/shared/useImageOrVideoAsset'\nexport { PlainTextArea } from './lib/shapes/text/PlainTextArea'\nexport { RichTextArea, type TextAreaProps } from './lib/shapes/text/RichTextArea'\nexport { TextShapeTool } from './lib/shapes/text/TextShapeTool'\nexport { TextShapeUtil, type TextShapeOptions } from './lib/shapes/text/TextShapeUtil'\nexport { VideoShapeUtil, type VideoShapeOptions } from './lib/shapes/video/VideoShapeUtil'\nexport { type StyleValuesForUi } from './lib/styles'\nexport { EraserTool } from './lib/tools/EraserTool/EraserTool'\nexport { HandTool } from './lib/tools/HandTool/HandTool'\nexport { LaserTool } from './lib/tools/LaserTool/LaserTool'\nexport { SelectTool } from './lib/tools/SelectTool/SelectTool'\nexport { ZoomTool } from './lib/tools/ZoomTool/ZoomTool'\nexport { TldrawUi, type TldrawUiProps } from './lib/ui/TldrawUi'\nexport {\n\tsetDefaultUiAssetUrls,\n\ttype TLUiAssetUrlOverrides,\n\ttype TLUiAssetUrls,\n} from './lib/ui/assetUrls'\nexport {\n\tDefaultActionsMenu,\n\ttype TLUiActionsMenuProps,\n} from './lib/ui/components/ActionsMenu/DefaultActionsMenu'\nexport {\n\tAlignMenuItems,\n\tDefaultActionsMenuContent,\n\tDistributeMenuItems,\n\tGroupOrUngroupMenuItem,\n\tReorderMenuItems,\n\tRotateCWMenuItem,\n\tStackMenuItems,\n\tZoomOrRotateMenuItem,\n} from './lib/ui/components/ActionsMenu/DefaultActionsMenuContent'\nexport {\n\tDefaultContextMenu as ContextMenu,\n\tDefaultContextMenu,\n\ttype TLUiContextMenuProps,\n} from './lib/ui/components/ContextMenu/DefaultContextMenu'\nexport { DefaultContextMenuContent } from './lib/ui/components/ContextMenu/DefaultContextMenuContent'\nexport {\n\tDefaultDebugMenu,\n\ttype TLUiDebugMenuProps,\n} from './lib/ui/components/DebugMenu/DefaultDebugMenu'\nexport {\n\tDebugFlags,\n\tDefaultDebugMenuContent,\n\tExampleDialog,\n\tFeatureFlags,\n\ttype ExampleDialogProps,\n} from './lib/ui/components/DebugMenu/DefaultDebugMenuContent'\nexport { DefaultMenuPanel } from './lib/ui/components/DefaultMenuPanel'\nexport {\n\tDefaultHelpMenu,\n\ttype TLUiHelpMenuProps,\n} from './lib/ui/components/HelpMenu/DefaultHelpMenu'\nexport {\n\tDefaultHelpMenuContent,\n\tKeyboardShortcutsMenuItem,\n} from './lib/ui/components/HelpMenu/DefaultHelpMenuContent'\nexport {\n\tDefaultHelperButtons,\n\ttype TLUiHelperButtonsProps,\n} from './lib/ui/components/HelperButtons/DefaultHelperButtons'\nexport { DefaultHelperButtonsContent } from './lib/ui/components/HelperButtons/DefaultHelperButtonsContent'\nexport {\n\tDefaultKeyboardShortcutsDialog,\n\ttype TLUiKeyboardShortcutsDialogProps,\n} from './lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialog'\nexport { DefaultKeyboardShortcutsDialogContent } from './lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent'\nexport { LanguageMenu } from './lib/ui/components/LanguageMenu'\nexport {\n\tDefaultMainMenu,\n\ttype TLUiMainMenuProps,\n} from './lib/ui/components/MainMenu/DefaultMainMenu'\nexport {\n\tDefaultMainMenuContent,\n\tEditSubmenu,\n\tExportFileContentSubMenu,\n\tExtrasGroup,\n\tMiscMenuGroup,\n\tPreferencesGroup,\n\tUndoRedoGroup,\n\tViewSubmenu,\n} from './lib/ui/components/MainMenu/DefaultMainMenuContent'\nexport { DefaultMinimap } from './lib/ui/components/Minimap/DefaultMinimap'\nexport { MobileStylePanel } from './lib/ui/components/MobileStylePanel'\nexport { DefaultNavigationPanel } from './lib/ui/components/NavigationPanel/DefaultNavigationPanel'\nexport { OfflineIndicator } from './lib/ui/components/OfflineIndicator/OfflineIndicator'\nexport { DefaultPageMenu } from './lib/ui/components/PageMenu/DefaultPageMenu'\nexport { PageItemInput, type PageItemInputProps } from './lib/ui/components/PageMenu/PageItemInput'\nexport {\n\tPageItemSubmenu,\n\ttype PageItemSubmenuProps,\n} from './lib/ui/components/PageMenu/PageItemSubmenu'\nexport {\n\tDefaultQuickActions,\n\ttype TLUiQuickActionsProps,\n} from './lib/ui/components/QuickActions/DefaultQuickActions'\nexport { DefaultQuickActionsContent } from './lib/ui/components/QuickActions/DefaultQuickActionsContent'\nexport { DefaultSharePanel } from './lib/ui/components/SharePanel/DefaultSharePanel'\nexport { PeopleMenu, type PeopleMenuProps } from './lib/ui/components/SharePanel/PeopleMenu'\nexport { Spinner } from './lib/ui/components/Spinner'\nexport {\n\tDefaultStylePanel,\n\ttype TLUiStylePanelProps,\n} from './lib/ui/components/StylePanel/DefaultStylePanel'\nexport {\n\tArrowheadStylePickerSet,\n\tCommonStylePickerSet,\n\tDefaultStylePanelContent,\n\tGeoStylePickerSet,\n\tOpacitySlider,\n\tSplineStylePickerSet,\n\tTextStylePickerSet,\n\ttype StylePickerSetProps,\n\ttype TLUiStylePanelContentProps,\n\ttype ThemeStylePickerSetProps,\n} from './lib/ui/components/StylePanel/DefaultStylePanelContent'\nexport {\n\tDefaultImageToolbar,\n\ttype TLUiImageToolbarProps,\n} from './lib/ui/components/Toolbar/DefaultImageToolbar'\nexport {\n\tDefaultImageToolbarContent,\n\ttype DefaultImageToolbarContentProps,\n} from './lib/ui/components/Toolbar/DefaultImageToolbarContent'\nexport {\n\tDefaultRichTextToolbar,\n\ttype TLUiRichTextToolbarProps,\n} from './lib/ui/components/Toolbar/DefaultRichTextToolbar'\nexport {\n\tDefaultRichTextToolbarContent,\n\ttype DefaultRichTextToolbarContentProps,\n} from './lib/ui/components/Toolbar/DefaultRichTextToolbarContent'\nexport {\n\tDefaultToolbar,\n\ttype DefaultToolbarProps,\n} from './lib/ui/components/Toolbar/DefaultToolbar'\nexport {\n\tArrowDownToolbarItem,\n\tArrowLeftToolbarItem,\n\tArrowRightToolbarItem,\n\tArrowToolbarItem,\n\tArrowUpToolbarItem,\n\tAssetToolbarItem,\n\tCheckBoxToolbarItem,\n\tCloudToolbarItem,\n\tDefaultToolbarContent,\n\tDiamondToolbarItem,\n\tDrawToolbarItem,\n\tEllipseToolbarItem,\n\tEraserToolbarItem,\n\tFrameToolbarItem,\n\tHandToolbarItem,\n\tHexagonToolbarItem,\n\tHighlightToolbarItem,\n\tLaserToolbarItem,\n\tLineToolbarItem,\n\tNoteToolbarItem,\n\tOvalToolbarItem,\n\tRectangleToolbarItem,\n\tRhombusToolbarItem,\n\tSelectToolbarItem,\n\tStarToolbarItem,\n\tTextToolbarItem,\n\tToolbarItem,\n\tTrapezoidToolbarItem,\n\tTriangleToolbarItem,\n\tXBoxToolbarItem,\n\tuseIsToolSelected,\n\ttype ToolbarItemProps,\n} from './lib/ui/components/Toolbar/DefaultToolbarContent'\nexport {\n\tDefaultVideoToolbar,\n\ttype TLUiVideoToolbarProps,\n} from './lib/ui/components/Toolbar/DefaultVideoToolbar'\nexport {\n\tDefaultVideoToolbarContent,\n\ttype DefaultVideoToolbarContentProps,\n} from './lib/ui/components/Toolbar/DefaultVideoToolbarContent'\nexport {\n\tOverflowingToolbar,\n\ttype OverflowingToolbarProps,\n} from './lib/ui/components/Toolbar/OverflowingToolbar'\nexport {\n\tCenteredTopPanelContainer,\n\ttype CenteredTopPanelContainerProps,\n} from './lib/ui/components/TopPanel/CenteredTopPanelContainer'\nexport { DefaultTopPanel } from './lib/ui/components/TopPanel/DefaultTopPanel'\nexport {\n\tDefaultZoomMenu,\n\ttype TLUiZoomMenuProps,\n} from './lib/ui/components/ZoomMenu/DefaultZoomMenu'\nexport { DefaultZoomMenuContent } from './lib/ui/components/ZoomMenu/DefaultZoomMenuContent'\nexport {\n\tArrangeMenuSubmenu,\n\tClipboardMenuGroup,\n\tConversionsMenuGroup,\n\tConvertToBookmarkMenuItem,\n\tConvertToEmbedMenuItem,\n\tCopyAsMenuGroup,\n\tCopyMenuItem,\n\tCursorChatItem,\n\tCutMenuItem,\n\tDeleteMenuItem,\n\tDuplicateMenuItem,\n\tEditLinkMenuItem,\n\tEditMenuSubmenu,\n\tFitFrameToContentMenuItem,\n\tGroupMenuItem,\n\tMoveToPageMenu,\n\tPasteMenuItem,\n\tPrintItem,\n\tRemoveFrameMenuItem,\n\tReorderMenuSubmenu,\n\tSelectAllMenuItem,\n\tToggleAutoSizeMenuItem,\n\tToggleDebugModeItem,\n\tToggleDynamicSizeModeItem,\n\tToggleEdgeScrollingItem,\n\tToggleFocusModeItem,\n\tToggleGridItem,\n\tToggleLockMenuItem,\n\tTogglePasteAtCursorItem,\n\tToggleReduceMotionItem,\n\tToggleSnapModeItem,\n\tToggleToolLockItem,\n\tToggleTransparentBgMenuItem,\n\tToggleWrapModeItem,\n\tUngroupMenuItem,\n\tUnlockAllMenuItem,\n\tZoomTo100MenuItem,\n\tZoomToFitMenuItem,\n\tZoomToSelectionMenuItem,\n} from './lib/ui/components/menu-items'\nexport {\n\tTldrawUiButton,\n\ttype TLUiButtonProps,\n} from './lib/ui/components/primitives/Button/TldrawUiButton'\nexport {\n\tTldrawUiButtonCheck,\n\ttype TLUiButtonCheckProps,\n} from './lib/ui/components/primitives/Button/TldrawUiButtonCheck'\nexport {\n\tTldrawUiButtonIcon,\n\ttype TLUiButtonIconProps,\n} from './lib/ui/components/primitives/Button/TldrawUiButtonIcon'\nexport {\n\tTldrawUiButtonLabel,\n\ttype TLUiButtonLabelProps,\n} from './lib/ui/components/primitives/Button/TldrawUiButtonLabel'\nexport {\n\tTldrawUiButtonPicker,\n\ttype TLUiButtonPickerProps,\n} from './lib/ui/components/primitives/TldrawUiButtonPicker'\nexport {\n\tTldrawUiContextualToolbar,\n\ttype TLUiContextualToolbarProps,\n} from './lib/ui/components/primitives/TldrawUiContextualToolbar'\nexport {\n\tTldrawUiDialogBody,\n\tTldrawUiDialogCloseButton,\n\tTldrawUiDialogFooter,\n\tTldrawUiDialogHeader,\n\tTldrawUiDialogTitle,\n\ttype TLUiDialogBodyProps,\n\ttype TLUiDialogFooterProps,\n\ttype TLUiDialogHeaderProps,\n\ttype TLUiDialogTitleProps,\n} from './lib/ui/components/primitives/TldrawUiDialog'\nexport {\n\tTldrawUiDropdownMenuCheckboxItem,\n\tTldrawUiDropdownMenuContent,\n\tTldrawUiDropdownMenuGroup,\n\tTldrawUiDropdownMenuIndicator,\n\tTldrawUiDropdownMenuItem,\n\tTldrawUiDropdownMenuRoot,\n\tTldrawUiDropdownMenuSub,\n\tTldrawUiDropdownMenuSubTrigger,\n\tTldrawUiDropdownMenuTrigger,\n\ttype TLUiDropdownMenuCheckboxItemProps,\n\ttype TLUiDropdownMenuContentProps,\n\ttype TLUiDropdownMenuGroupProps,\n\ttype TLUiDropdownMenuItemProps,\n\ttype TLUiDropdownMenuRootProps,\n\ttype TLUiDropdownMenuSubProps,\n\ttype TLUiDropdownMenuSubTriggerProps,\n\ttype TLUiDropdownMenuTriggerProps,\n} from './lib/ui/components/primitives/TldrawUiDropdownMenu'\nexport { TldrawUiIcon, type TLUiIconProps } from './lib/ui/components/primitives/TldrawUiIcon'\nexport { TldrawUiInput, type TLUiInputProps } from './lib/ui/components/primitives/TldrawUiInput'\nexport { TldrawUiKbd, type TLUiKbdProps } from './lib/ui/components/primitives/TldrawUiKbd'\nexport {\n\tTldrawUiPopover,\n\tTldrawUiPopoverContent,\n\tTldrawUiPopoverTrigger,\n\ttype TLUiPopoverContentProps,\n\ttype TLUiPopoverProps,\n\ttype TLUiPopoverTriggerProps,\n} from './lib/ui/components/primitives/TldrawUiPopover'\nexport { TldrawUiSlider, type TLUiSliderProps } from './lib/ui/components/primitives/TldrawUiSlider'\nexport {\n\tTldrawUiToolbar,\n\tTldrawUiToolbarButton,\n\tTldrawUiToolbarToggleGroup,\n\tTldrawUiToolbarToggleItem,\n\ttype TLUiToolbarButtonProps,\n\ttype TLUiToolbarProps,\n\ttype TLUiToolbarToggleGroupProps,\n\ttype TLUiToolbarToggleItemProps,\n} from './lib/ui/components/primitives/TldrawUiToolbar'\nexport {\n\tTldrawUiMenuCheckboxItem,\n\ttype TLUiMenuCheckboxItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem'\nexport {\n\tTldrawUiMenuContextProvider,\n\ttype TLUiMenuContextProviderProps,\n\ttype TLUiMenuContextType,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuContext'\nexport {\n\tTldrawUiMenuGroup,\n\ttype TLUiMenuGroupProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuGroup'\nexport {\n\tTldrawUiMenuItem,\n\ttype TLUiMenuItemProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuItem'\nexport {\n\tTldrawUiMenuSubmenu,\n\ttype TLUiMenuSubmenuProps,\n} from './lib/ui/components/primitives/menus/TldrawUiMenuSubmenu'\nexport { PORTRAIT_BREAKPOINT } from './lib/ui/constants'\nexport {\n\tTldrawUiContextProvider,\n\ttype TLUiContextProviderProps,\n} from './lib/ui/context/TldrawUiContextProvider'\nexport {\n\tTldrawUiA11yProvider,\n\tuseA11y,\n\ttype A11yPriority,\n\ttype A11yProviderProps,\n\ttype TLUiA11y,\n\ttype TLUiA11yContextType,\n} from './lib/ui/context/a11y'\nexport {\n\tunwrapLabel,\n\tuseActions,\n\ttype ActionsProviderProps,\n\ttype TLUiActionItem,\n\ttype TLUiActionsContextType,\n} from './lib/ui/context/actions'\nexport { AssetUrlsProvider, useAssetUrls } from './lib/ui/context/asset-urls'\nexport {\n\tBreakPointProvider,\n\tuseBreakpoint,\n\ttype BreakPointProviderProps,\n} from './lib/ui/context/breakpoints'\nexport {\n\tTldrawUiComponentsProvider,\n\tuseTldrawUiComponents,\n\ttype TLUiComponents,\n\ttype TLUiComponentsProviderProps,\n} from './lib/ui/context/components'\nexport {\n\tTldrawUiDialogsProvider,\n\tuseDialogs,\n\ttype TLUiDialog,\n\ttype TLUiDialogProps,\n\ttype TLUiDialogsContextType,\n\ttype TLUiDialogsProviderProps,\n} from './lib/ui/context/dialogs'\nexport {\n\tTldrawUiEventsProvider,\n\tuseUiEvents,\n\ttype EventsProviderProps,\n\ttype TLUiEventContextType,\n\ttype TLUiEventData,\n\ttype TLUiEventHandler,\n\ttype TLUiEventMap,\n\ttype TLUiEventSource,\n} from './lib/ui/context/events'\nexport {\n\tTldrawUiToastsProvider,\n\tuseToasts,\n\ttype AlertSeverity,\n\ttype TLUiToast,\n\ttype TLUiToastAction,\n\ttype TLUiToastsContextType,\n\ttype TLUiToastsProviderProps,\n} from './lib/ui/context/toasts'\nexport { useCanRedo, useCanUndo } from './lib/ui/hooks/menu-hooks'\nexport { useMenuClipboardEvents, useNativeClipboardEvents } from './lib/ui/hooks/useClipboardEvents'\nexport {\n\tuseCollaborationStatus,\n\tuseShowCollaborationUi,\n} from './lib/ui/hooks/useCollaborationStatus'\nexport { useCopyAs } from './lib/ui/hooks/useCopyAs'\nexport { useExportAs } from './lib/ui/hooks/useExportAs'\nexport { useKeyboardShortcuts } from './lib/ui/hooks/useKeyboardShortcuts'\nexport { useLocalStorageState } from './lib/ui/hooks/useLocalStorageState'\nexport { useMenuIsOpen } from './lib/ui/hooks/useMenuIsOpen'\nexport { useReadonly } from './lib/ui/hooks/useReadonly'\nexport { useRelevantStyles } from './lib/ui/hooks/useRelevantStyles'\nexport {\n\tuseTools,\n\ttype TLUiToolItem,\n\ttype TLUiToolsContextType,\n\ttype TLUiToolsProviderProps,\n} from './lib/ui/hooks/useTools'\nexport { type TLUiTranslationKey } from './lib/ui/hooks/useTranslation/TLUiTranslationKey'\nexport { type TLUiTranslation } from './lib/ui/hooks/useTranslation/translations'\nexport {\n\tuseCurrentTranslation,\n\tuseTranslation,\n\ttype TLUiTranslationContextType,\n\ttype TLUiTranslationProviderProps,\n} from './lib/ui/hooks/useTranslation/useTranslation'\nexport { type TLUiIconType } from './lib/ui/icon-types'\nexport { useDefaultHelpers, type TLUiOverrideHelpers, type TLUiOverrides } from './lib/ui/overrides'\nexport { containBoxSize, downsizeImage, type BoxWidthHeight } from './lib/utils/assets/assets'\nexport { preloadFont, type TLTypeFace } from './lib/utils/assets/preload-font'\nexport { getEmbedInfo, type TLEmbedResult } from './lib/utils/embeds/embeds'\nexport { putExcalidrawContent } from './lib/utils/excalidraw/putExcalidrawContent'\nexport { copyAs, type CopyAsOptions, type TLCopyType } from './lib/utils/export/copyAs'\nexport { exportToBlob } from './lib/utils/export/export'\nexport { downloadFile, exportAs, type ExportAsOptions } from './lib/utils/export/exportAs'\nexport { fitFrameToContent, removeFrame } from './lib/utils/frames/frames'\nexport {\n\tdefaultEditorAssetUrls,\n\tsetDefaultEditorAssetUrls,\n\ttype TLEditorAssetUrls,\n} from './lib/utils/static-assets/assetUrls'\nexport {\n\tKeyboardShiftEnterTweakExtension,\n\tdefaultAddFontsFromNode,\n\trenderHtmlFromRichText,\n\trenderHtmlFromRichTextForMeasurement,\n\trenderPlaintextFromRichText,\n\trenderRichTextFromHTML,\n\ttipTapDefaultExtensions,\n} from './lib/utils/text/richText'\nexport { truncateStringWithEllipsis } from './lib/utils/text/text'\nexport { TextDirection } from './lib/utils/text/textDirection'\nexport {\n\tTLV1AlignStyle,\n\tTLV1AssetType,\n\tTLV1ColorStyle,\n\tTLV1DashStyle,\n\tTLV1Decoration,\n\tTLV1FontStyle,\n\tTLV1ShapeType,\n\tTLV1SizeStyle,\n\tbuildFromV1Document,\n\ttype TLV1ArrowBinding,\n\ttype TLV1ArrowShape,\n\ttype TLV1Asset,\n\ttype TLV1BaseAsset,\n\ttype TLV1BaseBinding,\n\ttype TLV1BaseShape,\n\ttype TLV1Binding,\n\ttype TLV1Bounds,\n\ttype TLV1Document,\n\ttype TLV1DrawShape,\n\ttype TLV1EllipseShape,\n\ttype TLV1GroupShape,\n\ttype TLV1Handle,\n\ttype TLV1ImageAsset,\n\ttype TLV1ImageShape,\n\ttype TLV1Page,\n\ttype TLV1PageState,\n\ttype TLV1RectangleShape,\n\ttype TLV1Shape,\n\ttype TLV1ShapeStyles,\n\ttype TLV1StickyShape,\n\ttype TLV1TextShape,\n\ttype TLV1TriangleShape,\n\ttype TLV1VideoAsset,\n\ttype TLV1VideoShape,\n} from './lib/utils/tldr/buildFromV1Document'\nexport {\n\tTLDRAW_FILE_EXTENSION,\n\tparseAndLoadDocument,\n\tparseTldrawJsonFile,\n\tserializeTldrawJson,\n\tserializeTldrawJsonBlob,\n\ttype TldrawFile,\n\ttype TldrawFileParseError,\n} from './lib/utils/tldr/file'\n\nregisterTldrawLibraryVersion(\n\t(globalThis as any).TLDRAW_LIBRARY_NAME,\n\t(globalThis as any).TLDRAW_LIBRARY_VERSION,\n\t(globalThis as any).TLDRAW_LIBRARY_MODULES\n)\n"],
|
|
5
|
+
"mappings": "AAEA,SAAS,oCAAoC;AAC7C;AAAA,EACC;AAAA,EACA;AAAA,OAgBM;AACP,SAAS,+BAA+B;AACxC,SAAS,sBAAsB,kCAAkC;AACjE,SAAS,uBAAuB;AAChC,SAAS,sBAAsB;AAC/B,SAAS,qBAAqB;AAC9B;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP,SAAS,mCAAmC;AAE5C,cAAc;AACd,SAAS,cAAyE;AAClF,SAAS,mBAA0C;AACnD,SAAS,wBAAwB;AACjC,SAAS,qBAAqB;AAC9B,SAAS,kBAAkB,sBAAsB;AACjD,SAAS,sBAAsB;AAC/B,SAAS,iCAAiC;AAC1C,SAAS,6BAA6B;AACtC,SAAS,2BAA2B;AACpC;AAAA,EACC;AAAA,EACA;AAAA,OAMM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAGM;AACP,SAAS,yBAAyB;AAClC,SAAS,yBAAyB;AAClC,SAAS,kCAAkC;AAC3C,SAAS,oBAAoB;AAC7B,SAAS,sBAAsB;AAC/B,SAAS,sBAAsB;AAyB/B;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,OAEM;AACP,SAAS,yBAAyB;AAClC,SAAS,qBAAqB;AAC9B,SAAS,qBAA4C;AACrD,SAAS,sBAAsB;AAC/B,SAAS,sBAAsB;AAC/B,SAAS,sBAA8C;AACvD,SAAS,oBAAoB;AAC7B,SAAS,oBAAoB;AAC7B,SAAS,0BAA0B;AACnC;AAAA,EACC;AAAA,OAEM;AACP,SAAS,sBAAsB;AAC/B,SAAS,qBAAqB;AAC9B,SAAS,qBAAqB;AAC9B,SAAS,qBAAqB;AAC9B,SAAS,qBAA4C;AACrD;AAAA,EACC;AAAA,EACA;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OAGM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAGM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OAGM;AACP,SAAS,4BAA4B;AACrC,SAAS,sBAAsB,uBAAuB;AACtD,SAAS,2BAA2B;AACpC;AAAA,EACC;AAAA,EACA;AAAA,OAEM;AACP,SAAS,qBAAqB;AAC9B,SAAS,oBAAwC;AACjD,SAAS,qBAAqB;AAC9B,SAAS,qBAA4C;AACrD,SAAS,sBAA8C;AAEvD,SAAS,kBAAkB;AAC3B,SAAS,gBAAgB;AACzB,SAAS,iBAAiB;AAC1B,SAAS,kBAAkB;AAC3B,SAAS,gBAAgB;AACzB,SAAS,gBAAoC;AAC7C;AAAA,EACC;AAAA,OAGM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP;AAAA,EACuB;AAAA,EACtB,sBAAAA;AAAA,OAEM;AACP,SAAS,iCAAiC;AAC1C;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAEM;AACP,SAAS,wBAAwB;AACjC;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OACM;AACP;AAAA,EACC;AAAA,OAEM;AACP,SAAS,mCAAmC;AAC5C;AAAA,EACC;AAAA,OAEM;AACP,SAAS,6CAA6C;AACtD,SAAS,oBAAoB;AAC7B;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP,SAAS,sBAAsB;AAC/B,SAAS,wBAAwB;AACjC,SAAS,8BAA8B;AACvC,SAAS,wBAAwB;AACjC,SAAS,uBAAuB;AAChC,SAAS,qBAA8C;AACvD;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP,SAAS,kCAAkC;AAC3C,SAAS,yBAAyB;AAClC,SAAS,kBAAwC;AACjD,SAAS,eAAe;AACxB;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAIM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP,SAAS,uBAAuB;AAChC;AAAA,EACC;AAAA,OAEM;AACP,SAAS,8BAA8B;AACvC;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAKM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OASM;AACP,SAAS,oBAAwC;AACjD,SAAS,qBAA0C;AACnD,SAAS,mBAAsC;AAC/C;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,OAIM;AACP,SAAS,sBAA4C;AACrD;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAKM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAGM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,OAEM;AACP,SAAS,2BAA2B;AACpC;AAAA,EACC;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OAKM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OAIM;AACP,SAAS,mBAAmB,oBAAoB;AAChD;AAAA,EACC;AAAA,EACA;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OAGM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OAKM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OAOM;AACP;AAAA,EACC;AAAA,EACA;AAAA,OAMM;AACP,SAAS,YAAY,kBAAkB;AACvC,SAAS,wBAAwB,gCAAgC;AACjE;AAAA,EACC;AAAA,EACA;AAAA,OACM;AACP,SAAS,iBAAiB;AAC1B,SAAS,mBAAmB;AAC5B,SAAS,4BAA4B;AACrC,SAAS,4BAA4B;AACrC,SAAS,qBAAqB;AAC9B,SAAS,mBAAmB;AAC5B,SAAS,yBAAyB;AAClC;AAAA,EACC;AAAA,OAIM;AAGP;AAAA,EACC;AAAA,EACA;AAAA,OAGM;AAEP,SAAS,yBAAuE;AAChF,SAAS,gBAAgB,qBAA0C;AACnE,SAAS,mBAAoC;AAC7C,SAAS,oBAAwC;AACjD,SAAS,4BAA4B;AACrC,SAAS,cAAmD;AAC5D,SAAS,oBAAoB;AAC7B,SAAS,cAAc,gBAAsC;AAC7D,SAAS,mBAAmB,mBAAmB;AAC/C;AAAA,EACC;AAAA,EACA;AAAA,OAEM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP,SAAS,kCAAkC;AAC3C,SAAS,qBAAqB;AAC9B;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OA0BM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAGM;AAEP;AAAA,EACE;AAAA,EACA;AAAA,EACA;AACF;",
|
|
6
6
|
"names": ["DefaultContextMenu"]
|
|
7
7
|
}
|
|
@@ -150,6 +150,7 @@ class FrameShapeUtil extends BaseBoxShapeUtil {
|
|
|
150
150
|
},
|
|
151
151
|
[shape.id]
|
|
152
152
|
);
|
|
153
|
+
const zoomLevel = useValue("zoom level", () => this.editor.getZoomLevel(), [this.editor]);
|
|
153
154
|
const showFrameColors = this.options.showColors;
|
|
154
155
|
const color = theme[shape.props.color];
|
|
155
156
|
const frameFill = showFrameColors ? color.frame.fill : theme.black.frame.fill;
|
|
@@ -162,13 +163,12 @@ class FrameShapeUtil extends BaseBoxShapeUtil {
|
|
|
162
163
|
"rect",
|
|
163
164
|
{
|
|
164
165
|
className: classNames("tl-frame__body", { "tl-frame__creating": isCreating }),
|
|
166
|
+
width: shape.props.w + 1 / zoomLevel,
|
|
167
|
+
height: shape.props.h + 1 / zoomLevel,
|
|
165
168
|
fill: frameFill,
|
|
166
169
|
stroke: frameStroke,
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
height: `calc(${shape.props.h}px + 1px / var(--tl-zoom))`,
|
|
170
|
-
transform: `translate(calc(-0.5px / var(--tl-zoom)), calc(-0.5px / var(--tl-zoom)))`
|
|
171
|
-
}
|
|
170
|
+
y: -0.5 / zoomLevel,
|
|
171
|
+
x: -0.5 / zoomLevel
|
|
172
172
|
}
|
|
173
173
|
) }),
|
|
174
174
|
isCreating ? null : /* @__PURE__ */ jsx(
|