(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7211],{80594:function(e,t,n){var r=0/0,i=/^\s+|\s+$/g,o=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,c=/^0o[0-7]+$/i,u=parseInt,l="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,f="object"==typeof self&&self&&self.Object===Object&&self,s=l||f||Function("return this")(),d=Object.prototype.toString,p=Math.max,h=Math.min,g=function(){return s.Date.now()};function v(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function b(e){if("number"==typeof e)return e;if("symbol"==typeof(t=e)||t&&"object"==typeof t&&"[object Symbol]"==d.call(t))return r;if(v(e)){var t,n="function"==typeof e.valueOf?e.valueOf():e;e=v(n)?n+"":n}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(i,"");var l=a.test(e);return l||c.test(e)?u(e.slice(2),l?2:8):o.test(e)?r:+e}e.exports=function(e,t,n){var r,i,o,a,c,u,l=0,f=!1,s=!1,d=!0;if("function"!=typeof e)throw TypeError("Expected a function");function m(t){var n=r,o=i;return r=i=void 0,l=t,a=e.apply(o,n)}function y(e){var n=e-u,r=e-l;return void 0===u||n>=t||n<0||s&&r>=o}function O(){var e,n,r,i=g();if(y(i))return x(i);c=setTimeout(O,(e=i-u,n=i-l,r=t-e,s?h(r,o-n):r))}function x(e){return(c=void 0,d&&r)?m(e):(r=i=void 0,a)}function w(){var e,n=g(),o=y(n);if(r=arguments,i=this,u=n,o){if(void 0===c)return l=e=u,c=setTimeout(O,t),f?m(e):a;if(s)return c=setTimeout(O,t),m(u)}return void 0===c&&(c=setTimeout(O,t)),a}return t=b(t)||0,v(n)&&(f=!!n.leading,o=(s="maxWait"in n)?p(b(n.maxWait)||0,t):o,d="trailing"in n?!!n.trailing:d),w.cancel=function(){void 0!==c&&clearTimeout(c),l=0,r=u=i=c=void 0},w.flush=function(){return void 0===c?a:x(g())},w}},98357:function(e,t,n){var r="Expected a function",i=0/0,o=/^\s+|\s+$/g,a=/^[-+]0x[0-9a-f]+$/i,c=/^0b[01]+$/i,u=/^0o[0-7]+$/i,l=parseInt,f="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,s="object"==typeof self&&self&&self.Object===Object&&self,d=f||s||Function("return this")(),p=Object.prototype.toString,h=Math.max,g=Math.min,v=function(){return d.Date.now()};function b(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function m(e){if("number"==typeof e)return e;if("symbol"==typeof(t=e)||t&&"object"==typeof t&&"[object Symbol]"==p.call(t))return i;if(b(e)){var t,n="function"==typeof e.valueOf?e.valueOf():e;e=b(n)?n+"":n}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var r=c.test(e);return r||u.test(e)?l(e.slice(2),r?2:8):a.test(e)?i:+e}e.exports=function(e,t,n){var i=!0,o=!0;if("function"!=typeof e)throw TypeError(r);return b(n)&&(i="leading"in n?!!n.leading:i,o="trailing"in n?!!n.trailing:o),function(e,t,n){var i,o,a,c,u,l,f=0,s=!1,d=!1,p=!0;if("function"!=typeof e)throw TypeError(r);function y(t){var n=i,r=o;return i=o=void 0,f=t,c=e.apply(r,n)}function O(e){var n=e-l,r=e-f;return void 0===l||n>=t||n<0||d&&r>=a}function x(){var e,n,r,i=v();if(O(i))return w(i);u=setTimeout(x,(e=i-l,n=i-f,r=t-e,d?g(r,a-n):r))}function w(e){return(u=void 0,p&&i)?y(e):(i=o=void 0,c)}function j(){var e,n=v(),r=O(n);if(i=arguments,o=this,l=n,r){if(void 0===u)return f=e=l,u=setTimeout(x,t),s?y(e):c;if(d)return u=setTimeout(x,t),y(l)}return void 0===u&&(u=setTimeout(x,t)),c}return t=m(t)||0,b(n)&&(s=!!n.leading,a=(d="maxWait"in n)?h(m(n.maxWait)||0,t):a,p="trailing"in n?!!n.trailing:p),j.cancel=function(){void 0!==u&&clearTimeout(u),f=0,i=l=o=u=void 0},j.flush=function(){return void 0===u?c:w(v())},j}(e,t,{leading:i,maxWait:t,trailing:o})}},17211:function(e,t,n){"use strict";n.r(t),n.d(t,{SliderInput:function(){return C}});var r,i,o,a,c=n(95235),u=n(8529),l=n(2784),f=n(28316),s=n(26947),d=n(80594),p=n.n(d),h=n(98357),g=n.n(h),v=function(e,t){return(v=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},b=function(){return(b=Object.assign||function(e){for(var t,n=1,r=arguments.length;nt.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,r=Object.getOwnPropertySymbols(e);it.indexOf(r[i])&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}(a,["targetRef"]);return(0,l.cloneElement)(e,c)}return(0,l.cloneElement)(e,a);case"childArray":return(e=r).map(function(e){return!!e&&(0,l.cloneElement)(e,a)});default:return l.createElement(void 0===i?"div":i,null)}}}(l.PureComponent);var w=n(40226),j=n(60976),E=n(3105);function R(e){let t=(0,E.h)(()=>(0,w.BX)(e)),{isStatic:n}=(0,l.useContext)(j._);if(n){let[,n]=(0,l.useState)(e);(0,l.useEffect)(()=>t.on("change",n),[])}return t}var P=n(7328),M=n(95793),k=n(48840),S=(0,k.zo)(M.yK)(r||(r=(0,P.Z)(["\n width: ",";\n height: ",";\n border-radius: 50%;\n background-color: ",";\n top: -",";\n position: absolute;\n left: -",";\n\n &:hover {\n outline: "," solid\n ",";\n }\n\n &:active {\n background-color: ",";\n box-shadow: 0 0 0 ","\n ",";\n outline-offset: ",";\n outline: "," solid\n ",";\n }\n"])),(0,k.W0)(2.5),(0,k.W0)(2.5),function(e){return e.theme.colors.palette.brand.base},(0,k.W0)(.75),(0,k.W0)(1),(0,k.W0)(.875),function(e){return e.theme.colors.palette.brand.lighter},function(e){return e.theme.colors.palette.brand.darker},(0,k.W0)(.5),function(e){return e.theme.colors.palette.brand.lighter},(0,k.W0)(.5),(0,k.W0)(.25),function(e){return e.theme.colors.palette.brand.base}),z=(0,k.zo)(M.yK)(i||(i=(0,P.Z)(["\n width: 100%;\n height: 8px;\n background-color: ",";\n border-radius: 4px;\n position: relative;\n ","\n"])),function(e){return e.theme.colors.palette.brand.base},function(e){var t=e.minPercentage,n=e.maxPercentage,r=e.theme;return(0,k.iv)(o||(o=(0,P.Z)(["\n background: linear-gradient(\n to right,\n "," 0%,\n "," ","%,\n "," ","%,\n "," ","%,\n "," ","%\n );\n "])),r.colors.palette.greys.light,r.colors.palette.greys.light,t.toFixed(2),r.colors.palette.brand.base,t.toFixed(2),r.colors.palette.brand.base,n.toFixed(2),r.colors.palette.greys.light,n.toFixed(2))}),W=k.zo.div(a||(a=(0,P.Z)(["\n display: flex;\n flex-flow: column wrap;\n justify-content: center;\n align-items: center;\n margin: "," 0 ",";\n"])),(0,k.W0)(2),(0,k.W0)(3)),T=n(52322);function H(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function D(e){for(var t=1;te.maxValue&&(n=e.maxValue),e.setSliderMax(n)});return function(){t(),n()}});var K=(r=void 0!==(n=(t={onResize:l.useCallback(function(e){V(e)},[]),handleWidth:!0,refreshMode:"debounce",refreshRate:100}).skipOnMount)&&n,i=t.refreshMode,a=void 0===(o=t.refreshRate)?1e3:o,c=t.refreshOptions,d=void 0===(f=t.handleWidth)||f,h=void 0===(p=t.handleHeight)||p,g=t.onResize,v=(0,l.useRef)(null),x=(0,l.useRef)(null),w=(0,l.useRef)(null),j=(0,l.useRef)(g),(0,l.useEffect)(function(){null===v.current&&(v.current=r)},[r]),P=(E=(0,l.useState)({width:void 0,height:void 0}))[0],M=E[1],(0,l.useEffect)(function(){if(!O()){var e,t=(e=j.current,(0,s.Z)(function(t){var n=t.width,r=t.height;e&&y(e)&&e(n,r),M(function(e){return e.width===n&&e.height===r?e:{width:n,height:r}})}));w.current=m(function(e){(d||h)&&e.forEach(function(e){var n=e&&e.contentRect||{},r=n.width,i=n.height;v.current||O()||t({width:r,height:i}),v.current=!1})},i,a,c);var n=new window.ResizeObserver(w.current);return x.current&&n.observe(x.current),function(){n.disconnect(),t.cancel();var e=w.current;e&&e.cancel&&e.cancel()}}},[i,a,c,d,h,j]),b({ref:x},P)).ref;return(0,T.jsx)(W,{"data-testid":"slider-container",ref:K,children:(0,T.jsxs)(z,D(D({},Z()),{},{children:[!e.isSingleHandle&&(0,T.jsx)(S,{"data-testid":"slider-input-min-knob",drag:"x",initial:{x:_.get()},onDragEnd:function(){var t;null===(t=e.onDragEndCallback)||void 0===t||t.call(e)},dragMomentum:!1,dragElastic:!1,style:{x:_},dragConstraints:{left:0,right:Number(e.selectedMaxValue/(e.maxValue/C))-16}}),(0,T.jsx)(S,{"data-testid":"slider-input-max-knob",drag:"x",initial:{x:F.get()},onDragEnd:function(){var t;return null===(t=e.onDragEndCallback)||void 0===t?void 0:t.call(e)},dragMomentum:!1,dragElastic:!1,style:{x:F},dragConstraints:{top:0,bottom:0,left:e.isSingleHandle?0:_.get()+16,right:C}})]}))})}}}]); //# sourceMappingURL=7211.345213a93b75ae70.js.map