UNPKG

react-rotary-knob-react19

Version:
52 lines (51 loc) 74.1 kB
"use strict";var fo=Object.create;var ke=Object.defineProperty;var co=Object.getOwnPropertyDescriptor;var po=Object.getOwnPropertyNames;var mo=Object.getPrototypeOf,ho=Object.prototype.hasOwnProperty;var J=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),go=(e,t)=>{for(var r in t)ke(e,r,{get:t[r],enumerable:!0})},Zt=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of po(t))!ho.call(e,o)&&o!==r&&ke(e,o,{get:()=>t[o],enumerable:!(n=co(t,o))||n.enumerable});return e};var re=(e,t,r)=>(r=e!=null?fo(mo(e)):{},Zt(t||!e||!e.__esModule?ke(r,"default",{value:e,enumerable:!0}):r,e)),xo=e=>Zt(ke({},"__esModule",{value:!0}),e);var fr=J(E=>{"use strict";var at=Symbol.for("react.transitional.element"),yo=Symbol.for("react.portal"),vo=Symbol.for("react.fragment"),bo=Symbol.for("react.strict_mode"),wo=Symbol.for("react.profiler"),_o=Symbol.for("react.consumer"),So=Symbol.for("react.context"),Eo=Symbol.for("react.forward_ref"),Mo=Symbol.for("react.suspense"),Ao=Symbol.for("react.memo"),or=Symbol.for("react.lazy"),Jt=Symbol.iterator;function Co(e){return e===null||typeof e!="object"?null:(e=Jt&&e[Jt]||e["@@iterator"],typeof e=="function"?e:null)}var ir={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},ar=Object.assign,sr={};function xe(e,t,r){this.props=e,this.context=t,this.refs=sr,this.updater=r||ir}xe.prototype.isReactComponent={};xe.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};xe.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function ur(){}ur.prototype=xe.prototype;function st(e,t,r){this.props=e,this.context=t,this.refs=sr,this.updater=r||ir}var ut=st.prototype=new ur;ut.constructor=st;ar(ut,xe.prototype);ut.isPureReactComponent=!0;var er=Array.isArray,D={H:null,A:null,T:null,S:null},lr=Object.prototype.hasOwnProperty;function lt(e,t,r,n,o,i){return r=i.ref,{$$typeof:at,type:e,key:t,ref:r!==void 0?r:null,props:i}}function Oo(e,t){return lt(e.type,t,void 0,void 0,void 0,e.props)}function ft(e){return typeof e=="object"&&e!==null&&e.$$typeof===at}function Po(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(r){return t[r]})}var tr=/\/+/g;function it(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Po(""+e.key):t.toString(36)}function rr(){}function Ro(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status=="string"?e.then(rr,rr):(e.status="pending",e.then(function(t){e.status==="pending"&&(e.status="fulfilled",e.value=t)},function(t){e.status==="pending"&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function ge(e,t,r,n,o){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var a=!1;if(e===null)a=!0;else switch(i){case"bigint":case"string":case"number":a=!0;break;case"object":switch(e.$$typeof){case at:case yo:a=!0;break;case or:return a=e._init,ge(a(e._payload),t,r,n,o)}}if(a)return o=o(e),a=n===""?"."+it(e,0):n,er(o)?(r="",a!=null&&(r=a.replace(tr,"$&/")+"/"),ge(o,t,r,"",function(l){return l})):o!=null&&(ft(o)&&(o=Oo(o,r+(o.key==null||e&&e.key===o.key?"":(""+o.key).replace(tr,"$&/")+"/")+a)),t.push(o)),1;a=0;var s=n===""?".":n+":";if(er(e))for(var u=0;u<e.length;u++)n=e[u],i=s+it(n,u),a+=ge(n,t,r,i,o);else if(u=Co(e),typeof u=="function")for(e=u.call(e),u=0;!(n=e.next()).done;)n=n.value,i=s+it(n,u++),a+=ge(n,t,r,i,o);else if(i==="object"){if(typeof e.then=="function")return ge(Ro(e),t,r,n,o);throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.")}return a}function Te(e,t,r){if(e==null)return e;var n=[],o=0;return ge(e,n,"","",function(i){return t.call(r,i,o++)}),n}function ko(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(r){(e._status===0||e._status===-1)&&(e._status=1,e._result=r)},function(r){(e._status===0||e._status===-1)&&(e._status=2,e._result=r)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var nr=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function To(){}E.Children={map:Te,forEach:function(e,t,r){Te(e,function(){t.apply(this,arguments)},r)},count:function(e){var t=0;return Te(e,function(){t++}),t},toArray:function(e){return Te(e,function(t){return t})||[]},only:function(e){if(!ft(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};E.Component=xe;E.Fragment=vo;E.Profiler=wo;E.PureComponent=st;E.StrictMode=bo;E.Suspense=Mo;E.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=D;E.act=function(){throw Error("act(...) is not supported in production builds of React.")};E.cache=function(e){return function(){return e.apply(null,arguments)}};E.cloneElement=function(e,t,r){if(e==null)throw Error("The argument must be a React element, but you passed "+e+".");var n=ar({},e.props),o=e.key,i=void 0;if(t!=null)for(a in t.ref!==void 0&&(i=void 0),t.key!==void 0&&(o=""+t.key),t)!lr.call(t,a)||a==="key"||a==="__self"||a==="__source"||a==="ref"&&t.ref===void 0||(n[a]=t[a]);var a=arguments.length-2;if(a===1)n.children=r;else if(1<a){for(var s=Array(a),u=0;u<a;u++)s[u]=arguments[u+2];n.children=s}return lt(e.type,o,void 0,void 0,i,n)};E.createContext=function(e){return e={$$typeof:So,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:_o,_context:e},e};E.createElement=function(e,t,r){var n,o={},i=null;if(t!=null)for(n in t.key!==void 0&&(i=""+t.key),t)lr.call(t,n)&&n!=="key"&&n!=="__self"&&n!=="__source"&&(o[n]=t[n]);var a=arguments.length-2;if(a===1)o.children=r;else if(1<a){for(var s=Array(a),u=0;u<a;u++)s[u]=arguments[u+2];o.children=s}if(e&&e.defaultProps)for(n in a=e.defaultProps,a)o[n]===void 0&&(o[n]=a[n]);return lt(e,i,void 0,void 0,null,o)};E.createRef=function(){return{current:null}};E.forwardRef=function(e){return{$$typeof:Eo,render:e}};E.isValidElement=ft;E.lazy=function(e){return{$$typeof:or,_payload:{_status:-1,_result:e},_init:ko}};E.memo=function(e,t){return{$$typeof:Ao,type:e,compare:t===void 0?null:t}};E.startTransition=function(e){var t=D.T,r={};D.T=r;try{var n=e(),o=D.S;o!==null&&o(r,n),typeof n=="object"&&n!==null&&typeof n.then=="function"&&n.then(To,nr)}catch(i){nr(i)}finally{D.T=t}};E.unstable_useCacheRefresh=function(){return D.H.useCacheRefresh()};E.use=function(e){return D.H.use(e)};E.useActionState=function(e,t,r){return D.H.useActionState(e,t,r)};E.useCallback=function(e,t){return D.H.useCallback(e,t)};E.useContext=function(e){return D.H.useContext(e)};E.useDebugValue=function(){};E.useDeferredValue=function(e,t){return D.H.useDeferredValue(e,t)};E.useEffect=function(e,t){return D.H.useEffect(e,t)};E.useId=function(){return D.H.useId()};E.useImperativeHandle=function(e,t,r){return D.H.useImperativeHandle(e,t,r)};E.useInsertionEffect=function(e,t){return D.H.useInsertionEffect(e,t)};E.useLayoutEffect=function(e,t){return D.H.useLayoutEffect(e,t)};E.useMemo=function(e,t){return D.H.useMemo(e,t)};E.useOptimistic=function(e,t){return D.H.useOptimistic(e,t)};E.useReducer=function(e,t,r){return D.H.useReducer(e,t,r)};E.useRef=function(e){return D.H.useRef(e)};E.useState=function(e){return D.H.useState(e)};E.useSyncExternalStore=function(e,t,r){return D.H.useSyncExternalStore(e,t,r)};E.useTransition=function(){return D.H.useTransition()};E.version="19.0.0"});var ee=J((Ea,cr)=>{"use strict";cr.exports=fr()});var dr=J((Aa,mr)=>{"use strict";var Vo="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";mr.exports=Vo});var yr=J((Ca,xr)=>{"use strict";var Io=dr();function hr(){}function gr(){}gr.resetWarningCache=hr;xr.exports=function(){function e(n,o,i,a,s,u){if(u!==Io){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}e.isRequired=e;function t(){return e}var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:gr,resetWarningCache:hr};return r.PropTypes=r,r}});var br=J((Ra,vr)=>{vr.exports=yr()();var Oa,Pa});var _r=J((ka,wr)=>{(()=>{var e={692:(o,i,a)=>{var s;(function(u,l){"use strict";var p=u.location.protocol==="file:";l.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1");var m=Array.prototype.forEach||function(y,v){if(this==null||typeof y!="function")throw new TypeError;var g,f=this.length>>>0;for(g=0;g<f;++g)g in this&&y.call(v,this[g],g,this)},h={},A=0,C=[],T=[],L=function(y){return y.cloneNode(!0)},$=function(y,v){T[y]=T[y]||[],T[y].push(v)},H=function(y,v){if(v===void 0||typeof v=="string")return!1;var g=y.getAttribute("id");g&&v.setAttribute("id",g);var f=y.getAttribute("title");f&&v.setAttribute("title",f);var x=[].concat(v.getAttribute("class")||[],"injected-svg",y.getAttribute("class")||[]).join(" ");v.setAttribute("class",function(N){for(var Q={},Z=(N=N.split(" ")).length,Y=[];Z--;)Q.hasOwnProperty(N[Z])||(Q[N[Z]]=1,Y.unshift(N[Z]));return Y.join(" ")}(x));var c=y.getAttribute("style");c&&v.setAttribute("style",c);var b=[].filter.call(y.attributes,function(N){return/^data-\w[\w\-]*$/.test(N.name)});m.call(b,function(N){N.name&&N.value&&v.setAttribute(N.name,N.value)});var _,w,R,M,P,V={clipPath:["clip-path"],"color-profile":["color-profile"],cursor:["cursor"],filter:["filter"],linearGradient:["fill","stroke"],marker:["marker","marker-start","marker-mid","marker-end"],mask:["mask"],pattern:["fill","stroke"],radialGradient:["fill","stroke"]};Object.keys(V).forEach(function(N){_=N,R=V[N];for(var Q=0,Z=(w=v.querySelectorAll("defs "+_+"[id]")).length;Q<Z;Q++){var Y;M=w[Q].id,P=M+"-"+A,m.call(R,function(Qt){for(var ot=0,lo=(Y=v.querySelectorAll("["+Qt+'*="'+M+'"]')).length;ot<lo;ot++)Y[ot].setAttribute(Qt,"url(#"+P+")")}),w[Q].id=P}}),v.removeAttribute("xmlns:a");var k=v.querySelectorAll("style");if(m.call(k,function(N){N.textContent+=""}),O(y,v),v.hasAttributes())for(var q=v.attributes,G=q.length-1;G>=0;G--)q[G].name,q[G].value,y.setAttribute(q[G].name,q[G].value);delete C[C.indexOf(y)],y=null,A++},O=function(y,v){if(y.innerHTML=v.innerHTML||"",!y.innerHTML){var g=l.createElement("div"),f="<svg>"+function(x){let c=new XMLSerializer;return Array.prototype.slice.call(x.childNodes).map(b=>c.serializeToString(b)).join("")}(v)+"</svg>";g.innerHTML=""+f,y.textContent="",Array.prototype.slice.call(g.childNodes[0].childNodes).forEach(function(x){y.appendChild(x)})}},d=function(y,v,g,f){if(g){var x;try{x=new DOMParser().parseFromString(g,"text/xml")}catch{x=void 0}if(!x||x.getElementsByTagName("parsererror").length)return f("Unable to parse SVG file: "+x.getElementsByTagName("parsererror")[0].innerHTML),!1;H(y,x.documentElement),f()}else{var c=y.getAttribute("data-src")||y.getAttribute("src");if(y.setAttribute("src",""),C.indexOf(y)!==-1)return;C.push(y),function(b,_){if(h[b]!==void 0)h[b]instanceof SVGSVGElement?_(L(h[b])):$(b,_);else{if(!u.XMLHttpRequest)return _("Browser does not support XMLHttpRequest"),!1;h[b]={},$(b,_);var w=new XMLHttpRequest;w.onreadystatechange=function(){if(w.readyState===4){if(w.status===404||w.responseXML===null)return _("Unable to load SVG file: "+b),p&&_("Note: SVG injection ajax calls do not work locally without adjusting security setting in your browser. Or consider using a local webserver."),_(),!1;if(!(w.status===200||p&&w.status===0))return _("There was a problem injecting the SVG: "+w.status+" "+w.statusText),!1;if(w.responseXML instanceof Document)h[b]=w.responseXML.documentElement;else if(DOMParser&&DOMParser instanceof Function){var R;try{R=new DOMParser().parseFromString(w.responseText,"text/xml")}catch{R=void 0}if(!R||R.getElementsByTagName("parsererror").length)return _("Unable to parse SVG file: "+b),!1;h[b]=R.documentElement}(function(M){for(var P=0,V=T[M].length;P<V;P++)(function(k){setTimeout(function(){T[M][k](L(h[M]))},0)})(P)})(b)}},w.open("GET",b),w.overrideMimeType&&w.overrideMimeType("text/xml"),w.send()}}(c,b=>{H(y,b),f()})}},S=function(y,v,g){(v=v||{}).pngFallback;var f=v.each,x=v.svgXML;if(y.length!==void 0){var c=0;m.call(y,function(b){d(b,0,x,function(){f&&typeof f=="function"&&f(),g&&y.length===++c&&g(c)})})}else y?d(y,0,x,function(){f&&typeof f=="function"&&f(),g&&g(1),y=null}):g&&g(0)};typeof o.exports=="object"?o.exports=i=S:(s=function(){return S}.call(i,a,i,o))===void 0||(o.exports=s)})(window,document)}},t={};function r(o){var i=t[o];if(i!==void 0)return i.exports;var a=t[o]={exports:{}};return e[o](a,a.exports,r),a.exports}r.n=o=>{var i=o&&o.__esModule?()=>o.default:()=>o;return r.d(i,{a:i}),i},r.d=(o,i)=>{for(var a in i)r.o(i,a)&&!r.o(o,a)&&Object.defineProperty(o,a,{enumerable:!0,get:i[a]})},r.o=(o,i)=>Object.prototype.hasOwnProperty.call(o,i),r.r=o=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(o,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(o,"__esModule",{value:!0})};var n={};(()=>{"use strict";r.r(n),r.d(n,{SvgLoader:()=>d,SvgProxy:()=>v});let o=ee();var i=r.n(o);let a=br();var s=r.n(a);let u=["callback","path","svgXML","className"],l=["callback","path","svgXML"];function p(){return p=Object.assign?Object.assign.bind():function(g){for(var f=1;f<arguments.length;f++){var x=arguments[f];for(var c in x)({}).hasOwnProperty.call(x,c)&&(g[c]=x[c])}return g},p.apply(null,arguments)}function m(g,f){if(g==null)return{};var x,c,b=function(w,R){if(w==null)return{};var M={};for(var P in w)if({}.hasOwnProperty.call(w,P)){if(R.indexOf(P)!==-1)continue;M[P]=w[P]}return M}(g,f);if(Object.getOwnPropertySymbols){var _=Object.getOwnPropertySymbols(g);for(c=0;c<_.length;c++)x=_[c],f.indexOf(x)===-1&&{}.propertyIsEnumerable.call(g,x)&&(b[x]=g[x])}return b}let h=typeof window<"u"?r(692):void 0;class A extends i().Component{constructor(){super(),this.refCallback=this.refCallback.bind(this)}componentDidUpdate(f){this.props.path===f.path&&this.props.svgXML===f.svgXML||(this.container&&(this.container.innerHTML=""),this.renderSVG(this.props))}refCallback(f){f&&(this.container=f,this.renderSVG())}renderSVG(f=this.props){let x=this.container,{callback:c,path:b,svgXML:_,className:w}=f,R=m(f,u);h(x,{each:M=>{if(M)throw new Error(M);c(this.container)},svgXML:_},()=>{x&&R&&Object.keys(R).reduce((M,P)=>(P!=="style"&&M.setAttribute(P,R[P]),x),x)})}render(){let f=this.props,{callback:x,path:c,svgXML:b}=f,_=m(f,l);return i().createElement("svg",p({ref:this.refCallback,"data-src":this.props.path},_))}}A.defaultProps={callback:()=>{},path:null,svgXML:null},A.propTypes={callback:s().func,path:s().string,svgXML:s().string};let C=i().createContext(null),T=["path","onSVGReady","children","svgXML"];function L(){return L=Object.assign?Object.assign.bind():function(g){for(var f=1;f<arguments.length;f++){var x=arguments[f];for(var c in x)({}).hasOwnProperty.call(x,c)&&(g[c]=x[c])}return g},L.apply(null,arguments)}function $(g,f){var x=Object.keys(g);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(g);f&&(c=c.filter(function(b){return Object.getOwnPropertyDescriptor(g,b).enumerable})),x.push.apply(x,c)}return x}function H(g){for(var f=1;f<arguments.length;f++){var x=arguments[f]!=null?arguments[f]:{};f%2?$(Object(x),!0).forEach(function(c){O(g,c,x[c])}):Object.getOwnPropertyDescriptors?Object.defineProperties(g,Object.getOwnPropertyDescriptors(x)):$(Object(x)).forEach(function(c){Object.defineProperty(g,c,Object.getOwnPropertyDescriptor(x,c))})}return g}function O(g,f,x){return(f=function(c){var b=function(_){if(typeof _!="object"||!_)return _;var w=_[Symbol.toPrimitive];if(w!==void 0){var R=w.call(_,"string");if(typeof R!="object")return R;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(_)}(c);return typeof b=="symbol"?b:b+""}(f))in g?Object.defineProperty(g,f,{value:x,enumerable:!0,configurable:!0,writable:!0}):g[f]=x,g}class d extends i().Component{constructor(f){if(super(f),this.mounted=!1,this.state={svg:null,svgCount:0},i().Fragment==null)throw new Error("This version of React doesn't support Fragments, please update it");this.onSVGReady=this.onSVGReady.bind(this)}componentDidMount(){this.mounted=!0}componentWillUnmount(){this.mounted=!1}onSVGReady(f){setTimeout(()=>{this.mounted&&(this.setState(H(H({},this.state),{},{svg:f,svgCount:this.state.svgCount+1})),this.props.onSVGReady(f))},0)}render(){let f=this.props,{path:x,onSVGReady:c,children:b,svgXML:_}=f,w=function(M,P){if(M==null)return{};var V,k,q=function(N,Q){if(N==null)return{};var Z={};for(var Y in N)if({}.hasOwnProperty.call(N,Y)){if(Q.indexOf(Y)!==-1)continue;Z[Y]=N[Y]}return Z}(M,P);if(Object.getOwnPropertySymbols){var G=Object.getOwnPropertySymbols(M);for(k=0;k<G.length;k++)V=G[k],P.indexOf(V)===-1&&{}.propertyIsEnumerable.call(M,V)&&(q[V]=M[V])}return q}(f,T),R=this.state.svg!=null?this.props.children:null;return i().createElement(i().Fragment,null,i().createElement(A,L({path:x,callback:this.onSVGReady,svgXML:_},w)),i().createElement(C.Provider,{value:{path:x,svgCount:this.state.svgCount,svg:this.state.svg}},R))}}d.propTypes={path:s().string,svgXML:s().string,onSVGReady:s().func,style:s().object,children:s().any},d.defaultProps={path:null,svgXML:null,onSVGReady:function(){},style:null};let S=/(\w+)_(\S+)/,y={xlink:"http://www.w3.org/1999/xlink"};class v extends i().Component{constructor(f){super(f),this.elemRefs=[],this.svgRef=null,this.path=null,this.originalValues={},this.onSvgUpdated=this.onSvgUpdated.bind(this),this.updateSvgElements=this.updateSvgElements.bind(this)}componentDidMount(){this.updateSvgElements(this.props)}componentDidUpdate(f){this.props.selector!==f.selector&&(this.elemRefs=[]),this.updateSvgElements(this.props)}onSvgUpdated(){this.updateSvgElements(this.props,!0)}updateSvgElements(f,x){let{svgRef:c}=this;if(c&&(this.elemRefs.length===0||x)){let b=[].slice.apply(c.querySelectorAll(f.selector));b.length===0&&["svg","root"].indexOf(f.selector)!==-1&&b.push(c),f.onElementSelected&&b.length&&f.onElementSelected(b.length===1?b[0]:b),this.elemRefs=b}if(this.elemRefs){let b=Object.keys(f);for(let _=0;_<b.length;_+=1){let w=b[_];if(["selector","onElementSelected"].indexOf(w)===-1){let R=null,M=null,P=w,V=null,k=S.exec(w);k&&k[1]?(R=k[1],M=y[R],P=k[2],V=`${R}:${P}`):V=w;for(let q=0;q<this.elemRefs.length;q+=1){let G=this.elemRefs[q];if(typeof f[w]=="function")G[w.toLowerCase()]=f[w];else{if(typeof f[w]!="string")return;this.originalValues[w]==null&&(this.originalValues[w]=G.getAttributeNS(M,V)||"");let N=f[w].replace("$ORIGINAL",this.originalValues[w]);G.setAttributeNS(M,V,N),typeof f.children=="string"&&f.children.trim().length&&(G.textContent=f.children)}}}}}}render(){return i().createElement(C.Consumer,null,f=>{let{path:x,svg:c,svgCount:b}=f;this.svgCount&&this.svgCount!==b?this.onSvgUpdated():(this.svgRef=c,this.path=x,this.svgCount=b)})}}v.propTypes={selector:s().string.isRequired,onElementSelected:s().func},v.defaultProps={onElementSelected:()=>{}}})(),wr.exports=n})()});var Er=J((Ta,Sr)=>{Sr.exports=_r()});var Cr=J(B=>{"use strict";var qo=ee();function Ar(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var r=2;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function oe(){}var j={d:{f:oe,r:function(){throw Error(Ar(522))},D:oe,C:oe,L:oe,m:oe,X:oe,S:oe,M:oe},p:0,findDOMNode:null},jo=Symbol.for("react.portal");function Bo(e,t,r){var n=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:jo,key:n==null?null:""+n,children:e,containerInfo:t,implementation:r}}var we=qo.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function Ne(e,t){if(e==="font")return"";if(typeof t=="string")return t==="use-credentials"?t:""}B.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=j;B.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(Ar(299));return Bo(e,t,null,r)};B.flushSync=function(e){var t=we.T,r=j.p;try{if(we.T=null,j.p=2,e)return e()}finally{we.T=t,j.p=r,j.d.f()}};B.preconnect=function(e,t){typeof e=="string"&&(t?(t=t.crossOrigin,t=typeof t=="string"?t==="use-credentials"?t:"":void 0):t=null,j.d.C(e,t))};B.prefetchDNS=function(e){typeof e=="string"&&j.d.D(e)};B.preinit=function(e,t){if(typeof e=="string"&&t&&typeof t.as=="string"){var r=t.as,n=Ne(r,t.crossOrigin),o=typeof t.integrity=="string"?t.integrity:void 0,i=typeof t.fetchPriority=="string"?t.fetchPriority:void 0;r==="style"?j.d.S(e,typeof t.precedence=="string"?t.precedence:void 0,{crossOrigin:n,integrity:o,fetchPriority:i}):r==="script"&&j.d.X(e,{crossOrigin:n,integrity:o,fetchPriority:i,nonce:typeof t.nonce=="string"?t.nonce:void 0})}};B.preinitModule=function(e,t){if(typeof e=="string")if(typeof t=="object"&&t!==null){if(t.as==null||t.as==="script"){var r=Ne(t.as,t.crossOrigin);j.d.M(e,{crossOrigin:r,integrity:typeof t.integrity=="string"?t.integrity:void 0,nonce:typeof t.nonce=="string"?t.nonce:void 0})}}else t==null&&j.d.M(e)};B.preload=function(e,t){if(typeof e=="string"&&typeof t=="object"&&t!==null&&typeof t.as=="string"){var r=t.as,n=Ne(r,t.crossOrigin);j.d.L(e,r,{crossOrigin:n,integrity:typeof t.integrity=="string"?t.integrity:void 0,nonce:typeof t.nonce=="string"?t.nonce:void 0,type:typeof t.type=="string"?t.type:void 0,fetchPriority:typeof t.fetchPriority=="string"?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy=="string"?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet=="string"?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes=="string"?t.imageSizes:void 0,media:typeof t.media=="string"?t.media:void 0})}};B.preloadModule=function(e,t){if(typeof e=="string")if(t){var r=Ne(t.as,t.crossOrigin);j.d.m(e,{as:typeof t.as=="string"&&t.as!=="script"?t.as:void 0,crossOrigin:r,integrity:typeof t.integrity=="string"?t.integrity:void 0})}else j.d.m(e)};B.requestFormReset=function(e){j.d.r(e)};B.unstable_batchedUpdates=function(e,t){return e(t)};B.useFormState=function(e,t,r){return we.H.useFormState(e,t,r)};B.useFormStatus=function(){return we.H.useHostTransitionStatus()};B.version="19.0.0"});var Rr=J((La,Pr)=>{"use strict";function Or(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Or)}catch(e){console.error(e)}}Or(),Pr.exports=Cr()});var wa={};go(wa,{Knob:()=>Wt});module.exports=xo(wa);var X=re(ee());function No(e,t,r,n){var o=e.getBoundingClientRect(),i=t.getScreenCTM();return{x:i.a*r+i.c*n+i.e-o.left,y:i.b*r+i.d*n+i.f-o.top}}function Do(e,t,r,n){var o=e.getBoundingClientRect(),i=t.getScreenCTM().inverse();return{x:i.a*r+i.c*n+i.e-o.left,y:i.b*r+i.d*n+i.f-o.top}}function Lo(e){return e*Math.PI/180}function pr(e,t){return e>=0&&t>=0?1:e<=0&&t>=0?2:e<=0&&t<=0?3:e>=0&&t<=0?4:1}function $o(e,t){if(e==0&&t==0)return 0;let n=Math.atan(e/t)*180/Math.PI,o=pr(e,t);return o===1&&(n=90-n),o===2&&(n=90-n),o===3&&(n=270-n),o===4&&(n=270-n),n}function Ho(e){var t;let r=(((t=document.documentElement)||(t=document.body.parentNode))&&typeof t.scrollLeft=="number"?t:document.body).scrollLeft,n=(((t=document.documentElement)||(t=document.body.parentNode))&&typeof t.scrollTop=="number"?t:document.body).scrollTop,o=e.top-n,i=e.left-r;return{top:o,left:i,width:e.width,height:e.height}}var ne={toGlobalCoordinates:No,toLocalCoordinates:Do,toRadians:Lo,getQuadrant:pr,getAngleForPoint:$o,transformBoundingClientRectToDocument:Ho};var Re=re(Er());var Mr={knobX:71,knobY:71,updateAttributes:[],svg:` <svg width="204px" height="204px" viewBox="0 0 204 204" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <!-- Generator: Sketch 47.1 (45422) - http://www.bohemiancoding.com/sketch --> <desc>Created with Sketch.</desc> <defs> <linearGradient x1="50%" y1="50%" x2="50%" y2="100%" id="linearGradient-1"> <stop stop-color="#444040" stop-opacity="0.51098279" offset="0%"></stop> <stop stop-color="#131111" stop-opacity="0.893200861" offset="100%"></stop> </linearGradient> <circle id="path-2" cx="98.0400009" cy="98.0400009" r="98.0400009"></circle> <filter x="-3.3%" y="-3.3%" width="106.6%" height="106.6%" filterUnits="objectBoundingBox" id="filter-3"> <feMorphology radius="0.5" operator="dilate" in="SourceAlpha" result="shadowSpreadOuter1"></feMorphology> <feOffset dx="0" dy="0" in="shadowSpreadOuter1" result="shadowOffsetOuter1"></feOffset> <feGaussianBlur stdDeviation="2" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur> <feComposite in="shadowBlurOuter1" in2="SourceAlpha" operator="out" result="shadowBlurOuter1"></feComposite> <feColorMatrix values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.5 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix> </filter> <linearGradient x1="50%" y1="0%" x2="50%" y2="100%" id="linearGradient-4"> <stop stop-color="#FFFFFF" stop-opacity="0.5" offset="0%"></stop> <stop stop-color="#000000" stop-opacity="0.5" offset="100%"></stop> </linearGradient> <circle id="path-5" cx="98" cy="98" r="86"></circle> <filter x="-4.1%" y="-3.5%" width="108.1%" height="108.1%" filterUnits="objectBoundingBox" id="filter-6"> <feMorphology radius="0.5" operator="dilate" in="SourceAlpha" result="shadowSpreadOuter1"></feMorphology> <feOffset dx="0" dy="1" in="shadowSpreadOuter1" result="shadowOffsetOuter1"></feOffset> <feGaussianBlur stdDeviation="2" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur> <feComposite in="shadowBlurOuter1" in2="SourceAlpha" operator="out" result="shadowBlurOuter1"></feComposite> <feColorMatrix values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.5 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix> </filter> </defs> <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd"> <g id="s13" transform="translate(4.000000, 4.000000)"> <g id="container"> <g id="Oval-2"> <use fill="black" fill-opacity="1" filter="url(#filter-3)" xlink:href="#path-2"></use> <use stroke="#979797" stroke-width="1" fill="url(#linearGradient-1)" fill-rule="evenodd" xlink:href="#path-2"></use> </g> <g id="Oval-2"> <use fill="black" fill-opacity="1" filter="url(#filter-6)" xlink:href="#path-5"></use> <use fill="" fill-rule="evenodd" xlink:href="#path-5"></use> <use stroke="#4A4A4A" stroke-width="1" fill="url(#linearGradient-4)" fill-rule="evenodd" xlink:href="#path-5"></use> </g> <g id="knob" transform="translate(27.431373, 27.431373)"> <circle id="Oval-5" fill="#322E2E" cx="71" cy="71" r="71"></circle> <path d="M70.0686275,4.17063061 L86.5686275,65.2689929 C81.3642501,66.811221 75.8642501,67.5735686 70.0686275,67.5560356 C64.2730048,67.5385027 58.7730048,66.7761551 53.5686275,65.2689929 L70.0686275,4.17063061 Z" id="Rectangle-Copy" fill="#E6D7D7" transform="translate(70.068627, 35.863481) scale(1, -1) translate(-70.068627, -35.863481) "></path> </g> </g> </g> </g> </svg> `};var z=re(ee());var ct=re(ee()),kr=re(Rr()),pt=class extends ct.default.Component{render(){let t={overlay:Object.assign({width:"100%",height:"100vh",top:0,left:0,zIndex:2147483647,margin:"0",padding:"0",boxSizing:"border-box",position:"fixed"},this.props.overlayStyle||{})},{overlayStyle:r,...n}=this.props;return kr.default.createPortal(ct.default.createElement("div",{style:t.overlay,...n},this.props.children),document.body)}},Tr=pt;var mt=re(ee()),dt=class extends mt.default.Component{static defaultProps={borderColor:"black",fillColor:"transparent",borderWidth:2,fillOpacity:1};render(){let{r:t,borderColor:r,fillColor:n,borderWidth:o,cx:i,cy:a,...s}=this.props,u=this.props.r*2;return mt.default.createElement("circle",{stroke:this.props.borderColor,fill:this.props.fillColor,fillOpacity:this.props.fillOpacity,r:this.props.r,cx:this.props.cx,cy:this.props.cy,...s})}},ht=dt;var gt=re(ee()),xt=class extends gt.default.Component{static defaultProps={width:2,color:"black"};render(){let{width:t,color:r,...n}=this.props;return gt.default.createElement("line",{x1:this.props.p1.x,y1:this.props.p1.y,x2:this.props.p2.x,y2:this.props.p2.y,stroke:r,strokeWidth:this.props.width,...n})}},Nr=xt;var De=class extends z.default.Component{state={centerX:0,centerY:0,valueMarkerX:0,valueMarkerY:0};static getDerivedStateFromProps(t,r){let n=t.svgRef.current.getBoundingClientRect(),o=n.width/2,i=t.radius*Math.cos(ne.toRadians(t.valueAngle-90)),a=t.radius*Math.sin(ne.toRadians(t.valueAngle-90));return{...r,centerX:n.left+o,centerY:n.top+o,valueMarkerX:i,valueMarkerY:a}}render(){let t=this.props.minimumDragDistance<=this.props.radius?"green":"grey",r=this.props.minimumDragDistance<=this.props.radius?"#88E22D":"#D8D8D8",n=this.props.minimumDragDistance>=this.props.radius;return z.default.createElement(Tr,null,z.default.createElement("svg",{style:{position:"absolute",top:"0",left:"0"},width:"100%",height:"100%"},z.default.createElement("defs",null,z.default.createElement("marker",{id:"Triangle",viewBox:"0 0 10 10",refX:"1",refY:"5",markerWidth:"6",markerHeight:"6",orient:"auto"},z.default.createElement("path",{d:"M 0 0 L 10 5 L 0 10 z"}))),z.default.createElement(ht,{borderColor:t,fillColor:r,fillOpacity:.02,r:this.props.radius,cx:this.state.centerX,cy:this.state.centerY}),n&&z.default.createElement(ht,{borderColor:t,fillColor:r,fillOpacity:0,r:this.props.minimumDragDistance,cx:this.state.centerX,cy:this.state.centerY,strokeDasharray:"5, 5"}),z.default.createElement(Nr,{p1:{x:this.state.centerX,y:this.state.centerY},p2:{x:this.state.valueMarkerX+this.state.centerX,y:this.state.valueMarkerY+this.state.centerY},markerEnd:"url(#Triangle)"})))}};var yt=re(ee()),vt=class extends yt.default.Component{static defaultProps={step:1};render(){let t=this.props,r={};function n(h){t.onChange(Number(h.target.value))}let{value:o,min:i,max:a,step:s,onChange:u,inputRef:l,style:p,...m}=t;return yt.default.createElement("input",{ref:l,value:o,step:s,onChange:n,style:{...r,...p},type:"range",min:i,max:a,...m})}},Dr=vt;var Go={value:()=>{}};function $r(){for(var e=0,t=arguments.length,r={},n;e<t;++e){if(!(n=arguments[e]+"")||n in r||/[\s.]/.test(n))throw new Error("illegal type: "+n);r[n]=[]}return new Le(r)}function Le(e){this._=e}function Fo(e,t){return e.trim().split(/^|\s+/).map(function(r){var n="",o=r.indexOf(".");if(o>=0&&(n=r.slice(o+1),r=r.slice(0,o)),r&&!t.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:n}})}Le.prototype=$r.prototype={constructor:Le,on:function(e,t){var r=this._,n=Fo(e+"",r),o,i=-1,a=n.length;if(arguments.length<2){for(;++i<a;)if((o=(e=n[i]).type)&&(o=Xo(r[o],e.name)))return o;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++i<a;)if(o=(e=n[i]).type)r[o]=Lr(r[o],e.name,t);else if(t==null)for(o in r)r[o]=Lr(r[o],e.name,null);return this},copy:function(){var e={},t=this._;for(var r in t)e[r]=t[r].slice();return new Le(e)},call:function(e,t){if((o=arguments.length-2)>0)for(var r=new Array(o),n=0,o,i;n<o;++n)r[n]=arguments[n+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(i=this._[e],n=0,o=i.length;n<o;++n)i[n].value.apply(t,r)},apply:function(e,t,r){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var n=this._[e],o=0,i=n.length;o<i;++o)n[o].value.apply(t,r)}};function Xo(e,t){for(var r=0,n=e.length,o;r<n;++r)if((o=e[r]).name===t)return o.value}function Lr(e,t,r){for(var n=0,o=e.length;n<o;++n)if(e[n].name===t){e[n]=Go,e=e.slice(0,n).concat(e.slice(n+1));break}return r!=null&&e.push({name:t,value:r}),e}var bt=$r;var $e="http://www.w3.org/1999/xhtml",wt={svg:"http://www.w3.org/2000/svg",xhtml:$e,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function He(e){var t=e+="",r=t.indexOf(":");return r>=0&&(t=e.slice(0,r))!=="xmlns"&&(e=e.slice(r+1)),wt.hasOwnProperty(t)?{space:wt[t],local:e}:e}function Uo(e){return function(){var t=this.ownerDocument,r=this.namespaceURI;return r===$e&&t.documentElement.namespaceURI===$e?t.createElement(e):t.createElementNS(r,e)}}function Yo(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function Ve(e){var t=He(e);return(t.local?Yo:Uo)(t)}function zo(){}function Ie(e){return e==null?zo:function(){return this.querySelector(e)}}function Hr(e){typeof e!="function"&&(e=Ie(e));for(var t=this._groups,r=t.length,n=new Array(r),o=0;o<r;++o)for(var i=t[o],a=i.length,s=n[o]=new Array(a),u,l,p=0;p<a;++p)(u=i[p])&&(l=e.call(u,u.__data__,p,i))&&("__data__"in u&&(l.__data__=u.__data__),s[p]=l);return new I(n,this._parents)}function _t(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function Ko(){return[]}function Vr(e){return e==null?Ko:function(){return this.querySelectorAll(e)}}function Wo(e){return function(){return _t(e.apply(this,arguments))}}function Ir(e){typeof e=="function"?e=Wo(e):e=Vr(e);for(var t=this._groups,r=t.length,n=[],o=[],i=0;i<r;++i)for(var a=t[i],s=a.length,u,l=0;l<s;++l)(u=a[l])&&(n.push(e.call(u,u.__data__,l,a)),o.push(u));return new I(n,o)}function qr(e){return function(){return this.matches(e)}}function qe(e){return function(t){return t.matches(e)}}var Qo=Array.prototype.find;function Zo(e){return function(){return Qo.call(this.children,e)}}function Jo(){return this.firstElementChild}function jr(e){return this.select(e==null?Jo:Zo(typeof e=="function"?e:qe(e)))}var ei=Array.prototype.filter;function ti(){return Array.from(this.children)}function ri(e){return function(){return ei.call(this.children,e)}}function Br(e){return this.selectAll(e==null?ti:ri(typeof e=="function"?e:qe(e)))}function Gr(e){typeof e!="function"&&(e=qr(e));for(var t=this._groups,r=t.length,n=new Array(r),o=0;o<r;++o)for(var i=t[o],a=i.length,s=n[o]=[],u,l=0;l<a;++l)(u=i[l])&&e.call(u,u.__data__,l,i)&&s.push(u);return new I(n,this._parents)}function je(e){return new Array(e.length)}function Fr(){return new I(this._enter||this._groups.map(je),this._parents)}function _e(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}_e.prototype={constructor:_e,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function Xr(e){return function(){return e}}function ni(e,t,r,n,o,i){for(var a=0,s,u=t.length,l=i.length;a<l;++a)(s=t[a])?(s.__data__=i[a],n[a]=s):r[a]=new _e(e,i[a]);for(;a<u;++a)(s=t[a])&&(o[a]=s)}function oi(e,t,r,n,o,i,a){var s,u,l=new Map,p=t.length,m=i.length,h=new Array(p),A;for(s=0;s<p;++s)(u=t[s])&&(h[s]=A=a.call(u,u.__data__,s,t)+"",l.has(A)?o[s]=u:l.set(A,u));for(s=0;s<m;++s)A=a.call(e,i[s],s,i)+"",(u=l.get(A))?(n[s]=u,u.__data__=i[s],l.delete(A)):r[s]=new _e(e,i[s]);for(s=0;s<p;++s)(u=t[s])&&l.get(h[s])===u&&(o[s]=u)}function ii(e){return e.__data__}function Ur(e,t){if(!arguments.length)return Array.from(this,ii);var r=t?oi:ni,n=this._parents,o=this._groups;typeof e!="function"&&(e=Xr(e));for(var i=o.length,a=new Array(i),s=new Array(i),u=new Array(i),l=0;l<i;++l){var p=n[l],m=o[l],h=m.length,A=ai(e.call(p,p&&p.__data__,l,n)),C=A.length,T=s[l]=new Array(C),L=a[l]=new Array(C),$=u[l]=new Array(h);r(p,m,T,L,$,A,t);for(var H=0,O=0,d,S;H<C;++H)if(d=T[H]){for(H>=O&&(O=H+1);!(S=L[O])&&++O<C;);d._next=S||null}}return a=new I(a,n),a._enter=s,a._exit=u,a}function ai(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Yr(){return new I(this._exit||this._groups.map(je),this._parents)}function zr(e,t,r){var n=this.enter(),o=this,i=this.exit();return typeof e=="function"?(n=e(n),n&&(n=n.selection())):n=n.append(e+""),t!=null&&(o=t(o),o&&(o=o.selection())),r==null?i.remove():r(i),n&&o?n.merge(o).order():o}function Kr(e){for(var t=e.selection?e.selection():e,r=this._groups,n=t._groups,o=r.length,i=n.length,a=Math.min(o,i),s=new Array(o),u=0;u<a;++u)for(var l=r[u],p=n[u],m=l.length,h=s[u]=new Array(m),A,C=0;C<m;++C)(A=l[C]||p[C])&&(h[C]=A);for(;u<o;++u)s[u]=r[u];return new I(s,this._parents)}function Wr(){for(var e=this._groups,t=-1,r=e.length;++t<r;)for(var n=e[t],o=n.length-1,i=n[o],a;--o>=0;)(a=n[o])&&(i&&a.compareDocumentPosition(i)^4&&i.parentNode.insertBefore(a,i),i=a);return this}function Qr(e){e||(e=si);function t(m,h){return m&&h?e(m.__data__,h.__data__):!m-!h}for(var r=this._groups,n=r.length,o=new Array(n),i=0;i<n;++i){for(var a=r[i],s=a.length,u=o[i]=new Array(s),l,p=0;p<s;++p)(l=a[p])&&(u[p]=l);u.sort(t)}return new I(o,this._parents).order()}function si(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function Zr(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function Jr(){return Array.from(this)}function en(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var n=e[t],o=0,i=n.length;o<i;++o){var a=n[o];if(a)return a}return null}function tn(){let e=0;for(let t of this)++e;return e}function rn(){return!this.node()}function nn(e){for(var t=this._groups,r=0,n=t.length;r<n;++r)for(var o=t[r],i=0,a=o.length,s;i<a;++i)(s=o[i])&&e.call(s,s.__data__,i,o);return this}function ui(e){return function(){this.removeAttribute(e)}}function li(e){return function(){this.removeAttributeNS(e.space,e.local)}}function fi(e,t){return function(){this.setAttribute(e,t)}}function ci(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function pi(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttribute(e):this.setAttribute(e,r)}}function mi(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,r)}}function on(e,t){var r=He(e);if(arguments.length<2){var n=this.node();return r.local?n.getAttributeNS(r.space,r.local):n.getAttribute(r)}return this.each((t==null?r.local?li:ui:typeof t=="function"?r.local?mi:pi:r.local?ci:fi)(r,t))}function Be(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function di(e){return function(){this.style.removeProperty(e)}}function hi(e,t,r){return function(){this.style.setProperty(e,t,r)}}function gi(e,t,r){return function(){var n=t.apply(this,arguments);n==null?this.style.removeProperty(e):this.style.setProperty(e,n,r)}}function an(e,t,r){return arguments.length>1?this.each((t==null?di:typeof t=="function"?gi:hi)(e,t,r??"")):xi(this.node(),e)}function xi(e,t){return e.style.getPropertyValue(t)||Be(e).getComputedStyle(e,null).getPropertyValue(t)}function yi(e){return function(){delete this[e]}}function vi(e,t){return function(){this[e]=t}}function bi(e,t){return function(){var r=t.apply(this,arguments);r==null?delete this[e]:this[e]=r}}function sn(e,t){return arguments.length>1?this.each((t==null?yi:typeof t=="function"?bi:vi)(e,t)):this.node()[e]}function un(e){return e.trim().split(/^|\s+/)}function St(e){return e.classList||new ln(e)}function ln(e){this._node=e,this._names=un(e.getAttribute("class")||"")}ln.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function fn(e,t){for(var r=St(e),n=-1,o=t.length;++n<o;)r.add(t[n])}function cn(e,t){for(var r=St(e),n=-1,o=t.length;++n<o;)r.remove(t[n])}function wi(e){return function(){fn(this,e)}}function _i(e){return function(){cn(this,e)}}function Si(e,t){return function(){(t.apply(this,arguments)?fn:cn)(this,e)}}function pn(e,t){var r=un(e+"");if(arguments.length<2){for(var n=St(this.node()),o=-1,i=r.length;++o<i;)if(!n.contains(r[o]))return!1;return!0}return this.each((typeof t=="function"?Si:t?wi:_i)(r,t))}function Ei(){this.textContent=""}function Mi(e){return function(){this.textContent=e}}function Ai(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function mn(e){return arguments.length?this.each(e==null?Ei:(typeof e=="function"?Ai:Mi)(e)):this.node().textContent}function Ci(){this.innerHTML=""}function Oi(e){return function(){this.innerHTML=e}}function Pi(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function dn(e){return arguments.length?this.each(e==null?Ci:(typeof e=="function"?Pi:Oi)(e)):this.node().innerHTML}function Ri(){this.nextSibling&&this.parentNode.appendChild(this)}function hn(){return this.each(Ri)}function ki(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function gn(){return this.each(ki)}function xn(e){var t=typeof e=="function"?e:Ve(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function Ti(){return null}function yn(e,t){var r=typeof e=="function"?e:Ve(e),n=t==null?Ti:typeof t=="function"?t:Ie(t);return this.select(function(){return this.insertBefore(r.apply(this,arguments),n.apply(this,arguments)||null)})}function Ni(){var e=this.parentNode;e&&e.removeChild(this)}function vn(){return this.each(Ni)}function Di(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Li(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function bn(e){return this.select(e?Li:Di)}function wn(e){return arguments.length?this.property("__data__",e):this.node().__data__}function $i(e){return function(t){e.call(this,t,this.__data__)}}function Hi(e){return e.trim().split(/^|\s+/).map(function(t){var r="",n=t.indexOf(".");return n>=0&&(r=t.slice(n+1),t=t.slice(0,n)),{type:t,name:r}})}function Vi(e){return function(){var t=this.__on;if(t){for(var r=0,n=-1,o=t.length,i;r<o;++r)i=t[r],(!e.type||i.type===e.type)&&i.name===e.name?this.removeEventListener(i.type,i.listener,i.options):t[++n]=i;++n?t.length=n:delete this.__on}}}function Ii(e,t,r){return function(){var n=this.__on,o,i=$i(t);if(n){for(var a=0,s=n.length;a<s;++a)if((o=n[a]).type===e.type&&o.name===e.name){this.removeEventListener(o.type,o.listener,o.options),this.addEventListener(o.type,o.listener=i,o.options=r),o.value=t;return}}this.addEventListener(e.type,i,r),o={type:e.type,name:e.name,value:t,listener:i,options:r},n?n.push(o):this.__on=[o]}}function _n(e,t,r){var n=Hi(e+""),o,i=n.length,a;if(arguments.length<2){var s=this.node().__on;if(s){for(var u=0,l=s.length,p;u<l;++u)for(o=0,p=s[u];o<i;++o)if((a=n[o]).type===p.type&&a.name===p.name)return p.value}return}for(s=t?Ii:Vi,o=0;o<i;++o)this.each(s(n[o],t,r));return this}function Sn(e,t,r){var n=Be(e),o=n.CustomEvent;typeof o=="function"?o=new o(t,r):(o=n.document.createEvent("Event"),r?(o.initEvent(t,r.bubbles,r.cancelable),o.detail=r.detail):o.initEvent(t,!1,!1)),e.dispatchEvent(o)}function qi(e,t){return function(){return Sn(this,e,t)}}function ji(e,t){return function(){return Sn(this,e,t.apply(this,arguments))}}function En(e,t){return this.each((typeof t=="function"?ji:qi)(e,t))}function*Mn(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var n=e[t],o=0,i=n.length,a;o<i;++o)(a=n[o])&&(yield a)}var Et=[null];function I(e,t){this._groups=e,this._parents=t}function Bi(){return new I([[document.documentElement]],Et)}function Gi(){return this}I.prototype=Bi.prototype={constructor:I,select:Hr,selectAll:Ir,selectChild:jr,selectChildren:Br,filter:Gr,data:Ur,enter:Fr,exit:Yr,join:zr,merge:Kr,selection:Gi,order:Wr,sort:Qr,call:Zr,nodes:Jr,node:en,size:tn,empty:rn,each:nn,attr:on,style:an,property:sn,classed:pn,text:mn,html:dn,raise:hn,lower:gn,append:xn,insert:yn,remove:vn,clone:bn,datum:wn,on:_n,dispatch:En,[Symbol.iterator]:Mn};function te(e){return typeof e=="string"?new I([[document.querySelector(e)]],[document.documentElement]):new I([[e]],Et)}function An(e){let t;for(;t=e.sourceEvent;)e=t;return e}function Ge(e,t){if(e=An(e),t===void 0&&(t=e.currentTarget),t){var r=t.ownerSVGElement||t;if(r.createSVGPoint){var n=r.createSVGPoint();return n.x=e.clientX,n.y=e.clientY,n=n.matrixTransform(t.getScreenCTM().inverse()),[n.x,n.y]}if(t.getBoundingClientRect){var o=t.getBoundingClientRect();return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}}return[e.pageX,e.pageY]}var Cn={passive:!1},le={capture:!0,passive:!1};function Fe(e){e.stopImmediatePropagation()}function ie(e){e.preventDefault(),e.stopImmediatePropagation()}function On(e){var t=e.document.documentElement,r=te(e).on("dragstart.drag",ie,le);"onselectstart"in t?r.on("selectstart.drag",ie,le):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function Pn(e,t){var r=e.document.documentElement,n=te(e).on("dragstart.drag",null);t&&(n.on("click.drag",ie,le),setTimeout(function(){n.on("click.drag",null)},0)),"onselectstart"in r?n.on("selectstart.drag",null):(r.style.MozUserSelect=r.__noselect,delete r.__noselect)}var Se=e=>()=>e;function Ee(e,{sourceEvent:t,subject:r,target:n,identifier:o,active:i,x:a,y:s,dx:u,dy:l,dispatch:p}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:r,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},identifier:{value:o,enumerable:!0,configurable:!0},active:{value:i,enumerable:!0,configurable:!0},x:{value:a,enumerable:!0,configurable:!0},y:{value:s,enumerable:!0,configurable:!0},dx:{value:u,enumerable:!0,configurable:!0},dy:{value:l,enumerable:!0,configurable:!0},_:{value:p}})}Ee.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function Fi(e){return!e.ctrlKey&&!e.button}function Xi(){return this.parentNode}function Ui(e,t){return t??{x:e.x,y:e.y}}function Yi(){return navigator.maxTouchPoints||"ontouchstart"in this}function Mt(){var e=Fi,t=Xi,r=Ui,n=Yi,o={},i=bt("start","drag","end"),a=0,s,u,l,p,m=0;function h(d){d.on("mousedown.drag",A).filter(n).on("touchstart.drag",L).on("touchmove.drag",$,Cn).on("touchend.drag touchcancel.drag",H).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function A(d,S){if(!(p||!e.call(this,d,S))){var y=O(this,t.call(this,d,S),d,S,"mouse");y&&(te(d.view).on("mousemove.drag",C,le).on("mouseup.drag",T,le),On(d.view),Fe(d),l=!1,s=d.clientX,u=d.clientY,y("start",d))}}function C(d){if(ie(d),!l){var S=d.clientX-s,y=d.clientY-u;l=S*S+y*y>m}o.mouse("drag",d)}function T(d){te(d.view).on("mousemove.drag mouseup.drag",null),Pn(d.view,l),ie(d),o.mouse("end",d)}function L(d,S){if(e.call(this,d,S)){var y=d.changedTouches,v=t.call(this,d,S),g=y.length,f,x;for(f=0;f<g;++f)(x=O(this,v,d,S,y[f].identifier,y[f]))&&(Fe(d),x("start",d,y[f]))}}function $(d){var S=d.changedTouches,y=S.length,v,g;for(v=0;v<y;++v)(g=o[S[v].identifier])&&(ie(d),g("drag",d,S[v]))}function H(d){var S=d.changedTouches,y=S.length,v,g;for(p&&clearTimeout(p),p=setTimeout(function(){p=null},500),v=0;v<y;++v)(g=o[S[v].identifier])&&(Fe(d),g("end",d,S[v]))}function O(d,S,y,v,g,f){var x=i.copy(),c=Ge(f||y,S),b,_,w;if((w=r.call(d,new Ee("beforestart",{sourceEvent:y,target:h,identifier:g,active:a,x:c[0],y:c[1],dx:0,dy:0,dispatch:x}),v))!=null)return b=w.x-c[0]||0,_=w.y-c[1]||0,function R(M,P,V){var k=c,q;switch(M){case"start":o[g]=R,q=a++;break;case"end":delete o[g],--a;case"drag":c=Ge(V||P,S),q=a;break}x.call(M,d,new Ee(M,{sourceEvent:P,subject:w,target:h,identifier:g,active:q,x:c[0]+b,y:c[1]+_,dx:c[0]-k[0],dy:c[1]-k[1],dispatch:x}),v)}}return h.filter=function(d){return arguments.length?(e=typeof d=="function"?d:Se(!!d),h):e},h.container=function(d){return arguments.length?(t=typeof d=="function"?d:Se(d),h):t},h.subject=function(d){return arguments.length?(r=typeof d=="function"?d:Se(d),h):r},h.touchable=function(d){return arguments.length?(n=typeof d=="function"?d:Se(!!d),h):n},h.on=function(){var d=i.on.apply(i,arguments);return d===i?h:d},h.clickDistance=function(d){return arguments.length?(m=(d=+d)*d,h):Math.sqrt(m)},h}function fe(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function At(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Xe(e){let t,r,n;e.length!==2?(t=fe,r=(s,u)=>fe(e(s),u),n=(s,u)=>e(s)-u):(t=e===fe||e===At?e:zi,r=e,n=e);function o(s,u,l=0,p=s.length){if(l<p){if(t(u,u)!==0)return p;do{let m=l+p>>>1;r(s[m],u)<0?l=m+1:p=m}while(l<p)}return l}function i(s,u,l=0,p=s.length){if(l<p){if(t(u,u)!==0)return p;do{let m=l+p>>>1;r(s[m],u)<=0?l=m+1:p=m}while(l<p)}return l}function a(s,u,l=0,p=s.length){let m=o(s,u,l,p-1);return m>l&&n(s[m-1],u)>-n(s[m],u)?m-1:m}return{left:o,center:a,right:i}}function zi(){return 0}fu