Tldraw/packages/editor/src/lib/app/managers
Steve Ruiz a722e3e6f0
[fix] various text (#1350)
This PR updates tests for the text shape, as well as updating the logic
of `getTextLines`. We now:

- allow leading whitespace
- allow white space to cause line breaks, trim the whitespace off of the
end of the line. Crazy times!
- fix a bug with geo shapes changes width when growY changes

Note that this is not a "full solution" to line breaks that are caused
by whitespace + wrapping. AFAIK this is impossible to fix in SVG-land
without measuring the SVG element in order to collapse whitespace in the
same way that it collapses in HTML layout.

### Change Type

- [x] `patch` — Bug Fix
- [ ] `minor` — New Feature
- [ ] `major` — Breaking Change

- [ ] `dependencies` — Dependency Update (publishes a `patch` release,
for devDependencies use `internal`)

- [ ] `documentation` — Changes to the documentation only (will not
publish a new version)
- [ ] `tests` — Changes to any testing-related code only (will not
publish a new version)
- [ ] `internal` — Any other changes that don't affect the published
package (will not publish a new version)

### Test Plan

- [x] Webdriver tests

### Release Notes

- Allow leading whitespace
2023-05-11 22:15:24 +00:00
..
ActiveAreaManager.ts
CameraManager.ts
ClickManager.test.ts
ClickManager.ts [improvement] dragging start distance on coarse pointer (#1220) 2023-05-05 14:48:49 +00:00
DprManager.ts
DragAndDropManager.ts
HistoryManager.test.ts
HistoryManager.ts [feature] ui events (#1326) 2023-05-11 22:14:58 +00:00
ScribbleManager.ts
SnapManager.ts
Stack.ts
TextManager.ts [fix] various text (#1350) 2023-05-11 22:15:24 +00:00
TickManager.ts