')\n $template.addClass('resize-handler')\n\n let positions = []\n if (horizontal) positions = positions.concat(['right', 'left'])\n if (vertical) positions = positions.concat(['top', 'bottom'])\n\n positions.forEach(position => {\n const $handler = $template.clone()\n $handler.addClass(`resize-handler-${position}`)\n $handler.on('mousedown.srcissors touchstart.srcissors', this.getResizeMouseDown(position))\n\n this.view.append($handler)\n })\n }\n\n getResizeMouseDown (position) {\n const $doc = $(document)\n\n return (event) => {\n let {pageX: lastX, pageY: lastY} = getPageCoordinates(event)\n event.stopPropagation()\n\n $doc.on('mousemove.srcissors-resize touchmove.srcissors-resize', e2 => {\n let dx, dy\n const {pageX, pageY} = getPageCoordinates(e2)\n switch (position) {\n case 'top': case 'bottom':\n dy = pageY - lastY\n if (position === 'top') { dy = -dy }\n lastY = pageY\n break\n case 'left': case 'right':\n dx = pageX - lastX\n if (position === 'left') { dx = -dx }\n lastX = pageX\n break\n }\n\n this.parent.onResize({position, dx, dy})\n }).on('mouseup.srcissors-resize touchend.srcissors-resize', () => {\n $doc.off('mouseup.srcissors-resize touchmove.srcissors-resize')\n $doc.off('mousemove.srcissors-resize touchend.srcissors-resize')\n\n // only trigger panEnd if pan has been called\n this.parent.onResizeEnd({position})\n })\n }\n }\n\n responsiveArena () {}\n}\n\n// $(window).on('resize', (event) => console.log 'on window resize')\n","const $ = require('jquery')\n\nmodule.exports = class Preview {\n\n constructor ({onReady, img, opacity, outline}) {\n this.onReady = onReady\n this.img = img\n this.opacity = opacity\n this.outline = outline\n this.x = (this.y = 0)\n this.width = (this.height = 0)\n\n this.img.on('load', () => {\n const width = this.img.width()\n const height = this.img.height()\n this.ratio = width / height\n\n this.onReady({width, height})\n this.img.show()\n })\n }\n\n setImage ({url}) {\n this.url = url\n this.img.attr('src', this.url)\n if (this.outline) this.setBackgroundImage({url: this.url})\n }\n\n setBackgroundImage ({url}) {\n if (this.opacity > 0) {\n const bgImg = $('
![]()
').css({opacity: this.opacity}).attr('src', url)\n this.outline.append(bgImg)\n }\n }\n\n reset () {\n this.url = undefined\n this.x = (this.y = 0)\n this.width = (this.height = 0)\n this.img.attr('src', '')\n this.img.css({width: '', height: '', transform: ''})\n if (this.outline) this.outline.css({transform: ''}).html('')\n }\n\n setWidth (width) {\n this.img.css({width: `${width}px`, height: 'auto'})\n const height = width / this.ratio\n this.updateImageDimensions({width, height})\n }\n\n setHeight (height) {\n this.img.css({width: 'auto', height: `${height}px`})\n const width = height * this.ratio\n this.updateImageDimensions({width, height})\n }\n\n updateImageDimensions ({width, height}) {\n this.width = width\n this.height = height\n if (this.outline) this.outline.css({width: `${this.width}px`, height: `${this.height}px`})\n }\n\n pan (x1, y1) {\n // Without rounding some numbers would not be set to css.\n // e.g: '-5.14957320384e-14'\n this.x = x1\n this.y = y1\n const x = Math.round(this.x)\n const y = Math.round(this.y)\n this.img.css({transform: `translate(-${x}px, -${y}px)`})\n if (this.outline) this.outline.css({transform: `translate(-${x}px, -${y}px)`})\n }\n}\n\n","const $ = require('jquery')\nconst Crop = require('./crop')\n\nmodule.exports = {\n new ({\n arena, url, fixedWidth, fixedHeight, minWidth, minHeight,\n minRatio, maxRatio, maxArea, originalSize, zoomStep, crop, actions, minResolution,\n surroundingImageOpacity, showSurroundingImage\n }) {\n arena = $(arena)\n const view = arena.find('.crop-view')\n const preview = view.find('.crop-preview')\n const img = $('
![]()
')\n preview.append(img)\n let outline = view.find('.crop-outline')\n if (!outline.length) { outline = undefined }\n\n const allowedActions = {\n pan: true,\n zoomOnDoubleClick: true,\n resize: true,\n resizeHorizontal: !fixedWidth,\n resizeVertical: !fixedHeight\n }\n\n $.extend(allowedActions, actions)\n\n if (zoomStep == null) { zoomStep = 1.25 }\n\n if (minWidth == null) { minWidth = 50 }\n if (minHeight == null) { minHeight = 50 }\n\n return new Crop({\n url, // {String}\n crop, // {Object} Set an inital crop. This is the same as calling setCrop()\n arena, // {jQuery Element}\n view, // {jQuery Element}\n img, // {jQuery Element}\n outline, // {jQuery Element or undefined}\n showSurroundingImage, // {String} always|panning|never\n surroundingImageOpacity, // {Number} e.g. in the 0.0 - 1.0 range\n fixedWidth, // {Number} e.g. 300\n fixedHeight, // {Number} e.g. 500\n minViewWidth: minWidth, // {Number} e.g. 100\n minViewHeight: minHeight, // {Number} e.g. 100\n minViewRatio: minRatio, // {Number} e.g. 1.5/2\n maxViewRatio: maxRatio, // {Number} e.g. 2/1\n maxArea, // {Number} 0.8 -> max 80% of arena area are covered by the preview\n originalSize, // {Object} Original image size, can be used to display a downscaled\n // version of the image in the cropping interface, but use the original\n // size for crop attributes; e.g. {width: 4000, height: 3000}\n zoomStep, // {Number} e.g. 1.25 -> 125%\n actions: allowedActions,\n minResolution\n })\n }\n}\n","module.exports = __WEBPACK_EXTERNAL_MODULE__47__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// startup\n// Load entry module and return exports\n// This entry module is referenced by other modules so it can't be inlined\nvar __webpack_exports__ = __webpack_require__(505);\n"],"names":["root","factory","exports","module","require","define","amd","self","__WEBPACK_EXTERNAL_MODULE__47__","$","Preview","Events","Crop","_ref","arena","view","img","outline","url","fixedWidth","fixedHeight","minViewWidth","minViewHeight","minViewRatio","maxViewRatio","originalSize","crop","zoomStep","maxArea","actions","minResolution","surroundingImageOpacity","showSurroundingImage","_classCallCheck","this","onPreviewReady","bind","loadingCssClass","panningCssClass","outlineCssClass","isPanning","initialCrop","loadEvent","Callbacks","changeEvent","initializeReadyState","zoomInStep","zoomOutStep","arenaWidth","width","arenaHeight","height","setSurroundingImageVisibility","preview","onReady","opacity","setImage","key","value","isReady","readyEvent","empty","isInitialized","reset","addClass","visibility","parseFloat","css","resize","imageWidth","imageHeight","zoomAllOut","previewImageSize","checkRatio","keepDimension","_ref2","updateImageDimensions","events","parent","imageRatio","imageResolution","minRatioForResolution","maxRatioForResolution","calcMaxMinDimensions","setViewDimensions","removeClass","center","setCrop","fire","_ref3","_this","x","y","factor","viewWidth","previewWidth","zoom","pan","on","viewHeight","roundCrop","validateCrop","name","Math","round","ratio","_this2","enforceValidRatio","resizeFocusPoint","getFocusPoint","setRatio","data","newX","startX","dx","newY","startY","dy","_ref4","pageX","pageY","_this$view$0$getBound","getBoundingClientRect","viewX","left","viewY","top","zoomIn","_ref5","position","isResizing","includes","undefined","_ref6","focusPoint","_ref7","_this$enforceMaxArea","enforceMaxArea","_this$enforceViewDime","enforceViewDimensions","viewRatio","minZoomPixelWidth","sqrt","minZoomPixelHeight","maxImageWidth","maxImageHeight","fireChange","isWidthRestricting","params","_ref8","_this$enforceZoom","enforceZoom","setWidth","setHeight","focus","param","_param","percentX","percentY","_ref9","enforceXy","_ref10","_ref11","maxWidth","min","maxHeight","minWidth","minHeight","_ref12","_ref13","newHeight","newWidth","isValidRatio","_this$getRatioBox","getRatioBox","_this$centerAlign","centerAlign","_this$centerAlign2","_ref14","expectedRatio","actualRatio","percentageChange","abs","Error","concat","_ref15","areaWidth","areaHeight","array","_step","_iterator","_createForOfIteratorHelper","s","n","done","number","err","e","f","callback","add","remove","_this3","changeDispatch","setTimeout","getCrop","r","num","obj","image","previewXy","console","log","getPageCoordinates","event","type","originalEvent","changedTouches","horizontal","vertical","doubleClickThreshold","zoomOnDoubleClick","doubleClick","resizeView","resizeHorizontal","resizeVertical","preventBrowserDragDrop","responsiveArena","$doc","document","e1","panData","preventDefault","e2","_getPageCoordinates","_getPageCoordinates2","prevPageX","prevPageY","onPan","off","onPanEnd","lastClick","now","Date","getTime","onDoubleClick","$template","positions","forEach","$handler","clone","getResizeMouseDown","append","_this4","_getPageCoordinates3","lastX","lastY","stopPropagation","_getPageCoordinates4","onResize","onResizeEnd","show","attr","setBackgroundImage","bgImg","transform","html","x1","y1","new","minRatio","maxRatio","find","length","allowedActions","extend","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__"],"sourceRoot":""}
\ No newline at end of file
diff --git a/package-lock.json b/package-lock.json
index 4b13270..952021f 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -62,28 +62,28 @@
}
},
"node_modules/@babel/compat-data": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.21.4.tgz",
- "integrity": "sha512-/DYyDpeCfaVinT40FPGdkkb+lYSKvsVuMjDAG7jPOWWiM1ibOaB9CXJAlc4d1QpP/U2q2P9jbrSlClKSErd55g==",
+ "version": "7.21.7",
+ "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.21.7.tgz",
+ "integrity": "sha512-KYMqFYTaenzMK4yUtf4EW9wc4N9ef80FsbMtkwool5zpwl4YrT1SdWYSTRcT94KO4hannogdS+LxY7L+arP3gA==",
"engines": {
"node": ">=6.9.0"
}
},
"node_modules/@babel/core": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.21.4.tgz",
- "integrity": "sha512-qt/YV149Jman/6AfmlxJ04LMIu8bMoyl3RB91yTFrxQmgbrSvQMy7cI8Q62FHx1t8wJ8B5fu0UDoLwHAhUo1QA==",
+ "version": "7.21.8",
+ "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.21.8.tgz",
+ "integrity": "sha512-YeM22Sondbo523Sz0+CirSPnbj9bG3P0CdHcBZdqUuaeOaYEFbOLoGU7lebvGP6P5J/WE9wOn7u7C4J9HvS1xQ==",
"dependencies": {
"@ampproject/remapping": "^2.2.0",
"@babel/code-frame": "^7.21.4",
- "@babel/generator": "^7.21.4",
- "@babel/helper-compilation-targets": "^7.21.4",
- "@babel/helper-module-transforms": "^7.21.2",
- "@babel/helpers": "^7.21.0",
- "@babel/parser": "^7.21.4",
+ "@babel/generator": "^7.21.5",
+ "@babel/helper-compilation-targets": "^7.21.5",
+ "@babel/helper-module-transforms": "^7.21.5",
+ "@babel/helpers": "^7.21.5",
+ "@babel/parser": "^7.21.8",
"@babel/template": "^7.20.7",
- "@babel/traverse": "^7.21.4",
- "@babel/types": "^7.21.4",
+ "@babel/traverse": "^7.21.5",
+ "@babel/types": "^7.21.5",
"convert-source-map": "^1.7.0",
"debug": "^4.1.0",
"gensync": "^1.0.0-beta.2",
@@ -99,11 +99,11 @@
}
},
"node_modules/@babel/generator": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.21.4.tgz",
- "integrity": "sha512-NieM3pVIYW2SwGzKoqfPrQsf4xGs9M9AIG3ThppsSRmO+m7eQhmI6amajKMUeIO37wFfsvnvcxQFx6x6iqxDnA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.21.5.tgz",
+ "integrity": "sha512-SrKK/sRv8GesIW1bDagf9cCG38IOMYZusoe1dfg0D8aiUe3Amvoj1QtjTPAWcfrZFvIwlleLb0gxzQidL9w14w==",
"dependencies": {
- "@babel/types": "^7.21.4",
+ "@babel/types": "^7.21.5",
"@jridgewell/gen-mapping": "^0.3.2",
"@jridgewell/trace-mapping": "^0.3.17",
"jsesc": "^2.5.1"
@@ -136,11 +136,11 @@
}
},
"node_modules/@babel/helper-compilation-targets": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.21.4.tgz",
- "integrity": "sha512-Fa0tTuOXZ1iL8IeDFUWCzjZcn+sJGd9RZdH9esYVjEejGmzf+FFYQpMi/kZUk2kPy/q1H3/GPw7np8qar/stfg==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.21.5.tgz",
+ "integrity": "sha512-1RkbFGUKex4lvsB9yhIfWltJM5cZKUftB2eNajaDv3dCMEp49iBG0K14uH8NnX9IPux2+mK7JGEOB0jn48/J6w==",
"dependencies": {
- "@babel/compat-data": "^7.21.4",
+ "@babel/compat-data": "^7.21.5",
"@babel/helper-validator-option": "^7.21.0",
"browserslist": "^4.21.3",
"lru-cache": "^5.1.1",
@@ -206,9 +206,9 @@
}
},
"node_modules/@babel/helper-environment-visitor": {
- "version": "7.18.9",
- "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.9.tgz",
- "integrity": "sha512-3r/aACDJ3fhQ/EVgFy0hpj8oHyHpQc+LPtJoY9SzTThAsStm4Ptegq92vqKoE3vD706ZVFWITnMnxucw+S9Ipg==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.21.5.tgz",
+ "integrity": "sha512-IYl4gZ3ETsWocUWgsFZLM5i1BYx9SoemminVEXadgLBa9TdeorzgLKm8wWLA6J1N/kT3Kch8XIk1laNzYoHKvQ==",
"engines": {
"node": ">=6.9.0"
}
@@ -270,18 +270,18 @@
}
},
"node_modules/@babel/helper-module-transforms": {
- "version": "7.21.2",
- "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.21.2.tgz",
- "integrity": "sha512-79yj2AR4U/Oqq/WOV7Lx6hUjau1Zfo4cI+JLAVYeMV5XIlbOhmjEk5ulbTc9fMpmlojzZHkUUxAiK+UKn+hNQQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.21.5.tgz",
+ "integrity": "sha512-bI2Z9zBGY2q5yMHoBvJ2a9iX3ZOAzJPm7Q8Yz6YeoUjU/Cvhmi2G4QyTNyPBqqXSgTjUxRg3L0xV45HvkNWWBw==",
"dependencies": {
- "@babel/helper-environment-visitor": "^7.18.9",
- "@babel/helper-module-imports": "^7.18.6",
- "@babel/helper-simple-access": "^7.20.2",
+ "@babel/helper-environment-visitor": "^7.21.5",
+ "@babel/helper-module-imports": "^7.21.4",
+ "@babel/helper-simple-access": "^7.21.5",
"@babel/helper-split-export-declaration": "^7.18.6",
"@babel/helper-validator-identifier": "^7.19.1",
"@babel/template": "^7.20.7",
- "@babel/traverse": "^7.21.2",
- "@babel/types": "^7.21.2"
+ "@babel/traverse": "^7.21.5",
+ "@babel/types": "^7.21.5"
},
"engines": {
"node": ">=6.9.0"
@@ -299,9 +299,9 @@
}
},
"node_modules/@babel/helper-plugin-utils": {
- "version": "7.20.2",
- "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.20.2.tgz",
- "integrity": "sha512-8RvlJG2mj4huQ4pZ+rU9lqKi9ZKiRmuvGuM2HlWmkmgOhbs6zEAw6IEiJ5cQqGbDzGZOhwuOQNtZMi/ENLjZoQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.21.5.tgz",
+ "integrity": "sha512-0WDaIlXKOX/3KfBK/dwP1oQGiPh6rjMkT7HIRv7i5RR2VUMwrx5ZL0dwBkKx7+SW1zwNdgjHd34IMk5ZjTeHVg==",
"engines": {
"node": ">=6.9.0"
}
@@ -340,11 +340,11 @@
}
},
"node_modules/@babel/helper-simple-access": {
- "version": "7.20.2",
- "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.20.2.tgz",
- "integrity": "sha512-+0woI/WPq59IrqDYbVGfshjT5Dmk/nnbdpcF8SnMhhXObpTq2KNBdLFRFrkVdbDOyUmHBCxzm5FHV1rACIkIbA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.21.5.tgz",
+ "integrity": "sha512-ENPDAMC1wAjR0uaCUwliBdiSl1KBJAVnMTzXqi64c2MG8MPR6ii4qf7bSXDqSFbr4W6W028/rf5ivoHop5/mkg==",
"dependencies": {
- "@babel/types": "^7.20.2"
+ "@babel/types": "^7.21.5"
},
"engines": {
"node": ">=6.9.0"
@@ -373,9 +373,9 @@
}
},
"node_modules/@babel/helper-string-parser": {
- "version": "7.19.4",
- "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.19.4.tgz",
- "integrity": "sha512-nHtDoQcuqFmwYNYPz3Rah5ph2p8PFeFCsZk9A/48dPc/rGocJ5J3hAAZ7pb76VWX3fZKu+uEr/FhH5jLx7umrw==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.21.5.tgz",
+ "integrity": "sha512-5pTUx3hAJaZIdW99sJ6ZUUgWq/Y+Hja7TowEnLNMm1VivRgZQL3vpBY3qUACVsvw+yQU6+YgfBVmcbLaZtrA1w==",
"engines": {
"node": ">=6.9.0"
}
@@ -411,13 +411,13 @@
}
},
"node_modules/@babel/helpers": {
- "version": "7.21.0",
- "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.21.0.tgz",
- "integrity": "sha512-XXve0CBtOW0pd7MRzzmoyuSj0e3SEzj8pgyFxnTT1NJZL38BD1MK7yYrm8yefRPIDvNNe14xR4FdbHwpInD4rA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.21.5.tgz",
+ "integrity": "sha512-BSY+JSlHxOmGsPTydUkPf1MdMQ3M81x5xGCOVgWM3G8XH77sJ292Y2oqcp0CbbgxhqBuI46iUz1tT7hqP7EfgA==",
"dependencies": {
"@babel/template": "^7.20.7",
- "@babel/traverse": "^7.21.0",
- "@babel/types": "^7.21.0"
+ "@babel/traverse": "^7.21.5",
+ "@babel/types": "^7.21.5"
},
"engines": {
"node": ">=6.9.0"
@@ -437,9 +437,9 @@
}
},
"node_modules/@babel/parser": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.4.tgz",
- "integrity": "sha512-alVJj7k7zIxqBZ7BTRhz0IqJFxW1VJbm6N8JbcYhQ186df9ZBPbZBmWSqAMXwHGsCJdYks7z/voa3ibiS5bCIw==",
+ "version": "7.21.8",
+ "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.8.tgz",
+ "integrity": "sha512-6zavDGdzG3gUqAdWvlLFfk+36RilI+Pwyuuh7HItyeScCWP3k6i8vKclAQ0bM/0y/Kz/xiwvxhMv9MgTJP5gmA==",
"bin": {
"parser": "bin/babel-parser.js"
},
@@ -783,6 +783,17 @@
"@babel/core": "^7.0.0-0"
}
},
+ "node_modules/@babel/plugin-syntax-import-meta": {
+ "version": "7.10.4",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz",
+ "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==",
+ "dependencies": {
+ "@babel/helper-plugin-utils": "^7.10.4"
+ },
+ "peerDependencies": {
+ "@babel/core": "^7.0.0-0"
+ }
+ },
"node_modules/@babel/plugin-syntax-json-strings": {
"version": "7.8.3",
"resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz",
@@ -889,11 +900,11 @@
}
},
"node_modules/@babel/plugin-transform-arrow-functions": {
- "version": "7.20.7",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.20.7.tgz",
- "integrity": "sha512-3poA5E7dzDomxj9WXWwuD6A5F3kc7VXwIJO+E+J8qtDtS+pXPAhrgEyh+9GBwBgPq1Z+bB+/JD60lp5jsN7JPQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.21.5.tgz",
+ "integrity": "sha512-wb1mhwGOCaXHDTcsRYMKF9e5bbMgqwxtqa2Y1ifH96dXJPwbuLX9qHy3clhrxVqgMz7nyNXs8VkxdH8UBcjKqA==",
"dependencies": {
- "@babel/helper-plugin-utils": "^7.20.2"
+ "@babel/helper-plugin-utils": "^7.21.5"
},
"engines": {
"node": ">=6.9.0"
@@ -969,11 +980,11 @@
}
},
"node_modules/@babel/plugin-transform-computed-properties": {
- "version": "7.20.7",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.20.7.tgz",
- "integrity": "sha512-Lz7MvBK6DTjElHAmfu6bfANzKcxpyNPeYBGEafyA6E5HtRpjpZwU+u7Qrgz/2OR0z+5TvKYbPdphfSaAcZBrYQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.21.5.tgz",
+ "integrity": "sha512-TR653Ki3pAwxBxUe8srfF3e4Pe3FTA46uaNHYyQwIoM4oWKSoOZiDNyHJ0oIoDIUPSRQbQG7jzgVBX3FPVne1Q==",
"dependencies": {
- "@babel/helper-plugin-utils": "^7.20.2",
+ "@babel/helper-plugin-utils": "^7.21.5",
"@babel/template": "^7.20.7"
},
"engines": {
@@ -1042,11 +1053,11 @@
}
},
"node_modules/@babel/plugin-transform-for-of": {
- "version": "7.21.0",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.21.0.tgz",
- "integrity": "sha512-LlUYlydgDkKpIY7mcBWvyPPmMcOphEyYA27Ef4xpbh1IiDNLr0kZsos2nf92vz3IccvJI25QUwp86Eo5s6HmBQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.21.5.tgz",
+ "integrity": "sha512-nYWpjKW/7j/I/mZkGVgHJXh4bA1sfdFnJoOXwJuj4m3Q2EraO/8ZyrkCau9P5tbHQk01RMSt6KYLCsW7730SXQ==",
"dependencies": {
- "@babel/helper-plugin-utils": "^7.20.2"
+ "@babel/helper-plugin-utils": "^7.21.5"
},
"engines": {
"node": ">=6.9.0"
@@ -1115,13 +1126,13 @@
}
},
"node_modules/@babel/plugin-transform-modules-commonjs": {
- "version": "7.21.2",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.21.2.tgz",
- "integrity": "sha512-Cln+Yy04Gxua7iPdj6nOV96smLGjpElir5YwzF0LBPKoPlLDNJePNlrGGaybAJkd0zKRnOVXOgizSqPYMNYkzA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.21.5.tgz",
+ "integrity": "sha512-OVryBEgKUbtqMoB7eG2rs6UFexJi6Zj6FDXx+esBLPTCxCNxAY9o+8Di7IsUGJ+AVhp5ncK0fxWUBd0/1gPhrQ==",
"dependencies": {
- "@babel/helper-module-transforms": "^7.21.2",
- "@babel/helper-plugin-utils": "^7.20.2",
- "@babel/helper-simple-access": "^7.20.2"
+ "@babel/helper-module-transforms": "^7.21.5",
+ "@babel/helper-plugin-utils": "^7.21.5",
+ "@babel/helper-simple-access": "^7.21.5"
},
"engines": {
"node": ">=6.9.0"
@@ -1235,11 +1246,11 @@
}
},
"node_modules/@babel/plugin-transform-regenerator": {
- "version": "7.20.5",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.20.5.tgz",
- "integrity": "sha512-kW/oO7HPBtntbsahzQ0qSE3tFvkFwnbozz3NWFhLGqH75vLEg+sCGngLlhVkePlCs3Jv0dBBHDzCHxNiFAQKCQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.21.5.tgz",
+ "integrity": "sha512-ZoYBKDb6LyMi5yCsByQ5jmXsHAQDDYeexT1Szvlmui+lADvfSecr5Dxd/PkrTC3pAD182Fcju1VQkB4oCp9M+w==",
"dependencies": {
- "@babel/helper-plugin-utils": "^7.20.2",
+ "@babel/helper-plugin-utils": "^7.21.5",
"regenerator-transform": "^0.15.1"
},
"engines": {
@@ -1335,11 +1346,11 @@
}
},
"node_modules/@babel/plugin-transform-unicode-escapes": {
- "version": "7.18.10",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.18.10.tgz",
- "integrity": "sha512-kKAdAI+YzPgGY/ftStBFXTI1LZFju38rYThnfMykS+IXy8BVx+res7s2fxf1l8I35DV2T97ezo6+SGrXz6B3iQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.21.5.tgz",
+ "integrity": "sha512-LYm/gTOwZqsYohlvFUe/8Tujz75LqqVC2w+2qPHLR+WyWHGCZPN1KBpJCJn+4Bk4gOkQy/IXKIge6az5MqwlOg==",
"dependencies": {
- "@babel/helper-plugin-utils": "^7.18.9"
+ "@babel/helper-plugin-utils": "^7.21.5"
},
"engines": {
"node": ">=6.9.0"
@@ -1364,13 +1375,13 @@
}
},
"node_modules/@babel/preset-env": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.21.4.tgz",
- "integrity": "sha512-2W57zHs2yDLm6GD5ZpvNn71lZ0B/iypSdIeq25OurDKji6AdzV07qp4s3n1/x5BqtiGaTrPN3nerlSCaC5qNTw==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.21.5.tgz",
+ "integrity": "sha512-wH00QnTTldTbf/IefEVyChtRdw5RJvODT/Vb4Vcxq1AZvtXj6T0YeX0cAcXhI6/BdGuiP3GcNIL4OQbI2DVNxg==",
"dependencies": {
- "@babel/compat-data": "^7.21.4",
- "@babel/helper-compilation-targets": "^7.21.4",
- "@babel/helper-plugin-utils": "^7.20.2",
+ "@babel/compat-data": "^7.21.5",
+ "@babel/helper-compilation-targets": "^7.21.5",
+ "@babel/helper-plugin-utils": "^7.21.5",
"@babel/helper-validator-option": "^7.21.0",
"@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": "^7.18.6",
"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": "^7.20.7",
@@ -1395,6 +1406,7 @@
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
"@babel/plugin-syntax-export-namespace-from": "^7.8.3",
"@babel/plugin-syntax-import-assertions": "^7.20.0",
+ "@babel/plugin-syntax-import-meta": "^7.10.4",
"@babel/plugin-syntax-json-strings": "^7.8.3",
"@babel/plugin-syntax-logical-assignment-operators": "^7.10.4",
"@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3",
@@ -1404,22 +1416,22 @@
"@babel/plugin-syntax-optional-chaining": "^7.8.3",
"@babel/plugin-syntax-private-property-in-object": "^7.14.5",
"@babel/plugin-syntax-top-level-await": "^7.14.5",
- "@babel/plugin-transform-arrow-functions": "^7.20.7",
+ "@babel/plugin-transform-arrow-functions": "^7.21.5",
"@babel/plugin-transform-async-to-generator": "^7.20.7",
"@babel/plugin-transform-block-scoped-functions": "^7.18.6",
"@babel/plugin-transform-block-scoping": "^7.21.0",
"@babel/plugin-transform-classes": "^7.21.0",
- "@babel/plugin-transform-computed-properties": "^7.20.7",
+ "@babel/plugin-transform-computed-properties": "^7.21.5",
"@babel/plugin-transform-destructuring": "^7.21.3",
"@babel/plugin-transform-dotall-regex": "^7.18.6",
"@babel/plugin-transform-duplicate-keys": "^7.18.9",
"@babel/plugin-transform-exponentiation-operator": "^7.18.6",
- "@babel/plugin-transform-for-of": "^7.21.0",
+ "@babel/plugin-transform-for-of": "^7.21.5",
"@babel/plugin-transform-function-name": "^7.18.9",
"@babel/plugin-transform-literals": "^7.18.9",
"@babel/plugin-transform-member-expression-literals": "^7.18.6",
"@babel/plugin-transform-modules-amd": "^7.20.11",
- "@babel/plugin-transform-modules-commonjs": "^7.21.2",
+ "@babel/plugin-transform-modules-commonjs": "^7.21.5",
"@babel/plugin-transform-modules-systemjs": "^7.20.11",
"@babel/plugin-transform-modules-umd": "^7.18.6",
"@babel/plugin-transform-named-capturing-groups-regex": "^7.20.5",
@@ -1427,17 +1439,17 @@
"@babel/plugin-transform-object-super": "^7.18.6",
"@babel/plugin-transform-parameters": "^7.21.3",
"@babel/plugin-transform-property-literals": "^7.18.6",
- "@babel/plugin-transform-regenerator": "^7.20.5",
+ "@babel/plugin-transform-regenerator": "^7.21.5",
"@babel/plugin-transform-reserved-words": "^7.18.6",
"@babel/plugin-transform-shorthand-properties": "^7.18.6",
"@babel/plugin-transform-spread": "^7.20.7",
"@babel/plugin-transform-sticky-regex": "^7.18.6",
"@babel/plugin-transform-template-literals": "^7.18.9",
"@babel/plugin-transform-typeof-symbol": "^7.18.9",
- "@babel/plugin-transform-unicode-escapes": "^7.18.10",
+ "@babel/plugin-transform-unicode-escapes": "^7.21.5",
"@babel/plugin-transform-unicode-regex": "^7.18.6",
"@babel/preset-modules": "^0.1.5",
- "@babel/types": "^7.21.4",
+ "@babel/types": "^7.21.5",
"babel-plugin-polyfill-corejs2": "^0.3.3",
"babel-plugin-polyfill-corejs3": "^0.6.0",
"babel-plugin-polyfill-regenerator": "^0.4.1",
@@ -1496,18 +1508,18 @@
}
},
"node_modules/@babel/traverse": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.21.4.tgz",
- "integrity": "sha512-eyKrRHKdyZxqDm+fV1iqL9UAHMoIg0nDaGqfIOd8rKH17m5snv7Gn4qgjBoFfLz9APvjFU/ICT00NVCv1Epp8Q==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.21.5.tgz",
+ "integrity": "sha512-AhQoI3YjWi6u/y/ntv7k48mcrCXmus0t79J9qPNlk/lAsFlCiJ047RmbfMOawySTHtywXhbXgpx/8nXMYd+oFw==",
"dependencies": {
"@babel/code-frame": "^7.21.4",
- "@babel/generator": "^7.21.4",
- "@babel/helper-environment-visitor": "^7.18.9",
+ "@babel/generator": "^7.21.5",
+ "@babel/helper-environment-visitor": "^7.21.5",
"@babel/helper-function-name": "^7.21.0",
"@babel/helper-hoist-variables": "^7.18.6",
"@babel/helper-split-export-declaration": "^7.18.6",
- "@babel/parser": "^7.21.4",
- "@babel/types": "^7.21.4",
+ "@babel/parser": "^7.21.5",
+ "@babel/types": "^7.21.5",
"debug": "^4.1.0",
"globals": "^11.1.0"
},
@@ -1516,11 +1528,11 @@
}
},
"node_modules/@babel/types": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.21.4.tgz",
- "integrity": "sha512-rU2oY501qDxE8Pyo7i/Orqma4ziCOrby0/9mvbDUGEfvZjb279Nk9k19e2fiCxHbRRpY2ZyrgW1eq22mvmOIzA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.21.5.tgz",
+ "integrity": "sha512-m4AfNvVF2mVC/F7fDEdH2El3HzUg9It/XsCxZiOTTA3m3qYfcSVSbTfM6Q9xG+hYDniZssYhlXKKUMD5m8tF4Q==",
"dependencies": {
- "@babel/helper-string-parser": "^7.19.4",
+ "@babel/helper-string-parser": "^7.21.5",
"@babel/helper-validator-identifier": "^7.19.1",
"to-fast-properties": "^2.0.0"
},
@@ -3225,9 +3237,9 @@
"integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow=="
},
"node_modules/electron": {
- "version": "24.1.2",
- "resolved": "https://registry.npmjs.org/electron/-/electron-24.1.2.tgz",
- "integrity": "sha512-V0isWbyLYiXrSCcB4lrSVhS/U56NFGfuqHyc+yEPkyhhvY+h4F85cYGdEiZlXp6XjHT+/CLHmw0ltK54g9lvDw==",
+ "version": "24.2.0",
+ "resolved": "https://registry.npmjs.org/electron/-/electron-24.2.0.tgz",
+ "integrity": "sha512-fEYAftYqFhveniWJbEHXjNMWjooFFIuqNj/eEFJkGzycInfBJq/c4E/dew++s6s0YLubxFnjoF2qZiqapLj0gA==",
"hasInstallScript": true,
"dependencies": {
"@electron/get": "^2.0.0",
@@ -3268,9 +3280,9 @@
}
},
"node_modules/engine.io": {
- "version": "6.4.1",
- "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-6.4.1.tgz",
- "integrity": "sha512-JFYQurD/nbsA5BSPmbaOSLa3tSVj8L6o4srSwXXY3NqE+gGUNmmPTbhn8tjzcCtSqhFgIeqef81ngny8JM25hw==",
+ "version": "6.4.2",
+ "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-6.4.2.tgz",
+ "integrity": "sha512-FKn/3oMiJjrOEOeUub2WCox6JhxBXq/Zn3fZOMCBxKnNYtsdKjxhl7yR3fZhM9PV+rdE75SU5SYMc+2PGzo+Tg==",
"dependencies": {
"@types/cookie": "^0.4.1",
"@types/cors": "^2.8.12",
@@ -7738,25 +7750,25 @@
}
},
"@babel/compat-data": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.21.4.tgz",
- "integrity": "sha512-/DYyDpeCfaVinT40FPGdkkb+lYSKvsVuMjDAG7jPOWWiM1ibOaB9CXJAlc4d1QpP/U2q2P9jbrSlClKSErd55g=="
+ "version": "7.21.7",
+ "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.21.7.tgz",
+ "integrity": "sha512-KYMqFYTaenzMK4yUtf4EW9wc4N9ef80FsbMtkwool5zpwl4YrT1SdWYSTRcT94KO4hannogdS+LxY7L+arP3gA=="
},
"@babel/core": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.21.4.tgz",
- "integrity": "sha512-qt/YV149Jman/6AfmlxJ04LMIu8bMoyl3RB91yTFrxQmgbrSvQMy7cI8Q62FHx1t8wJ8B5fu0UDoLwHAhUo1QA==",
+ "version": "7.21.8",
+ "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.21.8.tgz",
+ "integrity": "sha512-YeM22Sondbo523Sz0+CirSPnbj9bG3P0CdHcBZdqUuaeOaYEFbOLoGU7lebvGP6P5J/WE9wOn7u7C4J9HvS1xQ==",
"requires": {
"@ampproject/remapping": "^2.2.0",
"@babel/code-frame": "^7.21.4",
- "@babel/generator": "^7.21.4",
- "@babel/helper-compilation-targets": "^7.21.4",
- "@babel/helper-module-transforms": "^7.21.2",
- "@babel/helpers": "^7.21.0",
- "@babel/parser": "^7.21.4",
+ "@babel/generator": "^7.21.5",
+ "@babel/helper-compilation-targets": "^7.21.5",
+ "@babel/helper-module-transforms": "^7.21.5",
+ "@babel/helpers": "^7.21.5",
+ "@babel/parser": "^7.21.8",
"@babel/template": "^7.20.7",
- "@babel/traverse": "^7.21.4",
- "@babel/types": "^7.21.4",
+ "@babel/traverse": "^7.21.5",
+ "@babel/types": "^7.21.5",
"convert-source-map": "^1.7.0",
"debug": "^4.1.0",
"gensync": "^1.0.0-beta.2",
@@ -7765,11 +7777,11 @@
}
},
"@babel/generator": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.21.4.tgz",
- "integrity": "sha512-NieM3pVIYW2SwGzKoqfPrQsf4xGs9M9AIG3ThppsSRmO+m7eQhmI6amajKMUeIO37wFfsvnvcxQFx6x6iqxDnA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.21.5.tgz",
+ "integrity": "sha512-SrKK/sRv8GesIW1bDagf9cCG38IOMYZusoe1dfg0D8aiUe3Amvoj1QtjTPAWcfrZFvIwlleLb0gxzQidL9w14w==",
"requires": {
- "@babel/types": "^7.21.4",
+ "@babel/types": "^7.21.5",
"@jridgewell/gen-mapping": "^0.3.2",
"@jridgewell/trace-mapping": "^0.3.17",
"jsesc": "^2.5.1"
@@ -7793,11 +7805,11 @@
}
},
"@babel/helper-compilation-targets": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.21.4.tgz",
- "integrity": "sha512-Fa0tTuOXZ1iL8IeDFUWCzjZcn+sJGd9RZdH9esYVjEejGmzf+FFYQpMi/kZUk2kPy/q1H3/GPw7np8qar/stfg==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.21.5.tgz",
+ "integrity": "sha512-1RkbFGUKex4lvsB9yhIfWltJM5cZKUftB2eNajaDv3dCMEp49iBG0K14uH8NnX9IPux2+mK7JGEOB0jn48/J6w==",
"requires": {
- "@babel/compat-data": "^7.21.4",
+ "@babel/compat-data": "^7.21.5",
"@babel/helper-validator-option": "^7.21.0",
"browserslist": "^4.21.3",
"lru-cache": "^5.1.1",
@@ -7842,9 +7854,9 @@
}
},
"@babel/helper-environment-visitor": {
- "version": "7.18.9",
- "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.18.9.tgz",
- "integrity": "sha512-3r/aACDJ3fhQ/EVgFy0hpj8oHyHpQc+LPtJoY9SzTThAsStm4Ptegq92vqKoE3vD706ZVFWITnMnxucw+S9Ipg=="
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.21.5.tgz",
+ "integrity": "sha512-IYl4gZ3ETsWocUWgsFZLM5i1BYx9SoemminVEXadgLBa9TdeorzgLKm8wWLA6J1N/kT3Kch8XIk1laNzYoHKvQ=="
},
"@babel/helper-explode-assignable-expression": {
"version": "7.18.6",
@@ -7888,18 +7900,18 @@
}
},
"@babel/helper-module-transforms": {
- "version": "7.21.2",
- "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.21.2.tgz",
- "integrity": "sha512-79yj2AR4U/Oqq/WOV7Lx6hUjau1Zfo4cI+JLAVYeMV5XIlbOhmjEk5ulbTc9fMpmlojzZHkUUxAiK+UKn+hNQQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.21.5.tgz",
+ "integrity": "sha512-bI2Z9zBGY2q5yMHoBvJ2a9iX3ZOAzJPm7Q8Yz6YeoUjU/Cvhmi2G4QyTNyPBqqXSgTjUxRg3L0xV45HvkNWWBw==",
"requires": {
- "@babel/helper-environment-visitor": "^7.18.9",
- "@babel/helper-module-imports": "^7.18.6",
- "@babel/helper-simple-access": "^7.20.2",
+ "@babel/helper-environment-visitor": "^7.21.5",
+ "@babel/helper-module-imports": "^7.21.4",
+ "@babel/helper-simple-access": "^7.21.5",
"@babel/helper-split-export-declaration": "^7.18.6",
"@babel/helper-validator-identifier": "^7.19.1",
"@babel/template": "^7.20.7",
- "@babel/traverse": "^7.21.2",
- "@babel/types": "^7.21.2"
+ "@babel/traverse": "^7.21.5",
+ "@babel/types": "^7.21.5"
}
},
"@babel/helper-optimise-call-expression": {
@@ -7911,9 +7923,9 @@
}
},
"@babel/helper-plugin-utils": {
- "version": "7.20.2",
- "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.20.2.tgz",
- "integrity": "sha512-8RvlJG2mj4huQ4pZ+rU9lqKi9ZKiRmuvGuM2HlWmkmgOhbs6zEAw6IEiJ5cQqGbDzGZOhwuOQNtZMi/ENLjZoQ=="
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.21.5.tgz",
+ "integrity": "sha512-0WDaIlXKOX/3KfBK/dwP1oQGiPh6rjMkT7HIRv7i5RR2VUMwrx5ZL0dwBkKx7+SW1zwNdgjHd34IMk5ZjTeHVg=="
},
"@babel/helper-remap-async-to-generator": {
"version": "7.18.9",
@@ -7940,11 +7952,11 @@
}
},
"@babel/helper-simple-access": {
- "version": "7.20.2",
- "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.20.2.tgz",
- "integrity": "sha512-+0woI/WPq59IrqDYbVGfshjT5Dmk/nnbdpcF8SnMhhXObpTq2KNBdLFRFrkVdbDOyUmHBCxzm5FHV1rACIkIbA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.21.5.tgz",
+ "integrity": "sha512-ENPDAMC1wAjR0uaCUwliBdiSl1KBJAVnMTzXqi64c2MG8MPR6ii4qf7bSXDqSFbr4W6W028/rf5ivoHop5/mkg==",
"requires": {
- "@babel/types": "^7.20.2"
+ "@babel/types": "^7.21.5"
}
},
"@babel/helper-skip-transparent-expression-wrappers": {
@@ -7964,9 +7976,9 @@
}
},
"@babel/helper-string-parser": {
- "version": "7.19.4",
- "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.19.4.tgz",
- "integrity": "sha512-nHtDoQcuqFmwYNYPz3Rah5ph2p8PFeFCsZk9A/48dPc/rGocJ5J3hAAZ7pb76VWX3fZKu+uEr/FhH5jLx7umrw=="
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.21.5.tgz",
+ "integrity": "sha512-5pTUx3hAJaZIdW99sJ6ZUUgWq/Y+Hja7TowEnLNMm1VivRgZQL3vpBY3qUACVsvw+yQU6+YgfBVmcbLaZtrA1w=="
},
"@babel/helper-validator-identifier": {
"version": "7.19.1",
@@ -7990,13 +8002,13 @@
}
},
"@babel/helpers": {
- "version": "7.21.0",
- "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.21.0.tgz",
- "integrity": "sha512-XXve0CBtOW0pd7MRzzmoyuSj0e3SEzj8pgyFxnTT1NJZL38BD1MK7yYrm8yefRPIDvNNe14xR4FdbHwpInD4rA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.21.5.tgz",
+ "integrity": "sha512-BSY+JSlHxOmGsPTydUkPf1MdMQ3M81x5xGCOVgWM3G8XH77sJ292Y2oqcp0CbbgxhqBuI46iUz1tT7hqP7EfgA==",
"requires": {
"@babel/template": "^7.20.7",
- "@babel/traverse": "^7.21.0",
- "@babel/types": "^7.21.0"
+ "@babel/traverse": "^7.21.5",
+ "@babel/types": "^7.21.5"
}
},
"@babel/highlight": {
@@ -8010,9 +8022,9 @@
}
},
"@babel/parser": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.4.tgz",
- "integrity": "sha512-alVJj7k7zIxqBZ7BTRhz0IqJFxW1VJbm6N8JbcYhQ186df9ZBPbZBmWSqAMXwHGsCJdYks7z/voa3ibiS5bCIw=="
+ "version": "7.21.8",
+ "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.21.8.tgz",
+ "integrity": "sha512-6zavDGdzG3gUqAdWvlLFfk+36RilI+Pwyuuh7HItyeScCWP3k6i8vKclAQ0bM/0y/Kz/xiwvxhMv9MgTJP5gmA=="
},
"@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": {
"version": "7.18.6",
@@ -8224,6 +8236,14 @@
"@babel/helper-plugin-utils": "^7.19.0"
}
},
+ "@babel/plugin-syntax-import-meta": {
+ "version": "7.10.4",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz",
+ "integrity": "sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==",
+ "requires": {
+ "@babel/helper-plugin-utils": "^7.10.4"
+ }
+ },
"@babel/plugin-syntax-json-strings": {
"version": "7.8.3",
"resolved": "https://registry.npmjs.org/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz",
@@ -8297,11 +8317,11 @@
}
},
"@babel/plugin-transform-arrow-functions": {
- "version": "7.20.7",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.20.7.tgz",
- "integrity": "sha512-3poA5E7dzDomxj9WXWwuD6A5F3kc7VXwIJO+E+J8qtDtS+pXPAhrgEyh+9GBwBgPq1Z+bB+/JD60lp5jsN7JPQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.21.5.tgz",
+ "integrity": "sha512-wb1mhwGOCaXHDTcsRYMKF9e5bbMgqwxtqa2Y1ifH96dXJPwbuLX9qHy3clhrxVqgMz7nyNXs8VkxdH8UBcjKqA==",
"requires": {
- "@babel/helper-plugin-utils": "^7.20.2"
+ "@babel/helper-plugin-utils": "^7.21.5"
}
},
"@babel/plugin-transform-async-to-generator": {
@@ -8347,11 +8367,11 @@
}
},
"@babel/plugin-transform-computed-properties": {
- "version": "7.20.7",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.20.7.tgz",
- "integrity": "sha512-Lz7MvBK6DTjElHAmfu6bfANzKcxpyNPeYBGEafyA6E5HtRpjpZwU+u7Qrgz/2OR0z+5TvKYbPdphfSaAcZBrYQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.21.5.tgz",
+ "integrity": "sha512-TR653Ki3pAwxBxUe8srfF3e4Pe3FTA46uaNHYyQwIoM4oWKSoOZiDNyHJ0oIoDIUPSRQbQG7jzgVBX3FPVne1Q==",
"requires": {
- "@babel/helper-plugin-utils": "^7.20.2",
+ "@babel/helper-plugin-utils": "^7.21.5",
"@babel/template": "^7.20.7"
}
},
@@ -8390,11 +8410,11 @@
}
},
"@babel/plugin-transform-for-of": {
- "version": "7.21.0",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.21.0.tgz",
- "integrity": "sha512-LlUYlydgDkKpIY7mcBWvyPPmMcOphEyYA27Ef4xpbh1IiDNLr0kZsos2nf92vz3IccvJI25QUwp86Eo5s6HmBQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.21.5.tgz",
+ "integrity": "sha512-nYWpjKW/7j/I/mZkGVgHJXh4bA1sfdFnJoOXwJuj4m3Q2EraO/8ZyrkCau9P5tbHQk01RMSt6KYLCsW7730SXQ==",
"requires": {
- "@babel/helper-plugin-utils": "^7.20.2"
+ "@babel/helper-plugin-utils": "^7.21.5"
}
},
"@babel/plugin-transform-function-name": {
@@ -8433,13 +8453,13 @@
}
},
"@babel/plugin-transform-modules-commonjs": {
- "version": "7.21.2",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.21.2.tgz",
- "integrity": "sha512-Cln+Yy04Gxua7iPdj6nOV96smLGjpElir5YwzF0LBPKoPlLDNJePNlrGGaybAJkd0zKRnOVXOgizSqPYMNYkzA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.21.5.tgz",
+ "integrity": "sha512-OVryBEgKUbtqMoB7eG2rs6UFexJi6Zj6FDXx+esBLPTCxCNxAY9o+8Di7IsUGJ+AVhp5ncK0fxWUBd0/1gPhrQ==",
"requires": {
- "@babel/helper-module-transforms": "^7.21.2",
- "@babel/helper-plugin-utils": "^7.20.2",
- "@babel/helper-simple-access": "^7.20.2"
+ "@babel/helper-module-transforms": "^7.21.5",
+ "@babel/helper-plugin-utils": "^7.21.5",
+ "@babel/helper-simple-access": "^7.21.5"
}
},
"@babel/plugin-transform-modules-systemjs": {
@@ -8505,11 +8525,11 @@
}
},
"@babel/plugin-transform-regenerator": {
- "version": "7.20.5",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.20.5.tgz",
- "integrity": "sha512-kW/oO7HPBtntbsahzQ0qSE3tFvkFwnbozz3NWFhLGqH75vLEg+sCGngLlhVkePlCs3Jv0dBBHDzCHxNiFAQKCQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.21.5.tgz",
+ "integrity": "sha512-ZoYBKDb6LyMi5yCsByQ5jmXsHAQDDYeexT1Szvlmui+lADvfSecr5Dxd/PkrTC3pAD182Fcju1VQkB4oCp9M+w==",
"requires": {
- "@babel/helper-plugin-utils": "^7.20.2",
+ "@babel/helper-plugin-utils": "^7.21.5",
"regenerator-transform": "^0.15.1"
}
},
@@ -8563,11 +8583,11 @@
}
},
"@babel/plugin-transform-unicode-escapes": {
- "version": "7.18.10",
- "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.18.10.tgz",
- "integrity": "sha512-kKAdAI+YzPgGY/ftStBFXTI1LZFju38rYThnfMykS+IXy8BVx+res7s2fxf1l8I35DV2T97ezo6+SGrXz6B3iQ==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-unicode-escapes/-/plugin-transform-unicode-escapes-7.21.5.tgz",
+ "integrity": "sha512-LYm/gTOwZqsYohlvFUe/8Tujz75LqqVC2w+2qPHLR+WyWHGCZPN1KBpJCJn+4Bk4gOkQy/IXKIge6az5MqwlOg==",
"requires": {
- "@babel/helper-plugin-utils": "^7.18.9"
+ "@babel/helper-plugin-utils": "^7.21.5"
}
},
"@babel/plugin-transform-unicode-regex": {
@@ -8580,13 +8600,13 @@
}
},
"@babel/preset-env": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.21.4.tgz",
- "integrity": "sha512-2W57zHs2yDLm6GD5ZpvNn71lZ0B/iypSdIeq25OurDKji6AdzV07qp4s3n1/x5BqtiGaTrPN3nerlSCaC5qNTw==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.21.5.tgz",
+ "integrity": "sha512-wH00QnTTldTbf/IefEVyChtRdw5RJvODT/Vb4Vcxq1AZvtXj6T0YeX0cAcXhI6/BdGuiP3GcNIL4OQbI2DVNxg==",
"requires": {
- "@babel/compat-data": "^7.21.4",
- "@babel/helper-compilation-targets": "^7.21.4",
- "@babel/helper-plugin-utils": "^7.20.2",
+ "@babel/compat-data": "^7.21.5",
+ "@babel/helper-compilation-targets": "^7.21.5",
+ "@babel/helper-plugin-utils": "^7.21.5",
"@babel/helper-validator-option": "^7.21.0",
"@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression": "^7.18.6",
"@babel/plugin-bugfix-v8-spread-parameters-in-optional-chaining": "^7.20.7",
@@ -8611,6 +8631,7 @@
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
"@babel/plugin-syntax-export-namespace-from": "^7.8.3",
"@babel/plugin-syntax-import-assertions": "^7.20.0",
+ "@babel/plugin-syntax-import-meta": "^7.10.4",
"@babel/plugin-syntax-json-strings": "^7.8.3",
"@babel/plugin-syntax-logical-assignment-operators": "^7.10.4",
"@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3",
@@ -8620,22 +8641,22 @@
"@babel/plugin-syntax-optional-chaining": "^7.8.3",
"@babel/plugin-syntax-private-property-in-object": "^7.14.5",
"@babel/plugin-syntax-top-level-await": "^7.14.5",
- "@babel/plugin-transform-arrow-functions": "^7.20.7",
+ "@babel/plugin-transform-arrow-functions": "^7.21.5",
"@babel/plugin-transform-async-to-generator": "^7.20.7",
"@babel/plugin-transform-block-scoped-functions": "^7.18.6",
"@babel/plugin-transform-block-scoping": "^7.21.0",
"@babel/plugin-transform-classes": "^7.21.0",
- "@babel/plugin-transform-computed-properties": "^7.20.7",
+ "@babel/plugin-transform-computed-properties": "^7.21.5",
"@babel/plugin-transform-destructuring": "^7.21.3",
"@babel/plugin-transform-dotall-regex": "^7.18.6",
"@babel/plugin-transform-duplicate-keys": "^7.18.9",
"@babel/plugin-transform-exponentiation-operator": "^7.18.6",
- "@babel/plugin-transform-for-of": "^7.21.0",
+ "@babel/plugin-transform-for-of": "^7.21.5",
"@babel/plugin-transform-function-name": "^7.18.9",
"@babel/plugin-transform-literals": "^7.18.9",
"@babel/plugin-transform-member-expression-literals": "^7.18.6",
"@babel/plugin-transform-modules-amd": "^7.20.11",
- "@babel/plugin-transform-modules-commonjs": "^7.21.2",
+ "@babel/plugin-transform-modules-commonjs": "^7.21.5",
"@babel/plugin-transform-modules-systemjs": "^7.20.11",
"@babel/plugin-transform-modules-umd": "^7.18.6",
"@babel/plugin-transform-named-capturing-groups-regex": "^7.20.5",
@@ -8643,17 +8664,17 @@
"@babel/plugin-transform-object-super": "^7.18.6",
"@babel/plugin-transform-parameters": "^7.21.3",
"@babel/plugin-transform-property-literals": "^7.18.6",
- "@babel/plugin-transform-regenerator": "^7.20.5",
+ "@babel/plugin-transform-regenerator": "^7.21.5",
"@babel/plugin-transform-reserved-words": "^7.18.6",
"@babel/plugin-transform-shorthand-properties": "^7.18.6",
"@babel/plugin-transform-spread": "^7.20.7",
"@babel/plugin-transform-sticky-regex": "^7.18.6",
"@babel/plugin-transform-template-literals": "^7.18.9",
"@babel/plugin-transform-typeof-symbol": "^7.18.9",
- "@babel/plugin-transform-unicode-escapes": "^7.18.10",
+ "@babel/plugin-transform-unicode-escapes": "^7.21.5",
"@babel/plugin-transform-unicode-regex": "^7.18.6",
"@babel/preset-modules": "^0.1.5",
- "@babel/types": "^7.21.4",
+ "@babel/types": "^7.21.5",
"babel-plugin-polyfill-corejs2": "^0.3.3",
"babel-plugin-polyfill-corejs3": "^0.6.0",
"babel-plugin-polyfill-regenerator": "^0.4.1",
@@ -8697,28 +8718,28 @@
}
},
"@babel/traverse": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.21.4.tgz",
- "integrity": "sha512-eyKrRHKdyZxqDm+fV1iqL9UAHMoIg0nDaGqfIOd8rKH17m5snv7Gn4qgjBoFfLz9APvjFU/ICT00NVCv1Epp8Q==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.21.5.tgz",
+ "integrity": "sha512-AhQoI3YjWi6u/y/ntv7k48mcrCXmus0t79J9qPNlk/lAsFlCiJ047RmbfMOawySTHtywXhbXgpx/8nXMYd+oFw==",
"requires": {
"@babel/code-frame": "^7.21.4",
- "@babel/generator": "^7.21.4",
- "@babel/helper-environment-visitor": "^7.18.9",
+ "@babel/generator": "^7.21.5",
+ "@babel/helper-environment-visitor": "^7.21.5",
"@babel/helper-function-name": "^7.21.0",
"@babel/helper-hoist-variables": "^7.18.6",
"@babel/helper-split-export-declaration": "^7.18.6",
- "@babel/parser": "^7.21.4",
- "@babel/types": "^7.21.4",
+ "@babel/parser": "^7.21.5",
+ "@babel/types": "^7.21.5",
"debug": "^4.1.0",
"globals": "^11.1.0"
}
},
"@babel/types": {
- "version": "7.21.4",
- "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.21.4.tgz",
- "integrity": "sha512-rU2oY501qDxE8Pyo7i/Orqma4ziCOrby0/9mvbDUGEfvZjb279Nk9k19e2fiCxHbRRpY2ZyrgW1eq22mvmOIzA==",
+ "version": "7.21.5",
+ "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.21.5.tgz",
+ "integrity": "sha512-m4AfNvVF2mVC/F7fDEdH2El3HzUg9It/XsCxZiOTTA3m3qYfcSVSbTfM6Q9xG+hYDniZssYhlXKKUMD5m8tF4Q==",
"requires": {
- "@babel/helper-string-parser": "^7.19.4",
+ "@babel/helper-string-parser": "^7.21.5",
"@babel/helper-validator-identifier": "^7.19.1",
"to-fast-properties": "^2.0.0"
}
@@ -10071,9 +10092,9 @@
"integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow=="
},
"electron": {
- "version": "24.1.2",
- "resolved": "https://registry.npmjs.org/electron/-/electron-24.1.2.tgz",
- "integrity": "sha512-V0isWbyLYiXrSCcB4lrSVhS/U56NFGfuqHyc+yEPkyhhvY+h4F85cYGdEiZlXp6XjHT+/CLHmw0ltK54g9lvDw==",
+ "version": "24.2.0",
+ "resolved": "https://registry.npmjs.org/electron/-/electron-24.2.0.tgz",
+ "integrity": "sha512-fEYAftYqFhveniWJbEHXjNMWjooFFIuqNj/eEFJkGzycInfBJq/c4E/dew++s6s0YLubxFnjoF2qZiqapLj0gA==",
"requires": {
"@electron/get": "^2.0.0",
"@types/node": "^18.11.18",
@@ -10104,9 +10125,9 @@
}
},
"engine.io": {
- "version": "6.4.1",
- "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-6.4.1.tgz",
- "integrity": "sha512-JFYQurD/nbsA5BSPmbaOSLa3tSVj8L6o4srSwXXY3NqE+gGUNmmPTbhn8tjzcCtSqhFgIeqef81ngny8JM25hw==",
+ "version": "6.4.2",
+ "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-6.4.2.tgz",
+ "integrity": "sha512-FKn/3oMiJjrOEOeUub2WCox6JhxBXq/Zn3fZOMCBxKnNYtsdKjxhl7yR3fZhM9PV+rdE75SU5SYMc+2PGzo+Tg==",
"requires": {
"@types/cookie": "^0.4.1",
"@types/cors": "^2.8.12",
diff --git a/renovate.json b/renovate.json
new file mode 100644
index 0000000..39a2b6e
--- /dev/null
+++ b/renovate.json
@@ -0,0 +1,6 @@
+{
+ "$schema": "https://docs.renovatebot.com/renovate-schema.json",
+ "extends": [
+ "config:base"
+ ]
+}
diff --git a/srcissors.js b/srcissors.js
index 926e90a..f98cf5d 100644
--- a/srcissors.js
+++ b/srcissors.js
@@ -1,2 +1,2 @@
-!function(i,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof exports?exports.srcissors=t(require("jquery")):i.srcissors=t(i.jQuery)}(window,(function(i){return function(i){var t={};function e(s){if(t[s])return t[s].exports;var n=t[s]={i:s,l:!1,exports:{}};return i[s].call(n.exports,n,n.exports,e),n.l=!0,n.exports}return e.m=i,e.c=t,e.d=function(i,t,s){e.o(i,t)||Object.defineProperty(i,t,{enumerable:!0,get:s})},e.r=function(i){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(i,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(i,"__esModule",{value:!0})},e.t=function(i,t){if(1&t&&(i=e(i)),8&t)return i;if(4&t&&"object"==typeof i&&i&&i.__esModule)return i;var s=Object.create(null);if(e.r(s),Object.defineProperty(s,"default",{enumerable:!0,value:i}),2&t&&"string"!=typeof i)for(var n in i)e.d(s,n,function(t){return i[t]}.bind(null,n));return s},e.n=function(i){var t=i&&i.__esModule?function(){return i.default}:function(){return i};return e.d(t,"a",t),t},e.o=function(i,t){return Object.prototype.hasOwnProperty.call(i,t)},e.p="",e(e.s=1)}([function(t,e){t.exports=i},function(i,t,e){var s=e(0),n=e(2);i.exports={new:function(i){var t=i.arena,e=i.url,h=i.fixedWidth,o=i.fixedHeight,a=i.minWidth,r=i.minHeight,u=i.minRatio,c=i.maxRatio,l=i.maxArea,g=i.originalSize,d=i.zoomStep,v=i.crop,m=i.actions,w=i.minResolution,p=i.surroundingImageOpacity,f=i.showSurroundingImage,y=(t=s(t)).find(".crop-view"),x=y.find(".crop-preview"),k=s("
![]()
");x.append(k);var R=y.find(".crop-outline");R.length||(R=void 0);var z={pan:!0,zoomOnDoubleClick:!0,resize:!0,resizeHorizontal:!h,resizeVertical:!o};return s.extend(z,m),null==d&&(d=1.25),null==a&&(a=50),null==r&&(r=50),new n({url:e,crop:v,arena:t,view:y,img:k,outline:R,showSurroundingImage:f,surroundingImageOpacity:p,fixedWidth:h,fixedHeight:o,minViewWidth:a,minViewHeight:r,minViewRatio:u,maxViewRatio:c,maxArea:l,originalSize:g,zoomStep:d,actions:z,minResolution:w})}}},function(i,t,e){function s(i,t){var e;if("undefined"==typeof Symbol||null==i[Symbol.iterator]){if(Array.isArray(i)||(e=function(i,t){if(!i)return;if("string"==typeof i)return n(i,t);var e=Object.prototype.toString.call(i).slice(8,-1);"Object"===e&&i.constructor&&(e=i.constructor.name);if("Map"===e||"Set"===e)return Array.from(i);if("Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return n(i,t)}(i))||t&&i&&"number"==typeof i.length){e&&(i=e);var s=0,h=function(){};return{s:h,n:function(){return s>=i.length?{done:!0}:{done:!1,value:i[s++]}},e:function(i){throw i},f:h}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,r=!1;return{s:function(){e=i[Symbol.iterator]()},n:function(){var i=e.next();return a=i.done,i},e:function(i){r=!0,o=i},f:function(){try{a||null==e.return||e.return()}finally{if(r)throw o}}}}function n(i,t){(null==t||t>i.length)&&(t=i.length);for(var e=0,s=new Array(t);e
h&&delete this.minResolution,this.minResolution){var o=this.minResolution/(this.imageHeight*this.imageHeight);(!this.minViewRatio||this.minViewRatioa)&&(this.maxViewRatio=a)}this.calcMaxMinDimensions(),this.fixedWidth&&(t="width"),this.fixedHeight&&(t="height"),this.setViewDimensions({width:this.imageWidth,height:this.imageHeight,keepDimension:t}),this.isReady=!0,this.view.removeClass(this.loadingCssClass),this.isInitialized||null==this.initialCrop?(this.zoomAllOut(),this.center()):this.setCrop(this.initialCrop),this.isInitialized=!0,this.readyEvent.fire(),this.loadEvent.fire()}},{key:"setCrop",value:function(i){var t=this,e=i.x,s=i.y,n=i.width,h=i.height;if(this.isReady){this.resize({width:n,height:h});var o=this.viewWidth/n,a=this.imageWidth*o;this.zoom({width:a}),this.pan({x:e*o,y:s*o})}else this.on("ready",(function(){return t.setCrop({x:e,y:s,width:n,height:h})}))}},{key:"getCrop",value:function(){var i=this.preview.width/this.imageWidth,t={x:this.preview.x/i,y:this.preview.y/i,width:this.viewWidth/i,height:this.viewHeight/i};return this.roundCrop(t),this.validateCrop(t),t}},{key:"roundCrop",value:function(i){for(var t in i){var e=i[t];i[t]=Math.round(e)}}},{key:"validateCrop",value:function(i){var t=i.x,e=i.y,s=i.width,n=i.height;return t+s>this.imageWidth?i.width=this.imageWidth-t:e+n>this.imageHeight&&(i.height=this.imageHeight-e),i}},{key:"setRatio",value:function(i,t){var e,s,n=this;if(this.isReady)return i=this.enforceValidRatio(i),"height"===t?s=(e=this.viewHeight)*i:e=(s=this.viewWidth)/i,this.resizeFocusPoint=this.getFocusPoint(),this.resize({width:s,height:e});this.on("ready",(function(){return n.setRatio(i,t)}))}},{key:"onPan",value:function(i){this.isPanning||(this.isPanning=!0,this.arena.addClass(this.panningCssClass),this.outline.addClass(this.outlineCssClass));var t=i.startX-i.dx,e=i.startY-i.dy;this.pan({x:t,y:e})}},{key:"onPanEnd",value:function(){return this.isPanning=!1,this.arena.removeClass(this.panningCssClass),this.outline.removeClass(this.outlineCssClass)}},{key:"onDoubleClick",value:function(i){var t=i.pageX,e=i.pageY,s=this.view[0].getBoundingClientRect(),n=t-s.left,h=e-s.top;this.zoomIn({viewX:n,viewY:h})}},{key:"onResize",value:function(i){var t=i.position,e=i.dx,s=i.dy;this.isResizing||(this.isResizing=!0,this.resizeFocusPoint=this.getFocusPoint()),["top","bottom"].includes(t)?(s*=2,this.resize({width:this.viewWidth,height:this.viewHeight+s,keepDimension:"height"})):["left","right"].includes(t)&&(e*=2,this.resize({width:this.viewWidth+e,height:this.viewHeight,keepDimension:"width"}))}},{key:"onResizeEnd",value:function(){this.isResizing=!1,this.resizeFocusPoint=void 0}},{key:"resize",value:function(i){var t=i.width,e=i.height,s=i.keepDimension;this.setViewDimensions({width:t,height:e,keepDimension:s}),this.resizeFocusPoint&&(this.resizeFocusPoint.viewX=this.viewWidth/2,this.resizeFocusPoint.viewY=this.viewHeight/2),this.zoom({width:this.preview.width,height:this.preview.height,focusPoint:this.resizeFocusPoint})}},{key:"setViewDimensions",value:function(i){var t=i.width,e=i.height,s=i.keepDimension;if(this.maxArea){var n=this.enforceMaxArea({width:t,height:e,keepDimension:s});t=n.width,e=n.height}var h=this.enforceViewDimensions({width:t,height:e,keepDimension:s});if(t=h.width,e=h.height,this.view.css({width:t,height:e}),this.viewWidth=t,this.viewHeight=e,this.viewRatio=t/e,this.minResolution){var o=Math.sqrt(this.minResolution*this.viewRatio),a=Math.sqrt(this.minResolution/this.viewRatio);this.maxImageWidth=this.viewWidth/o*this.imageWidth,this.maxImageHeight=this.viewHeight/a*this.imageHeight}this.fireChange()}},{key:"zoomAllOut",value:function(){this.isWidthRestricting()?this.zoom({width:this.viewWidth}):this.zoom({height:this.viewHeight})}},{key:"zoomIn",value:function(i){null==i&&(i={}),this.isWidthRestricting()?i.width=this.preview.width*this.zoomInStep:i.height=this.preview.height*this.zoomInStep,this.zoom(i)}},{key:"zoomOut",value:function(i){null==i&&(i={}),this.isWidthRestricting()?i.width=this.preview.width*this.zoomOutStep:i.height=this.preview.height*this.zoomOutStep,this.zoom(i)}},{key:"zoom",value:function(i){var t=i.width,e=i.height,s=i.viewX,n=i.viewY,h=i.focusPoint;null==h&&(h=this.getFocusPoint({viewX:s,viewY:n}));var o=this.enforceZoom({width:t,height:e});t=o.width,e=o.height,null!=t?(this.preview.setWidth(t),this.fireChange()):null!=e&&(this.preview.setHeight(e),this.fireChange()),this.focus(h)}},{key:"getFocusPoint",value:function(i){null==i&&(i={});var t=i,e=t.viewX,s=t.viewY;null==e&&(e=this.viewWidth/2),null==s&&(s=this.viewHeight/2);var n=this.preview.x+e,h=this.preview.y+s;return{percentX:n/this.preview.width,percentY:h/this.preview.height,viewX:e,viewY:s}}},{key:"focus",value:function(i){var t=i.percentX,e=i.percentY,s=i.viewX,n=i.viewY,h=this.preview.width*t,o=this.preview.height*e;h-=s,o-=n,this.pan({x:h,y:o})}},{key:"center",value:function(){var i=(this.preview.width-this.viewWidth)/2,t=(this.preview.height-this.viewHeight)/2;this.pan({x:i,y:t})}},{key:"pan",value:function(i){i=this.enforceXy(i),this.preview.pan(i.x,i.y),this.fireChange()}},{key:"enforceXy",value:function(i){var t=i.x,e=i.y;return t<0?t=0:t>this.preview.width-this.viewWidth&&(t=this.preview.width-this.viewWidth),e<0?e=0:e>this.preview.height-this.viewHeight&&(e=this.preview.height-this.viewHeight),{x:t,y:e}}},{key:"enforceZoom",value:function(i){var t=i.width,e=i.height;return null!=t&&this.maxImageWidth&&t>this.maxImageWidth?{width:this.maxImageWidth}:null!=t&&tthis.maxImageHeight?{height:this.maxImageHeight}:null!=e&ðis.maxWidth||ethis.maxHeight||sthis.maxViewRatio)}},{key:"isValidRatio",value:function(i){return!(ithis.maxViewRatio)}},{key:"enforceValidRatio",value:function(i){return ithis.maxViewRatio?this.maxViewRatio:i}},{key:"enforceViewDimensions",value:function(i){var t,e,s,n=i.width,h=i.height,o=i.keepDimension;if(nthis.maxWidth&&(e=this.maxWidth),hthis.maxHeight&&(t=this.maxHeight),o){if(e&&(n=e),t&&(h=t),s=n/h,!this.isValidRatio(s)){s=this.enforceValidRatio(s);var a=this.getRatioBox({ratio:s,width:n,height:h,keepDimension:o});if(n=a.width,h=a.height,n>this.arenaWidth||h>this.arenaHeight){var r=this.centerAlign(this.maxWidth,this.maxHeight,s);n=r.width,h=r.height}}}else if(e||t){s=this.enforceValidRatio(n/h);var u=this.centerAlign(this.maxWidth,this.maxHeight,s);n=u.width,h=u.height}return{width:n,height:h}}},{key:"enforceMaxArea",value:function(i){var t=i.width,e=i.height,s=i.keepDimension,n=t/e;return"width"===s?n=t/(e=this.maxArea/t):"height"===s?n=(t=this.maxArea/e)/e:e=(t=Math.sqrt(this.maxArea*n))/n,this.isValidRatio(n)||(n=this.enforceValidRatio(n),e=(t=Math.sqrt(this.maxArea*n))/n),{width:t,height:e}}},{key:"checkRatio",value:function(i){if(this.originalSize){var t=this.originalSize.width/this.originalSize.height,e=i.width/i.height,s=(e-t)/t*100;if(Math.abs(s)>1)throw new Error("srcissors: Displayed image has a different image ratio than the "+"one configured in 'originalRatio': ".concat(t," vs ").concat(e))}}},{key:"isWidthRestricting",value:function(){return this.viewRatio>=this.imageRatio}},{key:"getRatioBox",value:function(i){var t=i.ratio,e=i.width,s=i.height,n=i.keepDimension;return"width"===n||null==s?s=e/t:"height"===n||null==e?e=s*t:s=e/t,{width:e,height:s}}},{key:"centerAlign",value:function(i,t,e){var s,n,h,o;return i/t>e?h=(i-(n=t*e))/2:o=(t-(s=i/e))/2,{x:h||0,y:o||0,width:n||i,height:s||t}}},{key:"min",value:function(i){var t,e=i[0],n=s(i);try{for(n.s();!(t=n.n()).done;){var h=t.value;h0){var e=n("
").css({opacity:this.opacity}).attr("src",t);this.outline.append(e)}}},{key:"reset",value:function(){this.url=void 0,this.x=this.y=0,this.width=this.height=0,this.img.attr("src",""),this.img.css({width:"",height:"",transform:""}),this.outline&&this.outline.css({transform:""}).html("")}},{key:"setWidth",value:function(i){this.img.css({width:"".concat(i,"px"),height:"auto"});var t=i/this.ratio;this.updateImageDimensions({width:i,height:t})}},{key:"setHeight",value:function(i){this.img.css({width:"auto",height:"".concat(i,"px")});var t=i*this.ratio;this.updateImageDimensions({width:t,height:i})}},{key:"updateImageDimensions",value:function(i){var t=i.width,e=i.height;this.width=t,this.height=e,this.outline&&this.outline.css({width:"".concat(this.width,"px"),height:"".concat(this.height,"px")})}},{key:"pan",value:function(i,t){this.x=i,this.y=t;var e=Math.round(this.x),s=Math.round(this.y);this.img.css({transform:"translate(-".concat(e,"px, -").concat(s,"px)")}),this.outline&&this.outline.css({transform:"translate(-".concat(e,"px, -").concat(s,"px)")})}}])&&s(t.prototype,e),h&&s(t,h),i}()},function(i,t,e){function s(i,t){for(var e=0;es-t.doubleClickThreshold&&t.parent.onDoubleClick(h(e)),i=s}))}},{key:"preventBrowserDragDrop",value:function(){this.view.on("dragstart.srcissors",(function(){return!1}))}},{key:"resizeView",value:function(i){var t=this,e=i.horizontal,s=i.vertical,h=n("");h.addClass("resize-handler");var o=[];e&&(o=o.concat(["right","left"])),s&&(o=o.concat(["top","bottom"])),o.forEach((function(i){var e=h.clone();e.addClass("resize-handler-".concat(i)),e.on("mousedown.srcissors touchstart.srcissors",t.getResizeMouseDown(i)),t.view.append(e)}))}},{key:"getResizeMouseDown",value:function(i){var t=this,e=n(document);return function(s){var n=h(s),o=n.pageX,a=n.pageY;s.stopPropagation(),e.on("mousemove.srcissors-resize touchmove.srcissors-resize",(function(e){var s,n,r=h(e),u=r.pageX,c=r.pageY;switch(i){case"top":case"bottom":n=c-a,"top"===i&&(n=-n),a=c;break;case"left":case"right":s=u-o,"left"===i&&(s=-s),o=u}t.parent.onResize({position:i,dx:s,dy:n})})).on("mouseup.srcissors-resize touchend.srcissors-resize",(function(){e.off("mouseup.srcissors-resize touchmove.srcissors-resize"),e.off("mousemove.srcissors-resize touchend.srcissors-resize"),t.parent.onResizeEnd({position:i})}))}}},{key:"responsiveArena",value:function(){}}])&&s(t.prototype,e),o&&s(t,o),i}()}])}));
+!function(i,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof exports?exports.srcissors=t(require("jquery")):i.srcissors=t(i.jQuery)}(self,(i=>{return t={490:(i,t,e)=>{function n(i){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(i){return typeof i}:function(i){return i&&"function"==typeof Symbol&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},n(i)}function s(i,t){(null==t||t>i.length)&&(t=i.length);for(var e=0,n=new Array(t);e
h&&delete this.minResolution,this.minResolution){var o=this.minResolution/(this.imageHeight*this.imageHeight);(!this.minViewRatio||this.minViewRatior)&&(this.maxViewRatio=r)}this.calcMaxMinDimensions(),this.fixedWidth&&(t="width"),this.fixedHeight&&(t="height"),this.setViewDimensions({width:this.imageWidth,height:this.imageHeight,keepDimension:t}),this.isReady=!0,this.view.removeClass(this.loadingCssClass),this.isInitialized||null==this.initialCrop?(this.zoomAllOut(),this.center()):this.setCrop(this.initialCrop),this.isInitialized=!0,this.readyEvent.fire(),this.loadEvent.fire()}},{key:"setCrop",value:function(i){var t=this,e=i.x,n=i.y,s=i.width,h=i.height;if(this.isReady){this.resize({width:s,height:h});var o=this.viewWidth/s,r=this.imageWidth*o;this.zoom({width:r}),this.pan({x:e*o,y:n*o})}else this.on("ready",(function(){return t.setCrop({x:e,y:n,width:s,height:h})}))}},{key:"getCrop",value:function(){var i=this.preview.width/this.imageWidth,t={x:this.preview.x/i,y:this.preview.y/i,width:this.viewWidth/i,height:this.viewHeight/i};return this.roundCrop(t),this.validateCrop(t),t}},{key:"roundCrop",value:function(i){for(var t in i){var e=i[t];i[t]=Math.round(e)}}},{key:"validateCrop",value:function(i){var t=i.x,e=i.y,n=i.width,s=i.height;return t<0&&(i.x=0),e<0&&(i.y=0),t+n>this.imageWidth&&(i.width=this.imageWidth-t),e+s>this.imageHeight&&(i.height=this.imageHeight-e),i}},{key:"setRatio",value:function(i,t){var e,n,s=this;if(this.isReady)return i=this.enforceValidRatio(i),"height"===t?n=(e=this.viewHeight)*i:e=(n=this.viewWidth)/i,this.resizeFocusPoint=this.getFocusPoint(),this.resize({width:n,height:e});this.on("ready",(function(){return s.setRatio(i,t)}))}},{key:"onPan",value:function(i){this.isPanning||(this.isPanning=!0,this.arena.addClass(this.panningCssClass),this.outline.addClass(this.outlineCssClass));var t=i.startX-i.dx,e=i.startY-i.dy;this.pan({x:t,y:e})}},{key:"onPanEnd",value:function(){return this.isPanning=!1,this.arena.removeClass(this.panningCssClass),this.outline.removeClass(this.outlineCssClass)}},{key:"onDoubleClick",value:function(i){var t=i.pageX,e=i.pageY,n=this.view[0].getBoundingClientRect(),s=t-n.left,h=e-n.top;this.zoomIn({viewX:s,viewY:h})}},{key:"onResize",value:function(i){var t=i.position,e=i.dx,n=i.dy;this.isResizing||(this.isResizing=!0,this.resizeFocusPoint=this.getFocusPoint()),["top","bottom"].includes(t)?(n*=2,this.resize({width:this.viewWidth,height:this.viewHeight+n,keepDimension:"height"})):["left","right"].includes(t)&&(e*=2,this.resize({width:this.viewWidth+e,height:this.viewHeight,keepDimension:"width"}))}},{key:"onResizeEnd",value:function(){this.isResizing=!1,this.resizeFocusPoint=void 0}},{key:"resize",value:function(i){var t=i.width,e=i.height,n=i.keepDimension;this.setViewDimensions({width:t,height:e,keepDimension:n}),this.resizeFocusPoint&&(this.resizeFocusPoint.viewX=this.viewWidth/2,this.resizeFocusPoint.viewY=this.viewHeight/2),this.zoom({width:this.preview.width,height:this.preview.height,focusPoint:this.resizeFocusPoint})}},{key:"setViewDimensions",value:function(i){var t=i.width,e=i.height,n=i.keepDimension;if(this.maxArea){var s=this.enforceMaxArea({width:t,height:e,keepDimension:n});t=s.width,e=s.height}var h=this.enforceViewDimensions({width:t,height:e,keepDimension:n});if(t=h.width,e=h.height,this.view.css({width:t,height:e}),this.viewWidth=t,this.viewHeight=e,this.viewRatio=t/e,this.minResolution){var o=Math.sqrt(this.minResolution*this.viewRatio),r=Math.sqrt(this.minResolution/this.viewRatio);this.maxImageWidth=this.viewWidth/o*this.imageWidth,this.maxImageHeight=this.viewHeight/r*this.imageHeight}this.fireChange()}},{key:"zoomAllOut",value:function(){this.isWidthRestricting()?this.zoom({width:this.viewWidth}):this.zoom({height:this.viewHeight})}},{key:"zoomIn",value:function(i){null==i&&(i={}),this.isWidthRestricting()?i.width=this.preview.width*this.zoomInStep:i.height=this.preview.height*this.zoomInStep,this.zoom(i)}},{key:"zoomOut",value:function(i){null==i&&(i={}),this.isWidthRestricting()?i.width=this.preview.width*this.zoomOutStep:i.height=this.preview.height*this.zoomOutStep,this.zoom(i)}},{key:"zoom",value:function(i){var t=i.width,e=i.height,n=i.viewX,s=i.viewY,h=i.focusPoint;null==h&&(h=this.getFocusPoint({viewX:n,viewY:s}));var o=this.enforceZoom({width:t,height:e});t=o.width,e=o.height,null!=t?(this.preview.setWidth(t),this.fireChange()):null!=e&&(this.preview.setHeight(e),this.fireChange()),this.focus(h)}},{key:"getFocusPoint",value:function(i){null==i&&(i={});var t=i,e=t.viewX,n=t.viewY;null==e&&(e=this.viewWidth/2),null==n&&(n=this.viewHeight/2);var s=this.preview.x+e,h=this.preview.y+n;return{percentX:s/this.preview.width,percentY:h/this.preview.height,viewX:e,viewY:n}}},{key:"focus",value:function(i){var t=i.percentX,e=i.percentY,n=i.viewX,s=i.viewY,h=this.preview.width*t,o=this.preview.height*e;h-=n,o-=s,this.pan({x:h,y:o})}},{key:"center",value:function(){var i=(this.preview.width-this.viewWidth)/2,t=(this.preview.height-this.viewHeight)/2;this.pan({x:i,y:t})}},{key:"pan",value:function(i){i=this.enforceXy(i),this.preview.pan(i.x,i.y),this.fireChange()}},{key:"enforceXy",value:function(i){var t=i.x,e=i.y;return t>this.preview.width-this.viewWidth&&(t=this.preview.width-this.viewWidth),t<0&&(t=0),e>this.preview.height-this.viewHeight&&(e=this.preview.height-this.viewHeight),e<0&&(e=0),{x:t,y:e}}},{key:"enforceZoom",value:function(i){var t=i.width,e=i.height;return null!=t&&this.maxImageWidth&&t>this.maxImageWidth?{width:this.maxImageWidth}:null!=t&&tthis.maxImageHeight?{height:this.maxImageHeight}:null!=e&ðis.maxWidth||ethis.maxHeight||nthis.maxViewRatio)}},{key:"isValidRatio",value:function(i){return!(ithis.maxViewRatio)}},{key:"enforceValidRatio",value:function(i){return ithis.maxViewRatio?this.maxViewRatio:i}},{key:"enforceViewDimensions",value:function(i){var t,e,n,s=i.width,h=i.height,o=i.keepDimension;if(sthis.maxWidth&&(e=this.maxWidth),hthis.maxHeight&&(t=this.maxHeight),o){if(e&&(s=e),t&&(h=t),n=s/h,!this.isValidRatio(n)){n=this.enforceValidRatio(n);var r=this.getRatioBox({ratio:n,width:s,height:h,keepDimension:o});if(s=r.width,h=r.height,s>this.arenaWidth||h>this.arenaHeight){var a=this.centerAlign(this.maxWidth,this.maxHeight,n);s=a.width,h=a.height}}}else if(e||t){n=this.enforceValidRatio(s/h);var u=this.centerAlign(this.maxWidth,this.maxHeight,n);s=u.width,h=u.height}return{width:s,height:h}}},{key:"enforceMaxArea",value:function(i){var t=i.width,e=i.height,n=i.keepDimension,s=t/e;return"width"===n?s=t/(e=this.maxArea/t):"height"===n?s=(t=this.maxArea/e)/e:e=(t=Math.sqrt(this.maxArea*s))/s,this.isValidRatio(s)||(s=this.enforceValidRatio(s),e=(t=Math.sqrt(this.maxArea*s))/s),{width:t,height:e}}},{key:"checkRatio",value:function(i){if(this.originalSize){var t=this.originalSize.width/this.originalSize.height,e=i.width/i.height,n=(e-t)/t*100;if(Math.abs(n)>1)throw new Error("srcissors: Displayed image has a different image ratio than the "+"one configured in 'originalRatio': ".concat(t," vs ").concat(e))}}},{key:"isWidthRestricting",value:function(){return this.viewRatio>=this.imageRatio}},{key:"getRatioBox",value:function(i){var t=i.ratio,e=i.width,n=i.height,s=i.keepDimension;return"width"===s||null==n?n=e/t:"height"===s||null==e?e=n*t:n=e/t,{width:e,height:n}}},{key:"centerAlign",value:function(i,t,e){var n,s,h,o;return i/t>e?h=(i-(s=t*e))/2:o=(t-(n=i/e))/2,{x:h||0,y:o||0,width:s||i,height:n||t}}},{key:"min",value:function(i){var t,e=i[0],n=function(i,t){var e="undefined"!=typeof Symbol&&i[Symbol.iterator]||i["@@iterator"];if(!e){if(Array.isArray(i)||(e=function(i,t){if(i){if("string"==typeof i)return s(i,t);var e=Object.prototype.toString.call(i).slice(8,-1);return"Object"===e&&i.constructor&&(e=i.constructor.name),"Map"===e||"Set"===e?Array.from(i):"Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?s(i,t):void 0}}(i))||t&&i&&"number"==typeof i.length){e&&(i=e);var n=0,h=function(){};return{s:h,n:function(){return n>=i.length?{done:!0}:{done:!1,value:i[n++]}},e:function(i){throw i},f:h}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,r=!0,a=!1;return{s:function(){e=e.call(i)},n:function(){var i=e.next();return r=i.done,i},e:function(i){a=!0,o=i},f:function(){try{r||null==e.return||e.return()}finally{if(a)throw o}}}}(i);try{for(n.s();!(t=n.n()).done;){var h=t.value;h{function n(i){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(i){return typeof i}:function(i){return i&&"function"==typeof Symbol&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},n(i)}function s(i,t){for(var e=0;en-t.doubleClickThreshold&&t.parent.onDoubleClick(o(e)),i=n}))}},{key:"preventBrowserDragDrop",value:function(){this.view.on("dragstart.srcissors",(function(){return!1}))}},{key:"resizeView",value:function(i){var t=this,e=i.horizontal,n=i.vertical,s=h("");s.addClass("resize-handler");var o=[];e&&(o=o.concat(["right","left"])),n&&(o=o.concat(["top","bottom"])),o.forEach((function(i){var e=s.clone();e.addClass("resize-handler-".concat(i)),e.on("mousedown.srcissors touchstart.srcissors",t.getResizeMouseDown(i)),t.view.append(e)}))}},{key:"getResizeMouseDown",value:function(i){var t=this,e=h(document);return function(n){var s=o(n),h=s.pageX,r=s.pageY;n.stopPropagation(),e.on("mousemove.srcissors-resize touchmove.srcissors-resize",(function(e){var n,s,a=o(e),u=a.pageX,c=a.pageY;switch(i){case"top":case"bottom":s=c-r,"top"===i&&(s=-s),r=c;break;case"left":case"right":n=u-h,"left"===i&&(n=-n),h=u}t.parent.onResize({position:i,dx:n,dy:s})})).on("mouseup.srcissors-resize touchend.srcissors-resize",(function(){e.off("mouseup.srcissors-resize touchmove.srcissors-resize"),e.off("mousemove.srcissors-resize touchend.srcissors-resize"),t.parent.onResizeEnd({position:i})}))}}},{key:"responsiveArena",value:function(){}}])&&s(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),i}()},289:(i,t,e)=>{function n(i){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(i){return typeof i}:function(i){return i&&"function"==typeof Symbol&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},n(i)}function s(i,t){for(var e=0;e
0){var e=h("
").css({opacity:this.opacity}).attr("src",t);this.outline.append(e)}}},{key:"reset",value:function(){this.url=void 0,this.x=this.y=0,this.width=this.height=0,this.img.attr("src",""),this.img.css({width:"",height:"",transform:""}),this.outline&&this.outline.css({transform:""}).html("")}},{key:"setWidth",value:function(i){this.img.css({width:"".concat(i,"px"),height:"auto"});var t=i/this.ratio;this.updateImageDimensions({width:i,height:t})}},{key:"setHeight",value:function(i){this.img.css({width:"auto",height:"".concat(i,"px")});var t=i*this.ratio;this.updateImageDimensions({width:t,height:i})}},{key:"updateImageDimensions",value:function(i){var t=i.width,e=i.height;this.width=t,this.height=e,this.outline&&this.outline.css({width:"".concat(this.width,"px"),height:"".concat(this.height,"px")})}},{key:"pan",value:function(i,t){this.x=i,this.y=t;var e=Math.round(this.x),n=Math.round(this.y);this.img.css({transform:"translate(-".concat(e,"px, -").concat(n,"px)")}),this.outline&&this.outline.css({transform:"translate(-".concat(e,"px, -").concat(n,"px)")})}}])&&s(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),i}()},505:(i,t,e)=>{var n=e(47),s=e(490);i.exports={new:function(i){var t=i.arena,e=i.url,h=i.fixedWidth,o=i.fixedHeight,r=i.minWidth,a=i.minHeight,u=i.minRatio,c=i.maxRatio,l=i.maxArea,g=i.originalSize,v=i.zoomStep,d=i.crop,m=i.actions,p=i.minResolution,f=i.surroundingImageOpacity,w=i.showSurroundingImage,y=(t=n(t)).find(".crop-view"),x=y.find(".crop-preview"),b=n("
");x.append(b);var k=y.find(".crop-outline");k.length||(k=void 0);var R={pan:!0,zoomOnDoubleClick:!0,resize:!0,resizeHorizontal:!h,resizeVertical:!o};return n.extend(R,m),null==v&&(v=1.25),null==r&&(r=50),null==a&&(a=50),new s({url:e,crop:d,arena:t,view:y,img:b,outline:k,showSurroundingImage:w,surroundingImageOpacity:f,fixedWidth:h,fixedHeight:o,minViewWidth:r,minViewHeight:a,minViewRatio:u,maxViewRatio:c,maxArea:l,originalSize:g,zoomStep:v,actions:R,minResolution:p})}}},47:t=>{"use strict";t.exports=i}},e={},function i(n){var s=e[n];if(void 0!==s)return s.exports;var h=e[n]={exports:{}};return t[n](h,h.exports,i),h.exports}(505);var t,e}));
//# sourceMappingURL=srcissors.js.map
\ No newline at end of file
diff --git a/srcissors.js.map b/srcissors.js.map
index 8e58ae3..cb7b8cb 100644
--- a/srcissors.js.map
+++ b/srcissors.js.map
@@ -1 +1 @@
-{"version":3,"sources":["webpack://srcissors/srcissors.js"],"names":["root","factory","exports","module","require","define","amd","window","__WEBPACK_EXTERNAL_MODULE__0__","modules","installedModules","__webpack_require__","moduleId","i","l","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","$","Crop","new","_ref","arena","url","fixedWidth","fixedHeight","minWidth","minHeight","minRatio","maxRatio","maxArea","originalSize","zoomStep","crop","actions","minResolution","surroundingImageOpacity","showSurroundingImage","view","find","preview","img","append","outline","length","undefined","allowedActions","pan","zoomOnDoubleClick","resize","resizeHorizontal","resizeVertical","extend","minViewWidth","minViewHeight","minViewRatio","maxViewRatio","_createForOfIteratorHelper","allowArrayLike","it","iterator","Array","isArray","minLen","_arrayLikeToArray","toString","slice","constructor","from","test","_unsupportedIterableToArray","F","done","e","_e","f","TypeError","err","normalCompletion","didErr","step","next","_e2","return","arr","len","arr2","_defineProperties","target","props","descriptor","configurable","writable","Preview","Events","instance","Constructor","_classCallCheck","this","onPreviewReady","loadingCssClass","panningCssClass","outlineCssClass","isPanning","initialCrop","loadEvent","Callbacks","changeEvent","initializeReadyState","zoomInStep","zoomOutStep","arenaWidth","width","arenaHeight","height","setSurroundingImageVisibility","onReady","opacity","setImage","protoProps","staticProps","isReady","readyEvent","empty","isInitialized","reset","addClass","visibility","parseFloat","css","imageWidth","imageHeight","zoomAllOut","previewImageSize","checkRatio","keepDimension","_ref2","updateImageDimensions","events","parent","imageRatio","imageResolution","minRatioForResolution","maxRatioForResolution","calcMaxMinDimensions","setViewDimensions","removeClass","center","setCrop","fire","_ref3","_this","x","y","factor","viewWidth","previewWidth","zoom","on","viewHeight","roundCrop","validateCrop","Math","round","ratio","_this2","enforceValidRatio","resizeFocusPoint","getFocusPoint","setRatio","data","newX","startX","dx","newY","startY","dy","_ref4","pageX","pageY","_this$view$0$getBound","getBoundingClientRect","viewX","left","viewY","top","zoomIn","_ref5","position","isResizing","includes","_ref6","focusPoint","_ref7","_this$enforceMaxArea","enforceMaxArea","_this$enforceViewDime","enforceViewDimensions","viewRatio","minZoomPixelWidth","sqrt","minZoomPixelHeight","maxImageWidth","maxImageHeight","fireChange","isWidthRestricting","params","_ref8","_this$enforceZoom","enforceZoom","setWidth","setHeight","focus","param","_param","percentX","percentY","_ref9","enforceXy","_ref10","_ref11","maxWidth","min","maxHeight","_ref12","_ref13","newHeight","newWidth","isValidRatio","_this$getRatioBox","getRatioBox","_this$centerAlign","centerAlign","_this$centerAlign2","_ref14","expectedRatio","actualRatio","percentageChange","abs","Error","concat","_ref15","areaWidth","areaHeight","array","_step","_iterator","number","callback","add","remove","_this3","changeDispatch","setTimeout","getCrop","num","obj","image","previewXy","console","log","show","attr","setBackgroundImage","bgImg","transform","html","x1","y1","getPageCoordinates","event","type","originalEvent","changedTouches","horizontal","vertical","doubleClickThreshold","doubleClick","resizeView","preventBrowserDragDrop","responsiveArena","$doc","document","e1","panData","preventDefault","e2","_getPageCoordinates","_getPageCoordinates2","prevPageX","prevPageY","onPan","off","onPanEnd","lastClick","now","Date","getTime","onDoubleClick","$template","positions","forEach","$handler","clone","getResizeMouseDown","_this4","_getPageCoordinates3","lastX","lastY","stopPropagation","_getPageCoordinates4","onResize","onResizeEnd"],"mappings":"CAAA,SAA2CA,EAAMC,GAC1B,iBAAZC,SAA0C,iBAAXC,OACxCA,OAAOD,QAAUD,EAAQG,QAAQ,WACR,mBAAXC,QAAyBA,OAAOC,IAC9CD,OAAO,CAAC,UAAWJ,GACO,iBAAZC,QACdA,QAAmB,UAAID,EAAQG,QAAQ,WAEvCJ,EAAgB,UAAIC,EAAQD,EAAa,QAR3C,CASGO,QAAQ,SAASC,GACpB,OAAgB,SAAUC,GAEhB,IAAIC,EAAmB,GAGvB,SAASC,EAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUV,QAG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gBrP,GAET,MAAZF,IAAoBA,EAAW,MAEnB,MAAZ2I,IAAoBA,EAAW,IAClB,MAAbC,IAAqBA,EAAY,IAE9B,IAAI3J,EAAK,CACdM,IAAAA,EACAQ,KAAAA,EACAZ,MAAAA,EACAC,KAAAA,EACAC,IAAAA,EACAC,QAAAA,EACAe,qBAAAA,EACAD,wBAAAA,EACAZ,WAAAA,EACAC,YAAAA,EACAC,aAAciJ,EACdhJ,cAAeiJ,EACfhJ,aAAcuP,EACdtP,aAAcuP,EACdnP,QAAAA,EACAH,aAAAA,EAGAE,SAAAA,EACAE,QAASqP,EACTpP,cAAAA,GAEJ,E,sBCvDF3B,EAAOD,QAAUM,C,GCCb4Q,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBlJ,IAAjBmJ,EACH,OAAOA,EAAarR,QAGrB,IAAIC,EAASiR,EAAyBE,GAAY,CAGjDpR,QAAS,CAAC,GAOX,OAHAsR,EAAoBF,GAAUnR,EAAQA,EAAOD,QAASmR,GAG/ClR,EAAOD,OACf,CCnB0BmR,CAAoB,K,MDF1CD,C","sources":["webpack://srcissors/webpack/universalModuleDefinition","webpack://srcissors/./src/crop.js","webpack://srcissors/./src/events.js","webpack://srcissors/./src/preview.js","webpack://srcissors/./src/srcissors.js","webpack://srcissors/external umd {\"commonjs\":\"jquery\",\"commonjs2\":\"jquery\",\"amd\":\"jquery\",\"root\":\"jQuery\"}","webpack://srcissors/webpack/bootstrap","webpack://srcissors/webpack/startup"],"sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory(require(\"jquery\"));\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([\"jquery\"], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"srcissors\"] = factory(require(\"jquery\"));\n\telse\n\t\troot[\"srcissors\"] = factory(root[\"jQuery\"]);\n})(self, (__WEBPACK_EXTERNAL_MODULE__47__) => {\nreturn ","const $ = require('jquery')\nconst Preview = require('./preview')\nconst Events = require('./events')\n\nmodule.exports = class Crop {\n constructor ({\n arena, view, img, outline, url, fixedWidth, fixedHeight,\n minViewWidth, minViewHeight, minViewRatio, maxViewRatio, originalSize, crop,\n zoomStep, maxArea, actions, minResolution, surroundingImageOpacity,\n showSurroundingImage\n }) {\n // CSS classes\n this.onPreviewReady = this.onPreviewReady.bind(this)\n this.arena = arena\n this.view = view\n this.img = img\n this.outline = outline\n this.fixedWidth = fixedWidth\n this.fixedHeight = fixedHeight\n this.minViewWidth = minViewWidth\n this.minViewHeight = minViewHeight\n this.minViewRatio = minViewRatio\n this.maxViewRatio = maxViewRatio\n this.originalSize = originalSize\n this.actions = actions\n this.minResolution = minResolution\n this.surroundingImageOpacity = surroundingImageOpacity\n this.loadingCssClass = 'crop-view--is-loading'\n this.panningCssClass = 'crop-view--is-panning'\n this.outlineCssClass = 'crop-outline--active'\n\n // State\n this.isPanning = false\n this.initialCrop = crop\n\n // Events\n this.loadEvent = $.Callbacks()\n this.changeEvent = $.Callbacks()\n\n // Sets up the ready event and state\n this.initializeReadyState()\n\n // Confguration\n this.zoomInStep = zoomStep\n this.zoomOutStep = 1 / this.zoomInStep\n\n this.arenaWidth = this.arena.width()\n this.arenaHeight = this.arena.height()\n\n // todo: consider to calculate maxArea with regards to the\n // maximum space an image can within the area. That should\n // be more reliable.\n if (maxArea) this.maxArea = (this.arenaWidth * this.arenaHeight) * maxArea\n\n if (this.outline) this.setSurroundingImageVisibility(showSurroundingImage)\n\n this.preview = new Preview({\n onReady: this.onPreviewReady,\n img: this.img,\n outline: this.outline,\n opacity: this.surroundingImageOpacity\n })\n\n this.setImage(url)\n }\n\n initializeReadyState () {\n this.isReady = false\n if (this.readyEvent != null) {\n this.readyEvent.empty()\n }\n this.readyEvent = $.Callbacks('memory once')\n }\n\n setImage (url) {\n if (url === this.preview.url) return\n\n if (this.isInitialized) this.preview.reset()\n this.initializeReadyState()\n this.view.addClass(this.loadingCssClass)\n this.preview.setImage({url})\n }\n\n setSurroundingImageVisibility (visibility) {\n // visibility: always|panning|never\n // override opacity in crop-outline--active css class\n this.surroundingImageOpacity = parseFloat(this.surroundingImageOpacity || 0.2)\n\n if (visibility === 'always') {\n this.outline.css('opacity', 1.0)\n } else if (visibility === 'panning') {\n this.outline.css('opacity', null)\n } else { // 'never' default\n this.outline.css('opacity', 0)\n this.surroundingImageOpacity = 0\n }\n }\n\n reset () {\n if (!this.isReady) return\n\n this.resize({width: this.imageWidth, height: this.imageHeight})\n this.zoomAllOut()\n }\n\n onPreviewReady (previewImageSize) {\n this.checkRatio(previewImageSize)\n const {width, height} = this.originalSize || previewImageSize\n\n // console.log(this.originalSize, previewImageSize, {width, height})\n this.preview.updateImageDimensions({width, height})\n\n let keepDimension\n if (!this.isInitialized) {\n this.events = new Events({\n parent: this,\n view: this.view,\n actions: this.actions\n })\n }\n\n this.imageWidth = width\n this.imageHeight = height\n this.imageRatio = this.imageWidth / this.imageHeight\n const imageResolution = this.imageWidth * this.imageHeight\n\n if (this.minResolution && (this.minResolution > imageResolution)) {\n // If the minimal required resolution is bigger than the actual image\n // resolution, we ignore the configuration\n delete this.minResolution\n }\n\n if (this.minResolution) {\n // For any given image resolution with a minimal required resolution\n // we can calculate both, a minimal resolution and a maximal resolution\n const minRatioForResolution = this.minResolution / (this.imageHeight * this.imageHeight)\n if (!this.minViewRatio || (this.minViewRatio < minRatioForResolution)) {\n this.minViewRatio = minRatioForResolution\n }\n const maxRatioForResolution = (this.imageWidth * this.imageWidth) / this.minResolution\n if (!this.maxViewRatio || (this.maxViewRatio > maxRatioForResolution)) {\n this.maxViewRatio = maxRatioForResolution\n }\n }\n\n this.calcMaxMinDimensions()\n\n if (this.fixedWidth) { keepDimension = 'width' }\n if (this.fixedHeight) { keepDimension = 'height' }\n this.setViewDimensions({\n width: this.imageWidth,\n height: this.imageHeight,\n keepDimension\n })\n\n // ready state\n this.isReady = true\n this.view.removeClass(this.loadingCssClass)\n\n if (!this.isInitialized && (this.initialCrop != null)) {\n this.setCrop(this.initialCrop)\n } else {\n this.zoomAllOut()\n this.center()\n }\n\n this.isInitialized = true\n this.readyEvent.fire()\n this.loadEvent.fire()\n }\n\n setCrop ({x, y, width, height}) {\n if (!this.isReady) {\n this.on('ready', () => this.setCrop({x, y, width, height}))\n return\n }\n\n this.resize({width, height})\n\n const factor = this.viewWidth / width\n const previewWidth = this.imageWidth * factor\n\n this.zoom({width: previewWidth})\n this.pan({x: x * factor, y: y * factor})\n }\n\n getCrop () {\n const factor = this.preview.width / this.imageWidth\n const crop = {\n x: this.preview.x / factor,\n y: this.preview.y / factor,\n width: this.viewWidth / factor,\n height: this.viewHeight / factor\n }\n\n this.roundCrop(crop)\n this.validateCrop(crop)\n return crop\n }\n\n roundCrop (crop) {\n for (const name in crop) {\n const value = crop[name]\n crop[name] = Math.round(value)\n }\n }\n\n validateCrop (crop) {\n const {x, y, width, height} = crop\n if (x < 0) crop.x = 0\n if (y < 0) crop.y = 0\n\n if ((x + width) > this.imageWidth) {\n crop.width = this.imageWidth - x\n }\n\n if ((y + height) > this.imageHeight) {\n crop.height = this.imageHeight - y\n }\n\n return crop\n }\n\n setRatio (ratio, keepDimension) {\n let height, width\n if (!this.isReady) {\n this.on('ready', () => this.setRatio(ratio, keepDimension))\n return\n }\n\n ratio = this.enforceValidRatio(ratio)\n\n if (keepDimension === 'height') {\n height = this.viewHeight\n width = height * ratio\n } else {\n width = this.viewWidth\n height = width / ratio\n }\n\n this.resizeFocusPoint = this.getFocusPoint()\n return this.resize({width, height})\n }\n\n // Event handling\n // --------------\n\n onPan (data) {\n if (!this.isPanning) {\n this.isPanning = true\n this.arena.addClass(this.panningCssClass)\n this.outline.addClass(this.outlineCssClass)\n }\n\n const newX = data.startX - data.dx\n const newY = data.startY - data.dy\n this.pan({x: newX, y: newY})\n }\n\n onPanEnd () {\n this.isPanning = false\n this.arena.removeClass(this.panningCssClass)\n return this.outline.removeClass(this.outlineCssClass)\n }\n\n onDoubleClick ({pageX, pageY}) {\n const {left, top} = this.view[0].getBoundingClientRect()\n const viewX = pageX - left\n const viewY = pageY - top\n this.zoomIn({viewX, viewY})\n }\n\n onResize ({position, dx, dy}) {\n if (!this.isResizing) {\n this.isResizing = true\n this.resizeFocusPoint = this.getFocusPoint()\n }\n\n if (['top', 'bottom'].includes(position)) {\n dy = 2 * dy // Because it's centered we need to change width by factor two\n this.resize({width: this.viewWidth, height: this.viewHeight + dy, keepDimension: 'height'})\n } else if (['left', 'right'].includes(position)) {\n dx = 2 * dx\n this.resize({width: this.viewWidth + dx, height: this.viewHeight, keepDimension: 'width'})\n }\n }\n\n onResizeEnd () {\n this.isResizing = false\n this.resizeFocusPoint = undefined\n }\n\n resize ({width, height, keepDimension}) {\n this.setViewDimensions({width, height, keepDimension})\n\n // Update view center of focus point\n if (this.resizeFocusPoint) {\n this.resizeFocusPoint.viewX = this.viewWidth / 2\n this.resizeFocusPoint.viewY = this.viewHeight / 2\n }\n\n // Ensure dimensions and focus\n this.zoom({\n width: this.preview.width,\n height: this.preview.height,\n focusPoint: this.resizeFocusPoint\n })\n }\n\n setViewDimensions ({width, height, keepDimension}) {\n if (this.maxArea) {\n ({width, height} = this.enforceMaxArea({width, height, keepDimension}))\n }\n\n ({width, height} = this.enforceViewDimensions({width, height, keepDimension}))\n\n this.view.css({width, height})\n this.viewWidth = width\n this.viewHeight = height\n this.viewRatio = width / height\n\n if (this.minResolution) {\n const minZoomPixelWidth = Math.sqrt(this.minResolution * this.viewRatio)\n const minZoomPixelHeight = Math.sqrt(this.minResolution / this.viewRatio)\n this.maxImageWidth = (this.viewWidth / minZoomPixelWidth) * this.imageWidth\n this.maxImageHeight = (this.viewHeight / minZoomPixelHeight) * this.imageHeight\n }\n\n this.fireChange()\n }\n\n // Update view\n // -----------\n\n zoomAllOut () {\n if (this.isWidthRestricting()) {\n this.zoom({width: this.viewWidth})\n } else {\n this.zoom({height: this.viewHeight})\n }\n }\n\n zoomIn (params) {\n if (params == null) { params = {} }\n if (this.isWidthRestricting()) {\n params.width = this.preview.width * this.zoomInStep\n } else {\n params.height = this.preview.height * this.zoomInStep\n }\n\n this.zoom(params)\n }\n\n zoomOut (params) {\n if (params == null) { params = {} }\n if (this.isWidthRestricting()) {\n params.width = this.preview.width * this.zoomOutStep\n } else {\n params.height = this.preview.height * this.zoomOutStep\n }\n\n this.zoom(params)\n }\n\n zoom ({width, height, viewX, viewY, focusPoint}) {\n if (focusPoint == null) { focusPoint = this.getFocusPoint({viewX, viewY}) }\n\n ({width, height} = this.enforceZoom({width, height}))\n if (width != null) {\n this.preview.setWidth(width)\n this.fireChange()\n } else if (height != null) {\n this.preview.setHeight(height)\n this.fireChange()\n }\n\n this.focus(focusPoint)\n }\n\n // returns {Object} e.g. percentX: 0.2, percentY: 0.5\n getFocusPoint (param) {\n if (param == null) { param = {} }\n let {viewX, viewY} = param\n if (viewX == null) { viewX = this.viewWidth / 2 }\n if (viewY == null) { viewY = this.viewHeight / 2 }\n const x = this.preview.x + viewX\n const y = this.preview.y + viewY\n const percentX = x / this.preview.width\n const percentY = y / this.preview.height\n return {percentX, percentY, viewX, viewY}\n }\n\n focus ({percentX, percentY, viewX, viewY}) {\n let x = this.preview.width * percentX\n let y = this.preview.height * percentY\n x = x - viewX\n y = y - viewY\n\n this.pan({x, y})\n }\n\n center () {\n const newX = (this.preview.width - this.viewWidth) / 2\n const newY = (this.preview.height - this.viewHeight) / 2\n this.pan({x: newX, y: newY})\n }\n\n // @param { Object }\n // - x {Number} pixel to pan to the left\n // - y {Number} pixels to pan to the top\n pan (data) {\n data = this.enforceXy(data)\n this.preview.pan(data.x, data.y)\n this.fireChange()\n }\n\n // Validations\n // -----------\n\n enforceXy ({x, y}) {\n if (x > (this.preview.width - this.viewWidth)) {\n x = this.preview.width - this.viewWidth\n }\n\n if (x < 0) x = 0\n\n\n if (y > (this.preview.height - this.viewHeight)) {\n y = this.preview.height - this.viewHeight\n }\n\n if (y < 0) y = 0\n\n return {x, y}\n }\n\n enforceZoom ({width, height}) {\n\n if ((width != null) && this.maxImageWidth && (width > this.maxImageWidth)) {\n // prevent zooming in past the required resolution defined by minResolution\n return {width: this.maxImageWidth}\n }\n\n if ((width != null) && (width < this.viewWidth)) {\n // prevent zooming out past covering the view completely\n return {width: this.viewWidth}\n }\n\n if ((height != null) && this.maxImageHeight && (height > this.maxImageHeight)) {\n // prevent zooming in past the required resolution defined by minResolution\n return {height: this.maxImageHeight}\n }\n\n if ((height != null) && (height < this.viewHeight)) {\n // prevent zooming out past covering the view completely\n return {height: this.viewHeight}\n }\n\n return {width, height}\n }\n\n calcMaxMinDimensions () {\n this.maxWidth = this.min([this.arenaWidth, this.imageWidth])\n this.maxHeight = this.min([this.arenaHeight, this.imageHeight])\n this.minWidth = this.minViewWidth || 0\n this.minHeight = this.minViewHeight || 0\n\n if (this.fixedWidth) this.maxWidth = (this.minWidth = this.fixedWidth)\n if (this.fixedHeight) this.maxHeight = (this.minHeight = this.fixedHeight)\n }\n\n areDimensionsValid ({width, height, keepDimension}) {\n const ratio = width / height\n\n const invalid =\n (width < this.minWidth) ||\n (width > this.maxWidth) ||\n (height < this.minHeight) ||\n (height > this.maxHeight) ||\n (ratio < this.minViewRatio) ||\n (ratio > this.maxViewRatio)\n\n return !invalid\n }\n\n isValidRatio (ratio) {\n return !((ratio < this.minViewRatio) || (ratio > this.maxViewRatio))\n }\n\n enforceValidRatio (ratio) {\n if (ratio < this.minViewRatio) return this.minViewRatio\n if (ratio > this.maxViewRatio) return this.maxViewRatio\n return ratio\n }\n\n enforceViewDimensions ({width, height, keepDimension}) {\n let newHeight, newWidth, ratio\n if (width < this.minWidth) newWidth = this.minWidth\n if (width > this.maxWidth) newWidth = this.maxWidth\n if (height < this.minHeight) newHeight = this.minHeight\n if (height > this.maxHeight) newHeight = this.maxHeight\n\n if (keepDimension) {\n if (newWidth) width = newWidth\n if (newHeight) height = newHeight\n\n // check max/min ratios\n ratio = width / height\n if (!this.isValidRatio(ratio)) {\n ratio = this.enforceValidRatio(ratio);\n ({width, height} = this.getRatioBox({ratio, width, height, keepDimension}))\n if ((width > this.arenaWidth) || (height > this.arenaHeight)) {\n ({width, height} = this.centerAlign(this.maxWidth, this.maxHeight, ratio))\n }\n }\n\n } else if (newWidth || newHeight) {\n ratio = this.enforceValidRatio(width / height);\n ({width, height} = this.centerAlign(this.maxWidth, this.maxHeight, ratio))\n }\n\n return {width, height}\n }\n\n enforceMaxArea ({width, height, keepDimension}) {\n let ratio = width / height\n\n if (keepDimension === 'width') {\n height = this.maxArea / width\n ratio = width / height\n } else if (keepDimension === 'height') {\n width = this.maxArea / height\n ratio = width / height\n } else { // keep ratio\n width = Math.sqrt(this.maxArea * ratio)\n height = width / ratio\n }\n\n if (!this.isValidRatio(ratio)) {\n ratio = this.enforceValidRatio(ratio)\n width = Math.sqrt(this.maxArea * ratio)\n height = width / ratio\n }\n\n return {width, height}\n }\n\n checkRatio (previewImageSize) {\n if (this.originalSize) {\n const expectedRatio = this.originalSize.width / this.originalSize.height\n const actualRatio = previewImageSize.width / previewImageSize.height\n const percentageChange = ((actualRatio - expectedRatio) / expectedRatio) * 100\n if (Math.abs(percentageChange) > 1) {\n throw new Error(`srcissors: Displayed image has a different image ratio than the ` +\n `one configured in 'originalRatio': ${expectedRatio} vs ${actualRatio}`)\n }\n }\n }\n\n // Calculations\n // ------------\n //\n // Ratio: width / height\n // Tall < 1 (Square) < Wide\n // (A ratio less than one is a tall image format and\n // a ratio greater than one is a wide image format)\n\n // Check if the width or height is restricting\n isWidthRestricting () {\n return this.viewRatio >= this.imageRatio\n }\n\n getRatioBox ({ratio, width, height, keepDimension}) {\n if ((keepDimension === 'width') || (height == null)) {\n height = width / ratio\n } else if ((keepDimension === 'height') || (width == null)) {\n width = height * ratio\n } else {\n height = width / ratio\n }\n\n return {width, height}\n }\n\n centerAlign (areaWidth, areaHeight, ratio) {\n let height, width, x, y\n if ((areaWidth / areaHeight) > ratio) {\n width = areaHeight * ratio\n x = (areaWidth - width) / 2\n } else {\n height = areaWidth / ratio\n y = (areaHeight - height) / 2\n }\n\n // return\n return {\n x: x || 0,\n y: y || 0,\n width: width || areaWidth,\n height: height || areaHeight\n }\n }\n\n min (array) {\n let min = array[0]\n for (const number of array) {\n if (number < min) min = number\n }\n\n return min\n }\n\n // Events\n // ------\n\n on (name, callback) {\n return this[`${name}Event`].add(callback)\n }\n\n off (name, callback) {\n return this[`${name}Event`].remove(callback)\n }\n\n // Debounce change events so they are not fired more\n // than once per tick.\n fireChange () {\n if (this.changeDispatch != null) return\n\n this.changeDispatch = setTimeout(() => {\n this.changeDispatch = undefined\n this.changeEvent.fire(this.getCrop())\n }, 0)\n }\n\n // Development helpers\n // -------------------\n\n debug () {\n const r = num => Math.round(num * 10) / 10\n\n const obj = {\n arena: `${r(this.arenaWidth)}x${r(this.arenaHeight)}`,\n view: `${r(this.viewWidth)}x${r(this.viewHeight)}`,\n image: `${r(this.imageWidth)}x${r(this.imageHeight)}`,\n preview: `${r(this.preview.width)}x${r(this.preview.height)}`,\n previewXy: `${r(this.preview.x)}x${r(this.preview.y)}`\n }\n\n console.log(obj) // eslint-disable-line no-console\n return obj\n }\n}\n","const $ = require('jquery')\n\nconst getPageCoordinates = function (event) {\n if (event.type.includes('touch')) {\n return {\n pageX: event.originalEvent.changedTouches[0].pageX,\n pageY: event.originalEvent.changedTouches[0].pageY\n }\n }\n return {pageX: event.pageX, pageY: event.pageY}\n}\n\nmodule.exports = class Events {\n constructor ({parent, view, horizontal, vertical, actions}) {\n this.parent = parent\n this.view = view\n this.doubleClickThreshold = 300\n\n // setup events\n if (actions.pan) { this.pan() }\n if (actions.zoomOnDoubleClick) { this.doubleClick() }\n if (actions.resize) {\n this.resizeView({\n horizontal: actions.resizeHorizontal,\n vertical: actions.resizeVertical\n })\n }\n\n this.preventBrowserDragDrop()\n this.responsiveArena()\n }\n\n pan () {\n const $doc = $(document)\n this.view.on('mousedown.srcissors touchstart.srcissors', (e1) => {\n const panData = {\n startX: this.parent.preview.x,\n startY: this.parent.preview.y\n }\n\n e1.preventDefault()\n $doc.on('mousemove.srcissors-pan touchmove.srcissors-pan', (e2) => {\n const {pageX, pageY} = getPageCoordinates(e2)\n const {pageX: prevPageX, pageY: prevPageY} = getPageCoordinates(e1)\n panData.dx = pageX - prevPageX\n panData.dy = pageY - prevPageY\n this.parent.onPan(panData)\n }).on('mouseup.srcissors-pan touchend.srcissors-pan', () => {\n $doc.off('mouseup.srcissors-pan touchend.srcissors-pan')\n $doc.off('mousemove.srcissors-pan touchmove.srcissors-pan')\n\n // only trigger panEnd if pan has been called\n if (panData.dx != null) this.parent.onPanEnd()\n })\n })\n }\n\n doubleClick () {\n let lastClick\n\n this.view.on('mousedown.srcissors touchstart.srcissors', event => {\n const now = new Date().getTime()\n if (lastClick && (lastClick > (now - this.doubleClickThreshold))) {\n this.parent.onDoubleClick(getPageCoordinates(event))\n }\n lastClick = now\n })\n }\n\n preventBrowserDragDrop () {\n this.view.on('dragstart.srcissors', () => false)\n }\n\n // Resize View\n // -----------\n\n resizeView ({horizontal, vertical}) {\n const $template = $('')\n $template.addClass('resize-handler')\n\n let positions = []\n if (horizontal) positions = positions.concat(['right', 'left'])\n if (vertical) positions = positions.concat(['top', 'bottom'])\n\n positions.forEach(position => {\n const $handler = $template.clone()\n $handler.addClass(`resize-handler-${position}`)\n $handler.on('mousedown.srcissors touchstart.srcissors', this.getResizeMouseDown(position))\n\n this.view.append($handler)\n })\n }\n\n getResizeMouseDown (position) {\n const $doc = $(document)\n\n return (event) => {\n let {pageX: lastX, pageY: lastY} = getPageCoordinates(event)\n event.stopPropagation()\n\n $doc.on('mousemove.srcissors-resize touchmove.srcissors-resize', e2 => {\n let dx, dy\n const {pageX, pageY} = getPageCoordinates(e2)\n switch (position) {\n case 'top': case 'bottom':\n dy = pageY - lastY\n if (position === 'top') { dy = -dy }\n lastY = pageY\n break\n case 'left': case 'right':\n dx = pageX - lastX\n if (position === 'left') { dx = -dx }\n lastX = pageX\n break\n }\n\n this.parent.onResize({position, dx, dy})\n }).on('mouseup.srcissors-resize touchend.srcissors-resize', () => {\n $doc.off('mouseup.srcissors-resize touchmove.srcissors-resize')\n $doc.off('mousemove.srcissors-resize touchend.srcissors-resize')\n\n // only trigger panEnd if pan has been called\n this.parent.onResizeEnd({position})\n })\n }\n }\n\n responsiveArena () {}\n}\n\n// $(window).on('resize', (event) => console.log 'on window resize')\n","const $ = require('jquery')\n\nmodule.exports = class Preview {\n\n constructor ({onReady, img, opacity, outline}) {\n this.onReady = onReady\n this.img = img\n this.opacity = opacity\n this.outline = outline\n this.x = (this.y = 0)\n this.width = (this.height = 0)\n\n this.img.on('load', () => {\n const width = this.img.width()\n const height = this.img.height()\n this.ratio = width / height\n\n this.onReady({width, height})\n this.img.show()\n })\n }\n\n setImage ({url}) {\n this.url = url\n this.img.attr('src', this.url)\n if (this.outline) this.setBackgroundImage({url: this.url})\n }\n\n setBackgroundImage ({url}) {\n if (this.opacity > 0) {\n const bgImg = $('
![]()
').css({opacity: this.opacity}).attr('src', url)\n this.outline.append(bgImg)\n }\n }\n\n reset () {\n this.url = undefined\n this.x = (this.y = 0)\n this.width = (this.height = 0)\n this.img.attr('src', '')\n this.img.css({width: '', height: '', transform: ''})\n if (this.outline) this.outline.css({transform: ''}).html('')\n }\n\n setWidth (width) {\n this.img.css({width: `${width}px`, height: 'auto'})\n const height = width / this.ratio\n this.updateImageDimensions({width, height})\n }\n\n setHeight (height) {\n this.img.css({width: 'auto', height: `${height}px`})\n const width = height * this.ratio\n this.updateImageDimensions({width, height})\n }\n\n updateImageDimensions ({width, height}) {\n this.width = width\n this.height = height\n if (this.outline) this.outline.css({width: `${this.width}px`, height: `${this.height}px`})\n }\n\n pan (x1, y1) {\n // Without rounding some numbers would not be set to css.\n // e.g: '-5.14957320384e-14'\n this.x = x1\n this.y = y1\n const x = Math.round(this.x)\n const y = Math.round(this.y)\n this.img.css({transform: `translate(-${x}px, -${y}px)`})\n if (this.outline) this.outline.css({transform: `translate(-${x}px, -${y}px)`})\n }\n}\n\n","const $ = require('jquery')\nconst Crop = require('./crop')\n\nmodule.exports = {\n new ({\n arena, url, fixedWidth, fixedHeight, minWidth, minHeight,\n minRatio, maxRatio, maxArea, originalSize, zoomStep, crop, actions, minResolution,\n surroundingImageOpacity, showSurroundingImage\n }) {\n arena = $(arena)\n const view = arena.find('.crop-view')\n const preview = view.find('.crop-preview')\n const img = $('
![]()
')\n preview.append(img)\n let outline = view.find('.crop-outline')\n if (!outline.length) { outline = undefined }\n\n const allowedActions = {\n pan: true,\n zoomOnDoubleClick: true,\n resize: true,\n resizeHorizontal: !fixedWidth,\n resizeVertical: !fixedHeight\n }\n\n $.extend(allowedActions, actions)\n\n if (zoomStep == null) { zoomStep = 1.25 }\n\n if (minWidth == null) { minWidth = 50 }\n if (minHeight == null) { minHeight = 50 }\n\n return new Crop({\n url, // {String}\n crop, // {Object} Set an inital crop. This is the same as calling setCrop()\n arena, // {jQuery Element}\n view, // {jQuery Element}\n img, // {jQuery Element}\n outline, // {jQuery Element or undefined}\n showSurroundingImage, // {String} always|panning|never\n surroundingImageOpacity, // {Number} e.g. in the 0.0 - 1.0 range\n fixedWidth, // {Number} e.g. 300\n fixedHeight, // {Number} e.g. 500\n minViewWidth: minWidth, // {Number} e.g. 100\n minViewHeight: minHeight, // {Number} e.g. 100\n minViewRatio: minRatio, // {Number} e.g. 1.5/2\n maxViewRatio: maxRatio, // {Number} e.g. 2/1\n maxArea, // {Number} 0.8 -> max 80% of arena area are covered by the preview\n originalSize, // {Object} Original image size, can be used to display a downscaled\n // version of the image in the cropping interface, but use the original\n // size for crop attributes; e.g. {width: 4000, height: 3000}\n zoomStep, // {Number} e.g. 1.25 -> 125%\n actions: allowedActions,\n minResolution\n })\n }\n}\n","module.exports = __WEBPACK_EXTERNAL_MODULE__47__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// startup\n// Load entry module and return exports\n// This entry module is referenced by other modules so it can't be inlined\nvar __webpack_exports__ = __webpack_require__(505);\n"],"names":["root","factory","exports","module","require","define","amd","self","__WEBPACK_EXTERNAL_MODULE__47__","$","Preview","Events","Crop","_ref","arena","view","img","outline","url","fixedWidth","fixedHeight","minViewWidth","minViewHeight","minViewRatio","maxViewRatio","originalSize","crop","zoomStep","maxArea","actions","minResolution","surroundingImageOpacity","showSurroundingImage","_classCallCheck","this","onPreviewReady","bind","loadingCssClass","panningCssClass","outlineCssClass","isPanning","initialCrop","loadEvent","Callbacks","changeEvent","initializeReadyState","zoomInStep","zoomOutStep","arenaWidth","width","arenaHeight","height","setSurroundingImageVisibility","preview","onReady","opacity","setImage","key","value","isReady","readyEvent","empty","isInitialized","reset","addClass","visibility","parseFloat","css","resize","imageWidth","imageHeight","zoomAllOut","previewImageSize","checkRatio","keepDimension","_ref2","updateImageDimensions","events","parent","imageRatio","imageResolution","minRatioForResolution","maxRatioForResolution","calcMaxMinDimensions","setViewDimensions","removeClass","center","setCrop","fire","_ref3","_this","x","y","factor","viewWidth","previewWidth","zoom","pan","on","viewHeight","roundCrop","validateCrop","name","Math","round","ratio","_this2","enforceValidRatio","resizeFocusPoint","getFocusPoint","setRatio","data","newX","startX","dx","newY","startY","dy","_ref4","pageX","pageY","_this$view$0$getBound","getBoundingClientRect","viewX","left","viewY","top","zoomIn","_ref5","position","isResizing","includes","undefined","_ref6","focusPoint","_ref7","_this$enforceMaxArea","enforceMaxArea","_this$enforceViewDime","enforceViewDimensions","viewRatio","minZoomPixelWidth","sqrt","minZoomPixelHeight","maxImageWidth","maxImageHeight","fireChange","isWidthRestricting","params","_ref8","_this$enforceZoom","enforceZoom","setWidth","setHeight","focus","param","_param","percentX","percentY","_ref9","enforceXy","_ref10","_ref11","maxWidth","min","maxHeight","minWidth","minHeight","_ref12","_ref13","newHeight","newWidth","isValidRatio","_this$getRatioBox","getRatioBox","_this$centerAlign","centerAlign","_this$centerAlign2","_ref14","expectedRatio","actualRatio","percentageChange","abs","Error","concat","_ref15","areaWidth","areaHeight","array","_step","_iterator","_createForOfIteratorHelper","s","n","done","number","err","e","f","callback","add","remove","_this3","changeDispatch","setTimeout","getCrop","r","num","obj","image","previewXy","console","log","getPageCoordinates","event","type","originalEvent","changedTouches","horizontal","vertical","doubleClickThreshold","zoomOnDoubleClick","doubleClick","resizeView","resizeHorizontal","resizeVertical","preventBrowserDragDrop","responsiveArena","$doc","document","e1","panData","preventDefault","e2","_getPageCoordinates","_getPageCoordinates2","prevPageX","prevPageY","onPan","off","onPanEnd","lastClick","now","Date","getTime","onDoubleClick","$template","positions","forEach","$handler","clone","getResizeMouseDown","append","_this4","_getPageCoordinates3","lastX","lastY","stopPropagation","_getPageCoordinates4","onResize","onResizeEnd","show","attr","setBackgroundImage","bgImg","transform","html","x1","y1","new","minRatio","maxRatio","find","length","allowedActions","extend","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__"],"sourceRoot":""}
\ No newline at end of file