[fix] shape indicator showing when locked shapes are hovered (#1771)

This PR makes it so that locked shapes do not show an indicator when
hovered.

### Change Type

- [x] `patch` — Bug fix

### Test Plan

1. Hover a locked shape
2. Hover a shape, then lock it

### Release Notes

- locked shapes do not show an indicator when hovered
This commit is contained in:
Steve Ruiz 2023-07-27 17:11:08 +01:00 committed by GitHub
parent 1014a71abb
commit eb52eb4e30
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -28,7 +28,8 @@ export const InnerIndicator = ({ editor, id }: { editor: Editor; id: TLShapeId }
const { ShapeIndicatorErrorFallback } = useEditorComponents()
if (!shape.shape) return null
if (!shape.shape || shape.shape.isLocked) return null
return (
<OptionalErrorBoundary
fallback={ShapeIndicatorErrorFallback}