fabric
Version:
Object model for HTML5 canvas, and SVG-to-canvas parser. Backed by jsdom and node-canvas.
1 lines • 2.45 kB
Source Map (JSON)
{"version":3,"file":"constants.min.mjs","sources":["../../src/constants.ts"],"sourcesContent":["import type { TMat2D } from './typedefs';\n// use this syntax so babel plugin see this import here\nimport { version } from '../package.json';\n\nexport const VERSION = version;\n// eslint-disable-next-line @typescript-eslint/no-empty-function\nexport function noop() {}\n\nexport const halfPI = Math.PI / 2;\nexport const twoMathPi = Math.PI * 2;\nexport const PiBy180 = Math.PI / 180;\n\nexport const iMatrix = Object.freeze([1, 0, 0, 1, 0, 0]) as TMat2D;\nexport const DEFAULT_SVG_FONT_SIZE = 16;\nexport const ALIASING_LIMIT = 2;\n\n/* \"magic number\" for bezier approximations of arcs (http://itc.ktu.lt/itc354/Riskus354.pdf) */\nexport const kRect = 1 - 0.5522847498;\n\nexport const CENTER = 'center';\nexport const LEFT = 'left';\nexport const TOP = 'top';\nexport const BOTTOM = 'bottom';\nexport const RIGHT = 'right';\nexport const NONE = 'none';\n\nexport const reNewline = /\\r?\\n/;\n\nexport const MOVING = 'moving';\nexport const SCALING = 'scaling';\nexport const ROTATING = 'rotating';\nexport const ROTATE = 'rotate';\nexport const SKEWING = 'skewing';\nexport const RESIZING = 'resizing';\nexport const MODIFY_POLY = 'modifyPoly';\nexport const MODIFY_PATH = 'modifyPath';\nexport const CHANGED = 'changed';\nexport const SCALE = 'scale';\nexport const SCALE_X = 'scaleX';\nexport const SCALE_Y = 'scaleY';\nexport const SKEW_X = 'skewX';\nexport const SKEW_Y = 'skewY';\nexport const FILL = 'fill';\nexport const STROKE = 'stroke';\nexport const MODIFIED = 'modified';\n"],"names":["VERSION","version","noop","halfPI","Math","PI","twoMathPi","PiBy180","iMatrix","Object","freeze","DEFAULT_SVG_FONT_SIZE","ALIASING_LIMIT","kRect","CENTER","LEFT","TOP","BOTTOM","RIGHT","NONE","reNewline","MOVING","SCALING","ROTATING","ROTATE","SKEWING","RESIZING","MODIFY_POLY","MODIFY_PATH","CHANGED","SCALE","SCALE_X","SCALE_Y","SKEW_X","SKEW_Y","FILL","STROKE","MODIFIED"],"mappings":"kDAIO,MAAMA,EAAUC,EAEhB,SAASC,IAAQ,OAEXC,EAASC,KAAKC,GAAK,EACnBC,EAAsB,EAAVF,KAAKC,GACjBE,EAAUH,KAAKC,GAAK,IAEpBG,EAAUC,OAAOC,OAAO,CAAC,EAAG,EAAG,EAAG,EAAG,EAAG,IACxCC,EAAwB,GACxBC,EAAiB,EAGjBC,EAAQ,YAERC,EAAS,SACTC,EAAO,OACPC,EAAM,MACNC,EAAS,SACTC,EAAQ,QACRC,EAAO,OAEPC,EAAY,QAEZC,EAAS,SACTC,EAAU,UACVC,EAAW,WACXC,EAAS,SACTC,EAAU,UACVC,EAAW,WACXC,EAAc,aACdC,EAAc,aACdC,EAAU,UACVC,EAAQ,QACRC,EAAU,SACVC,EAAU,SACVC,EAAS,QACTC,EAAS,QACTC,EAAO,OACPC,EAAS,SACTC,EAAW"}