Can't get disableOnTarget prop working
See original GitHub issueHi @prc5,
Thanks for the awesome open source project 😄 I’m trying to get the disableOnTarget
option working so that a canvas inside of the wrapper is usable. I was hoping that upon clicking inside the canvas the panning would be disabled. I’m using a fabricjs canvas.
<TransformWrapper pan={{
disabledOnTarget: ["canvas_editor"],
}}>
<TransformComponent>
<div className="canvas_editor">
<canvas {...css(styles.templateEditor)} id="template_editor" className="" />
</div>
</TransformComponent>
</TransformWrapper>
Does this look like it should work?
Thanks in advance and cheers!
Kyle
Issue Analytics
- State:
- Created 4 years ago
- Comments:5
Top Results From Across the Web
disableOnTarget not accepted in pan props as docs say #169
in the Pan props elements a useful disableOnTarget is listed but actually not accepted in version 1.6.1.
Read more >Applying z-index to only child component does not work
I tried changing the z-index of box B but it didn't work. I also can't set pointerEvents to none because I need mouse...
Read more >dow-react-zoom-pan-pinch
Props of TransformWrapper ... Pan prop elements ... disableOnTarget, [], array of class names or node tags (div,span...).
Read more >Removing A Stuck Outboard Propeller - YouTube
Your browser can't play this video. Learn more. Switch camera.
Read more >Remove a stuck prop nut with electrical tape - YouTube
Uncertain about what to buy? Check out THE ULTIMATE FPV SHOPPING LIST: https://www.fpvknowitall.com/ultimate-fpv-shopping-listSUPPORT ME ON ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
+1 Facing the same issues. Seems like disableOnTarget is not even on interface.
Got it to work with
where select-area is css class. Also was needed to add
@ts-ignore
forpan
property definition