Open gabimor opened 11 months ago
Try the property zoom ? <Moveable zoom={zoom}/>
As @HZZformGD said, use zoom
prop or css
.moveable-control {
width: 14px;
height: 14px;
border-radius: 50%;
border: 2px solid #fff;
box-sizing: border-box;
background: #4af;
background: var(--moveable-color);
margin-top: -7px;
margin-left: -7px;
border: 2px solid #fff;
z-index: 10;
}
Thank you @daybrush but I am aiming at scaling only the blue selection rectangle and control circles, without scaling the actual element will this do the trick ?
Environments
Description
Is there a way to set the value of the
translate: scale()
for themoveable-control
andmoveable-line
elements ? My canvas where I use my moveables is scalable and I want the blue controls and lines to be visible even when zoomed out so my solution is to scale them (i'm using react). is there an Moveable API to affect the theirtransform
css property ? I've notice this happens on the moveable demo (using the InfiniteViewer) when you zoom in and out there the transform property for each moveable-control/line changes, but I can't find how to do that with in React (I can do it usingdocument.querySelectorAll
) but am looking for a more elegant way :)