mirror of
https://github.com/konvajs/konva.git
synced 2025-10-15 12:34:52 +08:00
fix(pointer-events): fix possible undefined stage error
Sometimes a shape may not have a stage associated with it? I was hitting this in our app. I also cleaned up the event types a bit and added the pointer methods to Stage to be consistent with the other types
This commit is contained in:
2
src/index-types.d.ts
vendored
2
src/index-types.d.ts
vendored
@@ -46,6 +46,8 @@ declare namespace Konva {
|
||||
EventType
|
||||
>;
|
||||
|
||||
export type KonvaPointerEvent = import('./PointerEvents').KonvaPointerEvent;
|
||||
|
||||
export type KonvaEventListener<
|
||||
This,
|
||||
EventType
|
||||
|
Reference in New Issue
Block a user