tldraw 3.16.0-next.f9f54ec051f3 → 4.0.0

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.
Files changed (542) hide show
  1. package/dist-cjs/index.d.ts +446 -112
  2. package/dist-cjs/index.js +50 -14
  3. package/dist-cjs/index.js.map +2 -2
  4. package/dist-cjs/lib/Tldraw.js +12 -2
  5. package/dist-cjs/lib/Tldraw.js.map +2 -2
  6. package/dist-cjs/lib/canvas/TldrawScribble.js +1 -1
  7. package/dist-cjs/lib/canvas/TldrawScribble.js.map +2 -2
  8. package/dist-cjs/lib/defaultExternalContentHandlers.js +15 -4
  9. package/dist-cjs/lib/defaultExternalContentHandlers.js.map +2 -2
  10. package/dist-cjs/lib/shapes/arrow/ArrowShapeUtil.js +3 -3
  11. package/dist-cjs/lib/shapes/arrow/ArrowShapeUtil.js.map +2 -2
  12. package/dist-cjs/lib/shapes/arrow/arrow-types.js.map +1 -1
  13. package/dist-cjs/lib/shapes/arrow/arrowLabel.js +6 -0
  14. package/dist-cjs/lib/shapes/arrow/arrowLabel.js.map +3 -3
  15. package/dist-cjs/lib/shapes/arrow/arrowTargetState.js +4 -3
  16. package/dist-cjs/lib/shapes/arrow/arrowTargetState.js.map +2 -2
  17. package/dist-cjs/lib/shapes/arrow/elbow/ElbowArrowDebug.js +3 -3
  18. package/dist-cjs/lib/shapes/arrow/elbow/ElbowArrowDebug.js.map +1 -1
  19. package/dist-cjs/lib/shapes/arrow/toolStates/Pointing.js +1 -1
  20. package/dist-cjs/lib/shapes/arrow/toolStates/Pointing.js.map +2 -2
  21. package/dist-cjs/lib/shapes/bookmark/BookmarkShapeUtil.js +4 -4
  22. package/dist-cjs/lib/shapes/bookmark/BookmarkShapeUtil.js.map +2 -2
  23. package/dist-cjs/lib/shapes/draw/DrawShapeUtil.js +3 -3
  24. package/dist-cjs/lib/shapes/draw/DrawShapeUtil.js.map +2 -2
  25. package/dist-cjs/lib/shapes/embed/EmbedShapeUtil.js +1 -1
  26. package/dist-cjs/lib/shapes/embed/EmbedShapeUtil.js.map +1 -1
  27. package/dist-cjs/lib/shapes/frame/FrameShapeUtil.js +20 -13
  28. package/dist-cjs/lib/shapes/frame/FrameShapeUtil.js.map +2 -2
  29. package/dist-cjs/lib/shapes/frame/components/FrameHeading.js +1 -1
  30. package/dist-cjs/lib/shapes/frame/components/FrameHeading.js.map +2 -2
  31. package/dist-cjs/lib/shapes/frame/components/FrameLabelInput.js +8 -2
  32. package/dist-cjs/lib/shapes/frame/components/FrameLabelInput.js.map +2 -2
  33. package/dist-cjs/lib/shapes/geo/GeoShapeUtil.js +3 -2
  34. package/dist-cjs/lib/shapes/geo/GeoShapeUtil.js.map +2 -2
  35. package/dist-cjs/lib/shapes/geo/components/GeoShapeBody.js +2 -1
  36. package/dist-cjs/lib/shapes/geo/components/GeoShapeBody.js.map +2 -2
  37. package/dist-cjs/lib/shapes/highlight/HighlightShapeUtil.js +5 -1
  38. package/dist-cjs/lib/shapes/highlight/HighlightShapeUtil.js.map +2 -2
  39. package/dist-cjs/lib/shapes/image/ImageShapeUtil.js +6 -3
  40. package/dist-cjs/lib/shapes/image/ImageShapeUtil.js.map +2 -2
  41. package/dist-cjs/lib/shapes/line/LineShapeUtil.js +5 -1
  42. package/dist-cjs/lib/shapes/line/LineShapeUtil.js.map +2 -2
  43. package/dist-cjs/lib/shapes/note/NoteShapeUtil.js +6 -5
  44. package/dist-cjs/lib/shapes/note/NoteShapeUtil.js.map +2 -2
  45. package/dist-cjs/lib/shapes/shared/HyperlinkButton.js +4 -4
  46. package/dist-cjs/lib/shapes/shared/HyperlinkButton.js.map +2 -2
  47. package/dist-cjs/lib/shapes/shared/PlainTextLabel.js +1 -3
  48. package/dist-cjs/lib/shapes/shared/PlainTextLabel.js.map +2 -2
  49. package/dist-cjs/lib/shapes/shared/ShapeFill.js +4 -4
  50. package/dist-cjs/lib/shapes/shared/ShapeFill.js.map +2 -2
  51. package/dist-cjs/lib/shapes/shared/freehand/svg.js.map +2 -2
  52. package/dist-cjs/lib/shapes/shared/useEditablePlainText.js +3 -5
  53. package/dist-cjs/lib/shapes/shared/useEditablePlainText.js.map +2 -2
  54. package/dist-cjs/lib/shapes/shared/useImageOrVideoAsset.js +0 -2
  55. package/dist-cjs/lib/shapes/shared/useImageOrVideoAsset.js.map +2 -2
  56. package/dist-cjs/lib/shapes/shared/usePrefersReducedMotion.js +10 -1
  57. package/dist-cjs/lib/shapes/shared/usePrefersReducedMotion.js.map +2 -2
  58. package/dist-cjs/lib/shapes/text/PlainTextArea.js +3 -2
  59. package/dist-cjs/lib/shapes/text/PlainTextArea.js.map +2 -2
  60. package/dist-cjs/lib/shapes/text/RichTextArea.js +3 -3
  61. package/dist-cjs/lib/shapes/text/RichTextArea.js.map +2 -2
  62. package/dist-cjs/lib/shapes/text/TextShapeUtil.js +2 -2
  63. package/dist-cjs/lib/shapes/text/TextShapeUtil.js.map +2 -2
  64. package/dist-cjs/lib/shapes/video/VideoShapeUtil.js +3 -3
  65. package/dist-cjs/lib/shapes/video/VideoShapeUtil.js.map +1 -1
  66. package/dist-cjs/lib/tools/EraserTool/childStates/Erasing.js +25 -1
  67. package/dist-cjs/lib/tools/EraserTool/childStates/Erasing.js.map +2 -2
  68. package/dist-cjs/lib/tools/EraserTool/childStates/Pointing.js +12 -0
  69. package/dist-cjs/lib/tools/EraserTool/childStates/Pointing.js.map +2 -2
  70. package/dist-cjs/lib/tools/SelectTool/childStates/DraggingHandle.js +3 -1
  71. package/dist-cjs/lib/tools/SelectTool/childStates/DraggingHandle.js.map +2 -2
  72. package/dist-cjs/lib/tools/SelectTool/childStates/Translating.js.map +2 -2
  73. package/dist-cjs/lib/ui/TldrawUi.js +27 -12
  74. package/dist-cjs/lib/ui/TldrawUi.js.map +3 -3
  75. package/dist-cjs/lib/ui/assetUrls.js +13 -10
  76. package/dist-cjs/lib/ui/assetUrls.js.map +2 -2
  77. package/dist-cjs/lib/ui/components/A11y.js +1 -1
  78. package/dist-cjs/lib/ui/components/A11y.js.map +2 -2
  79. package/dist-cjs/lib/ui/components/AccessibilityMenu.js +35 -0
  80. package/dist-cjs/lib/ui/components/AccessibilityMenu.js.map +7 -0
  81. package/dist-cjs/lib/ui/components/ActionsMenu/DefaultActionsMenu.js +12 -3
  82. package/dist-cjs/lib/ui/components/ActionsMenu/DefaultActionsMenu.js.map +2 -2
  83. package/dist-cjs/lib/ui/components/{FollowingIndicator.js → DefaultFollowingIndicator.js} +6 -6
  84. package/dist-cjs/lib/ui/components/DefaultFollowingIndicator.js.map +7 -0
  85. package/dist-cjs/lib/ui/components/DefaultMenuPanel.js +3 -2
  86. package/dist-cjs/lib/ui/components/DefaultMenuPanel.js.map +2 -2
  87. package/dist-cjs/lib/ui/components/InputModeMenu.js +77 -0
  88. package/dist-cjs/lib/ui/components/InputModeMenu.js.map +7 -0
  89. package/dist-cjs/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.js +6 -6
  90. package/dist-cjs/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.js.map +1 -1
  91. package/dist-cjs/lib/ui/components/LanguageMenu.js +1 -0
  92. package/dist-cjs/lib/ui/components/LanguageMenu.js.map +2 -2
  93. package/dist-cjs/lib/ui/components/MainMenu/DefaultMainMenuContent.js +5 -3
  94. package/dist-cjs/lib/ui/components/MainMenu/DefaultMainMenuContent.js.map +2 -2
  95. package/dist-cjs/lib/ui/components/Minimap/DefaultMinimap.js +2 -1
  96. package/dist-cjs/lib/ui/components/Minimap/DefaultMinimap.js.map +2 -2
  97. package/dist-cjs/lib/ui/components/Minimap/MinimapManager.js +4 -4
  98. package/dist-cjs/lib/ui/components/Minimap/MinimapManager.js.map +2 -2
  99. package/dist-cjs/lib/ui/components/MobileStylePanel.js +5 -3
  100. package/dist-cjs/lib/ui/components/MobileStylePanel.js.map +2 -2
  101. package/dist-cjs/lib/ui/components/NavigationPanel/DefaultNavigationPanel.js +1 -1
  102. package/dist-cjs/lib/ui/components/NavigationPanel/DefaultNavigationPanel.js.map +2 -2
  103. package/dist-cjs/lib/ui/components/PageMenu/DefaultPageMenu.js +3 -2
  104. package/dist-cjs/lib/ui/components/PageMenu/DefaultPageMenu.js.map +2 -2
  105. package/dist-cjs/lib/ui/components/SharePanel/PeopleMenuItem.js +3 -2
  106. package/dist-cjs/lib/ui/components/SharePanel/PeopleMenuItem.js.map +2 -2
  107. package/dist-cjs/lib/ui/components/SharePanel/UserPresenceColorPicker.js +2 -2
  108. package/dist-cjs/lib/ui/components/SharePanel/UserPresenceColorPicker.js.map +2 -2
  109. package/dist-cjs/lib/ui/components/StylePanel/DefaultStylePanel.js +13 -4
  110. package/dist-cjs/lib/ui/components/StylePanel/DefaultStylePanel.js.map +2 -2
  111. package/dist-cjs/lib/ui/components/StylePanel/DefaultStylePanelContent.js +249 -279
  112. package/dist-cjs/lib/ui/components/StylePanel/DefaultStylePanelContent.js.map +2 -2
  113. package/dist-cjs/lib/ui/components/StylePanel/StylePanelButtonPicker.js +147 -0
  114. package/dist-cjs/lib/ui/components/StylePanel/StylePanelButtonPicker.js.map +7 -0
  115. package/dist-cjs/lib/ui/components/StylePanel/StylePanelContext.js +70 -0
  116. package/dist-cjs/lib/ui/components/StylePanel/StylePanelContext.js.map +7 -0
  117. package/dist-cjs/lib/ui/components/StylePanel/{DoubleDropdownPicker.js → StylePanelDoubleDropdownPicker.js} +26 -25
  118. package/dist-cjs/lib/ui/components/StylePanel/StylePanelDoubleDropdownPicker.js.map +7 -0
  119. package/dist-cjs/lib/ui/components/StylePanel/{DropdownPicker.js → StylePanelDropdownPicker.js} +47 -43
  120. package/dist-cjs/lib/ui/components/StylePanel/StylePanelDropdownPicker.js.map +7 -0
  121. package/dist-cjs/lib/ui/components/StylePanel/StylePanelSubheading.js +28 -0
  122. package/dist-cjs/lib/ui/components/StylePanel/StylePanelSubheading.js.map +7 -0
  123. package/dist-cjs/lib/ui/components/Toolbar/AltTextEditor.js +2 -0
  124. package/dist-cjs/lib/ui/components/Toolbar/AltTextEditor.js.map +2 -2
  125. package/dist-cjs/lib/ui/components/Toolbar/DefaultImageToolbarContent.js +39 -10
  126. package/dist-cjs/lib/ui/components/Toolbar/DefaultImageToolbarContent.js.map +2 -2
  127. package/dist-cjs/lib/ui/components/Toolbar/DefaultToolbar.js +66 -21
  128. package/dist-cjs/lib/ui/components/Toolbar/DefaultToolbar.js.map +3 -3
  129. package/dist-cjs/lib/ui/components/Toolbar/DefaultVideoToolbarContent.js +15 -3
  130. package/dist-cjs/lib/ui/components/Toolbar/DefaultVideoToolbarContent.js.map +2 -2
  131. package/dist-cjs/lib/ui/components/Toolbar/LinkEditor.js +2 -1
  132. package/dist-cjs/lib/ui/components/Toolbar/LinkEditor.js.map +2 -2
  133. package/dist-cjs/lib/ui/components/Toolbar/OverflowingToolbar.js +189 -80
  134. package/dist-cjs/lib/ui/components/Toolbar/OverflowingToolbar.js.map +3 -3
  135. package/dist-cjs/lib/ui/components/Toolbar/ToggleToolLockedButton.js +10 -5
  136. package/dist-cjs/lib/ui/components/Toolbar/ToggleToolLockedButton.js.map +2 -2
  137. package/dist-cjs/lib/ui/components/menu-items.js +8 -0
  138. package/dist-cjs/lib/ui/components/menu-items.js.map +2 -2
  139. package/dist-cjs/lib/ui/components/primitives/TldrawUiContextualToolbar.js +11 -2
  140. package/dist-cjs/lib/ui/components/primitives/TldrawUiContextualToolbar.js.map +2 -2
  141. package/dist-cjs/lib/ui/components/primitives/TldrawUiInput.js +5 -3
  142. package/dist-cjs/lib/ui/components/primitives/TldrawUiInput.js.map +2 -2
  143. package/dist-cjs/lib/ui/components/primitives/TldrawUiPopover.js +3 -2
  144. package/dist-cjs/lib/ui/components/primitives/TldrawUiPopover.js.map +3 -3
  145. package/dist-cjs/lib/ui/components/primitives/TldrawUiSlider.js +18 -5
  146. package/dist-cjs/lib/ui/components/primitives/TldrawUiSlider.js.map +2 -2
  147. package/dist-cjs/lib/ui/components/primitives/TldrawUiToolbar.js +33 -7
  148. package/dist-cjs/lib/ui/components/primitives/TldrawUiToolbar.js.map +2 -2
  149. package/dist-cjs/lib/ui/components/primitives/TldrawUiTooltip.js +317 -0
  150. package/dist-cjs/lib/ui/components/primitives/TldrawUiTooltip.js.map +7 -0
  151. package/dist-cjs/lib/ui/components/primitives/layout.js +76 -0
  152. package/dist-cjs/lib/ui/components/primitives/layout.js.map +7 -0
  153. package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem.js +3 -0
  154. package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem.js.map +2 -2
  155. package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuContext.js.map +2 -2
  156. package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuGroup.js +25 -12
  157. package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuGroup.js.map +2 -2
  158. package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuItem.js +154 -20
  159. package/dist-cjs/lib/ui/components/primitives/menus/TldrawUiMenuItem.js.map +2 -2
  160. package/dist-cjs/lib/ui/context/TldrawUiContextProvider.js +3 -2
  161. package/dist-cjs/lib/ui/context/TldrawUiContextProvider.js.map +2 -2
  162. package/dist-cjs/lib/ui/context/actions.js +44 -30
  163. package/dist-cjs/lib/ui/context/actions.js.map +2 -2
  164. package/dist-cjs/lib/ui/context/components.js +2 -0
  165. package/dist-cjs/lib/ui/context/components.js.map +2 -2
  166. package/dist-cjs/lib/ui/context/events.js.map +2 -2
  167. package/dist-cjs/lib/ui/hooks/useClipboardEvents.js +1 -1
  168. package/dist-cjs/lib/ui/hooks/useClipboardEvents.js.map +2 -2
  169. package/dist-cjs/lib/ui/hooks/useExportAs.js +3 -2
  170. package/dist-cjs/lib/ui/hooks/useExportAs.js.map +2 -2
  171. package/dist-cjs/lib/ui/hooks/useTools.js +94 -9
  172. package/dist-cjs/lib/ui/hooks/useTools.js.map +2 -2
  173. package/dist-cjs/lib/ui/hooks/useTranslation/TLUiTranslationKey.js.map +1 -1
  174. package/dist-cjs/lib/ui/hooks/useTranslation/defaultTranslation.js +14 -1
  175. package/dist-cjs/lib/ui/hooks/useTranslation/defaultTranslation.js.map +2 -2
  176. package/dist-cjs/lib/ui/kbd-utils.js +9 -3
  177. package/dist-cjs/lib/ui/kbd-utils.js.map +2 -2
  178. package/dist-cjs/lib/ui/version.js +4 -4
  179. package/dist-cjs/lib/ui/version.js.map +1 -1
  180. package/dist-cjs/lib/utils/export/copyAs.js +1 -2
  181. package/dist-cjs/lib/utils/export/copyAs.js.map +2 -2
  182. package/dist-cjs/lib/utils/export/export.js +0 -20
  183. package/dist-cjs/lib/utils/export/export.js.map +2 -2
  184. package/dist-cjs/lib/utils/export/exportAs.js +1 -2
  185. package/dist-cjs/lib/utils/export/exportAs.js.map +2 -2
  186. package/dist-esm/index.d.mts +446 -112
  187. package/dist-esm/index.mjs +93 -29
  188. package/dist-esm/index.mjs.map +2 -2
  189. package/dist-esm/lib/Tldraw.mjs +14 -4
  190. package/dist-esm/lib/Tldraw.mjs.map +2 -2
  191. package/dist-esm/lib/canvas/TldrawScribble.mjs +1 -1
  192. package/dist-esm/lib/canvas/TldrawScribble.mjs.map +2 -2
  193. package/dist-esm/lib/defaultExternalContentHandlers.mjs +15 -4
  194. package/dist-esm/lib/defaultExternalContentHandlers.mjs.map +2 -2
  195. package/dist-esm/lib/shapes/arrow/ArrowShapeUtil.mjs +4 -3
  196. package/dist-esm/lib/shapes/arrow/ArrowShapeUtil.mjs.map +2 -2
  197. package/dist-esm/lib/shapes/arrow/arrowLabel.mjs +6 -0
  198. package/dist-esm/lib/shapes/arrow/arrowLabel.mjs.map +3 -3
  199. package/dist-esm/lib/shapes/arrow/arrowTargetState.mjs +4 -3
  200. package/dist-esm/lib/shapes/arrow/arrowTargetState.mjs.map +2 -2
  201. package/dist-esm/lib/shapes/arrow/elbow/ElbowArrowDebug.mjs +3 -3
  202. package/dist-esm/lib/shapes/arrow/elbow/ElbowArrowDebug.mjs.map +1 -1
  203. package/dist-esm/lib/shapes/arrow/toolStates/Pointing.mjs +1 -1
  204. package/dist-esm/lib/shapes/arrow/toolStates/Pointing.mjs.map +2 -2
  205. package/dist-esm/lib/shapes/bookmark/BookmarkShapeUtil.mjs +4 -5
  206. package/dist-esm/lib/shapes/bookmark/BookmarkShapeUtil.mjs.map +2 -2
  207. package/dist-esm/lib/shapes/draw/DrawShapeUtil.mjs +4 -3
  208. package/dist-esm/lib/shapes/draw/DrawShapeUtil.mjs.map +2 -2
  209. package/dist-esm/lib/shapes/embed/EmbedShapeUtil.mjs +1 -1
  210. package/dist-esm/lib/shapes/embed/EmbedShapeUtil.mjs.map +1 -1
  211. package/dist-esm/lib/shapes/frame/FrameShapeUtil.mjs +21 -13
  212. package/dist-esm/lib/shapes/frame/FrameShapeUtil.mjs.map +2 -2
  213. package/dist-esm/lib/shapes/frame/components/FrameHeading.mjs +1 -1
  214. package/dist-esm/lib/shapes/frame/components/FrameHeading.mjs.map +2 -2
  215. package/dist-esm/lib/shapes/frame/components/FrameLabelInput.mjs +9 -3
  216. package/dist-esm/lib/shapes/frame/components/FrameLabelInput.mjs.map +2 -2
  217. package/dist-esm/lib/shapes/geo/GeoShapeUtil.mjs +4 -2
  218. package/dist-esm/lib/shapes/geo/GeoShapeUtil.mjs.map +2 -2
  219. package/dist-esm/lib/shapes/geo/components/GeoShapeBody.mjs +2 -1
  220. package/dist-esm/lib/shapes/geo/components/GeoShapeBody.mjs.map +2 -2
  221. package/dist-esm/lib/shapes/highlight/HighlightShapeUtil.mjs +6 -1
  222. package/dist-esm/lib/shapes/highlight/HighlightShapeUtil.mjs.map +2 -2
  223. package/dist-esm/lib/shapes/image/ImageShapeUtil.mjs +6 -3
  224. package/dist-esm/lib/shapes/image/ImageShapeUtil.mjs.map +2 -2
  225. package/dist-esm/lib/shapes/line/LineShapeUtil.mjs +6 -1
  226. package/dist-esm/lib/shapes/line/LineShapeUtil.mjs.map +2 -2
  227. package/dist-esm/lib/shapes/note/NoteShapeUtil.mjs +7 -5
  228. package/dist-esm/lib/shapes/note/NoteShapeUtil.mjs.map +2 -2
  229. package/dist-esm/lib/shapes/shared/HyperlinkButton.mjs +5 -5
  230. package/dist-esm/lib/shapes/shared/HyperlinkButton.mjs.map +2 -2
  231. package/dist-esm/lib/shapes/shared/PlainTextLabel.mjs +1 -3
  232. package/dist-esm/lib/shapes/shared/PlainTextLabel.mjs.map +2 -2
  233. package/dist-esm/lib/shapes/shared/ShapeFill.mjs +5 -4
  234. package/dist-esm/lib/shapes/shared/ShapeFill.mjs.map +2 -2
  235. package/dist-esm/lib/shapes/shared/freehand/svg.mjs.map +2 -2
  236. package/dist-esm/lib/shapes/shared/useEditablePlainText.mjs +3 -6
  237. package/dist-esm/lib/shapes/shared/useEditablePlainText.mjs.map +2 -2
  238. package/dist-esm/lib/shapes/shared/useImageOrVideoAsset.mjs +0 -2
  239. package/dist-esm/lib/shapes/shared/useImageOrVideoAsset.mjs.map +2 -2
  240. package/dist-esm/lib/shapes/shared/usePrefersReducedMotion.mjs +10 -1
  241. package/dist-esm/lib/shapes/shared/usePrefersReducedMotion.mjs.map +2 -2
  242. package/dist-esm/lib/shapes/text/PlainTextArea.mjs +4 -3
  243. package/dist-esm/lib/shapes/text/PlainTextArea.mjs.map +2 -2
  244. package/dist-esm/lib/shapes/text/RichTextArea.mjs +3 -4
  245. package/dist-esm/lib/shapes/text/RichTextArea.mjs.map +2 -2
  246. package/dist-esm/lib/shapes/text/TextShapeUtil.mjs +3 -2
  247. package/dist-esm/lib/shapes/text/TextShapeUtil.mjs.map +2 -2
  248. package/dist-esm/lib/shapes/video/VideoShapeUtil.mjs +3 -3
  249. package/dist-esm/lib/shapes/video/VideoShapeUtil.mjs.map +1 -1
  250. package/dist-esm/lib/tools/EraserTool/childStates/Erasing.mjs +26 -1
  251. package/dist-esm/lib/tools/EraserTool/childStates/Erasing.mjs.map +2 -2
  252. package/dist-esm/lib/tools/EraserTool/childStates/Pointing.mjs +13 -0
  253. package/dist-esm/lib/tools/EraserTool/childStates/Pointing.mjs.map +2 -2
  254. package/dist-esm/lib/tools/SelectTool/childStates/DraggingHandle.mjs +3 -1
  255. package/dist-esm/lib/tools/SelectTool/childStates/DraggingHandle.mjs.map +2 -2
  256. package/dist-esm/lib/tools/SelectTool/childStates/Translating.mjs.map +2 -2
  257. package/dist-esm/lib/ui/TldrawUi.mjs +29 -14
  258. package/dist-esm/lib/ui/TldrawUi.mjs.map +3 -3
  259. package/dist-esm/lib/ui/assetUrls.mjs +13 -10
  260. package/dist-esm/lib/ui/assetUrls.mjs.map +2 -2
  261. package/dist-esm/lib/ui/components/A11y.mjs +1 -2
  262. package/dist-esm/lib/ui/components/A11y.mjs.map +2 -2
  263. package/dist-esm/lib/ui/components/AccessibilityMenu.mjs +19 -0
  264. package/dist-esm/lib/ui/components/AccessibilityMenu.mjs.map +7 -0
  265. package/dist-esm/lib/ui/components/ActionsMenu/DefaultActionsMenu.mjs +12 -3
  266. package/dist-esm/lib/ui/components/ActionsMenu/DefaultActionsMenu.mjs.map +2 -2
  267. package/dist-esm/lib/ui/components/{FollowingIndicator.mjs → DefaultFollowingIndicator.mjs} +3 -3
  268. package/dist-esm/lib/ui/components/DefaultFollowingIndicator.mjs.map +7 -0
  269. package/dist-esm/lib/ui/components/DefaultMenuPanel.mjs +3 -2
  270. package/dist-esm/lib/ui/components/DefaultMenuPanel.mjs.map +2 -2
  271. package/dist-esm/lib/ui/components/InputModeMenu.mjs +57 -0
  272. package/dist-esm/lib/ui/components/InputModeMenu.mjs.map +7 -0
  273. package/dist-esm/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.mjs +6 -6
  274. package/dist-esm/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.mjs.map +1 -1
  275. package/dist-esm/lib/ui/components/LanguageMenu.mjs +1 -0
  276. package/dist-esm/lib/ui/components/LanguageMenu.mjs.map +2 -2
  277. package/dist-esm/lib/ui/components/MainMenu/DefaultMainMenuContent.mjs +5 -5
  278. package/dist-esm/lib/ui/components/MainMenu/DefaultMainMenuContent.mjs.map +2 -2
  279. package/dist-esm/lib/ui/components/Minimap/DefaultMinimap.mjs +2 -1
  280. package/dist-esm/lib/ui/components/Minimap/DefaultMinimap.mjs.map +2 -2
  281. package/dist-esm/lib/ui/components/Minimap/MinimapManager.mjs +4 -4
  282. package/dist-esm/lib/ui/components/Minimap/MinimapManager.mjs.map +2 -2
  283. package/dist-esm/lib/ui/components/MobileStylePanel.mjs +6 -3
  284. package/dist-esm/lib/ui/components/MobileStylePanel.mjs.map +2 -2
  285. package/dist-esm/lib/ui/components/NavigationPanel/DefaultNavigationPanel.mjs +1 -1
  286. package/dist-esm/lib/ui/components/NavigationPanel/DefaultNavigationPanel.mjs.map +2 -2
  287. package/dist-esm/lib/ui/components/PageMenu/DefaultPageMenu.mjs +3 -3
  288. package/dist-esm/lib/ui/components/PageMenu/DefaultPageMenu.mjs.map +2 -2
  289. package/dist-esm/lib/ui/components/SharePanel/PeopleMenuItem.mjs +3 -2
  290. package/dist-esm/lib/ui/components/SharePanel/PeopleMenuItem.mjs.map +2 -2
  291. package/dist-esm/lib/ui/components/SharePanel/UserPresenceColorPicker.mjs +2 -2
  292. package/dist-esm/lib/ui/components/SharePanel/UserPresenceColorPicker.mjs.map +2 -2
  293. package/dist-esm/lib/ui/components/StylePanel/DefaultStylePanel.mjs +18 -5
  294. package/dist-esm/lib/ui/components/StylePanel/DefaultStylePanel.mjs.map +2 -2
  295. package/dist-esm/lib/ui/components/StylePanel/DefaultStylePanelContent.mjs +251 -283
  296. package/dist-esm/lib/ui/components/StylePanel/DefaultStylePanelContent.mjs.map +2 -2
  297. package/dist-esm/lib/ui/components/StylePanel/StylePanelButtonPicker.mjs +135 -0
  298. package/dist-esm/lib/ui/components/StylePanel/StylePanelButtonPicker.mjs.map +7 -0
  299. package/dist-esm/lib/ui/components/StylePanel/StylePanelContext.mjs +50 -0
  300. package/dist-esm/lib/ui/components/StylePanel/StylePanelContext.mjs.map +7 -0
  301. package/dist-esm/lib/ui/components/StylePanel/{DoubleDropdownPicker.mjs → StylePanelDoubleDropdownPicker.mjs} +23 -22
  302. package/dist-esm/lib/ui/components/StylePanel/StylePanelDoubleDropdownPicker.mjs.map +7 -0
  303. package/dist-esm/lib/ui/components/StylePanel/{DropdownPicker.mjs → StylePanelDropdownPicker.mjs} +44 -40
  304. package/dist-esm/lib/ui/components/StylePanel/StylePanelDropdownPicker.mjs.map +7 -0
  305. package/dist-esm/lib/ui/components/StylePanel/StylePanelSubheading.mjs +8 -0
  306. package/dist-esm/lib/ui/components/StylePanel/StylePanelSubheading.mjs.map +7 -0
  307. package/dist-esm/lib/ui/components/Toolbar/AltTextEditor.mjs +2 -0
  308. package/dist-esm/lib/ui/components/Toolbar/AltTextEditor.mjs.map +2 -2
  309. package/dist-esm/lib/ui/components/Toolbar/DefaultImageToolbarContent.mjs +39 -10
  310. package/dist-esm/lib/ui/components/Toolbar/DefaultImageToolbarContent.mjs.map +2 -2
  311. package/dist-esm/lib/ui/components/Toolbar/DefaultToolbar.mjs +56 -21
  312. package/dist-esm/lib/ui/components/Toolbar/DefaultToolbar.mjs.map +2 -2
  313. package/dist-esm/lib/ui/components/Toolbar/DefaultVideoToolbarContent.mjs +15 -3
  314. package/dist-esm/lib/ui/components/Toolbar/DefaultVideoToolbarContent.mjs.map +2 -2
  315. package/dist-esm/lib/ui/components/Toolbar/LinkEditor.mjs +2 -1
  316. package/dist-esm/lib/ui/components/Toolbar/LinkEditor.mjs.map +2 -2
  317. package/dist-esm/lib/ui/components/Toolbar/OverflowingToolbar.mjs +192 -81
  318. package/dist-esm/lib/ui/components/Toolbar/OverflowingToolbar.mjs.map +3 -3
  319. package/dist-esm/lib/ui/components/Toolbar/ToggleToolLockedButton.mjs +10 -5
  320. package/dist-esm/lib/ui/components/Toolbar/ToggleToolLockedButton.mjs.map +2 -2
  321. package/dist-esm/lib/ui/components/menu-items.mjs +8 -0
  322. package/dist-esm/lib/ui/components/menu-items.mjs.map +2 -2
  323. package/dist-esm/lib/ui/components/primitives/TldrawUiContextualToolbar.mjs +11 -3
  324. package/dist-esm/lib/ui/components/primitives/TldrawUiContextualToolbar.mjs.map +2 -2
  325. package/dist-esm/lib/ui/components/primitives/TldrawUiInput.mjs +6 -4
  326. package/dist-esm/lib/ui/components/primitives/TldrawUiInput.mjs.map +2 -2
  327. package/dist-esm/lib/ui/components/primitives/TldrawUiPopover.mjs +3 -2
  328. package/dist-esm/lib/ui/components/primitives/TldrawUiPopover.mjs.map +2 -2
  329. package/dist-esm/lib/ui/components/primitives/TldrawUiSlider.mjs +18 -5
  330. package/dist-esm/lib/ui/components/primitives/TldrawUiSlider.mjs.map +2 -2
  331. package/dist-esm/lib/ui/components/primitives/TldrawUiToolbar.mjs +33 -7
  332. package/dist-esm/lib/ui/components/primitives/TldrawUiToolbar.mjs.map +2 -2
  333. package/dist-esm/lib/ui/components/primitives/TldrawUiTooltip.mjs +295 -0
  334. package/dist-esm/lib/ui/components/primitives/TldrawUiTooltip.mjs.map +7 -0
  335. package/dist-esm/lib/ui/components/primitives/layout.mjs +46 -0
  336. package/dist-esm/lib/ui/components/primitives/layout.mjs.map +7 -0
  337. package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem.mjs +3 -0
  338. package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem.mjs.map +2 -2
  339. package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuContext.mjs.map +2 -2
  340. package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuGroup.mjs +25 -12
  341. package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuGroup.mjs.map +2 -2
  342. package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuItem.mjs +162 -22
  343. package/dist-esm/lib/ui/components/primitives/menus/TldrawUiMenuItem.mjs.map +2 -2
  344. package/dist-esm/lib/ui/context/TldrawUiContextProvider.mjs +3 -2
  345. package/dist-esm/lib/ui/context/TldrawUiContextProvider.mjs.map +2 -2
  346. package/dist-esm/lib/ui/context/actions.mjs +44 -30
  347. package/dist-esm/lib/ui/context/actions.mjs.map +2 -2
  348. package/dist-esm/lib/ui/context/components.mjs +2 -0
  349. package/dist-esm/lib/ui/context/components.mjs.map +2 -2
  350. package/dist-esm/lib/ui/context/events.mjs.map +2 -2
  351. package/dist-esm/lib/ui/hooks/useClipboardEvents.mjs +1 -2
  352. package/dist-esm/lib/ui/hooks/useClipboardEvents.mjs.map +2 -2
  353. package/dist-esm/lib/ui/hooks/useExportAs.mjs +3 -2
  354. package/dist-esm/lib/ui/hooks/useExportAs.mjs.map +2 -2
  355. package/dist-esm/lib/ui/hooks/useTools.mjs +102 -10
  356. package/dist-esm/lib/ui/hooks/useTools.mjs.map +2 -2
  357. package/dist-esm/lib/ui/hooks/useTranslation/defaultTranslation.mjs +14 -1
  358. package/dist-esm/lib/ui/hooks/useTranslation/defaultTranslation.mjs.map +2 -2
  359. package/dist-esm/lib/ui/kbd-utils.mjs +9 -3
  360. package/dist-esm/lib/ui/kbd-utils.mjs.map +2 -2
  361. package/dist-esm/lib/ui/version.mjs +4 -4
  362. package/dist-esm/lib/ui/version.mjs.map +1 -1
  363. package/dist-esm/lib/utils/export/copyAs.mjs +1 -2
  364. package/dist-esm/lib/utils/export/copyAs.mjs.map +2 -2
  365. package/dist-esm/lib/utils/export/export.mjs +0 -20
  366. package/dist-esm/lib/utils/export/export.mjs.map +2 -2
  367. package/dist-esm/lib/utils/export/exportAs.mjs +1 -2
  368. package/dist-esm/lib/utils/export/exportAs.mjs.map +2 -2
  369. package/package.json +11 -34
  370. package/src/index.ts +71 -22
  371. package/src/lib/Tldraw.tsx +15 -2
  372. package/src/lib/canvas/TldrawScribble.tsx +1 -1
  373. package/src/lib/defaultExternalContentHandlers.ts +26 -4
  374. package/src/lib/shapes/arrow/ArrowShapeOptions.test.ts +85 -14
  375. package/src/lib/shapes/arrow/ArrowShapeTool.test.ts +103 -8
  376. package/src/lib/shapes/arrow/ArrowShapeUtil.test.ts +48 -6
  377. package/src/lib/shapes/arrow/ArrowShapeUtil.tsx +4 -3
  378. package/src/lib/shapes/arrow/arrow-types.ts +3 -5
  379. package/src/lib/shapes/arrow/arrowLabel.ts +8 -0
  380. package/src/lib/shapes/arrow/arrowTargetState.ts +36 -4
  381. package/src/lib/shapes/arrow/elbow/ElbowArrowDebug.tsx +3 -3
  382. package/src/lib/shapes/arrow/toolStates/Pointing.tsx +1 -1
  383. package/src/lib/shapes/bookmark/BookmarkShapeUtil.tsx +4 -5
  384. package/src/lib/shapes/draw/DrawShapeTool.test.ts +0 -5
  385. package/src/lib/shapes/draw/DrawShapeUtil.tsx +4 -3
  386. package/src/lib/shapes/embed/EmbedShapeUtil.tsx +1 -1
  387. package/src/lib/shapes/frame/FrameShapeUtil.tsx +30 -14
  388. package/src/lib/shapes/frame/components/FrameHeading.tsx +1 -1
  389. package/src/lib/shapes/frame/components/FrameLabelInput.tsx +10 -3
  390. package/src/lib/shapes/geo/GeoShapeUtil.tsx +4 -2
  391. package/src/lib/shapes/geo/components/GeoShapeBody.tsx +2 -2
  392. package/src/lib/shapes/highlight/HighlightShapeUtil.tsx +7 -1
  393. package/src/lib/shapes/image/ImageShapeUtil.tsx +6 -3
  394. package/src/lib/shapes/line/LineShapeUtil.test.tsx +4 -3
  395. package/src/lib/shapes/line/LineShapeUtil.tsx +6 -1
  396. package/src/lib/shapes/line/__snapshots__/LineShapeUtil.test.tsx.snap +2 -2
  397. package/src/lib/shapes/note/NoteShapeUtil.tsx +10 -4
  398. package/src/lib/shapes/shared/HyperlinkButton.tsx +5 -5
  399. package/src/lib/shapes/shared/PlainTextLabel.tsx +0 -6
  400. package/src/lib/shapes/shared/ShapeFill.tsx +5 -4
  401. package/src/lib/shapes/shared/freehand/svg.ts +2 -0
  402. package/src/lib/shapes/shared/useEditablePlainText.ts +3 -10
  403. package/src/lib/shapes/shared/useImageOrVideoAsset.ts +0 -7
  404. package/src/lib/shapes/shared/usePrefersReducedMotion.tsx +11 -1
  405. package/src/lib/shapes/text/PlainTextArea.tsx +4 -3
  406. package/src/lib/shapes/text/RichTextArea.tsx +3 -4
  407. package/src/lib/shapes/text/TextShapeTool.test.ts +6 -5
  408. package/src/lib/shapes/text/TextShapeUtil.tsx +3 -2
  409. package/src/lib/shapes/video/VideoShapeUtil.tsx +3 -3
  410. package/src/lib/tools/EraserTool/childStates/Erasing.ts +34 -1
  411. package/src/lib/tools/EraserTool/childStates/Pointing.ts +20 -0
  412. package/src/lib/tools/SelectTool/childStates/DraggingHandle.tsx +6 -2
  413. package/src/lib/tools/SelectTool/childStates/Translating.ts +0 -1
  414. package/src/lib/ui/TldrawUi.tsx +33 -12
  415. package/src/lib/ui/assetUrls.ts +13 -10
  416. package/src/lib/ui/components/A11y.tsx +1 -2
  417. package/src/lib/ui/components/AccessibilityMenu.tsx +20 -0
  418. package/src/lib/ui/components/ActionsMenu/DefaultActionsMenu.tsx +15 -3
  419. package/src/lib/ui/components/{FollowingIndicator.tsx → DefaultFollowingIndicator.tsx} +2 -1
  420. package/src/lib/ui/components/DefaultMenuPanel.tsx +4 -3
  421. package/src/lib/ui/components/InputModeMenu.tsx +65 -0
  422. package/src/lib/ui/components/KeyboardShortcutsDialog/DefaultKeyboardShortcutsDialogContent.tsx +6 -6
  423. package/src/lib/ui/components/LanguageMenu.tsx +1 -0
  424. package/src/lib/ui/components/MainMenu/DefaultMainMenuContent.tsx +8 -4
  425. package/src/lib/ui/components/Minimap/DefaultMinimap.tsx +2 -1
  426. package/src/lib/ui/components/Minimap/MinimapManager.ts +4 -4
  427. package/src/lib/ui/components/MobileStylePanel.tsx +9 -6
  428. package/src/lib/ui/components/NavigationPanel/DefaultNavigationPanel.tsx +1 -1
  429. package/src/lib/ui/components/PageMenu/DefaultPageMenu.tsx +4 -4
  430. package/src/lib/ui/components/SharePanel/PeopleMenuItem.tsx +4 -3
  431. package/src/lib/ui/components/SharePanel/UserPresenceColorPicker.tsx +3 -3
  432. package/src/lib/ui/components/StylePanel/DefaultStylePanel.tsx +30 -12
  433. package/src/lib/ui/components/StylePanel/DefaultStylePanelContent.tsx +263 -343
  434. package/src/lib/ui/components/{primitives/TldrawUiButtonPicker.tsx → StylePanel/StylePanelButtonPicker.tsx} +73 -50
  435. package/src/lib/ui/components/StylePanel/StylePanelContext.tsx +65 -0
  436. package/src/lib/ui/components/StylePanel/{DoubleDropdownPicker.tsx → StylePanelDoubleDropdownPicker.tsx} +31 -22
  437. package/src/lib/ui/components/StylePanel/StylePanelDropdownPicker.tsx +119 -0
  438. package/src/lib/ui/components/StylePanel/StylePanelSubheading.tsx +9 -0
  439. package/src/lib/ui/components/Toolbar/AltTextEditor.tsx +2 -0
  440. package/src/lib/ui/components/Toolbar/DefaultImageToolbarContent.tsx +33 -16
  441. package/src/lib/ui/components/Toolbar/DefaultToolbar.tsx +55 -23
  442. package/src/lib/ui/components/Toolbar/DefaultVideoToolbarContent.tsx +12 -4
  443. package/src/lib/ui/components/Toolbar/LinkEditor.tsx +1 -0
  444. package/src/lib/ui/components/Toolbar/OverflowingToolbar.tsx +212 -61
  445. package/src/lib/ui/components/Toolbar/ToggleToolLockedButton.tsx +21 -11
  446. package/src/lib/ui/components/menu-items.tsx +10 -0
  447. package/src/lib/ui/components/primitives/TldrawUiContextualToolbar.tsx +7 -3
  448. package/src/lib/ui/components/primitives/TldrawUiInput.tsx +6 -3
  449. package/src/lib/ui/components/primitives/TldrawUiPopover.tsx +4 -2
  450. package/src/lib/ui/components/primitives/TldrawUiSlider.tsx +52 -32
  451. package/src/lib/ui/components/primitives/TldrawUiToolbar.tsx +55 -12
  452. package/src/lib/ui/components/primitives/TldrawUiTooltip.tsx +386 -0
  453. package/src/lib/ui/components/primitives/layout.tsx +107 -0
  454. package/src/lib/ui/components/primitives/menus/TldrawUiMenuCheckboxItem.tsx +4 -0
  455. package/src/lib/ui/components/primitives/menus/TldrawUiMenuContext.tsx +0 -1
  456. package/src/lib/ui/components/primitives/menus/TldrawUiMenuGroup.tsx +29 -16
  457. package/src/lib/ui/components/primitives/menus/TldrawUiMenuItem.tsx +221 -19
  458. package/src/lib/ui/context/TldrawUiContextProvider.tsx +23 -20
  459. package/src/lib/ui/context/actions.tsx +51 -32
  460. package/src/lib/ui/context/components.tsx +3 -0
  461. package/src/lib/ui/context/events.tsx +4 -1
  462. package/src/lib/ui/hooks/useClipboardEvents.ts +1 -2
  463. package/src/lib/ui/hooks/useExportAs.ts +3 -2
  464. package/src/lib/ui/hooks/useTools.tsx +140 -10
  465. package/src/lib/ui/hooks/useTranslation/TLUiTranslationKey.ts +13 -0
  466. package/src/lib/ui/hooks/useTranslation/defaultTranslation.ts +14 -1
  467. package/src/lib/ui/kbd-utils.ts +10 -3
  468. package/src/lib/ui/version.ts +4 -4
  469. package/src/lib/ui.css +448 -294
  470. package/src/lib/utils/excalidraw/__snapshots__/putExcalidrawContent.test.tsx.snap +5 -5
  471. package/src/lib/utils/export/copyAs.ts +1 -24
  472. package/src/lib/utils/export/export.ts +0 -36
  473. package/src/lib/utils/export/exportAs.ts +1 -32
  474. package/src/lib/utils/tldr/__snapshots__/buildFromV1Document.test.ts.snap +4 -4
  475. package/src/test/A11y.test.tsx +3 -2
  476. package/src/test/ClickManager.test.ts +7 -6
  477. package/src/test/Editor.test.tsx +20 -19
  478. package/src/test/EraserTool.test.ts +184 -13
  479. package/src/test/HandTool.test.ts +10 -9
  480. package/src/test/HighlightShape.test.ts +2 -1
  481. package/src/test/SelectTool.test.ts +3 -2
  482. package/src/test/TLUserPreferences.test.ts +4 -3
  483. package/src/test/TestEditor.ts +21 -17
  484. package/src/test/TldrawEditor.test.tsx +11 -10
  485. package/src/test/ZoomTool.test.ts +7 -6
  486. package/src/test/__snapshots__/drawing.test.ts.snap +2 -2
  487. package/src/test/__snapshots__/groups.test.tsx.snap +6 -6
  488. package/src/test/__snapshots__/resizing.test.ts.snap +2 -2
  489. package/src/test/arrows-megabus.test.tsx +17 -10
  490. package/src/test/bindings.test.tsx +24 -37
  491. package/src/test/bookmark-shapes.test.ts +1 -8
  492. package/src/test/commands/__snapshots__/getSvgString.test.ts.snap +23 -7
  493. package/src/test/commands/__snapshots__/packShapes.test.ts.snap +8 -8
  494. package/src/test/commands/__snapshots__/zoomToFit.test.ts.snap +2 -2
  495. package/src/test/commands/alignShapes.test.tsx +25 -24
  496. package/src/test/commands/animationSpeed.test.ts +2 -1
  497. package/src/test/commands/centerOnPoint.test.ts +3 -2
  498. package/src/test/commands/clipboard.test.ts +3 -2
  499. package/src/test/commands/createShapes.test.ts +2 -1
  500. package/src/test/commands/deleteShapes.test.ts +2 -1
  501. package/src/test/commands/distributeShapes.test.tsx +11 -10
  502. package/src/test/commands/getSvgString.test.ts +2 -1
  503. package/src/test/commands/packShapes.test.ts +5 -4
  504. package/src/test/commands/resizeShape.test.ts +2 -1
  505. package/src/test/commands/rotateShapes.test.ts +7 -6
  506. package/src/test/commands/setCamera.test.ts +17 -3
  507. package/src/test/commands/setCurrentPage.test.ts +3 -2
  508. package/src/test/commands/stackShapes.test.ts +11 -10
  509. package/src/test/commands/stretch.test.tsx +13 -12
  510. package/src/test/createDeepLink.test.tsx +2 -1
  511. package/src/test/cropping.test.ts +3 -2
  512. package/src/test/custom-clipping.test.ts +436 -0
  513. package/src/test/drawing.test.ts +2 -1
  514. package/src/test/flipShapes.test.ts +4 -3
  515. package/src/test/frames.test.ts +40 -24
  516. package/src/test/getCulledShapes.test.tsx +74 -4
  517. package/src/test/groups.test.tsx +1 -1
  518. package/src/test/handleDeepLink.test.tsx +2 -1
  519. package/src/test/inner-outer-margin.test.ts +315 -0
  520. package/src/test/maxShapes.test.ts +3 -2
  521. package/src/test/modifiers.test.ts +5 -4
  522. package/src/test/navigation.test.ts +12 -11
  523. package/src/test/panning.test.ts +2 -1
  524. package/src/test/perf/perf.test.ts +2 -1
  525. package/src/test/registerDeepLinkListener.test.tsx +10 -9
  526. package/src/test/resizing.test.ts +39 -38
  527. package/src/test/select.test.tsx +4 -3
  528. package/src/test/selection-omnibus.test.ts +11 -10
  529. package/src/test/shapeutils.test.ts +4 -3
  530. package/src/test/translating.test.ts +9 -8
  531. package/tldraw.css +756 -584
  532. package/dist-cjs/lib/ui/components/FollowingIndicator.js.map +0 -7
  533. package/dist-cjs/lib/ui/components/StylePanel/DoubleDropdownPicker.js.map +0 -7
  534. package/dist-cjs/lib/ui/components/StylePanel/DropdownPicker.js.map +0 -7
  535. package/dist-cjs/lib/ui/components/primitives/TldrawUiButtonPicker.js +0 -142
  536. package/dist-cjs/lib/ui/components/primitives/TldrawUiButtonPicker.js.map +0 -7
  537. package/dist-esm/lib/ui/components/FollowingIndicator.mjs.map +0 -7
  538. package/dist-esm/lib/ui/components/StylePanel/DoubleDropdownPicker.mjs.map +0 -7
  539. package/dist-esm/lib/ui/components/StylePanel/DropdownPicker.mjs.map +0 -7
  540. package/dist-esm/lib/ui/components/primitives/TldrawUiButtonPicker.mjs +0 -115
  541. package/dist-esm/lib/ui/components/primitives/TldrawUiButtonPicker.mjs.map +0 -7
  542. package/src/lib/ui/components/StylePanel/DropdownPicker.tsx +0 -109
@@ -11,13 +11,16 @@ import { Circle2d } from '@tldraw/editor';
11
11
  import { ComponentType } from 'react';
12
12
  import { CSSProperties } from 'react';
13
13
  import { Editor } from '@tldraw/editor';
14
+ import { ElbowArrowSnap } from '@tldraw/editor';
14
15
  import { Extension } from '@tiptap/core';
15
16
  import { Extensions } from '@tiptap/core';
17
+ import { ForwardRefExoticComponent } from 'react';
16
18
  import { Geometry2d } from '@tldraw/editor';
17
19
  import { Geometry2dFilters } from '@tldraw/editor';
18
20
  import { Geometry2dOptions } from '@tldraw/editor';
19
21
  import { Group2d } from '@tldraw/editor';
20
22
  import { HandleSnapGeometry } from '@tldraw/editor';
23
+ import { HTMLAttributes } from 'react';
21
24
  import { IndexKey } from '@tldraw/editor';
22
25
  import { JsonObject } from '@tldraw/editor';
23
26
  import { JSX as JSX_2 } from 'react/jsx-runtime';
@@ -37,6 +40,7 @@ import { ReadonlySharedStyleMap } from '@tldraw/editor';
37
40
  import { RecordProps } from '@tldraw/editor';
38
41
  import { Rectangle2d } from '@tldraw/editor';
39
42
  import { RecursivePartial } from '@tldraw/editor';
43
+ import { RefAttributes } from 'react';
40
44
  import { RefObject } from 'react';
41
45
  import { Result } from '@tldraw/editor';
42
46
  import { RichTextFontVisitorState } from '@tldraw/editor';
@@ -55,6 +59,7 @@ import { TLArrowBinding } from '@tldraw/editor';
55
59
  import { TLArrowBindingProps } from '@tldraw/editor';
56
60
  import { TLArrowShape } from '@tldraw/editor';
57
61
  import { TLArrowShapeArrowheadStyle } from '@tldraw/editor';
62
+ import { TLArrowShapeKind } from '@tldraw/editor';
58
63
  import { TLArrowShapeProps } from '@tldraw/editor';
59
64
  import { TLAsset } from '@tldraw/editor';
60
65
  import { TLAssetId } from '@tldraw/editor';
@@ -65,7 +70,6 @@ import { TLClickEventInfo } from '@tldraw/editor';
65
70
  import { TLContent } from '@tldraw/editor';
66
71
  import { TLCropInfo } from '@tldraw/editor';
67
72
  import { TLDefaultColorStyle } from '@tldraw/editor';
68
- import { TLDefaultColorTheme } from '@tldraw/editor';
69
73
  import { TLDefaultColorThemeColor } from '@tldraw/editor';
70
74
  import { TLDefaultDashStyle } from '@tldraw/editor';
71
75
  import { TLDefaultFillStyle } from '@tldraw/editor';
@@ -148,6 +152,9 @@ export declare interface A11yProviderProps {
148
152
  children: React.ReactNode;
149
153
  }
150
154
 
155
+ /** @public @react */
156
+ export declare function AccessibilityMenu(): JSX_2.Element;
157
+
151
158
  /** @public */
152
159
  export declare interface ActionsProviderProps {
153
160
  overrides?(editor: Editor, actions: TLUiActionsContextType, helpers: TLUiOverrideHelpers): TLUiActionsContextType;
@@ -187,9 +194,6 @@ export declare class ArrowBindingUtil extends BindingUtil<TLArrowBinding> {
187
194
  /** @public @react */
188
195
  export declare function ArrowDownToolbarItem(): JSX_2.Element;
189
196
 
190
- /** @public @react */
191
- export declare function ArrowheadStylePickerSet({ styles }: StylePickerSetProps): JSX_2.Element | null;
192
-
193
197
  /** @public @react */
194
198
  export declare function ArrowLeftToolbarItem(): JSX_2.Element;
195
199
 
@@ -272,7 +276,7 @@ export declare interface ArrowShapeOptions {
272
276
  */
273
277
  readonly hoverPreciseTimeout: number;
274
278
  /**
275
- * When pointing at a shape using the arrow tool or draggin an arrow terminal handle, how long
279
+ * When pointing at a shape using the arrow tool or dragging an arrow terminal handle, how long
276
280
  * should we wait before we assume the user is targeting precisely instead of imprecisely.
277
281
  */
278
282
  readonly pointingPreciseTimeout: number;
@@ -280,11 +284,11 @@ export declare interface ArrowShapeOptions {
280
284
  * When creating an arrow, should it stop exactly at the pointer, or should
281
285
  * it stop at the edge of the target shape.
282
286
  */
283
- readonly shouldBeExact: (editor: Editor) => boolean;
287
+ shouldBeExact(editor: Editor, isPrecise: boolean): boolean;
284
288
  /**
285
289
  * When creating an arrow, should it bind to the target shape.
286
290
  */
287
- readonly shouldIgnoreTargets: (editor: Editor) => boolean;
291
+ shouldIgnoreTargets(editor: Editor): boolean;
288
292
  }
289
293
 
290
294
  /** @public */
@@ -359,6 +363,42 @@ export declare class ArrowShapeUtil extends ShapeUtil<TLArrowShape> {
359
363
  getInterpolatedProps(startShape: TLArrowShape, endShape: TLArrowShape, progress: number): TLArrowShapeProps;
360
364
  }
361
365
 
366
+ /**
367
+ * State representing what we're pointing to when drawing or updating an arrow. You can get this
368
+ * state using {@link getArrowTargetState}, and update it as part of an arrow interaction with
369
+ * {@link updateArrowTargetState} or {@link clearArrowTargetState}.
370
+ *
371
+ * @public
372
+ */
373
+ export declare interface ArrowTargetState {
374
+ target: TLShape;
375
+ arrowKind: TLArrowShapeKind;
376
+ handlesInPageSpace: {
377
+ bottom: {
378
+ isEnabled: boolean;
379
+ point: VecLike;
380
+ };
381
+ left: {
382
+ isEnabled: boolean;
383
+ point: VecLike;
384
+ };
385
+ right: {
386
+ isEnabled: boolean;
387
+ point: VecLike;
388
+ };
389
+ top: {
390
+ isEnabled: boolean;
391
+ point: VecLike;
392
+ };
393
+ };
394
+ isExact: boolean;
395
+ isPrecise: boolean;
396
+ centerInPageSpace: VecLike;
397
+ anchorInPageSpace: VecLike;
398
+ snap: ElbowArrowSnap;
399
+ normalizedAnchor: VecLike;
400
+ }
401
+
362
402
  /** @public @react */
363
403
  export declare function ArrowToolbarItem(): JSX_2.Element;
364
404
 
@@ -485,6 +525,14 @@ export declare function centerSelectionAroundPoint(editor: Editor, position: Vec
485
525
  /** @public @react */
486
526
  export declare function CheckBoxToolbarItem(): JSX_2.Element;
487
527
 
528
+ /**
529
+ * Clear the current arrow target state for an editor. See {@link ArrowTargetState} for more
530
+ * information.
531
+ *
532
+ * @public
533
+ */
534
+ export declare function clearArrowTargetState(editor: Editor): void;
535
+
488
536
  /** @public @react */
489
537
  export declare function ClipboardMenuGroup(): JSX_2.Element;
490
538
 
@@ -494,9 +542,6 @@ export declare function CloudToolbarItem(): JSX_2.Element;
494
542
  /** @public @react */
495
543
  export declare function ColorSchemeMenu(): JSX_2.Element;
496
544
 
497
- /** @public @react */
498
- export declare function CommonStylePickerSet({ styles, theme }: ThemeStylePickerSetProps): JSX_2.Element;
499
-
500
545
  /**
501
546
  * Contains the size within the given box size
502
547
  *
@@ -528,14 +573,6 @@ export declare function ConvertToEmbedMenuItem(): JSX_2.Element | null;
528
573
  */
529
574
  export declare function copyAs(editor: Editor, ids: TLShapeId[], opts: CopyAsOptions): Promise<void>;
530
575
 
531
- /**
532
- * @deprecated The format parameter is now part of the opts object.
533
- * @public
534
- */
535
- export declare function copyAs(editor: Editor, ids: TLShapeId[], format: TLCopyType, opts?: TLImageExportOptions & {
536
- format?: undefined;
537
- }): Promise<void>;
538
-
539
576
  /** @public @react */
540
577
  export declare function CopyAsMenuGroup(): JSX_2.Element;
541
578
 
@@ -847,6 +884,9 @@ export declare let defaultEditorAssetUrls: TLEditorAssetUrls;
847
884
  /** @public */
848
885
  export declare type DefaultEmbedDefinitionType = (typeof DEFAULT_EMBED_DEFINITIONS)[number]['type'];
849
886
 
887
+ /** @public @react */
888
+ export declare function DefaultFollowingIndicator(): JSX_2.Element | null;
889
+
850
890
  /** @public */
851
891
  export declare const DefaultFontFaces: TLDefaultFonts;
852
892
 
@@ -990,7 +1030,7 @@ export declare function DefaultSharePanel(): JSX_2.Element;
990
1030
  export declare const DefaultStylePanel: NamedExoticComponent<TLUiStylePanelProps>;
991
1031
 
992
1032
  /** @public @react */
993
- export declare function DefaultStylePanelContent({ styles }: TLUiStylePanelContentProps): JSX_2.Element | null;
1033
+ export declare function DefaultStylePanelContent(): JSX_2.Element;
994
1034
 
995
1035
  /** @public @react */
996
1036
  export declare const DefaultToasts: NamedExoticComponent<object>;
@@ -1011,6 +1051,11 @@ export declare function DefaultToolbarContent(): JSX_2.Element;
1011
1051
  /** @public */
1012
1052
  export declare interface DefaultToolbarProps {
1013
1053
  children?: ReactNode;
1054
+ orientation?: 'horizontal' | 'vertical';
1055
+ minItems?: number;
1056
+ minSizePx?: number;
1057
+ maxItems?: number;
1058
+ maxSizePx?: number;
1014
1059
  }
1015
1060
 
1016
1061
  /** @public */
@@ -1478,12 +1523,6 @@ export declare interface ExampleDialogProps {
1478
1523
  */
1479
1524
  export declare function exportAs(editor: Editor, ids: TLShapeId[], opts: ExportAsOptions): Promise<void>;
1480
1525
 
1481
- /**
1482
- * @deprecated The format & name parameters are now part of the opts object.
1483
- * @public
1484
- */
1485
- export declare function exportAs(editor: Editor, ids: TLShapeId[], format?: TLExportType, name?: string, opts?: TLImageExportOptions): Promise<void>;
1486
-
1487
1526
  /** @public */
1488
1527
  export declare interface ExportAsOptions extends TLImageExportOptions {
1489
1528
  /** {@inheritdoc @tldraw/editor#TLImageExportOptions.format} */
@@ -1495,23 +1534,6 @@ export declare interface ExportAsOptions extends TLImageExportOptions {
1495
1534
  /** @public @react */
1496
1535
  export declare function ExportFileContentSubMenu(): JSX_2.Element;
1497
1536
 
1498
- /**
1499
- * Export the given shapes as a blob.
1500
- * @param editor - The editor instance.
1501
- * @param ids - The ids of the shapes to export.
1502
- * @param format - The format to export as.
1503
- * @param opts - Rendering options.
1504
- * @returns A promise that resolves to a blob.
1505
- * @deprecated Use {@link @tldraw/editor#Editor.toImage} instead.
1506
- * @public
1507
- */
1508
- export declare function exportToBlob({ editor, ids, format, opts, }: {
1509
- editor: Editor;
1510
- format: TLExportType;
1511
- ids: TLShapeId[];
1512
- opts?: TLImageExportOptions;
1513
- }): Promise<Blob>;
1514
-
1515
1537
  /** @public @react */
1516
1538
  export declare function ExtrasGroup(): JSX_2.Element;
1517
1539
 
@@ -1568,6 +1590,7 @@ export declare class FrameShapeUtil extends BaseBoxShapeUtil<TLFrameShape> {
1568
1590
  canEdit(): boolean;
1569
1591
  canResize(): boolean;
1570
1592
  canResizeChildren(): boolean;
1593
+ isExportBoundsContainer(): boolean;
1571
1594
  getDefaultProps(): TLFrameShape['props'];
1572
1595
  getAriaDescriptor(shape: TLFrameShape): string;
1573
1596
  getGeometry(shape: TLFrameShape): Geometry2d;
@@ -1576,6 +1599,7 @@ export declare class FrameShapeUtil extends BaseBoxShapeUtil<TLFrameShape> {
1576
1599
  toSvg(shape: TLFrameShape, ctx: SvgExportContext): JSX_2.Element;
1577
1600
  indicator(shape: TLFrameShape): JSX_2.Element;
1578
1601
  providesBackgroundForChildren(): boolean;
1602
+ getClipPath(shape: TLFrameShape): Vec[];
1579
1603
  canReceiveNewChildrenOfType(shape: TLShape): boolean;
1580
1604
  onResize(shape: any, info: TLResizeInfo<any>): any;
1581
1605
  getInterpolatedProps(startShape: TLFrameShape, endShape: TLFrameShape, t: number): TLFrameShapeProps;
@@ -1724,15 +1748,20 @@ export declare class GeoShapeUtil extends BaseBoxShapeUtil<TLGeoShape> {
1724
1748
  getInterpolatedProps(startShape: TLGeoShape, endShape: TLGeoShape, t: number): TLGeoShapeProps;
1725
1749
  }
1726
1750
 
1727
- /** @public @react */
1728
- export declare function GeoStylePickerSet({ styles }: StylePickerSetProps): JSX_2.Element | null;
1729
-
1730
1751
  /** @public */
1731
1752
  export declare function getArrowBindings(editor: Editor, shape: TLArrowShape): TLArrowBindings;
1732
1753
 
1733
1754
  /** @public */
1734
1755
  export declare function getArrowInfo(editor: Editor, shape: TLArrowShape | TLShapeId): TLArrowInfo | undefined;
1735
1756
 
1757
+ /**
1758
+ * Get the current arrow target state for an editor. See {@link ArrowTargetState} for more
1759
+ * information.
1760
+ *
1761
+ * @public
1762
+ */
1763
+ export declare function getArrowTargetState(editor: Editor): ArrowTargetState | null;
1764
+
1736
1765
  /** @public */
1737
1766
  export declare function getArrowTerminalsInArrowSpace(editor: Editor, shape: TLArrowShape, bindings: TLArrowBindings): {
1738
1767
  end: Vec;
@@ -1769,6 +1798,29 @@ export declare function getHitShapeOnCanvasPointerDown(editor: Editor, hitLabels
1769
1798
  /** @public */
1770
1799
  export declare function getMediaAssetInfoPartial(file: File, assetId: TLAssetId, isImageType: boolean, isVideoType: boolean, maxImageDimension?: number): Promise<TLImageAsset | TLVideoAsset>;
1771
1800
 
1801
+ /**
1802
+ * ## getStrokePoints
1803
+ *
1804
+ * Get an array of points as objects with an adjusted point, pressure, vector, distance, and
1805
+ * runningLength.
1806
+ *
1807
+ * @param points - An array of points (as `[x, y, pressure]` or `{x, y, pressure}`). Pressure is
1808
+ * optional in both cases.
1809
+ * @param options - An object with options.
1810
+ * @public
1811
+ */
1812
+ export declare function getStrokePoints(rawInputPoints: VecLike[], options?: StrokeOptions): StrokePoint[];
1813
+
1814
+ /**
1815
+ * Turn an array of stroke points into a path of quadradic curves.
1816
+ *
1817
+ * @param points - The stroke points returned from perfect-freehand
1818
+ * @param closed - Whether the shape is closed
1819
+ *
1820
+ * @public
1821
+ */
1822
+ export declare function getSvgPathFromStrokePoints(points: StrokePoint[], closed?: boolean): string;
1823
+
1772
1824
  /**
1773
1825
  * Original (uncropped) width and height of shape.
1774
1826
  *
@@ -1864,6 +1916,7 @@ export declare class ImageShapeUtil extends BaseBoxShapeUtil<TLImageShape> {
1864
1916
  static migrations: TLPropsMigrations;
1865
1917
  isAspectRatioLocked(): boolean;
1866
1918
  canCrop(): boolean;
1919
+ isExportBoundsContainer(): boolean;
1867
1920
  getDefaultProps(): TLImageShape['props'];
1868
1921
  getGeometry(shape: TLImageShape): Geometry2d;
1869
1922
  getAriaDescriptor(shape: TLImageShape): string;
@@ -2114,21 +2167,57 @@ export declare class NoteShapeUtil extends ShapeUtil<TLNoteShape> {
2114
2167
  /** @public @react */
2115
2168
  export declare function NoteToolbarItem(): JSX_2.Element;
2116
2169
 
2170
+ /**
2171
+ * Checks if a file is allowed to be uploaded. If it is not, it will show a toast explaining why to the user.
2172
+ *
2173
+ * @param file - The file to check
2174
+ * @param options - The options for the external content handler
2175
+ * @returns True if the file is allowed, false otherwise
2176
+ * @public
2177
+ */
2178
+ export declare function notifyIfFileNotAllowed(file: File, options: TLDefaultExternalContentHandlerOpts): boolean;
2179
+
2117
2180
  /** @public @react */
2118
2181
  export declare function OfflineIndicator(): JSX_2.Element;
2119
2182
 
2120
- /** @public @react */
2121
- export declare function OpacitySlider(): JSX_2.Element | null;
2183
+ /**
2184
+ * A helper method to use in {@link TLUiToolItem#onDragStart} to create a shape by dragging it from
2185
+ * the toolbar.
2186
+ * @public
2187
+ */
2188
+ export declare function onDragFromToolbarToCreateShape(editor: Editor, info: TLPointerEventInfo, opts: OnDragFromToolbarToCreateShapesOpts): void;
2189
+
2190
+ /**
2191
+ * Options for {@link onDragFromToolbarToCreateShape}.
2192
+ * @public
2193
+ */
2194
+ export declare interface OnDragFromToolbarToCreateShapesOpts {
2195
+ /**
2196
+ * Create the shape being dragged. You don't need to worry about positioning it, as it'll be
2197
+ * immediately updated with the correct position.
2198
+ */
2199
+ createShape(id: TLShapeId): void;
2200
+ /**
2201
+ * Called once the drag interaction has finished.
2202
+ */
2203
+ onDragEnd?(id: TLShapeId): void;
2204
+ }
2122
2205
 
2123
2206
  /** @public @react */
2124
2207
  export declare function OvalToolbarItem(): JSX_2.Element;
2125
2208
 
2126
2209
  /** @public @react */
2127
- export declare function OverflowingToolbar({ children }: OverflowingToolbarProps): JSX_2.Element;
2210
+ export declare function OverflowingToolbar({ children, orientation, sizingParentClassName, minItems, minSizePx, maxItems, maxSizePx, }: OverflowingToolbarProps): JSX_2.Element;
2128
2211
 
2129
2212
  /** @public */
2130
2213
  export declare interface OverflowingToolbarProps {
2131
2214
  children: React.ReactNode;
2215
+ orientation: 'horizontal' | 'vertical';
2216
+ sizingParentClassName: string;
2217
+ minItems: number;
2218
+ minSizePx: number;
2219
+ maxItems: number;
2220
+ maxSizePx: number;
2132
2221
  }
2133
2222
 
2134
2223
  /** @public @react */
@@ -2505,9 +2594,6 @@ export declare interface SolidPathBuilderOpts extends BasePathBuilderOpts {
2505
2594
 
2506
2595
  /* Excluded from this release type: Spinner */
2507
2596
 
2508
- /** @public @react */
2509
- export declare function SplineStylePickerSet({ styles }: StylePickerSetProps): JSX_2.Element | null;
2510
-
2511
2597
  /** @public @react */
2512
2598
  export declare function StackMenuItems(): JSX_2.Element;
2513
2599
 
@@ -2517,11 +2603,172 @@ export declare function StarToolbarItem(): JSX_2.Element;
2517
2603
  /** @public */
2518
2604
  export declare const STROKE_SIZES: Record<TLDefaultSizeStyle, number>;
2519
2605
 
2606
+ /**
2607
+ * The options object for `getStroke` or `getStrokePoints`.
2608
+ *
2609
+ * @public
2610
+ */
2611
+ export declare interface StrokeOptions {
2612
+ /** The base size (diameter) of the stroke. */
2613
+ size?: number;
2614
+ /** The effect of pressure on the stroke's size. */
2615
+ thinning?: number;
2616
+ /** How much to soften the stroke's edges. */
2617
+ smoothing?: number;
2618
+ streamline?: number;
2619
+ /** An easing function to apply to each point's pressure. */
2620
+ easing?(pressure: number): number;
2621
+ /** Whether to simulate pressure based on velocity. */
2622
+ simulatePressure?: boolean;
2623
+ /** Cap, taper and easing for the start of the line. */
2624
+ start?: {
2625
+ cap?: boolean;
2626
+ easing?(distance: number): number;
2627
+ taper?: boolean | number;
2628
+ };
2629
+ /** Cap, taper and easing for the end of the line. */
2630
+ end?: {
2631
+ cap?: boolean;
2632
+ easing?(distance: number): number;
2633
+ taper?: boolean | number;
2634
+ };
2635
+ /** Whether to handle the points as a completed stroke. */
2636
+ last?: boolean;
2637
+ }
2638
+
2639
+ /**
2640
+ * The points returned by `getStrokePoints`, and the input for `getStrokeOutlinePoints`
2641
+ *
2642
+ * @public
2643
+ */
2644
+ export declare interface StrokePoint {
2645
+ point: Vec;
2646
+ input: Vec;
2647
+ vector: Vec;
2648
+ pressure: number;
2649
+ distance: number;
2650
+ runningLength: number;
2651
+ radius: number;
2652
+ }
2653
+
2654
+ /** @public @react */
2655
+ export declare function StylePanelArrowheadPicker(): JSX_2.Element | null;
2656
+
2657
+ /** @public @react */
2658
+ export declare function StylePanelArrowKindPicker(): JSX_2.Element | null;
2659
+
2660
+ /** @public */
2661
+ export declare const StylePanelButtonPicker: <T extends string>(props: StylePanelButtonPickerProps<T>) => ReactElement;
2662
+
2520
2663
  /** @public */
2521
- export declare interface StylePickerSetProps {
2664
+ export declare interface StylePanelButtonPickerProps<T extends string> {
2665
+ title: string;
2666
+ uiType: string;
2667
+ style: StyleProp<T>;
2668
+ value: SharedStyle<T>;
2669
+ items: StyleValuesForUi<T>;
2670
+ onValueChange?(style: StyleProp<T>, value: T): void;
2671
+ onHistoryMark?(id: string): void;
2672
+ }
2673
+
2674
+ /** @public @react */
2675
+ export declare function StylePanelColorPicker(): JSX_2.Element | null;
2676
+
2677
+ /** @public */
2678
+ export declare interface StylePanelContext {
2679
+ styles: ReadonlySharedStyleMap;
2680
+ enhancedA11yMode: boolean;
2681
+ onHistoryMark(id: string): void;
2682
+ onValueChange<T>(style: StyleProp<T>, value: T): void;
2683
+ }
2684
+
2685
+ /** @public @react */
2686
+ export declare function StylePanelContextProvider({ children, styles }: StylePanelContextProviderProps): JSX_2.Element;
2687
+
2688
+ /** @public */
2689
+ export declare interface StylePanelContextProviderProps {
2690
+ children: React.ReactNode;
2522
2691
  styles: ReadonlySharedStyleMap;
2523
2692
  }
2524
2693
 
2694
+ /** @public @react */
2695
+ export declare function StylePanelDashPicker(): JSX_2.Element | null;
2696
+
2697
+ /** @public @react */
2698
+ export declare const StylePanelDoubleDropdownPicker: <T extends string>(props: StylePanelDoubleDropdownPickerProps<T>) => React_2.JSX.Element;
2699
+
2700
+ /** @public */
2701
+ export declare interface StylePanelDoubleDropdownPickerProps<T extends string> {
2702
+ uiTypeA: string;
2703
+ uiTypeB: string;
2704
+ label: Exclude<string, TLUiTranslationKey> | TLUiTranslationKey;
2705
+ labelA: Exclude<string, TLUiTranslationKey> | TLUiTranslationKey;
2706
+ labelB: Exclude<string, TLUiTranslationKey> | TLUiTranslationKey;
2707
+ itemsA: StyleValuesForUi<T>;
2708
+ itemsB: StyleValuesForUi<T>;
2709
+ styleA: StyleProp<T>;
2710
+ styleB: StyleProp<T>;
2711
+ valueA: SharedStyle<T>;
2712
+ valueB: SharedStyle<T>;
2713
+ onValueChange?(style: StyleProp<T>, value: T): void;
2714
+ }
2715
+
2716
+ /** @public @react */
2717
+ export declare const StylePanelDropdownPicker: <T extends string>(props: StylePanelDropdownPickerProps<T>) => React_2.JSX.Element;
2718
+
2719
+ /** @public */
2720
+ export declare interface StylePanelDropdownPickerProps<T extends string> {
2721
+ id: string;
2722
+ label?: Exclude<string, TLUiTranslationKey> | TLUiTranslationKey;
2723
+ uiType: string;
2724
+ stylePanelType: string;
2725
+ style: StyleProp<T>;
2726
+ value: SharedStyle<T>;
2727
+ items: StyleValuesForUi<T>;
2728
+ type: 'icon' | 'menu' | 'tool';
2729
+ onValueChange?(style: StyleProp<T>, value: T): void;
2730
+ }
2731
+
2732
+ /** @public @react */
2733
+ export declare function StylePanelFillPicker(): JSX_2.Element | null;
2734
+
2735
+ /** @public @react */
2736
+ export declare function StylePanelFontPicker(): JSX_2.Element | null;
2737
+
2738
+ /** @public @react */
2739
+ export declare function StylePanelGeoShapePicker(): JSX_2.Element | null;
2740
+
2741
+ /** @public @react */
2742
+ export declare function StylePanelLabelAlignPicker(): JSX_2.Element | null;
2743
+
2744
+ /** @public @react */
2745
+ export declare function StylePanelOpacityPicker(): JSX_2.Element | null;
2746
+
2747
+ /** @public @react */
2748
+ export declare function StylePanelSection({ children }: StylePanelSectionProps): JSX_2.Element;
2749
+
2750
+ /** @public */
2751
+ export declare interface StylePanelSectionProps {
2752
+ children: React_3.ReactNode;
2753
+ }
2754
+
2755
+ /** @public @react */
2756
+ export declare function StylePanelSizePicker(): JSX_2.Element | null;
2757
+
2758
+ /** @public @react */
2759
+ export declare function StylePanelSplinePicker(): JSX_2.Element | null;
2760
+
2761
+ /** @public @react */
2762
+ export declare function StylePanelSubheading({ children }: StylePanelSubheadingProps): JSX_2.Element;
2763
+
2764
+ /** @public */
2765
+ export declare interface StylePanelSubheadingProps {
2766
+ children: React.ReactNode;
2767
+ }
2768
+
2769
+ /** @public @react */
2770
+ export declare function StylePanelTextAlignPicker(): JSX_2.Element | null;
2771
+
2525
2772
  /** @public */
2526
2773
  export declare type StyleValuesForUi<T> = readonly {
2527
2774
  readonly icon: string | TLUiIconJsx;
@@ -2561,12 +2808,6 @@ export declare interface TextAreaProps {
2561
2808
  */
2562
2809
  export declare const TextDirection: Extension<any, any>;
2563
2810
 
2564
- /**
2565
- * @deprecated Use `PlainTextLabel` instead.
2566
- * @public
2567
- */
2568
- export declare const TextLabel: React_3.NamedExoticComponent<PlainTextLabelProps>;
2569
-
2570
2811
  /** @public */
2571
2812
  export declare interface TextShapeOptions {
2572
2813
  /** How much addition padding should be added to the horizontal geometry of the shape when binding to an arrow? */
@@ -2644,18 +2885,9 @@ export declare class TextShapeUtil extends ShapeUtil<TLTextShape> {
2644
2885
  } | undefined;
2645
2886
  }
2646
2887
 
2647
- /** @public @react */
2648
- export declare function TextStylePickerSet({ theme, styles }: ThemeStylePickerSetProps): JSX_2.Element | null;
2649
-
2650
2888
  /** @public @react */
2651
2889
  export declare function TextToolbarItem(): JSX_2.Element;
2652
2890
 
2653
- /** @public */
2654
- export declare interface ThemeStylePickerSetProps {
2655
- styles: ReadonlySharedStyleMap;
2656
- theme: TLDefaultColorTheme;
2657
- }
2658
-
2659
2891
  /**
2660
2892
  * Default extensions for the TipTap editor.
2661
2893
  *
@@ -2912,8 +3144,12 @@ export declare function TldrawUiButtonIcon({ icon, small, invertIcon }: TLUiButt
2912
3144
  /** @public @react */
2913
3145
  export declare function TldrawUiButtonLabel({ children }: TLUiButtonLabelProps): JSX_2.Element;
2914
3146
 
2915
- /** @public */
2916
- export declare const TldrawUiButtonPicker: <T extends string>(props: TLUiButtonPickerProps<T>) => ReactElement;
3147
+ /**
3148
+ * A column, usually of UI controls like buttons, select dropdown, checkboxes, etc.
3149
+ *
3150
+ * @public @react
3151
+ */
3152
+ export declare const TldrawUiColumn: ForwardRefExoticComponent<TLUiLayoutProps & RefAttributes<HTMLDivElement>>;
2917
3153
 
2918
3154
  /** @public @react */
2919
3155
  export declare function TldrawUiComponentsProvider({ overrides, children, }: TLUiComponentsProviderProps): JSX_2.Element;
@@ -2977,9 +3213,19 @@ export declare function TldrawUiDropdownMenuTrigger({ children, ...rest }: TLUiD
2977
3213
  /** @public @react */
2978
3214
  export declare function TldrawUiEventsProvider({ onEvent, children }: EventsProviderProps): JSX_2.Element;
2979
3215
 
3216
+ /**
3217
+ * A tight grid 4 elements wide, usually of UI controls like buttons, select dropdown, checkboxes,
3218
+ * etc.
3219
+ *
3220
+ * @public @react */
3221
+ export declare const TldrawUiGrid: ForwardRefExoticComponent<TLUiLayoutProps & RefAttributes<HTMLDivElement>>;
3222
+
2980
3223
  /** @public @react */
2981
3224
  export declare const TldrawUiIcon: NamedExoticComponent<TLUiIconProps>;
2982
3225
 
3226
+ /** @public @react */
3227
+ export declare function TldrawUiInFrontOfTheCanvas(): JSX_2.Element;
3228
+
2983
3229
  /** @public @react */
2984
3230
  export declare const TldrawUiInput: React_2.ForwardRefExoticComponent<TLUiInputProps & React_2.RefAttributes<HTMLInputElement>>;
2985
3231
 
@@ -2993,7 +3239,7 @@ export declare function TldrawUiMenuActionCheckboxItem({ actionId, ...rest }: TL
2993
3239
  export declare function TldrawUiMenuActionItem({ actionId, ...rest }: TLUiMenuActionItemProps): JSX_2.Element | null;
2994
3240
 
2995
3241
  /** @public @react */
2996
- export declare function TldrawUiMenuCheckboxItem<TranslationKey extends string = string, IconType extends string = string>({ id, kbd, label, readonlyOk, onSelect, toggle, disabled, checked, }: TLUiMenuCheckboxItemProps<TranslationKey, IconType>): JSX_2.Element | null;
3242
+ export declare function TldrawUiMenuCheckboxItem<TranslationKey extends string = string, IconType extends string = string>({ id, kbd, label, lang, readonlyOk, onSelect, toggle, disabled, checked, }: TLUiMenuCheckboxItemProps<TranslationKey, IconType>): JSX_2.Element | null;
2997
3243
 
2998
3244
  /** @public @react */
2999
3245
  export declare function TldrawUiMenuContextProvider({ type, sourceId, children, }: TLUiMenuContextProviderProps): JSX_2.Element;
@@ -3002,7 +3248,7 @@ export declare function TldrawUiMenuContextProvider({ type, sourceId, children,
3002
3248
  export declare function TldrawUiMenuGroup({ id, label, className, children }: TLUiMenuGroupProps): boolean | JSX_2.Element | Iterable<ReactNode> | null | number | string | undefined;
3003
3249
 
3004
3250
  /** @public @react */
3005
- export declare function TldrawUiMenuItem<TranslationKey extends string = string, IconType extends string = string>({ disabled, spinner, readonlyOk, id, kbd, label, icon, iconLeft, onSelect, noClose, isSelected, }: TLUiMenuItemProps<TranslationKey, IconType>): JSX_2.Element | null;
3251
+ export declare function TldrawUiMenuItem<TranslationKey extends string = string, IconType extends string = string>({ disabled, spinner, readonlyOk, id, kbd, label, icon, iconLeft, onSelect, noClose, isSelected, onDragStart, }: TLUiMenuItemProps<TranslationKey, IconType>): JSX_2.Element | null;
3006
3252
 
3007
3253
  /** @public @react */
3008
3254
  export declare function TldrawUiMenuSubmenu<Translation extends string = string>({ id, disabled, label, size, children, }: TLUiMenuSubmenuProps<Translation>): boolean | JSX_2.Element | Iterable<ReactNode> | null | number | string | undefined;
@@ -3010,8 +3256,24 @@ export declare function TldrawUiMenuSubmenu<Translation extends string = string>
3010
3256
  /** @public @react */
3011
3257
  export declare function TldrawUiMenuToolItem({ toolId, ...rest }: TLUiMenuToolItemProps): JSX_2.Element | null;
3012
3258
 
3259
+ /** @public */
3260
+ export declare interface TldrawUiOrientationContext {
3261
+ orientation: 'horizontal' | 'vertical';
3262
+ tooltipSide: 'bottom' | 'left' | 'right' | 'top';
3263
+ }
3264
+
3265
+ /** @public @react */
3266
+ export declare function TldrawUiOrientationProvider({ children, orientation, tooltipSide, }: TldrawUiOrientationProviderProps): JSX_2.Element;
3267
+
3268
+ /** @public */
3269
+ export declare interface TldrawUiOrientationProviderProps {
3270
+ children: ReactNode;
3271
+ orientation: 'horizontal' | 'vertical';
3272
+ tooltipSide?: 'bottom' | 'left' | 'right' | 'top';
3273
+ }
3274
+
3013
3275
  /** @public @react */
3014
- export declare function TldrawUiPopover({ id, children, onOpenChange, open }: TLUiPopoverProps): JSX_2.Element;
3276
+ export declare function TldrawUiPopover({ id, children, onOpenChange, open, className }: TLUiPopoverProps): JSX_2.Element;
3015
3277
 
3016
3278
  /** @public @react */
3017
3279
  export declare function TldrawUiPopoverContent({ side, children, align, sideOffset, alignOffset, disableEscapeKeyDown, autoFocusFirstButton, }: TLUiPopoverContentProps): JSX_2.Element;
@@ -3041,6 +3303,13 @@ export declare interface TldrawUiProps extends TLUiContextProviderProps {
3041
3303
  assetUrls?: TLUiAssetUrlOverrides;
3042
3304
  }
3043
3305
 
3306
+ /**
3307
+ * A row, usually of UI controls like buttons, select dropdown, checkboxes, etc.
3308
+ *
3309
+ * @public @react
3310
+ */
3311
+ export declare const TldrawUiRow: ForwardRefExoticComponent<TLUiLayoutProps & RefAttributes<HTMLDivElement>>;
3312
+
3044
3313
  /** @public @react */
3045
3314
  export declare const TldrawUiSlider: React_3.ForwardRefExoticComponent<TLUiSliderProps & React_3.RefAttributes<HTMLDivElement>>;
3046
3315
 
@@ -3054,10 +3323,32 @@ export declare const TldrawUiToolbar: React_3.ForwardRefExoticComponent<TLUiTool
3054
3323
  export declare const TldrawUiToolbarButton: React_3.ForwardRefExoticComponent<TLUiToolbarButtonProps & React_3.RefAttributes<HTMLButtonElement>>;
3055
3324
 
3056
3325
  /** @public @react */
3057
- export declare const TldrawUiToolbarToggleGroup: ({ children, className, type, ...props }: TLUiToolbarToggleGroupProps) => JSX_2.Element;
3326
+ export declare const TldrawUiToolbarToggleGroup: ({ children, className, type, asChild, ...props }: TLUiToolbarToggleGroupProps) => JSX_2.Element;
3327
+
3328
+ /** @public @react */
3329
+ export declare const TldrawUiToolbarToggleItem: ({ children, className, type, value, tooltip, ...props }: TLUiToolbarToggleItemProps) => JSX_2.Element;
3058
3330
 
3059
3331
  /** @public @react */
3060
- export declare const TldrawUiToolbarToggleItem: ({ children, className, type, value, ...props }: TLUiToolbarToggleItemProps) => JSX_2.Element;
3332
+ export declare const TldrawUiTooltip: React_3.ForwardRefExoticComponent<TldrawUiTooltipProps & React_3.RefAttributes<HTMLButtonElement>>;
3333
+
3334
+ /** @public */
3335
+ export declare interface TldrawUiTooltipProps {
3336
+ children: React_3.ReactNode;
3337
+ content?: React_3.ReactNode | string;
3338
+ side?: 'bottom' | 'left' | 'right' | 'top';
3339
+ sideOffset?: number;
3340
+ disabled?: boolean;
3341
+ showOnMobile?: boolean;
3342
+ delayDuration?: number;
3343
+ }
3344
+
3345
+ /** @public @react */
3346
+ export declare function TldrawUiTooltipProvider({ children }: TldrawUiTooltipProviderProps): JSX_2.Element;
3347
+
3348
+ /** @public */
3349
+ export declare interface TldrawUiTooltipProviderProps {
3350
+ children: React_3.ReactNode;
3351
+ }
3061
3352
 
3062
3353
  /* Excluded from this release type: TldrawUiTranslationProvider */
3063
3354
 
@@ -3219,18 +3510,6 @@ export declare interface TLUiButtonLabelProps {
3219
3510
  children?: ReactNode;
3220
3511
  }
3221
3512
 
3222
- /** @public */
3223
- export declare interface TLUiButtonPickerProps<T extends string> {
3224
- title: string;
3225
- uiType: string;
3226
- style: StyleProp<T>;
3227
- value: SharedStyle<T>;
3228
- items: StyleValuesForUi<T>;
3229
- theme: TLDefaultColorTheme;
3230
- onValueChange(style: StyleProp<T>, value: T): void;
3231
- onHistoryMark?(id: string): void;
3232
- }
3233
-
3234
3513
  /** @public */
3235
3514
  export declare interface TLUiButtonProps extends React_2.HTMLAttributes<HTMLButtonElement> {
3236
3515
  disabled?: boolean;
@@ -3265,6 +3544,7 @@ export declare interface TLUiComponents {
3265
3544
  Dialogs?: ComponentType | null;
3266
3545
  Toasts?: ComponentType | null;
3267
3546
  A11y?: ComponentType | null;
3547
+ FollowingIndicator?: ComponentType | null;
3268
3548
  }
3269
3549
 
3270
3550
  /** @public */
@@ -3566,12 +3846,16 @@ export declare interface TLUiEventMap {
3566
3846
  'toggle-grid-mode': null;
3567
3847
  'toggle-wrap-mode': null;
3568
3848
  'toggle-focus-mode': null;
3849
+ 'input-mode': {
3850
+ value: string;
3851
+ };
3569
3852
  'toggle-debug-mode': null;
3570
3853
  'toggle-dynamic-size-mode': null;
3571
3854
  'toggle-paste-at-cursor': null;
3572
3855
  'toggle-lock': null;
3573
3856
  'toggle-reduce-motion': null;
3574
3857
  'toggle-keyboard-shortcuts': null;
3858
+ 'enhanced-a11y-mode': null;
3575
3859
  'toggle-edge-scrolling': null;
3576
3860
  'color-scheme': {
3577
3861
  value: string;
@@ -3589,11 +3873,14 @@ export declare interface TLUiEventMap {
3589
3873
  'flatten-to-image': null;
3590
3874
  'a11y-repeat-shape-announce': null;
3591
3875
  'open-url': {
3592
- url: string;
3876
+ destinationUrl: string;
3593
3877
  };
3594
3878
  'open-context-menu': null;
3595
3879
  'adjust-shape-styles': null;
3596
3880
  'copy-link': null;
3881
+ 'drag-tool': {
3882
+ id: string;
3883
+ };
3597
3884
  'image-replace': null;
3598
3885
  'video-replace': null;
3599
3886
  'open-kbd-shortcuts': null;
@@ -3667,6 +3954,7 @@ export declare interface TLUiInputProps {
3667
3954
  shouldManuallyMaintainScrollPositionWhenFocused?: boolean;
3668
3955
  value?: string;
3669
3956
  'data-testid'?: string;
3957
+ 'aria-label'?: string;
3670
3958
  }
3671
3959
 
3672
3960
  /** @public */
@@ -3680,6 +3968,13 @@ export declare type TLUiKeyboardShortcutsDialogProps = TLUiDialogProps & {
3680
3968
  children?: ReactNode;
3681
3969
  };
3682
3970
 
3971
+ /** @public */
3972
+ export declare interface TLUiLayoutProps extends HTMLAttributes<HTMLDivElement> {
3973
+ children: ReactNode;
3974
+ tooltipSide?: 'bottom' | 'left' | 'right' | 'top';
3975
+ asChild?: boolean;
3976
+ }
3977
+
3683
3978
  /** @public */
3684
3979
  export declare interface TLUiMainMenuProps {
3685
3980
  children?: ReactNode;
@@ -3704,6 +3999,7 @@ export declare interface TLUiMenuCheckboxItemProps<TranslationKey extends string
3704
3999
  label?: {
3705
4000
  [key: string]: TranslationKey;
3706
4001
  } | TranslationKey;
4002
+ lang?: string;
3707
4003
  readonlyOk?: boolean;
3708
4004
  onSelect(source: TLUiEventSource): Promise<void> | void;
3709
4005
  toggle?: boolean;
@@ -3719,7 +4015,7 @@ export declare interface TLUiMenuContextProviderProps {
3719
4015
  }
3720
4016
 
3721
4017
  /** @public */
3722
- export declare type TLUiMenuContextType = 'context-menu' | 'helper-buttons' | 'icons' | 'keyboard-shortcuts' | 'menu' | 'panel' | 'small-icons' | 'toolbar-overflow' | 'toolbar';
4018
+ export declare type TLUiMenuContextType = 'context-menu' | 'helper-buttons' | 'icons' | 'keyboard-shortcuts' | 'menu' | 'small-icons' | 'toolbar-overflow' | 'toolbar';
3723
4019
 
3724
4020
  /** @public */
3725
4021
  export declare interface TLUiMenuGroupProps<TranslationKey extends string = string> {
@@ -3779,6 +4075,10 @@ export declare interface TLUiMenuItemProps<TranslationKey extends string = strin
3779
4075
  * Whether the item is selected.
3780
4076
  */
3781
4077
  isSelected?: boolean;
4078
+ /**
4079
+ * The function to call when the item is dragged. If this is provided, the item will be draggable.
4080
+ */
4081
+ onDragStart?(source: TLUiEventSource, info: TLPointerEventInfo): void;
3782
4082
  }
3783
4083
 
3784
4084
  /** @public */
@@ -3824,6 +4124,7 @@ export declare interface TLUiPopoverProps {
3824
4124
  open?: boolean;
3825
4125
  children: React_3.ReactNode;
3826
4126
  onOpenChange?(isOpen: boolean): void;
4127
+ className?: string;
3827
4128
  }
3828
4129
 
3829
4130
  /** @public */
@@ -3849,19 +4150,15 @@ export declare interface TLUiSliderProps {
3849
4150
  label: string;
3850
4151
  title: string;
3851
4152
  onValueChange(value: number): void;
3852
- onHistoryMark(id: string): void;
4153
+ onHistoryMark?(id: string): void;
3853
4154
  'data-testid'?: string;
3854
4155
  ariaValueModifier?: number;
3855
4156
  }
3856
4157
 
3857
- /** @public */
3858
- export declare interface TLUiStylePanelContentProps {
3859
- styles: ReturnType<typeof useRelevantStyles>;
3860
- }
3861
-
3862
4158
  /** @public */
3863
4159
  export declare interface TLUiStylePanelProps {
3864
4160
  isMobile?: boolean;
4161
+ styles?: null | ReadonlySharedStyleMap;
3865
4162
  children?: ReactNode;
3866
4163
  }
3867
4164
 
@@ -3909,6 +4206,7 @@ export declare interface TLUiToolbarButtonProps extends React_3.HTMLAttributes<H
3909
4206
  disabled?: boolean;
3910
4207
  isActive?: boolean;
3911
4208
  type: 'icon' | 'menu' | 'tool';
4209
+ tooltip?: string;
3912
4210
  }
3913
4211
 
3914
4212
  /** @public */
@@ -3917,6 +4215,8 @@ export declare interface TLUiToolbarProps extends React_3.HTMLAttributes<HTMLDiv
3917
4215
  className?: string;
3918
4216
  dir?: 'ltr' | 'rtl';
3919
4217
  label: string;
4218
+ orientation?: 'grid' | 'horizontal' | 'vertical';
4219
+ tooltipSide?: 'bottom' | 'left' | 'right' | 'top';
3920
4220
  }
3921
4221
 
3922
4222
  /** @public */
@@ -3927,6 +4227,7 @@ export declare interface TLUiToolbarToggleGroupProps extends React_3.HTMLAttribu
3927
4227
  value: any;
3928
4228
  defaultValue?: any;
3929
4229
  type: 'multiple' | 'single';
4230
+ asChild?: boolean;
3930
4231
  }
3931
4232
 
3932
4233
  /** @public */
@@ -3935,6 +4236,7 @@ export declare interface TLUiToolbarToggleItemProps extends React_3.HTMLAttribut
3935
4236
  className?: string;
3936
4237
  type: 'icon' | 'tool';
3937
4238
  value: string;
4239
+ tooltip?: React_3.ReactNode;
3938
4240
  }
3939
4241
 
3940
4242
  /** @public */
@@ -3944,6 +4246,7 @@ export declare interface TLUiToolItem<TranslationKey extends string = string, Ic
3944
4246
  shortcutsLabel?: TranslationKey;
3945
4247
  icon: IconType | TLUiIconJsx;
3946
4248
  onSelect(source: TLUiEventSource): void;
4249
+ onDragStart?(source: TLUiEventSource, info: TLPointerEventInfo): void;
3947
4250
  /**
3948
4251
  * The keyboard shortcut for this tool. This is a string that can be a single key,
3949
4252
  * or a combination of keys.
@@ -3979,7 +4282,7 @@ export declare interface TLUiTranslation {
3979
4282
  export declare type TLUiTranslationContextType = TLUiTranslation;
3980
4283
 
3981
4284
  /** @public */
3982
- export declare type TLUiTranslationKey = 'a11y.adjust-shape-styles' | 'a11y.enlarge-shape' | 'a11y.enter-leave-container' | 'a11y.move-shape-faster' | 'a11y.move-shape' | 'a11y.multiple-shapes' | 'a11y.open-context-menu' | 'a11y.open-keyboard-shortcuts' | 'a11y.pan-camera' | 'a11y.repeat-shape' | 'a11y.rotate-shape-ccw-fine' | 'a11y.rotate-shape-ccw' | 'a11y.rotate-shape-cw-fine' | 'a11y.rotate-shape-cw' | 'a11y.select-shape-direction' | 'a11y.select-shape' | 'a11y.shape-image' | 'a11y.shape-index' | 'a11y.shape-video' | 'a11y.shrink-shape' | 'a11y.skip-to-main-content' | 'a11y.status' | 'action.align-bottom' | 'action.align-center-horizontal.short' | 'action.align-center-horizontal' | 'action.align-center-vertical.short' | 'action.align-center-vertical' | 'action.align-left' | 'action.align-right' | 'action.align-top' | 'action.back-to-content' | 'action.bring-forward' | 'action.bring-to-front' | 'action.convert-to-bookmark' | 'action.convert-to-embed' | 'action.copy-as-png.short' | 'action.copy-as-png' | 'action.copy-as-svg.short' | 'action.copy-as-svg' | 'action.copy' | 'action.cut' | 'action.delete' | 'action.distribute-horizontal.short' | 'action.distribute-horizontal' | 'action.distribute-vertical.short' | 'action.distribute-vertical' | 'action.download-original' | 'action.duplicate' | 'action.edit-link' | 'action.exit-pen-mode' | 'action.export-all-as-png.short' | 'action.export-all-as-png' | 'action.export-all-as-svg.short' | 'action.export-all-as-svg' | 'action.export-as-png.short' | 'action.export-as-png' | 'action.export-as-svg.short' | 'action.export-as-svg' | 'action.fit-frame-to-content' | 'action.flatten-to-image' | 'action.flip-horizontal.short' | 'action.flip-horizontal' | 'action.flip-vertical.short' | 'action.flip-vertical' | 'action.fork-project-on-tldraw' | 'action.fork-project' | 'action.group' | 'action.insert-embed' | 'action.insert-media' | 'action.leave-shared-project' | 'action.new-project' | 'action.new-shared-project' | 'action.open-cursor-chat' | 'action.open-embed-link' | 'action.open-file' | 'action.open-kbd-shortcuts' | 'action.pack' | 'action.paste-error-description' | 'action.paste-error-title' | 'action.paste' | 'action.print' | 'action.redo' | 'action.remove-frame' | 'action.rename' | 'action.rotate-ccw' | 'action.rotate-cw' | 'action.save-copy' | 'action.select-all' | 'action.select-none' | 'action.send-backward' | 'action.send-to-back' | 'action.share-project' | 'action.stack-horizontal.short' | 'action.stack-horizontal' | 'action.stack-vertical.short' | 'action.stack-vertical' | 'action.stop-following' | 'action.stretch-horizontal.short' | 'action.stretch-horizontal' | 'action.stretch-vertical.short' | 'action.stretch-vertical' | 'action.toggle-auto-size' | 'action.toggle-dark-mode.menu' | 'action.toggle-dark-mode' | 'action.toggle-debug-mode.menu' | 'action.toggle-debug-mode' | 'action.toggle-dynamic-size-mode.menu' | 'action.toggle-dynamic-size-mode' | 'action.toggle-edge-scrolling.menu' | 'action.toggle-edge-scrolling' | 'action.toggle-focus-mode.menu' | 'action.toggle-focus-mode' | 'action.toggle-grid.menu' | 'action.toggle-grid' | 'action.toggle-keyboard-shortcuts.menu' | 'action.toggle-keyboard-shortcuts' | 'action.toggle-lock' | 'action.toggle-paste-at-cursor.menu' | 'action.toggle-paste-at-cursor' | 'action.toggle-reduce-motion.menu' | 'action.toggle-reduce-motion' | 'action.toggle-snap-mode.menu' | 'action.toggle-snap-mode' | 'action.toggle-tool-lock.menu' | 'action.toggle-tool-lock' | 'action.toggle-transparent.context-menu' | 'action.toggle-transparent.menu' | 'action.toggle-transparent' | 'action.toggle-wrap-mode.menu' | 'action.toggle-wrap-mode' | 'action.undo' | 'action.ungroup' | 'action.unlock-all' | 'action.zoom-in' | 'action.zoom-out' | 'action.zoom-to-100' | 'action.zoom-to-fit' | 'action.zoom-to-selection' | 'actions-menu.title' | 'align-style.end' | 'align-style.justify' | 'align-style.middle' | 'align-style.start' | 'app.loading' | 'arrow-kind-style.arc' | 'arrow-kind-style.elbow' | 'arrowheadEnd-style.arrow' | 'arrowheadEnd-style.bar' | 'arrowheadEnd-style.diamond' | 'arrowheadEnd-style.dot' | 'arrowheadEnd-style.inverted' | 'arrowheadEnd-style.none' | 'arrowheadEnd-style.pipe' | 'arrowheadEnd-style.square' | 'arrowheadEnd-style.triangle' | 'arrowheadStart-style.arrow' | 'arrowheadStart-style.bar' | 'arrowheadStart-style.diamond' | 'arrowheadStart-style.dot' | 'arrowheadStart-style.inverted' | 'arrowheadStart-style.none' | 'arrowheadStart-style.pipe' | 'arrowheadStart-style.square' | 'arrowheadStart-style.triangle' | 'assets.files.amount-too-many' | 'assets.files.size-too-big' | 'assets.files.type-not-allowed' | 'assets.files.upload-failed' | 'assets.url.failed' | 'color-style.black' | 'color-style.blue' | 'color-style.green' | 'color-style.grey' | 'color-style.light-blue' | 'color-style.light-green' | 'color-style.light-red' | 'color-style.light-violet' | 'color-style.orange' | 'color-style.red' | 'color-style.violet' | 'color-style.white' | 'color-style.yellow' | 'context-menu.arrange' | 'context-menu.copy-as' | 'context-menu.edit' | 'context-menu.export-all-as' | 'context-menu.export-as' | 'context-menu.move-to-page' | 'context-menu.reorder' | 'context-menu.title' | 'context.pages.new-page' | 'cursor-chat.type-to-chat' | 'dash-style.dashed' | 'dash-style.dotted' | 'dash-style.draw' | 'dash-style.solid' | 'document-name-menu.copy-link' | 'document.default-name' | 'edit-link-dialog.cancel' | 'edit-link-dialog.clear' | 'edit-link-dialog.detail' | 'edit-link-dialog.external-link' | 'edit-link-dialog.invalid-url' | 'edit-link-dialog.save' | 'edit-link-dialog.title' | 'edit-link-dialog.url' | 'embed-dialog.back' | 'embed-dialog.cancel' | 'embed-dialog.create' | 'embed-dialog.instruction' | 'embed-dialog.invalid-url' | 'embed-dialog.title' | 'embed-dialog.url' | 'file-system.confirm-clear.cancel' | 'file-system.confirm-clear.continue' | 'file-system.confirm-clear.description' | 'file-system.confirm-clear.dont-show-again' | 'file-system.confirm-clear.title' | 'file-system.confirm-open.cancel' | 'file-system.confirm-open.description' | 'file-system.confirm-open.dont-show-again' | 'file-system.confirm-open.open' | 'file-system.confirm-open.title' | 'file-system.file-open-error.file-format-version-too-new' | 'file-system.file-open-error.generic-corrupted-file' | 'file-system.file-open-error.not-a-tldraw-file' | 'file-system.file-open-error.title' | 'file-system.shared-document-file-open-error.description' | 'file-system.shared-document-file-open-error.title' | 'fill-style.fill' | 'fill-style.none' | 'fill-style.pattern' | 'fill-style.semi' | 'fill-style.solid' | 'focus-mode.toggle-focus-mode' | 'font-style.draw' | 'font-style.mono' | 'font-style.sans' | 'font-style.serif' | 'geo-style.arrow-down' | 'geo-style.arrow-left' | 'geo-style.arrow-right' | 'geo-style.arrow-up' | 'geo-style.check-box' | 'geo-style.cloud' | 'geo-style.diamond' | 'geo-style.ellipse' | 'geo-style.heart' | 'geo-style.hexagon' | 'geo-style.octagon' | 'geo-style.oval' | 'geo-style.pentagon' | 'geo-style.rectangle' | 'geo-style.rhombus' | 'geo-style.star' | 'geo-style.trapezoid' | 'geo-style.triangle' | 'geo-style.x-box' | 'handle.crop.bottom-left' | 'handle.crop.bottom-right' | 'handle.crop.bottom' | 'handle.crop.left' | 'handle.crop.right' | 'handle.crop.top-left' | 'handle.crop.top-right' | 'handle.crop.top' | 'handle.resize-bottom-left' | 'handle.resize-bottom-right' | 'handle.resize-bottom' | 'handle.resize-left' | 'handle.resize-right' | 'handle.resize-top-left' | 'handle.resize-top-right' | 'handle.resize-top' | 'handle.rotate.bottom_left_rotate' | 'handle.rotate.bottom_right_rotate' | 'handle.rotate.mobile_rotate' | 'handle.rotate.top_left_rotate' | 'handle.rotate.top_right_rotate' | 'help-menu.about' | 'help-menu.discord' | 'help-menu.github' | 'help-menu.import-tldr-file' | 'help-menu.keyboard-shortcuts' | 'help-menu.privacy' | 'help-menu.terms' | 'help-menu.title' | 'help-menu.twitter' | 'menu.copy-as' | 'menu.edit' | 'menu.export-as' | 'menu.file' | 'menu.language' | 'menu.preferences' | 'menu.theme' | 'menu.title' | 'menu.view' | 'navigation-zone.minimap' | 'navigation-zone.title' | 'navigation-zone.toggle-minimap' | 'navigation-zone.zoom' | 'opacity-style.0.1' | 'opacity-style.0.25' | 'opacity-style.0.5' | 'opacity-style.0.75' | 'opacity-style.1' | 'page-menu.create-new-page' | 'page-menu.edit-done' | 'page-menu.edit-start' | 'page-menu.go-to-page' | 'page-menu.max-page-count-reached' | 'page-menu.new-page-initial-name' | 'page-menu.submenu.delete' | 'page-menu.submenu.duplicate-page' | 'page-menu.submenu.move-down' | 'page-menu.submenu.move-up' | 'page-menu.submenu.rename' | 'page-menu.submenu.title' | 'page-menu.title' | 'people-menu.anonymous-user' | 'people-menu.avatar-color' | 'people-menu.change-color' | 'people-menu.change-name' | 'people-menu.follow' | 'people-menu.following' | 'people-menu.invite' | 'people-menu.leading' | 'people-menu.title' | 'people-menu.user' | 'share-menu.copied' | 'share-menu.copy-link-note' | 'share-menu.copy-link' | 'share-menu.copy-readonly-link-note' | 'share-menu.copy-readonly-link' | 'share-menu.create-snapshot-link' | 'share-menu.creating-project' | 'share-menu.fork-note' | 'share-menu.offline-note' | 'share-menu.project-too-large' | 'share-menu.save-note' | 'share-menu.share-project' | 'share-menu.snapshot-link-note' | 'share-menu.title' | 'share-menu.upload-failed' | 'sharing.confirm-leave.cancel' | 'sharing.confirm-leave.description' | 'sharing.confirm-leave.dont-show-again' | 'sharing.confirm-leave.leave' | 'sharing.confirm-leave.title' | 'shortcuts-dialog.a11y' | 'shortcuts-dialog.collaboration' | 'shortcuts-dialog.edit' | 'shortcuts-dialog.file' | 'shortcuts-dialog.preferences' | 'shortcuts-dialog.text-formatting' | 'shortcuts-dialog.title' | 'shortcuts-dialog.tools' | 'shortcuts-dialog.transform' | 'shortcuts-dialog.view' | 'size-style.l' | 'size-style.m' | 'size-style.s' | 'size-style.xl' | 'spline-style.cubic' | 'spline-style.line' | 'status.offline' | 'style-panel.align' | 'style-panel.arrow-kind' | 'style-panel.arrowhead-end' | 'style-panel.arrowhead-start' | 'style-panel.arrowheads' | 'style-panel.color' | 'style-panel.dash' | 'style-panel.fill' | 'style-panel.font' | 'style-panel.geo' | 'style-panel.label-align' | 'style-panel.mixed' | 'style-panel.opacity' | 'style-panel.position' | 'style-panel.size' | 'style-panel.spline' | 'style-panel.title' | 'style-panel.vertical-align' | 'theme.dark' | 'theme.light' | 'theme.system' | 'toast.close' | 'toast.error.copy-fail.desc' | 'toast.error.copy-fail.title' | 'toast.error.export-fail.desc' | 'toast.error.export-fail.title' | 'toast.error' | 'toast.info' | 'toast.success' | 'toast.warning' | 'tool-panel.more' | 'tool-panel.title' | 'tool.arrow-down' | 'tool.arrow-left' | 'tool.arrow-right' | 'tool.arrow-up' | 'tool.arrow' | 'tool.aspect-ratio.circle' | 'tool.aspect-ratio.landscape' | 'tool.aspect-ratio.original' | 'tool.aspect-ratio.portrait' | 'tool.aspect-ratio.square' | 'tool.aspect-ratio.wide' | 'tool.aspect-ratio' | 'tool.bookmark' | 'tool.check-box' | 'tool.cloud' | 'tool.diamond' | 'tool.draw' | 'tool.ellipse' | 'tool.embed' | 'tool.eraser' | 'tool.flip-horz' | 'tool.flip-vert' | 'tool.frame' | 'tool.hand' | 'tool.heart' | 'tool.hexagon' | 'tool.highlight' | 'tool.image-crop' | 'tool.image-toolbar-title' | 'tool.image-zoom' | 'tool.laser' | 'tool.line' | 'tool.media-alt-text-confirm' | 'tool.media-alt-text-desc' | 'tool.media-alt-text' | 'tool.media' | 'tool.note' | 'tool.octagon' | 'tool.oval' | 'tool.pentagon' | 'tool.pointer-down' | 'tool.rectangle' | 'tool.replace-media' | 'tool.rhombus' | 'tool.rich-text-bold' | 'tool.rich-text-bulletList' | 'tool.rich-text-code' | 'tool.rich-text-header' | 'tool.rich-text-highlight' | 'tool.rich-text-italic' | 'tool.rich-text-link-remove' | 'tool.rich-text-link-visit' | 'tool.rich-text-link' | 'tool.rich-text-orderedList' | 'tool.rich-text-strikethrough' | 'tool.rich-text-toolbar-title' | 'tool.rotate-cw' | 'tool.select' | 'tool.star' | 'tool.text' | 'tool.trapezoid' | 'tool.triangle' | 'tool.x-box' | 'ui.checked' | 'ui.close' | 'ui.unchecked' | 'verticalAlign-style.end' | 'verticalAlign-style.middle' | 'verticalAlign-style.start' | 'vscode.file-open.backup-failed' | 'vscode.file-open.backup-saved' | 'vscode.file-open.backup' | 'vscode.file-open.desc' | 'vscode.file-open.dont-show-again' | 'vscode.file-open.open';
4285
+ export declare type TLUiTranslationKey = 'a11y.adjust-shape-styles' | 'a11y.enlarge-shape' | 'a11y.enter-leave-container' | 'a11y.move-shape-faster' | 'a11y.move-shape' | 'a11y.multiple-shapes' | 'a11y.open-context-menu' | 'a11y.open-keyboard-shortcuts' | 'a11y.pan-camera' | 'a11y.repeat-shape' | 'a11y.rotate-shape-ccw-fine' | 'a11y.rotate-shape-ccw' | 'a11y.rotate-shape-cw-fine' | 'a11y.rotate-shape-cw' | 'a11y.select-shape-direction' | 'a11y.select-shape' | 'a11y.shape-image' | 'a11y.shape-index' | 'a11y.shape-video' | 'a11y.shrink-shape' | 'a11y.skip-to-main-content' | 'a11y.status' | 'action.align-bottom' | 'action.align-center-horizontal.short' | 'action.align-center-horizontal' | 'action.align-center-vertical.short' | 'action.align-center-vertical' | 'action.align-left' | 'action.align-right' | 'action.align-top' | 'action.back-to-content' | 'action.bring-forward' | 'action.bring-to-front' | 'action.convert-to-bookmark' | 'action.convert-to-embed' | 'action.copy-as-png.short' | 'action.copy-as-png' | 'action.copy-as-svg.short' | 'action.copy-as-svg' | 'action.copy' | 'action.cut' | 'action.delete' | 'action.distribute-horizontal.short' | 'action.distribute-horizontal' | 'action.distribute-vertical.short' | 'action.distribute-vertical' | 'action.download-original' | 'action.duplicate' | 'action.edit-link' | 'action.enhanced-a11y-mode.menu' | 'action.enhanced-a11y-mode' | 'action.exit-pen-mode' | 'action.export-all-as-png.short' | 'action.export-all-as-png' | 'action.export-all-as-svg.short' | 'action.export-all-as-svg' | 'action.export-as-png.short' | 'action.export-as-png' | 'action.export-as-svg.short' | 'action.export-as-svg' | 'action.fit-frame-to-content' | 'action.flatten-to-image' | 'action.flip-horizontal.short' | 'action.flip-horizontal' | 'action.flip-vertical.short' | 'action.flip-vertical' | 'action.fork-project-on-tldraw' | 'action.fork-project' | 'action.group' | 'action.insert-embed' | 'action.insert-media' | 'action.leave-shared-project' | 'action.new-project' | 'action.new-shared-project' | 'action.open-cursor-chat' | 'action.open-embed-link' | 'action.open-file' | 'action.open-kbd-shortcuts' | 'action.pack' | 'action.paste-error-description' | 'action.paste-error-title' | 'action.paste' | 'action.print' | 'action.redo' | 'action.remove-frame' | 'action.rename' | 'action.rotate-ccw' | 'action.rotate-cw' | 'action.save-copy' | 'action.select-all' | 'action.select-none' | 'action.send-backward' | 'action.send-to-back' | 'action.share-project' | 'action.stack-horizontal.short' | 'action.stack-horizontal' | 'action.stack-vertical.short' | 'action.stack-vertical' | 'action.stop-following' | 'action.stretch-horizontal.short' | 'action.stretch-horizontal' | 'action.stretch-vertical.short' | 'action.stretch-vertical' | 'action.toggle-auto-none' | 'action.toggle-auto-pan' | 'action.toggle-auto-size' | 'action.toggle-auto-zoom' | 'action.toggle-dark-mode.menu' | 'action.toggle-dark-mode' | 'action.toggle-debug-mode.menu' | 'action.toggle-debug-mode' | 'action.toggle-dynamic-size-mode.menu' | 'action.toggle-dynamic-size-mode' | 'action.toggle-edge-scrolling.menu' | 'action.toggle-edge-scrolling' | 'action.toggle-focus-mode.menu' | 'action.toggle-focus-mode' | 'action.toggle-grid.menu' | 'action.toggle-grid' | 'action.toggle-keyboard-shortcuts.menu' | 'action.toggle-keyboard-shortcuts' | 'action.toggle-lock' | 'action.toggle-mouse' | 'action.toggle-paste-at-cursor.menu' | 'action.toggle-paste-at-cursor' | 'action.toggle-reduce-motion.menu' | 'action.toggle-reduce-motion' | 'action.toggle-snap-mode.menu' | 'action.toggle-snap-mode' | 'action.toggle-tool-lock.menu' | 'action.toggle-tool-lock' | 'action.toggle-trackpad' | 'action.toggle-transparent.context-menu' | 'action.toggle-transparent.menu' | 'action.toggle-transparent' | 'action.toggle-wrap-mode.menu' | 'action.toggle-wrap-mode' | 'action.undo' | 'action.ungroup' | 'action.unlock-all' | 'action.zoom-in' | 'action.zoom-out' | 'action.zoom-to-100' | 'action.zoom-to-fit' | 'action.zoom-to-selection' | 'actions-menu.title' | 'align-style.end' | 'align-style.justify' | 'align-style.middle' | 'align-style.start' | 'app.loading' | 'arrow-kind-style.arc' | 'arrow-kind-style.elbow' | 'arrowheadEnd-style.arrow' | 'arrowheadEnd-style.bar' | 'arrowheadEnd-style.diamond' | 'arrowheadEnd-style.dot' | 'arrowheadEnd-style.inverted' | 'arrowheadEnd-style.none' | 'arrowheadEnd-style.pipe' | 'arrowheadEnd-style.square' | 'arrowheadEnd-style.triangle' | 'arrowheadStart-style.arrow' | 'arrowheadStart-style.bar' | 'arrowheadStart-style.diamond' | 'arrowheadStart-style.dot' | 'arrowheadStart-style.inverted' | 'arrowheadStart-style.none' | 'arrowheadStart-style.pipe' | 'arrowheadStart-style.square' | 'arrowheadStart-style.triangle' | 'assets.files.amount-too-many' | 'assets.files.maximum-size' | 'assets.files.size-too-big' | 'assets.files.type-not-allowed' | 'assets.files.upload-failed' | 'assets.url.failed' | 'color-style.black' | 'color-style.blue' | 'color-style.green' | 'color-style.grey' | 'color-style.light-blue' | 'color-style.light-green' | 'color-style.light-red' | 'color-style.light-violet' | 'color-style.orange' | 'color-style.red' | 'color-style.violet' | 'color-style.white' | 'color-style.yellow' | 'context-menu.arrange' | 'context-menu.copy-as' | 'context-menu.edit' | 'context-menu.export-all-as' | 'context-menu.export-as' | 'context-menu.move-to-page' | 'context-menu.reorder' | 'context-menu.title' | 'context.pages.new-page' | 'cursor-chat.type-to-chat' | 'dash-style.dashed' | 'dash-style.dotted' | 'dash-style.draw' | 'dash-style.solid' | 'document-name-menu.copy-link' | 'document.default-name' | 'edit-link-dialog.cancel' | 'edit-link-dialog.clear' | 'edit-link-dialog.detail' | 'edit-link-dialog.external-link' | 'edit-link-dialog.invalid-url' | 'edit-link-dialog.save' | 'edit-link-dialog.title' | 'edit-link-dialog.url' | 'embed-dialog.back' | 'embed-dialog.cancel' | 'embed-dialog.create' | 'embed-dialog.instruction' | 'embed-dialog.invalid-url' | 'embed-dialog.title' | 'embed-dialog.url' | 'file-system.confirm-clear.cancel' | 'file-system.confirm-clear.continue' | 'file-system.confirm-clear.description' | 'file-system.confirm-clear.dont-show-again' | 'file-system.confirm-clear.title' | 'file-system.confirm-open.cancel' | 'file-system.confirm-open.description' | 'file-system.confirm-open.dont-show-again' | 'file-system.confirm-open.open' | 'file-system.confirm-open.title' | 'file-system.file-open-error.file-format-version-too-new' | 'file-system.file-open-error.generic-corrupted-file' | 'file-system.file-open-error.not-a-tldraw-file' | 'file-system.file-open-error.title' | 'file-system.shared-document-file-open-error.description' | 'file-system.shared-document-file-open-error.title' | 'fill-style.fill' | 'fill-style.none' | 'fill-style.pattern' | 'fill-style.semi' | 'fill-style.solid' | 'focus-mode.toggle-focus-mode' | 'font-style.draw' | 'font-style.mono' | 'font-style.sans' | 'font-style.serif' | 'geo-style.arrow-down' | 'geo-style.arrow-left' | 'geo-style.arrow-right' | 'geo-style.arrow-up' | 'geo-style.check-box' | 'geo-style.cloud' | 'geo-style.diamond' | 'geo-style.ellipse' | 'geo-style.heart' | 'geo-style.hexagon' | 'geo-style.octagon' | 'geo-style.oval' | 'geo-style.pentagon' | 'geo-style.rectangle' | 'geo-style.rhombus-2' | 'geo-style.rhombus' | 'geo-style.star' | 'geo-style.trapezoid' | 'geo-style.triangle' | 'geo-style.x-box' | 'handle.crop.bottom-left' | 'handle.crop.bottom-right' | 'handle.crop.bottom' | 'handle.crop.left' | 'handle.crop.right' | 'handle.crop.top-left' | 'handle.crop.top-right' | 'handle.crop.top' | 'handle.resize-bottom-left' | 'handle.resize-bottom-right' | 'handle.resize-bottom' | 'handle.resize-left' | 'handle.resize-right' | 'handle.resize-top-left' | 'handle.resize-top-right' | 'handle.resize-top' | 'handle.rotate.bottom_left_rotate' | 'handle.rotate.bottom_right_rotate' | 'handle.rotate.mobile_rotate' | 'handle.rotate.top_left_rotate' | 'handle.rotate.top_right_rotate' | 'help-menu.about' | 'help-menu.discord' | 'help-menu.github' | 'help-menu.import-tldr-file' | 'help-menu.keyboard-shortcuts' | 'help-menu.privacy' | 'help-menu.terms' | 'help-menu.title' | 'help-menu.twitter' | 'menu.accessibility' | 'menu.copy-as' | 'menu.edit' | 'menu.export-as' | 'menu.file' | 'menu.input-mode' | 'menu.language' | 'menu.preferences' | 'menu.theme' | 'menu.title' | 'menu.view' | 'navigation-zone.minimap' | 'navigation-zone.title' | 'navigation-zone.toggle-minimap' | 'navigation-zone.zoom' | 'opacity-style.0.1' | 'opacity-style.0.25' | 'opacity-style.0.5' | 'opacity-style.0.75' | 'opacity-style.1' | 'page-menu.create-new-page' | 'page-menu.edit-done' | 'page-menu.edit-start' | 'page-menu.go-to-page' | 'page-menu.max-page-count-reached' | 'page-menu.new-page-initial-name' | 'page-menu.submenu.delete' | 'page-menu.submenu.duplicate-page' | 'page-menu.submenu.move-down' | 'page-menu.submenu.move-up' | 'page-menu.submenu.rename' | 'page-menu.submenu.title' | 'page-menu.title' | 'people-menu.anonymous-user' | 'people-menu.avatar-color' | 'people-menu.change-color' | 'people-menu.change-name' | 'people-menu.follow' | 'people-menu.following' | 'people-menu.invite' | 'people-menu.leading' | 'people-menu.title' | 'people-menu.user' | 'share-menu.copied' | 'share-menu.copy-link-note' | 'share-menu.copy-link' | 'share-menu.copy-readonly-link-note' | 'share-menu.copy-readonly-link' | 'share-menu.create-snapshot-link' | 'share-menu.creating-project' | 'share-menu.fork-note' | 'share-menu.offline-note' | 'share-menu.project-too-large' | 'share-menu.save-note' | 'share-menu.share-project' | 'share-menu.snapshot-link-note' | 'share-menu.title' | 'share-menu.upload-failed' | 'sharing.confirm-leave.cancel' | 'sharing.confirm-leave.description' | 'sharing.confirm-leave.dont-show-again' | 'sharing.confirm-leave.leave' | 'sharing.confirm-leave.title' | 'shortcuts-dialog.a11y' | 'shortcuts-dialog.collaboration' | 'shortcuts-dialog.edit' | 'shortcuts-dialog.file' | 'shortcuts-dialog.preferences' | 'shortcuts-dialog.text-formatting' | 'shortcuts-dialog.title' | 'shortcuts-dialog.tools' | 'shortcuts-dialog.transform' | 'shortcuts-dialog.view' | 'size-style.l' | 'size-style.m' | 'size-style.s' | 'size-style.xl' | 'spline-style.cubic' | 'spline-style.line' | 'status.offline' | 'style-panel.align' | 'style-panel.arrow-kind' | 'style-panel.arrowhead-end' | 'style-panel.arrowhead-start' | 'style-panel.arrowheads' | 'style-panel.color' | 'style-panel.dash' | 'style-panel.fill' | 'style-panel.font' | 'style-panel.geo' | 'style-panel.label-align' | 'style-panel.mixed' | 'style-panel.opacity' | 'style-panel.position' | 'style-panel.selected' | 'style-panel.size' | 'style-panel.spline' | 'style-panel.title' | 'style-panel.vertical-align' | 'theme.dark' | 'theme.light' | 'theme.system' | 'toast.close' | 'toast.error.copy-fail.desc' | 'toast.error.copy-fail.title' | 'toast.error.export-fail.desc' | 'toast.error.export-fail.title' | 'toast.error' | 'toast.info' | 'toast.success' | 'toast.warning' | 'tool-panel.more' | 'tool-panel.title' | 'tool.arrow-down' | 'tool.arrow-left' | 'tool.arrow-right' | 'tool.arrow-up' | 'tool.arrow' | 'tool.aspect-ratio.circle' | 'tool.aspect-ratio.landscape' | 'tool.aspect-ratio.original' | 'tool.aspect-ratio.portrait' | 'tool.aspect-ratio.square' | 'tool.aspect-ratio.wide' | 'tool.aspect-ratio' | 'tool.bookmark' | 'tool.check-box' | 'tool.cloud' | 'tool.diamond' | 'tool.draw' | 'tool.ellipse' | 'tool.embed' | 'tool.eraser' | 'tool.flip-horz' | 'tool.flip-vert' | 'tool.frame' | 'tool.hand' | 'tool.heart' | 'tool.hexagon' | 'tool.highlight' | 'tool.image-crop-confirm' | 'tool.image-crop' | 'tool.image-toolbar-title' | 'tool.image-zoom' | 'tool.laser' | 'tool.line' | 'tool.media-alt-text-confirm' | 'tool.media-alt-text-desc' | 'tool.media-alt-text' | 'tool.media' | 'tool.note' | 'tool.octagon' | 'tool.oval' | 'tool.pentagon' | 'tool.pointer-down' | 'tool.rectangle' | 'tool.replace-media' | 'tool.rhombus' | 'tool.rich-text-bold' | 'tool.rich-text-bulletList' | 'tool.rich-text-code' | 'tool.rich-text-header' | 'tool.rich-text-highlight' | 'tool.rich-text-italic' | 'tool.rich-text-link-remove' | 'tool.rich-text-link-visit' | 'tool.rich-text-link' | 'tool.rich-text-orderedList' | 'tool.rich-text-strikethrough' | 'tool.rich-text-toolbar-title' | 'tool.rotate-cw' | 'tool.select' | 'tool.star' | 'tool.text' | 'tool.trapezoid' | 'tool.triangle' | 'tool.x-box' | 'ui.checked' | 'ui.close' | 'ui.unchecked' | 'verticalAlign-style.end' | 'verticalAlign-style.middle' | 'verticalAlign-style.start' | 'vscode.file-open.backup-failed' | 'vscode.file-open.backup-saved' | 'vscode.file-open.backup' | 'vscode.file-open.desc' | 'vscode.file-open.dont-show-again' | 'vscode.file-open.open';
3983
4286
 
3984
4287
  /** @public */
3985
4288
  export declare interface TLUiTranslationProviderProps {
@@ -4085,6 +4388,9 @@ export declare function ToggleDynamicSizeModeItem(): JSX_2.Element;
4085
4388
  /** @public @react */
4086
4389
  export declare function ToggleEdgeScrollingItem(): JSX_2.Element;
4087
4390
 
4391
+ /** @public @react */
4392
+ export declare function ToggleEnhancedA11yModeItem(): JSX_2.Element;
4393
+
4088
4394
  /** @public @react */
4089
4395
  export declare function ToggleFocusModeItem(): JSX_2.Element;
4090
4396
 
@@ -4152,18 +4458,34 @@ export declare function UnlockAllMenuItem(): JSX_2.Element;
4152
4458
  /** @public */
4153
4459
  export declare function unwrapLabel(label?: TLUiActionItem['label'], menuType?: string): string | undefined;
4154
4460
 
4155
- /** @public */
4156
- export declare function useA11y(): TLUiA11yContextType;
4157
-
4158
- /** @public */
4159
- export declare function useActions(): TLUiActionsContextType;
4461
+ /**
4462
+ * Update the current arrow target state for an editor. See {@link ArrowTargetState} for more
4463
+ * information.
4464
+ *
4465
+ * @public
4466
+ */
4467
+ export declare function updateArrowTargetState({ editor, pointInPageSpace, arrow, isPrecise, currentBinding, oppositeBinding, }: UpdateArrowTargetStateOpts): ArrowTargetState | null;
4160
4468
 
4161
4469
  /**
4162
- * @deprecated Use {@link useImageOrVideoAsset} instead.
4470
+ * Options passed to {@link updateArrowTargetState}.
4163
4471
  *
4164
4472
  * @public
4165
4473
  */
4166
- export declare const useAsset: typeof useImageOrVideoAsset;
4474
+ export declare interface UpdateArrowTargetStateOpts {
4475
+ editor: Editor;
4476
+ pointInPageSpace: VecLike;
4477
+ arrow: TLArrowShape | undefined;
4478
+ isPrecise: boolean;
4479
+ currentBinding: TLArrowBinding | undefined;
4480
+ /** The binding from the opposite end of the arrow, if one exists. */
4481
+ oppositeBinding: TLArrowBinding | undefined;
4482
+ }
4483
+
4484
+ /** @public */
4485
+ export declare function useA11y(): TLUiA11yContextType;
4486
+
4487
+ /** @public */
4488
+ export declare function useActions(): TLUiActionsContextType;
4167
4489
 
4168
4490
  /* Excluded from this release type: useAssetUrls */
4169
4491
 
@@ -4219,7 +4541,11 @@ export declare function useDefaultHelpers(): {
4219
4541
  copy: (source: TLUiEventSource) => Promise<void>;
4220
4542
  copyAs: (ids: TLShapeId[], format?: TLCopyType) => void;
4221
4543
  cut: (source: TLUiEventSource) => Promise<void>;
4222
- exportAs: (ids: TLShapeId[], format: TLExportType | undefined, name: string | undefined) => void;
4544
+ exportAs: (ids: TLShapeId[], opts?: {
4545
+ format?: TLExportType;
4546
+ name?: string;
4547
+ scale?: number;
4548
+ }) => void;
4223
4549
  getEmbedDefinition: (url: string) => TLEmbedResult;
4224
4550
  insertMedia: () => Promise<void>;
4225
4551
  isMobile: boolean;
@@ -4241,7 +4567,9 @@ export declare function useEditablePlainText(shapeId: TLShapeId, type: string, t
4241
4567
  handleChange: ({ plaintext }: {
4242
4568
  plaintext: string;
4243
4569
  }) => void;
4244
- handleDoubleClick: (e: any) => any;
4570
+ handleDoubleClick: (e: {
4571
+ nativeEvent: Event;
4572
+ } | Event) => void;
4245
4573
  handleFocus: () => void;
4246
4574
  handleInputPointerDown: (e: React_3.PointerEvent) => void;
4247
4575
  handleKeyDown: (e: KeyboardEvent) => void;
@@ -4258,7 +4586,9 @@ export declare function useEditableRichText(shapeId: TLShapeId, type: string, ri
4258
4586
  handleChange: ({ richText }: {
4259
4587
  richText: TLRichText;
4260
4588
  }) => void;
4261
- handleDoubleClick: (e: any) => any;
4589
+ handleDoubleClick: (e: {
4590
+ nativeEvent: Event;
4591
+ } | Event) => void;
4262
4592
  handleFocus: () => void;
4263
4593
  handleInputPointerDown: (e: React.PointerEvent) => void;
4264
4594
  handleKeyDown: (e: KeyboardEvent) => void;
@@ -4269,14 +4599,12 @@ export declare function useEditableRichText(shapeId: TLShapeId, type: string, ri
4269
4599
  rInput: RefObject<HTMLDivElement>;
4270
4600
  };
4271
4601
 
4272
- /**
4273
- * @deprecated Use `useEditablePlainText` instead.
4274
- * @public
4275
- */
4276
- export declare const useEditableText: typeof useEditablePlainText;
4277
-
4278
4602
  /** @public */
4279
- export declare function useExportAs(): (ids: TLShapeId[], format: TLExportType | undefined, name: string | undefined) => void;
4603
+ export declare function useExportAs(): (ids: TLShapeId[], opts?: {
4604
+ format?: TLExportType;
4605
+ name?: string;
4606
+ scale?: number;
4607
+ }) => void;
4280
4608
 
4281
4609
  /**
4282
4610
  * This is a handy helper hook that resolves an asset to an optimized URL for a given shape, or its
@@ -4350,9 +4678,15 @@ export declare const useSelectedShapesAnnouncer: () => void;
4350
4678
  /** @public */
4351
4679
  export declare function useShowCollaborationUi(): boolean;
4352
4680
 
4681
+ /** @public */
4682
+ export declare function useStylePanelContext(): StylePanelContext;
4683
+
4353
4684
  /** @public */
4354
4685
  export declare function useTldrawUiComponents(): TLUiComponents;
4355
4686
 
4687
+ /** @public */
4688
+ export declare function useTldrawUiOrientation(): TldrawUiOrientationContext;
4689
+
4356
4690
  /** @public */
4357
4691
  export declare function useToasts(): TLUiToastsContextType;
4358
4692