"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../utils/mix/number.mjs.js"),i=require("../../value/types/numbers/units.mjs.js"),t=require("./delta-apply.mjs.js");function o(e,i,o,r,n){return e-=i,e=t.scalePoint(e,1/o,r),void 0!==n&&(e=t.scalePoint(e,1/n,r)),e}function r(t){let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:.5,m=arguments.length>4?arguments[4]:void 0,l=arguments.length>5&&void 0!==arguments[5]?arguments[5]:t,a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:t;if(i.percent.test(r)){r=parseFloat(r);r=e.mixNumber(a.min,a.max,r/100)-a.min}if("number"!=typeof r)return;let u=e.mixNumber(l.min,l.max,s);t===l&&(u-=r),t.min=o(t.min,r,n,u,m),t.max=o(t.max,r,n,u,m)}function n(e,i,t,o,n){let[s,m,l]=t;r(e,i[s],i[m],i[l],i.scale,o,n)}const s=["x","scaleX","originX"],m=["y","scaleY","originY"];exports.removeAxisDelta=r,exports.removeAxisTransforms=n,exports.removeBoxTransforms=function(e,i,t,o){n(e.x,i,s,t?t.x:void 0,o?o.x:void 0),n(e.y,i,m,t?t.y:void 0,o?o.y:void 0)},exports.removePointDelta=o;
//# sourceMappingURL=delta-remove.mjs.js.map
