File tree Expand file tree Collapse file tree 1 file changed +15
-16
lines changed
packages/react-ape/renderer Expand file tree Collapse file tree 1 file changed +15
-16
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,6 @@ const ReactApeComponent = {
34
34
} ) ;
35
35
36
36
const tag = '[CREATE_ELEMENT]' ;
37
-
38
37
if ( type === 'Button' ) {
39
38
const { ctx} = apeContextGlobal ;
40
39
ctx . canvas . addEventListener (
@@ -49,21 +48,21 @@ const ReactApeComponent = {
49
48
* Handling click button event
50
49
* @param {* } event
51
50
*/
52
- const onClick = ( event : SyntheticMouseEvent < HTMLButtonElement > ) => {
53
- const rect = {
54
- x,
55
- y,
56
- height,
57
- width,
58
- } ;
59
- const mousePosition = trackMousePosition ( ctx . canvas , event ) ;
60
- if ( isMouseInside ( mousePosition , rect ) ) {
61
- //redrawButton(ctx);
62
- if ( props . onClick && typeof props . onClick === 'function' ) {
63
- props . onClick ( event ) ;
64
- }
65
- }
66
- } ;
51
+ // const onClick = (event: SyntheticMouseEvent<HTMLButtonElement>) => {
52
+ // const rect = {
53
+ // x,
54
+ // y,
55
+ // height,
56
+ // width,
57
+ // };
58
+ // const mousePosition = trackMousePosition(ctx.canvas, event);
59
+ // if (isMouseInside(mousePosition, rect)) {
60
+ // //redrawButton(ctx);
61
+ // if (props.onClick && typeof props.onClick === 'function') {
62
+ // props.onClick(event);
63
+ // }
64
+ // }
65
+ // };
67
66
const COMPONENTS = {
68
67
...customDict ,
69
68
Image : Image ( props ) ,
You can’t perform that action at this time.
0 commit comments