tldraw/packages
Taha 512696c1ab
Fix style panel opening when disabled (#1983)
Closes #1982

When choosing whether to disable the mobile style menu, we now also
check if the select tool is active and whether any shapes have been
selected.

### Change Type

- [x] `patch` — Bug fix
- [ ] `minor` — New feature
- [ ] `major` — Breaking change
- [ ] `dependencies` — Changes to package dependencies[^1]
- [ ] `documentation` — Changes to the documentation only[^2]
- [ ] `tests` — Changes to any test code only[^2]
- [ ] `internal` — Any other changes that don't affect the published
package[^2]
- [ ] I don't know

[^1]: publishes a `patch` release, for devDependencies use `internal`
[^2]: will not publish a new version

### Test Plan

1. On a small screen
2. Choose the select tool
3. Deselect all shapes
4. Click on the disabled style menu button

Expected: Nothing should happen
Actual: The style menu opens

### Release Notes

- When select tool is active, the style menu shouldn't be openable
unless a shape is also selected.

Before/After

<img width="300"
src="https://github.com/tldraw/tldraw/assets/98838967/91ea55c8-0fcc-4f73-b61e-565829a5f25e"
/>
<img width="300"
src="https://github.com/tldraw/tldraw/assets/98838967/ee4070fe-e236-4818-8fb4-43520210102b"
/>

---------

Co-authored-by: Steve Ruiz <steveruizok@gmail.com>
2023-10-02 14:23:51 +00:00
..
assets [feature] Add val town embed (#1777) 2023-07-31 15:44:33 +00:00
editor Sliiiightly darken muted-2 color. (#1981) 2023-10-02 11:48:34 +00:00
state [improvement] More selection logic (#1806) 2023-08-13 15:55:24 +00:00
store Fix shape drag perf (#1932) 2023-09-19 15:29:13 +00:00
tldraw Fix style panel opening when disabled (#1983) 2023-10-02 14:23:51 +00:00
tlschema Fix arrow handle snapping, snapping to text labels, selection of text labels (#1910) 2023-09-18 14:59:27 +00:00
utils move some utils into tldraw/utils (#1750) 2023-07-19 10:50:40 +00:00
validate Add shapes to exports (#1776) 2023-07-28 16:08:59 +00:00