!/**
 * Highstock JS v12.6.0 (2026-04-13)
 * @module highcharts/modules/drag-panes
 * @requires highcharts
 * @requires highcharts/modules/stock
 *
 * Drag-panes module
 *
 * (c) 2010-2026 Highsoft AS
 * Author: Kacper Madej
 *
 * A commercial license may be required depending on use.
 * See www.highcharts.com/license
 */function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(t._Highcharts):"function"==typeof define&&define.amd?define("highcharts/modules/drag-panes",["highcharts/highcharts"],function(t){return e(t)}):"object"==typeof exports?exports["highcharts/modules/drag-panes"]=e(t._Highcharts):t.Highcharts=e(t.Highcharts)}("u"<typeof window?this:window,function(t){return function(){"use strict";var e={944:function(e){e.exports=t}},r={};function n(t){var o=r[t];if(void 0!==o)return o.exports;var i=r[t]={exports:{}};return e[t](i,i.exports,n),i.exports}n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)};var o={};n.d(o,{default:function(){return M}});var i=n(944),s=n.n(i),a=function(t,e,r){if(r||2==arguments.length)for(var n,o=0,i=e.length;o<i;o++)!n&&o in e||(n||(n=Array.prototype.slice.call(e,0,o)),n[o]=e[o]);return t.concat(n||Array.prototype.slice.call(e))};function c(t,e,r,n){void 0===n&&(n={});var o="function"==typeof t&&t.prototype||t;Object.hasOwnProperty.call(o,"hcEvents")||(o.hcEvents={});var i=o.hcEvents;s().Point&&t instanceof s().Point&&t.series&&t.series.chart&&(t.series.chart.runTrackerClick=!0);var a=t.addEventListener;a&&a.call(t,e,r,!!s().supportsPassiveEvents&&{passive:void 0===n.passive?-1!==e.indexOf("touch"):n.passive,capture:!1}),i[e]||(i[e]=[]);var c={fn:r,order:"number"==typeof n.order?n.order:1/0};return i[e].push(c),i[e].sort(function(t,e){return t.order-e.order}),function(){!function(t,e,r){function n(e,r){var n=t.removeEventListener;n&&n.call(t,e,r,!1)}function o(r){var o,i;t.nodeName&&(e?(o={})[e]=!0:o=r,l(o,function(t,e){if(r[e])for(i=r[e].length;i--;)n(e,r[e][i].fn)}))}var i="function"==typeof t&&t.prototype||t;if(Object.hasOwnProperty.call(i,"hcEvents")){var s=i.hcEvents;if(e){var a=s[e]||[];r?(s[e]=a.filter(function(t){return r!==t.fn}),n(e,r)):(o(s),s[e]=[])}else o(s),delete i.hcEvents}}(t,e,r)}}function h(t,e,r){return t>e?t<r?t:r:e}function u(t){return p(t)&&"number"==typeof t.nodeType}function p(t,e){var r;return!!t&&"object"==typeof t&&(!e||"[object Array]"!==(r=Object.prototype.toString.call(t))&&"[object Array Iterator]"!==r)}function l(t,e,r){for(var n in t)Object.hasOwnProperty.call(t,n)&&e.call(r||t[n],t[n],n,t)}function f(t,e,r){return/%$/.test(t)?e*parseFloat(t)/100+(r||0):parseFloat(t)}function d(t,e,r){var n=t[e];t[e]=function(){var t=arguments,e=this;return r.apply(this,[function(){return n.apply(e,arguments.length?arguments:t)}].concat([].slice.call(arguments)))}}s().doc,s().win,Array.prototype.find;var v=function(){function t(t){this.init(t)}return t.prototype.init=function(t,e){this.axis=t,this.options=t.options.resize||{},this.render(),e||this.addMouseEvents()},t.prototype.render=function(){var t=this.axis,e=t.chart,r=this.options,n=r.x||0,o=r.y,i=h(t.top+t.height+o,e.plotTop,e.plotTop+e.plotHeight),s={};e.styledMode||(s={cursor:r.cursor,stroke:r.lineColor,"stroke-width":r.lineWidth,dashstyle:r.lineDashStyle}),this.lastPos=i-o,this.controlLine||(this.controlLine=e.renderer.path().addClass("highcharts-axis-resizer")),this.controlLine.add(t.axisGroup);var a=e.styledMode?this.controlLine.strokeWidth():r.lineWidth;s.d=e.renderer.crispLine([["M",t.left+n,i],["L",t.left+t.width+n,i]],a),this.controlLine.attr(s)},t.prototype.addMouseEvents=function(){var t,e,r,n=this,o=n.controlLine.element,i=n.axis.chart.container,s=[];n.mouseMoveHandler=t=function(t){return n.onMouseMove(t)},n.mouseUpHandler=e=function(t){return n.onMouseUp(t)},n.mouseDownHandler=r=function(){return n.onMouseDown()},s.push(c(i,"mousemove",t),c(i.ownerDocument,"mouseup",e),c(o,"mousedown",r),c(i,"touchmove",t),c(i.ownerDocument,"touchend",e),c(o,"touchstart",r)),n.eventsToUnbind=s},t.prototype.onMouseMove=function(t){if(!t.touches||0!==t.touches[0].pageX){var e=this.axis.chart.pointer;this.grabbed&&e&&(this.hasDragged=!0,this.updateAxes(e.normalize(t).chartY-(this.options.y||0)))}},t.prototype.onMouseUp=function(t){var e=this.axis.chart.pointer;this.hasDragged&&e&&this.updateAxes(e.normalize(t).chartY-(this.options.y||0)),this.grabbed=this.hasDragged=this.axis.chart.activeResizer=void 0},t.prototype.onMouseDown=function(){var t;null==(t=this.axis.chart.pointer)||t.reset(!1,0),this.grabbed=this.axis.chart.activeResizer=!0},t.prototype.updateAxes=function(t){var e=this.axis.chart,r=this.options.controlledAxis,n=0===r.next.length?[e.yAxis.indexOf(this.axis)+1]:r.next,o=[this.axis].concat(r.prev),i=[],s=e.plotTop,a=e.plotHeight,c=s+a,u=function(t){return 100*t/a+"%"},p=function(t,e,r){return Math.round(h(t,e,r))};t=h(t,s,c);var l=!1,d=t-this.lastPos;if(!(d*d<1)){for(var v=!0,y=0,g=[o,n];y<g.length;y++)for(var x=g[y],m=0;m<x.length;m++){var b=x[m],w="number"==typeof b&&!isNaN(b)&&b<1/0&&b>-1/0?e.yAxis[b]:v?b:e.get(b),z=w&&w.options,M={},A=void 0,j=void 0;if(!z||z.isInternal){v=!1;continue}j=w.top;var L=Math.round(f(z.minLength||NaN,a)),O=Math.round(f(z.maxLength||NaN,a));if(v||x!==n)(A=p(t-j,L,O))===O&&(l=!0),t=j+A,i.push({axis:w,options:{height:u(A)}});else{if(d=t-this.lastPos,A=p(w.len-d,L,O),(j=w.top+d)+A>c){var P=c-A-j;t+=P,j+=P}j<s&&(j=s)+A>c&&(A=a),A===L&&(l=!0),i.push({axis:w,options:{top:u(j-s),height:u(A)}})}v=!1,M.height=A}if(!l){for(var E=0;E<i.length;E++){var D=i[E];D.axis.update(D.options,!1)}e.redraw(!1)}}},t.prototype.destroy=function(){var t=this.axis;delete t.resizer,this.eventsToUnbind&&this.eventsToUnbind.forEach(function(t){return t()}),this.controlLine.destroy();for(var e=0,r=Object.keys(this);e<r.length;e++)this[r[e]]=null},t}(),y={minLength:"10%",maxLength:"100%",resize:{controlledAxis:{next:[],prev:[]},enabled:!1,cursor:"ns-resize",lineColor:"#cccccc",lineDashStyle:"Solid",lineWidth:4,x:0,y:0}},g=s().defaultOptions;function x(){var t=this.resizer,e=this.options.resize;if(e){var r=!1!==e.enabled;t?r?t.init(this,!0):t.destroy():r&&(this.resizer=new v(this))}}function m(t){!t.keepEvents&&this.resizer&&this.resizer.destroy()}function b(t){this.chart.activeResizer||t.apply(this,[].slice.call(arguments,1))}function w(t){this.chart.activeResizer||t.apply(this,[].slice.call(arguments,1))}var z=s();({compose:function(t,e){t.keepProps.includes("resizer")||(!function(t){for(var e=[],r=1;r<arguments.length;r++)e[r-1]=arguments[r];var n,o=a([t],e,!0),i={},s=function(t,e){return"object"!=typeof t&&(t={}),l(e,function(r,n){if("__proto__"!==n&&"constructor"!==n){var o;!p(r,!0)||(o=null==r?void 0:r.constructor,p(r,!0)&&!u(r)&&(null==o?void 0:o.name)&&"Object"!==o.name)||u(r)?t[n]=e[n]:t[n]=s(t[n]||{},r)}}),t};!0===t&&(i=o[1],o=Array.prototype.slice.call(o,2));var c=o.length;for(n=0;n<c;n++)i=s(i,o[n])}(!0,g.yAxis,y),t.keepProps.push("resizer"),c(t,"afterRender",x),c(t,"destroy",m),d(e.prototype,"runPointActions",w),d(e.prototype,"drag",b))}}).compose(z.Axis,z.Pointer);var M=s();return o.default}()});