You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
NewEduCoderBuild/10311.40a632d7.async.js

1 line
22 KiB

"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[10311],{10311:function(e,t,n){n.d(t,{Z:function(){return J}});var r=n(92310),o=n.n(r),a=n(80962),i=n(26390),l=n(29043),u=n(80665),c=n(59301),s=n(51346),d=n(35788),f=n(5891),v=n(19149),h=n(57259),m=n(85108),g=c.createContext({min:0,max:0,direction:"ltr",step:1,includedStart:0,includedEnd:0,tabIndex:0,keyboard:!0});function b(e,t,n){return(e-t)/(n-t)}function p(e,t,n,r){var o=b(t,n,r),a={};switch(e){case"rtl":a.right="".concat(100*o,"%"),a.transform="translateX(50%)";break;case"btt":a.bottom="".concat(100*o,"%"),a.transform="translateY(50%)";break;case"ttb":a.top="".concat(100*o,"%"),a.transform="translateY(-50%)";break;default:a.left="".concat(100*o,"%"),a.transform="translateX(-50%)"}return a}function x(e,t){return Array.isArray(e)?e[t]:e}var S=["prefixCls","value","valueIndex","onStartMove","style","render","dragging","onOffsetChange"],k=c.forwardRef((function(e,t){var n,r,i=e.prefixCls,l=e.value,u=e.valueIndex,s=e.onStartMove,d=e.style,b=e.render,k=e.dragging,C=e.onOffsetChange,y=(0,v.Z)(e,S),E=c.useContext(g),$=E.min,Z=E.max,M=E.direction,w=E.disabled,B=E.keyboard,z=E.range,H=E.tabIndex,O=E.ariaLabelForHandle,L=E.ariaLabelledByForHandle,P=E.ariaValueTextFormatterForHandle,F="".concat(i,"-handle"),R=function(e){w||s(e,u)},D=p(M,l,$,Z),I=c.createElement("div",(0,f.Z)({ref:t,className:o()(F,(n={},(0,a.Z)(n,"".concat(F,"-").concat(u+1),z),(0,a.Z)(n,"".concat(F,"-dragging"),k),n)),style:(0,h.Z)((0,h.Z)({},D),d),onMouseDown:R,onTouchStart:R,onKeyDown:function(e){if(!w&&B){var t=null;switch(e.which||e.keyCode){case m.Z.LEFT:t="ltr"===M||"btt"===M?-1:1;break;case m.Z.RIGHT:t="ltr"===M||"btt"===M?1:-1;break;case m.Z.UP:t="ttb"!==M?1:-1;break;case m.Z.DOWN:t="ttb"!==M?-1:1;break;case m.Z.HOME:t="min";break;case m.Z.END:t="max";break;case m.Z.PAGE_UP:t=2;break;case m.Z.PAGE_DOWN:t=-2}null!==t&&(e.preventDefault(),C(t,u))}},tabIndex:w?null:x(H,u),role:"slider","aria-valuemin":$,"aria-valuemax":Z,"aria-valuenow":l,"aria-disabled":w,"aria-label":x(O,u),"aria-labelledby":x(L,u),"aria-valuetext":null===(r=x(P,u))||void 0===r?void 0:r(l),"aria-orientation":"ltr"===M||"rtl"===M?"horizontal":"vertical"},y));return b&&(I=b(I,{index:u,prefixCls:i,value:l,dragging:k})),I}));var C=k,y=["prefixCls","style","onStartMove","onOffsetChange","values","handleRender","draggingIndex"],E=c.forwardRef((function(e,t){var n=e.prefixCls,r=e.style,o=e.onStartMove,a=e.onOffsetChange,i=e.values,l=e.handleRender,u=e.draggingIndex,s=(0,v.Z)(e,y),d=c.useRef({});return c.useImperativeHandle(t,(function(){return{focus:function(e){var t;null===(t=d.current[e])||void 0===t||t.focus()}}})),c.createElement(c.Fragment,null,i.map((function(e,t){return c.createElement(C,(0,f.Z)({ref:function(e){e?d.current[t]=e:delete d.current[t]},dragging:u===t,prefixCls:n,style:x(r,t),key:t,value:e,valueIndex:t,onStartMove:o,onOffsetChange:a,render:l},s))})))}));var $=E;function Z(e){var t="touches"in e?e.touches[0]:e;return{pageX:t.pageX,pageY:t.pageY}}function M(e){var t,n=e.prefixCls,r=e.style,i=e.start,l=e.end,u=e.index,s=e.onStartMove,d=c.useContext(g),f=d.direction,v=d.min,m=d.max,p=d.disabled,x=d.range,S="".concat(n,"-track"),k=b(i,v,m),C=b(l,v,m),y=function(e){!p&&s&&s(e,-1)},E={};switch(f){case"rtl":E.right="".concat(100*k,"%"),E.width="".concat(100*C-100*k,"%");break;case"btt":E.bottom="".concat(100*k,"%"),E.height="".concat(100*C-100*k,"%");break;case"ttb":E.top="".concat(100*k,"%"),E.height="".concat(100*C-100*k,"%");break;default:E.left="".concat(100*k,"%"),E.width="".concat(100*C-100*k,"%")}return c.createElement("div",{className:o()(S,(t={},(0,a.Z)(t,"".concat(S,"-").concat(u+1),x),(0,a.Z)(t,"".concat(n,"-track-draggable"),s),t)),style:(0,h.Z)((0,h.Z)({},E),r),onMouseDown:y,onTouchStart:y})}function w(e){var t=e.prefixCls,n=e.style,r=e.values,o=e.startPoint,a=e.onStartMove,i=c.useContext(g),l=i.included,u=i.range,s=i.min,d=c.useMemo((function(){if(!u){if(0===r.length)return[];var e=null!=o?o:s,t=r[0];return[{start:Math.min(e,t),end:Math.max(e,t)}]}for(var n=[],a=0;a<r.length-1;a+=1)n.push({start:r[a],end:r[a+1]});return n}),[r,u,o,s]);return l?d.map((function(e,r){var o=e.start,i=e.end;return c.createElement(M,{index:r,prefixCls:t,style:x(n,r),start:o,end:i,key:r,onStartMove:a})})):null}function B(e){var t=e.prefixCls,n=e.style,r=e.children,i=e.value,l=e.onClick,u=c.useContext(g),s=u.min,d=u.max,f=u.direction,v=u.includedStart,m=u.includedEnd,b=u.included,x="".concat(t,"-text"),S=p(f,i,s,d);return c.createElement("span",{className:o()(x,(0,a.Z)({},"".concat(x,"-active"),b&&v<=i&&i<=m)),style:(0,h.Z)((0,h.Z)({},S),n),onMouseDown:function(e){e.stopPropagation()},onClick:function(){l(i)}},r)}function z(e){var t=e.prefixCls,n=e.marks,r=e.onClick,o="".concat(t,"-mark");return n.length?c.createElement("div",{className:o},n.map((function(e){var t=e.value,n=e.style,a=e.label;return c.createElement(B,{key:t,prefixCls:o,style:n,value:t,onClick:r},a)}))):null}function H(e){var t=e.prefixCls,n=e.value,r=e.style,i=e.activeStyle,l=c.useContext(g),u=l.min,s=l.max,d=l.direction,f=l.included,v=l.includedStart,m=l.includedEnd,b="".concat(t,"-dot"),x=f&&v<=n&&n<=m,S=(0,h.Z)((0,h.Z)({},p(d,n,u,s)),"function"==typeof r?r(n):r);return x&&(S=(0,h.Z)((0,h.Z)({},S),"function"==typeof i?i(n):i)),c.createElement("span",{className:o()(b,(0,a.Z)({},"".concat(b,"-active"),x)),style:S})}function O(e){var t=e.prefixCls,n=e.marks,r=e.dots,o=e.style,a=e.activeStyle,i=c.useContext(g),l=i.min,u=i.max,s=i.step,d=c.useMemo((function(){var e=new Set;if(n.forEach((function(t){e.add(t.value)})),r&&null!==s)for(var t=l;t<=u;)e.add(t),t+=s;return Array.from(e)}),[l,u,s,r,n]);return c.createElement("div",{className:"".concat(t,"-step")},d.map((function(e){return c.createElement(H,{prefixCls:t,key:e,value:e,style:o,activeStyle:a})})))}n(51395);var L=c.forwardRef((function(e,t){var n,r=e.prefixCls,f=void 0===r?"rc-slider":r,v=e.className,h=e.style,m=e.disabled,b=void 0!==m&&m,p=e.keyboard,x=void 0===p||p,S=e.autoFocus,k=e.onFocus,C=e.onBlur,y=e.min,E=void 0===y?0:y,M=e.max,B=void 0===M?100:M,H=e.step,L=void 0===H?1:H,P=e.value,F=e.defaultValue,R=e.range,D=e.count,I=e.onChange,W=e.onBeforeChange,j=e.onAfterChange,N=e.allowCross,T=void 0===N||N,A=e.pushable,X=void 0!==A&&A,Y=e.draggableTrack,V=e.reverse,G=e.vertical,_=e.included,U=void 0===_||_,K=e.startPoint,Q=e.trackStyle,q=e.handleStyle,J=e.railStyle,ee=e.dotStyle,te=e.activeDotStyle,ne=e.marks,re=e.dots,oe=e.handleRender,ae=e.tabIndex,ie=void 0===ae?0:ae,le=e.ariaLabelForHandle,ue=e.ariaLabelledByForHandle,ce=e.ariaValueTextFormatterForHandle,se=c.useRef(),de=c.useRef(),fe=c.useMemo((function(){return G?V?"ttb":"btt":V?"rtl":"ltr"}),[V,G]),ve=c.useMemo((function(){return isFinite(E)?E:0}),[E]),he=c.useMemo((function(){return isFinite(B)?B:100}),[B]),me=c.useMemo((function(){return null!==L&&L<=0?1:L}),[L]),ge=c.useMemo((function(){return"boolean"==typeof X?!!X&&me:X>=0&&X}),[X,me]),be=c.useMemo((function(){return Object.keys(ne||{}).map((function(e){var t=ne[e],n={value:Number(e)};return t&&"object"===(0,u.Z)(t)&&!c.isValidElement(t)&&("label"in t||"style"in t)?(n.style=t.style,n.label=t.label):n.label=t,n})).filter((function(e){var t=e.label;return t||"number"==typeof t})).sort((function(e,t){return e.value-t.value}))}),[ne]),pe=function(e,t,n,r,o,a){var l=c.useCallback((function(n){var r=isFinite(n)?n:e;return r=Math.min(t,n),Math.max(e,r)}),[e,t]),u=c.useCallback((function(r){if(null!==n){var o=e+Math.round((l(r)-e)/n)*n,a=function(e){return(String(e).split(".")[1]||"").length},i=Math.max(a(n),a(t),a(e)),u=Number(o.toFixed(i));return e<=u&&u<=t?u:null}return null}),[n,e,t,l]),s=c.useCallback((function(o){var a=l(o),i=r.map((function(e){return e.value}));null!==n&&i.push(u(o)),i.push(e,t);var c=i[0],s=t-e;return i.forEach((function(e){var t=Math.abs(a-e);t<=s&&(c=e,s=t)})),c}),[e,t,r,n,l,u]),d=function o(a,l,c){var s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"unit";if("number"==typeof l){var d,f=a[c],v=f+l,h=[];r.forEach((function(e){h.push(e.value)})),h.push(e,t),h.push(u(f));var m=l>0?1:-1;"unit"===s?h.push(u(f+m*n)):h.push(u(v)),h=h.filter((function(e){return null!==e})).filter((function(e){return l<0?e<=f:e>=f})),"unit"===s&&(h=h.filter((function(e){return e!==f})));var g="unit"===s?f:v;d=h[0];var b=Math.abs(d-g);if(h.forEach((function(e){var t=Math.abs(e-g);t<b&&(d=e,b=t)})),void 0===d)return l<0?e:t;if("dist"===s)return d;if(Math.abs(l)>1){var p=(0,i.Z)(a);return p[c]=d,o(p,l-m,c,s)}return d}return"min"===l?e:"max"===l?t:void 0},f=function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"unit",o=e[n],a=d(e,t,n,r);return{value:a,changed:a!==o}},v=function(e){return null===a&&0===e||"number"==typeof a&&e<a};return[s,function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"unit",i=e.map(s),l=i[n],u=d(i,t,n,r);if(i[n]=u,!1===o){var c=a||0;n>0&&i[n-1]!==l&&(i[n]=Math.max(i[n],i[n-1]+c)),n<i.length-1&&i[n+1]!==l&&(i[n]=Math.min(i[n],i[n+1]-c))}else if("number"==typeof a||null===a){for(var h=n+1;h<i.length;h+=1)for(var m=!0;v(i[h]-i[h-1])&&m;){var g=f(i,1,h);i[h]=g.value,m=g.changed}for(var b=n;b>0;b-=1)for(var p=!0;v(i[b]-i[b-1])&&p;){var x=f(i,-1,b-1);i[b-1]=x.value,p=x.changed}for(var S=i.length-1;S>0;S-=1)for(var k=!0;v(i[S]-i[S-1])&&k;){var C=f(i,-1,S-1);i[S-1]=C.value,k=C.changed}for(var y=0;y<i.length-1;y+=1)for(var E=!0;v(i[y+1]-i[y])&&E;){var $=f(i,1,y+1);i[y+1]=$.value,E=$.changed}}return{value:i[n],values:i}}]}(ve,he,me,be,T,ge),xe=(0,l.Z)(pe,2),Se=xe[0],ke=xe[1],Ce=(0,d.Z)(F,{value:P}),ye=(0,l.Z)(Ce,2),Ee=ye[0],$e=ye[1],Ze=c.useMemo((function(){var e=null==Ee?[]:Array.isArray(Ee)?Ee:[Ee],t=(0,l.Z)(e,1)[0],n=null===Ee?[]:[void 0===t?ve:t];if(R){if(n=(0,i.Z)(e),D||void 0===Ee){var r=D>=0?D+1:2;for(n=n.slice(0,r);n.length<r;){var o;n.push(null!==(o=n[n.length-1])&&void 0!==o?o:ve)}}n.sort((function(e,t){return e-t}))}return n.forEach((function(e,t){n[t]=Se(e)})),n}),[Ee,R,ve,D,Se]),Me=c.useRef(Ze);Me.current=Ze;var we=function(e){return R?e:e[0]},Be=function(e){var t=(0,i.Z)(e).sort((function(e,t){return e-t}));I&&!(0,s.Z)(t,Me.current,!0)&&I(we(t)),$e(t)},ze=function(e){if(!b){var t=0,n=he-ve;Ze.forEach((function(r,o){var a=Math.abs(e-r);a<=n&&(n=a,t=o)}));var r=(0,i.Z)(Ze);r[t]=e,R&&!Ze.length&&void 0===D&&r.push(e),null==W||W(we(r)),Be(r),null==j||j(we(r))}},He=c.useState(null),Oe=(0,l.Z)(He,2),Le=Oe[0],Pe=Oe[1];c.useEffect((function(){if(null!==Le){var e=Ze.indexOf(Le);e>=0&&se.current.focus(e)}Pe(null)}),[Le]);var Fe=c.useMemo((function(){return(!Y||null!==me)&&Y}),[Y,me]),Re=function(e,t,n,r,o,a,u,s,d){var f=c.useState(null),v=(0,l.Z)(f,2),h=v[0],m=v[1],g=c.useState(-1),b=(0,l.Z)(g,2),p=b[0],x=b[1],S=c.useState(n),k=(0,l.Z)(S,2),C=k[0],y=k[1],E=c.useState(n),$=(0,l.Z)(E,2),M=$[0],w=$[1],B=c.useRef(null),z=c.useRef(null);c.useEffect((function(){-1===p&&y(n)}),[n,p]),c.useEffect((function(){return function(){document.removeEventListener("mousemove",B.current),document.removeEventListener("mouseup",z.current),document.removeEventListener("touchmove",B.current),document.removeEventListener("touchend",z.current)}}),[]);var H=function(e,t){C.some((function(t,n){return t!==e[n]}))&&(void 0!==t&&m(t),y(e),u(e))},O=function(e,t){if(-1===e){var n=M[0],l=M[M.length-1],u=r-n,c=o-l,s=t*(o-r);s=Math.max(s,u),s=Math.min(s,c);var f=a(n+s);s=f-n;var v=M.map((function(e){return e+s}));H(v)}else{var h=(o-r)*t,m=(0,i.Z)(C);m[e]=M[e];var g=d(m,h,e,"dist");H(g.values,g.value)}},L=c.useRef(O);L.current=O;var P=c.useMemo((function(){var e=(0,i.Z)(n).sort((function(e,t){return e-t})),t=(0,i.Z)(C).sort((function(e,t){return e-t}));return e.every((function(e,n){return e===t[n]}))?C:n}),[n,C]);return[p,h,P,function(r,o){r.stopPropagation();var a=n[o];x(o),m(a),w(n);var i=Z(r),l=i.pageX,u=i.pageY,c=function(n){n.preventDefault();var r,a=Z(n),i=a.pageX,c=a.pageY,s=i-l,d=c-u,f=e.current.getBoundingClientRect(),v=f.width,h=f.height;switch(t){case"btt":r=-d/h;break;case"ttb":r=d/h;break;case"rtl":r=-s/v;break;default:r=s/v}L.current(o,r)},d=function e(t){t.preventDefault(),document.removeEventListener("mouseup",e),document.removeEventListener("mousemove",c),document.removeEventListener("touchend",e),document.removeEventListener("touchmove",c),B.current=null,z.current=null,x(-1),s()};document.addEventListener("mouseup",d),document.addEventListener("mousemove",c),document.addEventListener("touchend",d),document.addEventListener("touchmove",c),B.current=c,z.current=d}]}(de,fe,Ze,ve,he,Se,Be,(function(){null==j||j(we(Me.current))}),ke),De=(0,l.Z)(Re,4),Ie=De[0],We=De[1],je=De[2],Ne=De[3],Te=function(e,t){Ne(e,t),null==W||W(we(Me.current))},Ae=-1!==Ie;c.useEffect((function(){if(!Ae){var e=Ze.lastIndexOf(We);se.current.focus(e)}}),[Ae]);var Xe=c.useMemo((function(){return(0,i.Z)(je).sort((function(e,t){return e-t}))}),[je]),Ye=c.useMemo((function(){return R?[Xe[0],Xe[Xe.length-1]]:[ve,Xe[0]]}),[Xe,R,ve]),Ve=(0,l.Z)(Ye,2),Ge=Ve[0],_e=Ve[1];c.useImperativeHandle(t,(function(){return{focus:function(){se.current.focus(0)},blur:function(){var e=document.activeElement;de.current.contains(e)&&(null==e||e.blur())}}})),c.useEffect((function(){S&&se.current.focus(0)}),[]);var Ue=c.useMemo((function(){return{min:ve,max:he,direction:fe,disabled:b,keyboard:x,step:me,included:U,includedStart:Ge,includedEnd:_e,range:R,tabIndex:ie,ariaLabelForHandle:le,ariaLabelledByForHandle:ue,ariaValueTextFormatterForHandle:ce}}),[ve,he,fe,b,x,me,U,Ge,_e,R,ie,le,ue,ce]);return c.createElement(g.Provider,{value:Ue},c.createElement("div",{ref:de,className:o()(f,v,(n={},(0,a.Z)(n,"".concat(f,"-disabled"),b),(0,a.Z)(n,"".concat(f,"-vertical"),G),(0,a.Z)(n,"".concat(f,"-horizontal"),!G),(0,a.Z)(n,"".concat(f,"-with-marks"),be.length),n)),style:h,onMouseDown:function(e){e.preventDefault();var t,n=de.current.getBoundingClientRect(),r=n.width,o=n.height,a=n.left,i=n.top,l=n.bottom,u=n.right,c=e.clientX,s=e.clientY;switch(fe){case"btt":t=(l-s)/o;break;case"ttb":t=(s-i)/o;break;case"rtl":t=(u-c)/r;break;default:t=(c-a)/r}ze(Se(ve+t*(he-ve)))}},c.createElement("div",{className:"".concat(f,"-rail"),style:J}),c.createElement(w,{prefixCls:f,style:Q,values:Xe,startPoint:K,onStartMove:Fe?Te:null}),c.createElement(O,{prefixCls:f,marks:be,dots:re,style:ee,activeStyle:te}),c.createElement($,{ref:se,prefixCls:f,style:q,values:je,draggingIndex:Ie,onStartMove:Te,onOffsetChange:function(e,t){if(!b){var n=ke(Ze,e,t);null==W||W(we(Ze)),Be(n.values),null==j||j(we(n.values)),Pe(n.value)}},onFocus:k,onBlur:C,handleRender:oe}),c.createElement(z,{prefixCls:f,marks:be,onClick:ze})))}));var P=L,F=n(36355),R=n(1684),D=n(23073),I=n(20475),W=n(6848);var j=c.forwardRef(((e,t)=>{const{open:n}=e,r=(0,c.useRef)(null),o=(0,c.useRef)(null);function a(){D.Z.cancel(o.current),o.current=null}return c.useEffect((()=>(n?o.current=(0,D.Z)((()=>{var e;null===(e=r.current)||void 0===e||e.forceAlign(),o.current=null})):a(),a)),[n,e.title]),c.createElement(W.Z,Object.assign({ref:(0,I.sQ)(r,t)},e))})),N=n(64993),T=n(17313),A=n(83116),X=n(37613);const Y=e=>{const{componentCls:t,antCls:n,controlSize:r,dotSize:o,marginFull:a,marginPart:i,colorFillContentHover:l}=e;return{[t]:Object.assign(Object.assign({},(0,T.Wf)(e)),{position:"relative",height:r,margin:`${i}px ${a}px`,padding:0,cursor:"pointer",touchAction:"none","&-vertical":{margin:`${a}px ${i}px`},[`${t}-rail`]:{position:"absolute",backgroundColor:e.railBg,borderRadius:e.borderRadiusXS,transition:`background-color ${e.motionDurationMid}`},[`${t}-track`]:{position:"absolute",backgroundColor:e.trackBg,borderRadius:e.borderRadiusXS,transition:`background-color ${e.motionDurationMid}`},[`${t}-track-draggable`]:{boxSizing:"content-box",backgroundClip:"content-box",border:"solid rgba(0,0,0,0)"},"&:hover":{[`${t}-rail`]:{backgroundColor:e.railHoverBg},[`${t}-track`]:{backgroundColor:e.trackHoverBg},[`${t}-dot`]:{borderColor:l},[`${t}-handle::after`]:{boxShadow:`0 0 0 ${e.handleLineWidth}px ${e.colorPrimaryBorderHover}`},[`${t}-dot-active`]:{borderColor:e.dotActiveBorderColor}},[`${t}-handle`]:{position:"absolute",width:e.handleSize,height:e.handleSize,outline:"none",[`${t}-dragging`]:{zIndex:1},"&::before":{content:'""',position:"absolute",insetInlineStart:-e.handleLineWidth,insetBlockStart:-e.handleLineWidth,width:e.handleSize+2*e.handleLineWidth,height:e.handleSize+2*e.handleLineWidth,backgroundColor:"transparent"},"&::after":{content:'""',position:"absolute",insetBlockStart:0,insetInlineStart:0,width:e.handleSize,height:e.handleSize,backgroundColor:e.colorBgElevated,boxShadow:`0 0 0 ${e.handleLineWidth}px ${e.handleColor}`,borderRadius:"50%",cursor:"pointer",transition:`\n inset-inline-start ${e.motionDurationMid},\n inset-block-start ${e.motionDurationMid},\n width ${e.motionDurationMid},\n height ${e.motionDurationMid},\n box-shadow ${e.motionDurationMid}\n `},"&:hover, &:active, &:focus":{"&::before":{insetInlineStart:-((e.handleSizeHover-e.handleSize)/2+e.handleLineWidthHover),insetBlockStart:-((e.handleSizeHover-e.handleSize)/2+e.handleLineWidthHover),width:e.handleSizeHover+2*e.handleLineWidthHover,height:e.handleSizeHover+2*e.handleLineWidthHover},"&::after":{boxShadow:`0 0 0 ${e.handleLineWidthHover}px ${e.handleActiveColor}`,width:e.handleSizeHover,height:e.handleSizeHover,insetInlineStart:(e.handleSize-e.handleSizeHover)/2,insetBlockStart:(e.handleSize-e.handleSizeHover)/2}}},[`${t}-mark`]:{position:"absolute",fontSize:e.fontSize},[`${t}-mark-text`]:{position:"absolute",display:"inline-block",color:e.colorTextDescription,textAlign:"center",wordBreak:"keep-all",cursor:"pointer",userSelect:"none","&-active":{color:e.colorText}},[`${t}-step`]:{position:"absolute",background:"transparent",pointerEvents:"none"},[`${t}-dot`]:{position:"absolute",width:o,height:o,backgroundColor:e.colorBgElevated,border:`${e.handleLineWidth}px solid ${e.dotBorderColor}`,borderRadius:"50%",cursor:"pointer",transition:`border-color ${e.motionDurationSlow}`,pointerEvents:"auto","&-active":{borderColor:e.dotActiveBorderColor}},[`&${t}-disabled`]:{cursor:"not-allowed",[`${t}-rail`]:{backgroundColor:`${e.railBg} !important`},[`${t}-track`]:{backgroundColor:`${e.trackBgDisabled} !important`},[`\n ${t}-dot\n `]:{backgroundColor:e.colorBgElevated,borderColor:e.trackBgDisabled,boxShadow:"none",cursor:"not-allowed"},[`${t}-handle::after`]:{backgroundColor:e.colorBgElevated,cursor:"not-allowed",width:e.handleSize,height:e.handleSize,boxShadow:`0 0 0 ${e.handleLineWidth}px ${new N.C(e.colorTextDisabled).onBackground(e.colorBgContainer).toHexShortString()}`,insetInlineStart:0,insetBlockStart:0},[`\n ${t}-mark-text,\n ${t}-dot\n `]:{cursor:"not-allowed !important"}},[`&-tooltip ${n}-tooltip-inner`]:{minWidth:"unset"}})}},V=(e,t)=>{const{componentCls:n,railSize:r,handleSize:o,dotSize:a}=e,i=t?"width":"height",l=t?"height":"width",u=t?"insetBlockStart":"insetInlineStart",c=t?"top":"insetInlineStart",s=(3*r-o)/2,d=(o-r)/2,f=t?{borderWidth:`${d}px 0`,transform:`translateY(-${d}px)`}:{borderWidth:`0 ${d}px`,transform:`translateX(-${d}px)`};return{[t?"paddingBlock":"paddingInline"]:r,[l]:3*r,[`${n}-rail`]:{[i]:"100%",[l]:r},[`${n}-track`]:{[l]:r},[`${n}-track-draggable`]:Object.assign({},f),[`${n}-handle`]:{[u]:s},[`${n}-mark`]:{insetInlineStart:0,top:0,[c]:3*r+(t?0:e.marginFull),[i]:"100%"},[`${n}-step`]:{insetInlineStart:0,top:0,[c]:r,[i]:"100%",[l]:r},[`${n}-dot`]:{position:"absolute",[u]:(r-a)/2}}},G=e=>{const{componentCls:t,marginPartWithMark:n}=e;return{[`${t}-horizontal`]:Object.assign(Object.assign({},V(e,!0)),{[`&${t}-with-marks`]:{marginBottom:n}})}},_=e=>{const{componentCls:t}=e;return{[`${t}-vertical`]:Object.assign(Object.assign({},V(e,!1)),{height:"100%"})}};var U=(0,A.Z)("Slider",(e=>{const t=(0,X.TS)(e,{marginPart:(e.controlHeight-e.controlSize)/2,marginFull:e.controlSize/2,marginPartWithMark:e.controlHeightLG-e.controlSize});return[Y(t),G(t),_(t)]}),(e=>{const t=e.controlHeightLG/4;return{controlSize:t,railSize:4,handleSize:t,handleSizeHover:e.controlHeightSM/2,dotSize:8,handleLineWidth:e.lineWidth+1,handleLineWidthHover:e.lineWidth+3,railBg:e.colorFillTertiary,railHoverBg:e.colorFillSecondary,trackBg:e.colorPrimaryBorder,trackHoverBg:e.colorPrimaryBorderHover,handleColor:e.colorPrimaryBorder,handleActiveColor:e.colorPrimary,dotBorderColor:e.colorBorderSecondary,dotActiveBorderColor:e.colorPrimaryBorder,trackBgDisabled:e.colorBgContainerDisabled}})),K=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n};const Q=e=>"number"==typeof e?e.toString():"",q=c.forwardRef(((e,t)=>{const{prefixCls:n,range:r,className:a,rootClassName:i,style:l,disabled:u,tooltipPrefixCls:s,tipFormatter:d,tooltipVisible:f,getTooltipPopupContainer:v,tooltipPlacement:h}=e,m=K(e,["prefixCls","range","className","rootClassName","style","disabled","tooltipPrefixCls","tipFormatter","tooltipVisible","getTooltipPopupContainer","tooltipPlacement"]),{direction:g,slider:b,getPrefixCls:p,getPopupContainer:x}=c.useContext(F.E_),S=c.useContext(R.Z),k=null!=u?u:S,[C,y]=c.useState({}),E=(e,t)=>{y((n=>Object.assign(Object.assign({},n),{[e]:t})))},$=(e,t)=>e||(t?"rtl"===g?"left":"right":"top"),Z=p("slider",n),[M,w]=U(Z),B=o()(a,null==b?void 0:b.className,i,{[`${Z}-rtl`]:"rtl"===g},w);"rtl"!==g||m.vertical||(m.reverse=!m.reverse);const[z,H]=c.useMemo((()=>r?"object"==typeof r?[!0,r.draggableTrack]:[!0,!1]:[!1]),[r]);const O=Object.assign(Object.assign({},null==b?void 0:b.style),l);return M(c.createElement(P,Object.assign({},m,{step:m.step,range:z,draggableTrack:H,className:B,style:O,disabled:k,ref:t,prefixCls:Z,handleRender:(t,n)=>{var r;const{index:o,dragging:a}=n,{tooltip:i={},vertical:l}=e,u=Object.assign({},i),{open:m,placement:g,getPopupContainer:b,prefixCls:S,formatter:k}=u;let y;y=k||null===k?k:d||null===d?d:Q;const M=!!y&&(C[o]||a),w=null!==(r=null!=m?m:f)&&void 0!==r?r:void 0===m&&M,B=Object.assign(Object.assign({},t.props),{onMouseEnter:()=>E(o,!0),onMouseLeave:()=>E(o,!1)}),z=p("tooltip",null!=S?S:s);return c.createElement(j,Object.assign({},u,{prefixCls:z,title:y?y(n.value):"",open:w,placement:$(null!=g?g:h,l),key:o,overlayClassName:`${Z}-tooltip`,getPopupContainer:b||v||x}),c.cloneElement(t,B))}})))}));var J=q}}]);