@tldraw/editor 3.16.0-internal.a478398270c6 → 3.16.0-next.15f085081fd5

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 (235) hide show
  1. package/dist-cjs/index.d.ts +243 -16
  2. package/dist-cjs/index.js +8 -1
  3. package/dist-cjs/index.js.map +2 -2
  4. package/dist-cjs/lib/TldrawEditor.js +8 -2
  5. package/dist-cjs/lib/TldrawEditor.js.map +2 -2
  6. package/dist-cjs/lib/components/MenuClickCapture.js +0 -5
  7. package/dist-cjs/lib/components/MenuClickCapture.js.map +2 -2
  8. package/dist-cjs/lib/components/SVGContainer.js +1 -1
  9. package/dist-cjs/lib/components/SVGContainer.js.map +2 -2
  10. package/dist-cjs/lib/components/Shape.js +11 -36
  11. package/dist-cjs/lib/components/Shape.js.map +2 -2
  12. package/dist-cjs/lib/components/default-components/DefaultBrush.js +1 -1
  13. package/dist-cjs/lib/components/default-components/DefaultBrush.js.map +2 -2
  14. package/dist-cjs/lib/components/default-components/DefaultCanvas.js +5 -24
  15. package/dist-cjs/lib/components/default-components/DefaultCanvas.js.map +2 -2
  16. package/dist-cjs/lib/components/default-components/DefaultCollaboratorHint.js +2 -2
  17. package/dist-cjs/lib/components/default-components/DefaultCollaboratorHint.js.map +2 -2
  18. package/dist-cjs/lib/components/default-components/DefaultCursor.js +1 -1
  19. package/dist-cjs/lib/components/default-components/DefaultCursor.js.map +2 -2
  20. package/dist-cjs/lib/components/default-components/DefaultErrorFallback.js +1 -1
  21. package/dist-cjs/lib/components/default-components/DefaultErrorFallback.js.map +2 -2
  22. package/dist-cjs/lib/components/default-components/DefaultGrid.js +1 -1
  23. package/dist-cjs/lib/components/default-components/DefaultGrid.js.map +2 -2
  24. package/dist-cjs/lib/components/default-components/DefaultHandles.js +1 -1
  25. package/dist-cjs/lib/components/default-components/DefaultHandles.js.map +2 -2
  26. package/dist-cjs/lib/components/default-components/DefaultScribble.js +1 -1
  27. package/dist-cjs/lib/components/default-components/DefaultScribble.js.map +2 -2
  28. package/dist-cjs/lib/components/default-components/DefaultShapeIndicator.js +9 -1
  29. package/dist-cjs/lib/components/default-components/DefaultShapeIndicator.js.map +2 -2
  30. package/dist-cjs/lib/components/default-components/DefaultShapeWrapper.js +53 -0
  31. package/dist-cjs/lib/components/default-components/DefaultShapeWrapper.js.map +7 -0
  32. package/dist-cjs/lib/components/default-components/DefaultSnapIndictor.js +1 -1
  33. package/dist-cjs/lib/components/default-components/DefaultSnapIndictor.js.map +2 -2
  34. package/dist-cjs/lib/components/default-components/DefaultSpinner.js +27 -15
  35. package/dist-cjs/lib/components/default-components/DefaultSpinner.js.map +3 -3
  36. package/dist-cjs/lib/config/TLUserPreferences.js +15 -3
  37. package/dist-cjs/lib/config/TLUserPreferences.js.map +2 -2
  38. package/dist-cjs/lib/editor/Editor.js +151 -67
  39. package/dist-cjs/lib/editor/Editor.js.map +2 -2
  40. package/dist-cjs/lib/editor/managers/UserPreferencesManager/UserPreferencesManager.js +14 -4
  41. package/dist-cjs/lib/editor/managers/UserPreferencesManager/UserPreferencesManager.js.map +2 -2
  42. package/dist-cjs/lib/editor/shapes/ShapeUtil.js +13 -0
  43. package/dist-cjs/lib/editor/shapes/ShapeUtil.js.map +2 -2
  44. package/dist-cjs/lib/editor/tools/StateNode.js +20 -1
  45. package/dist-cjs/lib/editor/tools/StateNode.js.map +2 -2
  46. package/dist-cjs/lib/editor/types/misc-types.js.map +1 -1
  47. package/dist-cjs/lib/exports/getSvgJsx.js +35 -16
  48. package/dist-cjs/lib/exports/getSvgJsx.js.map +2 -2
  49. package/dist-cjs/lib/hooks/useCanvasEvents.js +31 -25
  50. package/dist-cjs/lib/hooks/useCanvasEvents.js.map +2 -2
  51. package/dist-cjs/lib/hooks/useEditor.js +1 -4
  52. package/dist-cjs/lib/hooks/useEditor.js.map +2 -2
  53. package/dist-cjs/lib/hooks/useEditorComponents.js +2 -0
  54. package/dist-cjs/lib/hooks/useEditorComponents.js.map +2 -2
  55. package/dist-cjs/lib/hooks/usePassThroughWheelEvents.js +4 -1
  56. package/dist-cjs/lib/hooks/usePassThroughWheelEvents.js.map +2 -2
  57. package/dist-cjs/lib/{utils/nearestMultiple.js → hooks/useStateAttribute.js} +15 -14
  58. package/dist-cjs/lib/hooks/useStateAttribute.js.map +7 -0
  59. package/dist-cjs/lib/license/Watermark.js +8 -8
  60. package/dist-cjs/lib/license/Watermark.js.map +2 -2
  61. package/dist-cjs/lib/options.js +7 -0
  62. package/dist-cjs/lib/options.js.map +2 -2
  63. package/dist-cjs/lib/primitives/Box.js +3 -0
  64. package/dist-cjs/lib/primitives/Box.js.map +2 -2
  65. package/dist-cjs/lib/primitives/geometry/Arc2d.js +1 -1
  66. package/dist-cjs/lib/primitives/geometry/Arc2d.js.map +2 -2
  67. package/dist-cjs/lib/primitives/geometry/Circle2d.js +1 -1
  68. package/dist-cjs/lib/primitives/geometry/Circle2d.js.map +2 -2
  69. package/dist-cjs/lib/primitives/geometry/CubicBezier2d.js +3 -1
  70. package/dist-cjs/lib/primitives/geometry/CubicBezier2d.js.map +2 -2
  71. package/dist-cjs/lib/primitives/geometry/Ellipse2d.js +1 -1
  72. package/dist-cjs/lib/primitives/geometry/Ellipse2d.js.map +2 -2
  73. package/dist-cjs/lib/primitives/geometry/geometry-constants.js +2 -2
  74. package/dist-cjs/lib/primitives/geometry/geometry-constants.js.map +2 -2
  75. package/dist-cjs/lib/primitives/intersect.js +4 -4
  76. package/dist-cjs/lib/primitives/intersect.js.map +2 -2
  77. package/dist-cjs/lib/primitives/utils.js +4 -0
  78. package/dist-cjs/lib/primitives/utils.js.map +2 -2
  79. package/dist-cjs/lib/utils/EditorAtom.js +45 -0
  80. package/dist-cjs/lib/utils/EditorAtom.js.map +7 -0
  81. package/dist-cjs/lib/utils/sync/TLLocalSyncClient.js +0 -1
  82. package/dist-cjs/lib/utils/sync/TLLocalSyncClient.js.map +2 -2
  83. package/dist-cjs/version.js +3 -3
  84. package/dist-cjs/version.js.map +1 -1
  85. package/dist-esm/index.d.mts +243 -16
  86. package/dist-esm/index.mjs +16 -2
  87. package/dist-esm/index.mjs.map +2 -2
  88. package/dist-esm/lib/TldrawEditor.mjs +8 -2
  89. package/dist-esm/lib/TldrawEditor.mjs.map +2 -2
  90. package/dist-esm/lib/components/MenuClickCapture.mjs +0 -5
  91. package/dist-esm/lib/components/MenuClickCapture.mjs.map +2 -2
  92. package/dist-esm/lib/components/SVGContainer.mjs +1 -1
  93. package/dist-esm/lib/components/SVGContainer.mjs.map +2 -2
  94. package/dist-esm/lib/components/Shape.mjs +11 -36
  95. package/dist-esm/lib/components/Shape.mjs.map +2 -2
  96. package/dist-esm/lib/components/default-components/DefaultBrush.mjs +1 -1
  97. package/dist-esm/lib/components/default-components/DefaultBrush.mjs.map +2 -2
  98. package/dist-esm/lib/components/default-components/DefaultCanvas.mjs +5 -24
  99. package/dist-esm/lib/components/default-components/DefaultCanvas.mjs.map +2 -2
  100. package/dist-esm/lib/components/default-components/DefaultCollaboratorHint.mjs +2 -2
  101. package/dist-esm/lib/components/default-components/DefaultCollaboratorHint.mjs.map +2 -2
  102. package/dist-esm/lib/components/default-components/DefaultCursor.mjs +1 -1
  103. package/dist-esm/lib/components/default-components/DefaultCursor.mjs.map +2 -2
  104. package/dist-esm/lib/components/default-components/DefaultErrorFallback.mjs +1 -1
  105. package/dist-esm/lib/components/default-components/DefaultErrorFallback.mjs.map +2 -2
  106. package/dist-esm/lib/components/default-components/DefaultGrid.mjs +1 -1
  107. package/dist-esm/lib/components/default-components/DefaultGrid.mjs.map +2 -2
  108. package/dist-esm/lib/components/default-components/DefaultHandles.mjs +1 -1
  109. package/dist-esm/lib/components/default-components/DefaultHandles.mjs.map +2 -2
  110. package/dist-esm/lib/components/default-components/DefaultScribble.mjs +1 -1
  111. package/dist-esm/lib/components/default-components/DefaultScribble.mjs.map +2 -2
  112. package/dist-esm/lib/components/default-components/DefaultShapeIndicator.mjs +9 -1
  113. package/dist-esm/lib/components/default-components/DefaultShapeIndicator.mjs.map +2 -2
  114. package/dist-esm/lib/components/default-components/DefaultShapeWrapper.mjs +23 -0
  115. package/dist-esm/lib/components/default-components/DefaultShapeWrapper.mjs.map +7 -0
  116. package/dist-esm/lib/components/default-components/DefaultSnapIndictor.mjs +1 -1
  117. package/dist-esm/lib/components/default-components/DefaultSnapIndictor.mjs.map +2 -2
  118. package/dist-esm/lib/components/default-components/DefaultSpinner.mjs +17 -15
  119. package/dist-esm/lib/components/default-components/DefaultSpinner.mjs.map +2 -2
  120. package/dist-esm/lib/config/TLUserPreferences.mjs +15 -3
  121. package/dist-esm/lib/config/TLUserPreferences.mjs.map +2 -2
  122. package/dist-esm/lib/editor/Editor.mjs +151 -67
  123. package/dist-esm/lib/editor/Editor.mjs.map +2 -2
  124. package/dist-esm/lib/editor/managers/UserPreferencesManager/UserPreferencesManager.mjs +14 -4
  125. package/dist-esm/lib/editor/managers/UserPreferencesManager/UserPreferencesManager.mjs.map +2 -2
  126. package/dist-esm/lib/editor/shapes/ShapeUtil.mjs +13 -0
  127. package/dist-esm/lib/editor/shapes/ShapeUtil.mjs.map +2 -2
  128. package/dist-esm/lib/editor/tools/StateNode.mjs +20 -1
  129. package/dist-esm/lib/editor/tools/StateNode.mjs.map +2 -2
  130. package/dist-esm/lib/exports/getSvgJsx.mjs +36 -16
  131. package/dist-esm/lib/exports/getSvgJsx.mjs.map +2 -2
  132. package/dist-esm/lib/hooks/useCanvasEvents.mjs +32 -26
  133. package/dist-esm/lib/hooks/useCanvasEvents.mjs.map +2 -2
  134. package/dist-esm/lib/hooks/useEditor.mjs +1 -4
  135. package/dist-esm/lib/hooks/useEditor.mjs.map +2 -2
  136. package/dist-esm/lib/hooks/useEditorComponents.mjs +4 -0
  137. package/dist-esm/lib/hooks/useEditorComponents.mjs.map +2 -2
  138. package/dist-esm/lib/hooks/usePassThroughWheelEvents.mjs +4 -1
  139. package/dist-esm/lib/hooks/usePassThroughWheelEvents.mjs.map +2 -2
  140. package/dist-esm/lib/hooks/useStateAttribute.mjs +15 -0
  141. package/dist-esm/lib/hooks/useStateAttribute.mjs.map +7 -0
  142. package/dist-esm/lib/license/Watermark.mjs +8 -8
  143. package/dist-esm/lib/license/Watermark.mjs.map +2 -2
  144. package/dist-esm/lib/options.mjs +7 -0
  145. package/dist-esm/lib/options.mjs.map +2 -2
  146. package/dist-esm/lib/primitives/Box.mjs +4 -1
  147. package/dist-esm/lib/primitives/Box.mjs.map +2 -2
  148. package/dist-esm/lib/primitives/geometry/Arc2d.mjs +2 -2
  149. package/dist-esm/lib/primitives/geometry/Arc2d.mjs.map +2 -2
  150. package/dist-esm/lib/primitives/geometry/Circle2d.mjs +2 -2
  151. package/dist-esm/lib/primitives/geometry/Circle2d.mjs.map +2 -2
  152. package/dist-esm/lib/primitives/geometry/CubicBezier2d.mjs +3 -1
  153. package/dist-esm/lib/primitives/geometry/CubicBezier2d.mjs.map +2 -2
  154. package/dist-esm/lib/primitives/geometry/Ellipse2d.mjs +2 -2
  155. package/dist-esm/lib/primitives/geometry/Ellipse2d.mjs.map +2 -2
  156. package/dist-esm/lib/primitives/geometry/geometry-constants.mjs +2 -2
  157. package/dist-esm/lib/primitives/geometry/geometry-constants.mjs.map +2 -2
  158. package/dist-esm/lib/primitives/intersect.mjs +5 -5
  159. package/dist-esm/lib/primitives/intersect.mjs.map +2 -2
  160. package/dist-esm/lib/primitives/utils.mjs +4 -0
  161. package/dist-esm/lib/primitives/utils.mjs.map +2 -2
  162. package/dist-esm/lib/utils/EditorAtom.mjs +25 -0
  163. package/dist-esm/lib/utils/EditorAtom.mjs.map +7 -0
  164. package/dist-esm/lib/utils/sync/TLLocalSyncClient.mjs +0 -1
  165. package/dist-esm/lib/utils/sync/TLLocalSyncClient.mjs.map +2 -2
  166. package/dist-esm/version.mjs +3 -3
  167. package/dist-esm/version.mjs.map +1 -1
  168. package/editor.css +320 -313
  169. package/package.json +16 -38
  170. package/src/index.ts +15 -1
  171. package/src/lib/TldrawEditor.tsx +13 -6
  172. package/src/lib/components/MenuClickCapture.tsx +0 -8
  173. package/src/lib/components/SVGContainer.tsx +1 -1
  174. package/src/lib/components/Shape.tsx +12 -33
  175. package/src/lib/components/default-components/DefaultBrush.tsx +1 -1
  176. package/src/lib/components/default-components/DefaultCanvas.tsx +6 -23
  177. package/src/lib/components/default-components/DefaultCollaboratorHint.tsx +2 -2
  178. package/src/lib/components/default-components/DefaultCursor.tsx +1 -1
  179. package/src/lib/components/default-components/DefaultErrorFallback.tsx +1 -1
  180. package/src/lib/components/default-components/DefaultGrid.tsx +1 -1
  181. package/src/lib/components/default-components/DefaultHandles.tsx +5 -1
  182. package/src/lib/components/default-components/DefaultScribble.tsx +1 -1
  183. package/src/lib/components/default-components/DefaultShapeIndicator.tsx +6 -2
  184. package/src/lib/components/default-components/DefaultShapeWrapper.tsx +35 -0
  185. package/src/lib/components/default-components/DefaultSnapIndictor.tsx +1 -1
  186. package/src/lib/components/default-components/DefaultSpinner.tsx +12 -12
  187. package/src/lib/config/TLUserPreferences.ts +15 -1
  188. package/src/lib/editor/Editor.test.ts +416 -8
  189. package/src/lib/editor/Editor.ts +195 -92
  190. package/src/lib/editor/managers/ClickManager/ClickManager.test.ts +15 -14
  191. package/src/lib/editor/managers/EdgeScrollManager/EdgeScrollManager.test.ts +16 -15
  192. package/src/lib/editor/managers/FocusManager/FocusManager.test.ts +49 -48
  193. package/src/lib/editor/managers/FontManager/FontManager.test.ts +24 -23
  194. package/src/lib/editor/managers/HistoryManager/HistoryManager.test.ts +7 -6
  195. package/src/lib/editor/managers/ScribbleManager/ScribbleManager.test.ts +12 -11
  196. package/src/lib/editor/managers/SnapManager/SnapManager.test.ts +57 -50
  197. package/src/lib/editor/managers/TextManager/TextManager.test.ts +51 -26
  198. package/src/lib/editor/managers/TickManager/TickManager.test.ts +14 -13
  199. package/src/lib/editor/managers/UserPreferencesManager/UserPreferencesManager.test.ts +55 -26
  200. package/src/lib/editor/managers/UserPreferencesManager/UserPreferencesManager.ts +14 -1
  201. package/src/lib/editor/shapes/ShapeUtil.ts +71 -0
  202. package/src/lib/editor/tools/StateNode.test.ts +285 -0
  203. package/src/lib/editor/tools/StateNode.ts +27 -1
  204. package/src/lib/editor/types/misc-types.ts +73 -1
  205. package/src/lib/exports/getSvgJsx.test.ts +868 -0
  206. package/src/lib/exports/getSvgJsx.tsx +78 -21
  207. package/src/lib/hooks/useCanvasEvents.ts +45 -38
  208. package/src/lib/hooks/useEditor.tsx +6 -5
  209. package/src/lib/hooks/useEditorComponents.tsx +8 -2
  210. package/src/lib/hooks/usePassThroughWheelEvents.ts +6 -1
  211. package/src/lib/hooks/useStateAttribute.ts +15 -0
  212. package/src/lib/license/LicenseManager.test.ts +3 -1
  213. package/src/lib/license/Watermark.test.tsx +2 -1
  214. package/src/lib/license/Watermark.tsx +8 -8
  215. package/src/lib/options.ts +8 -0
  216. package/src/lib/primitives/Box.test.ts +126 -0
  217. package/src/lib/primitives/Box.ts +10 -1
  218. package/src/lib/primitives/geometry/Arc2d.ts +2 -2
  219. package/src/lib/primitives/geometry/Circle2d.ts +2 -2
  220. package/src/lib/primitives/geometry/CubicBezier2d.ts +4 -1
  221. package/src/lib/primitives/geometry/Ellipse2d.ts +2 -2
  222. package/src/lib/primitives/geometry/geometry-constants.ts +2 -1
  223. package/src/lib/primitives/intersect.test.ts +946 -0
  224. package/src/lib/primitives/intersect.ts +12 -5
  225. package/src/lib/primitives/utils.ts +11 -0
  226. package/src/lib/utils/EditorAtom.ts +37 -0
  227. package/src/lib/utils/sync/LocalIndexedDb.test.ts +2 -1
  228. package/src/lib/utils/sync/TLLocalSyncClient.test.ts +15 -15
  229. package/src/lib/utils/sync/TLLocalSyncClient.ts +0 -1
  230. package/src/version.ts +3 -3
  231. package/dist-cjs/lib/utils/nearestMultiple.js.map +0 -7
  232. package/dist-esm/lib/utils/nearestMultiple.mjs +0 -14
  233. package/dist-esm/lib/utils/nearestMultiple.mjs.map +0 -7
  234. package/src/lib/test/currentToolIdMask.test.ts +0 -49
  235. package/src/lib/utils/nearestMultiple.ts +0 -13
@@ -4,9 +4,10 @@ import { ComponentType } from 'react';
4
4
  import { Computed } from '@tldraw/state';
5
5
  import { Dispatch } from 'react';
6
6
  import { Editor as Editor_2 } from '@tiptap/core';
7
- import { EditorProviderProps } from '@tiptap/react';
7
+ import { EditorProviderProps as EditorProviderProps_2 } from '@tiptap/react';
8
8
  import EventEmitter from 'eventemitter3';
9
9
  import { ExoticComponent } from 'react';
10
+ import { ForwardRefExoticComponent } from 'react';
10
11
  import { HistoryEntry } from '@tldraw/store';
11
12
  import { IndexKey } from '@tldraw/utils';
12
13
  import { JsonObject } from '@tldraw/utils';
@@ -23,6 +24,7 @@ import { ReactElement } from 'react';
23
24
  import { ReactNode } from 'react';
24
25
  import { RecordProps } from '@tldraw/tlschema';
25
26
  import { RecordsDiff } from '@tldraw/store';
27
+ import { RefAttributes } from 'react';
26
28
  import { RefObject } from 'react';
27
29
  import { SerializedSchema } from '@tldraw/store';
28
30
  import { SerializedStore } from '@tldraw/store';
@@ -508,6 +510,7 @@ export declare class Box {
508
510
  static ExpandBy(A: Box, n: number): Box;
509
511
  static Collides(A: Box, B: Box): boolean;
510
512
  static Contains(A: Box, B: Box): boolean;
513
+ static ContainsApproximately(A: Box, B: Box, precision?: number): boolean;
511
514
  static Includes(A: Box, B: Box): boolean;
512
515
  static ContainsPoint(A: Box, B: VecLike, margin?: number): boolean;
513
516
  static Common(boxes: Box[]): Box;
@@ -725,10 +728,12 @@ export declare class CubicBezier2d extends Polyline2d {
725
728
  private _b;
726
729
  private _c;
727
730
  private _d;
731
+ private _resolution;
728
732
  constructor(config: Omit<Geometry2dOptions, 'isClosed' | 'isFilled'> & {
729
733
  cp1: Vec;
730
734
  cp2: Vec;
731
735
  end: Vec;
736
+ resolution?: number;
732
737
  start: Vec;
733
738
  });
734
739
  getVertices(): Vec[];
@@ -815,11 +820,14 @@ export declare const DefaultShapeIndicator: NamedExoticComponent<TLShapeIndicato
815
820
  /** @public @react */
816
821
  export declare const DefaultShapeIndicators: NamedExoticComponent<TLShapeIndicatorsProps>;
817
822
 
823
+ /** @public @react */
824
+ export declare const DefaultShapeWrapper: ForwardRefExoticComponent<TLShapeWrapperProps & RefAttributes<HTMLDivElement>>;
825
+
818
826
  /** @public @react */
819
827
  export declare function DefaultSnapIndicator({ className, line, zoom }: TLSnapIndicatorProps): JSX_2.Element;
820
828
 
821
829
  /** @public @react */
822
- export declare function DefaultSpinner(): JSX_2.Element;
830
+ export declare function DefaultSpinner(props: React.SVGProps<SVGSVGElement>): JSX_2.Element;
823
831
 
824
832
  /** @public @react */
825
833
  export declare const DefaultSvgDefs: () => null;
@@ -882,11 +890,15 @@ export declare const defaultTldrawOptions: {
882
890
  readonly nonce: undefined;
883
891
  readonly temporaryAssetPreviewLifetimeMs: 180000;
884
892
  readonly textShadowLod: 0.35;
893
+ readonly tooltipDelayMs: 700;
894
+ readonly uiCoarseDragDistanceSquared: 625;
895
+ readonly uiDragDistanceSquared: 16;
885
896
  };
886
897
 
887
898
  /** @public */
888
899
  export declare const defaultUserPreferences: Readonly<{
889
900
  animationSpeed: 0 | 1;
901
+ areKeyboardShortcutsEnabled: true;
890
902
  color: "#02B1CC" | "#11B3A3" | "#39B178" | "#55B467" | "#7B66DC" | "#9D5BD2" | "#BD54C6" | "#E34BA9" | "#EC5E41" | "#F04F88" | "#F2555A" | "#FF802B";
891
903
  colorScheme: "light";
892
904
  edgeScrollSpeed: 1;
@@ -896,6 +908,7 @@ export declare const defaultUserPreferences: Readonly<{
896
908
  isWrapMode: false;
897
909
  locale: "ar" | "bn" | "ca" | "cs" | "da" | "de" | "el" | "en" | "es" | "fa" | "fi" | "fr" | "gl" | "gu-in" | "he" | "hi-in" | "hr" | "hu" | "id" | "it" | "ja" | "km-kh" | "kn" | "ko-kr" | "ml" | "mr" | "ms" | "ne" | "nl" | "no" | "pa" | "pl" | "pt-br" | "pt-pt" | "ro" | "ru" | "sl" | "so" | "sv" | "ta" | "te" | "th" | "tl" | "tr" | "uk" | "ur" | "vi" | "zh-cn" | "zh-tw";
898
910
  name: "";
911
+ showUiLabels: false;
899
912
  }>;
900
913
 
901
914
  /**
@@ -1552,7 +1565,9 @@ export declare class Editor extends EventEmitter<TLEventMap> {
1552
1565
  */
1553
1566
  deselect(...shapes: TLShape[] | TLShapeId[]): this;
1554
1567
  /**
1555
- * Select all direct children of the current page.
1568
+ * Select all shapes. If the user has selected shapes that share a parent,
1569
+ * select all shapes within that parent. If the user has not selected any shapes,
1570
+ * or if the shapes shapes are only on select all shapes on the current page.
1556
1571
  *
1557
1572
  * @example
1558
1573
  * ```ts
@@ -1586,7 +1601,7 @@ export declare class Editor extends EventEmitter<TLEventMap> {
1586
1601
  *
1587
1602
  * @public
1588
1603
  */
1589
- getNearestAdjacentShape(currentShapeId: TLShapeId, direction: 'down' | 'left' | 'right' | 'up'): TLShapeId;
1604
+ getNearestAdjacentShape(shapes: TLShape[], currentShapeId: TLShapeId, direction: 'down' | 'left' | 'right' | 'up'): TLShapeId;
1590
1605
  selectParentShape(): void;
1591
1606
  selectFirstChildShape(): void;
1592
1607
  private _selectShapesAndZoom;
@@ -2680,15 +2695,7 @@ export declare class Editor extends EventEmitter<TLEventMap> {
2680
2695
  *
2681
2696
  * @returns The shape at the given point, or undefined if there is no shape at the point.
2682
2697
  */
2683
- getShapeAtPoint(point: VecLike, opts?: {
2684
- filter?(shape: TLShape): boolean;
2685
- hitFrameInside?: boolean;
2686
- hitInside?: boolean;
2687
- hitLabels?: boolean;
2688
- hitLocked?: boolean;
2689
- margin?: number;
2690
- renderingOnly?: boolean;
2691
- }): TLShape | undefined;
2698
+ getShapeAtPoint(point: VecLike, opts?: TLGetShapeAtPointOptions): TLShape | undefined;
2692
2699
  /**
2693
2700
  * Get the shapes, if any, at a given page point.
2694
2701
  *
@@ -3702,6 +3709,20 @@ export declare class Editor extends EventEmitter<TLEventMap> {
3702
3709
  height: number;
3703
3710
  width: number;
3704
3711
  }>;
3712
+ /**
3713
+ * Get an exported image of the given shapes as a data URL.
3714
+ *
3715
+ * @param shapes - The shapes (or shape ids) to export.
3716
+ * @param opts - Options for the export.
3717
+ *
3718
+ * @returns A data URL of the image.
3719
+ * @public
3720
+ */
3721
+ toImageDataUrl(shapes: TLShape[] | TLShapeId[], opts?: TLImageExportOptions): Promise<{
3722
+ height: number;
3723
+ url: string;
3724
+ width: number;
3725
+ }>;
3705
3726
  /**
3706
3727
  * The app's current input state.
3707
3728
  *
@@ -3788,6 +3809,21 @@ export declare class Editor extends EventEmitter<TLEventMap> {
3788
3809
  * @public
3789
3810
  */
3790
3811
  complete(): this;
3812
+ /**
3813
+ * Dispatch a pointer move event in the current position of the pointer. This is useful when
3814
+ * external circumstances have changed (e.g. the camera moved or a shape was moved) and you want
3815
+ * the current interaction to respond to that change.
3816
+ *
3817
+ * @example
3818
+ * ```ts
3819
+ * editor.updatePointer()
3820
+ * ```
3821
+ *
3822
+ * @param options - The options for updating the pointer.
3823
+ * @returns The editor instance.
3824
+ * @public
3825
+ */
3826
+ updatePointer(options?: TLUpdatePointerOptions): this;
3791
3827
  /**
3792
3828
  * Puts the editor into focused mode.
3793
3829
  *
@@ -4011,9 +4047,38 @@ export declare class Editor extends EventEmitter<TLEventMap> {
4011
4047
  /* Excluded from this release type: maybeTrackPerformance */
4012
4048
  }
4013
4049
 
4050
+ /**
4051
+ * An Atom that is scoped to the lifetime of an Editor.
4052
+ *
4053
+ * This is useful for storing UI state for tldraw applications. Keeping state scoped to an editor
4054
+ * instead of stored in a global atom can prevent issues with state being shared between editors
4055
+ * when navigating between pages, or when multiple editor instances are used on the same page.
4056
+ *
4057
+ * @public
4058
+ */
4059
+ export declare class EditorAtom<T> {
4060
+ private name;
4061
+ private getInitialState;
4062
+ private states;
4063
+ constructor(name: string, getInitialState: (editor: Editor) => T);
4064
+ getAtom(editor: Editor): Atom<T>;
4065
+ get(editor: Editor): T;
4066
+ update(editor: Editor, update: (state: T) => T): T;
4067
+ set(editor: Editor, state: T): T;
4068
+ }
4069
+
4014
4070
  /** @public */
4015
4071
  export declare const EditorContext: React_3.Context<Editor | null>;
4016
4072
 
4073
+ /** @public @react */
4074
+ export declare function EditorProvider({ editor, children }: EditorProviderProps): JSX_2.Element;
4075
+
4076
+ /** @public */
4077
+ export declare interface EditorProviderProps {
4078
+ editor: Editor;
4079
+ children: React_3.ReactNode;
4080
+ }
4081
+
4017
4082
  /** @public */
4018
4083
  export declare class Ellipse2d extends Geometry2d {
4019
4084
  config: Omit<Geometry2dOptions, 'isClosed'> & {
@@ -4308,6 +4373,8 @@ export declare function getSvgPathFromPoints(points: VecLike[], closed?: boolean
4308
4373
  /** @public */
4309
4374
  export declare function getUserPreferences(): TLUserPreferences;
4310
4375
 
4376
+ /* Excluded from this release type: getVerticesCountForArcLength */
4377
+
4311
4378
  /** @public */
4312
4379
  export declare class Group2d extends Geometry2d {
4313
4380
  children: Geometry2d[];
@@ -4507,7 +4574,7 @@ export declare function intersectLineSegmentCircle(a1: VecLike, a2: VecLike, c:
4507
4574
  * @param b2 - The second segment's second point.
4508
4575
  * @public
4509
4576
  */
4510
- export declare function intersectLineSegmentLineSegment(a1: VecLike, a2: VecLike, b1: VecLike, b2: VecLike): null | Vec;
4577
+ export declare function intersectLineSegmentLineSegment(a1: VecLike, a2: VecLike, b1: VecLike, b2: VecLike, precision?: number): null | Vec;
4511
4578
 
4512
4579
  /**
4513
4580
  * Find the intersections between a line segment and a closed polygon.
@@ -5213,6 +5280,17 @@ export declare abstract class ShapeUtil<Shape extends TLUnknownShape = TLUnknown
5213
5280
  * @public
5214
5281
  */
5215
5282
  isAspectRatioLocked(_shape: Shape): boolean;
5283
+ /**
5284
+ * By default, the bounds of an image export are the bounds of all the shapes it contains, plus
5285
+ * some padding. If an export includes a shape where `isExportBoundsContainer` is true, then the
5286
+ * padding is skipped _if the bounds of that shape contains all the other shapes_. This is
5287
+ * useful in cases like annotating on top of an image, where you usually want to avoid extra
5288
+ * padding around the image if you don't need it.
5289
+ *
5290
+ * @param _shape - The shape to check
5291
+ * @returns True if this shape should be treated as an export bounds container
5292
+ */
5293
+ isExportBoundsContainer(_shape: Shape): boolean;
5216
5294
  /* Excluded from this release type: backgroundComponent */
5217
5295
  /**
5218
5296
  * Get the interpolated props for an animating shape. This is an optional method.
@@ -5402,6 +5480,14 @@ export declare abstract class ShapeUtil<Shape extends TLUnknownShape = TLUnknown
5402
5480
  * @public
5403
5481
  */
5404
5482
  onResizeEnd?(initial: Shape, current: Shape): TLShapePartial<Shape> | void;
5483
+ /**
5484
+ * A callback called when a shape resize is cancelled.
5485
+ *
5486
+ * @param initial - The shape at the start of the resize.
5487
+ * @param current - The current shape.
5488
+ * @public
5489
+ */
5490
+ onResizeCancel?(initial: Shape, current: Shape): void;
5405
5491
  /**
5406
5492
  * A callback called when a shape starts being translated.
5407
5493
  *
@@ -5428,6 +5514,23 @@ export declare abstract class ShapeUtil<Shape extends TLUnknownShape = TLUnknown
5428
5514
  * @public
5429
5515
  */
5430
5516
  onTranslateEnd?(initial: Shape, current: Shape): TLShapePartial<Shape> | void;
5517
+ /**
5518
+ * A callback called when a shape translation is cancelled.
5519
+ *
5520
+ * @param initial - The shape at the start of the translation.
5521
+ * @param current - The current shape.
5522
+ * @public
5523
+ */
5524
+ onTranslateCancel?(initial: Shape, current: Shape): void;
5525
+ /**
5526
+ * A callback called when a shape's handle starts being dragged.
5527
+ *
5528
+ * @param shape - The shape.
5529
+ * @param info - An object containing the handle and whether the handle is 'precise' or not.
5530
+ * @returns A change to apply to the shape, or void.
5531
+ * @public
5532
+ */
5533
+ onHandleDragStart?(shape: Shape, info: TLHandleDragInfo<Shape>): TLShapePartial<Shape> | void;
5431
5534
  /**
5432
5535
  * A callback called when a shape's handle changes.
5433
5536
  *
@@ -5437,6 +5540,23 @@ export declare abstract class ShapeUtil<Shape extends TLUnknownShape = TLUnknown
5437
5540
  * @public
5438
5541
  */
5439
5542
  onHandleDrag?(shape: Shape, info: TLHandleDragInfo<Shape>): TLShapePartial<Shape> | void;
5543
+ /**
5544
+ * A callback called when a shape's handle finishes being dragged.
5545
+ *
5546
+ * @param current - The current shape.
5547
+ * @param info - An object containing the handle and whether the handle is 'precise' or not.
5548
+ * @returns A change to apply to the shape, or void.
5549
+ * @public
5550
+ */
5551
+ onHandleDragEnd?(current: Shape, info: TLHandleDragInfo<Shape>): TLShapePartial<Shape> | void;
5552
+ /**
5553
+ * A callback called when a shape's handle drag is cancelled.
5554
+ *
5555
+ * @param current - The current shape.
5556
+ * @param info - An object containing the handle and whether the handle is 'precise' or not.
5557
+ * @public
5558
+ */
5559
+ onHandleDragCancel?(current: Shape, info: TLHandleDragInfo<Shape>): void;
5440
5560
  /**
5441
5561
  * A callback called when a shape starts being rotated.
5442
5562
  *
@@ -5463,6 +5583,14 @@ export declare abstract class ShapeUtil<Shape extends TLUnknownShape = TLUnknown
5463
5583
  * @public
5464
5584
  */
5465
5585
  onRotateEnd?(initial: Shape, current: Shape): TLShapePartial<Shape> | void;
5586
+ /**
5587
+ * A callback called when a shape rotation is cancelled.
5588
+ *
5589
+ * @param initial - The shape at the start of the rotation.
5590
+ * @param current - The current shape.
5591
+ * @public
5592
+ */
5593
+ onRotateCancel?(initial: Shape, current: Shape): void;
5466
5594
  /* Excluded from this release type: onBindingChange */
5467
5595
  /**
5468
5596
  * A callback called when a shape's children change.
@@ -5691,6 +5819,12 @@ export declare abstract class StateNode implements Partial<TLEventHandlers> {
5691
5819
  _currentToolIdMask: Atom<string | undefined, unknown>;
5692
5820
  getCurrentToolIdMask(): string | undefined;
5693
5821
  setCurrentToolIdMask(id: string | undefined): void;
5822
+ /**
5823
+ * Add a child node to this state node.
5824
+ *
5825
+ * @public
5826
+ */
5827
+ addChild(childConstructor: TLStateNodeConstructor): this;
5694
5828
  onWheel?(info: TLWheelEventInfo): void;
5695
5829
  onPointerDown?(info: TLPointerEventInfo): void;
5696
5830
  onPointerMove?(info: TLPointerEventInfo): void;
@@ -6316,6 +6450,8 @@ export declare interface TldrawOptions {
6316
6450
  readonly multiClickDurationMs: number;
6317
6451
  readonly coarseDragDistanceSquared: number;
6318
6452
  readonly dragDistanceSquared: number;
6453
+ readonly uiDragDistanceSquared: number;
6454
+ readonly uiCoarseDragDistanceSquared: number;
6319
6455
  readonly defaultSvgPadding: number;
6320
6456
  readonly cameraSlideFriction: number;
6321
6457
  readonly gridSteps: readonly {
@@ -6342,6 +6478,7 @@ export declare interface TldrawOptions {
6342
6478
  readonly flattenImageBoundsPadding: number;
6343
6479
  readonly laserDelayMs: number;
6344
6480
  readonly maxExportDelayMs: number;
6481
+ readonly tooltipDelayMs: number;
6345
6482
  /**
6346
6483
  * How long should previews created by {@link Editor.createTemporaryAssetPreview} last before
6347
6484
  * they expire? Defaults to 3 minutes.
@@ -6407,8 +6544,9 @@ export declare interface TLEditorComponents {
6407
6544
  SelectionForeground?: ComponentType<TLSelectionForegroundProps> | null;
6408
6545
  ShapeIndicator?: ComponentType<TLShapeIndicatorProps> | null;
6409
6546
  ShapeIndicators?: ComponentType | null;
6547
+ ShapeWrapper?: ComponentType<TLShapeWrapperProps & RefAttributes<HTMLDivElement>> | null;
6410
6548
  SnapIndicator?: ComponentType<TLSnapIndicatorProps> | null;
6411
- Spinner?: ComponentType | null;
6549
+ Spinner?: ComponentType<React.SVGProps<SVGSVGElement>> | null;
6412
6550
  SvgDefs?: ComponentType | null;
6413
6551
  ZoomBrush?: ComponentType<TLBrushProps> | null;
6414
6552
  ErrorFallback?: TLErrorFallbackComponent;
@@ -6742,6 +6880,59 @@ export declare interface TLGeometryOpts {
6742
6880
  context?: string;
6743
6881
  }
6744
6882
 
6883
+ /**
6884
+ * Options to {@link Editor.getShapeAtPoint}.
6885
+ *
6886
+ * @public
6887
+ */
6888
+ export declare interface TLGetShapeAtPointOptions {
6889
+ /**
6890
+ * The margin to apply to the shape.
6891
+ * If a number, it will be applied to both the inside and outside of the shape.
6892
+ * If an array, the first element will be applied to the inside of the shape, and the second element will be applied to the outside.
6893
+ *
6894
+ * @example
6895
+ * ```ts
6896
+ * // Get the shape at the center of the screen
6897
+ * const shape = editor.getShapeAtProps({
6898
+ * margin: 10,
6899
+ * })
6900
+ *
6901
+ * // Get the shape at the center of the screen with a 10px inner margin and a 5px outer margin
6902
+ * const shape = editor.getShapeAtProps({
6903
+ * margin: [10, 5],
6904
+ * })
6905
+ * ```
6906
+ */
6907
+ margin?: [number, number] | number;
6908
+ /**
6909
+ * Whether to register hits inside of shapes (beyond the margin), such as the inside of a solid shape.
6910
+ */
6911
+ hitInside?: boolean;
6912
+ /**
6913
+ * Whether to register hits on locked shapes.
6914
+ */
6915
+ hitLocked?: boolean;
6916
+ /**
6917
+ * Whether to register hits on labels.
6918
+ */
6919
+ hitLabels?: boolean;
6920
+ /**
6921
+ * Whether to only return hits on shapes that are currently being rendered.
6922
+ * todo: rename this to hitCulled or hitNotRendering
6923
+ */
6924
+ renderingOnly?: boolean;
6925
+ /**
6926
+ * Whether to register hits on the inside of frame shapes.
6927
+ * todo: rename this to hitInsideFrames
6928
+ */
6929
+ hitFrameInside?: boolean;
6930
+ /**
6931
+ * A filter function to apply to the shapes.
6932
+ */
6933
+ filter?(shape: TLShape): boolean;
6934
+ }
6935
+
6745
6936
  /** @public */
6746
6937
  export declare interface TLGridProps {
6747
6938
  x: number;
@@ -6754,6 +6945,7 @@ export declare interface TLGridProps {
6754
6945
  export declare interface TLHandleDragInfo<T extends TLShape> {
6755
6946
  handle: TLHandle;
6756
6947
  isPrecise: boolean;
6948
+ isCreatingShape: boolean;
6757
6949
  initial?: T | undefined;
6758
6950
  }
6759
6951
 
@@ -7280,6 +7472,16 @@ export declare interface TLShapeUtilConstructor<T extends TLUnknownShape, U exte
7280
7472
  migrations?: LegacyMigrations | MigrationSequence | TLPropsMigrations;
7281
7473
  }
7282
7474
 
7475
+ /** @public */
7476
+ export declare interface TLShapeWrapperProps extends React.HTMLAttributes<HTMLDivElement> {
7477
+ /** The shape being rendered. */
7478
+ shape: TLShape;
7479
+ /** Whether this is the shapes regular, or background component. */
7480
+ isBackground: boolean;
7481
+ /** The shape's rendered component. */
7482
+ children: ReactNode;
7483
+ }
7484
+
7283
7485
  /** @public */
7284
7486
  export declare interface TLSnapIndicatorProps {
7285
7487
  className?: string;
@@ -7429,7 +7631,7 @@ export declare interface TLTextExternalContentSource {
7429
7631
 
7430
7632
  /** @public */
7431
7633
  export declare interface TLTextOptions {
7432
- tipTapConfig?: EditorProviderProps;
7634
+ tipTapConfig?: EditorProviderProps_2;
7433
7635
  addFontsFromNode?: RichTextFontVisitor;
7434
7636
  }
7435
7637
 
@@ -7462,6 +7664,25 @@ export declare interface TLTldrawExternalContentSource {
7462
7664
  data: TLContent;
7463
7665
  }
7464
7666
 
7667
+ /** @public */
7668
+ export declare interface TLUpdatePointerOptions {
7669
+ /** Whether to update the pointer immediately, rather than on the next tick. */
7670
+ immediate?: boolean;
7671
+ /**
7672
+ * The point, in screen-space, to update the pointer to. Defaults to the position of the last
7673
+ * pointer event.
7674
+ */
7675
+ point?: VecLike;
7676
+ pointerId?: number;
7677
+ ctrlKey?: boolean;
7678
+ altKey?: boolean;
7679
+ shiftKey?: boolean;
7680
+ metaKey?: boolean;
7681
+ accelKey?: boolean;
7682
+ isPen?: boolean;
7683
+ button?: number;
7684
+ }
7685
+
7465
7686
  /** @public */
7466
7687
  export declare interface TLUrlExternalAsset {
7467
7688
  type: 'url';
@@ -7491,12 +7712,14 @@ export declare interface TLUserPreferences {
7491
7712
  color?: null | string;
7492
7713
  locale?: null | string;
7493
7714
  animationSpeed?: null | number;
7715
+ areKeyboardShortcutsEnabled?: boolean | null;
7494
7716
  edgeScrollSpeed?: null | number;
7495
7717
  colorScheme?: 'dark' | 'light' | 'system';
7496
7718
  isSnapMode?: boolean | null;
7497
7719
  isWrapMode?: boolean | null;
7498
7720
  isDynamicSizeMode?: boolean | null;
7499
7721
  isPasteAtCursorMode?: boolean | null;
7722
+ showUiLabels?: boolean | null;
7500
7723
  }
7501
7724
 
7502
7725
  /** @public */
@@ -7659,6 +7882,7 @@ export declare class UserPreferencesManager {
7659
7882
  updateUserPreferences(userPreferences: Partial<TLUserPreferences>): void;
7660
7883
  getUserPreferences(): {
7661
7884
  animationSpeed: number;
7885
+ areKeyboardShortcutsEnabled: boolean;
7662
7886
  color: string;
7663
7887
  colorScheme: "dark" | "light" | "system" | undefined;
7664
7888
  id: string;
@@ -7668,6 +7892,7 @@ export declare class UserPreferencesManager {
7668
7892
  isWrapMode: boolean;
7669
7893
  locale: string;
7670
7894
  name: string;
7895
+ showUiLabels: boolean;
7671
7896
  };
7672
7897
  getIsDarkMode(): boolean;
7673
7898
  /**
@@ -7675,6 +7900,7 @@ export declare class UserPreferencesManager {
7675
7900
  */
7676
7901
  getEdgeScrollSpeed(): number;
7677
7902
  getAnimationSpeed(): number;
7903
+ getAreKeyboardShortcutsEnabled(): boolean;
7678
7904
  getId(): string;
7679
7905
  getName(): string;
7680
7906
  getLocale(): string;
@@ -7683,6 +7909,7 @@ export declare class UserPreferencesManager {
7683
7909
  getIsWrapMode(): boolean;
7684
7910
  getIsDynamicResizeMode(): boolean;
7685
7911
  getIsPasteAtCursorMode(): boolean;
7912
+ getShowUiLabels(): boolean;
7686
7913
  }
7687
7914
 
7688
7915
  /** @public */
package/dist-cjs/index.js CHANGED
@@ -46,6 +46,7 @@ __export(index_exports, {
46
46
  DefaultSelectionForeground: () => import_DefaultSelectionForeground.DefaultSelectionForeground,
47
47
  DefaultShapeIndicator: () => import_DefaultShapeIndicator.DefaultShapeIndicator,
48
48
  DefaultShapeIndicators: () => import_DefaultShapeIndicators.DefaultShapeIndicators,
49
+ DefaultShapeWrapper: () => import_DefaultShapeWrapper.DefaultShapeWrapper,
49
50
  DefaultSnapIndicator: () => import_DefaultSnapIndictor.DefaultSnapIndicator,
50
51
  DefaultSpinner: () => import_DefaultSpinner.DefaultSpinner,
51
52
  DefaultSvgDefs: () => import_DefaultSvgDefs.DefaultSvgDefs,
@@ -54,7 +55,9 @@ __export(index_exports, {
54
55
  Edge2d: () => import_Edge2d.Edge2d,
55
56
  EdgeScrollManager: () => import_EdgeScrollManager.EdgeScrollManager,
56
57
  Editor: () => import_Editor.Editor,
58
+ EditorAtom: () => import_EditorAtom.EditorAtom,
57
59
  EditorContext: () => import_useEditor.EditorContext,
60
+ EditorProvider: () => import_useEditor.EditorProvider,
58
61
  Ellipse2d: () => import_Ellipse2d.Ellipse2d,
59
62
  ErrorBoundary: () => import_ErrorBoundary.ErrorBoundary,
60
63
  ErrorScreen: () => import_TldrawEditor.ErrorScreen,
@@ -143,6 +146,7 @@ __export(index_exports, {
143
146
  getSvgAsImage: () => import_getSvgAsImage.getSvgAsImage,
144
147
  getSvgPathFromPoints: () => import_getSvgPathFromPoints.getSvgPathFromPoints,
145
148
  getUserPreferences: () => import_TLUserPreferences.getUserPreferences,
149
+ getVerticesCountForArcLength: () => import_geometry_constants.getVerticesCountForArcLength,
146
150
  hardReset: () => import_hardReset.hardReset,
147
151
  hardResetEditor: () => import_hardResetEditor.hardResetEditor,
148
152
  inlineBase64AssetStore: () => import_createTLStore.inlineBase64AssetStore,
@@ -254,6 +258,7 @@ var import_DefaultSelectionBackground = require("./lib/components/default-compon
254
258
  var import_DefaultSelectionForeground = require("./lib/components/default-components/DefaultSelectionForeground");
255
259
  var import_DefaultShapeIndicator = require("./lib/components/default-components/DefaultShapeIndicator");
256
260
  var import_DefaultShapeIndicators = require("./lib/components/default-components/DefaultShapeIndicators");
261
+ var import_DefaultShapeWrapper = require("./lib/components/default-components/DefaultShapeWrapper");
257
262
  var import_DefaultSnapIndictor = require("./lib/components/default-components/DefaultSnapIndictor");
258
263
  var import_DefaultSpinner = require("./lib/components/default-components/DefaultSpinner");
259
264
  var import_DefaultSvgDefs = require("./lib/components/default-components/DefaultSvgDefs");
@@ -326,6 +331,7 @@ var import_CubicBezier2d = require("./lib/primitives/geometry/CubicBezier2d");
326
331
  var import_CubicSpline2d = require("./lib/primitives/geometry/CubicSpline2d");
327
332
  var import_Edge2d = require("./lib/primitives/geometry/Edge2d");
328
333
  var import_Ellipse2d = require("./lib/primitives/geometry/Ellipse2d");
334
+ var import_geometry_constants = require("./lib/primitives/geometry/geometry-constants");
329
335
  var import_Geometry2d = require("./lib/primitives/geometry/Geometry2d");
330
336
  var import_Group2d = require("./lib/primitives/geometry/Group2d");
331
337
  var import_Point2d = require("./lib/primitives/geometry/Point2d");
@@ -343,6 +349,7 @@ var import_browserCanvasMaxSize = require("./lib/utils/browserCanvasMaxSize");
343
349
  var import_debug_flags = require("./lib/utils/debug-flags");
344
350
  var import_deepLinks = require("./lib/utils/deepLinks");
345
351
  var import_dom = require("./lib/utils/dom");
352
+ var import_EditorAtom = require("./lib/utils/EditorAtom");
346
353
  var import_getIncrementedName = require("./lib/utils/getIncrementedName");
347
354
  var import_getPointerInfo = require("./lib/utils/getPointerInfo");
348
355
  var import_getSvgPathFromPoints = require("./lib/utils/getSvgPathFromPoints");
@@ -364,7 +371,7 @@ function debugEnableLicensing() {
364
371
  }
365
372
  (0, import_utils.registerTldrawLibraryVersion)(
366
373
  "@tldraw/editor",
367
- "3.16.0-internal.a478398270c6",
374
+ "3.16.0-next.15f085081fd5",
368
375
  "cjs"
369
376
  );
370
377
  //# sourceMappingURL=index.js.map