UNPKG

fabric

Version:

Object model for HTML5 canvas, and SVG-to-canvas parser. Backed by jsdom and node-canvas.

1 lines 791 B
{"version":3,"file":"fireEvent.min.mjs","sources":["../../../src/controls/fireEvent.ts"],"sourcesContent":["import type {\n ObjectModificationEvents,\n TModificationEvents,\n} from '../EventTypeDefs';\n\nexport const fireEvent = (\n eventName: TModificationEvents,\n options: ObjectModificationEvents[typeof eventName],\n) => {\n const {\n transform: { target },\n } = options;\n target.canvas?.fire(`object:${eventName}`, {\n ...options,\n target,\n });\n target.fire(eventName, options);\n};\n"],"names":["fireEvent","eventName","options","_target$canvas","transform","target","canvas","fire"],"mappings":"MAKaA,EAAYA,CACvBC,EACAC,KACG,IAAAC,EACH,MACEC,WAAWC,OAAEA,IACXH,EACS,QAAbC,EAAAE,EAAOC,cAAM,IAAAH,GAAbA,EAAeI,KAAK,UAAUN,IAAa,IACtCC,EACHG,WAEFA,EAAOE,KAAKN,EAAWC"}