tldraw/apps/examples/e2e/tests
alex e8bc114bf3
Styles API follow-ups (#1636)
tldraw-zero themed follow-ups to the styles API added in #1580.

- Removed style related helpers from `ShapeUtil`
- `editor.css` no longer includes the tldraw default color palette.
Instead, a global `DefaultColorPalette` is defined as part of the color
style. If developers wish to cusomise the colors, they can mutate that
global.
- `ShapeUtil.toSvg` no longer takes font/color. Instead, it takes an
"svg export context" that can be used to add `<defs>` to the exported
SVG element. Converting e.g. fonts to inlined data urls is now the
responsibility of the shapes that use them rather than the Editor.
- `usePattern` is not longer a core part of the editor. Instead,
`ShapeUtil` has a `getCanvasSvgDefs` method for returning react
components representing anything a shape needs included in `<defs>` for
the canvas.
- The shape-specific cleanup logic in `setStyle` has been deleted. It
turned out that none of that logic has been running anyway, and instead
the relevant logic lives in shape `onBeforeChange` callbacks already.

### Change Type
- [x] `minor` — New feature

### Test Plan


- [x] Unit Tests
- [x] End to end tests

### Release Notes
 --

---------

Co-authored-by: Steve Ruiz <steveruizok@gmail.com>
2023-06-24 13:46:04 +00:00
..
export-snapshots.spec.ts-snapshots speed up playwright and add visual regression tests (#1638) 2023-06-23 11:53:04 +00:00
export-snapshots.spec.ts Styles API follow-ups (#1636) 2023-06-24 13:46:04 +00:00
test-camera.spec.ts Add playwright tests (#1484) 2023-05-30 15:28:56 +01:00
test-canvas-events.spec.ts rename app to editor (#1503) 2023-06-02 15:21:45 +00:00
test-clipboard.spec.ts rename app to editor (#1503) 2023-06-02 15:21:45 +00:00
test-kbds.spec.ts Add playwright tests (#1484) 2023-05-30 15:28:56 +01:00
test-routes.spec.ts [refactor] User-facing APIs (#1478) 2023-06-01 15:47:34 +00:00
test-shapes.spec.ts replace console.log with nicelog (#1496) 2023-06-01 18:01:49 +00:00
test-smoke.spec.ts rename app to editor (#1503) 2023-06-02 15:21:45 +00:00
test-text.spec.ts rename app to editor (#1503) 2023-06-02 15:21:45 +00:00