@thewhitehaven04/chartjs-plugin-zoom 2.2.10 → 2.2.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@thewhitehaven04/chartjs-plugin-zoom.esm.js +3 -3
- package/dist/@thewhitehaven04/chartjs-plugin-zoom.js +3 -3
- package/dist/@thewhitehaven04/chartjs-plugin-zoom.min.js +3 -3
- package/dist/src/core.d.ts.map +1 -0
- package/dist/src/defaults.d.ts.map +1 -0
- package/dist/src/hammer.d.ts.map +1 -0
- package/dist/src/handlers.d.ts.map +1 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/index.umd.d.ts.map +1 -0
- package/dist/src/options.d.ts.map +1 -0
- package/dist/src/plugin.d.ts.map +1 -0
- package/dist/src/scale.types.d.ts.map +1 -0
- package/dist/src/scale.types.test.d.ts.map +1 -0
- package/dist/src/state.d.ts.map +1 -0
- package/dist/src/types.d.ts.map +1 -0
- package/dist/src/utils.d.ts.map +1 -0
- package/dist/src/utils.test.d.ts.map +1 -0
- package/package.json +5 -5
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @thewhitehaven04/chartjs-plugin-zoom v2.2.
|
|
3
|
-
* https://www.chartjs.org/chartjs-plugin-zoom/2.2.
|
|
2
|
+
* @thewhitehaven04/chartjs-plugin-zoom v2.2.12
|
|
3
|
+
* https://www.chartjs.org/chartjs-plugin-zoom/2.2.12/
|
|
4
4
|
* (c) 2016-2026 chartjs-plugin-zoom Contributors
|
|
5
5
|
* Released under the MIT License
|
|
6
6
|
*/
|
|
@@ -1043,7 +1043,7 @@ function hammerOptionsChanged(oldOptions, newOptions) {
|
|
|
1043
1043
|
return false;
|
|
1044
1044
|
}
|
|
1045
1045
|
|
|
1046
|
-
var version = "2.2.
|
|
1046
|
+
var version = "2.2.12";
|
|
1047
1047
|
|
|
1048
1048
|
const defaults = {
|
|
1049
1049
|
pan: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @thewhitehaven04/chartjs-plugin-zoom v2.2.
|
|
3
|
-
* https://www.chartjs.org/chartjs-plugin-zoom/2.2.
|
|
2
|
+
* @thewhitehaven04/chartjs-plugin-zoom v2.2.12
|
|
3
|
+
* https://www.chartjs.org/chartjs-plugin-zoom/2.2.12/
|
|
4
4
|
* (c) 2016-2026 chartjs-plugin-zoom Contributors
|
|
5
5
|
* Released under the MIT License
|
|
6
6
|
*/
|
|
@@ -1046,7 +1046,7 @@ function hammerOptionsChanged(oldOptions, newOptions) {
|
|
|
1046
1046
|
return false;
|
|
1047
1047
|
}
|
|
1048
1048
|
|
|
1049
|
-
var version = "2.2.
|
|
1049
|
+
var version = "2.2.12";
|
|
1050
1050
|
|
|
1051
1051
|
const defaults = {
|
|
1052
1052
|
pan: {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @thewhitehaven04/chartjs-plugin-zoom v2.2.
|
|
3
|
-
* https://www.chartjs.org/chartjs-plugin-zoom/2.2.
|
|
2
|
+
* @thewhitehaven04/chartjs-plugin-zoom v2.2.12
|
|
3
|
+
* https://www.chartjs.org/chartjs-plugin-zoom/2.2.12/
|
|
4
4
|
* (c) 2016-2026 chartjs-plugin-zoom Contributors
|
|
5
5
|
* Released under the MIT License
|
|
6
6
|
*/
|
|
7
|
-
!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n(require("chart.js"),require("hammerjs"),require("chart.js/helpers")):"function"==typeof define&&define.amd?define(["chart.js","hammerjs","chart.js/helpers"],n):(t="undefined"!=typeof globalThis?globalThis:t||self).ChartZoom=n(t.Chart,t.Hammer,t.Chart.helpers)}(this,(function(t,n,e){"use strict";const o=t=>`${t}Key`,i=t=>t?.enabled&&t.modifierKey?t.modifierKey:void 0,a=(t,n)=>t&&n[o(t)],r=(t,n)=>t&&!n[o(t)];function s(t,n,e){return void 0===t||("string"==typeof t?-1!==t.indexOf(n):"function"==typeof t&&-1!==t({chart:e}).indexOf(n))}function c(t,n){return"function"==typeof t&&(t=t({chart:n})),"string"==typeof t?{x:-1!==t.indexOf("x"),y:-1!==t.indexOf("y")}:{x:!1,y:!1}}function l(t,n,e){const{mode:o="xy",scaleMode:i,overScaleMode:a}=t||{},r=function({x:t,y:n},e){const o=e.scales,i=Object.keys(o);for(let e=0;e<i.length;e++){const a=o[i[e]];if(n>=a.top&&n<=a.bottom&&t>=a.left&&t<=a.right)return a}return null}(n,e),s=c(o,e),l=c(i,e);return((t,n,e,o)=>{if(!n)return;const i=c(n,t);for(const t of["x","y"])i[t]&&(e[t]=o[t],o[t]=!1)})(e,a,l,s),r&&l[r.axis]?[r]:((t,n)=>{const e=[];for(const o of Object.values(t.scales))n[o.axis]&&e.push(o);return e||Object.values(t.scales)})(e,s)}const m=new WeakMap;function u(t){let n=m.get(t);return n||(n={originalScaleLimits:{},updatedScaleLimits:{},handlers:{},options:{},targets:{},panDelta:{},dragging:!1,panning:!1},m.set(t,n)),n}const d=t=>void 0===t||isNaN(t);function f(t,n,o,i){const a=o&&e.isNumber(t)&&e.isNumber(n)?Math.max(0,Math.min(1,(t-n)/o)):0;return{min:i*a,max:i*(1-a)}}function p(t,n){const e=t.isHorizontal()?n.x:n.y;return t.getValueForPixel(e)}function h(t,n,e){const o=t.max-t.min,i=o*(n-1);return f(p(t,e),t.min,o,i)}function g(t,n,o,i,a){let r=o[i];if("original"===r){const o=t.originalScaleLimits[n.id][i];if(e.isNumber(o.options))return o.options;if(!e.isNullOrUndef(o.options)){const t=n.parse(o.options);if(e.isNumber(t))return t}r=o.scale}return e.valueOrDefault(r,a)}function x(t,{min:n,max:o},i,a=!1,r=!1){const s=u(t.chart),{options:c}=t,l=function(t,n){return n?.[t.id]||n?.[t.axis]||{}}(t,i),{minRange:m=0}=l,d=g(s,t,l,"min",-1/0),f=g(s,t,l,"max",1/0);if(r&&(n<d||o>f))return!0;const p=t.max-t.min,h=a?Math.max(o-n,m):p;if(a&&h===m&&p<=m)return!0;const x=function(t,{min:n,max:o,minLimit:i,maxLimit:a},r,s){const c=(t-o+n)/2;n-=c,o+=c;const l={min:"original",max:"original"},m=g(r,s,l,"min",-1/0),u=g(r,s,l,"max",1/0),d=t/1e6;return e.almostEquals(n,m,d)&&(n=m),e.almostEquals(o,u,d)&&(o=u),n<i?(n=i,o=Math.min(i+t,a)):o>a&&(o=a,n=Math.max(a-t,i)),{min:n,max:o}}(h,{min:n,max:o,minLimit:d,maxLimit:f},s,t);return c.min=x.min,c.max=x.max,s.updatedScaleLimits[t.id]=x,t.parse(x.min)!==t.min||t.parse(x.max)!==t.max}const y=t=>0===t||isNaN(t)?0:t<0?Math.min(Math.round(t),-1):Math.max(Math.round(t),1);const b={millisecond:0,second:500,minute:3e4,hour:18e5,day:432e5,week:3024e5,month:1296e6,quarter:5184e6,year:157248e5};function v(t,n,e,o=!1){const{min:i,max:a}=t;let r=0;if((t=>"time"===t.type)(t)){const n=t.options.time?.round;r=n?b[n]:0}const s=t.getValueForPixel(t.getPixelForValue(i+r)-n),c=t.getValueForPixel(t.getPixelForValue(a+r)-n);return!(!d(s)&&!d(c))||x(t,{min:s,max:c},e,o,!0)}function w(t,n,e){return v(t,n,e,!0)}const M={category:function(t,n,e,o){const i=h(t,n,e);return t.min===t.max&&n<1&&function(t){const n=t.getLabels().length-1;t.min>0&&(t.min-=1),t.max<n&&(t.max+=1)}(t),x(t,{min:t.min+y(i.min),max:t.max-y(i.max)},o,!0)},default:function(t,n,e,o){const i=h(t,n,e);return x(t,{min:t.min+i.min,max:t.max-i.max},o,!0)},logarithmic:function(t,n,e,o){const i=function(t,n,e){const o=p(t,e);if(void 0===o)return{min:t.min,max:t.max};const i=Math.log10(t.min),a=Math.log10(t.max),r=a-i,s=f(Math.log10(o),i,r,r*(n-1));return{min:Math.pow(10,i+s.min),max:Math.pow(10,a-s.max)}}(t,n,e);return x(t,i,o,!0)}},z={default:function(t,n,e,o){return x(t,function(t,n,e){const o=t.getValueForPixel(n)??t.min,i=t.getValueForPixel(e)??t.max;return{min:Math.min(o,i),max:Math.max(o,i)}}(t,n,e),o,!0)}},S={category:function(t,n,e){const o=t.getLabels().length-1;let{min:i,max:a}=t;const r=Math.max(a-i,1),s=Math.round(function(t){return t.isHorizontal()?t.width:t.height}(t)/Math.max(r,10)),c=Math.round(Math.abs(n/s));let l;return n<-s?(a=Math.min(a+c,o),i=1===r?a:a-r,l=a===o):n>s&&(i=Math.max(0,i-c),a=1===r?i:i+r,l=0===i),x(t,{min:i,max:a},e)||Boolean(l)},default:v,logarithmic:w,timeseries:w};function P(t,n,e){const{id:o,options:{min:i,max:a}}=t;if(!n[o]||!e[o])return!0;const r=e[o];return r.min!==i||r.max!==a}function j(t,n){for(const e of Object.keys(t))n[e]||delete t[e]}function O(t,n){const{scales:e}=t,{originalScaleLimits:o,updatedScaleLimits:i}=n;for(const t of Object.values(e))P(t,o,i)&&(o[t.id]={min:{scale:t.min,options:t.options.min},max:{scale:t.max,options:t.options.max}});return j(o,e),j(i,e),o}function k(t,n,e,o){const i=M[t.type]||M.default;i?.(t,n,e,o)}function C(t,n,e,o){const i=z[t.type]||z.default;i?.(t,n,e,o)}function Z(t){const n=t.chartArea;return{x:(n.left+n.right)/2,y:(n.top+n.bottom)/2}}function D(t,n,e="none",o="api"){const{x:i=1,y:a=1,focalPoint:r=Z(t)}="number"==typeof n?{x:n,y:n}:n,s=u(t),{options:{limits:c={},zoom:m}}=s;O(t,s);const d=1!==i,f=1!==a,p=l(m,r,t);for(const t of p)t.isHorizontal()&&d?k(t,i,r,c):!t.isHorizontal()&&f&&k(t,a,r,c);t.update(e),m?.onZoom?.({chart:t,trigger:o,amount:{x:i,y:a,focalPoint:r}})}function R(t,n,e,o="none",i="api"){const a=u(t),{options:{limits:r={},zoom:c={}}}=a,{mode:l="xy"}=c;O(t,a);const m=s(l,"x",t),d=s(l,"y",t);for(const o of Object.values(t.scales))o.isHorizontal()&&m?C(o,n.x,e.x,r):!o.isHorizontal()&&d&&C(o,n.y,e.y,r);t.update(o),c.onZoom?.({chart:t,trigger:i})}function L(t,n){const o=t.originalScaleLimits[n];if(!o)return;const{min:i,max:a}=o;return e.isNumber(a.options)&&e.isNumber(i.options)?a.options-i.options:e.isNumber(a.scale)&&e.isNumber(i.scale)?a.scale-i.scale:void 0}function N(t,n,o,i){const{panDelta:a}=i,r=a[t.id]||0;e.sign(r)===e.sign(n)&&(n+=r);const s=S[t.type]||S.default;s?.(t,n,o)?a[t.id]=0:a[t.id]=n}function E(t,n,e,o="none",i="other"){const{x:a=0,y:r=0}="number"==typeof n?{x:n,y:n}:n,s=u(t),{options:{pan:c,limits:l={}}}=s,{onPan:m}=c||{};O(t,s);const d=0!==a,f=0!==r,p=e||Object.values(t.scales);for(const t of p)t.isHorizontal()&&d?N(t,a,l,s):!t.isHorizontal()&&f&&N(t,r,l,s);t.update(o),m?.({chart:t,trigger:i,delta:{x:a,y:r}})}function F(t){const n=u(t);O(t,n);const e={};for(const o of Object.keys(t.scales)){const{min:t,max:i}=n.originalScaleLimits[o]||{min:{},max:{}};e[o]={min:t.scale,max:i.scale}}return e}function A(t){return t.panning||t.dragging}const H=(t,n,e)=>Math.min(e,Math.max(n,t));function T(t,n){const{handlers:e,targets:o}=u(t),i=e[n],a=o[n];i&&a&&(a.removeEventListener(n,i),delete e[n])}function Y(t,n,e,o){const{handlers:i,options:a,targets:r}=u(t);if(i[e]&&r[e]===n)return;T(t,e);const s=i[e]=n=>o(t,n,a);r[e]=n;const c="wheel"!==e&&void 0;n.addEventListener(e,s,{passive:c})}function B(t,n){const e=u(t);e.dragStart&&(e.dragging=!0,e.dragEnd=n,t.draw())}function q(t,n){const e=u(t);e.dragStart&&"Escape"===n.key&&(T(t,"keydown"),e.dragging=!1,e.dragStart=e.dragEnd=void 0,t.draw())}function V(t,n){if(t.target!==n.canvas){const e=n.canvas.getBoundingClientRect();return{x:t.clientX-e.left,y:t.clientY-e.top}}return e.getRelativePosition(t,n)}function X(t,n,e){const{onZoomStart:o,onZoomRejected:i}=e;if(o){const e=V(n,t);if(!1===o?.({chart:t,event:n,point:e}))return i?.({chart:t,event:n}),!1}}function K(t,n){if(t.legend){const o=e.getRelativePosition(n,t);if(e._isPointInArea(o,t.legend))return}const o=u(t),{pan:s,zoom:c={}}=o.options;if(0!==n.button||a(i(s),n)||r(i(c.drag),n))return c.onZoomRejected?.({chart:t,event:n});!1!==X(t,n,c)&&(o.dragStart=n,Y(t,t.canvas.ownerDocument,"mousemove",B),Y(t,window.document,"keydown",q))}function W(t,n,e,{min:o,max:i,prop:a}){t[o]=H(Math.min(e.begin[a],e.end[a]),n[o],n[i]),t[i]=H(Math.max(e.begin[a],e.end[a]),n[o],n[i])}function I(t,n,e){const o={begin:V(n.dragStart,t),end:V(n.dragEnd,t)};if(e){!function({begin:t,end:n},e){let o=n.x-t.x,i=n.y-t.y;const a=Math.abs(o/i);a>e?o=Math.sign(o)*Math.abs(i*e):a<e&&(i=Math.sign(i)*Math.abs(o/e)),n.x=t.x+o,n.y=t.y+i}(o,t.chartArea.width/t.chartArea.height)}return o}function U(t,n,e,o){const i=s(n,"x",t),a=s(n,"y",t),{top:r,left:c,right:l,bottom:m,width:u,height:d}=t.chartArea,f={top:r,left:c,right:l,bottom:m},p=I(t,e,o&&i&&a);i&&W(f,t.chartArea,p,{min:"left",max:"right",prop:"x"}),a&&W(f,t.chartArea,p,{min:"top",max:"bottom",prop:"y"});const h=f.right-f.left,g=f.bottom-f.top;return{...f,width:h,height:g,zoomX:i&&h?1+(u-h)/u:1,zoomY:a&&g?1+(d-g)/d:1}}function $(t,n){const e=u(t);if(!e.dragStart)return;T(t,"mousemove");const{mode:o,onZoomComplete:i,drag:a}=e.options.zoom??{},{threshold:r=0,maintainAspectRatio:c}=a??{},l=U(t,o,{dragStart:e.dragStart,dragEnd:n},c),m=s(o,"x",t)?l.width:0,d=s(o,"y",t)?l.height:0,f=Math.sqrt(m*m+d*d);if(e.dragStart=e.dragEnd=void 0,f<=r)return e.dragging=!1,void t.draw();R(t,{x:l.left,y:l.top},{x:l.right,y:l.bottom},"zoom","drag"),e.dragging=!1,e.filterNextClick=!0,i?.({chart:t})}function _(t,n){const{handlers:{onZoomComplete:e},options:{zoom:o={}}}=u(t);if(!function(t,n,e){if(r(i(e.wheel),n))e.onZoomRejected?.({chart:t,event:n});else if(!1!==X(t,n,e)&&(n.cancelable&&n.preventDefault(),void 0!==n.deltaY))return!0}(t,n,o))return;const a=n.target?.getBoundingClientRect(),s=o?.wheel?.speed??.1,c=n.deltaY>=0?2-1/(1-s):1+s;D(t,{x:c,y:c,focalPoint:{x:n.clientX-a.left,y:n.clientY-a.top}},"zoom","wheel"),e?.(n)}function G(t,n,e,o){e&&(u(t).handlers[n]=function(t,n){let e;return function(){return clearTimeout(e),e=setTimeout(t,n),n}}((()=>e?.({chart:t})),o))}function J(t,n){return function(e,o){const{pan:s,zoom:c={}}=n.options;if(!s||!s.enabled)return!1;const l=o&&o.srcEvent;return!l||(!(!n.panning&&"mouse"===o.pointerType&&(r(i(s),l)||a(i(c.drag),l)))||(s.onPanRejected?.({chart:t,event:o}),!1))}}function Q(t,n,e){if(n.scale){const{center:o,pointers:i}=e,a=1/n.scale*e.scale,r=e.target.getBoundingClientRect(),c=function(t,n){const e=Math.abs(t.clientX-n.clientX),o=Math.abs(t.clientY-n.clientY),i=e/o;let a,r;return i>.3&&i<1.7?a=r=!0:e>o?a=!0:r=!0,{x:a,y:r}}(i[0],i[1]),l=n.options.zoom?.mode;D(t,{x:c.x&&s(l,"x",t)?a:1,y:c.y&&s(l,"y",t)?a:1,focalPoint:{x:o.x-r.left,y:o.y-r.top}},"zoom","pinch"),n.scale=e.scale}}function tt(t,n,e){const o=n.delta;o&&(n.panning=!0,E(t,{x:e.deltaX-o.x,y:e.deltaY-o.y},n.panScales&&n.panScales.map((n=>t.scales[n])).filter(Boolean)),n.delta={x:e.deltaX,y:e.deltaY})}const nt=new WeakMap;function et(t,o){const i=u(t),a=t.canvas,{pan:r,zoom:s}=o,c=new n.Manager(a);s?.pinch?.enabled&&(c.add(new n.Pinch),c.on("pinchstart",(n=>function(t,n,o){if(n.options.zoom?.pinch?.enabled){const i=e.getRelativePosition(o.srcEvent,t);!1===n.options.zoom?.onZoomStart?.({chart:t,event:o.srcEvent,point:i})?(n.scale=null,n.options.zoom?.onZoomRejected?.({chart:t,event:o.srcEvent})):n.scale=1}}(t,i,n))),c.on("pinch",(n=>Q(t,i,n))),c.on("pinchend",(n=>function(t,n,e){n.scale&&(Q(t,n,e),n.scale=null,n.options.zoom?.onZoomComplete?.({chart:t}))}(t,i,n)))),r&&r.enabled&&(c.add(new n.Pan({threshold:r.threshold,enable:J(t,i)})),c.on("panstart",(n=>function(t,n,e){const{enabled:o,onPanStart:i,onPanRejected:a}=n.options.pan??{};if(!o)return;const r=e.target.getBoundingClientRect(),s={x:e.center.x-r.left,y:e.center.y-r.top};if(!1===i?.({chart:t,event:e,point:s}))return a?.({chart:t,event:e});n.panScales=l(n.options.pan,s,t).map((t=>t.id)),n.delta={x:0,y:0},tt(t,n,e)}(t,i,n))),c.on("panmove",(n=>tt(t,i,n))),c.on("panend",(()=>function(t,n){n.delta=null,n.panning&&(n.panning=!1,n.filterNextClick=!0,n.options.pan?.onPanComplete?.({chart:t}))}(t,i)))),nt.set(t,c)}function ot(t){const n=nt.get(t);n&&(n.remove("pinchstart"),n.remove("pinch"),n.remove("pinchend"),n.remove("panstart"),n.remove("pan"),n.remove("panend"),n.destroy(),nt.delete(t))}function it(t,n,e){const o=e.zoom?.drag,{dragStart:i,dragEnd:a}=u(t);if(o?.drawTime!==n||!i||!a)return;const{left:r,top:s,width:c,height:l}=U(t,e.zoom?.mode,{dragStart:i,dragEnd:a},o.maintainAspectRatio),m=t.ctx;m.save(),m.beginPath(),m.fillStyle=o.backgroundColor||"rgba(225,225,225,0.3)",m.fillRect(r,s,c,l),o.borderWidth&&(m.lineWidth=o.borderWidth,m.strokeStyle=o.borderColor||"rgba(225,225,225)",m.strokeRect(r,s,c,l)),m.restore()}const at=t=>{t.pan=(n,e,o)=>E(t,n,e,o,"api"),t.zoom=(n,e)=>D(t,n,e),t.zoomRect=(n,e,o)=>R(t,n,e,o),t.zoomScale=(n,e,o)=>function(t,n,e,o="none",i="api"){const a=u(t);O(t,a),x(t.scales[n],e,void 0,!0),t.update(o),a.options.zoom?.onZoom?.({chart:t,trigger:i})}(t,n,e,o),t.resetZoom=n=>function(t,n="default"){const e=u(t),o=O(t,e);for(const n of Object.values(t.scales)){const t=n.options;o[n.id]?(t.min=o[n.id].min.options,t.max=o[n.id].max.options):(delete t.min,delete t.max),delete e.updatedScaleLimits[n.id]}t.update(n),e.options.zoom?.onZoomComplete?.({chart:t})}(t,n),t.getZoomLevel=()=>function(t){const n=u(t);let e=1,o=1;for(const i of Object.values(t.scales)){const t=L(n,i.id);if(t){const n=Math.round(t/(i.max-i.min)*100)/100;e=Math.min(e,n),o=Math.max(o,n)}}return e<1?e:o}(t),t.getInitialScaleBounds=()=>F(t),t.getZoomedScaleBounds=()=>function(t){const n=u(t),e={};for(const o of Object.keys(t.scales))e[o]=n.updatedScaleLimits[o];return e}(t),t.isZoomedOrPanned=()=>function(t){const n=F(t);for(const e of Object.keys(t.scales)){const{min:o,max:i}=n[e];if(void 0!==o&&t.scales[e].min!==o)return!0;if(void 0!==i&&t.scales[e].max!==i)return!0}return!1}(t),t.isZoomingOrPanning=()=>function(t){const n=u(t);return!(!A(n)&&!n.filterNextClick)}(t)};var rt={id:"zoom",version:"2.2.10",defaults:{pan:{enabled:!1,mode:"xy",threshold:10,modifierKey:null},zoom:{wheel:{enabled:!1,speed:.1,modifierKey:null},drag:{enabled:!1,drawTime:"beforeDatasetsDraw",modifierKey:null},pinch:{enabled:!1},mode:"xy"}},start(t,e,o){u(t).options=o,Object.prototype.hasOwnProperty.call(o.zoom,"enabled")&&console.warn("The option `zoom.enabled` is no longer supported. Please use `zoom.wheel.enabled`, `zoom.drag.enabled`, or `zoom.pinch.enabled`."),(Object.prototype.hasOwnProperty.call(o.zoom,"overScaleMode")||Object.prototype.hasOwnProperty.call(o.pan,"overScaleMode"))&&console.warn("The option `overScaleMode` is deprecated. Please use `scaleMode` instead (and update `mode` as desired)."),n&&et(t,o),at(t)},beforeEvent(t,{event:n}){const e=u(t);return!A(e)&&("click"!==n.type&&"mouseup"!==n.type||!e.filterNextClick?void 0:(e.filterNextClick=!1,!1))},beforeUpdate(t,n,e){const o=u(t),i=o.options;o.options=e,function(t,n){const{pan:e,zoom:o}=t,{pan:i,zoom:a}=n;return o?.pinch?.enabled!==a?.pinch?.enabled||e?.enabled!==i?.enabled||e?.threshold!==i?.threshold}(i,e)&&(ot(t),et(t,e)),function(t,n){const e=t.canvas,{wheel:o,drag:i,onZoomComplete:a}=n.zoom??{};o?.enabled?(Y(t,e,"wheel",_),G(t,"onZoomComplete",a,250)):T(t,"wheel"),i?.enabled?(Y(t,e,"mousedown",K),Y(t,e.ownerDocument,"mouseup",$)):(T(t,"mousedown"),T(t,"mousemove"),T(t,"mouseup"),T(t,"keydown"))}(t,e)},beforeDatasetsDraw(t,n,e){it(t,"beforeDatasetsDraw",e)},afterDatasetsDraw(t,n,e){it(t,"afterDatasetsDraw",e)},beforeDraw(t,n,e){it(t,"beforeDraw",e)},afterDraw(t,n,e){it(t,"afterDraw",e)},stop(t){!function(t){T(t,"mousedown"),T(t,"mousemove"),T(t,"mouseup"),T(t,"wheel"),T(t,"click"),T(t,"keydown")}(t),n&&ot(t),function(t){m.delete(t)}(t)},panFunctions:S,zoomFunctions:M,zoomRectFunctions:z};return t.Chart.register(rt),rt}));
|
|
7
|
+
!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n(require("chart.js"),require("hammerjs"),require("chart.js/helpers")):"function"==typeof define&&define.amd?define(["chart.js","hammerjs","chart.js/helpers"],n):(t="undefined"!=typeof globalThis?globalThis:t||self).ChartZoom=n(t.Chart,t.Hammer,t.Chart.helpers)}(this,(function(t,n,e){"use strict";const o=t=>`${t}Key`,i=t=>t?.enabled&&t.modifierKey?t.modifierKey:void 0,a=(t,n)=>t&&n[o(t)],r=(t,n)=>t&&!n[o(t)];function s(t,n,e){return void 0===t||("string"==typeof t?-1!==t.indexOf(n):"function"==typeof t&&-1!==t({chart:e}).indexOf(n))}function c(t,n){return"function"==typeof t&&(t=t({chart:n})),"string"==typeof t?{x:-1!==t.indexOf("x"),y:-1!==t.indexOf("y")}:{x:!1,y:!1}}function l(t,n,e){const{mode:o="xy",scaleMode:i,overScaleMode:a}=t||{},r=function({x:t,y:n},e){const o=e.scales,i=Object.keys(o);for(let e=0;e<i.length;e++){const a=o[i[e]];if(n>=a.top&&n<=a.bottom&&t>=a.left&&t<=a.right)return a}return null}(n,e),s=c(o,e),l=c(i,e);return((t,n,e,o)=>{if(!n)return;const i=c(n,t);for(const t of["x","y"])i[t]&&(e[t]=o[t],o[t]=!1)})(e,a,l,s),r&&l[r.axis]?[r]:((t,n)=>{const e=[];for(const o of Object.values(t.scales))n[o.axis]&&e.push(o);return e||Object.values(t.scales)})(e,s)}const m=new WeakMap;function u(t){let n=m.get(t);return n||(n={originalScaleLimits:{},updatedScaleLimits:{},handlers:{},options:{},targets:{},panDelta:{},dragging:!1,panning:!1},m.set(t,n)),n}const d=t=>void 0===t||isNaN(t);function f(t,n,o,i){const a=o&&e.isNumber(t)&&e.isNumber(n)?Math.max(0,Math.min(1,(t-n)/o)):0;return{min:i*a,max:i*(1-a)}}function p(t,n){const e=t.isHorizontal()?n.x:n.y;return t.getValueForPixel(e)}function h(t,n,e){const o=t.max-t.min,i=o*(n-1);return f(p(t,e),t.min,o,i)}function g(t,n,o,i,a){let r=o[i];if("original"===r){const o=t.originalScaleLimits[n.id][i];if(e.isNumber(o.options))return o.options;if(!e.isNullOrUndef(o.options)){const t=n.parse(o.options);if(e.isNumber(t))return t}r=o.scale}return e.valueOrDefault(r,a)}function x(t,{min:n,max:o},i,a=!1,r=!1){const s=u(t.chart),{options:c}=t,l=function(t,n){return n?.[t.id]||n?.[t.axis]||{}}(t,i),{minRange:m=0}=l,d=g(s,t,l,"min",-1/0),f=g(s,t,l,"max",1/0);if(r&&(n<d||o>f))return!0;const p=t.max-t.min,h=a?Math.max(o-n,m):p;if(a&&h===m&&p<=m)return!0;const x=function(t,{min:n,max:o,minLimit:i,maxLimit:a},r,s){const c=(t-o+n)/2;n-=c,o+=c;const l={min:"original",max:"original"},m=g(r,s,l,"min",-1/0),u=g(r,s,l,"max",1/0),d=t/1e6;return e.almostEquals(n,m,d)&&(n=m),e.almostEquals(o,u,d)&&(o=u),n<i?(n=i,o=Math.min(i+t,a)):o>a&&(o=a,n=Math.max(a-t,i)),{min:n,max:o}}(h,{min:n,max:o,minLimit:d,maxLimit:f},s,t);return c.min=x.min,c.max=x.max,s.updatedScaleLimits[t.id]=x,t.parse(x.min)!==t.min||t.parse(x.max)!==t.max}const y=t=>0===t||isNaN(t)?0:t<0?Math.min(Math.round(t),-1):Math.max(Math.round(t),1);const b={millisecond:0,second:500,minute:3e4,hour:18e5,day:432e5,week:3024e5,month:1296e6,quarter:5184e6,year:157248e5};function v(t,n,e,o=!1){const{min:i,max:a}=t;let r=0;if((t=>"time"===t.type)(t)){const n=t.options.time?.round;r=n?b[n]:0}const s=t.getValueForPixel(t.getPixelForValue(i+r)-n),c=t.getValueForPixel(t.getPixelForValue(a+r)-n);return!(!d(s)&&!d(c))||x(t,{min:s,max:c},e,o,!0)}function w(t,n,e){return v(t,n,e,!0)}const M={category:function(t,n,e,o){const i=h(t,n,e);return t.min===t.max&&n<1&&function(t){const n=t.getLabels().length-1;t.min>0&&(t.min-=1),t.max<n&&(t.max+=1)}(t),x(t,{min:t.min+y(i.min),max:t.max-y(i.max)},o,!0)},default:function(t,n,e,o){const i=h(t,n,e);return x(t,{min:t.min+i.min,max:t.max-i.max},o,!0)},logarithmic:function(t,n,e,o){const i=function(t,n,e){const o=p(t,e);if(void 0===o)return{min:t.min,max:t.max};const i=Math.log10(t.min),a=Math.log10(t.max),r=a-i,s=f(Math.log10(o),i,r,r*(n-1));return{min:Math.pow(10,i+s.min),max:Math.pow(10,a-s.max)}}(t,n,e);return x(t,i,o,!0)}},z={default:function(t,n,e,o){return x(t,function(t,n,e){const o=t.getValueForPixel(n)??t.min,i=t.getValueForPixel(e)??t.max;return{min:Math.min(o,i),max:Math.max(o,i)}}(t,n,e),o,!0)}},S={category:function(t,n,e){const o=t.getLabels().length-1;let{min:i,max:a}=t;const r=Math.max(a-i,1),s=Math.round(function(t){return t.isHorizontal()?t.width:t.height}(t)/Math.max(r,10)),c=Math.round(Math.abs(n/s));let l;return n<-s?(a=Math.min(a+c,o),i=1===r?a:a-r,l=a===o):n>s&&(i=Math.max(0,i-c),a=1===r?i:i+r,l=0===i),x(t,{min:i,max:a},e)||Boolean(l)},default:v,logarithmic:w,timeseries:w};function P(t,n,e){const{id:o,options:{min:i,max:a}}=t;if(!n[o]||!e[o])return!0;const r=e[o];return r.min!==i||r.max!==a}function j(t,n){for(const e of Object.keys(t))n[e]||delete t[e]}function O(t,n){const{scales:e}=t,{originalScaleLimits:o,updatedScaleLimits:i}=n;for(const t of Object.values(e))P(t,o,i)&&(o[t.id]={min:{scale:t.min,options:t.options.min},max:{scale:t.max,options:t.options.max}});return j(o,e),j(i,e),o}function k(t,n,e,o){const i=M[t.type]||M.default;i?.(t,n,e,o)}function C(t,n,e,o){const i=z[t.type]||z.default;i?.(t,n,e,o)}function Z(t){const n=t.chartArea;return{x:(n.left+n.right)/2,y:(n.top+n.bottom)/2}}function D(t,n,e="none",o="api"){const{x:i=1,y:a=1,focalPoint:r=Z(t)}="number"==typeof n?{x:n,y:n}:n,s=u(t),{options:{limits:c={},zoom:m}}=s;O(t,s);const d=1!==i,f=1!==a,p=l(m,r,t);for(const t of p)t.isHorizontal()&&d?k(t,i,r,c):!t.isHorizontal()&&f&&k(t,a,r,c);t.update(e),m?.onZoom?.({chart:t,trigger:o,amount:{x:i,y:a,focalPoint:r}})}function R(t,n,e,o="none",i="api"){const a=u(t),{options:{limits:r={},zoom:c={}}}=a,{mode:l="xy"}=c;O(t,a);const m=s(l,"x",t),d=s(l,"y",t);for(const o of Object.values(t.scales))o.isHorizontal()&&m?C(o,n.x,e.x,r):!o.isHorizontal()&&d&&C(o,n.y,e.y,r);t.update(o),c.onZoom?.({chart:t,trigger:i})}function L(t,n){const o=t.originalScaleLimits[n];if(!o)return;const{min:i,max:a}=o;return e.isNumber(a.options)&&e.isNumber(i.options)?a.options-i.options:e.isNumber(a.scale)&&e.isNumber(i.scale)?a.scale-i.scale:void 0}function N(t,n,o,i){const{panDelta:a}=i,r=a[t.id]||0;e.sign(r)===e.sign(n)&&(n+=r);const s=S[t.type]||S.default;s?.(t,n,o)?a[t.id]=0:a[t.id]=n}function E(t,n,e,o="none",i="other"){const{x:a=0,y:r=0}="number"==typeof n?{x:n,y:n}:n,s=u(t),{options:{pan:c,limits:l={}}}=s,{onPan:m}=c||{};O(t,s);const d=0!==a,f=0!==r,p=e||Object.values(t.scales);for(const t of p)t.isHorizontal()&&d?N(t,a,l,s):!t.isHorizontal()&&f&&N(t,r,l,s);t.update(o),m?.({chart:t,trigger:i,delta:{x:a,y:r}})}function F(t){const n=u(t);O(t,n);const e={};for(const o of Object.keys(t.scales)){const{min:t,max:i}=n.originalScaleLimits[o]||{min:{},max:{}};e[o]={min:t.scale,max:i.scale}}return e}function A(t){return t.panning||t.dragging}const H=(t,n,e)=>Math.min(e,Math.max(n,t));function T(t,n){const{handlers:e,targets:o}=u(t),i=e[n],a=o[n];i&&a&&(a.removeEventListener(n,i),delete e[n])}function Y(t,n,e,o){const{handlers:i,options:a,targets:r}=u(t);if(i[e]&&r[e]===n)return;T(t,e);const s=i[e]=n=>o(t,n,a);r[e]=n;const c="wheel"!==e&&void 0;n.addEventListener(e,s,{passive:c})}function B(t,n){const e=u(t);e.dragStart&&(e.dragging=!0,e.dragEnd=n,t.draw())}function q(t,n){const e=u(t);e.dragStart&&"Escape"===n.key&&(T(t,"keydown"),e.dragging=!1,e.dragStart=e.dragEnd=void 0,t.draw())}function V(t,n){if(t.target!==n.canvas){const e=n.canvas.getBoundingClientRect();return{x:t.clientX-e.left,y:t.clientY-e.top}}return e.getRelativePosition(t,n)}function X(t,n,e){const{onZoomStart:o,onZoomRejected:i}=e;if(o){const e=V(n,t);if(!1===o?.({chart:t,event:n,point:e}))return i?.({chart:t,event:n}),!1}}function K(t,n){if(t.legend){const o=e.getRelativePosition(n,t);if(e._isPointInArea(o,t.legend))return}const o=u(t),{pan:s,zoom:c={}}=o.options;if(0!==n.button||a(i(s),n)||r(i(c.drag),n))return c.onZoomRejected?.({chart:t,event:n});!1!==X(t,n,c)&&(o.dragStart=n,Y(t,t.canvas.ownerDocument,"mousemove",B),Y(t,window.document,"keydown",q))}function W(t,n,e,{min:o,max:i,prop:a}){t[o]=H(Math.min(e.begin[a],e.end[a]),n[o],n[i]),t[i]=H(Math.max(e.begin[a],e.end[a]),n[o],n[i])}function I(t,n,e){const o={begin:V(n.dragStart,t),end:V(n.dragEnd,t)};if(e){!function({begin:t,end:n},e){let o=n.x-t.x,i=n.y-t.y;const a=Math.abs(o/i);a>e?o=Math.sign(o)*Math.abs(i*e):a<e&&(i=Math.sign(i)*Math.abs(o/e)),n.x=t.x+o,n.y=t.y+i}(o,t.chartArea.width/t.chartArea.height)}return o}function U(t,n,e,o){const i=s(n,"x",t),a=s(n,"y",t),{top:r,left:c,right:l,bottom:m,width:u,height:d}=t.chartArea,f={top:r,left:c,right:l,bottom:m},p=I(t,e,o&&i&&a);i&&W(f,t.chartArea,p,{min:"left",max:"right",prop:"x"}),a&&W(f,t.chartArea,p,{min:"top",max:"bottom",prop:"y"});const h=f.right-f.left,g=f.bottom-f.top;return{...f,width:h,height:g,zoomX:i&&h?1+(u-h)/u:1,zoomY:a&&g?1+(d-g)/d:1}}function $(t,n){const e=u(t);if(!e.dragStart)return;T(t,"mousemove");const{mode:o,onZoomComplete:i,drag:a}=e.options.zoom??{},{threshold:r=0,maintainAspectRatio:c}=a??{},l=U(t,o,{dragStart:e.dragStart,dragEnd:n},c),m=s(o,"x",t)?l.width:0,d=s(o,"y",t)?l.height:0,f=Math.sqrt(m*m+d*d);if(e.dragStart=e.dragEnd=void 0,f<=r)return e.dragging=!1,void t.draw();R(t,{x:l.left,y:l.top},{x:l.right,y:l.bottom},"zoom","drag"),e.dragging=!1,e.filterNextClick=!0,i?.({chart:t})}function _(t,n){const{handlers:{onZoomComplete:e},options:{zoom:o={}}}=u(t);if(!function(t,n,e){if(r(i(e.wheel),n))e.onZoomRejected?.({chart:t,event:n});else if(!1!==X(t,n,e)&&(n.cancelable&&n.preventDefault(),void 0!==n.deltaY))return!0}(t,n,o))return;const a=n.target?.getBoundingClientRect(),s=o?.wheel?.speed??.1,c=n.deltaY>=0?2-1/(1-s):1+s;D(t,{x:c,y:c,focalPoint:{x:n.clientX-a.left,y:n.clientY-a.top}},"zoom","wheel"),e?.(n)}function G(t,n,e,o){e&&(u(t).handlers[n]=function(t,n){let e;return function(){return clearTimeout(e),e=setTimeout(t,n),n}}((()=>e?.({chart:t})),o))}function J(t,n){return function(e,o){const{pan:s,zoom:c={}}=n.options;if(!s||!s.enabled)return!1;const l=o&&o.srcEvent;return!l||(!(!n.panning&&"mouse"===o.pointerType&&(r(i(s),l)||a(i(c.drag),l)))||(s.onPanRejected?.({chart:t,event:o}),!1))}}function Q(t,n,e){if(n.scale){const{center:o,pointers:i}=e,a=1/n.scale*e.scale,r=e.target.getBoundingClientRect(),c=function(t,n){const e=Math.abs(t.clientX-n.clientX),o=Math.abs(t.clientY-n.clientY),i=e/o;let a,r;return i>.3&&i<1.7?a=r=!0:e>o?a=!0:r=!0,{x:a,y:r}}(i[0],i[1]),l=n.options.zoom?.mode;D(t,{x:c.x&&s(l,"x",t)?a:1,y:c.y&&s(l,"y",t)?a:1,focalPoint:{x:o.x-r.left,y:o.y-r.top}},"zoom","pinch"),n.scale=e.scale}}function tt(t,n,e){const o=n.delta;o&&(n.panning=!0,E(t,{x:e.deltaX-o.x,y:e.deltaY-o.y},n.panScales&&n.panScales.map((n=>t.scales[n])).filter(Boolean)),n.delta={x:e.deltaX,y:e.deltaY})}const nt=new WeakMap;function et(t,o){const i=u(t),a=t.canvas,{pan:r,zoom:s}=o,c=new n.Manager(a);s?.pinch?.enabled&&(c.add(new n.Pinch),c.on("pinchstart",(n=>function(t,n,o){if(n.options.zoom?.pinch?.enabled){const i=e.getRelativePosition(o.srcEvent,t);!1===n.options.zoom?.onZoomStart?.({chart:t,event:o.srcEvent,point:i})?(n.scale=null,n.options.zoom?.onZoomRejected?.({chart:t,event:o.srcEvent})):n.scale=1}}(t,i,n))),c.on("pinch",(n=>Q(t,i,n))),c.on("pinchend",(n=>function(t,n,e){n.scale&&(Q(t,n,e),n.scale=null,n.options.zoom?.onZoomComplete?.({chart:t}))}(t,i,n)))),r&&r.enabled&&(c.add(new n.Pan({threshold:r.threshold,enable:J(t,i)})),c.on("panstart",(n=>function(t,n,e){const{enabled:o,onPanStart:i,onPanRejected:a}=n.options.pan??{};if(!o)return;const r=e.target.getBoundingClientRect(),s={x:e.center.x-r.left,y:e.center.y-r.top};if(!1===i?.({chart:t,event:e,point:s}))return a?.({chart:t,event:e});n.panScales=l(n.options.pan,s,t).map((t=>t.id)),n.delta={x:0,y:0},tt(t,n,e)}(t,i,n))),c.on("panmove",(n=>tt(t,i,n))),c.on("panend",(()=>function(t,n){n.delta=null,n.panning&&(n.panning=!1,n.filterNextClick=!0,n.options.pan?.onPanComplete?.({chart:t}))}(t,i)))),nt.set(t,c)}function ot(t){const n=nt.get(t);n&&(n.remove("pinchstart"),n.remove("pinch"),n.remove("pinchend"),n.remove("panstart"),n.remove("pan"),n.remove("panend"),n.destroy(),nt.delete(t))}function it(t,n,e){const o=e.zoom?.drag,{dragStart:i,dragEnd:a}=u(t);if(o?.drawTime!==n||!i||!a)return;const{left:r,top:s,width:c,height:l}=U(t,e.zoom?.mode,{dragStart:i,dragEnd:a},o.maintainAspectRatio),m=t.ctx;m.save(),m.beginPath(),m.fillStyle=o.backgroundColor||"rgba(225,225,225,0.3)",m.fillRect(r,s,c,l),o.borderWidth&&(m.lineWidth=o.borderWidth,m.strokeStyle=o.borderColor||"rgba(225,225,225)",m.strokeRect(r,s,c,l)),m.restore()}const at=t=>{t.pan=(n,e,o)=>E(t,n,e,o,"api"),t.zoom=(n,e)=>D(t,n,e),t.zoomRect=(n,e,o)=>R(t,n,e,o),t.zoomScale=(n,e,o)=>function(t,n,e,o="none",i="api"){const a=u(t);O(t,a),x(t.scales[n],e,void 0,!0),t.update(o),a.options.zoom?.onZoom?.({chart:t,trigger:i})}(t,n,e,o),t.resetZoom=n=>function(t,n="default"){const e=u(t),o=O(t,e);for(const n of Object.values(t.scales)){const t=n.options;o[n.id]?(t.min=o[n.id].min.options,t.max=o[n.id].max.options):(delete t.min,delete t.max),delete e.updatedScaleLimits[n.id]}t.update(n),e.options.zoom?.onZoomComplete?.({chart:t})}(t,n),t.getZoomLevel=()=>function(t){const n=u(t);let e=1,o=1;for(const i of Object.values(t.scales)){const t=L(n,i.id);if(t){const n=Math.round(t/(i.max-i.min)*100)/100;e=Math.min(e,n),o=Math.max(o,n)}}return e<1?e:o}(t),t.getInitialScaleBounds=()=>F(t),t.getZoomedScaleBounds=()=>function(t){const n=u(t),e={};for(const o of Object.keys(t.scales))e[o]=n.updatedScaleLimits[o];return e}(t),t.isZoomedOrPanned=()=>function(t){const n=F(t);for(const e of Object.keys(t.scales)){const{min:o,max:i}=n[e];if(void 0!==o&&t.scales[e].min!==o)return!0;if(void 0!==i&&t.scales[e].max!==i)return!0}return!1}(t),t.isZoomingOrPanning=()=>function(t){const n=u(t);return!(!A(n)&&!n.filterNextClick)}(t)};var rt={id:"zoom",version:"2.2.12",defaults:{pan:{enabled:!1,mode:"xy",threshold:10,modifierKey:null},zoom:{wheel:{enabled:!1,speed:.1,modifierKey:null},drag:{enabled:!1,drawTime:"beforeDatasetsDraw",modifierKey:null},pinch:{enabled:!1},mode:"xy"}},start(t,e,o){u(t).options=o,Object.prototype.hasOwnProperty.call(o.zoom,"enabled")&&console.warn("The option `zoom.enabled` is no longer supported. Please use `zoom.wheel.enabled`, `zoom.drag.enabled`, or `zoom.pinch.enabled`."),(Object.prototype.hasOwnProperty.call(o.zoom,"overScaleMode")||Object.prototype.hasOwnProperty.call(o.pan,"overScaleMode"))&&console.warn("The option `overScaleMode` is deprecated. Please use `scaleMode` instead (and update `mode` as desired)."),n&&et(t,o),at(t)},beforeEvent(t,{event:n}){const e=u(t);return!A(e)&&("click"!==n.type&&"mouseup"!==n.type||!e.filterNextClick?void 0:(e.filterNextClick=!1,!1))},beforeUpdate(t,n,e){const o=u(t),i=o.options;o.options=e,function(t,n){const{pan:e,zoom:o}=t,{pan:i,zoom:a}=n;return o?.pinch?.enabled!==a?.pinch?.enabled||e?.enabled!==i?.enabled||e?.threshold!==i?.threshold}(i,e)&&(ot(t),et(t,e)),function(t,n){const e=t.canvas,{wheel:o,drag:i,onZoomComplete:a}=n.zoom??{};o?.enabled?(Y(t,e,"wheel",_),G(t,"onZoomComplete",a,250)):T(t,"wheel"),i?.enabled?(Y(t,e,"mousedown",K),Y(t,e.ownerDocument,"mouseup",$)):(T(t,"mousedown"),T(t,"mousemove"),T(t,"mouseup"),T(t,"keydown"))}(t,e)},beforeDatasetsDraw(t,n,e){it(t,"beforeDatasetsDraw",e)},afterDatasetsDraw(t,n,e){it(t,"afterDatasetsDraw",e)},beforeDraw(t,n,e){it(t,"beforeDraw",e)},afterDraw(t,n,e){it(t,"afterDraw",e)},stop(t){!function(t){T(t,"mousedown"),T(t,"mousemove"),T(t,"mouseup"),T(t,"wheel"),T(t,"click"),T(t,"keydown")}(t),n&&ot(t),function(t){m.delete(t)}(t)},panFunctions:S,zoomFunctions:M,zoomRectFunctions:z};return t.Chart.register(rt),rt}));
|
|
8
8
|
//# sourceMappingURL=chartjs-plugin-zoom.min.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"core.d.ts","sourceRoot":"","sources":["../../src/core.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AC,KAAK,EAAE,KAAK,WAe5C;AAED,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,KAAK,WAEnD;AAED,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,KAAK,WAK9C"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"defaults.d.ts","sourceRoot":"","sources":["../../src/defaults.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAA;AAElD,eAAO,MAAM,QAAQ,EAAE,iBAuBtB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hammer.d.ts","sourceRoot":"","sources":["../../src/hammer.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,UAAU,CAAA;AACrC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAA;AAkIlD,wBAAgB,WAAW,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,iBAAiB,QA0BnE;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,KAAK,QAYtC;AAED,wBAAgB,oBAAoB,CAAC,UAAU,EAAE,iBAAiB,EAAE,UAAU,EAAE,iBAAiB,WAehG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handlers.d.ts","sourceRoot":"","sources":["../../src/handlers.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,KAAK,EAAoB,MAAM,UAAU,CAAA;AACvD,OAAO,KAAK,EAAE,UAAU,EAAe,iBAAiB,EAAE,MAAM,WAAW,CAAA;AAqC3E,wBAAgB,SAAS,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,QAOxD;AAoCD,wBAAgB,SAAS,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,UAAU,GAAG,IAAI,CAwB/D;AAiDD,wBAAgB,eAAe,CAC7B,KAAK,EAAE,KAAK,EACZ,IAAI,EAAE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EACvE,MAAM,GAAG,OAAO;QAEhB,GAAG,CAAC,GAAG,EAAE,SAAS,EAAE,MAAM,CAAC,EAAE,KAAK,EAAE,EAAE,IAAI,CAAC,EAAE,UAAU,GAAG,IAAI,CAAA;QAC9D,IAAI,CAAC,IAAI,EAAE,UAAU,EAAE,IAAI,CAAC,EAAE,UAAU,GAAG,IAAI,CAAA;QAC/C,QAAQ,CAAC,EAAE,EAAE,KAAK,EAAE,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,EAAE,UAAU,GAAG,IAAI,CAAA;QACvD,SAAS,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,CAAC,EAAE,UAAU,GAAG,IAAI,CAAA;QACjE,SAAS,CAAC,IAAI,CAAC,EAAE,UAAU,GAAG,IAAI,CAAA;QAClC,YAAY,IAAI,MAAM,CAAA;QACtB,qBAAqB,IAAI,MAAM,CAAC,MAAM,EAAE;YAAE,GAAG,CAAC,EAAE,MAAM,CAAC;YAAC,GAAG,CAAC,EAAE,MAAM,CAAA;SAAE,CAAC,CAAA;QACvE,oBAAoB,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,UAAU,CAAC,CAAC,CAAA;QAC3D,gBAAgB,IAAI,OAAO,CAAA;QAC3B,kBAAkB,IAAI,OAAO,CAAA;KAC9B;CACF;AAED,eAAe,MAAM,CAAA;AACrB,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,QAAQ,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.umd.d.ts","sourceRoot":"","sources":["../../src/index.umd.ts"],"names":[],"mappings":"AACA,OAAO,IAAI,MAAM,UAAU,CAAA;AAI3B,eAAe,IAAI,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"options.d.ts","sourceRoot":"","sources":["../../src/options.ts"],"names":[],"mappings":";AAAA,OA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,CAAA;CACnB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../../src/plugin.ts"],"names":[],"mappings":"AAmBA,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AACjD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAA;;;;;iBAmDnC,KAAK,SAAS,OAAO,WAAW,iBAAiB;uBA0BrD,KAAK;eACQ,UAAU;gBAAU,OAAO;oBAAc,IAAI;qBAAe,OAAO;QACtF,OAAO,GAAG,IAAI;wBAeG,KAAK,SAAS,OAAO,WAAW,iBAAiB;8BAc3C,KAAK,SAAS,OAAO,WAAW,iBAAiB;6BAIlD,KAAK,SAAS,OAAO,WAAW,iBAAiB;sBAIxD,KAAK,SAAS,OAAO,WAAW,iBAAiB;qBAIlD,KAAK,SAAS,OAAO,WAAW,iBAAiB;gBAItD,KAAK;;;;;AAhFnB,wBA4FC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scale.types.d.ts","sourceRoot":"","sources":["../../src/scale.types.ts"],"names":[],"mappings":"AACA,OAAO,EAAY,KAAK,UAAU,EAAc,MAAM,SAAS,CAAA;AAC/D,OAAO,KAAK,EAAE,KAAK,EAAE,KAAK,EAAuB,MAAM,UAAU,CAAA;AACjE,OAAO,KAAK,EAAE,YAAY,EAAe,MAAM,WAAW,CAAA;AAE1D,MAAM,MAAM,YAAY,GAAG,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,KAAK,OAAO,CAAA;AACvG,MAAM,MAAM,gBAAgB,GAAG,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,KAAK,OAAO,CAAA;AACxG,MAAM,MAAM,WAAW,GAAG,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,YAAY,KAAK,OAAO,CAAA;AAMxF,wBAAgB,SAAS,CACvB,GAAG,EAAE,MAAM,GAAG,SAAS,EACvB,GAAG,EAAE,MAAM,GAAG,SAAS,EACvB,KAAK,EAAE,MAAM,EACb,QAAQ,EAAE,MAAM,GACf,UAAU,CAQZ;AAyGD,wBAAgB,WAAW,CACzB,KAAK,EAAE,KAAK,EACZ,EAAE,GAAG,EAAE,GAAG,EAAE,EAAE,UAAU,EACxB,MAAM,CAAC,EAAE,YAAY,EACrB,IAAI,UAAQ,EACZ,GAAG,UAAQ,GACV,OAAO,CA+BT;AAsGD,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAItD,CAAA;AAED,eAAO,MAAM,iBAAiB,EAAE,MAAM,CAAC,MAAM,EAAE,gBAAgB,CAE9D,CAAA;AAED,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,WAAW,CAKpD,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scale.types.test.d.ts","sourceRoot":"","sources":["../../src/scale.types.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../src/state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,KAAK,KAAK,EAAE,MAAM,UAAU,CAAA;AAC5C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAA;AAElD,MAAM,MAAM,UAAU,GAAG;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAAA;AACrD,MAAM,MAAM,cAAc,GAAG;IAAE,GAAG,EAAE;QAAE,KAAK,CAAC,EAAE,MAAM,CAAC;QAAC,OAAO,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC;IAAC,GAAG,EAAE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C;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAAA;AACrD,MAAM,MAAM,iBAAiB,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,OAAO,CAAC,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,KAAK,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,UAAU,CAAA;AACnD,OAAO,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,WAAW,CAAA;AAIjF,eAAO,MAAM,cAAc,UAAW,WAAW,GAAG,UAAU,KAAG,WAAW,GAAG,SACb,CAAA;AAClE,eAAO,MAAM,UAAU,QAAS,WAAW,GAAG,SAAS,SAAS,UAAU,GAAG,UAAU,GAAG,YAAY,wBACzE,CAAA;AAC7B,eAAO,MAAM,aAAa,QAAS,WAAW,GAAG,SAAS,SAAS,UAAU,GAAG,UAAU,GAAG,YAAY,wBAC3E,CAAA;AAE9B,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,UAAU,GAAG,SAAS,EAAE,GAAG,EAAE,GAAG,GAAG,GAAG,EAAE,KAAK,EAAE,KAAK,GAAG,OAAO,CAUpG;AAaD,wBAAgB,QAAQ,CAAC,EAAE,EAAE,MAAM,IAAI,EAAE,KAAK,EAAE,MAAM,GAAG,SAAS,4BAOjE;AA+CD;;;;GAIG;AACH,wBAAgB,uBAAuB,CAAC,OAAO,EAAE,UAAU,GAAG,SAAS,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,GAAG,KAAK,EAAE,CAe5G"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.test.d.ts","sourceRoot":"","sources":["../../src/utils.test.ts"],"names":[],"mappings":""}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thewhitehaven04/chartjs-plugin-zoom",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.13",
|
|
4
4
|
"description": "A fork of the ChartJS Zoom plugin that enables zoom and pan functionality in Chart.js charts",
|
|
5
5
|
"homepage": "https://www.chartjs.org/chartjs-plugin-zoom/",
|
|
6
6
|
"repository": {
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"unpkg": "./dist/@thewhitehaven04/chartjs-plugin-zoom.min.js",
|
|
14
14
|
"main": "./dist/@thewhitehaven04/chartjs-plugin-zoom.js",
|
|
15
15
|
"module": "./dist/@thewhitehaven04/chartjs-plugin-zoom.esm.js",
|
|
16
|
-
"types": "./
|
|
16
|
+
"types": "./types/index.d.ts",
|
|
17
17
|
"exports": {
|
|
18
18
|
".": {
|
|
19
19
|
"types": "./dist/src/index.d.ts",
|
|
@@ -22,9 +22,9 @@
|
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
"files": [
|
|
25
|
-
"dist
|
|
26
|
-
"dist
|
|
27
|
-
"dist
|
|
25
|
+
"dist/**/*.js",
|
|
26
|
+
"dist/**/*.d.ts",
|
|
27
|
+
"dist/**/*.map"
|
|
28
28
|
],
|
|
29
29
|
"scripts": {
|
|
30
30
|
"autobuild": "rollup -c -w",
|