Commit graph

1288 commits

Author SHA1 Message Date
Steve Ruiz
31a1a8b5ae Fix bug with missing draw shape after undo 2022-01-06 13:36:40 +00:00
Steve Ruiz
deadc70030 fix pointer error 2022-01-06 13:23:45 +00:00
Steve Ruiz
32d96aef94 Merge branch 'main' of https://github.com/tldraw/tldraw 2022-01-06 10:47:36 +00:00
Steve Ruiz
5c33fbd89c bug fixes 2022-01-06 10:45:11 +00:00
Steve Ruiz
24ece6b38a
Update groupShapes.ts (#488) 2022-01-06 07:35:32 +00:00
Steve Ruiz
225f312bd0 Add sponsor 2022-01-06 07:06:05 +00:00
Jesco Wüster
0271ccccf8
Enable panning for all tools (#484)
* Enable panning for DrawTool

* move camera panning logic to TlDrawApp

* fix: disable shape button on keyboard pan

* ensure middle wheel panning returns to idle globally

* prevent flicker during mouseup while spacePanning

* Use boolean flags for force panning

* add middle mouse button

* Fix logic

* Fix toolbar re-selecting

Co-authored-by: Steve Ruiz <steveruizok@gmail.com>
2022-01-05 14:47:07 +00:00
Steve Ruiz
d00d443492
Add shift+click to draw straight lines between points (#478)
* Add shift+click to draw straight lines between points

* Add points to previous shape

* undo/redo fixes

* Fix bug with non-draw shapes

* Update drawHelpers.ts
2022-01-03 09:49:34 +00:00
Steve Ruiz
97ba1505ab
Fix editing bug (#480) 2022-01-03 09:39:27 +00:00
Tony Li
e7a2f5d6d4
added NaN check on pinch event (#476) 2021-12-31 09:42:56 +00:00
Steve Ruiz
bc37947d5e Update lerna.json 2021-12-29 16:38:56 +00:00
Steve Ruiz
acb68c8af9 v1.4.1 2021-12-29 14:15:58 +00:00
Soufiane Ghzal
23ad10d856
Fixed bunch of broken links (#471)
* fixed local links to documentation in README.md

* fixed links to core package
2021-12-29 06:39:08 +00:00
Steve Ruiz
59e5a446c9
Copies over browser-fs-access src :( (#470) 2021-12-28 14:29:55 +00:00
Steve Ruiz
32a5511b3d v1.4.1 2021-12-28 11:50:33 +00:00
Steve Ruiz
f45824a4a0 Update CHANGELOG.md 2021-12-28 11:32:36 +00:00
Steve Ruiz
e9217e0bec Update core readme with more info on assets 2021-12-28 11:28:27 +00:00
Steve Ruiz
d0fd712e5e
[improvement] labels (#467)
* Improve appearance of arrow shape labels, set label text color to match stroke

* fix svg copy fonts for text, labels

* Reduce opacity effect of scaled arrow label, update font in export, adds command+enter to finish text
2021-12-28 11:23:17 +00:00
Steve Ruiz
f57d6bda94 v1.4.0 2021-12-27 20:29:12 +00:00
Steve Ruiz
5a4918ca6b Update CHANGELOG.md 2021-12-27 20:27:14 +00:00
Steve Ruiz
9ff7447208 Update CHANGELOG.md 2021-12-27 20:23:37 +00:00
Steve Ruiz
d7a697647b
[feature] Labels for shapes (#462)
* Adds generic text label

* Clean up text label / text util

* labels for ellipse and triangles

* Add arrow label

* Update filesystem.ts

* Double click bend to edit label, fix mask location

* refactor arrowutil

* fix arrow bindings

* Rename text to label, add labelPoint

* Fix arrow binding, styles on text labels, double click bounds edge to edit label

* Update ArrowSession.ts

* Update StyleMenu.tsx

* set version
2021-12-27 19:21:30 +00:00
Steve Ruiz
e48f0c1794 Update migrate.ts 2021-12-27 18:51:20 +00:00
Steve Ruiz
7c02a6d514 Merge branch 'main' of https://github.com/tldraw/tldraw 2021-12-27 18:50:33 +00:00
Steve Ruiz
d355be10d6 Improve appearance of ellipses/videos, fix bug 2021-12-27 18:49:54 +00:00
Steve Ruiz
d60bb5c6ee
Fix bug where reloading could clear the state (#465)
* Fix bug where reloading could clear the state

* fix test

* Fix image and video positions
2021-12-27 18:44:47 +00:00
Steve Ruiz
d5cd7ed480 bump use-gesture, memoize gesture callbacks 2021-12-27 12:50:18 +00:00
Steve Ruiz
297486bb34 Remove performance modes (for now) 2021-12-27 12:38:30 +00:00
Steve Ruiz
d1fb7d1115 Merge branch 'main' of https://github.com/tldraw/tldraw 2021-12-27 12:32:17 +00:00
Steve Ruiz
e3865e1b1f update changelogs 2021-12-27 12:32:07 +00:00
Steve Ruiz
4aa8547a8e
[improvement] performance modes (#463)
* add performance modes to core, sessions

* Update filesystem.ts

* rename TLPerformance to TLPerformanceMode, fix bugs
2021-12-27 12:30:35 +00:00
Steve Ruiz
fd2befa305 rename refs 2021-12-25 19:39:20 +00:00
Steve Ruiz
dfe2e44c17 v1.3.0 2021-12-25 18:41:47 +00:00
Steve Ruiz
0ed7e55c4c Make core asset types more generic, update docs. 2021-12-25 18:39:50 +00:00
Steve Ruiz
bd09342596 Update changelogs 2021-12-25 18:28:37 +00:00
Faraz Shaikh
1c65c031b2
Add Image and Video shapes (#460)
* Added image and video shapes

* Fixed bugs; Added optional onImageUpload callback

* Added id field to onImageUpload

* Added onImageDelete callback for cleanup

* Added firebase storage to multiplayer for media

* Added firebase storage to multiplayer for media

* Silence unnecessary TS errors

* Fixed bugs; Added tests

* Added tests

* Disable images for multiplayer example

* switch to assets in document, rather than on shapes, fix resize, fix sizes

* bump version, add migration for assets table

* Rename onImageUpload

* Add isPlaying state to video (not complete)

* Revert "Add isPlaying state to video (not complete)"

This reverts commit 3dc2ba703f4194eb7c47524d384dc8392daa18be.

* Adds controls when editing video, sync current time when cloning

* Remove unused tools

* avoid duplication in assets

* Remove unused image styles from style menu

* Fix placement of clone buttons

* Fix flag to hide image assets in multiplayer

* move getSizeFromDataUrl to filesystem

* Update VideoUtil.tsx

* Re-center video after it loads

* Add copy and paste support for assets

* Fix bug in state manager, remove unused assets on load, fix indicators

* Add multiplayer with images example

* Update MultiplayerEditor.tsx

* Add images to copy SVG

* tighten up some code around svg export

* Update TldrawApp.spec.ts

* Update useBoundsHandleEvents.tsx

* Reset image size by double clicking bounds

* fix reset size

Co-authored-by: Steve Ruiz <steveruizok@gmail.com>
2021-12-25 17:06:33 +00:00
Steve Ruiz
2f84abcc1e v1.2.10 2021-12-22 14:33:56 +00:00
Steve Ruiz
b243600a3a Update changelog 2021-12-22 14:11:29 +00:00
Thomas Mathisen
4cf283e84f
Bugfix on useShapeEvents wrong key name (#459)
* onPointShape called instead of onPointerDown

* Update useShapeEvents.tsx

* Bugfix on useShapeEvents wrong key name

Co-authored-by: Steve Ruiz <steveruizok@gmail.com>
2021-12-22 12:56:49 +00:00
Steve Ruiz
9b7414509f v1.2.9 2021-12-22 00:46:58 +00:00
Steve Ruiz
64da0ba691 Update changelogs 2021-12-22 00:46:17 +00:00
Steve Ruiz
e8befe2290 fix leaky ref 2021-12-22 00:40:37 +00:00
Steve Ruiz
4da632d5d8
[improvement] Multiplayer cursors (#458)
* bump versions, improve cursors

* Spline cursors

* Update useCursorAnimation.ts

* Update useCursorAnimation.ts

* Add improved cursors

* Update MultiplayerEditor.tsx

* Update [id].tsx
2021-12-22 00:34:44 +00:00
Steve Ruiz
7c2777966f
[improvement] Multiplayer + cursors (#457)
* bump versions, improve cursors

* Spline cursors
2021-12-22 00:14:38 +00:00
Steve Ruiz
3b220f0afe v1.2.8 2021-12-20 15:20:04 +00:00
Jim Fisher
e55d4779f6
Bugfix: "Copy as SVG" should respect childIndex (#455)
* Bugfix: respect childIndex in Copy as SVG

* Try adding test - but why is the test output an empty svg
2021-12-18 20:49:30 +00:00
Steve Ruiz
58b8968f12
[fix] intersection bug (#452)
* Update TLShapeUtil.tsx

* Add tests

* Update tsconfig.json
2021-12-17 16:29:08 +00:00
Thomas Mathisen
34492f2f01
Bugfix: onPointerDown not called (#451)
* onPointShape called instead of onPointerDown

* Update useShapeEvents.tsx

Co-authored-by: Steve Ruiz <steveruizok@gmail.com>
2021-12-17 16:02:13 +00:00
Jim Fisher
2bc927f68e
Bugfix: 'Copy as SVG' shapes have black fill by default (#449)
* Bugfix: 'Copy as SVG' shapes have black fill by default

* Remove binding hit areas from copied SVG

Co-authored-by: Steve Ruiz <steveruizok@gmail.com>
2021-12-17 15:23:03 +00:00
Milo Hill
1271070798
Fix changing a setting preventing page content from being replaced (#447)
* Fix setting settings preventing UI from updating

* Add tests for replacePageContent
2021-12-15 21:14:40 +00:00