moveable
moveable copied to clipboard
moveable-control-box misplaced when used with SVG foreignObject elements on Safari
Environments
- Framework name: reactjs
- Framework version: 17.0.2
- Moveable Component version: react-moveable 0.45.1
- Testable Address(optional): Code Sandbox
Description
Hi, I need to render html elements inside a svg therefore i used foreignObject element. The moveable-control-box is renderer correctly on Chrome but misplaced on Safari.
This is what i tried to do
<>
<Moveable target={target} draggable={true} resizable={true} />
<svg viewBox="0 0 86 54">
<foreignObject ref={ref} x="10" y="10" width="20" height="20">
<div>Hi</div>
</foreignObject>
</svg>
</>
Below is a screenshot to compare:
Safari
Chrome
I am facing similar issue in Firefox as well
@lizaemran @DatLe1108
croact-moveable0.9.0@moveable/helper0.1.3lit-moveable0.30.0moveable0.53.0preact-moveable0.55.0react-moveable0.56.0svelte-moveable0.45.0vue-moveable2.0.0-beta.87vue3-moveable0.28.0ngx-moveable0.50.0
moveable's new version is released. Check it again.