92886e1f40
We got things sliggghhhtly wrong in #1980. That diff was attempting to fix a bug where the text measurement element would refuse to go above the viewport size in safari. This was most obvious in the case where there was no fixed width on a text shape, and that diff fixed that case, but it was also happening when a fixed width text shape was wider than viewport - which wasn't covered by that fix. It turned out that that fix also introduced a bug where shapes would no longer grow along the y-axis - in part because the relationship between `width`, `maxWidth`, and `minWidth` is very confusing. The one-liner fix is to just use `max-content` instead of `fit-content` - that way, the div ignores the size of its container. But I also cleared up the API for text measurement to remove the `width` property entirely in favour of `maxWidth`. I think this makes things much clearer and as far as I can tell doesn't affect anything. Closes #1998 ### Change Type - [x] `patch` — Bug fix ### Test Plan 1. Create an arrow & geo shape with labels, plus a note and text shape 2. Try to break text measurement - overflow the bounds, make very wide text, experiment with fixed/auto-size text, etc. |
||
---|---|---|
.. | ||
e2e | ||
src | ||
package.json | ||
README.md | ||
tsconfig.json | ||
vercel.json | ||
vite.config.ts |