From 6a9538d05062fdd8ce4d18deada5ac33280e77a3 Mon Sep 17 00:00:00 2001 From: Github Actions Date: Thu, 23 Jan 2025 15:12:26 +0000 Subject: [PATCH] ci: automatic build fixes --- ...der-1ef5878d.js => ClipLoader-8590c2f1.js} | 2 +- ...on-c5f0390c.js => DailyMotion-1fc74fca.js} | 2 +- ...ebook-95305f52.js => Facebook-ecfe1118.js} | 2 +- ...yer-66165434.js => FilePlayer-59fef6f9.js} | 2 +- ...altura-890aa431.js => Kaltura-a5ccda38.js} | 2 +- ...cloud-158f251f.js => Mixcloud-6647e53d.js} | 2 +- ...review-ac92af9a.js => Preview-2ad93ee1.js} | 2 +- ...leton-dbbfd404.js => Skeleton-7af13a79.js} | 8 +- ...oud-cb3d2c50.js => SoundCloud-b012eb42.js} | 2 +- .../{Stack-6038813c.js => Stack-5870980a.js} | 2 +- ...ble-344c59ee.js => Streamable-7ba1c141.js} | 2 +- .../{Tabs-7ecc0b57.js => Tabs-71f3fbcc.js} | 2 +- ...16e8d1.js => TextareaAutosize-f6242cb8.js} | 4 +- ...{Twitch-eec52ec3.js => Twitch-08c50d1f.js} | 2 +- build/assets/Typography-2a31701b.js | 1 + build/assets/Typography-f76555b9.js | 1 - ...idyard-77bcf258.js => Vidyard-9c70b529.js} | 2 +- .../{Vimeo-15629a32.js => Vimeo-401b9966.js} | 2 +- ...{Wistia-500f8a97.js => Wistia-74afe4bb.js} | 2 +- ...ouTube-af1e25c0.js => YouTube-2c06e076.js} | 2 +- ...ants-bc1d79ca.js => constants-b9d9206a.js} | 4 +- ...-41051178.js => createSvgIcon-c125a9c8.js} | 2 +- .../{index-c3934e6a.js => index-047858ad.js} | 6 +- build/assets/index-22c3582f.js | 71 ----- build/assets/index-27a0b90a.js | 246 ------------------ .../{index-7888478e.js => index-37b3c15b.js} | 2 +- .../{index-78eebc06.js => index-40addfb3.js} | 2 +- .../{index-4bb27744.js => index-4e60c9e2.js} | 12 +- .../{index-5111ebdb.js => index-569670a3.js} | 2 +- .../{index-c3e0684d.js => index-5c4e6029.js} | 4 +- .../{index-59c77710.js => index-5c5c5836.js} | 2 +- .../{index-e9ea328e.js => index-66368309.js} | 2 +- .../{index-b3d55c88.js => index-70e1d6d6.js} | 2 +- .../{index-5ca84596.js => index-763b7c2d.js} | 6 +- .../{index-6e6f13b5.js => index-769bba79.js} | 10 +- .../{index-a17bf5d0.js => index-7fe50db2.js} | 2 +- .../{index-e06603b3.js => index-88446b65.js} | 2 +- .../{index-20575f2c.js => index-8a87d5eb.js} | 8 +- .../{index-87de005d.js => index-a46872c4.js} | 4 +- .../{index-d0e3c339.js => index-aa1facf3.js} | 2 +- .../{index-7730ff6f.js => index-af5a3f81.js} | 2 +- .../{index-25ee1701.js => index-aff6ba6e.js} | 2 +- .../{index-005a3994.js => index-b8b4f42e.js} | 16 +- .../{index-686eedfc.js => index-c2e413fd.js} | 6 +- .../{index-dc12854c.js => index-c715ffeb.js} | 2 +- .../{index-555c3317.js => index-cf343a35.js} | 12 +- .../{index-ea85a09b.js => index-cfa9dcd8.js} | 4 +- build/assets/index-d07244c7.js | 246 ++++++++++++++++++ build/assets/index-d96216bb.js | 71 +++++ .../{index-39d7c317.js => index-f0bb1f56.js} | 6 +- build/assets/isPlainObject-1f2f9f4b.js | 1 + build/assets/isPlainObject-b85008a5.js | 1 - build/index.html | 2 +- 53 files changed, 404 insertions(+), 404 deletions(-) rename build/assets/{ClipLoader-1ef5878d.js => ClipLoader-8590c2f1.js} (97%) rename build/assets/{DailyMotion-c5f0390c.js => DailyMotion-1fc74fca.js} (95%) rename build/assets/{Facebook-95305f52.js => Facebook-ecfe1118.js} (96%) rename build/assets/{FilePlayer-66165434.js => FilePlayer-59fef6f9.js} (98%) rename build/assets/{Kaltura-890aa431.js => Kaltura-a5ccda38.js} (95%) rename build/assets/{Mixcloud-158f251f.js => Mixcloud-6647e53d.js} (95%) rename build/assets/{Preview-ac92af9a.js => Preview-2ad93ee1.js} (97%) rename build/assets/{Skeleton-dbbfd404.js => Skeleton-7af13a79.js} (72%) rename build/assets/{SoundCloud-cb3d2c50.js => SoundCloud-b012eb42.js} (95%) rename build/assets/{Stack-6038813c.js => Stack-5870980a.js} (63%) rename build/assets/{Streamable-344c59ee.js => Streamable-7ba1c141.js} (95%) rename build/assets/{Tabs-7ecc0b57.js => Tabs-71f3fbcc.js} (84%) rename build/assets/{TextareaAutosize-b716e8d1.js => TextareaAutosize-f6242cb8.js} (56%) rename build/assets/{Twitch-eec52ec3.js => Twitch-08c50d1f.js} (95%) create mode 100644 build/assets/Typography-2a31701b.js delete mode 100644 build/assets/Typography-f76555b9.js rename build/assets/{Vidyard-77bcf258.js => Vidyard-9c70b529.js} (95%) rename build/assets/{Vimeo-15629a32.js => Vimeo-401b9966.js} (96%) rename build/assets/{Wistia-500f8a97.js => Wistia-74afe4bb.js} (96%) rename build/assets/{YouTube-af1e25c0.js => YouTube-2c06e076.js} (97%) rename build/assets/{constants-bc1d79ca.js => constants-b9d9206a.js} (50%) rename build/assets/{createSvgIcon-41051178.js => createSvgIcon-c125a9c8.js} (94%) rename build/assets/{index-c3934e6a.js => index-047858ad.js} (78%) delete mode 100644 build/assets/index-22c3582f.js delete mode 100644 build/assets/index-27a0b90a.js rename build/assets/{index-7888478e.js => index-37b3c15b.js} (91%) rename build/assets/{index-78eebc06.js => index-40addfb3.js} (95%) rename build/assets/{index-4bb27744.js => index-4e60c9e2.js} (99%) rename build/assets/{index-5111ebdb.js => index-569670a3.js} (96%) rename build/assets/{index-c3e0684d.js => index-5c4e6029.js} (82%) rename build/assets/{index-59c77710.js => index-5c5c5836.js} (99%) rename build/assets/{index-e9ea328e.js => index-66368309.js} (99%) rename build/assets/{index-b3d55c88.js => index-70e1d6d6.js} (95%) rename build/assets/{index-5ca84596.js => index-763b7c2d.js} (97%) rename build/assets/{index-6e6f13b5.js => index-769bba79.js} (61%) rename build/assets/{index-a17bf5d0.js => index-7fe50db2.js} (69%) rename build/assets/{index-e06603b3.js => index-88446b65.js} (99%) rename build/assets/{index-20575f2c.js => index-8a87d5eb.js} (56%) rename build/assets/{index-87de005d.js => index-a46872c4.js} (99%) rename build/assets/{index-d0e3c339.js => index-aa1facf3.js} (85%) rename build/assets/{index-7730ff6f.js => index-af5a3f81.js} (72%) rename build/assets/{index-25ee1701.js => index-aff6ba6e.js} (95%) rename build/assets/{index-005a3994.js => index-b8b4f42e.js} (95%) rename build/assets/{index-686eedfc.js => index-c2e413fd.js} (72%) rename build/assets/{index-dc12854c.js => index-c715ffeb.js} (99%) rename build/assets/{index-555c3317.js => index-cf343a35.js} (82%) rename build/assets/{index-ea85a09b.js => index-cfa9dcd8.js} (89%) create mode 100644 build/assets/index-d07244c7.js create mode 100644 build/assets/index-d96216bb.js rename build/assets/{index-39d7c317.js => index-f0bb1f56.js} (86%) create mode 100644 build/assets/isPlainObject-1f2f9f4b.js delete mode 100644 build/assets/isPlainObject-b85008a5.js diff --git a/build/assets/ClipLoader-1ef5878d.js b/build/assets/ClipLoader-8590c2f1.js similarity index 97% rename from build/assets/ClipLoader-1ef5878d.js rename to build/assets/ClipLoader-8590c2f1.js index 458c4f710..d0eaf54e2 100644 --- a/build/assets/ClipLoader-1ef5878d.js +++ b/build/assets/ClipLoader-8590c2f1.js @@ -1,4 +1,4 @@ -import{r as m}from"./index-4bb27744.js";var g={cm:!0,mm:!0,in:!0,px:!0,pt:!0,pc:!0,em:!0,ex:!0,ch:!0,rem:!0,vw:!0,vh:!0,vmin:!0,vmax:!0,"%":!0};function h(e){if(typeof e=="number")return{value:e,unit:"px"};var t,a=(e.match(/^[0-9.]*/)||"").toString();a.includes(".")?t=parseFloat(a):t=parseInt(a,10);var r=(e.match(/[^0-9]*$/)||"").toString();return g[r]?{value:t,unit:r}:(console.warn("React Spinners: ".concat(e," is not a valid css value. Defaulting to ").concat(t,"px.")),{value:t,unit:"px"})}function d(e){var t=h(e);return"".concat(t.value).concat(t.unit)}var b=function(e,t,a){var r="react-spinners-".concat(e,"-").concat(a);if(typeof window>"u"||!window.document)return r;var n=document.createElement("style");document.head.appendChild(n);var o=n.sheet,l=` +import{r as m}from"./index-4e60c9e2.js";var g={cm:!0,mm:!0,in:!0,px:!0,pt:!0,pc:!0,em:!0,ex:!0,ch:!0,rem:!0,vw:!0,vh:!0,vmin:!0,vmax:!0,"%":!0};function h(e){if(typeof e=="number")return{value:e,unit:"px"};var t,a=(e.match(/^[0-9.]*/)||"").toString();a.includes(".")?t=parseFloat(a):t=parseInt(a,10);var r=(e.match(/[^0-9]*$/)||"").toString();return g[r]?{value:t,unit:r}:(console.warn("React Spinners: ".concat(e," is not a valid css value. Defaulting to ").concat(t,"px.")),{value:t,unit:"px"})}function d(e){var t=h(e);return"".concat(t.value).concat(t.unit)}var b=function(e,t,a){var r="react-spinners-".concat(e,"-").concat(a);if(typeof window>"u"||!window.document)return r;var n=document.createElement("style");document.head.appendChild(n);var o=n.sheet,l=` @keyframes `.concat(r,` { `).concat(t,` } diff --git a/build/assets/DailyMotion-c5f0390c.js b/build/assets/DailyMotion-1fc74fca.js similarity index 95% rename from build/assets/DailyMotion-c5f0390c.js rename to build/assets/DailyMotion-1fc74fca.js index e577ce784..90c7f4038 100644 --- a/build/assets/DailyMotion-c5f0390c.js +++ b/build/assets/DailyMotion-1fc74fca.js @@ -1 +1 @@ -import{a9 as P,r as v}from"./index-4bb27744.js";import{u as D,p as O}from"./index-87de005d.js";function b(t,e){for(var r=0;ro[a]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var M=Object.create,s=Object.defineProperty,w=Object.getOwnPropertyDescriptor,S=Object.getOwnPropertyNames,j=Object.getPrototypeOf,T=Object.prototype.hasOwnProperty,E=(t,e,r)=>e in t?s(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,A=(t,e)=>{for(var r in e)s(t,r,{get:e[r],enumerable:!0})},h=(t,e,r,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of S(e))!T.call(t,a)&&a!==r&&s(t,a,{get:()=>e[a],enumerable:!(o=w(e,a))||o.enumerable});return t},L=(t,e,r)=>(r=t!=null?M(j(t)):{},h(e||!t||!t.__esModule?s(r,"default",{value:t,enumerable:!0}):r,t)),C=t=>h(s({},"__esModule",{value:!0}),t),n=(t,e,r)=>(E(t,typeof e!="symbol"?e+"":e,r),r),d={};A(d,{default:()=>p});var _=C(d),c=L(v),l=D,f=O;const x="https://api.dmcdn.net/all.js",N="DM",K="dmAsyncInit";class p extends c.Component{constructor(){super(...arguments),n(this,"callPlayer",l.callPlayer),n(this,"onDurationChange",()=>{const e=this.getDuration();this.props.onDuration(e)}),n(this,"mute",()=>{this.callPlayer("setMuted",!0)}),n(this,"unmute",()=>{this.callPlayer("setMuted",!1)}),n(this,"ref",e=>{this.container=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){const{controls:r,config:o,onError:a,playing:i}=this.props,[,y]=e.match(f.MATCH_URL_DAILYMOTION);if(this.player){this.player.load(y,{start:(0,l.parseStartTime)(e),autoplay:i});return}(0,l.getSDK)(x,N,K,u=>u.player).then(u=>{if(!this.container)return;const m=u.player;this.player=new m(this.container,{width:"100%",height:"100%",video:y,params:{controls:r,autoplay:this.props.playing,mute:this.props.muted,start:(0,l.parseStartTime)(e),origin:window.location.origin,...o.params},events:{apiready:this.props.onReady,seeked:()=>this.props.onSeek(this.player.currentTime),video_end:this.props.onEnded,durationchange:this.onDurationChange,pause:this.props.onPause,playing:this.props.onPlay,waiting:this.props.onBuffer,error:g=>a(g)}})},a)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}getDuration(){return this.player.duration||null}getCurrentTime(){return this.player.currentTime}getSecondsLoaded(){return this.player.bufferedTime}render(){const{display:e}=this.props,r={width:"100%",height:"100%",display:e};return c.default.createElement("div",{style:r},c.default.createElement("div",{ref:this.ref}))}}n(p,"displayName","DailyMotion");n(p,"canPlay",f.canPlay.dailymotion);n(p,"loopOnEnded",!0);const R=P(_),k=b({__proto__:null,default:R},[_]);export{k as D}; +import{a8 as P,r as v}from"./index-4e60c9e2.js";import{u as D,p as O}from"./index-a46872c4.js";function b(t,e){for(var r=0;ro[a]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var M=Object.create,s=Object.defineProperty,w=Object.getOwnPropertyDescriptor,S=Object.getOwnPropertyNames,j=Object.getPrototypeOf,T=Object.prototype.hasOwnProperty,E=(t,e,r)=>e in t?s(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,A=(t,e)=>{for(var r in e)s(t,r,{get:e[r],enumerable:!0})},h=(t,e,r,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of S(e))!T.call(t,a)&&a!==r&&s(t,a,{get:()=>e[a],enumerable:!(o=w(e,a))||o.enumerable});return t},L=(t,e,r)=>(r=t!=null?M(j(t)):{},h(e||!t||!t.__esModule?s(r,"default",{value:t,enumerable:!0}):r,t)),C=t=>h(s({},"__esModule",{value:!0}),t),n=(t,e,r)=>(E(t,typeof e!="symbol"?e+"":e,r),r),d={};A(d,{default:()=>p});var _=C(d),c=L(v),l=D,f=O;const x="https://api.dmcdn.net/all.js",N="DM",K="dmAsyncInit";class p extends c.Component{constructor(){super(...arguments),n(this,"callPlayer",l.callPlayer),n(this,"onDurationChange",()=>{const e=this.getDuration();this.props.onDuration(e)}),n(this,"mute",()=>{this.callPlayer("setMuted",!0)}),n(this,"unmute",()=>{this.callPlayer("setMuted",!1)}),n(this,"ref",e=>{this.container=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){const{controls:r,config:o,onError:a,playing:i}=this.props,[,y]=e.match(f.MATCH_URL_DAILYMOTION);if(this.player){this.player.load(y,{start:(0,l.parseStartTime)(e),autoplay:i});return}(0,l.getSDK)(x,N,K,u=>u.player).then(u=>{if(!this.container)return;const m=u.player;this.player=new m(this.container,{width:"100%",height:"100%",video:y,params:{controls:r,autoplay:this.props.playing,mute:this.props.muted,start:(0,l.parseStartTime)(e),origin:window.location.origin,...o.params},events:{apiready:this.props.onReady,seeked:()=>this.props.onSeek(this.player.currentTime),video_end:this.props.onEnded,durationchange:this.onDurationChange,pause:this.props.onPause,playing:this.props.onPlay,waiting:this.props.onBuffer,error:g=>a(g)}})},a)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}getDuration(){return this.player.duration||null}getCurrentTime(){return this.player.currentTime}getSecondsLoaded(){return this.player.bufferedTime}render(){const{display:e}=this.props,r={width:"100%",height:"100%",display:e};return c.default.createElement("div",{style:r},c.default.createElement("div",{ref:this.ref}))}}n(p,"displayName","DailyMotion");n(p,"canPlay",f.canPlay.dailymotion);n(p,"loopOnEnded",!0);const R=P(_),k=b({__proto__:null,default:R},[_]);export{k as D}; diff --git a/build/assets/Facebook-95305f52.js b/build/assets/Facebook-ecfe1118.js similarity index 96% rename from build/assets/Facebook-95305f52.js rename to build/assets/Facebook-ecfe1118.js index e2af7020c..59ef6bb92 100644 --- a/build/assets/Facebook-95305f52.js +++ b/build/assets/Facebook-ecfe1118.js @@ -1 +1 @@ -import{a9 as _,r as P}from"./index-4bb27744.js";import{u as g,p as m}from"./index-87de005d.js";function v(t,e){for(var r=0;ra[s]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var O=Object.create,i=Object.defineProperty,D=Object.getOwnPropertyDescriptor,E=Object.getOwnPropertyNames,S=Object.getPrototypeOf,j=Object.prototype.hasOwnProperty,I=(t,e,r)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,k=(t,e)=>{for(var r in e)i(t,r,{get:e[r],enumerable:!0})},h=(t,e,r,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of E(e))!j.call(t,s)&&s!==r&&i(t,s,{get:()=>e[s],enumerable:!(a=D(e,s))||a.enumerable});return t},w=(t,e,r)=>(r=t!=null?O(S(t)):{},h(e||!t||!t.__esModule?i(r,"default",{value:t,enumerable:!0}):r,t)),F=t=>h(i({},"__esModule",{value:!0}),t),o=(t,e,r)=>(I(t,typeof e!="symbol"?e+"":e,r),r),b={};k(b,{default:()=>l});var d=F(b),u=w(P),n=g,x=m;const c="https://connect.facebook.net/en_US/sdk.js",f="FB",y="fbAsyncInit",L="facebook-player-";class l extends u.Component{constructor(){super(...arguments),o(this,"callPlayer",n.callPlayer),o(this,"playerID",this.props.config.playerId||`${L}${(0,n.randomString)()}`),o(this,"mute",()=>{this.callPlayer("mute")}),o(this,"unmute",()=>{this.callPlayer("unmute")})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e,r){if(r){(0,n.getSDK)(c,f,y).then(a=>a.XFBML.parse());return}(0,n.getSDK)(c,f,y).then(a=>{a.init({appId:this.props.config.appId,xfbml:!0,version:this.props.config.version}),a.Event.subscribe("xfbml.render",s=>{this.props.onLoaded()}),a.Event.subscribe("xfbml.ready",s=>{s.type==="video"&&s.id===this.playerID&&(this.player=s.instance,this.player.subscribe("startedPlaying",this.props.onPlay),this.player.subscribe("paused",this.props.onPause),this.player.subscribe("finishedPlaying",this.props.onEnded),this.player.subscribe("startedBuffering",this.props.onBuffer),this.player.subscribe("finishedBuffering",this.props.onBufferEnd),this.player.subscribe("error",this.props.onError),this.props.muted?this.callPlayer("mute"):this.callPlayer("unmute"),this.props.onReady(),document.getElementById(this.playerID).querySelector("iframe").style.visibility="visible")})})}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentPosition")}getSecondsLoaded(){return null}render(){const{attributes:e}=this.props.config,r={width:"100%",height:"100%"};return u.default.createElement("div",{style:r,id:this.playerID,className:"fb-video","data-href":this.props.url,"data-autoplay":this.props.playing?"true":"false","data-allowfullscreen":"true","data-controls":this.props.controls?"true":"false",...e})}}o(l,"displayName","Facebook");o(l,"canPlay",x.canPlay.facebook);o(l,"loopOnEnded",!0);const M=_(d),N=v({__proto__:null,default:M},[d]);export{N as F}; +import{a8 as _,r as P}from"./index-4e60c9e2.js";import{u as g,p as m}from"./index-a46872c4.js";function v(t,e){for(var r=0;ra[s]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var O=Object.create,i=Object.defineProperty,D=Object.getOwnPropertyDescriptor,E=Object.getOwnPropertyNames,S=Object.getPrototypeOf,j=Object.prototype.hasOwnProperty,I=(t,e,r)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,k=(t,e)=>{for(var r in e)i(t,r,{get:e[r],enumerable:!0})},h=(t,e,r,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of E(e))!j.call(t,s)&&s!==r&&i(t,s,{get:()=>e[s],enumerable:!(a=D(e,s))||a.enumerable});return t},w=(t,e,r)=>(r=t!=null?O(S(t)):{},h(e||!t||!t.__esModule?i(r,"default",{value:t,enumerable:!0}):r,t)),F=t=>h(i({},"__esModule",{value:!0}),t),o=(t,e,r)=>(I(t,typeof e!="symbol"?e+"":e,r),r),b={};k(b,{default:()=>l});var d=F(b),u=w(P),n=g,x=m;const c="https://connect.facebook.net/en_US/sdk.js",f="FB",y="fbAsyncInit",L="facebook-player-";class l extends u.Component{constructor(){super(...arguments),o(this,"callPlayer",n.callPlayer),o(this,"playerID",this.props.config.playerId||`${L}${(0,n.randomString)()}`),o(this,"mute",()=>{this.callPlayer("mute")}),o(this,"unmute",()=>{this.callPlayer("unmute")})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e,r){if(r){(0,n.getSDK)(c,f,y).then(a=>a.XFBML.parse());return}(0,n.getSDK)(c,f,y).then(a=>{a.init({appId:this.props.config.appId,xfbml:!0,version:this.props.config.version}),a.Event.subscribe("xfbml.render",s=>{this.props.onLoaded()}),a.Event.subscribe("xfbml.ready",s=>{s.type==="video"&&s.id===this.playerID&&(this.player=s.instance,this.player.subscribe("startedPlaying",this.props.onPlay),this.player.subscribe("paused",this.props.onPause),this.player.subscribe("finishedPlaying",this.props.onEnded),this.player.subscribe("startedBuffering",this.props.onBuffer),this.player.subscribe("finishedBuffering",this.props.onBufferEnd),this.player.subscribe("error",this.props.onError),this.props.muted?this.callPlayer("mute"):this.callPlayer("unmute"),this.props.onReady(),document.getElementById(this.playerID).querySelector("iframe").style.visibility="visible")})})}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentPosition")}getSecondsLoaded(){return null}render(){const{attributes:e}=this.props.config,r={width:"100%",height:"100%"};return u.default.createElement("div",{style:r,id:this.playerID,className:"fb-video","data-href":this.props.url,"data-autoplay":this.props.playing?"true":"false","data-allowfullscreen":"true","data-controls":this.props.controls?"true":"false",...e})}}o(l,"displayName","Facebook");o(l,"canPlay",x.canPlay.facebook);o(l,"loopOnEnded",!0);const M=_(d),N=v({__proto__:null,default:M},[d]);export{N as F}; diff --git a/build/assets/FilePlayer-66165434.js b/build/assets/FilePlayer-59fef6f9.js similarity index 98% rename from build/assets/FilePlayer-66165434.js rename to build/assets/FilePlayer-59fef6f9.js index 29b5733fb..32c8a0eb8 100644 --- a/build/assets/FilePlayer-66165434.js +++ b/build/assets/FilePlayer-59fef6f9.js @@ -1 +1 @@ -import{a9 as b,r as _}from"./index-4bb27744.js";import{u as O,p as A}from"./index-87de005d.js";function R(s,e){for(var t=0;ti[n]})}}}return Object.freeze(Object.defineProperty(s,Symbol.toStringTag,{value:"Module"}))}var I=Object.create,u=Object.defineProperty,D=Object.getOwnPropertyDescriptor,w=Object.getOwnPropertyNames,M=Object.getPrototypeOf,k=Object.prototype.hasOwnProperty,U=(s,e,t)=>e in s?u(s,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):s[e]=t,N=(s,e)=>{for(var t in e)u(s,t,{get:e[t],enumerable:!0})},E=(s,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of w(e))!k.call(s,n)&&n!==t&&u(s,n,{get:()=>e[n],enumerable:!(i=D(e,n))||i.enumerable});return s},j=(s,e,t)=>(t=s!=null?I(M(s)):{},E(e||!s||!s.__esModule?u(t,"default",{value:s,enumerable:!0}):t,s)),H=s=>E(u({},"__esModule",{value:!0}),s),r=(s,e,t)=>(U(s,typeof e!="symbol"?e+"":e,t),t),m={};N(m,{default:()=>P});var g=H(m),c=j(_),a=O,d=A;const y=typeof navigator<"u",F=y&&navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1,v=y&&(/iPad|iPhone|iPod/.test(navigator.userAgent)||F)&&!window.MSStream,V=y&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent)&&!window.MSStream,T="https://cdn.jsdelivr.net/npm/hls.js@VERSION/dist/hls.min.js",C="Hls",B="https://cdnjs.cloudflare.com/ajax/libs/dashjs/VERSION/dash.all.min.js",x="dashjs",K="https://cdn.jsdelivr.net/npm/flv.js@VERSION/dist/flv.min.js",G="flvjs",X=/www\.dropbox\.com\/.+/,f=/https:\/\/watch\.cloudflarestream\.com\/([a-z0-9]+)/,W="https://videodelivery.net/{id}/manifest/video.m3u8";class P extends c.Component{constructor(){super(...arguments),r(this,"onReady",(...e)=>this.props.onReady(...e)),r(this,"onPlay",(...e)=>this.props.onPlay(...e)),r(this,"onBuffer",(...e)=>this.props.onBuffer(...e)),r(this,"onBufferEnd",(...e)=>this.props.onBufferEnd(...e)),r(this,"onPause",(...e)=>this.props.onPause(...e)),r(this,"onEnded",(...e)=>this.props.onEnded(...e)),r(this,"onError",(...e)=>this.props.onError(...e)),r(this,"onPlayBackRateChange",e=>this.props.onPlaybackRateChange(e.target.playbackRate)),r(this,"onEnablePIP",(...e)=>this.props.onEnablePIP(...e)),r(this,"onDisablePIP",e=>{const{onDisablePIP:t,playing:i}=this.props;t(e),i&&this.play()}),r(this,"onPresentationModeChange",e=>{if(this.player&&(0,a.supportsWebKitPresentationMode)(this.player)){const{webkitPresentationMode:t}=this.player;t==="picture-in-picture"?this.onEnablePIP(e):t==="inline"&&this.onDisablePIP(e)}}),r(this,"onSeek",e=>{this.props.onSeek(e.target.currentTime)}),r(this,"mute",()=>{this.player.muted=!0}),r(this,"unmute",()=>{this.player.muted=!1}),r(this,"renderSourceElement",(e,t)=>typeof e=="string"?c.default.createElement("source",{key:t,src:e}):c.default.createElement("source",{key:t,...e})),r(this,"renderTrack",(e,t)=>c.default.createElement("track",{key:t,...e})),r(this,"ref",e=>{this.player&&(this.prevPlayer=this.player),this.player=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this),this.addListeners(this.player);const e=this.getSource(this.props.url);e&&(this.player.src=e),(v||this.props.config.forceDisableHls)&&this.player.load()}componentDidUpdate(e){this.shouldUseAudio(this.props)!==this.shouldUseAudio(e)&&(this.removeListeners(this.prevPlayer,e.url),this.addListeners(this.player)),this.props.url!==e.url&&!(0,a.isMediaStream)(this.props.url)&&!(this.props.url instanceof Array)&&(this.player.srcObject=null)}componentWillUnmount(){this.player.removeAttribute("src"),this.removeListeners(this.player),this.hls&&this.hls.destroy()}addListeners(e){const{url:t,playsinline:i}=this.props;e.addEventListener("play",this.onPlay),e.addEventListener("waiting",this.onBuffer),e.addEventListener("playing",this.onBufferEnd),e.addEventListener("pause",this.onPause),e.addEventListener("seeked",this.onSeek),e.addEventListener("ended",this.onEnded),e.addEventListener("error",this.onError),e.addEventListener("ratechange",this.onPlayBackRateChange),e.addEventListener("enterpictureinpicture",this.onEnablePIP),e.addEventListener("leavepictureinpicture",this.onDisablePIP),e.addEventListener("webkitpresentationmodechanged",this.onPresentationModeChange),this.shouldUseHLS(t)||e.addEventListener("canplay",this.onReady),i&&(e.setAttribute("playsinline",""),e.setAttribute("webkit-playsinline",""),e.setAttribute("x5-playsinline",""))}removeListeners(e,t){e.removeEventListener("canplay",this.onReady),e.removeEventListener("play",this.onPlay),e.removeEventListener("waiting",this.onBuffer),e.removeEventListener("playing",this.onBufferEnd),e.removeEventListener("pause",this.onPause),e.removeEventListener("seeked",this.onSeek),e.removeEventListener("ended",this.onEnded),e.removeEventListener("error",this.onError),e.removeEventListener("ratechange",this.onPlayBackRateChange),e.removeEventListener("enterpictureinpicture",this.onEnablePIP),e.removeEventListener("leavepictureinpicture",this.onDisablePIP),e.removeEventListener("webkitpresentationmodechanged",this.onPresentationModeChange),this.shouldUseHLS(t)||e.removeEventListener("canplay",this.onReady)}shouldUseAudio(e){return e.config.forceVideo||e.config.attributes.poster?!1:d.AUDIO_EXTENSIONS.test(e.url)||e.config.forceAudio}shouldUseHLS(e){return V&&this.props.config.forceSafariHLS||this.props.config.forceHLS?!0:v||this.props.config.forceDisableHls?!1:d.HLS_EXTENSIONS.test(e)||f.test(e)}shouldUseDASH(e){return d.DASH_EXTENSIONS.test(e)||this.props.config.forceDASH}shouldUseFLV(e){return d.FLV_EXTENSIONS.test(e)||this.props.config.forceFLV}load(e){const{hlsVersion:t,hlsOptions:i,dashVersion:n,flvVersion:l}=this.props.config;if(this.hls&&this.hls.destroy(),this.dash&&this.dash.reset(),this.shouldUseHLS(e)&&(0,a.getSDK)(T.replace("VERSION",t),C).then(o=>{if(this.hls=new o(i),this.hls.on(o.Events.MANIFEST_PARSED,()=>{this.props.onReady()}),this.hls.on(o.Events.ERROR,(h,p)=>{this.props.onError(h,p,this.hls,o)}),f.test(e)){const h=e.match(f)[1];this.hls.loadSource(W.replace("{id}",h))}else this.hls.loadSource(e);this.hls.attachMedia(this.player),this.props.onLoaded()}),this.shouldUseDASH(e)&&(0,a.getSDK)(B.replace("VERSION",n),x).then(o=>{this.dash=o.MediaPlayer().create(),this.dash.initialize(this.player,e,this.props.playing),this.dash.on("error",this.props.onError),parseInt(n)<3?this.dash.getDebug().setLogToBrowserConsole(!1):this.dash.updateSettings({debug:{logLevel:o.Debug.LOG_LEVEL_NONE}}),this.props.onLoaded()}),this.shouldUseFLV(e)&&(0,a.getSDK)(K.replace("VERSION",l),G).then(o=>{this.flv=o.createPlayer({type:"flv",url:e}),this.flv.attachMediaElement(this.player),this.flv.on(o.Events.ERROR,(h,p)=>{this.props.onError(h,p,this.flv,o)}),this.flv.load(),this.props.onLoaded()}),e instanceof Array)this.player.load();else if((0,a.isMediaStream)(e))try{this.player.srcObject=e}catch{this.player.src=window.URL.createObjectURL(e)}}play(){const e=this.player.play();e&&e.catch(this.props.onError)}pause(){this.player.pause()}stop(){this.player.removeAttribute("src"),this.dash&&this.dash.reset()}seekTo(e,t=!0){this.player.currentTime=e,t||this.pause()}setVolume(e){this.player.volume=e}enablePIP(){this.player.requestPictureInPicture&&document.pictureInPictureElement!==this.player?this.player.requestPictureInPicture():(0,a.supportsWebKitPresentationMode)(this.player)&&this.player.webkitPresentationMode!=="picture-in-picture"&&this.player.webkitSetPresentationMode("picture-in-picture")}disablePIP(){document.exitPictureInPicture&&document.pictureInPictureElement===this.player?document.exitPictureInPicture():(0,a.supportsWebKitPresentationMode)(this.player)&&this.player.webkitPresentationMode!=="inline"&&this.player.webkitSetPresentationMode("inline")}setPlaybackRate(e){try{this.player.playbackRate=e}catch(t){this.props.onError(t)}}getDuration(){if(!this.player)return null;const{duration:e,seekable:t}=this.player;return e===1/0&&t.length>0?t.end(t.length-1):e}getCurrentTime(){return this.player?this.player.currentTime:null}getSecondsLoaded(){if(!this.player)return null;const{buffered:e}=this.player;if(e.length===0)return 0;const t=e.end(e.length-1),i=this.getDuration();return t>i?i:t}getSource(e){const t=this.shouldUseHLS(e),i=this.shouldUseDASH(e),n=this.shouldUseFLV(e);if(!(e instanceof Array||(0,a.isMediaStream)(e)||t||i||n))return X.test(e)?e.replace("www.dropbox.com","dl.dropboxusercontent.com"):e}render(){const{url:e,playing:t,loop:i,controls:n,muted:l,config:o,width:h,height:p}=this.props,L=this.shouldUseAudio(this.props)?"audio":"video",S={width:h==="auto"?h:"100%",height:p==="auto"?p:"100%"};return c.default.createElement(L,{ref:this.ref,src:this.getSource(e),style:S,preload:"auto",autoPlay:t||void 0,controls:n,muted:l,loop:i,...o.attributes},e instanceof Array&&e.map(this.renderSourceElement),o.tracks.map(this.renderTrack))}}r(P,"displayName","FilePlayer");r(P,"canPlay",d.canPlay.file);const z=b(g),Q=R({__proto__:null,default:z},[g]);export{Q as F}; +import{a8 as b,r as _}from"./index-4e60c9e2.js";import{u as O,p as A}from"./index-a46872c4.js";function R(s,e){for(var t=0;ti[n]})}}}return Object.freeze(Object.defineProperty(s,Symbol.toStringTag,{value:"Module"}))}var I=Object.create,u=Object.defineProperty,D=Object.getOwnPropertyDescriptor,w=Object.getOwnPropertyNames,M=Object.getPrototypeOf,k=Object.prototype.hasOwnProperty,U=(s,e,t)=>e in s?u(s,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):s[e]=t,N=(s,e)=>{for(var t in e)u(s,t,{get:e[t],enumerable:!0})},E=(s,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let n of w(e))!k.call(s,n)&&n!==t&&u(s,n,{get:()=>e[n],enumerable:!(i=D(e,n))||i.enumerable});return s},j=(s,e,t)=>(t=s!=null?I(M(s)):{},E(e||!s||!s.__esModule?u(t,"default",{value:s,enumerable:!0}):t,s)),H=s=>E(u({},"__esModule",{value:!0}),s),r=(s,e,t)=>(U(s,typeof e!="symbol"?e+"":e,t),t),m={};N(m,{default:()=>P});var g=H(m),c=j(_),a=O,d=A;const y=typeof navigator<"u",F=y&&navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1,v=y&&(/iPad|iPhone|iPod/.test(navigator.userAgent)||F)&&!window.MSStream,V=y&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent)&&!window.MSStream,T="https://cdn.jsdelivr.net/npm/hls.js@VERSION/dist/hls.min.js",C="Hls",B="https://cdnjs.cloudflare.com/ajax/libs/dashjs/VERSION/dash.all.min.js",x="dashjs",K="https://cdn.jsdelivr.net/npm/flv.js@VERSION/dist/flv.min.js",G="flvjs",X=/www\.dropbox\.com\/.+/,f=/https:\/\/watch\.cloudflarestream\.com\/([a-z0-9]+)/,W="https://videodelivery.net/{id}/manifest/video.m3u8";class P extends c.Component{constructor(){super(...arguments),r(this,"onReady",(...e)=>this.props.onReady(...e)),r(this,"onPlay",(...e)=>this.props.onPlay(...e)),r(this,"onBuffer",(...e)=>this.props.onBuffer(...e)),r(this,"onBufferEnd",(...e)=>this.props.onBufferEnd(...e)),r(this,"onPause",(...e)=>this.props.onPause(...e)),r(this,"onEnded",(...e)=>this.props.onEnded(...e)),r(this,"onError",(...e)=>this.props.onError(...e)),r(this,"onPlayBackRateChange",e=>this.props.onPlaybackRateChange(e.target.playbackRate)),r(this,"onEnablePIP",(...e)=>this.props.onEnablePIP(...e)),r(this,"onDisablePIP",e=>{const{onDisablePIP:t,playing:i}=this.props;t(e),i&&this.play()}),r(this,"onPresentationModeChange",e=>{if(this.player&&(0,a.supportsWebKitPresentationMode)(this.player)){const{webkitPresentationMode:t}=this.player;t==="picture-in-picture"?this.onEnablePIP(e):t==="inline"&&this.onDisablePIP(e)}}),r(this,"onSeek",e=>{this.props.onSeek(e.target.currentTime)}),r(this,"mute",()=>{this.player.muted=!0}),r(this,"unmute",()=>{this.player.muted=!1}),r(this,"renderSourceElement",(e,t)=>typeof e=="string"?c.default.createElement("source",{key:t,src:e}):c.default.createElement("source",{key:t,...e})),r(this,"renderTrack",(e,t)=>c.default.createElement("track",{key:t,...e})),r(this,"ref",e=>{this.player&&(this.prevPlayer=this.player),this.player=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this),this.addListeners(this.player);const e=this.getSource(this.props.url);e&&(this.player.src=e),(v||this.props.config.forceDisableHls)&&this.player.load()}componentDidUpdate(e){this.shouldUseAudio(this.props)!==this.shouldUseAudio(e)&&(this.removeListeners(this.prevPlayer,e.url),this.addListeners(this.player)),this.props.url!==e.url&&!(0,a.isMediaStream)(this.props.url)&&!(this.props.url instanceof Array)&&(this.player.srcObject=null)}componentWillUnmount(){this.player.removeAttribute("src"),this.removeListeners(this.player),this.hls&&this.hls.destroy()}addListeners(e){const{url:t,playsinline:i}=this.props;e.addEventListener("play",this.onPlay),e.addEventListener("waiting",this.onBuffer),e.addEventListener("playing",this.onBufferEnd),e.addEventListener("pause",this.onPause),e.addEventListener("seeked",this.onSeek),e.addEventListener("ended",this.onEnded),e.addEventListener("error",this.onError),e.addEventListener("ratechange",this.onPlayBackRateChange),e.addEventListener("enterpictureinpicture",this.onEnablePIP),e.addEventListener("leavepictureinpicture",this.onDisablePIP),e.addEventListener("webkitpresentationmodechanged",this.onPresentationModeChange),this.shouldUseHLS(t)||e.addEventListener("canplay",this.onReady),i&&(e.setAttribute("playsinline",""),e.setAttribute("webkit-playsinline",""),e.setAttribute("x5-playsinline",""))}removeListeners(e,t){e.removeEventListener("canplay",this.onReady),e.removeEventListener("play",this.onPlay),e.removeEventListener("waiting",this.onBuffer),e.removeEventListener("playing",this.onBufferEnd),e.removeEventListener("pause",this.onPause),e.removeEventListener("seeked",this.onSeek),e.removeEventListener("ended",this.onEnded),e.removeEventListener("error",this.onError),e.removeEventListener("ratechange",this.onPlayBackRateChange),e.removeEventListener("enterpictureinpicture",this.onEnablePIP),e.removeEventListener("leavepictureinpicture",this.onDisablePIP),e.removeEventListener("webkitpresentationmodechanged",this.onPresentationModeChange),this.shouldUseHLS(t)||e.removeEventListener("canplay",this.onReady)}shouldUseAudio(e){return e.config.forceVideo||e.config.attributes.poster?!1:d.AUDIO_EXTENSIONS.test(e.url)||e.config.forceAudio}shouldUseHLS(e){return V&&this.props.config.forceSafariHLS||this.props.config.forceHLS?!0:v||this.props.config.forceDisableHls?!1:d.HLS_EXTENSIONS.test(e)||f.test(e)}shouldUseDASH(e){return d.DASH_EXTENSIONS.test(e)||this.props.config.forceDASH}shouldUseFLV(e){return d.FLV_EXTENSIONS.test(e)||this.props.config.forceFLV}load(e){const{hlsVersion:t,hlsOptions:i,dashVersion:n,flvVersion:l}=this.props.config;if(this.hls&&this.hls.destroy(),this.dash&&this.dash.reset(),this.shouldUseHLS(e)&&(0,a.getSDK)(T.replace("VERSION",t),C).then(o=>{if(this.hls=new o(i),this.hls.on(o.Events.MANIFEST_PARSED,()=>{this.props.onReady()}),this.hls.on(o.Events.ERROR,(h,p)=>{this.props.onError(h,p,this.hls,o)}),f.test(e)){const h=e.match(f)[1];this.hls.loadSource(W.replace("{id}",h))}else this.hls.loadSource(e);this.hls.attachMedia(this.player),this.props.onLoaded()}),this.shouldUseDASH(e)&&(0,a.getSDK)(B.replace("VERSION",n),x).then(o=>{this.dash=o.MediaPlayer().create(),this.dash.initialize(this.player,e,this.props.playing),this.dash.on("error",this.props.onError),parseInt(n)<3?this.dash.getDebug().setLogToBrowserConsole(!1):this.dash.updateSettings({debug:{logLevel:o.Debug.LOG_LEVEL_NONE}}),this.props.onLoaded()}),this.shouldUseFLV(e)&&(0,a.getSDK)(K.replace("VERSION",l),G).then(o=>{this.flv=o.createPlayer({type:"flv",url:e}),this.flv.attachMediaElement(this.player),this.flv.on(o.Events.ERROR,(h,p)=>{this.props.onError(h,p,this.flv,o)}),this.flv.load(),this.props.onLoaded()}),e instanceof Array)this.player.load();else if((0,a.isMediaStream)(e))try{this.player.srcObject=e}catch{this.player.src=window.URL.createObjectURL(e)}}play(){const e=this.player.play();e&&e.catch(this.props.onError)}pause(){this.player.pause()}stop(){this.player.removeAttribute("src"),this.dash&&this.dash.reset()}seekTo(e,t=!0){this.player.currentTime=e,t||this.pause()}setVolume(e){this.player.volume=e}enablePIP(){this.player.requestPictureInPicture&&document.pictureInPictureElement!==this.player?this.player.requestPictureInPicture():(0,a.supportsWebKitPresentationMode)(this.player)&&this.player.webkitPresentationMode!=="picture-in-picture"&&this.player.webkitSetPresentationMode("picture-in-picture")}disablePIP(){document.exitPictureInPicture&&document.pictureInPictureElement===this.player?document.exitPictureInPicture():(0,a.supportsWebKitPresentationMode)(this.player)&&this.player.webkitPresentationMode!=="inline"&&this.player.webkitSetPresentationMode("inline")}setPlaybackRate(e){try{this.player.playbackRate=e}catch(t){this.props.onError(t)}}getDuration(){if(!this.player)return null;const{duration:e,seekable:t}=this.player;return e===1/0&&t.length>0?t.end(t.length-1):e}getCurrentTime(){return this.player?this.player.currentTime:null}getSecondsLoaded(){if(!this.player)return null;const{buffered:e}=this.player;if(e.length===0)return 0;const t=e.end(e.length-1),i=this.getDuration();return t>i?i:t}getSource(e){const t=this.shouldUseHLS(e),i=this.shouldUseDASH(e),n=this.shouldUseFLV(e);if(!(e instanceof Array||(0,a.isMediaStream)(e)||t||i||n))return X.test(e)?e.replace("www.dropbox.com","dl.dropboxusercontent.com"):e}render(){const{url:e,playing:t,loop:i,controls:n,muted:l,config:o,width:h,height:p}=this.props,L=this.shouldUseAudio(this.props)?"audio":"video",S={width:h==="auto"?h:"100%",height:p==="auto"?p:"100%"};return c.default.createElement(L,{ref:this.ref,src:this.getSource(e),style:S,preload:"auto",autoPlay:t||void 0,controls:n,muted:l,loop:i,...o.attributes},e instanceof Array&&e.map(this.renderSourceElement),o.tracks.map(this.renderTrack))}}r(P,"displayName","FilePlayer");r(P,"canPlay",d.canPlay.file);const z=b(g),Q=R({__proto__:null,default:z},[g]);export{Q as F}; diff --git a/build/assets/Kaltura-890aa431.js b/build/assets/Kaltura-a5ccda38.js similarity index 95% rename from build/assets/Kaltura-890aa431.js rename to build/assets/Kaltura-a5ccda38.js index b7d9ec09d..c9b0426e9 100644 --- a/build/assets/Kaltura-890aa431.js +++ b/build/assets/Kaltura-a5ccda38.js @@ -1 +1 @@ -import{a9 as y,r as f}from"./index-4bb27744.js";import{u as _,p as m}from"./index-87de005d.js";function P(r,e){for(var t=0;to[a]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var g=Object.create,n=Object.defineProperty,b=Object.getOwnPropertyDescriptor,v=Object.getOwnPropertyNames,O=Object.getPrototypeOf,w=Object.prototype.hasOwnProperty,j=(r,e,t)=>e in r?n(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,L=(r,e)=>{for(var t in e)n(r,t,{get:e[t],enumerable:!0})},c=(r,e,t,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of v(e))!w.call(r,a)&&a!==t&&n(r,a,{get:()=>e[a],enumerable:!(o=b(e,a))||o.enumerable});return r},K=(r,e,t)=>(t=r!=null?g(O(r)):{},c(e||!r||!r.__esModule?n(t,"default",{value:r,enumerable:!0}):t,r)),D=r=>c(n({},"__esModule",{value:!0}),r),s=(r,e,t)=>(j(r,typeof e!="symbol"?e+"":e,t),t),h={};L(h,{default:()=>i});var d=D(h),u=K(f),p=_,S=m;const T="https://cdn.embed.ly/player-0.1.0.min.js",E="playerjs";class i extends u.Component{constructor(){super(...arguments),s(this,"callPlayer",p.callPlayer),s(this,"duration",null),s(this,"currentTime",null),s(this,"secondsLoaded",null),s(this,"mute",()=>{this.callPlayer("mute")}),s(this,"unmute",()=>{this.callPlayer("unmute")}),s(this,"ref",e=>{this.iframe=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){(0,p.getSDK)(T,E).then(t=>{this.iframe&&(this.player=new t.Player(this.iframe),this.player.on("ready",()=>{setTimeout(()=>{this.player.isReady=!0,this.player.setLoop(this.props.loop),this.props.muted&&this.player.mute(),this.addListeners(this.player,this.props),this.props.onReady()},500)}))},this.props.onError)}addListeners(e,t){e.on("play",t.onPlay),e.on("pause",t.onPause),e.on("ended",t.onEnded),e.on("error",t.onError),e.on("timeupdate",({duration:o,seconds:a})=>{this.duration=o,this.currentTime=a})}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,t=!0){this.callPlayer("setCurrentTime",e),t||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}setLoop(e){this.callPlayer("setLoop",e)}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return this.secondsLoaded}render(){const e={width:"100%",height:"100%"};return u.default.createElement("iframe",{ref:this.ref,src:this.props.url,frameBorder:"0",scrolling:"no",style:e,allow:"encrypted-media; autoplay; fullscreen;",referrerPolicy:"no-referrer-when-downgrade"})}}s(i,"displayName","Kaltura");s(i,"canPlay",S.canPlay.kaltura);const M=y(d),N=P({__proto__:null,default:M},[d]);export{N as K}; +import{a8 as y,r as f}from"./index-4e60c9e2.js";import{u as _,p as m}from"./index-a46872c4.js";function P(r,e){for(var t=0;to[a]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var g=Object.create,n=Object.defineProperty,b=Object.getOwnPropertyDescriptor,v=Object.getOwnPropertyNames,O=Object.getPrototypeOf,w=Object.prototype.hasOwnProperty,j=(r,e,t)=>e in r?n(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,L=(r,e)=>{for(var t in e)n(r,t,{get:e[t],enumerable:!0})},c=(r,e,t,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of v(e))!w.call(r,a)&&a!==t&&n(r,a,{get:()=>e[a],enumerable:!(o=b(e,a))||o.enumerable});return r},K=(r,e,t)=>(t=r!=null?g(O(r)):{},c(e||!r||!r.__esModule?n(t,"default",{value:r,enumerable:!0}):t,r)),D=r=>c(n({},"__esModule",{value:!0}),r),s=(r,e,t)=>(j(r,typeof e!="symbol"?e+"":e,t),t),h={};L(h,{default:()=>i});var d=D(h),u=K(f),p=_,S=m;const T="https://cdn.embed.ly/player-0.1.0.min.js",E="playerjs";class i extends u.Component{constructor(){super(...arguments),s(this,"callPlayer",p.callPlayer),s(this,"duration",null),s(this,"currentTime",null),s(this,"secondsLoaded",null),s(this,"mute",()=>{this.callPlayer("mute")}),s(this,"unmute",()=>{this.callPlayer("unmute")}),s(this,"ref",e=>{this.iframe=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){(0,p.getSDK)(T,E).then(t=>{this.iframe&&(this.player=new t.Player(this.iframe),this.player.on("ready",()=>{setTimeout(()=>{this.player.isReady=!0,this.player.setLoop(this.props.loop),this.props.muted&&this.player.mute(),this.addListeners(this.player,this.props),this.props.onReady()},500)}))},this.props.onError)}addListeners(e,t){e.on("play",t.onPlay),e.on("pause",t.onPause),e.on("ended",t.onEnded),e.on("error",t.onError),e.on("timeupdate",({duration:o,seconds:a})=>{this.duration=o,this.currentTime=a})}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,t=!0){this.callPlayer("setCurrentTime",e),t||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}setLoop(e){this.callPlayer("setLoop",e)}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return this.secondsLoaded}render(){const e={width:"100%",height:"100%"};return u.default.createElement("iframe",{ref:this.ref,src:this.props.url,frameBorder:"0",scrolling:"no",style:e,allow:"encrypted-media; autoplay; fullscreen;",referrerPolicy:"no-referrer-when-downgrade"})}}s(i,"displayName","Kaltura");s(i,"canPlay",S.canPlay.kaltura);const M=y(d),N=P({__proto__:null,default:M},[d]);export{N as K}; diff --git a/build/assets/Mixcloud-158f251f.js b/build/assets/Mixcloud-6647e53d.js similarity index 95% rename from build/assets/Mixcloud-158f251f.js rename to build/assets/Mixcloud-6647e53d.js index 7165bd919..e8b5df6fc 100644 --- a/build/assets/Mixcloud-158f251f.js +++ b/build/assets/Mixcloud-6647e53d.js @@ -1 +1 @@ -import{a9 as _,r as f}from"./index-4bb27744.js";import{u as m,p as g}from"./index-87de005d.js";function v(t,e){for(var r=0;rs[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var P=Object.create,i=Object.defineProperty,O=Object.getOwnPropertyDescriptor,b=Object.getOwnPropertyNames,M=Object.getPrototypeOf,w=Object.prototype.hasOwnProperty,x=(t,e,r)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,j=(t,e)=>{for(var r in e)i(t,r,{get:e[r],enumerable:!0})},c=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of b(e))!w.call(t,o)&&o!==r&&i(t,o,{get:()=>e[o],enumerable:!(s=O(e,o))||s.enumerable});return t},D=(t,e,r)=>(r=t!=null?P(M(t)):{},c(e||!t||!t.__esModule?i(r,"default",{value:t,enumerable:!0}):r,t)),S=t=>c(i({},"__esModule",{value:!0}),t),a=(t,e,r)=>(x(t,typeof e!="symbol"?e+"":e,r),r),d={};j(d,{default:()=>l});var h=S(d),u=D(f),p=m,y=g;const E="https://widget.mixcloud.com/media/js/widgetApi.js",L="Mixcloud";class l extends u.Component{constructor(){super(...arguments),a(this,"callPlayer",p.callPlayer),a(this,"duration",null),a(this,"currentTime",null),a(this,"secondsLoaded",null),a(this,"mute",()=>{}),a(this,"unmute",()=>{}),a(this,"ref",e=>{this.iframe=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){(0,p.getSDK)(E,L).then(r=>{this.player=r.PlayerWidget(this.iframe),this.player.ready.then(()=>{this.player.events.play.on(this.props.onPlay),this.player.events.pause.on(this.props.onPause),this.player.events.ended.on(this.props.onEnded),this.player.events.error.on(this.props.error),this.player.events.progress.on((s,o)=>{this.currentTime=s,this.duration=o}),this.props.onReady()})},this.props.onError)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return null}render(){const{url:e,config:r}=this.props,s=e.match(y.MATCH_URL_MIXCLOUD)[1],o={width:"100%",height:"100%"},n=(0,p.queryString)({...r.options,feed:`/${s}/`});return u.default.createElement("iframe",{key:s,ref:this.ref,style:o,src:`https://www.mixcloud.com/widget/iframe/?${n}`,frameBorder:"0",allow:"autoplay"})}}a(l,"displayName","Mixcloud");a(l,"canPlay",y.canPlay.mixcloud);a(l,"loopOnEnded",!0);const T=_(h),N=v({__proto__:null,default:T},[h]);export{N as M}; +import{a8 as _,r as f}from"./index-4e60c9e2.js";import{u as m,p as g}from"./index-a46872c4.js";function v(t,e){for(var r=0;rs[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var P=Object.create,i=Object.defineProperty,O=Object.getOwnPropertyDescriptor,b=Object.getOwnPropertyNames,M=Object.getPrototypeOf,w=Object.prototype.hasOwnProperty,x=(t,e,r)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,j=(t,e)=>{for(var r in e)i(t,r,{get:e[r],enumerable:!0})},c=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of b(e))!w.call(t,o)&&o!==r&&i(t,o,{get:()=>e[o],enumerable:!(s=O(e,o))||s.enumerable});return t},D=(t,e,r)=>(r=t!=null?P(M(t)):{},c(e||!t||!t.__esModule?i(r,"default",{value:t,enumerable:!0}):r,t)),S=t=>c(i({},"__esModule",{value:!0}),t),a=(t,e,r)=>(x(t,typeof e!="symbol"?e+"":e,r),r),d={};j(d,{default:()=>l});var h=S(d),u=D(f),p=m,y=g;const E="https://widget.mixcloud.com/media/js/widgetApi.js",L="Mixcloud";class l extends u.Component{constructor(){super(...arguments),a(this,"callPlayer",p.callPlayer),a(this,"duration",null),a(this,"currentTime",null),a(this,"secondsLoaded",null),a(this,"mute",()=>{}),a(this,"unmute",()=>{}),a(this,"ref",e=>{this.iframe=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){(0,p.getSDK)(E,L).then(r=>{this.player=r.PlayerWidget(this.iframe),this.player.ready.then(()=>{this.player.events.play.on(this.props.onPlay),this.player.events.pause.on(this.props.onPause),this.player.events.ended.on(this.props.onEnded),this.player.events.error.on(this.props.error),this.player.events.progress.on((s,o)=>{this.currentTime=s,this.duration=o}),this.props.onReady()})},this.props.onError)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return null}render(){const{url:e,config:r}=this.props,s=e.match(y.MATCH_URL_MIXCLOUD)[1],o={width:"100%",height:"100%"},n=(0,p.queryString)({...r.options,feed:`/${s}/`});return u.default.createElement("iframe",{key:s,ref:this.ref,style:o,src:`https://www.mixcloud.com/widget/iframe/?${n}`,frameBorder:"0",allow:"autoplay"})}}a(l,"displayName","Mixcloud");a(l,"canPlay",y.canPlay.mixcloud);a(l,"loopOnEnded",!0);const T=_(h),N=v({__proto__:null,default:T},[h]);export{N as M}; diff --git a/build/assets/Preview-ac92af9a.js b/build/assets/Preview-2ad93ee1.js similarity index 97% rename from build/assets/Preview-ac92af9a.js rename to build/assets/Preview-2ad93ee1.js index 9f3418a2d..c3e38b9f4 100644 --- a/build/assets/Preview-ac92af9a.js +++ b/build/assets/Preview-2ad93ee1.js @@ -1 +1 @@ -import{a9 as y,r as b}from"./index-4bb27744.js";function v(r,e){for(var t=0;tn[a]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var w=Object.create,i=Object.defineProperty,P=Object.getOwnPropertyDescriptor,O=Object.getOwnPropertyNames,x=Object.getPrototypeOf,I=Object.prototype.hasOwnProperty,j=(r,e,t)=>e in r?i(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,E=(r,e)=>{for(var t in e)i(r,t,{get:e[t],enumerable:!0})},h=(r,e,t,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of O(e))!I.call(r,a)&&a!==t&&i(r,a,{get:()=>e[a],enumerable:!(n=P(e,a))||n.enumerable});return r},S=(r,e,t)=>(t=r!=null?w(x(r)):{},h(e||!r||!r.__esModule?i(t,"default",{value:r,enumerable:!0}):t,r)),C=r=>h(i({},"__esModule",{value:!0}),r),p=(r,e,t)=>(j(r,typeof e!="symbol"?e+"":e,t),t),_={};E(_,{default:()=>N});var g=C(_),s=S(b);const u="64px",d={};class N extends s.Component{constructor(){super(...arguments),p(this,"mounted",!1),p(this,"state",{image:null}),p(this,"handleKeyPress",e=>{(e.key==="Enter"||e.key===" ")&&this.props.onClick()})}componentDidMount(){this.mounted=!0,this.fetchImage(this.props)}componentDidUpdate(e){const{url:t,light:n}=this.props;(e.url!==t||e.light!==n)&&this.fetchImage(this.props)}componentWillUnmount(){this.mounted=!1}fetchImage({url:e,light:t,oEmbedUrl:n}){if(!s.default.isValidElement(t)){if(typeof t=="string"){this.setState({image:t});return}if(d[e]){this.setState({image:d[e]});return}return this.setState({image:null}),window.fetch(n.replace("{url}",e)).then(a=>a.json()).then(a=>{if(a.thumbnail_url&&this.mounted){const o=a.thumbnail_url.replace("height=100","height=480").replace("-d_295x166","-d_640");this.setState({image:o}),d[e]=o}})}}render(){const{light:e,onClick:t,playIcon:n,previewTabIndex:a}=this.props,{image:o}=this.state,l=s.default.isValidElement(e),f={display:"flex",alignItems:"center",justifyContent:"center"},c={preview:{width:"100%",height:"100%",backgroundImage:o&&!l?`url(${o})`:void 0,backgroundSize:"cover",backgroundPosition:"center",cursor:"pointer",...f},shadow:{background:"radial-gradient(rgb(0, 0, 0, 0.3), rgba(0, 0, 0, 0) 60%)",borderRadius:u,width:u,height:u,position:l?"absolute":void 0,...f},playIcon:{borderStyle:"solid",borderWidth:"16px 0 16px 26px",borderColor:"transparent transparent transparent white",marginLeft:"7px"}},m=s.default.createElement("div",{style:c.shadow,className:"react-player__shadow"},s.default.createElement("div",{style:c.playIcon,className:"react-player__play-icon"}));return s.default.createElement("div",{style:c.preview,className:"react-player__preview",onClick:t,tabIndex:a,onKeyPress:this.handleKeyPress},l?e:null,n||m)}}const k=y(g),M=v({__proto__:null,default:k},[g]);export{M as P}; +import{a8 as y,r as b}from"./index-4e60c9e2.js";function v(r,e){for(var t=0;tn[a]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var w=Object.create,i=Object.defineProperty,P=Object.getOwnPropertyDescriptor,O=Object.getOwnPropertyNames,x=Object.getPrototypeOf,I=Object.prototype.hasOwnProperty,j=(r,e,t)=>e in r?i(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,E=(r,e)=>{for(var t in e)i(r,t,{get:e[t],enumerable:!0})},h=(r,e,t,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of O(e))!I.call(r,a)&&a!==t&&i(r,a,{get:()=>e[a],enumerable:!(n=P(e,a))||n.enumerable});return r},S=(r,e,t)=>(t=r!=null?w(x(r)):{},h(e||!r||!r.__esModule?i(t,"default",{value:r,enumerable:!0}):t,r)),C=r=>h(i({},"__esModule",{value:!0}),r),p=(r,e,t)=>(j(r,typeof e!="symbol"?e+"":e,t),t),_={};E(_,{default:()=>N});var g=C(_),s=S(b);const u="64px",d={};class N extends s.Component{constructor(){super(...arguments),p(this,"mounted",!1),p(this,"state",{image:null}),p(this,"handleKeyPress",e=>{(e.key==="Enter"||e.key===" ")&&this.props.onClick()})}componentDidMount(){this.mounted=!0,this.fetchImage(this.props)}componentDidUpdate(e){const{url:t,light:n}=this.props;(e.url!==t||e.light!==n)&&this.fetchImage(this.props)}componentWillUnmount(){this.mounted=!1}fetchImage({url:e,light:t,oEmbedUrl:n}){if(!s.default.isValidElement(t)){if(typeof t=="string"){this.setState({image:t});return}if(d[e]){this.setState({image:d[e]});return}return this.setState({image:null}),window.fetch(n.replace("{url}",e)).then(a=>a.json()).then(a=>{if(a.thumbnail_url&&this.mounted){const o=a.thumbnail_url.replace("height=100","height=480").replace("-d_295x166","-d_640");this.setState({image:o}),d[e]=o}})}}render(){const{light:e,onClick:t,playIcon:n,previewTabIndex:a}=this.props,{image:o}=this.state,l=s.default.isValidElement(e),f={display:"flex",alignItems:"center",justifyContent:"center"},c={preview:{width:"100%",height:"100%",backgroundImage:o&&!l?`url(${o})`:void 0,backgroundSize:"cover",backgroundPosition:"center",cursor:"pointer",...f},shadow:{background:"radial-gradient(rgb(0, 0, 0, 0.3), rgba(0, 0, 0, 0) 60%)",borderRadius:u,width:u,height:u,position:l?"absolute":void 0,...f},playIcon:{borderStyle:"solid",borderWidth:"16px 0 16px 26px",borderColor:"transparent transparent transparent white",marginLeft:"7px"}},m=s.default.createElement("div",{style:c.shadow,className:"react-player__shadow"},s.default.createElement("div",{style:c.playIcon,className:"react-player__play-icon"}));return s.default.createElement("div",{style:c.preview,className:"react-player__preview",onClick:t,tabIndex:a,onKeyPress:this.handleKeyPress},l?e:null,n||m)}}const k=y(g),M=v({__proto__:null,default:k},[g]);export{M as P}; diff --git a/build/assets/Skeleton-dbbfd404.js b/build/assets/Skeleton-7af13a79.js similarity index 72% rename from build/assets/Skeleton-dbbfd404.js rename to build/assets/Skeleton-7af13a79.js index b445c4b97..a8f55d835 100644 --- a/build/assets/Skeleton-dbbfd404.js +++ b/build/assets/Skeleton-7af13a79.js @@ -1,4 +1,4 @@ -import{L as x,M as y,bz as b,N as R,O as o,P as S,bA as u,r as _,S as U,H as $,j as M,U as A,V as j}from"./index-4bb27744.js";function N(t){return String(t).match(/[\d.\-+]*\s*(.*)/)[1]||""}function X(t){return parseFloat(t)}function P(t){return x("MuiSkeleton",t)}y("MuiSkeleton",["root","text","rectangular","rounded","circular","pulse","wave","withChildren","fitContent","heightAuto"]);const B=["animation","className","component","height","style","variant","width"];let r=t=>t,p,g,m,f;const E=t=>{const{classes:a,variant:e,animation:i,hasChildren:n,width:l,height:s}=t;return j({root:["root",e,i,n&&"withChildren",n&&!l&&"fitContent",n&&!s&&"heightAuto"]},P,a)},F=b(p||(p=r` +import{K as w,L as x,by as b,M as R,N as o,O as S,bz as u,r as _,P as U,G as $,j as M,S as j,U as A}from"./index-4e60c9e2.js";function N(t){return String(t).match(/[\d.\-+]*\s*(.*)/)[1]||""}function X(t){return parseFloat(t)}function K(t){return w("MuiSkeleton",t)}x("MuiSkeleton",["root","text","rectangular","rounded","circular","pulse","wave","withChildren","fitContent","heightAuto"]);const P=["animation","className","component","height","style","variant","width"];let r=t=>t,p,g,m,f;const B=t=>{const{classes:a,variant:e,animation:i,hasChildren:n,width:l,height:s}=t;return A({root:["root",e,i,n&&"withChildren",n&&!l&&"fitContent",n&&!s&&"heightAuto"]},K,a)},E=b(p||(p=r` 0% { opacity: 1; } @@ -10,7 +10,7 @@ import{L as x,M as y,bz as b,N as R,O as o,P as S,bA as u,r as _,S as U,H as $,j 100% { opacity: 1; } -`)),K=b(g||(g=r` +`)),F=b(g||(g=r` 0% { transform: translateX(-100%); } @@ -25,7 +25,7 @@ import{L as x,M as y,bz as b,N as R,O as o,P as S,bA as u,r as _,S as U,H as $,j } `)),L=R("span",{name:"MuiSkeleton",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:e}=t;return[a.root,a[e.variant],e.animation!==!1&&a[e.animation],e.hasChildren&&a.withChildren,e.hasChildren&&!e.width&&a.fitContent,e.hasChildren&&!e.height&&a.heightAuto]}})(({theme:t,ownerState:a})=>{const e=N(t.shape.borderRadius)||"px",i=X(t.shape.borderRadius);return o({display:"block",backgroundColor:t.vars?t.vars.palette.Skeleton.bg:S(t.palette.text.primary,t.palette.mode==="light"?.11:.13),height:"1.2em"},a.variant==="text"&&{marginTop:0,marginBottom:0,height:"auto",transformOrigin:"0 55%",transform:"scale(1, 0.60)",borderRadius:`${i}${e}/${Math.round(i/.6*10)/10}${e}`,"&:empty:before":{content:'"\\00a0"'}},a.variant==="circular"&&{borderRadius:"50%"},a.variant==="rounded"&&{borderRadius:(t.vars||t).shape.borderRadius},a.hasChildren&&{"& > *":{visibility:"hidden"}},a.hasChildren&&!a.width&&{maxWidth:"fit-content"},a.hasChildren&&!a.height&&{height:"auto"})},({ownerState:t})=>t.animation==="pulse"&&u(m||(m=r` animation: ${0} 2s ease-in-out 0.5s infinite; - `),F),({ownerState:t,theme:a})=>t.animation==="wave"&&u(f||(f=r` + `),E),({ownerState:t,theme:a})=>t.animation==="wave"&&u(f||(f=r` position: relative; overflow: hidden; @@ -48,4 +48,4 @@ import{L as x,M as y,bz as b,N as R,O as o,P as S,bA as u,r as _,S as U,H as $,j right: 0; top: 0; } - `),K,(a.vars||a).palette.action.hover)),O=_.forwardRef(function(a,e){const i=U({props:a,name:"MuiSkeleton"}),{animation:n="pulse",className:l,component:s="span",height:h,style:v,variant:C="text",width:k}=i,d=$(i,B),c=o({},i,{animation:n,component:s,variant:C,hasChildren:!!d.children}),w=E(c);return M.jsx(L,o({as:s,ref:e,className:A(w.root,l),ownerState:c},d,{style:o({width:k,height:h},v)}))}),V=O;export{V as S}; + `),F,(a.vars||a).palette.action.hover)),O=_.forwardRef(function(a,e){const i=U({props:a,name:"MuiSkeleton"}),{animation:n="pulse",className:l,component:s="span",height:h,style:v,variant:C="text",width:k}=i,d=$(i,P),c=o({},i,{animation:n,component:s,variant:C,hasChildren:!!d.children}),y=B(c);return M.jsx(L,o({as:s,ref:e,className:j(y.root,l),ownerState:c},d,{style:o({width:k,height:h},v)}))}),W=O;export{W as S}; diff --git a/build/assets/SoundCloud-cb3d2c50.js b/build/assets/SoundCloud-b012eb42.js similarity index 95% rename from build/assets/SoundCloud-cb3d2c50.js rename to build/assets/SoundCloud-b012eb42.js index 58e21f7c4..7857f8bed 100644 --- a/build/assets/SoundCloud-cb3d2c50.js +++ b/build/assets/SoundCloud-b012eb42.js @@ -1 +1 @@ -import{a9 as P,r as g}from"./index-4bb27744.js";import{u as b,p as v}from"./index-87de005d.js";function O(t,e){for(var r=0;rs[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var S=Object.create,l=Object.defineProperty,w=Object.getOwnPropertyDescriptor,j=Object.getOwnPropertyNames,C=Object.getPrototypeOf,E=Object.prototype.hasOwnProperty,D=(t,e,r)=>e in t?l(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,L=(t,e)=>{for(var r in e)l(t,r,{get:e[r],enumerable:!0})},d=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of j(e))!E.call(t,o)&&o!==r&&l(t,o,{get:()=>e[o],enumerable:!(s=w(e,o))||s.enumerable});return t},R=(t,e,r)=>(r=t!=null?S(C(t)):{},d(e||!t||!t.__esModule?l(r,"default",{value:t,enumerable:!0}):r,t)),T=t=>d(l({},"__esModule",{value:!0}),t),a=(t,e,r)=>(D(t,typeof e!="symbol"?e+"":e,r),r),h={};L(h,{default:()=>u});var f=T(h),p=R(g),c=b,M=v;const x="https://w.soundcloud.com/player/api.js",A="SC";class u extends p.Component{constructor(){super(...arguments),a(this,"callPlayer",c.callPlayer),a(this,"duration",null),a(this,"currentTime",null),a(this,"fractionLoaded",null),a(this,"mute",()=>{this.setVolume(0)}),a(this,"unmute",()=>{this.props.volume!==null&&this.setVolume(this.props.volume)}),a(this,"ref",e=>{this.iframe=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e,r){(0,c.getSDK)(x,A).then(s=>{if(!this.iframe)return;const{PLAY:o,PLAY_PROGRESS:i,PAUSE:y,FINISH:_,ERROR:m}=s.Widget.Events;r||(this.player=s.Widget(this.iframe),this.player.bind(o,this.props.onPlay),this.player.bind(y,()=>{this.duration-this.currentTime<.05||this.props.onPause()}),this.player.bind(i,n=>{this.currentTime=n.currentPosition/1e3,this.fractionLoaded=n.loadedProgress}),this.player.bind(_,()=>this.props.onEnded()),this.player.bind(m,n=>this.props.onError(n))),this.player.load(e,{...this.props.config.options,callback:()=>{this.player.getDuration(n=>{this.duration=n/1e3,this.props.onReady()})}})})}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("seekTo",e*1e3),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e*100)}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return this.fractionLoaded*this.duration}render(){const{display:e}=this.props,r={width:"100%",height:"100%",display:e};return p.default.createElement("iframe",{ref:this.ref,src:`https://w.soundcloud.com/player/?url=${encodeURIComponent(this.props.url)}`,style:r,frameBorder:0,allow:"autoplay"})}}a(u,"displayName","SoundCloud");a(u,"canPlay",M.canPlay.soundcloud);a(u,"loopOnEnded",!0);const N=P(f),I=O({__proto__:null,default:N},[f]);export{I as S}; +import{a8 as P,r as g}from"./index-4e60c9e2.js";import{u as b,p as v}from"./index-a46872c4.js";function O(t,e){for(var r=0;rs[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var S=Object.create,l=Object.defineProperty,w=Object.getOwnPropertyDescriptor,j=Object.getOwnPropertyNames,C=Object.getPrototypeOf,E=Object.prototype.hasOwnProperty,D=(t,e,r)=>e in t?l(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,L=(t,e)=>{for(var r in e)l(t,r,{get:e[r],enumerable:!0})},d=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of j(e))!E.call(t,o)&&o!==r&&l(t,o,{get:()=>e[o],enumerable:!(s=w(e,o))||s.enumerable});return t},R=(t,e,r)=>(r=t!=null?S(C(t)):{},d(e||!t||!t.__esModule?l(r,"default",{value:t,enumerable:!0}):r,t)),T=t=>d(l({},"__esModule",{value:!0}),t),a=(t,e,r)=>(D(t,typeof e!="symbol"?e+"":e,r),r),h={};L(h,{default:()=>u});var f=T(h),p=R(g),c=b,M=v;const x="https://w.soundcloud.com/player/api.js",A="SC";class u extends p.Component{constructor(){super(...arguments),a(this,"callPlayer",c.callPlayer),a(this,"duration",null),a(this,"currentTime",null),a(this,"fractionLoaded",null),a(this,"mute",()=>{this.setVolume(0)}),a(this,"unmute",()=>{this.props.volume!==null&&this.setVolume(this.props.volume)}),a(this,"ref",e=>{this.iframe=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e,r){(0,c.getSDK)(x,A).then(s=>{if(!this.iframe)return;const{PLAY:o,PLAY_PROGRESS:i,PAUSE:y,FINISH:_,ERROR:m}=s.Widget.Events;r||(this.player=s.Widget(this.iframe),this.player.bind(o,this.props.onPlay),this.player.bind(y,()=>{this.duration-this.currentTime<.05||this.props.onPause()}),this.player.bind(i,n=>{this.currentTime=n.currentPosition/1e3,this.fractionLoaded=n.loadedProgress}),this.player.bind(_,()=>this.props.onEnded()),this.player.bind(m,n=>this.props.onError(n))),this.player.load(e,{...this.props.config.options,callback:()=>{this.player.getDuration(n=>{this.duration=n/1e3,this.props.onReady()})}})})}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("seekTo",e*1e3),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e*100)}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return this.fractionLoaded*this.duration}render(){const{display:e}=this.props,r={width:"100%",height:"100%",display:e};return p.default.createElement("iframe",{ref:this.ref,src:`https://w.soundcloud.com/player/?url=${encodeURIComponent(this.props.url)}`,style:r,frameBorder:0,allow:"autoplay"})}}a(u,"displayName","SoundCloud");a(u,"canPlay",M.canPlay.soundcloud);a(u,"loopOnEnded",!0);const N=P(f),I=O({__proto__:null,default:N},[f]);export{I as S}; diff --git a/build/assets/Stack-6038813c.js b/build/assets/Stack-5870980a.js similarity index 63% rename from build/assets/Stack-6038813c.js rename to build/assets/Stack-5870980a.js index eef2d0921..c0f70cbeb 100644 --- a/build/assets/Stack-6038813c.js +++ b/build/assets/Stack-5870980a.js @@ -1 +1 @@ -import{r as E,a8 as Bt,H as ae,O as T,c6 as Ft,c7 as Wt,c8 as Vt,c9 as Lt,ca as Nt,bD as Je,bC as Ae,cb as Ht,c5 as It,cc as Ut,j as J,cd as Ke,V as ke,L as Te,M as ht,Z as et,$ as tt,N as Me,ce as qt,S as Be,Y as gt,U as zt}from"./index-4bb27744.js";import{w as rt,aN as Xt,Q as Yt}from"./index-7730ff6f.js";function Se(e,t){var r,o;return E.isValidElement(e)&&t.indexOf((r=e.type.muiName)!=null?r:(o=e.type)==null||(o=o._payload)==null||(o=o.value)==null?void 0:o.muiName)!==-1}let ot=0;function Gt(e){const[t,r]=E.useState(e),o=e||t;return E.useEffect(()=>{t==null&&(ot+=1,r(`mui-${ot}`))},[t]),o}const nt=Bt["useId".toString()];function Ho(e){if(nt!==void 0){const t=nt();return e??t}return Gt(e)}function Io({controlled:e,default:t,name:r,state:o="value"}){const{current:n}=E.useRef(e!==void 0),[a,c]=E.useState(t),s=n?e:a,i=E.useCallback(f=>{n||c(f)},[]);return[s,i]}const _t=["sx"],Qt=e=>{var t,r;const o={systemProps:{},otherProps:{}},n=(t=e==null||(r=e.theme)==null?void 0:r.unstable_sxConfig)!=null?t:Ft;return Object.keys(e).forEach(a=>{n[a]?o.systemProps[a]=e[a]:o.otherProps[a]=e[a]}),o};function Zt(e){const{sx:t}=e,r=ae(e,_t),{systemProps:o,otherProps:n}=Qt(r);let a;return Array.isArray(t)?a=[o,...t]:typeof t=="function"?a=(...c)=>{const s=t(...c);return Wt(s)?T({},o,s):o}:a=T({},o,t),T({},n,{sx:a})}function yt(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;tt.root});function nr(e){return Nt({props:e,name:"MuiStack",defaultTheme:rr})}function ar(e,t){const r=E.Children.toArray(e).filter(Boolean);return r.reduce((o,n,a)=>(o.push(n),a({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"})[e],sr=({ownerState:e,theme:t})=>{let r=T({display:"flex",flexDirection:"column"},Je({theme:t},Ae({values:e.direction,breakpoints:t.breakpoints.values}),o=>({flexDirection:o})));if(e.spacing){const o=Ht(t),n=Object.keys(t.breakpoints.values).reduce((i,f)=>((typeof e.spacing=="object"&&e.spacing[f]!=null||typeof e.direction=="object"&&e.direction[f]!=null)&&(i[f]=!0),i),{}),a=Ae({values:e.direction,base:n}),c=Ae({values:e.spacing,base:n});typeof a=="object"&&Object.keys(a).forEach((i,f,l)=>{if(!a[i]){const h=f>0?a[l[f-1]]:"column";a[i]=h}}),r=It(r,Je({theme:t},c,(i,f)=>e.useFlexGap?{gap:Ke(o,i)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${ir(f?a[f]:e.direction)}`]:Ke(o,i)}}))}return r=Ut(t.breakpoints,r),r};function lr(e={}){const{createStyledComponent:t=or,useThemeProps:r=nr,componentName:o="MuiStack"}=e,n=()=>ke({root:["root"]},i=>Te(o,i),{}),a=t(sr);return E.forwardRef(function(i,f){const l=r(i),v=Zt(l),{component:h="div",direction:p="column",spacing:x=0,divider:d,children:m,className:w,useFlexGap:P=!1}=v,b=ae(v,tr),u={direction:p,spacing:x,useFlexGap:P},g=n();return J.jsx(a,T({as:h,ownerState:u,ref:f,className:Jt(g.root,w)},b,{children:d?ar(m,d):m}))})}const cr={disableDefaultClasses:!1},fr=E.createContext(cr);function ur(e){const{disableDefaultClasses:t}=E.useContext(fr);return r=>t?"":e(r)}var B="top",N="bottom",H="right",F="left",Fe="auto",de=[B,N,H,F],te="start",ue="end",pr="clippingParents",bt="viewport",le="popper",dr="reference",at=de.reduce(function(e,t){return e.concat([t+"-"+te,t+"-"+ue])},[]),xt=[].concat(de,[Fe]).reduce(function(e,t){return e.concat([t,t+"-"+te,t+"-"+ue])},[]),vr="beforeRead",mr="read",hr="afterRead",gr="beforeMain",yr="main",br="afterMain",xr="beforeWrite",wr="write",Or="afterWrite",Pr=[vr,mr,hr,gr,yr,br,xr,wr,Or];function U(e){return e?(e.nodeName||"").toLowerCase():null}function W(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function K(e){var t=W(e).Element;return e instanceof t||e instanceof Element}function L(e){var t=W(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function We(e){if(typeof ShadowRoot>"u")return!1;var t=W(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Er(e){var t=e.state;Object.keys(t.elements).forEach(function(r){var o=t.styles[r]||{},n=t.attributes[r]||{},a=t.elements[r];!L(a)||!U(a)||(Object.assign(a.style,o),Object.keys(n).forEach(function(c){var s=n[c];s===!1?a.removeAttribute(c):a.setAttribute(c,s===!0?"":s)}))})}function Cr(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(o){var n=t.elements[o],a=t.attributes[o]||{},c=Object.keys(t.styles.hasOwnProperty(o)?t.styles[o]:r[o]),s=c.reduce(function(i,f){return i[f]="",i},{});!L(n)||!U(n)||(Object.assign(n.style,s),Object.keys(a).forEach(function(i){n.removeAttribute(i)}))})}}const Rr={name:"applyStyles",enabled:!0,phase:"write",fn:Er,effect:Cr,requires:["computeStyles"]};function I(e){return e.split("-")[0]}var Z=Math.max,we=Math.min,re=Math.round;function $e(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function wt(){return!/^((?!chrome|android).)*safari/i.test($e())}function oe(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var o=e.getBoundingClientRect(),n=1,a=1;t&&L(e)&&(n=e.offsetWidth>0&&re(o.width)/e.offsetWidth||1,a=e.offsetHeight>0&&re(o.height)/e.offsetHeight||1);var c=K(e)?W(e):window,s=c.visualViewport,i=!wt()&&r,f=(o.left+(i&&s?s.offsetLeft:0))/n,l=(o.top+(i&&s?s.offsetTop:0))/a,v=o.width/n,h=o.height/a;return{width:v,height:h,top:l,right:f+v,bottom:l+h,left:f,x:f,y:l}}function Ve(e){var t=oe(e),r=e.offsetWidth,o=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-o)<=1&&(o=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:o}}function Ot(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&We(r)){var o=t;do{if(o&&e.isSameNode(o))return!0;o=o.parentNode||o.host}while(o)}return!1}function q(e){return W(e).getComputedStyle(e)}function Ar(e){return["table","td","th"].indexOf(U(e))>=0}function Y(e){return((K(e)?e.ownerDocument:e.document)||window.document).documentElement}function Oe(e){return U(e)==="html"?e:e.assignedSlot||e.parentNode||(We(e)?e.host:null)||Y(e)}function it(e){return!L(e)||q(e).position==="fixed"?null:e.offsetParent}function Sr(e){var t=/firefox/i.test($e()),r=/Trident/i.test($e());if(r&&L(e)){var o=q(e);if(o.position==="fixed")return null}var n=Oe(e);for(We(n)&&(n=n.host);L(n)&&["html","body"].indexOf(U(n))<0;){var a=q(n);if(a.transform!=="none"||a.perspective!=="none"||a.contain==="paint"||["transform","perspective"].indexOf(a.willChange)!==-1||t&&a.willChange==="filter"||t&&a.filter&&a.filter!=="none")return n;n=n.parentNode}return null}function ve(e){for(var t=W(e),r=it(e);r&&Ar(r)&&q(r).position==="static";)r=it(r);return r&&(U(r)==="html"||U(r)==="body"&&q(r).position==="static")?t:r||Sr(e)||t}function Le(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function ce(e,t,r){return Z(e,we(t,r))}function $r(e,t,r){var o=ce(e,t,r);return o>r?r:o}function Pt(){return{top:0,right:0,bottom:0,left:0}}function Et(e){return Object.assign({},Pt(),e)}function Ct(e,t){return t.reduce(function(r,o){return r[o]=e,r},{})}var Dr=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,Et(typeof t!="number"?t:Ct(t,de))};function jr(e){var t,r=e.state,o=e.name,n=e.options,a=r.elements.arrow,c=r.modifiersData.popperOffsets,s=I(r.placement),i=Le(s),f=[F,H].indexOf(s)>=0,l=f?"height":"width";if(!(!a||!c)){var v=Dr(n.padding,r),h=Ve(a),p=i==="y"?B:F,x=i==="y"?N:H,d=r.rects.reference[l]+r.rects.reference[i]-c[i]-r.rects.popper[l],m=c[i]-r.rects.reference[i],w=ve(a),P=w?i==="y"?w.clientHeight||0:w.clientWidth||0:0,b=d/2-m/2,u=v[p],g=P-h[l]-v[x],y=P/2-h[l]/2+b,O=ce(u,y,g),A=i;r.modifiersData[o]=(t={},t[A]=O,t.centerOffset=O-y,t)}}function kr(e){var t=e.state,r=e.options,o=r.element,n=o===void 0?"[data-popper-arrow]":o;n!=null&&(typeof n=="string"&&(n=t.elements.popper.querySelector(n),!n)||Ot(t.elements.popper,n)&&(t.elements.arrow=n))}const Tr={name:"arrow",enabled:!0,phase:"main",fn:jr,effect:kr,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ne(e){return e.split("-")[1]}var Mr={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Br(e,t){var r=e.x,o=e.y,n=t.devicePixelRatio||1;return{x:re(r*n)/n||0,y:re(o*n)/n||0}}function st(e){var t,r=e.popper,o=e.popperRect,n=e.placement,a=e.variation,c=e.offsets,s=e.position,i=e.gpuAcceleration,f=e.adaptive,l=e.roundOffsets,v=e.isFixed,h=c.x,p=h===void 0?0:h,x=c.y,d=x===void 0?0:x,m=typeof l=="function"?l({x:p,y:d}):{x:p,y:d};p=m.x,d=m.y;var w=c.hasOwnProperty("x"),P=c.hasOwnProperty("y"),b=F,u=B,g=window;if(f){var y=ve(r),O="clientHeight",A="clientWidth";if(y===W(r)&&(y=Y(r),q(y).position!=="static"&&s==="absolute"&&(O="scrollHeight",A="scrollWidth")),y=y,n===B||(n===F||n===H)&&a===ue){u=N;var C=v&&y===g&&g.visualViewport?g.visualViewport.height:y[O];d-=C-o.height,d*=i?1:-1}if(n===F||(n===B||n===N)&&a===ue){b=H;var R=v&&y===g&&g.visualViewport?g.visualViewport.width:y[A];p-=R-o.width,p*=i?1:-1}}var $=Object.assign({position:s},f&&Mr),k=l===!0?Br({x:p,y:d},W(r)):{x:p,y:d};if(p=k.x,d=k.y,i){var S;return Object.assign({},$,(S={},S[u]=P?"0":"",S[b]=w?"0":"",S.transform=(g.devicePixelRatio||1)<=1?"translate("+p+"px, "+d+"px)":"translate3d("+p+"px, "+d+"px, 0)",S))}return Object.assign({},$,(t={},t[u]=P?d+"px":"",t[b]=w?p+"px":"",t.transform="",t))}function Fr(e){var t=e.state,r=e.options,o=r.gpuAcceleration,n=o===void 0?!0:o,a=r.adaptive,c=a===void 0?!0:a,s=r.roundOffsets,i=s===void 0?!0:s,f={placement:I(t.placement),variation:ne(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:n,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,st(Object.assign({},f,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:c,roundOffsets:i})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,st(Object.assign({},f,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:i})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Wr={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Fr,data:{}};var be={passive:!0};function Vr(e){var t=e.state,r=e.instance,o=e.options,n=o.scroll,a=n===void 0?!0:n,c=o.resize,s=c===void 0?!0:c,i=W(t.elements.popper),f=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&f.forEach(function(l){l.addEventListener("scroll",r.update,be)}),s&&i.addEventListener("resize",r.update,be),function(){a&&f.forEach(function(l){l.removeEventListener("scroll",r.update,be)}),s&&i.removeEventListener("resize",r.update,be)}}const Lr={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Vr,data:{}};var Nr={left:"right",right:"left",bottom:"top",top:"bottom"};function xe(e){return e.replace(/left|right|bottom|top/g,function(t){return Nr[t]})}var Hr={start:"end",end:"start"};function lt(e){return e.replace(/start|end/g,function(t){return Hr[t]})}function Ne(e){var t=W(e),r=t.pageXOffset,o=t.pageYOffset;return{scrollLeft:r,scrollTop:o}}function He(e){return oe(Y(e)).left+Ne(e).scrollLeft}function Ir(e,t){var r=W(e),o=Y(e),n=r.visualViewport,a=o.clientWidth,c=o.clientHeight,s=0,i=0;if(n){a=n.width,c=n.height;var f=wt();(f||!f&&t==="fixed")&&(s=n.offsetLeft,i=n.offsetTop)}return{width:a,height:c,x:s+He(e),y:i}}function Ur(e){var t,r=Y(e),o=Ne(e),n=(t=e.ownerDocument)==null?void 0:t.body,a=Z(r.scrollWidth,r.clientWidth,n?n.scrollWidth:0,n?n.clientWidth:0),c=Z(r.scrollHeight,r.clientHeight,n?n.scrollHeight:0,n?n.clientHeight:0),s=-o.scrollLeft+He(e),i=-o.scrollTop;return q(n||r).direction==="rtl"&&(s+=Z(r.clientWidth,n?n.clientWidth:0)-a),{width:a,height:c,x:s,y:i}}function Ie(e){var t=q(e),r=t.overflow,o=t.overflowX,n=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+n+o)}function Rt(e){return["html","body","#document"].indexOf(U(e))>=0?e.ownerDocument.body:L(e)&&Ie(e)?e:Rt(Oe(e))}function fe(e,t){var r;t===void 0&&(t=[]);var o=Rt(e),n=o===((r=e.ownerDocument)==null?void 0:r.body),a=W(o),c=n?[a].concat(a.visualViewport||[],Ie(o)?o:[]):o,s=t.concat(c);return n?s:s.concat(fe(Oe(c)))}function De(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function qr(e,t){var r=oe(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function ct(e,t,r){return t===bt?De(Ir(e,r)):K(t)?qr(t,r):De(Ur(Y(e)))}function zr(e){var t=fe(Oe(e)),r=["absolute","fixed"].indexOf(q(e).position)>=0,o=r&&L(e)?ve(e):e;return K(o)?t.filter(function(n){return K(n)&&Ot(n,o)&&U(n)!=="body"}):[]}function Xr(e,t,r,o){var n=t==="clippingParents"?zr(e):[].concat(t),a=[].concat(n,[r]),c=a[0],s=a.reduce(function(i,f){var l=ct(e,f,o);return i.top=Z(l.top,i.top),i.right=we(l.right,i.right),i.bottom=we(l.bottom,i.bottom),i.left=Z(l.left,i.left),i},ct(e,c,o));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function At(e){var t=e.reference,r=e.element,o=e.placement,n=o?I(o):null,a=o?ne(o):null,c=t.x+t.width/2-r.width/2,s=t.y+t.height/2-r.height/2,i;switch(n){case B:i={x:c,y:t.y-r.height};break;case N:i={x:c,y:t.y+t.height};break;case H:i={x:t.x+t.width,y:s};break;case F:i={x:t.x-r.width,y:s};break;default:i={x:t.x,y:t.y}}var f=n?Le(n):null;if(f!=null){var l=f==="y"?"height":"width";switch(a){case te:i[f]=i[f]-(t[l]/2-r[l]/2);break;case ue:i[f]=i[f]+(t[l]/2-r[l]/2);break}}return i}function pe(e,t){t===void 0&&(t={});var r=t,o=r.placement,n=o===void 0?e.placement:o,a=r.strategy,c=a===void 0?e.strategy:a,s=r.boundary,i=s===void 0?pr:s,f=r.rootBoundary,l=f===void 0?bt:f,v=r.elementContext,h=v===void 0?le:v,p=r.altBoundary,x=p===void 0?!1:p,d=r.padding,m=d===void 0?0:d,w=Et(typeof m!="number"?m:Ct(m,de)),P=h===le?dr:le,b=e.rects.popper,u=e.elements[x?P:h],g=Xr(K(u)?u:u.contextElement||Y(e.elements.popper),i,l,c),y=oe(e.elements.reference),O=At({reference:y,element:b,strategy:"absolute",placement:n}),A=De(Object.assign({},b,O)),C=h===le?A:y,R={top:g.top-C.top+w.top,bottom:C.bottom-g.bottom+w.bottom,left:g.left-C.left+w.left,right:C.right-g.right+w.right},$=e.modifiersData.offset;if(h===le&&$){var k=$[n];Object.keys(R).forEach(function(S){var j=[H,N].indexOf(S)>=0?1:-1,V=[B,N].indexOf(S)>=0?"y":"x";R[S]+=k[V]*j})}return R}function Yr(e,t){t===void 0&&(t={});var r=t,o=r.placement,n=r.boundary,a=r.rootBoundary,c=r.padding,s=r.flipVariations,i=r.allowedAutoPlacements,f=i===void 0?xt:i,l=ne(o),v=l?s?at:at.filter(function(x){return ne(x)===l}):de,h=v.filter(function(x){return f.indexOf(x)>=0});h.length===0&&(h=v);var p=h.reduce(function(x,d){return x[d]=pe(e,{placement:d,boundary:n,rootBoundary:a,padding:c})[I(d)],x},{});return Object.keys(p).sort(function(x,d){return p[x]-p[d]})}function Gr(e){if(I(e)===Fe)return[];var t=xe(e);return[lt(e),t,lt(t)]}function _r(e){var t=e.state,r=e.options,o=e.name;if(!t.modifiersData[o]._skip){for(var n=r.mainAxis,a=n===void 0?!0:n,c=r.altAxis,s=c===void 0?!0:c,i=r.fallbackPlacements,f=r.padding,l=r.boundary,v=r.rootBoundary,h=r.altBoundary,p=r.flipVariations,x=p===void 0?!0:p,d=r.allowedAutoPlacements,m=t.options.placement,w=I(m),P=w===m,b=i||(P||!x?[xe(m)]:Gr(m)),u=[m].concat(b).reduce(function(ee,X){return ee.concat(I(X)===Fe?Yr(t,{placement:X,boundary:l,rootBoundary:v,padding:f,flipVariations:x,allowedAutoPlacements:d}):X)},[]),g=t.rects.reference,y=t.rects.popper,O=new Map,A=!0,C=u[0],R=0;R=0,V=j?"width":"height",D=pe(t,{placement:$,boundary:l,rootBoundary:v,altBoundary:h,padding:f}),M=j?S?H:F:S?N:B;g[V]>y[V]&&(M=xe(M));var z=xe(M),G=[];if(a&&G.push(D[k]<=0),s&&G.push(D[M]<=0,D[z]<=0),G.every(function(ee){return ee})){C=$,A=!1;break}O.set($,G)}if(A)for(var me=x?3:1,Pe=function(X){var se=u.find(function(ge){var _=O.get(ge);if(_)return _.slice(0,X).every(function(Ee){return Ee})});if(se)return C=se,"break"},ie=me;ie>0;ie--){var he=Pe(ie);if(he==="break")break}t.placement!==C&&(t.modifiersData[o]._skip=!0,t.placement=C,t.reset=!0)}}const Qr={name:"flip",enabled:!0,phase:"main",fn:_r,requiresIfExists:["offset"],data:{_skip:!1}};function ft(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function ut(e){return[B,H,N,F].some(function(t){return e[t]>=0})}function Zr(e){var t=e.state,r=e.name,o=t.rects.reference,n=t.rects.popper,a=t.modifiersData.preventOverflow,c=pe(t,{elementContext:"reference"}),s=pe(t,{altBoundary:!0}),i=ft(c,o),f=ft(s,n,a),l=ut(i),v=ut(f);t.modifiersData[r]={referenceClippingOffsets:i,popperEscapeOffsets:f,isReferenceHidden:l,hasPopperEscaped:v},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":l,"data-popper-escaped":v})}const Jr={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Zr};function Kr(e,t,r){var o=I(e),n=[F,B].indexOf(o)>=0?-1:1,a=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,c=a[0],s=a[1];return c=c||0,s=(s||0)*n,[F,H].indexOf(o)>=0?{x:s,y:c}:{x:c,y:s}}function eo(e){var t=e.state,r=e.options,o=e.name,n=r.offset,a=n===void 0?[0,0]:n,c=xt.reduce(function(l,v){return l[v]=Kr(v,t.rects,a),l},{}),s=c[t.placement],i=s.x,f=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=i,t.modifiersData.popperOffsets.y+=f),t.modifiersData[o]=c}const to={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:eo};function ro(e){var t=e.state,r=e.name;t.modifiersData[r]=At({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const oo={name:"popperOffsets",enabled:!0,phase:"read",fn:ro,data:{}};function no(e){return e==="x"?"y":"x"}function ao(e){var t=e.state,r=e.options,o=e.name,n=r.mainAxis,a=n===void 0?!0:n,c=r.altAxis,s=c===void 0?!1:c,i=r.boundary,f=r.rootBoundary,l=r.altBoundary,v=r.padding,h=r.tether,p=h===void 0?!0:h,x=r.tetherOffset,d=x===void 0?0:x,m=pe(t,{boundary:i,rootBoundary:f,padding:v,altBoundary:l}),w=I(t.placement),P=ne(t.placement),b=!P,u=Le(w),g=no(u),y=t.modifiersData.popperOffsets,O=t.rects.reference,A=t.rects.popper,C=typeof d=="function"?d(Object.assign({},t.rects,{placement:t.placement})):d,R=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),$=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,k={x:0,y:0};if(y){if(a){var S,j=u==="y"?B:F,V=u==="y"?N:H,D=u==="y"?"height":"width",M=y[u],z=M+m[j],G=M-m[V],me=p?-A[D]/2:0,Pe=P===te?O[D]:A[D],ie=P===te?-A[D]:-O[D],he=t.elements.arrow,ee=p&&he?Ve(he):{width:0,height:0},X=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Pt(),se=X[j],ge=X[V],_=ce(0,O[D],ee[D]),Ee=b?O[D]/2-me-_-se-R.mainAxis:Pe-_-se-R.mainAxis,$t=b?-O[D]/2+me+_+ge+R.mainAxis:ie+_+ge+R.mainAxis,Ce=t.elements.arrow&&ve(t.elements.arrow),Dt=Ce?u==="y"?Ce.clientTop||0:Ce.clientLeft||0:0,Ue=(S=$==null?void 0:$[u])!=null?S:0,jt=M+Ee-Ue-Dt,kt=M+$t-Ue,qe=ce(p?we(z,jt):z,M,p?Z(G,kt):G);y[u]=qe,k[u]=qe-M}if(s){var ze,Tt=u==="x"?B:F,Mt=u==="x"?N:H,Q=y[g],ye=g==="y"?"height":"width",Xe=Q+m[Tt],Ye=Q-m[Mt],Re=[B,F].indexOf(w)!==-1,Ge=(ze=$==null?void 0:$[g])!=null?ze:0,_e=Re?Xe:Q-O[ye]-A[ye]-Ge+R.altAxis,Qe=Re?Q+O[ye]+A[ye]-Ge-R.altAxis:Ye,Ze=p&&Re?$r(_e,Q,Qe):ce(p?_e:Xe,Q,p?Qe:Ye);y[g]=Ze,k[g]=Ze-Q}t.modifiersData[o]=k}}const io={name:"preventOverflow",enabled:!0,phase:"main",fn:ao,requiresIfExists:["offset"]};function so(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function lo(e){return e===W(e)||!L(e)?Ne(e):so(e)}function co(e){var t=e.getBoundingClientRect(),r=re(t.width)/e.offsetWidth||1,o=re(t.height)/e.offsetHeight||1;return r!==1||o!==1}function fo(e,t,r){r===void 0&&(r=!1);var o=L(t),n=L(t)&&co(t),a=Y(t),c=oe(e,n,r),s={scrollLeft:0,scrollTop:0},i={x:0,y:0};return(o||!o&&!r)&&((U(t)!=="body"||Ie(a))&&(s=lo(t)),L(t)?(i=oe(t,!0),i.x+=t.clientLeft,i.y+=t.clientTop):a&&(i.x=He(a))),{x:c.left+s.scrollLeft-i.x,y:c.top+s.scrollTop-i.y,width:c.width,height:c.height}}function uo(e){var t=new Map,r=new Set,o=[];e.forEach(function(a){t.set(a.name,a)});function n(a){r.add(a.name);var c=[].concat(a.requires||[],a.requiresIfExists||[]);c.forEach(function(s){if(!r.has(s)){var i=t.get(s);i&&n(i)}}),o.push(a)}return e.forEach(function(a){r.has(a.name)||n(a)}),o}function po(e){var t=uo(e);return Pr.reduce(function(r,o){return r.concat(t.filter(function(n){return n.phase===o}))},[])}function vo(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function mo(e){var t=e.reduce(function(r,o){var n=r[o.name];return r[o.name]=n?Object.assign({},n,o,{options:Object.assign({},n.options,o.options),data:Object.assign({},n.data,o.data)}):o,r},{});return Object.keys(t).map(function(r){return t[r]})}var pt={placement:"bottom",modifiers:[],strategy:"absolute"};function dt(){for(var e=arguments.length,t=new Array(e),r=0;rke({root:["root"]},ur(bo)),Co={},Ro=E.forwardRef(function(t,r){var o;const{anchorEl:n,children:a,direction:c,disablePortal:s,modifiers:i,open:f,placement:l,popperOptions:v,popperRef:h,slotProps:p={},slots:x={},TransitionProps:d}=t,m=ae(t,xo),w=E.useRef(null),P=et(w,r),b=E.useRef(null),u=et(b,h),g=E.useRef(u);tt(()=>{g.current=u},[u]),E.useImperativeHandle(h,()=>b.current,[]);const y=Oo(l,c),[O,A]=E.useState(y),[C,R]=E.useState(je(n));E.useEffect(()=>{b.current&&b.current.forceUpdate()}),E.useEffect(()=>{n&&R(je(n))},[n]),tt(()=>{if(!C||!f)return;const V=z=>{A(z.placement)};let D=[{name:"preventOverflow",options:{altBoundary:s}},{name:"flip",options:{altBoundary:s}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:z})=>{V(z)}}];i!=null&&(D=D.concat(i)),v&&v.modifiers!=null&&(D=D.concat(v.modifiers));const M=yo(C,w.current,T({placement:y},v,{modifiers:D}));return g.current(M),()=>{M.destroy(),g.current(null)}},[C,s,i,f,v,y]);const $={placement:O};d!==null&&($.TransitionProps=d);const k=Eo(),S=(o=x.root)!=null?o:"div",j=Yt({elementType:S,externalSlotProps:p.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:P},ownerState:t,className:k.root});return J.jsx(S,T({},j,{children:typeof a=="function"?a($):a}))}),Ao=E.forwardRef(function(t,r){const{anchorEl:o,children:n,container:a,direction:c="ltr",disablePortal:s=!1,keepMounted:i=!1,modifiers:f,open:l,placement:v="bottom",popperOptions:h=Co,popperRef:p,style:x,transition:d=!1,slotProps:m={},slots:w={}}=t,P=ae(t,wo),[b,u]=E.useState(!0),g=()=>{u(!1)},y=()=>{u(!0)};if(!i&&!l&&(!d||b))return null;let O;if(a)O=a;else if(o){const R=je(o);O=R&&Po(R)?rt(R).body:rt(null).body}const A=!l&&i&&(!d||b)?"none":void 0,C=d?{in:l,onEnter:g,onExited:y}:void 0;return J.jsx(Xt,{disablePortal:s,container:O,children:J.jsx(Ro,T({anchorEl:o,direction:c,disablePortal:s,modifiers:f,ref:r,open:d?!b:l,placement:v,popperOptions:h,popperRef:p,slotProps:m,slots:w},P,{style:T({position:"fixed",top:0,left:0,display:A},x),TransitionProps:C,children:n}))})}),So=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],$o=Me(Ao,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Do=E.forwardRef(function(t,r){var o;const n=qt(),a=Be({props:t,name:"MuiPopper"}),{anchorEl:c,component:s,components:i,componentsProps:f,container:l,disablePortal:v,keepMounted:h,modifiers:p,open:x,placement:d,popperOptions:m,popperRef:w,transition:P,slots:b,slotProps:u}=a,g=ae(a,So),y=(o=b==null?void 0:b.root)!=null?o:i==null?void 0:i.Root,O=T({anchorEl:c,container:l,disablePortal:v,keepMounted:h,modifiers:p,open:x,placement:d,popperOptions:m,popperRef:w,transition:P},g);return J.jsx($o,T({as:s,direction:n==null?void 0:n.direction,slots:{root:y},slotProps:u??f},O,{ref:r}))}),Uo=Do;function qo({props:e,states:t,muiFormControl:r}){return t.reduce((o,n)=>(o[n]=e[n],r&&typeof e[n]>"u"&&(o[n]=r[n]),o),{})}const jo=E.createContext(void 0),St=jo;function zo(){return E.useContext(St)}function vt(e){return e!=null&&!(Array.isArray(e)&&e.length===0)}function mt(e,t=!1){return e&&(vt(e.value)&&e.value!==""||t&&vt(e.defaultValue)&&e.defaultValue!=="")}function ko(e){return e.startAdornment}function To(e){return Te("MuiFormControl",e)}ht("MuiFormControl",["root","marginNone","marginNormal","marginDense","fullWidth","disabled"]);const Mo=["children","className","color","component","disabled","error","focused","fullWidth","hiddenLabel","margin","required","size","variant"],Bo=e=>{const{classes:t,margin:r,fullWidth:o}=e,n={root:["root",r!=="none"&&`margin${gt(r)}`,o&&"fullWidth"]};return ke(n,To,t)},Fo=Me("div",{name:"MuiFormControl",slot:"Root",overridesResolver:({ownerState:e},t)=>T({},t.root,t[`margin${gt(e.margin)}`],e.fullWidth&&t.fullWidth)})(({ownerState:e})=>T({display:"inline-flex",flexDirection:"column",position:"relative",minWidth:0,padding:0,margin:0,border:0,verticalAlign:"top"},e.margin==="normal"&&{marginTop:16,marginBottom:8},e.margin==="dense"&&{marginTop:8,marginBottom:4},e.fullWidth&&{width:"100%"})),Wo=E.forwardRef(function(t,r){const o=Be({props:t,name:"MuiFormControl"}),{children:n,className:a,color:c="primary",component:s="div",disabled:i=!1,error:f=!1,focused:l,fullWidth:v=!1,hiddenLabel:h=!1,margin:p="none",required:x=!1,size:d="medium",variant:m="outlined"}=o,w=ae(o,Mo),P=T({},o,{color:c,component:s,disabled:i,error:f,fullWidth:v,hiddenLabel:h,margin:p,required:x,size:d,variant:m}),b=Bo(P),[u,g]=E.useState(()=>{let S=!1;return n&&E.Children.forEach(n,j=>{if(!Se(j,["Input","Select"]))return;const V=Se(j,["Select"])?j.props.input:j;V&&ko(V.props)&&(S=!0)}),S}),[y,O]=E.useState(()=>{let S=!1;return n&&E.Children.forEach(n,j=>{Se(j,["Input","Select"])&&(mt(j.props,!0)||mt(j.props.inputProps,!0))&&(S=!0)}),S}),[A,C]=E.useState(!1);i&&A&&C(!1);const R=l!==void 0&&!i?l:A;let $;const k=E.useMemo(()=>({adornedStart:u,setAdornedStart:g,color:c,disabled:i,error:f,filled:y,focused:R,fullWidth:v,hiddenLabel:h,size:d,onBlur:()=>{C(!1)},onEmpty:()=>{O(!1)},onFilled:()=>{O(!0)},onFocus:()=>{C(!0)},registerEffect:$,required:x,variant:m}),[u,c,i,f,y,R,v,h,$,x,d,m]);return J.jsx(St.Provider,{value:k,children:J.jsx(Fo,T({as:s,ownerState:P,className:zt(b.root,a),ref:r},w,{children:n}))})}),Xo=Wo,Vo=lr({createStyledComponent:Me("div",{name:"MuiStack",slot:"Root",overridesResolver:(e,t)=>t.root}),useThemeProps:e=>Be({props:e,name:"MuiStack"})}),Yo=Vo;export{Xo as F,Uo as P,Yo as S,Ho as a,zo as b,St as c,Zt as e,qo as f,mt as i,Io as u}; +import{r as E,a7 as Mt,G as ae,N as T,c5 as Ft,c6 as Wt,c7 as Lt,c8 as Nt,c9 as Vt,bC as Ze,bB as Ae,ca as Ht,c4 as It,cb as Ut,j as Z,cc as Je,U as ke,K as Te,L as ht,Y as et,Z as tt,M as Be,cd as qt,P as Me,X as gt,S as Xt}from"./index-4e60c9e2.js";import{w as rt,aN as zt,Q as Yt}from"./index-af5a3f81.js";function Se(e,t){var r,o;return E.isValidElement(e)&&t.indexOf((r=e.type.muiName)!=null?r:(o=e.type)==null||(o=o._payload)==null||(o=o.value)==null?void 0:o.muiName)!==-1}let ot=0;function Gt(e){const[t,r]=E.useState(e),o=e||t;return E.useEffect(()=>{t==null&&(ot+=1,r(`mui-${ot}`))},[t]),o}const nt=Mt["useId".toString()];function Ho(e){if(nt!==void 0){const t=nt();return e??t}return Gt(e)}function Io({controlled:e,default:t,name:r,state:o="value"}){const{current:n}=E.useRef(e!==void 0),[a,c]=E.useState(t),s=n?e:a,i=E.useCallback(f=>{n||c(f)},[]);return[s,i]}const _t=["sx"],Kt=e=>{var t,r;const o={systemProps:{},otherProps:{}},n=(t=e==null||(r=e.theme)==null?void 0:r.unstable_sxConfig)!=null?t:Ft;return Object.keys(e).forEach(a=>{n[a]?o.systemProps[a]=e[a]:o.otherProps[a]=e[a]}),o};function Qt(e){const{sx:t}=e,r=ae(e,_t),{systemProps:o,otherProps:n}=Kt(r);let a;return Array.isArray(t)?a=[o,...t]:typeof t=="function"?a=(...c)=>{const s=t(...c);return Wt(s)?T({},o,s):o}:a=T({},o,t),T({},n,{sx:a})}function yt(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;tt.root});function nr(e){return Vt({props:e,name:"MuiStack",defaultTheme:rr})}function ar(e,t){const r=E.Children.toArray(e).filter(Boolean);return r.reduce((o,n,a)=>(o.push(n),a({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"})[e],sr=({ownerState:e,theme:t})=>{let r=T({display:"flex",flexDirection:"column"},Ze({theme:t},Ae({values:e.direction,breakpoints:t.breakpoints.values}),o=>({flexDirection:o})));if(e.spacing){const o=Ht(t),n=Object.keys(t.breakpoints.values).reduce((i,f)=>((typeof e.spacing=="object"&&e.spacing[f]!=null||typeof e.direction=="object"&&e.direction[f]!=null)&&(i[f]=!0),i),{}),a=Ae({values:e.direction,base:n}),c=Ae({values:e.spacing,base:n});typeof a=="object"&&Object.keys(a).forEach((i,f,l)=>{if(!a[i]){const h=f>0?a[l[f-1]]:"column";a[i]=h}}),r=It(r,Ze({theme:t},c,(i,f)=>e.useFlexGap?{gap:Je(o,i)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${ir(f?a[f]:e.direction)}`]:Je(o,i)}}))}return r=Ut(t.breakpoints,r),r};function lr(e={}){const{createStyledComponent:t=or,useThemeProps:r=nr,componentName:o="MuiStack"}=e,n=()=>ke({root:["root"]},i=>Te(o,i),{}),a=t(sr);return E.forwardRef(function(i,f){const l=r(i),v=Qt(l),{component:h="div",direction:p="column",spacing:x=0,divider:d,children:m,className:w,useFlexGap:O=!1}=v,b=ae(v,tr),u={direction:p,spacing:x,useFlexGap:O},g=n();return Z.jsx(a,T({as:h,ownerState:u,ref:f,className:Zt(g.root,w)},b,{children:d?ar(m,d):m}))})}const cr={disableDefaultClasses:!1},fr=E.createContext(cr);function ur(e){const{disableDefaultClasses:t}=E.useContext(fr);return r=>t?"":e(r)}var M="top",V="bottom",H="right",F="left",Fe="auto",de=[M,V,H,F],te="start",ue="end",pr="clippingParents",bt="viewport",le="popper",dr="reference",at=de.reduce(function(e,t){return e.concat([t+"-"+te,t+"-"+ue])},[]),xt=[].concat(de,[Fe]).reduce(function(e,t){return e.concat([t,t+"-"+te,t+"-"+ue])},[]),vr="beforeRead",mr="read",hr="afterRead",gr="beforeMain",yr="main",br="afterMain",xr="beforeWrite",wr="write",Pr="afterWrite",Or=[vr,mr,hr,gr,yr,br,xr,wr,Pr];function U(e){return e?(e.nodeName||"").toLowerCase():null}function W(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function J(e){var t=W(e).Element;return e instanceof t||e instanceof Element}function N(e){var t=W(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function We(e){if(typeof ShadowRoot>"u")return!1;var t=W(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Er(e){var t=e.state;Object.keys(t.elements).forEach(function(r){var o=t.styles[r]||{},n=t.attributes[r]||{},a=t.elements[r];!N(a)||!U(a)||(Object.assign(a.style,o),Object.keys(n).forEach(function(c){var s=n[c];s===!1?a.removeAttribute(c):a.setAttribute(c,s===!0?"":s)}))})}function Cr(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(o){var n=t.elements[o],a=t.attributes[o]||{},c=Object.keys(t.styles.hasOwnProperty(o)?t.styles[o]:r[o]),s=c.reduce(function(i,f){return i[f]="",i},{});!N(n)||!U(n)||(Object.assign(n.style,s),Object.keys(a).forEach(function(i){n.removeAttribute(i)}))})}}const Rr={name:"applyStyles",enabled:!0,phase:"write",fn:Er,effect:Cr,requires:["computeStyles"]};function I(e){return e.split("-")[0]}var Q=Math.max,we=Math.min,re=Math.round;function $e(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function wt(){return!/^((?!chrome|android).)*safari/i.test($e())}function oe(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var o=e.getBoundingClientRect(),n=1,a=1;t&&N(e)&&(n=e.offsetWidth>0&&re(o.width)/e.offsetWidth||1,a=e.offsetHeight>0&&re(o.height)/e.offsetHeight||1);var c=J(e)?W(e):window,s=c.visualViewport,i=!wt()&&r,f=(o.left+(i&&s?s.offsetLeft:0))/n,l=(o.top+(i&&s?s.offsetTop:0))/a,v=o.width/n,h=o.height/a;return{width:v,height:h,top:l,right:f+v,bottom:l+h,left:f,x:f,y:l}}function Le(e){var t=oe(e),r=e.offsetWidth,o=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-o)<=1&&(o=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:o}}function Pt(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&We(r)){var o=t;do{if(o&&e.isSameNode(o))return!0;o=o.parentNode||o.host}while(o)}return!1}function q(e){return W(e).getComputedStyle(e)}function Ar(e){return["table","td","th"].indexOf(U(e))>=0}function Y(e){return((J(e)?e.ownerDocument:e.document)||window.document).documentElement}function Pe(e){return U(e)==="html"?e:e.assignedSlot||e.parentNode||(We(e)?e.host:null)||Y(e)}function it(e){return!N(e)||q(e).position==="fixed"?null:e.offsetParent}function Sr(e){var t=/firefox/i.test($e()),r=/Trident/i.test($e());if(r&&N(e)){var o=q(e);if(o.position==="fixed")return null}var n=Pe(e);for(We(n)&&(n=n.host);N(n)&&["html","body"].indexOf(U(n))<0;){var a=q(n);if(a.transform!=="none"||a.perspective!=="none"||a.contain==="paint"||["transform","perspective"].indexOf(a.willChange)!==-1||t&&a.willChange==="filter"||t&&a.filter&&a.filter!=="none")return n;n=n.parentNode}return null}function ve(e){for(var t=W(e),r=it(e);r&&Ar(r)&&q(r).position==="static";)r=it(r);return r&&(U(r)==="html"||U(r)==="body"&&q(r).position==="static")?t:r||Sr(e)||t}function Ne(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function ce(e,t,r){return Q(e,we(t,r))}function $r(e,t,r){var o=ce(e,t,r);return o>r?r:o}function Ot(){return{top:0,right:0,bottom:0,left:0}}function Et(e){return Object.assign({},Ot(),e)}function Ct(e,t){return t.reduce(function(r,o){return r[o]=e,r},{})}var Dr=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,Et(typeof t!="number"?t:Ct(t,de))};function jr(e){var t,r=e.state,o=e.name,n=e.options,a=r.elements.arrow,c=r.modifiersData.popperOffsets,s=I(r.placement),i=Ne(s),f=[F,H].indexOf(s)>=0,l=f?"height":"width";if(!(!a||!c)){var v=Dr(n.padding,r),h=Le(a),p=i==="y"?M:F,x=i==="y"?V:H,d=r.rects.reference[l]+r.rects.reference[i]-c[i]-r.rects.popper[l],m=c[i]-r.rects.reference[i],w=ve(a),O=w?i==="y"?w.clientHeight||0:w.clientWidth||0:0,b=d/2-m/2,u=v[p],g=O-h[l]-v[x],y=O/2-h[l]/2+b,P=ce(u,y,g),A=i;r.modifiersData[o]=(t={},t[A]=P,t.centerOffset=P-y,t)}}function kr(e){var t=e.state,r=e.options,o=r.element,n=o===void 0?"[data-popper-arrow]":o;n!=null&&(typeof n=="string"&&(n=t.elements.popper.querySelector(n),!n)||Pt(t.elements.popper,n)&&(t.elements.arrow=n))}const Tr={name:"arrow",enabled:!0,phase:"main",fn:jr,effect:kr,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ne(e){return e.split("-")[1]}var Br={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Mr(e,t){var r=e.x,o=e.y,n=t.devicePixelRatio||1;return{x:re(r*n)/n||0,y:re(o*n)/n||0}}function st(e){var t,r=e.popper,o=e.popperRect,n=e.placement,a=e.variation,c=e.offsets,s=e.position,i=e.gpuAcceleration,f=e.adaptive,l=e.roundOffsets,v=e.isFixed,h=c.x,p=h===void 0?0:h,x=c.y,d=x===void 0?0:x,m=typeof l=="function"?l({x:p,y:d}):{x:p,y:d};p=m.x,d=m.y;var w=c.hasOwnProperty("x"),O=c.hasOwnProperty("y"),b=F,u=M,g=window;if(f){var y=ve(r),P="clientHeight",A="clientWidth";if(y===W(r)&&(y=Y(r),q(y).position!=="static"&&s==="absolute"&&(P="scrollHeight",A="scrollWidth")),y=y,n===M||(n===F||n===H)&&a===ue){u=V;var C=v&&y===g&&g.visualViewport?g.visualViewport.height:y[P];d-=C-o.height,d*=i?1:-1}if(n===F||(n===M||n===V)&&a===ue){b=H;var R=v&&y===g&&g.visualViewport?g.visualViewport.width:y[A];p-=R-o.width,p*=i?1:-1}}var $=Object.assign({position:s},f&&Br),k=l===!0?Mr({x:p,y:d},W(r)):{x:p,y:d};if(p=k.x,d=k.y,i){var S;return Object.assign({},$,(S={},S[u]=O?"0":"",S[b]=w?"0":"",S.transform=(g.devicePixelRatio||1)<=1?"translate("+p+"px, "+d+"px)":"translate3d("+p+"px, "+d+"px, 0)",S))}return Object.assign({},$,(t={},t[u]=O?d+"px":"",t[b]=w?p+"px":"",t.transform="",t))}function Fr(e){var t=e.state,r=e.options,o=r.gpuAcceleration,n=o===void 0?!0:o,a=r.adaptive,c=a===void 0?!0:a,s=r.roundOffsets,i=s===void 0?!0:s,f={placement:I(t.placement),variation:ne(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:n,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,st(Object.assign({},f,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:c,roundOffsets:i})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,st(Object.assign({},f,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:i})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Wr={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Fr,data:{}};var be={passive:!0};function Lr(e){var t=e.state,r=e.instance,o=e.options,n=o.scroll,a=n===void 0?!0:n,c=o.resize,s=c===void 0?!0:c,i=W(t.elements.popper),f=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&f.forEach(function(l){l.addEventListener("scroll",r.update,be)}),s&&i.addEventListener("resize",r.update,be),function(){a&&f.forEach(function(l){l.removeEventListener("scroll",r.update,be)}),s&&i.removeEventListener("resize",r.update,be)}}const Nr={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Lr,data:{}};var Vr={left:"right",right:"left",bottom:"top",top:"bottom"};function xe(e){return e.replace(/left|right|bottom|top/g,function(t){return Vr[t]})}var Hr={start:"end",end:"start"};function lt(e){return e.replace(/start|end/g,function(t){return Hr[t]})}function Ve(e){var t=W(e),r=t.pageXOffset,o=t.pageYOffset;return{scrollLeft:r,scrollTop:o}}function He(e){return oe(Y(e)).left+Ve(e).scrollLeft}function Ir(e,t){var r=W(e),o=Y(e),n=r.visualViewport,a=o.clientWidth,c=o.clientHeight,s=0,i=0;if(n){a=n.width,c=n.height;var f=wt();(f||!f&&t==="fixed")&&(s=n.offsetLeft,i=n.offsetTop)}return{width:a,height:c,x:s+He(e),y:i}}function Ur(e){var t,r=Y(e),o=Ve(e),n=(t=e.ownerDocument)==null?void 0:t.body,a=Q(r.scrollWidth,r.clientWidth,n?n.scrollWidth:0,n?n.clientWidth:0),c=Q(r.scrollHeight,r.clientHeight,n?n.scrollHeight:0,n?n.clientHeight:0),s=-o.scrollLeft+He(e),i=-o.scrollTop;return q(n||r).direction==="rtl"&&(s+=Q(r.clientWidth,n?n.clientWidth:0)-a),{width:a,height:c,x:s,y:i}}function Ie(e){var t=q(e),r=t.overflow,o=t.overflowX,n=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+n+o)}function Rt(e){return["html","body","#document"].indexOf(U(e))>=0?e.ownerDocument.body:N(e)&&Ie(e)?e:Rt(Pe(e))}function fe(e,t){var r;t===void 0&&(t=[]);var o=Rt(e),n=o===((r=e.ownerDocument)==null?void 0:r.body),a=W(o),c=n?[a].concat(a.visualViewport||[],Ie(o)?o:[]):o,s=t.concat(c);return n?s:s.concat(fe(Pe(c)))}function De(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function qr(e,t){var r=oe(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function ct(e,t,r){return t===bt?De(Ir(e,r)):J(t)?qr(t,r):De(Ur(Y(e)))}function Xr(e){var t=fe(Pe(e)),r=["absolute","fixed"].indexOf(q(e).position)>=0,o=r&&N(e)?ve(e):e;return J(o)?t.filter(function(n){return J(n)&&Pt(n,o)&&U(n)!=="body"}):[]}function zr(e,t,r,o){var n=t==="clippingParents"?Xr(e):[].concat(t),a=[].concat(n,[r]),c=a[0],s=a.reduce(function(i,f){var l=ct(e,f,o);return i.top=Q(l.top,i.top),i.right=we(l.right,i.right),i.bottom=we(l.bottom,i.bottom),i.left=Q(l.left,i.left),i},ct(e,c,o));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function At(e){var t=e.reference,r=e.element,o=e.placement,n=o?I(o):null,a=o?ne(o):null,c=t.x+t.width/2-r.width/2,s=t.y+t.height/2-r.height/2,i;switch(n){case M:i={x:c,y:t.y-r.height};break;case V:i={x:c,y:t.y+t.height};break;case H:i={x:t.x+t.width,y:s};break;case F:i={x:t.x-r.width,y:s};break;default:i={x:t.x,y:t.y}}var f=n?Ne(n):null;if(f!=null){var l=f==="y"?"height":"width";switch(a){case te:i[f]=i[f]-(t[l]/2-r[l]/2);break;case ue:i[f]=i[f]+(t[l]/2-r[l]/2);break}}return i}function pe(e,t){t===void 0&&(t={});var r=t,o=r.placement,n=o===void 0?e.placement:o,a=r.strategy,c=a===void 0?e.strategy:a,s=r.boundary,i=s===void 0?pr:s,f=r.rootBoundary,l=f===void 0?bt:f,v=r.elementContext,h=v===void 0?le:v,p=r.altBoundary,x=p===void 0?!1:p,d=r.padding,m=d===void 0?0:d,w=Et(typeof m!="number"?m:Ct(m,de)),O=h===le?dr:le,b=e.rects.popper,u=e.elements[x?O:h],g=zr(J(u)?u:u.contextElement||Y(e.elements.popper),i,l,c),y=oe(e.elements.reference),P=At({reference:y,element:b,strategy:"absolute",placement:n}),A=De(Object.assign({},b,P)),C=h===le?A:y,R={top:g.top-C.top+w.top,bottom:C.bottom-g.bottom+w.bottom,left:g.left-C.left+w.left,right:C.right-g.right+w.right},$=e.modifiersData.offset;if(h===le&&$){var k=$[n];Object.keys(R).forEach(function(S){var j=[H,V].indexOf(S)>=0?1:-1,L=[M,V].indexOf(S)>=0?"y":"x";R[S]+=k[L]*j})}return R}function Yr(e,t){t===void 0&&(t={});var r=t,o=r.placement,n=r.boundary,a=r.rootBoundary,c=r.padding,s=r.flipVariations,i=r.allowedAutoPlacements,f=i===void 0?xt:i,l=ne(o),v=l?s?at:at.filter(function(x){return ne(x)===l}):de,h=v.filter(function(x){return f.indexOf(x)>=0});h.length===0&&(h=v);var p=h.reduce(function(x,d){return x[d]=pe(e,{placement:d,boundary:n,rootBoundary:a,padding:c})[I(d)],x},{});return Object.keys(p).sort(function(x,d){return p[x]-p[d]})}function Gr(e){if(I(e)===Fe)return[];var t=xe(e);return[lt(e),t,lt(t)]}function _r(e){var t=e.state,r=e.options,o=e.name;if(!t.modifiersData[o]._skip){for(var n=r.mainAxis,a=n===void 0?!0:n,c=r.altAxis,s=c===void 0?!0:c,i=r.fallbackPlacements,f=r.padding,l=r.boundary,v=r.rootBoundary,h=r.altBoundary,p=r.flipVariations,x=p===void 0?!0:p,d=r.allowedAutoPlacements,m=t.options.placement,w=I(m),O=w===m,b=i||(O||!x?[xe(m)]:Gr(m)),u=[m].concat(b).reduce(function(ee,z){return ee.concat(I(z)===Fe?Yr(t,{placement:z,boundary:l,rootBoundary:v,padding:f,flipVariations:x,allowedAutoPlacements:d}):z)},[]),g=t.rects.reference,y=t.rects.popper,P=new Map,A=!0,C=u[0],R=0;R=0,L=j?"width":"height",D=pe(t,{placement:$,boundary:l,rootBoundary:v,altBoundary:h,padding:f}),B=j?S?H:F:S?V:M;g[L]>y[L]&&(B=xe(B));var X=xe(B),G=[];if(a&&G.push(D[k]<=0),s&&G.push(D[B]<=0,D[X]<=0),G.every(function(ee){return ee})){C=$,A=!1;break}P.set($,G)}if(A)for(var me=x?3:1,Oe=function(z){var se=u.find(function(ge){var _=P.get(ge);if(_)return _.slice(0,z).every(function(Ee){return Ee})});if(se)return C=se,"break"},ie=me;ie>0;ie--){var he=Oe(ie);if(he==="break")break}t.placement!==C&&(t.modifiersData[o]._skip=!0,t.placement=C,t.reset=!0)}}const Kr={name:"flip",enabled:!0,phase:"main",fn:_r,requiresIfExists:["offset"],data:{_skip:!1}};function ft(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function ut(e){return[M,H,V,F].some(function(t){return e[t]>=0})}function Qr(e){var t=e.state,r=e.name,o=t.rects.reference,n=t.rects.popper,a=t.modifiersData.preventOverflow,c=pe(t,{elementContext:"reference"}),s=pe(t,{altBoundary:!0}),i=ft(c,o),f=ft(s,n,a),l=ut(i),v=ut(f);t.modifiersData[r]={referenceClippingOffsets:i,popperEscapeOffsets:f,isReferenceHidden:l,hasPopperEscaped:v},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":l,"data-popper-escaped":v})}const Zr={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Qr};function Jr(e,t,r){var o=I(e),n=[F,M].indexOf(o)>=0?-1:1,a=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,c=a[0],s=a[1];return c=c||0,s=(s||0)*n,[F,H].indexOf(o)>=0?{x:s,y:c}:{x:c,y:s}}function eo(e){var t=e.state,r=e.options,o=e.name,n=r.offset,a=n===void 0?[0,0]:n,c=xt.reduce(function(l,v){return l[v]=Jr(v,t.rects,a),l},{}),s=c[t.placement],i=s.x,f=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=i,t.modifiersData.popperOffsets.y+=f),t.modifiersData[o]=c}const to={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:eo};function ro(e){var t=e.state,r=e.name;t.modifiersData[r]=At({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const oo={name:"popperOffsets",enabled:!0,phase:"read",fn:ro,data:{}};function no(e){return e==="x"?"y":"x"}function ao(e){var t=e.state,r=e.options,o=e.name,n=r.mainAxis,a=n===void 0?!0:n,c=r.altAxis,s=c===void 0?!1:c,i=r.boundary,f=r.rootBoundary,l=r.altBoundary,v=r.padding,h=r.tether,p=h===void 0?!0:h,x=r.tetherOffset,d=x===void 0?0:x,m=pe(t,{boundary:i,rootBoundary:f,padding:v,altBoundary:l}),w=I(t.placement),O=ne(t.placement),b=!O,u=Ne(w),g=no(u),y=t.modifiersData.popperOffsets,P=t.rects.reference,A=t.rects.popper,C=typeof d=="function"?d(Object.assign({},t.rects,{placement:t.placement})):d,R=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),$=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,k={x:0,y:0};if(y){if(a){var S,j=u==="y"?M:F,L=u==="y"?V:H,D=u==="y"?"height":"width",B=y[u],X=B+m[j],G=B-m[L],me=p?-A[D]/2:0,Oe=O===te?P[D]:A[D],ie=O===te?-A[D]:-P[D],he=t.elements.arrow,ee=p&&he?Le(he):{width:0,height:0},z=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Ot(),se=z[j],ge=z[L],_=ce(0,P[D],ee[D]),Ee=b?P[D]/2-me-_-se-R.mainAxis:Oe-_-se-R.mainAxis,$t=b?-P[D]/2+me+_+ge+R.mainAxis:ie+_+ge+R.mainAxis,Ce=t.elements.arrow&&ve(t.elements.arrow),Dt=Ce?u==="y"?Ce.clientTop||0:Ce.clientLeft||0:0,Ue=(S=$==null?void 0:$[u])!=null?S:0,jt=B+Ee-Ue-Dt,kt=B+$t-Ue,qe=ce(p?we(X,jt):X,B,p?Q(G,kt):G);y[u]=qe,k[u]=qe-B}if(s){var Xe,Tt=u==="x"?M:F,Bt=u==="x"?V:H,K=y[g],ye=g==="y"?"height":"width",ze=K+m[Tt],Ye=K-m[Bt],Re=[M,F].indexOf(w)!==-1,Ge=(Xe=$==null?void 0:$[g])!=null?Xe:0,_e=Re?ze:K-P[ye]-A[ye]-Ge+R.altAxis,Ke=Re?K+P[ye]+A[ye]-Ge-R.altAxis:Ye,Qe=p&&Re?$r(_e,K,Ke):ce(p?_e:ze,K,p?Ke:Ye);y[g]=Qe,k[g]=Qe-K}t.modifiersData[o]=k}}const io={name:"preventOverflow",enabled:!0,phase:"main",fn:ao,requiresIfExists:["offset"]};function so(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function lo(e){return e===W(e)||!N(e)?Ve(e):so(e)}function co(e){var t=e.getBoundingClientRect(),r=re(t.width)/e.offsetWidth||1,o=re(t.height)/e.offsetHeight||1;return r!==1||o!==1}function fo(e,t,r){r===void 0&&(r=!1);var o=N(t),n=N(t)&&co(t),a=Y(t),c=oe(e,n,r),s={scrollLeft:0,scrollTop:0},i={x:0,y:0};return(o||!o&&!r)&&((U(t)!=="body"||Ie(a))&&(s=lo(t)),N(t)?(i=oe(t,!0),i.x+=t.clientLeft,i.y+=t.clientTop):a&&(i.x=He(a))),{x:c.left+s.scrollLeft-i.x,y:c.top+s.scrollTop-i.y,width:c.width,height:c.height}}function uo(e){var t=new Map,r=new Set,o=[];e.forEach(function(a){t.set(a.name,a)});function n(a){r.add(a.name);var c=[].concat(a.requires||[],a.requiresIfExists||[]);c.forEach(function(s){if(!r.has(s)){var i=t.get(s);i&&n(i)}}),o.push(a)}return e.forEach(function(a){r.has(a.name)||n(a)}),o}function po(e){var t=uo(e);return Or.reduce(function(r,o){return r.concat(t.filter(function(n){return n.phase===o}))},[])}function vo(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function mo(e){var t=e.reduce(function(r,o){var n=r[o.name];return r[o.name]=n?Object.assign({},n,o,{options:Object.assign({},n.options,o.options),data:Object.assign({},n.data,o.data)}):o,r},{});return Object.keys(t).map(function(r){return t[r]})}var pt={placement:"bottom",modifiers:[],strategy:"absolute"};function dt(){for(var e=arguments.length,t=new Array(e),r=0;rke({root:["root"]},ur(bo)),Co={},Ro=E.forwardRef(function(t,r){var o;const{anchorEl:n,children:a,direction:c,disablePortal:s,modifiers:i,open:f,placement:l,popperOptions:v,popperRef:h,slotProps:p={},slots:x={},TransitionProps:d}=t,m=ae(t,xo),w=E.useRef(null),O=et(w,r),b=E.useRef(null),u=et(b,h),g=E.useRef(u);tt(()=>{g.current=u},[u]),E.useImperativeHandle(h,()=>b.current,[]);const y=Po(l,c),[P,A]=E.useState(y),[C,R]=E.useState(je(n));E.useEffect(()=>{b.current&&b.current.forceUpdate()}),E.useEffect(()=>{n&&R(je(n))},[n]),tt(()=>{if(!C||!f)return;const L=X=>{A(X.placement)};let D=[{name:"preventOverflow",options:{altBoundary:s}},{name:"flip",options:{altBoundary:s}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:X})=>{L(X)}}];i!=null&&(D=D.concat(i)),v&&v.modifiers!=null&&(D=D.concat(v.modifiers));const B=yo(C,w.current,T({placement:y},v,{modifiers:D}));return g.current(B),()=>{B.destroy(),g.current(null)}},[C,s,i,f,v,y]);const $={placement:P};d!==null&&($.TransitionProps=d);const k=Eo(),S=(o=x.root)!=null?o:"div",j=Yt({elementType:S,externalSlotProps:p.root,externalForwardedProps:m,additionalProps:{role:"tooltip",ref:O},ownerState:t,className:k.root});return Z.jsx(S,T({},j,{children:typeof a=="function"?a($):a}))}),Ao=E.forwardRef(function(t,r){const{anchorEl:o,children:n,container:a,direction:c="ltr",disablePortal:s=!1,keepMounted:i=!1,modifiers:f,open:l,placement:v="bottom",popperOptions:h=Co,popperRef:p,style:x,transition:d=!1,slotProps:m={},slots:w={}}=t,O=ae(t,wo),[b,u]=E.useState(!0),g=()=>{u(!1)},y=()=>{u(!0)};if(!i&&!l&&(!d||b))return null;let P;if(a)P=a;else if(o){const R=je(o);P=R&&Oo(R)?rt(R).body:rt(null).body}const A=!l&&i&&(!d||b)?"none":void 0,C=d?{in:l,onEnter:g,onExited:y}:void 0;return Z.jsx(zt,{disablePortal:s,container:P,children:Z.jsx(Ro,T({anchorEl:o,direction:c,disablePortal:s,modifiers:f,ref:r,open:d?!b:l,placement:v,popperOptions:h,popperRef:p,slotProps:m,slots:w},O,{style:T({position:"fixed",top:0,left:0,display:A},x),TransitionProps:C,children:n}))})}),So=["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"],$o=Be(Ao,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Do=E.forwardRef(function(t,r){var o;const n=qt(),a=Me({props:t,name:"MuiPopper"}),{anchorEl:c,component:s,components:i,componentsProps:f,container:l,disablePortal:v,keepMounted:h,modifiers:p,open:x,placement:d,popperOptions:m,popperRef:w,transition:O,slots:b,slotProps:u}=a,g=ae(a,So),y=(o=b==null?void 0:b.root)!=null?o:i==null?void 0:i.Root,P=T({anchorEl:c,container:l,disablePortal:v,keepMounted:h,modifiers:p,open:x,placement:d,popperOptions:m,popperRef:w,transition:O},g);return Z.jsx($o,T({as:s,direction:n==null?void 0:n.direction,slots:{root:y},slotProps:u??f},P,{ref:r}))}),Uo=Do;function qo({props:e,states:t,muiFormControl:r}){return t.reduce((o,n)=>(o[n]=e[n],r&&typeof e[n]>"u"&&(o[n]=r[n]),o),{})}const jo=E.createContext(void 0),St=jo;function Xo(){return E.useContext(St)}function vt(e){return e!=null&&!(Array.isArray(e)&&e.length===0)}function mt(e,t=!1){return e&&(vt(e.value)&&e.value!==""||t&&vt(e.defaultValue)&&e.defaultValue!=="")}function ko(e){return e.startAdornment}function To(e){return Te("MuiFormControl",e)}ht("MuiFormControl",["root","marginNone","marginNormal","marginDense","fullWidth","disabled"]);const Bo=["children","className","color","component","disabled","error","focused","fullWidth","hiddenLabel","margin","required","size","variant"],Mo=e=>{const{classes:t,margin:r,fullWidth:o}=e,n={root:["root",r!=="none"&&`margin${gt(r)}`,o&&"fullWidth"]};return ke(n,To,t)},Fo=Be("div",{name:"MuiFormControl",slot:"Root",overridesResolver:({ownerState:e},t)=>T({},t.root,t[`margin${gt(e.margin)}`],e.fullWidth&&t.fullWidth)})(({ownerState:e})=>T({display:"inline-flex",flexDirection:"column",position:"relative",minWidth:0,padding:0,margin:0,border:0,verticalAlign:"top"},e.margin==="normal"&&{marginTop:16,marginBottom:8},e.margin==="dense"&&{marginTop:8,marginBottom:4},e.fullWidth&&{width:"100%"})),Wo=E.forwardRef(function(t,r){const o=Me({props:t,name:"MuiFormControl"}),{children:n,className:a,color:c="primary",component:s="div",disabled:i=!1,error:f=!1,focused:l,fullWidth:v=!1,hiddenLabel:h=!1,margin:p="none",required:x=!1,size:d="medium",variant:m="outlined"}=o,w=ae(o,Bo),O=T({},o,{color:c,component:s,disabled:i,error:f,fullWidth:v,hiddenLabel:h,margin:p,required:x,size:d,variant:m}),b=Mo(O),[u,g]=E.useState(()=>{let S=!1;return n&&E.Children.forEach(n,j=>{if(!Se(j,["Input","Select"]))return;const L=Se(j,["Select"])?j.props.input:j;L&&ko(L.props)&&(S=!0)}),S}),[y,P]=E.useState(()=>{let S=!1;return n&&E.Children.forEach(n,j=>{Se(j,["Input","Select"])&&(mt(j.props,!0)||mt(j.props.inputProps,!0))&&(S=!0)}),S}),[A,C]=E.useState(!1);i&&A&&C(!1);const R=l!==void 0&&!i?l:A;let $;const k=E.useMemo(()=>({adornedStart:u,setAdornedStart:g,color:c,disabled:i,error:f,filled:y,focused:R,fullWidth:v,hiddenLabel:h,size:d,onBlur:()=>{C(!1)},onEmpty:()=>{P(!1)},onFilled:()=>{P(!0)},onFocus:()=>{C(!0)},registerEffect:$,required:x,variant:m}),[u,c,i,f,y,R,v,h,$,x,d,m]);return Z.jsx(St.Provider,{value:k,children:Z.jsx(Fo,T({as:s,ownerState:O,className:Xt(b.root,a),ref:r},w,{children:n}))})}),zo=Wo,Lo=lr({createStyledComponent:Be("div",{name:"MuiStack",slot:"Root",overridesResolver:(e,t)=>t.root}),useThemeProps:e=>Me({props:e,name:"MuiStack"})}),Yo=Lo;export{zo as F,Uo as P,Yo as S,Ho as a,Xo as b,St as c,Qt as e,qo as f,mt as i,Io as u}; diff --git a/build/assets/Streamable-344c59ee.js b/build/assets/Streamable-7ba1c141.js similarity index 95% rename from build/assets/Streamable-344c59ee.js rename to build/assets/Streamable-7ba1c141.js index 5148299c6..499e19ca8 100644 --- a/build/assets/Streamable-344c59ee.js +++ b/build/assets/Streamable-7ba1c141.js @@ -1 +1 @@ -import{a9 as m,r as f}from"./index-4bb27744.js";import{u as _,p as b}from"./index-87de005d.js";function P(t,e){for(var r=0;rs[a]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var g=Object.create,l=Object.defineProperty,v=Object.getOwnPropertyDescriptor,O=Object.getOwnPropertyNames,S=Object.getPrototypeOf,j=Object.prototype.hasOwnProperty,L=(t,e,r)=>e in t?l(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,w=(t,e)=>{for(var r in e)l(t,r,{get:e[r],enumerable:!0})},c=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of O(e))!j.call(t,a)&&a!==r&&l(t,a,{get:()=>e[a],enumerable:!(s=v(e,a))||s.enumerable});return t},D=(t,e,r)=>(r=t!=null?g(S(t)):{},c(e||!t||!t.__esModule?l(r,"default",{value:t,enumerable:!0}):r,t)),E=t=>c(l({},"__esModule",{value:!0}),t),o=(t,e,r)=>(L(t,typeof e!="symbol"?e+"":e,r),r),h={};w(h,{default:()=>i});var y=E(h),p=D(f),u=_,d=b;const M="https://cdn.embed.ly/player-0.1.0.min.js",T="playerjs";class i extends p.Component{constructor(){super(...arguments),o(this,"callPlayer",u.callPlayer),o(this,"duration",null),o(this,"currentTime",null),o(this,"secondsLoaded",null),o(this,"mute",()=>{this.callPlayer("mute")}),o(this,"unmute",()=>{this.callPlayer("unmute")}),o(this,"ref",e=>{this.iframe=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){(0,u.getSDK)(M,T).then(r=>{this.iframe&&(this.player=new r.Player(this.iframe),this.player.setLoop(this.props.loop),this.player.on("ready",this.props.onReady),this.player.on("play",this.props.onPlay),this.player.on("pause",this.props.onPause),this.player.on("seeked",this.props.onSeek),this.player.on("ended",this.props.onEnded),this.player.on("error",this.props.onError),this.player.on("timeupdate",({duration:s,seconds:a})=>{this.duration=s,this.currentTime=a}),this.player.on("buffered",({percent:s})=>{this.duration&&(this.secondsLoaded=this.duration*s)}),this.props.muted&&this.player.mute())},this.props.onError)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("setCurrentTime",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e*100)}setLoop(e){this.callPlayer("setLoop",e)}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return this.secondsLoaded}render(){const e=this.props.url.match(d.MATCH_URL_STREAMABLE)[1],r={width:"100%",height:"100%"};return p.default.createElement("iframe",{ref:this.ref,src:`https://streamable.com/o/${e}`,frameBorder:"0",scrolling:"no",style:r,allow:"encrypted-media; autoplay; fullscreen;"})}}o(i,"displayName","Streamable");o(i,"canPlay",d.canPlay.streamable);const x=m(y),N=P({__proto__:null,default:x},[y]);export{N as S}; +import{a8 as m,r as f}from"./index-4e60c9e2.js";import{u as _,p as b}from"./index-a46872c4.js";function P(t,e){for(var r=0;rs[a]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var g=Object.create,l=Object.defineProperty,v=Object.getOwnPropertyDescriptor,O=Object.getOwnPropertyNames,S=Object.getPrototypeOf,j=Object.prototype.hasOwnProperty,L=(t,e,r)=>e in t?l(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,w=(t,e)=>{for(var r in e)l(t,r,{get:e[r],enumerable:!0})},c=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of O(e))!j.call(t,a)&&a!==r&&l(t,a,{get:()=>e[a],enumerable:!(s=v(e,a))||s.enumerable});return t},D=(t,e,r)=>(r=t!=null?g(S(t)):{},c(e||!t||!t.__esModule?l(r,"default",{value:t,enumerable:!0}):r,t)),E=t=>c(l({},"__esModule",{value:!0}),t),o=(t,e,r)=>(L(t,typeof e!="symbol"?e+"":e,r),r),h={};w(h,{default:()=>i});var y=E(h),p=D(f),u=_,d=b;const M="https://cdn.embed.ly/player-0.1.0.min.js",T="playerjs";class i extends p.Component{constructor(){super(...arguments),o(this,"callPlayer",u.callPlayer),o(this,"duration",null),o(this,"currentTime",null),o(this,"secondsLoaded",null),o(this,"mute",()=>{this.callPlayer("mute")}),o(this,"unmute",()=>{this.callPlayer("unmute")}),o(this,"ref",e=>{this.iframe=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){(0,u.getSDK)(M,T).then(r=>{this.iframe&&(this.player=new r.Player(this.iframe),this.player.setLoop(this.props.loop),this.player.on("ready",this.props.onReady),this.player.on("play",this.props.onPlay),this.player.on("pause",this.props.onPause),this.player.on("seeked",this.props.onSeek),this.player.on("ended",this.props.onEnded),this.player.on("error",this.props.onError),this.player.on("timeupdate",({duration:s,seconds:a})=>{this.duration=s,this.currentTime=a}),this.player.on("buffered",({percent:s})=>{this.duration&&(this.secondsLoaded=this.duration*s)}),this.props.muted&&this.player.mute())},this.props.onError)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){}seekTo(e,r=!0){this.callPlayer("setCurrentTime",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e*100)}setLoop(e){this.callPlayer("setLoop",e)}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return this.secondsLoaded}render(){const e=this.props.url.match(d.MATCH_URL_STREAMABLE)[1],r={width:"100%",height:"100%"};return p.default.createElement("iframe",{ref:this.ref,src:`https://streamable.com/o/${e}`,frameBorder:"0",scrolling:"no",style:r,allow:"encrypted-media; autoplay; fullscreen;"})}}o(i,"displayName","Streamable");o(i,"canPlay",d.canPlay.streamable);const x=m(y),N=P({__proto__:null,default:x},[y]);export{N as S}; diff --git a/build/assets/Tabs-7ecc0b57.js b/build/assets/Tabs-71f3fbcc.js similarity index 84% rename from build/assets/Tabs-7ecc0b57.js rename to build/assets/Tabs-71f3fbcc.js index efec1206b..b84f4296d 100644 --- a/build/assets/Tabs-7ecc0b57.js +++ b/build/assets/Tabs-71f3fbcc.js @@ -1 +1 @@ -import{M as ft,L as pt,N as O,X as Pt,Y as Lt,O as b,r as c,S as ht,H as rt,U as L,j as S,V as St,$ as Zt,a3 as Nt,a2 as ut}from"./index-4bb27744.js";import{G as $t,y as kt,Q as lt,w as te}from"./index-7730ff6f.js";import{c as Ft}from"./createSvgIcon-41051178.js";let U;function At(){if(U)return U;const t=document.createElement("div"),e=document.createElement("div");return e.style.width="10px",e.style.height="1px",t.appendChild(e),t.dir="rtl",t.style.fontSize="14px",t.style.width="4px",t.style.height="1px",t.style.position="absolute",t.style.top="-1000px",t.style.overflow="scroll",document.body.appendChild(t),U="reverse",t.scrollLeft>0?U="default":(t.scrollLeft=1,t.scrollLeft===0&&(U="negative")),document.body.removeChild(t),U}function ee(t,e){const r=t.scrollLeft;if(e!=="rtl")return r;switch(At()){case"negative":return t.scrollWidth-t.clientWidth+r;case"reverse":return t.scrollWidth-t.clientWidth-r;default:return r}}function oe(t){return pt("MuiTab",t)}const le=ft("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","iconWrapper"]),A=le,re=["className","disabled","disableFocusRipple","fullWidth","icon","iconPosition","indicator","label","onChange","onClick","onFocus","selected","selectionFollowsFocus","textColor","value","wrapped"],ne=t=>{const{classes:e,textColor:r,fullWidth:a,wrapped:n,icon:d,label:h,selected:p,disabled:u}=t,m={root:["root",d&&h&&"labelIcon",`textColor${Lt(r)}`,a&&"fullWidth",n&&"wrapped",p&&"selected",u&&"disabled"],iconWrapper:["iconWrapper"]};return St(m,oe,e)},se=O(Pt,{name:"MuiTab",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[e.root,r.label&&r.icon&&e.labelIcon,e[`textColor${Lt(r.textColor)}`],r.fullWidth&&e.fullWidth,r.wrapped&&e.wrapped]}})(({theme:t,ownerState:e})=>b({},t.typography.button,{maxWidth:360,minWidth:90,position:"relative",minHeight:48,flexShrink:0,padding:"12px 16px",overflow:"hidden",whiteSpace:"normal",textAlign:"center"},e.label&&{flexDirection:e.iconPosition==="top"||e.iconPosition==="bottom"?"column":"row"},{lineHeight:1.25},e.icon&&e.label&&{minHeight:72,paddingTop:9,paddingBottom:9,[`& > .${A.iconWrapper}`]:b({},e.iconPosition==="top"&&{marginBottom:6},e.iconPosition==="bottom"&&{marginTop:6},e.iconPosition==="start"&&{marginRight:t.spacing(1)},e.iconPosition==="end"&&{marginLeft:t.spacing(1)})},e.textColor==="inherit"&&{color:"inherit",opacity:.6,[`&.${A.selected}`]:{opacity:1},[`&.${A.disabled}`]:{opacity:(t.vars||t).palette.action.disabledOpacity}},e.textColor==="primary"&&{color:(t.vars||t).palette.text.secondary,[`&.${A.selected}`]:{color:(t.vars||t).palette.primary.main},[`&.${A.disabled}`]:{color:(t.vars||t).palette.text.disabled}},e.textColor==="secondary"&&{color:(t.vars||t).palette.text.secondary,[`&.${A.selected}`]:{color:(t.vars||t).palette.secondary.main},[`&.${A.disabled}`]:{color:(t.vars||t).palette.text.disabled}},e.fullWidth&&{flexShrink:1,flexGrow:1,flexBasis:0,maxWidth:"none"},e.wrapped&&{fontSize:t.typography.pxToRem(12)})),ae=c.forwardRef(function(e,r){const a=ht({props:e,name:"MuiTab"}),{className:n,disabled:d=!1,disableFocusRipple:h=!1,fullWidth:p,icon:u,iconPosition:m="top",indicator:w,label:T,onChange:y,onClick:x,onFocus:j,selected:I,selectionFollowsFocus:g,textColor:H="inherit",value:C,wrapped:nt=!1}=a,X=rt(a,re),Y=b({},a,{disabled:d,disableFocusRipple:h,selected:I,icon:!!u,iconPosition:m,label:!!T,fullWidth:p,textColor:H,wrapped:nt}),D=ne(Y),N=u&&T&&c.isValidElement(u)?c.cloneElement(u,{className:L(D.iconWrapper,u.props.className)}):u,Q=R=>{!I&&y&&y(R,C),x&&x(R)},_=R=>{g&&!I&&y&&y(R,C),j&&j(R)};return S.jsxs(se,b({focusRipple:!h,className:L(D.root,n),ref:r,role:"tab","aria-selected":I,disabled:d,onClick:Q,onFocus:_,ownerState:Y,tabIndex:I?0:-1},X,{children:[m==="top"||m==="start"?S.jsxs(c.Fragment,{children:[N,T]}):S.jsxs(c.Fragment,{children:[T,N]}),w]}))}),ke=ae,ie=Ft(S.jsx("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"}),"KeyboardArrowLeft"),ce=Ft(S.jsx("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}),"KeyboardArrowRight");function de(t){return(1+Math.sin(Math.PI*t-Math.PI/2))/2}function ue(t,e,r,a={},n=()=>{}){const{ease:d=de,duration:h=300}=a;let p=null;const u=e[t];let m=!1;const w=()=>{m=!0},T=y=>{if(m){n(new Error("Animation cancelled"));return}p===null&&(p=y);const x=Math.min(1,(y-p)/h);if(e[t]=d(x)*(r-u)+u,x>=1){requestAnimationFrame(()=>{n(null)});return}requestAnimationFrame(T)};return u===r?(n(new Error("Element already at target position")),w):(requestAnimationFrame(T),w)}const be=["onChange"],fe={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll"};function pe(t){const{onChange:e}=t,r=rt(t,be),a=c.useRef(),n=c.useRef(null),d=()=>{a.current=n.current.offsetHeight-n.current.clientHeight};return Zt(()=>{const h=$t(()=>{const u=a.current;d(),u!==a.current&&e(a.current)}),p=kt(n.current);return p.addEventListener("resize",h),()=>{h.clear(),p.removeEventListener("resize",h)}},[e]),c.useEffect(()=>{d(),e(a.current)},[e]),S.jsx("div",b({style:fe,ref:n},r))}function he(t){return pt("MuiTabScrollButton",t)}const Se=ft("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),ve=Se,me=["className","slots","slotProps","direction","orientation","disabled"],xe=t=>{const{classes:e,orientation:r,disabled:a}=t;return St({root:["root",r,a&&"disabled"]},he,e)},ge=O(Pt,{name:"MuiTabScrollButton",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[e.root,r.orientation&&e[r.orientation]]}})(({ownerState:t})=>b({width:40,flexShrink:0,opacity:.8,[`&.${ve.disabled}`]:{opacity:0}},t.orientation==="vertical"&&{width:"100%",height:40,"& svg":{transform:`rotate(${t.isRtl?-90:90}deg)`}})),ye=c.forwardRef(function(e,r){var a,n;const d=ht({props:e,name:"MuiTabScrollButton"}),{className:h,slots:p={},slotProps:u={},direction:m}=d,w=rt(d,me),y=Nt().direction==="rtl",x=b({isRtl:y},d),j=xe(x),I=(a=p.StartScrollButtonIcon)!=null?a:ie,g=(n=p.EndScrollButtonIcon)!=null?n:ce,H=lt({elementType:I,externalSlotProps:u.startScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:x}),C=lt({elementType:g,externalSlotProps:u.endScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:x});return S.jsx(ge,b({component:"div",className:L(j.root,h),ref:r,role:null,ownerState:x,tabIndex:null},w,{children:m==="left"?S.jsx(I,b({},H)):S.jsx(g,b({},C))}))}),Ce=ye;function Be(t){return pt("MuiTabs",t)}const we=ft("MuiTabs",["root","vertical","flexContainer","flexContainerVertical","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]),bt=we,Te=["aria-label","aria-labelledby","action","centered","children","className","component","allowScrollButtonsMobile","indicatorColor","onChange","orientation","ScrollButtonComponent","scrollButtons","selectionFollowsFocus","slots","slotProps","TabIndicatorProps","TabScrollButtonProps","textColor","value","variant","visibleScrollbar"],Rt=(t,e)=>t===e?t.firstChild:e&&e.nextElementSibling?e.nextElementSibling:t.firstChild,zt=(t,e)=>t===e?t.lastChild:e&&e.previousElementSibling?e.previousElementSibling:t.lastChild,ot=(t,e,r)=>{let a=!1,n=r(t,e);for(;n;){if(n===t.firstChild){if(a)return;a=!0}const d=n.disabled||n.getAttribute("aria-disabled")==="true";if(!n.hasAttribute("tabindex")||d)n=r(t,n);else{n.focus();return}}},Ie=t=>{const{vertical:e,fixed:r,hideScrollbar:a,scrollableX:n,scrollableY:d,centered:h,scrollButtonsHideMobile:p,classes:u}=t;return St({root:["root",e&&"vertical"],scroller:["scroller",r&&"fixed",a&&"hideScrollbar",n&&"scrollableX",d&&"scrollableY"],flexContainer:["flexContainer",e&&"flexContainerVertical",h&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",p&&"scrollButtonsHideMobile"],scrollableX:[n&&"scrollableX"],hideScrollbar:[a&&"hideScrollbar"]},Be,u)},Ee=O("div",{name:"MuiTabs",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[{[`& .${bt.scrollButtons}`]:e.scrollButtons},{[`& .${bt.scrollButtons}`]:r.scrollButtonsHideMobile&&e.scrollButtonsHideMobile},e.root,r.vertical&&e.vertical]}})(({ownerState:t,theme:e})=>b({overflow:"hidden",minHeight:48,WebkitOverflowScrolling:"touch",display:"flex"},t.vertical&&{flexDirection:"column"},t.scrollButtonsHideMobile&&{[`& .${bt.scrollButtons}`]:{[e.breakpoints.down("sm")]:{display:"none"}}})),Me=O("div",{name:"MuiTabs",slot:"Scroller",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[e.scroller,r.fixed&&e.fixed,r.hideScrollbar&&e.hideScrollbar,r.scrollableX&&e.scrollableX,r.scrollableY&&e.scrollableY]}})(({ownerState:t})=>b({position:"relative",display:"inline-block",flex:"1 1 auto",whiteSpace:"nowrap"},t.fixed&&{overflowX:"hidden",width:"100%"},t.hideScrollbar&&{scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}},t.scrollableX&&{overflowX:"auto",overflowY:"hidden"},t.scrollableY&&{overflowY:"auto",overflowX:"hidden"})),Re=O("div",{name:"MuiTabs",slot:"FlexContainer",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[e.flexContainer,r.vertical&&e.flexContainerVertical,r.centered&&e.centered]}})(({ownerState:t})=>b({display:"flex"},t.vertical&&{flexDirection:"column"},t.centered&&{justifyContent:"center"})),ze=O("span",{name:"MuiTabs",slot:"Indicator",overridesResolver:(t,e)=>e.indicator})(({ownerState:t,theme:e})=>b({position:"absolute",height:2,bottom:0,width:"100%",transition:e.transitions.create()},t.indicatorColor==="primary"&&{backgroundColor:(e.vars||e).palette.primary.main},t.indicatorColor==="secondary"&&{backgroundColor:(e.vars||e).palette.secondary.main},t.vertical&&{height:"100%",width:2,right:0})),We=O(pe)({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),Wt={},Pe=c.forwardRef(function(e,r){const a=ht({props:e,name:"MuiTabs"}),n=Nt(),d=n.direction==="rtl",{"aria-label":h,"aria-labelledby":p,action:u,centered:m=!1,children:w,className:T,component:y="div",allowScrollButtonsMobile:x=!1,indicatorColor:j="primary",onChange:I,orientation:g="horizontal",ScrollButtonComponent:H=Ce,scrollButtons:C="auto",selectionFollowsFocus:nt,slots:X={},slotProps:Y={},TabIndicatorProps:D={},TabScrollButtonProps:N={},textColor:Q="primary",value:_,variant:R="standard",visibleScrollbar:st=!1}=a,Ot=rt(a,Te),E=R==="scrollable",B=g==="vertical",V=B?"scrollTop":"scrollLeft",J=B?"top":"left",Z=B?"bottom":"right",at=B?"clientHeight":"clientWidth",K=B?"height":"width",$=b({},a,{component:y,allowScrollButtonsMobile:x,indicatorColor:j,orientation:g,vertical:B,scrollButtons:C,textColor:Q,variant:R,visibleScrollbar:st,fixed:!E,hideScrollbar:E&&!st,scrollableX:E&&!B,scrollableY:E&&B,centered:m&&!E,scrollButtonsHideMobile:!x}),W=Ie($),jt=lt({elementType:X.StartScrollButtonIcon,externalSlotProps:Y.startScrollButtonIcon,ownerState:$}),Ht=lt({elementType:X.EndScrollButtonIcon,externalSlotProps:Y.endScrollButtonIcon,ownerState:$}),[vt,Xt]=c.useState(!1),[k,mt]=c.useState(Wt),[xt,Dt]=c.useState(!1),[gt,_t]=c.useState(!1),[yt,Ut]=c.useState(!1),[Ct,Yt]=c.useState({overflow:"hidden",scrollbarWidth:0}),Bt=new Map,z=c.useRef(null),F=c.useRef(null),wt=()=>{const o=z.current;let l;if(o){const s=o.getBoundingClientRect();l={clientWidth:o.clientWidth,scrollLeft:o.scrollLeft,scrollTop:o.scrollTop,scrollLeftNormalized:ee(o,n.direction),scrollWidth:o.scrollWidth,top:s.top,bottom:s.bottom,left:s.left,right:s.right}}let i;if(o&&_!==!1){const s=F.current.children;if(s.length>0){const f=s[Bt.get(_)];i=f?f.getBoundingClientRect():null}}return{tabsMeta:l,tabMeta:i}},q=ut(()=>{const{tabsMeta:o,tabMeta:l}=wt();let i=0,s;if(B)s="top",l&&o&&(i=l.top-o.top+o.scrollTop);else if(s=d?"right":"left",l&&o){const v=d?o.scrollLeftNormalized+o.clientWidth-o.scrollWidth:o.scrollLeft;i=(d?-1:1)*(l[s]-o[s]+v)}const f={[s]:i,[K]:l?l[K]:0};if(isNaN(k[s])||isNaN(k[K]))mt(f);else{const v=Math.abs(k[s]-f[s]),M=Math.abs(k[K]-f[K]);(v>=1||M>=1)&&mt(f)}}),it=(o,{animation:l=!0}={})=>{l?ue(V,z.current,o,{duration:n.transitions.duration.standard}):z.current[V]=o},Tt=o=>{let l=z.current[V];B?l+=o:(l+=o*(d?-1:1),l*=d&&At()==="reverse"?-1:1),it(l)},It=()=>{const o=z.current[at];let l=0;const i=Array.from(F.current.children);for(let s=0;so){s===0&&(l=o);break}l+=f[at]}return l},Vt=()=>{Tt(-1*It())},Kt=()=>{Tt(It())},qt=c.useCallback(o=>{Yt({overflow:null,scrollbarWidth:o})},[]),Gt=()=>{const o={};o.scrollbarSizeListener=E?S.jsx(We,{onChange:qt,className:L(W.scrollableX,W.hideScrollbar)}):null;const i=E&&(C==="auto"&&(xt||gt)||C===!0);return o.scrollButtonStart=i?S.jsx(H,b({slots:{StartScrollButtonIcon:X.StartScrollButtonIcon},slotProps:{startScrollButtonIcon:jt},orientation:g,direction:d?"right":"left",onClick:Vt,disabled:!xt},N,{className:L(W.scrollButtons,N.className)})):null,o.scrollButtonEnd=i?S.jsx(H,b({slots:{EndScrollButtonIcon:X.EndScrollButtonIcon},slotProps:{endScrollButtonIcon:Ht},orientation:g,direction:d?"left":"right",onClick:Kt,disabled:!gt},N,{className:L(W.scrollButtons,N.className)})):null,o},Et=ut(o=>{const{tabsMeta:l,tabMeta:i}=wt();if(!(!i||!l)){if(i[J]l[Z]){const s=l[V]+(i[Z]-l[Z]);it(s,{animation:o})}}}),tt=ut(()=>{E&&C!==!1&&Ut(!yt)});c.useEffect(()=>{const o=$t(()=>{z.current&&q()});let l;const i=v=>{v.forEach(M=>{M.removedNodes.forEach(G=>{var P;(P=l)==null||P.unobserve(G)}),M.addedNodes.forEach(G=>{var P;(P=l)==null||P.observe(G)})}),o(),tt()},s=kt(z.current);s.addEventListener("resize",o);let f;return typeof ResizeObserver<"u"&&(l=new ResizeObserver(o),Array.from(F.current.children).forEach(v=>{l.observe(v)})),typeof MutationObserver<"u"&&(f=new MutationObserver(i),f.observe(F.current,{childList:!0})),()=>{var v,M;o.clear(),s.removeEventListener("resize",o),(v=f)==null||v.disconnect(),(M=l)==null||M.disconnect()}},[q,tt]),c.useEffect(()=>{const o=Array.from(F.current.children),l=o.length;if(typeof IntersectionObserver<"u"&&l>0&&E&&C!==!1){const i=o[0],s=o[l-1],f={root:z.current,threshold:.99},v=dt=>{Dt(!dt[0].isIntersecting)},M=new IntersectionObserver(v,f);M.observe(i);const G=dt=>{_t(!dt[0].isIntersecting)},P=new IntersectionObserver(G,f);return P.observe(s),()=>{M.disconnect(),P.disconnect()}}},[E,C,yt,w==null?void 0:w.length]),c.useEffect(()=>{Xt(!0)},[]),c.useEffect(()=>{q()}),c.useEffect(()=>{Et(Wt!==k)},[Et,k]),c.useImperativeHandle(u,()=>({updateIndicator:q,updateScrollButtons:tt}),[q,tt]);const Mt=S.jsx(ze,b({},D,{className:L(W.indicator,D.className),ownerState:$,style:b({},k,D.style)}));let et=0;const Qt=c.Children.map(w,o=>{if(!c.isValidElement(o))return null;const l=o.props.value===void 0?et:o.props.value;Bt.set(l,et);const i=l===_;return et+=1,c.cloneElement(o,b({fullWidth:R==="fullWidth",indicator:i&&!vt&&Mt,selected:i,selectionFollowsFocus:nt,onChange:I,textColor:Q,value:l},et===1&&_===!1&&!o.props.tabIndex?{tabIndex:0}:{}))}),Jt=o=>{const l=F.current,i=te(l).activeElement;if(i.getAttribute("role")!=="tab")return;let f=g==="horizontal"?"ArrowLeft":"ArrowUp",v=g==="horizontal"?"ArrowRight":"ArrowDown";switch(g==="horizontal"&&d&&(f="ArrowRight",v="ArrowLeft"),o.key){case f:o.preventDefault(),ot(l,i,zt);break;case v:o.preventDefault(),ot(l,i,Rt);break;case"Home":o.preventDefault(),ot(l,null,Rt);break;case"End":o.preventDefault(),ot(l,null,zt);break}},ct=Gt();return S.jsxs(Ee,b({className:L(W.root,T),ownerState:$,ref:r,as:y},Ot,{children:[ct.scrollButtonStart,ct.scrollbarSizeListener,S.jsxs(Me,{className:W.scroller,ownerState:$,style:{overflow:Ct.overflow,[B?`margin${d?"Left":"Right"}`:"marginBottom"]:st?void 0:-Ct.scrollbarWidth},ref:z,children:[S.jsx(Re,{"aria-label":h,"aria-labelledby":p,"aria-orientation":g==="vertical"?"vertical":null,className:W.flexContainer,ownerState:$,onKeyDown:Jt,ref:F,role:"tablist",children:Qt}),vt&&Mt]}),ct.scrollButtonEnd]}))}),Fe=Pe;export{Fe as T,ke as a}; +import{L as ft,K as pt,M as O,V as Wt,X as Lt,N as b,r as c,P as ht,G as rt,S as L,j as S,U as St,Z as Jt,a2 as Nt,a1 as ut}from"./index-4e60c9e2.js";import{G as $t,y as kt,Q as lt,w as te}from"./index-af5a3f81.js";import{c as Ft}from"./createSvgIcon-c125a9c8.js";let U;function At(){if(U)return U;const t=document.createElement("div"),e=document.createElement("div");return e.style.width="10px",e.style.height="1px",t.appendChild(e),t.dir="rtl",t.style.fontSize="14px",t.style.width="4px",t.style.height="1px",t.style.position="absolute",t.style.top="-1000px",t.style.overflow="scroll",document.body.appendChild(t),U="reverse",t.scrollLeft>0?U="default":(t.scrollLeft=1,t.scrollLeft===0&&(U="negative")),document.body.removeChild(t),U}function ee(t,e){const r=t.scrollLeft;if(e!=="rtl")return r;switch(At()){case"negative":return t.scrollWidth-t.clientWidth+r;case"reverse":return t.scrollWidth-t.clientWidth-r;default:return r}}function oe(t){return pt("MuiTab",t)}const le=ft("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","iconWrapper"]),A=le,re=["className","disabled","disableFocusRipple","fullWidth","icon","iconPosition","indicator","label","onChange","onClick","onFocus","selected","selectionFollowsFocus","textColor","value","wrapped"],ne=t=>{const{classes:e,textColor:r,fullWidth:a,wrapped:n,icon:d,label:h,selected:p,disabled:u}=t,m={root:["root",d&&h&&"labelIcon",`textColor${Lt(r)}`,a&&"fullWidth",n&&"wrapped",p&&"selected",u&&"disabled"],iconWrapper:["iconWrapper"]};return St(m,oe,e)},se=O(Wt,{name:"MuiTab",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[e.root,r.label&&r.icon&&e.labelIcon,e[`textColor${Lt(r.textColor)}`],r.fullWidth&&e.fullWidth,r.wrapped&&e.wrapped]}})(({theme:t,ownerState:e})=>b({},t.typography.button,{maxWidth:360,minWidth:90,position:"relative",minHeight:48,flexShrink:0,padding:"12px 16px",overflow:"hidden",whiteSpace:"normal",textAlign:"center"},e.label&&{flexDirection:e.iconPosition==="top"||e.iconPosition==="bottom"?"column":"row"},{lineHeight:1.25},e.icon&&e.label&&{minHeight:72,paddingTop:9,paddingBottom:9,[`& > .${A.iconWrapper}`]:b({},e.iconPosition==="top"&&{marginBottom:6},e.iconPosition==="bottom"&&{marginTop:6},e.iconPosition==="start"&&{marginRight:t.spacing(1)},e.iconPosition==="end"&&{marginLeft:t.spacing(1)})},e.textColor==="inherit"&&{color:"inherit",opacity:.6,[`&.${A.selected}`]:{opacity:1},[`&.${A.disabled}`]:{opacity:(t.vars||t).palette.action.disabledOpacity}},e.textColor==="primary"&&{color:(t.vars||t).palette.text.secondary,[`&.${A.selected}`]:{color:(t.vars||t).palette.primary.main},[`&.${A.disabled}`]:{color:(t.vars||t).palette.text.disabled}},e.textColor==="secondary"&&{color:(t.vars||t).palette.text.secondary,[`&.${A.selected}`]:{color:(t.vars||t).palette.secondary.main},[`&.${A.disabled}`]:{color:(t.vars||t).palette.text.disabled}},e.fullWidth&&{flexShrink:1,flexGrow:1,flexBasis:0,maxWidth:"none"},e.wrapped&&{fontSize:t.typography.pxToRem(12)})),ae=c.forwardRef(function(e,r){const a=ht({props:e,name:"MuiTab"}),{className:n,disabled:d=!1,disableFocusRipple:h=!1,fullWidth:p,icon:u,iconPosition:m="top",indicator:w,label:T,onChange:y,onClick:x,onFocus:j,selected:I,selectionFollowsFocus:g,textColor:H="inherit",value:C,wrapped:nt=!1}=a,X=rt(a,re),Y=b({},a,{disabled:d,disableFocusRipple:h,selected:I,icon:!!u,iconPosition:m,label:!!T,fullWidth:p,textColor:H,wrapped:nt}),D=ne(Y),N=u&&T&&c.isValidElement(u)?c.cloneElement(u,{className:L(D.iconWrapper,u.props.className)}):u,Q=R=>{!I&&y&&y(R,C),x&&x(R)},_=R=>{g&&!I&&y&&y(R,C),j&&j(R)};return S.jsxs(se,b({focusRipple:!h,className:L(D.root,n),ref:r,role:"tab","aria-selected":I,disabled:d,onClick:Q,onFocus:_,ownerState:Y,tabIndex:I?0:-1},X,{children:[m==="top"||m==="start"?S.jsxs(c.Fragment,{children:[N,T]}):S.jsxs(c.Fragment,{children:[T,N]}),w]}))}),ke=ae,ie=Ft(S.jsx("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"}),"KeyboardArrowLeft"),ce=Ft(S.jsx("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}),"KeyboardArrowRight");function de(t){return(1+Math.sin(Math.PI*t-Math.PI/2))/2}function ue(t,e,r,a={},n=()=>{}){const{ease:d=de,duration:h=300}=a;let p=null;const u=e[t];let m=!1;const w=()=>{m=!0},T=y=>{if(m){n(new Error("Animation cancelled"));return}p===null&&(p=y);const x=Math.min(1,(y-p)/h);if(e[t]=d(x)*(r-u)+u,x>=1){requestAnimationFrame(()=>{n(null)});return}requestAnimationFrame(T)};return u===r?(n(new Error("Element already at target position")),w):(requestAnimationFrame(T),w)}const be=["onChange"],fe={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll"};function pe(t){const{onChange:e}=t,r=rt(t,be),a=c.useRef(),n=c.useRef(null),d=()=>{a.current=n.current.offsetHeight-n.current.clientHeight};return Jt(()=>{const h=$t(()=>{const u=a.current;d(),u!==a.current&&e(a.current)}),p=kt(n.current);return p.addEventListener("resize",h),()=>{h.clear(),p.removeEventListener("resize",h)}},[e]),c.useEffect(()=>{d(),e(a.current)},[e]),S.jsx("div",b({style:fe,ref:n},r))}function he(t){return pt("MuiTabScrollButton",t)}const Se=ft("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),ve=Se,me=["className","slots","slotProps","direction","orientation","disabled"],xe=t=>{const{classes:e,orientation:r,disabled:a}=t;return St({root:["root",r,a&&"disabled"]},he,e)},ge=O(Wt,{name:"MuiTabScrollButton",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[e.root,r.orientation&&e[r.orientation]]}})(({ownerState:t})=>b({width:40,flexShrink:0,opacity:.8,[`&.${ve.disabled}`]:{opacity:0}},t.orientation==="vertical"&&{width:"100%",height:40,"& svg":{transform:`rotate(${t.isRtl?-90:90}deg)`}})),ye=c.forwardRef(function(e,r){var a,n;const d=ht({props:e,name:"MuiTabScrollButton"}),{className:h,slots:p={},slotProps:u={},direction:m}=d,w=rt(d,me),y=Nt().direction==="rtl",x=b({isRtl:y},d),j=xe(x),I=(a=p.StartScrollButtonIcon)!=null?a:ie,g=(n=p.EndScrollButtonIcon)!=null?n:ce,H=lt({elementType:I,externalSlotProps:u.startScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:x}),C=lt({elementType:g,externalSlotProps:u.endScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:x});return S.jsx(ge,b({component:"div",className:L(j.root,h),ref:r,role:null,ownerState:x,tabIndex:null},w,{children:m==="left"?S.jsx(I,b({},H)):S.jsx(g,b({},C))}))}),Ce=ye;function Be(t){return pt("MuiTabs",t)}const we=ft("MuiTabs",["root","vertical","flexContainer","flexContainerVertical","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]),bt=we,Te=["aria-label","aria-labelledby","action","centered","children","className","component","allowScrollButtonsMobile","indicatorColor","onChange","orientation","ScrollButtonComponent","scrollButtons","selectionFollowsFocus","slots","slotProps","TabIndicatorProps","TabScrollButtonProps","textColor","value","variant","visibleScrollbar"],Rt=(t,e)=>t===e?t.firstChild:e&&e.nextElementSibling?e.nextElementSibling:t.firstChild,zt=(t,e)=>t===e?t.lastChild:e&&e.previousElementSibling?e.previousElementSibling:t.lastChild,ot=(t,e,r)=>{let a=!1,n=r(t,e);for(;n;){if(n===t.firstChild){if(a)return;a=!0}const d=n.disabled||n.getAttribute("aria-disabled")==="true";if(!n.hasAttribute("tabindex")||d)n=r(t,n);else{n.focus();return}}},Ie=t=>{const{vertical:e,fixed:r,hideScrollbar:a,scrollableX:n,scrollableY:d,centered:h,scrollButtonsHideMobile:p,classes:u}=t;return St({root:["root",e&&"vertical"],scroller:["scroller",r&&"fixed",a&&"hideScrollbar",n&&"scrollableX",d&&"scrollableY"],flexContainer:["flexContainer",e&&"flexContainerVertical",h&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",p&&"scrollButtonsHideMobile"],scrollableX:[n&&"scrollableX"],hideScrollbar:[a&&"hideScrollbar"]},Be,u)},Ee=O("div",{name:"MuiTabs",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[{[`& .${bt.scrollButtons}`]:e.scrollButtons},{[`& .${bt.scrollButtons}`]:r.scrollButtonsHideMobile&&e.scrollButtonsHideMobile},e.root,r.vertical&&e.vertical]}})(({ownerState:t,theme:e})=>b({overflow:"hidden",minHeight:48,WebkitOverflowScrolling:"touch",display:"flex"},t.vertical&&{flexDirection:"column"},t.scrollButtonsHideMobile&&{[`& .${bt.scrollButtons}`]:{[e.breakpoints.down("sm")]:{display:"none"}}})),Me=O("div",{name:"MuiTabs",slot:"Scroller",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[e.scroller,r.fixed&&e.fixed,r.hideScrollbar&&e.hideScrollbar,r.scrollableX&&e.scrollableX,r.scrollableY&&e.scrollableY]}})(({ownerState:t})=>b({position:"relative",display:"inline-block",flex:"1 1 auto",whiteSpace:"nowrap"},t.fixed&&{overflowX:"hidden",width:"100%"},t.hideScrollbar&&{scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}},t.scrollableX&&{overflowX:"auto",overflowY:"hidden"},t.scrollableY&&{overflowY:"auto",overflowX:"hidden"})),Re=O("div",{name:"MuiTabs",slot:"FlexContainer",overridesResolver:(t,e)=>{const{ownerState:r}=t;return[e.flexContainer,r.vertical&&e.flexContainerVertical,r.centered&&e.centered]}})(({ownerState:t})=>b({display:"flex"},t.vertical&&{flexDirection:"column"},t.centered&&{justifyContent:"center"})),ze=O("span",{name:"MuiTabs",slot:"Indicator",overridesResolver:(t,e)=>e.indicator})(({ownerState:t,theme:e})=>b({position:"absolute",height:2,bottom:0,width:"100%",transition:e.transitions.create()},t.indicatorColor==="primary"&&{backgroundColor:(e.vars||e).palette.primary.main},t.indicatorColor==="secondary"&&{backgroundColor:(e.vars||e).palette.secondary.main},t.vertical&&{height:"100%",width:2,right:0})),Pe=O(pe)({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),Pt={},We=c.forwardRef(function(e,r){const a=ht({props:e,name:"MuiTabs"}),n=Nt(),d=n.direction==="rtl",{"aria-label":h,"aria-labelledby":p,action:u,centered:m=!1,children:w,className:T,component:y="div",allowScrollButtonsMobile:x=!1,indicatorColor:j="primary",onChange:I,orientation:g="horizontal",ScrollButtonComponent:H=Ce,scrollButtons:C="auto",selectionFollowsFocus:nt,slots:X={},slotProps:Y={},TabIndicatorProps:D={},TabScrollButtonProps:N={},textColor:Q="primary",value:_,variant:R="standard",visibleScrollbar:st=!1}=a,Ot=rt(a,Te),E=R==="scrollable",B=g==="vertical",K=B?"scrollTop":"scrollLeft",Z=B?"top":"left",J=B?"bottom":"right",at=B?"clientHeight":"clientWidth",V=B?"height":"width",$=b({},a,{component:y,allowScrollButtonsMobile:x,indicatorColor:j,orientation:g,vertical:B,scrollButtons:C,textColor:Q,variant:R,visibleScrollbar:st,fixed:!E,hideScrollbar:E&&!st,scrollableX:E&&!B,scrollableY:E&&B,centered:m&&!E,scrollButtonsHideMobile:!x}),P=Ie($),jt=lt({elementType:X.StartScrollButtonIcon,externalSlotProps:Y.startScrollButtonIcon,ownerState:$}),Ht=lt({elementType:X.EndScrollButtonIcon,externalSlotProps:Y.endScrollButtonIcon,ownerState:$}),[vt,Xt]=c.useState(!1),[k,mt]=c.useState(Pt),[xt,Dt]=c.useState(!1),[gt,_t]=c.useState(!1),[yt,Ut]=c.useState(!1),[Ct,Yt]=c.useState({overflow:"hidden",scrollbarWidth:0}),Bt=new Map,z=c.useRef(null),F=c.useRef(null),wt=()=>{const o=z.current;let l;if(o){const s=o.getBoundingClientRect();l={clientWidth:o.clientWidth,scrollLeft:o.scrollLeft,scrollTop:o.scrollTop,scrollLeftNormalized:ee(o,n.direction),scrollWidth:o.scrollWidth,top:s.top,bottom:s.bottom,left:s.left,right:s.right}}let i;if(o&&_!==!1){const s=F.current.children;if(s.length>0){const f=s[Bt.get(_)];i=f?f.getBoundingClientRect():null}}return{tabsMeta:l,tabMeta:i}},q=ut(()=>{const{tabsMeta:o,tabMeta:l}=wt();let i=0,s;if(B)s="top",l&&o&&(i=l.top-o.top+o.scrollTop);else if(s=d?"right":"left",l&&o){const v=d?o.scrollLeftNormalized+o.clientWidth-o.scrollWidth:o.scrollLeft;i=(d?-1:1)*(l[s]-o[s]+v)}const f={[s]:i,[V]:l?l[V]:0};if(isNaN(k[s])||isNaN(k[V]))mt(f);else{const v=Math.abs(k[s]-f[s]),M=Math.abs(k[V]-f[V]);(v>=1||M>=1)&&mt(f)}}),it=(o,{animation:l=!0}={})=>{l?ue(K,z.current,o,{duration:n.transitions.duration.standard}):z.current[K]=o},Tt=o=>{let l=z.current[K];B?l+=o:(l+=o*(d?-1:1),l*=d&&At()==="reverse"?-1:1),it(l)},It=()=>{const o=z.current[at];let l=0;const i=Array.from(F.current.children);for(let s=0;so){s===0&&(l=o);break}l+=f[at]}return l},Kt=()=>{Tt(-1*It())},Vt=()=>{Tt(It())},qt=c.useCallback(o=>{Yt({overflow:null,scrollbarWidth:o})},[]),Gt=()=>{const o={};o.scrollbarSizeListener=E?S.jsx(Pe,{onChange:qt,className:L(P.scrollableX,P.hideScrollbar)}):null;const i=E&&(C==="auto"&&(xt||gt)||C===!0);return o.scrollButtonStart=i?S.jsx(H,b({slots:{StartScrollButtonIcon:X.StartScrollButtonIcon},slotProps:{startScrollButtonIcon:jt},orientation:g,direction:d?"right":"left",onClick:Kt,disabled:!xt},N,{className:L(P.scrollButtons,N.className)})):null,o.scrollButtonEnd=i?S.jsx(H,b({slots:{EndScrollButtonIcon:X.EndScrollButtonIcon},slotProps:{endScrollButtonIcon:Ht},orientation:g,direction:d?"left":"right",onClick:Vt,disabled:!gt},N,{className:L(P.scrollButtons,N.className)})):null,o},Et=ut(o=>{const{tabsMeta:l,tabMeta:i}=wt();if(!(!i||!l)){if(i[Z]l[J]){const s=l[K]+(i[J]-l[J]);it(s,{animation:o})}}}),tt=ut(()=>{E&&C!==!1&&Ut(!yt)});c.useEffect(()=>{const o=$t(()=>{z.current&&q()});let l;const i=v=>{v.forEach(M=>{M.removedNodes.forEach(G=>{var W;(W=l)==null||W.unobserve(G)}),M.addedNodes.forEach(G=>{var W;(W=l)==null||W.observe(G)})}),o(),tt()},s=kt(z.current);s.addEventListener("resize",o);let f;return typeof ResizeObserver<"u"&&(l=new ResizeObserver(o),Array.from(F.current.children).forEach(v=>{l.observe(v)})),typeof MutationObserver<"u"&&(f=new MutationObserver(i),f.observe(F.current,{childList:!0})),()=>{var v,M;o.clear(),s.removeEventListener("resize",o),(v=f)==null||v.disconnect(),(M=l)==null||M.disconnect()}},[q,tt]),c.useEffect(()=>{const o=Array.from(F.current.children),l=o.length;if(typeof IntersectionObserver<"u"&&l>0&&E&&C!==!1){const i=o[0],s=o[l-1],f={root:z.current,threshold:.99},v=dt=>{Dt(!dt[0].isIntersecting)},M=new IntersectionObserver(v,f);M.observe(i);const G=dt=>{_t(!dt[0].isIntersecting)},W=new IntersectionObserver(G,f);return W.observe(s),()=>{M.disconnect(),W.disconnect()}}},[E,C,yt,w==null?void 0:w.length]),c.useEffect(()=>{Xt(!0)},[]),c.useEffect(()=>{q()}),c.useEffect(()=>{Et(Pt!==k)},[Et,k]),c.useImperativeHandle(u,()=>({updateIndicator:q,updateScrollButtons:tt}),[q,tt]);const Mt=S.jsx(ze,b({},D,{className:L(P.indicator,D.className),ownerState:$,style:b({},k,D.style)}));let et=0;const Qt=c.Children.map(w,o=>{if(!c.isValidElement(o))return null;const l=o.props.value===void 0?et:o.props.value;Bt.set(l,et);const i=l===_;return et+=1,c.cloneElement(o,b({fullWidth:R==="fullWidth",indicator:i&&!vt&&Mt,selected:i,selectionFollowsFocus:nt,onChange:I,textColor:Q,value:l},et===1&&_===!1&&!o.props.tabIndex?{tabIndex:0}:{}))}),Zt=o=>{const l=F.current,i=te(l).activeElement;if(i.getAttribute("role")!=="tab")return;let f=g==="horizontal"?"ArrowLeft":"ArrowUp",v=g==="horizontal"?"ArrowRight":"ArrowDown";switch(g==="horizontal"&&d&&(f="ArrowRight",v="ArrowLeft"),o.key){case f:o.preventDefault(),ot(l,i,zt);break;case v:o.preventDefault(),ot(l,i,Rt);break;case"Home":o.preventDefault(),ot(l,null,Rt);break;case"End":o.preventDefault(),ot(l,null,zt);break}},ct=Gt();return S.jsxs(Ee,b({className:L(P.root,T),ownerState:$,ref:r,as:y},Ot,{children:[ct.scrollButtonStart,ct.scrollbarSizeListener,S.jsxs(Me,{className:P.scroller,ownerState:$,style:{overflow:Ct.overflow,[B?`margin${d?"Left":"Right"}`:"marginBottom"]:st?void 0:-Ct.scrollbarWidth},ref:z,children:[S.jsx(Re,{"aria-label":h,"aria-labelledby":p,"aria-orientation":g==="vertical"?"vertical":null,className:P.flexContainer,ownerState:$,onKeyDown:Zt,ref:F,role:"tablist",children:Qt}),vt&&Mt]}),ct.scrollButtonEnd]}))}),Fe=We;export{Fe as T,ke as a}; diff --git a/build/assets/TextareaAutosize-b716e8d1.js b/build/assets/TextareaAutosize-f6242cb8.js similarity index 56% rename from build/assets/TextareaAutosize-b716e8d1.js rename to build/assets/TextareaAutosize-f6242cb8.js index 6c02af653..d8094fd03 100644 --- a/build/assets/TextareaAutosize-b716e8d1.js +++ b/build/assets/TextareaAutosize-f6242cb8.js @@ -1,2 +1,2 @@ -import{r as o,H as _,Z as I,$ as O,j as v,O as b,a1 as Z}from"./index-4bb27744.js";import{y as T,G as D}from"./index-7730ff6f.js";const G=["onChange","maxRows","minRows","style","value"];function m(r){return parseInt(r,10)||0}const P={shadow:{visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"}};function F(r){return r==null||Object.keys(r).length===0||r.outerHeightStyle===0&&!r.overflow}const $=o.forwardRef(function(l,M){const{onChange:R,maxRows:y,minRows:h=1,style:S,value:x}=l,k=_(l,G),{current:A}=o.useRef(x!=null),p=o.useRef(null),N=I(M,p),H=o.useRef(null),c=o.useRef(0),[z,E]=o.useState({outerHeightStyle:0}),f=o.useCallback(()=>{const e=p.current,n=T(e).getComputedStyle(e);if(n.width==="0px")return{outerHeightStyle:0};const t=H.current;t.style.width=n.width,t.value=e.value||l.placeholder||"x",t.value.slice(-1)===` -`&&(t.value+=" ");const g=n.boxSizing,w=m(n.paddingBottom)+m(n.paddingTop),a=m(n.borderBottomWidth)+m(n.borderTopWidth),u=t.scrollHeight;t.value="x";const d=t.scrollHeight;let s=u;h&&(s=Math.max(Number(h)*d,s)),y&&(s=Math.min(Number(y)*d,s)),s=Math.max(s,d);const B=s+(g==="border-box"?w+a:0),L=Math.abs(s-u)<=1;return{outerHeightStyle:B,overflow:L}},[y,h,l.placeholder]),C=(e,i)=>{const{outerHeightStyle:n,overflow:t}=i;return c.current<20&&(n>0&&Math.abs((e.outerHeightStyle||0)-n)>1||e.overflow!==t)?(c.current+=1,{overflow:t,outerHeightStyle:n}):e},W=o.useCallback(()=>{const e=f();F(e)||E(i=>C(i,e))},[f]);O(()=>{const e=()=>{const u=f();F(u)||Z.flushSync(()=>{E(d=>C(d,u))})},i=()=>{c.current=0,e()};let n;const t=D(i),g=p.current,w=T(g);w.addEventListener("resize",t);let a;return typeof ResizeObserver<"u"&&(a=new ResizeObserver(i),a.observe(g)),()=>{t.clear(),cancelAnimationFrame(n),w.removeEventListener("resize",t),a&&a.disconnect()}},[f]),O(()=>{W()}),o.useEffect(()=>{c.current=0},[x]);const j=e=>{c.current=0,A||W(),R&&R(e)};return v.jsxs(o.Fragment,{children:[v.jsx("textarea",b({value:x,onChange:j,ref:N,rows:h,style:b({height:z.outerHeightStyle,overflow:z.overflow?"hidden":void 0},S)},k)),v.jsx("textarea",{"aria-hidden":!0,className:l.className,readOnly:!0,ref:H,tabIndex:-1,style:b({},P.shadow,S,{paddingTop:0,paddingBottom:0})})]})});export{$ as T}; +import{r as o,G as _,Y as G,Z as T,j as v,N as b,a0 as I}from"./index-4e60c9e2.js";import{y as F,G as Z}from"./index-af5a3f81.js";const D=["onChange","maxRows","minRows","style","value"];function m(r){return parseInt(r,10)||0}const P={shadow:{visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"}};function M(r){return r==null||Object.keys(r).length===0||r.outerHeightStyle===0&&!r.overflow}const Y=o.forwardRef(function(l,N){const{onChange:R,maxRows:y,minRows:h=1,style:S,value:x}=l,O=_(l,D),{current:k}=o.useRef(x!=null),p=o.useRef(null),A=G(N,p),H=o.useRef(null),c=o.useRef(0),[z,E]=o.useState({outerHeightStyle:0}),f=o.useCallback(()=>{const e=p.current,n=F(e).getComputedStyle(e);if(n.width==="0px")return{outerHeightStyle:0};const t=H.current;t.style.width=n.width,t.value=e.value||l.placeholder||"x",t.value.slice(-1)===` +`&&(t.value+=" ");const g=n.boxSizing,w=m(n.paddingBottom)+m(n.paddingTop),a=m(n.borderBottomWidth)+m(n.borderTopWidth),u=t.scrollHeight;t.value="x";const d=t.scrollHeight;let s=u;h&&(s=Math.max(Number(h)*d,s)),y&&(s=Math.min(Number(y)*d,s)),s=Math.max(s,d);const B=s+(g==="border-box"?w+a:0),L=Math.abs(s-u)<=1;return{outerHeightStyle:B,overflow:L}},[y,h,l.placeholder]),C=(e,i)=>{const{outerHeightStyle:n,overflow:t}=i;return c.current<20&&(n>0&&Math.abs((e.outerHeightStyle||0)-n)>1||e.overflow!==t)?(c.current+=1,{overflow:t,outerHeightStyle:n}):e},W=o.useCallback(()=>{const e=f();M(e)||E(i=>C(i,e))},[f]);T(()=>{const e=()=>{const u=f();M(u)||I.flushSync(()=>{E(d=>C(d,u))})},i=()=>{c.current=0,e()};let n;const t=Z(i),g=p.current,w=F(g);w.addEventListener("resize",t);let a;return typeof ResizeObserver<"u"&&(a=new ResizeObserver(i),a.observe(g)),()=>{t.clear(),cancelAnimationFrame(n),w.removeEventListener("resize",t),a&&a.disconnect()}},[f]),T(()=>{W()}),o.useEffect(()=>{c.current=0},[x]);const j=e=>{c.current=0,k||W(),R&&R(e)};return v.jsxs(o.Fragment,{children:[v.jsx("textarea",b({value:x,onChange:j,ref:A,rows:h,style:b({height:z.outerHeightStyle,overflow:z.overflow?"hidden":void 0},S)},O)),v.jsx("textarea",{"aria-hidden":!0,className:l.className,readOnly:!0,ref:H,tabIndex:-1,style:b({},P.shadow,S,{paddingTop:0,paddingBottom:0})})]})});export{Y as T}; diff --git a/build/assets/Twitch-eec52ec3.js b/build/assets/Twitch-08c50d1f.js similarity index 95% rename from build/assets/Twitch-eec52ec3.js rename to build/assets/Twitch-08c50d1f.js index 285068b4d..e8099f5a9 100644 --- a/build/assets/Twitch-eec52ec3.js +++ b/build/assets/Twitch-08c50d1f.js @@ -1 +1 @@ -import{a9 as w,r as D}from"./index-4bb27744.js";import{u as C,p as N}from"./index-87de005d.js";function I(t,e){for(var r=0;rs[a]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var S=Object.create,l=Object.defineProperty,j=Object.getOwnPropertyDescriptor,A=Object.getOwnPropertyNames,M=Object.getPrototypeOf,H=Object.prototype.hasOwnProperty,R=(t,e,r)=>e in t?l(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,x=(t,e)=>{for(var r in e)l(t,r,{get:e[r],enumerable:!0})},_=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of A(e))!H.call(t,a)&&a!==r&&l(t,a,{get:()=>e[a],enumerable:!(s=j(e,a))||s.enumerable});return t},F=(t,e,r)=>(r=t!=null?S(M(t)):{},_(e||!t||!t.__esModule?l(r,"default",{value:t,enumerable:!0}):r,t)),U=t=>_(l({},"__esModule",{value:!0}),t),o=(t,e,r)=>(R(t,typeof e!="symbol"?e+"":e,r),r),P={};x(P,{default:()=>h});var f=U(P),d=F(D),c=C,u=N;const K="https://player.twitch.tv/js/embed/v1.js",V="Twitch",$="twitch-player-";class h extends d.Component{constructor(){super(...arguments),o(this,"callPlayer",c.callPlayer),o(this,"playerID",this.props.config.playerId||`${$}${(0,c.randomString)()}`),o(this,"mute",()=>{this.callPlayer("setMuted",!0)}),o(this,"unmute",()=>{this.callPlayer("setMuted",!1)})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e,r){const{playsinline:s,onError:a,config:n,controls:v}=this.props,i=u.MATCH_URL_TWITCH_CHANNEL.test(e),p=i?e.match(u.MATCH_URL_TWITCH_CHANNEL)[1]:e.match(u.MATCH_URL_TWITCH_VIDEO)[1];if(r){i?this.player.setChannel(p):this.player.setVideo("v"+p);return}(0,c.getSDK)(K,V).then(y=>{this.player=new y.Player(this.playerID,{video:i?"":p,channel:i?p:"",height:"100%",width:"100%",playsinline:s,autoplay:this.props.playing,muted:this.props.muted,controls:i?!0:v,time:(0,c.parseStartTime)(e),...n.options});const{READY:m,PLAYING:g,PAUSE:E,ENDED:O,ONLINE:L,OFFLINE:b,SEEK:T}=y.Player;this.player.addEventListener(m,this.props.onReady),this.player.addEventListener(g,this.props.onPlay),this.player.addEventListener(E,this.props.onPause),this.player.addEventListener(O,this.props.onEnded),this.player.addEventListener(T,this.props.onSeek),this.player.addEventListener(L,this.props.onLoaded),this.player.addEventListener(b,this.props.onLoaded)},a)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){this.callPlayer("pause")}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentTime")}getSecondsLoaded(){return null}render(){const e={width:"100%",height:"100%"};return d.default.createElement("div",{style:e,id:this.playerID})}}o(h,"displayName","Twitch");o(h,"canPlay",u.canPlay.twitch);o(h,"loopOnEnded",!0);const W=w(f),k=I({__proto__:null,default:W},[f]);export{k as T}; +import{a8 as w,r as D}from"./index-4e60c9e2.js";import{u as C,p as N}from"./index-a46872c4.js";function I(t,e){for(var r=0;rs[a]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var S=Object.create,l=Object.defineProperty,j=Object.getOwnPropertyDescriptor,A=Object.getOwnPropertyNames,M=Object.getPrototypeOf,H=Object.prototype.hasOwnProperty,R=(t,e,r)=>e in t?l(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,x=(t,e)=>{for(var r in e)l(t,r,{get:e[r],enumerable:!0})},_=(t,e,r,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of A(e))!H.call(t,a)&&a!==r&&l(t,a,{get:()=>e[a],enumerable:!(s=j(e,a))||s.enumerable});return t},F=(t,e,r)=>(r=t!=null?S(M(t)):{},_(e||!t||!t.__esModule?l(r,"default",{value:t,enumerable:!0}):r,t)),U=t=>_(l({},"__esModule",{value:!0}),t),o=(t,e,r)=>(R(t,typeof e!="symbol"?e+"":e,r),r),P={};x(P,{default:()=>h});var f=U(P),d=F(D),c=C,u=N;const K="https://player.twitch.tv/js/embed/v1.js",V="Twitch",$="twitch-player-";class h extends d.Component{constructor(){super(...arguments),o(this,"callPlayer",c.callPlayer),o(this,"playerID",this.props.config.playerId||`${$}${(0,c.randomString)()}`),o(this,"mute",()=>{this.callPlayer("setMuted",!0)}),o(this,"unmute",()=>{this.callPlayer("setMuted",!1)})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e,r){const{playsinline:s,onError:a,config:n,controls:v}=this.props,i=u.MATCH_URL_TWITCH_CHANNEL.test(e),p=i?e.match(u.MATCH_URL_TWITCH_CHANNEL)[1]:e.match(u.MATCH_URL_TWITCH_VIDEO)[1];if(r){i?this.player.setChannel(p):this.player.setVideo("v"+p);return}(0,c.getSDK)(K,V).then(y=>{this.player=new y.Player(this.playerID,{video:i?"":p,channel:i?p:"",height:"100%",width:"100%",playsinline:s,autoplay:this.props.playing,muted:this.props.muted,controls:i?!0:v,time:(0,c.parseStartTime)(e),...n.options});const{READY:m,PLAYING:g,PAUSE:E,ENDED:O,ONLINE:L,OFFLINE:b,SEEK:T}=y.Player;this.player.addEventListener(m,this.props.onReady),this.player.addEventListener(g,this.props.onPlay),this.player.addEventListener(E,this.props.onPause),this.player.addEventListener(O,this.props.onEnded),this.player.addEventListener(T,this.props.onSeek),this.player.addEventListener(L,this.props.onLoaded),this.player.addEventListener(b,this.props.onLoaded)},a)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){this.callPlayer("pause")}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentTime")}getSecondsLoaded(){return null}render(){const e={width:"100%",height:"100%"};return d.default.createElement("div",{style:e,id:this.playerID})}}o(h,"displayName","Twitch");o(h,"canPlay",u.canPlay.twitch);o(h,"loopOnEnded",!0);const W=w(f),k=I({__proto__:null,default:W},[f]);export{k as T}; diff --git a/build/assets/Typography-2a31701b.js b/build/assets/Typography-2a31701b.js new file mode 100644 index 000000000..63cfd2f84 --- /dev/null +++ b/build/assets/Typography-2a31701b.js @@ -0,0 +1 @@ +import{K as b,L as B,M as W,X as u,N as s,r as C,P as M,G as P,j as R,S as U,U as j}from"./index-4e60c9e2.js";import{e as N}from"./Stack-5870980a.js";function L(a){return b("MuiTypography",a)}B("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const _=["align","className","component","gutterBottom","noWrap","paragraph","variant","variantMapping"],$=a=>{const{align:t,gutterBottom:r,noWrap:n,paragraph:e,variant:o,classes:p}=a,i={root:["root",o,a.align!=="inherit"&&`align${u(t)}`,r&&"gutterBottom",n&&"noWrap",e&&"paragraph"]};return j(i,L,p)},E=W("span",{name:"MuiTypography",slot:"Root",overridesResolver:(a,t)=>{const{ownerState:r}=a;return[t.root,r.variant&&t[r.variant],r.align!=="inherit"&&t[`align${u(r.align)}`],r.noWrap&&t.noWrap,r.gutterBottom&&t.gutterBottom,r.paragraph&&t.paragraph]}})(({theme:a,ownerState:t})=>s({margin:0},t.variant==="inherit"&&{font:"inherit"},t.variant!=="inherit"&&a.typography[t.variant],t.align!=="inherit"&&{textAlign:t.align},t.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t.gutterBottom&&{marginBottom:"0.35em"},t.paragraph&&{marginBottom:16})),y={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},z={primary:"primary.main",textPrimary:"text.primary",secondary:"secondary.main",textSecondary:"text.secondary",error:"error.main"},A=a=>z[a]||a,D=C.forwardRef(function(t,r){const n=M({props:t,name:"MuiTypography"}),e=A(n.color),o=N(s({},n,{color:e})),{align:p="inherit",className:i,component:g,gutterBottom:d=!1,noWrap:f=!1,paragraph:l=!1,variant:h="body1",variantMapping:c=y}=o,x=P(o,_),m=s({},o,{align:p,color:e,className:i,component:g,gutterBottom:d,noWrap:f,paragraph:l,variant:h,variantMapping:c}),v=g||(l?"p":c[h]||y[h])||"span",T=$(m);return R.jsx(E,s({as:v,ref:r,ownerState:m,className:U(T.root,i)},x))}),K=D;export{K as T}; diff --git a/build/assets/Typography-f76555b9.js b/build/assets/Typography-f76555b9.js deleted file mode 100644 index bdff14dac..000000000 --- a/build/assets/Typography-f76555b9.js +++ /dev/null @@ -1 +0,0 @@ -import{L as b,M as B,N as W,Y as u,O as s,r as C,S as M,H as R,j as P,U,V as j}from"./index-4bb27744.js";import{e as N}from"./Stack-6038813c.js";function L(a){return b("MuiTypography",a)}B("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const _=["align","className","component","gutterBottom","noWrap","paragraph","variant","variantMapping"],$=a=>{const{align:t,gutterBottom:r,noWrap:n,paragraph:e,variant:o,classes:p}=a,i={root:["root",o,a.align!=="inherit"&&`align${u(t)}`,r&&"gutterBottom",n&&"noWrap",e&&"paragraph"]};return j(i,L,p)},E=W("span",{name:"MuiTypography",slot:"Root",overridesResolver:(a,t)=>{const{ownerState:r}=a;return[t.root,r.variant&&t[r.variant],r.align!=="inherit"&&t[`align${u(r.align)}`],r.noWrap&&t.noWrap,r.gutterBottom&&t.gutterBottom,r.paragraph&&t.paragraph]}})(({theme:a,ownerState:t})=>s({margin:0},t.variant==="inherit"&&{font:"inherit"},t.variant!=="inherit"&&a.typography[t.variant],t.align!=="inherit"&&{textAlign:t.align},t.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t.gutterBottom&&{marginBottom:"0.35em"},t.paragraph&&{marginBottom:16})),y={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},O={primary:"primary.main",textPrimary:"text.primary",secondary:"secondary.main",textSecondary:"text.secondary",error:"error.main"},V=a=>O[a]||a,z=C.forwardRef(function(t,r){const n=M({props:t,name:"MuiTypography"}),e=V(n.color),o=N(s({},n,{color:e})),{align:p="inherit",className:i,component:g,gutterBottom:d=!1,noWrap:f=!1,paragraph:l=!1,variant:h="body1",variantMapping:c=y}=o,x=R(o,_),m=s({},o,{align:p,color:e,className:i,component:g,gutterBottom:d,noWrap:f,paragraph:l,variant:h,variantMapping:c}),v=g||(l?"p":c[h]||y[h])||"span",T=$(m);return P.jsx(E,s({as:v,ref:r,ownerState:m,className:U(T.root,i)},x))}),H=z;export{H as T}; diff --git a/build/assets/Vidyard-77bcf258.js b/build/assets/Vidyard-9c70b529.js similarity index 95% rename from build/assets/Vidyard-77bcf258.js rename to build/assets/Vidyard-9c70b529.js index 9f99e6dec..4f9301aca 100644 --- a/build/assets/Vidyard-77bcf258.js +++ b/build/assets/Vidyard-9c70b529.js @@ -1 +1 @@ -import{a9 as g,r as v}from"./index-4bb27744.js";import{u as b,p as O}from"./index-87de005d.js";function V(t,e){for(var r=0;ro[a]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var D=Object.create,i=Object.defineProperty,j=Object.getOwnPropertyDescriptor,w=Object.getOwnPropertyNames,S=Object.getPrototypeOf,M=Object.prototype.hasOwnProperty,A=(t,e,r)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,E=(t,e)=>{for(var r in e)i(t,r,{get:e[r],enumerable:!0})},h=(t,e,r,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of w(e))!M.call(t,a)&&a!==r&&i(t,a,{get:()=>e[a],enumerable:!(o=j(e,a))||o.enumerable});return t},L=(t,e,r)=>(r=t!=null?D(S(t)):{},h(e||!t||!t.__esModule?i(r,"default",{value:t,enumerable:!0}):r,t)),R=t=>h(i({},"__esModule",{value:!0}),t),s=(t,e,r)=>(A(t,typeof e!="symbol"?e+"":e,r),r),_={};E(_,{default:()=>y});var f=R(_),c=L(v),d=b,P=O;const x="https://play.vidyard.com/embed/v4.js",C="VidyardV4",N="onVidyardAPI";class y extends c.Component{constructor(){super(...arguments),s(this,"callPlayer",d.callPlayer),s(this,"mute",()=>{this.setVolume(0)}),s(this,"unmute",()=>{this.props.volume!==null&&this.setVolume(this.props.volume)}),s(this,"ref",e=>{this.container=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){const{playing:r,config:o,onError:a,onDuration:n}=this.props,l=e&&e.match(P.MATCH_URL_VIDYARD)[1];this.player&&this.stop(),(0,d.getSDK)(x,C,N).then(p=>{this.container&&(p.api.addReadyListener((u,m)=>{this.player||(this.player=m,this.player.on("ready",this.props.onReady),this.player.on("play",this.props.onPlay),this.player.on("pause",this.props.onPause),this.player.on("seek",this.props.onSeek),this.player.on("playerComplete",this.props.onEnded))},l),p.api.renderPlayer({uuid:l,container:this.container,autoplay:r?1:0,...o.options}),p.api.getPlayerMetadata(l).then(u=>{this.duration=u.length_in_seconds,n(u.length_in_seconds)}))},a)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){window.VidyardV4.api.destroyPlayer(this.player)}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}setPlaybackRate(e){this.callPlayer("setPlaybackSpeed",e)}getDuration(){return this.duration}getCurrentTime(){return this.callPlayer("currentTime")}getSecondsLoaded(){return null}render(){const{display:e}=this.props,r={width:"100%",height:"100%",display:e};return c.default.createElement("div",{style:r},c.default.createElement("div",{ref:this.ref}))}}s(y,"displayName","Vidyard");s(y,"canPlay",P.canPlay.vidyard);const T=g(f),B=V({__proto__:null,default:T},[f]);export{B as V}; +import{a8 as g,r as v}from"./index-4e60c9e2.js";import{u as b,p as O}from"./index-a46872c4.js";function V(t,e){for(var r=0;ro[a]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var D=Object.create,i=Object.defineProperty,j=Object.getOwnPropertyDescriptor,w=Object.getOwnPropertyNames,S=Object.getPrototypeOf,M=Object.prototype.hasOwnProperty,A=(t,e,r)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,E=(t,e)=>{for(var r in e)i(t,r,{get:e[r],enumerable:!0})},h=(t,e,r,o)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of w(e))!M.call(t,a)&&a!==r&&i(t,a,{get:()=>e[a],enumerable:!(o=j(e,a))||o.enumerable});return t},L=(t,e,r)=>(r=t!=null?D(S(t)):{},h(e||!t||!t.__esModule?i(r,"default",{value:t,enumerable:!0}):r,t)),R=t=>h(i({},"__esModule",{value:!0}),t),s=(t,e,r)=>(A(t,typeof e!="symbol"?e+"":e,r),r),_={};E(_,{default:()=>y});var f=R(_),c=L(v),d=b,P=O;const x="https://play.vidyard.com/embed/v4.js",C="VidyardV4",N="onVidyardAPI";class y extends c.Component{constructor(){super(...arguments),s(this,"callPlayer",d.callPlayer),s(this,"mute",()=>{this.setVolume(0)}),s(this,"unmute",()=>{this.props.volume!==null&&this.setVolume(this.props.volume)}),s(this,"ref",e=>{this.container=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){const{playing:r,config:o,onError:a,onDuration:n}=this.props,l=e&&e.match(P.MATCH_URL_VIDYARD)[1];this.player&&this.stop(),(0,d.getSDK)(x,C,N).then(p=>{this.container&&(p.api.addReadyListener((u,m)=>{this.player||(this.player=m,this.player.on("ready",this.props.onReady),this.player.on("play",this.props.onPlay),this.player.on("pause",this.props.onPause),this.player.on("seek",this.props.onSeek),this.player.on("playerComplete",this.props.onEnded))},l),p.api.renderPlayer({uuid:l,container:this.container,autoplay:r?1:0,...o.options}),p.api.getPlayerMetadata(l).then(u=>{this.duration=u.length_in_seconds,n(u.length_in_seconds)}))},a)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){window.VidyardV4.api.destroyPlayer(this.player)}seekTo(e,r=!0){this.callPlayer("seek",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}setPlaybackRate(e){this.callPlayer("setPlaybackSpeed",e)}getDuration(){return this.duration}getCurrentTime(){return this.callPlayer("currentTime")}getSecondsLoaded(){return null}render(){const{display:e}=this.props,r={width:"100%",height:"100%",display:e};return c.default.createElement("div",{style:r},c.default.createElement("div",{ref:this.ref}))}}s(y,"displayName","Vidyard");s(y,"canPlay",P.canPlay.vidyard);const T=g(f),B=V({__proto__:null,default:T},[f]);export{B as V}; diff --git a/build/assets/Vimeo-15629a32.js b/build/assets/Vimeo-401b9966.js similarity index 96% rename from build/assets/Vimeo-15629a32.js rename to build/assets/Vimeo-401b9966.js index f70186fa5..95556ea1f 100644 --- a/build/assets/Vimeo-15629a32.js +++ b/build/assets/Vimeo-401b9966.js @@ -1 +1 @@ -import{a9 as d,r as f}from"./index-4bb27744.js";import{u as m,p as _}from"./index-87de005d.js";function P(t,e){for(var r=0;ra[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var g=Object.create,n=Object.defineProperty,b=Object.getOwnPropertyDescriptor,v=Object.getOwnPropertyNames,O=Object.getPrototypeOf,D=Object.prototype.hasOwnProperty,w=(t,e,r)=>e in t?n(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,j=(t,e)=>{for(var r in e)n(t,r,{get:e[r],enumerable:!0})},h=(t,e,r,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of v(e))!D.call(t,o)&&o!==r&&n(t,o,{get:()=>e[o],enumerable:!(a=b(e,o))||a.enumerable});return t},M=(t,e,r)=>(r=t!=null?g(O(t)):{},h(e||!t||!t.__esModule?n(r,"default",{value:t,enumerable:!0}):r,t)),E=t=>h(n({},"__esModule",{value:!0}),t),i=(t,e,r)=>(w(t,typeof e!="symbol"?e+"":e,r),r),c={};j(c,{default:()=>l});var y=E(c),p=M(f),u=m,L=_;const S="https://player.vimeo.com/api/player.js",V="Vimeo",k=t=>t.replace("/manage/videos","");class l extends p.Component{constructor(){super(...arguments),i(this,"callPlayer",u.callPlayer),i(this,"duration",null),i(this,"currentTime",null),i(this,"secondsLoaded",null),i(this,"mute",()=>{this.setMuted(!0)}),i(this,"unmute",()=>{this.setMuted(!1)}),i(this,"ref",e=>{this.container=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){this.duration=null,(0,u.getSDK)(S,V).then(r=>{if(!this.container)return;const{playerOptions:a,title:o}=this.props.config;this.player=new r.Player(this.container,{url:k(e),autoplay:this.props.playing,muted:this.props.muted,loop:this.props.loop,playsinline:this.props.playsinline,controls:this.props.controls,...a}),this.player.ready().then(()=>{const s=this.container.querySelector("iframe");s.style.width="100%",s.style.height="100%",o&&(s.title=o)}).catch(this.props.onError),this.player.on("loaded",()=>{this.props.onReady(),this.refreshDuration()}),this.player.on("play",()=>{this.props.onPlay(),this.refreshDuration()}),this.player.on("pause",this.props.onPause),this.player.on("seeked",s=>this.props.onSeek(s.seconds)),this.player.on("ended",this.props.onEnded),this.player.on("error",this.props.onError),this.player.on("timeupdate",({seconds:s})=>{this.currentTime=s}),this.player.on("progress",({seconds:s})=>{this.secondsLoaded=s}),this.player.on("bufferstart",this.props.onBuffer),this.player.on("bufferend",this.props.onBufferEnd),this.player.on("playbackratechange",s=>this.props.onPlaybackRateChange(s.playbackRate))},this.props.onError)}refreshDuration(){this.player.getDuration().then(e=>{this.duration=e})}play(){const e=this.callPlayer("play");e&&e.catch(this.props.onError)}pause(){this.callPlayer("pause")}stop(){this.callPlayer("unload")}seekTo(e,r=!0){this.callPlayer("setCurrentTime",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}setMuted(e){this.callPlayer("setMuted",e)}setLoop(e){this.callPlayer("setLoop",e)}setPlaybackRate(e){this.callPlayer("setPlaybackRate",e)}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return this.secondsLoaded}render(){const{display:e}=this.props,r={width:"100%",height:"100%",overflow:"hidden",display:e};return p.default.createElement("div",{key:this.props.url,ref:this.ref,style:r})}}i(l,"displayName","Vimeo");i(l,"canPlay",L.canPlay.vimeo);i(l,"forceLoad",!0);const T=d(y),R=P({__proto__:null,default:T},[y]);export{R as V}; +import{a8 as d,r as f}from"./index-4e60c9e2.js";import{u as m,p as _}from"./index-a46872c4.js";function P(t,e){for(var r=0;ra[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var g=Object.create,n=Object.defineProperty,b=Object.getOwnPropertyDescriptor,v=Object.getOwnPropertyNames,O=Object.getPrototypeOf,D=Object.prototype.hasOwnProperty,w=(t,e,r)=>e in t?n(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,j=(t,e)=>{for(var r in e)n(t,r,{get:e[r],enumerable:!0})},h=(t,e,r,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of v(e))!D.call(t,o)&&o!==r&&n(t,o,{get:()=>e[o],enumerable:!(a=b(e,o))||a.enumerable});return t},M=(t,e,r)=>(r=t!=null?g(O(t)):{},h(e||!t||!t.__esModule?n(r,"default",{value:t,enumerable:!0}):r,t)),E=t=>h(n({},"__esModule",{value:!0}),t),i=(t,e,r)=>(w(t,typeof e!="symbol"?e+"":e,r),r),c={};j(c,{default:()=>l});var y=E(c),p=M(f),u=m,L=_;const S="https://player.vimeo.com/api/player.js",V="Vimeo",k=t=>t.replace("/manage/videos","");class l extends p.Component{constructor(){super(...arguments),i(this,"callPlayer",u.callPlayer),i(this,"duration",null),i(this,"currentTime",null),i(this,"secondsLoaded",null),i(this,"mute",()=>{this.setMuted(!0)}),i(this,"unmute",()=>{this.setMuted(!1)}),i(this,"ref",e=>{this.container=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){this.duration=null,(0,u.getSDK)(S,V).then(r=>{if(!this.container)return;const{playerOptions:a,title:o}=this.props.config;this.player=new r.Player(this.container,{url:k(e),autoplay:this.props.playing,muted:this.props.muted,loop:this.props.loop,playsinline:this.props.playsinline,controls:this.props.controls,...a}),this.player.ready().then(()=>{const s=this.container.querySelector("iframe");s.style.width="100%",s.style.height="100%",o&&(s.title=o)}).catch(this.props.onError),this.player.on("loaded",()=>{this.props.onReady(),this.refreshDuration()}),this.player.on("play",()=>{this.props.onPlay(),this.refreshDuration()}),this.player.on("pause",this.props.onPause),this.player.on("seeked",s=>this.props.onSeek(s.seconds)),this.player.on("ended",this.props.onEnded),this.player.on("error",this.props.onError),this.player.on("timeupdate",({seconds:s})=>{this.currentTime=s}),this.player.on("progress",({seconds:s})=>{this.secondsLoaded=s}),this.player.on("bufferstart",this.props.onBuffer),this.player.on("bufferend",this.props.onBufferEnd),this.player.on("playbackratechange",s=>this.props.onPlaybackRateChange(s.playbackRate))},this.props.onError)}refreshDuration(){this.player.getDuration().then(e=>{this.duration=e})}play(){const e=this.callPlayer("play");e&&e.catch(this.props.onError)}pause(){this.callPlayer("pause")}stop(){this.callPlayer("unload")}seekTo(e,r=!0){this.callPlayer("setCurrentTime",e),r||this.pause()}setVolume(e){this.callPlayer("setVolume",e)}setMuted(e){this.callPlayer("setMuted",e)}setLoop(e){this.callPlayer("setLoop",e)}setPlaybackRate(e){this.callPlayer("setPlaybackRate",e)}getDuration(){return this.duration}getCurrentTime(){return this.currentTime}getSecondsLoaded(){return this.secondsLoaded}render(){const{display:e}=this.props,r={width:"100%",height:"100%",overflow:"hidden",display:e};return p.default.createElement("div",{key:this.props.url,ref:this.ref,style:r})}}i(l,"displayName","Vimeo");i(l,"canPlay",L.canPlay.vimeo);i(l,"forceLoad",!0);const T=d(y),R=P({__proto__:null,default:T},[y]);export{R as V}; diff --git a/build/assets/Wistia-500f8a97.js b/build/assets/Wistia-74afe4bb.js similarity index 96% rename from build/assets/Wistia-500f8a97.js rename to build/assets/Wistia-74afe4bb.js index fa962f9bd..6ed740a3a 100644 --- a/build/assets/Wistia-500f8a97.js +++ b/build/assets/Wistia-74afe4bb.js @@ -1 +1 @@ -import{a9 as m,r as g}from"./index-4bb27744.js";import{u as v,p as w}from"./index-87de005d.js";function O(t,e){for(var a=0;as[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var C=Object.create,i=Object.defineProperty,k=Object.getOwnPropertyDescriptor,D=Object.getOwnPropertyNames,E=Object.getPrototypeOf,S=Object.prototype.hasOwnProperty,R=(t,e,a)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:a}):t[e]=a,j=(t,e)=>{for(var a in e)i(t,a,{get:e[a],enumerable:!0})},h=(t,e,a,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of D(e))!S.call(t,r)&&r!==a&&i(t,r,{get:()=>e[r],enumerable:!(s=k(e,r))||s.enumerable});return t},I=(t,e,a)=>(a=t!=null?C(E(t)):{},h(e||!t||!t.__esModule?i(a,"default",{value:t,enumerable:!0}):a,t)),W=t=>h(i({},"__esModule",{value:!0}),t),n=(t,e,a)=>(R(t,typeof e!="symbol"?e+"":e,a),a),d={};j(d,{default:()=>l});var _=W(d),y=I(g),c=v,P=w;const M="https://fast.wistia.com/assets/external/E-v1.js",x="Wistia",A="wistia-player-";class l extends y.Component{constructor(){super(...arguments),n(this,"callPlayer",c.callPlayer),n(this,"playerID",this.props.config.playerId||`${A}${(0,c.randomString)()}`),n(this,"onPlay",(...e)=>this.props.onPlay(...e)),n(this,"onPause",(...e)=>this.props.onPause(...e)),n(this,"onSeek",(...e)=>this.props.onSeek(...e)),n(this,"onEnded",(...e)=>this.props.onEnded(...e)),n(this,"onPlaybackRateChange",(...e)=>this.props.onPlaybackRateChange(...e)),n(this,"mute",()=>{this.callPlayer("mute")}),n(this,"unmute",()=>{this.callPlayer("unmute")})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){const{playing:a,muted:s,controls:r,onReady:o,config:p,onError:b}=this.props;(0,c.getSDK)(M,x).then(f=>{p.customControls&&p.customControls.forEach(u=>f.defineControl(u)),window._wq=window._wq||[],window._wq.push({id:this.playerID,options:{autoPlay:a,silentAutoPlay:"allow",muted:s,controlsVisibleOnLoad:r,fullscreenButton:r,playbar:r,playbackRateControl:r,qualityControl:r,volumeControl:r,settingsControl:r,smallPlayButton:r,...p.options},onReady:u=>{this.player=u,this.unbind(),this.player.bind("play",this.onPlay),this.player.bind("pause",this.onPause),this.player.bind("seek",this.onSeek),this.player.bind("end",this.onEnded),this.player.bind("playbackratechange",this.onPlaybackRateChange),o()}})},b)}unbind(){this.player.unbind("play",this.onPlay),this.player.unbind("pause",this.onPause),this.player.unbind("seek",this.onSeek),this.player.unbind("end",this.onEnded),this.player.unbind("playbackratechange",this.onPlaybackRateChange)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){this.unbind(),this.callPlayer("remove")}seekTo(e,a=!0){this.callPlayer("time",e),a||this.pause()}setVolume(e){this.callPlayer("volume",e)}setPlaybackRate(e){this.callPlayer("playbackRate",e)}getDuration(){return this.callPlayer("duration")}getCurrentTime(){return this.callPlayer("time")}getSecondsLoaded(){return null}render(){const{url:e}=this.props,a=e&&e.match(P.MATCH_URL_WISTIA)[1],s=`wistia_embed wistia_async_${a}`,r={width:"100%",height:"100%"};return y.default.createElement("div",{id:this.playerID,key:a,className:s,style:r})}}n(l,"displayName","Wistia");n(l,"canPlay",P.canPlay.wistia);n(l,"loopOnEnded",!0);const L=m(_),$=O({__proto__:null,default:L},[_]);export{$ as W}; +import{a8 as m,r as g}from"./index-4e60c9e2.js";import{u as v,p as w}from"./index-a46872c4.js";function O(t,e){for(var a=0;as[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var C=Object.create,i=Object.defineProperty,k=Object.getOwnPropertyDescriptor,D=Object.getOwnPropertyNames,E=Object.getPrototypeOf,S=Object.prototype.hasOwnProperty,R=(t,e,a)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:a}):t[e]=a,j=(t,e)=>{for(var a in e)i(t,a,{get:e[a],enumerable:!0})},h=(t,e,a,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of D(e))!S.call(t,r)&&r!==a&&i(t,r,{get:()=>e[r],enumerable:!(s=k(e,r))||s.enumerable});return t},I=(t,e,a)=>(a=t!=null?C(E(t)):{},h(e||!t||!t.__esModule?i(a,"default",{value:t,enumerable:!0}):a,t)),W=t=>h(i({},"__esModule",{value:!0}),t),n=(t,e,a)=>(R(t,typeof e!="symbol"?e+"":e,a),a),d={};j(d,{default:()=>l});var _=W(d),y=I(g),c=v,P=w;const M="https://fast.wistia.com/assets/external/E-v1.js",x="Wistia",A="wistia-player-";class l extends y.Component{constructor(){super(...arguments),n(this,"callPlayer",c.callPlayer),n(this,"playerID",this.props.config.playerId||`${A}${(0,c.randomString)()}`),n(this,"onPlay",(...e)=>this.props.onPlay(...e)),n(this,"onPause",(...e)=>this.props.onPause(...e)),n(this,"onSeek",(...e)=>this.props.onSeek(...e)),n(this,"onEnded",(...e)=>this.props.onEnded(...e)),n(this,"onPlaybackRateChange",(...e)=>this.props.onPlaybackRateChange(...e)),n(this,"mute",()=>{this.callPlayer("mute")}),n(this,"unmute",()=>{this.callPlayer("unmute")})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}load(e){const{playing:a,muted:s,controls:r,onReady:o,config:p,onError:b}=this.props;(0,c.getSDK)(M,x).then(f=>{p.customControls&&p.customControls.forEach(u=>f.defineControl(u)),window._wq=window._wq||[],window._wq.push({id:this.playerID,options:{autoPlay:a,silentAutoPlay:"allow",muted:s,controlsVisibleOnLoad:r,fullscreenButton:r,playbar:r,playbackRateControl:r,qualityControl:r,volumeControl:r,settingsControl:r,smallPlayButton:r,...p.options},onReady:u=>{this.player=u,this.unbind(),this.player.bind("play",this.onPlay),this.player.bind("pause",this.onPause),this.player.bind("seek",this.onSeek),this.player.bind("end",this.onEnded),this.player.bind("playbackratechange",this.onPlaybackRateChange),o()}})},b)}unbind(){this.player.unbind("play",this.onPlay),this.player.unbind("pause",this.onPause),this.player.unbind("seek",this.onSeek),this.player.unbind("end",this.onEnded),this.player.unbind("playbackratechange",this.onPlaybackRateChange)}play(){this.callPlayer("play")}pause(){this.callPlayer("pause")}stop(){this.unbind(),this.callPlayer("remove")}seekTo(e,a=!0){this.callPlayer("time",e),a||this.pause()}setVolume(e){this.callPlayer("volume",e)}setPlaybackRate(e){this.callPlayer("playbackRate",e)}getDuration(){return this.callPlayer("duration")}getCurrentTime(){return this.callPlayer("time")}getSecondsLoaded(){return null}render(){const{url:e}=this.props,a=e&&e.match(P.MATCH_URL_WISTIA)[1],s=`wistia_embed wistia_async_${a}`,r={width:"100%",height:"100%"};return y.default.createElement("div",{id:this.playerID,key:a,className:s,style:r})}}n(l,"displayName","Wistia");n(l,"canPlay",P.canPlay.wistia);n(l,"loopOnEnded",!0);const L=m(_),$=O({__proto__:null,default:L},[_]);export{$ as W}; diff --git a/build/assets/YouTube-af1e25c0.js b/build/assets/YouTube-2c06e076.js similarity index 97% rename from build/assets/YouTube-af1e25c0.js rename to build/assets/YouTube-2c06e076.js index 61fe1ea5f..47f4487c7 100644 --- a/build/assets/YouTube-af1e25c0.js +++ b/build/assets/YouTube-2c06e076.js @@ -1 +1 @@ -import{a9 as U,r as I}from"./index-4bb27744.js";import{u as L,p as Y}from"./index-87de005d.js";function k(a,e){for(var t=0;ts[r]})}}}return Object.freeze(Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}))}var M=Object.create,u=Object.defineProperty,j=Object.getOwnPropertyDescriptor,N=Object.getOwnPropertyNames,V=Object.getPrototypeOf,B=Object.prototype.hasOwnProperty,x=(a,e,t)=>e in a?u(a,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):a[e]=t,K=(a,e)=>{for(var t in e)u(a,t,{get:e[t],enumerable:!0})},v=(a,e,t,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of N(e))!B.call(a,r)&&r!==t&&u(a,r,{get:()=>e[r],enumerable:!(s=j(e,r))||s.enumerable});return a},F=(a,e,t)=>(t=a!=null?M(V(a)):{},v(e||!a||!a.__esModule?u(t,"default",{value:a,enumerable:!0}):t,a)),H=a=>v(u({},"__esModule",{value:!0}),a),o=(a,e,t)=>(x(a,typeof e!="symbol"?e+"":e,t),t),w={};K(w,{default:()=>O});var S=H(w),m=F(I),p=L,D=Y;const G="https://www.youtube.com/iframe_api",T="YT",z="onYouTubeIframeAPIReady",f=/[?&](?:list|channel)=([a-zA-Z0-9_-]+)/,b=/user\/([a-zA-Z0-9_-]+)\/?/,Q=/youtube-nocookie\.com/,Z="https://www.youtube-nocookie.com";class O extends m.Component{constructor(){super(...arguments),o(this,"callPlayer",p.callPlayer),o(this,"parsePlaylist",e=>{if(e instanceof Array)return{listType:"playlist",playlist:e.map(this.getID).join(",")};if(f.test(e)){const[,t]=e.match(f);return{listType:"playlist",list:t.replace(/^UC/,"UU")}}if(b.test(e)){const[,t]=e.match(b);return{listType:"user_uploads",list:t}}return{}}),o(this,"onStateChange",e=>{const{data:t}=e,{onPlay:s,onPause:r,onBuffer:n,onBufferEnd:P,onEnded:_,onReady:g,loop:y,config:{playerVars:l,onUnstarted:h}}=this.props,{UNSTARTED:d,PLAYING:c,PAUSED:i,BUFFERING:E,ENDED:A,CUED:C}=window[T].PlayerState;if(t===d&&h(),t===c&&(s(),P()),t===i&&r(),t===E&&n(),t===A){const R=!!this.callPlayer("getPlaylist");y&&!R&&(l.start?this.seekTo(l.start):this.play()),_()}t===C&&g()}),o(this,"mute",()=>{this.callPlayer("mute")}),o(this,"unmute",()=>{this.callPlayer("unMute")}),o(this,"ref",e=>{this.container=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}getID(e){return!e||e instanceof Array||f.test(e)?null:e.match(D.MATCH_URL_YOUTUBE)[1]}load(e,t){const{playing:s,muted:r,playsinline:n,controls:P,loop:_,config:g,onError:y}=this.props,{playerVars:l,embedOptions:h}=g,d=this.getID(e);if(t){if(f.test(e)||b.test(e)||e instanceof Array){this.player.loadPlaylist(this.parsePlaylist(e));return}this.player.cueVideoById({videoId:d,startSeconds:(0,p.parseStartTime)(e)||l.start,endSeconds:(0,p.parseEndTime)(e)||l.end});return}(0,p.getSDK)(G,T,z,c=>c.loaded).then(c=>{this.container&&(this.player=new c.Player(this.container,{width:"100%",height:"100%",videoId:d,playerVars:{autoplay:s?1:0,mute:r?1:0,controls:P?1:0,start:(0,p.parseStartTime)(e),end:(0,p.parseEndTime)(e),origin:window.location.origin,playsinline:n?1:0,...this.parsePlaylist(e),...l},events:{onReady:()=>{_&&this.player.setLoop(!0),this.props.onReady()},onPlaybackRateChange:i=>this.props.onPlaybackRateChange(i.data),onPlaybackQualityChange:i=>this.props.onPlaybackQualityChange(i),onStateChange:this.onStateChange,onError:i=>y(i.data)},host:Q.test(e)?Z:void 0,...h}))},y),h.events&&console.warn("Using `embedOptions.events` will likely break things. Use ReactPlayer’s callback props instead, eg onReady, onPlay, onPause")}play(){this.callPlayer("playVideo")}pause(){this.callPlayer("pauseVideo")}stop(){document.body.contains(this.callPlayer("getIframe"))&&this.callPlayer("stopVideo")}seekTo(e,t=!1){this.callPlayer("seekTo",e),!t&&!this.props.playing&&this.pause()}setVolume(e){this.callPlayer("setVolume",e*100)}setPlaybackRate(e){this.callPlayer("setPlaybackRate",e)}setLoop(e){this.callPlayer("setLoop",e)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentTime")}getSecondsLoaded(){return this.callPlayer("getVideoLoadedFraction")*this.getDuration()}render(){const{display:e}=this.props,t={width:"100%",height:"100%",display:e};return m.default.createElement("div",{style:t},m.default.createElement("div",{ref:this.ref}))}}o(O,"displayName","YouTube");o(O,"canPlay",D.canPlay.youtube);const $=U(S),W=k({__proto__:null,default:$},[S]);export{W as Y}; +import{a8 as U,r as I}from"./index-4e60c9e2.js";import{u as L,p as Y}from"./index-a46872c4.js";function k(a,e){for(var t=0;ts[r]})}}}return Object.freeze(Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}))}var M=Object.create,u=Object.defineProperty,j=Object.getOwnPropertyDescriptor,N=Object.getOwnPropertyNames,V=Object.getPrototypeOf,B=Object.prototype.hasOwnProperty,x=(a,e,t)=>e in a?u(a,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):a[e]=t,K=(a,e)=>{for(var t in e)u(a,t,{get:e[t],enumerable:!0})},v=(a,e,t,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of N(e))!B.call(a,r)&&r!==t&&u(a,r,{get:()=>e[r],enumerable:!(s=j(e,r))||s.enumerable});return a},F=(a,e,t)=>(t=a!=null?M(V(a)):{},v(e||!a||!a.__esModule?u(t,"default",{value:a,enumerable:!0}):t,a)),H=a=>v(u({},"__esModule",{value:!0}),a),o=(a,e,t)=>(x(a,typeof e!="symbol"?e+"":e,t),t),w={};K(w,{default:()=>O});var S=H(w),m=F(I),p=L,D=Y;const G="https://www.youtube.com/iframe_api",T="YT",z="onYouTubeIframeAPIReady",f=/[?&](?:list|channel)=([a-zA-Z0-9_-]+)/,b=/user\/([a-zA-Z0-9_-]+)\/?/,Q=/youtube-nocookie\.com/,Z="https://www.youtube-nocookie.com";class O extends m.Component{constructor(){super(...arguments),o(this,"callPlayer",p.callPlayer),o(this,"parsePlaylist",e=>{if(e instanceof Array)return{listType:"playlist",playlist:e.map(this.getID).join(",")};if(f.test(e)){const[,t]=e.match(f);return{listType:"playlist",list:t.replace(/^UC/,"UU")}}if(b.test(e)){const[,t]=e.match(b);return{listType:"user_uploads",list:t}}return{}}),o(this,"onStateChange",e=>{const{data:t}=e,{onPlay:s,onPause:r,onBuffer:n,onBufferEnd:P,onEnded:_,onReady:g,loop:y,config:{playerVars:l,onUnstarted:h}}=this.props,{UNSTARTED:d,PLAYING:c,PAUSED:i,BUFFERING:E,ENDED:A,CUED:C}=window[T].PlayerState;if(t===d&&h(),t===c&&(s(),P()),t===i&&r(),t===E&&n(),t===A){const R=!!this.callPlayer("getPlaylist");y&&!R&&(l.start?this.seekTo(l.start):this.play()),_()}t===C&&g()}),o(this,"mute",()=>{this.callPlayer("mute")}),o(this,"unmute",()=>{this.callPlayer("unMute")}),o(this,"ref",e=>{this.container=e})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}getID(e){return!e||e instanceof Array||f.test(e)?null:e.match(D.MATCH_URL_YOUTUBE)[1]}load(e,t){const{playing:s,muted:r,playsinline:n,controls:P,loop:_,config:g,onError:y}=this.props,{playerVars:l,embedOptions:h}=g,d=this.getID(e);if(t){if(f.test(e)||b.test(e)||e instanceof Array){this.player.loadPlaylist(this.parsePlaylist(e));return}this.player.cueVideoById({videoId:d,startSeconds:(0,p.parseStartTime)(e)||l.start,endSeconds:(0,p.parseEndTime)(e)||l.end});return}(0,p.getSDK)(G,T,z,c=>c.loaded).then(c=>{this.container&&(this.player=new c.Player(this.container,{width:"100%",height:"100%",videoId:d,playerVars:{autoplay:s?1:0,mute:r?1:0,controls:P?1:0,start:(0,p.parseStartTime)(e),end:(0,p.parseEndTime)(e),origin:window.location.origin,playsinline:n?1:0,...this.parsePlaylist(e),...l},events:{onReady:()=>{_&&this.player.setLoop(!0),this.props.onReady()},onPlaybackRateChange:i=>this.props.onPlaybackRateChange(i.data),onPlaybackQualityChange:i=>this.props.onPlaybackQualityChange(i),onStateChange:this.onStateChange,onError:i=>y(i.data)},host:Q.test(e)?Z:void 0,...h}))},y),h.events&&console.warn("Using `embedOptions.events` will likely break things. Use ReactPlayer’s callback props instead, eg onReady, onPlay, onPause")}play(){this.callPlayer("playVideo")}pause(){this.callPlayer("pauseVideo")}stop(){document.body.contains(this.callPlayer("getIframe"))&&this.callPlayer("stopVideo")}seekTo(e,t=!1){this.callPlayer("seekTo",e),!t&&!this.props.playing&&this.pause()}setVolume(e){this.callPlayer("setVolume",e*100)}setPlaybackRate(e){this.callPlayer("setPlaybackRate",e)}setLoop(e){this.callPlayer("setLoop",e)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentTime")}getSecondsLoaded(){return this.callPlayer("getVideoLoadedFraction")*this.getDuration()}render(){const{display:e}=this.props,t={width:"100%",height:"100%",display:e};return m.default.createElement("div",{style:t},m.default.createElement("div",{ref:this.ref}))}}o(O,"displayName","YouTube");o(O,"canPlay",D.canPlay.youtube);const $=U(S),W=k({__proto__:null,default:$},[S]);export{W as Y}; diff --git a/build/assets/constants-bc1d79ca.js b/build/assets/constants-b9d9206a.js similarity index 50% rename from build/assets/constants-bc1d79ca.js rename to build/assets/constants-b9d9206a.js index 0cf46cb33..b3e05dacd 100644 --- a/build/assets/constants-bc1d79ca.js +++ b/build/assets/constants-b9d9206a.js @@ -1,8 +1,8 @@ -import{s,b2 as t,b0 as o,b1 as a,b3 as n}from"./index-4bb27744.js";import{e as c}from"./index-7730ff6f.js";const i={[t]:"RSS link",[o]:"Twitter Handle",[a]:"Youtube channel",[n]:"Github Repository"},r="Sources Table",E="Queued Sources",I="Topics",S="View Content",u="date",p="edge_count",l="alphabetically",_="https://twitter.com",b="IS_ALIAS",A="https://www.twitter.com/anyuser/status/",d=s(c)` +import{s,b1 as t,a$ as a,b0 as o,b2 as n}from"./index-4e60c9e2.js";import{e as c}from"./index-af5a3f81.js";const i={[t]:"RSS link",[a]:"Twitter Handle",[o]:"Youtube channel",[n]:"Github Repository"},r="Sources Table",E="Queued Sources",I="Topics",S="View Content",u="date",p="edge_count",l="alphabetically",_="https://twitter.com",A="IS_ALIAS",b="https://www.twitter.com/anyuser/status/",d=s(c)` && { vertical-align: middle; margin: 5px 0 0 4px; padding: 4px; transition: background-color 150ms cubic-bezier(0.4, 0, 0.2, 1); } -`;export{l as A,u as D,p as E,b as I,E as Q,d as S,A as T,S as V,_ as a,I as b,r as c,i as s}; +`;export{l as A,u as D,p as E,A as I,E as Q,d as S,b as T,S as V,_ as a,I as b,r as c,i as s}; diff --git a/build/assets/createSvgIcon-41051178.js b/build/assets/createSvgIcon-c125a9c8.js similarity index 94% rename from build/assets/createSvgIcon-41051178.js rename to build/assets/createSvgIcon-c125a9c8.js index 88555d419..6d455ab32 100644 --- a/build/assets/createSvgIcon-41051178.js +++ b/build/assets/createSvgIcon-c125a9c8.js @@ -1 +1 @@ -import{L as I,M as C,N as w,Y as f,r as v,S as R,H as N,O as S,j as g,U as b,V as j}from"./index-4bb27744.js";function M(o){return I("MuiSvgIcon",o)}C("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const A=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],B=o=>{const{color:e,fontSize:t,classes:i}=o,n={root:["root",e!=="inherit"&&`color${f(e)}`,`fontSize${f(t)}`]};return j(n,M,i)},T=w("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(o,e)=>{const{ownerState:t}=o;return[e.root,t.color!=="inherit"&&e[`color${f(t.color)}`],e[`fontSize${f(t.fontSize)}`]]}})(({theme:o,ownerState:e})=>{var t,i,n,u,m,a,h,p,d,r,s,c,l;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:e.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(t=o.transitions)==null||(i=t.create)==null?void 0:i.call(t,"fill",{duration:(n=o.transitions)==null||(n=n.duration)==null?void 0:n.shorter}),fontSize:{inherit:"inherit",small:((u=o.typography)==null||(m=u.pxToRem)==null?void 0:m.call(u,20))||"1.25rem",medium:((a=o.typography)==null||(h=a.pxToRem)==null?void 0:h.call(a,24))||"1.5rem",large:((p=o.typography)==null||(d=p.pxToRem)==null?void 0:d.call(p,35))||"2.1875rem"}[e.fontSize],color:(r=(s=(o.vars||o).palette)==null||(s=s[e.color])==null?void 0:s.main)!=null?r:{action:(c=(o.vars||o).palette)==null||(c=c.action)==null?void 0:c.active,disabled:(l=(o.vars||o).palette)==null||(l=l.action)==null?void 0:l.disabled,inherit:void 0}[e.color]}}),_=v.forwardRef(function(e,t){const i=R({props:e,name:"MuiSvgIcon"}),{children:n,className:u,color:m="inherit",component:a="svg",fontSize:h="medium",htmlColor:p,inheritViewBox:d=!1,titleAccess:r,viewBox:s="0 0 24 24"}=i,c=N(i,A),l=v.isValidElement(n)&&n.type==="svg",y=S({},i,{color:m,component:a,fontSize:h,instanceFontSize:e.fontSize,inheritViewBox:d,viewBox:s,hasSvgAsChild:l}),x={};d||(x.viewBox=s);const z=B(y);return g.jsxs(T,S({as:a,className:b(z.root,u),focusable:"false",color:p,"aria-hidden":r?void 0:!0,role:r?"img":void 0,ref:t},x,c,l&&n.props,{ownerState:y,children:[l?n.props.children:n,r?g.jsx("title",{children:r}):null]}))});_.muiName="SvgIcon";const $=_;function E(o,e){function t(i,n){return g.jsx($,S({"data-testid":`${e}Icon`,ref:n},i,{children:o}))}return t.muiName=$.muiName,v.memo(v.forwardRef(t))}export{E as c}; +import{K as I,L as C,M as w,X as f,r as v,P as R,G as N,N as S,j as g,S as b,U as j}from"./index-4e60c9e2.js";function M(o){return I("MuiSvgIcon",o)}C("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const A=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],B=o=>{const{color:e,fontSize:t,classes:i}=o,n={root:["root",e!=="inherit"&&`color${f(e)}`,`fontSize${f(t)}`]};return j(n,M,i)},T=w("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(o,e)=>{const{ownerState:t}=o;return[e.root,t.color!=="inherit"&&e[`color${f(t.color)}`],e[`fontSize${f(t.fontSize)}`]]}})(({theme:o,ownerState:e})=>{var t,i,n,u,m,a,h,p,d,r,s,c,l;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:e.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(t=o.transitions)==null||(i=t.create)==null?void 0:i.call(t,"fill",{duration:(n=o.transitions)==null||(n=n.duration)==null?void 0:n.shorter}),fontSize:{inherit:"inherit",small:((u=o.typography)==null||(m=u.pxToRem)==null?void 0:m.call(u,20))||"1.25rem",medium:((a=o.typography)==null||(h=a.pxToRem)==null?void 0:h.call(a,24))||"1.5rem",large:((p=o.typography)==null||(d=p.pxToRem)==null?void 0:d.call(p,35))||"2.1875rem"}[e.fontSize],color:(r=(s=(o.vars||o).palette)==null||(s=s[e.color])==null?void 0:s.main)!=null?r:{action:(c=(o.vars||o).palette)==null||(c=c.action)==null?void 0:c.active,disabled:(l=(o.vars||o).palette)==null||(l=l.action)==null?void 0:l.disabled,inherit:void 0}[e.color]}}),_=v.forwardRef(function(e,t){const i=R({props:e,name:"MuiSvgIcon"}),{children:n,className:u,color:m="inherit",component:a="svg",fontSize:h="medium",htmlColor:p,inheritViewBox:d=!1,titleAccess:r,viewBox:s="0 0 24 24"}=i,c=N(i,A),l=v.isValidElement(n)&&n.type==="svg",y=S({},i,{color:m,component:a,fontSize:h,instanceFontSize:e.fontSize,inheritViewBox:d,viewBox:s,hasSvgAsChild:l}),x={};d||(x.viewBox=s);const z=B(y);return g.jsxs(T,S({as:a,className:b(z.root,u),focusable:"false",color:p,"aria-hidden":r?void 0:!0,role:r?"img":void 0,ref:t},x,c,l&&n.props,{ownerState:y,children:[l?n.props.children:n,r?g.jsx("title",{children:r}):null]}))});_.muiName="SvgIcon";const $=_;function E(o,e){function t(i,n){return g.jsx($,S({"data-testid":`${e}Icon`,ref:n},i,{children:o}))}return t.muiName=$.muiName,v.memo(v.forwardRef(t))}export{E as c}; diff --git a/build/assets/index-c3934e6a.js b/build/assets/index-047858ad.js similarity index 78% rename from build/assets/index-c3934e6a.js rename to build/assets/index-047858ad.js index b9c57cee4..62cd3145a 100644 --- a/build/assets/index-c3934e6a.js +++ b/build/assets/index-047858ad.js @@ -1,4 +1,4 @@ -import{s as c,a as N,T as _,F as r,e as x,q as W,r as d,j as e,aY as P,aZ as V,t as k,u as q,v as G,B as F,bw as Y,bx as H,a$ as Z}from"./index-4bb27744.js";import{l as I,aB as J}from"./index-7730ff6f.js";import{T as K}from"./index-5111ebdb.js";import{S as Q}from"./Skeleton-dbbfd404.js";import{C as X}from"./ClipLoader-1ef5878d.js";const ee=/^https:\/\/\S+\.(png|jpe?g|svg)$/;function te(i){return!!ee.test(i)}function ae(i){return i.split("_").map(p=>p.charAt(0).toUpperCase()+p.slice(1)).join(" ")}const oe=()=>{const{open:i}=x("changeNodeType"),{close:p}=x("editNodeName"),{changeNodeTypeFeatureFlag:y}=W(o=>({changeNodeTypeFeatureFlag:o.changeNodeTypeFeatureFlag})),a=I(),j=a==null?void 0:a.node_type,[m,g]=d.useState({});d.useEffect(()=>{a!=null&&a.properties&&g(a.properties)},[a]);const b=()=>{p(),i()},h=(o,n)=>{g(T=>({...T,[o]:n}))};return e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsxs(r,{align:"center",direction:"row",children:[e.jsx(ne,{children:"Edit Node"}),e.jsxs(re,{children:[e.jsx(K,{type:j}),y&&e.jsx(ie,{onClick:b,children:e.jsx(J,{})})]})]})}),e.jsx(ce,{children:Object.keys(m).map(o=>e.jsxs(r,{mb:18,children:[e.jsx(se,{style:{marginBottom:8},children:ae(o)}),e.jsx(P,{id:`cy-${o}`,maxLength:50,name:`properties.${o}`,onChange:n=>h(o,n),placeholder:`Please Enter the ${o}`,rules:o==="name"?{...V}:{}})]},o))})]})},ne=c(_)` +import{s as c,a as N,T as _,F as r,e as x,q as W,r as d,j as e,aX as P,aY as V,t as k,u as q,v as G,B as F,bv as Y,bw as H,a_ as X}from"./index-4e60c9e2.js";import{l as I,aB as J}from"./index-af5a3f81.js";import{T as K}from"./index-569670a3.js";import{S as Q}from"./Skeleton-7af13a79.js";import{C as Z}from"./ClipLoader-8590c2f1.js";const ee=/^https:\/\/\S+\.(png|jpe?g|svg)$/;function te(i){return!!ee.test(i)}function ae(i){return i.split("_").map(p=>p.charAt(0).toUpperCase()+p.slice(1)).join(" ")}const oe=()=>{const{open:i}=x("changeNodeType"),{close:p}=x("editNodeName"),{changeNodeTypeFeatureFlag:y}=W(o=>({changeNodeTypeFeatureFlag:o.changeNodeTypeFeatureFlag})),a=I(),j=a==null?void 0:a.node_type,[m,g]=d.useState({});d.useEffect(()=>{a!=null&&a.properties&&g(a.properties)},[a]);const b=()=>{p(),i()},h=(o,n)=>{g(T=>({...T,[o]:n}))};return e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsxs(r,{align:"center",direction:"row",children:[e.jsx(ne,{children:"Edit Node"}),e.jsxs(re,{children:[e.jsx(K,{type:j}),y&&e.jsx(ie,{onClick:b,children:e.jsx(J,{})})]})]})}),e.jsx(ce,{children:Object.keys(m).map(o=>e.jsxs(r,{mb:18,children:[e.jsx(se,{style:{marginBottom:8},children:ae(o)}),e.jsx(P,{id:`cy-${o}`,maxLength:50,name:`properties.${o}`,onChange:n=>h(o,n),placeholder:`Please Enter the ${o}`,rules:o==="name"?{...V}:{}})]},o))})]})},ne=c(_)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; @@ -23,7 +23,7 @@ import{s as c,a as N,T as _,F as r,e as x,q as W,r as d,j as e,aY as P,aZ as V,t overflow-y: auto; padding-right: 40px; width: calc(100% + 40px); -`,le=()=>{var w,E,S;const{close:i}=x("editNodeName"),p=k({mode:"onChange"}),{watch:y,setValue:a,reset:j,getValues:m}=p,[g,b]=d.useState(!1),[h,o]=d.useState(!1),[n,T]=d.useState(),t=I(),B=q(s=>s.updateNode),{open:D}=x("removeNode");d.useEffect(()=>(n?Object.keys(n).forEach(s=>{a(s,n[s])}):t&&Object.keys(t).forEach(s=>{a(s,t[s])}),()=>{j()}),[n,a,j,t]),d.useEffect(()=>{(async()=>{if(!(!t||t.type!=="topic")){o(!0);try{const{data:u}=await Y({search:t==null?void 0:t.name}),f=u.find(O=>O.name===t.name);T(f)}catch(u){console.error(u)}finally{o(!1)}}})()},[t]);const L=y("imageInputType"),C=y("image_url");d.useEffect(()=>{a("imageInputType",te(C))},[C,a]);const $=()=>{i()},l=n||t,R=async()=>{if(!l)return;b(!0);const s=m(),u={name:s.name,image_url:s.image_url,properties:s.properties};try{const f={node_type:l.node_type,ref_id:l.ref_id,properties:u.properties};await H((l==null?void 0:l.ref_id)||"",f),B({...l,...u}),$()}catch(f){console.warn(f)}finally{b(!1)}},z=async()=>{D()},v=(E=(w=m())==null?void 0:w.name)==null?void 0:E.trim(),M=v&&(n==null?void 0:n.name.trim())!==v,U=m().image_url&&(t==null?void 0:t.image_url)!==((S=m())==null?void 0:S.image_url),A=g||h||!!C&&!L||!M&&!U;return e.jsx(de,{children:e.jsxs(G,{...p,children:[h?e.jsx(r,{my:24,children:e.jsx(Q,{})}):e.jsx(oe,{}),e.jsxs(r,{direction:"row",justify:"space-between",mt:20,children:[e.jsx(r,{direction:"column",children:e.jsx(pe,{color:"secondary",disabled:h||!l,onClick:z,size:"large",variant:"contained",children:"Delete"})}),e.jsxs(ue,{color:"secondary",disabled:A,onClick:R,size:"large",variant:"contained",children:["Save Changes",g&&e.jsx(me,{children:e.jsx(X,{color:N.lightGray,size:12})})]})]})]})})},de=c(r)` +`,le=()=>{var w,E,S;const{close:i}=x("editNodeName"),p=k({mode:"onChange"}),{watch:y,setValue:a,reset:j,getValues:m}=p,[g,b]=d.useState(!1),[h,o]=d.useState(!1),[n,T]=d.useState(),t=I(),B=q(s=>s.updateNode),{open:D}=x("removeNode");d.useEffect(()=>(n?Object.keys(n).forEach(s=>{a(s,n[s])}):t&&Object.keys(t).forEach(s=>{a(s,t[s])}),()=>{j()}),[n,a,j,t]),d.useEffect(()=>{(async()=>{if(!(!t||t.type!=="topic")){o(!0);try{const{data:u}=await Y({search:t==null?void 0:t.name}),f=u.find(O=>O.name===t.name);T(f)}catch(u){console.error(u)}finally{o(!1)}}})()},[t]);const L=y("imageInputType"),v=y("image_url");d.useEffect(()=>{a("imageInputType",te(v))},[v,a]);const R=()=>{i()},l=n||t,$=async()=>{if(!l)return;b(!0);const s=m(),u={name:s.name,image_url:s.image_url,properties:s.properties};try{const f={node_type:l.node_type,ref_id:l.ref_id,properties:u.properties};await H((l==null?void 0:l.ref_id)||"",f),B({...l,...u}),R()}catch(f){console.warn(f)}finally{b(!1)}},z=async()=>{D()},C=(E=(w=m())==null?void 0:w.name)==null?void 0:E.trim(),M=C&&(n==null?void 0:n.name.trim())!==C,U=m().image_url&&(t==null?void 0:t.image_url)!==((S=m())==null?void 0:S.image_url),A=g||h||!!v&&!L||!M&&!U;return e.jsx(de,{children:e.jsxs(G,{...p,children:[h?e.jsx(r,{my:24,children:e.jsx(Q,{})}):e.jsx(oe,{}),e.jsxs(r,{direction:"row",justify:"space-between",mt:20,children:[e.jsx(r,{direction:"column",children:e.jsx(pe,{color:"secondary",disabled:h||!l,onClick:z,size:"large",variant:"contained",children:"Delete"})}),e.jsxs(ue,{color:"secondary",disabled:A,onClick:$,size:"large",variant:"contained",children:["Save Changes",g&&e.jsx(me,{children:e.jsx(Z,{color:N.lightGray,size:12})})]})]})]})})},de=c(r)` padding: 20px; `,pe=c(F)` && { @@ -44,4 +44,4 @@ import{s as c,a as N,T as _,F as r,e as x,q as W,r as d,j as e,aY as P,aZ as V,t `,ue=c(F)` width: 80% !important; margin: 0 auto !important; -`,je=()=>{const{close:i}=x("editNodeName");return e.jsx(Z,{id:"editNodeName",kind:"regular",onClose:i,preventOutsideClose:!0,children:e.jsx(le,{})})};export{je as EditNodeNameModal}; +`,je=()=>{const{close:i}=x("editNodeName");return e.jsx(X,{id:"editNodeName",kind:"regular",onClose:i,preventOutsideClose:!0,children:e.jsx(le,{})})};export{je as EditNodeNameModal}; diff --git a/build/assets/index-22c3582f.js b/build/assets/index-22c3582f.js deleted file mode 100644 index 363257cb0..000000000 --- a/build/assets/index-22c3582f.js +++ /dev/null @@ -1,71 +0,0 @@ -import{r as u,j as f,c0 as kt,c1 as Rt,a2 as xo,a0 as Ot,O as a,L as ye,M as $e,N as w,Y as L,S as Pe,H as ae,U as ne,V as Ie,P as Re,Z as lo,X as Uo,c2 as Lt,c3 as wt,$ as st,c4 as it,bz as ct,bA as dt,ak as Xe,c5 as To,a3 as Mt,an as Ft,s as Tt,a as je,F as At}from"./index-4bb27744.js";import{T as Nt}from"./index-5111ebdb.js";import{a as Ao,u as fo,b as so,f as io,i as ut,c as zt,P as No,F as Dt,S as Et}from"./Stack-6038813c.js";import{L as Ho,e as pt,ap as ft,aL as Bt,w as Fo,P as jt,aM as Wt,Q as Vo}from"./index-7730ff6f.js";import{c as zo}from"./createSvgIcon-41051178.js";import{T as _t}from"./TextareaAutosize-b716e8d1.js";const Ut=e=>{const o=u.useRef({});return u.useEffect(()=>{o.current=e}),o.current},Ht=Ut;function Vt(e){return e==null||Object.keys(e).length===0}function Kt(e){const{styles:o,defaultTheme:t={}}=e,r=typeof o=="function"?s=>o(Vt(s)?t:s):o;return f.jsx(kt,{styles:r})}function qt({styles:e,themeId:o,defaultTheme:t={}}){const r=Rt(t),s=typeof e=="function"?e(o&&r[o]||r):e;return f.jsx(Kt,{styles:s})}const Gt=zo(f.jsx("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close");function Ko(e){return typeof e.normalize<"u"?e.normalize("NFD").replace(/[\u0300-\u036f]/g,""):e}function Xt(e={}){const{ignoreAccents:o=!0,ignoreCase:t=!0,limit:r,matchFrom:s="any",stringify:c,trim:d=!1}=e;return(i,{inputValue:b,getOptionLabel:p})=>{let m=d?b.trim():b;t&&(m=m.toLowerCase()),o&&(m=Ko(m));const h=m?i.filter($=>{let v=(c||p)($);return t&&(v=v.toLowerCase()),o&&(v=Ko(v)),s==="start"?v.indexOf(m)===0:v.indexOf(m)>-1}):i;return typeof r=="number"?h.slice(0,r):h}}function wo(e,o){for(let t=0;t{var o;return e.current!==null&&((o=e.current.parentElement)==null?void 0:o.contains(document.activeElement))};function Qt(e){const{unstable_isActiveElementInListbox:o=Zt,unstable_classNamePrefix:t="Mui",autoComplete:r=!1,autoHighlight:s=!1,autoSelect:c=!1,blurOnSelect:d=!1,clearOnBlur:i=!e.freeSolo,clearOnEscape:b=!1,componentName:p="useAutocomplete",defaultValue:m=e.multiple?[]:null,disableClearable:h=!1,disableCloseOnSelect:$=!1,disabled:v,disabledItemsFocusable:R=!1,disableListWrap:M=!1,filterOptions:P=Yt,filterSelectedOptions:O=!1,freeSolo:k=!1,getOptionDisabled:C,getOptionKey:I,getOptionLabel:E=l=>{var n;return(n=l.label)!=null?n:l},groupBy:N,handleHomeEndKeys:F=!e.freeSolo,id:q,includeInputInList:le=!1,inputValue:de,isOptionEqualToValue:oe=(l,n)=>l===n,multiple:T=!1,onChange:Q,onClose:G,onHighlightChange:se,onInputChange:J,onOpen:re,open:U,openOnFocus:A=!1,options:ie,readOnly:Se=!1,selectOnFocus:we=!e.freeSolo,value:ue}=e,W=Ao(q);let ee=E;ee=l=>{const n=E(l);return typeof n!="string"?String(n):n};const fe=u.useRef(!1),We=u.useRef(!0),Z=u.useRef(null),be=u.useRef(null),[Me,Y]=u.useState(null),[H,ze]=u.useState(-1),_e=s?0:-1,te=u.useRef(_e),[S,to]=fo({controlled:ue,default:m,name:p}),[_,xe]=fo({controlled:de,default:"",name:p,state:"inputValue"}),[Fe,ce]=u.useState(!1),Te=u.useCallback((l,n)=>{if(!(T?S.length!(O&&(T?S:[S]).some(n=>n!==null&&oe(l,n)))),{inputValue:Ee&&Ye?"":_,getOptionLabel:ee}):[],he=Ht({filteredOptions:j,value:S,inputValue:_});u.useEffect(()=>{const l=S!==he.value;Fe&&!l||k&&!l||Te(null,S)},[S,Te,Fe,he.value,k]);const Ke=me&&j.length>0&&!Se,qe=xo(l=>{l===-1?Z.current.focus():Me.querySelector(`[data-tag-index="${l}"]`).focus()});u.useEffect(()=>{T&&H>S.length-1&&(ze(-1),qe(-1))},[S,T,H,qe]);function y(l,n){if(!be.current||l<0||l>=j.length)return-1;let g=l;for(;;){const x=be.current.querySelector(`[data-option-index="${g}"]`),K=R?!1:!x||x.disabled||x.getAttribute("aria-disabled")==="true";if(x&&x.hasAttribute("tabindex")&&!K)return g;if(n==="next"?g=(g+1)%j.length:g=(g-1+j.length)%j.length,g===l)return-1}}const B=xo(({event:l,index:n,reason:g="auto"})=>{if(te.current=n,n===-1?Z.current.removeAttribute("aria-activedescendant"):Z.current.setAttribute("aria-activedescendant",`${W}-option-${n}`),se&&se(l,n===-1?null:j[n],g),!be.current)return;const x=be.current.querySelector(`[role="option"].${t}-focused`);x&&(x.classList.remove(`${t}-focused`),x.classList.remove(`${t}-focusVisible`));let K=be.current;if(be.current.getAttribute("role")!=="listbox"&&(K=be.current.parentElement.querySelector('[role="listbox"]')),!K)return;if(n===-1){K.scrollTop=0;return}const pe=be.current.querySelector(`[data-option-index="${n}"]`);if(pe&&(pe.classList.add(`${t}-focused`),g==="keyboard"&&pe.classList.add(`${t}-focusVisible`),K.scrollHeight>K.clientHeight&&g!=="mouse"&&g!=="touch")){const ge=pe,He=K.clientHeight+K.scrollTop,_o=ge.offsetTop+ge.offsetHeight;_o>He?K.scrollTop=_o-K.clientHeight:ge.offsetTop-ge.offsetHeight*(N?1.3:0){if(!z)return;const pe=y((()=>{const ge=j.length-1;if(n==="reset")return _e;if(n==="start")return 0;if(n==="end")return ge;const He=te.current+n;return He<0?He===-1&&le?-1:M&&te.current!==-1||Math.abs(n)>1?0:ge:He>ge?He===ge+1&&le?-1:M||Math.abs(n)>1?ge:0:He})(),g);if(B({index:pe,reason:x,event:l}),r&&n!=="reset")if(pe===-1)Z.current.value=_;else{const ge=ee(j[pe]);Z.current.value=ge,ge.toLowerCase().indexOf(_.toLowerCase())===0&&_.length>0&&Z.current.setSelectionRange(_.length,ge.length)}}),ke=()=>{const l=(n,g)=>{const x=n?ee(n):"",K=g?ee(g):"";return x===K};if(te.current!==-1&&he.filteredOptions&&he.filteredOptions.length!==j.length&&he.inputValue===_&&(T?S.length===he.value.length&&he.value.every((n,g)=>ee(S[g])===ee(n)):l(he.value,S))){const n=he.filteredOptions[te.current];if(n&&j.some(x=>ee(x)===ee(n)))return!0}return!1},Ze=u.useCallback(()=>{if(!z||ke())return;const l=T?S[0]:S;if(j.length===0||l==null){X({diff:"reset"});return}if(be.current){if(l!=null){const n=j[te.current];if(T&&n&&wo(S,x=>oe(n,x))!==-1)return;const g=wo(j,x=>oe(x,l));g===-1?X({diff:"reset"}):B({index:g});return}if(te.current>=j.length-1){B({index:j.length-1});return}B({index:te.current})}},[j.length,T?!1:S,O,X,B,z,_,T]),Po=xo(l=>{Ot(be,l),l&&Ze()});u.useEffect(()=>{Ze()},[Ze]);const Ne=l=>{me||(Ae(!0),De(!0),re&&re(l))},Ge=(l,n)=>{me&&(Ae(!1),G&&G(l,n))},Ue=(l,n,g,x)=>{if(T){if(S.length===n.length&&S.every((K,pe)=>K===n[pe]))return}else if(S===n)return;Q&&Q(l,n,g,x),to(n)},no=u.useRef(!1),eo=(l,n,g="selectOption",x="options")=>{let K=g,pe=n;if(T){pe=Array.isArray(S)?S.slice():[];const ge=wo(pe,He=>oe(n,He));ge===-1?pe.push(n):x!=="freeSolo"&&(pe.splice(ge,1),K="removeOption")}Te(l,pe),Ue(l,pe,K,{option:n}),!$&&(!l||!l.ctrlKey&&!l.metaKey)&&Ge(l,K),(d===!0||d==="touch"&&no.current||d==="mouse"&&!no.current)&&Z.current.blur()};function go(l,n){if(l===-1)return-1;let g=l;for(;;){if(n==="next"&&g===S.length||n==="previous"&&g===-1)return-1;const x=Me.querySelector(`[data-tag-index="${g}"]`);if(!x||!x.hasAttribute("tabindex")||x.disabled||x.getAttribute("aria-disabled")==="true")g+=n==="next"?1:-1;else return g}}const mo=(l,n)=>{if(!T)return;_===""&&Ge(l,"toggleInput");let g=H;H===-1?_===""&&n==="previous"&&(g=S.length-1):(g+=n==="next"?1:-1,g<0&&(g=0),g===S.length&&(g=-1)),g=go(g,n),ze(g),qe(g)},ho=l=>{fe.current=!0,xe(""),J&&J(l,"","clear"),Ue(l,T?[]:null,"clear")},ko=l=>n=>{if(l.onKeyDown&&l.onKeyDown(n),!n.defaultMuiPrevented&&(H!==-1&&["ArrowLeft","ArrowRight"].indexOf(n.key)===-1&&(ze(-1),qe(-1)),n.which!==229))switch(n.key){case"Home":z&&F&&(n.preventDefault(),X({diff:"start",direction:"next",reason:"keyboard",event:n}));break;case"End":z&&F&&(n.preventDefault(),X({diff:"end",direction:"previous",reason:"keyboard",event:n}));break;case"PageUp":n.preventDefault(),X({diff:-qo,direction:"previous",reason:"keyboard",event:n}),Ne(n);break;case"PageDown":n.preventDefault(),X({diff:qo,direction:"next",reason:"keyboard",event:n}),Ne(n);break;case"ArrowDown":n.preventDefault(),X({diff:1,direction:"next",reason:"keyboard",event:n}),Ne(n);break;case"ArrowUp":n.preventDefault(),X({diff:-1,direction:"previous",reason:"keyboard",event:n}),Ne(n);break;case"ArrowLeft":mo(n,"previous");break;case"ArrowRight":mo(n,"next");break;case"Enter":if(te.current!==-1&&z){const g=j[te.current],x=C?C(g):!1;if(n.preventDefault(),x)return;eo(n,g,"selectOption"),r&&Z.current.setSelectionRange(Z.current.value.length,Z.current.value.length)}else k&&_!==""&&Ee===!1&&(T&&n.preventDefault(),eo(n,_,"createOption","freeSolo"));break;case"Escape":z?(n.preventDefault(),n.stopPropagation(),Ge(n,"escape")):b&&(_!==""||T&&S.length>0)&&(n.preventDefault(),n.stopPropagation(),ho(n));break;case"Backspace":if(T&&!Se&&_===""&&S.length>0){const g=H===-1?S.length-1:H,x=S.slice();x.splice(g,1),Ue(n,x,"removeOption",{option:S[g]})}break;case"Delete":if(T&&!Se&&_===""&&S.length>0&&H!==-1){const g=H,x=S.slice();x.splice(g,1),Ue(n,x,"removeOption",{option:S[g]})}break}},jo=l=>{ce(!0),A&&!fe.current&&Ne(l)},ro=l=>{if(o(be)){Z.current.focus();return}ce(!1),We.current=!0,fe.current=!1,c&&te.current!==-1&&z?eo(l,j[te.current],"blur"):c&&k&&_!==""?eo(l,_,"blur","freeSolo"):i&&Te(l,S),Ge(l,"blur")},Ce=l=>{const n=l.target.value;_!==n&&(xe(n),De(!1),J&&J(l,n,"input")),n===""?!h&&!T&&Ue(l,null,"clear"):Ne(l)},ve=l=>{const n=Number(l.currentTarget.getAttribute("data-option-index"));te.current!==n&&B({event:l,index:n,reason:"mouse"})},Be=l=>{B({event:l,index:Number(l.currentTarget.getAttribute("data-option-index")),reason:"touch"}),no.current=!0},Wo=l=>{const n=Number(l.currentTarget.getAttribute("data-option-index"));eo(l,j[n],"selectOption"),no.current=!1},Ro=l=>n=>{const g=S.slice();g.splice(l,1),Ue(n,g,"removeOption",{option:S[l]})},Oo=l=>{me?Ge(l,"toggleInput"):Ne(l)},Lo=l=>{l.currentTarget.contains(l.target)&&l.target.getAttribute("id")!==W&&l.preventDefault()},vo=l=>{l.currentTarget.contains(l.target)&&(Z.current.focus(),we&&We.current&&Z.current.selectionEnd-Z.current.selectionStart===0&&Z.current.select(),We.current=!1)},co=l=>{!v&&(_===""||!me)&&Oo(l)};let oo=k&&_.length>0;oo=oo||(T?S.length>0:S!==null);let ao=j;return N&&(ao=j.reduce((l,n,g)=>{const x=N(n);return l.length>0&&l[l.length-1].group===x?l[l.length-1].options.push(n):l.push({key:g,index:g,group:x,options:[n]}),l},[])),v&&Fe&&ro(),{getRootProps:(l={})=>a({"aria-owns":Ke?`${W}-listbox`:null},l,{onKeyDown:ko(l),onMouseDown:Lo,onClick:vo}),getInputLabelProps:()=>({id:`${W}-label`,htmlFor:W}),getInputProps:()=>({id:W,value:_,onBlur:ro,onFocus:jo,onChange:Ce,onMouseDown:co,"aria-activedescendant":z?"":null,"aria-autocomplete":r?"both":"list","aria-controls":Ke?`${W}-listbox`:void 0,"aria-expanded":Ke,autoComplete:"off",ref:Z,autoCapitalize:"none",spellCheck:"false",role:"combobox",disabled:v}),getClearProps:()=>({tabIndex:-1,type:"button",onClick:ho}),getPopupIndicatorProps:()=>({tabIndex:-1,type:"button",onClick:Oo}),getTagProps:({index:l})=>a({key:l,"data-tag-index":l,tabIndex:-1},!Se&&{onDelete:Ro(l)}),getListboxProps:()=>({role:"listbox",id:`${W}-listbox`,"aria-labelledby":`${W}-label`,ref:Po,onMouseDown:l=>{l.preventDefault()}}),getOptionProps:({index:l,option:n})=>{var g;const x=(T?S:[S]).some(pe=>pe!=null&&oe(n,pe)),K=C?C(n):!1;return{key:(g=I==null?void 0:I(n))!=null?g:ee(n),tabIndex:-1,role:"option",id:`${W}-option-${l}`,onMouseMove:ve,onClick:Wo,onTouchStart:Be,"data-option-index":l,"aria-disabled":K,"aria-selected":x}},id:W,inputValue:_,value:S,dirty:oo,expanded:z&&Me,popupOpen:z,focused:Fe||H!==-1,anchorEl:Me,setAnchorEl:Y,focusedTag:H,groupedOptions:ao}}function Jt(e){return ye("MuiListSubheader",e)}$e("MuiListSubheader",["root","colorPrimary","colorInherit","gutters","inset","sticky"]);const en=["className","color","component","disableGutters","disableSticky","inset"],on=e=>{const{classes:o,color:t,disableGutters:r,inset:s,disableSticky:c}=e,d={root:["root",t!=="default"&&`color${L(t)}`,!r&&"gutters",s&&"inset",!c&&"sticky"]};return Ie(d,Jt,o)},tn=w("li",{name:"MuiListSubheader",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.root,t.color!=="default"&&o[`color${L(t.color)}`],!t.disableGutters&&o.gutters,t.inset&&o.inset,!t.disableSticky&&o.sticky]}})(({theme:e,ownerState:o})=>a({boxSizing:"border-box",lineHeight:"48px",listStyle:"none",color:(e.vars||e).palette.text.secondary,fontFamily:e.typography.fontFamily,fontWeight:e.typography.fontWeightMedium,fontSize:e.typography.pxToRem(14)},o.color==="primary"&&{color:(e.vars||e).palette.primary.main},o.color==="inherit"&&{color:"inherit"},!o.disableGutters&&{paddingLeft:16,paddingRight:16},o.inset&&{paddingLeft:72},!o.disableSticky&&{position:"sticky",top:0,zIndex:1,backgroundColor:(e.vars||e).palette.background.paper})),bt=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiListSubheader"}),{className:s,color:c="default",component:d="li",disableGutters:i=!1,disableSticky:b=!1,inset:p=!1}=r,m=ae(r,en),h=a({},r,{color:c,component:d,disableGutters:i,disableSticky:b,inset:p}),$=on(h);return f.jsx(tn,a({as:d,className:ne($.root,s),ref:t,ownerState:h},m))});bt.muiSkipListHighlight=!0;const nn=bt,rn=zo(f.jsx("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"}),"Cancel");function an(e){return ye("MuiChip",e)}const ln=$e("MuiChip",["root","sizeSmall","sizeMedium","colorError","colorInfo","colorPrimary","colorSecondary","colorSuccess","colorWarning","disabled","clickable","clickableColorPrimary","clickableColorSecondary","deletable","deletableColorPrimary","deletableColorSecondary","outlined","filled","outlinedPrimary","outlinedSecondary","filledPrimary","filledSecondary","avatar","avatarSmall","avatarMedium","avatarColorPrimary","avatarColorSecondary","icon","iconSmall","iconMedium","iconColorPrimary","iconColorSecondary","label","labelSmall","labelMedium","deleteIcon","deleteIconSmall","deleteIconMedium","deleteIconColorPrimary","deleteIconColorSecondary","deleteIconOutlinedColorPrimary","deleteIconOutlinedColorSecondary","deleteIconFilledColorPrimary","deleteIconFilledColorSecondary","focusVisible"]),V=ln,sn=["avatar","className","clickable","color","component","deleteIcon","disabled","icon","label","onClick","onDelete","onKeyDown","onKeyUp","size","variant","tabIndex","skipFocusWhenDisabled"],cn=e=>{const{classes:o,disabled:t,size:r,color:s,iconColor:c,onDelete:d,clickable:i,variant:b}=e,p={root:["root",b,t&&"disabled",`size${L(r)}`,`color${L(s)}`,i&&"clickable",i&&`clickableColor${L(s)}`,d&&"deletable",d&&`deletableColor${L(s)}`,`${b}${L(s)}`],label:["label",`label${L(r)}`],avatar:["avatar",`avatar${L(r)}`,`avatarColor${L(s)}`],icon:["icon",`icon${L(r)}`,`iconColor${L(c)}`],deleteIcon:["deleteIcon",`deleteIcon${L(r)}`,`deleteIconColor${L(s)}`,`deleteIcon${L(b)}Color${L(s)}`]};return Ie(p,an,o)},dn=w("div",{name:"MuiChip",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e,{color:r,iconColor:s,clickable:c,onDelete:d,size:i,variant:b}=t;return[{[`& .${V.avatar}`]:o.avatar},{[`& .${V.avatar}`]:o[`avatar${L(i)}`]},{[`& .${V.avatar}`]:o[`avatarColor${L(r)}`]},{[`& .${V.icon}`]:o.icon},{[`& .${V.icon}`]:o[`icon${L(i)}`]},{[`& .${V.icon}`]:o[`iconColor${L(s)}`]},{[`& .${V.deleteIcon}`]:o.deleteIcon},{[`& .${V.deleteIcon}`]:o[`deleteIcon${L(i)}`]},{[`& .${V.deleteIcon}`]:o[`deleteIconColor${L(r)}`]},{[`& .${V.deleteIcon}`]:o[`deleteIcon${L(b)}Color${L(r)}`]},o.root,o[`size${L(i)}`],o[`color${L(r)}`],c&&o.clickable,c&&r!=="default"&&o[`clickableColor${L(r)})`],d&&o.deletable,d&&r!=="default"&&o[`deletableColor${L(r)}`],o[b],o[`${b}${L(r)}`]]}})(({theme:e,ownerState:o})=>{const t=e.palette.mode==="light"?e.palette.grey[700]:e.palette.grey[300];return a({maxWidth:"100%",fontFamily:e.typography.fontFamily,fontSize:e.typography.pxToRem(13),display:"inline-flex",alignItems:"center",justifyContent:"center",height:32,color:(e.vars||e).palette.text.primary,backgroundColor:(e.vars||e).palette.action.selected,borderRadius:32/2,whiteSpace:"nowrap",transition:e.transitions.create(["background-color","box-shadow"]),cursor:"unset",outline:0,textDecoration:"none",border:0,padding:0,verticalAlign:"middle",boxSizing:"border-box",[`&.${V.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity,pointerEvents:"none"},[`& .${V.avatar}`]:{marginLeft:5,marginRight:-6,width:24,height:24,color:e.vars?e.vars.palette.Chip.defaultAvatarColor:t,fontSize:e.typography.pxToRem(12)},[`& .${V.avatarColorPrimary}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.dark},[`& .${V.avatarColorSecondary}`]:{color:(e.vars||e).palette.secondary.contrastText,backgroundColor:(e.vars||e).palette.secondary.dark},[`& .${V.avatarSmall}`]:{marginLeft:4,marginRight:-4,width:18,height:18,fontSize:e.typography.pxToRem(10)},[`& .${V.icon}`]:a({marginLeft:5,marginRight:-6},o.size==="small"&&{fontSize:18,marginLeft:4,marginRight:-4},o.iconColor===o.color&&a({color:e.vars?e.vars.palette.Chip.defaultIconColor:t},o.color!=="default"&&{color:"inherit"})),[`& .${V.deleteIcon}`]:a({WebkitTapHighlightColor:"transparent",color:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / 0.26)`:Re(e.palette.text.primary,.26),fontSize:22,cursor:"pointer",margin:"0 5px 0 -6px","&:hover":{color:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / 0.4)`:Re(e.palette.text.primary,.4)}},o.size==="small"&&{fontSize:16,marginRight:4,marginLeft:-4},o.color!=="default"&&{color:e.vars?`rgba(${e.vars.palette[o.color].contrastTextChannel} / 0.7)`:Re(e.palette[o.color].contrastText,.7),"&:hover, &:active":{color:(e.vars||e).palette[o.color].contrastText}})},o.size==="small"&&{height:24},o.color!=="default"&&{backgroundColor:(e.vars||e).palette[o.color].main,color:(e.vars||e).palette[o.color].contrastText},o.onDelete&&{[`&.${V.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Re(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},o.onDelete&&o.color!=="default"&&{[`&.${V.focusVisible}`]:{backgroundColor:(e.vars||e).palette[o.color].dark}})},({theme:e,ownerState:o})=>a({},o.clickable&&{userSelect:"none",WebkitTapHighlightColor:"transparent",cursor:"pointer","&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Re(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity)},[`&.${V.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Re(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)},"&:active":{boxShadow:(e.vars||e).shadows[1]}},o.clickable&&o.color!=="default"&&{[`&:hover, &.${V.focusVisible}`]:{backgroundColor:(e.vars||e).palette[o.color].dark}}),({theme:e,ownerState:o})=>a({},o.variant==="outlined"&&{backgroundColor:"transparent",border:e.vars?`1px solid ${e.vars.palette.Chip.defaultBorder}`:`1px solid ${e.palette.mode==="light"?e.palette.grey[400]:e.palette.grey[700]}`,[`&.${V.clickable}:hover`]:{backgroundColor:(e.vars||e).palette.action.hover},[`&.${V.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`& .${V.avatar}`]:{marginLeft:4},[`& .${V.avatarSmall}`]:{marginLeft:2},[`& .${V.icon}`]:{marginLeft:4},[`& .${V.iconSmall}`]:{marginLeft:2},[`& .${V.deleteIcon}`]:{marginRight:5},[`& .${V.deleteIconSmall}`]:{marginRight:3}},o.variant==="outlined"&&o.color!=="default"&&{color:(e.vars||e).palette[o.color].main,border:`1px solid ${e.vars?`rgba(${e.vars.palette[o.color].mainChannel} / 0.7)`:Re(e.palette[o.color].main,.7)}`,[`&.${V.clickable}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette[o.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Re(e.palette[o.color].main,e.palette.action.hoverOpacity)},[`&.${V.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette[o.color].mainChannel} / ${e.vars.palette.action.focusOpacity})`:Re(e.palette[o.color].main,e.palette.action.focusOpacity)},[`& .${V.deleteIcon}`]:{color:e.vars?`rgba(${e.vars.palette[o.color].mainChannel} / 0.7)`:Re(e.palette[o.color].main,.7),"&:hover, &:active":{color:(e.vars||e).palette[o.color].main}}})),un=w("span",{name:"MuiChip",slot:"Label",overridesResolver:(e,o)=>{const{ownerState:t}=e,{size:r}=t;return[o.label,o[`label${L(r)}`]]}})(({ownerState:e})=>a({overflow:"hidden",textOverflow:"ellipsis",paddingLeft:12,paddingRight:12,whiteSpace:"nowrap"},e.variant==="outlined"&&{paddingLeft:11,paddingRight:11},e.size==="small"&&{paddingLeft:8,paddingRight:8},e.size==="small"&&e.variant==="outlined"&&{paddingLeft:7,paddingRight:7}));function Go(e){return e.key==="Backspace"||e.key==="Delete"}const pn=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiChip"}),{avatar:s,className:c,clickable:d,color:i="default",component:b,deleteIcon:p,disabled:m=!1,icon:h,label:$,onClick:v,onDelete:R,onKeyDown:M,onKeyUp:P,size:O="medium",variant:k="filled",tabIndex:C,skipFocusWhenDisabled:I=!1}=r,E=ae(r,sn),N=u.useRef(null),F=lo(N,t),q=A=>{A.stopPropagation(),R&&R(A)},le=A=>{A.currentTarget===A.target&&Go(A)&&A.preventDefault(),M&&M(A)},de=A=>{A.currentTarget===A.target&&(R&&Go(A)?R(A):A.key==="Escape"&&N.current&&N.current.blur()),P&&P(A)},oe=d!==!1&&v?!0:d,T=oe||R?Uo:b||"div",Q=a({},r,{component:T,disabled:m,size:O,color:i,iconColor:u.isValidElement(h)&&h.props.color||i,onDelete:!!R,clickable:oe,variant:k}),G=cn(Q),se=T===Uo?a({component:b||"div",focusVisibleClassName:G.focusVisible},R&&{disableRipple:!0}):{};let J=null;R&&(J=p&&u.isValidElement(p)?u.cloneElement(p,{className:ne(p.props.className,G.deleteIcon),onClick:q}):f.jsx(rn,{className:ne(G.deleteIcon),onClick:q}));let re=null;s&&u.isValidElement(s)&&(re=u.cloneElement(s,{className:ne(G.avatar,s.props.className)}));let U=null;return h&&u.isValidElement(h)&&(U=u.cloneElement(h,{className:ne(G.icon,h.props.className)})),f.jsxs(dn,a({as:T,className:ne(G.root,c),disabled:oe&&m?!0:void 0,onClick:v,onKeyDown:le,onKeyUp:de,ref:F,tabIndex:I&&m?-1:C,ownerState:Q},se,E,{children:[re||U,f.jsx(un,{className:ne(G.label),ownerState:Q,children:$}),J]}))}),fn=pn;function bn(e){return f.jsx(qt,a({},e,{defaultTheme:Lt,themeId:wt}))}function gn(e){return ye("MuiInputBase",e)}const mn=$e("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]),Oe=mn,hn=["aria-describedby","autoComplete","autoFocus","className","color","components","componentsProps","defaultValue","disabled","disableInjectingGlobalStyles","endAdornment","error","fullWidth","id","inputComponent","inputProps","inputRef","margin","maxRows","minRows","multiline","name","onBlur","onChange","onClick","onFocus","onKeyDown","onKeyUp","placeholder","readOnly","renderSuffix","rows","size","slotProps","slots","startAdornment","type","value"],Co=(e,o)=>{const{ownerState:t}=e;return[o.root,t.formControl&&o.formControl,t.startAdornment&&o.adornedStart,t.endAdornment&&o.adornedEnd,t.error&&o.error,t.size==="small"&&o.sizeSmall,t.multiline&&o.multiline,t.color&&o[`color${L(t.color)}`],t.fullWidth&&o.fullWidth,t.hiddenLabel&&o.hiddenLabel]},yo=(e,o)=>{const{ownerState:t}=e;return[o.input,t.size==="small"&&o.inputSizeSmall,t.multiline&&o.inputMultiline,t.type==="search"&&o.inputTypeSearch,t.startAdornment&&o.inputAdornedStart,t.endAdornment&&o.inputAdornedEnd,t.hiddenLabel&&o.inputHiddenLabel]},vn=e=>{const{classes:o,color:t,disabled:r,error:s,endAdornment:c,focused:d,formControl:i,fullWidth:b,hiddenLabel:p,multiline:m,readOnly:h,size:$,startAdornment:v,type:R}=e,M={root:["root",`color${L(t)}`,r&&"disabled",s&&"error",b&&"fullWidth",d&&"focused",i&&"formControl",$&&$!=="medium"&&`size${L($)}`,m&&"multiline",v&&"adornedStart",c&&"adornedEnd",p&&"hiddenLabel",h&&"readOnly"],input:["input",r&&"disabled",R==="search"&&"inputTypeSearch",m&&"inputMultiline",$==="small"&&"inputSizeSmall",p&&"inputHiddenLabel",v&&"inputAdornedStart",c&&"inputAdornedEnd",h&&"readOnly"]};return Ie(M,gn,o)},$o=w("div",{name:"MuiInputBase",slot:"Root",overridesResolver:Co})(({theme:e,ownerState:o})=>a({},e.typography.body1,{color:(e.vars||e).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${Oe.disabled}`]:{color:(e.vars||e).palette.text.disabled,cursor:"default"}},o.multiline&&a({padding:"4px 0 5px"},o.size==="small"&&{paddingTop:1}),o.fullWidth&&{width:"100%"})),Io=w("input",{name:"MuiInputBase",slot:"Input",overridesResolver:yo})(({theme:e,ownerState:o})=>{const t=e.palette.mode==="light",r=a({color:"currentColor"},e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5},{transition:e.transitions.create("opacity",{duration:e.transitions.duration.shorter})}),s={opacity:"0 !important"},c=e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5};return a({font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%",animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&::-webkit-input-placeholder":r,"&::-moz-placeholder":r,"&:-ms-input-placeholder":r,"&::-ms-input-placeholder":r,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${Oe.formControl} &`]:{"&::-webkit-input-placeholder":s,"&::-moz-placeholder":s,"&:-ms-input-placeholder":s,"&::-ms-input-placeholder":s,"&:focus::-webkit-input-placeholder":c,"&:focus::-moz-placeholder":c,"&:focus:-ms-input-placeholder":c,"&:focus::-ms-input-placeholder":c},[`&.${Oe.disabled}`]:{opacity:1,WebkitTextFillColor:(e.vars||e).palette.text.disabled},"&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}},o.size==="small"&&{paddingTop:1},o.multiline&&{height:"auto",resize:"none",padding:0,paddingTop:0},o.type==="search"&&{MozAppearance:"textfield"})}),xn=f.jsx(bn,{styles:{"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}}),Cn=u.forwardRef(function(o,t){var r;const s=Pe({props:o,name:"MuiInputBase"}),{"aria-describedby":c,autoComplete:d,autoFocus:i,className:b,components:p={},componentsProps:m={},defaultValue:h,disabled:$,disableInjectingGlobalStyles:v,endAdornment:R,fullWidth:M=!1,id:P,inputComponent:O="input",inputProps:k={},inputRef:C,maxRows:I,minRows:E,multiline:N=!1,name:F,onBlur:q,onChange:le,onClick:de,onFocus:oe,onKeyDown:T,onKeyUp:Q,placeholder:G,readOnly:se,renderSuffix:J,rows:re,slotProps:U={},slots:A={},startAdornment:ie,type:Se="text",value:we}=s,ue=ae(s,hn),W=k.value!=null?k.value:we,{current:ee}=u.useRef(W!=null),fe=u.useRef(),We=u.useCallback(z=>{},[]),Z=lo(fe,C,k.ref,We),[be,Me]=u.useState(!1),Y=so(),H=io({props:s,muiFormControl:Y,states:["color","disabled","error","hiddenLabel","size","required","filled"]});H.focused=Y?Y.focused:be,u.useEffect(()=>{!Y&&$&&be&&(Me(!1),q&&q())},[Y,$,be,q]);const ze=Y&&Y.onFilled,_e=Y&&Y.onEmpty,te=u.useCallback(z=>{ut(z)?ze&&ze():_e&&_e()},[ze,_e]);st(()=>{ee&&te({value:W})},[W,te,ee]);const S=z=>{if(H.disabled){z.stopPropagation();return}oe&&oe(z),k.onFocus&&k.onFocus(z),Y&&Y.onFocus?Y.onFocus(z):Me(!0)},to=z=>{q&&q(z),k.onBlur&&k.onBlur(z),Y&&Y.onBlur?Y.onBlur(z):Me(!1)},_=(z,...j)=>{if(!ee){const he=z.target||fe.current;if(he==null)throw new Error(it(1));te({value:he.value})}k.onChange&&k.onChange(z,...j),le&&le(z,...j)};u.useEffect(()=>{te(fe.current)},[]);const xe=z=>{fe.current&&z.currentTarget===z.target&&fe.current.focus(),de&&de(z)};let Fe=O,ce=k;N&&Fe==="input"&&(re?ce=a({type:void 0,minRows:re,maxRows:re},ce):ce=a({type:void 0,maxRows:I,minRows:E},ce),Fe=_t);const Te=z=>{te(z.animationName==="mui-auto-fill-cancel"?fe.current:{value:"x"})};u.useEffect(()=>{Y&&Y.setAdornedStart(!!ie)},[Y,ie]);const me=a({},s,{color:H.color||"primary",disabled:H.disabled,endAdornment:R,error:H.error,focused:H.focused,formControl:Y,fullWidth:M,hiddenLabel:H.hiddenLabel,multiline:N,size:H.size,startAdornment:ie,type:Se}),Ae=vn(me),Ye=A.root||p.Root||$o,De=U.root||m.root||{},Ee=A.input||p.Input||Io;return ce=a({},ce,(r=U.input)!=null?r:m.input),f.jsxs(u.Fragment,{children:[!v&&xn,f.jsxs(Ye,a({},De,!Ho(Ye)&&{ownerState:a({},me,De.ownerState)},{ref:t,onClick:xe},ue,{className:ne(Ae.root,De.className,b,se&&"MuiInputBase-readOnly"),children:[ie,f.jsx(zt.Provider,{value:null,children:f.jsx(Ee,a({ownerState:me,"aria-invalid":H.error,"aria-describedby":c,autoComplete:d,autoFocus:i,defaultValue:h,disabled:H.disabled,id:P,onAnimationStart:Te,name:F,placeholder:G,readOnly:se,required:H.required,rows:re,value:W,onKeyDown:T,onKeyUp:Q,type:Se},ce,!Ho(Ee)&&{as:Fe,ownerState:a({},me,ce.ownerState)},{ref:Z,className:ne(Ae.input,ce.className,se&&"MuiInputBase-readOnly"),onBlur:to,onChange:_,onFocus:S}))}),R,J?J(a({},H,{startAdornment:ie})):null]}))]})}),Do=Cn;function yn(e){return ye("MuiInput",e)}const $n=a({},Oe,$e("MuiInput",["root","underline","input"])),Je=$n;function In(e){return ye("MuiOutlinedInput",e)}const Sn=a({},Oe,$e("MuiOutlinedInput",["root","notchedOutline","input"])),Ve=Sn;function Pn(e){return ye("MuiFilledInput",e)}const kn=a({},Oe,$e("MuiFilledInput",["root","underline","input"])),Le=kn,gt=zo(f.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown");function Rn(e){return ye("MuiAutocomplete",e)}const On=$e("MuiAutocomplete",["root","expanded","fullWidth","focused","focusVisible","tag","tagSizeSmall","tagSizeMedium","hasPopupIcon","hasClearIcon","inputRoot","input","inputFocused","endAdornment","clearIndicator","popupIndicator","popupIndicatorOpen","popper","popperDisablePortal","paper","listbox","loading","noOptions","option","groupLabel","groupUl"]),D=On;var Xo,Yo;const Ln=["autoComplete","autoHighlight","autoSelect","blurOnSelect","ChipProps","className","clearIcon","clearOnBlur","clearOnEscape","clearText","closeText","componentsProps","defaultValue","disableClearable","disableCloseOnSelect","disabled","disabledItemsFocusable","disableListWrap","disablePortal","filterOptions","filterSelectedOptions","forcePopupIcon","freeSolo","fullWidth","getLimitTagsText","getOptionDisabled","getOptionKey","getOptionLabel","isOptionEqualToValue","groupBy","handleHomeEndKeys","id","includeInputInList","inputValue","limitTags","ListboxComponent","ListboxProps","loading","loadingText","multiple","noOptionsText","onChange","onClose","onHighlightChange","onInputChange","onOpen","open","openOnFocus","openText","options","PaperComponent","PopperComponent","popupIcon","readOnly","renderGroup","renderInput","renderOption","renderTags","selectOnFocus","size","slotProps","value"],wn=["ref"],Mn=["key"],Fn=e=>{const{classes:o,disablePortal:t,expanded:r,focused:s,fullWidth:c,hasClearIcon:d,hasPopupIcon:i,inputFocused:b,popupOpen:p,size:m}=e,h={root:["root",r&&"expanded",s&&"focused",c&&"fullWidth",d&&"hasClearIcon",i&&"hasPopupIcon"],inputRoot:["inputRoot"],input:["input",b&&"inputFocused"],tag:["tag",`tagSize${L(m)}`],endAdornment:["endAdornment"],clearIndicator:["clearIndicator"],popupIndicator:["popupIndicator",p&&"popupIndicatorOpen"],popper:["popper",t&&"popperDisablePortal"],paper:["paper"],listbox:["listbox"],loading:["loading"],noOptions:["noOptions"],option:["option"],groupLabel:["groupLabel"],groupUl:["groupUl"]};return Ie(h,Rn,o)},Tn=w("div",{name:"MuiAutocomplete",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e,{fullWidth:r,hasClearIcon:s,hasPopupIcon:c,inputFocused:d,size:i}=t;return[{[`& .${D.tag}`]:o.tag},{[`& .${D.tag}`]:o[`tagSize${L(i)}`]},{[`& .${D.inputRoot}`]:o.inputRoot},{[`& .${D.input}`]:o.input},{[`& .${D.input}`]:d&&o.inputFocused},o.root,r&&o.fullWidth,c&&o.hasPopupIcon,s&&o.hasClearIcon]}})(({ownerState:e})=>a({[`&.${D.focused} .${D.clearIndicator}`]:{visibility:"visible"},"@media (pointer: fine)":{[`&:hover .${D.clearIndicator}`]:{visibility:"visible"}}},e.fullWidth&&{width:"100%"},{[`& .${D.tag}`]:a({margin:3,maxWidth:"calc(100% - 6px)"},e.size==="small"&&{margin:2,maxWidth:"calc(100% - 4px)"}),[`& .${D.inputRoot}`]:{flexWrap:"wrap",[`.${D.hasPopupIcon}&, .${D.hasClearIcon}&`]:{paddingRight:26+4},[`.${D.hasPopupIcon}.${D.hasClearIcon}&`]:{paddingRight:52+4},[`& .${D.input}`]:{width:0,minWidth:30}},[`& .${Je.root}`]:{paddingBottom:1,"& .MuiInput-input":{padding:"4px 4px 4px 0px"}},[`& .${Je.root}.${Oe.sizeSmall}`]:{[`& .${Je.input}`]:{padding:"2px 4px 3px 0"}},[`& .${Ve.root}`]:{padding:9,[`.${D.hasPopupIcon}&, .${D.hasClearIcon}&`]:{paddingRight:26+4+9},[`.${D.hasPopupIcon}.${D.hasClearIcon}&`]:{paddingRight:52+4+9},[`& .${D.input}`]:{padding:"7.5px 4px 7.5px 5px"},[`& .${D.endAdornment}`]:{right:9}},[`& .${Ve.root}.${Oe.sizeSmall}`]:{paddingTop:6,paddingBottom:6,paddingLeft:6,[`& .${D.input}`]:{padding:"2.5px 4px 2.5px 8px"}},[`& .${Le.root}`]:{paddingTop:19,paddingLeft:8,[`.${D.hasPopupIcon}&, .${D.hasClearIcon}&`]:{paddingRight:26+4+9},[`.${D.hasPopupIcon}.${D.hasClearIcon}&`]:{paddingRight:52+4+9},[`& .${Le.input}`]:{padding:"7px 4px"},[`& .${D.endAdornment}`]:{right:9}},[`& .${Le.root}.${Oe.sizeSmall}`]:{paddingBottom:1,[`& .${Le.input}`]:{padding:"2.5px 4px"}},[`& .${Oe.hiddenLabel}`]:{paddingTop:8},[`& .${Le.root}.${Oe.hiddenLabel}`]:{paddingTop:0,paddingBottom:0,[`& .${D.input}`]:{paddingTop:16,paddingBottom:17}},[`& .${Le.root}.${Oe.hiddenLabel}.${Oe.sizeSmall}`]:{[`& .${D.input}`]:{paddingTop:8,paddingBottom:9}},[`& .${D.input}`]:a({flexGrow:1,textOverflow:"ellipsis",opacity:0},e.inputFocused&&{opacity:1})})),An=w("div",{name:"MuiAutocomplete",slot:"EndAdornment",overridesResolver:(e,o)=>o.endAdornment})({position:"absolute",right:0,top:"calc(50% - 14px)"}),Nn=w(pt,{name:"MuiAutocomplete",slot:"ClearIndicator",overridesResolver:(e,o)=>o.clearIndicator})({marginRight:-2,padding:4,visibility:"hidden"}),zn=w(pt,{name:"MuiAutocomplete",slot:"PopupIndicator",overridesResolver:({ownerState:e},o)=>a({},o.popupIndicator,e.popupOpen&&o.popupIndicatorOpen)})(({ownerState:e})=>a({padding:2,marginRight:-2},e.popupOpen&&{transform:"rotate(180deg)"})),Dn=w(No,{name:"MuiAutocomplete",slot:"Popper",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[{[`& .${D.option}`]:o.option},o.popper,t.disablePortal&&o.popperDisablePortal]}})(({theme:e,ownerState:o})=>a({zIndex:(e.vars||e).zIndex.modal},o.disablePortal&&{position:"absolute"})),En=w(ft,{name:"MuiAutocomplete",slot:"Paper",overridesResolver:(e,o)=>o.paper})(({theme:e})=>a({},e.typography.body1,{overflow:"auto"})),Bn=w("div",{name:"MuiAutocomplete",slot:"Loading",overridesResolver:(e,o)=>o.loading})(({theme:e})=>({color:(e.vars||e).palette.text.secondary,padding:"14px 16px"})),jn=w("div",{name:"MuiAutocomplete",slot:"NoOptions",overridesResolver:(e,o)=>o.noOptions})(({theme:e})=>({color:(e.vars||e).palette.text.secondary,padding:"14px 16px"})),Wn=w("div",{name:"MuiAutocomplete",slot:"Listbox",overridesResolver:(e,o)=>o.listbox})(({theme:e})=>({listStyle:"none",margin:0,padding:"8px 0",maxHeight:"40vh",overflow:"auto",position:"relative",[`& .${D.option}`]:{minHeight:48,display:"flex",overflow:"hidden",justifyContent:"flex-start",alignItems:"center",cursor:"pointer",paddingTop:6,boxSizing:"border-box",outline:"0",WebkitTapHighlightColor:"transparent",paddingBottom:6,paddingLeft:16,paddingRight:16,[e.breakpoints.up("sm")]:{minHeight:"auto"},[`&.${D.focused}`]:{backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},'&[aria-disabled="true"]':{opacity:(e.vars||e).palette.action.disabledOpacity,pointerEvents:"none"},[`&.${D.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},'&[aria-selected="true"]':{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:Re(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${D.focused}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Re(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:(e.vars||e).palette.action.selected}},[`&.${D.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Re(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}}}})),_n=w(nn,{name:"MuiAutocomplete",slot:"GroupLabel",overridesResolver:(e,o)=>o.groupLabel})(({theme:e})=>({backgroundColor:(e.vars||e).palette.background.paper,top:-8})),Un=w("ul",{name:"MuiAutocomplete",slot:"GroupUl",overridesResolver:(e,o)=>o.groupUl})({padding:0,[`& .${D.option}`]:{paddingLeft:24}}),Hn=u.forwardRef(function(o,t){var r,s,c,d;const i=Pe({props:o,name:"MuiAutocomplete"}),{autoComplete:b=!1,autoHighlight:p=!1,autoSelect:m=!1,blurOnSelect:h=!1,ChipProps:$,className:v,clearIcon:R=Xo||(Xo=f.jsx(Gt,{fontSize:"small"})),clearOnBlur:M=!i.freeSolo,clearOnEscape:P=!1,clearText:O="Clear",closeText:k="Close",componentsProps:C={},defaultValue:I=i.multiple?[]:null,disableClearable:E=!1,disableCloseOnSelect:N=!1,disabled:F=!1,disabledItemsFocusable:q=!1,disableListWrap:le=!1,disablePortal:de=!1,filterSelectedOptions:oe=!1,forcePopupIcon:T="auto",freeSolo:Q=!1,fullWidth:G=!1,getLimitTagsText:se=n=>`+${n}`,getOptionLabel:J,groupBy:re,handleHomeEndKeys:U=!i.freeSolo,includeInputInList:A=!1,limitTags:ie=-1,ListboxComponent:Se="ul",ListboxProps:we,loading:ue=!1,loadingText:W="Loading…",multiple:ee=!1,noOptionsText:fe="No options",openOnFocus:We=!1,openText:Z="Open",PaperComponent:be=ft,PopperComponent:Me=No,popupIcon:Y=Yo||(Yo=f.jsx(gt,{})),readOnly:H=!1,renderGroup:ze,renderInput:_e,renderOption:te,renderTags:S,selectOnFocus:to=!i.freeSolo,size:_="medium",slotProps:xe={}}=i,Fe=ae(i,Ln),{getRootProps:ce,getInputProps:Te,getInputLabelProps:me,getPopupIndicatorProps:Ae,getClearProps:Ye,getTagProps:De,getListboxProps:Ee,getOptionProps:z,value:j,dirty:he,expanded:Ke,id:qe,popupOpen:y,focused:B,focusedTag:X,anchorEl:ke,setAnchorEl:Ze,inputValue:Po,groupedOptions:Ne}=Qt(a({},i,{componentName:"Autocomplete"})),Ge=!E&&!F&&he&&!H,Ue=(!Q||T===!0)&&T!==!1,{onMouseDown:no}=Te(),{ref:eo}=we??{},go=Ee(),{ref:mo}=go,ho=ae(go,wn),ko=lo(mo,eo),ro=J||(n=>{var g;return(g=n.label)!=null?g:n}),Ce=a({},i,{disablePortal:de,expanded:Ke,focused:B,fullWidth:G,getOptionLabel:ro,hasClearIcon:Ge,hasPopupIcon:Ue,inputFocused:X===-1,popupOpen:y,size:_}),ve=Fn(Ce);let Be;if(ee&&j.length>0){const n=g=>a({className:ve.tag,disabled:F},De(g));S?Be=S(j,n,Ce):Be=j.map((g,x)=>f.jsx(fn,a({label:ro(g),size:_},n({index:x}),$)))}if(ie>-1&&Array.isArray(Be)){const n=Be.length-ie;!B&&n>0&&(Be=Be.splice(0,ie),Be.push(f.jsx("span",{className:ve.tag,children:se(n)},Be.length)))}const Ro=ze||(n=>f.jsxs("li",{children:[f.jsx(_n,{className:ve.groupLabel,ownerState:Ce,component:"div",children:n.group}),f.jsx(Un,{className:ve.groupUl,ownerState:Ce,children:n.children})]},n.key)),Lo=te||((n,g)=>{const{key:x}=n,K=ae(n,Mn);return f.jsx("li",a({},K,{children:ro(g)}),x)}),vo=(n,g)=>{const x=z({option:n,index:g});return Lo(a({},x,{className:ve.option}),n,{selected:x["aria-selected"],index:g,inputValue:Po},Ce)},co=(r=xe.clearIndicator)!=null?r:C.clearIndicator,oo=(s=xe.paper)!=null?s:C.paper,ao=(c=xe.popper)!=null?c:C.popper,l=(d=xe.popupIndicator)!=null?d:C.popupIndicator;return f.jsxs(u.Fragment,{children:[f.jsx(Tn,a({ref:t,className:ne(ve.root,v),ownerState:Ce},ce(Fe),{children:_e({id:qe,disabled:F,fullWidth:!0,size:_==="small"?"small":void 0,InputLabelProps:me(),InputProps:a({ref:Ze,className:ve.inputRoot,startAdornment:Be,onClick:n=>{n.target===n.currentTarget&&no(n)}},(Ge||Ue)&&{endAdornment:f.jsxs(An,{className:ve.endAdornment,ownerState:Ce,children:[Ge?f.jsx(Nn,a({},Ye(),{"aria-label":O,title:O,ownerState:Ce},co,{className:ne(ve.clearIndicator,co==null?void 0:co.className),children:R})):null,Ue?f.jsx(zn,a({},Ae(),{disabled:F,"aria-label":y?k:Z,title:y?k:Z,ownerState:Ce},l,{className:ne(ve.popupIndicator,l==null?void 0:l.className),children:Y})):null]})}),inputProps:a({className:ve.input,disabled:F,readOnly:H},Te())})})),ke?f.jsx(Dn,a({as:Me,disablePortal:de,style:{width:ke?ke.clientWidth:null},ownerState:Ce,role:"presentation",anchorEl:ke,open:y},ao,{className:ne(ve.popper,ao==null?void 0:ao.className),children:f.jsxs(En,a({ownerState:Ce,as:be},oo,{className:ne(ve.paper,oo==null?void 0:oo.className),children:[ue&&Ne.length===0?f.jsx(Bn,{className:ve.loading,ownerState:Ce,children:W}):null,Ne.length===0&&!Q&&!ue?f.jsx(jn,{className:ve.noOptions,ownerState:Ce,role:"presentation",onMouseDown:n=>{n.preventDefault()},children:fe}):null,Ne.length>0?f.jsx(Wn,a({as:Se,className:ve.listbox,ownerState:Ce},ho,we,{ref:ko,children:Ne.map((n,g)=>re?Ro({key:n.key,group:n.group,children:n.options.map((x,K)=>vo(x,n.index+K))}):vo(n,g))})):null]}))})):null]})}),Vn=Hn;function Kn(e){return ye("MuiCircularProgress",e)}$e("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const qn=["className","color","disableShrink","size","style","thickness","value","variant"];let So=e=>e,Zo,Qo,Jo,et;const Qe=44,Gn=ct(Zo||(Zo=So` - 0% { - transform: rotate(0deg); - } - - 100% { - transform: rotate(360deg); - } -`)),Xn=ct(Qo||(Qo=So` - 0% { - stroke-dasharray: 1px, 200px; - stroke-dashoffset: 0; - } - - 50% { - stroke-dasharray: 100px, 200px; - stroke-dashoffset: -15px; - } - - 100% { - stroke-dasharray: 100px, 200px; - stroke-dashoffset: -125px; - } -`)),Yn=e=>{const{classes:o,variant:t,color:r,disableShrink:s}=e,c={root:["root",t,`color${L(r)}`],svg:["svg"],circle:["circle",`circle${L(t)}`,s&&"circleDisableShrink"]};return Ie(c,Kn,o)},Zn=w("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.root,o[t.variant],o[`color${L(t.color)}`]]}})(({ownerState:e,theme:o})=>a({display:"inline-block"},e.variant==="determinate"&&{transition:o.transitions.create("transform")},e.color!=="inherit"&&{color:(o.vars||o).palette[e.color].main}),({ownerState:e})=>e.variant==="indeterminate"&&dt(Jo||(Jo=So` - animation: ${0} 1.4s linear infinite; - `),Gn)),Qn=w("svg",{name:"MuiCircularProgress",slot:"Svg",overridesResolver:(e,o)=>o.svg})({display:"block"}),Jn=w("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.circle,o[`circle${L(t.variant)}`],t.disableShrink&&o.circleDisableShrink]}})(({ownerState:e,theme:o})=>a({stroke:"currentColor"},e.variant==="determinate"&&{transition:o.transitions.create("stroke-dashoffset")},e.variant==="indeterminate"&&{strokeDasharray:"80px, 200px",strokeDashoffset:0}),({ownerState:e})=>e.variant==="indeterminate"&&!e.disableShrink&&dt(et||(et=So` - animation: ${0} 1.4s ease-in-out infinite; - `),Xn)),er=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiCircularProgress"}),{className:s,color:c="primary",disableShrink:d=!1,size:i=40,style:b,thickness:p=3.6,value:m=0,variant:h="indeterminate"}=r,$=ae(r,qn),v=a({},r,{color:c,disableShrink:d,size:i,thickness:p,value:m,variant:h}),R=Yn(v),M={},P={},O={};if(h==="determinate"){const k=2*Math.PI*((Qe-p)/2);M.strokeDasharray=k.toFixed(3),O["aria-valuenow"]=Math.round(m),M.strokeDashoffset=`${((100-m)/100*k).toFixed(3)}px`,P.transform="rotate(-90deg)"}return f.jsx(Zn,a({className:ne(R.root,s),style:a({width:i,height:i},P,b),ownerState:v,ref:t,role:"progressbar"},O,$,{children:f.jsx(Qn,{className:R.svg,ownerState:v,viewBox:`${Qe/2} ${Qe/2} ${Qe} ${Qe}`,children:f.jsx(Jn,{className:R.circle,style:M,ownerState:v,cx:Qe,cy:Qe,r:(Qe-p)/2,fill:"none",strokeWidth:p})})}))}),or=er,tr=["disableUnderline","components","componentsProps","fullWidth","hiddenLabel","inputComponent","multiline","slotProps","slots","type"],nr=e=>{const{classes:o,disableUnderline:t}=e,s=Ie({root:["root",!t&&"underline"],input:["input"]},Pn,o);return a({},o,s)},rr=w($o,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiFilledInput",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[...Co(e,o),!t.disableUnderline&&o.underline]}})(({theme:e,ownerState:o})=>{var t;const r=e.palette.mode==="light",s=r?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",c=r?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",d=r?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",i=r?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return a({position:"relative",backgroundColor:e.vars?e.vars.palette.FilledInput.bg:c,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:d,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:c}},[`&.${Le.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:c},[`&.${Le.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:i}},!o.disableUnderline&&{"&:after":{borderBottom:`2px solid ${(t=(e.vars||e).palette[o.color||"primary"])==null?void 0:t.main}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Le.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Le.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&:before":{borderBottom:`1px solid ${e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`:s}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Le.disabled}, .${Le.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${Le.disabled}:before`]:{borderBottomStyle:"dotted"}},o.startAdornment&&{paddingLeft:12},o.endAdornment&&{paddingRight:12},o.multiline&&a({padding:"25px 12px 8px"},o.size==="small"&&{paddingTop:21,paddingBottom:4},o.hiddenLabel&&{paddingTop:16,paddingBottom:17},o.hiddenLabel&&o.size==="small"&&{paddingTop:8,paddingBottom:9}))}),ar=w(Io,{name:"MuiFilledInput",slot:"Input",overridesResolver:yo})(({theme:e,ownerState:o})=>a({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12},!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}},e.vars&&{"&:-webkit-autofill":{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},o.size==="small"&&{paddingTop:21,paddingBottom:4},o.hiddenLabel&&{paddingTop:16,paddingBottom:17},o.startAdornment&&{paddingLeft:0},o.endAdornment&&{paddingRight:0},o.hiddenLabel&&o.size==="small"&&{paddingTop:8,paddingBottom:9},o.multiline&&{paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0})),mt=u.forwardRef(function(o,t){var r,s,c,d;const i=Pe({props:o,name:"MuiFilledInput"}),{components:b={},componentsProps:p,fullWidth:m=!1,inputComponent:h="input",multiline:$=!1,slotProps:v,slots:R={},type:M="text"}=i,P=ae(i,tr),O=a({},i,{fullWidth:m,inputComponent:h,multiline:$,type:M}),k=nr(i),C={root:{ownerState:O},input:{ownerState:O}},I=v??p?To(C,v??p):C,E=(r=(s=R.root)!=null?s:b.Root)!=null?r:rr,N=(c=(d=R.input)!=null?d:b.Input)!=null?c:ar;return f.jsx(Do,a({slots:{root:E,input:N},componentsProps:I,fullWidth:m,inputComponent:h,multiline:$,ref:t,type:M},P,{classes:k}))});mt.muiName="Input";const ht=mt;function lr(e){return ye("MuiFormHelperText",e)}const sr=$e("MuiFormHelperText",["root","error","disabled","sizeSmall","sizeMedium","contained","focused","filled","required"]),ot=sr;var tt;const ir=["children","className","component","disabled","error","filled","focused","margin","required","variant"],cr=e=>{const{classes:o,contained:t,size:r,disabled:s,error:c,filled:d,focused:i,required:b}=e,p={root:["root",s&&"disabled",c&&"error",r&&`size${L(r)}`,t&&"contained",i&&"focused",d&&"filled",b&&"required"]};return Ie(p,lr,o)},dr=w("p",{name:"MuiFormHelperText",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.root,t.size&&o[`size${L(t.size)}`],t.contained&&o.contained,t.filled&&o.filled]}})(({theme:e,ownerState:o})=>a({color:(e.vars||e).palette.text.secondary},e.typography.caption,{textAlign:"left",marginTop:3,marginRight:0,marginBottom:0,marginLeft:0,[`&.${ot.disabled}`]:{color:(e.vars||e).palette.text.disabled},[`&.${ot.error}`]:{color:(e.vars||e).palette.error.main}},o.size==="small"&&{marginTop:4},o.contained&&{marginLeft:14,marginRight:14})),ur=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiFormHelperText"}),{children:s,className:c,component:d="p"}=r,i=ae(r,ir),b=so(),p=io({props:r,muiFormControl:b,states:["variant","size","disabled","error","filled","focused","required"]}),m=a({},r,{component:d,contained:p.variant==="filled"||p.variant==="outlined",variant:p.variant,size:p.size,disabled:p.disabled,error:p.error,filled:p.filled,focused:p.focused,required:p.required}),h=cr(m);return f.jsx(dr,a({as:d,ownerState:m,className:ne(h.root,c),ref:t},i,{children:s===" "?tt||(tt=f.jsx("span",{className:"notranslate",children:"​"})):s}))}),pr=ur;function fr(e){return ye("MuiFormLabel",e)}const br=$e("MuiFormLabel",["root","colorSecondary","focused","disabled","error","filled","required","asterisk"]),bo=br,gr=["children","className","color","component","disabled","error","filled","focused","required"],mr=e=>{const{classes:o,color:t,focused:r,disabled:s,error:c,filled:d,required:i}=e,b={root:["root",`color${L(t)}`,s&&"disabled",c&&"error",d&&"filled",r&&"focused",i&&"required"],asterisk:["asterisk",c&&"error"]};return Ie(b,fr,o)},hr=w("label",{name:"MuiFormLabel",slot:"Root",overridesResolver:({ownerState:e},o)=>a({},o.root,e.color==="secondary"&&o.colorSecondary,e.filled&&o.filled)})(({theme:e,ownerState:o})=>a({color:(e.vars||e).palette.text.secondary},e.typography.body1,{lineHeight:"1.4375em",padding:0,position:"relative",[`&.${bo.focused}`]:{color:(e.vars||e).palette[o.color].main},[`&.${bo.disabled}`]:{color:(e.vars||e).palette.text.disabled},[`&.${bo.error}`]:{color:(e.vars||e).palette.error.main}})),vr=w("span",{name:"MuiFormLabel",slot:"Asterisk",overridesResolver:(e,o)=>o.asterisk})(({theme:e})=>({[`&.${bo.error}`]:{color:(e.vars||e).palette.error.main}})),xr=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiFormLabel"}),{children:s,className:c,component:d="label"}=r,i=ae(r,gr),b=so(),p=io({props:r,muiFormControl:b,states:["color","required","focused","disabled","error","filled"]}),m=a({},r,{color:p.color||"primary",component:d,disabled:p.disabled,error:p.error,filled:p.filled,focused:p.focused,required:p.required}),h=mr(m);return f.jsxs(hr,a({as:d,ownerState:m,className:ne(h.root,c),ref:t},i,{children:[s,p.required&&f.jsxs(vr,{ownerState:m,"aria-hidden":!0,className:h.asterisk,children:[" ","*"]})]}))}),Cr=xr,yr=["disableUnderline","components","componentsProps","fullWidth","inputComponent","multiline","slotProps","slots","type"],$r=e=>{const{classes:o,disableUnderline:t}=e,s=Ie({root:["root",!t&&"underline"],input:["input"]},yn,o);return a({},o,s)},Ir=w($o,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiInput",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[...Co(e,o),!t.disableUnderline&&o.underline]}})(({theme:e,ownerState:o})=>{let r=e.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(r=`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`),a({position:"relative"},o.formControl&&{"label + &":{marginTop:16}},!o.disableUnderline&&{"&:after":{borderBottom:`2px solid ${(e.vars||e).palette[o.color].main}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Je.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Je.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&:before":{borderBottom:`1px solid ${r}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Je.disabled}, .${Je.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${r}`}},[`&.${Je.disabled}:before`]:{borderBottomStyle:"dotted"}})}),Sr=w(Io,{name:"MuiInput",slot:"Input",overridesResolver:yo})({}),vt=u.forwardRef(function(o,t){var r,s,c,d;const i=Pe({props:o,name:"MuiInput"}),{disableUnderline:b,components:p={},componentsProps:m,fullWidth:h=!1,inputComponent:$="input",multiline:v=!1,slotProps:R,slots:M={},type:P="text"}=i,O=ae(i,yr),k=$r(i),I={root:{ownerState:{disableUnderline:b}}},E=R??m?To(R??m,I):I,N=(r=(s=M.root)!=null?s:p.Root)!=null?r:Ir,F=(c=(d=M.input)!=null?d:p.Input)!=null?c:Sr;return f.jsx(Do,a({slots:{root:N,input:F},slotProps:E,fullWidth:h,inputComponent:$,multiline:v,ref:t,type:P},O,{classes:k}))});vt.muiName="Input";const xt=vt;function Pr(e){return ye("MuiInputLabel",e)}$e("MuiInputLabel",["root","focused","disabled","error","required","asterisk","formControl","sizeSmall","shrink","animated","standard","filled","outlined"]);const kr=["disableAnimation","margin","shrink","variant","className"],Rr=e=>{const{classes:o,formControl:t,size:r,shrink:s,disableAnimation:c,variant:d,required:i}=e,b={root:["root",t&&"formControl",!c&&"animated",s&&"shrink",r&&r!=="normal"&&`size${L(r)}`,d],asterisk:[i&&"asterisk"]},p=Ie(b,Pr,o);return a({},o,p)},Or=w(Cr,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiInputLabel",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[{[`& .${bo.asterisk}`]:o.asterisk},o.root,t.formControl&&o.formControl,t.size==="small"&&o.sizeSmall,t.shrink&&o.shrink,!t.disableAnimation&&o.animated,t.focused&&o.focused,o[t.variant]]}})(({theme:e,ownerState:o})=>a({display:"block",transformOrigin:"top left",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:"100%"},o.formControl&&{position:"absolute",left:0,top:0,transform:"translate(0, 20px) scale(1)"},o.size==="small"&&{transform:"translate(0, 17px) scale(1)"},o.shrink&&{transform:"translate(0, -1.5px) scale(0.75)",transformOrigin:"top left",maxWidth:"133%"},!o.disableAnimation&&{transition:e.transitions.create(["color","transform","max-width"],{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut})},o.variant==="filled"&&a({zIndex:1,pointerEvents:"none",transform:"translate(12px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"},o.size==="small"&&{transform:"translate(12px, 13px) scale(1)"},o.shrink&&a({userSelect:"none",pointerEvents:"auto",transform:"translate(12px, 7px) scale(0.75)",maxWidth:"calc(133% - 24px)"},o.size==="small"&&{transform:"translate(12px, 4px) scale(0.75)"})),o.variant==="outlined"&&a({zIndex:1,pointerEvents:"none",transform:"translate(14px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"},o.size==="small"&&{transform:"translate(14px, 9px) scale(1)"},o.shrink&&{userSelect:"none",pointerEvents:"auto",maxWidth:"calc(133% - 32px)",transform:"translate(14px, -9px) scale(0.75)"}))),Lr=u.forwardRef(function(o,t){const r=Pe({name:"MuiInputLabel",props:o}),{disableAnimation:s=!1,shrink:c,className:d}=r,i=ae(r,kr),b=so();let p=c;typeof p>"u"&&b&&(p=b.filled||b.focused||b.adornedStart);const m=io({props:r,muiFormControl:b,states:["size","variant","required","focused"]}),h=a({},r,{disableAnimation:s,formControl:b,shrink:p,size:m.size,variant:m.variant,required:m.required,focused:m.focused}),$=Rr(h);return f.jsx(Or,a({"data-shrink":p,ownerState:h,ref:t,className:ne($.root,d)},i,{classes:$}))}),wr=Lr,Mr=u.createContext({}),Fr=Mr;function Tr(e){return ye("MuiList",e)}$e("MuiList",["root","padding","dense","subheader"]);const Ar=["children","className","component","dense","disablePadding","subheader"],Nr=e=>{const{classes:o,disablePadding:t,dense:r,subheader:s}=e;return Ie({root:["root",!t&&"padding",r&&"dense",s&&"subheader"]},Tr,o)},zr=w("ul",{name:"MuiList",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.root,!t.disablePadding&&o.padding,t.dense&&o.dense,t.subheader&&o.subheader]}})(({ownerState:e})=>a({listStyle:"none",margin:0,padding:0,position:"relative"},!e.disablePadding&&{paddingTop:8,paddingBottom:8},e.subheader&&{paddingTop:0})),Dr=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiList"}),{children:s,className:c,component:d="ul",dense:i=!1,disablePadding:b=!1,subheader:p}=r,m=ae(r,Ar),h=u.useMemo(()=>({dense:i}),[i]),$=a({},r,{component:d,dense:i,disablePadding:b}),v=Nr($);return f.jsx(Fr.Provider,{value:h,children:f.jsxs(zr,a({as:d,className:ne(v.root,c),ref:t,ownerState:$},m,{children:[p,s]}))})}),Er=Dr,Br=["actions","autoFocus","autoFocusItem","children","className","disabledItemsFocusable","disableListWrap","onKeyDown","variant"];function Mo(e,o,t){return e===o?e.firstChild:o&&o.nextElementSibling?o.nextElementSibling:t?null:e.firstChild}function nt(e,o,t){return e===o?t?e.firstChild:e.lastChild:o&&o.previousElementSibling?o.previousElementSibling:t?null:e.lastChild}function Ct(e,o){if(o===void 0)return!0;let t=e.innerText;return t===void 0&&(t=e.textContent),t=t.trim().toLowerCase(),t.length===0?!1:o.repeating?t[0]===o.keys[0]:t.indexOf(o.keys.join(""))===0}function uo(e,o,t,r,s,c){let d=!1,i=s(e,o,o?t:!1);for(;i;){if(i===e.firstChild){if(d)return!1;d=!0}const b=r?!1:i.disabled||i.getAttribute("aria-disabled")==="true";if(!i.hasAttribute("tabindex")||!Ct(i,c)||b)i=s(e,i,t);else return i.focus(),!0}return!1}const jr=u.forwardRef(function(o,t){const{actions:r,autoFocus:s=!1,autoFocusItem:c=!1,children:d,className:i,disabledItemsFocusable:b=!1,disableListWrap:p=!1,onKeyDown:m,variant:h="selectedMenu"}=o,$=ae(o,Br),v=u.useRef(null),R=u.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});st(()=>{s&&v.current.focus()},[s]),u.useImperativeHandle(r,()=>({adjustStyleForScrollbar:(C,I)=>{const E=!v.current.style.width;if(C.clientHeight{const I=v.current,E=C.key,N=Fo(I).activeElement;if(E==="ArrowDown")C.preventDefault(),uo(I,N,p,b,Mo);else if(E==="ArrowUp")C.preventDefault(),uo(I,N,p,b,nt);else if(E==="Home")C.preventDefault(),uo(I,null,p,b,Mo);else if(E==="End")C.preventDefault(),uo(I,null,p,b,nt);else if(E.length===1){const F=R.current,q=E.toLowerCase(),le=performance.now();F.keys.length>0&&(le-F.lastTime>500?(F.keys=[],F.repeating=!0,F.previousKeyMatched=!0):F.repeating&&q!==F.keys[0]&&(F.repeating=!1)),F.lastTime=le,F.keys.push(q);const de=N&&!F.repeating&&Ct(N,F);F.previousKeyMatched&&(de||uo(I,N,!1,b,Mo,F))?C.preventDefault():F.previousKeyMatched=!1}m&&m(C)},P=lo(v,t);let O=-1;u.Children.forEach(d,(C,I)=>{if(!u.isValidElement(C)){O===I&&(O+=1,O>=d.length&&(O=-1));return}C.props.disabled||(h==="selectedMenu"&&C.props.selected||O===-1)&&(O=I),O===I&&(C.props.disabled||C.props.muiSkipListHighlight||C.type.muiSkipListHighlight)&&(O+=1,O>=d.length&&(O=-1))});const k=u.Children.map(d,(C,I)=>{if(I===O){const E={};return c&&(E.autoFocus=!0),C.props.tabIndex===void 0&&h==="selectedMenu"&&(E.tabIndex=0),u.cloneElement(C,E)}return C});return f.jsx(Er,a({role:"menu",ref:P,className:i,onKeyDown:M,tabIndex:s?0:-1},$,{children:k}))}),Wr=jr;function _r(e){return ye("MuiMenu",e)}$e("MuiMenu",["root","paper","list"]);const Ur=["onEntering"],Hr=["autoFocus","children","className","disableAutoFocusItem","MenuListProps","onClose","open","PaperProps","PopoverClasses","transitionDuration","TransitionProps","variant","slots","slotProps"],Vr={vertical:"top",horizontal:"right"},Kr={vertical:"top",horizontal:"left"},qr=e=>{const{classes:o}=e;return Ie({root:["root"],paper:["paper"],list:["list"]},_r,o)},Gr=w(jt,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiMenu",slot:"Root",overridesResolver:(e,o)=>o.root})({}),Xr=w(Wt,{name:"MuiMenu",slot:"Paper",overridesResolver:(e,o)=>o.paper})({maxHeight:"calc(100% - 96px)",WebkitOverflowScrolling:"touch"}),Yr=w(Wr,{name:"MuiMenu",slot:"List",overridesResolver:(e,o)=>o.list})({outline:0}),Zr=u.forwardRef(function(o,t){var r,s;const c=Pe({props:o,name:"MuiMenu"}),{autoFocus:d=!0,children:i,className:b,disableAutoFocusItem:p=!1,MenuListProps:m={},onClose:h,open:$,PaperProps:v={},PopoverClasses:R,transitionDuration:M="auto",TransitionProps:{onEntering:P}={},variant:O="selectedMenu",slots:k={},slotProps:C={}}=c,I=ae(c.TransitionProps,Ur),E=ae(c,Hr),N=Mt(),F=N.direction==="rtl",q=a({},c,{autoFocus:d,disableAutoFocusItem:p,MenuListProps:m,onEntering:P,PaperProps:v,transitionDuration:M,TransitionProps:I,variant:O}),le=qr(q),de=d&&!p&&$,oe=u.useRef(null),T=(A,ie)=>{oe.current&&oe.current.adjustStyleForScrollbar(A,N),P&&P(A,ie)},Q=A=>{A.key==="Tab"&&(A.preventDefault(),h&&h(A,"tabKeyDown"))};let G=-1;u.Children.map(i,(A,ie)=>{u.isValidElement(A)&&(A.props.disabled||(O==="selectedMenu"&&A.props.selected||G===-1)&&(G=ie))});const se=(r=k.paper)!=null?r:Xr,J=(s=C.paper)!=null?s:v,re=Vo({elementType:k.root,externalSlotProps:C.root,ownerState:q,className:[le.root,b]}),U=Vo({elementType:se,externalSlotProps:J,ownerState:q,className:le.paper});return f.jsx(Gr,a({onClose:h,anchorOrigin:{vertical:"bottom",horizontal:F?"right":"left"},transformOrigin:F?Vr:Kr,slots:{paper:se,root:k.root},slotProps:{root:re,paper:U},open:$,ref:t,transitionDuration:M,TransitionProps:a({onEntering:T},I),ownerState:q},E,{classes:R,children:f.jsx(Yr,a({onKeyDown:Q,actions:oe,autoFocus:d&&(G===-1||p),autoFocusItem:de,variant:O},m,{className:ne(le.list,m.className),children:i}))}))}),Qr=Zr;function Jr(e){return ye("MuiNativeSelect",e)}const ea=$e("MuiNativeSelect",["root","select","multiple","filled","outlined","standard","disabled","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]),Eo=ea,oa=["className","disabled","error","IconComponent","inputRef","variant"],ta=e=>{const{classes:o,variant:t,disabled:r,multiple:s,open:c,error:d}=e,i={select:["select",t,r&&"disabled",s&&"multiple",d&&"error"],icon:["icon",`icon${L(t)}`,c&&"iconOpen",r&&"disabled"]};return Ie(i,Jr,o)},yt=({ownerState:e,theme:o})=>a({MozAppearance:"none",WebkitAppearance:"none",userSelect:"none",borderRadius:0,cursor:"pointer","&:focus":a({},o.vars?{backgroundColor:`rgba(${o.vars.palette.common.onBackgroundChannel} / 0.05)`}:{backgroundColor:o.palette.mode==="light"?"rgba(0, 0, 0, 0.05)":"rgba(255, 255, 255, 0.05)"},{borderRadius:0}),"&::-ms-expand":{display:"none"},[`&.${Eo.disabled}`]:{cursor:"default"},"&[multiple]":{height:"auto"},"&:not([multiple]) option, &:not([multiple]) optgroup":{backgroundColor:(o.vars||o).palette.background.paper},"&&&":{paddingRight:24,minWidth:16}},e.variant==="filled"&&{"&&&":{paddingRight:32}},e.variant==="outlined"&&{borderRadius:(o.vars||o).shape.borderRadius,"&:focus":{borderRadius:(o.vars||o).shape.borderRadius},"&&&":{paddingRight:32}}),na=w("select",{name:"MuiNativeSelect",slot:"Select",shouldForwardProp:Xe,overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.select,o[t.variant],t.error&&o.error,{[`&.${Eo.multiple}`]:o.multiple}]}})(yt),$t=({ownerState:e,theme:o})=>a({position:"absolute",right:0,top:"calc(50% - .5em)",pointerEvents:"none",color:(o.vars||o).palette.action.active,[`&.${Eo.disabled}`]:{color:(o.vars||o).palette.action.disabled}},e.open&&{transform:"rotate(180deg)"},e.variant==="filled"&&{right:7},e.variant==="outlined"&&{right:7}),ra=w("svg",{name:"MuiNativeSelect",slot:"Icon",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.icon,t.variant&&o[`icon${L(t.variant)}`],t.open&&o.iconOpen]}})($t),aa=u.forwardRef(function(o,t){const{className:r,disabled:s,error:c,IconComponent:d,inputRef:i,variant:b="standard"}=o,p=ae(o,oa),m=a({},o,{disabled:s,variant:b,error:c}),h=ta(m);return f.jsxs(u.Fragment,{children:[f.jsx(na,a({ownerState:m,className:ne(h.select,r),disabled:s,ref:i||t},p)),o.multiple?null:f.jsx(ra,{as:d,ownerState:m,className:h.icon})]})}),la=aa;var rt;const sa=["children","classes","className","label","notched"],ia=w("fieldset",{shouldForwardProp:Xe})({textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%"}),ca=w("legend",{shouldForwardProp:Xe})(({ownerState:e,theme:o})=>a({float:"unset",width:"auto",overflow:"hidden"},!e.withLabel&&{padding:0,lineHeight:"11px",transition:o.transitions.create("width",{duration:150,easing:o.transitions.easing.easeOut})},e.withLabel&&a({display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:o.transitions.create("max-width",{duration:50,easing:o.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}},e.notched&&{maxWidth:"100%",transition:o.transitions.create("max-width",{duration:100,easing:o.transitions.easing.easeOut,delay:50})})));function da(e){const{className:o,label:t,notched:r}=e,s=ae(e,sa),c=t!=null&&t!=="",d=a({},e,{notched:r,withLabel:c});return f.jsx(ia,a({"aria-hidden":!0,className:o,ownerState:d},s,{children:f.jsx(ca,{ownerState:d,children:c?f.jsx("span",{children:t}):rt||(rt=f.jsx("span",{className:"notranslate",children:"​"}))})}))}const ua=["components","fullWidth","inputComponent","label","multiline","notched","slots","type"],pa=e=>{const{classes:o}=e,r=Ie({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},In,o);return a({},o,r)},fa=w($o,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiOutlinedInput",slot:"Root",overridesResolver:Co})(({theme:e,ownerState:o})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return a({position:"relative",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${Ve.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${Ve.notchedOutline}`]:{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}},[`&.${Ve.focused} .${Ve.notchedOutline}`]:{borderColor:(e.vars||e).palette[o.color].main,borderWidth:2},[`&.${Ve.error} .${Ve.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},[`&.${Ve.disabled} .${Ve.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled}},o.startAdornment&&{paddingLeft:14},o.endAdornment&&{paddingRight:14},o.multiline&&a({padding:"16.5px 14px"},o.size==="small"&&{padding:"8.5px 14px"}))}),ba=w(da,{name:"MuiOutlinedInput",slot:"NotchedOutline",overridesResolver:(e,o)=>o.notchedOutline})(({theme:e})=>{const o=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:o}}),ga=w(Io,{name:"MuiOutlinedInput",slot:"Input",overridesResolver:yo})(({theme:e,ownerState:o})=>a({padding:"16.5px 14px"},!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderRadius:"inherit"}},e.vars&&{"&:-webkit-autofill":{borderRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},o.size==="small"&&{padding:"8.5px 14px"},o.multiline&&{padding:0},o.startAdornment&&{paddingLeft:0},o.endAdornment&&{paddingRight:0})),It=u.forwardRef(function(o,t){var r,s,c,d,i;const b=Pe({props:o,name:"MuiOutlinedInput"}),{components:p={},fullWidth:m=!1,inputComponent:h="input",label:$,multiline:v=!1,notched:R,slots:M={},type:P="text"}=b,O=ae(b,ua),k=pa(b),C=so(),I=io({props:b,muiFormControl:C,states:["color","disabled","error","focused","hiddenLabel","size","required"]}),E=a({},b,{color:I.color||"primary",disabled:I.disabled,error:I.error,focused:I.focused,formControl:C,fullWidth:m,hiddenLabel:I.hiddenLabel,multiline:v,size:I.size,type:P}),N=(r=(s=M.root)!=null?s:p.Root)!=null?r:fa,F=(c=(d=M.input)!=null?d:p.Input)!=null?c:ga;return f.jsx(Do,a({slots:{root:N,input:F},renderSuffix:q=>f.jsx(ba,{ownerState:E,className:k.notchedOutline,label:$!=null&&$!==""&&I.required?i||(i=f.jsxs(u.Fragment,{children:[$," ","*"]})):$,notched:typeof R<"u"?R:!!(q.startAdornment||q.filled||q.focused)}),fullWidth:m,inputComponent:h,multiline:v,ref:t,type:P},O,{classes:a({},k,{notchedOutline:null})}))});It.muiName="Input";const St=It;function ma(e){return ye("MuiSelect",e)}const ha=$e("MuiSelect",["root","select","multiple","filled","outlined","standard","disabled","focused","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]),po=ha;var at;const va=["aria-describedby","aria-label","autoFocus","autoWidth","children","className","defaultOpen","defaultValue","disabled","displayEmpty","error","IconComponent","inputRef","labelId","MenuProps","multiple","name","onBlur","onChange","onClose","onFocus","onOpen","open","readOnly","renderValue","SelectDisplayProps","tabIndex","type","value","variant"],xa=w("div",{name:"MuiSelect",slot:"Select",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[{[`&.${po.select}`]:o.select},{[`&.${po.select}`]:o[t.variant]},{[`&.${po.error}`]:o.error},{[`&.${po.multiple}`]:o.multiple}]}})(yt,{[`&.${po.select}`]:{height:"auto",minHeight:"1.4375em",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}}),Ca=w("svg",{name:"MuiSelect",slot:"Icon",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.icon,t.variant&&o[`icon${L(t.variant)}`],t.open&&o.iconOpen]}})($t),ya=w("input",{shouldForwardProp:e=>Ft(e)&&e!=="classes",name:"MuiSelect",slot:"NativeInput",overridesResolver:(e,o)=>o.nativeInput})({bottom:0,left:0,position:"absolute",opacity:0,pointerEvents:"none",width:"100%",boxSizing:"border-box"});function lt(e,o){return typeof o=="object"&&o!==null?e===o:String(e)===String(o)}function $a(e){return e==null||typeof e=="string"&&!e.trim()}const Ia=e=>{const{classes:o,variant:t,disabled:r,multiple:s,open:c,error:d}=e,i={select:["select",t,r&&"disabled",s&&"multiple",d&&"error"],icon:["icon",`icon${L(t)}`,c&&"iconOpen",r&&"disabled"],nativeInput:["nativeInput"]};return Ie(i,ma,o)},Sa=u.forwardRef(function(o,t){var r;const{"aria-describedby":s,"aria-label":c,autoFocus:d,autoWidth:i,children:b,className:p,defaultOpen:m,defaultValue:h,disabled:$,displayEmpty:v,error:R=!1,IconComponent:M,inputRef:P,labelId:O,MenuProps:k={},multiple:C,name:I,onBlur:E,onChange:N,onClose:F,onFocus:q,onOpen:le,open:de,readOnly:oe,renderValue:T,SelectDisplayProps:Q={},tabIndex:G,value:se,variant:J="standard"}=o,re=ae(o,va),[U,A]=fo({controlled:se,default:h,name:"Select"}),[ie,Se]=fo({controlled:de,default:m,name:"Select"}),we=u.useRef(null),ue=u.useRef(null),[W,ee]=u.useState(null),{current:fe}=u.useRef(de!=null),[We,Z]=u.useState(),be=lo(t,P),Me=u.useCallback(y=>{ue.current=y,y&&ee(y)},[]),Y=W==null?void 0:W.parentNode;u.useImperativeHandle(be,()=>({focus:()=>{ue.current.focus()},node:we.current,value:U}),[U]),u.useEffect(()=>{m&&ie&&W&&!fe&&(Z(i?null:Y.clientWidth),ue.current.focus())},[W,i]),u.useEffect(()=>{d&&ue.current.focus()},[d]),u.useEffect(()=>{if(!O)return;const y=Fo(ue.current).getElementById(O);if(y){const B=()=>{getSelection().isCollapsed&&ue.current.focus()};return y.addEventListener("click",B),()=>{y.removeEventListener("click",B)}}},[O]);const H=(y,B)=>{y?le&&le(B):F&&F(B),fe||(Z(i?null:Y.clientWidth),Se(y))},ze=y=>{y.button===0&&(y.preventDefault(),ue.current.focus(),H(!0,y))},_e=y=>{H(!1,y)},te=u.Children.toArray(b),S=y=>{const B=te.find(X=>X.props.value===y.target.value);B!==void 0&&(A(B.props.value),N&&N(y,B))},to=y=>B=>{let X;if(B.currentTarget.hasAttribute("tabindex")){if(C){X=Array.isArray(U)?U.slice():[];const ke=U.indexOf(y.props.value);ke===-1?X.push(y.props.value):X.splice(ke,1)}else X=y.props.value;if(y.props.onClick&&y.props.onClick(B),U!==X&&(A(X),N)){const ke=B.nativeEvent||B,Ze=new ke.constructor(ke.type,ke);Object.defineProperty(Ze,"target",{writable:!0,value:{value:X,name:I}}),N(Ze,y)}C||H(!1,B)}},_=y=>{oe||[" ","ArrowUp","ArrowDown","Enter"].indexOf(y.key)!==-1&&(y.preventDefault(),H(!0,y))},xe=W!==null&&ie,Fe=y=>{!xe&&E&&(Object.defineProperty(y,"target",{writable:!0,value:{value:U,name:I}}),E(y))};delete re["aria-invalid"];let ce,Te;const me=[];let Ae=!1;(ut({value:U})||v)&&(T?ce=T(U):Ae=!0);const Ye=te.map(y=>{if(!u.isValidElement(y))return null;let B;if(C){if(!Array.isArray(U))throw new Error(it(2));B=U.some(X=>lt(X,y.props.value)),B&&Ae&&me.push(y.props.children)}else B=lt(U,y.props.value),B&&Ae&&(Te=y.props.children);return u.cloneElement(y,{"aria-selected":B?"true":"false",onClick:to(y),onKeyUp:X=>{X.key===" "&&X.preventDefault(),y.props.onKeyUp&&y.props.onKeyUp(X)},role:"option",selected:B,value:void 0,"data-value":y.props.value})});Ae&&(C?me.length===0?ce=null:ce=me.reduce((y,B,X)=>(y.push(B),X{const{classes:o}=e;return o},Bo={name:"MuiSelect",overridesResolver:(e,o)=>o.root,shouldForwardProp:e=>Xe(e)&&e!=="variant",slot:"Root"},La=w(xt,Bo)(""),wa=w(St,Bo)(""),Ma=w(ht,Bo)(""),Pt=u.forwardRef(function(o,t){const r=Pe({name:"MuiSelect",props:o}),{autoWidth:s=!1,children:c,classes:d={},className:i,defaultOpen:b=!1,displayEmpty:p=!1,IconComponent:m=gt,id:h,input:$,inputProps:v,label:R,labelId:M,MenuProps:P,multiple:O=!1,native:k=!1,onClose:C,onOpen:I,open:E,renderValue:N,SelectDisplayProps:F,variant:q="outlined"}=r,le=ae(r,ka),de=k?la:Pa,oe=so(),T=io({props:r,muiFormControl:oe,states:["variant","error"]}),Q=T.variant||q,G=a({},r,{variant:Q,classes:d}),se=Oa(G),J=ae(se,Ra),re=$||{standard:f.jsx(La,{ownerState:G}),outlined:f.jsx(wa,{label:R,ownerState:G}),filled:f.jsx(Ma,{ownerState:G})}[Q],U=lo(t,re.ref);return f.jsx(u.Fragment,{children:u.cloneElement(re,a({inputComponent:de,inputProps:a({children:c,error:T.error,IconComponent:m,variant:Q,type:void 0,multiple:O},k?{id:h}:{autoWidth:s,defaultOpen:b,displayEmpty:p,labelId:M,MenuProps:P,onClose:C,onOpen:I,open:E,renderValue:N,SelectDisplayProps:a({id:h},F)},v,{classes:v?To(J,v.classes):J},$?$.props.inputProps:{})},O&&k&&Q==="outlined"?{notched:!0}:{},{ref:U,className:ne(re.props.className,i,se.root)},!$&&{variant:Q},le))})});Pt.muiName="Select";const Fa=Pt;function Ta(e){return ye("MuiTextField",e)}$e("MuiTextField",["root"]);const Aa=["autoComplete","autoFocus","children","className","color","defaultValue","disabled","error","FormHelperTextProps","fullWidth","helperText","id","InputLabelProps","inputProps","InputProps","inputRef","label","maxRows","minRows","multiline","name","onBlur","onChange","onFocus","placeholder","required","rows","select","SelectProps","type","value","variant"],Na={standard:xt,filled:ht,outlined:St},za=e=>{const{classes:o}=e;return Ie({root:["root"]},Ta,o)},Da=w(Dt,{name:"MuiTextField",slot:"Root",overridesResolver:(e,o)=>o.root})({}),Ea=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiTextField"}),{autoComplete:s,autoFocus:c=!1,children:d,className:i,color:b="primary",defaultValue:p,disabled:m=!1,error:h=!1,FormHelperTextProps:$,fullWidth:v=!1,helperText:R,id:M,InputLabelProps:P,inputProps:O,InputProps:k,inputRef:C,label:I,maxRows:E,minRows:N,multiline:F=!1,name:q,onBlur:le,onChange:de,onFocus:oe,placeholder:T,required:Q=!1,rows:G,select:se=!1,SelectProps:J,type:re,value:U,variant:A="outlined"}=r,ie=ae(r,Aa),Se=a({},r,{autoFocus:c,color:b,disabled:m,error:h,fullWidth:v,multiline:F,required:Q,select:se,variant:A}),we=za(Se),ue={};A==="outlined"&&(P&&typeof P.shrink<"u"&&(ue.notched=P.shrink),ue.label=I),se&&((!J||!J.native)&&(ue.id=void 0),ue["aria-describedby"]=void 0);const W=Ao(M),ee=R&&W?`${W}-helper-text`:void 0,fe=I&&W?`${W}-label`:void 0,We=Na[A],Z=f.jsx(We,a({"aria-describedby":ee,autoComplete:s,autoFocus:c,defaultValue:p,fullWidth:v,multiline:F,name:q,rows:G,maxRows:E,minRows:N,type:re,value:U,id:W,inputRef:C,onBlur:le,onChange:de,onFocus:oe,placeholder:T,inputProps:O},ue,k));return f.jsxs(Da,a({className:ne(we.root,i),disabled:m,error:h,fullWidth:v,ref:t,required:Q,color:b,variant:A,ownerState:Se},ie,{children:[I!=null&&I!==""&&f.jsx(wr,a({htmlFor:W,id:fe},P,{children:I})),se?f.jsx(Fa,a({"aria-describedby":ee,id:W,labelId:fe,value:U,input:Z},J,{children:d})):Z,R&&f.jsx(pr,a({id:ee},$,{children:R}))]}))}),Ba=Ea,ja={options:[],getOptionLabel:e=>e.label,handleInputChange:e=>e},Ga=({options:e,onSelect:o,selectedValue:t=null,handleInputChange:r,isLoading:s=!1,autoFocus:c=!1,disabled:d=!1,dataTestId:i,dataId:b,placeholder:p,className:m})=>{const h=u.useRef(null),[$,v]=u.useState(!1);u.useEffect(()=>{c&&h.current&&(h.current.focus(),v(!0))},[c]);const R=(M,P)=>{o(P)};return f.jsx(Et,{flexGrow:1,spacing:1,children:f.jsx(Vn,{...ja,autoFocus:!0,autoHighlight:!0,blurOnSelect:!0,className:m,"data-testid":b,disableClearable:!0,disabled:d,disablePortal:!0,id:"blur-on-select",ListboxProps:{sx:{backgroundColor:je.DROPDOWN_BG,"&::-webkit-scrollbar":{width:"3px"},"&::-webkit-scrollbar-thumb":{backgroundClip:"padding-box",backgroundColor:je.SCROLL_BAR,borderRadius:"6px"}},ref:h},loading:s,onChange:R,onClose:()=>v(!1),onInputChange:(M,P)=>r==null?void 0:r(P),onOpen:()=>v(!0),open:$,options:e??[],PopperComponent:({children:M,...P})=>f.jsx(No,{...P,placement:"bottom-start",children:M}),renderInput:M=>f.jsx(Wa,{inputRef:h,...M,"data-testid":i,InputProps:{...M.InputProps,disableUnderline:!0,endAdornment:f.jsx(f.Fragment,{children:s?f.jsx(or,{color:"inherit",size:20}):M.InputProps.endAdornment})},placeholder:p,size:"medium",variant:"standard"}),renderOption:(M,P)=>f.jsx("li",{...M,children:f.jsxs(At,{align:"center","data-testid":P.label,direction:"row",grow:1,justify:"space-between",onClick:P==null?void 0:P.action,shrink:1,style:{fontSize:"14px",wordBreak:"break-word"},children:[f.jsx("div",{className:"option",children:P.label!==""?P.label:"Not Selected"}),(P==null?void 0:P.type)&&f.jsx(Nt,{type:P.type})]})}),sx:{"&.MuiAutocomplete-option:hover":{backgroundColor:je.DROPDOWN_HOVER},"&.MuiAutocomplete-option[aria-selected='true']":{backgroundColor:je.DROPDOWN_SELECTED}},value:t||void 0})})},Wa=Tt(Ba)` - && { - z-index: 2; - width: 100%; - color: #fff; - font-size: 15px; - box-shadow: none; - border-radius: 6px; - pointer-events: auto; - background-color: ${je.BG2}; - box-shadow: 0px 1px 6px rgba(0, 0, 0, 0.1); - padding: 0 8px; - - &:focus, - &:active { - color: ${je.white}; - background-color: ${je.BG2_ACTIVE_INPUT}; - outline: 1px solid ${je.primaryBlue}; - } - - &:hover { - background-color: ${je.BG2_ACTIVE_INPUT}; - box-shadow: 0 0 0 1px ${je.primaryBlue}; - } - - &::placeholder { - font-size: 15px; - text-align: left; - font-weight: 500; - line-height: 16px; - letter-spacing: 0em; - font-family: Barlow; - color: ${je.GRAY7}; - } - - .MuiInput-input.MuiInputBase-input { - padding: 8px; - } - - .MuiInput-root { - padding: 0; - } - } -`;export{Ga as A,Do as I,Ba as T}; diff --git a/build/assets/index-27a0b90a.js b/build/assets/index-27a0b90a.js deleted file mode 100644 index 7c9d22726..000000000 --- a/build/assets/index-27a0b90a.js +++ /dev/null @@ -1,246 +0,0 @@ -import{j as e,s as p,a as k,F as v,T as te,r as s,d as re,u as U,A as se,x as ne,y as N,o as oe,z as ie,D as ae,E as Z}from"./index-4bb27744.js";import{Universe as ce}from"./index-e06603b3.js";import{b as M,M as le,V as de,c as pe,d as ue,e as fe,f as X,a as ge}from"./index-7730ff6f.js";import{S as xe,R as he,s as V,M as me}from"./index-87de005d.js";import"./index-dc12854c.js";import"./three.module-71ec604c.js";import"./index-7888478e.js";import"./TextareaAutosize-b716e8d1.js";import"./index-5111ebdb.js";import"./index-a17bf5d0.js";import"./ClipLoader-1ef5878d.js";import"./Skeleton-dbbfd404.js";import"./Stack-6038813c.js";import"./isPlainObject-b85008a5.js";import"./Typography-f76555b9.js";import"./createSvgIcon-41051178.js";import"./index-59c77710.js";const ye=t=>e.jsxs("svg",{width:"1em",height:"1em",viewBox:"0 0 30 28",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:[e.jsx("path",{d:"M7.2998 2.55199C7.2998 1.51094 8.11675 0.666992 9.1245 0.666992H12.1299C13.1376 0.666992 13.9546 1.51094 13.9546 2.55199C13.9546 3.59305 13.1376 4.43699 12.1299 4.43699H9.1245C8.11675 4.43699 7.2998 3.59305 7.2998 2.55199Z",fill:"currentColor"}),e.jsx("path",{d:"M7.2998 25.449C7.2998 26.49 8.11675 27.334 9.1245 27.334H12.1299C13.1376 27.334 13.9546 26.49 13.9546 25.449C13.9546 24.4079 13.1376 23.564 12.1299 23.564H9.1245C8.11675 23.564 7.2998 24.4079 7.2998 25.449Z",fill:"currentColor"}),e.jsx("path",{d:"M2.79102 8.29613C2.79102 7.25508 3.60796 6.41113 4.61571 6.41113H12.1292C13.1369 6.41113 13.9539 7.25508 13.9539 8.29613C13.9539 9.33719 13.1369 10.1811 12.1292 10.1811H4.61571C3.60796 10.1811 2.79102 9.33719 2.79102 8.29613Z",fill:"currentColor"}),e.jsx("path",{d:"M2.79102 19.7039C2.79102 20.7449 3.60796 21.5889 4.61571 21.5889H12.1292C13.1369 21.5889 13.9539 20.7449 13.9539 19.7039C13.9539 18.6628 13.1369 17.8189 12.1292 17.8189H4.61571C3.60796 17.8189 2.79102 18.6628 2.79102 19.7039Z",fill:"currentColor"}),e.jsx("path",{d:"M0 14.094C0 13.0529 0.816945 12.209 1.8247 12.209H12.1289C13.1366 12.209 13.9536 13.0529 13.9536 14.094C13.9536 15.135 13.1366 15.979 12.1289 15.979H1.8247C0.816946 15.979 0 15.135 0 14.094Z",fill:"currentColor"}),e.jsx("path",{d:"M22.7002 25.448C22.7002 26.4891 21.8833 27.333 20.8755 27.333H17.8701C16.8624 27.333 16.0454 26.4891 16.0454 25.448C16.0454 24.407 16.8624 23.563 17.8701 23.563H20.8755C21.8832 23.563 22.7002 24.407 22.7002 25.448Z",fill:"currentColor"}),e.jsx("path",{d:"M22.7002 2.55199C22.7002 1.51094 21.8833 0.666992 20.8755 0.666992H17.8701C16.8624 0.666992 16.0454 1.51094 16.0454 2.55199C16.0454 3.59305 16.8624 4.43699 17.8701 4.43699H20.8755C21.8832 4.43699 22.7002 3.59305 22.7002 2.55199Z",fill:"currentColor"}),e.jsx("path",{d:"M27.209 19.7029C27.209 20.7439 26.392 21.5879 25.3843 21.5879H17.8708C16.8631 21.5879 16.0461 20.7439 16.0461 19.7029C16.0461 18.6618 16.8631 17.8179 17.8708 17.8179H25.3843C26.392 17.8179 27.209 18.6618 27.209 19.7029Z",fill:"currentColor"}),e.jsx("path",{d:"M27.209 8.29613C27.209 7.25508 26.392 6.41113 25.3843 6.41113H17.8708C16.8631 6.41113 16.0461 7.25508 16.0461 8.29613C16.0461 9.33719 16.8631 10.1811 17.8708 10.1811H25.3843C26.392 10.1811 27.209 9.33719 27.209 8.29613Z",fill:"currentColor"}),e.jsx("path",{d:"M30 14.093C30 13.052 29.1831 12.208 28.1753 12.208H17.8711C16.8634 12.208 16.0464 13.052 16.0464 14.093C16.0464 15.1341 16.8634 15.978 17.8711 15.978H28.1753C29.1831 15.978 30 15.1341 30 14.093Z",fill:"currentColor"})]}),we=()=>e.jsxs(Ce,{children:[e.jsx(je,{children:e.jsx(be,{children:e.jsx(ye,{})})}),e.jsx(ve,{children:"Graph Mindset"})]}),Ce=p(v).attrs({align:"center",direction:"row",grow:1,justify:"flex-start"})` - height: 64px; - box-sizing: border-box; - padding: 20px 23px; - gap: 0px; - z-index: 50; - position: relative; -`,je=p(v)` - align-items: center; - justify-content: center; - cursor: pointer; -`,be=p.div` - display: flex; - align-items: center; - justify-content: center; - - svg { - width: 30px; - height: 27px; - color: ${k.white}; - } -`,ve=p(te)` - width: 127px; - height: 24px; - color: ${k.white}; - font-family: Barlow; - font-size: 22px; - font-style: normal; - font-weight: 700; - line-height: 24px; - letter-spacing: 0.22px; - margin-left: 16px; - white-space: nowrap; -`,Y=s.memo(()=>{const t=M(n=>n.isPlaying),c=M(n=>n.setIsPlaying),r=M(n=>n.setVolume),a=M(n=>n.setPlaybackSpeed),g=M(n=>n.playbackSpeed),i=M(n=>n.playerRef),[w,j]=s.useState(!1),u=[.5,1,1.5,2],h=()=>{if(i){const n=i.getCurrentTime()-15;i.seekTo(n,"seconds")}},d=()=>{if(i){const n=i.getCurrentTime()+15;i.seekTo(n,"seconds")}},I=()=>{c(!t)},l=()=>{j(!w),r(w?1:0)},f=()=>{const S=(u.indexOf(g)+1)%u.length,P=u[S];if(a(P),i){const T=i.getInternalPlayer();T&&typeof T.playbackRate<"u"&&(T.playbackRate=P)}};return e.jsxs(Se,{children:[e.jsx(Pe,{onClick:l,children:w?e.jsx(le,{}):e.jsx(de,{})}),e.jsx(Te,{onClick:h,children:e.jsx("img",{alt:"",src:"RewindIcon.svg"})}),e.jsx(ke,{"data-testid":"play-pause-button",onClick:I,size:"small",children:t?e.jsx(pe,{"data-testid":"pause-icon"}):e.jsx(ue,{"data-testid":"play-icon"})}),e.jsx(Ie,{onClick:d,children:e.jsx("img",{alt:"",src:"ForwardIcon.svg"})}),e.jsxs(Ee,{onClick:f,children:[g,"x"]})]})});Y.displayName="Controls";const Se=p(v).attrs({direction:"row",align:"center",justify:"flex-start"})` - width: 200px; - height: 54px; - background: ${k.BG1}; - border-radius: 40px; - margin-right: 30px; - color: ${k.white}; - font-size: 20px; - padding: 12px; - justify-content: space-between; - box-sizing: border-box; -`,ke=p(fe)` - && { - font-size: 36px; - padding: 2px; - overflow: hidden; - } -`,Te=p.div` - display: flex; - align-items: center; - justify-content: center; - margin: 1px 0 0 1px; - cursor: pointer; - img { - width: 20px; - height: auto; - } -`,Ie=p.div` - display: flex; - align-items: center; - justify-content: center; - cursor: pointer; - img { - width: 24px; - height: auto; - } -`,Pe=p.div` - display: flex; - align-items: center; - justify-content: center; - width: 40px; - height: 40px; - cursor: pointer; - border-radius: 50%; - transition: background-color 0.3s ease; - color: ${k.GRAY6}; - - svg { - margin-top: 3px; - width: 24px; - height: 24px; - } - - &:hover { - background-color: ${k.DROPDOWN_BG}; - } -`,Ee=p.button` - margin-top: 4px; - background: ${k.BG1}; - color: ${k.GRAY6}; - border: none; - width: 8px; - border-radius: 20px; - padding: 8px 20px 8px 8px; - font-size: 14px; - cursor: pointer; - transition: background-color 0.3s ease; -`,J=s.memo(({type:t,left:c,img:r})=>{var u,h;const a=re(d=>d.normalizedSchemasByType),g=(u=a[t])==null?void 0:u.primary_color,i=(h=a[t])==null?void 0:h.icon,w=i?`svg-icons/${i}.svg`:"",j={iconStart:r||w,color:g??k.THING};return e.jsx(Re,{style:{left:`${c}%`},children:e.jsx(K,{...j,label:t})})});J.displayName="Marker";const K=s.memo(({iconStart:t,color:c,label:r})=>e.jsx(Me,{color:c,children:t&&e.jsx("img",{alt:r,className:"badge__img",src:t})}));K.displayName="Badge";const Me=p(v).attrs({direction:"row"})` - cursor: pointer; - background: ${({color:t})=>t}; - border-radius: 3px; - overflow: hidden; - justify-content: center; - align-items: center; - - .badge__img { - width: 10px; - height: 10px; - object-fit: contain; - } -`,Re=p.div` - position: absolute; - top: -6px; - width: 12px; - height: 12px; - border-radius: 4px; - background-color: ${k.white}; - transform: translateX(-50%); - transform: translateX(-50%) translateY(-50%); - top: 50%; - display: flex; - align-items: center; - justify-content: center; -`,Q=s.memo(({markers:t,duration:c})=>e.jsx(e.Fragment,{children:t.map((r,a)=>{var j;const g=Math.floor(((r==null?void 0:r.start)||0)/c*200),i=(r==null?void 0:r.node_type)||"",w=((j=r==null?void 0:r.properties)==null?void 0:j.image_url)||"";return e.jsx(J,{img:w,left:g,type:i},`${r.ref_id}_${a}`)})}));Q.displayName="Markers";const _e=({duration:t,markers:c,handleProgressChange:r,playingTIme:a})=>{const g=10/t*100;return e.jsxs($e,{children:[e.jsx(He,{max:t,onChange:r,value:a,width:g}),e.jsx(Q,{duration:t,markers:c})]})},$e=p(v)` - position: relative; - flex: 1 1 100%; -`,He=p(xe)` - && { - z-index: 20; - color: ${k.white}; - height: 3px; - width: calc(100% - 12px); - box-sizing: border-box; - .MuiSlider-track { - border: none; - } - .MuiSlider-thumb { - width: ${({width:t})=>`${t}%`}; - height: 54px; - border-radius: 8px; - background-color: ${k.primaryBlue}; - opacity: 0.2; - &:before { - box-shadow: '0 4px 8px rgba(0,0,0,0.4)'; - } - &:hover, - &.Mui-focusVisible, - &.Mui-active { - box-shadow: none; - } - } - } -`,We=({markers:t})=>{const{playingNode:c,playerRef:r}=M(u=>u),[a,g]=s.useState(0),i=c,w=s.useCallback((u,h)=>{const d=Array.isArray(h)?h[0]:h;r&&r.seekTo(d,"seconds")},[r]);s.useEffect(()=>{const u=setInterval(()=>{if(r&&g){const h=r.getCurrentTime();g(h)}},500);return()=>clearInterval(u)},[r,g]);const j=(r==null?void 0:r.getDuration())||0;return i?e.jsxs(Be,{children:[e.jsx(Y,{}),e.jsx(_e,{duration:j,handleProgressChange:w,markers:t,playingTIme:a})]}):null},Be=p(v).attrs({direction:"row",align:"center",justify:"space-between"})` - padding: 20px; - background: ${k.BG2}; - height: 96px; - /* margin-top: 16px; */ - border-radius: 8px; - box-sizing: border-box; - margin-right: 4px; -`,Fe=(t,c)=>{let r=0,a=t.length-1;for(;r<=a;){const g=Math.floor((r+a)/2),i=t[g],{start:w,end:j}=i.properties;if(c>=w&&c<=j)return i;c{const c=s.useRef(null),[r,a]=s.useState("ready"),[g,i]=s.useState(!1),{setActiveEdge:w}=X(b=>b),{dataInitial:j}=U(b=>b),{isPlaying:u,playingTime:h,setIsPlaying:d,setPlayingTime:I,setDuration:l,playingNode:f,volume:n,setHasError:S,resetPlayer:P,isSeeking:T,setIsSeeking:W,setPlayerRef:B,playerRef:R,playbackSpeed:x}=M(b=>b);s.useEffect(()=>()=>P(),[P]),s.useEffect(()=>{f&&!g&&(I(0),l(0),i(!1))},[f,I,l,i,g]),s.useEffect(()=>{T&&R&&(R.seekTo(h,"seconds"),W(!1))},[h,T,W,R]);const m=s.useCallback(()=>{d(!u)},[u,d]),o=()=>{S(!0),a("error")},C=s.useCallback(b=>{b.code},[m]);s.useEffect(()=>(window.addEventListener("keydown",C),()=>{window.removeEventListener("keydown",C)}),[C]);const _=s.useMemo(()=>((j==null?void 0:j.links.filter(y=>{var E;return(E=y==null?void 0:y.properties)==null?void 0:E.start}))||[]).slice().sort((y,E)=>{var z,q;return((z=y==null?void 0:y.properties)==null?void 0:z.start)-((q=E==null?void 0:E.properties)==null?void 0:q.start)}),[j]),F=b=>{if(!T){const H=b.playedSeconds,y=Fe(_,H);w(y||null)}},$=()=>{R&&a("ready")},A=s.useCallback(()=>{u||d(!0)},[d,u]),G=s.useCallback(()=>{u&&d(!1)},[d,u]),D=b=>{b.stopPropagation()},L=s.useCallback(b=>{!R&&b&&B(b)},[B,R]);return t?e.jsxs(ze,{ref:c,tabIndex:0,children:[e.jsx(Ne,{isFullScreen:!1,children:e.jsx(se,{size:120,src:(f==null?void 0:f.image_url)||"",type:"clip"})}),e.jsx(Ge,{isFullScreen:!1,onClick:D,children:e.jsx(he,{ref:L,height:"219px",onBuffer:()=>a("buffering"),onBufferEnd:()=>a("ready"),onError:o,onPause:G,onPlay:A,onProgress:F,onReady:$,playbackRate:x,playing:u,url:t||"",volume:n,width:"100%"})}),r==="error"?e.jsx(De,{className:"error-wrapper",children:"Error happened, please try later"}):null]}):null},ze=p(v)` - border-bottom: 1px solid rgba(0, 0, 0, 0.25); - background: rgba(0, 0, 0, 0.2); - position: relative; - overflow: hidden; - height: auto; - &:focus { - outline: none; - } -`,Ne=p(v)` - position: absolute; - top: ${t=>t.isFullScreen?"38%":"18%"}; - left: 50%; - transform: translateX(-50%); - z-index: -1; -`,De=p(v)` - height: 60px; - padding: 12px 16px; - color: ${k.primaryRed}; -`,Ge=p.div` - margin: ${t=>t.isFullScreen?"80px auto":"0"}; - width: 100%; - cursor: pointer; -`,Le=s.memo(Ae),ee=s.forwardRef(({active:t,start:c,text:r},a)=>e.jsxs(Ze,{ref:a,className:ne({active:t}),children:[e.jsx(Ve,{children:c}),e.jsx(Oe,{children:e.jsx("span",{children:r})})]}));ee.displayName="ParagraphComponent";const O=s.memo(ee,(t,c)=>t.active===c.active),Ze=p(v)` - flex-direction: row; - align-items: flex-start; - font-size: 14px; - padding: 8px 24px; - &.active { - background: ${k.AI_HIGHLIGHT}; - } -`,Ve=p.span` - background: ${k.lightBlue100}; - color: ${k.lightBlue500}; - padding: 2px; - margin-right: 8px; - border-radius: 4px; -`,Oe=p.div` - margin: 0 2px; - word-break: break-word; - - &.active { - background: ${k.AI_HIGHLIGHT}; - } -`,qe=({transcriptString:t,isFirst:c})=>{const[r,a]=s.useState(0),[g,i]=s.useState(!1),{playerRef:w}=M(l=>l),j=t.replace(/^["']|["']$/g,""),u=JSON.parse(j),h=s.useRef(null),d=s.useRef(null),I=s.useRef(null);return s.useEffect(()=>{const l=setInterval(()=>{if(w&&a){const f=w.getCurrentTime();a(f)}},100);return()=>clearInterval(l)},[w,a]),s.useEffect(()=>{const l=()=>{i(!0),I.current&&clearTimeout(I.current),I.current=setTimeout(()=>{i(!1)},1e3)},f=d.current;return f&&f.addEventListener("scroll",l),()=>{f&&f.removeEventListener("scroll",l)}},[]),s.useEffect(()=>{!g&&h.current&&h.current.scrollIntoView({behavior:"smooth",block:"center"})},[r,g]),e.jsx(Ue,{ref:d,children:e.jsx(e.Fragment,{children:c?e.jsx(e.Fragment,{children:u[0].start>r?e.jsx(O,{active:!1,start:V(u[0].start),text:u[0].text}):e.jsx(e.Fragment,{children:u.map(l=>{const f=V(l.start),n=l.start{const f=V(l.start),n=l.start{var f;const c=N(n=>n.clips),{playerRef:r}=M(n=>n),[a,g]=s.useState(0),[i,w]=s.useState(null),[j,u]=s.useState(!0),[h,d,I]=X(n=>[n.setActiveNode,n.activeNode,n.simulation]);s.useEffect(()=>{const n=setInterval(()=>{if(r&&g){const S=r.getCurrentTime();g(S)}},100);return()=>clearInterval(n)},[r,g]),s.useEffect(()=>{a&&(()=>{var P;const S=c.find(T=>{var R;const[W,B]=l((R=T==null?void 0:T.properties)==null?void 0:R.timestamp);return W<=a&&a{if(i&&(!d||i.ref_id!==d.ref_id)){const n=I==null?void 0:I.nodes().find(S=>S.ref_id===i.ref_id);typeof(n==null?void 0:n.fx)=="number"&&h(n)}},[i,d,h,I]);const l=n=>n?n.split("-").map(Number):[0,0];return e.jsxs(Ye,{children:[e.jsx(v,{className:"heading",children:t}),i?e.jsx(Je,{direction:"row",children:((f=i.properties)==null?void 0:f.transcript)&&e.jsx(qe,{isFirst:j,transcriptString:i.properties.transcript})}):null]})},Ye=p(v)` - .heading { - font-weight: 700; - font-size: 16px; - margin-bottom: 16px; - } - color: ${k.white}; - background: ${k.BG1}; - border-radius: 8px; - padding: 24px; - overflow-y: auto; - flex: 1 1 100%; -`,Je=p(v)` - flex-wrap: wrap; - flex: 1 1 100%; - margin-left: -24px; - margin-right: -24px; -`,Ke=()=>{const{selectedEpisodeLink:t,selectedEpisode:c}=N(r=>r);return e.jsxs(Qe,{align:"stretch",basis:"100%",grow:1,shrink:1,children:[e.jsx(et,{children:t&&e.jsx(Le,{mediaUrl:t})}),e.jsx(Xe,{name:(c==null?void 0:c.name)||""})]})},Qe=p(v)(({theme:t})=>({position:"relative",display:"flex",padding:"0 20px 0 20px",background:"transparent",width:"100%",height:"calc(100vh - 180px)",overflow:"auto",[t.breakpoints.up("sm")]:{width:me,gap:"10px"}})),et=p(v)(({theme:t})=>({width:"100%",marginBottom:"20px",[t.breakpoints.up("sm")]:{width:"390px",margin:"0 auto"}})),bt=()=>{const{addNewNode:t,isFetching:c,runningProjectId:r}=U(x=>x),[a,g]=s.useState(null),[i,w]=s.useState(!1),{setSelectedEpisode:j}=N(x=>x),u=N(x=>x.setClips),h=N(x=>x.clips),d=ge(),I=s.useRef(null),l=s.useRef(null),f=s.useRef(null),n=s.useRef(null),S=s.useRef(null),P=oe(),{episodeId:T}=ie(),{setPlayingNode:W}=M(x=>x);s.useEffect(()=>{T&&(async m=>{try{const o=await ae(m);o&&(W(o),j(o),t({nodes:[o],edges:[]}))}catch(o){P("/"),console.error(o)}})(T)},[T,W,j,t,P]),s.useEffect(()=>{T&&(async()=>{try{const m=await Z(T||"",0,50,{nodeType:["Show","Host","Guest"],useSubGraph:!1}),o=await Z(T||"",0,50,{nodeType:["Clip"],useSubGraph:!1});t({nodes:m!=null&&m.nodes?m==null?void 0:m.nodes:[],edges:m!=null&&m.edges?m.edges:[]}),o!=null&&o.nodes&&u(o==null?void 0:o.nodes)}catch(m){P("/"),console.error("Error fetching initial data:",m)}})()},[T,t,u,P]),s.useEffect(()=>{if(!h)return;(async()=>{var m,o;try{const C=(h==null?void 0:h.map(F=>F.ref_id).filter(Boolean))||[],_={nodes:((m=f.current)==null?void 0:m.nodes)||[],edges:((o=f.current)==null?void 0:o.edges)||[]};for(const F of C){const $=await Z(F,0,50);$&&(_.nodes.push(...($==null?void 0:$.nodes)||[]),_.edges.push(...($==null?void 0:$.edges)||[]),f.current=_,g({..._}))}}catch(C){console.error("Error processing clip nodes:",C)}})()},[h]);const B=s.useCallback(x=>{c||(n.current||(n.current={nodes:[],edges:[]}),x.edges&&n.current.edges.push(...x.edges),x.nodes&&n.current.nodes.push(...x.nodes),S.current&&clearTimeout(S.current),S.current=setTimeout(()=>{if(n.current){const{nodes:m,edges:o}=n.current,C={nodes:m,edges:o};n.current={nodes:[],edges:[]},t(C)}},3e3))},[t,c]);s.useEffect(()=>(d&&(d.connect(),d.on("connect_error",x=>{console.error("Socket connection error:",x)}),r&&d.on("new_node_created",B)),()=>{d&&d.off()}),[d,B,r]),s.useEffect(()=>{const x=m=>{const{playerRef:o}=M.getState();if(l.current!==null){if(m-l.current>1e3){if(f.current&&o){const{nodes:_,edges:F}=f.current,$=o==null?void 0:o.getCurrentTime(),[A,G]=F.reduce(([b,H],y)=>{var E,z;return((E=y==null?void 0:y.properties)==null?void 0:E.start)!==void 0&&((z=y==null?void 0:y.properties)==null?void 0:z.start)<$+1?b.push(y):H.push(y),[b,H]},[[],[]]),[D,L]=_.reduce(([b,H],y)=>(A.some(E=>E.target===y.ref_id||E.source===y.ref_id)?b.push(y):H.push(y),[b,H]),[[],[]]);f.current={nodes:L,edges:G},(D.length||A.length)&&t({nodes:D,edges:A})}l.current=m}}else l.current=m;I.current=requestAnimationFrame(x)};return I.current=requestAnimationFrame(x),()=>{I.current&&cancelAnimationFrame(I.current)}},[f,t]),s.useEffect(()=>{if(r)try{d==null||d.emit("update_project_id",{id:r})}catch(x){console.error(x)}},[r,d]);const R=s.useMemo(()=>{if(a){const x=a.edges.filter(o=>{var C;return(C=o==null?void 0:o.properties)==null?void 0:C.start}).map(o=>{var C;return{source:o.source,target:o.target,start:(C=o.properties)==null?void 0:C.start}});return a.nodes.filter(o=>a.edges.some(C=>C.source===o.ref_id||C.target===o.ref_id)).map(o=>{const C=x.find(_=>o.ref_id===_.source||o.ref_id===_.target);return{...o,start:(C==null?void 0:C.start)||0}}).filter(o=>o&&o.node_type!=="Clip"&&o.node_type!=="Episode"&&o.node_type!=="Show")}return[]},[a]);return e.jsxs(tt,{children:[e.jsx(rt,{direction:"row",children:e.jsxs(e.Fragment,{children:[e.jsxs(v,{children:[e.jsx(v,{onClick:()=>w(!i),children:e.jsx(we,{})}),e.jsx(Ke,{})]}),e.jsx(st,{children:e.jsx(v,{basis:"100%",grow:1,shrink:1,children:e.jsx(ce,{})})})]})}),e.jsx(nt,{children:e.jsx(We,{markers:R})})]})},tt=p.div` - display: flex; - flex-direction: column; - height: 100vh; - width: 100%; -`,rt=p(v)` - flex: 1; - overflow: hidden; -`,st=p(v)` - flex-basis: 100%; - flex-shrink: 1; - flex-grow: 1; - padding: 16px 16px 16px 0; -`,nt=p(v)` - padding: 16px 16px 16px 0; - margin-left: 18px; -`;export{bt as MindSet}; diff --git a/build/assets/index-7888478e.js b/build/assets/index-37b3c15b.js similarity index 91% rename from build/assets/index-7888478e.js rename to build/assets/index-37b3c15b.js index 39f977dd5..52ec187a2 100644 --- a/build/assets/index-7888478e.js +++ b/build/assets/index-37b3c15b.js @@ -1 +1 @@ -import{a9 as c}from"./index-4bb27744.js";var p={exports:{}},i="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",y=i,m=y;function a(){}function n(){}n.resetWarningCache=a;var T=function(){function e(f,h,l,P,v,s){if(s!==m){var o=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 o.name="Invariant Violation",o}}e.isRequired=e;function r(){return e}var t={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:r,element:e,elementType:e,instanceOf:r,node:e,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:n,resetWarningCache:a};return t.PropTypes=t,t};p.exports=T();var u=p.exports;const _=c(u);export{_ as P,u as p}; +import{a8 as c}from"./index-4e60c9e2.js";var p={exports:{}},i="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",y=i,m=y;function a(){}function n(){}n.resetWarningCache=a;var T=function(){function e(f,h,l,P,v,s){if(s!==m){var o=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 o.name="Invariant Violation",o}}e.isRequired=e;function r(){return e}var t={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:r,element:e,elementType:e,instanceOf:r,node:e,objectOf:r,oneOf:r,oneOfType:r,shape:r,exact:r,checkPropTypes:n,resetWarningCache:a};return t.PropTypes=t,t};p.exports=T();var u=p.exports;const _=c(u);export{_ as P,u as p}; diff --git a/build/assets/index-78eebc06.js b/build/assets/index-40addfb3.js similarity index 95% rename from build/assets/index-78eebc06.js rename to build/assets/index-40addfb3.js index 83c37560b..cd42471d9 100644 --- a/build/assets/index-78eebc06.js +++ b/build/assets/index-40addfb3.js @@ -1,4 +1,4 @@ -import{s as t,a as o,F as n,T as S,r as b,j as e,B as v,t as C,k as $,b as T,aV as G,aW as k,aX as y,v as z,aY as w,aZ as M,a_ as D,e as j,a$ as I}from"./index-4bb27744.js";import{f as A,s as R}from"./index-7730ff6f.js";import{C as B}from"./ClipLoader-1ef5878d.js";import{T as E,a as L}from"./Tabs-7ecc0b57.js";import"./createSvgIcon-41051178.js";const V=()=>(A(R(a=>[a.graphStyle,a.setGraphStyle])),null);t(n).attrs({direction:"row",align:"center",justify:"space-between"})` +import{s as t,a as o,F as n,T as S,r as b,j as e,B as v,t as C,k as $,b as T,aU as G,aV as k,aW as y,v as z,aX as w,aY as M,aZ as D,e as j,a_ as I}from"./index-4e60c9e2.js";import{f as A,s as R}from"./index-af5a3f81.js";import{C as B}from"./ClipLoader-8590c2f1.js";import{T as E,a as L}from"./Tabs-71f3fbcc.js";import"./createSvgIcon-c125a9c8.js";const V=()=>(A(R(a=>[a.graphStyle,a.setGraphStyle])),null);t(n).attrs({direction:"row",align:"center",justify:"space-between"})` width: 447px; height: 48px; background: ${o.appearanceBg}; diff --git a/build/assets/index-4bb27744.js b/build/assets/index-4e60c9e2.js similarity index 99% rename from build/assets/index-4bb27744.js rename to build/assets/index-4e60c9e2.js index 555bd07c7..257589fee 100644 --- a/build/assets/index-4bb27744.js +++ b/build/assets/index-4e60c9e2.js @@ -264,7 +264,7 @@ PROCEED WITH CAUTION! * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var h$3=reactExports,n$1=shimExports;function p$2(et,tt){return et===tt&&(et!==0||1/et===1/tt)||et!==et&&tt!==tt}var q$1=typeof Object.is=="function"?Object.is:p$2,r$4=n$1.useSyncExternalStore,t$1=h$3.useRef,u$2=h$3.useEffect,v$3=h$3.useMemo,w$2=h$3.useDebugValue;withSelector_production_min.useSyncExternalStoreWithSelector=function(et,tt,rt,nt,it){var st=t$1(null);if(st.current===null){var at={hasValue:!1,value:null};st.current=at}else at=st.current;st=v$3(function(){function lt(kt){if(!ut){if(ut=!0,dt=kt,kt=nt(kt),it!==void 0&&at.hasValue){var pt=at.value;if(it(pt,kt))return vt=pt}return vt=kt}if(pt=vt,q$1(dt,kt))return pt;var yt=nt(kt);return it!==void 0&&it(pt,yt)?pt:(dt=kt,vt=yt)}var ut=!1,dt,vt,mt=rt===void 0?null:rt;return[function(){return lt(tt())},mt===null?void 0:function(){return lt(mt())}]},[tt,rt,nt,it]);var ot=r$4(et,st[0],st[1]);return u$2(function(){at.hasValue=!0,at.value=ot},[ot]),w$2(ot),ot};withSelector.exports=withSelector_production_min;var withSelectorExports=withSelector.exports;const useSyncExternalStoreExports=getDefaultExportFromCjs(withSelectorExports),{useDebugValue}=React,{useSyncExternalStoreWithSelector}=useSyncExternalStoreExports;let didWarnAboutEqualityFn=!1;function useStore(et,tt=et.getState,rt){const nt=useSyncExternalStoreWithSelector(et.subscribe,et.getState,et.getServerState||et.getState,tt,rt);return useDebugValue(nt),nt}const createImpl=et=>{const tt=typeof et=="function"?createStore(et):et,rt=(nt,it)=>useStore(tt,nt,it);return Object.assign(rt,tt),rt},create=et=>et?createImpl(et):createImpl;var react=et=>create(et);const defaultData$7={isAdmin:!1,isAuthenticated:!1,pubKey:"",budget:0,nodeCount:0,tribeHost:"",tribeUuid:"",signedToken:"",swarmUiUrl:""},useUserStore=create(et=>({...defaultData$7,setIsAdmin:tt=>et({isAdmin:tt}),setPubKey:tt=>et({pubKey:tt}),setBudget:tt=>et({budget:tt}),setNodeCount:tt=>et(rt=>tt==="INCREMENT"?{nodeCount:rt.nodeCount+1}:{nodeCount:0}),setTribeUuid:tt=>et({tribeUuid:tt}),setTribeHost:tt=>et({tribeHost:tt}),setIsAuthenticated:tt=>et({isAuthenticated:tt}),setSignedToken:tt=>et({signedToken:tt}),setSwarmUiUrl:tt=>et({swarmUiUrl:tt})})),executeIfTetsRunning=et=>{isE2E&&et()};function executeIfProd(et){return isDevelopment||isE2E?null:et()}function addToGlobalForE2e(et,tt){executeIfTetsRunning(()=>{window.e2e||(window.e2e={}),window.e2e[tt]=et})}const E2E=()=>{const et=useUserStore();return reactExports.useEffect(()=>{isE2E&&addToGlobalForE2e(et,"userStore")},[et]),jsxRuntimeExports.jsx("div",{id:"e2e-check"})},E2ETests=reactExports.memo(()=>isE2E?jsxRuntimeExports.jsx(E2E,{}):null);async function getBalance(et){return api$1.get("/balance",{Authorization:et})}async function updateBudget(et){const tt=await getLSat();if(!tt){et(0);return}try{const rt=await getBalance(tt);et(rt.balance)}catch{et(0)}}const common={black:"#000",white:"#fff"},common$1=common,red={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},red$1=red,purple={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},purple$1=purple,blue={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},blue$1=blue,lightBlue={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},lightBlue$1=lightBlue,green={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},green$1=green,orange={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},orange$1=orange,grey={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},grey$1=grey;function _extends(){return _extends=Object.assign?Object.assign.bind():function(et){for(var tt=1;tt{tt[rt]=deepClone(et[rt])}),tt}function deepmerge(et,tt,rt={clone:!0}){const nt=rt.clone?_extends({},et):et;return isPlainObject$1(et)&&isPlainObject$1(tt)&&Object.keys(tt).forEach(it=>{it!=="__proto__"&&(isPlainObject$1(tt[it])&&it in et&&isPlainObject$1(et[it])?nt[it]=deepmerge(et[it],tt[it],rt):rt.clone?nt[it]=isPlainObject$1(tt[it])?deepClone(tt[it]):tt[it]:nt[it]=tt[it])}),nt}function formatMuiErrorMessage(et){let tt="https://mui.com/production-error/?code="+et;for(let rt=1;rt{tt.current=et}),reactExports.useRef((...rt)=>(0,tt.current)(...rt)).current}function useForkRef(...et){return reactExports.useMemo(()=>et.every(tt=>tt==null)?null:tt=>{et.forEach(rt=>{setRef(rt,tt)})},et)}let hadKeyboardEvent=!0,hadFocusVisibleRecently=!1,hadFocusVisibleRecentlyTimeout;const inputTypesWhitelist={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function focusTriggersKeyboardModality(et){const{type:tt,tagName:rt}=et;return!!(rt==="INPUT"&&inputTypesWhitelist[tt]&&!et.readOnly||rt==="TEXTAREA"&&!et.readOnly||et.isContentEditable)}function handleKeyDown(et){et.metaKey||et.altKey||et.ctrlKey||(hadKeyboardEvent=!0)}function handlePointerDown(){hadKeyboardEvent=!1}function handleVisibilityChange(){this.visibilityState==="hidden"&&hadFocusVisibleRecently&&(hadKeyboardEvent=!0)}function prepare(et){et.addEventListener("keydown",handleKeyDown,!0),et.addEventListener("mousedown",handlePointerDown,!0),et.addEventListener("pointerdown",handlePointerDown,!0),et.addEventListener("touchstart",handlePointerDown,!0),et.addEventListener("visibilitychange",handleVisibilityChange,!0)}function isFocusVisible(et){const{target:tt}=et;try{return tt.matches(":focus-visible")}catch{}return hadKeyboardEvent||focusTriggersKeyboardModality(tt)}function useIsFocusVisible(){const et=reactExports.useCallback(it=>{it!=null&&prepare(it.ownerDocument)},[]),tt=reactExports.useRef(!1);function rt(){return tt.current?(hadFocusVisibleRecently=!0,window.clearTimeout(hadFocusVisibleRecentlyTimeout),hadFocusVisibleRecentlyTimeout=window.setTimeout(()=>{hadFocusVisibleRecently=!1},100),tt.current=!1,!0):!1}function nt(it){return isFocusVisible(it)?(tt.current=!0,!0):!1}return{isFocusVisibleRef:tt,onFocus:nt,onBlur:rt,ref:et}}function resolveProps(et,tt){const rt=_extends({},tt);return Object.keys(et).forEach(nt=>{if(nt.toString().match(/^(components|slots)$/))rt[nt]=_extends({},et[nt],rt[nt]);else if(nt.toString().match(/^(componentsProps|slotProps)$/)){const it=et[nt]||{},st=tt[nt];rt[nt]={},!st||!Object.keys(st)?rt[nt]=it:!it||!Object.keys(it)?rt[nt]=st:(rt[nt]=_extends({},st),Object.keys(it).forEach(at=>{rt[nt][at]=resolveProps(it[at],st[at])}))}else rt[nt]===void 0&&(rt[nt]=et[nt])}),rt}function composeClasses(et,tt,rt=void 0){const nt={};return Object.keys(et).forEach(it=>{nt[it]=et[it].reduce((st,at)=>{if(at){const ot=tt(at);ot!==""&&st.push(ot),rt&&rt[at]&&st.push(rt[at])}return st},[]).join(" ")}),nt}const defaultGenerator=et=>et,createClassNameGenerator=()=>{let et=defaultGenerator;return{configure(tt){et=tt},generate(tt){return et(tt)},reset(){et=defaultGenerator}}},ClassNameGenerator=createClassNameGenerator(),ClassNameGenerator$1=ClassNameGenerator,globalStateClassesMapping={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function generateUtilityClass(et,tt,rt="Mui"){const nt=globalStateClassesMapping[tt];return nt?`${rt}-${nt}`:`${ClassNameGenerator$1.generate(et)}-${tt}`}function generateUtilityClasses(et,tt,rt="Mui"){const nt={};return tt.forEach(it=>{nt[it]=generateUtilityClass(et,it,rt)}),nt}const THEME_ID="$$material";function _objectWithoutPropertiesLoose(et,tt){if(et==null)return{};var rt={},nt=Object.keys(et),it,st;for(st=0;st=0)&&(rt[it]=et[it]);return rt}var reactPropsRegex=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,isPropValid=memoize$1(function(et){return reactPropsRegex.test(et)||et.charCodeAt(0)===111&&et.charCodeAt(1)===110&&et.charCodeAt(2)<91});function sheetForTag(et){if(et.sheet)return et.sheet;for(var tt=0;tt0?charat(characters,--position):0,column--,character===10&&(column=1,line--),character}function next(){return character=position2||token(character)>3?"":" "}function escaping(et,tt){for(;--tt&&next()&&!(character<48||character>102||character>57&&character<65||character>70&&character<97););return slice(et,caret()+(tt<6&&peek()==32&&next()==32))}function delimiter(et){for(;next();)switch(character){case et:return position;case 34:case 39:et!==34&&et!==39&&delimiter(character);break;case 40:et===41&&delimiter(et);break;case 92:next();break}return position}function commenter(et,tt){for(;next()&&et+character!==47+10;)if(et+character===42+42&&peek()===47)break;return"/*"+slice(tt,position-1)+"*"+from(et===47?et:next())}function identifier(et){for(;!token(peek());)next();return slice(et,position)}function compile(et){return dealloc(parse$1("",null,null,null,[""],et=alloc(et),0,[0],et))}function parse$1(et,tt,rt,nt,it,st,at,ot,lt){for(var ut=0,dt=0,vt=at,mt=0,kt=0,pt=0,yt=1,$t=1,gt=1,wt=0,St="",Bt=it,Ot=st,Lt=nt,zt=St;$t;)switch(pt=wt,wt=next()){case 40:if(pt!=108&&charat(zt,vt-1)==58){indexof(zt+=replace(delimit(wt),"&","&\f"),"&\f")!=-1&&(gt=-1);break}case 34:case 39:case 91:zt+=delimit(wt);break;case 9:case 10:case 13:case 32:zt+=whitespace(pt);break;case 92:zt+=escaping(caret()-1,7);continue;case 47:switch(peek()){case 42:case 47:append(comment(commenter(next(),caret()),tt,rt),lt);break;default:zt+="/"}break;case 123*yt:ot[ut++]=strlen(zt)*gt;case 125*yt:case 59:case 0:switch(wt){case 0:case 125:$t=0;case 59+dt:gt==-1&&(zt=replace(zt,/\f/g,"")),kt>0&&strlen(zt)-vt&&append(kt>32?declaration(zt+";",nt,rt,vt-1):declaration(replace(zt," ","")+";",nt,rt,vt-2),lt);break;case 59:zt+=";";default:if(append(Lt=ruleset(zt,tt,rt,ut,dt,it,ot,St,Bt=[],Ot=[],vt),st),wt===123)if(dt===0)parse$1(zt,tt,Lt,Lt,Bt,st,vt,ot,Ot);else switch(mt===99&&charat(zt,3)===110?100:mt){case 100:case 108:case 109:case 115:parse$1(et,Lt,Lt,nt&&append(ruleset(et,Lt,Lt,0,0,it,ot,St,it,Bt=[],vt),Ot),it,Ot,vt,ot,nt?Bt:Ot);break;default:parse$1(zt,Lt,Lt,Lt,[""],Ot,0,ot,Ot)}}ut=dt=kt=0,yt=gt=1,St=zt="",vt=at;break;case 58:vt=1+strlen(zt),kt=pt;default:if(yt<1){if(wt==123)--yt;else if(wt==125&&yt++==0&&prev$1()==125)continue}switch(zt+=from(wt),wt*yt){case 38:gt=dt>0?1:(zt+="\f",-1);break;case 44:ot[ut++]=(strlen(zt)-1)*gt,gt=1;break;case 64:peek()===45&&(zt+=delimit(next())),mt=peek(),dt=vt=strlen(St=zt+=identifier(caret())),wt++;break;case 45:pt===45&&strlen(zt)==2&&(yt=0)}}return st}function ruleset(et,tt,rt,nt,it,st,at,ot,lt,ut,dt){for(var vt=it-1,mt=it===0?st:[""],kt=sizeof(mt),pt=0,yt=0,$t=0;pt0?mt[gt]+" "+wt:replace(wt,/&\f/g,mt[gt])))&&(lt[$t++]=St);return node(et,tt,rt,it===0?RULESET:ot,lt,ut,dt)}function comment(et,tt,rt){return node(et,tt,rt,COMMENT,from(char()),substr(et,2,-2),0)}function declaration(et,tt,rt,nt){return node(et,tt,rt,DECLARATION,substr(et,0,nt),substr(et,nt+1,-1),nt)}function serialize(et,tt){for(var rt="",nt=sizeof(et),it=0;it6)switch(charat(et,tt+1)){case 109:if(charat(et,tt+4)!==45)break;case 102:return replace(et,/(.+:)(.+)-([^]+)/,"$1"+WEBKIT+"$2-$3$1"+MOZ+(charat(et,tt+3)==108?"$3":"$2-$3"))+et;case 115:return~indexof(et,"stretch")?prefix(replace(et,"stretch","fill-available"),tt)+et:et}break;case 4949:if(charat(et,tt+1)!==115)break;case 6444:switch(charat(et,strlen(et)-3-(~indexof(et,"!important")&&10))){case 107:return replace(et,":",":"+WEBKIT)+et;case 101:return replace(et,/(.+:)([^;!]+)(;|!.+)?/,"$1"+WEBKIT+(charat(et,14)===45?"inline-":"")+"box$3$1"+WEBKIT+"$2$3$1"+MS+"$2box$3")+et}break;case 5936:switch(charat(et,tt+11)){case 114:return WEBKIT+et+MS+replace(et,/[svh]\w+-[tblr]{2}/,"tb")+et;case 108:return WEBKIT+et+MS+replace(et,/[svh]\w+-[tblr]{2}/,"tb-rl")+et;case 45:return WEBKIT+et+MS+replace(et,/[svh]\w+-[tblr]{2}/,"lr")+et}return WEBKIT+et+MS+et+et}return et}var prefixer=function(tt,rt,nt,it){if(tt.length>-1&&!tt.return)switch(tt.type){case DECLARATION:tt.return=prefix(tt.value,tt.length);break;case KEYFRAMES:return serialize([copy(tt,{value:replace(tt.value,"@","@"+WEBKIT)})],it);case RULESET:if(tt.length)return combine(tt.props,function(st){switch(match(st,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return serialize([copy(tt,{props:[replace(st,/:(read-\w+)/,":"+MOZ+"$1")]})],it);case"::placeholder":return serialize([copy(tt,{props:[replace(st,/:(plac\w+)/,":"+WEBKIT+"input-$1")]}),copy(tt,{props:[replace(st,/:(plac\w+)/,":"+MOZ+"$1")]}),copy(tt,{props:[replace(st,/:(plac\w+)/,MS+"input-$1")]})],it)}return""})}},defaultStylisPlugins=[prefixer],createCache=function(tt){var rt=tt.key;if(rt==="css"){var nt=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(nt,function(yt){var $t=yt.getAttribute("data-emotion");$t.indexOf(" ")!==-1&&(document.head.appendChild(yt),yt.setAttribute("data-s",""))})}var it=tt.stylisPlugins||defaultStylisPlugins,st={},at,ot=[];at=tt.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+rt+' "]'),function(yt){for(var $t=yt.getAttribute("data-emotion").split(" "),gt=1;gt<$t.length;gt++)st[$t[gt]]=!0;ot.push(yt)});var lt,ut=[compat,removeLabel];{var dt,vt=[stringify,rulesheet(function(yt){dt.insert(yt)})],mt=middleware(ut.concat(it,vt)),kt=function($t){return serialize(compile($t),mt)};lt=function($t,gt,wt,St){dt=wt,kt($t?$t+"{"+gt.styles+"}":gt.styles),St&&(pt.inserted[gt.name]=!0)}}var pt={key:rt,sheet:new StyleSheet({key:rt,container:at,nonce:tt.nonce,speedy:tt.speedy,prepend:tt.prepend,insertionPoint:tt.insertionPoint}),nonce:tt.nonce,inserted:st,registered:{},insert:lt};return pt.sheet.hydrate(ot),pt},isBrowser=!0;function getRegisteredStyles(et,tt,rt){var nt="";return rt.split(" ").forEach(function(it){et[it]!==void 0?tt.push(et[it]+";"):nt+=it+" "}),nt}var registerStyles=function(tt,rt,nt){var it=tt.key+"-"+rt.name;(nt===!1||isBrowser===!1)&&tt.registered[it]===void 0&&(tt.registered[it]=rt.styles)},insertStyles=function(tt,rt,nt){registerStyles(tt,rt,nt);var it=tt.key+"-"+rt.name;if(tt.inserted[rt.name]===void 0){var st=rt;do tt.insert(rt===st?"."+it:"",st,tt.sheet,!0),st=st.next;while(st!==void 0)}};function murmur2(et){for(var tt=0,rt,nt=0,it=et.length;it>=4;++nt,it-=4)rt=et.charCodeAt(nt)&255|(et.charCodeAt(++nt)&255)<<8|(et.charCodeAt(++nt)&255)<<16|(et.charCodeAt(++nt)&255)<<24,rt=(rt&65535)*1540483477+((rt>>>16)*59797<<16),rt^=rt>>>24,tt=(rt&65535)*1540483477+((rt>>>16)*59797<<16)^(tt&65535)*1540483477+((tt>>>16)*59797<<16);switch(it){case 3:tt^=(et.charCodeAt(nt+2)&255)<<16;case 2:tt^=(et.charCodeAt(nt+1)&255)<<8;case 1:tt^=et.charCodeAt(nt)&255,tt=(tt&65535)*1540483477+((tt>>>16)*59797<<16)}return tt^=tt>>>13,tt=(tt&65535)*1540483477+((tt>>>16)*59797<<16),((tt^tt>>>15)>>>0).toString(36)}var unitlessKeys={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},hyphenateRegex=/[A-Z]|^ms/g,animationRegex=/_EMO_([^_]+?)_([^]*?)_EMO_/g,isCustomProperty=function(tt){return tt.charCodeAt(1)===45},isProcessableValue=function(tt){return tt!=null&&typeof tt!="boolean"},processStyleName=memoize$1(function(et){return isCustomProperty(et)?et:et.replace(hyphenateRegex,"-$&").toLowerCase()}),processStyleValue=function(tt,rt){switch(tt){case"animation":case"animationName":if(typeof rt=="string")return rt.replace(animationRegex,function(nt,it,st){return cursor={name:it,styles:st,next:cursor},it})}return unitlessKeys[tt]!==1&&!isCustomProperty(tt)&&typeof rt=="number"&&rt!==0?rt+"px":rt},noComponentSelectorMessage="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function handleInterpolation(et,tt,rt){if(rt==null)return"";if(rt.__emotion_styles!==void 0)return rt;switch(typeof rt){case"boolean":return"";case"object":{if(rt.anim===1)return cursor={name:rt.name,styles:rt.styles,next:cursor},rt.name;if(rt.styles!==void 0){var nt=rt.next;if(nt!==void 0)for(;nt!==void 0;)cursor={name:nt.name,styles:nt.styles,next:cursor},nt=nt.next;var it=rt.styles+";";return it}return createStringFromObject(et,tt,rt)}case"function":{if(et!==void 0){var st=cursor,at=rt(et);return cursor=st,handleInterpolation(et,tt,at)}break}}if(tt==null)return rt;var ot=tt[rt];return ot!==void 0?ot:rt}function createStringFromObject(et,tt,rt){var nt="";if(Array.isArray(rt))for(var it=0;it96?testOmitPropsOnStringTag:testOmitPropsOnComponent},composeShouldForwardProps=function(tt,rt,nt){var it;if(rt){var st=rt.shouldForwardProp;it=tt.__emotion_forwardProp&&st?function(at){return tt.__emotion_forwardProp(at)&&st(at)}:st}return typeof it!="function"&&nt&&(it=tt.__emotion_forwardProp),it},Insertion=function(tt){var rt=tt.cache,nt=tt.serialized,it=tt.isStringTag;return registerStyles(rt,nt,it),useInsertionEffectAlwaysWithSyncFallback(function(){return insertStyles(rt,nt,it)}),null},createStyled$1=function et(tt,rt){var nt=tt.__emotion_real===tt,it=nt&&tt.__emotion_base||tt,st,at;rt!==void 0&&(st=rt.label,at=rt.target);var ot=composeShouldForwardProps(tt,rt,nt),lt=ot||getDefaultShouldForwardProp(it),ut=!lt("as");return function(){var dt=arguments,vt=nt&&tt.__emotion_styles!==void 0?tt.__emotion_styles.slice(0):[];if(st!==void 0&&vt.push("label:"+st+";"),dt[0]==null||dt[0].raw===void 0)vt.push.apply(vt,dt);else{vt.push(dt[0][0]);for(var mt=dt.length,kt=1;kt{const tt=typeof et=="function"?createStore(et):et,rt=(nt,it)=>useStore(tt,nt,it);return Object.assign(rt,tt),rt},create=et=>et?createImpl(et):createImpl;var react=et=>create(et);const defaultData$6={isAdmin:!1,isAuthenticated:!1,pubKey:"",budget:0,nodeCount:0,tribeHost:"",tribeUuid:"",signedToken:"",swarmUiUrl:""},useUserStore=create(et=>({...defaultData$6,setIsAdmin:tt=>et({isAdmin:tt}),setPubKey:tt=>et({pubKey:tt}),setBudget:tt=>et({budget:tt}),setNodeCount:tt=>et(rt=>tt==="INCREMENT"?{nodeCount:rt.nodeCount+1}:{nodeCount:0}),setTribeUuid:tt=>et({tribeUuid:tt}),setTribeHost:tt=>et({tribeHost:tt}),setIsAuthenticated:tt=>et({isAuthenticated:tt}),setSignedToken:tt=>et({signedToken:tt}),setSwarmUiUrl:tt=>et({swarmUiUrl:tt})})),executeIfTetsRunning=et=>{isE2E&&et()};function executeIfProd(et){return isDevelopment||isE2E?null:et()}function addToGlobalForE2e(et,tt){executeIfTetsRunning(()=>{window.e2e||(window.e2e={}),window.e2e[tt]=et})}const E2E=()=>{const et=useUserStore();return reactExports.useEffect(()=>{isE2E&&addToGlobalForE2e(et,"userStore")},[et]),jsxRuntimeExports.jsx("div",{id:"e2e-check"})},E2ETests=reactExports.memo(()=>isE2E?jsxRuntimeExports.jsx(E2E,{}):null);async function getBalance(et){return api$1.get("/balance",{Authorization:et})}async function updateBudget(et){const tt=await getLSat();if(!tt){et(0);return}try{const rt=await getBalance(tt);et(rt.balance)}catch{et(0)}}const common={black:"#000",white:"#fff"},common$1=common,red={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},red$1=red,purple={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},purple$1=purple,blue={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},blue$1=blue,lightBlue={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},lightBlue$1=lightBlue,green={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"},green$1=green,orange={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},orange$1=orange,grey={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},grey$1=grey;function _extends(){return _extends=Object.assign?Object.assign.bind():function(et){for(var tt=1;tt{tt[rt]=deepClone(et[rt])}),tt}function deepmerge(et,tt,rt={clone:!0}){const nt=rt.clone?_extends({},et):et;return isPlainObject$1(et)&&isPlainObject$1(tt)&&Object.keys(tt).forEach(it=>{it!=="__proto__"&&(isPlainObject$1(tt[it])&&it in et&&isPlainObject$1(et[it])?nt[it]=deepmerge(et[it],tt[it],rt):rt.clone?nt[it]=isPlainObject$1(tt[it])?deepClone(tt[it]):tt[it]:nt[it]=tt[it])}),nt}function formatMuiErrorMessage(et){let tt="https://mui.com/production-error/?code="+et;for(let rt=1;rt{tt.current=et}),reactExports.useRef((...rt)=>(0,tt.current)(...rt)).current}function useForkRef(...et){return reactExports.useMemo(()=>et.every(tt=>tt==null)?null:tt=>{et.forEach(rt=>{setRef(rt,tt)})},et)}let hadKeyboardEvent=!0,hadFocusVisibleRecently=!1,hadFocusVisibleRecentlyTimeout;const inputTypesWhitelist={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function focusTriggersKeyboardModality(et){const{type:tt,tagName:rt}=et;return!!(rt==="INPUT"&&inputTypesWhitelist[tt]&&!et.readOnly||rt==="TEXTAREA"&&!et.readOnly||et.isContentEditable)}function handleKeyDown(et){et.metaKey||et.altKey||et.ctrlKey||(hadKeyboardEvent=!0)}function handlePointerDown(){hadKeyboardEvent=!1}function handleVisibilityChange(){this.visibilityState==="hidden"&&hadFocusVisibleRecently&&(hadKeyboardEvent=!0)}function prepare(et){et.addEventListener("keydown",handleKeyDown,!0),et.addEventListener("mousedown",handlePointerDown,!0),et.addEventListener("pointerdown",handlePointerDown,!0),et.addEventListener("touchstart",handlePointerDown,!0),et.addEventListener("visibilitychange",handleVisibilityChange,!0)}function isFocusVisible(et){const{target:tt}=et;try{return tt.matches(":focus-visible")}catch{}return hadKeyboardEvent||focusTriggersKeyboardModality(tt)}function useIsFocusVisible(){const et=reactExports.useCallback(it=>{it!=null&&prepare(it.ownerDocument)},[]),tt=reactExports.useRef(!1);function rt(){return tt.current?(hadFocusVisibleRecently=!0,window.clearTimeout(hadFocusVisibleRecentlyTimeout),hadFocusVisibleRecentlyTimeout=window.setTimeout(()=>{hadFocusVisibleRecently=!1},100),tt.current=!1,!0):!1}function nt(it){return isFocusVisible(it)?(tt.current=!0,!0):!1}return{isFocusVisibleRef:tt,onFocus:nt,onBlur:rt,ref:et}}function resolveProps(et,tt){const rt=_extends({},tt);return Object.keys(et).forEach(nt=>{if(nt.toString().match(/^(components|slots)$/))rt[nt]=_extends({},et[nt],rt[nt]);else if(nt.toString().match(/^(componentsProps|slotProps)$/)){const it=et[nt]||{},st=tt[nt];rt[nt]={},!st||!Object.keys(st)?rt[nt]=it:!it||!Object.keys(it)?rt[nt]=st:(rt[nt]=_extends({},st),Object.keys(it).forEach(at=>{rt[nt][at]=resolveProps(it[at],st[at])}))}else rt[nt]===void 0&&(rt[nt]=et[nt])}),rt}function composeClasses(et,tt,rt=void 0){const nt={};return Object.keys(et).forEach(it=>{nt[it]=et[it].reduce((st,at)=>{if(at){const ot=tt(at);ot!==""&&st.push(ot),rt&&rt[at]&&st.push(rt[at])}return st},[]).join(" ")}),nt}const defaultGenerator=et=>et,createClassNameGenerator=()=>{let et=defaultGenerator;return{configure(tt){et=tt},generate(tt){return et(tt)},reset(){et=defaultGenerator}}},ClassNameGenerator=createClassNameGenerator(),ClassNameGenerator$1=ClassNameGenerator,globalStateClassesMapping={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function generateUtilityClass(et,tt,rt="Mui"){const nt=globalStateClassesMapping[tt];return nt?`${rt}-${nt}`:`${ClassNameGenerator$1.generate(et)}-${tt}`}function generateUtilityClasses(et,tt,rt="Mui"){const nt={};return tt.forEach(it=>{nt[it]=generateUtilityClass(et,it,rt)}),nt}const THEME_ID="$$material";function _objectWithoutPropertiesLoose(et,tt){if(et==null)return{};var rt={},nt=Object.keys(et),it,st;for(st=0;st=0)&&(rt[it]=et[it]);return rt}var reactPropsRegex=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,isPropValid=memoize$1(function(et){return reactPropsRegex.test(et)||et.charCodeAt(0)===111&&et.charCodeAt(1)===110&&et.charCodeAt(2)<91});function sheetForTag(et){if(et.sheet)return et.sheet;for(var tt=0;tt0?charat(characters,--position):0,column--,character===10&&(column=1,line--),character}function next(){return character=position2||token(character)>3?"":" "}function escaping(et,tt){for(;--tt&&next()&&!(character<48||character>102||character>57&&character<65||character>70&&character<97););return slice(et,caret()+(tt<6&&peek()==32&&next()==32))}function delimiter(et){for(;next();)switch(character){case et:return position;case 34:case 39:et!==34&&et!==39&&delimiter(character);break;case 40:et===41&&delimiter(et);break;case 92:next();break}return position}function commenter(et,tt){for(;next()&&et+character!==47+10;)if(et+character===42+42&&peek()===47)break;return"/*"+slice(tt,position-1)+"*"+from(et===47?et:next())}function identifier(et){for(;!token(peek());)next();return slice(et,position)}function compile(et){return dealloc(parse$1("",null,null,null,[""],et=alloc(et),0,[0],et))}function parse$1(et,tt,rt,nt,it,st,at,ot,lt){for(var ut=0,dt=0,vt=at,mt=0,kt=0,pt=0,yt=1,$t=1,gt=1,wt=0,St="",Bt=it,Ot=st,Lt=nt,zt=St;$t;)switch(pt=wt,wt=next()){case 40:if(pt!=108&&charat(zt,vt-1)==58){indexof(zt+=replace(delimit(wt),"&","&\f"),"&\f")!=-1&&(gt=-1);break}case 34:case 39:case 91:zt+=delimit(wt);break;case 9:case 10:case 13:case 32:zt+=whitespace(pt);break;case 92:zt+=escaping(caret()-1,7);continue;case 47:switch(peek()){case 42:case 47:append(comment(commenter(next(),caret()),tt,rt),lt);break;default:zt+="/"}break;case 123*yt:ot[ut++]=strlen(zt)*gt;case 125*yt:case 59:case 0:switch(wt){case 0:case 125:$t=0;case 59+dt:gt==-1&&(zt=replace(zt,/\f/g,"")),kt>0&&strlen(zt)-vt&&append(kt>32?declaration(zt+";",nt,rt,vt-1):declaration(replace(zt," ","")+";",nt,rt,vt-2),lt);break;case 59:zt+=";";default:if(append(Lt=ruleset(zt,tt,rt,ut,dt,it,ot,St,Bt=[],Ot=[],vt),st),wt===123)if(dt===0)parse$1(zt,tt,Lt,Lt,Bt,st,vt,ot,Ot);else switch(mt===99&&charat(zt,3)===110?100:mt){case 100:case 108:case 109:case 115:parse$1(et,Lt,Lt,nt&&append(ruleset(et,Lt,Lt,0,0,it,ot,St,it,Bt=[],vt),Ot),it,Ot,vt,ot,nt?Bt:Ot);break;default:parse$1(zt,Lt,Lt,Lt,[""],Ot,0,ot,Ot)}}ut=dt=kt=0,yt=gt=1,St=zt="",vt=at;break;case 58:vt=1+strlen(zt),kt=pt;default:if(yt<1){if(wt==123)--yt;else if(wt==125&&yt++==0&&prev$1()==125)continue}switch(zt+=from(wt),wt*yt){case 38:gt=dt>0?1:(zt+="\f",-1);break;case 44:ot[ut++]=(strlen(zt)-1)*gt,gt=1;break;case 64:peek()===45&&(zt+=delimit(next())),mt=peek(),dt=vt=strlen(St=zt+=identifier(caret())),wt++;break;case 45:pt===45&&strlen(zt)==2&&(yt=0)}}return st}function ruleset(et,tt,rt,nt,it,st,at,ot,lt,ut,dt){for(var vt=it-1,mt=it===0?st:[""],kt=sizeof(mt),pt=0,yt=0,$t=0;pt0?mt[gt]+" "+wt:replace(wt,/&\f/g,mt[gt])))&&(lt[$t++]=St);return node(et,tt,rt,it===0?RULESET:ot,lt,ut,dt)}function comment(et,tt,rt){return node(et,tt,rt,COMMENT,from(char()),substr(et,2,-2),0)}function declaration(et,tt,rt,nt){return node(et,tt,rt,DECLARATION,substr(et,0,nt),substr(et,nt+1,-1),nt)}function serialize(et,tt){for(var rt="",nt=sizeof(et),it=0;it6)switch(charat(et,tt+1)){case 109:if(charat(et,tt+4)!==45)break;case 102:return replace(et,/(.+:)(.+)-([^]+)/,"$1"+WEBKIT+"$2-$3$1"+MOZ+(charat(et,tt+3)==108?"$3":"$2-$3"))+et;case 115:return~indexof(et,"stretch")?prefix(replace(et,"stretch","fill-available"),tt)+et:et}break;case 4949:if(charat(et,tt+1)!==115)break;case 6444:switch(charat(et,strlen(et)-3-(~indexof(et,"!important")&&10))){case 107:return replace(et,":",":"+WEBKIT)+et;case 101:return replace(et,/(.+:)([^;!]+)(;|!.+)?/,"$1"+WEBKIT+(charat(et,14)===45?"inline-":"")+"box$3$1"+WEBKIT+"$2$3$1"+MS+"$2box$3")+et}break;case 5936:switch(charat(et,tt+11)){case 114:return WEBKIT+et+MS+replace(et,/[svh]\w+-[tblr]{2}/,"tb")+et;case 108:return WEBKIT+et+MS+replace(et,/[svh]\w+-[tblr]{2}/,"tb-rl")+et;case 45:return WEBKIT+et+MS+replace(et,/[svh]\w+-[tblr]{2}/,"lr")+et}return WEBKIT+et+MS+et+et}return et}var prefixer=function(tt,rt,nt,it){if(tt.length>-1&&!tt.return)switch(tt.type){case DECLARATION:tt.return=prefix(tt.value,tt.length);break;case KEYFRAMES:return serialize([copy(tt,{value:replace(tt.value,"@","@"+WEBKIT)})],it);case RULESET:if(tt.length)return combine(tt.props,function(st){switch(match(st,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return serialize([copy(tt,{props:[replace(st,/:(read-\w+)/,":"+MOZ+"$1")]})],it);case"::placeholder":return serialize([copy(tt,{props:[replace(st,/:(plac\w+)/,":"+WEBKIT+"input-$1")]}),copy(tt,{props:[replace(st,/:(plac\w+)/,":"+MOZ+"$1")]}),copy(tt,{props:[replace(st,/:(plac\w+)/,MS+"input-$1")]})],it)}return""})}},defaultStylisPlugins=[prefixer],createCache=function(tt){var rt=tt.key;if(rt==="css"){var nt=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(nt,function(yt){var $t=yt.getAttribute("data-emotion");$t.indexOf(" ")!==-1&&(document.head.appendChild(yt),yt.setAttribute("data-s",""))})}var it=tt.stylisPlugins||defaultStylisPlugins,st={},at,ot=[];at=tt.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+rt+' "]'),function(yt){for(var $t=yt.getAttribute("data-emotion").split(" "),gt=1;gt<$t.length;gt++)st[$t[gt]]=!0;ot.push(yt)});var lt,ut=[compat,removeLabel];{var dt,vt=[stringify,rulesheet(function(yt){dt.insert(yt)})],mt=middleware(ut.concat(it,vt)),kt=function($t){return serialize(compile($t),mt)};lt=function($t,gt,wt,St){dt=wt,kt($t?$t+"{"+gt.styles+"}":gt.styles),St&&(pt.inserted[gt.name]=!0)}}var pt={key:rt,sheet:new StyleSheet({key:rt,container:at,nonce:tt.nonce,speedy:tt.speedy,prepend:tt.prepend,insertionPoint:tt.insertionPoint}),nonce:tt.nonce,inserted:st,registered:{},insert:lt};return pt.sheet.hydrate(ot),pt},isBrowser=!0;function getRegisteredStyles(et,tt,rt){var nt="";return rt.split(" ").forEach(function(it){et[it]!==void 0?tt.push(et[it]+";"):nt+=it+" "}),nt}var registerStyles=function(tt,rt,nt){var it=tt.key+"-"+rt.name;(nt===!1||isBrowser===!1)&&tt.registered[it]===void 0&&(tt.registered[it]=rt.styles)},insertStyles=function(tt,rt,nt){registerStyles(tt,rt,nt);var it=tt.key+"-"+rt.name;if(tt.inserted[rt.name]===void 0){var st=rt;do tt.insert(rt===st?"."+it:"",st,tt.sheet,!0),st=st.next;while(st!==void 0)}};function murmur2(et){for(var tt=0,rt,nt=0,it=et.length;it>=4;++nt,it-=4)rt=et.charCodeAt(nt)&255|(et.charCodeAt(++nt)&255)<<8|(et.charCodeAt(++nt)&255)<<16|(et.charCodeAt(++nt)&255)<<24,rt=(rt&65535)*1540483477+((rt>>>16)*59797<<16),rt^=rt>>>24,tt=(rt&65535)*1540483477+((rt>>>16)*59797<<16)^(tt&65535)*1540483477+((tt>>>16)*59797<<16);switch(it){case 3:tt^=(et.charCodeAt(nt+2)&255)<<16;case 2:tt^=(et.charCodeAt(nt+1)&255)<<8;case 1:tt^=et.charCodeAt(nt)&255,tt=(tt&65535)*1540483477+((tt>>>16)*59797<<16)}return tt^=tt>>>13,tt=(tt&65535)*1540483477+((tt>>>16)*59797<<16),((tt^tt>>>15)>>>0).toString(36)}var unitlessKeys={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},hyphenateRegex=/[A-Z]|^ms/g,animationRegex=/_EMO_([^_]+?)_([^]*?)_EMO_/g,isCustomProperty=function(tt){return tt.charCodeAt(1)===45},isProcessableValue=function(tt){return tt!=null&&typeof tt!="boolean"},processStyleName=memoize$1(function(et){return isCustomProperty(et)?et:et.replace(hyphenateRegex,"-$&").toLowerCase()}),processStyleValue=function(tt,rt){switch(tt){case"animation":case"animationName":if(typeof rt=="string")return rt.replace(animationRegex,function(nt,it,st){return cursor={name:it,styles:st,next:cursor},it})}return unitlessKeys[tt]!==1&&!isCustomProperty(tt)&&typeof rt=="number"&&rt!==0?rt+"px":rt},noComponentSelectorMessage="Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";function handleInterpolation(et,tt,rt){if(rt==null)return"";if(rt.__emotion_styles!==void 0)return rt;switch(typeof rt){case"boolean":return"";case"object":{if(rt.anim===1)return cursor={name:rt.name,styles:rt.styles,next:cursor},rt.name;if(rt.styles!==void 0){var nt=rt.next;if(nt!==void 0)for(;nt!==void 0;)cursor={name:nt.name,styles:nt.styles,next:cursor},nt=nt.next;var it=rt.styles+";";return it}return createStringFromObject(et,tt,rt)}case"function":{if(et!==void 0){var st=cursor,at=rt(et);return cursor=st,handleInterpolation(et,tt,at)}break}}if(tt==null)return rt;var ot=tt[rt];return ot!==void 0?ot:rt}function createStringFromObject(et,tt,rt){var nt="";if(Array.isArray(rt))for(var it=0;it96?testOmitPropsOnStringTag:testOmitPropsOnComponent},composeShouldForwardProps=function(tt,rt,nt){var it;if(rt){var st=rt.shouldForwardProp;it=tt.__emotion_forwardProp&&st?function(at){return tt.__emotion_forwardProp(at)&&st(at)}:st}return typeof it!="function"&&nt&&(it=tt.__emotion_forwardProp),it},Insertion=function(tt){var rt=tt.cache,nt=tt.serialized,it=tt.isStringTag;return registerStyles(rt,nt,it),useInsertionEffectAlwaysWithSyncFallback(function(){return insertStyles(rt,nt,it)}),null},createStyled$1=function et(tt,rt){var nt=tt.__emotion_real===tt,it=nt&&tt.__emotion_base||tt,st,at;rt!==void 0&&(st=rt.label,at=rt.target);var ot=composeShouldForwardProps(tt,rt,nt),lt=ot||getDefaultShouldForwardProp(it),ut=!lt("as");return function(){var dt=arguments,vt=nt&&tt.__emotion_styles!==void 0?tt.__emotion_styles.slice(0):[];if(st!==void 0&&vt.push("label:"+st+";"),dt[0]==null||dt[0].raw===void 0)vt.push.apply(vt,dt);else{vt.push(dt[0][0]);for(var mt=dt.length,kt=1;kt{const tt=et||"Success",rt="uniqueToastId";B.isActive(rt)||B.success(jsxRuntimeExports.jsxs(StyledDiv,{children:[jsxRuntimeExports.jsx(MdCheckCircle,{color:colors.white,fontSize:24}),tt]}),{toastId:rt,autoClose:5e3,icon:!1,closeButton:!1})},defaultData$6={addNodeModalData:null,currentModals:{budgetExplanation:!1,sourcesTable:!1,addItem:!1,addType:!1,addContent:!1,editTopic:!1,addEdge:!1,addSource:!1,settings:!1,mergeTopic:!1,briefDescription:!1,editNodeName:!1,removeNode:!1,mergeToNode:!1,removeNodeType:!1,addEdgeToNode:!1,blueprintGraph:!1,changeNodeType:!1,feedback:!1,createBounty:!1,onboardingFlow:!1}},useModalStore=create(et=>({...defaultData$6,close:tt=>{et(rt=>({addNodeModalData:null,currentModals:{...rt.currentModals,[tt]:!1}}))},open:tt=>{et(rt=>({currentModals:{...rt.currentModals,[tt]:!0}}))}})),useModal=et=>{const{open:tt,close:rt,currentModals:nt}=useModalStore();return{close:()=>rt(et),open:()=>tt(et),visible:nt[et]}},ClearIcon=et=>jsxRuntimeExports.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 32 32",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("g",{id:"Property 1=press",children:jsxRuntimeExports.jsx("path",{id:"close",d:"M16 17.2833L11.5083 21.775C11.3403 21.943 11.1264 22.0271 10.8667 22.0271C10.6069 22.0271 10.393 21.943 10.225 21.775C10.0569 21.6069 9.9729 21.393 9.9729 21.1333C9.9729 20.8736 10.0569 20.6597 10.225 20.4917L14.7167 16L10.225 11.5083C10.0569 11.3403 9.9729 11.1264 9.9729 10.8667C9.9729 10.6069 10.0569 10.393 10.225 10.225C10.393 10.0569 10.6069 9.9729 10.8667 9.9729C11.1264 9.9729 11.3403 10.0569 11.5083 10.225L16 14.7167L20.4917 10.225C20.6597 10.0569 20.8736 9.9729 21.1333 9.9729C21.393 9.9729 21.6069 10.0569 21.775 10.225C21.943 10.393 22.0271 10.6069 22.0271 10.8667C22.0271 11.1264 21.943 11.3403 21.775 11.5083L17.2833 16L21.775 20.4917C21.943 20.6597 22.0271 20.8736 22.0271 21.1333C22.0271 21.393 21.943 21.6069 21.775 21.775C21.6069 21.943 21.393 22.0271 21.1333 22.0271C20.8736 22.0271 20.6597 21.943 20.4917 21.775L16 17.2833Z",fill:"currentColor"})})}),scaleAnimation=Ue` +`,SuccessNotify=et=>{const tt=et||"Success",rt="uniqueToastId";B.isActive(rt)||B.success(jsxRuntimeExports.jsxs(StyledDiv,{children:[jsxRuntimeExports.jsx(MdCheckCircle,{color:colors.white,fontSize:24}),tt]}),{toastId:rt,autoClose:5e3,icon:!1,closeButton:!1})},defaultData$5={addNodeModalData:null,currentModals:{budgetExplanation:!1,sourcesTable:!1,addItem:!1,addType:!1,addContent:!1,editTopic:!1,addEdge:!1,addSource:!1,settings:!1,mergeTopic:!1,briefDescription:!1,editNodeName:!1,removeNode:!1,mergeToNode:!1,removeNodeType:!1,addEdgeToNode:!1,blueprintGraph:!1,changeNodeType:!1,feedback:!1,createBounty:!1,onboardingFlow:!1}},useModalStore=create(et=>({...defaultData$5,close:tt=>{et(rt=>({addNodeModalData:null,currentModals:{...rt.currentModals,[tt]:!1}}))},open:tt=>{et(rt=>({currentModals:{...rt.currentModals,[tt]:!0}}))}})),useModal=et=>{const{open:tt,close:rt,currentModals:nt}=useModalStore();return{close:()=>rt(et),open:()=>tt(et),visible:nt[et]}},ClearIcon=et=>jsxRuntimeExports.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 32 32",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("g",{id:"Property 1=press",children:jsxRuntimeExports.jsx("path",{id:"close",d:"M16 17.2833L11.5083 21.775C11.3403 21.943 11.1264 22.0271 10.8667 22.0271C10.6069 22.0271 10.393 21.943 10.225 21.775C10.0569 21.6069 9.9729 21.393 9.9729 21.1333C9.9729 20.8736 10.0569 20.6597 10.225 20.4917L14.7167 16L10.225 11.5083C10.0569 11.3403 9.9729 11.1264 9.9729 10.8667C9.9729 10.6069 10.0569 10.393 10.225 10.225C10.393 10.0569 10.6069 9.9729 10.8667 9.9729C11.1264 9.9729 11.3403 10.0569 11.5083 10.225L16 14.7167L20.4917 10.225C20.6597 10.0569 20.8736 9.9729 21.1333 9.9729C21.393 9.9729 21.6069 10.0569 21.775 10.225C21.943 10.393 22.0271 10.6069 22.0271 10.8667C22.0271 11.1264 21.943 11.3403 21.775 11.5083L17.2833 16L21.775 20.4917C21.943 20.6597 22.0271 20.8736 22.0271 21.1333C22.0271 21.393 21.943 21.6069 21.775 21.775C21.6069 21.943 21.393 22.0271 21.1333 22.0271C20.8736 22.0271 20.6597 21.943 20.4917 21.775L16 17.2833Z",fill:"currentColor"})})}),scaleAnimation=Ue` 0% { transform: scale(0.8); } @@ -711,7 +711,7 @@ PROCEED WITH CAUTION! [zustand devtools middleware] Unsupported __setState action format. When using 'store' option in devtools(), the 'state' should have only one key, which is a value of 'store' that was passed in devtools(), and value of this only key should be a state object. Example: { "type": "__setState", "state": { "abc123Store": { "foo": "bar" } } } - `);const wt=gt.state[ot];if(wt==null)return;JSON.stringify(it.getState())!==JSON.stringify(wt)&&kt(wt);return}it.dispatchFromDevtools&&typeof it.dispatch=="function"&&it.dispatch(gt)});case"DISPATCH":switch(yt.payload.type){case"RESET":return kt(pt),ot===void 0?dt==null?void 0:dt.init(it.getState()):dt==null?void 0:dt.init(getTrackedConnectionState(lt.name));case"COMMIT":if(ot===void 0){dt==null||dt.init(it.getState());return}return dt==null?void 0:dt.init(getTrackedConnectionState(lt.name));case"ROLLBACK":return parseJsonThen(yt.state,gt=>{if(ot===void 0){kt(gt),dt==null||dt.init(it.getState());return}kt(gt[ot]),dt==null||dt.init(getTrackedConnectionState(lt.name))});case"JUMP_TO_STATE":case"JUMP_TO_ACTION":return parseJsonThen(yt.state,gt=>{if(ot===void 0){kt(gt);return}JSON.stringify(it.getState())!==JSON.stringify(gt[ot])&&kt(gt[ot])});case"IMPORT_STATE":{const{nextLiftedState:gt}=yt.payload,wt=($t=gt.computedStates.slice(-1)[0])==null?void 0:$t.state;if(!wt)return;kt(ot===void 0?wt:wt[ot]),dt==null||dt.send(null,gt);return}case"PAUSE_RECORDING":return mt=!mt}return}}),pt},devtools=devtoolsImpl,parseJsonThen=(et,tt)=>{let rt;try{rt=JSON.parse(et)}catch(nt){console.error("[zustand devtools middleware] Could not parse the received json",nt)}rt!==void 0&&tt(rt)},fetchGraphData=async(et,tt,rt=!1,nt,it)=>fetchNodes(et,tt,rt,nt),fetchNodes=async(et,tt,rt=!1,nt,it)=>{const st=new URLSearchParams(tt).toString(),at=rt?"/prediction/graph/search/latest?":`/prediction/graph/search?${st}`,ot=async()=>{const lt=await getLSat();try{const ut=await api$1.get(at,{Authorization:lt},nt);return updateBudget(et),ut}catch(ut){if(ut.status===402)return await payLsat(et),fetchNodes(et,tt,rt,nt);throw ut}};return!tt.word||isDevelopment&&!isE2E?api$1.get(`${at}&free=true`,void 0,nt):ot()},fetchNodeEdges=async(et,tt,rt=5,nt={})=>{try{const{sortBy:it="edge_count",includeProperties:st=!0,includeContent:at=!0,depth:ot=1,useSubGraph:lt=!0,nodeType:ut=[]}=nt,dt=new URLSearchParams({skip:tt.toString(),limit:rt.toString(),sort_by:it,include_properties:st.toString(),includeContent:at.toString(),depth:ot.toString(),top_node_count:"5",use_sub_graph:lt.toString(),...ut.length>0&&{node_type:JSON.stringify(ut)}}).toString();return await api$1.get(`/prediction/graph/edges/${et}?${dt}`)}catch(it){return console.error(it),null}},defaultData$5={currentSearch:"",searchFormValue:"",flagErrorIsOpen:!1,universeQuestionIsOpen:!1,hasBudgetExplanationModalBeSeen:!1,relevanceIsSelected:!1,secondarySidebarActiveTab:"",sidebarIsOpen:!0,theme:"light",transcriptIsOpen:!1,appMetaData:null,currentPlayingAudio:null,showCollapseButton:!0,selectedColor:"#962777",selectedIcon:"ConstructionIcon"},useAppStore=create((et,tt)=>({...defaultData$5,clearSearch:()=>et({currentSearch:""}),setCurrentSearch:rt=>et({currentSearch:rt}),setSearchFormValue:rt=>et({searchFormValue:rt}),setFlagErrorOpen:rt=>et({flagErrorIsOpen:rt}),setRelevanceSelected:rt=>et({relevanceIsSelected:rt}),setCurrentPlayingAudio:rt=>et({currentPlayingAudio:rt}),setSecondarySidebarActiveTab:rt=>et({secondarySidebarActiveTab:rt}),setSidebarOpen:rt=>et({sidebarIsOpen:rt,transcriptIsOpen:rt?tt().transcriptIsOpen:!1}),setTranscriptOpen:rt=>et({transcriptIsOpen:rt}),setUniverseQuestionIsOpen:()=>et({universeQuestionIsOpen:!tt().universeQuestionIsOpen}),setAppMetaData:rt=>et({appMetaData:rt}),setShowCollapseButton:rt=>et({showCollapseButton:rt}),setSelectedColor:rt=>et({selectedColor:rt}),setSelectedIcon:rt=>et({selectedIcon:rt})})),QuestionNode={edge_count:1,name:"",node_type:"Question",score:0,x:0,y:0,z:0,label:"",scale:2},defaultData$4={aiSummaryAnswers:{},aiRefId:"",newLoading:null,dataInitial:null};let abortController$1=null;const useAiSummaryStore=create()(devtools((et,tt)=>({...defaultData$4,setAiSummaryAnswer:(rt,nt)=>{const it=tt().aiSummaryAnswers;it[rt]={...it[rt]||{},...nt};const st=structuredClone(it);et({aiSummaryAnswers:st})},setNewLoading:rt=>{et({newLoading:rt})},resetAiSummaryAnswer:()=>{et({aiSummaryAnswers:{},aiRefId:""})},getAiSummaryAnswer:rt=>tt().aiSummaryAnswers[rt].answer||"",setAiRefId:rt=>et({aiRefId:rt}),fetchAIData:async(rt,nt,it="")=>{var Ot;const{filters:st,addNewNode:at}=useDataStore.getState(),ot=st.skip,lt=st.limit,{currentSearch:ut}=useAppStore.getState(),{setAiSummaryAnswer:dt,setNewLoading:vt,aiRefId:mt}=tt(),kt={ai_summary:String(!!it)};at({nodes:[{...QuestionNode,name:it,ref_id:it}],edges:[]}),it&&vt({question:it,answerLoading:!0}),abortController$1&&abortController$1.abort("abort");const pt=new AbortController,{signal:yt}=pt;abortController$1=pt;const{node_type:$t,...gt}=st,wt=it||ut,St=lodashExports.isEqual(st,defaultFilters)&&!wt,Bt={...gt,...kt,skip:String(ot===0?ot*lt:ot*lt+1),limit:wt?"25":String(lt),...$t.length>0?{node_type:JSON.stringify($t)}:{},...wt?{word:wt}:{},...mt&&it?{previous_search_ref_id:mt}:{},...!wt&&!it?{sort_by:"date_added_to_graph"}:{}};try{const Lt=await fetchGraphData(rt,Bt,St,yt,nt);if((Ot=Lt==null?void 0:Lt.query_data)!=null&&Ot.ref_id){useAiSummaryStore.setState({aiRefId:Lt.query_data.ref_id});const{aiSummaryAnswers:zt}=useAiSummaryStore.getState(),{answer:Vt}=zt[Lt.query_data.ref_id]||{};dt(Lt.query_data.ref_id,{question:it,answer:Vt||"",answerLoading:!Vt,sourcesLoading:!Vt,shouldRender:!0}),vt(null)}Lt!=null&&Lt.nodes&&et({dataInitial:Lt})}catch(Lt){console.error(Lt)}},getKeyExist:rt=>rt in tt().aiSummaryAnswers}))),useHasAiChats=()=>useAiSummaryStore(et=>Object.values(et.aiSummaryAnswers).filter(tt=>tt.shouldRender).length||!!et.newLoading),useHasAiChatsResponseLoading=()=>useAiSummaryStore(et=>{var rt;const tt=et.aiSummaryAnswers;return!!et.newLoading||((rt=Object.values(tt).at(-1))==null?void 0:rt.answerLoading)}),defaultFilters={skip:0,limit:300,depth:"2",sort_by:"score",include_properties:"true",top_node_count:"50",includeContent:"true",node_type:[],search_method:"vector"},defaultData$3={categoryFilter:null,dataInitial:null,runningProjectMessages:[],filters:defaultFilters,isFetching:!1,isLoadingNew:!1,queuedSources:null,selectedTimestamp:null,sources:null,sidebarFilter:"all",sidebarFilters:[],trendingTopics:[],sidebarFilterCounts:[],stats:null,splashDataLoading:!0,abortRequest:!1,dataNew:null,seedQuestions:null,runningProjectId:"",hideNodeDetails:!1,nodeTypes:[],linkTypes:[],nodesNormalized:new Map,linksNormalized:new Map};let abortController=null;const useDataStore=create()(devtools((et,tt)=>({...defaultData$3,fetchData:async(rt,nt,it="")=>{var Ot;const{filters:st,addNewNode:at}=tt(),ot=st.skip,lt=st.limit,{currentSearch:ut}=useAppStore.getState(),{setAiSummaryAnswer:dt,setNewLoading:vt,aiRefId:mt}=useAiSummaryStore.getState(),kt={ai_summary:String(!!it)};it||et(ot===0?{isFetching:!0}:{isLoadingNew:!0}),it&&vt({question:it,answerLoading:!0}),abortController&&abortController.abort("abort");const pt=new AbortController,{signal:yt}=pt;abortController=pt;const{node_type:$t,...gt}=st,wt=it||ut,St=lodashExports.isEqual(st,defaultData$3.filters)&&!wt,Bt={...gt,...kt,skip:String(ot===0?ot*lt:ot*lt+1),limit:wt?"25":String(lt),...$t.length>0?{node_type:JSON.stringify($t)}:{},...wt?{word:wt}:{},...mt&&it?{previous_search_ref_id:mt}:{},...!wt&&!it?{sort_by:"date_added_to_graph"}:{}};try{const Lt=await fetchGraphData(rt,Bt,St,yt,nt);if((Ot=Lt==null?void 0:Lt.query_data)!=null&&Ot.ref_id){useAiSummaryStore.setState({aiRefId:Lt.query_data.ref_id});const{aiSummaryAnswers:zt}=useAiSummaryStore.getState(),{answer:Vt}=zt[Lt.query_data.ref_id]||{};dt(Lt.query_data.ref_id,{question:it,answer:Vt||"",answerLoading:!Vt,sourcesLoading:!Vt,shouldRender:!0}),vt(null)}Lt!=null&&Lt.nodes&&at(Lt),et({isFetching:!1,isLoadingNew:!1,splashDataLoading:!1})}catch(Lt){console.error(Lt),Lt!=="abort"&&et({isFetching:!1,isLoadingNew:!1})}},addNewNode:rt=>{const{dataInitial:nt,filters:it,nodesNormalized:st,linksNormalized:at}=tt();if(!(rt!=null&&rt.nodes))return;const ot=st||new Map,lt=at||new Map,ut=it.node_type.length?rt.nodes.filter(Ot=>it.node_type.includes(Ot.node_type)):rt.nodes,dt=[];ut.forEach(Ot=>{ot.has(Ot.ref_id)||(ot.set(Ot.ref_id,{...Ot,sources:[],targets:[]}),dt.push(Ot))});const mt=[...(nt==null?void 0:nt.nodes)||[],...dt],kt=[];(rt.edges||[]).forEach(Ot=>{if(!lt.has(Ot.ref_id)&&ot.has(Ot.source)&&ot.has(Ot.target)){lt.set(Ot.ref_id,Ot),kt.push(Ot);const Lt=ot.get(Ot.source),zt=ot.get(Ot.target);Lt&&zt&&(Lt.targets?Lt.targets.push(Ot.target):Lt.targets=[Ot.target],zt.sources?zt.sources.push(Ot.source):zt.sources=[Ot.source],Lt.edgeTypes=[...new Set([...Lt.edgeTypes||[],Ot.edge_type])],zt.edgeTypes=[...new Set([...zt.edgeTypes||[],Ot.edge_type])])}});const $t=[...(nt==null?void 0:nt.links)||[],...kt],gt=[...new Set(mt.map(Ot=>Ot.node_type))],wt=[...new Set($t.map(Ot=>Ot.edge_type))],St=["all",...gt.map(Ot=>Ot.toLowerCase())],Bt=St.map(Ot=>({name:Ot,count:mt.filter(Lt=>{var zt;return Ot==="all"||((zt=Lt.node_type)==null?void 0:zt.toLowerCase())===Ot}).length}));et({dataInitial:{nodes:mt,links:$t},dataNew:{nodes:dt,links:kt},nodeTypes:gt,linkTypes:wt,sidebarFilters:St,sidebarFilterCounts:Bt,nodesNormalized:ot,linksNormalized:lt})},abortFetchData:()=>{abortController&&abortController.abort("abort")},resetGraph:()=>{const{setAbortRequests:rt}=tt(),{setBudget:nt}=useUserStore.getState();et({filters:defaultData$3.filters,dataInitial:null,dataNew:null}),tt().fetchData(nt,rt)},resetData:()=>{et({dataInitial:null,sidebarFilter:"all",sidebarFilters:[],sidebarFilterCounts:[],dataNew:null,runningProjectId:"",nodeTypes:[],nodesNormalized:new Map,linksNormalized:new Map})},nextPage:()=>{const{filters:rt,fetchData:nt,setAbortRequests:it}=tt(),{setBudget:st}=useUserStore.getState();et({filters:{...rt,skip:rt.skip+1}}),nt(st,it)},resetDataNew:()=>et({dataNew:null}),setFilters:rt=>{const{setBudget:nt}=useUserStore.getState();et(it=>({filters:{...it.filters,...rt,skip:0}})),tt().fetchData(nt,tt().setAbortRequests)},setSidebarFilterCounts:rt=>et({sidebarFilterCounts:rt}),setTrendingTopics:rt=>et({trendingTopics:rt}),setStats:rt=>et({stats:rt}),setIsFetching:rt=>et({isFetching:rt}),setCategoryFilter:rt=>et({categoryFilter:rt}),setQueuedSources:rt=>et({queuedSources:rt}),setSidebarFilter:rt=>et({sidebarFilter:rt}),setSelectedTimestamp:rt=>et({selectedTimestamp:rt}),setSources:rt=>et({sources:rt}),setHideNodeDetails:rt=>et({hideNodeDetails:rt}),setSeedQuestions:rt=>et({seedQuestions:rt}),updateNode:rt=>{const{nodesNormalized:nt}=tt(),it=new Map(nt);it.set(rt.ref_id,rt),et({nodesNormalized:it})},removeNode:rt=>{console.log(rt)},setRunningProjectId:rt=>et({runningProjectId:rt,runningProjectMessages:[]}),setRunningProjectMessages:rt=>{const{runningProjectMessages:nt}=tt();et({runningProjectMessages:[...nt,rt]})},resetRunningProjectMessages:()=>et({runningProjectMessages:[]}),setAbortRequests:rt=>et({abortRequest:rt})}))),useFilteredNodes=()=>useDataStore(et=>{var tt,rt;return et.sidebarFilter==="all"?((tt=et.dataInitial)==null?void 0:tt.nodes)||[]:(((rt=et.dataInitial)==null?void 0:rt.nodes)||[]).filter(nt=>{var it;return((it=nt.node_type)==null?void 0:it.toLowerCase())===et.sidebarFilter.toLowerCase()})}),useNodeTypes=()=>useDataStore(et=>et.nodeTypes),useNormalizedNode=et=>{const tt=useDataStore(rt=>rt.nodesNormalized);return et?tt.get(et):null},defaultData$2={trendingTopicsFeatureFlag:!0,queuedSourcesFeatureFlag:!1,v2FeatureFlag:!1,customSchemaFeatureFlag:!1,graphBluePrintFeatureFlag:!1,changeNodeTypeFeatureFlag:!1,realtimeGraphFeatureFlag:!1,userFeedbackFeatureFlag:!1,chatInterfaceFeatureFlag:!1,fastFiltersFeatureFlag:!1},useFeatureFlagStore=create(et=>({...defaultData$2,setTrendingTopicsFeatureFlag:tt=>et({trendingTopicsFeatureFlag:tt}),setV2FeatureFlag:tt=>et({v2FeatureFlag:tt}),setQueuedSourcesFeatureFlag:tt=>et({queuedSourcesFeatureFlag:tt}),setCustomSchemaFeatureFlag:tt=>et({customSchemaFeatureFlag:tt}),setGraphBluePrintFeatureFlag:tt=>et({graphBluePrintFeatureFlag:tt}),setChangeNodeTypeFeatureFlag:tt=>et({changeNodeTypeFeatureFlag:tt}),setRealtimeGraphFeatureFlag:tt=>et({realtimeGraphFeatureFlag:tt}),setUserFeedbackFeatureFlag:tt=>et({userFeedbackFeatureFlag:tt}),setChatInterfaceFeatureFlag:tt=>et({chatInterfaceFeatureFlag:tt}),setFastFiltersFeatureFlag:tt=>et({fastFiltersFeatureFlag:tt})})),isWebView=()=>(navigator.userAgent||navigator.vendor||window.opera)==="Sphinx",isAndroid=()=>navigator.userAgent.includes("Android"),defaultData$1={schemas:[],links:[],normalizedSchemasByType:{}},useSchemaStore=create()(devtools((et,tt)=>({...defaultData$1,setSchemas:rt=>{const nt=rt.reduce((it,st)=>(it[st.type]=st,it),{});et({schemas:rt.map(it=>({...it})),normalizedSchemasByType:nt})},setSchemaLinks:rt=>{et({links:rt})},getPrimaryColorByType:rt=>{const nt=tt().normalizedSchemasByType[rt];return nt?nt.primary_color:void 0},getIndexByType:rt=>{const nt=tt().normalizedSchemasByType[rt];return nt?nt.index:"name"},getNodeKeysByType:rt=>{const nt=tt().normalizedSchemasByType[rt];return nt?nt.index||nt.node_key:void 0},getSchemaByType:rt=>tt().normalizedSchemasByType[rt]})));function r(et){var tt,rt,nt="";if(typeof et=="string"||typeof et=="number")nt+=et;else if(typeof et=="object")if(Array.isArray(et))for(tt=0;tt{const[tt,rt]=reactExports.useState(0),nt=et.filter(it=>it.value!=="0");return reactExports.useEffect(()=>{const it=setInterval(()=>rt(st=>(st+1)%et.length),1e3);return()=>clearInterval(it)},[tt]),jsxRuntimeExports.jsxs(TextWrapper$1,{children:[jsxRuntimeExports.jsx(Text,{className:"loading",children:"LOADING"}),jsxRuntimeExports.jsx(Flex,{className:"value-wrapper",children:nt.map(({key:it,value:st},at)=>jsxRuntimeExports.jsx("div",{className:clsx("value",{show:tt===at}),children:st},it))}),jsxRuntimeExports.jsx(Flex,{children:nt.map(({key:it,label:st},at)=>jsxRuntimeExports.jsx(Flex,{className:clsx("label-wrapper",{show:tt===at}),children:jsxRuntimeExports.jsx("div",{className:"label",children:st})},it))})]})},TextWrapper$1=styled$3.div` + `);const wt=gt.state[ot];if(wt==null)return;JSON.stringify(it.getState())!==JSON.stringify(wt)&&kt(wt);return}it.dispatchFromDevtools&&typeof it.dispatch=="function"&&it.dispatch(gt)});case"DISPATCH":switch(yt.payload.type){case"RESET":return kt(pt),ot===void 0?dt==null?void 0:dt.init(it.getState()):dt==null?void 0:dt.init(getTrackedConnectionState(lt.name));case"COMMIT":if(ot===void 0){dt==null||dt.init(it.getState());return}return dt==null?void 0:dt.init(getTrackedConnectionState(lt.name));case"ROLLBACK":return parseJsonThen(yt.state,gt=>{if(ot===void 0){kt(gt),dt==null||dt.init(it.getState());return}kt(gt[ot]),dt==null||dt.init(getTrackedConnectionState(lt.name))});case"JUMP_TO_STATE":case"JUMP_TO_ACTION":return parseJsonThen(yt.state,gt=>{if(ot===void 0){kt(gt);return}JSON.stringify(it.getState())!==JSON.stringify(gt[ot])&&kt(gt[ot])});case"IMPORT_STATE":{const{nextLiftedState:gt}=yt.payload,wt=($t=gt.computedStates.slice(-1)[0])==null?void 0:$t.state;if(!wt)return;kt(ot===void 0?wt:wt[ot]),dt==null||dt.send(null,gt);return}case"PAUSE_RECORDING":return mt=!mt}return}}),pt},devtools=devtoolsImpl,parseJsonThen=(et,tt)=>{let rt;try{rt=JSON.parse(et)}catch(nt){console.error("[zustand devtools middleware] Could not parse the received json",nt)}rt!==void 0&&tt(rt)},fetchGraphData=async(et,tt,rt=!1,nt,it)=>fetchNodes(et,tt,rt,nt),fetchNodes=async(et,tt,rt=!1,nt,it)=>{const st=new URLSearchParams(tt).toString(),at=rt?"/prediction/graph/search/latest?":`/prediction/graph/search?${st}`,ot=async()=>{const lt=await getLSat();try{const ut=await api$1.get(at,{Authorization:lt},nt);return updateBudget(et),ut}catch(ut){if(ut.status===402)return await payLsat(et),fetchNodes(et,tt,rt,nt);throw ut}};return!tt.word||isDevelopment&&!isE2E?api$1.get(`${at}&free=true`,void 0,nt):ot()},fetchNodeEdges=async(et,tt,rt=5,nt={})=>{try{const{sortBy:it="edge_count",includeProperties:st=!0,includeContent:at=!0,depth:ot=1,useSubGraph:lt=!0,nodeType:ut=[]}=nt,dt=new URLSearchParams({skip:tt.toString(),limit:rt.toString(),sort_by:it,include_properties:st.toString(),includeContent:at.toString(),depth:ot.toString(),top_node_count:"5",use_sub_graph:lt.toString(),...ut.length>0&&{node_type:JSON.stringify(ut)}}).toString();return await api$1.get(`/prediction/graph/edges/${et}?${dt}`)}catch(it){return console.error(it),null}},defaultData$4={currentSearch:"",searchFormValue:"",flagErrorIsOpen:!1,universeQuestionIsOpen:!1,hasBudgetExplanationModalBeSeen:!1,relevanceIsSelected:!1,secondarySidebarActiveTab:"",sidebarIsOpen:!0,theme:"light",transcriptIsOpen:!1,appMetaData:null,currentPlayingAudio:null,showCollapseButton:!0,selectedColor:"#962777",selectedIcon:"ConstructionIcon"},useAppStore=create((et,tt)=>({...defaultData$4,clearSearch:()=>et({currentSearch:""}),setCurrentSearch:rt=>et({currentSearch:rt}),setSearchFormValue:rt=>et({searchFormValue:rt}),setFlagErrorOpen:rt=>et({flagErrorIsOpen:rt}),setRelevanceSelected:rt=>et({relevanceIsSelected:rt}),setCurrentPlayingAudio:rt=>et({currentPlayingAudio:rt}),setSecondarySidebarActiveTab:rt=>et({secondarySidebarActiveTab:rt}),setSidebarOpen:rt=>et({sidebarIsOpen:rt,transcriptIsOpen:rt?tt().transcriptIsOpen:!1}),setTranscriptOpen:rt=>et({transcriptIsOpen:rt}),setUniverseQuestionIsOpen:()=>et({universeQuestionIsOpen:!tt().universeQuestionIsOpen}),setAppMetaData:rt=>et({appMetaData:rt}),setShowCollapseButton:rt=>et({showCollapseButton:rt}),setSelectedColor:rt=>et({selectedColor:rt}),setSelectedIcon:rt=>et({selectedIcon:rt})})),QuestionNode={edge_count:1,name:"",node_type:"Question",score:0,x:0,y:0,z:0,label:"",scale:2},defaultData$3={aiSummaryAnswers:{},aiRefId:"",newLoading:null,dataInitial:null};let abortController$1=null;const useAiSummaryStore=create()(devtools((et,tt)=>({...defaultData$3,setAiSummaryAnswer:(rt,nt)=>{const it=tt().aiSummaryAnswers;it[rt]={...it[rt]||{},...nt};const st=structuredClone(it);et({aiSummaryAnswers:st})},setNewLoading:rt=>{et({newLoading:rt})},resetAiSummaryAnswer:()=>{et({aiSummaryAnswers:{},aiRefId:""})},getAiSummaryAnswer:rt=>tt().aiSummaryAnswers[rt].answer||"",setAiRefId:rt=>et({aiRefId:rt}),fetchAIData:async(rt,nt,it="")=>{var Ot;const{filters:st,addNewNode:at}=useDataStore.getState(),ot=st.skip,lt=st.limit,{currentSearch:ut}=useAppStore.getState(),{setAiSummaryAnswer:dt,setNewLoading:vt,aiRefId:mt}=tt(),kt={ai_summary:String(!!it)};at({nodes:[{...QuestionNode,name:it,ref_id:it}],edges:[]}),it&&vt({question:it,answerLoading:!0}),abortController$1&&abortController$1.abort("abort");const pt=new AbortController,{signal:yt}=pt;abortController$1=pt;const{node_type:$t,...gt}=st,wt=it||ut,St=lodashExports.isEqual(st,defaultFilters)&&!wt,Bt={...gt,...kt,skip:String(ot===0?ot*lt:ot*lt+1),limit:wt?"25":String(lt),...$t.length>0?{node_type:JSON.stringify($t)}:{},...wt?{word:wt}:{},...mt&&it?{previous_search_ref_id:mt}:{},...!wt&&!it?{sort_by:"date_added_to_graph"}:{}};try{const Lt=await fetchGraphData(rt,Bt,St,yt,nt);if((Ot=Lt==null?void 0:Lt.query_data)!=null&&Ot.ref_id){useAiSummaryStore.setState({aiRefId:Lt.query_data.ref_id});const{aiSummaryAnswers:zt}=useAiSummaryStore.getState(),{answer:Vt}=zt[Lt.query_data.ref_id]||{};dt(Lt.query_data.ref_id,{question:it,answer:Vt||"",answerLoading:!Vt,sourcesLoading:!Vt,shouldRender:!0}),vt(null)}Lt!=null&&Lt.nodes&&et({dataInitial:Lt})}catch(Lt){console.error(Lt)}},getKeyExist:rt=>rt in tt().aiSummaryAnswers}))),useHasAiChats=()=>useAiSummaryStore(et=>Object.values(et.aiSummaryAnswers).filter(tt=>tt.shouldRender).length||!!et.newLoading),useHasAiChatsResponseLoading=()=>useAiSummaryStore(et=>{var rt;const tt=et.aiSummaryAnswers;return!!et.newLoading||((rt=Object.values(tt).at(-1))==null?void 0:rt.answerLoading)}),defaultFilters={skip:0,limit:300,depth:"2",sort_by:"score",include_properties:"true",top_node_count:"50",includeContent:"true",node_type:[],search_method:"vector"},defaultData$2={categoryFilter:null,dataInitial:null,runningProjectMessages:[],filters:defaultFilters,isFetching:!1,isLoadingNew:!1,queuedSources:null,selectedTimestamp:null,sources:null,sidebarFilter:"all",sidebarFilters:[],trendingTopics:[],sidebarFilterCounts:[],stats:null,splashDataLoading:!0,abortRequest:!1,dataNew:null,seedQuestions:null,runningProjectId:"",hideNodeDetails:!1,nodeTypes:[],linkTypes:[],nodesNormalized:new Map,linksNormalized:new Map};let abortController=null;const useDataStore=create()(devtools((et,tt)=>({...defaultData$2,fetchData:async(rt,nt,it="")=>{var Ot;const{filters:st,addNewNode:at}=tt(),ot=st.skip,lt=st.limit,{currentSearch:ut}=useAppStore.getState(),{setAiSummaryAnswer:dt,setNewLoading:vt,aiRefId:mt}=useAiSummaryStore.getState(),kt={ai_summary:String(!!it)};it||et(ot===0?{isFetching:!0}:{isLoadingNew:!0}),it&&vt({question:it,answerLoading:!0}),abortController&&abortController.abort("abort");const pt=new AbortController,{signal:yt}=pt;abortController=pt;const{node_type:$t,...gt}=st,wt=it||ut,St=lodashExports.isEqual(st,defaultData$2.filters)&&!wt,Bt={...gt,...kt,skip:String(ot===0?ot*lt:ot*lt+1),limit:wt?"25":String(lt),...$t.length>0?{node_type:JSON.stringify($t)}:{},...wt?{word:wt}:{},...mt&&it?{previous_search_ref_id:mt}:{},...!wt&&!it?{sort_by:"date_added_to_graph"}:{}};try{const Lt=await fetchGraphData(rt,Bt,St,yt,nt);if((Ot=Lt==null?void 0:Lt.query_data)!=null&&Ot.ref_id){useAiSummaryStore.setState({aiRefId:Lt.query_data.ref_id});const{aiSummaryAnswers:zt}=useAiSummaryStore.getState(),{answer:Vt}=zt[Lt.query_data.ref_id]||{};dt(Lt.query_data.ref_id,{question:it,answer:Vt||"",answerLoading:!Vt,sourcesLoading:!Vt,shouldRender:!0}),vt(null)}Lt!=null&&Lt.nodes&&at(Lt),et({isFetching:!1,isLoadingNew:!1,splashDataLoading:!1})}catch(Lt){console.error(Lt),Lt!=="abort"&&et({isFetching:!1,isLoadingNew:!1})}},addNewNode:rt=>{const{dataInitial:nt,filters:it,nodesNormalized:st,linksNormalized:at}=tt();if(!(rt!=null&&rt.nodes))return;const ot=st||new Map,lt=at||new Map,ut=it.node_type.length?rt.nodes.filter(Ot=>it.node_type.includes(Ot.node_type)):rt.nodes,dt=[];ut.forEach(Ot=>{ot.has(Ot.ref_id)||(ot.set(Ot.ref_id,{...Ot,sources:[],targets:[]}),dt.push(Ot))});const mt=[...(nt==null?void 0:nt.nodes)||[],...dt],kt=[];(rt.edges||[]).forEach(Ot=>{if(!lt.has(Ot.ref_id)&&ot.has(Ot.source)&&ot.has(Ot.target)){lt.set(Ot.ref_id,Ot),kt.push(Ot);const Lt=ot.get(Ot.source),zt=ot.get(Ot.target);Lt&&zt&&(Lt.targets?Lt.targets.push(Ot.target):Lt.targets=[Ot.target],zt.sources?zt.sources.push(Ot.source):zt.sources=[Ot.source],Lt.edgeTypes=[...new Set([...Lt.edgeTypes||[],Ot.edge_type])],zt.edgeTypes=[...new Set([...zt.edgeTypes||[],Ot.edge_type])])}});const $t=[...(nt==null?void 0:nt.links)||[],...kt],gt=[...new Set(mt.map(Ot=>Ot.node_type))],wt=[...new Set($t.map(Ot=>Ot.edge_type))],St=["all",...gt.map(Ot=>Ot.toLowerCase())],Bt=St.map(Ot=>({name:Ot,count:mt.filter(Lt=>{var zt;return Ot==="all"||((zt=Lt.node_type)==null?void 0:zt.toLowerCase())===Ot}).length}));et({dataInitial:{nodes:mt,links:$t},dataNew:{nodes:dt,links:kt},nodeTypes:gt,linkTypes:wt,sidebarFilters:St,sidebarFilterCounts:Bt,nodesNormalized:ot,linksNormalized:lt})},abortFetchData:()=>{abortController&&abortController.abort("abort")},resetGraph:()=>{const{setAbortRequests:rt}=tt(),{setBudget:nt}=useUserStore.getState();et({filters:defaultData$2.filters,dataInitial:null,dataNew:null}),tt().fetchData(nt,rt)},resetData:()=>{et({dataInitial:null,sidebarFilter:"all",sidebarFilters:[],sidebarFilterCounts:[],dataNew:null,runningProjectId:"",nodeTypes:[],nodesNormalized:new Map,linksNormalized:new Map})},nextPage:()=>{const{filters:rt,fetchData:nt,setAbortRequests:it}=tt(),{setBudget:st}=useUserStore.getState();et({filters:{...rt,skip:rt.skip+1}}),nt(st,it)},resetDataNew:()=>et({dataNew:null}),setFilters:rt=>{const{setBudget:nt}=useUserStore.getState();et(it=>({filters:{...it.filters,...rt,skip:0}})),tt().fetchData(nt,tt().setAbortRequests)},setSidebarFilterCounts:rt=>et({sidebarFilterCounts:rt}),setTrendingTopics:rt=>et({trendingTopics:rt}),setStats:rt=>et({stats:rt}),setIsFetching:rt=>et({isFetching:rt}),setCategoryFilter:rt=>et({categoryFilter:rt}),setQueuedSources:rt=>et({queuedSources:rt}),setSidebarFilter:rt=>et({sidebarFilter:rt}),setSelectedTimestamp:rt=>et({selectedTimestamp:rt}),setSources:rt=>et({sources:rt}),setHideNodeDetails:rt=>et({hideNodeDetails:rt}),setSeedQuestions:rt=>et({seedQuestions:rt}),updateNode:rt=>{const{nodesNormalized:nt}=tt(),it=new Map(nt);it.set(rt.ref_id,rt),et({nodesNormalized:it})},removeNode:rt=>{console.log(rt)},setRunningProjectId:rt=>et({runningProjectId:rt,runningProjectMessages:[]}),setRunningProjectMessages:rt=>{const{runningProjectMessages:nt}=tt();et({runningProjectMessages:[...nt,rt]})},resetRunningProjectMessages:()=>et({runningProjectMessages:[]}),setAbortRequests:rt=>et({abortRequest:rt})}))),useFilteredNodes=()=>useDataStore(et=>{var tt,rt;return et.sidebarFilter==="all"?((tt=et.dataInitial)==null?void 0:tt.nodes)||[]:(((rt=et.dataInitial)==null?void 0:rt.nodes)||[]).filter(nt=>{var it;return((it=nt.node_type)==null?void 0:it.toLowerCase())===et.sidebarFilter.toLowerCase()})}),useNodeTypes=()=>useDataStore(et=>et.nodeTypes),useNormalizedNode=et=>{const tt=useDataStore(rt=>rt.nodesNormalized);return et?tt.get(et):null},defaultData$1={trendingTopicsFeatureFlag:!0,queuedSourcesFeatureFlag:!1,v2FeatureFlag:!1,customSchemaFeatureFlag:!1,graphBluePrintFeatureFlag:!1,changeNodeTypeFeatureFlag:!1,realtimeGraphFeatureFlag:!1,userFeedbackFeatureFlag:!1,chatInterfaceFeatureFlag:!1,fastFiltersFeatureFlag:!1},useFeatureFlagStore=create(et=>({...defaultData$1,setTrendingTopicsFeatureFlag:tt=>et({trendingTopicsFeatureFlag:tt}),setV2FeatureFlag:tt=>et({v2FeatureFlag:tt}),setQueuedSourcesFeatureFlag:tt=>et({queuedSourcesFeatureFlag:tt}),setCustomSchemaFeatureFlag:tt=>et({customSchemaFeatureFlag:tt}),setGraphBluePrintFeatureFlag:tt=>et({graphBluePrintFeatureFlag:tt}),setChangeNodeTypeFeatureFlag:tt=>et({changeNodeTypeFeatureFlag:tt}),setRealtimeGraphFeatureFlag:tt=>et({realtimeGraphFeatureFlag:tt}),setUserFeedbackFeatureFlag:tt=>et({userFeedbackFeatureFlag:tt}),setChatInterfaceFeatureFlag:tt=>et({chatInterfaceFeatureFlag:tt}),setFastFiltersFeatureFlag:tt=>et({fastFiltersFeatureFlag:tt})})),isWebView=()=>(navigator.userAgent||navigator.vendor||window.opera)==="Sphinx",isAndroid=()=>navigator.userAgent.includes("Android"),defaultData={schemas:[],links:[],normalizedSchemasByType:{}},useSchemaStore=create()(devtools((et,tt)=>({...defaultData,setSchemas:rt=>{const nt=rt.reduce((it,st)=>(it[st.type]=st,it),{});et({schemas:rt.map(it=>({...it})),normalizedSchemasByType:nt})},setSchemaLinks:rt=>{et({links:rt})},getPrimaryColorByType:rt=>{const nt=tt().normalizedSchemasByType[rt];return nt?nt.primary_color:void 0},getIndexByType:rt=>{const nt=tt().normalizedSchemasByType[rt];return nt?nt.index:"name"},getNodeKeysByType:rt=>{const nt=tt().normalizedSchemasByType[rt];return nt?nt.index||nt.node_key:void 0},getSchemaByType:rt=>tt().normalizedSchemasByType[rt]})));function r(et){var tt,rt,nt="";if(typeof et=="string"||typeof et=="number")nt+=et;else if(typeof et=="object")if(Array.isArray(et))for(tt=0;tt{const[tt,rt]=reactExports.useState(0),nt=et.filter(it=>it.value!=="0");return reactExports.useEffect(()=>{const it=setInterval(()=>rt(st=>(st+1)%et.length),1e3);return()=>clearInterval(it)},[tt]),jsxRuntimeExports.jsxs(TextWrapper$1,{children:[jsxRuntimeExports.jsx(Text,{className:"loading",children:"LOADING"}),jsxRuntimeExports.jsx(Flex,{className:"value-wrapper",children:nt.map(({key:it,value:st},at)=>jsxRuntimeExports.jsx("div",{className:clsx("value",{show:tt===at}),children:st},it))}),jsxRuntimeExports.jsx(Flex,{children:nt.map(({key:it,label:st},at)=>jsxRuntimeExports.jsx(Flex,{className:clsx("label-wrapper",{show:tt===at}),children:jsxRuntimeExports.jsx("div",{className:"label",children:st})},it))})]})},TextWrapper$1=styled$3.div` height: 16px; display: flex; justify-content: space-between; @@ -831,7 +831,7 @@ PROCEED WITH CAUTION! align-items: center; width: 100%; height: 100%; -`,defaultData={selectedEpisodeId:"",selectedEpisodeLink:"",selectedEpisode:null,clips:[]},useMindsetStore=create(et=>({...defaultData,setSelectedEpisodeId:tt=>et({selectedEpisodeId:tt}),setSelectedEpisodeLink:tt=>et({selectedEpisodeLink:tt}),setSelectedEpisode:tt=>et({selectedEpisode:tt}),setClips:tt=>et({clips:tt})})),ChevronRight=et=>jsxRuntimeExports.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 7 12",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("path",{d:"M4.77978 6.00243L0.706705 1.92933C0.568239 1.79088 0.497405 1.61684 0.494205 1.40723C0.490989 1.19763 0.561822 1.02039 0.706705 0.875528C0.851572 0.730645 1.02721 0.658203 1.23361 0.658203C1.44001 0.658203 1.61564 0.730645 1.7605 0.875528L6.25473 5.36975C6.34833 5.46334 6.41436 5.56205 6.45281 5.6659C6.49127 5.76974 6.51051 5.88191 6.51051 6.00243C6.51051 6.12294 6.49127 6.23512 6.45281 6.33895C6.41436 6.4428 6.34833 6.54152 6.25473 6.6351L1.7605 11.1293C1.62205 11.2678 1.44802 11.3386 1.2384 11.3418C1.0288 11.345 0.851572 11.2742 0.706705 11.1293C0.561822 10.9845 0.48938 10.8088 0.48938 10.6024C0.48938 10.396 0.561822 10.2204 0.706705 10.0755L4.77978 6.00243Z",fill:"currentColor"})}),TypesMapper={video:"video",podcast:"audio",episode:"audio",clip:"audio",tweet:"twitter",person:"person",guest:"person",twitter_space:"audio",show:"show",image:"image"},Avatar=styled$3.div` +`,ChevronRight=et=>jsxRuntimeExports.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 7 12",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("path",{d:"M4.77978 6.00243L0.706705 1.92933C0.568239 1.79088 0.497405 1.61684 0.494205 1.40723C0.490989 1.19763 0.561822 1.02039 0.706705 0.875528C0.851572 0.730645 1.02721 0.658203 1.23361 0.658203C1.44001 0.658203 1.61564 0.730645 1.7605 0.875528L6.25473 5.36975C6.34833 5.46334 6.41436 5.56205 6.45281 5.6659C6.49127 5.76974 6.51051 5.88191 6.51051 6.00243C6.51051 6.12294 6.49127 6.23512 6.45281 6.33895C6.41436 6.4428 6.34833 6.54152 6.25473 6.6351L1.7605 11.1293C1.62205 11.2678 1.44802 11.3386 1.2384 11.3418C1.0288 11.345 0.851572 11.2742 0.706705 11.1293C0.561822 10.9845 0.48938 10.8088 0.48938 10.6024C0.48938 10.396 0.561822 10.2204 0.706705 10.0755L4.77978 6.00243Z",fill:"currentColor"})}),TypesMapper={video:"video",podcast:"audio",episode:"audio",clip:"audio",tweet:"twitter",person:"person",guest:"person",twitter_space:"audio",show:"show",image:"image"},Avatar=styled$3.div` background-image: ${({src:et,type:tt="audio"})=>`url(${et}), url('/${TypesMapper[tt]||"generic"}_placeholder_img.png')`}; background-size: cover; background-position: center; @@ -888,7 +888,7 @@ PROCEED WITH CAUTION! white-space: wrap; overflow: hidden; text-overflow: ellipsis; -`,protocol=/^(https?:\/\/)/,subDomain=/(www\.)?/,rootDomain=/[\w-]+(\.[\w-]+)*/,topLevelDomains=/(?:\.[a-zA-Z0-9][a-zA-Z0-9-]{0,61})[a-zA-Z0-9](?:\.[a-zA-Z]{2,})/,path=/(\/[^\s?]*)?/,query=/(\?[^\s]*)?/,youtubeRegex=/(https?:\/\/)?(www\.)?youtube\.com\/watch\?v=([A-Za-z0-9_-]+)/,youtubeLiveRegex=/(https?:\/\/)?(www\.)?youtube\.com\/live\/([A-Za-z0-9_-]+)/,youtubeShortRegex=/(https?:\/\/)?(www\.)?youtu\.be\/([A-Za-z0-9_-]+)/,mp3Regex=/(https?:\/\/)?([A-Za-z0-9_-]+)\.mp3/,urlRegex=new RegExp(`${protocol.source}${subDomain.source}${rootDomain.source}${topLevelDomains.source}?${path.source}${query.source}$`,"i"),validateUrl=et=>{try{if(!(et==null?void 0:et.match(urlRegex)))return!1;const nt=new URL(et).hostname;return nt!=null&&nt.startsWith("www.")?((nt==null?void 0:nt.match(/\./g))||[]).length>=2:((nt==null?void 0:nt.match(/\./g))||[]).length>=1}catch{return!1}},isValidMediaUrl=et=>validateUrl(et)?[youtubeRegex,youtubeLiveRegex,youtubeShortRegex,mp3Regex].some(rt=>rt.test(et)):!1,Nodes=[{date_added_to_graph:1733218679827695e-6,node_type:"Episode",properties:{date:1731888e3,episode_title:"AI Agents and AI Assistants: A Contrast in Function",image_url:"https://i.ytimg.com/vi/IivxYYkJ2DI/sddefault.jpg",media_url:"https://s3.amazonaws.com/stakwork-uploads/uploads/customers/4291/media_to_local/62110bc0-6b27-4779-9d5e-320eab6fae84/IivxYYkJ2DI.mp3",source_link:"https://www.youtube.com/watch?v=IivxYYkJ2DI",status:"completed"},ref_id:"b8784fb9-efa8-4a25-8a78-e14be96a4387"},{date_added_to_graph:1733323898765796e-6,node_type:"Episode",properties:{date:1733184e3,episode_title:"Joe Rogan Experience #2237 - Mike Benz",image_url:"https://i.ytimg.com/vi_webp/rrJhQpvlkLA/sddefault.webp",media_url:"https://s3.amazonaws.com/stakwork-uploads/uploads/customers/4291/media_to_local/b4c6220e-7048-431c-80c4-90e56b71bd06/rrJhQpvlkLA.mp3",source_link:"https://www.youtube.com/watch?v=rrJhQpvlkLA",status:"completed"},ref_id:"2e51fdb8-a1f1-4e1f-b9d5-4dbdae00b1a2"},{date_added_to_graph:17326354109931817e-7,node_type:"Episode",properties:{date:1730851200,description:"Exploring the Transformative Potential of Llama, the Open-Source AI Model",episode_title:"Llama: The Open-Source AI Model that's Changing How We Think About AI",image_url:"https://i.ytimg.com/vi/8c2LnKNoSmg/sddefault.jpg",media_url:"https://s3.amazonaws.com/stakwork-uploads/uploads/customers/4291/media_to_local/a4542523-6b12-4baa-bce7-ed63f2704955/8c2LnKNoSmg.mp3",source_link:"https://www.youtube.com/watch?v=8c2LnKNoSmg",status:"completed"},ref_id:"87f5e4c5-39c2-4773-8208-8c1c4fe4019b"}];console.log(Nodes);const handleSubmitForm=async et=>{const tt="add_node",rt={};rt.media_url=et.source,rt.content_type="audio_video";const nt=await api$1.post(`/${tt}`,JSON.stringify(rt));if(nt.error){const{message:it}=nt.error;throw new Error(it)}return nt},LandingPage=()=>{const[et,tt]=reactExports.useState(""),[rt,nt]=reactExports.useState(!1),[it,st]=reactExports.useState(""),{setRunningProjectId:at}=useDataStore(mt=>mt),{setSelectedEpisodeLink:ot}=useMindsetStore(mt=>mt),{setSchemas:lt}=useSchemaStore(mt=>mt),ut=useNavigate();reactExports.useEffect(()=>{(async()=>{try{const kt=await getSchemaAll();lt(kt.schemas.filter(pt=>!pt.is_deleted))}catch(kt){console.error("Error fetching schema:",kt)}})()},[lt]);const dt=mt=>{const{value:kt}=mt.target;tt(kt),nt(kt!==""&&!isValidMediaUrl(kt))},vt=async mt=>{const kt=mt||et;if(isValidMediaUrl(kt))try{const pt=await handleSubmitForm({source:kt});pt.data.project_id&&at(pt.data.project_id),pt.data.ref_id&&(ut(`/episode/${pt.data.ref_id}`),ot(kt))}catch(pt){let yt=NODE_ADD_ERROR;if((pt==null?void 0:pt.status)===400){const $t=await pt.json();yt=$t.errorCode||($t==null?void 0:$t.status)||NODE_ADD_ERROR,$t.data.ref_id&&(ut(`/episode/${$t.data.ref_id}`),ot(kt))}else pt instanceof Error&&(yt=pt.message);st(String(yt))}};return jsxRuntimeExports.jsxs(Wrapper,{children:[jsxRuntimeExports.jsx(Title,{children:"Ideas have shapes"}),jsxRuntimeExports.jsxs(InputWrapper,{children:[jsxRuntimeExports.jsx(Input,{error:rt,onChange:dt,onKeyDown:mt=>mt.key==="Enter"&&vt(),placeholder:"Paste podcast or video link",value:et}),jsxRuntimeExports.jsx(IconWrapper,{error:rt,onClick:rt?void 0:()=>vt(),children:jsxRuntimeExports.jsx(ChevronRight,{})})]}),it&&jsxRuntimeExports.jsx("div",{children:it}),jsxRuntimeExports.jsx(SeedQuestionsWrapper,{children:Nodes.map(mt=>{var kt,pt;return jsxRuntimeExports.jsx(VideoCard,{imageUrl:((kt=mt==null?void 0:mt.properties)==null?void 0:kt.image_url)||"",onClick:()=>{var yt;return vt((yt=mt==null?void 0:mt.properties)==null?void 0:yt.source_link)},subtitle:"",title:((pt=mt==null?void 0:mt.properties)==null?void 0:pt.episode_title)||""},mt==null?void 0:mt.ref_id)})})]})},Wrapper=styled$3(Flex)` +`,protocol=/^(https?:\/\/)/,subDomain=/(www\.)?/,rootDomain=/[\w-]+(\.[\w-]+)*/,topLevelDomains=/(?:\.[a-zA-Z0-9][a-zA-Z0-9-]{0,61})[a-zA-Z0-9](?:\.[a-zA-Z]{2,})/,path=/(\/[^\s?]*)?/,query=/(\?[^\s]*)?/,youtubeRegex=/(https?:\/\/)?(www\.)?youtube\.com\/watch\?v=([A-Za-z0-9_-]+)/,youtubeLiveRegex=/(https?:\/\/)?(www\.)?youtube\.com\/live\/([A-Za-z0-9_-]+)/,youtubeShortRegex=/(https?:\/\/)?(www\.)?youtu\.be\/([A-Za-z0-9_-]+)/,mp3Regex=/(https?:\/\/)?([A-Za-z0-9_-]+)\.mp3/,urlRegex=new RegExp(`${protocol.source}${subDomain.source}${rootDomain.source}${topLevelDomains.source}?${path.source}${query.source}$`,"i"),validateUrl=et=>{try{if(!(et==null?void 0:et.match(urlRegex)))return!1;const nt=new URL(et).hostname;return nt!=null&&nt.startsWith("www.")?((nt==null?void 0:nt.match(/\./g))||[]).length>=2:((nt==null?void 0:nt.match(/\./g))||[]).length>=1}catch{return!1}},isValidMediaUrl=et=>validateUrl(et)?[youtubeRegex,youtubeLiveRegex,youtubeShortRegex,mp3Regex].some(rt=>rt.test(et)):!1,Nodes=[{date_added_to_graph:1733218679827695e-6,node_type:"Episode",properties:{date:1731888e3,episode_title:"AI Agents and AI Assistants: A Contrast in Function",image_url:"https://i.ytimg.com/vi/IivxYYkJ2DI/sddefault.jpg",media_url:"https://s3.amazonaws.com/stakwork-uploads/uploads/customers/4291/media_to_local/62110bc0-6b27-4779-9d5e-320eab6fae84/IivxYYkJ2DI.mp3",source_link:"https://www.youtube.com/watch?v=IivxYYkJ2DI",status:"completed"},ref_id:"b8784fb9-efa8-4a25-8a78-e14be96a4387"},{date_added_to_graph:1733323898765796e-6,node_type:"Episode",properties:{date:1733184e3,episode_title:"Joe Rogan Experience #2237 - Mike Benz",image_url:"https://i.ytimg.com/vi_webp/rrJhQpvlkLA/sddefault.webp",media_url:"https://s3.amazonaws.com/stakwork-uploads/uploads/customers/4291/media_to_local/b4c6220e-7048-431c-80c4-90e56b71bd06/rrJhQpvlkLA.mp3",source_link:"https://www.youtube.com/watch?v=rrJhQpvlkLA",status:"completed"},ref_id:"2e51fdb8-a1f1-4e1f-b9d5-4dbdae00b1a2"},{date_added_to_graph:17326354109931817e-7,node_type:"Episode",properties:{date:1730851200,description:"Exploring the Transformative Potential of Llama, the Open-Source AI Model",episode_title:"Llama: The Open-Source AI Model that's Changing How We Think About AI",image_url:"https://i.ytimg.com/vi/8c2LnKNoSmg/sddefault.jpg",media_url:"https://s3.amazonaws.com/stakwork-uploads/uploads/customers/4291/media_to_local/a4542523-6b12-4baa-bce7-ed63f2704955/8c2LnKNoSmg.mp3",source_link:"https://www.youtube.com/watch?v=8c2LnKNoSmg",status:"completed"},ref_id:"87f5e4c5-39c2-4773-8208-8c1c4fe4019b"}];console.log(Nodes);const handleSubmitForm=async et=>{const tt="add_node",rt={};rt.media_url=et.source,rt.content_type="audio_video";const nt=await api$1.post(`/${tt}`,JSON.stringify(rt));if(nt.error){const{message:it}=nt.error;throw new Error(it)}return nt},LandingPage=()=>{const[et,tt]=reactExports.useState(""),[rt,nt]=reactExports.useState(!1),[it,st]=reactExports.useState(""),{setRunningProjectId:at}=useDataStore(vt=>vt),{setSchemas:ot}=useSchemaStore(vt=>vt),lt=useNavigate();reactExports.useEffect(()=>{(async()=>{try{const mt=await getSchemaAll();ot(mt.schemas.filter(kt=>!kt.is_deleted))}catch(mt){console.error("Error fetching schema:",mt)}})()},[ot]);const ut=vt=>{const{value:mt}=vt.target;tt(mt),nt(mt!==""&&!isValidMediaUrl(mt))},dt=async vt=>{const mt=vt||et;if(isValidMediaUrl(mt))try{const kt=await handleSubmitForm({source:mt});kt.data.project_id&&at(kt.data.project_id),kt.data.ref_id&<(`/episode/${kt.data.ref_id}`)}catch(kt){let pt=NODE_ADD_ERROR;if((kt==null?void 0:kt.status)===400){const yt=await kt.json();pt=yt.errorCode||(yt==null?void 0:yt.status)||NODE_ADD_ERROR,yt.data.ref_id&<(`/episode/${yt.data.ref_id}`)}else kt instanceof Error&&(pt=kt.message);st(String(pt))}};return jsxRuntimeExports.jsxs(Wrapper,{children:[jsxRuntimeExports.jsx(Title,{children:"Ideas have shapes"}),jsxRuntimeExports.jsxs(InputWrapper,{children:[jsxRuntimeExports.jsx(Input,{error:rt,onChange:ut,onKeyDown:vt=>vt.key==="Enter"&&dt(),placeholder:"Paste podcast or video link",value:et}),jsxRuntimeExports.jsx(IconWrapper,{error:rt,onClick:rt?void 0:()=>dt(),children:jsxRuntimeExports.jsx(ChevronRight,{})})]}),it&&jsxRuntimeExports.jsx("div",{children:it}),jsxRuntimeExports.jsx(SeedQuestionsWrapper,{children:Nodes.map(vt=>{var mt,kt;return jsxRuntimeExports.jsx(VideoCard,{imageUrl:((mt=vt==null?void 0:vt.properties)==null?void 0:mt.image_url)||"",onClick:()=>{var pt;return dt((pt=vt==null?void 0:vt.properties)==null?void 0:pt.source_link)},subtitle:"",title:((kt=vt==null?void 0:vt.properties)==null?void 0:kt.episode_title)||""},vt==null?void 0:vt.ref_id)})})]})},Wrapper=styled$3(Flex)` background: #16161de3; position: absolute; left: 0; @@ -954,4 +954,4 @@ PROCEED WITH CAUTION! margin-top: 20px; max-width: 648px; height: 237px; -`,LazyApp=reactExports.lazy(()=>__vitePreload(()=>import("./index-5ca84596.js").then(et=>et.i),["assets/index-5ca84596.js","assets/index-7730ff6f.js"]).then(({App:et})=>({default:et}))),LazyMindSet=reactExports.lazy(()=>__vitePreload(()=>import("./index-27a0b90a.js"),["assets/index-27a0b90a.js","assets/index-e06603b3.js","assets/index-dc12854c.js","assets/three.module-71ec604c.js","assets/index-7888478e.js","assets/index-7730ff6f.js","assets/TextareaAutosize-b716e8d1.js","assets/index-5111ebdb.js","assets/index-a17bf5d0.js","assets/ClipLoader-1ef5878d.js","assets/index-87de005d.js","assets/Skeleton-dbbfd404.js","assets/Stack-6038813c.js","assets/isPlainObject-b85008a5.js","assets/Typography-f76555b9.js","assets/createSvgIcon-41051178.js","assets/index-59c77710.js"]).then(({MindSet:et})=>({default:et}))),AppContainer=()=>{var tt;const et=((tt=window.location)==null?void 0:tt.hostname)==="graphmindset.sphinx.chat"||window.location.hostname==="localhost"&&!isE2E;return jsxRuntimeExports.jsxs(AppProviders,{children:[jsxRuntimeExports.jsx(reactExports.Suspense,{fallback:jsxRuntimeExports.jsx("div",{children:"Loading..."}),children:jsxRuntimeExports.jsxs(Routes,{children:[et&&jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(LandingPage,{}),path:"/"}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(LazyMindSet,{}),path:"/episode/:episodeId"}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(Navigate,{replace:!0,to:"/"}),path:"/episode"})]}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(AuthGuard,{children:jsxRuntimeExports.jsx(LazyApp,{})}),path:"/"}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(AuthGuard,{children:jsxRuntimeExports.jsx(LazyApp,{})}),path:"/search"}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(AuthGuard,{children:jsxRuntimeExports.jsx(LazyApp,{})}),path:"*"})]})}),jsxRuntimeExports.jsx(E2ETests,{})]})},index="",root=client$1.createRoot(document.getElementById("root"));root.render(isE2E?jsxRuntimeExports.jsx(BrowserRouter,{children:jsxRuntimeExports.jsx(AppContainer,{})}):jsxRuntimeExports.jsx(React.StrictMode,{children:jsxRuntimeExports.jsx(BrowserRouter,{children:jsxRuntimeExports.jsx(AppContainer,{})})}));reportWebVitals();overrideConsole();export{useEnhancedEffect$1 as $,Avatar as A,Button$1 as B,ClearIcon as C,getNode as D,fetchNodeEdges as E,Flex as F,_inheritsLoose as G,_objectWithoutPropertiesLoose as H,InfoIcon as I,React as J,TransitionGroupContext as K,generateUtilityClass as L,generateUtilityClasses as M,styled$1 as N,_extends as O,alpha as P,Q,ReactDOM as R,useThemeProps as S,Text as T,clsx$2 as U,composeClasses as V,We as W,ButtonBase$1 as X,capitalize as Y,useForkRef as Z,__vitePreload as _,colors as a,BaseModal as a$,setRef as a0,reactDomExports as a1,useEventCallback as a2,useTheme as a3,devtools as a4,LinearProgress$1 as a5,SocketContext as a6,isSphinx as a7,$2AODx$react as a8,getDefaultExportFromCjs as a9,_Set as aA,_Symbol as aB,isArguments_1 as aC,isArray_1 as aD,_arrayPush as aE,_baseUnary as aF,_defineProperty as aG,eq_1 as aH,isArrayLike_1 as aI,_isIndex as aJ,isObject_1 as aK,_root as aL,_baseAssignValue as aM,keys_1 as aN,MdBolt as aO,getFullTranscript as aP,MdPlayArrow as aQ,MdAccessTime as aR,useNormalizedNode as aS,getAugmentedNamespace as aT,useHasAiChats as aU,postAboutData as aV,SuccessNotify as aW,NODE_ADD_ERROR as aX,TextInput as aY,requiredRule as aZ,MdError as a_,useNodeTypes as aa,MdViewInAr as ab,MdClose as ac,Ce as ad,addToGlobalForE2e as ae,isDevelopment as af,api$1 as ag,distExports$1 as ah,executeIfProd as ai,useIsFocusVisible as aj,rootShouldForwardProp as ak,lighten as al,darken as am,slotShouldForwardProp as an,useFormContext as ao,useHasAiChatsResponseLoading as ap,Ue as aq,hooks as ar,commonjsGlobal as as,commonjsRequire as at,getSchemaAll as au,useFilteredNodes as av,_baseGetTag as aw,isObjectLike_1 as ax,isObject$8 as ay,isFunction$4 as az,useUserStore as b,sphinx$1 as b$,TWITTER_HANDLE as b0,YOUTUBE_CHANNEL as b1,RSS as b2,GITHUB_REPOSITORY as b3,LINK as b4,TWITTER_SOURCE as b5,WEB_PAGE as b6,DOCUMENT as b7,getPriceData as b8,isE2E as b9,css as bA,changeNodeType as bB,resolveBreakpointValues as bC,handleBreakpoints as bD,updateEdgeType as bE,postBluePrintType as bF,deleteEdgeType as bG,cloneDeep_1 as bH,useFieldArray as bI,OptionTypes as bJ,NoParent as bK,editNodeSchemaUpdate as bL,createRoot as bM,react as bN,GRAPH_GROUND_COLOR as bO,GRAPH_LIGHT_INTENSITY as bP,_MapCache as bQ,_Uint8Array as bR,_getAllKeys as bS,_Stack as bT,_getTag as bU,isBufferExports as bV,isTypedArray_1 as bW,isLength_1 as bX,_getPrototype as bY,request as bZ,buffer$2 as b_,sphinxBridge as ba,getLSat as bb,payLsat as bc,noSpacePattern as bd,getNodeType as be,getNodeSchemaTypes as bf,OPTIONS as bg,initialValue as bh,getNodeContent as bi,MdCheckCircle as bj,MdCancel as bk,approveRadarData as bl,deleteRadarData as bm,getRadarData as bn,BaseTextInput as bo,MdCheck as bp,putRadarData as bq,getEdgeTypes as br,getEdges as bs,postEdgeType as bt,putNodeData as bu,postMergeTopics as bv,getTopicsData as bw,editNodeData as bx,deleteNode as by,keyframes as bz,create as c,Global as c0,useTheme$2 as c1,defaultTheme$1 as c2,THEME_ID as c3,formatMuiErrorMessage as c4,deepmerge as c5,defaultSxConfig$1 as c6,isPlainObject$1 as c7,createStyled as c8,createTheme$1 as c9,useThemeProps$1 as ca,createUnarySpacing as cb,mergeBreakpointsInOrder as cc,getValue as cd,useTheme$3 as ce,index$1 as cf,useSchemaStore as d,useModal as e,getStats as f,getTotalProcessing as g,formatStatsResponse as h,lodashExports as i,jsxRuntimeExports as j,useAppStore as k,lottie as l,media as m,useAiSummaryStore as n,useNavigate as o,useSearchParams as p,useFeatureFlagStore as q,reactExports as r,styled$3 as s,useForm as t,useDataStore as u,FormProvider as v,updateBudget as w,clsx as x,useMindsetStore as y,useParams as z}; +`,LazyApp=reactExports.lazy(()=>__vitePreload(()=>import("./index-763b7c2d.js").then(et=>et.i),["assets/index-763b7c2d.js","assets/index-af5a3f81.js"]).then(({App:et})=>({default:et}))),LazyMindSet=reactExports.lazy(()=>__vitePreload(()=>import("./index-d07244c7.js"),["assets/index-d07244c7.js","assets/index-88446b65.js","assets/index-c715ffeb.js","assets/three.module-71ec604c.js","assets/index-37b3c15b.js","assets/index-af5a3f81.js","assets/TextareaAutosize-f6242cb8.js","assets/index-569670a3.js","assets/index-7fe50db2.js","assets/ClipLoader-8590c2f1.js","assets/index-a46872c4.js","assets/Skeleton-7af13a79.js","assets/Stack-5870980a.js","assets/isPlainObject-1f2f9f4b.js","assets/Typography-2a31701b.js","assets/createSvgIcon-c125a9c8.js","assets/index-5c5c5836.js"]).then(({MindSet:et})=>({default:et}))),AppContainer=()=>{var tt;const et=((tt=window.location)==null?void 0:tt.hostname)==="graphmindset.sphinx.chat"||window.location.hostname==="localhost"&&!isE2E;return jsxRuntimeExports.jsxs(AppProviders,{children:[jsxRuntimeExports.jsx(reactExports.Suspense,{fallback:jsxRuntimeExports.jsx("div",{children:"Loading..."}),children:jsxRuntimeExports.jsxs(Routes,{children:[et&&jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(LandingPage,{}),path:"/"}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(LazyMindSet,{}),path:"/episode/:episodeId"}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(Navigate,{replace:!0,to:"/"}),path:"/episode"})]}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(AuthGuard,{children:jsxRuntimeExports.jsx(LazyApp,{})}),path:"/"}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(AuthGuard,{children:jsxRuntimeExports.jsx(LazyApp,{})}),path:"/search"}),jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(AuthGuard,{children:jsxRuntimeExports.jsx(LazyApp,{})}),path:"*"})]})}),jsxRuntimeExports.jsx(E2ETests,{})]})},index="",root=client$1.createRoot(document.getElementById("root"));root.render(isE2E?jsxRuntimeExports.jsx(BrowserRouter,{children:jsxRuntimeExports.jsx(AppContainer,{})}):jsxRuntimeExports.jsx(React.StrictMode,{children:jsxRuntimeExports.jsx(BrowserRouter,{children:jsxRuntimeExports.jsx(AppContainer,{})})}));reportWebVitals();overrideConsole();export{setRef as $,Avatar as A,Button$1 as B,ClearIcon as C,fetchNodeEdges as D,_inheritsLoose as E,Flex as F,_objectWithoutPropertiesLoose as G,React as H,InfoIcon as I,TransitionGroupContext as J,generateUtilityClass as K,generateUtilityClasses as L,styled$1 as M,_extends as N,alpha as O,useThemeProps as P,Q,ReactDOM as R,clsx$2 as S,Text as T,composeClasses as U,ButtonBase$1 as V,We as W,capitalize as X,useForkRef as Y,useEnhancedEffect$1 as Z,__vitePreload as _,colors as a,TWITTER_HANDLE as a$,reactDomExports as a0,useEventCallback as a1,useTheme as a2,devtools as a3,LinearProgress$1 as a4,SocketContext as a5,isSphinx as a6,$2AODx$react as a7,getDefaultExportFromCjs as a8,useNodeTypes as a9,_Symbol as aA,isArguments_1 as aB,isArray_1 as aC,_arrayPush as aD,_baseUnary as aE,_defineProperty as aF,eq_1 as aG,isArrayLike_1 as aH,_isIndex as aI,isObject_1 as aJ,_root as aK,_baseAssignValue as aL,keys_1 as aM,MdBolt as aN,getFullTranscript as aO,MdPlayArrow as aP,MdAccessTime as aQ,useNormalizedNode as aR,getAugmentedNamespace as aS,useHasAiChats as aT,postAboutData as aU,SuccessNotify as aV,NODE_ADD_ERROR as aW,TextInput as aX,requiredRule as aY,MdError as aZ,BaseModal as a_,MdViewInAr as aa,MdClose as ab,Ce as ac,addToGlobalForE2e as ad,isDevelopment as ae,api$1 as af,distExports$1 as ag,executeIfProd as ah,useIsFocusVisible as ai,rootShouldForwardProp as aj,lighten as ak,darken as al,slotShouldForwardProp as am,useFormContext as an,useHasAiChatsResponseLoading as ao,Ue as ap,hooks as aq,commonjsGlobal as ar,commonjsRequire as as,getSchemaAll as at,useFilteredNodes as au,_baseGetTag as av,isObjectLike_1 as aw,isObject$8 as ax,isFunction$4 as ay,_Set as az,useUserStore as b,Global as b$,YOUTUBE_CHANNEL as b0,RSS as b1,GITHUB_REPOSITORY as b2,LINK as b3,TWITTER_SOURCE as b4,WEB_PAGE as b5,DOCUMENT as b6,getPriceData as b7,isE2E as b8,sphinxBridge as b9,changeNodeType as bA,resolveBreakpointValues as bB,handleBreakpoints as bC,updateEdgeType as bD,postBluePrintType as bE,deleteEdgeType as bF,cloneDeep_1 as bG,useFieldArray as bH,OptionTypes as bI,NoParent as bJ,editNodeSchemaUpdate as bK,createRoot as bL,react as bM,GRAPH_GROUND_COLOR as bN,GRAPH_LIGHT_INTENSITY as bO,_MapCache as bP,_Uint8Array as bQ,_getAllKeys as bR,_Stack as bS,_getTag as bT,isBufferExports as bU,isTypedArray_1 as bV,isLength_1 as bW,_getPrototype as bX,request as bY,buffer$2 as bZ,sphinx$1 as b_,getLSat as ba,payLsat as bb,noSpacePattern as bc,getNodeType as bd,getNodeSchemaTypes as be,OPTIONS as bf,initialValue as bg,getNodeContent as bh,MdCheckCircle as bi,MdCancel as bj,approveRadarData as bk,deleteRadarData as bl,getRadarData as bm,BaseTextInput as bn,MdCheck as bo,putRadarData as bp,getEdgeTypes as bq,getEdges as br,postEdgeType as bs,putNodeData as bt,postMergeTopics as bu,getTopicsData as bv,editNodeData as bw,deleteNode as bx,keyframes as by,css as bz,create as c,useTheme$2 as c0,defaultTheme$1 as c1,THEME_ID as c2,formatMuiErrorMessage as c3,deepmerge as c4,defaultSxConfig$1 as c5,isPlainObject$1 as c6,createStyled as c7,createTheme$1 as c8,useThemeProps$1 as c9,createUnarySpacing as ca,mergeBreakpointsInOrder as cb,getValue as cc,useTheme$3 as cd,index$1 as ce,useSchemaStore as d,useModal as e,getStats as f,getTotalProcessing as g,formatStatsResponse as h,lodashExports as i,jsxRuntimeExports as j,useAppStore as k,lottie as l,media as m,useAiSummaryStore as n,useNavigate as o,useSearchParams as p,useFeatureFlagStore as q,reactExports as r,styled$3 as s,useForm as t,useDataStore as u,FormProvider as v,updateBudget as w,clsx as x,useParams as y,getNode as z}; diff --git a/build/assets/index-5111ebdb.js b/build/assets/index-569670a3.js similarity index 96% rename from build/assets/index-5111ebdb.js rename to build/assets/index-569670a3.js index 8804917a4..f58bcbf03 100644 --- a/build/assets/index-5111ebdb.js +++ b/build/assets/index-569670a3.js @@ -1,4 +1,4 @@ -import{s as p,a,F as b,d as m,j as c}from"./index-4bb27744.js";const v=({type:s})=>{var n,g;let e;const[r]=m(l=>[l.normalizedSchemasByType]),d=s,o=(n=r[s])==null?void 0:n.primary_color,i=(g=r[s])==null?void 0:g.icon,t=i?`svg-icons/${i}.svg`:null;switch(d){case"video":case"twitter_space":case"podcast":case"clip":e={iconStart:t??"video_badge.svg",color:o??a.CLIP};break;case"show":e={iconStart:t??"show_badge.svg",color:o??a.SHOW};break;case"tweet":e={iconStart:t??"twitter_badge.svg",color:o??a.TWEET};break;case"episode":e={iconStart:t??"audio_badge.svg",color:o??a.EPISODE};break;case"document":e={iconStart:t??"notes_badge.svg",color:o??a.TEXT};break;case(i??"organization"):e={iconStart:t??"organization_badge.svg",color:o??a.ORGANIZATION};break;case"person":case"guest":case"host":e={iconStart:t??"person_badge.svg",color:o??a.PERSON};break;case"event":e={iconStart:t??"event_badge.svg",color:o??a.EVENT};break;default:e={iconStart:t??"thing_badge.svg",color:o??a.THING};break}return c.jsx(h,{...e,label:s})},h=({iconStart:s,color:e,label:r})=>c.jsxs(x,{color:e,children:[c.jsx("img",{alt:r,className:"badge__img",src:s}),c.jsx("div",{className:"badge__label",children:r})]}),x=p(b).attrs({direction:"row"})` +import{s as p,a,F as b,d as m,j as c}from"./index-4e60c9e2.js";const v=({type:s})=>{var n,g;let e;const[r]=m(l=>[l.normalizedSchemasByType]),d=s,o=(n=r[s])==null?void 0:n.primary_color,i=(g=r[s])==null?void 0:g.icon,t=i?`svg-icons/${i}.svg`:null;switch(d){case"video":case"twitter_space":case"podcast":case"clip":e={iconStart:t??"video_badge.svg",color:o??a.CLIP};break;case"show":e={iconStart:t??"show_badge.svg",color:o??a.SHOW};break;case"tweet":e={iconStart:t??"twitter_badge.svg",color:o??a.TWEET};break;case"episode":e={iconStart:t??"audio_badge.svg",color:o??a.EPISODE};break;case"document":e={iconStart:t??"notes_badge.svg",color:o??a.TEXT};break;case(i??"organization"):e={iconStart:t??"organization_badge.svg",color:o??a.ORGANIZATION};break;case"person":case"guest":case"host":e={iconStart:t??"person_badge.svg",color:o??a.PERSON};break;case"event":e={iconStart:t??"event_badge.svg",color:o??a.EVENT};break;default:e={iconStart:t??"thing_badge.svg",color:o??a.THING};break}return c.jsx(h,{...e,label:s})},h=({iconStart:s,color:e,label:r})=>c.jsxs(x,{color:e,children:[c.jsx("img",{alt:r,className:"badge__img",src:s}),c.jsx("div",{className:"badge__label",children:r})]}),x=p(b).attrs({direction:"row"})` cursor: pointer; background: ${({color:s})=>s}; border-radius: 3px; diff --git a/build/assets/index-c3e0684d.js b/build/assets/index-5c4e6029.js similarity index 82% rename from build/assets/index-c3e0684d.js rename to build/assets/index-5c4e6029.js index 4c23db2d5..7d471b956 100644 --- a/build/assets/index-c3e0684d.js +++ b/build/assets/index-5c4e6029.js @@ -1,4 +1,4 @@ -import{r as p,i as T,j as e,F as x,C as I,bg as _,bs as L,s as n,T as w,e as A,t as B,a$ as E,v as F,a as M,bv as N,B as k}from"./index-4bb27744.js";import{ar as O,as as z,at as D,l as P}from"./index-7730ff6f.js";import{u as v}from"./index-d0e3c339.js";import{S as Y,A as R,I as X}from"./constants-bc1d79ca.js";import{A as H,T as W}from"./index-22c3582f.js";import{C as $}from"./ClipLoader-1ef5878d.js";import"./index-5111ebdb.js";import"./Stack-6038813c.js";import"./createSvgIcon-41051178.js";import"./TextareaAutosize-b716e8d1.js";const U=({topicId:s,onSelect:a,selectedValue:d,dataId:c})=>{const[u,h]=p.useState([]),[m,f]=p.useState(!1),j=p.useMemo(()=>{const o=async i=>{const g={is_muted:"False",sort_by:R,search:i,skip:"0",limit:"1000"};f(!0);try{const C=(await L(g.search)).data.filter(y=>(y==null?void 0:y.ref_id)!==s);h(C)}catch{h([])}finally{f(!1)}};return T.debounce(o,300)},[s]),r=o=>{const i=o.trim();if(!i){h([]);return}i.length>2&&j(o)},b=o=>{const i=o?u.find(g=>g.ref_id===o.value):null;a(i||null)},t=o=>({label:o.search_value,value:o.ref_id,type:o.node_type}),S=o=>o.map(t);return d?e.jsxs(x,{align:"center",basis:"100%",direction:"row",grow:1,shrink:1,children:[e.jsx("span",{children:d.search_value}),e.jsx(Y,{onClick:()=>a(null),size:"medium",children:e.jsx(I,{})})]}):e.jsx(H,{dataId:c,handleInputChange:r,isLoading:m,onSelect:b,options:S(u)||_,selectedValue:d?t(d):null})},q=({from:s,onSelect:a,selectedToNode:d,isSwapped:c,setIsSwapped:u})=>e.jsxs(x,{mb:20,children:[e.jsx(x,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(x,{align:"center",direction:"row",children:e.jsx(G,{children:"Merge topic"})})}),e.jsxs(Q,{swap:c,children:[e.jsx(J,{children:e.jsx(V,{disabled:!0,label:c?"To":"From",swap:c,value:s==null?void 0:s.name})}),e.jsxs(x,{my:16,children:[e.jsx(ee,{children:"Type"}),e.jsx(w,{children:"IS ALIAS"})]}),e.jsx(x,{"data-testid":"to-section-container",children:e.jsxs(Z,{children:[e.jsx(te,{children:c?"From":"To"}),e.jsx(U,{dataId:"to-node",onSelect:a,selectedValue:d,topicId:s==null?void 0:s.ref_id})]})}),e.jsxs(K,{children:[e.jsx(oe,{children:e.jsx(O,{})}),e.jsx(se,{"data-testid":"swap-icon",onClick:u,children:e.jsx(z,{})}),e.jsx(ne,{children:e.jsx(D,{})})]})]})]}),G=n(w)` +import{r as p,i as T,j as e,F as x,C as I,bf as _,br as L,s as n,T as v,e as A,t as B,a_ as E,v as F,a as M,bu as N,B as k}from"./index-4e60c9e2.js";import{ar as O,as as z,at as D,l as P}from"./index-af5a3f81.js";import{u as w}from"./index-aa1facf3.js";import{S as Y,A as R,I as X}from"./constants-b9d9206a.js";import{A as H,T as W}from"./index-d96216bb.js";import{C as U}from"./ClipLoader-8590c2f1.js";import"./index-569670a3.js";import"./Stack-5870980a.js";import"./createSvgIcon-c125a9c8.js";import"./TextareaAutosize-f6242cb8.js";const $=({topicId:s,onSelect:a,selectedValue:d,dataId:c})=>{const[u,h]=p.useState([]),[m,f]=p.useState(!1),j=p.useMemo(()=>{const o=async i=>{const g={is_muted:"False",sort_by:R,search:i,skip:"0",limit:"1000"};f(!0);try{const C=(await L(g.search)).data.filter(y=>(y==null?void 0:y.ref_id)!==s);h(C)}catch{h([])}finally{f(!1)}};return T.debounce(o,300)},[s]),r=o=>{const i=o.trim();if(!i){h([]);return}i.length>2&&j(o)},b=o=>{const i=o?u.find(g=>g.ref_id===o.value):null;a(i||null)},t=o=>({label:o.search_value,value:o.ref_id,type:o.node_type}),S=o=>o.map(t);return d?e.jsxs(x,{align:"center",basis:"100%",direction:"row",grow:1,shrink:1,children:[e.jsx("span",{children:d.search_value}),e.jsx(Y,{onClick:()=>a(null),size:"medium",children:e.jsx(I,{})})]}):e.jsx(H,{dataId:c,handleInputChange:r,isLoading:m,onSelect:b,options:S(u)||_,selectedValue:d?t(d):null})},q=({from:s,onSelect:a,selectedToNode:d,isSwapped:c,setIsSwapped:u})=>e.jsxs(x,{mb:20,children:[e.jsx(x,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(x,{align:"center",direction:"row",children:e.jsx(G,{children:"Merge topic"})})}),e.jsxs(Q,{swap:c,children:[e.jsx(J,{children:e.jsx(V,{disabled:!0,label:c?"To":"From",swap:c,value:s==null?void 0:s.name})}),e.jsxs(x,{my:16,children:[e.jsx(ee,{children:"Type"}),e.jsx(v,{children:"IS ALIAS"})]}),e.jsx(x,{"data-testid":"to-section-container",children:e.jsxs(Z,{children:[e.jsx(te,{children:c?"From":"To"}),e.jsx($,{dataId:"to-node",onSelect:a,selectedValue:d,topicId:s==null?void 0:s.ref_id})]})}),e.jsxs(K,{children:[e.jsx(oe,{children:e.jsx(O,{})}),e.jsx(se,{"data-testid":"swap-icon",onClick:u,children:e.jsx(z,{})}),e.jsx(ne,{children:e.jsx(D,{})})]})]})]}),G=n(v)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; @@ -87,7 +87,7 @@ import{r as p,i as T,j as e,F as x,C as I,bg as _,bs as L,s as n,T as w,e as A,t transform: translateY(10px) translateX(3px); color: #6b7a8d; line-height: 1; -`,me=()=>{const{close:s}=A("mergeToNode"),[a,d,c]=v(l=>[l.data,l.ids,l.total]),u=B({mode:"onChange"}),[h,m]=p.useState(!1),[f,j]=p.useState(!1),[r,b]=p.useState(null),[t,S]=p.useState(),o=P();p.useEffect(()=>{o&&S(o)},[o]);const i=()=>{b(null),s()},g=async()=>{if(!(!r||!a)){m(!0);try{await N({from:t==null?void 0:t.ref_id,to:r==null?void 0:r.ref_id}),t!=null&&t.ref_id&&(a[t==null?void 0:t.ref_id]={...a[t==null?void 0:t.ref_id],edgeList:[X],edgeCount:a[t==null?void 0:t.ref_id].edgeCount-1},v.setState({ids:d.filter(l=>l!==r.ref_id),total:c-1})),i()}catch(l){console.warn(l)}finally{m(!1)}}};return e.jsx(E,{id:"mergeToNode",kind:"small",onClose:i,preventOutsideClose:!0,children:e.jsxs(F,{...u,children:[e.jsx(q,{from:t,isSwapped:f,onSelect:b,selectedToNode:r,setIsSwapped:()=>j(!f)}),e.jsxs(ae,{color:"secondary","data-testid":"merge-topics-button",disabled:h||!r,onClick:g,size:"large",variant:"contained",children:["Merge topics",h&&e.jsx(re,{children:e.jsx($,{color:M.BLUE_PRESS_STATE,size:12})})]})]})})},ae=n(k)` +`,me=()=>{const{close:s}=A("mergeToNode"),[a,d,c]=w(l=>[l.data,l.ids,l.total]),u=B({mode:"onChange"}),[h,m]=p.useState(!1),[f,j]=p.useState(!1),[r,b]=p.useState(null),[t,S]=p.useState(),o=P();p.useEffect(()=>{o&&S(o)},[o]);const i=()=>{b(null),s()},g=async()=>{if(!(!r||!a)){m(!0);try{await N({from:t==null?void 0:t.ref_id,to:r==null?void 0:r.ref_id}),t!=null&&t.ref_id&&(a[t==null?void 0:t.ref_id]={...a[t==null?void 0:t.ref_id],edgeList:[X],edgeCount:a[t==null?void 0:t.ref_id].edgeCount-1},w.setState({ids:d.filter(l=>l!==r.ref_id),total:c-1})),i()}catch(l){console.warn(l)}finally{m(!1)}}};return e.jsx(E,{id:"mergeToNode",kind:"small",onClose:i,preventOutsideClose:!0,children:e.jsxs(F,{...u,children:[e.jsx(q,{from:t,isSwapped:f,onSelect:b,selectedToNode:r,setIsSwapped:()=>j(!f)}),e.jsxs(ae,{color:"secondary","data-testid":"merge-topics-button",disabled:h||!r,onClick:g,size:"large",variant:"contained",children:["Merge topics",h&&e.jsx(re,{children:e.jsx(U,{color:M.BLUE_PRESS_STATE,size:12})})]})]})})},ae=n(k)` width: 293px !important; margin: 0 0 10px auto !important; `,re=n.span` diff --git a/build/assets/index-59c77710.js b/build/assets/index-5c5c5836.js similarity index 99% rename from build/assets/index-59c77710.js rename to build/assets/index-5c5c5836.js index f641c12e1..fd571de17 100644 --- a/build/assets/index-59c77710.js +++ b/build/assets/index-5c5c5836.js @@ -1,4 +1,4 @@ -import{as as He,a9 as Tr,j as V,s as zn,a as Bn,r as Un,e as vt,k as zr,b as Lr,u as Or,x as Dr,F as fe,T as Ft,B as vr,c as Fr,a$ as Rr}from"./index-4bb27744.js";import{c as Br,aO as Nr,aP as Mr}from"./index-7730ff6f.js";function _r(n,e){const t=e||{};return(n[n.length-1]===""?[...n,""]:n).join((t.padRight?" ":"")+","+(t.padLeft===!1?"":" ")).trim()}const jr=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Hr=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Ur={};function Ue(n,e){return((e||Ur).jsx?Hr:jr).test(n)}const Vr=/[ \t\n\f\r]/g;function qr(n){return typeof n=="object"?n.type==="text"?Ve(n.value):!1:Ve(n)}function Ve(n){return n.replace(Vr,"")===""}class jn{constructor(e,t,r){this.property=e,this.normal=t,r&&(this.space=r)}}jn.prototype.property={};jn.prototype.normal={};jn.prototype.space=null;function Rt(n,e){const t={},r={};let i=-1;for(;++i4&&t.slice(0,4)==="data"&&Yr.test(e)){if(e.charAt(4)==="-"){const l=e.slice(5).replace($e,Zr);r="data"+l.charAt(0).toUpperCase()+l.slice(1)}else{const l=e.slice(4);if(!$e.test(l)){let o=l.replace(Kr,Jr);o.charAt(0)!=="-"&&(o="-"+o),e="data"+o}}i=Se}return new i(r,e)}function Jr(n){return"-"+n.toLowerCase()}function Zr(n){return n.charAt(1).toUpperCase()}const ni={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},ei=Rt([Mt,Nt,Ht,Ut,Qr],"html"),Ce=Rt([Mt,Nt,Ht,Ut,Xr],"svg");function ti(n){return n.join(" ").trim()}var Vt={},We=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,ri=/\n/g,ii=/^\s*/,li=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,oi=/^:\s*/,ai=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,ui=/^[;\s]*/,si=/^\s+|\s+$/g,ci=` +import{ar as He,a8 as Tr,j as V,s as zn,a as Bn,r as Un,e as vt,k as zr,b as Lr,u as Or,x as Dr,F as fe,T as Ft,B as vr,c as Fr,a_ as Rr}from"./index-4e60c9e2.js";import{c as Br,aO as Nr,aP as Mr}from"./index-af5a3f81.js";function _r(n,e){const t=e||{};return(n[n.length-1]===""?[...n,""]:n).join((t.padRight?" ":"")+","+(t.padLeft===!1?"":" ")).trim()}const jr=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Hr=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,Ur={};function Ue(n,e){return((e||Ur).jsx?Hr:jr).test(n)}const Vr=/[ \t\n\f\r]/g;function qr(n){return typeof n=="object"?n.type==="text"?Ve(n.value):!1:Ve(n)}function Ve(n){return n.replace(Vr,"")===""}class jn{constructor(e,t,r){this.property=e,this.normal=t,r&&(this.space=r)}}jn.prototype.property={};jn.prototype.normal={};jn.prototype.space=null;function Rt(n,e){const t={},r={};let i=-1;for(;++i4&&t.slice(0,4)==="data"&&Yr.test(e)){if(e.charAt(4)==="-"){const l=e.slice(5).replace($e,Zr);r="data"+l.charAt(0).toUpperCase()+l.slice(1)}else{const l=e.slice(4);if(!$e.test(l)){let o=l.replace(Kr,Jr);o.charAt(0)!=="-"&&(o="-"+o),e="data"+o}}i=Se}return new i(r,e)}function Jr(n){return"-"+n.toLowerCase()}function Zr(n){return n.charAt(1).toUpperCase()}const ni={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},ei=Rt([Mt,Nt,Ht,Ut,Qr],"html"),Ce=Rt([Mt,Nt,Ht,Ut,Xr],"svg");function ti(n){return n.join(" ").trim()}var Vt={},We=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,ri=/\n/g,ii=/^\s*/,li=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,oi=/^:\s*/,ai=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,ui=/^[;\s]*/,si=/^\s+|\s+$/g,ci=` `,Qe="/",Xe="*",Sn="",pi="comment",fi="declaration",hi=function(n,e){if(typeof n!="string")throw new TypeError("First argument must be a string");if(!n)return[];e=e||{};var t=1,r=1;function i(y){var k=y.match(ri);k&&(t+=k.length);var I=y.lastIndexOf(ci);r=~I?y.length-I:r+y.length}function l(){var y={line:t,column:r};return function(k){return k.position=new o(y),s(),k}}function o(y){this.start=y,this.end={line:t,column:r},this.source=e.source}o.prototype.content=n;function a(y){var k=new Error(e.source+":"+t+":"+r+": "+y);if(k.reason=y,k.filename=e.source,k.line=t,k.column=r,k.source=n,!e.silent)throw k}function u(y){var k=y.exec(n);if(k){var I=k[0];return i(I),n=n.slice(I.length),k}}function s(){u(ii)}function c(y){var k;for(y=y||[];k=f();)k!==!1&&y.push(k);return y}function f(){var y=l();if(!(Qe!=n.charAt(0)||Xe!=n.charAt(1))){for(var k=2;Sn!=n.charAt(k)&&(Xe!=n.charAt(k)||Qe!=n.charAt(k+1));)++k;if(k+=2,Sn===n.charAt(k-1))return a("End of comment missing");var I=n.slice(2,k-2);return r+=2,i(I),n=n.slice(k),r+=2,y({type:pi,comment:I})}}function d(){var y=l(),k=u(li);if(k){if(f(),!u(oi))return a("property missing ':'");var I=u(ai),w=y({type:fi,property:Ye(k[0].replace(We,Sn)),value:I?Ye(I[0].replace(We,Sn)):Sn});return u(ui),w}}function p(){var y=[];c(y);for(var k;k=d();)k!==!1&&(y.push(k),c(y));return y}return s(),p()};function Ye(n){return n?n.replace(si,Sn):Sn}var mi=He&&He.__importDefault||function(n){return n&&n.__esModule?n:{default:n}};Object.defineProperty(Vt,"__esModule",{value:!0});var di=mi(hi);function gi(n,e){var t=null;if(!n||typeof n!="string")return t;var r=(0,di.default)(n),i=typeof e=="function";return r.forEach(function(l){if(l.type==="declaration"){var o=l.property,a=l.value;i?e(o,a,l):a&&(t=t||{},t[o]=a)}}),t}var Ke=Vt.default=gi;const yi=Ke.default||Ke,qt=$t("end"),Ee=$t("start");function $t(n){return e;function e(t){const r=t&&t.position&&t.position[n]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function xi(n){const e=Ee(n),t=qt(n);if(e&&t)return{start:e,end:t}}function Nn(n){return!n||typeof n!="object"?"":"position"in n||"type"in n?Ge(n.position):"start"in n||"end"in n?Ge(n):"line"in n||"column"in n?de(n):""}function de(n){return Je(n&&n.line)+":"+Je(n&&n.column)}function Ge(n){return de(n&&n.start)+"-"+de(n&&n.end)}function Je(n){return n&&typeof n=="number"?n:1}class K extends Error{constructor(e,t,r){super(),typeof t=="string"&&(r=t,t=void 0);let i="",l={},o=!1;if(t&&("line"in t&&"column"in t?l={place:t}:"start"in t&&"end"in t?l={place:t}:"type"in t?l={ancestors:[t],place:t.position}:l={...t}),typeof e=="string"?i=e:!l.cause&&e&&(o=!0,i=e.message,l.cause=e),!l.ruleId&&!l.source&&typeof r=="string"){const u=r.indexOf(":");u===-1?l.ruleId=r:(l.source=r.slice(0,u),l.ruleId=r.slice(u+1))}if(!l.place&&l.ancestors&&l.ancestors){const u=l.ancestors[l.ancestors.length-1];u&&(l.place=u.position)}const a=l.place&&"start"in l.place?l.place.start:l.place;this.ancestors=l.ancestors||void 0,this.cause=l.cause||void 0,this.column=a?a.column:void 0,this.fatal=void 0,this.file,this.message=i,this.line=a?a.line:void 0,this.name=Nn(l.place)||"1:1",this.place=l.place||void 0,this.reason=this.message,this.ruleId=l.ruleId||void 0,this.source=l.source||void 0,this.stack=o&&l.cause&&typeof l.cause.stack=="string"?l.cause.stack:"",this.actual,this.expected,this.note,this.url}}K.prototype.file="";K.prototype.name="";K.prototype.reason="";K.prototype.message="";K.prototype.stack="";K.prototype.column=void 0;K.prototype.line=void 0;K.prototype.ancestors=void 0;K.prototype.cause=void 0;K.prototype.fatal=void 0;K.prototype.place=void 0;K.prototype.ruleId=void 0;K.prototype.source=void 0;const Ie={}.hasOwnProperty,ki=new Map,bi=/[A-Z]/g,wi=/-([a-z])/g,Si=new Set(["table","tbody","thead","tfoot","tr"]),Ci=new Set(["td","th"]),Wt="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function Ei(n,e){if(!e||e.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const t=e.filePath||void 0;let r;if(e.development){if(typeof e.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=Di(t,e.jsxDEV)}else{if(typeof e.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof e.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=Oi(t,e.jsx,e.jsxs)}const i={Fragment:e.Fragment,ancestors:[],components:e.components||{},create:r,elementAttributeNameCase:e.elementAttributeNameCase||"react",evaluater:e.createEvaluater?e.createEvaluater():void 0,filePath:t,ignoreInvalidStyle:e.ignoreInvalidStyle||!1,passKeys:e.passKeys!==!1,passNode:e.passNode||!1,schema:e.space==="svg"?Ce:ei,stylePropertyNameCase:e.stylePropertyNameCase||"dom",tableCellAlignToStyle:e.tableCellAlignToStyle!==!1},l=Qt(i,n,void 0);return l&&typeof l!="string"?l:i.create(n,i.Fragment,{children:l||void 0},void 0)}function Qt(n,e,t){if(e.type==="element")return Ii(n,e,t);if(e.type==="mdxFlowExpression"||e.type==="mdxTextExpression")return Ai(n,e);if(e.type==="mdxJsxFlowElement"||e.type==="mdxJsxTextElement")return Ti(n,e,t);if(e.type==="mdxjsEsm")return Pi(n,e);if(e.type==="root")return zi(n,e,t);if(e.type==="text")return Li(n,e)}function Ii(n,e,t){const r=n.schema;let i=r;e.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=Ce,n.schema=i),n.ancestors.push(e);const l=Yt(n,e.tagName,!1),o=vi(n,e);let a=Pe(n,e);return Si.has(e.tagName)&&(a=a.filter(function(u){return typeof u=="string"?!qr(u):!0})),Xt(n,o,l,e),Ae(o,a),n.ancestors.pop(),n.schema=r,n.create(e,l,o,t)}function Ai(n,e){if(e.data&&e.data.estree&&n.evaluater){const r=e.data.estree.body[0];return r.type,n.evaluater.evaluateExpression(r.expression)}_n(n,e.position)}function Pi(n,e){if(e.data&&e.data.estree&&n.evaluater)return n.evaluater.evaluateProgram(e.data.estree);_n(n,e.position)}function Ti(n,e,t){const r=n.schema;let i=r;e.name==="svg"&&r.space==="html"&&(i=Ce,n.schema=i),n.ancestors.push(e);const l=e.name===null?n.Fragment:Yt(n,e.name,!0),o=Fi(n,e),a=Pe(n,e);return Xt(n,o,l,e),Ae(o,a),n.ancestors.pop(),n.schema=r,n.create(e,l,o,t)}function zi(n,e,t){const r={};return Ae(r,Pe(n,e)),n.create(e,n.Fragment,r,t)}function Li(n,e){return e.value}function Xt(n,e,t,r){typeof t!="string"&&t!==n.Fragment&&n.passNode&&(e.node=r)}function Ae(n,e){if(e.length>0){const t=e.length>1?e:e[0];t&&(n.children=t)}}function Oi(n,e,t){return r;function r(i,l,o,a){const s=Array.isArray(o.children)?t:e;return a?s(l,o,a):s(l,o)}}function Di(n,e){return t;function t(r,i,l,o){const a=Array.isArray(l.children),u=Ee(r);return e(i,l,o,a,{columnNumber:u?u.column-1:void 0,fileName:n,lineNumber:u?u.line:void 0},void 0)}}function vi(n,e){const t={};let r,i;for(i in e.properties)if(i!=="children"&&Ie.call(e.properties,i)){const l=Ri(n,i,e.properties[i]);if(l){const[o,a]=l;n.tableCellAlignToStyle&&o==="align"&&typeof a=="string"&&Ci.has(e.tagName)?r=a:t[o]=a}}if(r){const l=t.style||(t.style={});l[n.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return t}function Fi(n,e){const t={};for(const r of e.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&n.evaluater){const l=r.data.estree.body[0];l.type;const o=l.expression;o.type;const a=o.properties[0];a.type,Object.assign(t,n.evaluater.evaluateExpression(a.argument))}else _n(n,e.position);else{const i=r.name;let l;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&n.evaluater){const a=r.value.data.estree.body[0];a.type,l=n.evaluater.evaluateExpression(a.expression)}else _n(n,e.position);else l=r.value===null?!0:r.value;t[i]=l}return t}function Pe(n,e){const t=[];let r=-1;const i=n.passKeys?new Map:ki;for(;++ri?0:i+e:e=e>i?i:e,t=t>0?t:0,r.length<1e4)o=Array.from(r),o.unshift(e,t),n.splice(...o);else for(t&&n.splice(e,t);l0?(pn(n,n.length,0,e),n):e}const et={}.hasOwnProperty;function qi(n){const e={};let t=-1;for(;++t13&&t<32||t>126&&t<160||t>55295&&t<57344||t>64975&&t<65008||(t&65535)===65535||(t&65535)===65534||t>1114111?"�":String.fromCodePoint(t)}function Tn(n){return n.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Qi=xn(/\p{P}/u),cn=xn(/[A-Za-z]/),en=xn(/[\dA-Za-z]/),Xi=xn(/[#-'*+\--9=?A-Z^-~]/);function ge(n){return n!==null&&(n<32||n===127)}const ye=xn(/\d/),Yi=xn(/[\dA-Fa-f]/),Jt=xn(/[!-/:-@[-`{-~]/);function T(n){return n!==null&&n<-2}function J(n){return n!==null&&(n<0||n===32)}function B(n){return n===-2||n===-1||n===32}function Ki(n){return Jt(n)||Qi(n)}const Gi=xn(/\s/);function xn(n){return e;function e(t){return t!==null&&t>-1&&n.test(String.fromCharCode(t))}}function On(n){const e=[];let t=-1,r=0,i=0;for(;++t55295&&l<57344){const a=n.charCodeAt(t+1);l<56320&&a>56319&&a<57344?(o=String.fromCharCode(l,a),i=1):o="�"}else o=String.fromCharCode(l);o&&(e.push(n.slice(r,t),encodeURIComponent(o)),r=t+i+1,o=""),i&&(t+=i,i=0)}return e.join("")+n.slice(r)}function j(n,e,t,r){const i=r?r-1:Number.POSITIVE_INFINITY;let l=0;return o;function o(u){return B(u)?(n.enter(t),a(u)):e(u)}function a(u){return B(u)&&l++o))return;const R=e.events.length;let q=R,M,H;for(;q--;)if(e.events[q][0]==="exit"&&e.events[q][1].type==="chunkFlow"){if(M){H=e.events[q][1].end;break}M=!0}for(w(r),x=R;xC;){const O=t[D];e.containerState=O[1],O[0].exit.call(e,n)}t.length=C}function E(){i.write([null]),l=void 0,i=void 0,e.containerState._closeFlow=void 0}}function tl(n,e,t){return j(n,n.attempt(this.parser.constructs.document,e,t),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function rt(n){if(n===null||J(n)||Gi(n))return 1;if(Ki(n))return 2}function ze(n,e,t){const r=[];let i=-1;for(;++i1&&n[t][1].end.offset-n[t][1].start.offset>1?2:1;const f=Object.assign({},n[r][1].end),d=Object.assign({},n[t][1].start);it(f,-u),it(d,u),o={type:u>1?"strongSequence":"emphasisSequence",start:f,end:Object.assign({},n[r][1].end)},a={type:u>1?"strongSequence":"emphasisSequence",start:Object.assign({},n[t][1].start),end:d},l={type:u>1?"strongText":"emphasisText",start:Object.assign({},n[r][1].end),end:Object.assign({},n[t][1].start)},i={type:u>1?"strong":"emphasis",start:Object.assign({},o.start),end:Object.assign({},a.end)},n[r][1].end=Object.assign({},o.start),n[t][1].start=Object.assign({},a.end),s=[],n[r][1].end.offset-n[r][1].start.offset&&(s=tn(s,[["enter",n[r][1],e],["exit",n[r][1],e]])),s=tn(s,[["enter",i,e],["enter",o,e],["exit",o,e],["enter",l,e]]),s=tn(s,ze(e.parser.constructs.insideSpan.null,n.slice(r+1,t),e)),s=tn(s,[["exit",l,e],["enter",a,e],["exit",a,e],["exit",i,e]]),n[t][1].end.offset-n[t][1].start.offset?(c=2,s=tn(s,[["enter",n[t][1],e],["exit",n[t][1],e]])):c=0,pn(n,r-1,t-r+3,s),t=r+s.length-c-2;break}}for(t=-1;++t0&&B(x)?j(n,E,"linePrefix",l+1)(x):E(x)}function E(x){return x===null||T(x)?n.check(lt,k,D)(x):(n.enter("codeFlowValue"),C(x))}function C(x){return x===null||T(x)?(n.exit("codeFlowValue"),E(x)):(n.consume(x),C)}function D(x){return n.exit("codeFenced"),e(x)}function O(x,R,q){let M=0;return H;function H(F){return x.enter("lineEnding"),x.consume(F),x.exit("lineEnding"),P}function P(F){return x.enter("codeFencedFence"),B(F)?j(x,A,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(F):A(F)}function A(F){return F===a?(x.enter("codeFencedFenceSequence"),U(F)):q(F)}function U(F){return F===a?(M++,x.consume(F),U):M>=o?(x.exit("codeFencedFenceSequence"),B(F)?j(x,$,"whitespace")(F):$(F)):q(F)}function $(F){return F===null||T(F)?(x.exit("codeFencedFence"),R(F)):q(F)}}}function ml(n,e,t){const r=this;return i;function i(o){return o===null?t(o):(n.enter("lineEnding"),n.consume(o),n.exit("lineEnding"),l)}function l(o){return r.parser.lazy[r.now().line]?t(o):e(o)}}const re={name:"codeIndented",tokenize:gl},dl={tokenize:yl,partial:!0};function gl(n,e,t){const r=this;return i;function i(s){return n.enter("codeIndented"),j(n,l,"linePrefix",4+1)(s)}function l(s){const c=r.events[r.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?o(s):t(s)}function o(s){return s===null?u(s):T(s)?n.attempt(dl,o,u)(s):(n.enter("codeFlowValue"),a(s))}function a(s){return s===null||T(s)?(n.exit("codeFlowValue"),o(s)):(n.consume(s),a)}function u(s){return n.exit("codeIndented"),e(s)}}function yl(n,e,t){const r=this;return i;function i(o){return r.parser.lazy[r.now().line]?t(o):T(o)?(n.enter("lineEnding"),n.consume(o),n.exit("lineEnding"),i):j(n,l,"linePrefix",4+1)(o)}function l(o){const a=r.events[r.events.length-1];return a&&a[1].type==="linePrefix"&&a[2].sliceSerialize(a[1],!0).length>=4?e(o):T(o)?i(o):t(o)}}const xl={name:"codeText",tokenize:wl,resolve:kl,previous:bl};function kl(n){let e=n.length-4,t=3,r,i;if((n[t][1].type==="lineEnding"||n[t][1].type==="space")&&(n[e][1].type==="lineEnding"||n[e][1].type==="space")){for(r=t;++r=4?e(o):n.interrupt(r.parser.constructs.flow,t,e)(o)}}function rr(n,e,t,r,i,l,o,a,u){const s=u||Number.POSITIVE_INFINITY;let c=0;return f;function f(w){return w===60?(n.enter(r),n.enter(i),n.enter(l),n.consume(w),n.exit(l),d):w===null||w===32||w===41||ge(w)?t(w):(n.enter(r),n.enter(o),n.enter(a),n.enter("chunkString",{contentType:"string"}),k(w))}function d(w){return w===62?(n.enter(l),n.consume(w),n.exit(l),n.exit(i),n.exit(r),e):(n.enter(a),n.enter("chunkString",{contentType:"string"}),p(w))}function p(w){return w===62?(n.exit("chunkString"),n.exit(a),d(w)):w===null||w===60||T(w)?t(w):(n.consume(w),w===92?y:p)}function y(w){return w===60||w===62||w===92?(n.consume(w),p):p(w)}function k(w){return!c&&(w===null||w===41||J(w))?(n.exit("chunkString"),n.exit(a),n.exit(o),n.exit(r),e(w)):c999||p===null||p===91||p===93&&!u||p===94&&!a&&"_hiddenFootnoteSupport"in o.parser.constructs?t(p):p===93?(n.exit(l),n.enter(i),n.consume(p),n.exit(i),n.exit(r),e):T(p)?(n.enter("lineEnding"),n.consume(p),n.exit("lineEnding"),c):(n.enter("chunkString",{contentType:"string"}),f(p))}function f(p){return p===null||p===91||p===93||T(p)||a++>999?(n.exit("chunkString"),c(p)):(n.consume(p),u||(u=!B(p)),p===92?d:f)}function d(p){return p===91||p===92||p===93?(n.consume(p),a++,f):f(p)}}function lr(n,e,t,r,i,l){let o;return a;function a(d){return d===34||d===39||d===40?(n.enter(r),n.enter(i),n.consume(d),n.exit(i),o=d===40?41:d,u):t(d)}function u(d){return d===o?(n.enter(i),n.consume(d),n.exit(i),n.exit(r),e):(n.enter(l),s(d))}function s(d){return d===o?(n.exit(l),u(o)):d===null?t(d):T(d)?(n.enter("lineEnding"),n.consume(d),n.exit("lineEnding"),j(n,s,"linePrefix")):(n.enter("chunkString",{contentType:"string"}),c(d))}function c(d){return d===o||d===null||T(d)?(n.exit("chunkString"),s(d)):(n.consume(d),d===92?f:c)}function f(d){return d===o||d===92?(n.consume(d),c):c(d)}}function Mn(n,e){let t;return r;function r(i){return T(i)?(n.enter("lineEnding"),n.consume(i),n.exit("lineEnding"),t=!0,r):B(i)?j(n,r,t?"linePrefix":"lineSuffix")(i):e(i)}}const Tl={name:"definition",tokenize:Ll},zl={tokenize:Ol,partial:!0};function Ll(n,e,t){const r=this;let i;return l;function l(p){return n.enter("definition"),o(p)}function o(p){return ir.call(r,n,a,t,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function a(p){return i=Tn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),p===58?(n.enter("definitionMarker"),n.consume(p),n.exit("definitionMarker"),u):t(p)}function u(p){return J(p)?Mn(n,s)(p):s(p)}function s(p){return rr(n,c,t,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(p)}function c(p){return n.attempt(zl,f,f)(p)}function f(p){return B(p)?j(n,d,"whitespace")(p):d(p)}function d(p){return p===null||T(p)?(n.exit("definition"),r.parser.defined.push(i),e(p)):t(p)}}function Ol(n,e,t){return r;function r(a){return J(a)?Mn(n,i)(a):t(a)}function i(a){return lr(n,l,t,"definitionTitle","definitionTitleMarker","definitionTitleString")(a)}function l(a){return B(a)?j(n,o,"whitespace")(a):o(a)}function o(a){return a===null||T(a)?e(a):t(a)}}const Dl={name:"hardBreakEscape",tokenize:vl};function vl(n,e,t){return r;function r(l){return n.enter("hardBreakEscape"),n.consume(l),i}function i(l){return T(l)?(n.exit("hardBreakEscape"),e(l)):t(l)}}const Fl={name:"headingAtx",tokenize:Bl,resolve:Rl};function Rl(n,e){let t=n.length-2,r=3,i,l;return n[r][1].type==="whitespace"&&(r+=2),t-2>r&&n[t][1].type==="whitespace"&&(t-=2),n[t][1].type==="atxHeadingSequence"&&(r===t-1||t-4>r&&n[t-2][1].type==="whitespace")&&(t-=r+1===t?2:4),t>r&&(i={type:"atxHeadingText",start:n[r][1].start,end:n[t][1].end},l={type:"chunkText",start:n[r][1].start,end:n[t][1].end,contentType:"text"},pn(n,r,t-r+1,[["enter",i,e],["enter",l,e],["exit",l,e],["exit",i,e]])),n}function Bl(n,e,t){let r=0;return i;function i(c){return n.enter("atxHeading"),l(c)}function l(c){return n.enter("atxHeadingSequence"),o(c)}function o(c){return c===35&&r++<6?(n.consume(c),o):c===null||J(c)?(n.exit("atxHeadingSequence"),a(c)):t(c)}function a(c){return c===35?(n.enter("atxHeadingSequence"),u(c)):c===null||T(c)?(n.exit("atxHeading"),e(c)):B(c)?j(n,a,"whitespace")(c):(n.enter("atxHeadingText"),s(c))}function u(c){return c===35?(n.consume(c),u):(n.exit("atxHeadingSequence"),a(c))}function s(c){return c===null||c===35||J(c)?(n.exit("atxHeadingText"),a(c)):(n.consume(c),s)}}const Nl=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],at=["pre","script","style","textarea"],Ml={name:"htmlFlow",tokenize:Ul,resolveTo:Hl,concrete:!0},_l={tokenize:ql,partial:!0},jl={tokenize:Vl,partial:!0};function Hl(n){let e=n.length;for(;e--&&!(n[e][0]==="enter"&&n[e][1].type==="htmlFlow"););return e>1&&n[e-2][1].type==="linePrefix"&&(n[e][1].start=n[e-2][1].start,n[e+1][1].start=n[e-2][1].start,n.splice(e-2,2)),n}function Ul(n,e,t){const r=this;let i,l,o,a,u;return s;function s(m){return c(m)}function c(m){return n.enter("htmlFlow"),n.enter("htmlFlowData"),n.consume(m),f}function f(m){return m===33?(n.consume(m),d):m===47?(n.consume(m),l=!0,k):m===63?(n.consume(m),i=3,r.interrupt?e:h):cn(m)?(n.consume(m),o=String.fromCharCode(m),I):t(m)}function d(m){return m===45?(n.consume(m),i=2,p):m===91?(n.consume(m),i=5,a=0,y):cn(m)?(n.consume(m),i=4,r.interrupt?e:h):t(m)}function p(m){return m===45?(n.consume(m),r.interrupt?e:h):t(m)}function y(m){const an="CDATA[";return m===an.charCodeAt(a++)?(n.consume(m),a===an.length?r.interrupt?e:A:y):t(m)}function k(m){return cn(m)?(n.consume(m),o=String.fromCharCode(m),I):t(m)}function I(m){if(m===null||m===47||m===62||J(m)){const an=m===47,kn=o.toLowerCase();return!an&&!l&&at.includes(kn)?(i=1,r.interrupt?e(m):A(m)):Nl.includes(o.toLowerCase())?(i=6,an?(n.consume(m),w):r.interrupt?e(m):A(m)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?t(m):l?E(m):C(m))}return m===45||en(m)?(n.consume(m),o+=String.fromCharCode(m),I):t(m)}function w(m){return m===62?(n.consume(m),r.interrupt?e:A):t(m)}function E(m){return B(m)?(n.consume(m),E):H(m)}function C(m){return m===47?(n.consume(m),H):m===58||m===95||cn(m)?(n.consume(m),D):B(m)?(n.consume(m),C):H(m)}function D(m){return m===45||m===46||m===58||m===95||en(m)?(n.consume(m),D):O(m)}function O(m){return m===61?(n.consume(m),x):B(m)?(n.consume(m),O):C(m)}function x(m){return m===null||m===60||m===61||m===62||m===96?t(m):m===34||m===39?(n.consume(m),u=m,R):B(m)?(n.consume(m),x):q(m)}function R(m){return m===u?(n.consume(m),u=null,M):m===null||T(m)?t(m):(n.consume(m),R)}function q(m){return m===null||m===34||m===39||m===47||m===60||m===61||m===62||m===96||J(m)?O(m):(n.consume(m),q)}function M(m){return m===47||m===62||B(m)?C(m):t(m)}function H(m){return m===62?(n.consume(m),P):t(m)}function P(m){return m===null||T(m)?A(m):B(m)?(n.consume(m),P):t(m)}function A(m){return m===45&&i===2?(n.consume(m),Y):m===60&&i===1?(n.consume(m),Q):m===62&&i===4?(n.consume(m),on):m===63&&i===3?(n.consume(m),h):m===93&&i===5?(n.consume(m),fn):T(m)&&(i===6||i===7)?(n.exit("htmlFlowData"),n.check(_l,hn,U)(m)):m===null||T(m)?(n.exit("htmlFlowData"),U(m)):(n.consume(m),A)}function U(m){return n.check(jl,$,hn)(m)}function $(m){return n.enter("lineEnding"),n.consume(m),n.exit("lineEnding"),F}function F(m){return m===null||T(m)?U(m):(n.enter("htmlFlowData"),A(m))}function Y(m){return m===45?(n.consume(m),h):A(m)}function Q(m){return m===47?(n.consume(m),o="",ln):A(m)}function ln(m){if(m===62){const an=o.toLowerCase();return at.includes(an)?(n.consume(m),on):A(m)}return cn(m)&&o.length<8?(n.consume(m),o+=String.fromCharCode(m),ln):A(m)}function fn(m){return m===93?(n.consume(m),h):A(m)}function h(m){return m===62?(n.consume(m),on):m===45&&i===2?(n.consume(m),h):A(m)}function on(m){return m===null||T(m)?(n.exit("htmlFlowData"),hn(m)):(n.consume(m),on)}function hn(m){return n.exit("htmlFlow"),e(m)}}function Vl(n,e,t){const r=this;return i;function i(o){return T(o)?(n.enter("lineEnding"),n.consume(o),n.exit("lineEnding"),l):t(o)}function l(o){return r.parser.lazy[r.now().line]?t(o):e(o)}}function ql(n,e,t){return r;function r(i){return n.enter("lineEnding"),n.consume(i),n.exit("lineEnding"),n.attempt(Gn,e,t)}}const $l={name:"htmlText",tokenize:Wl};function Wl(n,e,t){const r=this;let i,l,o;return a;function a(h){return n.enter("htmlText"),n.enter("htmlTextData"),n.consume(h),u}function u(h){return h===33?(n.consume(h),s):h===47?(n.consume(h),O):h===63?(n.consume(h),C):cn(h)?(n.consume(h),q):t(h)}function s(h){return h===45?(n.consume(h),c):h===91?(n.consume(h),l=0,y):cn(h)?(n.consume(h),E):t(h)}function c(h){return h===45?(n.consume(h),p):t(h)}function f(h){return h===null?t(h):h===45?(n.consume(h),d):T(h)?(o=f,Q(h)):(n.consume(h),f)}function d(h){return h===45?(n.consume(h),p):f(h)}function p(h){return h===62?Y(h):h===45?d(h):f(h)}function y(h){const on="CDATA[";return h===on.charCodeAt(l++)?(n.consume(h),l===on.length?k:y):t(h)}function k(h){return h===null?t(h):h===93?(n.consume(h),I):T(h)?(o=k,Q(h)):(n.consume(h),k)}function I(h){return h===93?(n.consume(h),w):k(h)}function w(h){return h===62?Y(h):h===93?(n.consume(h),w):k(h)}function E(h){return h===null||h===62?Y(h):T(h)?(o=E,Q(h)):(n.consume(h),E)}function C(h){return h===null?t(h):h===63?(n.consume(h),D):T(h)?(o=C,Q(h)):(n.consume(h),C)}function D(h){return h===62?Y(h):C(h)}function O(h){return cn(h)?(n.consume(h),x):t(h)}function x(h){return h===45||en(h)?(n.consume(h),x):R(h)}function R(h){return T(h)?(o=R,Q(h)):B(h)?(n.consume(h),R):Y(h)}function q(h){return h===45||en(h)?(n.consume(h),q):h===47||h===62||J(h)?M(h):t(h)}function M(h){return h===47?(n.consume(h),Y):h===58||h===95||cn(h)?(n.consume(h),H):T(h)?(o=M,Q(h)):B(h)?(n.consume(h),M):Y(h)}function H(h){return h===45||h===46||h===58||h===95||en(h)?(n.consume(h),H):P(h)}function P(h){return h===61?(n.consume(h),A):T(h)?(o=P,Q(h)):B(h)?(n.consume(h),P):M(h)}function A(h){return h===null||h===60||h===61||h===62||h===96?t(h):h===34||h===39?(n.consume(h),i=h,U):T(h)?(o=A,Q(h)):B(h)?(n.consume(h),A):(n.consume(h),$)}function U(h){return h===i?(n.consume(h),i=void 0,F):h===null?t(h):T(h)?(o=U,Q(h)):(n.consume(h),U)}function $(h){return h===null||h===34||h===39||h===60||h===61||h===96?t(h):h===47||h===62||J(h)?M(h):(n.consume(h),$)}function F(h){return h===47||h===62||J(h)?M(h):t(h)}function Y(h){return h===62?(n.consume(h),n.exit("htmlTextData"),n.exit("htmlText"),e):t(h)}function Q(h){return n.exit("htmlTextData"),n.enter("lineEnding"),n.consume(h),n.exit("lineEnding"),ln}function ln(h){return B(h)?j(n,fn,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(h):fn(h)}function fn(h){return n.enter("htmlTextData"),o(h)}}const Le={name:"labelEnd",tokenize:Jl,resolveTo:Gl,resolveAll:Kl},Ql={tokenize:Zl},Xl={tokenize:no},Yl={tokenize:eo};function Kl(n){let e=-1;for(;++e=3&&(s===null||T(s))?(n.exit("thematicBreak"),e(s)):t(s)}function u(s){return s===i?(n.consume(s),r++,u):(n.exit("thematicBreakSequence"),B(s)?j(n,a,"whitespace")(s):a(s))}}const G={name:"list",tokenize:co,continuation:{tokenize:po},exit:ho},uo={tokenize:mo,partial:!0},so={tokenize:fo,partial:!0};function co(n,e,t){const r=this,i=r.events[r.events.length-1];let l=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,o=0;return a;function a(p){const y=r.containerState.type||(p===42||p===43||p===45?"listUnordered":"listOrdered");if(y==="listUnordered"?!r.containerState.marker||p===r.containerState.marker:ye(p)){if(r.containerState.type||(r.containerState.type=y,n.enter(y,{_container:!0})),y==="listUnordered")return n.enter("listItemPrefix"),p===42||p===45?n.check(Wn,t,s)(p):s(p);if(!r.interrupt||p===49)return n.enter("listItemPrefix"),n.enter("listItemValue"),u(p)}return t(p)}function u(p){return ye(p)&&++o<10?(n.consume(p),u):(!r.interrupt||o<2)&&(r.containerState.marker?p===r.containerState.marker:p===41||p===46)?(n.exit("listItemValue"),s(p)):t(p)}function s(p){return n.enter("listItemMarker"),n.consume(p),n.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||p,n.check(Gn,r.interrupt?t:c,n.attempt(uo,d,f))}function c(p){return r.containerState.initialBlankLine=!0,l++,d(p)}function f(p){return B(p)?(n.enter("listItemPrefixWhitespace"),n.consume(p),n.exit("listItemPrefixWhitespace"),d):t(p)}function d(p){return r.containerState.size=l+r.sliceSerialize(n.exit("listItemPrefix"),!0).length,e(p)}}function po(n,e,t){const r=this;return r.containerState._closeFlow=void 0,n.check(Gn,i,l);function i(a){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,j(n,e,"listItemIndent",r.containerState.size+1)(a)}function l(a){return r.containerState.furtherBlankLines||!B(a)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,o(a)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,n.attempt(so,e,o)(a))}function o(a){return r.containerState._closeFlow=!0,r.interrupt=void 0,j(n,n.attempt(G,e,t),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a)}}function fo(n,e,t){const r=this;return j(n,i,"listItemIndent",r.containerState.size+1);function i(l){const o=r.events[r.events.length-1];return o&&o[1].type==="listItemIndent"&&o[2].sliceSerialize(o[1],!0).length===r.containerState.size?e(l):t(l)}}function ho(n){n.exit(this.containerState.type)}function mo(n,e,t){const r=this;return j(n,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4+1);function i(l){const o=r.events[r.events.length-1];return!B(l)&&o&&o[1].type==="listItemPrefixWhitespace"?e(l):t(l)}}const ut={name:"setextUnderline",tokenize:yo,resolveTo:go};function go(n,e){let t=n.length,r,i,l;for(;t--;)if(n[t][0]==="enter"){if(n[t][1].type==="content"){r=t;break}n[t][1].type==="paragraph"&&(i=t)}else n[t][1].type==="content"&&n.splice(t,1),!l&&n[t][1].type==="definition"&&(l=t);const o={type:"setextHeading",start:Object.assign({},n[i][1].start),end:Object.assign({},n[n.length-1][1].end)};return n[i][1].type="setextHeadingText",l?(n.splice(i,0,["enter",o,e]),n.splice(l+1,0,["exit",n[r][1],e]),n[r][1].end=Object.assign({},n[l][1].end)):n[r][1]=o,n.push(["exit",o,e]),n}function yo(n,e,t){const r=this;let i;return l;function l(s){let c=r.events.length,f;for(;c--;)if(r.events[c][1].type!=="lineEnding"&&r.events[c][1].type!=="linePrefix"&&r.events[c][1].type!=="content"){f=r.events[c][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||f)?(n.enter("setextHeadingLine"),i=s,o(s)):t(s)}function o(s){return n.enter("setextHeadingLineSequence"),a(s)}function a(s){return s===i?(n.consume(s),a):(n.exit("setextHeadingLineSequence"),B(s)?j(n,u,"lineSuffix")(s):u(s))}function u(s){return s===null||T(s)?(n.exit("setextHeadingLine"),e(s)):t(s)}}const xo={tokenize:ko};function ko(n){const e=this,t=n.attempt(Gn,r,n.attempt(this.parser.constructs.flowInitial,i,j(n,n.attempt(this.parser.constructs.flow,i,n.attempt(Cl,i)),"linePrefix")));return t;function r(l){if(l===null){n.consume(l);return}return n.enter("lineEndingBlank"),n.consume(l),n.exit("lineEndingBlank"),e.currentConstruct=void 0,t}function i(l){if(l===null){n.consume(l);return}return n.enter("lineEnding"),n.consume(l),n.exit("lineEnding"),e.currentConstruct=void 0,t}}const bo={resolveAll:ar()},wo=or("string"),So=or("text");function or(n){return{tokenize:e,resolveAll:ar(n==="text"?Co:void 0)};function e(t){const r=this,i=this.parser.constructs[n],l=t.attempt(i,o,a);return o;function o(c){return s(c)?l(c):a(c)}function a(c){if(c===null){t.consume(c);return}return t.enter("data"),t.consume(c),u}function u(c){return s(c)?(t.exit("data"),l(c)):(t.consume(c),u)}function s(c){if(c===null)return!0;const f=i[c];let d=-1;if(f)for(;++d-1){const a=o[0];typeof a=="string"?o[0]=a.slice(r):o.shift()}l>0&&o.push(n[i].slice(0,l))}return o}function Ao(n,e){let t=-1;const r=[];let i;for(;++t0){const un=z.tokenStack[z.tokenStack.length-1];(un[1]||ct).call(z,void 0,un[0])}for(S.position={start:yn(g.length>0?g[0][1].start:{line:1,column:1,offset:0}),end:yn(g.length>0?g[g.length-2][1].end:{line:1,column:1,offset:0})},N=-1;++N`spacing-xs-${t}`),...gs.map(t=>`direction-xs-${t}`),...bs.map(t=>`wrap-xs-${t}`),...Mt.map(t=>`grid-xs-${t}`),...Mt.map(t=>`grid-sm-${t}`),...Mt.map(t=>`grid-md-${t}`),...Mt.map(t=>`grid-lg-${t}`),...Mt.map(t=>`grid-xl-${t}`)]),zt=xs,ms=["className","columns","columnSpacing","component","container","direction","item","rowSpacing","spacing","wrap","zeroMinWidth"];function xt(t){const e=parseFloat(t);return`${e}${String(t).replace(String(e),"")||"px"}`}function vs({theme:t,ownerState:e}){let n;return t.breakpoints.keys.reduce((r,a)=>{let o={};if(e[a]&&(n=e[a]),!n)return r;if(n===!0)o={flexBasis:0,flexGrow:1,maxWidth:"100%"};else if(n==="auto")o={flexBasis:"auto",flexGrow:0,flexShrink:0,maxWidth:"none",width:"auto"};else{const s=En({values:e.columns,breakpoints:t.breakpoints.values}),i=typeof s=="object"?s[a]:s;if(i==null)return r;const l=`${Math.round(n/i*1e8)/1e6}%`;let u={};if(e.container&&e.item&&e.columnSpacing!==0){const d=t.spacing(e.columnSpacing);if(d!=="0px"){const f=`calc(${l} + ${xt(d)})`;u={flexBasis:f,maxWidth:f}}}o=oe({flexBasis:l,flexGrow:0,maxWidth:l},u)}return t.breakpoints.values[a]===0?Object.assign(r,o):r[t.breakpoints.up(a)]=o,r},{})}function ys({theme:t,ownerState:e}){const n=En({values:e.direction,breakpoints:t.breakpoints.values});return gr({theme:t},n,r=>{const a={flexDirection:r};return r.indexOf("column")===0&&(a[`& > .${zt.item}`]={maxWidth:"none"}),a})}function Io({breakpoints:t,values:e}){let n="";Object.keys(e).forEach(a=>{n===""&&e[a]!==0&&(n=a)});const r=Object.keys(t).sort((a,o)=>t[a]-t[o]);return r.slice(0,r.indexOf(n))}function ws({theme:t,ownerState:e}){const{container:n,rowSpacing:r}=e;let a={};if(n&&r!==0){const o=En({values:r,breakpoints:t.breakpoints.values});let s;typeof o=="object"&&(s=Io({breakpoints:t.breakpoints.values,values:o})),a=gr({theme:t},o,(i,l)=>{var u;const d=t.spacing(i);return d!=="0px"?{marginTop:`-${xt(d)}`,[`& > .${zt.item}`]:{paddingTop:xt(d)}}:(u=s)!=null&&u.includes(l)?{}:{marginTop:0,[`& > .${zt.item}`]:{paddingTop:0}}})}return a}function Es({theme:t,ownerState:e}){const{container:n,columnSpacing:r}=e;let a={};if(n&&r!==0){const o=En({values:r,breakpoints:t.breakpoints.values});let s;typeof o=="object"&&(s=Io({breakpoints:t.breakpoints.values,values:o})),a=gr({theme:t},o,(i,l)=>{var u;const d=t.spacing(i);return d!=="0px"?{width:`calc(100% + ${xt(d)})`,marginLeft:`-${xt(d)}`,[`& > .${zt.item}`]:{paddingLeft:xt(d)}}:(u=s)!=null&&u.includes(l)?{}:{width:"100%",marginLeft:0,[`& > .${zt.item}`]:{paddingLeft:0}}})}return a}function Cs(t,e,n={}){if(!t||t<=0)return[];if(typeof t=="string"&&!Number.isNaN(Number(t))||typeof t=="number")return[n[`spacing-xs-${String(t)}`]];const r=[];return e.forEach(a=>{const o=t[a];Number(o)>0&&r.push(n[`spacing-${a}-${String(o)}`])}),r}const Ss=Wt("div",{name:"MuiGrid",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t,{container:r,direction:a,item:o,spacing:s,wrap:i,zeroMinWidth:l,breakpoints:u}=n;let d=[];r&&(d=Cs(s,u,e));const f=[];return u.forEach(h=>{const g=n[h];g&&f.push(e[`grid-${h}-${String(g)}`])}),[e.root,r&&e.container,o&&e.item,l&&e.zeroMinWidth,...d,a!=="row"&&e[`direction-xs-${String(a)}`],i!=="wrap"&&e[`wrap-xs-${String(i)}`],...f]}})(({ownerState:t})=>oe({boxSizing:"border-box"},t.container&&{display:"flex",flexWrap:"wrap",width:"100%"},t.item&&{margin:0},t.zeroMinWidth&&{minWidth:0},t.wrap!=="wrap"&&{flexWrap:t.wrap}),ys,ws,Es,vs);function _s(t,e){if(!t||t<=0)return[];if(typeof t=="string"&&!Number.isNaN(Number(t))||typeof t=="number")return[`spacing-xs-${String(t)}`];const n=[];return e.forEach(r=>{const a=t[r];if(Number(a)>0){const o=`spacing-${r}-${String(a)}`;n.push(o)}}),n}const js=t=>{const{classes:e,container:n,direction:r,item:a,spacing:o,wrap:s,zeroMinWidth:i,breakpoints:l}=t;let u=[];n&&(u=_s(o,l));const d=[];l.forEach(h=>{const g=t[h];g&&d.push(`grid-${h}-${String(g)}`)});const f={root:["root",n&&"container",a&&"item",i&&"zeroMinWidth",...u,r!=="row"&&`direction-xs-${String(r)}`,s!=="wrap"&&`wrap-xs-${String(s)}`,...d]};return $o(f,fs,e)},Os=y.forwardRef(function(e,n){const r=Oo({props:e,name:"MuiGrid"}),{breakpoints:a}=Ei(),o=Zi(r),{className:s,columns:i,columnSpacing:l,component:u="div",container:d=!1,direction:f="row",item:h=!1,rowSpacing:g,spacing:x=0,wrap:m="wrap",zeroMinWidth:v=!1}=o,w=Po(o,ms),_=g||x,B=l||x,P=y.useContext(la),T=d?i||12:P,M={},L=oe({},w);a.keys.forEach(S=>{w[S]!=null&&(M[S]=w[S],delete L[S])});const H=oe({},o,{columns:T,container:d,direction:f,item:h,rowSpacing:_,columnSpacing:B,wrap:m,zeroMinWidth:v,spacing:x},M,{breakpoints:a.keys}),V=js(H);return p.jsx(la.Provider,{value:T,children:p.jsx(Ss,oe({ownerState:H,className:To(V.root,s),as:u,ref:n},L))})}),je=Os;function Ps(t){return _o("MuiSwitch",t)}const Ts=jo("MuiSwitch",["root","edgeStart","edgeEnd","switchBase","colorPrimary","colorSecondary","sizeSmall","sizeMedium","checked","disabled","input","thumb","track"]),Q=Ts,$s=["className","color","edge","size","sx"],As=t=>{const{classes:e,edge:n,size:r,color:a,checked:o,disabled:s}=t,i={root:["root",n&&`edge${bt(n)}`,`size${bt(r)}`],switchBase:["switchBase",`color${bt(a)}`,o&&"checked",s&&"disabled"],thumb:["thumb"],track:["track"],input:["input"]},l=$o(i,Ps,e);return oe({},e,l)},Ms=Wt("span",{name:"MuiSwitch",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.edge&&e[`edge${bt(n.edge)}`],e[`size${bt(n.size)}`]]}})(({ownerState:t})=>oe({display:"inline-flex",width:34+12*2,height:14+12*2,overflow:"hidden",padding:12,boxSizing:"border-box",position:"relative",flexShrink:0,zIndex:0,verticalAlign:"middle","@media print":{colorAdjust:"exact"}},t.edge==="start"&&{marginLeft:-8},t.edge==="end"&&{marginRight:-8},t.size==="small"&&{width:40,height:24,padding:7,[`& .${Q.thumb}`]:{width:16,height:16},[`& .${Q.switchBase}`]:{padding:4,[`&.${Q.checked}`]:{transform:"translateX(16px)"}}})),ks=Wt(Hi,{name:"MuiSwitch",slot:"SwitchBase",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.switchBase,{[`& .${Q.input}`]:e.input},n.color!=="default"&&e[`color${bt(n.color)}`]]}})(({theme:t})=>({position:"absolute",top:0,left:0,zIndex:1,color:t.vars?t.vars.palette.Switch.defaultColor:`${t.palette.mode==="light"?t.palette.common.white:t.palette.grey[300]}`,transition:t.transitions.create(["left","transform"],{duration:t.transitions.duration.shortest}),[`&.${Q.checked}`]:{transform:"translateX(20px)"},[`&.${Q.disabled}`]:{color:t.vars?t.vars.palette.Switch.defaultDisabledColor:`${t.palette.mode==="light"?t.palette.grey[100]:t.palette.grey[600]}`},[`&.${Q.checked} + .${Q.track}`]:{opacity:.5},[`&.${Q.disabled} + .${Q.track}`]:{opacity:t.vars?t.vars.opacity.switchTrackDisabled:`${t.palette.mode==="light"?.12:.2}`},[`& .${Q.input}`]:{left:"-100%",width:"300%"}}),({theme:t,ownerState:e})=>oe({"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Zr(t.palette.action.active,t.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},e.color!=="default"&&{[`&.${Q.checked}`]:{color:(t.vars||t).palette[e.color].main,"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette[e.color].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Zr(t.palette[e.color].main,t.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${Q.disabled}`]:{color:t.vars?t.vars.palette.Switch[`${e.color}DisabledColor`]:`${t.palette.mode==="light"?Ci(t.palette[e.color].main,.62):Si(t.palette[e.color].main,.55)}`}},[`&.${Q.checked} + .${Q.track}`]:{backgroundColor:(t.vars||t).palette[e.color].main}})),Rs=Wt("span",{name:"MuiSwitch",slot:"Track",overridesResolver:(t,e)=>e.track})(({theme:t})=>({height:"100%",width:"100%",borderRadius:14/2,zIndex:-1,transition:t.transitions.create(["opacity","background-color"],{duration:t.transitions.duration.shortest}),backgroundColor:t.vars?t.vars.palette.common.onBackground:`${t.palette.mode==="light"?t.palette.common.black:t.palette.common.white}`,opacity:t.vars?t.vars.opacity.switchTrack:`${t.palette.mode==="light"?.38:.3}`})),Bs=Wt("span",{name:"MuiSwitch",slot:"Thumb",overridesResolver:(t,e)=>e.thumb})(({theme:t})=>({boxShadow:(t.vars||t).shadows[1],backgroundColor:"currentColor",width:20,height:20,borderRadius:"50%"})),Fs=y.forwardRef(function(e,n){const r=Oo({props:e,name:"MuiSwitch"}),{className:a,color:o="primary",edge:s=!1,size:i="medium",sx:l}=r,u=Po(r,$s),d=oe({},r,{color:o,edge:s,size:i}),f=As(d),h=p.jsx(Bs,{className:f.thumb,ownerState:d});return p.jsxs(Ms,{className:To(f.root,a),sx:l,ownerState:d,children:[p.jsx(ks,oe({type:"checkbox",icon:h,checkedIcon:h,ref:n,ownerState:d},u,{classes:oe({},f,{root:f.switchBase})})),p.jsx(Rs,{className:f.track,ownerState:d})]})}),Do=Fs;var Ns=Object.defineProperty,Is=(t,e,n)=>e in t?Ns(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,R=(t,e,n)=>(Is(t,typeof e!="symbol"?e+"":e,n),n);const un=new is,ca=new ss,Ds=Math.cos(70*(Math.PI/180)),ua=(t,e)=>(t%e+e)%e;let Hs=class extends ls{constructor(e,n){super(),R(this,"object"),R(this,"domElement"),R(this,"enabled",!0),R(this,"target",new G),R(this,"minDistance",0),R(this,"maxDistance",1/0),R(this,"minZoom",0),R(this,"maxZoom",1/0),R(this,"minPolarAngle",0),R(this,"maxPolarAngle",Math.PI),R(this,"minAzimuthAngle",-1/0),R(this,"maxAzimuthAngle",1/0),R(this,"enableDamping",!1),R(this,"dampingFactor",.05),R(this,"enableZoom",!0),R(this,"zoomSpeed",1),R(this,"enableRotate",!0),R(this,"rotateSpeed",1),R(this,"enablePan",!0),R(this,"panSpeed",1),R(this,"screenSpacePanning",!0),R(this,"keyPanSpeed",7),R(this,"zoomToCursor",!1),R(this,"autoRotate",!1),R(this,"autoRotateSpeed",2),R(this,"reverseOrbit",!1),R(this,"reverseHorizontalOrbit",!1),R(this,"reverseVerticalOrbit",!1),R(this,"keys",{LEFT:"ArrowLeft",UP:"ArrowUp",RIGHT:"ArrowRight",BOTTOM:"ArrowDown"}),R(this,"mouseButtons",{LEFT:qe.ROTATE,MIDDLE:qe.DOLLY,RIGHT:qe.PAN}),R(this,"touches",{ONE:Ze.ROTATE,TWO:Ze.DOLLY_PAN}),R(this,"target0"),R(this,"position0"),R(this,"zoom0"),R(this,"_domElementKeyEvents",null),R(this,"getPolarAngle"),R(this,"getAzimuthalAngle"),R(this,"setPolarAngle"),R(this,"setAzimuthalAngle"),R(this,"getDistance"),R(this,"listenToKeyEvents"),R(this,"stopListenToKeyEvents"),R(this,"saveState"),R(this,"reset"),R(this,"update"),R(this,"connect"),R(this,"dispose"),this.object=e,this.domElement=n,this.target0=this.target.clone(),this.position0=this.object.position.clone(),this.zoom0=this.object.zoom,this.getPolarAngle=()=>d.phi,this.getAzimuthalAngle=()=>d.theta,this.setPolarAngle=b=>{let C=ua(b,2*Math.PI),F=d.phi;F<0&&(F+=2*Math.PI),C<0&&(C+=2*Math.PI);let U=Math.abs(C-F);2*Math.PI-U{let C=ua(b,2*Math.PI),F=d.theta;F<0&&(F+=2*Math.PI),C<0&&(C+=2*Math.PI);let U=Math.abs(C-F);2*Math.PI-Ur.object.position.distanceTo(r.target),this.listenToKeyEvents=b=>{b.addEventListener("keydown",jt),this._domElementKeyEvents=b},this.stopListenToKeyEvents=()=>{this._domElementKeyEvents.removeEventListener("keydown",jt),this._domElementKeyEvents=null},this.saveState=()=>{r.target0.copy(r.target),r.position0.copy(r.object.position),r.zoom0=r.object.zoom},this.reset=()=>{r.target.copy(r.target0),r.object.position.copy(r.position0),r.object.zoom=r.zoom0,r.object.updateProjectionMatrix(),r.dispatchEvent(a),r.update(),l=i.NONE},this.update=(()=>{const b=new G,C=new G(0,1,0),F=new ia().setFromUnitVectors(e.up,C),U=F.clone().invert(),Z=new G,we=new ia,Me=2*Math.PI;return function(){const qr=r.object.position;F.setFromUnitVectors(e.up,C),U.copy(F).invert(),b.copy(qr).sub(r.target),b.applyQuaternion(F),d.setFromVector3(b),r.autoRotate&&l===i.NONE&&K(X()),r.enableDamping?(d.theta+=f.theta*r.dampingFactor,d.phi+=f.phi*r.dampingFactor):(d.theta+=f.theta,d.phi+=f.phi);let Ee=r.minAzimuthAngle,Ce=r.maxAzimuthAngle;isFinite(Ee)&&isFinite(Ce)&&(Ee<-Math.PI?Ee+=Me:Ee>Math.PI&&(Ee-=Me),Ce<-Math.PI?Ce+=Me:Ce>Math.PI&&(Ce-=Me),Ee<=Ce?d.theta=Math.max(Ee,Math.min(Ce,d.theta)):d.theta=d.theta>(Ee+Ce)/2?Math.max(Ee,d.theta):Math.min(Ce,d.theta)),d.phi=Math.max(r.minPolarAngle,Math.min(r.maxPolarAngle,d.phi)),d.makeSafe(),r.enableDamping===!0?r.target.addScaledVector(g,r.dampingFactor):r.target.add(g),r.zoomToCursor&&V||r.object.isOrthographicCamera?d.radius=Fe(d.radius):d.radius=Fe(d.radius*h),b.setFromSpherical(d),b.applyQuaternion(U),qr.copy(r.target).add(b),r.object.matrixAutoUpdate||r.object.updateMatrix(),r.object.lookAt(r.target),r.enableDamping===!0?(f.theta*=1-r.dampingFactor,f.phi*=1-r.dampingFactor,g.multiplyScalar(1-r.dampingFactor)):(f.set(0,0,0),g.set(0,0,0));let on=!1;if(r.zoomToCursor&&V){let $t=null;if(r.object instanceof ln&&r.object.isPerspectiveCamera){const At=b.length();$t=Fe(At*h);const sn=At-$t;r.object.position.addScaledVector(L,sn),r.object.updateMatrixWorld()}else if(r.object.isOrthographicCamera){const At=new G(H.x,H.y,0);At.unproject(r.object),r.object.zoom=Math.max(r.minZoom,Math.min(r.maxZoom,r.object.zoom/h)),r.object.updateProjectionMatrix(),on=!0;const sn=new G(H.x,H.y,0);sn.unproject(r.object),r.object.position.sub(sn).add(At),r.object.updateMatrixWorld(),$t=b.length()}else console.warn("WARNING: OrbitControls.js encountered an unknown camera type - zoom to cursor disabled."),r.zoomToCursor=!1;$t!==null&&(r.screenSpacePanning?r.target.set(0,0,-1).transformDirection(r.object.matrix).multiplyScalar($t).add(r.object.position):(un.origin.copy(r.object.position),un.direction.set(0,0,-1).transformDirection(r.object.matrix),Math.abs(r.object.up.dot(un.direction))u||8*(1-we.dot(r.object.quaternion))>u?(r.dispatchEvent(a),Z.copy(r.object.position),we.copy(r.object.quaternion),on=!1,!0):!1}})(),this.connect=b=>{b===document&&console.error('THREE.OrbitControls: "document" should not be used as the target "domElement". Please use "renderer.domElement" instead.'),r.domElement=b,r.domElement.style.touchAction="none",r.domElement.addEventListener("contextmenu",Ot),r.domElement.addEventListener("pointerdown",Xe),r.domElement.addEventListener("pointercancel",z),r.domElement.addEventListener("wheel",le)},this.dispose=()=>{var b,C,F,U,Z,we;(b=r.domElement)==null||b.removeEventListener("contextmenu",Ot),(C=r.domElement)==null||C.removeEventListener("pointerdown",Xe),(F=r.domElement)==null||F.removeEventListener("pointercancel",z),(U=r.domElement)==null||U.removeEventListener("wheel",le),(Z=r.domElement)==null||Z.ownerDocument.removeEventListener("pointermove",Ke),(we=r.domElement)==null||we.ownerDocument.removeEventListener("pointerup",k),r._domElementKeyEvents!==null&&r._domElementKeyEvents.removeEventListener("keydown",jt)};const r=this,a={type:"change"},o={type:"start"},s={type:"end"},i={NONE:-1,ROTATE:0,DOLLY:1,PAN:2,TOUCH_ROTATE:3,TOUCH_PAN:4,TOUCH_DOLLY_PAN:5,TOUCH_DOLLY_ROTATE:6};let l=i.NONE;const u=1e-6,d=new sa,f=new sa;let h=1;const g=new G,x=new de,m=new de,v=new de,w=new de,_=new de,B=new de,P=new de,T=new de,M=new de,L=new G,H=new de;let V=!1;const S=[],D={};function X(){return 2*Math.PI/60/60*r.autoRotateSpeed}function I(){return Math.pow(.95,r.zoomSpeed)}function K(b){r.reverseOrbit||r.reverseHorizontalOrbit?f.theta+=b:f.theta-=b}function re(b){r.reverseOrbit||r.reverseVerticalOrbit?f.phi+=b:f.phi-=b}const xe=(()=>{const b=new G;return function(F,U){b.setFromMatrixColumn(U,0),b.multiplyScalar(-F),g.add(b)}})(),Te=(()=>{const b=new G;return function(F,U){r.screenSpacePanning===!0?b.setFromMatrixColumn(U,1):(b.setFromMatrixColumn(U,0),b.crossVectors(r.object.up,b)),b.multiplyScalar(F),g.add(b)}})(),pe=(()=>{const b=new G;return function(F,U){const Z=r.domElement;if(Z&&r.object instanceof ln&&r.object.isPerspectiveCamera){const we=r.object.position;b.copy(we).sub(r.target);let Me=b.length();Me*=Math.tan(r.object.fov/2*Math.PI/180),xe(2*F*Me/Z.clientHeight,r.object.matrix),Te(2*U*Me/Z.clientHeight,r.object.matrix)}else Z&&r.object instanceof cn&&r.object.isOrthographicCamera?(xe(F*(r.object.right-r.object.left)/r.object.zoom/Z.clientWidth,r.object.matrix),Te(U*(r.object.top-r.object.bottom)/r.object.zoom/Z.clientHeight,r.object.matrix)):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - pan disabled."),r.enablePan=!1)}})();function Et(b){r.object instanceof ln&&r.object.isPerspectiveCamera||r.object instanceof cn&&r.object.isOrthographicCamera?h/=b:(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),r.enableZoom=!1)}function Ue(b){r.object instanceof ln&&r.object.isPerspectiveCamera||r.object instanceof cn&&r.object.isOrthographicCamera?h*=b:(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),r.enableZoom=!1)}function $e(b){if(!r.zoomToCursor||!r.domElement)return;V=!0;const C=r.domElement.getBoundingClientRect(),F=b.clientX-C.left,U=b.clientY-C.top,Z=C.width,we=C.height;H.x=F/Z*2-1,H.y=-(U/we)*2+1,L.set(H.x,H.y,1).unproject(r.object).sub(r.object.position).normalize()}function Fe(b){return Math.max(r.minDistance,Math.min(r.maxDistance,b))}function ye(b){x.set(b.clientX,b.clientY)}function Ct(b){$e(b),P.set(b.clientX,b.clientY)}function St(b){w.set(b.clientX,b.clientY)}function kn(b){m.set(b.clientX,b.clientY),v.subVectors(m,x).multiplyScalar(r.rotateSpeed);const C=r.domElement;C&&(K(2*Math.PI*v.x/C.clientHeight),re(2*Math.PI*v.y/C.clientHeight)),x.copy(m),r.update()}function Jt(b){T.set(b.clientX,b.clientY),M.subVectors(T,P),M.y>0?Et(I()):M.y<0&&Ue(I()),P.copy(T),r.update()}function Rn(b){_.set(b.clientX,b.clientY),B.subVectors(_,w).multiplyScalar(r.panSpeed),pe(B.x,B.y),w.copy(_),r.update()}function ee(b){$e(b),b.deltaY<0?Ue(I()):b.deltaY>0&&Et(I()),r.update()}function Bn(b){let C=!1;switch(b.code){case r.keys.UP:pe(0,r.keyPanSpeed),C=!0;break;case r.keys.BOTTOM:pe(0,-r.keyPanSpeed),C=!0;break;case r.keys.LEFT:pe(r.keyPanSpeed,0),C=!0;break;case r.keys.RIGHT:pe(-r.keyPanSpeed,0),C=!0;break}C&&(b.preventDefault(),r.update())}function Ve(){if(S.length==1)x.set(S[0].pageX,S[0].pageY);else{const b=.5*(S[0].pageX+S[1].pageX),C=.5*(S[0].pageY+S[1].pageY);x.set(b,C)}}function Ae(){if(S.length==1)w.set(S[0].pageX,S[0].pageY);else{const b=.5*(S[0].pageX+S[1].pageX),C=.5*(S[0].pageY+S[1].pageY);w.set(b,C)}}function Qt(){const b=S[0].pageX-S[1].pageX,C=S[0].pageY-S[1].pageY,F=Math.sqrt(b*b+C*C);P.set(0,F)}function Fn(){r.enableZoom&&Qt(),r.enablePan&&Ae()}function Nn(){r.enableZoom&&Qt(),r.enableRotate&&Ve()}function _t(b){if(S.length==1)m.set(b.pageX,b.pageY);else{const F=Dn(b),U=.5*(b.pageX+F.x),Z=.5*(b.pageY+F.y);m.set(U,Z)}v.subVectors(m,x).multiplyScalar(r.rotateSpeed);const C=r.domElement;C&&(K(2*Math.PI*v.x/C.clientHeight),re(2*Math.PI*v.y/C.clientHeight)),x.copy(m)}function en(b){if(S.length==1)_.set(b.pageX,b.pageY);else{const C=Dn(b),F=.5*(b.pageX+C.x),U=.5*(b.pageY+C.y);_.set(F,U)}B.subVectors(_,w).multiplyScalar(r.panSpeed),pe(B.x,B.y),w.copy(_)}function tn(b){const C=Dn(b),F=b.pageX-C.x,U=b.pageY-C.y,Z=Math.sqrt(F*F+U*U);T.set(0,Z),M.set(0,Math.pow(T.y/P.y,r.zoomSpeed)),Et(M.y),P.copy(T)}function Ye(b){r.enableZoom&&tn(b),r.enablePan&&en(b)}function In(b){r.enableZoom&&tn(b),r.enableRotate&&_t(b)}function Xe(b){var C,F;r.enabled!==!1&&(S.length===0&&((C=r.domElement)==null||C.ownerDocument.addEventListener("pointermove",Ke),(F=r.domElement)==null||F.ownerDocument.addEventListener("pointerup",k)),an(b),b.pointerType==="touch"?nn(b):J(b))}function Ke(b){r.enabled!==!1&&(b.pointerType==="touch"?rn(b):se(b))}function k(b){var C,F,U;Pt(b),S.length===0&&((C=r.domElement)==null||C.releasePointerCapture(b.pointerId),(F=r.domElement)==null||F.ownerDocument.removeEventListener("pointermove",Ke),(U=r.domElement)==null||U.ownerDocument.removeEventListener("pointerup",k)),r.dispatchEvent(s),l=i.NONE}function z(b){Pt(b)}function J(b){let C;switch(b.button){case 0:C=r.mouseButtons.LEFT;break;case 1:C=r.mouseButtons.MIDDLE;break;case 2:C=r.mouseButtons.RIGHT;break;default:C=-1}switch(C){case qe.DOLLY:if(r.enableZoom===!1)return;Ct(b),l=i.DOLLY;break;case qe.ROTATE:if(b.ctrlKey||b.metaKey||b.shiftKey){if(r.enablePan===!1)return;St(b),l=i.PAN}else{if(r.enableRotate===!1)return;ye(b),l=i.ROTATE}break;case qe.PAN:if(b.ctrlKey||b.metaKey||b.shiftKey){if(r.enableRotate===!1)return;ye(b),l=i.ROTATE}else{if(r.enablePan===!1)return;St(b),l=i.PAN}break;default:l=i.NONE}l!==i.NONE&&r.dispatchEvent(o)}function se(b){if(r.enabled!==!1)switch(l){case i.ROTATE:if(r.enableRotate===!1)return;kn(b);break;case i.DOLLY:if(r.enableZoom===!1)return;Jt(b);break;case i.PAN:if(r.enablePan===!1)return;Rn(b);break}}function le(b){r.enabled===!1||r.enableZoom===!1||l!==i.NONE&&l!==i.ROTATE||(b.preventDefault(),r.dispatchEvent(o),ee(b),r.dispatchEvent(s))}function jt(b){r.enabled===!1||r.enablePan===!1||Bn(b)}function nn(b){switch(Tt(b),S.length){case 1:switch(r.touches.ONE){case Ze.ROTATE:if(r.enableRotate===!1)return;Ve(),l=i.TOUCH_ROTATE;break;case Ze.PAN:if(r.enablePan===!1)return;Ae(),l=i.TOUCH_PAN;break;default:l=i.NONE}break;case 2:switch(r.touches.TWO){case Ze.DOLLY_PAN:if(r.enableZoom===!1&&r.enablePan===!1)return;Fn(),l=i.TOUCH_DOLLY_PAN;break;case Ze.DOLLY_ROTATE:if(r.enableZoom===!1&&r.enableRotate===!1)return;Nn(),l=i.TOUCH_DOLLY_ROTATE;break;default:l=i.NONE}break;default:l=i.NONE}l!==i.NONE&&r.dispatchEvent(o)}function rn(b){switch(Tt(b),l){case i.TOUCH_ROTATE:if(r.enableRotate===!1)return;_t(b),r.update();break;case i.TOUCH_PAN:if(r.enablePan===!1)return;en(b),r.update();break;case i.TOUCH_DOLLY_PAN:if(r.enableZoom===!1&&r.enablePan===!1)return;Ye(b),r.update();break;case i.TOUCH_DOLLY_ROTATE:if(r.enableZoom===!1&&r.enableRotate===!1)return;In(b),r.update();break;default:l=i.NONE}}function Ot(b){r.enabled!==!1&&b.preventDefault()}function an(b){S.push(b)}function Pt(b){delete D[b.pointerId];for(let C=0;Cnew cs(void 0,void 0,void 0)),u=y.useCallback((f,h,g,x=20)=>(f instanceof G?l.v0.copy(f):l.v0.set(...f),h instanceof G?l.v2.copy(h):l.v2.set(...h),g instanceof G?l.v1.copy(g):l.v1.copy(l.v0.clone().add(l.v2.clone().sub(l.v0)).add(zs.set(0,l.v0.y-l.v2.y,0))),l.getPoints(x)),[]);y.useLayoutEffect(()=>{i.current.setPoints=(f,h,g)=>{const x=u(f,h,g);i.current.geometry&&i.current.geometry.setPositions(x.map(m=>m.toArray()).flat())}},[]);const d=y.useMemo(()=>u(e,n,r,a),[e,n,r,a]);return y.createElement(Ji,oe({ref:Qi([i,s]),points:d},o))}),Ls=y.forwardRef(({makeDefault:t,camera:e,regress:n,domElement:r,enableDamping:a=!0,onChange:o,onStart:s,onEnd:i,...l},u)=>{const d=me(T=>T.invalidate),f=me(T=>T.camera),h=me(T=>T.gl),g=me(T=>T.events),x=me(T=>T.setEvents),m=me(T=>T.set),v=me(T=>T.get),w=me(T=>T.performance),_=e||f,B=r||g.connected||h.domElement,P=y.useMemo(()=>new Hs(_),[_]);return Sn(()=>{P.enabled&&P.update()},-1),y.useEffect(()=>(P.connect(B),()=>void P.dispose()),[B,n,P,d]),y.useEffect(()=>{const T=H=>{d(),n&&w.regress(),o&&o(H)},M=H=>{s&&s(H)},L=H=>{i&&i(H)};return P.addEventListener("change",T),P.addEventListener("start",M),P.addEventListener("end",L),()=>{P.removeEventListener("start",M),P.removeEventListener("end",L),P.removeEventListener("change",T)}},[o,s,i,P,d,x]),y.useEffect(()=>{if(t){const T=v().controls;return m({controls:P}),()=>m({controls:T})}},[t,P]),y.createElement("primitive",oe({ref:u,object:P,enableDamping:a},l))}),Gs={type:"",parent:""},da=({onSelect:t,dataTestId:e,edgeLink:n,hideSelectAll:r,placeholder:a})=>{const o=br({mode:"onChange",defaultValues:Gs}),{watch:s,setValue:i}=o,[l,u]=y.useState([]),[d,f]=y.useState(!1),h=v=>{i("parent",(v==null?void 0:v.value)||""),t(v==null?void 0:v.value)},g=v=>v.charAt(0).toUpperCase()+v.slice(1);y.useEffect(()=>{(async()=>{f(!0);try{const _=(await xr()).schemas.filter(P=>!P.is_deleted&&P.type).map(P=>P.type==="thing"?{label:"No Parent",value:P.type}:{label:g(P.type),value:P.type}).filter((P,T,M)=>T===M.findIndex(L=>L.value===P.value));u(r?_:[{label:"Select all",value:"all"},..._]),n&&i("parent",n)}catch(w){console.warn(w)}finally{f(!1)}})()},[n,i,r]);const x=s("parent"),m=()=>{const v=l==null?void 0:l.find(w=>w.value===x);if(v)return v;if(n)return{label:n,value:n}};return p.jsx(Ws,{dataTestId:e,disabled:!!n,isLoading:d,onSelect:h,options:l||_i,placeholder:a,selectedValue:m()})},Ws=O(Dt)` +import{r as y,K as _o,L as jo,M as Wt,N as oe,P as Oo,a2 as Ei,G as Po,j as p,S as To,bB as En,bC as gr,U as $o,X as bt,O as Zr,ak as Ci,al as Si,s as O,a as j,t as br,bf as _i,be as xr,T as _e,F as $,aX as hn,aY as gn,bc as ji,B as Cn,bD as Oi,bE as Hn,v as Ao,bF as Pi,C as mr,bG as Ti,H as c,k as vr,ac as Jr,bH as $i,an as Ai,bI as Qr,bJ as Mo,bd as ko,e as Ro,bK as Mi,aW as gt,af as ar,d as yr,ae as ki,at as ea,a_ as Ri}from"./index-4e60c9e2.js";import{A as Dt}from"./index-d96216bb.js";import{C as Ie}from"./ClipLoader-8590c2f1.js";import{I as or,e as Bi,aq as Fi,q as Bo,aD as ta,aE as na,aF as ra,aG as aa,aH as Ni,aI as Ii,aJ as Di}from"./index-af5a3f81.js";import{S as Hi,j as zi,p as Li,q as Gi,r as Wi,m as Ui,F as Vi}from"./isPlainObject-1f2f9f4b.js";import{P as E}from"./index-37b3c15b.js";import{T as Yi,a as Xi}from"./Tabs-71f3fbcc.js";import{p as ir,c as Ki,g as qi}from"./index-5fe8c70d.js";import{e as Zi}from"./Stack-5870980a.js";import{g as Ji,m as Qi,u as me,a as Sn,t as sr,T as Fo,h as No,f as es,o as ts,H as ns,i as oa,k as rs,l as as,j as os}from"./index-c715ffeb.js";import{R as is,t as ss,u as ls,V as G,v as qe,w as Ze,Q as ia,x as ln,O as cn,y as sa,b as de,z as cs,n as us,C as ps}from"./three.module-71ec604c.js";import"./index-569670a3.js";import"./createSvgIcon-c125a9c8.js";import"./TextareaAutosize-f6242cb8.js";import"./Typography-2a31701b.js";const ds=y.createContext(),la=ds;function fs(t){return _o("MuiGrid",t)}const hs=[0,1,2,3,4,5,6,7,8,9,10],gs=["column-reverse","column","row-reverse","row"],bs=["nowrap","wrap-reverse","wrap"],Mt=["auto",!0,1,2,3,4,5,6,7,8,9,10,11,12],xs=jo("MuiGrid",["root","container","item","zeroMinWidth",...hs.map(t=>`spacing-xs-${t}`),...gs.map(t=>`direction-xs-${t}`),...bs.map(t=>`wrap-xs-${t}`),...Mt.map(t=>`grid-xs-${t}`),...Mt.map(t=>`grid-sm-${t}`),...Mt.map(t=>`grid-md-${t}`),...Mt.map(t=>`grid-lg-${t}`),...Mt.map(t=>`grid-xl-${t}`)]),zt=xs,ms=["className","columns","columnSpacing","component","container","direction","item","rowSpacing","spacing","wrap","zeroMinWidth"];function xt(t){const e=parseFloat(t);return`${e}${String(t).replace(String(e),"")||"px"}`}function vs({theme:t,ownerState:e}){let n;return t.breakpoints.keys.reduce((r,a)=>{let o={};if(e[a]&&(n=e[a]),!n)return r;if(n===!0)o={flexBasis:0,flexGrow:1,maxWidth:"100%"};else if(n==="auto")o={flexBasis:"auto",flexGrow:0,flexShrink:0,maxWidth:"none",width:"auto"};else{const s=En({values:e.columns,breakpoints:t.breakpoints.values}),i=typeof s=="object"?s[a]:s;if(i==null)return r;const l=`${Math.round(n/i*1e8)/1e6}%`;let u={};if(e.container&&e.item&&e.columnSpacing!==0){const d=t.spacing(e.columnSpacing);if(d!=="0px"){const f=`calc(${l} + ${xt(d)})`;u={flexBasis:f,maxWidth:f}}}o=oe({flexBasis:l,flexGrow:0,maxWidth:l},u)}return t.breakpoints.values[a]===0?Object.assign(r,o):r[t.breakpoints.up(a)]=o,r},{})}function ys({theme:t,ownerState:e}){const n=En({values:e.direction,breakpoints:t.breakpoints.values});return gr({theme:t},n,r=>{const a={flexDirection:r};return r.indexOf("column")===0&&(a[`& > .${zt.item}`]={maxWidth:"none"}),a})}function Io({breakpoints:t,values:e}){let n="";Object.keys(e).forEach(a=>{n===""&&e[a]!==0&&(n=a)});const r=Object.keys(t).sort((a,o)=>t[a]-t[o]);return r.slice(0,r.indexOf(n))}function ws({theme:t,ownerState:e}){const{container:n,rowSpacing:r}=e;let a={};if(n&&r!==0){const o=En({values:r,breakpoints:t.breakpoints.values});let s;typeof o=="object"&&(s=Io({breakpoints:t.breakpoints.values,values:o})),a=gr({theme:t},o,(i,l)=>{var u;const d=t.spacing(i);return d!=="0px"?{marginTop:`-${xt(d)}`,[`& > .${zt.item}`]:{paddingTop:xt(d)}}:(u=s)!=null&&u.includes(l)?{}:{marginTop:0,[`& > .${zt.item}`]:{paddingTop:0}}})}return a}function Es({theme:t,ownerState:e}){const{container:n,columnSpacing:r}=e;let a={};if(n&&r!==0){const o=En({values:r,breakpoints:t.breakpoints.values});let s;typeof o=="object"&&(s=Io({breakpoints:t.breakpoints.values,values:o})),a=gr({theme:t},o,(i,l)=>{var u;const d=t.spacing(i);return d!=="0px"?{width:`calc(100% + ${xt(d)})`,marginLeft:`-${xt(d)}`,[`& > .${zt.item}`]:{paddingLeft:xt(d)}}:(u=s)!=null&&u.includes(l)?{}:{width:"100%",marginLeft:0,[`& > .${zt.item}`]:{paddingLeft:0}}})}return a}function Cs(t,e,n={}){if(!t||t<=0)return[];if(typeof t=="string"&&!Number.isNaN(Number(t))||typeof t=="number")return[n[`spacing-xs-${String(t)}`]];const r=[];return e.forEach(a=>{const o=t[a];Number(o)>0&&r.push(n[`spacing-${a}-${String(o)}`])}),r}const Ss=Wt("div",{name:"MuiGrid",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t,{container:r,direction:a,item:o,spacing:s,wrap:i,zeroMinWidth:l,breakpoints:u}=n;let d=[];r&&(d=Cs(s,u,e));const f=[];return u.forEach(h=>{const g=n[h];g&&f.push(e[`grid-${h}-${String(g)}`])}),[e.root,r&&e.container,o&&e.item,l&&e.zeroMinWidth,...d,a!=="row"&&e[`direction-xs-${String(a)}`],i!=="wrap"&&e[`wrap-xs-${String(i)}`],...f]}})(({ownerState:t})=>oe({boxSizing:"border-box"},t.container&&{display:"flex",flexWrap:"wrap",width:"100%"},t.item&&{margin:0},t.zeroMinWidth&&{minWidth:0},t.wrap!=="wrap"&&{flexWrap:t.wrap}),ys,ws,Es,vs);function _s(t,e){if(!t||t<=0)return[];if(typeof t=="string"&&!Number.isNaN(Number(t))||typeof t=="number")return[`spacing-xs-${String(t)}`];const n=[];return e.forEach(r=>{const a=t[r];if(Number(a)>0){const o=`spacing-${r}-${String(a)}`;n.push(o)}}),n}const js=t=>{const{classes:e,container:n,direction:r,item:a,spacing:o,wrap:s,zeroMinWidth:i,breakpoints:l}=t;let u=[];n&&(u=_s(o,l));const d=[];l.forEach(h=>{const g=t[h];g&&d.push(`grid-${h}-${String(g)}`)});const f={root:["root",n&&"container",a&&"item",i&&"zeroMinWidth",...u,r!=="row"&&`direction-xs-${String(r)}`,s!=="wrap"&&`wrap-xs-${String(s)}`,...d]};return $o(f,fs,e)},Os=y.forwardRef(function(e,n){const r=Oo({props:e,name:"MuiGrid"}),{breakpoints:a}=Ei(),o=Zi(r),{className:s,columns:i,columnSpacing:l,component:u="div",container:d=!1,direction:f="row",item:h=!1,rowSpacing:g,spacing:x=0,wrap:m="wrap",zeroMinWidth:v=!1}=o,w=Po(o,ms),_=g||x,B=l||x,P=y.useContext(la),T=d?i||12:P,M={},L=oe({},w);a.keys.forEach(S=>{w[S]!=null&&(M[S]=w[S],delete L[S])});const H=oe({},o,{columns:T,container:d,direction:f,item:h,rowSpacing:_,columnSpacing:B,wrap:m,zeroMinWidth:v,spacing:x},M,{breakpoints:a.keys}),V=js(H);return p.jsx(la.Provider,{value:T,children:p.jsx(Ss,oe({ownerState:H,className:To(V.root,s),as:u,ref:n},L))})}),je=Os;function Ps(t){return _o("MuiSwitch",t)}const Ts=jo("MuiSwitch",["root","edgeStart","edgeEnd","switchBase","colorPrimary","colorSecondary","sizeSmall","sizeMedium","checked","disabled","input","thumb","track"]),Q=Ts,$s=["className","color","edge","size","sx"],As=t=>{const{classes:e,edge:n,size:r,color:a,checked:o,disabled:s}=t,i={root:["root",n&&`edge${bt(n)}`,`size${bt(r)}`],switchBase:["switchBase",`color${bt(a)}`,o&&"checked",s&&"disabled"],thumb:["thumb"],track:["track"],input:["input"]},l=$o(i,Ps,e);return oe({},e,l)},Ms=Wt("span",{name:"MuiSwitch",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.edge&&e[`edge${bt(n.edge)}`],e[`size${bt(n.size)}`]]}})(({ownerState:t})=>oe({display:"inline-flex",width:34+12*2,height:14+12*2,overflow:"hidden",padding:12,boxSizing:"border-box",position:"relative",flexShrink:0,zIndex:0,verticalAlign:"middle","@media print":{colorAdjust:"exact"}},t.edge==="start"&&{marginLeft:-8},t.edge==="end"&&{marginRight:-8},t.size==="small"&&{width:40,height:24,padding:7,[`& .${Q.thumb}`]:{width:16,height:16},[`& .${Q.switchBase}`]:{padding:4,[`&.${Q.checked}`]:{transform:"translateX(16px)"}}})),ks=Wt(Hi,{name:"MuiSwitch",slot:"SwitchBase",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.switchBase,{[`& .${Q.input}`]:e.input},n.color!=="default"&&e[`color${bt(n.color)}`]]}})(({theme:t})=>({position:"absolute",top:0,left:0,zIndex:1,color:t.vars?t.vars.palette.Switch.defaultColor:`${t.palette.mode==="light"?t.palette.common.white:t.palette.grey[300]}`,transition:t.transitions.create(["left","transform"],{duration:t.transitions.duration.shortest}),[`&.${Q.checked}`]:{transform:"translateX(20px)"},[`&.${Q.disabled}`]:{color:t.vars?t.vars.palette.Switch.defaultDisabledColor:`${t.palette.mode==="light"?t.palette.grey[100]:t.palette.grey[600]}`},[`&.${Q.checked} + .${Q.track}`]:{opacity:.5},[`&.${Q.disabled} + .${Q.track}`]:{opacity:t.vars?t.vars.opacity.switchTrackDisabled:`${t.palette.mode==="light"?.12:.2}`},[`& .${Q.input}`]:{left:"-100%",width:"300%"}}),({theme:t,ownerState:e})=>oe({"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Zr(t.palette.action.active,t.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},e.color!=="default"&&{[`&.${Q.checked}`]:{color:(t.vars||t).palette[e.color].main,"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette[e.color].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Zr(t.palette[e.color].main,t.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${Q.disabled}`]:{color:t.vars?t.vars.palette.Switch[`${e.color}DisabledColor`]:`${t.palette.mode==="light"?Ci(t.palette[e.color].main,.62):Si(t.palette[e.color].main,.55)}`}},[`&.${Q.checked} + .${Q.track}`]:{backgroundColor:(t.vars||t).palette[e.color].main}})),Rs=Wt("span",{name:"MuiSwitch",slot:"Track",overridesResolver:(t,e)=>e.track})(({theme:t})=>({height:"100%",width:"100%",borderRadius:14/2,zIndex:-1,transition:t.transitions.create(["opacity","background-color"],{duration:t.transitions.duration.shortest}),backgroundColor:t.vars?t.vars.palette.common.onBackground:`${t.palette.mode==="light"?t.palette.common.black:t.palette.common.white}`,opacity:t.vars?t.vars.opacity.switchTrack:`${t.palette.mode==="light"?.38:.3}`})),Bs=Wt("span",{name:"MuiSwitch",slot:"Thumb",overridesResolver:(t,e)=>e.thumb})(({theme:t})=>({boxShadow:(t.vars||t).shadows[1],backgroundColor:"currentColor",width:20,height:20,borderRadius:"50%"})),Fs=y.forwardRef(function(e,n){const r=Oo({props:e,name:"MuiSwitch"}),{className:a,color:o="primary",edge:s=!1,size:i="medium",sx:l}=r,u=Po(r,$s),d=oe({},r,{color:o,edge:s,size:i}),f=As(d),h=p.jsx(Bs,{className:f.thumb,ownerState:d});return p.jsxs(Ms,{className:To(f.root,a),sx:l,ownerState:d,children:[p.jsx(ks,oe({type:"checkbox",icon:h,checkedIcon:h,ref:n,ownerState:d},u,{classes:oe({},f,{root:f.switchBase})})),p.jsx(Rs,{className:f.track,ownerState:d})]})}),Do=Fs;var Ns=Object.defineProperty,Is=(t,e,n)=>e in t?Ns(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,R=(t,e,n)=>(Is(t,typeof e!="symbol"?e+"":e,n),n);const un=new is,ca=new ss,Ds=Math.cos(70*(Math.PI/180)),ua=(t,e)=>(t%e+e)%e;let Hs=class extends ls{constructor(e,n){super(),R(this,"object"),R(this,"domElement"),R(this,"enabled",!0),R(this,"target",new G),R(this,"minDistance",0),R(this,"maxDistance",1/0),R(this,"minZoom",0),R(this,"maxZoom",1/0),R(this,"minPolarAngle",0),R(this,"maxPolarAngle",Math.PI),R(this,"minAzimuthAngle",-1/0),R(this,"maxAzimuthAngle",1/0),R(this,"enableDamping",!1),R(this,"dampingFactor",.05),R(this,"enableZoom",!0),R(this,"zoomSpeed",1),R(this,"enableRotate",!0),R(this,"rotateSpeed",1),R(this,"enablePan",!0),R(this,"panSpeed",1),R(this,"screenSpacePanning",!0),R(this,"keyPanSpeed",7),R(this,"zoomToCursor",!1),R(this,"autoRotate",!1),R(this,"autoRotateSpeed",2),R(this,"reverseOrbit",!1),R(this,"reverseHorizontalOrbit",!1),R(this,"reverseVerticalOrbit",!1),R(this,"keys",{LEFT:"ArrowLeft",UP:"ArrowUp",RIGHT:"ArrowRight",BOTTOM:"ArrowDown"}),R(this,"mouseButtons",{LEFT:qe.ROTATE,MIDDLE:qe.DOLLY,RIGHT:qe.PAN}),R(this,"touches",{ONE:Ze.ROTATE,TWO:Ze.DOLLY_PAN}),R(this,"target0"),R(this,"position0"),R(this,"zoom0"),R(this,"_domElementKeyEvents",null),R(this,"getPolarAngle"),R(this,"getAzimuthalAngle"),R(this,"setPolarAngle"),R(this,"setAzimuthalAngle"),R(this,"getDistance"),R(this,"listenToKeyEvents"),R(this,"stopListenToKeyEvents"),R(this,"saveState"),R(this,"reset"),R(this,"update"),R(this,"connect"),R(this,"dispose"),this.object=e,this.domElement=n,this.target0=this.target.clone(),this.position0=this.object.position.clone(),this.zoom0=this.object.zoom,this.getPolarAngle=()=>d.phi,this.getAzimuthalAngle=()=>d.theta,this.setPolarAngle=b=>{let C=ua(b,2*Math.PI),F=d.phi;F<0&&(F+=2*Math.PI),C<0&&(C+=2*Math.PI);let U=Math.abs(C-F);2*Math.PI-U{let C=ua(b,2*Math.PI),F=d.theta;F<0&&(F+=2*Math.PI),C<0&&(C+=2*Math.PI);let U=Math.abs(C-F);2*Math.PI-Ur.object.position.distanceTo(r.target),this.listenToKeyEvents=b=>{b.addEventListener("keydown",jt),this._domElementKeyEvents=b},this.stopListenToKeyEvents=()=>{this._domElementKeyEvents.removeEventListener("keydown",jt),this._domElementKeyEvents=null},this.saveState=()=>{r.target0.copy(r.target),r.position0.copy(r.object.position),r.zoom0=r.object.zoom},this.reset=()=>{r.target.copy(r.target0),r.object.position.copy(r.position0),r.object.zoom=r.zoom0,r.object.updateProjectionMatrix(),r.dispatchEvent(a),r.update(),l=i.NONE},this.update=(()=>{const b=new G,C=new G(0,1,0),F=new ia().setFromUnitVectors(e.up,C),U=F.clone().invert(),Z=new G,we=new ia,Me=2*Math.PI;return function(){const qr=r.object.position;F.setFromUnitVectors(e.up,C),U.copy(F).invert(),b.copy(qr).sub(r.target),b.applyQuaternion(F),d.setFromVector3(b),r.autoRotate&&l===i.NONE&&K(X()),r.enableDamping?(d.theta+=f.theta*r.dampingFactor,d.phi+=f.phi*r.dampingFactor):(d.theta+=f.theta,d.phi+=f.phi);let Ee=r.minAzimuthAngle,Ce=r.maxAzimuthAngle;isFinite(Ee)&&isFinite(Ce)&&(Ee<-Math.PI?Ee+=Me:Ee>Math.PI&&(Ee-=Me),Ce<-Math.PI?Ce+=Me:Ce>Math.PI&&(Ce-=Me),Ee<=Ce?d.theta=Math.max(Ee,Math.min(Ce,d.theta)):d.theta=d.theta>(Ee+Ce)/2?Math.max(Ee,d.theta):Math.min(Ce,d.theta)),d.phi=Math.max(r.minPolarAngle,Math.min(r.maxPolarAngle,d.phi)),d.makeSafe(),r.enableDamping===!0?r.target.addScaledVector(g,r.dampingFactor):r.target.add(g),r.zoomToCursor&&V||r.object.isOrthographicCamera?d.radius=Fe(d.radius):d.radius=Fe(d.radius*h),b.setFromSpherical(d),b.applyQuaternion(U),qr.copy(r.target).add(b),r.object.matrixAutoUpdate||r.object.updateMatrix(),r.object.lookAt(r.target),r.enableDamping===!0?(f.theta*=1-r.dampingFactor,f.phi*=1-r.dampingFactor,g.multiplyScalar(1-r.dampingFactor)):(f.set(0,0,0),g.set(0,0,0));let on=!1;if(r.zoomToCursor&&V){let $t=null;if(r.object instanceof ln&&r.object.isPerspectiveCamera){const At=b.length();$t=Fe(At*h);const sn=At-$t;r.object.position.addScaledVector(L,sn),r.object.updateMatrixWorld()}else if(r.object.isOrthographicCamera){const At=new G(H.x,H.y,0);At.unproject(r.object),r.object.zoom=Math.max(r.minZoom,Math.min(r.maxZoom,r.object.zoom/h)),r.object.updateProjectionMatrix(),on=!0;const sn=new G(H.x,H.y,0);sn.unproject(r.object),r.object.position.sub(sn).add(At),r.object.updateMatrixWorld(),$t=b.length()}else console.warn("WARNING: OrbitControls.js encountered an unknown camera type - zoom to cursor disabled."),r.zoomToCursor=!1;$t!==null&&(r.screenSpacePanning?r.target.set(0,0,-1).transformDirection(r.object.matrix).multiplyScalar($t).add(r.object.position):(un.origin.copy(r.object.position),un.direction.set(0,0,-1).transformDirection(r.object.matrix),Math.abs(r.object.up.dot(un.direction))u||8*(1-we.dot(r.object.quaternion))>u?(r.dispatchEvent(a),Z.copy(r.object.position),we.copy(r.object.quaternion),on=!1,!0):!1}})(),this.connect=b=>{b===document&&console.error('THREE.OrbitControls: "document" should not be used as the target "domElement". Please use "renderer.domElement" instead.'),r.domElement=b,r.domElement.style.touchAction="none",r.domElement.addEventListener("contextmenu",Ot),r.domElement.addEventListener("pointerdown",Xe),r.domElement.addEventListener("pointercancel",z),r.domElement.addEventListener("wheel",le)},this.dispose=()=>{var b,C,F,U,Z,we;(b=r.domElement)==null||b.removeEventListener("contextmenu",Ot),(C=r.domElement)==null||C.removeEventListener("pointerdown",Xe),(F=r.domElement)==null||F.removeEventListener("pointercancel",z),(U=r.domElement)==null||U.removeEventListener("wheel",le),(Z=r.domElement)==null||Z.ownerDocument.removeEventListener("pointermove",Ke),(we=r.domElement)==null||we.ownerDocument.removeEventListener("pointerup",k),r._domElementKeyEvents!==null&&r._domElementKeyEvents.removeEventListener("keydown",jt)};const r=this,a={type:"change"},o={type:"start"},s={type:"end"},i={NONE:-1,ROTATE:0,DOLLY:1,PAN:2,TOUCH_ROTATE:3,TOUCH_PAN:4,TOUCH_DOLLY_PAN:5,TOUCH_DOLLY_ROTATE:6};let l=i.NONE;const u=1e-6,d=new sa,f=new sa;let h=1;const g=new G,x=new de,m=new de,v=new de,w=new de,_=new de,B=new de,P=new de,T=new de,M=new de,L=new G,H=new de;let V=!1;const S=[],D={};function X(){return 2*Math.PI/60/60*r.autoRotateSpeed}function I(){return Math.pow(.95,r.zoomSpeed)}function K(b){r.reverseOrbit||r.reverseHorizontalOrbit?f.theta+=b:f.theta-=b}function re(b){r.reverseOrbit||r.reverseVerticalOrbit?f.phi+=b:f.phi-=b}const xe=(()=>{const b=new G;return function(F,U){b.setFromMatrixColumn(U,0),b.multiplyScalar(-F),g.add(b)}})(),Te=(()=>{const b=new G;return function(F,U){r.screenSpacePanning===!0?b.setFromMatrixColumn(U,1):(b.setFromMatrixColumn(U,0),b.crossVectors(r.object.up,b)),b.multiplyScalar(F),g.add(b)}})(),pe=(()=>{const b=new G;return function(F,U){const Z=r.domElement;if(Z&&r.object instanceof ln&&r.object.isPerspectiveCamera){const we=r.object.position;b.copy(we).sub(r.target);let Me=b.length();Me*=Math.tan(r.object.fov/2*Math.PI/180),xe(2*F*Me/Z.clientHeight,r.object.matrix),Te(2*U*Me/Z.clientHeight,r.object.matrix)}else Z&&r.object instanceof cn&&r.object.isOrthographicCamera?(xe(F*(r.object.right-r.object.left)/r.object.zoom/Z.clientWidth,r.object.matrix),Te(U*(r.object.top-r.object.bottom)/r.object.zoom/Z.clientHeight,r.object.matrix)):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - pan disabled."),r.enablePan=!1)}})();function Et(b){r.object instanceof ln&&r.object.isPerspectiveCamera||r.object instanceof cn&&r.object.isOrthographicCamera?h/=b:(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),r.enableZoom=!1)}function Ue(b){r.object instanceof ln&&r.object.isPerspectiveCamera||r.object instanceof cn&&r.object.isOrthographicCamera?h*=b:(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),r.enableZoom=!1)}function $e(b){if(!r.zoomToCursor||!r.domElement)return;V=!0;const C=r.domElement.getBoundingClientRect(),F=b.clientX-C.left,U=b.clientY-C.top,Z=C.width,we=C.height;H.x=F/Z*2-1,H.y=-(U/we)*2+1,L.set(H.x,H.y,1).unproject(r.object).sub(r.object.position).normalize()}function Fe(b){return Math.max(r.minDistance,Math.min(r.maxDistance,b))}function ye(b){x.set(b.clientX,b.clientY)}function Ct(b){$e(b),P.set(b.clientX,b.clientY)}function St(b){w.set(b.clientX,b.clientY)}function kn(b){m.set(b.clientX,b.clientY),v.subVectors(m,x).multiplyScalar(r.rotateSpeed);const C=r.domElement;C&&(K(2*Math.PI*v.x/C.clientHeight),re(2*Math.PI*v.y/C.clientHeight)),x.copy(m),r.update()}function Jt(b){T.set(b.clientX,b.clientY),M.subVectors(T,P),M.y>0?Et(I()):M.y<0&&Ue(I()),P.copy(T),r.update()}function Rn(b){_.set(b.clientX,b.clientY),B.subVectors(_,w).multiplyScalar(r.panSpeed),pe(B.x,B.y),w.copy(_),r.update()}function ee(b){$e(b),b.deltaY<0?Ue(I()):b.deltaY>0&&Et(I()),r.update()}function Bn(b){let C=!1;switch(b.code){case r.keys.UP:pe(0,r.keyPanSpeed),C=!0;break;case r.keys.BOTTOM:pe(0,-r.keyPanSpeed),C=!0;break;case r.keys.LEFT:pe(r.keyPanSpeed,0),C=!0;break;case r.keys.RIGHT:pe(-r.keyPanSpeed,0),C=!0;break}C&&(b.preventDefault(),r.update())}function Ve(){if(S.length==1)x.set(S[0].pageX,S[0].pageY);else{const b=.5*(S[0].pageX+S[1].pageX),C=.5*(S[0].pageY+S[1].pageY);x.set(b,C)}}function Ae(){if(S.length==1)w.set(S[0].pageX,S[0].pageY);else{const b=.5*(S[0].pageX+S[1].pageX),C=.5*(S[0].pageY+S[1].pageY);w.set(b,C)}}function Qt(){const b=S[0].pageX-S[1].pageX,C=S[0].pageY-S[1].pageY,F=Math.sqrt(b*b+C*C);P.set(0,F)}function Fn(){r.enableZoom&&Qt(),r.enablePan&&Ae()}function Nn(){r.enableZoom&&Qt(),r.enableRotate&&Ve()}function _t(b){if(S.length==1)m.set(b.pageX,b.pageY);else{const F=Dn(b),U=.5*(b.pageX+F.x),Z=.5*(b.pageY+F.y);m.set(U,Z)}v.subVectors(m,x).multiplyScalar(r.rotateSpeed);const C=r.domElement;C&&(K(2*Math.PI*v.x/C.clientHeight),re(2*Math.PI*v.y/C.clientHeight)),x.copy(m)}function en(b){if(S.length==1)_.set(b.pageX,b.pageY);else{const C=Dn(b),F=.5*(b.pageX+C.x),U=.5*(b.pageY+C.y);_.set(F,U)}B.subVectors(_,w).multiplyScalar(r.panSpeed),pe(B.x,B.y),w.copy(_)}function tn(b){const C=Dn(b),F=b.pageX-C.x,U=b.pageY-C.y,Z=Math.sqrt(F*F+U*U);T.set(0,Z),M.set(0,Math.pow(T.y/P.y,r.zoomSpeed)),Et(M.y),P.copy(T)}function Ye(b){r.enableZoom&&tn(b),r.enablePan&&en(b)}function In(b){r.enableZoom&&tn(b),r.enableRotate&&_t(b)}function Xe(b){var C,F;r.enabled!==!1&&(S.length===0&&((C=r.domElement)==null||C.ownerDocument.addEventListener("pointermove",Ke),(F=r.domElement)==null||F.ownerDocument.addEventListener("pointerup",k)),an(b),b.pointerType==="touch"?nn(b):J(b))}function Ke(b){r.enabled!==!1&&(b.pointerType==="touch"?rn(b):se(b))}function k(b){var C,F,U;Pt(b),S.length===0&&((C=r.domElement)==null||C.releasePointerCapture(b.pointerId),(F=r.domElement)==null||F.ownerDocument.removeEventListener("pointermove",Ke),(U=r.domElement)==null||U.ownerDocument.removeEventListener("pointerup",k)),r.dispatchEvent(s),l=i.NONE}function z(b){Pt(b)}function J(b){let C;switch(b.button){case 0:C=r.mouseButtons.LEFT;break;case 1:C=r.mouseButtons.MIDDLE;break;case 2:C=r.mouseButtons.RIGHT;break;default:C=-1}switch(C){case qe.DOLLY:if(r.enableZoom===!1)return;Ct(b),l=i.DOLLY;break;case qe.ROTATE:if(b.ctrlKey||b.metaKey||b.shiftKey){if(r.enablePan===!1)return;St(b),l=i.PAN}else{if(r.enableRotate===!1)return;ye(b),l=i.ROTATE}break;case qe.PAN:if(b.ctrlKey||b.metaKey||b.shiftKey){if(r.enableRotate===!1)return;ye(b),l=i.ROTATE}else{if(r.enablePan===!1)return;St(b),l=i.PAN}break;default:l=i.NONE}l!==i.NONE&&r.dispatchEvent(o)}function se(b){if(r.enabled!==!1)switch(l){case i.ROTATE:if(r.enableRotate===!1)return;kn(b);break;case i.DOLLY:if(r.enableZoom===!1)return;Jt(b);break;case i.PAN:if(r.enablePan===!1)return;Rn(b);break}}function le(b){r.enabled===!1||r.enableZoom===!1||l!==i.NONE&&l!==i.ROTATE||(b.preventDefault(),r.dispatchEvent(o),ee(b),r.dispatchEvent(s))}function jt(b){r.enabled===!1||r.enablePan===!1||Bn(b)}function nn(b){switch(Tt(b),S.length){case 1:switch(r.touches.ONE){case Ze.ROTATE:if(r.enableRotate===!1)return;Ve(),l=i.TOUCH_ROTATE;break;case Ze.PAN:if(r.enablePan===!1)return;Ae(),l=i.TOUCH_PAN;break;default:l=i.NONE}break;case 2:switch(r.touches.TWO){case Ze.DOLLY_PAN:if(r.enableZoom===!1&&r.enablePan===!1)return;Fn(),l=i.TOUCH_DOLLY_PAN;break;case Ze.DOLLY_ROTATE:if(r.enableZoom===!1&&r.enableRotate===!1)return;Nn(),l=i.TOUCH_DOLLY_ROTATE;break;default:l=i.NONE}break;default:l=i.NONE}l!==i.NONE&&r.dispatchEvent(o)}function rn(b){switch(Tt(b),l){case i.TOUCH_ROTATE:if(r.enableRotate===!1)return;_t(b),r.update();break;case i.TOUCH_PAN:if(r.enablePan===!1)return;en(b),r.update();break;case i.TOUCH_DOLLY_PAN:if(r.enableZoom===!1&&r.enablePan===!1)return;Ye(b),r.update();break;case i.TOUCH_DOLLY_ROTATE:if(r.enableZoom===!1&&r.enableRotate===!1)return;In(b),r.update();break;default:l=i.NONE}}function Ot(b){r.enabled!==!1&&b.preventDefault()}function an(b){S.push(b)}function Pt(b){delete D[b.pointerId];for(let C=0;Cnew cs(void 0,void 0,void 0)),u=y.useCallback((f,h,g,x=20)=>(f instanceof G?l.v0.copy(f):l.v0.set(...f),h instanceof G?l.v2.copy(h):l.v2.set(...h),g instanceof G?l.v1.copy(g):l.v1.copy(l.v0.clone().add(l.v2.clone().sub(l.v0)).add(zs.set(0,l.v0.y-l.v2.y,0))),l.getPoints(x)),[]);y.useLayoutEffect(()=>{i.current.setPoints=(f,h,g)=>{const x=u(f,h,g);i.current.geometry&&i.current.geometry.setPositions(x.map(m=>m.toArray()).flat())}},[]);const d=y.useMemo(()=>u(e,n,r,a),[e,n,r,a]);return y.createElement(Ji,oe({ref:Qi([i,s]),points:d},o))}),Ls=y.forwardRef(({makeDefault:t,camera:e,regress:n,domElement:r,enableDamping:a=!0,onChange:o,onStart:s,onEnd:i,...l},u)=>{const d=me(T=>T.invalidate),f=me(T=>T.camera),h=me(T=>T.gl),g=me(T=>T.events),x=me(T=>T.setEvents),m=me(T=>T.set),v=me(T=>T.get),w=me(T=>T.performance),_=e||f,B=r||g.connected||h.domElement,P=y.useMemo(()=>new Hs(_),[_]);return Sn(()=>{P.enabled&&P.update()},-1),y.useEffect(()=>(P.connect(B),()=>void P.dispose()),[B,n,P,d]),y.useEffect(()=>{const T=H=>{d(),n&&w.regress(),o&&o(H)},M=H=>{s&&s(H)},L=H=>{i&&i(H)};return P.addEventListener("change",T),P.addEventListener("start",M),P.addEventListener("end",L),()=>{P.removeEventListener("start",M),P.removeEventListener("end",L),P.removeEventListener("change",T)}},[o,s,i,P,d,x]),y.useEffect(()=>{if(t){const T=v().controls;return m({controls:P}),()=>m({controls:T})}},[t,P]),y.createElement("primitive",oe({ref:u,object:P,enableDamping:a},l))}),Gs={type:"",parent:""},da=({onSelect:t,dataTestId:e,edgeLink:n,hideSelectAll:r,placeholder:a})=>{const o=br({mode:"onChange",defaultValues:Gs}),{watch:s,setValue:i}=o,[l,u]=y.useState([]),[d,f]=y.useState(!1),h=v=>{i("parent",(v==null?void 0:v.value)||""),t(v==null?void 0:v.value)},g=v=>v.charAt(0).toUpperCase()+v.slice(1);y.useEffect(()=>{(async()=>{f(!0);try{const _=(await xr()).schemas.filter(P=>!P.is_deleted&&P.type).map(P=>P.type==="thing"?{label:"No Parent",value:P.type}:{label:g(P.type),value:P.type}).filter((P,T,M)=>T===M.findIndex(L=>L.value===P.value));u(r?_:[{label:"Select all",value:"all"},..._]),n&&i("parent",n)}catch(w){console.warn(w)}finally{f(!1)}})()},[n,i,r]);const x=s("parent"),m=()=>{const v=l==null?void 0:l.find(w=>w.value===x);if(v)return v;if(n)return{label:n,value:n}};return p.jsx(Ws,{dataTestId:e,disabled:!!n,isLoading:d,onSelect:h,options:l||_i,placeholder:a,selectedValue:m()})},Ws=O(Dt)` .MuiInputBase-input { font-family: Barlow; font-size: 14px; diff --git a/build/assets/index-b3d55c88.js b/build/assets/index-70e1d6d6.js similarity index 95% rename from build/assets/index-b3d55c88.js rename to build/assets/index-70e1d6d6.js index 5a5243030..59cff98fa 100644 --- a/build/assets/index-b3d55c88.js +++ b/build/assets/index-70e1d6d6.js @@ -1,4 +1,4 @@ -import{e as a,o as B,n as M,u as T,k as z,q as G,b as L,a7 as N,j as e,T as t,s as c,a as n,F as l}from"./index-4bb27744.js";import{g as O,h as D,i as E,S as R,C as U,j as W,F as Y}from"./index-7730ff6f.js";const K=()=>{const{open:r}=a("sourcesTable"),{open:p}=a("addItem"),{open:u}=a("addContent"),{open:h}=a("settings"),{open:x}=a("blueprintGraph"),{open:b}=a("feedback"),g=B(),{resetAiSummaryAnswer:j,setNewLoading:m}=M(),{abortFetchData:k,resetGraph:f}=T(o=>o),{setUniverseQuestionIsOpen:y,setSidebarOpen:w,setShowCollapseButton:S}=z(o=>o),{customSchemaFeatureFlag:C,userFeedbackFeatureFlag:F,chatInterfaceFeatureFlag:I}=G(o=>o),{isAdmin:d}=L(o=>o),v=N(),A=()=>{m(null),k(),j(),f(),g("/")},$=()=>{y(),w(!0),S(!0)};return e.jsxs(q,{children:[e.jsx(Q,{onClick:A,children:e.jsx("img",{alt:"Second brain",src:"logo.svg"})}),I?e.jsxs(i,{onClick:$,children:[e.jsx(s,{children:e.jsx(O,{})}),e.jsx(t,{children:"New Chat"})]}):null,d?e.jsxs(i,{"data-testid":"add-item-modal",onClick:p,children:[e.jsx(s,{children:e.jsx(D,{})}),e.jsx(t,{children:"Add Item"})]}):null,e.jsxs(i,{"data-testid":"add-content-modal",onClick:u,children:[e.jsx(s,{children:e.jsx(E,{})}),e.jsx(t,{children:"Add Content"})]}),e.jsxs(i,{id:"cy-open-soure-table",onClick:r,children:[e.jsx(s,{children:e.jsx(R,{})}),e.jsx(t,{children:"Source Table"})]}),C&&d?e.jsxs(i,{"data-testid":"add-blueprint-modal",id:"cy-open-soure-table",onClick:x,children:[e.jsx(s,{children:e.jsx(U,{})}),e.jsx(t,{children:"Blueprint"})]}):null,e.jsxs(i,{"data-testid":"settings-modal",onClick:h,children:[e.jsx(s,{children:e.jsx(W,{})}),e.jsx(t,{children:"Settings"})]}),F&&v?e.jsxs(X,{"data-testid":"feedback-modal",onClick:b,children:[e.jsx(s,{children:e.jsx(Y,{})}),e.jsx(t,{children:"Send Feedback"})]}):null]})},q=c(l).attrs({align:"flex-start",direction:"column",justify:"flex-start"})` +import{e as a,o as B,n as M,u as T,k as z,q as G,b as L,a6 as N,j as e,T as t,s as c,a as n,F as l}from"./index-4e60c9e2.js";import{g as O,h as D,i as E,S as R,C as U,j as W,F as Y}from"./index-af5a3f81.js";const K=()=>{const{open:r}=a("sourcesTable"),{open:p}=a("addItem"),{open:u}=a("addContent"),{open:h}=a("settings"),{open:x}=a("blueprintGraph"),{open:b}=a("feedback"),g=B(),{resetAiSummaryAnswer:j,setNewLoading:m}=M(),{abortFetchData:k,resetGraph:f}=T(o=>o),{setUniverseQuestionIsOpen:y,setSidebarOpen:w,setShowCollapseButton:S}=z(o=>o),{customSchemaFeatureFlag:C,userFeedbackFeatureFlag:F,chatInterfaceFeatureFlag:I}=G(o=>o),{isAdmin:d}=L(o=>o),v=N(),A=()=>{m(null),k(),j(),f(),g("/")},$=()=>{y(),w(!0),S(!0)};return e.jsxs(q,{children:[e.jsx(Q,{onClick:A,children:e.jsx("img",{alt:"Second brain",src:"logo.svg"})}),I?e.jsxs(i,{onClick:$,children:[e.jsx(s,{children:e.jsx(O,{})}),e.jsx(t,{children:"New Chat"})]}):null,d?e.jsxs(i,{"data-testid":"add-item-modal",onClick:p,children:[e.jsx(s,{children:e.jsx(D,{})}),e.jsx(t,{children:"Add Item"})]}):null,e.jsxs(i,{"data-testid":"add-content-modal",onClick:u,children:[e.jsx(s,{children:e.jsx(E,{})}),e.jsx(t,{children:"Add Content"})]}),e.jsxs(i,{id:"cy-open-soure-table",onClick:r,children:[e.jsx(s,{children:e.jsx(R,{})}),e.jsx(t,{children:"Source Table"})]}),C&&d?e.jsxs(i,{"data-testid":"add-blueprint-modal",id:"cy-open-soure-table",onClick:x,children:[e.jsx(s,{children:e.jsx(U,{})}),e.jsx(t,{children:"Blueprint"})]}):null,e.jsxs(i,{"data-testid":"settings-modal",onClick:h,children:[e.jsx(s,{children:e.jsx(W,{})}),e.jsx(t,{children:"Settings"})]}),F&&v?e.jsxs(X,{"data-testid":"feedback-modal",onClick:b,children:[e.jsx(s,{children:e.jsx(Y,{})}),e.jsx(t,{children:"Send Feedback"})]}):null]})},q=c(l).attrs({align:"flex-start",direction:"column",justify:"flex-start"})` flex: 0 0 64px; z-index: 31; transition: opacity 1s; diff --git a/build/assets/index-5ca84596.js b/build/assets/index-763b7c2d.js similarity index 97% rename from build/assets/index-5ca84596.js rename to build/assets/index-763b7c2d.js index 2977edb79..e18e215d2 100644 --- a/build/assets/index-5ca84596.js +++ b/build/assets/index-763b7c2d.js @@ -1,4 +1,4 @@ -import{W as s0,c as r0,r as x,_ as h,j as a,s as c,a as r,F as d,u as _,I as e0,C as o0,l as m0,b as a0,d as n0,e as c0,g as l0,f as h0,h as p0,i as d0,m as f0,k as i0,n as t0,o as y0,T as N,B as G0,Q as b0,p as u0,q as E0,t as A0,v as B0,w as D0}from"./index-4bb27744.js";import{P as V0,T as R,u as k0,B as S0,I as g0,N as F0,a as j0,O as w0,A as v0}from"./index-7730ff6f.js";function P0(i){return i===null?"?":i.toLocaleString("en-US").split(",").join(" ")}const _0=s0` +import{W as s0,c as r0,r as x,_ as h,j as a,s as c,a as r,F as d,u as _,I as e0,C as o0,l as m0,b as a0,d as n0,e as c0,g as l0,f as h0,h as p0,i as d0,m as f0,k as i0,n as t0,o as y0,T as N,B as G0,Q as b0,p as u0,q as E0,t as A0,v as B0,w as D0}from"./index-4e60c9e2.js";import{P as V0,T as R,u as k0,B as S0,I as g0,N as F0,a as j0,O as w0,A as v0}from"./index-af5a3f81.js";function P0(i){return i===null?"?":i.toLocaleString("en-US").split(",").join(" ")}const _0=s0` html { box-sizing: border-box; } @@ -50,7 +50,7 @@ import{W as s0,c as r0,r as x,_ as h,j as a,s as c,a as r,F as d,u as _,I as e0, border-collapse: collapse; border-spacing: 0; } -`,M0={askedQuestions:null,askedQuestionsAnswers:null,hasQuestionInProgress:!1,hasTeachingInProgress:!1,hasInstagraphInProgress:!1,teachMeAnswer:null,instgraphAnswser:null},C0=r0(i=>({...M0,setAskedQuestion:k=>i(e=>({askedQuestions:[...e.askedQuestions||[],k],hasQuestionInProgress:!0})),setAskedQuestionAnswer:k=>i(e=>({askedQuestionsAnswers:[...e.askedQuestionsAnswers||[],k],hasQuestionInProgress:!1})),setHasQuestionInProgress:k=>i({hasQuestionInProgress:k}),setHasTeachingInProgress:k=>i({hasTeachingInProgress:k}),setHasInstagraphInProgress:k=>i({hasInstagraphInProgress:k}),setTeachMeAnswer:k=>i({hasTeachingInProgress:!1,teachMeAnswer:k}),setInstagraphAnswer:k=>{var e,n,o,y;(e=k==null?void 0:k.instagraph)!=null&&e.edges&&((n=k==null?void 0:k.instagraph)!=null&&n.nodes)&&i({hasInstagraphInProgress:!1,instgraphAnswser:{edges:(o=k==null?void 0:k.instagraph)==null?void 0:o.edges,nodes:(y=k==null?void 0:k.instagraph)==null?void 0:y.nodes}})}})),T0="0.1.106",I0=x.lazy(()=>h(()=>import("./index-78eebc06.js"),["assets/index-78eebc06.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/ClipLoader-1ef5878d.js","assets/Tabs-7ecc0b57.js","assets/createSvgIcon-41051178.js"]).then(({SettingsModal:i})=>({default:i}))),z0=x.lazy(()=>h(()=>import("./index-25ee1701.js"),["assets/index-25ee1701.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/ClipLoader-1ef5878d.js"]).then(({AddContentModal:i})=>({default:i}))),L0=x.lazy(()=>h(()=>import("./index-39d7c317.js"),["assets/index-39d7c317.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/ClipLoader-1ef5878d.js","assets/index-5fe8c70d.js","assets/three.module-71ec604c.js","assets/index-22c3582f.js","assets/index-5111ebdb.js","assets/Stack-6038813c.js","assets/createSvgIcon-41051178.js","assets/TextareaAutosize-b716e8d1.js","assets/index-64f1c910.js"]).then(({AddItemModal:i})=>({default:i}))),N0=x.lazy(()=>h(()=>import("./index-005a3994.js"),["assets/index-005a3994.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/constants-bc1d79ca.js","assets/ClipLoader-1ef5878d.js","assets/index-22c3582f.js","assets/index-5111ebdb.js","assets/Stack-6038813c.js","assets/createSvgIcon-41051178.js","assets/TextareaAutosize-b716e8d1.js","assets/index-d0e3c339.js","assets/Typography-f76555b9.js","assets/Tabs-7ecc0b57.js"]).then(({SourcesTableModal:i})=>({default:i}))),R0=x.lazy(()=>h(()=>import("./index-c3934e6a.js"),["assets/index-c3934e6a.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/index-5111ebdb.js","assets/Skeleton-dbbfd404.js","assets/ClipLoader-1ef5878d.js"]).then(({EditNodeNameModal:i})=>({default:i}))),O0=x.lazy(()=>h(()=>import("./index-20575f2c.js"),["assets/index-20575f2c.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/Skeleton-dbbfd404.js","assets/ClipLoader-1ef5878d.js"]).then(({RemoveNodeModal:i})=>({default:i}))),$0=x.lazy(()=>h(()=>import("./index-ea85a09b.js"),["assets/index-ea85a09b.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/index-22c3582f.js","assets/index-5111ebdb.js","assets/Stack-6038813c.js","assets/createSvgIcon-41051178.js","assets/TextareaAutosize-b716e8d1.js","assets/constants-bc1d79ca.js","assets/ClipLoader-1ef5878d.js"]).then(({AddNodeEdgeModal:i})=>({default:i}))),q0=x.lazy(()=>h(()=>import("./index-c3e0684d.js"),["assets/index-c3e0684d.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/index-d0e3c339.js","assets/constants-bc1d79ca.js","assets/index-22c3582f.js","assets/index-5111ebdb.js","assets/Stack-6038813c.js","assets/createSvgIcon-41051178.js","assets/TextareaAutosize-b716e8d1.js","assets/ClipLoader-1ef5878d.js"]).then(({MergeNodeModal:i})=>({default:i}))),Q0=x.lazy(()=>h(()=>import("./index-555c3317.js"),["assets/index-555c3317.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-5fe8c70d.js","assets/three.module-71ec604c.js","assets/ClipLoader-1ef5878d.js","assets/index-7730ff6f.js","assets/index-22c3582f.js","assets/index-5111ebdb.js","assets/Stack-6038813c.js","assets/createSvgIcon-41051178.js","assets/TextareaAutosize-b716e8d1.js","assets/index-64f1c910.js"]).then(({ChangeNodeTypeModal:i})=>({default:i}))),U0=x.lazy(()=>h(()=>import("./index-e9ea328e.js"),["assets/index-e9ea328e.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-22c3582f.js","assets/index-5111ebdb.js","assets/Stack-6038813c.js","assets/index-7730ff6f.js","assets/createSvgIcon-41051178.js","assets/TextareaAutosize-b716e8d1.js","assets/ClipLoader-1ef5878d.js","assets/isPlainObject-b85008a5.js","assets/Typography-f76555b9.js","assets/index-7888478e.js","assets/Tabs-7ecc0b57.js","assets/index-5fe8c70d.js","assets/three.module-71ec604c.js","assets/index-dc12854c.js"]).then(({BlueprintModal:i})=>({default:i}))),W0=x.lazy(()=>h(()=>import("./index-6e6f13b5.js"),["assets/index-6e6f13b5.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js"]).then(({UserFeedBackModal:i})=>({default:i}))),H0=x.lazy(()=>h(()=>import("./index-686eedfc.js"),["assets/index-686eedfc.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/index-22c3582f.js","assets/index-5111ebdb.js","assets/Stack-6038813c.js","assets/createSvgIcon-41051178.js","assets/TextareaAutosize-b716e8d1.js"]).then(({CreateBountyModal:i})=>({default:i}))),Y0=x.lazy(()=>h(()=>import("./index-4bb27744.js").then(i=>i.cf),["assets/index-4bb27744.js","assets/index-b4d03b7b.css"]).then(({OnboardingModal:i})=>({default:i}))),J0=x.lazy(()=>h(()=>import("./index-59c77710.js"),["assets/index-59c77710.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js"]).then(({BriefDescription:i})=>({default:i}))),K0=()=>a.jsxs(a.Fragment,{children:[a.jsx(L0,{}),a.jsx(z0,{}),a.jsx(I0,{}),a.jsx(R0,{}),a.jsx(O0,{}),a.jsx(N0,{}),a.jsx($0,{}),a.jsx(Q0,{}),a.jsx(U0,{}),a.jsx(q0,{}),a.jsx(W0,{}),a.jsx(H0,{}),a.jsx(Y0,{}),a.jsx(J0,{})]}),X0=()=>{const[i,k]=x.useState(null),{runningProjectMessages:e}=_(m=>m),n=m=>{k(m.currentTarget)},o=()=>{k(null)},y=!!i,u=y?"simple-popover":void 0;return e.length?a.jsxs(Z0,{ml:8,children:[a.jsx(ia,{onClick:n,children:a.jsxs(R,{content:"Messages",margin:"18px",children:[a.jsx("div",{className:"icon",children:a.jsx(e0,{})}),a.jsx("div",{className:"text",children:a.jsx("p",{children:e.length})})]})}),a.jsxs(ta,{anchorEl:i,anchorOrigin:{vertical:"bottom",horizontal:"right"},id:u,onClose:o,open:y,children:[a.jsx(x0,{onClick:o,children:a.jsx(o0,{})}),a.jsx(aa,{p:16,children:e.map(m=>a.jsx("p",{className:"item",children:m},m))})]})]}):null},Z0=c(d).attrs({align:"center",direction:"row",grow:0,justify:"flex-start"})``,aa=c(d)` +`,M0={askedQuestions:null,askedQuestionsAnswers:null,hasQuestionInProgress:!1,hasTeachingInProgress:!1,hasInstagraphInProgress:!1,teachMeAnswer:null,instgraphAnswser:null},C0=r0(i=>({...M0,setAskedQuestion:k=>i(e=>({askedQuestions:[...e.askedQuestions||[],k],hasQuestionInProgress:!0})),setAskedQuestionAnswer:k=>i(e=>({askedQuestionsAnswers:[...e.askedQuestionsAnswers||[],k],hasQuestionInProgress:!1})),setHasQuestionInProgress:k=>i({hasQuestionInProgress:k}),setHasTeachingInProgress:k=>i({hasTeachingInProgress:k}),setHasInstagraphInProgress:k=>i({hasInstagraphInProgress:k}),setTeachMeAnswer:k=>i({hasTeachingInProgress:!1,teachMeAnswer:k}),setInstagraphAnswer:k=>{var e,n,o,y;(e=k==null?void 0:k.instagraph)!=null&&e.edges&&((n=k==null?void 0:k.instagraph)!=null&&n.nodes)&&i({hasInstagraphInProgress:!1,instgraphAnswser:{edges:(o=k==null?void 0:k.instagraph)==null?void 0:o.edges,nodes:(y=k==null?void 0:k.instagraph)==null?void 0:y.nodes}})}})),T0="0.1.106",I0=x.lazy(()=>h(()=>import("./index-40addfb3.js"),["assets/index-40addfb3.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/ClipLoader-8590c2f1.js","assets/Tabs-71f3fbcc.js","assets/createSvgIcon-c125a9c8.js"]).then(({SettingsModal:i})=>({default:i}))),z0=x.lazy(()=>h(()=>import("./index-aff6ba6e.js"),["assets/index-aff6ba6e.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/ClipLoader-8590c2f1.js"]).then(({AddContentModal:i})=>({default:i}))),L0=x.lazy(()=>h(()=>import("./index-f0bb1f56.js"),["assets/index-f0bb1f56.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/ClipLoader-8590c2f1.js","assets/index-5fe8c70d.js","assets/three.module-71ec604c.js","assets/index-d96216bb.js","assets/index-569670a3.js","assets/Stack-5870980a.js","assets/createSvgIcon-c125a9c8.js","assets/TextareaAutosize-f6242cb8.js","assets/index-64f1c910.js"]).then(({AddItemModal:i})=>({default:i}))),N0=x.lazy(()=>h(()=>import("./index-b8b4f42e.js"),["assets/index-b8b4f42e.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/constants-b9d9206a.js","assets/ClipLoader-8590c2f1.js","assets/index-d96216bb.js","assets/index-569670a3.js","assets/Stack-5870980a.js","assets/createSvgIcon-c125a9c8.js","assets/TextareaAutosize-f6242cb8.js","assets/index-aa1facf3.js","assets/Typography-2a31701b.js","assets/Tabs-71f3fbcc.js"]).then(({SourcesTableModal:i})=>({default:i}))),R0=x.lazy(()=>h(()=>import("./index-047858ad.js"),["assets/index-047858ad.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/index-569670a3.js","assets/Skeleton-7af13a79.js","assets/ClipLoader-8590c2f1.js"]).then(({EditNodeNameModal:i})=>({default:i}))),O0=x.lazy(()=>h(()=>import("./index-8a87d5eb.js"),["assets/index-8a87d5eb.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/Skeleton-7af13a79.js","assets/ClipLoader-8590c2f1.js"]).then(({RemoveNodeModal:i})=>({default:i}))),$0=x.lazy(()=>h(()=>import("./index-cfa9dcd8.js"),["assets/index-cfa9dcd8.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/index-d96216bb.js","assets/index-569670a3.js","assets/Stack-5870980a.js","assets/createSvgIcon-c125a9c8.js","assets/TextareaAutosize-f6242cb8.js","assets/constants-b9d9206a.js","assets/ClipLoader-8590c2f1.js"]).then(({AddNodeEdgeModal:i})=>({default:i}))),q0=x.lazy(()=>h(()=>import("./index-5c4e6029.js"),["assets/index-5c4e6029.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/index-aa1facf3.js","assets/constants-b9d9206a.js","assets/index-d96216bb.js","assets/index-569670a3.js","assets/Stack-5870980a.js","assets/createSvgIcon-c125a9c8.js","assets/TextareaAutosize-f6242cb8.js","assets/ClipLoader-8590c2f1.js"]).then(({MergeNodeModal:i})=>({default:i}))),Q0=x.lazy(()=>h(()=>import("./index-cf343a35.js"),["assets/index-cf343a35.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-5fe8c70d.js","assets/three.module-71ec604c.js","assets/ClipLoader-8590c2f1.js","assets/index-af5a3f81.js","assets/index-d96216bb.js","assets/index-569670a3.js","assets/Stack-5870980a.js","assets/createSvgIcon-c125a9c8.js","assets/TextareaAutosize-f6242cb8.js","assets/index-64f1c910.js"]).then(({ChangeNodeTypeModal:i})=>({default:i}))),U0=x.lazy(()=>h(()=>import("./index-66368309.js"),["assets/index-66368309.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-d96216bb.js","assets/index-569670a3.js","assets/Stack-5870980a.js","assets/index-af5a3f81.js","assets/createSvgIcon-c125a9c8.js","assets/TextareaAutosize-f6242cb8.js","assets/ClipLoader-8590c2f1.js","assets/isPlainObject-1f2f9f4b.js","assets/Typography-2a31701b.js","assets/index-37b3c15b.js","assets/Tabs-71f3fbcc.js","assets/index-5fe8c70d.js","assets/three.module-71ec604c.js","assets/index-c715ffeb.js"]).then(({BlueprintModal:i})=>({default:i}))),W0=x.lazy(()=>h(()=>import("./index-769bba79.js"),["assets/index-769bba79.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js"]).then(({UserFeedBackModal:i})=>({default:i}))),H0=x.lazy(()=>h(()=>import("./index-c2e413fd.js"),["assets/index-c2e413fd.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/index-d96216bb.js","assets/index-569670a3.js","assets/Stack-5870980a.js","assets/createSvgIcon-c125a9c8.js","assets/TextareaAutosize-f6242cb8.js"]).then(({CreateBountyModal:i})=>({default:i}))),Y0=x.lazy(()=>h(()=>import("./index-4e60c9e2.js").then(i=>i.ce),["assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]).then(({OnboardingModal:i})=>({default:i}))),J0=x.lazy(()=>h(()=>import("./index-5c5c5836.js"),["assets/index-5c5c5836.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js"]).then(({BriefDescription:i})=>({default:i}))),K0=()=>a.jsxs(a.Fragment,{children:[a.jsx(L0,{}),a.jsx(z0,{}),a.jsx(I0,{}),a.jsx(R0,{}),a.jsx(O0,{}),a.jsx(N0,{}),a.jsx($0,{}),a.jsx(Q0,{}),a.jsx(U0,{}),a.jsx(q0,{}),a.jsx(W0,{}),a.jsx(H0,{}),a.jsx(Y0,{}),a.jsx(J0,{})]}),X0=()=>{const[i,k]=x.useState(null),{runningProjectMessages:e}=_(m=>m),n=m=>{k(m.currentTarget)},o=()=>{k(null)},y=!!i,u=y?"simple-popover":void 0;return e.length?a.jsxs(Z0,{ml:8,children:[a.jsx(ia,{onClick:n,children:a.jsxs(R,{content:"Messages",margin:"18px",children:[a.jsx("div",{className:"icon",children:a.jsx(e0,{})}),a.jsx("div",{className:"text",children:a.jsx("p",{children:e.length})})]})}),a.jsxs(ta,{anchorEl:i,anchorOrigin:{vertical:"bottom",horizontal:"right"},id:u,onClose:o,open:y,children:[a.jsx(x0,{onClick:o,children:a.jsx(o0,{})}),a.jsx(aa,{p:16,children:e.map(m=>a.jsx("p",{className:"item",children:m},m))})]})]}):null},Z0=c(d).attrs({align:"center",direction:"row",grow:0,justify:"flex-start"})``,aa=c(d)` max-height: 50vh; max-width: 30vw; background: transparent; @@ -360,4 +360,4 @@ import{W as s0,c as r0,r as x,_ as h,j as a,s as c,a as r,F as d,u as _,I as e0, color: ${r.white}; font-size: 12px; opacity: 0.5; -`,_a=x.lazy(()=>h(()=>import("./index-b3d55c88.js"),["assets/index-b3d55c88.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js"]).then(({MainToolbar:i})=>({default:i}))),Ma=x.lazy(()=>h(()=>import("./index-e06603b3.js"),["assets/index-e06603b3.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-dc12854c.js","assets/three.module-71ec604c.js","assets/index-7888478e.js","assets/index-7730ff6f.js","assets/TextareaAutosize-b716e8d1.js","assets/index-5111ebdb.js","assets/index-a17bf5d0.js","assets/ClipLoader-1ef5878d.js"]).then(({Universe:i})=>({default:i}))),Ca=x.lazy(()=>h(()=>import("./index-87de005d.js").then(i=>i.i),["assets/index-87de005d.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css","assets/index-7730ff6f.js","assets/ClipLoader-1ef5878d.js","assets/Skeleton-dbbfd404.js","assets/Stack-6038813c.js","assets/index-5111ebdb.js","assets/isPlainObject-b85008a5.js","assets/Typography-f76555b9.js","assets/createSvgIcon-41051178.js","assets/index-59c77710.js","assets/index-7888478e.js","assets/index-a17bf5d0.js"]).then(({SideBar:i})=>({default:i}))),Ta=()=>{const[i]=u0(),k=i.get("q"),{setBudget:e,setNodeCount:n}=a0(t=>t),o=x.useRef(null),y=x.useRef(null),{setSidebarOpen:u,currentSearch:m,setCurrentSearch:V,setRelevanceSelected:M,setTranscriptOpen:C,universeQuestionIsOpen:T,setUniverseQuestionIsOpen:g}=i0(t=>t),I=C0(t=>t.setTeachMeAnswer),{fetchData:F,setCategoryFilter:j,setAbortRequests:w,addNewNode:s,splashDataLoading:p,runningProjectId:f,setRunningProjectMessages:B,isFetching:D,resetData:S}=_(t=>t),{setAiSummaryAnswer:G,getKeyExist:O,aiRefId:z}=t0(t=>t),v=k0(),[$,E]=E0(t=>[t.realtimeGraphFeatureFlag,t.chatInterfaceFeatureFlag]),l=j0(),q=A0({mode:"onChange"}),{setValue:Q}=q;x.useEffect(()=>{Q("search",k??""),C(!1),v(null),M(!1),V(k??""),I(""),j(null)},[k,j,V,M,v,I,C,Q]),x.useEffect(()=>{const t=async()=>{await F(e,w),u(!0),m?await D0(e):v(null)};S(),t()},[m,F,e,w,u,v,S]);const U=x.useCallback(()=>{n("INCREMENT")},[n]),W=x.useCallback(t=>{D||(o.current||(o.current={nodes:[],edges:[]}),t.edges&&o.current.edges.push(...t.edges),t.nodes&&o.current.nodes.push(...t.nodes),y.current&&clearTimeout(y.current),y.current=setTimeout(()=>{if(o.current){const{nodes:b,edges:A}=o.current,P={nodes:b,edges:A};o.current={nodes:[],edges:[]},s(P)}},3e3))},[s,D]),H=x.useCallback(t=>{t.ref_id&&G(t.ref_id,{answer:t.answer,answerLoading:!1})},[G]),Y=x.useCallback(t=>{t.ref_id&&G(t.ref_id,{audio_en:t.audio_EN})},[G]),J=x.useCallback(t=>{t.ref_id&&G(t.ref_id,{questions:t.relevant_questions.map(b=>b.question),questionsLoading:!1})},[G]),K=x.useCallback(t=>{t.ref_id&&G(t.ref_id,{sources:t.sources.map(b=>b.ref_id),sourcesLoading:!1})},[G]),X=x.useCallback(t=>{t.question&&O(z)&&G(z,{answerLoading:!1,entities:t.entities})},[G,O,z]);return x.useEffect(()=>(l&&(l.connect(),l.on("connect_error",t=>{console.error("Socket connection error:",t)}),l.on("newnode",U),E&&l.on("extractedentitieshook",X),E&&l.on("askquestionhook",H),E&&l.on("relevantquestionshook",J),E&&l.on("answersourceshook",K),$&&l.on("new_node_created",W),E&&l.on("answeraudiohook",Y)),()=>{l&&l.off()}),[l,U,W,$,H,E,J,K,X,Y]),x.useEffect(()=>{},[f,B]),x.useEffect(()=>{if(f)try{l==null||l.emit("update_project_id",{id:f})}catch(t){console.error(t)}},[f,l]),x.useEffect(()=>{p||E&&g()},[g,p,E]),a.jsxs(a.Fragment,{children:[a.jsx(_0,{}),a.jsx(Fa,{}),a.jsx(x.Suspense,{fallback:a.jsx("div",{children:"Loading..."}),children:p?null:a.jsxs(va,{direction:"row",children:[a.jsxs(B0,{...q,children:[a.jsx(_a,{}),!T&&a.jsx(Ca,{}),a.jsx(Ma,{}),a.jsx(w0,{}),a.jsx(Ba,{}),a.jsxs(Pa,{children:["v",T0]}),a.jsx(v0,{})]}),a.jsx(K0,{}),a.jsx(wa,{})]})})]})},La=Object.freeze(Object.defineProperty({__proto__:null,App:Ta},Symbol.toStringTag,{value:"Module"}));export{P0 as f,La as i}; +`,_a=x.lazy(()=>h(()=>import("./index-70e1d6d6.js"),["assets/index-70e1d6d6.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js"]).then(({MainToolbar:i})=>({default:i}))),Ma=x.lazy(()=>h(()=>import("./index-88446b65.js"),["assets/index-88446b65.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-c715ffeb.js","assets/three.module-71ec604c.js","assets/index-37b3c15b.js","assets/index-af5a3f81.js","assets/TextareaAutosize-f6242cb8.js","assets/index-569670a3.js","assets/index-7fe50db2.js","assets/ClipLoader-8590c2f1.js"]).then(({Universe:i})=>({default:i}))),Ca=x.lazy(()=>h(()=>import("./index-a46872c4.js").then(i=>i.i),["assets/index-a46872c4.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css","assets/index-af5a3f81.js","assets/ClipLoader-8590c2f1.js","assets/Skeleton-7af13a79.js","assets/Stack-5870980a.js","assets/index-569670a3.js","assets/isPlainObject-1f2f9f4b.js","assets/Typography-2a31701b.js","assets/createSvgIcon-c125a9c8.js","assets/index-5c5c5836.js","assets/index-37b3c15b.js","assets/index-7fe50db2.js"]).then(({SideBar:i})=>({default:i}))),Ta=()=>{const[i]=u0(),k=i.get("q"),{setBudget:e,setNodeCount:n}=a0(t=>t),o=x.useRef(null),y=x.useRef(null),{setSidebarOpen:u,currentSearch:m,setCurrentSearch:V,setRelevanceSelected:M,setTranscriptOpen:C,universeQuestionIsOpen:T,setUniverseQuestionIsOpen:g}=i0(t=>t),I=C0(t=>t.setTeachMeAnswer),{fetchData:F,setCategoryFilter:j,setAbortRequests:w,addNewNode:s,splashDataLoading:p,runningProjectId:f,setRunningProjectMessages:B,isFetching:D,resetData:S}=_(t=>t),{setAiSummaryAnswer:G,getKeyExist:O,aiRefId:z}=t0(t=>t),v=k0(),[$,E]=E0(t=>[t.realtimeGraphFeatureFlag,t.chatInterfaceFeatureFlag]),l=j0(),q=A0({mode:"onChange"}),{setValue:Q}=q;x.useEffect(()=>{Q("search",k??""),C(!1),v(null),M(!1),V(k??""),I(""),j(null)},[k,j,V,M,v,I,C,Q]),x.useEffect(()=>{const t=async()=>{await F(e,w),u(!0),m?await D0(e):v(null)};S(),t()},[m,F,e,w,u,v,S]);const U=x.useCallback(()=>{n("INCREMENT")},[n]),W=x.useCallback(t=>{D||(o.current||(o.current={nodes:[],edges:[]}),t.edges&&o.current.edges.push(...t.edges),t.nodes&&o.current.nodes.push(...t.nodes),y.current&&clearTimeout(y.current),y.current=setTimeout(()=>{if(o.current){const{nodes:b,edges:A}=o.current,P={nodes:b,edges:A};o.current={nodes:[],edges:[]},s(P)}},3e3))},[s,D]),H=x.useCallback(t=>{t.ref_id&&G(t.ref_id,{answer:t.answer,answerLoading:!1})},[G]),Y=x.useCallback(t=>{t.ref_id&&G(t.ref_id,{audio_en:t.audio_EN})},[G]),J=x.useCallback(t=>{t.ref_id&&G(t.ref_id,{questions:t.relevant_questions.map(b=>b.question),questionsLoading:!1})},[G]),K=x.useCallback(t=>{t.ref_id&&G(t.ref_id,{sources:t.sources.map(b=>b.ref_id),sourcesLoading:!1})},[G]),X=x.useCallback(t=>{t.question&&O(z)&&G(z,{answerLoading:!1,entities:t.entities})},[G,O,z]);return x.useEffect(()=>(l&&(l.connect(),l.on("connect_error",t=>{console.error("Socket connection error:",t)}),l.on("newnode",U),E&&l.on("extractedentitieshook",X),E&&l.on("askquestionhook",H),E&&l.on("relevantquestionshook",J),E&&l.on("answersourceshook",K),$&&l.on("new_node_created",W),E&&l.on("answeraudiohook",Y)),()=>{l&&l.off()}),[l,U,W,$,H,E,J,K,X,Y]),x.useEffect(()=>{},[f,B]),x.useEffect(()=>{if(f)try{l==null||l.emit("update_project_id",{id:f})}catch(t){console.error(t)}},[f,l]),x.useEffect(()=>{p||E&&g()},[g,p,E]),a.jsxs(a.Fragment,{children:[a.jsx(_0,{}),a.jsx(Fa,{}),a.jsx(x.Suspense,{fallback:a.jsx("div",{children:"Loading..."}),children:p?null:a.jsxs(va,{direction:"row",children:[a.jsxs(B0,{...q,children:[a.jsx(_a,{}),!T&&a.jsx(Ca,{}),a.jsx(Ma,{}),a.jsx(w0,{}),a.jsx(Ba,{}),a.jsxs(Pa,{children:["v",T0]}),a.jsx(v0,{})]}),a.jsx(K0,{}),a.jsx(wa,{})]})})]})},La=Object.freeze(Object.defineProperty({__proto__:null,App:Ta},Symbol.toStringTag,{value:"Module"}));export{P0 as f,La as i}; diff --git a/build/assets/index-6e6f13b5.js b/build/assets/index-769bba79.js similarity index 61% rename from build/assets/index-6e6f13b5.js rename to build/assets/index-769bba79.js index f855c5c02..e0ff5a9a1 100644 --- a/build/assets/index-6e6f13b5.js +++ b/build/assets/index-769bba79.js @@ -1,8 +1,8 @@ -import{s as a,j as e,F as s,aY as b,aZ as j,B as w,T as i,a as n,e as S,t as y,r as m,aW as k,a$ as v,v as F,ag as B}from"./index-4bb27744.js";import{aK as T}from"./index-7730ff6f.js";const E=({allowNextStep:r})=>e.jsxs(s,{p:12,children:[e.jsx(s,{align:"center",direction:"row",justify:"space-between",mb:25,children:e.jsx(s,{align:"center",direction:"row",children:e.jsx($,{children:"Feedback"})})}),e.jsx(s,{mb:30,children:e.jsx(b,{id:"feedback-message",isTextArea:!0,maxLength:500,name:"message",placeholder:"Leave your feedback here ...",rules:j})}),e.jsx(s,{children:e.jsx(w,{color:"secondary","data-testid":"submit-feedback-btn",disabled:!r,size:"large",type:"submit",variant:"contained",children:"Submit"})})]}),$=a(i)` +import{s as a,j as e,F as s,aX as g,aY as j,B as w,T as i,a as n,e as S,t as y,r as m,aV as k,a_ as v,v as F,af as B}from"./index-4e60c9e2.js";import{aK as T}from"./index-af5a3f81.js";const E=({allowNextStep:r})=>e.jsxs(s,{p:12,children:[e.jsx(s,{align:"center",direction:"row",justify:"space-between",mb:25,children:e.jsx(s,{align:"center",direction:"row",children:e.jsx(z,{children:"Feedback"})})}),e.jsx(s,{mb:30,children:e.jsx(g,{id:"feedback-message",isTextArea:!0,maxLength:500,name:"message",placeholder:"Leave your feedback here ...",rules:j})}),e.jsx(s,{children:e.jsx(w,{color:"secondary","data-testid":"submit-feedback-btn",disabled:!r,size:"large",type:"submit",variant:"contained",children:"Submit"})})]}),z=a(i)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; -`,z=()=>e.jsxs(s,{align:"center",direction:"column",justify:"center",p:40,children:[e.jsx(C,{children:e.jsx(T,{})}),e.jsx(M,{children:"We've Got Your Feedback"}),e.jsx(W,{children:"Thank you for sharing your thoughts with us! We value your input."})]}),C=a.div` +`,C=()=>e.jsxs(s,{align:"center",direction:"column",justify:"center",p:40,children:[e.jsx(M,{children:e.jsx(T,{})}),e.jsx($,{children:"We've Got Your Feedback"}),e.jsx(I,{children:"Thank you for sharing your thoughts with us! We value your input."})]}),M=a.div` margin-bottom: 20px; width: 50px; height: 50px; @@ -17,13 +17,13 @@ import{s as a,j as e,F as s,aY as b,aZ as j,B as w,T as i,a as n,e as S,t as y,r circle { color: ${n.SUCESS}; } -`,M=a(i)` +`,$=a(i)` font-size: 22px; font-weight: 700; font-family: 'Barlow'; text-align: center; margin-bottom: 10px; -`,W=a(i)` +`,I=a(i)` font-size: 16px; font-family: 'Barlow'; text-align: center; @@ -31,4 +31,4 @@ import{s as a,j as e,F as s,aY as b,aZ as j,B as w,T as i,a as n,e as S,t as y,r font-weight: 400; color: ${n.GRAY6}; padding-top: 10px; -`,I=async r=>{try{const t=await B.post("/prediction/feedback",JSON.stringify(r));if(t.error){const{message:o}=t.error;throw new Error(o)}}catch(t){throw new Error(t.message||"Error submitting feedback")}},Y=()=>{const{close:r,visible:t}=S("feedback"),o=y({mode:"onChange"}),{watch:u,reset:c}=o,[x,d]=m.useState(!1);m.useEffect(()=>()=>{d(!1),c()},[t,c]);const l=u("message"),h=!!l&&l.trim().length>0,f=o.handleSubmit(async g=>{try{await I(g),k("Feedback Submitted"),d(!0)}catch(p){console.error(p.message)}});return e.jsx(v,{id:"feedback",kind:"small",onClose:r,preventOutsideClose:!0,children:e.jsx(F,{...o,children:e.jsx("form",{id:"feedback-form",onSubmit:f,children:x?e.jsx(z,{}):e.jsx(E,{allowNextStep:h})})})})};export{Y as UserFeedBackModal}; +`,N=async r=>{try{const t=await B.post("/prediction/feedback",JSON.stringify(r));if(t.error){const{message:o}=t.error;throw new Error(o)}}catch(t){throw new Error(t.message||"Error submitting feedback")}},Y=()=>{const{close:r,visible:t}=S("feedback"),o=y({mode:"onChange"}),{watch:u,reset:c}=o,[x,d]=m.useState(!1);m.useEffect(()=>()=>{d(!1),c()},[t,c]);const l=u("message"),h=!!l&&l.trim().length>0,f=o.handleSubmit(async p=>{try{await N(p),k("Feedback Submitted"),d(!0)}catch(b){console.error(b.message)}});return e.jsx(v,{id:"feedback",kind:"small",onClose:r,preventOutsideClose:!0,children:e.jsx(F,{...o,children:e.jsx("form",{id:"feedback-form",onSubmit:f,children:x?e.jsx(C,{}):e.jsx(E,{allowNextStep:h})})})})};export{Y as UserFeedBackModal}; diff --git a/build/assets/index-a17bf5d0.js b/build/assets/index-7fe50db2.js similarity index 69% rename from build/assets/index-a17bf5d0.js rename to build/assets/index-7fe50db2.js index 46ae2c795..bdaea78b1 100644 --- a/build/assets/index-a17bf5d0.js +++ b/build/assets/index-7fe50db2.js @@ -1 +1 @@ -import"./index-4bb27744.js";import{f as o}from"./index-7730ff6f.js";const a=()=>{const{simulation:s,simulationHelpers:e}=o(r=>r);return{nodes:(s==null?void 0:s.nodes())||[],links:e.getLinks()}};export{a as u}; +import"./index-4e60c9e2.js";import{f as o}from"./index-af5a3f81.js";const a=()=>{const{simulation:s,simulationHelpers:e}=o(r=>r);return{nodes:(s==null?void 0:s.nodes())||[],links:e.getLinks()}};export{a as u}; diff --git a/build/assets/index-e06603b3.js b/build/assets/index-88446b65.js similarity index 99% rename from build/assets/index-e06603b3.js rename to build/assets/index-88446b65.js index 07d74c584..896979179 100644 --- a/build/assets/index-e06603b3.js +++ b/build/assets/index-88446b65.js @@ -1,4 +1,4 @@ -import{r as v,a1 as gu,O as Se,j as P,R as mp,a8 as B_,J as N,a9 as W_,c as gp,s as ge,a as ie,F as Me,B as _p,u as Nt,b as _u,k as bo,n as jh,T as yp,d as Hn,aa as yu,l as q_,e as Er,E as vp,ab as H_,ac as Y_,i as G_,x as Lr,ad as X_,C as Z_,ae as K_,af as zh}from"./index-4bb27744.js";import{u as Ye,a as Ht,m as lc,b as uc,e as vu,L as bu,c as Q_,d as J_,q as ey,f as ty,g as bp,T as xu,h as wu,t as _a,H as xo,P as ny,C as sy,i as ry,j as xp,k as Vh,l as Uh,n as iy}from"./index-dc12854c.js";import{P as Ee}from"./index-7888478e.js";import{k as Bh,H as oy,E as ay,l as ts,f as ze,m as wp,N as Vi,I as hc,n as cy,o as Wh,D as ly,p as uy,R as hy,q as dy,r as kp,P as fy,s as Tp,t as py,O as my}from"./index-7730ff6f.js";import{T as gy}from"./TextareaAutosize-b716e8d1.js";import{D as zo,F as _y,V as ye,L as yy,a as vy,M as fr,b as Te,S as by,B as xy,c as Ep,P as Bc,d as wy,e as ua,f as Ms,T as dc,g as ya,h as ky,i as qh,G as Ty,C as va,j as Ey,k as wo,Q as Cy,l as Cp,W as Sy,m as Oy,n as Ay,E as Ry,o as Dy,p as fc,q as Hh,r as Sp,s as Op}from"./three.module-71ec604c.js";import{T as Py}from"./index-5111ebdb.js";import{u as My}from"./index-a17bf5d0.js";import{C as Ny}from"./ClipLoader-1ef5878d.js";const Iy=["top","right","bottom","left"],vs=Math.min,jt=Math.max,ba=Math.round,Vo=Math.floor,bs=n=>({x:n,y:n}),$y={left:"right",right:"left",bottom:"top",top:"bottom"},Fy={start:"end",end:"start"};function xl(n,e,t){return jt(n,vs(e,t))}function Yn(n,e){return typeof n=="function"?n(e):n}function Gn(n){return n.split("-")[0]}function ei(n){return n.split("-")[1]}function ku(n){return n==="x"?"y":"x"}function Tu(n){return n==="y"?"height":"width"}function ti(n){return["top","bottom"].includes(Gn(n))?"y":"x"}function Eu(n){return ku(ti(n))}function Ly(n,e,t){t===void 0&&(t=!1);const s=ei(n),r=Eu(n),i=Tu(r);let o=r==="x"?s===(t?"end":"start")?"right":"left":s==="start"?"bottom":"top";return e.reference[i]>e.floating[i]&&(o=xa(o)),[o,xa(o)]}function jy(n){const e=xa(n);return[wl(n),e,wl(e)]}function wl(n){return n.replace(/start|end/g,e=>Fy[e])}function zy(n,e,t){const s=["left","right"],r=["right","left"],i=["top","bottom"],o=["bottom","top"];switch(n){case"top":case"bottom":return t?e?r:s:e?s:r;case"left":case"right":return e?i:o;default:return[]}}function Vy(n,e,t,s){const r=ei(n);let i=zy(Gn(n),t==="start",s);return r&&(i=i.map(o=>o+"-"+r),e&&(i=i.concat(i.map(wl)))),i}function xa(n){return n.replace(/left|right|bottom|top/g,e=>$y[e])}function Uy(n){return{top:0,right:0,bottom:0,left:0,...n}}function Ap(n){return typeof n!="number"?Uy(n):{top:n,right:n,bottom:n,left:n}}function wa(n){return{...n,top:n.y,left:n.x,right:n.x+n.width,bottom:n.y+n.height}}function Yh(n,e,t){let{reference:s,floating:r}=n;const i=ti(e),o=Eu(e),a=Tu(o),c=Gn(e),l=i==="y",u=s.x+s.width/2-r.width/2,h=s.y+s.height/2-r.height/2,d=s[a]/2-r[a]/2;let f;switch(c){case"top":f={x:u,y:s.y-r.height};break;case"bottom":f={x:u,y:s.y+s.height};break;case"right":f={x:s.x+s.width,y:h};break;case"left":f={x:s.x-r.width,y:h};break;default:f={x:s.x,y:s.y}}switch(ei(e)){case"start":f[o]-=d*(t&&l?-1:1);break;case"end":f[o]+=d*(t&&l?-1:1);break}return f}const By=async(n,e,t)=>{const{placement:s="bottom",strategy:r="absolute",middleware:i=[],platform:o}=t,a=i.filter(Boolean),c=await(o.isRTL==null?void 0:o.isRTL(e));let l=await o.getElementRects({reference:n,floating:e,strategy:r}),{x:u,y:h}=Yh(l,s,c),d=s,f={},m=0;for(let p=0;p({name:"arrow",options:n,async fn(e){const{x:t,y:s,placement:r,rects:i,platform:o,elements:a,middlewareData:c}=e,{element:l,padding:u=0}=Yn(n,e)||{};if(l==null)return{};const h=Ap(u),d={x:t,y:s},f=Eu(r),m=Tu(f),p=await o.getDimensions(l),g=f==="y",_=g?"top":"left",T=g?"bottom":"right",w=g?"clientHeight":"clientWidth",b=i.reference[m]+i.reference[f]-d[f]-i.floating[m],y=d[f]-i.reference[f],x=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l));let E=x?x[w]:0;(!E||!await(o.isElement==null?void 0:o.isElement(x)))&&(E=a.floating[w]||i.floating[m]);const k=b/2-y/2,C=E/2-p[m]/2-1,S=vs(h[_],C),R=vs(h[T],C),O=S,L=E-p[m]-R,j=E/2-p[m]/2+k,W=xl(O,j,L),V=!c.arrow&&ei(r)!=null&&j!=W&&i.reference[m]/2-(jO<=0)){var C,S;const O=(((C=i.flip)==null?void 0:C.index)||0)+1,L=y[O];if(L)return{data:{index:O,overflows:k},reset:{placement:L}};let j=(S=k.filter(W=>W.overflows[0]<=0).sort((W,V)=>W.overflows[1]-V.overflows[1])[0])==null?void 0:S.placement;if(!j)switch(f){case"bestFit":{var R;const W=(R=k.map(V=>[V.placement,V.overflows.filter(U=>U>0).reduce((U,B)=>U+B,0)]).sort((V,U)=>V[1]-U[1])[0])==null?void 0:R[0];W&&(j=W);break}case"initialPlacement":j=a;break}if(r!==j)return{reset:{placement:j}}}return{}}}};function Xh(n,e){return{top:n.top-e.height,right:n.right-e.width,bottom:n.bottom-e.height,left:n.left-e.width}}function Zh(n){return Iy.some(e=>n[e]>=0)}const qy=function(n){return n===void 0&&(n={}),{name:"hide",options:n,async fn(e){const{rects:t}=e,{strategy:s="referenceHidden",...r}=Yn(n,e);switch(s){case"referenceHidden":{const i=await Ui(e,{...r,elementContext:"reference"}),o=Xh(i,t.reference);return{data:{referenceHiddenOffsets:o,referenceHidden:Zh(o)}}}case"escaped":{const i=await Ui(e,{...r,altBoundary:!0}),o=Xh(i,t.floating);return{data:{escapedOffsets:o,escaped:Zh(o)}}}default:return{}}}}};async function Hy(n,e){const{placement:t,platform:s,elements:r}=n,i=await(s.isRTL==null?void 0:s.isRTL(r.floating)),o=Gn(t),a=ei(t),c=ti(t)==="y",l=["left","top"].includes(o)?-1:1,u=i&&c?-1:1,h=Yn(e,n);let{mainAxis:d,crossAxis:f,alignmentAxis:m}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...h};return a&&typeof m=="number"&&(f=a==="end"?m*-1:m),c?{x:f*u,y:d*l}:{x:d*l,y:f*u}}const Yy=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(e){var t,s;const{x:r,y:i,placement:o,middlewareData:a}=e,c=await Hy(e,n);return o===((t=a.offset)==null?void 0:t.placement)&&(s=a.arrow)!=null&&s.alignmentOffset?{}:{x:r+c.x,y:i+c.y,data:{...c,placement:o}}}}},Gy=function(n){return n===void 0&&(n={}),{name:"shift",options:n,async fn(e){const{x:t,y:s,placement:r}=e,{mainAxis:i=!0,crossAxis:o=!1,limiter:a={fn:g=>{let{x:_,y:T}=g;return{x:_,y:T}}},...c}=Yn(n,e),l={x:t,y:s},u=await Ui(e,c),h=ti(Gn(r)),d=ku(h);let f=l[d],m=l[h];if(i){const g=d==="y"?"top":"left",_=d==="y"?"bottom":"right",T=f+u[g],w=f-u[_];f=xl(T,f,w)}if(o){const g=h==="y"?"top":"left",_=h==="y"?"bottom":"right",T=m+u[g],w=m-u[_];m=xl(T,m,w)}const p=a.fn({...e,[d]:f,[h]:m});return{...p,data:{x:p.x-t,y:p.y-s}}}}},Xy=function(n){return n===void 0&&(n={}),{options:n,fn(e){const{x:t,y:s,placement:r,rects:i,middlewareData:o}=e,{offset:a=0,mainAxis:c=!0,crossAxis:l=!0}=Yn(n,e),u={x:t,y:s},h=ti(r),d=ku(h);let f=u[d],m=u[h];const p=Yn(a,e),g=typeof p=="number"?{mainAxis:p,crossAxis:0}:{mainAxis:0,crossAxis:0,...p};if(c){const w=d==="y"?"height":"width",b=i.reference[d]-i.floating[w]+g.mainAxis,y=i.reference[d]+i.reference[w]-g.mainAxis;fy&&(f=y)}if(l){var _,T;const w=d==="y"?"width":"height",b=["top","left"].includes(Gn(r)),y=i.reference[h]-i.floating[w]+(b&&((_=o.offset)==null?void 0:_[h])||0)+(b?0:g.crossAxis),x=i.reference[h]+i.reference[w]+(b?0:((T=o.offset)==null?void 0:T[h])||0)-(b?g.crossAxis:0);mx&&(m=x)}return{[d]:f,[h]:m}}}},Zy=function(n){return n===void 0&&(n={}),{name:"size",options:n,async fn(e){const{placement:t,rects:s,platform:r,elements:i}=e,{apply:o=()=>{},...a}=Yn(n,e),c=await Ui(e,a),l=Gn(t),u=ei(t),h=ti(t)==="y",{width:d,height:f}=s.floating;let m,p;l==="top"||l==="bottom"?(m=l,p=u===(await(r.isRTL==null?void 0:r.isRTL(i.floating))?"start":"end")?"left":"right"):(p=l,m=u==="end"?"top":"bottom");const g=f-c[m],_=d-c[p],T=!e.middlewareData.shift;let w=g,b=_;if(h){const x=d-c.left-c.right;b=u||T?vs(_,x):x}else{const x=f-c.top-c.bottom;w=u||T?vs(g,x):x}if(T&&!u){const x=jt(c.left,0),E=jt(c.right,0),k=jt(c.top,0),C=jt(c.bottom,0);h?b=d-2*(x!==0||E!==0?x+E:jt(c.left,c.right)):w=f-2*(k!==0||C!==0?k+C:jt(c.top,c.bottom))}await o({...e,availableWidth:b,availableHeight:w});const y=await r.getDimensions(i.floating);return d!==y.width||f!==y.height?{reset:{rects:!0}}:{}}}};function xs(n){return Rp(n)?(n.nodeName||"").toLowerCase():"#document"}function Ut(n){var e;return(n==null||(e=n.ownerDocument)==null?void 0:e.defaultView)||window}function ns(n){var e;return(e=(Rp(n)?n.ownerDocument:n.document)||window.document)==null?void 0:e.documentElement}function Rp(n){return n instanceof Node||n instanceof Ut(n).Node}function Xn(n){return n instanceof Element||n instanceof Ut(n).Element}function Sn(n){return n instanceof HTMLElement||n instanceof Ut(n).HTMLElement}function Kh(n){return typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof Ut(n).ShadowRoot}function ko(n){const{overflow:e,overflowX:t,overflowY:s,display:r}=en(n);return/auto|scroll|overlay|hidden|clip/.test(e+s+t)&&!["inline","contents"].includes(r)}function Ky(n){return["table","td","th"].includes(xs(n))}function Cu(n){const e=Su(),t=en(n);return t.transform!=="none"||t.perspective!=="none"||(t.containerType?t.containerType!=="normal":!1)||!e&&(t.backdropFilter?t.backdropFilter!=="none":!1)||!e&&(t.filter?t.filter!=="none":!1)||["transform","perspective","filter"].some(s=>(t.willChange||"").includes(s))||["paint","layout","strict","content"].some(s=>(t.contain||"").includes(s))}function Qy(n){let e=jr(n);for(;Sn(e)&&!pc(e);){if(Cu(e))return e;e=jr(e)}return null}function Su(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function pc(n){return["html","body","#document"].includes(xs(n))}function en(n){return Ut(n).getComputedStyle(n)}function mc(n){return Xn(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.pageXOffset,scrollTop:n.pageYOffset}}function jr(n){if(xs(n)==="html")return n;const e=n.assignedSlot||n.parentNode||Kh(n)&&n.host||ns(n);return Kh(e)?e.host:e}function Dp(n){const e=jr(n);return pc(e)?n.ownerDocument?n.ownerDocument.body:n.body:Sn(e)&&ko(e)?e:Dp(e)}function Bi(n,e,t){var s;e===void 0&&(e=[]),t===void 0&&(t=!0);const r=Dp(n),i=r===((s=n.ownerDocument)==null?void 0:s.body),o=Ut(r);return i?e.concat(o,o.visualViewport||[],ko(r)?r:[],o.frameElement&&t?Bi(o.frameElement):[]):e.concat(r,Bi(r,[],t))}function Pp(n){const e=en(n);let t=parseFloat(e.width)||0,s=parseFloat(e.height)||0;const r=Sn(n),i=r?n.offsetWidth:t,o=r?n.offsetHeight:s,a=ba(t)!==i||ba(s)!==o;return a&&(t=i,s=o),{width:t,height:s,$:a}}function Ou(n){return Xn(n)?n:n.contextElement}function Dr(n){const e=Ou(n);if(!Sn(e))return bs(1);const t=e.getBoundingClientRect(),{width:s,height:r,$:i}=Pp(e);let o=(i?ba(t.width):t.width)/s,a=(i?ba(t.height):t.height)/r;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const Jy=bs(0);function Mp(n){const e=Ut(n);return!Su()||!e.visualViewport?Jy:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function e1(n,e,t){return e===void 0&&(e=!1),!t||e&&t!==Ut(n)?!1:e}function Qs(n,e,t,s){e===void 0&&(e=!1),t===void 0&&(t=!1);const r=n.getBoundingClientRect(),i=Ou(n);let o=bs(1);e&&(s?Xn(s)&&(o=Dr(s)):o=Dr(n));const a=e1(i,t,s)?Mp(i):bs(0);let c=(r.left+a.x)/o.x,l=(r.top+a.y)/o.y,u=r.width/o.x,h=r.height/o.y;if(i){const d=Ut(i),f=s&&Xn(s)?Ut(s):s;let m=d.frameElement;for(;m&&s&&f!==d;){const p=Dr(m),g=m.getBoundingClientRect(),_=en(m),T=g.left+(m.clientLeft+parseFloat(_.paddingLeft))*p.x,w=g.top+(m.clientTop+parseFloat(_.paddingTop))*p.y;c*=p.x,l*=p.y,u*=p.x,h*=p.y,c+=T,l+=w,m=Ut(m).frameElement}}return wa({width:u,height:h,x:c,y:l})}function t1(n){let{rect:e,offsetParent:t,strategy:s}=n;const r=Sn(t),i=ns(t);if(t===i)return e;let o={scrollLeft:0,scrollTop:0},a=bs(1);const c=bs(0);if((r||!r&&s!=="fixed")&&((xs(t)!=="body"||ko(i))&&(o=mc(t)),Sn(t))){const l=Qs(t);a=Dr(t),c.x=l.x+t.clientLeft,c.y=l.y+t.clientTop}return{width:e.width*a.x,height:e.height*a.y,x:e.x*a.x-o.scrollLeft*a.x+c.x,y:e.y*a.y-o.scrollTop*a.y+c.y}}function n1(n){return Array.from(n.getClientRects())}function Np(n){return Qs(ns(n)).left+mc(n).scrollLeft}function s1(n){const e=ns(n),t=mc(n),s=n.ownerDocument.body,r=jt(e.scrollWidth,e.clientWidth,s.scrollWidth,s.clientWidth),i=jt(e.scrollHeight,e.clientHeight,s.scrollHeight,s.clientHeight);let o=-t.scrollLeft+Np(n);const a=-t.scrollTop;return en(s).direction==="rtl"&&(o+=jt(e.clientWidth,s.clientWidth)-r),{width:r,height:i,x:o,y:a}}function r1(n,e){const t=Ut(n),s=ns(n),r=t.visualViewport;let i=s.clientWidth,o=s.clientHeight,a=0,c=0;if(r){i=r.width,o=r.height;const l=Su();(!l||l&&e==="fixed")&&(a=r.offsetLeft,c=r.offsetTop)}return{width:i,height:o,x:a,y:c}}function i1(n,e){const t=Qs(n,!0,e==="fixed"),s=t.top+n.clientTop,r=t.left+n.clientLeft,i=Sn(n)?Dr(n):bs(1),o=n.clientWidth*i.x,a=n.clientHeight*i.y,c=r*i.x,l=s*i.y;return{width:o,height:a,x:c,y:l}}function Qh(n,e,t){let s;if(e==="viewport")s=r1(n,t);else if(e==="document")s=s1(ns(n));else if(Xn(e))s=i1(e,t);else{const r=Mp(n);s={...e,x:e.x-r.x,y:e.y-r.y}}return wa(s)}function Ip(n,e){const t=jr(n);return t===e||!Xn(t)||pc(t)?!1:en(t).position==="fixed"||Ip(t,e)}function o1(n,e){const t=e.get(n);if(t)return t;let s=Bi(n,[],!1).filter(a=>Xn(a)&&xs(a)!=="body"),r=null;const i=en(n).position==="fixed";let o=i?jr(n):n;for(;Xn(o)&&!pc(o);){const a=en(o),c=Cu(o);!c&&a.position==="fixed"&&(r=null),(i?!c&&!r:!c&&a.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||ko(o)&&!c&&Ip(n,o))?s=s.filter(u=>u!==o):r=a,o=jr(o)}return e.set(n,s),s}function a1(n){let{element:e,boundary:t,rootBoundary:s,strategy:r}=n;const o=[...t==="clippingAncestors"?o1(e,this._c):[].concat(t),s],a=o[0],c=o.reduce((l,u)=>{const h=Qh(e,u,r);return l.top=jt(h.top,l.top),l.right=vs(h.right,l.right),l.bottom=vs(h.bottom,l.bottom),l.left=jt(h.left,l.left),l},Qh(e,a,r));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function c1(n){return Pp(n)}function l1(n,e,t){const s=Sn(e),r=ns(e),i=t==="fixed",o=Qs(n,!0,i,e);let a={scrollLeft:0,scrollTop:0};const c=bs(0);if(s||!s&&!i)if((xs(e)!=="body"||ko(r))&&(a=mc(e)),s){const l=Qs(e,!0,i,e);c.x=l.x+e.clientLeft,c.y=l.y+e.clientTop}else r&&(c.x=Np(r));return{x:o.left+a.scrollLeft-c.x,y:o.top+a.scrollTop-c.y,width:o.width,height:o.height}}function Jh(n,e){return!Sn(n)||en(n).position==="fixed"?null:e?e(n):n.offsetParent}function $p(n,e){const t=Ut(n);if(!Sn(n))return t;let s=Jh(n,e);for(;s&&Ky(s)&&en(s).position==="static";)s=Jh(s,e);return s&&(xs(s)==="html"||xs(s)==="body"&&en(s).position==="static"&&!Cu(s))?t:s||Qy(n)||t}const u1=async function(n){let{reference:e,floating:t,strategy:s}=n;const r=this.getOffsetParent||$p,i=this.getDimensions;return{reference:l1(e,await r(t),s),floating:{x:0,y:0,...await i(t)}}};function h1(n){return en(n).direction==="rtl"}const d1={convertOffsetParentRelativeRectToViewportRelativeRect:t1,getDocumentElement:ns,getClippingRect:a1,getOffsetParent:$p,getElementRects:u1,getClientRects:n1,getDimensions:c1,getScale:Dr,isElement:Xn,isRTL:h1};function f1(n,e){let t=null,s;const r=ns(n);function i(){clearTimeout(s),t&&t.disconnect(),t=null}function o(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),i();const{left:l,top:u,width:h,height:d}=n.getBoundingClientRect();if(a||e(),!h||!d)return;const f=Vo(u),m=Vo(r.clientWidth-(l+h)),p=Vo(r.clientHeight-(u+d)),g=Vo(l),T={rootMargin:-f+"px "+-m+"px "+-p+"px "+-g+"px",threshold:jt(0,vs(1,c))||1};let w=!0;function b(y){const x=y[0].intersectionRatio;if(x!==c){if(!w)return o();x?o(!1,x):s=setTimeout(()=>{o(!1,1e-7)},100)}w=!1}try{t=new IntersectionObserver(b,{...T,root:r.ownerDocument})}catch{t=new IntersectionObserver(b,T)}t.observe(n)}return o(!0),i}function p1(n,e,t,s){s===void 0&&(s={});const{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=s,l=Ou(n),u=r||i?[...l?Bi(l):[],...Bi(e)]:[];u.forEach(_=>{r&&_.addEventListener("scroll",t,{passive:!0}),i&&_.addEventListener("resize",t)});const h=l&&a?f1(l,t):null;let d=-1,f=null;o&&(f=new ResizeObserver(_=>{let[T]=_;T&&T.target===l&&f&&(f.unobserve(e),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{f&&f.observe(e)})),t()}),l&&!c&&f.observe(l),f.observe(e));let m,p=c?Qs(n):null;c&&g();function g(){const _=Qs(n);p&&(_.x!==p.x||_.y!==p.y||_.width!==p.width||_.height!==p.height)&&t(),p=_,m=requestAnimationFrame(g)}return t(),()=>{u.forEach(_=>{r&&_.removeEventListener("scroll",t),i&&_.removeEventListener("resize",t)}),h&&h(),f&&f.disconnect(),f=null,c&&cancelAnimationFrame(m)}}const m1=(n,e,t)=>{const s=new Map,r={platform:d1,...t},i={...r.platform,_c:s};return By(n,e,{...r,platform:i})},g1=n=>{function e(t){return{}.hasOwnProperty.call(t,"current")}return{name:"arrow",options:n,fn(t){const{element:s,padding:r}=typeof n=="function"?n(t):n;return s&&e(s)?s.current!=null?Gh({element:s.current,padding:r}).fn(t):{}:s?Gh({element:s,padding:r}).fn(t):{}}}};var ha=typeof document<"u"?v.useLayoutEffect:v.useEffect;function ka(n,e){if(n===e)return!0;if(typeof n!=typeof e)return!1;if(typeof n=="function"&&n.toString()===e.toString())return!0;let t,s,r;if(n&&e&&typeof n=="object"){if(Array.isArray(n)){if(t=n.length,t!=e.length)return!1;for(s=t;s--!==0;)if(!ka(n[s],e[s]))return!1;return!0}if(r=Object.keys(n),t=r.length,t!==Object.keys(e).length)return!1;for(s=t;s--!==0;)if(!{}.hasOwnProperty.call(e,r[s]))return!1;for(s=t;s--!==0;){const i=r[s];if(!(i==="_owner"&&n.$$typeof)&&!ka(n[i],e[i]))return!1}return!0}return n!==n&&e!==e}function Fp(n){return typeof window>"u"?1:(n.ownerDocument.defaultView||window).devicePixelRatio||1}function ed(n,e){const t=Fp(n);return Math.round(e*t)/t}function td(n){const e=v.useRef(n);return ha(()=>{e.current=n}),e}function _1(n){n===void 0&&(n={});const{placement:e="bottom",strategy:t="absolute",middleware:s=[],platform:r,elements:{reference:i,floating:o}={},transform:a=!0,whileElementsMounted:c,open:l}=n,[u,h]=v.useState({x:0,y:0,strategy:t,placement:e,middlewareData:{},isPositioned:!1}),[d,f]=v.useState(s);ka(d,s)||f(s);const[m,p]=v.useState(null),[g,_]=v.useState(null),T=v.useCallback(V=>{V!=x.current&&(x.current=V,p(V))},[p]),w=v.useCallback(V=>{V!==E.current&&(E.current=V,_(V))},[_]),b=i||m,y=o||g,x=v.useRef(null),E=v.useRef(null),k=v.useRef(u),C=td(c),S=td(r),R=v.useCallback(()=>{if(!x.current||!E.current)return;const V={placement:e,strategy:t,middleware:d};S.current&&(V.platform=S.current),m1(x.current,E.current,V).then(U=>{const B={...U,isPositioned:!0};O.current&&!ka(k.current,B)&&(k.current=B,gu.flushSync(()=>{h(B)}))})},[d,e,t,S]);ha(()=>{l===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,h(V=>({...V,isPositioned:!1})))},[l]);const O=v.useRef(!1);ha(()=>(O.current=!0,()=>{O.current=!1}),[]),ha(()=>{if(b&&(x.current=b),y&&(E.current=y),b&&y){if(C.current)return C.current(b,y,R);R()}},[b,y,R,C]);const L=v.useMemo(()=>({reference:x,floating:E,setReference:T,setFloating:w}),[T,w]),j=v.useMemo(()=>({reference:b,floating:y}),[b,y]),W=v.useMemo(()=>{const V={position:t,left:0,top:0};if(!j.floating)return V;const U=ed(j.floating,u.x),B=ed(j.floating,u.y);return a?{...V,transform:"translate("+U+"px, "+B+"px)",...Fp(j.floating)>=1.5&&{willChange:"transform"}}:{position:t,left:U,top:B}},[t,a,j.floating,u.x,u.y]);return v.useMemo(()=>({...u,update:R,refs:L,elements:j,floatingStyles:W}),[u,R,L,j,W])}function y1(n){let e;const t=new Set,s=(l,u)=>{const h=typeof l=="function"?l(e):l;if(h!==e){const d=e;e=u?h:Object.assign({},e,h),t.forEach(f=>f(e,d))}},r=()=>e,i=(l,u=r,h=Object.is)=>{console.warn("[DEPRECATED] Please use `subscribeWithSelector` middleware");let d=u(e);function f(){const m=u(e);if(!h(d,m)){const p=d;l(d=m,p)}}return t.add(f),()=>t.delete(f)},c={setState:s,getState:r,subscribe:(l,u,h)=>u||h?i(l,u,h):(t.add(l),()=>t.delete(l)),destroy:()=>t.clear()};return e=n(s,r,c),c}const v1=typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),nd=v1?v.useEffect:v.useLayoutEffect;function b1(n){const e=typeof n=="function"?y1(n):n,t=(s=e.getState,r=Object.is)=>{const[,i]=v.useReducer(g=>g+1,0),o=e.getState(),a=v.useRef(o),c=v.useRef(s),l=v.useRef(r),u=v.useRef(!1),h=v.useRef();h.current===void 0&&(h.current=s(o));let d,f=!1;(a.current!==o||c.current!==s||l.current!==r||u.current)&&(d=s(o),f=!r(h.current,d)),nd(()=>{f&&(h.current=d),a.current=o,c.current=s,l.current=r,u.current=!1});const m=v.useRef(o);nd(()=>{const g=()=>{try{const T=e.getState(),w=c.current(T);l.current(h.current,w)||(a.current=T,h.current=w,i())}catch{u.current=!0,i()}},_=e.subscribe(g);return e.getState()!==m.current&&g(),_},[]);const p=f?d:h.current;return v.useDebugValue(p),p};return Object.assign(t,e),t[Symbol.iterator]=function(){console.warn("[useStore, api] = create() is deprecated and will be removed in v4");const s=[t,e];return{next(){const r=s.length<=0;return{value:s.shift(),done:r}}}},t}let hi=0;const x1=b1(n=>(zo.onStart=(e,t,s)=>{n({active:!0,item:e,loaded:t,total:s,progress:(t-hi)/(s-hi)*100})},zo.onLoad=()=>{n({active:!1})},zo.onError=e=>n(t=>({errors:[...t.errors,e]})),zo.onProgress=(e,t,s)=>{t===s&&(hi=s),n({active:!0,item:e,loaded:t,total:s,progress:(t-hi)/(s-hi)*100||100})},{errors:[],active:!1,progress:0,item:"",loaded:0,total:0})),w1=n=>`Loading ${n.toFixed(2)}%`;function k1({containerStyles:n,innerStyles:e,barStyles:t,dataStyles:s,dataInterpolation:r=w1,initialState:i=o=>o}){const{active:o,progress:a}=x1(),c=v.useRef(0),l=v.useRef(0),u=v.useRef(null),[h,d]=v.useState(i(o));v.useEffect(()=>{let m;return o!==h&&(m=setTimeout(()=>d(o),300)),()=>clearTimeout(m)},[h,o]);const f=v.useCallback(()=>{u.current&&(c.current+=(a-c.current)/2,(c.current>.95*a||a===100)&&(c.current=a),u.current.innerText=r(c.current),c.current(f(),()=>cancelAnimationFrame(l.current)),[f]),h?v.createElement("div",{style:{...Uo.container,opacity:o?1:0,...n}},v.createElement("div",null,v.createElement("div",{style:{...Uo.inner,...e}},v.createElement("div",{style:{...Uo.bar,transform:`scaleX(${a/100})`,...t}}),v.createElement("span",{ref:u,style:{...Uo.data,...s}})))):null}const Uo={container:{position:"absolute",top:0,left:0,width:"100%",height:"100%",background:"#171717",display:"flex",alignItems:"center",justifyContent:"center",transition:"opacity 300ms ease",zIndex:1e3},inner:{width:100,height:3,background:"#272727",textAlign:"center"},bar:{height:3,width:"100%",background:"white",transition:"transform 200ms",transformOrigin:"left center"},data:{display:"inline-block",position:"relative",fontVariantNumeric:"tabular-nums",marginTop:"0.8em",color:"#f0f0f0",fontSize:"0.6em",fontFamily:'-apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", "Helvetica Neue", Helvetica, Arial, Roboto, Ubuntu, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',whiteSpace:"nowrap"}},Wc=new _y,qc=new ye,pr=new ye,rn=new ye,Nn=new ye,vn=new ye,In=new ye,$n=new ye,di=new ye,fi=new ye,pi=new ye,Bo=new ye,mi=new ye,gi=new ye,_i=new ye;class T1{constructor(e,t,s){this.camera=e,this.scene=t,this.startPoint=new ye,this.endPoint=new ye,this.collection=[],this.deep=s||Number.MAX_VALUE}select(e,t){return this.startPoint=e||this.startPoint,this.endPoint=t||this.endPoint,this.collection=[],this.updateFrustum(this.startPoint,this.endPoint),this.searchChildInFrustum(Wc,this.scene),this.collection}updateFrustum(e,t){if(e=e||this.startPoint,t=t||this.endPoint,e.x===t.x&&(t.x+=Number.EPSILON),e.y===t.y&&(t.y+=Number.EPSILON),this.camera.updateProjectionMatrix(),this.camera.updateMatrixWorld(),this.camera.isPerspectiveCamera){pr.copy(e),pr.x=Math.min(e.x,t.x),pr.y=Math.max(e.y,t.y),t.x=Math.max(e.x,t.x),t.y=Math.min(e.y,t.y),rn.setFromMatrixPosition(this.camera.matrixWorld),Nn.copy(pr),vn.set(t.x,pr.y,0),In.copy(t),$n.set(pr.x,t.y,0),Nn.unproject(this.camera),vn.unproject(this.camera),In.unproject(this.camera),$n.unproject(this.camera),mi.copy(Nn).sub(rn),gi.copy(vn).sub(rn),_i.copy(In).sub(rn),mi.normalize(),gi.normalize(),_i.normalize(),mi.multiplyScalar(this.deep),gi.multiplyScalar(this.deep),_i.multiplyScalar(this.deep),mi.add(rn),gi.add(rn),_i.add(rn);var s=Wc.planes;s[0].setFromCoplanarPoints(rn,Nn,vn),s[1].setFromCoplanarPoints(rn,vn,In),s[2].setFromCoplanarPoints(In,$n,rn),s[3].setFromCoplanarPoints($n,Nn,rn),s[4].setFromCoplanarPoints(vn,In,$n),s[5].setFromCoplanarPoints(_i,gi,mi),s[5].normal.multiplyScalar(-1)}else if(this.camera.isOrthographicCamera){const r=Math.min(e.x,t.x),i=Math.max(e.y,t.y),o=Math.max(e.x,t.x),a=Math.min(e.y,t.y);Nn.set(r,i,-1),vn.set(o,i,-1),In.set(o,a,-1),$n.set(r,a,-1),di.set(r,i,1),fi.set(o,i,1),pi.set(o,a,1),Bo.set(r,a,1),Nn.unproject(this.camera),vn.unproject(this.camera),In.unproject(this.camera),$n.unproject(this.camera),di.unproject(this.camera),fi.unproject(this.camera),pi.unproject(this.camera),Bo.unproject(this.camera);var s=Wc.planes;s[0].setFromCoplanarPoints(Nn,di,fi),s[1].setFromCoplanarPoints(vn,fi,pi),s[2].setFromCoplanarPoints(pi,Bo,$n),s[3].setFromCoplanarPoints(Bo,di,Nn),s[4].setFromCoplanarPoints(vn,In,$n),s[5].setFromCoplanarPoints(pi,fi,di),s[5].normal.multiplyScalar(-1)}else console.error("THREE.SelectionBox: Unsupported camera type.")}searchChildInFrustum(e,t){if((t.isMesh||t.isLine||t.isPoints)&&t.material!==void 0&&(t.geometry.boundingSphere===null&&t.geometry.computeBoundingSphere(),qc.copy(t.geometry.boundingSphere.center),qc.applyMatrix4(t.matrixWorld),e.containsPoint(qc)&&this.collection.push(t)),t.children.length>0)for(let s=0;s0?X.copy(O[O.length-1]):X.identity())}function r(F){const z=new Ms,A=new Te,I=new Te,Y=new Te;let $=!0,q=!1;const re=F.getAttribute("d").match(/[a-df-z][^a-df-z]*/gi);for(let oe=0,ne=re.length;oe0&&(A.copy(Y),z.currentPath.currentPoint.copy(A),$=!0);break;default:console.warn(_e)}q=!1}return z}function i(F){if(!(!F.sheet||!F.sheet.cssRules||!F.sheet.cssRules.length))for(let z=0;zY.trim());for(let Y=0;Y1){const as=Math.sqrt(Q);z=as*z,A=as*A,te=z*z,H=A*A}const se=te*D+H*M,le=(te*H-se)/se;let be=Math.sqrt(Math.max(0,le));Y===$&&(be=-be);const et=be*z*_e/A,ee=-be*A*ne/z,fe=Math.cos(I)*et-Math.sin(I)*ee+(q.x+ae.x)/2,tt=Math.sin(I)*et+Math.cos(I)*ee+(q.y+ae.y)/2,at=a(1,0,(ne-et)/z,(_e-ee)/A),Ft=a((ne-et)/z,(_e-ee)/A,(-ne-et)/z,(-_e-ee)/A)%(Math.PI*2);F.currentPath.absellipse(fe,tt,z,A,at,at+Ft,$===0,I)}function a(F,z,A,I){const Y=F*A+z*I,$=Math.sqrt(F*F+z*z)*Math.sqrt(A*A+I*I);let q=Math.acos(Math.max(-1,Math.min(1,Y/$)));return F*I-z*A<0&&(q=-q),q}function c(F){const z=w(F.getAttribute("x")||0),A=w(F.getAttribute("y")||0),I=w(F.getAttribute("rx")||F.getAttribute("ry")||0),Y=w(F.getAttribute("ry")||F.getAttribute("rx")||0),$=w(F.getAttribute("width")),q=w(F.getAttribute("height")),ae=1-.551915024494,re=new Ms;return re.moveTo(z+I,A),re.lineTo(z+$-I,A),(I!==0||Y!==0)&&re.bezierCurveTo(z+$-I*ae,A,z+$,A+Y*ae,z+$,A+Y),re.lineTo(z+$,A+q-Y),(I!==0||Y!==0)&&re.bezierCurveTo(z+$,A+q-Y*ae,z+$-I*ae,A+q,z+$-I,A+q),re.lineTo(z+I,A+q),(I!==0||Y!==0)&&re.bezierCurveTo(z+I*ae,A+q,z,A+q-Y*ae,z,A+q-Y),re.lineTo(z,A+Y),(I!==0||Y!==0)&&re.bezierCurveTo(z,A+Y*ae,z+I*ae,A,z+I,A),re}function l(F){function z($,q,ae){const re=w(q),oe=w(ae);Y===0?I.moveTo(re,oe):I.lineTo(re,oe),Y++}const A=/(-?[\d\.?]+)[,|\s](-?[\d\.?]+)/g,I=new Ms;let Y=0;return F.getAttribute("points").replace(A,z),I.currentPath.autoClose=!0,I}function u(F){function z($,q,ae){const re=w(q),oe=w(ae);Y===0?I.moveTo(re,oe):I.lineTo(re,oe),Y++}const A=/(-?[\d\.?]+)[,|\s](-?[\d\.?]+)/g,I=new Ms;let Y=0;return F.getAttribute("points").replace(A,z),I.currentPath.autoClose=!1,I}function h(F){const z=w(F.getAttribute("cx")||0),A=w(F.getAttribute("cy")||0),I=w(F.getAttribute("r")||0),Y=new Bc;Y.absarc(z,A,I,0,Math.PI*2);const $=new Ms;return $.subPaths.push(Y),$}function d(F){const z=w(F.getAttribute("cx")||0),A=w(F.getAttribute("cy")||0),I=w(F.getAttribute("rx")||0),Y=w(F.getAttribute("ry")||0),$=new Bc;$.absellipse(z,A,I,Y,0,Math.PI*2);const q=new Ms;return q.subPaths.push($),q}function f(F){const z=w(F.getAttribute("x1")||0),A=w(F.getAttribute("y1")||0),I=w(F.getAttribute("x2")||0),Y=w(F.getAttribute("y2")||0),$=new Ms;return $.moveTo(z,A),$.lineTo(I,Y),$.currentPath.autoClose=!1,$}function m(F,z){z=Object.assign({},z);let A={};if(F.hasAttribute("class")){const q=F.getAttribute("class").split(/\s/).filter(Boolean).map(ae=>ae.trim());for(let ae=0;ae0&&z.premultiply(O[O.length-1]),X.copy(z),O.push(z),z}function y(F){const z=new fr,A=L;if(F.nodeName==="use"&&(F.hasAttribute("x")||F.hasAttribute("y"))){const I=w(F.getAttribute("x")),Y=w(F.getAttribute("y"));z.translate(I,Y)}if(F.hasAttribute("transform")){const I=F.getAttribute("transform").split(")");for(let Y=I.length-1;Y>=0;Y--){const $=I[Y].trim();if($==="")continue;const q=$.indexOf("("),ae=$.length;if(q>0&&q=1){const ne=oe[0];let _e=ne;oe.length>=2&&(_e=oe[1]),A.translate(ne,_e)}break;case"rotate":if(oe.length>=1){let ne=0,_e=0,te=0;ne=-oe[0]*Math.PI/180,oe.length>=3&&(_e=oe[1],te=oe[2]),j.identity().translate(-_e,-te),W.identity().rotate(ne),V.multiplyMatrices(W,j),j.identity().translate(_e,te),A.multiplyMatrices(j,V)}break;case"scale":if(oe.length>=1){const ne=oe[0];let _e=ne;oe.length>=2&&(_e=oe[1]),A.scale(ne,_e)}break;case"skewX":oe.length===1&&A.set(1,Math.tan(oe[0]*Math.PI/180),0,0,1,0,0,0,1);break;case"skewY":oe.length===1&&A.set(1,0,0,Math.tan(oe[0]*Math.PI/180),1,0,0,0,1);break;case"matrix":oe.length===6&&A.set(oe[0],oe[2],oe[4],oe[1],oe[3],oe[5],0,0,1);break}}z.premultiply(A)}}return z}function x(F,z){function A($){B.set($.x,$.y,1).applyMatrix3(z),$.set(B.x,B.y)}const I=E(z),Y=F.subPaths;for(let $=0,q=Y.length;$=1||V<0||V>1)return null;if(O===0&&j===0){for(let U=0;U<2;U++)if(o(U===0?T:w,g,_),r.loc==s.ORIGIN){const B=U===0?T:w;return{x:B.x,y:B.y,t:r.t}}else if(r.loc==s.BETWEEN){const B=+(b+r.t*(y-b)).toPrecision(10),X=+(k+r.t*(C-k)).toPrecision(10);return{x:B,y:X,t:r.t}}return null}else{for(let X=0;X<2;X++)if(o(X===0?T:w,g,_),r.loc==s.ORIGIN){const K=X===0?T:w;return{x:K.x,y:K.y,t:r.t}}const U=+(b+W*(y-b)).toPrecision(10),B=+(k+W*(C-k)).toPrecision(10);return{x:U,y:B,t:W}}}function o(g,_,T){const w=T.x-_.x,b=T.y-_.y,y=g.x-_.x,x=g.y-_.y,E=w*x-y*b;if(g.x===_.x&&g.y===_.y){r.loc=s.ORIGIN,r.t=0;return}if(g.x===T.x&&g.y===T.y){r.loc=s.DESTINATION,r.t=1;return}if(E<-Number.EPSILON){r.loc=s.LEFT;return}if(E>Number.EPSILON){r.loc=s.RIGHT;return}if(w*y<0||b*x<0){r.loc=s.BEHIND;return}if(Math.sqrt(w*w+b*b)R.t<=S.t+Number.EPSILON&&R.t>=S.t-Number.EPSILON)===void 0&&(T.push(S),w.push(new Te(S.x,S.y)))}}return w}function c(g,_,T){const w=new Te;_.getCenter(w);const b=[];return T.forEach(y=>{y.boundingBox.containsPoint(w)&&a(g,y.points).forEach(E=>{b.push({identifier:y.identifier,isCW:y.isCW,point:E})})}),b.sort((y,x)=>y.point.x-x.point.x),b}function l(g,_,T,w,b){(b==null||b==="")&&(b="nonzero");const y=new Te;g.boundingBox.getCenter(y);const x=[new Te(T,y.y),new Te(w,y.y)],E=c(x,g.boundingBox,_);E.sort((L,j)=>L.point.x-j.point.x);const k=[],C=[];E.forEach(L=>{L.identifier===g.identifier?k.push(L):C.push(L)});const S=k[0].point.x,R=[];let O=0;for(;O0&&R[R.length-1]===C[O].identifier?R.pop():R.push(C[O].identifier),O++;if(R.push(g.identifier),b==="evenodd"){const L=R.length%2===0,j=R[R.length-2];return{identifier:g.identifier,isHole:L,for:j}}else if(b==="nonzero"){let L=!0,j=null,W=null;for(let V=0;V{const _=g.getPoints();let T=-999999999,w=999999999,b=-999999999,y=999999999;for(let x=0;x<_.length;x++){const E=_[x];E.y>T&&(T=E.y),E.yb&&(b=E.x),E.x=y&&(h=y-1),{curves:g.curves,points:_,isCW:by.isClockWise(_),identifier:u++,boundingBox:new xy(new Te(y,w),new Te(b,T))}});f=f.filter(g=>g.points.length>1);const m=f.map(g=>l(g,f,h,d,e.userData.style.fillRule)),p=[];return f.forEach(g=>{if(!m[g.identifier].isHole){const T=new Ep;T.curves=g.curves,m.filter(b=>b.isHole&&b.for===g.identifier).forEach(b=>{const y=f[b.identifier],x=new Bc;x.curves=y.curves,T.holes.push(x)}),p.push(T)}}),p}static getStrokeStyle(e,t,s,r,i){return e=e!==void 0?e:1,t=t!==void 0?t:"#000",s=s!==void 0?s:"miter",r=r!==void 0?r:"butt",i=i!==void 0?i:4,{strokeColor:t,strokeWidth:e,strokeLineJoin:s,strokeLineCap:r,strokeMiterLimit:i}}static pointsToStroke(e,t,s,r){const i=[],o=[],a=[];if(Pi.pointsToStrokeWithBuffers(e,t,s,r,i,o,a)===0)return null;const c=new wy;return c.setAttribute("position",new ua(i,3)),c.setAttribute("normal",new ua(o,3)),c.setAttribute("uv",new ua(a,2)),c}static pointsToStrokeWithBuffers(e,t,s,r,i,o,a,c){const l=new Te,u=new Te,h=new Te,d=new Te,f=new Te,m=new Te,p=new Te,g=new Te,_=new Te,T=new Te,w=new Te,b=new Te,y=new Te,x=new Te,E=new Te,k=new Te,C=new Te;s=s!==void 0?s:12,r=r!==void 0?r:.001,c=c!==void 0?c:0,e=_e(e);const S=e.length;if(S<2)return 0;const R=e[0].equals(e[S-1]);let O,L=e[0],j;const W=t.strokeWidth/2,V=1/(S-1);let U=0,B,X,K,J,F=!1,z=0,A=c*3,I=c*2;Y(e[0],e[1],l).multiplyScalar(W),g.copy(e[0]).sub(l),_.copy(e[0]).add(l),T.copy(g),w.copy(_);for(let te=1;te=r&&M.push(te[D]);return M.push(te[te.length-1]),M}}}function E1(n,e){if(Object.is(n,e))return!0;if(typeof n!="object"||n===null||typeof e!="object"||e===null)return!1;const t=Object.keys(n);if(t.length!==Object.keys(e).length)return!1;for(let s=0;sc,...a}){const{setEvents:c,camera:l,raycaster:u,gl:h,controls:d,size:f,get:m}=Ye(),[p,g]=v.useState(!1),[_,T]=v.useReducer((x,{object:E,shift:k})=>E===void 0?[]:Array.isArray(E)?E:k?x.includes(E)?x.filter(C=>C!==E):[E,...x]:x[0]===E?[]:[E],[]);v.useEffect(()=>void(s==null?void 0:s(_)),[_]);const w=v.useCallback(x=>{x.stopPropagation(),T({object:o([x.object])[0],shift:e&&x.shiftKey})},[]),b=v.useCallback(x=>!p&&T({}),[p]),y=v.useRef(null);return v.useEffect(()=>{if(!n||!e)return;const x=new T1(l,y.current),E=document.createElement("div");E.style.pointerEvents="none",E.style.border=r,E.style.backgroundColor=i,E.style.position="fixed";const k=new Te,C=new Te,S=new Te,R=m().events.enabled,O=d==null?void 0:d.enabled;let L=!1;function j(F,z){const{offsetX:A,offsetY:I}=F,{width:Y,height:$}=f;z.set(A/Y*2-1,-(I/$)*2+1)}function W(F){var z;d&&(d.enabled=!1),c({enabled:!1}),L=!0,(z=h.domElement.parentElement)==null||z.appendChild(E),E.style.left=`${F.clientX}px`,E.style.top=`${F.clientY}px`,E.style.width="0px",E.style.height="0px",k.x=F.clientX,k.y=F.clientY}function V(F){S.x=Math.max(k.x,F.clientX),S.y=Math.max(k.y,F.clientY),C.x=Math.min(k.x,F.clientX),C.y=Math.min(k.y,F.clientY),E.style.left=`${C.x}px`,E.style.top=`${C.y}px`,E.style.width=`${S.x-C.x}px`,E.style.height=`${S.y-C.y}px`}function U(){if(L){var F;d&&(d.enabled=O),c({enabled:R}),L=!1,(F=E.parentElement)==null||F.removeChild(E)}}function B(F){F.shiftKey&&(W(F),j(F,x.startPoint))}let X=[];function K(F){if(L){V(F),j(F,x.endPoint);const z=x.select().sort(A=>A.uuid).filter(A=>A.isMesh);E1(z,X)||(X=z,T({object:o(z)}))}}function J(F){L&&U()}return document.addEventListener("pointerdown",B,{passive:!0}),document.addEventListener("pointermove",K,{passive:!0,capture:!0}),document.addEventListener("pointerup",J,{passive:!0}),()=>{document.removeEventListener("pointerdown",B),document.removeEventListener("pointermove",K),document.removeEventListener("pointerup",J)}},[f.width,f.height,u,l,d,h]),v.createElement("group",Se({ref:y,onClick:w,onPointerOver:()=>g(!0),onPointerOut:()=>g(!1),onPointerMissed:b},a),v.createElement(C1.Provider,{value:_},t))}const Au=v.forwardRef(function({follow:e=!0,lockX:t=!1,lockY:s=!1,lockZ:r=!1,...i},o){const a=v.useRef();return Ht(({camera:c})=>{if(!e||!a.current)return;const l=a.current.rotation.clone();c.getWorldQuaternion(a.current.quaternion),t&&(a.current.rotation.x=l.x),s&&(a.current.rotation.y=l.y),r&&(a.current.rotation.z=l.z)}),v.createElement("group",Se({ref:lc([a,o])},i))}),sd=n=>n===Object(n)&&!Array.isArray(n)&&typeof n!="function";function Bs(n,e){const t=Ye(r=>r.gl),s=uc(dc,sd(n)?Object.values(n):n);if(v.useLayoutEffect(()=>{e==null||e(s)},[e]),v.useEffect(()=>{(Array.isArray(s)?s:[s]).forEach(t.initTexture)},[t,s]),sd(n)){const r=Object.keys(n),i={};return r.forEach(o=>Object.assign(i,{[o]:s[r.indexOf(o)]})),i}else return s}Bs.preload=n=>uc.preload(dc,n);Bs.clear=n=>uc.clear(dc,n);const O1=v.forwardRef(function({src:e,skipFill:t,skipStrokes:s,fillMaterial:r,strokeMaterial:i,fillMeshProps:o,strokeMeshProps:a,...c},l){const u=uc(Pi,e.startsWith("s?[]:u.paths.map(d=>{var f;return((f=d.userData)==null?void 0:f.style.stroke)===void 0||d.userData.style.stroke==="none"?null:d.subPaths.map(m=>Pi.pointsToStroke(m.getPoints(),d.userData.style))}),[u,s]);return v.useEffect(()=>()=>h.forEach(d=>d&&d.map(f=>f.dispose())),[h]),v.createElement("object3D",Se({ref:l},c),v.createElement("object3D",{scale:[1,-1,1]},u.paths.map((d,f)=>{var m,p;return v.createElement(v.Fragment,{key:f},!t&&((m=d.userData)==null?void 0:m.style.fill)!==void 0&&d.userData.style.fill!=="none"&&Pi.createShapes(d).map((g,_)=>v.createElement("mesh",Se({key:_},o),v.createElement("shapeGeometry",{args:[g]}),v.createElement("meshBasicMaterial",Se({color:d.userData.style.fill,opacity:d.userData.style.fillOpacity,transparent:!0,side:ya,depthWrite:!1},r)))),!s&&((p=d.userData)==null?void 0:p.style.stroke)!==void 0&&d.userData.style.stroke!=="none"&&d.subPaths.map((g,_)=>v.createElement("mesh",Se({key:_,geometry:h[f][_]},a),v.createElement("meshBasicMaterial",Se({color:d.userData.style.stroke,opacity:d.userData.style.strokeOpacity,transparent:!0,side:ya,depthWrite:!1},i)))))})))});/*! +import{r as v,a0 as gu,N as Se,j as P,R as mp,a7 as B_,H as N,a8 as W_,c as gp,s as ge,a as ie,F as Me,B as _p,u as Nt,b as _u,k as bo,n as jh,T as yp,d as Hn,a9 as yu,l as q_,e as Er,D as vp,aa as H_,ab as Y_,i as G_,x as Lr,ac as X_,C as Z_,ad as K_,ae as zh}from"./index-4e60c9e2.js";import{u as Ye,a as Ht,m as lc,b as uc,e as vu,L as bu,c as Q_,d as J_,q as ey,f as ty,g as bp,T as xu,h as wu,t as _a,H as xo,P as ny,C as sy,i as ry,j as xp,k as Vh,l as Uh,n as iy}from"./index-c715ffeb.js";import{P as Ee}from"./index-37b3c15b.js";import{k as Bh,H as oy,E as ay,l as ts,f as ze,m as wp,N as Vi,I as hc,n as cy,o as Wh,D as ly,p as uy,R as hy,q as dy,r as kp,P as fy,s as Tp,t as py,O as my}from"./index-af5a3f81.js";import{T as gy}from"./TextareaAutosize-f6242cb8.js";import{D as zo,F as _y,V as ye,L as yy,a as vy,M as fr,b as Te,S as by,B as xy,c as Ep,P as Bc,d as wy,e as ua,f as Ms,T as dc,g as ya,h as ky,i as qh,G as Ty,C as va,j as Ey,k as wo,Q as Cy,l as Cp,W as Sy,m as Oy,n as Ay,E as Ry,o as Dy,p as fc,q as Hh,r as Sp,s as Op}from"./three.module-71ec604c.js";import{T as Py}from"./index-569670a3.js";import{u as My}from"./index-7fe50db2.js";import{C as Ny}from"./ClipLoader-8590c2f1.js";const Iy=["top","right","bottom","left"],vs=Math.min,jt=Math.max,ba=Math.round,Vo=Math.floor,bs=n=>({x:n,y:n}),$y={left:"right",right:"left",bottom:"top",top:"bottom"},Fy={start:"end",end:"start"};function xl(n,e,t){return jt(n,vs(e,t))}function Yn(n,e){return typeof n=="function"?n(e):n}function Gn(n){return n.split("-")[0]}function ei(n){return n.split("-")[1]}function ku(n){return n==="x"?"y":"x"}function Tu(n){return n==="y"?"height":"width"}function ti(n){return["top","bottom"].includes(Gn(n))?"y":"x"}function Eu(n){return ku(ti(n))}function Ly(n,e,t){t===void 0&&(t=!1);const s=ei(n),r=Eu(n),i=Tu(r);let o=r==="x"?s===(t?"end":"start")?"right":"left":s==="start"?"bottom":"top";return e.reference[i]>e.floating[i]&&(o=xa(o)),[o,xa(o)]}function jy(n){const e=xa(n);return[wl(n),e,wl(e)]}function wl(n){return n.replace(/start|end/g,e=>Fy[e])}function zy(n,e,t){const s=["left","right"],r=["right","left"],i=["top","bottom"],o=["bottom","top"];switch(n){case"top":case"bottom":return t?e?r:s:e?s:r;case"left":case"right":return e?i:o;default:return[]}}function Vy(n,e,t,s){const r=ei(n);let i=zy(Gn(n),t==="start",s);return r&&(i=i.map(o=>o+"-"+r),e&&(i=i.concat(i.map(wl)))),i}function xa(n){return n.replace(/left|right|bottom|top/g,e=>$y[e])}function Uy(n){return{top:0,right:0,bottom:0,left:0,...n}}function Ap(n){return typeof n!="number"?Uy(n):{top:n,right:n,bottom:n,left:n}}function wa(n){return{...n,top:n.y,left:n.x,right:n.x+n.width,bottom:n.y+n.height}}function Yh(n,e,t){let{reference:s,floating:r}=n;const i=ti(e),o=Eu(e),a=Tu(o),c=Gn(e),l=i==="y",u=s.x+s.width/2-r.width/2,h=s.y+s.height/2-r.height/2,d=s[a]/2-r[a]/2;let f;switch(c){case"top":f={x:u,y:s.y-r.height};break;case"bottom":f={x:u,y:s.y+s.height};break;case"right":f={x:s.x+s.width,y:h};break;case"left":f={x:s.x-r.width,y:h};break;default:f={x:s.x,y:s.y}}switch(ei(e)){case"start":f[o]-=d*(t&&l?-1:1);break;case"end":f[o]+=d*(t&&l?-1:1);break}return f}const By=async(n,e,t)=>{const{placement:s="bottom",strategy:r="absolute",middleware:i=[],platform:o}=t,a=i.filter(Boolean),c=await(o.isRTL==null?void 0:o.isRTL(e));let l=await o.getElementRects({reference:n,floating:e,strategy:r}),{x:u,y:h}=Yh(l,s,c),d=s,f={},m=0;for(let p=0;p({name:"arrow",options:n,async fn(e){const{x:t,y:s,placement:r,rects:i,platform:o,elements:a,middlewareData:c}=e,{element:l,padding:u=0}=Yn(n,e)||{};if(l==null)return{};const h=Ap(u),d={x:t,y:s},f=Eu(r),m=Tu(f),p=await o.getDimensions(l),g=f==="y",_=g?"top":"left",T=g?"bottom":"right",w=g?"clientHeight":"clientWidth",b=i.reference[m]+i.reference[f]-d[f]-i.floating[m],y=d[f]-i.reference[f],x=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l));let E=x?x[w]:0;(!E||!await(o.isElement==null?void 0:o.isElement(x)))&&(E=a.floating[w]||i.floating[m]);const k=b/2-y/2,C=E/2-p[m]/2-1,S=vs(h[_],C),R=vs(h[T],C),O=S,L=E-p[m]-R,j=E/2-p[m]/2+k,W=xl(O,j,L),V=!c.arrow&&ei(r)!=null&&j!=W&&i.reference[m]/2-(jO<=0)){var C,S;const O=(((C=i.flip)==null?void 0:C.index)||0)+1,L=y[O];if(L)return{data:{index:O,overflows:k},reset:{placement:L}};let j=(S=k.filter(W=>W.overflows[0]<=0).sort((W,V)=>W.overflows[1]-V.overflows[1])[0])==null?void 0:S.placement;if(!j)switch(f){case"bestFit":{var R;const W=(R=k.map(V=>[V.placement,V.overflows.filter(U=>U>0).reduce((U,B)=>U+B,0)]).sort((V,U)=>V[1]-U[1])[0])==null?void 0:R[0];W&&(j=W);break}case"initialPlacement":j=a;break}if(r!==j)return{reset:{placement:j}}}return{}}}};function Xh(n,e){return{top:n.top-e.height,right:n.right-e.width,bottom:n.bottom-e.height,left:n.left-e.width}}function Zh(n){return Iy.some(e=>n[e]>=0)}const qy=function(n){return n===void 0&&(n={}),{name:"hide",options:n,async fn(e){const{rects:t}=e,{strategy:s="referenceHidden",...r}=Yn(n,e);switch(s){case"referenceHidden":{const i=await Ui(e,{...r,elementContext:"reference"}),o=Xh(i,t.reference);return{data:{referenceHiddenOffsets:o,referenceHidden:Zh(o)}}}case"escaped":{const i=await Ui(e,{...r,altBoundary:!0}),o=Xh(i,t.floating);return{data:{escapedOffsets:o,escaped:Zh(o)}}}default:return{}}}}};async function Hy(n,e){const{placement:t,platform:s,elements:r}=n,i=await(s.isRTL==null?void 0:s.isRTL(r.floating)),o=Gn(t),a=ei(t),c=ti(t)==="y",l=["left","top"].includes(o)?-1:1,u=i&&c?-1:1,h=Yn(e,n);let{mainAxis:d,crossAxis:f,alignmentAxis:m}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...h};return a&&typeof m=="number"&&(f=a==="end"?m*-1:m),c?{x:f*u,y:d*l}:{x:d*l,y:f*u}}const Yy=function(n){return n===void 0&&(n=0),{name:"offset",options:n,async fn(e){var t,s;const{x:r,y:i,placement:o,middlewareData:a}=e,c=await Hy(e,n);return o===((t=a.offset)==null?void 0:t.placement)&&(s=a.arrow)!=null&&s.alignmentOffset?{}:{x:r+c.x,y:i+c.y,data:{...c,placement:o}}}}},Gy=function(n){return n===void 0&&(n={}),{name:"shift",options:n,async fn(e){const{x:t,y:s,placement:r}=e,{mainAxis:i=!0,crossAxis:o=!1,limiter:a={fn:g=>{let{x:_,y:T}=g;return{x:_,y:T}}},...c}=Yn(n,e),l={x:t,y:s},u=await Ui(e,c),h=ti(Gn(r)),d=ku(h);let f=l[d],m=l[h];if(i){const g=d==="y"?"top":"left",_=d==="y"?"bottom":"right",T=f+u[g],w=f-u[_];f=xl(T,f,w)}if(o){const g=h==="y"?"top":"left",_=h==="y"?"bottom":"right",T=m+u[g],w=m-u[_];m=xl(T,m,w)}const p=a.fn({...e,[d]:f,[h]:m});return{...p,data:{x:p.x-t,y:p.y-s}}}}},Xy=function(n){return n===void 0&&(n={}),{options:n,fn(e){const{x:t,y:s,placement:r,rects:i,middlewareData:o}=e,{offset:a=0,mainAxis:c=!0,crossAxis:l=!0}=Yn(n,e),u={x:t,y:s},h=ti(r),d=ku(h);let f=u[d],m=u[h];const p=Yn(a,e),g=typeof p=="number"?{mainAxis:p,crossAxis:0}:{mainAxis:0,crossAxis:0,...p};if(c){const w=d==="y"?"height":"width",b=i.reference[d]-i.floating[w]+g.mainAxis,y=i.reference[d]+i.reference[w]-g.mainAxis;fy&&(f=y)}if(l){var _,T;const w=d==="y"?"width":"height",b=["top","left"].includes(Gn(r)),y=i.reference[h]-i.floating[w]+(b&&((_=o.offset)==null?void 0:_[h])||0)+(b?0:g.crossAxis),x=i.reference[h]+i.reference[w]+(b?0:((T=o.offset)==null?void 0:T[h])||0)-(b?g.crossAxis:0);mx&&(m=x)}return{[d]:f,[h]:m}}}},Zy=function(n){return n===void 0&&(n={}),{name:"size",options:n,async fn(e){const{placement:t,rects:s,platform:r,elements:i}=e,{apply:o=()=>{},...a}=Yn(n,e),c=await Ui(e,a),l=Gn(t),u=ei(t),h=ti(t)==="y",{width:d,height:f}=s.floating;let m,p;l==="top"||l==="bottom"?(m=l,p=u===(await(r.isRTL==null?void 0:r.isRTL(i.floating))?"start":"end")?"left":"right"):(p=l,m=u==="end"?"top":"bottom");const g=f-c[m],_=d-c[p],T=!e.middlewareData.shift;let w=g,b=_;if(h){const x=d-c.left-c.right;b=u||T?vs(_,x):x}else{const x=f-c.top-c.bottom;w=u||T?vs(g,x):x}if(T&&!u){const x=jt(c.left,0),E=jt(c.right,0),k=jt(c.top,0),C=jt(c.bottom,0);h?b=d-2*(x!==0||E!==0?x+E:jt(c.left,c.right)):w=f-2*(k!==0||C!==0?k+C:jt(c.top,c.bottom))}await o({...e,availableWidth:b,availableHeight:w});const y=await r.getDimensions(i.floating);return d!==y.width||f!==y.height?{reset:{rects:!0}}:{}}}};function xs(n){return Rp(n)?(n.nodeName||"").toLowerCase():"#document"}function Ut(n){var e;return(n==null||(e=n.ownerDocument)==null?void 0:e.defaultView)||window}function ns(n){var e;return(e=(Rp(n)?n.ownerDocument:n.document)||window.document)==null?void 0:e.documentElement}function Rp(n){return n instanceof Node||n instanceof Ut(n).Node}function Xn(n){return n instanceof Element||n instanceof Ut(n).Element}function Sn(n){return n instanceof HTMLElement||n instanceof Ut(n).HTMLElement}function Kh(n){return typeof ShadowRoot>"u"?!1:n instanceof ShadowRoot||n instanceof Ut(n).ShadowRoot}function ko(n){const{overflow:e,overflowX:t,overflowY:s,display:r}=en(n);return/auto|scroll|overlay|hidden|clip/.test(e+s+t)&&!["inline","contents"].includes(r)}function Ky(n){return["table","td","th"].includes(xs(n))}function Cu(n){const e=Su(),t=en(n);return t.transform!=="none"||t.perspective!=="none"||(t.containerType?t.containerType!=="normal":!1)||!e&&(t.backdropFilter?t.backdropFilter!=="none":!1)||!e&&(t.filter?t.filter!=="none":!1)||["transform","perspective","filter"].some(s=>(t.willChange||"").includes(s))||["paint","layout","strict","content"].some(s=>(t.contain||"").includes(s))}function Qy(n){let e=jr(n);for(;Sn(e)&&!pc(e);){if(Cu(e))return e;e=jr(e)}return null}function Su(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function pc(n){return["html","body","#document"].includes(xs(n))}function en(n){return Ut(n).getComputedStyle(n)}function mc(n){return Xn(n)?{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}:{scrollLeft:n.pageXOffset,scrollTop:n.pageYOffset}}function jr(n){if(xs(n)==="html")return n;const e=n.assignedSlot||n.parentNode||Kh(n)&&n.host||ns(n);return Kh(e)?e.host:e}function Dp(n){const e=jr(n);return pc(e)?n.ownerDocument?n.ownerDocument.body:n.body:Sn(e)&&ko(e)?e:Dp(e)}function Bi(n,e,t){var s;e===void 0&&(e=[]),t===void 0&&(t=!0);const r=Dp(n),i=r===((s=n.ownerDocument)==null?void 0:s.body),o=Ut(r);return i?e.concat(o,o.visualViewport||[],ko(r)?r:[],o.frameElement&&t?Bi(o.frameElement):[]):e.concat(r,Bi(r,[],t))}function Pp(n){const e=en(n);let t=parseFloat(e.width)||0,s=parseFloat(e.height)||0;const r=Sn(n),i=r?n.offsetWidth:t,o=r?n.offsetHeight:s,a=ba(t)!==i||ba(s)!==o;return a&&(t=i,s=o),{width:t,height:s,$:a}}function Ou(n){return Xn(n)?n:n.contextElement}function Dr(n){const e=Ou(n);if(!Sn(e))return bs(1);const t=e.getBoundingClientRect(),{width:s,height:r,$:i}=Pp(e);let o=(i?ba(t.width):t.width)/s,a=(i?ba(t.height):t.height)/r;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const Jy=bs(0);function Mp(n){const e=Ut(n);return!Su()||!e.visualViewport?Jy:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function e1(n,e,t){return e===void 0&&(e=!1),!t||e&&t!==Ut(n)?!1:e}function Qs(n,e,t,s){e===void 0&&(e=!1),t===void 0&&(t=!1);const r=n.getBoundingClientRect(),i=Ou(n);let o=bs(1);e&&(s?Xn(s)&&(o=Dr(s)):o=Dr(n));const a=e1(i,t,s)?Mp(i):bs(0);let c=(r.left+a.x)/o.x,l=(r.top+a.y)/o.y,u=r.width/o.x,h=r.height/o.y;if(i){const d=Ut(i),f=s&&Xn(s)?Ut(s):s;let m=d.frameElement;for(;m&&s&&f!==d;){const p=Dr(m),g=m.getBoundingClientRect(),_=en(m),T=g.left+(m.clientLeft+parseFloat(_.paddingLeft))*p.x,w=g.top+(m.clientTop+parseFloat(_.paddingTop))*p.y;c*=p.x,l*=p.y,u*=p.x,h*=p.y,c+=T,l+=w,m=Ut(m).frameElement}}return wa({width:u,height:h,x:c,y:l})}function t1(n){let{rect:e,offsetParent:t,strategy:s}=n;const r=Sn(t),i=ns(t);if(t===i)return e;let o={scrollLeft:0,scrollTop:0},a=bs(1);const c=bs(0);if((r||!r&&s!=="fixed")&&((xs(t)!=="body"||ko(i))&&(o=mc(t)),Sn(t))){const l=Qs(t);a=Dr(t),c.x=l.x+t.clientLeft,c.y=l.y+t.clientTop}return{width:e.width*a.x,height:e.height*a.y,x:e.x*a.x-o.scrollLeft*a.x+c.x,y:e.y*a.y-o.scrollTop*a.y+c.y}}function n1(n){return Array.from(n.getClientRects())}function Np(n){return Qs(ns(n)).left+mc(n).scrollLeft}function s1(n){const e=ns(n),t=mc(n),s=n.ownerDocument.body,r=jt(e.scrollWidth,e.clientWidth,s.scrollWidth,s.clientWidth),i=jt(e.scrollHeight,e.clientHeight,s.scrollHeight,s.clientHeight);let o=-t.scrollLeft+Np(n);const a=-t.scrollTop;return en(s).direction==="rtl"&&(o+=jt(e.clientWidth,s.clientWidth)-r),{width:r,height:i,x:o,y:a}}function r1(n,e){const t=Ut(n),s=ns(n),r=t.visualViewport;let i=s.clientWidth,o=s.clientHeight,a=0,c=0;if(r){i=r.width,o=r.height;const l=Su();(!l||l&&e==="fixed")&&(a=r.offsetLeft,c=r.offsetTop)}return{width:i,height:o,x:a,y:c}}function i1(n,e){const t=Qs(n,!0,e==="fixed"),s=t.top+n.clientTop,r=t.left+n.clientLeft,i=Sn(n)?Dr(n):bs(1),o=n.clientWidth*i.x,a=n.clientHeight*i.y,c=r*i.x,l=s*i.y;return{width:o,height:a,x:c,y:l}}function Qh(n,e,t){let s;if(e==="viewport")s=r1(n,t);else if(e==="document")s=s1(ns(n));else if(Xn(e))s=i1(e,t);else{const r=Mp(n);s={...e,x:e.x-r.x,y:e.y-r.y}}return wa(s)}function Ip(n,e){const t=jr(n);return t===e||!Xn(t)||pc(t)?!1:en(t).position==="fixed"||Ip(t,e)}function o1(n,e){const t=e.get(n);if(t)return t;let s=Bi(n,[],!1).filter(a=>Xn(a)&&xs(a)!=="body"),r=null;const i=en(n).position==="fixed";let o=i?jr(n):n;for(;Xn(o)&&!pc(o);){const a=en(o),c=Cu(o);!c&&a.position==="fixed"&&(r=null),(i?!c&&!r:!c&&a.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||ko(o)&&!c&&Ip(n,o))?s=s.filter(u=>u!==o):r=a,o=jr(o)}return e.set(n,s),s}function a1(n){let{element:e,boundary:t,rootBoundary:s,strategy:r}=n;const o=[...t==="clippingAncestors"?o1(e,this._c):[].concat(t),s],a=o[0],c=o.reduce((l,u)=>{const h=Qh(e,u,r);return l.top=jt(h.top,l.top),l.right=vs(h.right,l.right),l.bottom=vs(h.bottom,l.bottom),l.left=jt(h.left,l.left),l},Qh(e,a,r));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function c1(n){return Pp(n)}function l1(n,e,t){const s=Sn(e),r=ns(e),i=t==="fixed",o=Qs(n,!0,i,e);let a={scrollLeft:0,scrollTop:0};const c=bs(0);if(s||!s&&!i)if((xs(e)!=="body"||ko(r))&&(a=mc(e)),s){const l=Qs(e,!0,i,e);c.x=l.x+e.clientLeft,c.y=l.y+e.clientTop}else r&&(c.x=Np(r));return{x:o.left+a.scrollLeft-c.x,y:o.top+a.scrollTop-c.y,width:o.width,height:o.height}}function Jh(n,e){return!Sn(n)||en(n).position==="fixed"?null:e?e(n):n.offsetParent}function $p(n,e){const t=Ut(n);if(!Sn(n))return t;let s=Jh(n,e);for(;s&&Ky(s)&&en(s).position==="static";)s=Jh(s,e);return s&&(xs(s)==="html"||xs(s)==="body"&&en(s).position==="static"&&!Cu(s))?t:s||Qy(n)||t}const u1=async function(n){let{reference:e,floating:t,strategy:s}=n;const r=this.getOffsetParent||$p,i=this.getDimensions;return{reference:l1(e,await r(t),s),floating:{x:0,y:0,...await i(t)}}};function h1(n){return en(n).direction==="rtl"}const d1={convertOffsetParentRelativeRectToViewportRelativeRect:t1,getDocumentElement:ns,getClippingRect:a1,getOffsetParent:$p,getElementRects:u1,getClientRects:n1,getDimensions:c1,getScale:Dr,isElement:Xn,isRTL:h1};function f1(n,e){let t=null,s;const r=ns(n);function i(){clearTimeout(s),t&&t.disconnect(),t=null}function o(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),i();const{left:l,top:u,width:h,height:d}=n.getBoundingClientRect();if(a||e(),!h||!d)return;const f=Vo(u),m=Vo(r.clientWidth-(l+h)),p=Vo(r.clientHeight-(u+d)),g=Vo(l),T={rootMargin:-f+"px "+-m+"px "+-p+"px "+-g+"px",threshold:jt(0,vs(1,c))||1};let w=!0;function b(y){const x=y[0].intersectionRatio;if(x!==c){if(!w)return o();x?o(!1,x):s=setTimeout(()=>{o(!1,1e-7)},100)}w=!1}try{t=new IntersectionObserver(b,{...T,root:r.ownerDocument})}catch{t=new IntersectionObserver(b,T)}t.observe(n)}return o(!0),i}function p1(n,e,t,s){s===void 0&&(s={});const{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=s,l=Ou(n),u=r||i?[...l?Bi(l):[],...Bi(e)]:[];u.forEach(_=>{r&&_.addEventListener("scroll",t,{passive:!0}),i&&_.addEventListener("resize",t)});const h=l&&a?f1(l,t):null;let d=-1,f=null;o&&(f=new ResizeObserver(_=>{let[T]=_;T&&T.target===l&&f&&(f.unobserve(e),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{f&&f.observe(e)})),t()}),l&&!c&&f.observe(l),f.observe(e));let m,p=c?Qs(n):null;c&&g();function g(){const _=Qs(n);p&&(_.x!==p.x||_.y!==p.y||_.width!==p.width||_.height!==p.height)&&t(),p=_,m=requestAnimationFrame(g)}return t(),()=>{u.forEach(_=>{r&&_.removeEventListener("scroll",t),i&&_.removeEventListener("resize",t)}),h&&h(),f&&f.disconnect(),f=null,c&&cancelAnimationFrame(m)}}const m1=(n,e,t)=>{const s=new Map,r={platform:d1,...t},i={...r.platform,_c:s};return By(n,e,{...r,platform:i})},g1=n=>{function e(t){return{}.hasOwnProperty.call(t,"current")}return{name:"arrow",options:n,fn(t){const{element:s,padding:r}=typeof n=="function"?n(t):n;return s&&e(s)?s.current!=null?Gh({element:s.current,padding:r}).fn(t):{}:s?Gh({element:s,padding:r}).fn(t):{}}}};var ha=typeof document<"u"?v.useLayoutEffect:v.useEffect;function ka(n,e){if(n===e)return!0;if(typeof n!=typeof e)return!1;if(typeof n=="function"&&n.toString()===e.toString())return!0;let t,s,r;if(n&&e&&typeof n=="object"){if(Array.isArray(n)){if(t=n.length,t!=e.length)return!1;for(s=t;s--!==0;)if(!ka(n[s],e[s]))return!1;return!0}if(r=Object.keys(n),t=r.length,t!==Object.keys(e).length)return!1;for(s=t;s--!==0;)if(!{}.hasOwnProperty.call(e,r[s]))return!1;for(s=t;s--!==0;){const i=r[s];if(!(i==="_owner"&&n.$$typeof)&&!ka(n[i],e[i]))return!1}return!0}return n!==n&&e!==e}function Fp(n){return typeof window>"u"?1:(n.ownerDocument.defaultView||window).devicePixelRatio||1}function ed(n,e){const t=Fp(n);return Math.round(e*t)/t}function td(n){const e=v.useRef(n);return ha(()=>{e.current=n}),e}function _1(n){n===void 0&&(n={});const{placement:e="bottom",strategy:t="absolute",middleware:s=[],platform:r,elements:{reference:i,floating:o}={},transform:a=!0,whileElementsMounted:c,open:l}=n,[u,h]=v.useState({x:0,y:0,strategy:t,placement:e,middlewareData:{},isPositioned:!1}),[d,f]=v.useState(s);ka(d,s)||f(s);const[m,p]=v.useState(null),[g,_]=v.useState(null),T=v.useCallback(V=>{V!=x.current&&(x.current=V,p(V))},[p]),w=v.useCallback(V=>{V!==E.current&&(E.current=V,_(V))},[_]),b=i||m,y=o||g,x=v.useRef(null),E=v.useRef(null),k=v.useRef(u),C=td(c),S=td(r),R=v.useCallback(()=>{if(!x.current||!E.current)return;const V={placement:e,strategy:t,middleware:d};S.current&&(V.platform=S.current),m1(x.current,E.current,V).then(U=>{const B={...U,isPositioned:!0};O.current&&!ka(k.current,B)&&(k.current=B,gu.flushSync(()=>{h(B)}))})},[d,e,t,S]);ha(()=>{l===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,h(V=>({...V,isPositioned:!1})))},[l]);const O=v.useRef(!1);ha(()=>(O.current=!0,()=>{O.current=!1}),[]),ha(()=>{if(b&&(x.current=b),y&&(E.current=y),b&&y){if(C.current)return C.current(b,y,R);R()}},[b,y,R,C]);const L=v.useMemo(()=>({reference:x,floating:E,setReference:T,setFloating:w}),[T,w]),j=v.useMemo(()=>({reference:b,floating:y}),[b,y]),W=v.useMemo(()=>{const V={position:t,left:0,top:0};if(!j.floating)return V;const U=ed(j.floating,u.x),B=ed(j.floating,u.y);return a?{...V,transform:"translate("+U+"px, "+B+"px)",...Fp(j.floating)>=1.5&&{willChange:"transform"}}:{position:t,left:U,top:B}},[t,a,j.floating,u.x,u.y]);return v.useMemo(()=>({...u,update:R,refs:L,elements:j,floatingStyles:W}),[u,R,L,j,W])}function y1(n){let e;const t=new Set,s=(l,u)=>{const h=typeof l=="function"?l(e):l;if(h!==e){const d=e;e=u?h:Object.assign({},e,h),t.forEach(f=>f(e,d))}},r=()=>e,i=(l,u=r,h=Object.is)=>{console.warn("[DEPRECATED] Please use `subscribeWithSelector` middleware");let d=u(e);function f(){const m=u(e);if(!h(d,m)){const p=d;l(d=m,p)}}return t.add(f),()=>t.delete(f)},c={setState:s,getState:r,subscribe:(l,u,h)=>u||h?i(l,u,h):(t.add(l),()=>t.delete(l)),destroy:()=>t.clear()};return e=n(s,r,c),c}const v1=typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),nd=v1?v.useEffect:v.useLayoutEffect;function b1(n){const e=typeof n=="function"?y1(n):n,t=(s=e.getState,r=Object.is)=>{const[,i]=v.useReducer(g=>g+1,0),o=e.getState(),a=v.useRef(o),c=v.useRef(s),l=v.useRef(r),u=v.useRef(!1),h=v.useRef();h.current===void 0&&(h.current=s(o));let d,f=!1;(a.current!==o||c.current!==s||l.current!==r||u.current)&&(d=s(o),f=!r(h.current,d)),nd(()=>{f&&(h.current=d),a.current=o,c.current=s,l.current=r,u.current=!1});const m=v.useRef(o);nd(()=>{const g=()=>{try{const T=e.getState(),w=c.current(T);l.current(h.current,w)||(a.current=T,h.current=w,i())}catch{u.current=!0,i()}},_=e.subscribe(g);return e.getState()!==m.current&&g(),_},[]);const p=f?d:h.current;return v.useDebugValue(p),p};return Object.assign(t,e),t[Symbol.iterator]=function(){console.warn("[useStore, api] = create() is deprecated and will be removed in v4");const s=[t,e];return{next(){const r=s.length<=0;return{value:s.shift(),done:r}}}},t}let hi=0;const x1=b1(n=>(zo.onStart=(e,t,s)=>{n({active:!0,item:e,loaded:t,total:s,progress:(t-hi)/(s-hi)*100})},zo.onLoad=()=>{n({active:!1})},zo.onError=e=>n(t=>({errors:[...t.errors,e]})),zo.onProgress=(e,t,s)=>{t===s&&(hi=s),n({active:!0,item:e,loaded:t,total:s,progress:(t-hi)/(s-hi)*100||100})},{errors:[],active:!1,progress:0,item:"",loaded:0,total:0})),w1=n=>`Loading ${n.toFixed(2)}%`;function k1({containerStyles:n,innerStyles:e,barStyles:t,dataStyles:s,dataInterpolation:r=w1,initialState:i=o=>o}){const{active:o,progress:a}=x1(),c=v.useRef(0),l=v.useRef(0),u=v.useRef(null),[h,d]=v.useState(i(o));v.useEffect(()=>{let m;return o!==h&&(m=setTimeout(()=>d(o),300)),()=>clearTimeout(m)},[h,o]);const f=v.useCallback(()=>{u.current&&(c.current+=(a-c.current)/2,(c.current>.95*a||a===100)&&(c.current=a),u.current.innerText=r(c.current),c.current(f(),()=>cancelAnimationFrame(l.current)),[f]),h?v.createElement("div",{style:{...Uo.container,opacity:o?1:0,...n}},v.createElement("div",null,v.createElement("div",{style:{...Uo.inner,...e}},v.createElement("div",{style:{...Uo.bar,transform:`scaleX(${a/100})`,...t}}),v.createElement("span",{ref:u,style:{...Uo.data,...s}})))):null}const Uo={container:{position:"absolute",top:0,left:0,width:"100%",height:"100%",background:"#171717",display:"flex",alignItems:"center",justifyContent:"center",transition:"opacity 300ms ease",zIndex:1e3},inner:{width:100,height:3,background:"#272727",textAlign:"center"},bar:{height:3,width:"100%",background:"white",transition:"transform 200ms",transformOrigin:"left center"},data:{display:"inline-block",position:"relative",fontVariantNumeric:"tabular-nums",marginTop:"0.8em",color:"#f0f0f0",fontSize:"0.6em",fontFamily:'-apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", "Helvetica Neue", Helvetica, Arial, Roboto, Ubuntu, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',whiteSpace:"nowrap"}},Wc=new _y,qc=new ye,pr=new ye,rn=new ye,Nn=new ye,vn=new ye,In=new ye,$n=new ye,di=new ye,fi=new ye,pi=new ye,Bo=new ye,mi=new ye,gi=new ye,_i=new ye;class T1{constructor(e,t,s){this.camera=e,this.scene=t,this.startPoint=new ye,this.endPoint=new ye,this.collection=[],this.deep=s||Number.MAX_VALUE}select(e,t){return this.startPoint=e||this.startPoint,this.endPoint=t||this.endPoint,this.collection=[],this.updateFrustum(this.startPoint,this.endPoint),this.searchChildInFrustum(Wc,this.scene),this.collection}updateFrustum(e,t){if(e=e||this.startPoint,t=t||this.endPoint,e.x===t.x&&(t.x+=Number.EPSILON),e.y===t.y&&(t.y+=Number.EPSILON),this.camera.updateProjectionMatrix(),this.camera.updateMatrixWorld(),this.camera.isPerspectiveCamera){pr.copy(e),pr.x=Math.min(e.x,t.x),pr.y=Math.max(e.y,t.y),t.x=Math.max(e.x,t.x),t.y=Math.min(e.y,t.y),rn.setFromMatrixPosition(this.camera.matrixWorld),Nn.copy(pr),vn.set(t.x,pr.y,0),In.copy(t),$n.set(pr.x,t.y,0),Nn.unproject(this.camera),vn.unproject(this.camera),In.unproject(this.camera),$n.unproject(this.camera),mi.copy(Nn).sub(rn),gi.copy(vn).sub(rn),_i.copy(In).sub(rn),mi.normalize(),gi.normalize(),_i.normalize(),mi.multiplyScalar(this.deep),gi.multiplyScalar(this.deep),_i.multiplyScalar(this.deep),mi.add(rn),gi.add(rn),_i.add(rn);var s=Wc.planes;s[0].setFromCoplanarPoints(rn,Nn,vn),s[1].setFromCoplanarPoints(rn,vn,In),s[2].setFromCoplanarPoints(In,$n,rn),s[3].setFromCoplanarPoints($n,Nn,rn),s[4].setFromCoplanarPoints(vn,In,$n),s[5].setFromCoplanarPoints(_i,gi,mi),s[5].normal.multiplyScalar(-1)}else if(this.camera.isOrthographicCamera){const r=Math.min(e.x,t.x),i=Math.max(e.y,t.y),o=Math.max(e.x,t.x),a=Math.min(e.y,t.y);Nn.set(r,i,-1),vn.set(o,i,-1),In.set(o,a,-1),$n.set(r,a,-1),di.set(r,i,1),fi.set(o,i,1),pi.set(o,a,1),Bo.set(r,a,1),Nn.unproject(this.camera),vn.unproject(this.camera),In.unproject(this.camera),$n.unproject(this.camera),di.unproject(this.camera),fi.unproject(this.camera),pi.unproject(this.camera),Bo.unproject(this.camera);var s=Wc.planes;s[0].setFromCoplanarPoints(Nn,di,fi),s[1].setFromCoplanarPoints(vn,fi,pi),s[2].setFromCoplanarPoints(pi,Bo,$n),s[3].setFromCoplanarPoints(Bo,di,Nn),s[4].setFromCoplanarPoints(vn,In,$n),s[5].setFromCoplanarPoints(pi,fi,di),s[5].normal.multiplyScalar(-1)}else console.error("THREE.SelectionBox: Unsupported camera type.")}searchChildInFrustum(e,t){if((t.isMesh||t.isLine||t.isPoints)&&t.material!==void 0&&(t.geometry.boundingSphere===null&&t.geometry.computeBoundingSphere(),qc.copy(t.geometry.boundingSphere.center),qc.applyMatrix4(t.matrixWorld),e.containsPoint(qc)&&this.collection.push(t)),t.children.length>0)for(let s=0;s0?X.copy(O[O.length-1]):X.identity())}function r(F){const z=new Ms,A=new Te,I=new Te,Y=new Te;let $=!0,q=!1;const re=F.getAttribute("d").match(/[a-df-z][^a-df-z]*/gi);for(let oe=0,ne=re.length;oe0&&(A.copy(Y),z.currentPath.currentPoint.copy(A),$=!0);break;default:console.warn(_e)}q=!1}return z}function i(F){if(!(!F.sheet||!F.sheet.cssRules||!F.sheet.cssRules.length))for(let z=0;zY.trim());for(let Y=0;Y1){const as=Math.sqrt(Q);z=as*z,A=as*A,te=z*z,H=A*A}const se=te*D+H*M,le=(te*H-se)/se;let be=Math.sqrt(Math.max(0,le));Y===$&&(be=-be);const et=be*z*_e/A,ee=-be*A*ne/z,fe=Math.cos(I)*et-Math.sin(I)*ee+(q.x+ae.x)/2,tt=Math.sin(I)*et+Math.cos(I)*ee+(q.y+ae.y)/2,at=a(1,0,(ne-et)/z,(_e-ee)/A),Ft=a((ne-et)/z,(_e-ee)/A,(-ne-et)/z,(-_e-ee)/A)%(Math.PI*2);F.currentPath.absellipse(fe,tt,z,A,at,at+Ft,$===0,I)}function a(F,z,A,I){const Y=F*A+z*I,$=Math.sqrt(F*F+z*z)*Math.sqrt(A*A+I*I);let q=Math.acos(Math.max(-1,Math.min(1,Y/$)));return F*I-z*A<0&&(q=-q),q}function c(F){const z=w(F.getAttribute("x")||0),A=w(F.getAttribute("y")||0),I=w(F.getAttribute("rx")||F.getAttribute("ry")||0),Y=w(F.getAttribute("ry")||F.getAttribute("rx")||0),$=w(F.getAttribute("width")),q=w(F.getAttribute("height")),ae=1-.551915024494,re=new Ms;return re.moveTo(z+I,A),re.lineTo(z+$-I,A),(I!==0||Y!==0)&&re.bezierCurveTo(z+$-I*ae,A,z+$,A+Y*ae,z+$,A+Y),re.lineTo(z+$,A+q-Y),(I!==0||Y!==0)&&re.bezierCurveTo(z+$,A+q-Y*ae,z+$-I*ae,A+q,z+$-I,A+q),re.lineTo(z+I,A+q),(I!==0||Y!==0)&&re.bezierCurveTo(z+I*ae,A+q,z,A+q-Y*ae,z,A+q-Y),re.lineTo(z,A+Y),(I!==0||Y!==0)&&re.bezierCurveTo(z,A+Y*ae,z+I*ae,A,z+I,A),re}function l(F){function z($,q,ae){const re=w(q),oe=w(ae);Y===0?I.moveTo(re,oe):I.lineTo(re,oe),Y++}const A=/(-?[\d\.?]+)[,|\s](-?[\d\.?]+)/g,I=new Ms;let Y=0;return F.getAttribute("points").replace(A,z),I.currentPath.autoClose=!0,I}function u(F){function z($,q,ae){const re=w(q),oe=w(ae);Y===0?I.moveTo(re,oe):I.lineTo(re,oe),Y++}const A=/(-?[\d\.?]+)[,|\s](-?[\d\.?]+)/g,I=new Ms;let Y=0;return F.getAttribute("points").replace(A,z),I.currentPath.autoClose=!1,I}function h(F){const z=w(F.getAttribute("cx")||0),A=w(F.getAttribute("cy")||0),I=w(F.getAttribute("r")||0),Y=new Bc;Y.absarc(z,A,I,0,Math.PI*2);const $=new Ms;return $.subPaths.push(Y),$}function d(F){const z=w(F.getAttribute("cx")||0),A=w(F.getAttribute("cy")||0),I=w(F.getAttribute("rx")||0),Y=w(F.getAttribute("ry")||0),$=new Bc;$.absellipse(z,A,I,Y,0,Math.PI*2);const q=new Ms;return q.subPaths.push($),q}function f(F){const z=w(F.getAttribute("x1")||0),A=w(F.getAttribute("y1")||0),I=w(F.getAttribute("x2")||0),Y=w(F.getAttribute("y2")||0),$=new Ms;return $.moveTo(z,A),$.lineTo(I,Y),$.currentPath.autoClose=!1,$}function m(F,z){z=Object.assign({},z);let A={};if(F.hasAttribute("class")){const q=F.getAttribute("class").split(/\s/).filter(Boolean).map(ae=>ae.trim());for(let ae=0;ae0&&z.premultiply(O[O.length-1]),X.copy(z),O.push(z),z}function y(F){const z=new fr,A=L;if(F.nodeName==="use"&&(F.hasAttribute("x")||F.hasAttribute("y"))){const I=w(F.getAttribute("x")),Y=w(F.getAttribute("y"));z.translate(I,Y)}if(F.hasAttribute("transform")){const I=F.getAttribute("transform").split(")");for(let Y=I.length-1;Y>=0;Y--){const $=I[Y].trim();if($==="")continue;const q=$.indexOf("("),ae=$.length;if(q>0&&q=1){const ne=oe[0];let _e=ne;oe.length>=2&&(_e=oe[1]),A.translate(ne,_e)}break;case"rotate":if(oe.length>=1){let ne=0,_e=0,te=0;ne=-oe[0]*Math.PI/180,oe.length>=3&&(_e=oe[1],te=oe[2]),j.identity().translate(-_e,-te),W.identity().rotate(ne),V.multiplyMatrices(W,j),j.identity().translate(_e,te),A.multiplyMatrices(j,V)}break;case"scale":if(oe.length>=1){const ne=oe[0];let _e=ne;oe.length>=2&&(_e=oe[1]),A.scale(ne,_e)}break;case"skewX":oe.length===1&&A.set(1,Math.tan(oe[0]*Math.PI/180),0,0,1,0,0,0,1);break;case"skewY":oe.length===1&&A.set(1,0,0,Math.tan(oe[0]*Math.PI/180),1,0,0,0,1);break;case"matrix":oe.length===6&&A.set(oe[0],oe[2],oe[4],oe[1],oe[3],oe[5],0,0,1);break}}z.premultiply(A)}}return z}function x(F,z){function A($){B.set($.x,$.y,1).applyMatrix3(z),$.set(B.x,B.y)}const I=E(z),Y=F.subPaths;for(let $=0,q=Y.length;$=1||V<0||V>1)return null;if(O===0&&j===0){for(let U=0;U<2;U++)if(o(U===0?T:w,g,_),r.loc==s.ORIGIN){const B=U===0?T:w;return{x:B.x,y:B.y,t:r.t}}else if(r.loc==s.BETWEEN){const B=+(b+r.t*(y-b)).toPrecision(10),X=+(k+r.t*(C-k)).toPrecision(10);return{x:B,y:X,t:r.t}}return null}else{for(let X=0;X<2;X++)if(o(X===0?T:w,g,_),r.loc==s.ORIGIN){const K=X===0?T:w;return{x:K.x,y:K.y,t:r.t}}const U=+(b+W*(y-b)).toPrecision(10),B=+(k+W*(C-k)).toPrecision(10);return{x:U,y:B,t:W}}}function o(g,_,T){const w=T.x-_.x,b=T.y-_.y,y=g.x-_.x,x=g.y-_.y,E=w*x-y*b;if(g.x===_.x&&g.y===_.y){r.loc=s.ORIGIN,r.t=0;return}if(g.x===T.x&&g.y===T.y){r.loc=s.DESTINATION,r.t=1;return}if(E<-Number.EPSILON){r.loc=s.LEFT;return}if(E>Number.EPSILON){r.loc=s.RIGHT;return}if(w*y<0||b*x<0){r.loc=s.BEHIND;return}if(Math.sqrt(w*w+b*b)R.t<=S.t+Number.EPSILON&&R.t>=S.t-Number.EPSILON)===void 0&&(T.push(S),w.push(new Te(S.x,S.y)))}}return w}function c(g,_,T){const w=new Te;_.getCenter(w);const b=[];return T.forEach(y=>{y.boundingBox.containsPoint(w)&&a(g,y.points).forEach(E=>{b.push({identifier:y.identifier,isCW:y.isCW,point:E})})}),b.sort((y,x)=>y.point.x-x.point.x),b}function l(g,_,T,w,b){(b==null||b==="")&&(b="nonzero");const y=new Te;g.boundingBox.getCenter(y);const x=[new Te(T,y.y),new Te(w,y.y)],E=c(x,g.boundingBox,_);E.sort((L,j)=>L.point.x-j.point.x);const k=[],C=[];E.forEach(L=>{L.identifier===g.identifier?k.push(L):C.push(L)});const S=k[0].point.x,R=[];let O=0;for(;O0&&R[R.length-1]===C[O].identifier?R.pop():R.push(C[O].identifier),O++;if(R.push(g.identifier),b==="evenodd"){const L=R.length%2===0,j=R[R.length-2];return{identifier:g.identifier,isHole:L,for:j}}else if(b==="nonzero"){let L=!0,j=null,W=null;for(let V=0;V{const _=g.getPoints();let T=-999999999,w=999999999,b=-999999999,y=999999999;for(let x=0;x<_.length;x++){const E=_[x];E.y>T&&(T=E.y),E.yb&&(b=E.x),E.x=y&&(h=y-1),{curves:g.curves,points:_,isCW:by.isClockWise(_),identifier:u++,boundingBox:new xy(new Te(y,w),new Te(b,T))}});f=f.filter(g=>g.points.length>1);const m=f.map(g=>l(g,f,h,d,e.userData.style.fillRule)),p=[];return f.forEach(g=>{if(!m[g.identifier].isHole){const T=new Ep;T.curves=g.curves,m.filter(b=>b.isHole&&b.for===g.identifier).forEach(b=>{const y=f[b.identifier],x=new Bc;x.curves=y.curves,T.holes.push(x)}),p.push(T)}}),p}static getStrokeStyle(e,t,s,r,i){return e=e!==void 0?e:1,t=t!==void 0?t:"#000",s=s!==void 0?s:"miter",r=r!==void 0?r:"butt",i=i!==void 0?i:4,{strokeColor:t,strokeWidth:e,strokeLineJoin:s,strokeLineCap:r,strokeMiterLimit:i}}static pointsToStroke(e,t,s,r){const i=[],o=[],a=[];if(Pi.pointsToStrokeWithBuffers(e,t,s,r,i,o,a)===0)return null;const c=new wy;return c.setAttribute("position",new ua(i,3)),c.setAttribute("normal",new ua(o,3)),c.setAttribute("uv",new ua(a,2)),c}static pointsToStrokeWithBuffers(e,t,s,r,i,o,a,c){const l=new Te,u=new Te,h=new Te,d=new Te,f=new Te,m=new Te,p=new Te,g=new Te,_=new Te,T=new Te,w=new Te,b=new Te,y=new Te,x=new Te,E=new Te,k=new Te,C=new Te;s=s!==void 0?s:12,r=r!==void 0?r:.001,c=c!==void 0?c:0,e=_e(e);const S=e.length;if(S<2)return 0;const R=e[0].equals(e[S-1]);let O,L=e[0],j;const W=t.strokeWidth/2,V=1/(S-1);let U=0,B,X,K,J,F=!1,z=0,A=c*3,I=c*2;Y(e[0],e[1],l).multiplyScalar(W),g.copy(e[0]).sub(l),_.copy(e[0]).add(l),T.copy(g),w.copy(_);for(let te=1;te=r&&M.push(te[D]);return M.push(te[te.length-1]),M}}}function E1(n,e){if(Object.is(n,e))return!0;if(typeof n!="object"||n===null||typeof e!="object"||e===null)return!1;const t=Object.keys(n);if(t.length!==Object.keys(e).length)return!1;for(let s=0;sc,...a}){const{setEvents:c,camera:l,raycaster:u,gl:h,controls:d,size:f,get:m}=Ye(),[p,g]=v.useState(!1),[_,T]=v.useReducer((x,{object:E,shift:k})=>E===void 0?[]:Array.isArray(E)?E:k?x.includes(E)?x.filter(C=>C!==E):[E,...x]:x[0]===E?[]:[E],[]);v.useEffect(()=>void(s==null?void 0:s(_)),[_]);const w=v.useCallback(x=>{x.stopPropagation(),T({object:o([x.object])[0],shift:e&&x.shiftKey})},[]),b=v.useCallback(x=>!p&&T({}),[p]),y=v.useRef(null);return v.useEffect(()=>{if(!n||!e)return;const x=new T1(l,y.current),E=document.createElement("div");E.style.pointerEvents="none",E.style.border=r,E.style.backgroundColor=i,E.style.position="fixed";const k=new Te,C=new Te,S=new Te,R=m().events.enabled,O=d==null?void 0:d.enabled;let L=!1;function j(F,z){const{offsetX:A,offsetY:I}=F,{width:Y,height:$}=f;z.set(A/Y*2-1,-(I/$)*2+1)}function W(F){var z;d&&(d.enabled=!1),c({enabled:!1}),L=!0,(z=h.domElement.parentElement)==null||z.appendChild(E),E.style.left=`${F.clientX}px`,E.style.top=`${F.clientY}px`,E.style.width="0px",E.style.height="0px",k.x=F.clientX,k.y=F.clientY}function V(F){S.x=Math.max(k.x,F.clientX),S.y=Math.max(k.y,F.clientY),C.x=Math.min(k.x,F.clientX),C.y=Math.min(k.y,F.clientY),E.style.left=`${C.x}px`,E.style.top=`${C.y}px`,E.style.width=`${S.x-C.x}px`,E.style.height=`${S.y-C.y}px`}function U(){if(L){var F;d&&(d.enabled=O),c({enabled:R}),L=!1,(F=E.parentElement)==null||F.removeChild(E)}}function B(F){F.shiftKey&&(W(F),j(F,x.startPoint))}let X=[];function K(F){if(L){V(F),j(F,x.endPoint);const z=x.select().sort(A=>A.uuid).filter(A=>A.isMesh);E1(z,X)||(X=z,T({object:o(z)}))}}function J(F){L&&U()}return document.addEventListener("pointerdown",B,{passive:!0}),document.addEventListener("pointermove",K,{passive:!0,capture:!0}),document.addEventListener("pointerup",J,{passive:!0}),()=>{document.removeEventListener("pointerdown",B),document.removeEventListener("pointermove",K),document.removeEventListener("pointerup",J)}},[f.width,f.height,u,l,d,h]),v.createElement("group",Se({ref:y,onClick:w,onPointerOver:()=>g(!0),onPointerOut:()=>g(!1),onPointerMissed:b},a),v.createElement(C1.Provider,{value:_},t))}const Au=v.forwardRef(function({follow:e=!0,lockX:t=!1,lockY:s=!1,lockZ:r=!1,...i},o){const a=v.useRef();return Ht(({camera:c})=>{if(!e||!a.current)return;const l=a.current.rotation.clone();c.getWorldQuaternion(a.current.quaternion),t&&(a.current.rotation.x=l.x),s&&(a.current.rotation.y=l.y),r&&(a.current.rotation.z=l.z)}),v.createElement("group",Se({ref:lc([a,o])},i))}),sd=n=>n===Object(n)&&!Array.isArray(n)&&typeof n!="function";function Bs(n,e){const t=Ye(r=>r.gl),s=uc(dc,sd(n)?Object.values(n):n);if(v.useLayoutEffect(()=>{e==null||e(s)},[e]),v.useEffect(()=>{(Array.isArray(s)?s:[s]).forEach(t.initTexture)},[t,s]),sd(n)){const r=Object.keys(n),i={};return r.forEach(o=>Object.assign(i,{[o]:s[r.indexOf(o)]})),i}else return s}Bs.preload=n=>uc.preload(dc,n);Bs.clear=n=>uc.clear(dc,n);const O1=v.forwardRef(function({src:e,skipFill:t,skipStrokes:s,fillMaterial:r,strokeMaterial:i,fillMeshProps:o,strokeMeshProps:a,...c},l){const u=uc(Pi,e.startsWith("s?[]:u.paths.map(d=>{var f;return((f=d.userData)==null?void 0:f.style.stroke)===void 0||d.userData.style.stroke==="none"?null:d.subPaths.map(m=>Pi.pointsToStroke(m.getPoints(),d.userData.style))}),[u,s]);return v.useEffect(()=>()=>h.forEach(d=>d&&d.map(f=>f.dispose())),[h]),v.createElement("object3D",Se({ref:l},c),v.createElement("object3D",{scale:[1,-1,1]},u.paths.map((d,f)=>{var m,p;return v.createElement(v.Fragment,{key:f},!t&&((m=d.userData)==null?void 0:m.style.fill)!==void 0&&d.userData.style.fill!=="none"&&Pi.createShapes(d).map((g,_)=>v.createElement("mesh",Se({key:_},o),v.createElement("shapeGeometry",{args:[g]}),v.createElement("meshBasicMaterial",Se({color:d.userData.style.fill,opacity:d.userData.style.fillOpacity,transparent:!0,side:ya,depthWrite:!1},r)))),!s&&((p=d.userData)==null?void 0:p.style.stroke)!==void 0&&d.userData.style.stroke!=="none"&&d.subPaths.map((g,_)=>v.createElement("mesh",Se({key:_,geometry:h[f][_]},a),v.createElement("meshBasicMaterial",Se({color:d.userData.style.stroke,opacity:d.userData.style.strokeOpacity,transparent:!0,side:ya,depthWrite:!1},i)))))})))});/*! * camera-controls * https://github.com/yomotsu/camera-controls * (c) 2017 @yomotsu diff --git a/build/assets/index-20575f2c.js b/build/assets/index-8a87d5eb.js similarity index 56% rename from build/assets/index-20575f2c.js rename to build/assets/index-8a87d5eb.js index 608fdb24f..dd44ceb52 100644 --- a/build/assets/index-20575f2c.js +++ b/build/assets/index-8a87d5eb.js @@ -1,4 +1,4 @@ -import{s as i,a as t,F as c,j as e,e as j,r as l,u as B,B as w,bw as C,by as R,a$ as I}from"./index-4bb27744.js";import{aC as z,f as D,l as E}from"./index-7730ff6f.js";import{S as L}from"./Skeleton-dbbfd404.js";import{C as T}from"./ClipLoader-1ef5878d.js";const G=({nodeName:p})=>e.jsx(c,{children:e.jsxs(c,{align:"center",direction:"column",justify:"space-between",children:[e.jsx(A,{children:e.jsx(z,{})}),e.jsxs(M,{children:["Are you sure you want to delete ",p||"this item","?"]})]})}),M=i(c)` +import{s as i,a as t,F as c,j as e,e as j,r as l,u as C,B as w,bv as $,bx as R,a_ as I}from"./index-4e60c9e2.js";import{aC as z,f as D,l as E}from"./index-af5a3f81.js";import{S as L}from"./Skeleton-7af13a79.js";import{C as T}from"./ClipLoader-8590c2f1.js";const G=({nodeName:p})=>e.jsx(c,{children:e.jsxs(c,{align:"center",direction:"column",justify:"space-between",children:[e.jsx(_,{children:e.jsx(z,{})}),e.jsxs(M,{children:["Are you sure you want to delete ",p||"this item","?"]})]})}),M=i(c)` color: ${t.white}; font-family: 'Barlow'; font-size: 20px; @@ -9,7 +9,7 @@ import{s as i,a as t,F as c,j as e,e as j,r as l,u as B,B as w,bw as C,by as R,a padding: 0 20px; width: 100%; word-wrap: break-word; -`,A=i(c)` +`,_=i(c)` justify-content: center; align-items: center; font-size: 52px; @@ -19,7 +19,7 @@ import{s as i,a as t,F as c,j as e,e as j,r as l,u as B,B as w,bw as C,by as R,a path:nth-child(3) { color: #6b7a8d; } -`,W=()=>{const{close:p}=j("removeNode"),{close:h}=j("editNodeName"),[x,d]=l.useState(!1),[y]=D(s=>[s.setSelectedNode]),[v]=B(s=>[s.removeNode]),[N,g]=l.useState(!1),[n,b]=l.useState(),[a,S]=l.useState(),o=E(),f=()=>{p()};l.useEffect(()=>{(async()=>{if(o){g(!0);try{if(o.type==="topic"){const{data:r}=await C({search:o==null?void 0:o.name}),u=r.find(m=>m.name===o.name);S(u)}else b(o)}catch(r){console.error(r)}finally{g(!1)}}})()},[o]);const $=async()=>{d(!0);try{y(null),f(),h()}catch(s){console.warn(s)}finally{d(!1)}},k=async()=>{let s="";const r=n||a;if(!r)return;r!=null&&r.ref_id&&(s=r.ref_id),d(!0);const u=o==null?void 0:o.ref_id;try{await R(s),v(u),y(null),f(),h()}catch(m){console.warn(m)}finally{d(!1)}};return e.jsxs(_,{children:[e.jsx(G,{nodeName:(n==null?void 0:n.name)||(a==null?void 0:a.name)||""}),N?e.jsx(L,{}):e.jsxs(c,{direction:"row",mt:34,children:[e.jsx(F,{color:"secondary",onClick:f,size:"large",style:{flex:1,marginRight:20},variant:"contained",children:"Cancel"}),e.jsxs(H,{color:"secondary",disabled:x||!n&&!a,onClick:n||a?k:$,size:"large",style:{flex:1},variant:"contained",children:["Delete",x&&e.jsx(O,{children:e.jsx(T,{color:t.lightGray,size:12})})]})]})]})},_=i(c)` +`,A=()=>{const{close:p}=j("removeNode"),{close:h}=j("editNodeName"),[x,d]=l.useState(!1),[g]=D(s=>[s.setSelectedNode]),[v]=C(s=>[s.removeNode]),[N,y]=l.useState(!1),[n,b]=l.useState(),[a,S]=l.useState(),o=E(),f=()=>{p()};l.useEffect(()=>{(async()=>{if(o){y(!0);try{if(o.type==="topic"){const{data:r}=await $({search:o==null?void 0:o.name}),u=r.find(m=>m.name===o.name);S(u)}else b(o)}catch(r){console.error(r)}finally{y(!1)}}})()},[o]);const k=async()=>{d(!0);try{g(null),f(),h()}catch(s){console.warn(s)}finally{d(!1)}},B=async()=>{let s="";const r=n||a;if(!r)return;r!=null&&r.ref_id&&(s=r.ref_id),d(!0);const u=o==null?void 0:o.ref_id;try{await R(s),v(u),g(null),f(),h()}catch(m){console.warn(m)}finally{d(!1)}};return e.jsxs(W,{children:[e.jsx(G,{nodeName:(n==null?void 0:n.name)||(a==null?void 0:a.name)||""}),N?e.jsx(L,{}):e.jsxs(c,{direction:"row",mt:34,children:[e.jsx(F,{color:"secondary",onClick:f,size:"large",style:{flex:1,marginRight:20},variant:"contained",children:"Cancel"}),e.jsxs(H,{color:"secondary",disabled:x||!n&&!a,onClick:n||a?B:k,size:"large",style:{flex:1},variant:"contained",children:["Delete",x&&e.jsx(O,{children:e.jsx(T,{color:t.lightGray,size:12})})]})]})]})},W=i(c)` padding: 4px 12px 16px; `,F=i(w)` && { @@ -47,4 +47,4 @@ import{s as i,a as t,F as c,j as e,e as j,r as l,u as B,B as w,bw as C,by as R,a } `,O=i.span` margin-top: 2px; -`,Q=()=>e.jsx(I,{id:"removeNode",kind:"small",preventOutsideClose:!0,children:e.jsx(W,{})});export{Q as RemoveNodeModal}; +`,Q=()=>e.jsx(I,{id:"removeNode",kind:"small",preventOutsideClose:!0,children:e.jsx(A,{})});export{Q as RemoveNodeModal}; diff --git a/build/assets/index-87de005d.js b/build/assets/index-a46872c4.js similarity index 99% rename from build/assets/index-87de005d.js rename to build/assets/index-a46872c4.js index 0534766a4..2cefdddf7 100644 --- a/build/assets/index-87de005d.js +++ b/build/assets/index-a46872c4.js @@ -1,4 +1,4 @@ -import{ag as WO,ah as xa,i as Pv,ai as GL,r as M,aj as VO,Z as qs,$ as zL,a2 as $s,O as ce,j as m,M as fb,L as gb,N as Mr,ak as qL,Y as Jt,P as Hi,S as hb,H as Fl,U as Cr,V as mb,a3 as Bl,al as HL,am as WL,an as YO,s as B,a as P,ad as KO,ao as bb,o as Ul,F,t as VL,u as Pr,b as Gl,n as Mo,ap as XO,v as YL,T as pt,aq as KL,x as dn,k as Ct,d as yb,A as $r,ar as ei,as as Tt,at as XL,a9 as ft,B as Mt,q as ZO,C as JO,au as ZL,av as QO,e as $v,p as JL,aw as e1,ax as t1,ay as ti,az as Ne,J as U,aA as QL,aB as eM,aC as tM,aD as zl,aE as rM,aF as nM,aG as aM,aH as iM,aI as r1,aJ as oM,aK as ql,aL as sM,aM as lM,aN as uM,aO as cM,ac as dM,aP as jv,l as pM,aQ as fM,aR as gM,I as hM,aS as mM,E as bM,_ as ir,aT as yM,aU as vM}from"./index-4bb27744.js";import{v as na,w as js,x as ic,y as n1,z as SM,G as EM,J as xM,K as Fv,L as Fs,Q as Tn,U as Bv,W as gs,X as a1,Y as wM,q as vb,Z as i1,_ as vn,$ as o1,f as s1,a0 as _M,u as Po,a1 as TM,a2 as Sb,a3 as Hl,a4 as AM,a5 as l1,a6 as u1,a7 as OM,P as kM,a8 as c1,a9 as RM,aa as IM,ab as NM,ac as CM,c as Eb,d as xb,ad as DM,ae as LM,af as MM,l as Pt,ag as d1,ah as PM,e as p1,ai as $M,b as $o,M as jM,V as FM,aj as BM,ak as UM,t as GM,al as f1,am as zM}from"./index-7730ff6f.js";import{c as qM,a as oc,C as Wl}from"./ClipLoader-1ef5878d.js";import{S as g1}from"./Skeleton-dbbfd404.js";import{u as h1,P as wb,a as HM,F as WM}from"./Stack-6038813c.js";import{T as ri}from"./index-5111ebdb.js";import{S as VM,F as Uv,i as jo,g as yr,t as YM,_ as m1,a as KM,b as XM,c as ia,d as _b,e as ZM,f as JM,h as QM,j as Fo,m as eP,k as tP,l as rP,n as b1,o as nP,p as aP}from"./isPlainObject-b85008a5.js";import{c as Tb}from"./createSvgIcon-41051178.js";import{useBriefDescriptionStore as iP}from"./index-59c77710.js";import{P as we,p as oP}from"./index-7888478e.js";import{u as y1}from"./index-a17bf5d0.js";const Gv="023d8eb306f0027b902fbdc81d33b49b6558b3434d374626f8c324979c92d47c21",sP=async e=>{let t=await xa.enable(!0);if(t||console.warn("Sphinx enable failed, means no pubkey and no budget (including budget of 0)"),t=await xa.keysend(Gv,e),!(t!=null&&t.success)){if(t=await xa.topup(),t||(t=await xa.authorize()),!(t!=null&&t.budget)||(t==null?void 0:t.budget){const r=await sP(t),n={amount:t,refid:e};return await WO.post("/boost",JSON.stringify(n)),r};function Ab(e){return e?String(e).replace(/[[]{2}/g,"").replace(/[\]]{2}/g,""):""}const uP=e=>{const[t,r]=e.split("-")||["",""];return parseInt(r,10)!==0?`${t} - ${r}`:t},v1=(e,t)=>{if(!t)return null;const r=e.filter(i=>i.show_title&&i.link&&i.show_title===t.show_title&&i.episode_title===t.episode_title),n=Pv.groupBy(r,i=>i.timestamp),a=Pv.values(n).reduce((i,o)=>(o[0]&&i.push(o[0]),i),[]);return a.sort((i,o)=>{var p,g;const[s]=((p=i.timestamp)==null?void 0:p.split("-"))||[""],[l]=((g=o.timestamp)==null?void 0:g.split("-"))||[""],c=na(s),d=na(l);return c-d}),a},cP=async e=>{await GL(async()=>{try{await xa.saveGraphData({metaData:{date:Math.floor(new Date().getTime()/1e3),...e},type:"second_brain_consumed_content"})}catch(t){console.warn(t)}})},dP=e=>{const t=/((http|https):\/\/[^\s]+)/g,r=/@(\w+)/g;let n=e.replace(/\\/g,"");return n=n.replace(/'/g,"’"),n=n.replace(/\n/g,"
"),n=n.replace(t,'$1'),n=n.replace(r,'@$1'),n},pP={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:-1,overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"},fP=pP;function gP(e,t,r=(n,a)=>n===a){return e.length===t.length&&e.every((n,a)=>r(n,t[a]))}const hP=2;function S1(e,t){return e-t}function hi(e,t,r){return e==null?t:Math.min(Math.max(t,e),r)}function zv(e,t){var r;const{index:n}=(r=e.reduce((a,i,o)=>{const s=Math.abs(t-i);return a===null||s({left:`${e}%`}),leap:e=>({width:`${e}%`})},"horizontal-reverse":{offset:e=>({right:`${e}%`}),leap:e=>({width:`${e}%`})},vertical:{offset:e=>({bottom:`${e}%`}),leap:e=>({height:`${e}%`})}},SP=e=>e;let ys;function sc(){return ys===void 0&&(typeof CSS<"u"&&typeof CSS.supports=="function"?ys=CSS.supports("touch-action","none"):ys=!0),ys}function EP(e){const{"aria-labelledby":t,defaultValue:r,disabled:n=!1,disableSwap:a=!1,isRtl:i=!1,marks:o=!1,max:s=100,min:l=0,name:c,onChange:d,onChangeCommitted:p,orientation:g="horizontal",rootRef:h,scale:b=SP,step:S=1,tabIndex:v,value:O}=e,_=M.useRef(),[w,A]=M.useState(-1),[x,E]=M.useState(-1),[k,N]=M.useState(!1),I=M.useRef(0),[D,L]=h1({controlled:O,default:r??l,name:"Slider"}),j=d&&((te,de,ye)=>{const ve=te.nativeEvent||te,ge=new ve.constructor(ve.type,ve);Object.defineProperty(ge,"target",{writable:!0,value:{value:de,name:c}}),d(ge,de,ye)}),q=Array.isArray(D);let H=q?D.slice().sort(S1):[D];H=H.map(te=>hi(te,l,s));const z=o===!0&&S!==null?[...Array(Math.floor((s-l)/S)+1)].map((te,de)=>({value:l+S*de})):o||[],W=z.map(te=>te.value),{isFocusVisibleRef:K,onBlur:G,onFocus:V,ref:J}=VO(),[ae,re]=M.useState(-1),ue=M.useRef(),Se=qs(J,ue),Q=qs(h,Se),Ie=te=>de=>{var ye;const ve=Number(de.currentTarget.getAttribute("data-index"));V(de),K.current===!0&&re(ve),E(ve),te==null||(ye=te.onFocus)==null||ye.call(te,de)},Ue=te=>de=>{var ye;G(de),K.current===!1&&re(-1),E(-1),te==null||(ye=te.onBlur)==null||ye.call(te,de)};zL(()=>{if(n&&ue.current.contains(document.activeElement)){var te;(te=document.activeElement)==null||te.blur()}},[n]),n&&w!==-1&&A(-1),n&&ae!==-1&&re(-1);const xe=te=>de=>{var ye;(ye=te.onChange)==null||ye.call(te,de);const ve=Number(de.currentTarget.getAttribute("data-index")),ge=H[ve],qe=W.indexOf(ge);let De=de.target.valueAsNumber;if(z&&S==null){const Ge=W[W.length-1];De>Ge?De=Ge:De{const{current:ye}=ue,{width:ve,height:ge,bottom:qe,left:De}=ye.getBoundingClientRect();let Ge;oe.indexOf("vertical")===0?Ge=(qe-te.y)/ge:Ge=(te.x-De)/ve,oe.indexOf("-reverse")!==-1&&(Ge=1-Ge);let Je;if(Je=mP(Ge,l,s),S)Je=yP(Je,S,l);else{const rr=zv(W,Je);Je=W[rr]}Je=hi(Je,l,s);let jt=0;if(q){de?jt=ee.current:jt=zv(H,Je),a&&(Je=hi(Je,H[jt-1]||-1/0,H[jt+1]||1/0));const rr=Je;Je=qv({values:H,newValue:Je,index:jt}),a&&de||(jt=Je.indexOf(rr),ee.current=jt)}return{newValue:Je,activeIndex:jt}},X=$s(te=>{const de=hs(te,_);if(!de)return;if(I.current+=1,te.type==="mousemove"&&te.buttons===0){Ee(te);return}const{newValue:ye,activeIndex:ve}=ie({finger:de,move:!0});ms({sliderRef:ue,activeIndex:ve,setActive:A}),L(ye),!k&&I.current>hP&&N(!0),j&&!bs(ye,D)&&j(te,ye,ve)}),Ee=$s(te=>{const de=hs(te,_);if(N(!1),!de)return;const{newValue:ye}=ie({finger:de,move:!0});A(-1),te.type==="touchend"&&E(-1),p&&p(te,ye),_.current=void 0,he()}),fe=$s(te=>{if(n)return;sc()||te.preventDefault();const de=te.changedTouches[0];de!=null&&(_.current=de.identifier);const ye=hs(te,_);if(ye!==!1){const{newValue:ge,activeIndex:qe}=ie({finger:ye});ms({sliderRef:ue,activeIndex:qe,setActive:A}),L(ge),j&&!bs(ge,D)&&j(te,ge,qe)}I.current=0;const ve=js(ue.current);ve.addEventListener("touchmove",X),ve.addEventListener("touchend",Ee)}),he=M.useCallback(()=>{const te=js(ue.current);te.removeEventListener("mousemove",X),te.removeEventListener("mouseup",Ee),te.removeEventListener("touchmove",X),te.removeEventListener("touchend",Ee)},[Ee,X]);M.useEffect(()=>{const{current:te}=ue;return te.addEventListener("touchstart",fe,{passive:sc()}),()=>{te.removeEventListener("touchstart",fe,{passive:sc()}),he()}},[he,fe]),M.useEffect(()=>{n&&he()},[n,he]);const je=te=>de=>{var ye;if((ye=te.onMouseDown)==null||ye.call(te,de),n||de.defaultPrevented||de.button!==0)return;de.preventDefault();const ve=hs(de,_);if(ve!==!1){const{newValue:qe,activeIndex:De}=ie({finger:ve});ms({sliderRef:ue,activeIndex:De,setActive:A}),L(qe),j&&!bs(qe,D)&&j(de,qe,De)}I.current=0;const ge=js(ue.current);ge.addEventListener("mousemove",X),ge.addEventListener("mouseup",Ee)},nt=Hs(q?H[0]:l,l,s),et=Hs(H[H.length-1],l,s)-nt,tr=(te={})=>{const de=ic(te),ye={onMouseDown:je(de||{})},ve=ce({},de,ye);return ce({},te,{ref:Q},ve)},Pe=te=>de=>{var ye;(ye=te.onMouseOver)==null||ye.call(te,de);const ve=Number(de.currentTarget.getAttribute("data-index"));E(ve)},$e=te=>de=>{var ye;(ye=te.onMouseLeave)==null||ye.call(te,de),E(-1)};return{active:w,axis:oe,axisProps:vP,dragging:k,focusedThumbIndex:ae,getHiddenInputProps:(te={})=>{var de;const ye=ic(te),ve={onChange:xe(ye||{}),onFocus:Ie(ye||{}),onBlur:Ue(ye||{})},ge=ce({},ye,ve);return ce({tabIndex:v,"aria-labelledby":t,"aria-orientation":g,"aria-valuemax":b(s),"aria-valuemin":b(l),name:c,type:"range",min:e.min,max:e.max,step:e.step===null&&e.marks?"any":(de=e.step)!=null?de:void 0,disabled:n},te,ge,{style:ce({},fP,{direction:i?"rtl":"ltr",width:"100%",height:"100%"})})},getRootProps:tr,getThumbProps:(te={})=>{const de=ic(te),ye={onMouseOver:Pe(de||{}),onMouseLeave:$e(de||{})};return ce({},te,de,ye)},marks:z,open:x,range:q,rootRef:Q,trackLeap:et,trackOffset:nt,values:H,getThumbStyle:te=>({pointerEvents:w!==-1&&w!==te?"none":void 0})}}const xP=Tb(m.jsx("path",{d:"M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"}),"CheckBoxOutlineBlank"),wP=Tb(m.jsx("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"}),"CheckBox"),_P=Tb(m.jsx("path",{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z"}),"IndeterminateCheckBox");function TP(e){return gb("MuiCheckbox",e)}const AP=fb("MuiCheckbox",["root","checked","disabled","indeterminate","colorPrimary","colorSecondary","sizeSmall","sizeMedium"]),lc=AP,OP=["checkedIcon","color","icon","indeterminate","indeterminateIcon","inputProps","size","className"],kP=e=>{const{classes:t,indeterminate:r,color:n,size:a}=e,i={root:["root",r&&"indeterminate",`color${Jt(n)}`,`size${Jt(a)}`]},o=mb(i,TP,t);return ce({},t,o)},RP=Mr(VM,{shouldForwardProp:e=>qL(e)||e==="classes",name:"MuiCheckbox",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.indeterminate&&t.indeterminate,t[`size${Jt(r.size)}`],r.color!=="default"&&t[`color${Jt(r.color)}`]]}})(({theme:e,ownerState:t})=>ce({color:(e.vars||e).palette.text.secondary},!t.disableRipple&&{"&:hover":{backgroundColor:e.vars?`rgba(${t.color==="default"?e.vars.palette.action.activeChannel:e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Hi(t.color==="default"?e.palette.action.active:e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},t.color!=="default"&&{[`&.${lc.checked}, &.${lc.indeterminate}`]:{color:(e.vars||e).palette[t.color].main},[`&.${lc.disabled}`]:{color:(e.vars||e).palette.action.disabled}})),IP=m.jsx(wP,{}),NP=m.jsx(xP,{}),CP=m.jsx(_P,{}),DP=M.forwardRef(function(t,r){var n,a;const i=hb({props:t,name:"MuiCheckbox"}),{checkedIcon:o=IP,color:s="primary",icon:l=NP,indeterminate:c=!1,indeterminateIcon:d=CP,inputProps:p,size:g="medium",className:h}=i,b=Fl(i,OP),S=c?d:l,v=c?d:o,O=ce({},i,{color:s,indeterminate:c,size:g}),_=kP(O);return m.jsx(RP,ce({type:"checkbox",inputProps:ce({"data-indeterminate":c},p),icon:M.cloneElement(S,{fontSize:(n=S.props.fontSize)!=null?n:g}),checkedIcon:M.cloneElement(v,{fontSize:(a=v.props.fontSize)!=null?a:g}),ownerState:O,ref:r,className:Cr(_.root,h)},b,{classes:_}))}),LP=DP,MP=["addEndListener","appear","children","container","direction","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function PP(e,t,r){const n=t.getBoundingClientRect(),a=r&&r.getBoundingClientRect(),i=n1(t);let o;if(t.fakeTransform)o=t.fakeTransform;else{const c=i.getComputedStyle(t);o=c.getPropertyValue("-webkit-transform")||c.getPropertyValue("transform")}let s=0,l=0;if(o&&o!=="none"&&typeof o=="string"){const c=o.split("(")[1].split(")")[0].split(",");s=parseInt(c[4],10),l=parseInt(c[5],10)}return e==="left"?a?`translateX(${a.right+s-n.left}px)`:`translateX(${i.innerWidth+s-n.left}px)`:e==="right"?a?`translateX(-${n.right-a.left-s}px)`:`translateX(-${n.left+n.width-s}px)`:e==="up"?a?`translateY(${a.bottom+l-n.top}px)`:`translateY(${i.innerHeight+l-n.top}px)`:a?`translateY(-${n.top-a.top+n.height-l}px)`:`translateY(-${n.top+n.height-l}px)`}function $P(e){return typeof e=="function"?e():e}function vs(e,t,r){const n=$P(r),a=PP(e,t,n);a&&(t.style.webkitTransform=a,t.style.transform=a)}const jP=M.forwardRef(function(t,r){const n=Bl(),a={enter:n.transitions.easing.easeOut,exit:n.transitions.easing.sharp},i={enter:n.transitions.duration.enteringScreen,exit:n.transitions.duration.leavingScreen},{addEndListener:o,appear:s=!0,children:l,container:c,direction:d="down",easing:p=a,in:g,onEnter:h,onEntered:b,onEntering:S,onExit:v,onExited:O,onExiting:_,style:w,timeout:A=i,TransitionComponent:x=SM}=t,E=Fl(t,MP),k=M.useRef(null),N=qs(l.ref,k,r),I=G=>V=>{G&&(V===void 0?G(k.current):G(k.current,V))},D=I((G,V)=>{vs(d,G,c),xM(G),h&&h(G,V)}),L=I((G,V)=>{const J=Fv({timeout:A,style:w,easing:p},{mode:"enter"});G.style.webkitTransition=n.transitions.create("-webkit-transform",ce({},J)),G.style.transition=n.transitions.create("transform",ce({},J)),G.style.webkitTransform="none",G.style.transform="none",S&&S(G,V)}),j=I(b),q=I(_),H=I(G=>{const V=Fv({timeout:A,style:w,easing:p},{mode:"exit"});G.style.webkitTransition=n.transitions.create("-webkit-transform",V),G.style.transition=n.transitions.create("transform",V),vs(d,G,c),v&&v(G)}),z=I(G=>{G.style.webkitTransition="",G.style.transition="",O&&O(G)}),W=G=>{o&&o(k.current,G)},K=M.useCallback(()=>{k.current&&vs(d,k.current,c)},[d,c]);return M.useEffect(()=>{if(g||d==="down"||d==="right")return;const G=EM(()=>{k.current&&vs(d,k.current,c)}),V=n1(k.current);return V.addEventListener("resize",G),()=>{G.clear(),V.removeEventListener("resize",G)}},[d,g,c]),M.useEffect(()=>{g||K()},[g,K]),m.jsx(x,ce({nodeRef:k,onEnter:D,onEntered:j,onEntering:L,onExit:H,onExited:z,onExiting:q,addEndListener:W,appear:s,in:g,timeout:A},E,{children:(G,V)=>M.cloneElement(l,ce({ref:N,style:ce({visibility:G==="exited"&&!g?"hidden":void 0},w,l.props.style)},V))}))}),Ca=jP,FP=e=>!e||!Fs(e),BP=FP;function UP(e){return gb("MuiSlider",e)}const GP=fb("MuiSlider",["root","active","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","disabled","dragging","focusVisible","mark","markActive","marked","markLabel","markLabelActive","rail","sizeSmall","thumb","thumbColorPrimary","thumbColorSecondary","thumbColorError","thumbColorSuccess","thumbColorInfo","thumbColorWarning","track","trackInverted","trackFalse","thumbSizeSmall","valueLabel","valueLabelOpen","valueLabelCircle","valueLabelLabel","vertical"]),Dr=GP,zP=e=>{const{open:t}=e;return{offset:Cr(t&&Dr.valueLabelOpen),circle:Dr.valueLabelCircle,label:Dr.valueLabelLabel}};function qP(e){const{children:t,className:r,value:n}=e,a=zP(e);return t?M.cloneElement(t,{className:Cr(t.props.className)},m.jsxs(M.Fragment,{children:[t.props.children,m.jsx("span",{className:Cr(a.offset,r),"aria-hidden":!0,children:m.jsx("span",{className:a.circle,children:m.jsx("span",{className:a.label,children:n})})})]})):null}const HP=["aria-label","aria-valuetext","aria-labelledby","component","components","componentsProps","color","classes","className","disableSwap","disabled","getAriaLabel","getAriaValueText","marks","max","min","name","onChange","onChangeCommitted","orientation","size","step","scale","slotProps","slots","tabIndex","track","value","valueLabelDisplay","valueLabelFormat"];function Hv(e){return e}const WP=Mr("span",{name:"MuiSlider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[`color${Jt(r.color)}`],r.size!=="medium"&&t[`size${Jt(r.size)}`],r.marked&&t.marked,r.orientation==="vertical"&&t.vertical,r.track==="inverted"&&t.trackInverted,r.track===!1&&t.trackFalse]}})(({theme:e,ownerState:t})=>ce({borderRadius:12,boxSizing:"content-box",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",color:(e.vars||e).palette[t.color].main,WebkitTapHighlightColor:"transparent"},t.orientation==="horizontal"&&ce({height:4,width:"100%",padding:"13px 0","@media (pointer: coarse)":{padding:"20px 0"}},t.size==="small"&&{height:2},t.marked&&{marginBottom:20}),t.orientation==="vertical"&&ce({height:"100%",width:4,padding:"0 13px","@media (pointer: coarse)":{padding:"0 20px"}},t.size==="small"&&{width:2},t.marked&&{marginRight:44}),{"@media print":{colorAdjust:"exact"},[`&.${Dr.disabled}`]:{pointerEvents:"none",cursor:"default",color:(e.vars||e).palette.grey[400]},[`&.${Dr.dragging}`]:{[`& .${Dr.thumb}, & .${Dr.track}`]:{transition:"none"}}})),VP=Mr("span",{name:"MuiSlider",slot:"Rail",overridesResolver:(e,t)=>t.rail})(({ownerState:e})=>ce({display:"block",position:"absolute",borderRadius:"inherit",backgroundColor:"currentColor",opacity:.38},e.orientation==="horizontal"&&{width:"100%",height:"inherit",top:"50%",transform:"translateY(-50%)"},e.orientation==="vertical"&&{height:"100%",width:"inherit",left:"50%",transform:"translateX(-50%)"},e.track==="inverted"&&{opacity:1})),YP=Mr("span",{name:"MuiSlider",slot:"Track",overridesResolver:(e,t)=>t.track})(({theme:e,ownerState:t})=>{const r=e.palette.mode==="light"?HL(e.palette[t.color].main,.62):WL(e.palette[t.color].main,.5);return ce({display:"block",position:"absolute",borderRadius:"inherit",border:"1px solid currentColor",backgroundColor:"currentColor",transition:e.transitions.create(["left","width","bottom","height"],{duration:e.transitions.duration.shortest})},t.size==="small"&&{border:"none"},t.orientation==="horizontal"&&{height:"inherit",top:"50%",transform:"translateY(-50%)"},t.orientation==="vertical"&&{width:"inherit",left:"50%",transform:"translateX(-50%)"},t.track===!1&&{display:"none"},t.track==="inverted"&&{backgroundColor:e.vars?e.vars.palette.Slider[`${t.color}Track`]:r,borderColor:e.vars?e.vars.palette.Slider[`${t.color}Track`]:r})}),KP=Mr("span",{name:"MuiSlider",slot:"Thumb",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.thumb,t[`thumbColor${Jt(r.color)}`],r.size!=="medium"&&t[`thumbSize${Jt(r.size)}`]]}})(({theme:e,ownerState:t})=>ce({position:"absolute",width:20,height:20,boxSizing:"border-box",borderRadius:"50%",outline:0,backgroundColor:"currentColor",display:"flex",alignItems:"center",justifyContent:"center",transition:e.transitions.create(["box-shadow","left","bottom"],{duration:e.transitions.duration.shortest})},t.size==="small"&&{width:12,height:12},t.orientation==="horizontal"&&{top:"50%",transform:"translate(-50%, -50%)"},t.orientation==="vertical"&&{left:"50%",transform:"translate(-50%, 50%)"},{"&:before":ce({position:"absolute",content:'""',borderRadius:"inherit",width:"100%",height:"100%",boxShadow:(e.vars||e).shadows[2]},t.size==="small"&&{boxShadow:"none"}),"&::after":{position:"absolute",content:'""',borderRadius:"50%",width:42,height:42,top:"50%",left:"50%",transform:"translate(-50%, -50%)"},[`&:hover, &.${Dr.focusVisible}`]:{boxShadow:`0px 0px 0px 8px ${e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / 0.16)`:Hi(e.palette[t.color].main,.16)}`,"@media (hover: none)":{boxShadow:"none"}},[`&.${Dr.active}`]:{boxShadow:`0px 0px 0px 14px ${e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / 0.16)`:Hi(e.palette[t.color].main,.16)}`},[`&.${Dr.disabled}`]:{"&:hover":{boxShadow:"none"}}})),XP=Mr(qP,{name:"MuiSlider",slot:"ValueLabel",overridesResolver:(e,t)=>t.valueLabel})(({theme:e,ownerState:t})=>ce({[`&.${Dr.valueLabelOpen}`]:{transform:`${t.orientation==="vertical"?"translateY(-50%)":"translateY(-100%)"} scale(1)`},zIndex:1,whiteSpace:"nowrap"},e.typography.body2,{fontWeight:500,transition:e.transitions.create(["transform"],{duration:e.transitions.duration.shortest}),transform:`${t.orientation==="vertical"?"translateY(-50%)":"translateY(-100%)"} scale(0)`,position:"absolute",backgroundColor:(e.vars||e).palette.grey[600],borderRadius:2,color:(e.vars||e).palette.common.white,display:"flex",alignItems:"center",justifyContent:"center",padding:"0.25rem 0.75rem"},t.orientation==="horizontal"&&{top:"-10px",transformOrigin:"bottom center","&:before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, 50%) rotate(45deg)",backgroundColor:"inherit",bottom:0,left:"50%"}},t.orientation==="vertical"&&{right:t.size==="small"?"20px":"30px",top:"50%",transformOrigin:"right center","&:before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, -50%) rotate(45deg)",backgroundColor:"inherit",right:-8,top:"50%"}},t.size==="small"&&{fontSize:e.typography.pxToRem(12),padding:"0.25rem 0.5rem"})),ZP=Mr("span",{name:"MuiSlider",slot:"Mark",shouldForwardProp:e=>YO(e)&&e!=="markActive",overridesResolver:(e,t)=>{const{markActive:r}=e;return[t.mark,r&&t.markActive]}})(({theme:e,ownerState:t,markActive:r})=>ce({position:"absolute",width:2,height:2,borderRadius:1,backgroundColor:"currentColor"},t.orientation==="horizontal"&&{top:"50%",transform:"translate(-1px, -50%)"},t.orientation==="vertical"&&{left:"50%",transform:"translate(-50%, 1px)"},r&&{backgroundColor:(e.vars||e).palette.background.paper,opacity:.8})),JP=Mr("span",{name:"MuiSlider",slot:"MarkLabel",shouldForwardProp:e=>YO(e)&&e!=="markLabelActive",overridesResolver:(e,t)=>t.markLabel})(({theme:e,ownerState:t,markLabelActive:r})=>ce({},e.typography.body2,{color:(e.vars||e).palette.text.secondary,position:"absolute",whiteSpace:"nowrap"},t.orientation==="horizontal"&&{top:30,transform:"translateX(-50%)","@media (pointer: coarse)":{top:40}},t.orientation==="vertical"&&{left:36,transform:"translateY(50%)","@media (pointer: coarse)":{left:44}},r&&{color:(e.vars||e).palette.text.primary})),QP=e=>{const{disabled:t,dragging:r,marked:n,orientation:a,track:i,classes:o,color:s,size:l}=e,c={root:["root",t&&"disabled",r&&"dragging",n&&"marked",a==="vertical"&&"vertical",i==="inverted"&&"trackInverted",i===!1&&"trackFalse",s&&`color${Jt(s)}`,l&&`size${Jt(l)}`],rail:["rail"],track:["track"],mark:["mark"],markActive:["markActive"],markLabel:["markLabel"],markLabelActive:["markLabelActive"],valueLabel:["valueLabel"],thumb:["thumb",t&&"disabled",l&&`thumbSize${Jt(l)}`,s&&`thumbColor${Jt(s)}`],active:["active"],disabled:["disabled"],focusVisible:["focusVisible"]};return mb(c,UP,o)},e$=({children:e})=>e,t$=M.forwardRef(function(t,r){var n,a,i,o,s,l,c,d,p,g,h,b,S,v,O,_,w,A,x,E,k,N,I,D;const L=hb({props:t,name:"MuiSlider"}),q=Bl().direction==="rtl",{"aria-label":H,"aria-valuetext":z,"aria-labelledby":W,component:K="span",components:G={},componentsProps:V={},color:J="primary",classes:ae,className:re,disableSwap:ue=!1,disabled:Se=!1,getAriaLabel:Q,getAriaValueText:Ie,marks:Ue=!1,max:xe=100,min:ee=0,orientation:oe="horizontal",size:ie="medium",step:X=1,scale:Ee=Hv,slotProps:fe,slots:he,track:je="normal",valueLabelDisplay:nt="off",valueLabelFormat:et=Hv}=L,tr=Fl(L,HP),Pe=ce({},L,{isRtl:q,max:xe,min:ee,classes:ae,disabled:Se,disableSwap:ue,orientation:oe,marks:Ue,color:J,size:ie,step:X,scale:Ee,track:je,valueLabelDisplay:nt,valueLabelFormat:et}),{axisProps:$e,getRootProps:Ye,getHiddenInputProps:$t,getThumbProps:Kt,open:te,active:de,axis:ye,focusedThumbIndex:ve,range:ge,dragging:qe,marks:De,values:Ge,trackOffset:Je,trackLeap:jt,getThumbStyle:rr}=EP(ce({},Pe,{rootRef:r}));Pe.marked=De.length>0&&De.some(_e=>_e.label),Pe.dragging=qe,Pe.focusedThumbIndex=ve;const ze=QP(Pe),Kr=(n=(a=he==null?void 0:he.root)!=null?a:G.Root)!=null?n:WP,Xr=(i=(o=he==null?void 0:he.rail)!=null?o:G.Rail)!=null?i:VP,Zr=(s=(l=he==null?void 0:he.track)!=null?l:G.Track)!=null?s:YP,He=(c=(d=he==null?void 0:he.thumb)!=null?d:G.Thumb)!=null?c:KP,Bn=(p=(g=he==null?void 0:he.valueLabel)!=null?g:G.ValueLabel)!=null?p:XP,Jr=(h=(b=he==null?void 0:he.mark)!=null?b:G.Mark)!=null?h:ZP,xr=(S=(v=he==null?void 0:he.markLabel)!=null?v:G.MarkLabel)!=null?S:JP,Qr=(O=(_=he==null?void 0:he.input)!=null?_:G.Input)!=null?O:"input",wr=(w=fe==null?void 0:fe.root)!=null?w:V.root,_r=(A=fe==null?void 0:fe.rail)!=null?A:V.rail,Tr=(x=fe==null?void 0:fe.track)!=null?x:V.track,Un=(E=fe==null?void 0:fe.thumb)!=null?E:V.thumb,Fr=(k=fe==null?void 0:fe.valueLabel)!=null?k:V.valueLabel,li=(N=fe==null?void 0:fe.mark)!=null?N:V.mark,Ar=(I=fe==null?void 0:fe.markLabel)!=null?I:V.markLabel,En=(D=fe==null?void 0:fe.input)!=null?D:V.input,le=Tn({elementType:Kr,getSlotProps:Ye,externalSlotProps:wr,externalForwardedProps:tr,additionalProps:ce({},BP(Kr)&&{as:K}),ownerState:ce({},Pe,wr==null?void 0:wr.ownerState),className:[ze.root,re]}),Gn=Tn({elementType:Xr,externalSlotProps:_r,ownerState:Pe,className:ze.rail}),Ft=Tn({elementType:Zr,externalSlotProps:Tr,additionalProps:{style:ce({},$e[ye].offset(Je),$e[ye].leap(jt))},ownerState:ce({},Pe,Tr==null?void 0:Tr.ownerState),className:ze.track}),ut=Tn({elementType:He,getSlotProps:Kt,externalSlotProps:Un,ownerState:ce({},Pe,Un==null?void 0:Un.ownerState),className:ze.thumb}),zn=Tn({elementType:Bn,externalSlotProps:Fr,ownerState:ce({},Pe,Fr==null?void 0:Fr.ownerState),className:ze.valueLabel}),Oe=Tn({elementType:Jr,externalSlotProps:li,ownerState:Pe,className:ze.mark}),nr=Tn({elementType:xr,externalSlotProps:Ar,ownerState:Pe,className:ze.markLabel}),da=Tn({elementType:Qr,getSlotProps:$t,externalSlotProps:En,ownerState:Pe});return m.jsxs(Kr,ce({},le,{children:[m.jsx(Xr,ce({},Gn)),m.jsx(Zr,ce({},Ft)),De.filter(_e=>_e.value>=ee&&_e.value<=xe).map((_e,We)=>{const kt=Hs(_e.value,ee,xe),tt=$e[ye].offset(kt);let ct;return je===!1?ct=Ge.indexOf(_e.value)!==-1:ct=je==="normal"&&(ge?_e.value>=Ge[0]&&_e.value<=Ge[Ge.length-1]:_e.value<=Ge[0])||je==="inverted"&&(ge?_e.value<=Ge[0]||_e.value>=Ge[Ge.length-1]:_e.value>=Ge[0]),m.jsxs(M.Fragment,{children:[m.jsx(Jr,ce({"data-index":We},Oe,!Fs(Jr)&&{markActive:ct},{style:ce({},tt,Oe.style),className:Cr(Oe.className,ct&&ze.markActive)})),_e.label!=null?m.jsx(xr,ce({"aria-hidden":!0,"data-index":We},nr,!Fs(xr)&&{markLabelActive:ct},{style:ce({},tt,nr.style),className:Cr(ze.markLabel,nr.className,ct&&ze.markLabelActive),children:_e.label})):null]},We)}),Ge.map((_e,We)=>{const kt=Hs(_e,ee,xe),tt=$e[ye].offset(kt),ct=nt==="off"?e$:Bn;return m.jsx(ct,ce({},!Fs(ct)&&{valueLabelFormat:et,valueLabelDisplay:nt,value:typeof et=="function"?et(Ee(_e),We):et,index:We,open:te===We||de===We||nt==="on",disabled:Se},zn,{children:m.jsx(He,ce({"data-index":We},ut,{className:Cr(ze.thumb,ut.className,de===We&&ze.active,ve===We&&ze.focusVisible),style:ce({},tt,rr(We),ut.style),children:m.jsx(Qr,ce({"data-index":We,"aria-label":Q?Q(We):H,"aria-valuenow":Ee(_e),"aria-labelledby":W,"aria-valuetext":Ie?Ie(Ee(_e),We):z,value:Ge[We]},da))}))}),We)})]}))}),Vl=t$;function r$(e){return gb("MuiTooltip",e)}const n$=fb("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),Nn=n$,a$=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function i$(e){return Math.round(e*1e5)/1e5}const o$=e=>{const{classes:t,disableInteractive:r,arrow:n,touch:a,placement:i}=e,o={popper:["popper",!r&&"popperInteractive",n&&"popperArrow"],tooltip:["tooltip",n&&"tooltipArrow",a&&"touch",`tooltipPlacement${Jt(i.split("-")[0])}`],arrow:["arrow"]};return mb(o,r$,t)},s$=Mr(wb,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.popper,!r.disableInteractive&&t.popperInteractive,r.arrow&&t.popperArrow,!r.open&&t.popperClose]}})(({theme:e,ownerState:t,open:r})=>ce({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!r&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${Nn.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${Nn.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${Nn.arrow}`]:ce({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${Nn.arrow}`]:ce({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),l$=Mr("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.tooltip,r.touch&&t.touch,r.arrow&&t.tooltipArrow,t[`tooltipPlacement${Jt(r.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>ce({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:Hi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${i$(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${Nn.popper}[data-popper-placement*="left"] &`]:ce({transformOrigin:"right center"},t.isRtl?ce({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):ce({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${Nn.popper}[data-popper-placement*="right"] &`]:ce({transformOrigin:"left center"},t.isRtl?ce({marginRight:"14px"},t.touch&&{marginRight:"24px"}):ce({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${Nn.popper}[data-popper-placement*="top"] &`]:ce({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${Nn.popper}[data-popper-placement*="bottom"] &`]:ce({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),u$=Mr("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:Hi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Ss=!1,uc=null,mi={x:0,y:0};function Es(e,t){return r=>{t&&t(r),e(r)}}const c$=M.forwardRef(function(t,r){var n,a,i,o,s,l,c,d,p,g,h,b,S,v,O,_,w,A,x;const E=hb({props:t,name:"MuiTooltip"}),{arrow:k=!1,children:N,components:I={},componentsProps:D={},describeChild:L=!1,disableFocusListener:j=!1,disableHoverListener:q=!1,disableInteractive:H=!1,disableTouchListener:z=!1,enterDelay:W=100,enterNextDelay:K=0,enterTouchDelay:G=700,followCursor:V=!1,id:J,leaveDelay:ae=0,leaveTouchDelay:re=1500,onClose:ue,onOpen:Se,open:Q,placement:Ie="bottom",PopperComponent:Ue,PopperProps:xe={},slotProps:ee={},slots:oe={},title:ie,TransitionComponent:X=Bv,TransitionProps:Ee}=E,fe=Fl(E,a$),he=M.isValidElement(N)?N:m.jsx("span",{children:N}),je=Bl(),nt=je.direction==="rtl",[et,tr]=M.useState(),[Pe,$e]=M.useState(null),Ye=M.useRef(!1),$t=H||V,Kt=M.useRef(),te=M.useRef(),de=M.useRef(),ye=M.useRef(),[ve,ge]=h1({controlled:Q,default:!1,name:"Tooltip",state:"open"});let qe=ve;const De=HM(J),Ge=M.useRef(),Je=M.useCallback(()=>{Ge.current!==void 0&&(document.body.style.WebkitUserSelect=Ge.current,Ge.current=void 0),clearTimeout(ye.current)},[]);M.useEffect(()=>()=>{clearTimeout(Kt.current),clearTimeout(te.current),clearTimeout(de.current),Je()},[Je]);const jt=ke=>{clearTimeout(uc),Ss=!0,ge(!0),Se&&!qe&&Se(ke)},rr=$s(ke=>{clearTimeout(uc),uc=setTimeout(()=>{Ss=!1},800+ae),ge(!1),ue&&qe&&ue(ke),clearTimeout(Kt.current),Kt.current=setTimeout(()=>{Ye.current=!1},je.transitions.duration.shortest)}),ze=ke=>{Ye.current&&ke.type!=="touchstart"||(et&&et.removeAttribute("title"),clearTimeout(te.current),clearTimeout(de.current),W||Ss&&K?te.current=setTimeout(()=>{jt(ke)},Ss?K:W):jt(ke))},Kr=ke=>{clearTimeout(te.current),clearTimeout(de.current),de.current=setTimeout(()=>{rr(ke)},ae)},{isFocusVisibleRef:Xr,onBlur:Zr,onFocus:He,ref:Bn}=VO(),[,Jr]=M.useState(!1),xr=ke=>{Zr(ke),Xr.current===!1&&(Jr(!1),Kr(ke))},Qr=ke=>{et||tr(ke.currentTarget),He(ke),Xr.current===!0&&(Jr(!0),ze(ke))},wr=ke=>{Ye.current=!0;const Bt=he.props;Bt.onTouchStart&&Bt.onTouchStart(ke)},_r=ze,Tr=Kr,Un=ke=>{wr(ke),clearTimeout(de.current),clearTimeout(Kt.current),Je(),Ge.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",ye.current=setTimeout(()=>{document.body.style.WebkitUserSelect=Ge.current,ze(ke)},G)},Fr=ke=>{he.props.onTouchEnd&&he.props.onTouchEnd(ke),Je(),clearTimeout(de.current),de.current=setTimeout(()=>{rr(ke)},re)};M.useEffect(()=>{if(!qe)return;function ke(Bt){(Bt.key==="Escape"||Bt.key==="Esc")&&rr(Bt)}return document.addEventListener("keydown",ke),()=>{document.removeEventListener("keydown",ke)}},[rr,qe]);const li=qs(he.ref,Bn,tr,r);!ie&&ie!==0&&(qe=!1);const Ar=M.useRef(),En=ke=>{const Bt=he.props;Bt.onMouseMove&&Bt.onMouseMove(ke),mi={x:ke.clientX,y:ke.clientY},Ar.current&&Ar.current.update()},le={},Gn=typeof ie=="string";L?(le.title=!qe&&Gn&&!q?ie:null,le["aria-describedby"]=qe?De:null):(le["aria-label"]=Gn?ie:null,le["aria-labelledby"]=qe&&!Gn?De:null);const Ft=ce({},le,fe,he.props,{className:Cr(fe.className,he.props.className),onTouchStart:wr,ref:li},V?{onMouseMove:En}:{}),ut={};z||(Ft.onTouchStart=Un,Ft.onTouchEnd=Fr),q||(Ft.onMouseOver=Es(_r,Ft.onMouseOver),Ft.onMouseLeave=Es(Tr,Ft.onMouseLeave),$t||(ut.onMouseOver=_r,ut.onMouseLeave=Tr)),j||(Ft.onFocus=Es(Qr,Ft.onFocus),Ft.onBlur=Es(xr,Ft.onBlur),$t||(ut.onFocus=Qr,ut.onBlur=xr));const zn=M.useMemo(()=>{var ke;let Bt=[{name:"arrow",enabled:!!Pe,options:{element:Pe,padding:4}}];return(ke=xe.popperOptions)!=null&&ke.modifiers&&(Bt=Bt.concat(xe.popperOptions.modifiers)),ce({},xe.popperOptions,{modifiers:Bt})},[Pe,xe]),Oe=ce({},E,{isRtl:nt,arrow:k,disableInteractive:$t,placement:Ie,PopperComponentProp:Ue,touch:Ye.current}),nr=o$(Oe),da=(n=(a=oe.popper)!=null?a:I.Popper)!=null?n:s$,_e=(i=(o=(s=oe.transition)!=null?s:I.Transition)!=null?o:X)!=null?i:Bv,We=(l=(c=oe.tooltip)!=null?c:I.Tooltip)!=null?l:l$,kt=(d=(p=oe.arrow)!=null?p:I.Arrow)!=null?d:u$,tt=gs(da,ce({},xe,(g=ee.popper)!=null?g:D.popper,{className:Cr(nr.popper,xe==null?void 0:xe.className,(h=(b=ee.popper)!=null?b:D.popper)==null?void 0:h.className)}),Oe),ct=gs(_e,ce({},Ee,(S=ee.transition)!=null?S:D.transition),Oe),Or=gs(We,ce({},(v=ee.tooltip)!=null?v:D.tooltip,{className:Cr(nr.tooltip,(O=(_=ee.tooltip)!=null?_:D.tooltip)==null?void 0:O.className)}),Oe),en=gs(kt,ce({},(w=ee.arrow)!=null?w:D.arrow,{className:Cr(nr.arrow,(A=(x=ee.arrow)!=null?x:D.arrow)==null?void 0:A.className)}),Oe);return m.jsxs(M.Fragment,{children:[M.cloneElement(he,Ft),m.jsx(da,ce({as:Ue??wb,placement:Ie,anchorEl:V?{getBoundingClientRect:()=>({top:mi.y,left:mi.x,right:mi.x,bottom:mi.y,width:0,height:0})}:et,popperRef:Ar,open:et?qe:!1,id:De,transition:!0},ut,tt,{popperOptions:zn,children:({TransitionProps:ke})=>m.jsx(_e,ce({timeout:je.transitions.duration.shorter},ke,ct,{children:m.jsxs(We,ce({},Or,{children:[ie,k?m.jsx(kt,ce({},en,{ref:$e})):null]}))}))}))]})}),d$=c$,p$=(e,t="down")=>{const r=Bl(),[n,a]=M.useState(!1),i=r.breakpoints[t](e).split("@media")[1].trim();return M.useEffect(()=>{const o=()=>{const{matches:s}=window.matchMedia(i);a(s)};return o(),window.addEventListener("resize",o),()=>window.removeEventListener("resize",o)},[i]),n},f$=e=>e.filter(t=>t.tldr).length>=2&&e.some(t=>t.audio_EN);function g$(e){return e.tldr_topic??e.name}var Ws=globalThis&&globalThis.__assign||function(){return Ws=Object.assign||function(e){for(var t,r=1,n=arguments.length;r({autoCorrect:"off",autoComplete:"off"}))` +import{af as WO,ag as xa,i as Pv,ah as GL,r as M,ai as VO,Y as qs,Z as zL,a1 as $s,N as ce,j as m,L as fb,K as gb,M as Mr,aj as qL,X as Jt,O as Hi,P as hb,G as Fl,S as Cr,U as mb,a2 as Bl,ak as HL,al as WL,am as YO,s as B,a as P,ac as KO,an as bb,o as Ul,F,t as VL,u as Pr,b as Gl,n as Mo,ao as XO,v as YL,T as pt,ap as KL,x as dn,k as Ct,d as yb,A as $r,aq as ei,ar as Tt,as as XL,a8 as ft,B as Mt,q as ZO,C as JO,at as ZL,au as QO,e as $v,p as JL,av as e1,aw as t1,ax as ti,ay as Ne,H as U,az as QL,aA as eM,aB as tM,aC as zl,aD as rM,aE as nM,aF as aM,aG as iM,aH as r1,aI as oM,aJ as ql,aK as sM,aL as lM,aM as uM,aN as cM,ab as dM,aO as jv,l as pM,aP as fM,aQ as gM,I as hM,aR as mM,D as bM,_ as ir,aS as yM,aT as vM}from"./index-4e60c9e2.js";import{v as na,w as js,x as ic,y as n1,z as SM,G as EM,J as xM,K as Fv,L as Fs,Q as Tn,U as Bv,W as gs,X as a1,Y as wM,q as vb,Z as i1,_ as vn,$ as o1,f as s1,a0 as _M,u as Po,a1 as TM,a2 as Sb,a3 as Hl,a4 as AM,a5 as l1,a6 as u1,a7 as OM,P as kM,a8 as c1,a9 as RM,aa as IM,ab as NM,ac as CM,c as Eb,d as xb,ad as DM,ae as LM,af as MM,l as Pt,ag as d1,ah as PM,e as p1,ai as $M,b as $o,M as jM,V as FM,aj as BM,ak as UM,t as GM,al as f1,am as zM}from"./index-af5a3f81.js";import{c as qM,a as oc,C as Wl}from"./ClipLoader-8590c2f1.js";import{S as g1}from"./Skeleton-7af13a79.js";import{u as h1,P as wb,a as HM,F as WM}from"./Stack-5870980a.js";import{T as ri}from"./index-569670a3.js";import{S as VM,F as Uv,i as jo,g as yr,t as YM,_ as m1,a as KM,b as XM,c as ia,d as _b,e as ZM,f as JM,h as QM,j as Fo,m as eP,k as tP,l as rP,n as b1,o as nP,p as aP}from"./isPlainObject-1f2f9f4b.js";import{c as Tb}from"./createSvgIcon-c125a9c8.js";import{useBriefDescriptionStore as iP}from"./index-5c5c5836.js";import{P as we,p as oP}from"./index-37b3c15b.js";import{u as y1}from"./index-7fe50db2.js";const Gv="023d8eb306f0027b902fbdc81d33b49b6558b3434d374626f8c324979c92d47c21",sP=async e=>{let t=await xa.enable(!0);if(t||console.warn("Sphinx enable failed, means no pubkey and no budget (including budget of 0)"),t=await xa.keysend(Gv,e),!(t!=null&&t.success)){if(t=await xa.topup(),t||(t=await xa.authorize()),!(t!=null&&t.budget)||(t==null?void 0:t.budget){const r=await sP(t),n={amount:t,refid:e};return await WO.post("/boost",JSON.stringify(n)),r};function Ab(e){return e?String(e).replace(/[[]{2}/g,"").replace(/[\]]{2}/g,""):""}const uP=e=>{const[t,r]=e.split("-")||["",""];return parseInt(r,10)!==0?`${t} - ${r}`:t},v1=(e,t)=>{if(!t)return null;const r=e.filter(i=>i.show_title&&i.link&&i.show_title===t.show_title&&i.episode_title===t.episode_title),n=Pv.groupBy(r,i=>i.timestamp),a=Pv.values(n).reduce((i,o)=>(o[0]&&i.push(o[0]),i),[]);return a.sort((i,o)=>{var p,g;const[s]=((p=i.timestamp)==null?void 0:p.split("-"))||[""],[l]=((g=o.timestamp)==null?void 0:g.split("-"))||[""],c=na(s),d=na(l);return c-d}),a},cP=async e=>{await GL(async()=>{try{await xa.saveGraphData({metaData:{date:Math.floor(new Date().getTime()/1e3),...e},type:"second_brain_consumed_content"})}catch(t){console.warn(t)}})},dP=e=>{const t=/((http|https):\/\/[^\s]+)/g,r=/@(\w+)/g;let n=e.replace(/\\/g,"");return n=n.replace(/'/g,"’"),n=n.replace(/\n/g,"
"),n=n.replace(t,'$1'),n=n.replace(r,'@$1'),n},pP={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:-1,overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"},fP=pP;function gP(e,t,r=(n,a)=>n===a){return e.length===t.length&&e.every((n,a)=>r(n,t[a]))}const hP=2;function S1(e,t){return e-t}function hi(e,t,r){return e==null?t:Math.min(Math.max(t,e),r)}function zv(e,t){var r;const{index:n}=(r=e.reduce((a,i,o)=>{const s=Math.abs(t-i);return a===null||s({left:`${e}%`}),leap:e=>({width:`${e}%`})},"horizontal-reverse":{offset:e=>({right:`${e}%`}),leap:e=>({width:`${e}%`})},vertical:{offset:e=>({bottom:`${e}%`}),leap:e=>({height:`${e}%`})}},SP=e=>e;let ys;function sc(){return ys===void 0&&(typeof CSS<"u"&&typeof CSS.supports=="function"?ys=CSS.supports("touch-action","none"):ys=!0),ys}function EP(e){const{"aria-labelledby":t,defaultValue:r,disabled:n=!1,disableSwap:a=!1,isRtl:i=!1,marks:o=!1,max:s=100,min:l=0,name:c,onChange:d,onChangeCommitted:p,orientation:g="horizontal",rootRef:h,scale:b=SP,step:S=1,tabIndex:v,value:O}=e,_=M.useRef(),[w,A]=M.useState(-1),[x,E]=M.useState(-1),[k,N]=M.useState(!1),I=M.useRef(0),[D,L]=h1({controlled:O,default:r??l,name:"Slider"}),j=d&&((te,de,ye)=>{const ve=te.nativeEvent||te,ge=new ve.constructor(ve.type,ve);Object.defineProperty(ge,"target",{writable:!0,value:{value:de,name:c}}),d(ge,de,ye)}),q=Array.isArray(D);let H=q?D.slice().sort(S1):[D];H=H.map(te=>hi(te,l,s));const z=o===!0&&S!==null?[...Array(Math.floor((s-l)/S)+1)].map((te,de)=>({value:l+S*de})):o||[],W=z.map(te=>te.value),{isFocusVisibleRef:K,onBlur:G,onFocus:V,ref:J}=VO(),[ae,re]=M.useState(-1),ue=M.useRef(),Se=qs(J,ue),Q=qs(h,Se),Ie=te=>de=>{var ye;const ve=Number(de.currentTarget.getAttribute("data-index"));V(de),K.current===!0&&re(ve),E(ve),te==null||(ye=te.onFocus)==null||ye.call(te,de)},Ue=te=>de=>{var ye;G(de),K.current===!1&&re(-1),E(-1),te==null||(ye=te.onBlur)==null||ye.call(te,de)};zL(()=>{if(n&&ue.current.contains(document.activeElement)){var te;(te=document.activeElement)==null||te.blur()}},[n]),n&&w!==-1&&A(-1),n&&ae!==-1&&re(-1);const xe=te=>de=>{var ye;(ye=te.onChange)==null||ye.call(te,de);const ve=Number(de.currentTarget.getAttribute("data-index")),ge=H[ve],qe=W.indexOf(ge);let De=de.target.valueAsNumber;if(z&&S==null){const Ge=W[W.length-1];De>Ge?De=Ge:De{const{current:ye}=ue,{width:ve,height:ge,bottom:qe,left:De}=ye.getBoundingClientRect();let Ge;oe.indexOf("vertical")===0?Ge=(qe-te.y)/ge:Ge=(te.x-De)/ve,oe.indexOf("-reverse")!==-1&&(Ge=1-Ge);let Je;if(Je=mP(Ge,l,s),S)Je=yP(Je,S,l);else{const rr=zv(W,Je);Je=W[rr]}Je=hi(Je,l,s);let jt=0;if(q){de?jt=ee.current:jt=zv(H,Je),a&&(Je=hi(Je,H[jt-1]||-1/0,H[jt+1]||1/0));const rr=Je;Je=qv({values:H,newValue:Je,index:jt}),a&&de||(jt=Je.indexOf(rr),ee.current=jt)}return{newValue:Je,activeIndex:jt}},X=$s(te=>{const de=hs(te,_);if(!de)return;if(I.current+=1,te.type==="mousemove"&&te.buttons===0){Ee(te);return}const{newValue:ye,activeIndex:ve}=ie({finger:de,move:!0});ms({sliderRef:ue,activeIndex:ve,setActive:A}),L(ye),!k&&I.current>hP&&N(!0),j&&!bs(ye,D)&&j(te,ye,ve)}),Ee=$s(te=>{const de=hs(te,_);if(N(!1),!de)return;const{newValue:ye}=ie({finger:de,move:!0});A(-1),te.type==="touchend"&&E(-1),p&&p(te,ye),_.current=void 0,he()}),fe=$s(te=>{if(n)return;sc()||te.preventDefault();const de=te.changedTouches[0];de!=null&&(_.current=de.identifier);const ye=hs(te,_);if(ye!==!1){const{newValue:ge,activeIndex:qe}=ie({finger:ye});ms({sliderRef:ue,activeIndex:qe,setActive:A}),L(ge),j&&!bs(ge,D)&&j(te,ge,qe)}I.current=0;const ve=js(ue.current);ve.addEventListener("touchmove",X),ve.addEventListener("touchend",Ee)}),he=M.useCallback(()=>{const te=js(ue.current);te.removeEventListener("mousemove",X),te.removeEventListener("mouseup",Ee),te.removeEventListener("touchmove",X),te.removeEventListener("touchend",Ee)},[Ee,X]);M.useEffect(()=>{const{current:te}=ue;return te.addEventListener("touchstart",fe,{passive:sc()}),()=>{te.removeEventListener("touchstart",fe,{passive:sc()}),he()}},[he,fe]),M.useEffect(()=>{n&&he()},[n,he]);const je=te=>de=>{var ye;if((ye=te.onMouseDown)==null||ye.call(te,de),n||de.defaultPrevented||de.button!==0)return;de.preventDefault();const ve=hs(de,_);if(ve!==!1){const{newValue:qe,activeIndex:De}=ie({finger:ve});ms({sliderRef:ue,activeIndex:De,setActive:A}),L(qe),j&&!bs(qe,D)&&j(de,qe,De)}I.current=0;const ge=js(ue.current);ge.addEventListener("mousemove",X),ge.addEventListener("mouseup",Ee)},nt=Hs(q?H[0]:l,l,s),et=Hs(H[H.length-1],l,s)-nt,tr=(te={})=>{const de=ic(te),ye={onMouseDown:je(de||{})},ve=ce({},de,ye);return ce({},te,{ref:Q},ve)},Pe=te=>de=>{var ye;(ye=te.onMouseOver)==null||ye.call(te,de);const ve=Number(de.currentTarget.getAttribute("data-index"));E(ve)},$e=te=>de=>{var ye;(ye=te.onMouseLeave)==null||ye.call(te,de),E(-1)};return{active:w,axis:oe,axisProps:vP,dragging:k,focusedThumbIndex:ae,getHiddenInputProps:(te={})=>{var de;const ye=ic(te),ve={onChange:xe(ye||{}),onFocus:Ie(ye||{}),onBlur:Ue(ye||{})},ge=ce({},ye,ve);return ce({tabIndex:v,"aria-labelledby":t,"aria-orientation":g,"aria-valuemax":b(s),"aria-valuemin":b(l),name:c,type:"range",min:e.min,max:e.max,step:e.step===null&&e.marks?"any":(de=e.step)!=null?de:void 0,disabled:n},te,ge,{style:ce({},fP,{direction:i?"rtl":"ltr",width:"100%",height:"100%"})})},getRootProps:tr,getThumbProps:(te={})=>{const de=ic(te),ye={onMouseOver:Pe(de||{}),onMouseLeave:$e(de||{})};return ce({},te,de,ye)},marks:z,open:x,range:q,rootRef:Q,trackLeap:et,trackOffset:nt,values:H,getThumbStyle:te=>({pointerEvents:w!==-1&&w!==te?"none":void 0})}}const xP=Tb(m.jsx("path",{d:"M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"}),"CheckBoxOutlineBlank"),wP=Tb(m.jsx("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"}),"CheckBox"),_P=Tb(m.jsx("path",{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z"}),"IndeterminateCheckBox");function TP(e){return gb("MuiCheckbox",e)}const AP=fb("MuiCheckbox",["root","checked","disabled","indeterminate","colorPrimary","colorSecondary","sizeSmall","sizeMedium"]),lc=AP,OP=["checkedIcon","color","icon","indeterminate","indeterminateIcon","inputProps","size","className"],kP=e=>{const{classes:t,indeterminate:r,color:n,size:a}=e,i={root:["root",r&&"indeterminate",`color${Jt(n)}`,`size${Jt(a)}`]},o=mb(i,TP,t);return ce({},t,o)},RP=Mr(VM,{shouldForwardProp:e=>qL(e)||e==="classes",name:"MuiCheckbox",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.indeterminate&&t.indeterminate,t[`size${Jt(r.size)}`],r.color!=="default"&&t[`color${Jt(r.color)}`]]}})(({theme:e,ownerState:t})=>ce({color:(e.vars||e).palette.text.secondary},!t.disableRipple&&{"&:hover":{backgroundColor:e.vars?`rgba(${t.color==="default"?e.vars.palette.action.activeChannel:e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Hi(t.color==="default"?e.palette.action.active:e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},t.color!=="default"&&{[`&.${lc.checked}, &.${lc.indeterminate}`]:{color:(e.vars||e).palette[t.color].main},[`&.${lc.disabled}`]:{color:(e.vars||e).palette.action.disabled}})),IP=m.jsx(wP,{}),NP=m.jsx(xP,{}),CP=m.jsx(_P,{}),DP=M.forwardRef(function(t,r){var n,a;const i=hb({props:t,name:"MuiCheckbox"}),{checkedIcon:o=IP,color:s="primary",icon:l=NP,indeterminate:c=!1,indeterminateIcon:d=CP,inputProps:p,size:g="medium",className:h}=i,b=Fl(i,OP),S=c?d:l,v=c?d:o,O=ce({},i,{color:s,indeterminate:c,size:g}),_=kP(O);return m.jsx(RP,ce({type:"checkbox",inputProps:ce({"data-indeterminate":c},p),icon:M.cloneElement(S,{fontSize:(n=S.props.fontSize)!=null?n:g}),checkedIcon:M.cloneElement(v,{fontSize:(a=v.props.fontSize)!=null?a:g}),ownerState:O,ref:r,className:Cr(_.root,h)},b,{classes:_}))}),LP=DP,MP=["addEndListener","appear","children","container","direction","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function PP(e,t,r){const n=t.getBoundingClientRect(),a=r&&r.getBoundingClientRect(),i=n1(t);let o;if(t.fakeTransform)o=t.fakeTransform;else{const c=i.getComputedStyle(t);o=c.getPropertyValue("-webkit-transform")||c.getPropertyValue("transform")}let s=0,l=0;if(o&&o!=="none"&&typeof o=="string"){const c=o.split("(")[1].split(")")[0].split(",");s=parseInt(c[4],10),l=parseInt(c[5],10)}return e==="left"?a?`translateX(${a.right+s-n.left}px)`:`translateX(${i.innerWidth+s-n.left}px)`:e==="right"?a?`translateX(-${n.right-a.left-s}px)`:`translateX(-${n.left+n.width-s}px)`:e==="up"?a?`translateY(${a.bottom+l-n.top}px)`:`translateY(${i.innerHeight+l-n.top}px)`:a?`translateY(-${n.top-a.top+n.height-l}px)`:`translateY(-${n.top+n.height-l}px)`}function $P(e){return typeof e=="function"?e():e}function vs(e,t,r){const n=$P(r),a=PP(e,t,n);a&&(t.style.webkitTransform=a,t.style.transform=a)}const jP=M.forwardRef(function(t,r){const n=Bl(),a={enter:n.transitions.easing.easeOut,exit:n.transitions.easing.sharp},i={enter:n.transitions.duration.enteringScreen,exit:n.transitions.duration.leavingScreen},{addEndListener:o,appear:s=!0,children:l,container:c,direction:d="down",easing:p=a,in:g,onEnter:h,onEntered:b,onEntering:S,onExit:v,onExited:O,onExiting:_,style:w,timeout:A=i,TransitionComponent:x=SM}=t,E=Fl(t,MP),k=M.useRef(null),N=qs(l.ref,k,r),I=G=>V=>{G&&(V===void 0?G(k.current):G(k.current,V))},D=I((G,V)=>{vs(d,G,c),xM(G),h&&h(G,V)}),L=I((G,V)=>{const J=Fv({timeout:A,style:w,easing:p},{mode:"enter"});G.style.webkitTransition=n.transitions.create("-webkit-transform",ce({},J)),G.style.transition=n.transitions.create("transform",ce({},J)),G.style.webkitTransform="none",G.style.transform="none",S&&S(G,V)}),j=I(b),q=I(_),H=I(G=>{const V=Fv({timeout:A,style:w,easing:p},{mode:"exit"});G.style.webkitTransition=n.transitions.create("-webkit-transform",V),G.style.transition=n.transitions.create("transform",V),vs(d,G,c),v&&v(G)}),z=I(G=>{G.style.webkitTransition="",G.style.transition="",O&&O(G)}),W=G=>{o&&o(k.current,G)},K=M.useCallback(()=>{k.current&&vs(d,k.current,c)},[d,c]);return M.useEffect(()=>{if(g||d==="down"||d==="right")return;const G=EM(()=>{k.current&&vs(d,k.current,c)}),V=n1(k.current);return V.addEventListener("resize",G),()=>{G.clear(),V.removeEventListener("resize",G)}},[d,g,c]),M.useEffect(()=>{g||K()},[g,K]),m.jsx(x,ce({nodeRef:k,onEnter:D,onEntered:j,onEntering:L,onExit:H,onExited:z,onExiting:q,addEndListener:W,appear:s,in:g,timeout:A},E,{children:(G,V)=>M.cloneElement(l,ce({ref:N,style:ce({visibility:G==="exited"&&!g?"hidden":void 0},w,l.props.style)},V))}))}),Ca=jP,FP=e=>!e||!Fs(e),BP=FP;function UP(e){return gb("MuiSlider",e)}const GP=fb("MuiSlider",["root","active","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","disabled","dragging","focusVisible","mark","markActive","marked","markLabel","markLabelActive","rail","sizeSmall","thumb","thumbColorPrimary","thumbColorSecondary","thumbColorError","thumbColorSuccess","thumbColorInfo","thumbColorWarning","track","trackInverted","trackFalse","thumbSizeSmall","valueLabel","valueLabelOpen","valueLabelCircle","valueLabelLabel","vertical"]),Dr=GP,zP=e=>{const{open:t}=e;return{offset:Cr(t&&Dr.valueLabelOpen),circle:Dr.valueLabelCircle,label:Dr.valueLabelLabel}};function qP(e){const{children:t,className:r,value:n}=e,a=zP(e);return t?M.cloneElement(t,{className:Cr(t.props.className)},m.jsxs(M.Fragment,{children:[t.props.children,m.jsx("span",{className:Cr(a.offset,r),"aria-hidden":!0,children:m.jsx("span",{className:a.circle,children:m.jsx("span",{className:a.label,children:n})})})]})):null}const HP=["aria-label","aria-valuetext","aria-labelledby","component","components","componentsProps","color","classes","className","disableSwap","disabled","getAriaLabel","getAriaValueText","marks","max","min","name","onChange","onChangeCommitted","orientation","size","step","scale","slotProps","slots","tabIndex","track","value","valueLabelDisplay","valueLabelFormat"];function Hv(e){return e}const WP=Mr("span",{name:"MuiSlider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[`color${Jt(r.color)}`],r.size!=="medium"&&t[`size${Jt(r.size)}`],r.marked&&t.marked,r.orientation==="vertical"&&t.vertical,r.track==="inverted"&&t.trackInverted,r.track===!1&&t.trackFalse]}})(({theme:e,ownerState:t})=>ce({borderRadius:12,boxSizing:"content-box",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",color:(e.vars||e).palette[t.color].main,WebkitTapHighlightColor:"transparent"},t.orientation==="horizontal"&&ce({height:4,width:"100%",padding:"13px 0","@media (pointer: coarse)":{padding:"20px 0"}},t.size==="small"&&{height:2},t.marked&&{marginBottom:20}),t.orientation==="vertical"&&ce({height:"100%",width:4,padding:"0 13px","@media (pointer: coarse)":{padding:"0 20px"}},t.size==="small"&&{width:2},t.marked&&{marginRight:44}),{"@media print":{colorAdjust:"exact"},[`&.${Dr.disabled}`]:{pointerEvents:"none",cursor:"default",color:(e.vars||e).palette.grey[400]},[`&.${Dr.dragging}`]:{[`& .${Dr.thumb}, & .${Dr.track}`]:{transition:"none"}}})),VP=Mr("span",{name:"MuiSlider",slot:"Rail",overridesResolver:(e,t)=>t.rail})(({ownerState:e})=>ce({display:"block",position:"absolute",borderRadius:"inherit",backgroundColor:"currentColor",opacity:.38},e.orientation==="horizontal"&&{width:"100%",height:"inherit",top:"50%",transform:"translateY(-50%)"},e.orientation==="vertical"&&{height:"100%",width:"inherit",left:"50%",transform:"translateX(-50%)"},e.track==="inverted"&&{opacity:1})),YP=Mr("span",{name:"MuiSlider",slot:"Track",overridesResolver:(e,t)=>t.track})(({theme:e,ownerState:t})=>{const r=e.palette.mode==="light"?HL(e.palette[t.color].main,.62):WL(e.palette[t.color].main,.5);return ce({display:"block",position:"absolute",borderRadius:"inherit",border:"1px solid currentColor",backgroundColor:"currentColor",transition:e.transitions.create(["left","width","bottom","height"],{duration:e.transitions.duration.shortest})},t.size==="small"&&{border:"none"},t.orientation==="horizontal"&&{height:"inherit",top:"50%",transform:"translateY(-50%)"},t.orientation==="vertical"&&{width:"inherit",left:"50%",transform:"translateX(-50%)"},t.track===!1&&{display:"none"},t.track==="inverted"&&{backgroundColor:e.vars?e.vars.palette.Slider[`${t.color}Track`]:r,borderColor:e.vars?e.vars.palette.Slider[`${t.color}Track`]:r})}),KP=Mr("span",{name:"MuiSlider",slot:"Thumb",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.thumb,t[`thumbColor${Jt(r.color)}`],r.size!=="medium"&&t[`thumbSize${Jt(r.size)}`]]}})(({theme:e,ownerState:t})=>ce({position:"absolute",width:20,height:20,boxSizing:"border-box",borderRadius:"50%",outline:0,backgroundColor:"currentColor",display:"flex",alignItems:"center",justifyContent:"center",transition:e.transitions.create(["box-shadow","left","bottom"],{duration:e.transitions.duration.shortest})},t.size==="small"&&{width:12,height:12},t.orientation==="horizontal"&&{top:"50%",transform:"translate(-50%, -50%)"},t.orientation==="vertical"&&{left:"50%",transform:"translate(-50%, 50%)"},{"&:before":ce({position:"absolute",content:'""',borderRadius:"inherit",width:"100%",height:"100%",boxShadow:(e.vars||e).shadows[2]},t.size==="small"&&{boxShadow:"none"}),"&::after":{position:"absolute",content:'""',borderRadius:"50%",width:42,height:42,top:"50%",left:"50%",transform:"translate(-50%, -50%)"},[`&:hover, &.${Dr.focusVisible}`]:{boxShadow:`0px 0px 0px 8px ${e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / 0.16)`:Hi(e.palette[t.color].main,.16)}`,"@media (hover: none)":{boxShadow:"none"}},[`&.${Dr.active}`]:{boxShadow:`0px 0px 0px 14px ${e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / 0.16)`:Hi(e.palette[t.color].main,.16)}`},[`&.${Dr.disabled}`]:{"&:hover":{boxShadow:"none"}}})),XP=Mr(qP,{name:"MuiSlider",slot:"ValueLabel",overridesResolver:(e,t)=>t.valueLabel})(({theme:e,ownerState:t})=>ce({[`&.${Dr.valueLabelOpen}`]:{transform:`${t.orientation==="vertical"?"translateY(-50%)":"translateY(-100%)"} scale(1)`},zIndex:1,whiteSpace:"nowrap"},e.typography.body2,{fontWeight:500,transition:e.transitions.create(["transform"],{duration:e.transitions.duration.shortest}),transform:`${t.orientation==="vertical"?"translateY(-50%)":"translateY(-100%)"} scale(0)`,position:"absolute",backgroundColor:(e.vars||e).palette.grey[600],borderRadius:2,color:(e.vars||e).palette.common.white,display:"flex",alignItems:"center",justifyContent:"center",padding:"0.25rem 0.75rem"},t.orientation==="horizontal"&&{top:"-10px",transformOrigin:"bottom center","&:before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, 50%) rotate(45deg)",backgroundColor:"inherit",bottom:0,left:"50%"}},t.orientation==="vertical"&&{right:t.size==="small"?"20px":"30px",top:"50%",transformOrigin:"right center","&:before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, -50%) rotate(45deg)",backgroundColor:"inherit",right:-8,top:"50%"}},t.size==="small"&&{fontSize:e.typography.pxToRem(12),padding:"0.25rem 0.5rem"})),ZP=Mr("span",{name:"MuiSlider",slot:"Mark",shouldForwardProp:e=>YO(e)&&e!=="markActive",overridesResolver:(e,t)=>{const{markActive:r}=e;return[t.mark,r&&t.markActive]}})(({theme:e,ownerState:t,markActive:r})=>ce({position:"absolute",width:2,height:2,borderRadius:1,backgroundColor:"currentColor"},t.orientation==="horizontal"&&{top:"50%",transform:"translate(-1px, -50%)"},t.orientation==="vertical"&&{left:"50%",transform:"translate(-50%, 1px)"},r&&{backgroundColor:(e.vars||e).palette.background.paper,opacity:.8})),JP=Mr("span",{name:"MuiSlider",slot:"MarkLabel",shouldForwardProp:e=>YO(e)&&e!=="markLabelActive",overridesResolver:(e,t)=>t.markLabel})(({theme:e,ownerState:t,markLabelActive:r})=>ce({},e.typography.body2,{color:(e.vars||e).palette.text.secondary,position:"absolute",whiteSpace:"nowrap"},t.orientation==="horizontal"&&{top:30,transform:"translateX(-50%)","@media (pointer: coarse)":{top:40}},t.orientation==="vertical"&&{left:36,transform:"translateY(50%)","@media (pointer: coarse)":{left:44}},r&&{color:(e.vars||e).palette.text.primary})),QP=e=>{const{disabled:t,dragging:r,marked:n,orientation:a,track:i,classes:o,color:s,size:l}=e,c={root:["root",t&&"disabled",r&&"dragging",n&&"marked",a==="vertical"&&"vertical",i==="inverted"&&"trackInverted",i===!1&&"trackFalse",s&&`color${Jt(s)}`,l&&`size${Jt(l)}`],rail:["rail"],track:["track"],mark:["mark"],markActive:["markActive"],markLabel:["markLabel"],markLabelActive:["markLabelActive"],valueLabel:["valueLabel"],thumb:["thumb",t&&"disabled",l&&`thumbSize${Jt(l)}`,s&&`thumbColor${Jt(s)}`],active:["active"],disabled:["disabled"],focusVisible:["focusVisible"]};return mb(c,UP,o)},e$=({children:e})=>e,t$=M.forwardRef(function(t,r){var n,a,i,o,s,l,c,d,p,g,h,b,S,v,O,_,w,A,x,E,k,N,I,D;const L=hb({props:t,name:"MuiSlider"}),q=Bl().direction==="rtl",{"aria-label":H,"aria-valuetext":z,"aria-labelledby":W,component:K="span",components:G={},componentsProps:V={},color:J="primary",classes:ae,className:re,disableSwap:ue=!1,disabled:Se=!1,getAriaLabel:Q,getAriaValueText:Ie,marks:Ue=!1,max:xe=100,min:ee=0,orientation:oe="horizontal",size:ie="medium",step:X=1,scale:Ee=Hv,slotProps:fe,slots:he,track:je="normal",valueLabelDisplay:nt="off",valueLabelFormat:et=Hv}=L,tr=Fl(L,HP),Pe=ce({},L,{isRtl:q,max:xe,min:ee,classes:ae,disabled:Se,disableSwap:ue,orientation:oe,marks:Ue,color:J,size:ie,step:X,scale:Ee,track:je,valueLabelDisplay:nt,valueLabelFormat:et}),{axisProps:$e,getRootProps:Ye,getHiddenInputProps:$t,getThumbProps:Kt,open:te,active:de,axis:ye,focusedThumbIndex:ve,range:ge,dragging:qe,marks:De,values:Ge,trackOffset:Je,trackLeap:jt,getThumbStyle:rr}=EP(ce({},Pe,{rootRef:r}));Pe.marked=De.length>0&&De.some(_e=>_e.label),Pe.dragging=qe,Pe.focusedThumbIndex=ve;const ze=QP(Pe),Kr=(n=(a=he==null?void 0:he.root)!=null?a:G.Root)!=null?n:WP,Xr=(i=(o=he==null?void 0:he.rail)!=null?o:G.Rail)!=null?i:VP,Zr=(s=(l=he==null?void 0:he.track)!=null?l:G.Track)!=null?s:YP,He=(c=(d=he==null?void 0:he.thumb)!=null?d:G.Thumb)!=null?c:KP,Bn=(p=(g=he==null?void 0:he.valueLabel)!=null?g:G.ValueLabel)!=null?p:XP,Jr=(h=(b=he==null?void 0:he.mark)!=null?b:G.Mark)!=null?h:ZP,xr=(S=(v=he==null?void 0:he.markLabel)!=null?v:G.MarkLabel)!=null?S:JP,Qr=(O=(_=he==null?void 0:he.input)!=null?_:G.Input)!=null?O:"input",wr=(w=fe==null?void 0:fe.root)!=null?w:V.root,_r=(A=fe==null?void 0:fe.rail)!=null?A:V.rail,Tr=(x=fe==null?void 0:fe.track)!=null?x:V.track,Un=(E=fe==null?void 0:fe.thumb)!=null?E:V.thumb,Fr=(k=fe==null?void 0:fe.valueLabel)!=null?k:V.valueLabel,li=(N=fe==null?void 0:fe.mark)!=null?N:V.mark,Ar=(I=fe==null?void 0:fe.markLabel)!=null?I:V.markLabel,En=(D=fe==null?void 0:fe.input)!=null?D:V.input,le=Tn({elementType:Kr,getSlotProps:Ye,externalSlotProps:wr,externalForwardedProps:tr,additionalProps:ce({},BP(Kr)&&{as:K}),ownerState:ce({},Pe,wr==null?void 0:wr.ownerState),className:[ze.root,re]}),Gn=Tn({elementType:Xr,externalSlotProps:_r,ownerState:Pe,className:ze.rail}),Ft=Tn({elementType:Zr,externalSlotProps:Tr,additionalProps:{style:ce({},$e[ye].offset(Je),$e[ye].leap(jt))},ownerState:ce({},Pe,Tr==null?void 0:Tr.ownerState),className:ze.track}),ut=Tn({elementType:He,getSlotProps:Kt,externalSlotProps:Un,ownerState:ce({},Pe,Un==null?void 0:Un.ownerState),className:ze.thumb}),zn=Tn({elementType:Bn,externalSlotProps:Fr,ownerState:ce({},Pe,Fr==null?void 0:Fr.ownerState),className:ze.valueLabel}),Oe=Tn({elementType:Jr,externalSlotProps:li,ownerState:Pe,className:ze.mark}),nr=Tn({elementType:xr,externalSlotProps:Ar,ownerState:Pe,className:ze.markLabel}),da=Tn({elementType:Qr,getSlotProps:$t,externalSlotProps:En,ownerState:Pe});return m.jsxs(Kr,ce({},le,{children:[m.jsx(Xr,ce({},Gn)),m.jsx(Zr,ce({},Ft)),De.filter(_e=>_e.value>=ee&&_e.value<=xe).map((_e,We)=>{const kt=Hs(_e.value,ee,xe),tt=$e[ye].offset(kt);let ct;return je===!1?ct=Ge.indexOf(_e.value)!==-1:ct=je==="normal"&&(ge?_e.value>=Ge[0]&&_e.value<=Ge[Ge.length-1]:_e.value<=Ge[0])||je==="inverted"&&(ge?_e.value<=Ge[0]||_e.value>=Ge[Ge.length-1]:_e.value>=Ge[0]),m.jsxs(M.Fragment,{children:[m.jsx(Jr,ce({"data-index":We},Oe,!Fs(Jr)&&{markActive:ct},{style:ce({},tt,Oe.style),className:Cr(Oe.className,ct&&ze.markActive)})),_e.label!=null?m.jsx(xr,ce({"aria-hidden":!0,"data-index":We},nr,!Fs(xr)&&{markLabelActive:ct},{style:ce({},tt,nr.style),className:Cr(ze.markLabel,nr.className,ct&&ze.markLabelActive),children:_e.label})):null]},We)}),Ge.map((_e,We)=>{const kt=Hs(_e,ee,xe),tt=$e[ye].offset(kt),ct=nt==="off"?e$:Bn;return m.jsx(ct,ce({},!Fs(ct)&&{valueLabelFormat:et,valueLabelDisplay:nt,value:typeof et=="function"?et(Ee(_e),We):et,index:We,open:te===We||de===We||nt==="on",disabled:Se},zn,{children:m.jsx(He,ce({"data-index":We},ut,{className:Cr(ze.thumb,ut.className,de===We&&ze.active,ve===We&&ze.focusVisible),style:ce({},tt,rr(We),ut.style),children:m.jsx(Qr,ce({"data-index":We,"aria-label":Q?Q(We):H,"aria-valuenow":Ee(_e),"aria-labelledby":W,"aria-valuetext":Ie?Ie(Ee(_e),We):z,value:Ge[We]},da))}))}),We)})]}))}),Vl=t$;function r$(e){return gb("MuiTooltip",e)}const n$=fb("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]),Nn=n$,a$=["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"];function i$(e){return Math.round(e*1e5)/1e5}const o$=e=>{const{classes:t,disableInteractive:r,arrow:n,touch:a,placement:i}=e,o={popper:["popper",!r&&"popperInteractive",n&&"popperArrow"],tooltip:["tooltip",n&&"tooltipArrow",a&&"touch",`tooltipPlacement${Jt(i.split("-")[0])}`],arrow:["arrow"]};return mb(o,r$,t)},s$=Mr(wb,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.popper,!r.disableInteractive&&t.popperInteractive,r.arrow&&t.popperArrow,!r.open&&t.popperClose]}})(({theme:e,ownerState:t,open:r})=>ce({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none"},!t.disableInteractive&&{pointerEvents:"auto"},!r&&{pointerEvents:"none"},t.arrow&&{[`&[data-popper-placement*="bottom"] .${Nn.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${Nn.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${Nn.arrow}`]:ce({},t.isRtl?{right:0,marginRight:"-0.71em"}:{left:0,marginLeft:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}}),[`&[data-popper-placement*="left"] .${Nn.arrow}`]:ce({},t.isRtl?{left:0,marginLeft:"-0.71em"}:{right:0,marginRight:"-0.71em"},{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}})})),l$=Mr("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.tooltip,r.touch&&t.touch,r.arrow&&t.tooltipArrow,t[`tooltipPlacement${Jt(r.placement.split("-")[0])}`]]}})(({theme:e,ownerState:t})=>ce({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:Hi(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium},t.arrow&&{position:"relative",margin:0},t.touch&&{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${i$(16/14)}em`,fontWeight:e.typography.fontWeightRegular},{[`.${Nn.popper}[data-popper-placement*="left"] &`]:ce({transformOrigin:"right center"},t.isRtl?ce({marginLeft:"14px"},t.touch&&{marginLeft:"24px"}):ce({marginRight:"14px"},t.touch&&{marginRight:"24px"})),[`.${Nn.popper}[data-popper-placement*="right"] &`]:ce({transformOrigin:"left center"},t.isRtl?ce({marginRight:"14px"},t.touch&&{marginRight:"24px"}):ce({marginLeft:"14px"},t.touch&&{marginLeft:"24px"})),[`.${Nn.popper}[data-popper-placement*="top"] &`]:ce({transformOrigin:"center bottom",marginBottom:"14px"},t.touch&&{marginBottom:"24px"}),[`.${Nn.popper}[data-popper-placement*="bottom"] &`]:ce({transformOrigin:"center top",marginTop:"14px"},t.touch&&{marginTop:"24px"})})),u$=Mr("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:Hi(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}}));let Ss=!1,uc=null,mi={x:0,y:0};function Es(e,t){return r=>{t&&t(r),e(r)}}const c$=M.forwardRef(function(t,r){var n,a,i,o,s,l,c,d,p,g,h,b,S,v,O,_,w,A,x;const E=hb({props:t,name:"MuiTooltip"}),{arrow:k=!1,children:N,components:I={},componentsProps:D={},describeChild:L=!1,disableFocusListener:j=!1,disableHoverListener:q=!1,disableInteractive:H=!1,disableTouchListener:z=!1,enterDelay:W=100,enterNextDelay:K=0,enterTouchDelay:G=700,followCursor:V=!1,id:J,leaveDelay:ae=0,leaveTouchDelay:re=1500,onClose:ue,onOpen:Se,open:Q,placement:Ie="bottom",PopperComponent:Ue,PopperProps:xe={},slotProps:ee={},slots:oe={},title:ie,TransitionComponent:X=Bv,TransitionProps:Ee}=E,fe=Fl(E,a$),he=M.isValidElement(N)?N:m.jsx("span",{children:N}),je=Bl(),nt=je.direction==="rtl",[et,tr]=M.useState(),[Pe,$e]=M.useState(null),Ye=M.useRef(!1),$t=H||V,Kt=M.useRef(),te=M.useRef(),de=M.useRef(),ye=M.useRef(),[ve,ge]=h1({controlled:Q,default:!1,name:"Tooltip",state:"open"});let qe=ve;const De=HM(J),Ge=M.useRef(),Je=M.useCallback(()=>{Ge.current!==void 0&&(document.body.style.WebkitUserSelect=Ge.current,Ge.current=void 0),clearTimeout(ye.current)},[]);M.useEffect(()=>()=>{clearTimeout(Kt.current),clearTimeout(te.current),clearTimeout(de.current),Je()},[Je]);const jt=ke=>{clearTimeout(uc),Ss=!0,ge(!0),Se&&!qe&&Se(ke)},rr=$s(ke=>{clearTimeout(uc),uc=setTimeout(()=>{Ss=!1},800+ae),ge(!1),ue&&qe&&ue(ke),clearTimeout(Kt.current),Kt.current=setTimeout(()=>{Ye.current=!1},je.transitions.duration.shortest)}),ze=ke=>{Ye.current&&ke.type!=="touchstart"||(et&&et.removeAttribute("title"),clearTimeout(te.current),clearTimeout(de.current),W||Ss&&K?te.current=setTimeout(()=>{jt(ke)},Ss?K:W):jt(ke))},Kr=ke=>{clearTimeout(te.current),clearTimeout(de.current),de.current=setTimeout(()=>{rr(ke)},ae)},{isFocusVisibleRef:Xr,onBlur:Zr,onFocus:He,ref:Bn}=VO(),[,Jr]=M.useState(!1),xr=ke=>{Zr(ke),Xr.current===!1&&(Jr(!1),Kr(ke))},Qr=ke=>{et||tr(ke.currentTarget),He(ke),Xr.current===!0&&(Jr(!0),ze(ke))},wr=ke=>{Ye.current=!0;const Bt=he.props;Bt.onTouchStart&&Bt.onTouchStart(ke)},_r=ze,Tr=Kr,Un=ke=>{wr(ke),clearTimeout(de.current),clearTimeout(Kt.current),Je(),Ge.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",ye.current=setTimeout(()=>{document.body.style.WebkitUserSelect=Ge.current,ze(ke)},G)},Fr=ke=>{he.props.onTouchEnd&&he.props.onTouchEnd(ke),Je(),clearTimeout(de.current),de.current=setTimeout(()=>{rr(ke)},re)};M.useEffect(()=>{if(!qe)return;function ke(Bt){(Bt.key==="Escape"||Bt.key==="Esc")&&rr(Bt)}return document.addEventListener("keydown",ke),()=>{document.removeEventListener("keydown",ke)}},[rr,qe]);const li=qs(he.ref,Bn,tr,r);!ie&&ie!==0&&(qe=!1);const Ar=M.useRef(),En=ke=>{const Bt=he.props;Bt.onMouseMove&&Bt.onMouseMove(ke),mi={x:ke.clientX,y:ke.clientY},Ar.current&&Ar.current.update()},le={},Gn=typeof ie=="string";L?(le.title=!qe&&Gn&&!q?ie:null,le["aria-describedby"]=qe?De:null):(le["aria-label"]=Gn?ie:null,le["aria-labelledby"]=qe&&!Gn?De:null);const Ft=ce({},le,fe,he.props,{className:Cr(fe.className,he.props.className),onTouchStart:wr,ref:li},V?{onMouseMove:En}:{}),ut={};z||(Ft.onTouchStart=Un,Ft.onTouchEnd=Fr),q||(Ft.onMouseOver=Es(_r,Ft.onMouseOver),Ft.onMouseLeave=Es(Tr,Ft.onMouseLeave),$t||(ut.onMouseOver=_r,ut.onMouseLeave=Tr)),j||(Ft.onFocus=Es(Qr,Ft.onFocus),Ft.onBlur=Es(xr,Ft.onBlur),$t||(ut.onFocus=Qr,ut.onBlur=xr));const zn=M.useMemo(()=>{var ke;let Bt=[{name:"arrow",enabled:!!Pe,options:{element:Pe,padding:4}}];return(ke=xe.popperOptions)!=null&&ke.modifiers&&(Bt=Bt.concat(xe.popperOptions.modifiers)),ce({},xe.popperOptions,{modifiers:Bt})},[Pe,xe]),Oe=ce({},E,{isRtl:nt,arrow:k,disableInteractive:$t,placement:Ie,PopperComponentProp:Ue,touch:Ye.current}),nr=o$(Oe),da=(n=(a=oe.popper)!=null?a:I.Popper)!=null?n:s$,_e=(i=(o=(s=oe.transition)!=null?s:I.Transition)!=null?o:X)!=null?i:Bv,We=(l=(c=oe.tooltip)!=null?c:I.Tooltip)!=null?l:l$,kt=(d=(p=oe.arrow)!=null?p:I.Arrow)!=null?d:u$,tt=gs(da,ce({},xe,(g=ee.popper)!=null?g:D.popper,{className:Cr(nr.popper,xe==null?void 0:xe.className,(h=(b=ee.popper)!=null?b:D.popper)==null?void 0:h.className)}),Oe),ct=gs(_e,ce({},Ee,(S=ee.transition)!=null?S:D.transition),Oe),Or=gs(We,ce({},(v=ee.tooltip)!=null?v:D.tooltip,{className:Cr(nr.tooltip,(O=(_=ee.tooltip)!=null?_:D.tooltip)==null?void 0:O.className)}),Oe),en=gs(kt,ce({},(w=ee.arrow)!=null?w:D.arrow,{className:Cr(nr.arrow,(A=(x=ee.arrow)!=null?x:D.arrow)==null?void 0:A.className)}),Oe);return m.jsxs(M.Fragment,{children:[M.cloneElement(he,Ft),m.jsx(da,ce({as:Ue??wb,placement:Ie,anchorEl:V?{getBoundingClientRect:()=>({top:mi.y,left:mi.x,right:mi.x,bottom:mi.y,width:0,height:0})}:et,popperRef:Ar,open:et?qe:!1,id:De,transition:!0},ut,tt,{popperOptions:zn,children:({TransitionProps:ke})=>m.jsx(_e,ce({timeout:je.transitions.duration.shorter},ke,ct,{children:m.jsxs(We,ce({},Or,{children:[ie,k?m.jsx(kt,ce({},en,{ref:$e})):null]}))}))}))]})}),d$=c$,p$=(e,t="down")=>{const r=Bl(),[n,a]=M.useState(!1),i=r.breakpoints[t](e).split("@media")[1].trim();return M.useEffect(()=>{const o=()=>{const{matches:s}=window.matchMedia(i);a(s)};return o(),window.addEventListener("resize",o),()=>window.removeEventListener("resize",o)},[i]),n},f$=e=>e.filter(t=>t.tldr).length>=2&&e.some(t=>t.audio_EN);function g$(e){return e.tldr_topic??e.name}var Ws=globalThis&&globalThis.__assign||function(){return Ws=Object.assign||function(e){for(var t,r=1,n=arguments.length;r({autoCorrect:"off",autoComplete:"off"}))` pointer-events: auto; height: 48px; padding: 0 40px 0 18px; @@ -1909,7 +1909,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho `,xoe=B.audio` height: 0; width: 0; -`,woe=()=>{const e=Pt(),{setPlayingNode:t}=$o(r=>r);switch(M.useEffect(()=>{var n,a;if(!e)return;(e.media_url||e.link||((n=e.properties)==null?void 0:n.link)||((a=e.properties)==null?void 0:a.media_url))&&t(e)},[t,e]),e==null?void 0:e.node_type){case"guest":case"person":return m.jsx(c7,{});case"data_series":return m.jsx(uX,{});case"tribe_message":return m.jsx(o7,{});case"Tweet":return m.jsx(S7,{});case"topic":return m.jsx(v7,{});case"show":return m.jsx(y7,{});case"video":case"podcast":case"clip":case"twitter_space":return m.jsx(XR,{});case"document":return m.jsx(boe,{});case"episode":return m.jsx(t7,{},e.ref_id);case"image":return m.jsx(i7,{});default:return m.jsx(noe,{})}},_oe=M.memo(woe);var Toe=function(t,r,n){var a=document.head||document.getElementsByTagName("head")[0],i=document.createElement("script");typeof r=="function"&&(n=r,r={}),r=r||{},n=n||function(){},i.type=r.type||"text/javascript",i.charset=r.charset||"utf8",i.async="async"in r?!!r.async:!0,i.src=t,r.attrs&&Aoe(i,r.attrs),r.text&&(i.text=""+r.text);var o="onload"in i?jO:Ooe;o(i,n),i.onload||jO(i,n),a.appendChild(i)};function Aoe(e,t){for(var r in t)e.setAttribute(r,t[r])}function jO(e,t){e.onload=function(){this.onerror=this.onload=null,t(null,e)},e.onerror=function(){this.onerror=this.onload=null,t(new Error("Failed to load "+this.src),e)}}function Ooe(e,t){e.onreadystatechange=function(){this.readyState!="complete"&&this.readyState!="loaded"||(this.onreadystatechange=null,t(null,e))}}var koe=function(t){return Roe(t)&&!Ioe(t)};function Roe(e){return!!e&&typeof e=="object"}function Ioe(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||Doe(e)}var Noe=typeof Symbol=="function"&&Symbol.for,Coe=Noe?Symbol.for("react.element"):60103;function Doe(e){return e.$$typeof===Coe}function Loe(e){return Array.isArray(e)?[]:{}}function Lo(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Qa(Loe(e),e,t):e}function Moe(e,t,r){return e.concat(t).map(function(n){return Lo(n,r)})}function Poe(e,t){if(!t.customMerge)return Qa;var r=t.customMerge(e);return typeof r=="function"?r:Qa}function $oe(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function FO(e){return Object.keys(e).concat($oe(e))}function DI(e,t){try{return t in e}catch{return!1}}function joe(e,t){return DI(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function Foe(e,t,r){var n={};return r.isMergeableObject(e)&&FO(e).forEach(function(a){n[a]=Lo(e[a],r)}),FO(t).forEach(function(a){joe(e,a)||(DI(e,a)&&r.isMergeableObject(t[a])?n[a]=Poe(a,r)(e[a],t[a],r):n[a]=Lo(t[a],r))}),n}function Qa(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||Moe,r.isMergeableObject=r.isMergeableObject||koe,r.cloneUnlessOtherwiseSpecified=Lo;var n=Array.isArray(t),a=Array.isArray(e),i=n===a;return i?n?r.arrayMerge(e,t,r):Foe(e,t,r):Lo(t,r)}Qa.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(n,a){return Qa(n,a,r)},{})};var Boe=Qa,LI=Boe,Uoe=Object.create,$u=Object.defineProperty,Goe=Object.getOwnPropertyDescriptor,zoe=Object.getOwnPropertyNames,qoe=Object.getPrototypeOf,Hoe=Object.prototype.hasOwnProperty,Woe=(e,t)=>{for(var r in t)$u(e,r,{get:t[r],enumerable:!0})},MI=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of zoe(t))!Hoe.call(e,a)&&a!==r&&$u(e,a,{get:()=>t[a],enumerable:!(n=Goe(t,a))||n.enumerable});return e},Vy=(e,t,r)=>(r=e!=null?Uoe(qoe(e)):{},MI(t||!e||!e.__esModule?$u(r,"default",{value:e,enumerable:!0}):r,e)),Voe=e=>MI($u({},"__esModule",{value:!0}),e),PI={};Woe(PI,{callPlayer:()=>use,getConfig:()=>sse,getSDK:()=>ose,isBlobUrl:()=>dse,isMediaStream:()=>cse,lazy:()=>Zoe,omit:()=>lse,parseEndTime:()=>nse,parseStartTime:()=>rse,queryString:()=>ise,randomString:()=>ase,supportsWebKitPresentationMode:()=>pse});var ju=Voe(PI),Yoe=Vy(M),Koe=Vy(Toe),Xoe=Vy(LI);const Zoe=e=>Yoe.default.lazy(async()=>{const t=await e();return typeof t.default=="function"?t:t.default}),Joe=/[?&#](?:start|t)=([0-9hms]+)/,Qoe=/[?&#]end=([0-9hms]+)/,ub=/(\d+)(h|m|s)/g,ese=/^\d+$/;function $I(e,t){if(e instanceof Array)return;const r=e.match(t);if(r){const n=r[1];if(n.match(ub))return tse(n);if(ese.test(n))return parseInt(n)}}function tse(e){let t=0,r=ub.exec(e);for(;r!==null;){const[,n,a]=r;a==="h"&&(t+=parseInt(n,10)*60*60),a==="m"&&(t+=parseInt(n,10)*60),a==="s"&&(t+=parseInt(n,10)),r=ub.exec(e)}return t}function rse(e){return $I(e,Joe)}function nse(e){return $I(e,Qoe)}function ase(){return Math.random().toString(36).substr(2,5)}function ise(e){return Object.keys(e).map(t=>`${t}=${e[t]}`).join("&")}function Hh(e){return window[e]?window[e]:window.exports&&window.exports[e]?window.exports[e]:window.module&&window.module.exports&&window.module.exports[e]?window.module.exports[e]:null}const Sa={},ose=function(t,r,n=null,a=()=>!0,i=Koe.default){const o=Hh(r);return o&&a(o)?Promise.resolve(o):new Promise((s,l)=>{if(Sa[t]){Sa[t].push({resolve:s,reject:l});return}Sa[t]=[{resolve:s,reject:l}];const c=d=>{Sa[t].forEach(p=>p.resolve(d))};if(n){const d=window[n];window[n]=function(){d&&d(),c(Hh(r))}}i(t,d=>{d?(Sa[t].forEach(p=>p.reject(d)),Sa[t]=null):n||c(Hh(r))})})};function sse(e,t){return(0,Xoe.default)(t.config,e.config)}function lse(e,...t){const r=[].concat(...t),n={},a=Object.keys(e);for(const i of a)r.indexOf(i)===-1&&(n[i]=e[i]);return n}function use(e,...t){if(!this.player||!this.player[e]){let r=`ReactPlayer: ${this.constructor.displayName} player could not call %c${e}%c – `;return this.player?this.player[e]||(r+="The method was not available"):r+="The player was not available",console.warn(r,"font-weight: bold",""),null}return this.player[e](...t)}function cse(e){return typeof window<"u"&&typeof window.MediaStream<"u"&&e instanceof window.MediaStream}function dse(e){return/^blob:/.test(e)}function pse(e=document.createElement("video")){const t=/iPhone|iPod/.test(navigator.userAgent)===!1;return e.webkitSupportsPresentationMode&&typeof e.webkitSetPresentationMode=="function"&&t}var Yy=Object.defineProperty,fse=Object.getOwnPropertyDescriptor,gse=Object.getOwnPropertyNames,hse=Object.prototype.hasOwnProperty,mse=(e,t)=>{for(var r in t)Yy(e,r,{get:t[r],enumerable:!0})},bse=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of gse(t))!hse.call(e,a)&&a!==r&&Yy(e,a,{get:()=>t[a],enumerable:!(n=fse(t,a))||n.enumerable});return e},yse=e=>bse(Yy({},"__esModule",{value:!0}),e),jI={};mse(jI,{AUDIO_EXTENSIONS:()=>Ky,DASH_EXTENSIONS:()=>ZI,FLV_EXTENSIONS:()=>JI,HLS_EXTENSIONS:()=>Zy,MATCH_URL_DAILYMOTION:()=>VI,MATCH_URL_FACEBOOK:()=>UI,MATCH_URL_FACEBOOK_WATCH:()=>GI,MATCH_URL_KALTURA:()=>XI,MATCH_URL_MIXCLOUD:()=>YI,MATCH_URL_SOUNDCLOUD:()=>FI,MATCH_URL_STREAMABLE:()=>zI,MATCH_URL_TWITCH_CHANNEL:()=>WI,MATCH_URL_TWITCH_VIDEO:()=>HI,MATCH_URL_VIDYARD:()=>KI,MATCH_URL_VIMEO:()=>BI,MATCH_URL_WISTIA:()=>qI,MATCH_URL_YOUTUBE:()=>cb,VIDEO_EXTENSIONS:()=>Xy,canPlay:()=>Sse});var vse=yse(jI),BO=ju;const cb=/(?:youtu\.be\/|youtube(?:-nocookie|education)?\.com\/(?:embed\/|v\/|watch\/|watch\?v=|watch\?.+&v=|shorts\/|live\/))((\w|-){11})|youtube\.com\/playlist\?list=|youtube\.com\/user\//,FI=/(?:soundcloud\.com|snd\.sc)\/[^.]+$/,BI=/vimeo\.com\/(?!progressive_redirect).+/,UI=/^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/,GI=/^https?:\/\/fb\.watch\/.+$/,zI=/streamable\.com\/([a-z0-9]+)$/,qI=/(?:wistia\.(?:com|net)|wi\.st)\/(?:medias|embed)\/(?:iframe\/)?([^?]+)/,HI=/(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/,WI=/(?:www\.|go\.)?twitch\.tv\/([a-zA-Z0-9_]+)($|\?)/,VI=/^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?(?:[\w.#_-]+)?/,YI=/mixcloud\.com\/([^/]+\/[^/]+)/,KI=/vidyard.com\/(?:watch\/)?([a-zA-Z0-9-_]+)/,XI=/^https?:\/\/[a-zA-Z]+\.kaltura.(com|org)\/p\/([0-9]+)\/sp\/([0-9]+)00\/embedIframeJs\/uiconf_id\/([0-9]+)\/partner_id\/([0-9]+)(.*)entry_id.([a-zA-Z0-9-_].*)$/,Ky=/\.(m4a|m4b|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i,Xy=/\.(mp4|og[gv]|webm|mov|m4v)(#t=[,\d+]+)?($|\?)/i,Zy=/\.(m3u8)($|\?)/i,ZI=/\.(mpd)($|\?)/i,JI=/\.(flv)($|\?)/i,db=e=>{if(e instanceof Array){for(const t of e)if(typeof t=="string"&&db(t)||db(t.src))return!0;return!1}return(0,BO.isMediaStream)(e)||(0,BO.isBlobUrl)(e)?!0:Ky.test(e)||Xy.test(e)||Zy.test(e)||ZI.test(e)||JI.test(e)},Sse={youtube:e=>e instanceof Array?e.every(t=>cb.test(t)):cb.test(e),soundcloud:e=>FI.test(e)&&!Ky.test(e),vimeo:e=>BI.test(e)&&!Xy.test(e)&&!Zy.test(e),facebook:e=>UI.test(e)||GI.test(e),streamable:e=>zI.test(e),wistia:e=>qI.test(e),twitch:e=>HI.test(e)||WI.test(e),dailymotion:e=>VI.test(e),mixcloud:e=>YI.test(e),vidyard:e=>KI.test(e),kaltura:e=>XI.test(e),file:db};var Jy=Object.defineProperty,Ese=Object.getOwnPropertyDescriptor,xse=Object.getOwnPropertyNames,wse=Object.prototype.hasOwnProperty,_se=(e,t)=>{for(var r in t)Jy(e,r,{get:t[r],enumerable:!0})},Tse=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of xse(t))!wse.call(e,a)&&a!==r&&Jy(e,a,{get:()=>t[a],enumerable:!(n=Ese(t,a))||n.enumerable});return e},Ase=e=>Tse(Jy({},"__esModule",{value:!0}),e),QI={};_se(QI,{default:()=>kse});var Ose=Ase(QI),ar=ju,Zt=vse,kse=[{key:"youtube",name:"YouTube",canPlay:Zt.canPlay.youtube,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./YouTube-af1e25c0.js").then(e=>e.Y),["assets/YouTube-af1e25c0.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"soundcloud",name:"SoundCloud",canPlay:Zt.canPlay.soundcloud,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./SoundCloud-cb3d2c50.js").then(e=>e.S),["assets/SoundCloud-cb3d2c50.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"vimeo",name:"Vimeo",canPlay:Zt.canPlay.vimeo,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Vimeo-15629a32.js").then(e=>e.V),["assets/Vimeo-15629a32.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"facebook",name:"Facebook",canPlay:Zt.canPlay.facebook,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Facebook-95305f52.js").then(e=>e.F),["assets/Facebook-95305f52.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"streamable",name:"Streamable",canPlay:Zt.canPlay.streamable,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Streamable-344c59ee.js").then(e=>e.S),["assets/Streamable-344c59ee.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"wistia",name:"Wistia",canPlay:Zt.canPlay.wistia,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Wistia-500f8a97.js").then(e=>e.W),["assets/Wistia-500f8a97.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"twitch",name:"Twitch",canPlay:Zt.canPlay.twitch,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Twitch-eec52ec3.js").then(e=>e.T),["assets/Twitch-eec52ec3.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"dailymotion",name:"DailyMotion",canPlay:Zt.canPlay.dailymotion,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./DailyMotion-c5f0390c.js").then(e=>e.D),["assets/DailyMotion-c5f0390c.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"mixcloud",name:"Mixcloud",canPlay:Zt.canPlay.mixcloud,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Mixcloud-158f251f.js").then(e=>e.M),["assets/Mixcloud-158f251f.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"vidyard",name:"Vidyard",canPlay:Zt.canPlay.vidyard,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Vidyard-77bcf258.js").then(e=>e.V),["assets/Vidyard-77bcf258.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"kaltura",name:"Kaltura",canPlay:Zt.canPlay.kaltura,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Kaltura-890aa431.js").then(e=>e.K),["assets/Kaltura-890aa431.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))},{key:"file",name:"FilePlayer",canPlay:Zt.canPlay.file,canEnablePIP:e=>Zt.canPlay.file(e)&&(document.pictureInPictureEnabled||(0,ar.supportsWebKitPresentationMode)())&&!Zt.AUDIO_EXTENSIONS.test(e),lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./FilePlayer-66165434.js").then(e=>e.F),["assets/FilePlayer-66165434.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"]))}],UO=Number.isNaN||function(t){return typeof t=="number"&&t!==t};function Rse(e,t){return!!(e===t||UO(e)&&UO(t))}function Ise(e,t){if(e.length!==t.length)return!1;for(var r=0;r{for(var r in t)Fu(e,r,{get:t[r],enumerable:!0})},tN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of Bse(t))!Gse.call(e,a)&&a!==r&&Fu(e,a,{get:()=>t[a],enumerable:!(n=Fse(t,a))||n.enumerable});return e},qse=(e,t,r)=>(r=e!=null?jse(Use(e)):{},tN(t||!e||!e.__esModule?Fu(r,"default",{value:e,enumerable:!0}):r,e)),Hse=e=>tN(Fu({},"__esModule",{value:!0}),e),rN={};zse(rN,{defaultProps:()=>Yse,propTypes:()=>Vse});var nN=Hse(rN),Wse=qse(oP);const{string:qt,bool:Ht,number:Ea,array:Wh,oneOfType:Ii,shape:gr,object:Wt,func:vt,node:GO}=Wse.default,Vse={url:Ii([qt,Wh,Wt]),playing:Ht,loop:Ht,controls:Ht,volume:Ea,muted:Ht,playbackRate:Ea,width:Ii([qt,Ea]),height:Ii([qt,Ea]),style:Wt,progressInterval:Ea,playsinline:Ht,pip:Ht,stopOnUnmount:Ht,light:Ii([Ht,qt,Wt]),playIcon:GO,previewTabIndex:Ea,fallback:GO,oEmbedUrl:qt,wrapper:Ii([qt,vt,gr({render:vt.isRequired})]),config:gr({soundcloud:gr({options:Wt}),youtube:gr({playerVars:Wt,embedOptions:Wt,onUnstarted:vt}),facebook:gr({appId:qt,version:qt,playerId:qt,attributes:Wt}),dailymotion:gr({params:Wt}),vimeo:gr({playerOptions:Wt,title:qt}),file:gr({attributes:Wt,tracks:Wh,forceVideo:Ht,forceAudio:Ht,forceHLS:Ht,forceSafariHLS:Ht,forceDisableHls:Ht,forceDASH:Ht,forceFLV:Ht,hlsOptions:Wt,hlsVersion:qt,dashVersion:qt,flvVersion:qt}),wistia:gr({options:Wt,playerId:qt,customControls:Wh}),mixcloud:gr({options:Wt}),twitch:gr({options:Wt,playerId:qt}),vidyard:gr({options:Wt})}),onReady:vt,onStart:vt,onPlay:vt,onPause:vt,onBuffer:vt,onBufferEnd:vt,onEnded:vt,onError:vt,onDuration:vt,onSeek:vt,onPlaybackRateChange:vt,onPlaybackQualityChange:vt,onProgress:vt,onClickPreview:vt,onEnablePIP:vt,onDisablePIP:vt},Rt=()=>{},Yse={playing:!1,loop:!1,controls:!1,volume:null,muted:!1,playbackRate:1,width:"640px",height:"360px",style:{},progressInterval:1e3,playsinline:!1,pip:!1,stopOnUnmount:!0,light:!1,fallback:null,wrapper:"div",previewTabIndex:0,oEmbedUrl:"https://noembed.com/embed?url={url}",config:{soundcloud:{options:{visual:!0,buying:!1,liking:!1,download:!1,sharing:!1,show_comments:!1,show_playcount:!1}},youtube:{playerVars:{playsinline:1,showinfo:0,rel:0,iv_load_policy:3,modestbranding:1},embedOptions:{},onUnstarted:Rt},facebook:{appId:"1309697205772819",version:"v3.3",playerId:null,attributes:{}},dailymotion:{params:{api:1,"endscreen-enable":!1}},vimeo:{playerOptions:{autopause:!1,byline:!1,portrait:!1,title:!1},title:null},file:{attributes:{},tracks:[],forceVideo:!1,forceAudio:!1,forceHLS:!1,forceDASH:!1,forceFLV:!1,hlsOptions:{},hlsVersion:"1.1.4",dashVersion:"3.1.3",flvVersion:"1.5.0",forceDisableHls:!1},wistia:{options:{},playerId:null,customControls:null},mixcloud:{options:{hide_cover:1}},twitch:{options:{},playerId:null},vidyard:{options:{}}},onReady:Rt,onStart:Rt,onPlay:Rt,onPause:Rt,onBuffer:Rt,onBufferEnd:Rt,onEnded:Rt,onError:Rt,onDuration:Rt,onSeek:Rt,onPlaybackRateChange:Rt,onPlaybackQualityChange:Rt,onProgress:Rt,onClickPreview:Rt,onEnablePIP:Rt,onDisablePIP:Rt};var Kse=Object.create,Qo=Object.defineProperty,Xse=Object.getOwnPropertyDescriptor,Zse=Object.getOwnPropertyNames,Jse=Object.getPrototypeOf,Qse=Object.prototype.hasOwnProperty,ele=(e,t,r)=>t in e?Qo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,tle=(e,t)=>{for(var r in t)Qo(e,r,{get:t[r],enumerable:!0})},aN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of Zse(t))!Qse.call(e,a)&&a!==r&&Qo(e,a,{get:()=>t[a],enumerable:!(n=Xse(t,a))||n.enumerable});return e},iN=(e,t,r)=>(r=e!=null?Kse(Jse(e)):{},aN(t||!e||!e.__esModule?Qo(r,"default",{value:e,enumerable:!0}):r,e)),rle=e=>aN(Qo({},"__esModule",{value:!0}),e),mt=(e,t,r)=>(ele(e,typeof t!="symbol"?t+"":t,r),r),oN={};tle(oN,{default:()=>Bu});var nle=rle(oN),zO=iN(M),ale=iN(eN),sN=nN,ile=ju;const ole=5e3;class Bu extends zO.Component{constructor(){super(...arguments),mt(this,"mounted",!1),mt(this,"isReady",!1),mt(this,"isPlaying",!1),mt(this,"isLoading",!0),mt(this,"loadOnReady",null),mt(this,"startOnPlay",!0),mt(this,"seekOnPlay",null),mt(this,"onDurationCalled",!1),mt(this,"handlePlayerMount",t=>{if(this.player){this.progress();return}this.player=t,this.player.load(this.props.url),this.progress()}),mt(this,"getInternalPlayer",t=>this.player?this.player[t]:null),mt(this,"progress",()=>{if(this.props.url&&this.player&&this.isReady){const t=this.getCurrentTime()||0,r=this.getSecondsLoaded(),n=this.getDuration();if(n){const a={playedSeconds:t,played:t/n};r!==null&&(a.loadedSeconds=r,a.loaded=r/n),(a.playedSeconds!==this.prevPlayed||a.loadedSeconds!==this.prevLoaded)&&this.props.onProgress(a),this.prevPlayed=a.playedSeconds,this.prevLoaded=a.loadedSeconds}}this.progressTimeout=setTimeout(this.progress,this.props.progressFrequency||this.props.progressInterval)}),mt(this,"handleReady",()=>{if(!this.mounted)return;this.isReady=!0,this.isLoading=!1;const{onReady:t,playing:r,volume:n,muted:a}=this.props;t(),!a&&n!==null&&this.player.setVolume(n),this.loadOnReady?(this.player.load(this.loadOnReady,!0),this.loadOnReady=null):r&&this.player.play(),this.handleDurationCheck()}),mt(this,"handlePlay",()=>{this.isPlaying=!0,this.isLoading=!1;const{onStart:t,onPlay:r,playbackRate:n}=this.props;this.startOnPlay&&(this.player.setPlaybackRate&&n!==1&&this.player.setPlaybackRate(n),t(),this.startOnPlay=!1),r(),this.seekOnPlay&&(this.seekTo(this.seekOnPlay),this.seekOnPlay=null),this.handleDurationCheck()}),mt(this,"handlePause",t=>{this.isPlaying=!1,this.isLoading||this.props.onPause(t)}),mt(this,"handleEnded",()=>{const{activePlayer:t,loop:r,onEnded:n}=this.props;t.loopOnEnded&&r&&this.seekTo(0),r||(this.isPlaying=!1,n())}),mt(this,"handleError",(...t)=>{this.isLoading=!1,this.props.onError(...t)}),mt(this,"handleDurationCheck",()=>{clearTimeout(this.durationCheckTimeout);const t=this.getDuration();t?this.onDurationCalled||(this.props.onDuration(t),this.onDurationCalled=!0):this.durationCheckTimeout=setTimeout(this.handleDurationCheck,100)}),mt(this,"handleLoaded",()=>{this.isLoading=!1})}componentDidMount(){this.mounted=!0}componentWillUnmount(){clearTimeout(this.progressTimeout),clearTimeout(this.durationCheckTimeout),this.isReady&&this.props.stopOnUnmount&&(this.player.stop(),this.player.disablePIP&&this.player.disablePIP()),this.mounted=!1}componentDidUpdate(t){if(!this.player)return;const{url:r,playing:n,volume:a,muted:i,playbackRate:o,pip:s,loop:l,activePlayer:c,disableDeferredLoading:d}=this.props;if(!(0,ale.default)(t.url,r)){if(this.isLoading&&!c.forceLoad&&!d&&!(0,ile.isMediaStream)(r)){console.warn(`ReactPlayer: the attempt to load ${r} is being deferred until the player has loaded`),this.loadOnReady=r;return}this.isLoading=!0,this.startOnPlay=!0,this.onDurationCalled=!1,this.player.load(r,this.isReady)}!t.playing&&n&&!this.isPlaying&&this.player.play(),t.playing&&!n&&this.isPlaying&&this.player.pause(),!t.pip&&s&&this.player.enablePIP&&this.player.enablePIP(),t.pip&&!s&&this.player.disablePIP&&this.player.disablePIP(),t.volume!==a&&a!==null&&this.player.setVolume(a),t.muted!==i&&(i?this.player.mute():(this.player.unmute(),a!==null&&setTimeout(()=>this.player.setVolume(a)))),t.playbackRate!==o&&this.player.setPlaybackRate&&this.player.setPlaybackRate(o),t.loop!==l&&this.player.setLoop&&this.player.setLoop(l)}getDuration(){return this.isReady?this.player.getDuration():null}getCurrentTime(){return this.isReady?this.player.getCurrentTime():null}getSecondsLoaded(){return this.isReady?this.player.getSecondsLoaded():null}seekTo(t,r,n){if(!this.isReady){t!==0&&(this.seekOnPlay=t,setTimeout(()=>{this.seekOnPlay=null},ole));return}if(r?r==="fraction":t>0&&t<1){const i=this.player.getDuration();if(!i){console.warn("ReactPlayer: could not seek using fraction – duration not yet available");return}this.player.seekTo(i*t,n);return}this.player.seekTo(t,n)}render(){const t=this.props.activePlayer;return t?zO.default.createElement(t,{...this.props,onMount:this.handlePlayerMount,onReady:this.handleReady,onPlay:this.handlePlay,onPause:this.handlePause,onEnded:this.handleEnded,onLoaded:this.handleLoaded,onError:this.handleError}):null}}mt(Bu,"displayName","Player");mt(Bu,"propTypes",sN.propTypes);mt(Bu,"defaultProps",sN.defaultProps);var sle=Object.create,es=Object.defineProperty,lle=Object.getOwnPropertyDescriptor,ule=Object.getOwnPropertyNames,cle=Object.getPrototypeOf,dle=Object.prototype.hasOwnProperty,ple=(e,t,r)=>t in e?es(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,fle=(e,t)=>{for(var r in t)es(e,r,{get:t[r],enumerable:!0})},lN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of ule(t))!dle.call(e,a)&&a!==r&&es(e,a,{get:()=>t[a],enumerable:!(n=lle(t,a))||n.enumerable});return e},ts=(e,t,r)=>(r=e!=null?sle(cle(e)):{},lN(t||!e||!e.__esModule?es(r,"default",{value:e,enumerable:!0}):r,e)),gle=e=>lN(es({},"__esModule",{value:!0}),e),ht=(e,t,r)=>(ple(e,typeof t!="symbol"?t+"":t,r),r),uN={};fle(uN,{createReactPlayer:()=>wle});var hle=gle(uN),_a=ts(M),mle=ts(LI),Vh=ts(Dse),qO=ts(eN),$i=nN,cN=ju,ble=ts(nle);const yle=(0,cN.lazy)(()=>ir(()=>import("./Preview-ac92af9a.js").then(e=>e.P),["assets/Preview-ac92af9a.js","assets/index-4bb27744.js","assets/index-b4d03b7b.css"])),vle=typeof window<"u"&&window.document,Sle=typeof Tt<"u"&&Tt.window&&Tt.window.document,Ele=Object.keys($i.propTypes),xle=vle||Sle?_a.Suspense:()=>null,Ni=[],wle=(e,t)=>{var r;return r=class extends _a.Component{constructor(){super(...arguments),ht(this,"state",{showPreview:!!this.props.light}),ht(this,"references",{wrapper:n=>{this.wrapper=n},player:n=>{this.player=n}}),ht(this,"handleClickPreview",n=>{this.setState({showPreview:!1}),this.props.onClickPreview(n)}),ht(this,"showPreview",()=>{this.setState({showPreview:!0})}),ht(this,"getDuration",()=>this.player?this.player.getDuration():null),ht(this,"getCurrentTime",()=>this.player?this.player.getCurrentTime():null),ht(this,"getSecondsLoaded",()=>this.player?this.player.getSecondsLoaded():null),ht(this,"getInternalPlayer",(n="player")=>this.player?this.player.getInternalPlayer(n):null),ht(this,"seekTo",(n,a,i)=>{if(!this.player)return null;this.player.seekTo(n,a,i)}),ht(this,"handleReady",()=>{this.props.onReady(this)}),ht(this,"getActivePlayer",(0,Vh.default)(n=>{for(const a of[...Ni,...e])if(a.canPlay(n))return a;return t||null})),ht(this,"getConfig",(0,Vh.default)((n,a)=>{const{config:i}=this.props;return mle.default.all([$i.defaultProps.config,$i.defaultProps.config[a]||{},i,i[a]||{}])})),ht(this,"getAttributes",(0,Vh.default)(n=>(0,cN.omit)(this.props,Ele))),ht(this,"renderActivePlayer",n=>{if(!n)return null;const a=this.getActivePlayer(n);if(!a)return null;const i=this.getConfig(n,a.key);return _a.default.createElement(ble.default,{...this.props,key:a.key,ref:this.references.player,config:i,activePlayer:a.lazyPlayer||a,onReady:this.handleReady})})}shouldComponentUpdate(n,a){return!(0,qO.default)(this.props,n)||!(0,qO.default)(this.state,a)}componentDidUpdate(n){const{light:a}=this.props;!n.light&&a&&this.setState({showPreview:!0}),n.light&&!a&&this.setState({showPreview:!1})}renderPreview(n){if(!n)return null;const{light:a,playIcon:i,previewTabIndex:o,oEmbedUrl:s}=this.props;return _a.default.createElement(yle,{url:n,light:a,playIcon:i,previewTabIndex:o,oEmbedUrl:s,onClick:this.handleClickPreview})}render(){const{url:n,style:a,width:i,height:o,fallback:s,wrapper:l}=this.props,{showPreview:c}=this.state,d=this.getAttributes(n),p=typeof l=="string"?this.references.wrapper:void 0;return _a.default.createElement(l,{ref:p,style:{...a,width:i,height:o},...d},_a.default.createElement(xle,{fallback:s},c?this.renderPreview(n):this.renderActivePlayer(n)))}},ht(r,"displayName","ReactPlayer"),ht(r,"propTypes",$i.propTypes),ht(r,"defaultProps",$i.defaultProps),ht(r,"addCustomPlayer",n=>{Ni.push(n)}),ht(r,"removeCustomPlayers",()=>{Ni.length=0}),ht(r,"canPlay",n=>{for(const a of[...Ni,...e])if(a.canPlay(n))return!0;return!1}),ht(r,"canEnablePIP",n=>{for(const a of[...Ni,...e])if(a.canEnablePIP&&a.canEnablePIP(n))return!0;return!1}),r};var _le=Object.create,Uu=Object.defineProperty,Tle=Object.getOwnPropertyDescriptor,Ale=Object.getOwnPropertyNames,Ole=Object.getPrototypeOf,kle=Object.prototype.hasOwnProperty,Rle=(e,t)=>{for(var r in t)Uu(e,r,{get:t[r],enumerable:!0})},dN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of Ale(t))!kle.call(e,a)&&a!==r&&Uu(e,a,{get:()=>t[a],enumerable:!(n=Tle(t,a))||n.enumerable});return e},Ile=(e,t,r)=>(r=e!=null?_le(Ole(e)):{},dN(t||!e||!e.__esModule?Uu(r,"default",{value:e,enumerable:!0}):r,e)),Nle=e=>dN(Uu({},"__esModule",{value:!0}),e),pN={};Rle(pN,{default:()=>Mle});var Cle=Nle(pN),pb=Ile(Ose),Dle=hle;const Lle=pb.default[pb.default.length-1];var Mle=(0,Dle.createReactPlayer)(pb.default,Lle);const Ple=ft(Cle),HO=e=>{const t=Math.floor(e/3600),r=Math.floor(e%3600/60),n=Math.floor(e%60),a=t>0?`${t}:`:"",i=t>0?r.toString().padStart(2,"0"):r.toString(),o=n.toString().padStart(2,"0");return`${a}${i}:${o}`},$le=({isPlaying:e,isFullScreen:t,setIsPlaying:r,playingTime:n,duration:a,handleProgressChange:i,handleVolumeChange:o,onFullScreenClick:s,showToolbar:l})=>{const[c,d]=M.useState(.5),[p,g]=M.useState(!1),[h,b]=M.useState(.5),S=(O,_)=>{const w=Array.isArray(_)?_[0]:_;d(w),o(O,w),p&&g(!1)},v=()=>{p?(d(h),o(new Event("input"),h)):(b(c),d(0),o(new Event("input"),0)),g(!p)};return m.jsxs(F,{children:[(!l||t)&&m.jsx(qle,{"aria-label":"Small","data-testid":"progress-bar",isFullScreen:t,max:a,onChange:i,size:"small",value:n}),m.jsxs(jle,{align:"center",direction:"row",showToolbar:l||t,children:[m.jsx(Ule,{onClick:r,size:"small",children:e?m.jsx(Eb,{}):m.jsx(xb,{})}),m.jsxs(Hle,{direction:"row",children:[m.jsx("span",{children:HO(n)}),m.jsx("span",{className:"separator",children:"/"}),m.jsx("span",{className:"duration",children:HO(a)})]}),m.jsxs(Gle,{direction:"row",px:9,children:[m.jsx(Vl,{className:"volume-slider",max:1,min:0,onChange:S,size:"small",step:.1,value:c}),m.jsx(Fle,{onClick:v,children:p?m.jsx(Ble,{children:m.jsx(jM,{})}):m.jsx(FM,{})})]}),m.jsx(zle,{"data-testid":"fullscreen-button",onClick:s,children:t?m.jsx(UM,{}):m.jsx(BM,{})})]})]})},jle=B(F)` +`,woe=()=>{const e=Pt(),{setPlayingNode:t}=$o(r=>r);switch(M.useEffect(()=>{var n,a;if(!e)return;(e.media_url||e.link||((n=e.properties)==null?void 0:n.link)||((a=e.properties)==null?void 0:a.media_url))&&t(e)},[t,e]),e==null?void 0:e.node_type){case"guest":case"person":return m.jsx(c7,{});case"data_series":return m.jsx(uX,{});case"tribe_message":return m.jsx(o7,{});case"Tweet":return m.jsx(S7,{});case"topic":return m.jsx(v7,{});case"show":return m.jsx(y7,{});case"video":case"podcast":case"clip":case"twitter_space":return m.jsx(XR,{});case"document":return m.jsx(boe,{});case"episode":return m.jsx(t7,{},e.ref_id);case"image":return m.jsx(i7,{});default:return m.jsx(noe,{})}},_oe=M.memo(woe);var Toe=function(t,r,n){var a=document.head||document.getElementsByTagName("head")[0],i=document.createElement("script");typeof r=="function"&&(n=r,r={}),r=r||{},n=n||function(){},i.type=r.type||"text/javascript",i.charset=r.charset||"utf8",i.async="async"in r?!!r.async:!0,i.src=t,r.attrs&&Aoe(i,r.attrs),r.text&&(i.text=""+r.text);var o="onload"in i?jO:Ooe;o(i,n),i.onload||jO(i,n),a.appendChild(i)};function Aoe(e,t){for(var r in t)e.setAttribute(r,t[r])}function jO(e,t){e.onload=function(){this.onerror=this.onload=null,t(null,e)},e.onerror=function(){this.onerror=this.onload=null,t(new Error("Failed to load "+this.src),e)}}function Ooe(e,t){e.onreadystatechange=function(){this.readyState!="complete"&&this.readyState!="loaded"||(this.onreadystatechange=null,t(null,e))}}var koe=function(t){return Roe(t)&&!Ioe(t)};function Roe(e){return!!e&&typeof e=="object"}function Ioe(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||Doe(e)}var Noe=typeof Symbol=="function"&&Symbol.for,Coe=Noe?Symbol.for("react.element"):60103;function Doe(e){return e.$$typeof===Coe}function Loe(e){return Array.isArray(e)?[]:{}}function Lo(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Qa(Loe(e),e,t):e}function Moe(e,t,r){return e.concat(t).map(function(n){return Lo(n,r)})}function Poe(e,t){if(!t.customMerge)return Qa;var r=t.customMerge(e);return typeof r=="function"?r:Qa}function $oe(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function FO(e){return Object.keys(e).concat($oe(e))}function DI(e,t){try{return t in e}catch{return!1}}function joe(e,t){return DI(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function Foe(e,t,r){var n={};return r.isMergeableObject(e)&&FO(e).forEach(function(a){n[a]=Lo(e[a],r)}),FO(t).forEach(function(a){joe(e,a)||(DI(e,a)&&r.isMergeableObject(t[a])?n[a]=Poe(a,r)(e[a],t[a],r):n[a]=Lo(t[a],r))}),n}function Qa(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||Moe,r.isMergeableObject=r.isMergeableObject||koe,r.cloneUnlessOtherwiseSpecified=Lo;var n=Array.isArray(t),a=Array.isArray(e),i=n===a;return i?n?r.arrayMerge(e,t,r):Foe(e,t,r):Lo(t,r)}Qa.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(n,a){return Qa(n,a,r)},{})};var Boe=Qa,LI=Boe,Uoe=Object.create,$u=Object.defineProperty,Goe=Object.getOwnPropertyDescriptor,zoe=Object.getOwnPropertyNames,qoe=Object.getPrototypeOf,Hoe=Object.prototype.hasOwnProperty,Woe=(e,t)=>{for(var r in t)$u(e,r,{get:t[r],enumerable:!0})},MI=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of zoe(t))!Hoe.call(e,a)&&a!==r&&$u(e,a,{get:()=>t[a],enumerable:!(n=Goe(t,a))||n.enumerable});return e},Vy=(e,t,r)=>(r=e!=null?Uoe(qoe(e)):{},MI(t||!e||!e.__esModule?$u(r,"default",{value:e,enumerable:!0}):r,e)),Voe=e=>MI($u({},"__esModule",{value:!0}),e),PI={};Woe(PI,{callPlayer:()=>use,getConfig:()=>sse,getSDK:()=>ose,isBlobUrl:()=>dse,isMediaStream:()=>cse,lazy:()=>Zoe,omit:()=>lse,parseEndTime:()=>nse,parseStartTime:()=>rse,queryString:()=>ise,randomString:()=>ase,supportsWebKitPresentationMode:()=>pse});var ju=Voe(PI),Yoe=Vy(M),Koe=Vy(Toe),Xoe=Vy(LI);const Zoe=e=>Yoe.default.lazy(async()=>{const t=await e();return typeof t.default=="function"?t:t.default}),Joe=/[?&#](?:start|t)=([0-9hms]+)/,Qoe=/[?&#]end=([0-9hms]+)/,ub=/(\d+)(h|m|s)/g,ese=/^\d+$/;function $I(e,t){if(e instanceof Array)return;const r=e.match(t);if(r){const n=r[1];if(n.match(ub))return tse(n);if(ese.test(n))return parseInt(n)}}function tse(e){let t=0,r=ub.exec(e);for(;r!==null;){const[,n,a]=r;a==="h"&&(t+=parseInt(n,10)*60*60),a==="m"&&(t+=parseInt(n,10)*60),a==="s"&&(t+=parseInt(n,10)),r=ub.exec(e)}return t}function rse(e){return $I(e,Joe)}function nse(e){return $I(e,Qoe)}function ase(){return Math.random().toString(36).substr(2,5)}function ise(e){return Object.keys(e).map(t=>`${t}=${e[t]}`).join("&")}function Hh(e){return window[e]?window[e]:window.exports&&window.exports[e]?window.exports[e]:window.module&&window.module.exports&&window.module.exports[e]?window.module.exports[e]:null}const Sa={},ose=function(t,r,n=null,a=()=>!0,i=Koe.default){const o=Hh(r);return o&&a(o)?Promise.resolve(o):new Promise((s,l)=>{if(Sa[t]){Sa[t].push({resolve:s,reject:l});return}Sa[t]=[{resolve:s,reject:l}];const c=d=>{Sa[t].forEach(p=>p.resolve(d))};if(n){const d=window[n];window[n]=function(){d&&d(),c(Hh(r))}}i(t,d=>{d?(Sa[t].forEach(p=>p.reject(d)),Sa[t]=null):n||c(Hh(r))})})};function sse(e,t){return(0,Xoe.default)(t.config,e.config)}function lse(e,...t){const r=[].concat(...t),n={},a=Object.keys(e);for(const i of a)r.indexOf(i)===-1&&(n[i]=e[i]);return n}function use(e,...t){if(!this.player||!this.player[e]){let r=`ReactPlayer: ${this.constructor.displayName} player could not call %c${e}%c – `;return this.player?this.player[e]||(r+="The method was not available"):r+="The player was not available",console.warn(r,"font-weight: bold",""),null}return this.player[e](...t)}function cse(e){return typeof window<"u"&&typeof window.MediaStream<"u"&&e instanceof window.MediaStream}function dse(e){return/^blob:/.test(e)}function pse(e=document.createElement("video")){const t=/iPhone|iPod/.test(navigator.userAgent)===!1;return e.webkitSupportsPresentationMode&&typeof e.webkitSetPresentationMode=="function"&&t}var Yy=Object.defineProperty,fse=Object.getOwnPropertyDescriptor,gse=Object.getOwnPropertyNames,hse=Object.prototype.hasOwnProperty,mse=(e,t)=>{for(var r in t)Yy(e,r,{get:t[r],enumerable:!0})},bse=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of gse(t))!hse.call(e,a)&&a!==r&&Yy(e,a,{get:()=>t[a],enumerable:!(n=fse(t,a))||n.enumerable});return e},yse=e=>bse(Yy({},"__esModule",{value:!0}),e),jI={};mse(jI,{AUDIO_EXTENSIONS:()=>Ky,DASH_EXTENSIONS:()=>ZI,FLV_EXTENSIONS:()=>JI,HLS_EXTENSIONS:()=>Zy,MATCH_URL_DAILYMOTION:()=>VI,MATCH_URL_FACEBOOK:()=>UI,MATCH_URL_FACEBOOK_WATCH:()=>GI,MATCH_URL_KALTURA:()=>XI,MATCH_URL_MIXCLOUD:()=>YI,MATCH_URL_SOUNDCLOUD:()=>FI,MATCH_URL_STREAMABLE:()=>zI,MATCH_URL_TWITCH_CHANNEL:()=>WI,MATCH_URL_TWITCH_VIDEO:()=>HI,MATCH_URL_VIDYARD:()=>KI,MATCH_URL_VIMEO:()=>BI,MATCH_URL_WISTIA:()=>qI,MATCH_URL_YOUTUBE:()=>cb,VIDEO_EXTENSIONS:()=>Xy,canPlay:()=>Sse});var vse=yse(jI),BO=ju;const cb=/(?:youtu\.be\/|youtube(?:-nocookie|education)?\.com\/(?:embed\/|v\/|watch\/|watch\?v=|watch\?.+&v=|shorts\/|live\/))((\w|-){11})|youtube\.com\/playlist\?list=|youtube\.com\/user\//,FI=/(?:soundcloud\.com|snd\.sc)\/[^.]+$/,BI=/vimeo\.com\/(?!progressive_redirect).+/,UI=/^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/,GI=/^https?:\/\/fb\.watch\/.+$/,zI=/streamable\.com\/([a-z0-9]+)$/,qI=/(?:wistia\.(?:com|net)|wi\.st)\/(?:medias|embed)\/(?:iframe\/)?([^?]+)/,HI=/(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/,WI=/(?:www\.|go\.)?twitch\.tv\/([a-zA-Z0-9_]+)($|\?)/,VI=/^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?(?:[\w.#_-]+)?/,YI=/mixcloud\.com\/([^/]+\/[^/]+)/,KI=/vidyard.com\/(?:watch\/)?([a-zA-Z0-9-_]+)/,XI=/^https?:\/\/[a-zA-Z]+\.kaltura.(com|org)\/p\/([0-9]+)\/sp\/([0-9]+)00\/embedIframeJs\/uiconf_id\/([0-9]+)\/partner_id\/([0-9]+)(.*)entry_id.([a-zA-Z0-9-_].*)$/,Ky=/\.(m4a|m4b|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i,Xy=/\.(mp4|og[gv]|webm|mov|m4v)(#t=[,\d+]+)?($|\?)/i,Zy=/\.(m3u8)($|\?)/i,ZI=/\.(mpd)($|\?)/i,JI=/\.(flv)($|\?)/i,db=e=>{if(e instanceof Array){for(const t of e)if(typeof t=="string"&&db(t)||db(t.src))return!0;return!1}return(0,BO.isMediaStream)(e)||(0,BO.isBlobUrl)(e)?!0:Ky.test(e)||Xy.test(e)||Zy.test(e)||ZI.test(e)||JI.test(e)},Sse={youtube:e=>e instanceof Array?e.every(t=>cb.test(t)):cb.test(e),soundcloud:e=>FI.test(e)&&!Ky.test(e),vimeo:e=>BI.test(e)&&!Xy.test(e)&&!Zy.test(e),facebook:e=>UI.test(e)||GI.test(e),streamable:e=>zI.test(e),wistia:e=>qI.test(e),twitch:e=>HI.test(e)||WI.test(e),dailymotion:e=>VI.test(e),mixcloud:e=>YI.test(e),vidyard:e=>KI.test(e),kaltura:e=>XI.test(e),file:db};var Jy=Object.defineProperty,Ese=Object.getOwnPropertyDescriptor,xse=Object.getOwnPropertyNames,wse=Object.prototype.hasOwnProperty,_se=(e,t)=>{for(var r in t)Jy(e,r,{get:t[r],enumerable:!0})},Tse=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of xse(t))!wse.call(e,a)&&a!==r&&Jy(e,a,{get:()=>t[a],enumerable:!(n=Ese(t,a))||n.enumerable});return e},Ase=e=>Tse(Jy({},"__esModule",{value:!0}),e),QI={};_se(QI,{default:()=>kse});var Ose=Ase(QI),ar=ju,Zt=vse,kse=[{key:"youtube",name:"YouTube",canPlay:Zt.canPlay.youtube,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./YouTube-2c06e076.js").then(e=>e.Y),["assets/YouTube-2c06e076.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"soundcloud",name:"SoundCloud",canPlay:Zt.canPlay.soundcloud,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./SoundCloud-b012eb42.js").then(e=>e.S),["assets/SoundCloud-b012eb42.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"vimeo",name:"Vimeo",canPlay:Zt.canPlay.vimeo,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Vimeo-401b9966.js").then(e=>e.V),["assets/Vimeo-401b9966.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"facebook",name:"Facebook",canPlay:Zt.canPlay.facebook,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Facebook-ecfe1118.js").then(e=>e.F),["assets/Facebook-ecfe1118.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"streamable",name:"Streamable",canPlay:Zt.canPlay.streamable,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Streamable-7ba1c141.js").then(e=>e.S),["assets/Streamable-7ba1c141.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"wistia",name:"Wistia",canPlay:Zt.canPlay.wistia,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Wistia-74afe4bb.js").then(e=>e.W),["assets/Wistia-74afe4bb.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"twitch",name:"Twitch",canPlay:Zt.canPlay.twitch,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Twitch-08c50d1f.js").then(e=>e.T),["assets/Twitch-08c50d1f.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"dailymotion",name:"DailyMotion",canPlay:Zt.canPlay.dailymotion,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./DailyMotion-1fc74fca.js").then(e=>e.D),["assets/DailyMotion-1fc74fca.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"mixcloud",name:"Mixcloud",canPlay:Zt.canPlay.mixcloud,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Mixcloud-6647e53d.js").then(e=>e.M),["assets/Mixcloud-6647e53d.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"vidyard",name:"Vidyard",canPlay:Zt.canPlay.vidyard,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Vidyard-9c70b529.js").then(e=>e.V),["assets/Vidyard-9c70b529.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"kaltura",name:"Kaltura",canPlay:Zt.canPlay.kaltura,lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./Kaltura-a5ccda38.js").then(e=>e.K),["assets/Kaltura-a5ccda38.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))},{key:"file",name:"FilePlayer",canPlay:Zt.canPlay.file,canEnablePIP:e=>Zt.canPlay.file(e)&&(document.pictureInPictureEnabled||(0,ar.supportsWebKitPresentationMode)())&&!Zt.AUDIO_EXTENSIONS.test(e),lazyPlayer:(0,ar.lazy)(()=>ir(()=>import("./FilePlayer-59fef6f9.js").then(e=>e.F),["assets/FilePlayer-59fef6f9.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"]))}],UO=Number.isNaN||function(t){return typeof t=="number"&&t!==t};function Rse(e,t){return!!(e===t||UO(e)&&UO(t))}function Ise(e,t){if(e.length!==t.length)return!1;for(var r=0;r{for(var r in t)Fu(e,r,{get:t[r],enumerable:!0})},tN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of Bse(t))!Gse.call(e,a)&&a!==r&&Fu(e,a,{get:()=>t[a],enumerable:!(n=Fse(t,a))||n.enumerable});return e},qse=(e,t,r)=>(r=e!=null?jse(Use(e)):{},tN(t||!e||!e.__esModule?Fu(r,"default",{value:e,enumerable:!0}):r,e)),Hse=e=>tN(Fu({},"__esModule",{value:!0}),e),rN={};zse(rN,{defaultProps:()=>Yse,propTypes:()=>Vse});var nN=Hse(rN),Wse=qse(oP);const{string:qt,bool:Ht,number:Ea,array:Wh,oneOfType:Ii,shape:gr,object:Wt,func:vt,node:GO}=Wse.default,Vse={url:Ii([qt,Wh,Wt]),playing:Ht,loop:Ht,controls:Ht,volume:Ea,muted:Ht,playbackRate:Ea,width:Ii([qt,Ea]),height:Ii([qt,Ea]),style:Wt,progressInterval:Ea,playsinline:Ht,pip:Ht,stopOnUnmount:Ht,light:Ii([Ht,qt,Wt]),playIcon:GO,previewTabIndex:Ea,fallback:GO,oEmbedUrl:qt,wrapper:Ii([qt,vt,gr({render:vt.isRequired})]),config:gr({soundcloud:gr({options:Wt}),youtube:gr({playerVars:Wt,embedOptions:Wt,onUnstarted:vt}),facebook:gr({appId:qt,version:qt,playerId:qt,attributes:Wt}),dailymotion:gr({params:Wt}),vimeo:gr({playerOptions:Wt,title:qt}),file:gr({attributes:Wt,tracks:Wh,forceVideo:Ht,forceAudio:Ht,forceHLS:Ht,forceSafariHLS:Ht,forceDisableHls:Ht,forceDASH:Ht,forceFLV:Ht,hlsOptions:Wt,hlsVersion:qt,dashVersion:qt,flvVersion:qt}),wistia:gr({options:Wt,playerId:qt,customControls:Wh}),mixcloud:gr({options:Wt}),twitch:gr({options:Wt,playerId:qt}),vidyard:gr({options:Wt})}),onReady:vt,onStart:vt,onPlay:vt,onPause:vt,onBuffer:vt,onBufferEnd:vt,onEnded:vt,onError:vt,onDuration:vt,onSeek:vt,onPlaybackRateChange:vt,onPlaybackQualityChange:vt,onProgress:vt,onClickPreview:vt,onEnablePIP:vt,onDisablePIP:vt},Rt=()=>{},Yse={playing:!1,loop:!1,controls:!1,volume:null,muted:!1,playbackRate:1,width:"640px",height:"360px",style:{},progressInterval:1e3,playsinline:!1,pip:!1,stopOnUnmount:!0,light:!1,fallback:null,wrapper:"div",previewTabIndex:0,oEmbedUrl:"https://noembed.com/embed?url={url}",config:{soundcloud:{options:{visual:!0,buying:!1,liking:!1,download:!1,sharing:!1,show_comments:!1,show_playcount:!1}},youtube:{playerVars:{playsinline:1,showinfo:0,rel:0,iv_load_policy:3,modestbranding:1},embedOptions:{},onUnstarted:Rt},facebook:{appId:"1309697205772819",version:"v3.3",playerId:null,attributes:{}},dailymotion:{params:{api:1,"endscreen-enable":!1}},vimeo:{playerOptions:{autopause:!1,byline:!1,portrait:!1,title:!1},title:null},file:{attributes:{},tracks:[],forceVideo:!1,forceAudio:!1,forceHLS:!1,forceDASH:!1,forceFLV:!1,hlsOptions:{},hlsVersion:"1.1.4",dashVersion:"3.1.3",flvVersion:"1.5.0",forceDisableHls:!1},wistia:{options:{},playerId:null,customControls:null},mixcloud:{options:{hide_cover:1}},twitch:{options:{},playerId:null},vidyard:{options:{}}},onReady:Rt,onStart:Rt,onPlay:Rt,onPause:Rt,onBuffer:Rt,onBufferEnd:Rt,onEnded:Rt,onError:Rt,onDuration:Rt,onSeek:Rt,onPlaybackRateChange:Rt,onPlaybackQualityChange:Rt,onProgress:Rt,onClickPreview:Rt,onEnablePIP:Rt,onDisablePIP:Rt};var Kse=Object.create,Qo=Object.defineProperty,Xse=Object.getOwnPropertyDescriptor,Zse=Object.getOwnPropertyNames,Jse=Object.getPrototypeOf,Qse=Object.prototype.hasOwnProperty,ele=(e,t,r)=>t in e?Qo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,tle=(e,t)=>{for(var r in t)Qo(e,r,{get:t[r],enumerable:!0})},aN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of Zse(t))!Qse.call(e,a)&&a!==r&&Qo(e,a,{get:()=>t[a],enumerable:!(n=Xse(t,a))||n.enumerable});return e},iN=(e,t,r)=>(r=e!=null?Kse(Jse(e)):{},aN(t||!e||!e.__esModule?Qo(r,"default",{value:e,enumerable:!0}):r,e)),rle=e=>aN(Qo({},"__esModule",{value:!0}),e),mt=(e,t,r)=>(ele(e,typeof t!="symbol"?t+"":t,r),r),oN={};tle(oN,{default:()=>Bu});var nle=rle(oN),zO=iN(M),ale=iN(eN),sN=nN,ile=ju;const ole=5e3;class Bu extends zO.Component{constructor(){super(...arguments),mt(this,"mounted",!1),mt(this,"isReady",!1),mt(this,"isPlaying",!1),mt(this,"isLoading",!0),mt(this,"loadOnReady",null),mt(this,"startOnPlay",!0),mt(this,"seekOnPlay",null),mt(this,"onDurationCalled",!1),mt(this,"handlePlayerMount",t=>{if(this.player){this.progress();return}this.player=t,this.player.load(this.props.url),this.progress()}),mt(this,"getInternalPlayer",t=>this.player?this.player[t]:null),mt(this,"progress",()=>{if(this.props.url&&this.player&&this.isReady){const t=this.getCurrentTime()||0,r=this.getSecondsLoaded(),n=this.getDuration();if(n){const a={playedSeconds:t,played:t/n};r!==null&&(a.loadedSeconds=r,a.loaded=r/n),(a.playedSeconds!==this.prevPlayed||a.loadedSeconds!==this.prevLoaded)&&this.props.onProgress(a),this.prevPlayed=a.playedSeconds,this.prevLoaded=a.loadedSeconds}}this.progressTimeout=setTimeout(this.progress,this.props.progressFrequency||this.props.progressInterval)}),mt(this,"handleReady",()=>{if(!this.mounted)return;this.isReady=!0,this.isLoading=!1;const{onReady:t,playing:r,volume:n,muted:a}=this.props;t(),!a&&n!==null&&this.player.setVolume(n),this.loadOnReady?(this.player.load(this.loadOnReady,!0),this.loadOnReady=null):r&&this.player.play(),this.handleDurationCheck()}),mt(this,"handlePlay",()=>{this.isPlaying=!0,this.isLoading=!1;const{onStart:t,onPlay:r,playbackRate:n}=this.props;this.startOnPlay&&(this.player.setPlaybackRate&&n!==1&&this.player.setPlaybackRate(n),t(),this.startOnPlay=!1),r(),this.seekOnPlay&&(this.seekTo(this.seekOnPlay),this.seekOnPlay=null),this.handleDurationCheck()}),mt(this,"handlePause",t=>{this.isPlaying=!1,this.isLoading||this.props.onPause(t)}),mt(this,"handleEnded",()=>{const{activePlayer:t,loop:r,onEnded:n}=this.props;t.loopOnEnded&&r&&this.seekTo(0),r||(this.isPlaying=!1,n())}),mt(this,"handleError",(...t)=>{this.isLoading=!1,this.props.onError(...t)}),mt(this,"handleDurationCheck",()=>{clearTimeout(this.durationCheckTimeout);const t=this.getDuration();t?this.onDurationCalled||(this.props.onDuration(t),this.onDurationCalled=!0):this.durationCheckTimeout=setTimeout(this.handleDurationCheck,100)}),mt(this,"handleLoaded",()=>{this.isLoading=!1})}componentDidMount(){this.mounted=!0}componentWillUnmount(){clearTimeout(this.progressTimeout),clearTimeout(this.durationCheckTimeout),this.isReady&&this.props.stopOnUnmount&&(this.player.stop(),this.player.disablePIP&&this.player.disablePIP()),this.mounted=!1}componentDidUpdate(t){if(!this.player)return;const{url:r,playing:n,volume:a,muted:i,playbackRate:o,pip:s,loop:l,activePlayer:c,disableDeferredLoading:d}=this.props;if(!(0,ale.default)(t.url,r)){if(this.isLoading&&!c.forceLoad&&!d&&!(0,ile.isMediaStream)(r)){console.warn(`ReactPlayer: the attempt to load ${r} is being deferred until the player has loaded`),this.loadOnReady=r;return}this.isLoading=!0,this.startOnPlay=!0,this.onDurationCalled=!1,this.player.load(r,this.isReady)}!t.playing&&n&&!this.isPlaying&&this.player.play(),t.playing&&!n&&this.isPlaying&&this.player.pause(),!t.pip&&s&&this.player.enablePIP&&this.player.enablePIP(),t.pip&&!s&&this.player.disablePIP&&this.player.disablePIP(),t.volume!==a&&a!==null&&this.player.setVolume(a),t.muted!==i&&(i?this.player.mute():(this.player.unmute(),a!==null&&setTimeout(()=>this.player.setVolume(a)))),t.playbackRate!==o&&this.player.setPlaybackRate&&this.player.setPlaybackRate(o),t.loop!==l&&this.player.setLoop&&this.player.setLoop(l)}getDuration(){return this.isReady?this.player.getDuration():null}getCurrentTime(){return this.isReady?this.player.getCurrentTime():null}getSecondsLoaded(){return this.isReady?this.player.getSecondsLoaded():null}seekTo(t,r,n){if(!this.isReady){t!==0&&(this.seekOnPlay=t,setTimeout(()=>{this.seekOnPlay=null},ole));return}if(r?r==="fraction":t>0&&t<1){const i=this.player.getDuration();if(!i){console.warn("ReactPlayer: could not seek using fraction – duration not yet available");return}this.player.seekTo(i*t,n);return}this.player.seekTo(t,n)}render(){const t=this.props.activePlayer;return t?zO.default.createElement(t,{...this.props,onMount:this.handlePlayerMount,onReady:this.handleReady,onPlay:this.handlePlay,onPause:this.handlePause,onEnded:this.handleEnded,onLoaded:this.handleLoaded,onError:this.handleError}):null}}mt(Bu,"displayName","Player");mt(Bu,"propTypes",sN.propTypes);mt(Bu,"defaultProps",sN.defaultProps);var sle=Object.create,es=Object.defineProperty,lle=Object.getOwnPropertyDescriptor,ule=Object.getOwnPropertyNames,cle=Object.getPrototypeOf,dle=Object.prototype.hasOwnProperty,ple=(e,t,r)=>t in e?es(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,fle=(e,t)=>{for(var r in t)es(e,r,{get:t[r],enumerable:!0})},lN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of ule(t))!dle.call(e,a)&&a!==r&&es(e,a,{get:()=>t[a],enumerable:!(n=lle(t,a))||n.enumerable});return e},ts=(e,t,r)=>(r=e!=null?sle(cle(e)):{},lN(t||!e||!e.__esModule?es(r,"default",{value:e,enumerable:!0}):r,e)),gle=e=>lN(es({},"__esModule",{value:!0}),e),ht=(e,t,r)=>(ple(e,typeof t!="symbol"?t+"":t,r),r),uN={};fle(uN,{createReactPlayer:()=>wle});var hle=gle(uN),_a=ts(M),mle=ts(LI),Vh=ts(Dse),qO=ts(eN),$i=nN,cN=ju,ble=ts(nle);const yle=(0,cN.lazy)(()=>ir(()=>import("./Preview-2ad93ee1.js").then(e=>e.P),["assets/Preview-2ad93ee1.js","assets/index-4e60c9e2.js","assets/index-b4d03b7b.css"])),vle=typeof window<"u"&&window.document,Sle=typeof Tt<"u"&&Tt.window&&Tt.window.document,Ele=Object.keys($i.propTypes),xle=vle||Sle?_a.Suspense:()=>null,Ni=[],wle=(e,t)=>{var r;return r=class extends _a.Component{constructor(){super(...arguments),ht(this,"state",{showPreview:!!this.props.light}),ht(this,"references",{wrapper:n=>{this.wrapper=n},player:n=>{this.player=n}}),ht(this,"handleClickPreview",n=>{this.setState({showPreview:!1}),this.props.onClickPreview(n)}),ht(this,"showPreview",()=>{this.setState({showPreview:!0})}),ht(this,"getDuration",()=>this.player?this.player.getDuration():null),ht(this,"getCurrentTime",()=>this.player?this.player.getCurrentTime():null),ht(this,"getSecondsLoaded",()=>this.player?this.player.getSecondsLoaded():null),ht(this,"getInternalPlayer",(n="player")=>this.player?this.player.getInternalPlayer(n):null),ht(this,"seekTo",(n,a,i)=>{if(!this.player)return null;this.player.seekTo(n,a,i)}),ht(this,"handleReady",()=>{this.props.onReady(this)}),ht(this,"getActivePlayer",(0,Vh.default)(n=>{for(const a of[...Ni,...e])if(a.canPlay(n))return a;return t||null})),ht(this,"getConfig",(0,Vh.default)((n,a)=>{const{config:i}=this.props;return mle.default.all([$i.defaultProps.config,$i.defaultProps.config[a]||{},i,i[a]||{}])})),ht(this,"getAttributes",(0,Vh.default)(n=>(0,cN.omit)(this.props,Ele))),ht(this,"renderActivePlayer",n=>{if(!n)return null;const a=this.getActivePlayer(n);if(!a)return null;const i=this.getConfig(n,a.key);return _a.default.createElement(ble.default,{...this.props,key:a.key,ref:this.references.player,config:i,activePlayer:a.lazyPlayer||a,onReady:this.handleReady})})}shouldComponentUpdate(n,a){return!(0,qO.default)(this.props,n)||!(0,qO.default)(this.state,a)}componentDidUpdate(n){const{light:a}=this.props;!n.light&&a&&this.setState({showPreview:!0}),n.light&&!a&&this.setState({showPreview:!1})}renderPreview(n){if(!n)return null;const{light:a,playIcon:i,previewTabIndex:o,oEmbedUrl:s}=this.props;return _a.default.createElement(yle,{url:n,light:a,playIcon:i,previewTabIndex:o,oEmbedUrl:s,onClick:this.handleClickPreview})}render(){const{url:n,style:a,width:i,height:o,fallback:s,wrapper:l}=this.props,{showPreview:c}=this.state,d=this.getAttributes(n),p=typeof l=="string"?this.references.wrapper:void 0;return _a.default.createElement(l,{ref:p,style:{...a,width:i,height:o},...d},_a.default.createElement(xle,{fallback:s},c?this.renderPreview(n):this.renderActivePlayer(n)))}},ht(r,"displayName","ReactPlayer"),ht(r,"propTypes",$i.propTypes),ht(r,"defaultProps",$i.defaultProps),ht(r,"addCustomPlayer",n=>{Ni.push(n)}),ht(r,"removeCustomPlayers",()=>{Ni.length=0}),ht(r,"canPlay",n=>{for(const a of[...Ni,...e])if(a.canPlay(n))return!0;return!1}),ht(r,"canEnablePIP",n=>{for(const a of[...Ni,...e])if(a.canEnablePIP&&a.canEnablePIP(n))return!0;return!1}),r};var _le=Object.create,Uu=Object.defineProperty,Tle=Object.getOwnPropertyDescriptor,Ale=Object.getOwnPropertyNames,Ole=Object.getPrototypeOf,kle=Object.prototype.hasOwnProperty,Rle=(e,t)=>{for(var r in t)Uu(e,r,{get:t[r],enumerable:!0})},dN=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let a of Ale(t))!kle.call(e,a)&&a!==r&&Uu(e,a,{get:()=>t[a],enumerable:!(n=Tle(t,a))||n.enumerable});return e},Ile=(e,t,r)=>(r=e!=null?_le(Ole(e)):{},dN(t||!e||!e.__esModule?Uu(r,"default",{value:e,enumerable:!0}):r,e)),Nle=e=>dN(Uu({},"__esModule",{value:!0}),e),pN={};Rle(pN,{default:()=>Mle});var Cle=Nle(pN),pb=Ile(Ose),Dle=hle;const Lle=pb.default[pb.default.length-1];var Mle=(0,Dle.createReactPlayer)(pb.default,Lle);const Ple=ft(Cle),HO=e=>{const t=Math.floor(e/3600),r=Math.floor(e%3600/60),n=Math.floor(e%60),a=t>0?`${t}:`:"",i=t>0?r.toString().padStart(2,"0"):r.toString(),o=n.toString().padStart(2,"0");return`${a}${i}:${o}`},$le=({isPlaying:e,isFullScreen:t,setIsPlaying:r,playingTime:n,duration:a,handleProgressChange:i,handleVolumeChange:o,onFullScreenClick:s,showToolbar:l})=>{const[c,d]=M.useState(.5),[p,g]=M.useState(!1),[h,b]=M.useState(.5),S=(O,_)=>{const w=Array.isArray(_)?_[0]:_;d(w),o(O,w),p&&g(!1)},v=()=>{p?(d(h),o(new Event("input"),h)):(b(c),d(0),o(new Event("input"),0)),g(!p)};return m.jsxs(F,{children:[(!l||t)&&m.jsx(qle,{"aria-label":"Small","data-testid":"progress-bar",isFullScreen:t,max:a,onChange:i,size:"small",value:n}),m.jsxs(jle,{align:"center",direction:"row",showToolbar:l||t,children:[m.jsx(Ule,{onClick:r,size:"small",children:e?m.jsx(Eb,{}):m.jsx(xb,{})}),m.jsxs(Hle,{direction:"row",children:[m.jsx("span",{children:HO(n)}),m.jsx("span",{className:"separator",children:"/"}),m.jsx("span",{className:"duration",children:HO(a)})]}),m.jsxs(Gle,{direction:"row",px:9,children:[m.jsx(Vl,{className:"volume-slider",max:1,min:0,onChange:S,size:"small",step:.1,value:c}),m.jsx(Fle,{onClick:v,children:p?m.jsx(Ble,{children:m.jsx(jM,{})}):m.jsx(FM,{})})]}),m.jsx(zle,{"data-testid":"fullscreen-button",onClick:s,children:t?m.jsx(UM,{}):m.jsx(BM,{})})]})]})},jle=B(F)` height: 60px; padding: 12px 16px; ${e=>e.showToolbar&&` diff --git a/build/assets/index-d0e3c339.js b/build/assets/index-aa1facf3.js similarity index 85% rename from build/assets/index-d0e3c339.js rename to build/assets/index-aa1facf3.js index f6d6db49c..b3b043ecb 100644 --- a/build/assets/index-d0e3c339.js +++ b/build/assets/index-aa1facf3.js @@ -1 +1 @@ -import{c as f,bw as m}from"./index-4bb27744.js";import{D as y}from"./constants-bc1d79ca.js";const c={data:null,ids:[],loading:!1,total:0,filters:{is_muted:!1,sortBy:y,page:0,pageSize:50}};let s=null;const S=f((a,n)=>({...c,setTopics:async()=>{a({loading:!0}),s&&s.abort();const t=new AbortController,{signal:p}=t;s=t;const{data:d,ids:g,filters:e}=n(),u=T(e);e.page===0&&a({data:null,ids:[],total:0});try{const o=await m(u,p),i=e.page===0?{}:{...d||{}},l=e.page===0?[]:[...g];o.data.forEach(r=>{i[r.ref_id]=r,l.push(r.ref_id)}),a({data:i,ids:l,total:o.totalCount}),a({loading:!1})}catch(o){console.error(o)}},setFilters:t=>a({filters:{...n().filters,page:0,...t}}),terminate:()=>a(c)})),T=a=>({muted:a.is_muted?"True":"False",skip:String(a.page*a.pageSize),limit:String(a.pageSize),sort_by:a.sortBy,...a.search?{search:a.search}:{node_type:"Topic"}});export{S as u}; +import{c as f,bv as m}from"./index-4e60c9e2.js";import{D as y}from"./constants-b9d9206a.js";const c={data:null,ids:[],loading:!1,total:0,filters:{is_muted:!1,sortBy:y,page:0,pageSize:50}};let s=null;const S=f((a,n)=>({...c,setTopics:async()=>{a({loading:!0}),s&&s.abort();const t=new AbortController,{signal:p}=t;s=t;const{data:d,ids:g,filters:e}=n(),u=T(e);e.page===0&&a({data:null,ids:[],total:0});try{const o=await m(u,p),i=e.page===0?{}:{...d||{}},l=e.page===0?[]:[...g];o.data.forEach(r=>{i[r.ref_id]=r,l.push(r.ref_id)}),a({data:i,ids:l,total:o.totalCount}),a({loading:!1})}catch(o){console.error(o)}},setFilters:t=>a({filters:{...n().filters,page:0,...t}}),terminate:()=>a(c)})),T=a=>({muted:a.is_muted?"True":"False",skip:String(a.page*a.pageSize),limit:String(a.pageSize),sort_by:a.sortBy,...a.search?{search:a.search}:{node_type:"Topic"}});export{S as u}; diff --git a/build/assets/index-7730ff6f.js b/build/assets/index-af5a3f81.js similarity index 72% rename from build/assets/index-7730ff6f.js rename to build/assets/index-af5a3f81.js index f5529381c..1628c16f6 100644 --- a/build/assets/index-7730ff6f.js +++ b/build/assets/index-af5a3f81.js @@ -1,4 +1,4 @@ -import{G as m3,R as A1,H as r1,J as Z1,K as G2,L as N1,M as R1,N as u1,O as Z,P as F1,r as H,S as U1,j as r,U as c1,V as O1,X as w3,Y as k1,Z as d1,$ as _2,a0 as k2,a1 as v3,a2 as y2,a3 as W2,c as X2,u as I1,s as q,a as i1,F as f1,B as Y2,C as C2,a4 as _3,a5 as k3,k as K2,A as y3,b as j3,a6 as L3,I as H3}from"./index-4bb27744.js";const M3=e=>{const[n,t,i]=e.split(":"),s=parseInt(n,10),o=parseInt(t,10),l=parseInt(i,10);return s*3600+o*60+l};function j2(...e){return e.reduce((n,t)=>t==null?n:function(...s){n.apply(this,s),t.apply(this,s)},()=>{})}function V3(e,n=166){let t;function i(...s){const o=()=>{e.apply(this,s)};clearTimeout(t),t=setTimeout(o,n)}return i.clear=()=>{clearTimeout(t)},i}function s1(e){return e&&e.ownerDocument||document}function B1(e){return s1(e).defaultView||window}function Z3(e){const n=e.documentElement.clientWidth;return Math.abs(window.innerWidth-n)}const b3=e=>{let n;return e<1?n=5.11916*e**2:n=4.5*Math.log(e+1)+2,(n/100).toFixed(2)},L2=b3,H2={disabled:!1};var E3=function(n){return n.scrollTop},b1="unmounted",C1="exited",a1="entering",_1="entered",i2="exiting",l1=function(e){m3(n,e);function n(i,s){var o;o=e.call(this,i,s)||this;var l=s,C=l&&!l.isMounting?i.enter:i.appear,a;return o.appearStatus=null,i.in?C?(a=C1,o.appearStatus=a1):a=_1:i.unmountOnExit||i.mountOnEnter?a=b1:a=C1,o.state={status:a},o.nextCallback=null,o}n.getDerivedStateFromProps=function(s,o){var l=s.in;return l&&o.status===b1?{status:C1}:null};var t=n.prototype;return t.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},t.componentDidUpdate=function(s){var o=null;if(s!==this.props){var l=this.state.status;this.props.in?l!==a1&&l!==_1&&(o=a1):(l===a1||l===_1)&&(o=i2)}this.updateStatus(!1,o)},t.componentWillUnmount=function(){this.cancelNextCallback()},t.getTimeouts=function(){var s=this.props.timeout,o,l,C;return o=l=C=s,s!=null&&typeof s!="number"&&(o=s.exit,l=s.enter,C=s.appear!==void 0?s.appear:l),{exit:o,enter:l,appear:C}},t.updateStatus=function(s,o){if(s===void 0&&(s=!1),o!==null)if(this.cancelNextCallback(),o===a1){if(this.props.unmountOnExit||this.props.mountOnEnter){var l=this.props.nodeRef?this.props.nodeRef.current:A1.findDOMNode(this);l&&E3(l)}this.performEnter(s)}else this.performExit();else this.props.unmountOnExit&&this.state.status===C1&&this.setState({status:b1})},t.performEnter=function(s){var o=this,l=this.props.enter,C=this.context?this.context.isMounting:s,a=this.props.nodeRef?[C]:[A1.findDOMNode(this),C],h=a[0],c=a[1],u=this.getTimeouts(),p=C?u.appear:u.enter;if(!s&&!l||H2.disabled){this.safeSetState({status:_1},function(){o.props.onEntered(h)});return}this.props.onEnter(h,c),this.safeSetState({status:a1},function(){o.props.onEntering(h,c),o.onTransitionEnd(p,function(){o.safeSetState({status:_1},function(){o.props.onEntered(h,c)})})})},t.performExit=function(){var s=this,o=this.props.exit,l=this.getTimeouts(),C=this.props.nodeRef?void 0:A1.findDOMNode(this);if(!o||H2.disabled){this.safeSetState({status:C1},function(){s.props.onExited(C)});return}this.props.onExit(C),this.safeSetState({status:i2},function(){s.props.onExiting(C),s.onTransitionEnd(l.exit,function(){s.safeSetState({status:C1},function(){s.props.onExited(C)})})})},t.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},t.safeSetState=function(s,o){o=this.setNextCallback(o),this.setState(s,o)},t.setNextCallback=function(s){var o=this,l=!0;return this.nextCallback=function(C){l&&(l=!1,o.nextCallback=null,s(C))},this.nextCallback.cancel=function(){l=!1},this.nextCallback},t.onTransitionEnd=function(s,o){this.setNextCallback(o);var l=this.props.nodeRef?this.props.nodeRef.current:A1.findDOMNode(this),C=s==null&&!this.props.addEndListener;if(!l||C){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var a=this.props.nodeRef?[this.nextCallback]:[l,this.nextCallback],h=a[0],c=a[1];this.props.addEndListener(h,c)}s!=null&&setTimeout(this.nextCallback,s)},t.render=function(){var s=this.state.status;if(s===b1)return null;var o=this.props,l=o.children;o.in,o.mountOnEnter,o.unmountOnExit,o.appear,o.enter,o.exit,o.timeout,o.addEndListener,o.onEnter,o.onEntering,o.onEntered,o.onExit,o.onExiting,o.onExited,o.nodeRef;var C=r1(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return Z1.createElement(G2.Provider,{value:null},typeof l=="function"?l(s,C):Z1.cloneElement(Z1.Children.only(l),C))},n}(Z1.Component);l1.contextType=G2;l1.propTypes={};function v1(){}l1.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:v1,onEntering:v1,onEntered:v1,onExit:v1,onExiting:v1,onExited:v1};l1.UNMOUNTED=b1;l1.EXITED=C1;l1.ENTERING=a1;l1.ENTERED=_1;l1.EXITING=i2;const Q2=l1,J2=e=>e.scrollTop;function D1(e,n){var t,i;const{timeout:s,easing:o,style:l={}}=e;return{duration:(t=l.transitionDuration)!=null?t:typeof s=="number"?s:s[n.mode]||0,easing:(i=l.transitionTimingFunction)!=null?i:typeof o=="object"?o[n.mode]:o,delay:l.transitionDelay}}function S3(e){return N1("MuiPaper",e)}R1("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const I3=["className","component","elevation","square","variant"],P3=e=>{const{square:n,elevation:t,variant:i,classes:s}=e,o={root:["root",i,!n&&"rounded",i==="elevation"&&`elevation${t}`]};return O1(o,S3,s)},B3=u1("div",{name:"MuiPaper",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,n[t.variant],!t.square&&n.rounded,t.variant==="elevation"&&n[`elevation${t.elevation}`]]}})(({theme:e,ownerState:n})=>{var t;return Z({backgroundColor:(e.vars||e).palette.background.paper,color:(e.vars||e).palette.text.primary,transition:e.transitions.create("box-shadow")},!n.square&&{borderRadius:e.shape.borderRadius},n.variant==="outlined"&&{border:`1px solid ${(e.vars||e).palette.divider}`},n.variant==="elevation"&&Z({boxShadow:(e.vars||e).shadows[n.elevation]},!e.vars&&e.palette.mode==="dark"&&{backgroundImage:`linear-gradient(${F1("#fff",L2(n.elevation))}, ${F1("#fff",L2(n.elevation))})`},e.vars&&{backgroundImage:(t=e.vars.overlays)==null?void 0:t[n.elevation]}))}),T3=H.forwardRef(function(n,t){const i=U1({props:n,name:"MuiPaper"}),{className:s,component:o="div",elevation:l=1,square:C=!1,variant:a="elevation"}=i,h=r1(i,I3),c=Z({},i,{component:o,elevation:l,square:C,variant:a}),u=P3(c);return r.jsx(B3,Z({as:o,ownerState:c,className:c1(u.root,s),ref:t},h))}),N3=T3;function R3(e){return N1("MuiIconButton",e)}const U3=R1("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge"]),O3=U3,A3=["edge","children","className","color","disabled","disableFocusRipple","size"],$3=e=>{const{classes:n,disabled:t,color:i,edge:s,size:o}=e,l={root:["root",t&&"disabled",i!=="default"&&`color${k1(i)}`,s&&`edge${k1(s)}`,`size${k1(o)}`]};return O1(l,R3,n)},z3=u1(w3,{name:"MuiIconButton",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,t.color!=="default"&&n[`color${k1(t.color)}`],t.edge&&n[`edge${k1(t.edge)}`],n[`size${k1(t.size)}`]]}})(({theme:e,ownerState:n})=>Z({textAlign:"center",flex:"0 0 auto",fontSize:e.typography.pxToRem(24),padding:8,borderRadius:"50%",overflow:"visible",color:(e.vars||e).palette.action.active,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest})},!n.disableRipple&&{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:F1(e.palette.action.active,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},n.edge==="start"&&{marginLeft:n.size==="small"?-3:-12},n.edge==="end"&&{marginRight:n.size==="small"?-3:-12}),({theme:e,ownerState:n})=>{var t;const i=(t=(e.vars||e).palette)==null?void 0:t[n.color];return Z({},n.color==="inherit"&&{color:"inherit"},n.color!=="inherit"&&n.color!=="default"&&Z({color:i==null?void 0:i.main},!n.disableRipple&&{"&:hover":Z({},i&&{backgroundColor:e.vars?`rgba(${i.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:F1(i.main,e.palette.action.hoverOpacity)},{"@media (hover: none)":{backgroundColor:"transparent"}})}),n.size==="small"&&{padding:5,fontSize:e.typography.pxToRem(18)},n.size==="large"&&{padding:12,fontSize:e.typography.pxToRem(28)},{[`&.${O3.disabled}`]:{backgroundColor:"transparent",color:(e.vars||e).palette.action.disabled}})}),F3=H.forwardRef(function(n,t){const i=U1({props:n,name:"MuiIconButton"}),{edge:s=!1,children:o,className:l,color:C="default",disabled:a=!1,disableFocusRipple:h=!1,size:c="medium"}=i,u=r1(i,A3),p=Z({},i,{edge:s,color:C,disabled:a,disableFocusRipple:h,size:c}),x=$3(p);return r.jsx(z3,Z({className:c1(x.root,l),centerRipple:!0,focusRipple:!h,disabled:a,ref:t,ownerState:p},u,{children:o}))}),e3=F3;function t3(e){return typeof e=="string"}function D3(e,n,t){return e===void 0||t3(e)?n:Z({},n,{ownerState:Z({},n.ownerState,t)})}function n3(e,n=[]){if(e===void 0)return{};const t={};return Object.keys(e).filter(i=>i.match(/^on[A-Z]/)&&typeof e[i]=="function"&&!n.includes(i)).forEach(i=>{t[i]=e[i]}),t}function q3(e,n,t){return typeof e=="function"?e(n,t):e}function r3(e){var n,t,i="";if(typeof e=="string"||typeof e=="number")i+=e;else if(typeof e=="object")if(Array.isArray(e))for(n=0;n!(t.match(/^on[A-Z]/)&&typeof e[t]=="function")).forEach(t=>{n[t]=e[t]}),n}function G3(e){const{getSlotProps:n,additionalProps:t,externalSlotProps:i,externalForwardedProps:s,className:o}=e;if(!n){const x=M2(t==null?void 0:t.className,o,s==null?void 0:s.className,i==null?void 0:i.className),f=Z({},t==null?void 0:t.style,s==null?void 0:s.style,i==null?void 0:i.style),_=Z({},t,s,i);return x.length>0&&(_.className=x),Object.keys(f).length>0&&(_.style=f),{props:_,internalRef:void 0}}const l=n3(Z({},s,i)),C=V2(i),a=V2(s),h=n(l),c=M2(h==null?void 0:h.className,t==null?void 0:t.className,o,s==null?void 0:s.className,i==null?void 0:i.className),u=Z({},h==null?void 0:h.style,t==null?void 0:t.style,s==null?void 0:s.style,i==null?void 0:i.style),p=Z({},h,t,a,C);return c.length>0&&(p.className=c),Object.keys(u).length>0&&(p.style=u),{props:p,internalRef:h.ref}}const W3=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function q1(e){var n;const{elementType:t,externalSlotProps:i,ownerState:s,skipResolvingSlotProps:o=!1}=e,l=r1(e,W3),C=o?{}:q3(i,s),{props:a,internalRef:h}=G3(Z({},l,{externalSlotProps:C})),c=d1(h,C==null?void 0:C.ref,(n=e.additionalProps)==null?void 0:n.ref);return D3(t,Z({},a,{ref:c}),s)}const X3=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function Y3(e){const n=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(n)?e.contentEditable==="true"||(e.nodeName==="AUDIO"||e.nodeName==="VIDEO"||e.nodeName==="DETAILS")&&e.getAttribute("tabindex")===null?0:e.tabIndex:n}function K3(e){if(e.tagName!=="INPUT"||e.type!=="radio"||!e.name)return!1;const n=i=>e.ownerDocument.querySelector(`input[type="radio"]${i}`);let t=n(`[name="${e.name}"]:checked`);return t||(t=n(`[name="${e.name}"]`)),t!==e}function Q3(e){return!(e.disabled||e.tagName==="INPUT"&&e.type==="hidden"||K3(e))}function J3(e){const n=[],t=[];return Array.from(e.querySelectorAll(X3)).forEach((i,s)=>{const o=Y3(i);o===-1||!Q3(i)||(o===0?n.push(i):t.push({documentOrder:s,tabIndex:o,node:i}))}),t.sort((i,s)=>i.tabIndex===s.tabIndex?i.documentOrder-s.documentOrder:i.tabIndex-s.tabIndex).map(i=>i.node).concat(n)}function e5(){return!0}function t5(e){const{children:n,disableAutoFocus:t=!1,disableEnforceFocus:i=!1,disableRestoreFocus:s=!1,getTabbable:o=J3,isEnabled:l=e5,open:C}=e,a=H.useRef(!1),h=H.useRef(null),c=H.useRef(null),u=H.useRef(null),p=H.useRef(null),x=H.useRef(!1),f=H.useRef(null),_=d1(n.ref,f),w=H.useRef(null);H.useEffect(()=>{!C||!f.current||(x.current=!t)},[t,C]),H.useEffect(()=>{if(!C||!f.current)return;const g=s1(f.current);return f.current.contains(g.activeElement)||(f.current.hasAttribute("tabIndex")||f.current.setAttribute("tabIndex","-1"),x.current&&f.current.focus()),()=>{s||(u.current&&u.current.focus&&(a.current=!0,u.current.focus()),u.current=null)}},[C]),H.useEffect(()=>{if(!C||!f.current)return;const g=s1(f.current),v=j=>{w.current=j,!(i||!l()||j.key!=="Tab")&&g.activeElement===f.current&&j.shiftKey&&(a.current=!0,c.current&&c.current.focus())},m=()=>{const j=f.current;if(j===null)return;if(!g.hasFocus()||!l()||a.current){a.current=!1;return}if(j.contains(g.activeElement)||i&&g.activeElement!==h.current&&g.activeElement!==c.current)return;if(g.activeElement!==p.current)p.current=null;else if(p.current!==null)return;if(!x.current)return;let L=[];if((g.activeElement===h.current||g.activeElement===c.current)&&(L=o(f.current)),L.length>0){var M,S;const P=!!((M=w.current)!=null&&M.shiftKey&&((S=w.current)==null?void 0:S.key)==="Tab"),V=L[0],U=L[L.length-1];typeof V!="string"&&typeof U!="string"&&(P?U.focus():V.focus())}else j.focus()};g.addEventListener("focusin",m),g.addEventListener("keydown",v,!0);const y=setInterval(()=>{g.activeElement&&g.activeElement.tagName==="BODY"&&m()},50);return()=>{clearInterval(y),g.removeEventListener("focusin",m),g.removeEventListener("keydown",v,!0)}},[t,i,s,l,C,o]);const d=g=>{u.current===null&&(u.current=g.relatedTarget),x.current=!0,p.current=g.target;const v=n.props.onFocus;v&&v(g)},k=g=>{u.current===null&&(u.current=g.relatedTarget),x.current=!0};return r.jsxs(H.Fragment,{children:[r.jsx("div",{tabIndex:C?0:-1,onFocus:k,ref:h,"data-testid":"sentinelStart"}),H.cloneElement(n,{ref:_,onFocus:d}),r.jsx("div",{tabIndex:C?0:-1,onFocus:k,ref:c,"data-testid":"sentinelEnd"})]})}function n5(e){return typeof e=="function"?e():e}const r5=H.forwardRef(function(n,t){const{children:i,container:s,disablePortal:o=!1}=n,[l,C]=H.useState(null),a=d1(H.isValidElement(i)?i.ref:null,t);if(_2(()=>{o||C(n5(s)||document.body)},[s,o]),_2(()=>{if(l&&!o)return k2(t,l),()=>{k2(t,null)}},[t,l,o]),o){if(H.isValidElement(i)){const h={ref:a};return H.cloneElement(i,h)}return r.jsx(H.Fragment,{children:i})}return r.jsx(H.Fragment,{children:l&&v3.createPortal(i,l)})});function i5(e){const n=s1(e);return n.body===e?B1(e).innerWidth>n.documentElement.clientWidth:e.scrollHeight>e.clientHeight}function P1(e,n){n?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function Z2(e){return parseInt(B1(e).getComputedStyle(e).paddingRight,10)||0}function s5(e){const t=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].indexOf(e.tagName)!==-1,i=e.tagName==="INPUT"&&e.getAttribute("type")==="hidden";return t||i}function b2(e,n,t,i,s){const o=[n,t,...i];[].forEach.call(e.children,l=>{const C=o.indexOf(l)===-1,a=!s5(l);C&&a&&P1(l,s)})}function Q1(e,n){let t=-1;return e.some((i,s)=>n(i)?(t=s,!0):!1),t}function o5(e,n){const t=[],i=e.container;if(!n.disableScrollLock){if(i5(i)){const l=Z3(s1(i));t.push({value:i.style.paddingRight,property:"padding-right",el:i}),i.style.paddingRight=`${Z2(i)+l}px`;const C=s1(i).querySelectorAll(".mui-fixed");[].forEach.call(C,a=>{t.push({value:a.style.paddingRight,property:"padding-right",el:a}),a.style.paddingRight=`${Z2(a)+l}px`})}let o;if(i.parentNode instanceof DocumentFragment)o=s1(i).body;else{const l=i.parentElement,C=B1(i);o=(l==null?void 0:l.nodeName)==="HTML"&&C.getComputedStyle(l).overflowY==="scroll"?l:i}t.push({value:o.style.overflow,property:"overflow",el:o},{value:o.style.overflowX,property:"overflow-x",el:o},{value:o.style.overflowY,property:"overflow-y",el:o}),o.style.overflow="hidden"}return()=>{t.forEach(({value:o,el:l,property:C})=>{o?l.style.setProperty(C,o):l.style.removeProperty(C)})}}function l5(e){const n=[];return[].forEach.call(e.children,t=>{t.getAttribute("aria-hidden")==="true"&&n.push(t)}),n}class C5{constructor(){this.containers=void 0,this.modals=void 0,this.modals=[],this.containers=[]}add(n,t){let i=this.modals.indexOf(n);if(i!==-1)return i;i=this.modals.length,this.modals.push(n),n.modalRef&&P1(n.modalRef,!1);const s=l5(t);b2(t,n.mount,n.modalRef,s,!0);const o=Q1(this.containers,l=>l.container===t);return o!==-1?(this.containers[o].modals.push(n),i):(this.containers.push({modals:[n],container:t,restore:null,hiddenSiblings:s}),i)}mount(n,t){const i=Q1(this.containers,o=>o.modals.indexOf(n)!==-1),s=this.containers[i];s.restore||(s.restore=o5(s,t))}remove(n,t=!0){const i=this.modals.indexOf(n);if(i===-1)return i;const s=Q1(this.containers,l=>l.modals.indexOf(n)!==-1),o=this.containers[s];if(o.modals.splice(o.modals.indexOf(n),1),this.modals.splice(i,1),o.modals.length===0)o.restore&&o.restore(),n.modalRef&&P1(n.modalRef,t),b2(o.container,n.mount,n.modalRef,o.hiddenSiblings,!1),this.containers.splice(s,1);else{const l=o.modals[o.modals.length-1];l.modalRef&&P1(l.modalRef,!1)}return i}isTopModal(n){return this.modals.length>0&&this.modals[this.modals.length-1]===n}}function a5(e){return typeof e=="function"?e():e}function c5(e){return e?e.props.hasOwnProperty("in"):!1}const h5=new C5;function u5(e){const{container:n,disableEscapeKeyDown:t=!1,disableScrollLock:i=!1,manager:s=h5,closeAfterTransition:o=!1,onTransitionEnter:l,onTransitionExited:C,children:a,onClose:h,open:c,rootRef:u}=e,p=H.useRef({}),x=H.useRef(null),f=H.useRef(null),_=d1(f,u),[w,d]=H.useState(!c),k=c5(a);let g=!0;(e["aria-hidden"]==="false"||e["aria-hidden"]===!1)&&(g=!1);const v=()=>s1(x.current),m=()=>(p.current.modalRef=f.current,p.current.mount=x.current,p.current),y=()=>{s.mount(m(),{disableScrollLock:i}),f.current&&(f.current.scrollTop=0)},j=y2(()=>{const E=a5(n)||v().body;s.add(m(),E),f.current&&y()}),L=H.useCallback(()=>s.isTopModal(m()),[s]),M=y2(E=>{x.current=E,E&&(c&&L()?y():f.current&&P1(f.current,g))}),S=H.useCallback(()=>{s.remove(m(),g)},[g,s]);H.useEffect(()=>()=>{S()},[S]),H.useEffect(()=>{c?j():(!k||!o)&&S()},[c,S,k,o,j]);const P=E=>I=>{var z;(z=E.onKeyDown)==null||z.call(E,I),!(I.key!=="Escape"||I.which===229||!L())&&(t||(I.stopPropagation(),h&&h(I,"escapeKeyDown")))},V=E=>I=>{var z;(z=E.onClick)==null||z.call(E,I),I.target===I.currentTarget&&h&&h(I,"backdropClick")};return{getRootProps:(E={})=>{const I=n3(e);delete I.onTransitionEnter,delete I.onTransitionExited;const z=Z({},I,E);return Z({role:"presentation"},z,{onKeyDown:P(z),ref:_})},getBackdropProps:(E={})=>{const I=E;return Z({"aria-hidden":!0},I,{onClick:V(I),open:c})},getTransitionProps:()=>{const E=()=>{d(!1),l&&l()},I=()=>{d(!0),C&&C(),o&&S()};return{onEnter:j2(E,a==null?void 0:a.props.onEnter),onExited:j2(I,a==null?void 0:a.props.onExited)}},rootRef:_,portalRef:M,isTopModal:L,exited:w,hasTransition:k}}const d5=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"],f5={entering:{opacity:1},entered:{opacity:1}},p5=H.forwardRef(function(n,t){const i=W2(),s={enter:i.transitions.duration.enteringScreen,exit:i.transitions.duration.leavingScreen},{addEndListener:o,appear:l=!0,children:C,easing:a,in:h,onEnter:c,onEntered:u,onEntering:p,onExit:x,onExited:f,onExiting:_,style:w,timeout:d=s,TransitionComponent:k=Q2}=n,g=r1(n,d5),v=H.useRef(null),m=d1(v,C.ref,t),y=B=>b=>{if(B){const E=v.current;b===void 0?B(E):B(E,b)}},j=y(p),L=y((B,b)=>{J2(B);const E=D1({style:w,timeout:d,easing:a},{mode:"enter"});B.style.webkitTransition=i.transitions.create("opacity",E),B.style.transition=i.transitions.create("opacity",E),c&&c(B,b)}),M=y(u),S=y(_),P=y(B=>{const b=D1({style:w,timeout:d,easing:a},{mode:"exit"});B.style.webkitTransition=i.transitions.create("opacity",b),B.style.transition=i.transitions.create("opacity",b),x&&x(B)}),V=y(f),U=B=>{o&&o(v.current,B)};return r.jsx(k,Z({appear:l,in:h,nodeRef:v,onEnter:L,onEntered:M,onEntering:j,onExit:P,onExited:V,onExiting:S,addEndListener:U,timeout:d},g,{children:(B,b)=>H.cloneElement(C,Z({style:Z({opacity:0,visibility:B==="exited"&&!h?"hidden":void 0},f5[B],w,C.props.style),ref:m},b))}))}),x5=p5;function g5(e){return N1("MuiBackdrop",e)}R1("MuiBackdrop",["root","invisible"]);const m5=["children","className","component","components","componentsProps","invisible","open","slotProps","slots","TransitionComponent","transitionDuration"],w5=e=>{const{classes:n,invisible:t}=e;return O1({root:["root",t&&"invisible"]},g5,n)},v5=u1("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,t.invisible&&n.invisible]}})(({ownerState:e})=>Z({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent"},e.invisible&&{backgroundColor:"transparent"})),_5=H.forwardRef(function(n,t){var i,s,o;const l=U1({props:n,name:"MuiBackdrop"}),{children:C,className:a,component:h="div",components:c={},componentsProps:u={},invisible:p=!1,open:x,slotProps:f={},slots:_={},TransitionComponent:w=x5,transitionDuration:d}=l,k=r1(l,m5),g=Z({},l,{component:h,invisible:p}),v=w5(g),m=(i=f.root)!=null?i:u.root;return r.jsx(w,Z({in:x,timeout:d},k,{children:r.jsx(v5,Z({"aria-hidden":!0},m,{as:(s=(o=_.root)!=null?o:c.Root)!=null?s:h,className:c1(v.root,a,m==null?void 0:m.className),ownerState:Z({},g,m==null?void 0:m.ownerState),classes:v,ref:t,children:C}))}))}),k5=_5;function y5(e){return N1("MuiModal",e)}R1("MuiModal",["root","hidden","backdrop"]);const j5=["BackdropComponent","BackdropProps","classes","className","closeAfterTransition","children","container","component","components","componentsProps","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","onBackdropClick","onClose","onTransitionEnter","onTransitionExited","open","slotProps","slots","theme"],L5=e=>{const{open:n,exited:t,classes:i}=e;return O1({root:["root",!n&&t&&"hidden"],backdrop:["backdrop"]},y5,i)},H5=u1("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,!t.open&&t.exited&&n.hidden]}})(({theme:e,ownerState:n})=>Z({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0},!n.open&&n.exited&&{visibility:"hidden"})),M5=u1(k5,{name:"MuiModal",slot:"Backdrop",overridesResolver:(e,n)=>n.backdrop})({zIndex:-1}),V5=H.forwardRef(function(n,t){var i,s,o,l,C,a;const h=U1({name:"MuiModal",props:n}),{BackdropComponent:c=M5,BackdropProps:u,className:p,closeAfterTransition:x=!1,children:f,container:_,component:w,components:d={},componentsProps:k={},disableAutoFocus:g=!1,disableEnforceFocus:v=!1,disableEscapeKeyDown:m=!1,disablePortal:y=!1,disableRestoreFocus:j=!1,disableScrollLock:L=!1,hideBackdrop:M=!1,keepMounted:S=!1,onBackdropClick:P,open:V,slotProps:U,slots:B}=h,b=r1(h,j5),E=Z({},h,{closeAfterTransition:x,disableAutoFocus:g,disableEnforceFocus:v,disableEscapeKeyDown:m,disablePortal:y,disableRestoreFocus:j,disableScrollLock:L,hideBackdrop:M,keepMounted:S}),{getRootProps:I,getBackdropProps:z,getTransitionProps:R,portalRef:W,isTopModal:O,exited:A,hasTransition:J}=u5(Z({},E,{rootRef:t})),D=Z({},E,{exited:A}),$=L5(D),p1={};if(f.props.tabIndex===void 0&&(p1.tabIndex="-1"),J){const{onEnter:T,onExited:F}=R();p1.onEnter=T,p1.onExited=F}const x1=(i=(s=B==null?void 0:B.root)!=null?s:d.Root)!=null?i:H5,L1=(o=(l=B==null?void 0:B.backdrop)!=null?l:d.Backdrop)!=null?o:c,H1=(C=U==null?void 0:U.root)!=null?C:k.root,g1=(a=U==null?void 0:U.backdrop)!=null?a:k.backdrop,Y1=q1({elementType:x1,externalSlotProps:H1,externalForwardedProps:b,getSlotProps:I,additionalProps:{ref:t,as:w},ownerState:D,className:c1(p,H1==null?void 0:H1.className,$==null?void 0:$.root,!D.open&&D.exited&&($==null?void 0:$.hidden))}),K1=q1({elementType:L1,externalSlotProps:g1,additionalProps:u,getSlotProps:T=>z(Z({},T,{onClick:F=>{P&&P(F),T!=null&&T.onClick&&T.onClick(F)}})),className:c1(g1==null?void 0:g1.className,u==null?void 0:u.className,$==null?void 0:$.backdrop),ownerState:D});return!S&&!V&&(!J||A)?null:r.jsx(r5,{ref:W,container:_,disablePortal:y,children:r.jsxs(x1,Z({},Y1,{children:[!M&&c?r.jsx(L1,Z({},K1)):null,r.jsx(t5,{disableEnforceFocus:v,disableAutoFocus:g,disableRestoreFocus:j,isEnabled:O,open:V,children:H.cloneElement(f,p1)})]}))})}),Z5=V5,b5=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function s2(e){return`scale(${e}, ${e**2})`}const E5={entering:{opacity:1,transform:s2(1)},entered:{opacity:1,transform:"none"}},J1=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),i3=H.forwardRef(function(n,t){const{addEndListener:i,appear:s=!0,children:o,easing:l,in:C,onEnter:a,onEntered:h,onEntering:c,onExit:u,onExited:p,onExiting:x,style:f,timeout:_="auto",TransitionComponent:w=Q2}=n,d=r1(n,b5),k=H.useRef(),g=H.useRef(),v=W2(),m=H.useRef(null),y=d1(m,o.ref,t),j=b=>E=>{if(b){const I=m.current;E===void 0?b(I):b(I,E)}},L=j(c),M=j((b,E)=>{J2(b);const{duration:I,delay:z,easing:R}=D1({style:f,timeout:_,easing:l},{mode:"enter"});let W;_==="auto"?(W=v.transitions.getAutoHeightDuration(b.clientHeight),g.current=W):W=I,b.style.transition=[v.transitions.create("opacity",{duration:W,delay:z}),v.transitions.create("transform",{duration:J1?W:W*.666,delay:z,easing:R})].join(","),a&&a(b,E)}),S=j(h),P=j(x),V=j(b=>{const{duration:E,delay:I,easing:z}=D1({style:f,timeout:_,easing:l},{mode:"exit"});let R;_==="auto"?(R=v.transitions.getAutoHeightDuration(b.clientHeight),g.current=R):R=E,b.style.transition=[v.transitions.create("opacity",{duration:R,delay:I}),v.transitions.create("transform",{duration:J1?R:R*.666,delay:J1?I:I||R*.333,easing:z})].join(","),b.style.opacity=0,b.style.transform=s2(.75),u&&u(b)}),U=j(p),B=b=>{_==="auto"&&(k.current=setTimeout(b,g.current||0)),i&&i(m.current,b)};return H.useEffect(()=>()=>{clearTimeout(k.current)},[]),r.jsx(w,Z({appear:s,in:C,nodeRef:m,onEnter:M,onEntered:S,onEntering:L,onExit:V,onExited:U,onExiting:P,addEndListener:B,timeout:_==="auto"?null:_},d,{children:(b,E)=>H.cloneElement(o,Z({style:Z({opacity:0,transform:s2(.75),visibility:b==="exited"&&!C?"hidden":void 0},E5[b],f,o.props.style),ref:y},E))}))});i3.muiSupportAuto=!0;const S5=i3;function I5(e){return N1("MuiPopover",e)}R1("MuiPopover",["root","paper"]);const P5=["onEntering"],B5=["action","anchorEl","anchorOrigin","anchorPosition","anchorReference","children","className","container","elevation","marginThreshold","open","PaperProps","slots","slotProps","transformOrigin","TransitionComponent","transitionDuration","TransitionProps","disableScrollLock"],T5=["slotProps"];function E2(e,n){let t=0;return typeof n=="number"?t=n:n==="center"?t=e.height/2:n==="bottom"&&(t=e.height),t}function S2(e,n){let t=0;return typeof n=="number"?t=n:n==="center"?t=e.width/2:n==="right"&&(t=e.width),t}function I2(e){return[e.horizontal,e.vertical].map(n=>typeof n=="number"?`${n}px`:n).join(" ")}function e2(e){return typeof e=="function"?e():e}const N5=e=>{const{classes:n}=e;return O1({root:["root"],paper:["paper"]},I5,n)},R5=u1(Z5,{name:"MuiPopover",slot:"Root",overridesResolver:(e,n)=>n.root})({}),U5=u1(N3,{name:"MuiPopover",slot:"Paper",overridesResolver:(e,n)=>n.paper})({position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}),O5=H.forwardRef(function(n,t){var i,s,o;const l=U1({props:n,name:"MuiPopover"}),{action:C,anchorEl:a,anchorOrigin:h={vertical:"top",horizontal:"left"},anchorPosition:c,anchorReference:u="anchorEl",children:p,className:x,container:f,elevation:_=8,marginThreshold:w=16,open:d,PaperProps:k={},slots:g,slotProps:v,transformOrigin:m={vertical:"top",horizontal:"left"},TransitionComponent:y=S5,transitionDuration:j="auto",TransitionProps:{onEntering:L}={},disableScrollLock:M=!1}=l,S=r1(l.TransitionProps,P5),P=r1(l,B5),V=(i=v==null?void 0:v.paper)!=null?i:k,U=H.useRef(),B=d1(U,V.ref),b=Z({},l,{anchorOrigin:h,anchorReference:u,elevation:_,marginThreshold:w,externalPaperSlotProps:V,transformOrigin:m,TransitionComponent:y,transitionDuration:j,TransitionProps:S}),E=N5(b),I=H.useCallback(()=>{if(u==="anchorPosition")return c;const T=e2(a),e1=(T&&T.nodeType===1?T:s1(U.current).body).getBoundingClientRect();return{top:e1.top+E2(e1,h.vertical),left:e1.left+S2(e1,h.horizontal)}},[a,h.horizontal,h.vertical,c,u]),z=H.useCallback(T=>({vertical:E2(T,m.vertical),horizontal:S2(T,m.horizontal)}),[m.horizontal,m.vertical]),R=H.useCallback(T=>{const F={width:T.offsetWidth,height:T.offsetHeight},e1=z(F);if(u==="none")return{top:null,left:null,transformOrigin:I2(e1)};const p2=I();let m1=p2.top-e1.vertical,w1=p2.left-e1.horizontal;const x2=m1+F.height,g2=w1+F.width,m2=B1(e2(a)),w2=m2.innerHeight-w,v2=m2.innerWidth-w;if(w!==null&&m1w2){const n1=x2-w2;m1-=n1,e1.vertical+=n1}if(w!==null&&w1v2){const n1=g2-v2;w1-=n1,e1.horizontal+=n1}return{top:`${Math.round(m1)}px`,left:`${Math.round(w1)}px`,transformOrigin:I2(e1)}},[a,u,I,z,w]),[W,O]=H.useState(d),A=H.useCallback(()=>{const T=U.current;if(!T)return;const F=R(T);F.top!==null&&(T.style.top=F.top),F.left!==null&&(T.style.left=F.left),T.style.transformOrigin=F.transformOrigin,O(!0)},[R]);H.useEffect(()=>(M&&window.addEventListener("scroll",A),()=>window.removeEventListener("scroll",A)),[a,M,A]);const J=(T,F)=>{L&&L(T,F),A()},D=()=>{O(!1)};H.useEffect(()=>{d&&A()}),H.useImperativeHandle(C,()=>d?{updatePosition:()=>{A()}}:null,[d,A]),H.useEffect(()=>{if(!d)return;const T=V3(()=>{A()}),F=B1(a);return F.addEventListener("resize",T),()=>{T.clear(),F.removeEventListener("resize",T)}},[a,d,A]);let $=j;j==="auto"&&!y.muiSupportAuto&&($=void 0);const p1=f||(a?s1(e2(a)).body:void 0),x1=(s=g==null?void 0:g.root)!=null?s:R5,L1=(o=g==null?void 0:g.paper)!=null?o:U5,H1=q1({elementType:L1,externalSlotProps:Z({},V,{style:W?V.style:Z({},V.style,{opacity:0})}),additionalProps:{elevation:_,ref:B},ownerState:b,className:c1(E.paper,V==null?void 0:V.className)}),g1=q1({elementType:x1,externalSlotProps:(v==null?void 0:v.root)||{},externalForwardedProps:P,additionalProps:{ref:t,slotProps:{backdrop:{invisible:!0}},container:p1,open:d},ownerState:b,className:c1(E.root,x)}),{slotProps:Y1}=g1,K1=r1(g1,T5);return r.jsx(x1,Z({},K1,!t3(x1)&&{slotProps:Y1,disableScrollLock:M},{children:r.jsx(y,Z({appear:!0,in:d,onEntering:J,onExited:D,timeout:$},S,{children:r.jsx(L1,Z({},H1,{children:p}))}))}))}),b7=O5;function A5(e,n){if(Object.is(e,n))return!0;if(typeof e!="object"||e===null||typeof n!="object"||n===null)return!1;if(e instanceof Map&&n instanceof Map){if(e.size!==n.size)return!1;for(const[i,s]of e)if(!Object.is(s,n.get(i)))return!1;return!0}if(e instanceof Set&&n instanceof Set){if(e.size!==n.size)return!1;for(const i of e)if(!n.has(i))return!1;return!0}const t=Object.keys(e);if(t.length!==Object.keys(n).length)return!1;for(let i=0;i{const i=e(t);return A5(n.current,i)?n.current:n.current=i}}const F5=e=>r.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:r.jsxs("g",{id:"bubble_chart",children:[r.jsx("mask",{id:"mask0_1551_42",maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"20",height:"20",children:r.jsx("rect",{id:"Bounding box",width:"1em",height:"1em",fill:"currentColor"})}),r.jsx("g",{mask:"url(#mask0_1551_42)",children:r.jsx("path",{id:"bubble_chart_2",d:"M5.83333 15C4.91667 15 4.13194 14.6736 3.47917 14.0208C2.82639 13.3681 2.5 12.5833 2.5 11.6667C2.5 10.75 2.82639 9.96528 3.47917 9.3125C4.13194 8.65972 4.91667 8.33333 5.83333 8.33333C6.75 8.33333 7.53472 8.65972 8.1875 9.3125C8.84028 9.96528 9.16667 10.75 9.16667 11.6667C9.16667 12.5833 8.84028 13.3681 8.1875 14.0208C7.53472 14.6736 6.75 15 5.83333 15ZM13.75 11.6667C12.4722 11.6667 11.3889 11.2222 10.5 10.3333C9.61111 9.44444 9.16667 8.36111 9.16667 7.08333C9.16667 5.80556 9.61111 4.72222 10.5 3.83333C11.3889 2.94444 12.4722 2.5 13.75 2.5C15.0278 2.5 16.1111 2.94444 17 3.83333C17.8889 4.72222 18.3333 5.80556 18.3333 7.08333C18.3333 8.36111 17.8889 9.44444 17 10.3333C16.1111 11.2222 15.0278 11.6667 13.75 11.6667ZM12.0833 17.5C11.3889 17.5 10.7986 17.2569 10.3125 16.7708C9.82639 16.2847 9.58333 15.6944 9.58333 15C9.58333 14.3056 9.82639 13.7153 10.3125 13.2292C10.7986 12.7431 11.3889 12.5 12.0833 12.5C12.7778 12.5 13.3681 12.7431 13.8542 13.2292C14.3403 13.7153 14.5833 14.3056 14.5833 15C14.5833 15.6944 14.3403 16.2847 13.8542 16.7708C13.3681 17.2569 12.7778 17.5 12.0833 17.5Z",fill:"currentColor"})})]})}),D5=e=>r.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:r.jsxs("g",{id:"communities",children:[r.jsx("mask",{id:"mask0_1551_39",maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"20",height:"20",children:r.jsx("rect",{id:"Bounding box",width:"1em",height:"1em",fill:"currentColor"})}),r.jsx("g",{mask:"url(#mask0_1551_39)",children:r.jsx("path",{id:"communities_2",d:"M7.50002 13.125C7.90494 13.125 8.24921 12.9832 8.53285 12.6995C8.81651 12.4159 8.95833 12.0716 8.95833 11.6667C8.95833 11.2618 8.81651 10.9175 8.53285 10.6339C8.24921 10.3502 7.90494 10.2084 7.50002 10.2084C7.0951 10.2084 6.75083 10.3502 6.46719 10.6339C6.18353 10.9175 6.04171 11.2618 6.04171 11.6667C6.04171 12.0716 6.18353 12.4159 6.46719 12.6995C6.75083 12.9832 7.0951 13.125 7.50002 13.125ZM12.5 13.125C12.9049 13.125 13.2492 12.9832 13.5329 12.6995C13.8165 12.4159 13.9583 12.0716 13.9583 11.6667C13.9583 11.2618 13.8165 10.9175 13.5329 10.6339C13.2492 10.3502 12.9049 10.2084 12.5 10.2084C12.0951 10.2084 11.7508 10.3502 11.4672 10.6339C11.1835 10.9175 11.0417 11.2618 11.0417 11.6667C11.0417 12.0716 11.1835 12.4159 11.4672 12.6995C11.7508 12.9832 12.0951 13.125 12.5 13.125ZM10 8.95833C10.4049 8.95833 10.7492 8.81651 11.0329 8.53285C11.3165 8.24922 11.4583 7.90494 11.4583 7.50002C11.4583 7.0951 11.3165 6.75083 11.0329 6.46719C10.7492 6.18354 10.4049 6.04171 10 6.04171C9.5951 6.04171 9.25083 6.18354 8.96719 6.46719C8.68354 6.75083 8.54171 7.0951 8.54171 7.50002C8.54171 7.90494 8.68354 8.24922 8.96719 8.53285C9.25083 8.81651 9.5951 8.95833 10 8.95833ZM10.0014 17.9167C8.90647 17.9167 7.87728 17.7089 6.91383 17.2933C5.95037 16.8778 5.1123 16.3138 4.39962 15.6015C3.68693 14.8891 3.12271 14.0514 2.70698 13.0884C2.29124 12.1253 2.08337 11.0964 2.08337 10.0014C2.08337 8.90647 2.29115 7.87728 2.70671 6.91383C3.12226 5.95037 3.68622 5.11231 4.39858 4.39963C5.11096 3.68693 5.94866 3.12272 6.91169 2.70698C7.8747 2.29124 8.90368 2.08337 9.99862 2.08337C11.0936 2.08337 12.1228 2.29115 13.0862 2.70671C14.0497 3.12226 14.8877 3.68622 15.6004 4.39858C16.3131 5.11096 16.8773 5.94866 17.2931 6.91169C17.7088 7.8747 17.9167 8.90368 17.9167 9.99863C17.9167 11.0936 17.7089 12.1228 17.2933 13.0862C16.8778 14.0497 16.3138 14.8877 15.6015 15.6004C14.8891 16.3131 14.0514 16.8773 13.0884 17.2931C12.1253 17.7088 11.0964 17.9167 10.0014 17.9167ZM10 16.6667C11.8611 16.6667 13.4375 16.0209 14.7292 14.7292C16.0209 13.4375 16.6667 11.8611 16.6667 10C16.6667 8.13891 16.0209 6.56252 14.7292 5.27085C13.4375 3.97919 11.8611 3.33335 10 3.33335C8.13891 3.33335 6.56252 3.97919 5.27085 5.27085C3.97919 6.56252 3.33335 8.13891 3.33335 10C3.33335 11.8611 3.97919 13.4375 5.27085 14.7292C6.56252 16.0209 8.13891 16.6667 10 16.6667Z",fill:"currentColor"})})]})}),q5=e=>r.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:r.jsxs("g",{id:"grain",children:[r.jsx("mask",{id:"mask0_1551_45",maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"20",height:"20",children:r.jsx("rect",{id:"Bounding box",width:"1em",height:"1em",fill:"currentColor"})}),r.jsx("g",{mask:"url(#mask0_1551_45)",children:r.jsx("path",{id:"grain_2",d:"M4.99999 16.5064C4.57906 16.5064 4.22276 16.3605 3.93109 16.0689C3.63942 15.7772 3.49359 15.4209 3.49359 15C3.49359 14.5791 3.63942 14.2228 3.93109 13.9311C4.22276 13.6394 4.57906 13.4936 4.99999 13.4936C5.42092 13.4936 5.77722 13.6394 6.06888 13.9311C6.36055 14.2228 6.50638 14.5791 6.50638 15C6.50638 15.4209 6.36055 15.7772 6.06888 16.0689C5.77722 16.3605 5.42092 16.5064 4.99999 16.5064ZM11.6667 16.5064C11.2457 16.5064 10.8894 16.3605 10.5978 16.0689C10.3061 15.7772 10.1603 15.4209 10.1603 15C10.1603 14.5791 10.3061 14.2228 10.5978 13.9311C10.8894 13.6394 11.2457 13.4936 11.6667 13.4936C12.0876 13.4936 12.4439 13.6394 12.7355 13.9311C13.0272 14.2228 13.1731 14.5791 13.1731 15C13.1731 15.4209 13.0272 15.7772 12.7355 16.0689C12.4439 16.3605 12.0876 16.5064 11.6667 16.5064ZM8.33332 13.1731C7.91239 13.1731 7.55609 13.0272 7.26442 12.7355C6.97276 12.4439 6.82692 12.0876 6.82692 11.6667C6.82692 11.2457 6.97276 10.8894 7.26442 10.5978C7.55609 10.3061 7.91239 10.1603 8.33332 10.1603C8.75425 10.1603 9.11055 10.3061 9.40222 10.5978C9.69388 10.8894 9.83972 11.2457 9.83972 11.6667C9.83972 12.0876 9.69388 12.4439 9.40222 12.7355C9.11055 13.0272 8.75425 13.1731 8.33332 13.1731ZM15 13.1731C14.5791 13.1731 14.2228 13.0272 13.9311 12.7355C13.6394 12.4439 13.4936 12.0876 13.4936 11.6667C13.4936 11.2457 13.6394 10.8894 13.9311 10.5978C14.2228 10.3061 14.5791 10.1603 15 10.1603C15.4209 10.1603 15.7772 10.3061 16.0689 10.5978C16.3605 10.8894 16.5064 11.2457 16.5064 11.6667C16.5064 12.0876 16.3605 12.4439 16.0689 12.7355C15.7772 13.0272 15.4209 13.1731 15 13.1731ZM4.99999 9.83972C4.57906 9.83972 4.22276 9.69388 3.93109 9.40222C3.63942 9.11055 3.49359 8.75425 3.49359 8.33332C3.49359 7.91239 3.63942 7.55609 3.93109 7.26442C4.22276 6.97276 4.57906 6.82692 4.99999 6.82692C5.42092 6.82692 5.77722 6.97276 6.06888 7.26442C6.36055 7.55609 6.50638 7.91239 6.50638 8.33332C6.50638 8.75425 6.36055 9.11055 6.06888 9.40222C5.77722 9.69388 5.42092 9.83972 4.99999 9.83972ZM11.6667 9.83972C11.2457 9.83972 10.8894 9.69388 10.5978 9.40222C10.3061 9.11055 10.1603 8.75425 10.1603 8.33332C10.1603 7.91239 10.3061 7.55609 10.5978 7.26442C10.8894 6.97276 11.2457 6.82692 11.6667 6.82692C12.0876 6.82692 12.4439 6.97276 12.7355 7.26442C13.0272 7.55609 13.1731 7.91239 13.1731 8.33332C13.1731 8.75425 13.0272 9.11055 12.7355 9.40222C12.4439 9.69388 12.0876 9.83972 11.6667 9.83972ZM8.33332 6.50638C7.91239 6.50638 7.55609 6.36055 7.26442 6.06888C6.97276 5.77722 6.82692 5.42092 6.82692 4.99999C6.82692 4.57906 6.97276 4.22276 7.26442 3.93109C7.55609 3.63942 7.91239 3.49359 8.33332 3.49359C8.75425 3.49359 9.11055 3.63942 9.40222 3.93109C9.69388 4.22276 9.83972 4.57906 9.83972 4.99999C9.83972 5.42092 9.69388 5.77722 9.40222 6.06888C9.11055 6.36055 8.75425 6.50638 8.33332 6.50638ZM15 6.50638C14.5791 6.50638 14.2228 6.36055 13.9311 6.06888C13.6394 5.77722 13.4936 5.42092 13.4936 4.99999C13.4936 4.57906 13.6394 4.22276 13.9311 3.93109C14.2228 3.63942 14.5791 3.49359 15 3.49359C15.4209 3.49359 15.7772 3.63942 16.0689 3.93109C16.3605 4.22276 16.5064 4.57906 16.5064 4.99999C16.5064 5.42092 16.3605 5.77722 16.0689 6.06888C15.7772 6.36055 15.4209 6.50638 15 6.50638Z",fill:"currentColor"})})]})}),G5=e=>r.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:r.jsxs("g",{id:"public",children:[r.jsx("mask",{id:"mask0_1551_36",maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"20",height:"20",children:r.jsx("rect",{id:"Bounding box",width:"1em",height:"1em",fill:"currentColor"})}),r.jsx("g",{mask:"url(#mask0_1551_36)",children:r.jsx("path",{id:"public_2",d:"M10.0028 17.5C8.96567 17.5 7.9906 17.3032 7.07758 16.9096C6.16457 16.516 5.37037 15.9818 4.69498 15.3071C4.0196 14.6323 3.48493 13.8389 3.09096 12.9267C2.69699 12.0145 2.5 11.0399 2.5 10.0028C2.5 8.96567 2.6968 7.9906 3.0904 7.07758C3.48401 6.16457 4.01819 5.37037 4.69294 4.69498C5.36769 4.0196 6.16114 3.48493 7.07329 3.09096C7.98546 2.69699 8.9601 2.5 9.99721 2.5C11.0343 2.5 12.0094 2.6968 12.9224 3.0904C13.8354 3.48401 14.6296 4.01819 15.305 4.69294C15.9804 5.36769 16.5151 6.16114 16.909 7.07329C17.303 7.98546 17.5 8.9601 17.5 9.99721C17.5 11.0343 17.3032 12.0094 16.9096 12.9224C16.516 13.8354 15.9818 14.6296 15.3071 15.305C14.6323 15.9804 13.8389 16.5151 12.9267 16.909C12.0145 17.303 11.0399 17.5 10.0028 17.5ZM9.16667 16.625V15C8.70833 15 8.31597 14.8368 7.98958 14.5104C7.66319 14.184 7.5 13.7917 7.5 13.3333V12.5L3.5 8.5C3.45833 8.75 3.42014 9 3.38542 9.25C3.35069 9.5 3.33333 9.75 3.33333 10C3.33333 11.6806 3.88542 13.1528 4.98958 14.4167C6.09375 15.6806 7.48611 16.4167 9.16667 16.625ZM14.9167 14.5C15.1944 14.1944 15.4444 13.8646 15.6667 13.5104C15.8889 13.1562 16.0729 12.7882 16.2187 12.4062C16.3646 12.0243 16.4757 11.6319 16.5521 11.2292C16.6285 10.8264 16.6667 10.4167 16.6667 10C16.6667 8.63083 16.2909 7.38042 15.5393 6.24877C14.7877 5.11712 13.7746 4.30129 12.5 3.80129V4.16667C12.5 4.625 12.3368 5.01736 12.0104 5.34375C11.684 5.67014 11.2917 5.83333 10.8333 5.83333H9.16667V7.5C9.16667 7.73611 9.08681 7.93403 8.92708 8.09375C8.76736 8.25347 8.56944 8.33333 8.33333 8.33333H6.66667V10H11.6667C11.9028 10 12.1007 10.0799 12.2604 10.2396C12.4201 10.3993 12.5 10.5972 12.5 10.8333V13.3333H13.3333C13.6944 13.3333 14.0208 13.441 14.3125 13.6562C14.6042 13.8715 14.8056 14.1528 14.9167 14.5Z",fill:"currentColor"})})]})});function P2(e,n,t){var i,s=1;e==null&&(e=0),n==null&&(n=0),t==null&&(t=0);function o(){var l,C=i.length,a,h=0,c=0,u=0;for(l=0;l=(a=(l+C)/2))?l=a:C=a,i=s,!(s=s[u=+c]))return i[u]=o,e;if(h=+e._x.call(null,s.data),n===h)return o.next=s,i?i[u]=o:e._root=o,e;do i=i?i[u]=new Array(2):e._root=new Array(2),(c=n>=(a=(l+C)/2))?l=a:C=a;while((u=+c)==(p=+(h>=a)));return i[p]=s,i[u]=o,e}function X5(e){Array.isArray(e)||(e=Array.from(e));const n=e.length,t=new Float64Array(n);let i=1/0,s=-1/0;for(let o=0,l;os&&(s=l));if(i>s)return this;this.cover(i).cover(s);for(let o=0;oe||e>=t;)switch(l=+(el||(o=h.x1)=u))&&(h=C[C.length-1],C[C.length-1]=C[C.length-1-c],C[C.length-1-c]=h)}else{var p=Math.abs(e-+this._x.call(null,a.data));p=(h=(l+C)/2))?l=h:C=h,n=t,!(t=t[u=+c]))return this;if(!t.length)break;n[u+1&1]&&(i=n,p=u)}for(;t.data!==e;)if(s=t,!(t=t.next))return this;return(o=t.next)&&delete t.next,s?(o?s.next=o:delete s.next,this):n?(o?n[u]=o:delete n[u],(t=n[0]||n[1])&&t===(n[1]||n[0])&&!t.length&&(i?i[p]=t:this._root=t),this):(this._root=o,this)}function t0(e){for(var n=0,t=e.length;n=(u=(C+h)/2))?C=u:h=u,(w=t>=(p=(a+c)/2))?a=p:c=p,s=o,!(o=o[d=w<<1|_]))return s[d]=l,e;if(x=+e._x.call(null,o.data),f=+e._y.call(null,o.data),n===x&&t===f)return l.next=o,s?s[d]=l:e._root=l,e;do s=s?s[d]=new Array(4):e._root=new Array(4),(_=n>=(u=(C+h)/2))?C=u:h=u,(w=t>=(p=(a+c)/2))?a=p:c=p;while((d=w<<1|_)===(k=(f>=p)<<1|x>=u));return s[k]=o,s[d]=l,e}function a0(e){var n,t,i=e.length,s,o,l=new Array(i),C=new Array(i),a=1/0,h=1/0,c=-1/0,u=-1/0;for(t=0;tc&&(c=s),ou&&(u=o));if(a>c||h>u)return this;for(this.cover(a,h).cover(c,u),t=0;te||e>=s||i>n||n>=o;)switch(h=(nc||(C=f.y0)>u||(a=f.x1)=d)<<1|e>=w)&&(f=p[p.length-1],p[p.length-1]=p[p.length-1-_],p[p.length-1-_]=f)}else{var k=e-+this._x.call(null,x.data),g=n-+this._y.call(null,x.data),v=k*k+g*g;if(v=(p=(l+a)/2))?l=p:a=p,(_=u>=(x=(C+h)/2))?C=x:h=x,n=t,!(t=t[w=_<<1|f]))return this;if(!t.length)break;(n[w+1&3]||n[w+2&3]||n[w+3&3])&&(i=n,d=w)}for(;t.data!==e;)if(s=t,!(t=t.next))return this;return(o=t.next)&&delete t.next,s?(o?s.next=o:delete s.next,this):n?(o?n[w]=o:delete n[w],(t=n[0]||n[1]||n[2]||n[3])&&t===(n[3]||n[2]||n[1]||n[0])&&!t.length&&(i?i[d]=t:this._root=t),this):(this._root=o,this)}function p0(e){for(var n=0,t=e.length;n=(f=(a+u)/2))?a=f:u=f,(m=t>=(_=(h+p)/2))?h=_:p=_,(y=i>=(w=(c+x)/2))?c=w:x=w,o=l,!(l=l[j=y<<2|m<<1|v]))return o[j]=C,e;if(d=+e._x.call(null,l.data),k=+e._y.call(null,l.data),g=+e._z.call(null,l.data),n===d&&t===k&&i===g)return C.next=l,o?o[j]=C:e._root=C,e;do o=o?o[j]=new Array(8):e._root=new Array(8),(v=n>=(f=(a+u)/2))?a=f:u=f,(m=t>=(_=(h+p)/2))?h=_:p=_,(y=i>=(w=(c+x)/2))?c=w:x=w;while((j=y<<2|m<<1|v)===(L=(g>=w)<<2|(k>=_)<<1|d>=f));return o[L]=l,o[j]=C,e}function L0(e){Array.isArray(e)||(e=Array.from(e));const n=e.length,t=new Float64Array(n),i=new Float64Array(n),s=new Float64Array(n);let o=1/0,l=1/0,C=1/0,a=-1/0,h=-1/0,c=-1/0;for(let u=0,p,x,f,_;ua&&(a=x),fh&&(h=f),_c&&(c=_));if(o>a||l>h||C>c)return this;this.cover(o,l,C).cover(a,h,c);for(let u=0;ue||e>=l||s>n||n>=C||o>t||t>=a;)switch(p=(tf||(h=g.y0)>_||(c=g.z0)>w||(u=g.x1)=j)<<2|(n>=y)<<1|e>=m)&&(g=d[d.length-1],d[d.length-1]=d[d.length-1-v],d[d.length-1-v]=g)}else{var L=e-+this._x.call(null,k.data),M=n-+this._y.call(null,k.data),S=t-+this._z.call(null,k.data),P=L*L+M*M+S*S;if(P=(_=(l+h)/2))?l=_:h=_,(g=x>=(w=(C+c)/2))?C=w:c=w,(v=f>=(d=(a+u)/2))?a=d:u=d,n=t,!(t=t[m=v<<2|g<<1|k]))return this;if(!t.length)break;(n[m+1&7]||n[m+2&7]||n[m+3&7]||n[m+4&7]||n[m+5&7]||n[m+6&7]||n[m+7&7])&&(i=n,y=m)}for(;t.data!==e;)if(s=t,!(t=t.next))return this;return(o=t.next)&&delete t.next,s?(o?s.next=o:delete s.next,this):n?(o?n[m]=o:delete n[m],(t=n[0]||n[1]||n[2]||n[3]||n[4]||n[5]||n[6]||n[7])&&t===(n[7]||n[6]||n[5]||n[4]||n[3]||n[2]||n[1]||n[0])&&!t.length&&(i?i[y]=t:this._root=t),this):(this._root=o,this)}function E0(e){for(var n=0,t=e.length;n1&&(_=x.y+x.vy),t>2&&(w=x.z+x.vz),p.visit(v);function v(m,y,j,L,M,S,P){var V=[y,j,L,M,S,P],U=V[0],B=V[1],b=V[2],E=V[t],I=V[t+1],z=V[t+2],R=m.data,W=m.r,O=d+W;if(R){if(R.index>x.index){var A=f-R.x-R.vx,J=t>1?_-R.y-R.vy:0,D=t>2?w-R.z-R.vz:0,$=A*A+J*J+D*D;$1&&J===0&&(J=t1(s),$+=J*J),t>2&&D===0&&(D=t1(s),$+=D*D),$=(O-($=Math.sqrt($)))/$*o,x.vx+=(A*=$)*(O=(W*=W)/(k+W)),t>1&&(x.vy+=(J*=$)*O),t>2&&(x.vz+=(D*=$)*O),R.vx-=A*(O=1-O),t>1&&(R.vy-=J*O),t>2&&(R.vz-=D*O))}return}return U>f+O||E1&&(B>_+O||I<_-O)||t>2&&(b>w+O||zc.r&&(c.r=c[u].r)}function h(){if(n){var c,u=n.length,p;for(i=new Array(u),c=0;ctypeof p=="function")||Math.random,t=u.find(p=>[1,2,3].includes(p))||2,h()},C.iterations=function(c){return arguments.length?(l=+c,C):l},C.strength=function(c){return arguments.length?(o=+c,C):o},C.radius=function(c){return arguments.length?(e=typeof c=="function"?c:Y(+c),h(),C):e},C}function z0(e){return e.index}function U2(e,n){var t=e.get(n);if(!t)throw new Error("node not found: "+n);return t}function F0(e){var n=z0,t=p,i,s=Y(30),o,l,C,a,h,c,u=1;e==null&&(e=[]);function p(d){return 1/Math.min(a[d.source.index],a[d.target.index])}function x(d){for(var k=0,g=e.length;k1&&(M=j.y+j.vy-y.y-y.vy||t1(c)),C>2&&(S=j.z+j.vz-y.z-y.vz||t1(c)),P=Math.sqrt(L*L+M*M+S*S),P=(P-o[v])/P*d*i[v],L*=P,M*=P,S*=P,j.vx-=L*(V=h[v]),C>1&&(j.vy-=M*V),C>2&&(j.vz-=S*V),y.vx+=L*(V=1-V),C>1&&(y.vy+=M*V),C>2&&(y.vz+=S*V)}function f(){if(l){var d,k=l.length,g=e.length,v=new Map(l.map((y,j)=>[n(y,j,l),y])),m;for(d=0,a=new Array(k);dtypeof g=="function")||Math.random,C=k.find(g=>[1,2,3].includes(g))||2,f()},x.links=function(d){return arguments.length?(e=d,f(),x):e},x.id=function(d){return arguments.length?(n=d,x):n},x.iterations=function(d){return arguments.length?(u=+d,x):u},x.strength=function(d){return arguments.length?(t=typeof d=="function"?d:Y(+d),_(),x):t},x.distance=function(d){return arguments.length?(s=typeof d=="function"?d:Y(+d),w(),x):s},x}var D0={value:()=>{}};function C3(){for(var e=0,n=arguments.length,t={},i;e=0&&(i=t.slice(s+1),t=t.slice(0,s)),t&&!n.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:i}})}z1.prototype=C3.prototype={constructor:z1,on:function(e,n){var t=this._,i=q0(e+"",t),s,o=-1,l=i.length;if(arguments.length<2){for(;++o0)for(var t=new Array(s),i=0,s,o;i=0&&e._call.call(void 0,n),e=e._next;--y1}function A2(){h1=(W1=T1.now())+X1,y1=E1=0;try{X0()}finally{y1=0,K0(),h1=0}}function Y0(){var e=T1.now(),n=e-W1;n>a3&&(X1-=n,W1=e)}function K0(){for(var e,n=G1,t,i=1/0;n;)n._call?(i>n._time&&(i=n._time),e=n,n=n._next):(t=n._next,n._next=null,n=e?e._next=t:G1=t);S1=e,l2(i)}function l2(e){if(!y1){E1&&(E1=clearTimeout(E1));var n=e-h1;n>24?(e<1/0&&(E1=setTimeout(A2,e-T1.now()-X1)),M1&&(M1=clearInterval(M1))):(M1||(W1=T1.now(),M1=setInterval(Y0,a3)),y1=1,c3(A2))}}const Q0=1664525,J0=1013904223,$2=4294967296;function e6(){let e=1;return()=>(e=(Q0*e+J0)%$2)/$2}var z2=3;function r2(e){return e.x}function F2(e){return e.y}function t6(e){return e.z}var n6=10,r6=Math.PI*(3-Math.sqrt(5)),i6=Math.PI*20/(9+Math.sqrt(221));function s6(e,n){n=n||2;var t=Math.min(z2,Math.max(1,Math.round(n))),i,s=1,o=.001,l=1-Math.pow(o,1/300),C=0,a=.6,h=new Map,c=u3(x),u=C3("tick","end"),p=e6();e==null&&(e=[]);function x(){f(),u.call("tick",i),s1&&(v.fy==null?v.y+=v.vy*=a:(v.y=v.fy,v.vy=0)),t>2&&(v.fz==null?v.z+=v.vz*=a:(v.z=v.fz,v.vz=0));return i}function _(){for(var d=0,k=e.length,g;d1&&isNaN(g.y)||t>2&&isNaN(g.z)){var v=n6*(t>2?Math.cbrt(.5+d):t>1?Math.sqrt(.5+d):d),m=d*r6,y=d*i6;t===1?g.x=v:t===2?(g.x=v*Math.cos(m),g.y=v*Math.sin(m)):(g.x=v*Math.sin(m)*Math.cos(y),g.y=v*Math.cos(m),g.z=v*Math.sin(m)*Math.sin(y))}(isNaN(g.vx)||t>1&&isNaN(g.vy)||t>2&&isNaN(g.vz))&&(g.vx=0,t>1&&(g.vy=0),t>2&&(g.vz=0))}}function w(d){return d.initialize&&d.initialize(e,p,t),d}return _(),i={tick:f,restart:function(){return c.restart(x),i},stop:function(){return c.stop(),i},numDimensions:function(d){return arguments.length?(t=Math.min(z2,Math.max(1,Math.round(d))),h.forEach(w),i):t},nodes:function(d){return arguments.length?(e=d,_(),h.forEach(w),i):e},alpha:function(d){return arguments.length?(s=+d,i):s},alphaMin:function(d){return arguments.length?(o=+d,i):o},alphaDecay:function(d){return arguments.length?(l=+d,i):+l},alphaTarget:function(d){return arguments.length?(C=+d,i):C},velocityDecay:function(d){return arguments.length?(a=1-d,i):1-a},randomSource:function(d){return arguments.length?(p=d,h.forEach(w),i):p},force:function(d,k){return arguments.length>1?(k==null?h.delete(d):h.set(d,w(k)),i):h.get(d)},find:function(){var d=Array.prototype.slice.call(arguments),k=d.shift()||0,g=(t>1?d.shift():null)||0,v=(t>2?d.shift():null)||0,m=d.shift()||1/0,y=0,j=e.length,L,M,S,P,V,U;for(m*=m,y=0;y1?(u.on(d,k),i):u.on(d)}}}function D2(){var e,n,t,i,s,o=Y(-30),l,C=1,a=1/0,h=.81;function c(f){var _,w=e.length,d=(n===1?a2(e,r2):n===2?h2(e,r2,F2):n===3?d2(e,r2,F2,t6):null).visitAfter(p);for(s=f,_=0;_1&&(f.y=v/k),n>2&&(f.z=m/k)}else{w=f,w.x=w.data.x,n>1&&(w.y=w.data.y),n>2&&(w.z=w.data.z);do _+=l[w.data.index];while(w=w.next)}f.value=_}function x(f,_,w,d,k){if(!f.value)return!0;var g=[w,d,k][n-1],v=f.x-t.x,m=n>1?f.y-t.y:0,y=n>2?f.z-t.z:0,j=g-_,L=v*v+m*m+y*y;if(j*j/h1&&m===0&&(m=t1(i),L+=m*m),n>2&&y===0&&(y=t1(i),L+=y*y),L1&&(t.vy+=m*f.value*s/L),n>2&&(t.vz+=y*f.value*s/L)),!0;if(f.length||L>=a)return;(f.data!==t||f.next)&&(v===0&&(v=t1(i),L+=v*v),n>1&&m===0&&(m=t1(i),L+=m*m),n>2&&y===0&&(y=t1(i),L+=y*y),L1&&(t.vy+=m*j),n>2&&(t.vz+=y*j));while(f=f.next)}return c.initialize=function(f,..._){e=f,i=_.find(w=>typeof w=="function")||Math.random,n=_.find(w=>[1,2,3].includes(w))||2,u()},c.strength=function(f){return arguments.length?(o=typeof f=="function"?f:Y(+f),u(),c):o},c.distanceMin=function(f){return arguments.length?(C=f*f,c):Math.sqrt(C)},c.distanceMax=function(f){return arguments.length?(a=f*f,c):Math.sqrt(a)},c.theta=function(f){return arguments.length?(h=f*f,c):Math.sqrt(h)},c}function q2(e,n,t,i){var s,o,l=Y(.1),C,a;typeof e!="function"&&(e=Y(+e)),n==null&&(n=0),t==null&&(t=0),i==null&&(i=0);function h(u){for(var p=0,x=s.length;p1&&(f.vy+=w*g),o>2&&(f.vz+=d*g)}}function c(){if(s){var u,p=s.length;for(C=new Array(p),a=new Array(p),u=0;u[1,2,3].includes(x))||2,c()},h.strength=function(u){return arguments.length?(l=typeof u=="function"?u:Y(+u),c(),h):l},h.radius=function(u){return arguments.length?(e=typeof u=="function"?u:Y(+u),c(),h):e},h.x=function(u){return arguments.length?(n=+u,h):n},h.y=function(u){return arguments.length?(t=+u,h):t},h.z=function(u){return arguments.length?(i=+u,h):i},h}function o6(e){var n=Y(.1),t,i,s;typeof e!="function"&&(e=Y(e==null?0:+e));function o(C){for(var a=0,h=t.length,c;a{},setForces:()=>{},addRadialForce:()=>{},addDefaultForce:()=>{},addClusterForce:()=>{},addSplitForce:()=>{},simulationRestart:()=>{},getLinks:()=>[]},C6={data:null,simulation:null,selectionGraphData:{nodes:[],links:[]},disableCameraRotation:!0,scrollEventsDisabled:!1,graphRadius:1500,selectionGraphRadius:200,graphStyle:"sphere",hoveredNode:null,hoveredNodeSiblings:[],selectedNode:null,activeEdge:null,cameraFocusTrigger:!1,nearbyNodeIds:[],showSelectionGraph:!1,simulationHelpers:l6,isHovering:!1,selectionPath:[],activeNode:null,highlightNodes:[],searchQuery:"",selectedNodeTypes:[],selectedLinkTypes:[]},j1=X2()((e,n)=>({...C6,setData:t=>{e({data:t})},setSelectedNodeTypes:t=>{const{selectedNodeTypes:i}=n(),s=i.includes(t)?i.filter(o=>o!==t):[...i,t];e({selectedNodeTypes:s})},setSelectedLinkTypes:t=>{const{selectedLinkTypes:i}=n(),s=i.includes(t)?i.filter(o=>o!==t):[...i,t];e({selectedLinkTypes:s})},resetSelectedNodeTypes:()=>e({selectedNodeTypes:[]}),resetSelectedLinkTypes:()=>e({selectedLinkTypes:[]}),setSelectionData:t=>e({selectionGraphData:t}),setScrollEventsDisabled:t=>e({scrollEventsDisabled:t}),setDisableCameraRotation:t=>e({disableCameraRotation:t}),setIsHovering:t=>e({isHovering:t}),setGraphRadius:t=>e({graphRadius:t}),setSelectionGraphRadius:t=>e({selectionGraphRadius:t}),setGraphStyle:t=>e({graphStyle:"sphere"}),setHoveredNode:t=>{const{nodesNormalized:i}=I1.getState()||{};if(t){const s=i.get(t.ref_id),o=[...(s==null?void 0:s.targets)||[],...(s==null?void 0:s.sources)||[]];e({hoveredNode:t,hoveredNodeSiblings:o})}else e({hoveredNode:t,hoveredNodeSiblings:[]})},setActiveEdge:t=>{e({activeEdge:t})},setActiveNode:t=>{e({activeNode:t})},setHighlightNodes:t=>{e({highlightNodes:t})},addToSelectionPath:t=>{const{selectionPath:i}=n();e({selectionPath:[...i,t]})},setSelectedNode:t=>{const{nodesNormalized:i}=I1.getState()||{};t||e({hoveredNode:null,selectedNode:null,disableCameraRotation:!1,showSelectionGraph:!1,selectionPath:[]});const{selectedNode:s,simulation:o,selectionPath:l}=n();if((s==null?void 0:s.ref_id)!==(t==null?void 0:t.ref_id)){const C=o.nodes().find(a=>a.ref_id===(t==null?void 0:t.ref_id))||null;if(t!=null&&t.ref_id){const a=(i==null?void 0:i.get(t==null?void 0:t.ref_id))||{};e({hoveredNode:null,selectedNode:{...C,...a},disableCameraRotation:!0,showSelectionGraph:!!t,selectionPath:[...l,C.ref_id]})}}},setCameraFocusTrigger:t=>e({cameraFocusTrigger:t}),setNearbyNodeIds:t=>{const i=n().nearbyNodeIds;(t.length!==i.length||t[0]!==i[0])&&e({nearbyNodeIds:t})},setShowSelectionGraph:t=>e({showSelectionGraph:t}),simulationHelpers:{addNodesAndLinks:(t,i,s)=>{const{simulation:o,simulationHelpers:l}=n();console.log(o.nodes()),console.log(t),o.stop();const C=structuredClone(t),a=structuredClone(i);o.stop();const h=s?[]:o.nodes(),c=s?[]:o.force("link").links();h.push(...C),c.push(...a),o.nodes(h),o.force("link").links([]).links(c),l.simulationRestart();try{console.log("try")}catch(u){console.error(u)}},addRadialForce:()=>{const{simulation:t}=n();t.nodes(t.nodes().map(i=>({...i,...$1}))).force("y",null).force("center",P2().strength(1)).force("charge",D2().strength(-1)).force("collide",n2().radius(i=>(i.scale||1)*95).strength(.5).iterations(1))},addClusterForce:()=>{const{simulation:t,highlightNodes:i}=n();t.nodes(t.nodes().map(s=>({...s,...$1}))).force("cluster",q2(s=>i.includes(s.ref_id)?25:500).strength(1))},addDefaultForce:()=>{const{simulation:t}=n();t.nodes(t.nodes().map(i=>({...i,...$1}))).force("y",null).force("charge",D2().strength(-20)).force("center",P2().strength(1)).force("collide",n2().radius(()=>250).strength(1).iterations(1))},addSplitForce:()=>{const{simulation:t}=n(),{nodeTypes:i}=I1.getState();t.stop().nodes(t.nodes().map(s=>({...s,...$1}))).force("radial",q2(200,0,0,0).strength(.1)).force("collide",n2().radius(()=>250).strength(1).iterations(1)).force("y",o6().y(s=>{const o=i.indexOf(s.node_type),l=Math.floor(o/2)*400;return o%2===0?l:-l}).strength(10))},getLinks:()=>{const{simulation:t}=n();return t?t.force("link").links():[]},setForces:()=>{const{graphStyle:t,simulationHelpers:i}=n();t==="split"&&i.addSplitForce(),t==="sphere"&&i.addRadialForce(),t==="force"&&i.addDefaultForce(),i.simulationRestart()},simulationRestart:()=>{const{simulation:t}=n();t.alpha(1).restart()}},simulationCreate:(t,i)=>{const s=structuredClone(t),o=structuredClone(i),l=s6([]).numDimensions(3).stop().nodes(s).force("link",F0().strength(0).links(o).id(C=>C.ref_id));e({simulation:l})},removeSimulation:()=>e({simulation:null}),setSearchQuery:t=>e({searchQuery:t})})),d3=()=>j1(e=>e.selectedNode),E7=()=>j1(e=>e.hoveredNode),a6=()=>j1(e=>e.setSelectedNode),c6=()=>(j1(z5(e=>[e.graphStyle,e.setGraphStyle])),null);q(f1).attrs({direction:"row",align:"center",justify:"space-between"})` +import{E as m3,R as A1,G as r1,H as Z1,J as G2,K as N1,L as R1,M as u1,N as Z,O as F1,r as H,P as U1,j as r,S as c1,U as O1,V as w3,X as k1,Y as d1,Z as _2,$ as k2,a0 as v3,a1 as y2,a2 as W2,c as X2,u as I1,s as q,a as i1,F as f1,B as Y2,C as C2,a3 as _3,a4 as k3,k as K2,A as y3,b as j3,a5 as L3,I as H3}from"./index-4e60c9e2.js";const M3=e=>{const[n,t,i]=e.split(":"),s=parseInt(n,10),o=parseInt(t,10),l=parseInt(i,10);return s*3600+o*60+l};function j2(...e){return e.reduce((n,t)=>t==null?n:function(...s){n.apply(this,s),t.apply(this,s)},()=>{})}function V3(e,n=166){let t;function i(...s){const o=()=>{e.apply(this,s)};clearTimeout(t),t=setTimeout(o,n)}return i.clear=()=>{clearTimeout(t)},i}function s1(e){return e&&e.ownerDocument||document}function B1(e){return s1(e).defaultView||window}function Z3(e){const n=e.documentElement.clientWidth;return Math.abs(window.innerWidth-n)}const b3=e=>{let n;return e<1?n=5.11916*e**2:n=4.5*Math.log(e+1)+2,(n/100).toFixed(2)},L2=b3,H2={disabled:!1};var E3=function(n){return n.scrollTop},b1="unmounted",C1="exited",a1="entering",_1="entered",i2="exiting",l1=function(e){m3(n,e);function n(i,s){var o;o=e.call(this,i,s)||this;var l=s,C=l&&!l.isMounting?i.enter:i.appear,a;return o.appearStatus=null,i.in?C?(a=C1,o.appearStatus=a1):a=_1:i.unmountOnExit||i.mountOnEnter?a=b1:a=C1,o.state={status:a},o.nextCallback=null,o}n.getDerivedStateFromProps=function(s,o){var l=s.in;return l&&o.status===b1?{status:C1}:null};var t=n.prototype;return t.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},t.componentDidUpdate=function(s){var o=null;if(s!==this.props){var l=this.state.status;this.props.in?l!==a1&&l!==_1&&(o=a1):(l===a1||l===_1)&&(o=i2)}this.updateStatus(!1,o)},t.componentWillUnmount=function(){this.cancelNextCallback()},t.getTimeouts=function(){var s=this.props.timeout,o,l,C;return o=l=C=s,s!=null&&typeof s!="number"&&(o=s.exit,l=s.enter,C=s.appear!==void 0?s.appear:l),{exit:o,enter:l,appear:C}},t.updateStatus=function(s,o){if(s===void 0&&(s=!1),o!==null)if(this.cancelNextCallback(),o===a1){if(this.props.unmountOnExit||this.props.mountOnEnter){var l=this.props.nodeRef?this.props.nodeRef.current:A1.findDOMNode(this);l&&E3(l)}this.performEnter(s)}else this.performExit();else this.props.unmountOnExit&&this.state.status===C1&&this.setState({status:b1})},t.performEnter=function(s){var o=this,l=this.props.enter,C=this.context?this.context.isMounting:s,a=this.props.nodeRef?[C]:[A1.findDOMNode(this),C],h=a[0],c=a[1],u=this.getTimeouts(),p=C?u.appear:u.enter;if(!s&&!l||H2.disabled){this.safeSetState({status:_1},function(){o.props.onEntered(h)});return}this.props.onEnter(h,c),this.safeSetState({status:a1},function(){o.props.onEntering(h,c),o.onTransitionEnd(p,function(){o.safeSetState({status:_1},function(){o.props.onEntered(h,c)})})})},t.performExit=function(){var s=this,o=this.props.exit,l=this.getTimeouts(),C=this.props.nodeRef?void 0:A1.findDOMNode(this);if(!o||H2.disabled){this.safeSetState({status:C1},function(){s.props.onExited(C)});return}this.props.onExit(C),this.safeSetState({status:i2},function(){s.props.onExiting(C),s.onTransitionEnd(l.exit,function(){s.safeSetState({status:C1},function(){s.props.onExited(C)})})})},t.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},t.safeSetState=function(s,o){o=this.setNextCallback(o),this.setState(s,o)},t.setNextCallback=function(s){var o=this,l=!0;return this.nextCallback=function(C){l&&(l=!1,o.nextCallback=null,s(C))},this.nextCallback.cancel=function(){l=!1},this.nextCallback},t.onTransitionEnd=function(s,o){this.setNextCallback(o);var l=this.props.nodeRef?this.props.nodeRef.current:A1.findDOMNode(this),C=s==null&&!this.props.addEndListener;if(!l||C){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var a=this.props.nodeRef?[this.nextCallback]:[l,this.nextCallback],h=a[0],c=a[1];this.props.addEndListener(h,c)}s!=null&&setTimeout(this.nextCallback,s)},t.render=function(){var s=this.state.status;if(s===b1)return null;var o=this.props,l=o.children;o.in,o.mountOnEnter,o.unmountOnExit,o.appear,o.enter,o.exit,o.timeout,o.addEndListener,o.onEnter,o.onEntering,o.onEntered,o.onExit,o.onExiting,o.onExited,o.nodeRef;var C=r1(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return Z1.createElement(G2.Provider,{value:null},typeof l=="function"?l(s,C):Z1.cloneElement(Z1.Children.only(l),C))},n}(Z1.Component);l1.contextType=G2;l1.propTypes={};function v1(){}l1.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:v1,onEntering:v1,onEntered:v1,onExit:v1,onExiting:v1,onExited:v1};l1.UNMOUNTED=b1;l1.EXITED=C1;l1.ENTERING=a1;l1.ENTERED=_1;l1.EXITING=i2;const Q2=l1,J2=e=>e.scrollTop;function D1(e,n){var t,i;const{timeout:s,easing:o,style:l={}}=e;return{duration:(t=l.transitionDuration)!=null?t:typeof s=="number"?s:s[n.mode]||0,easing:(i=l.transitionTimingFunction)!=null?i:typeof o=="object"?o[n.mode]:o,delay:l.transitionDelay}}function S3(e){return N1("MuiPaper",e)}R1("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const I3=["className","component","elevation","square","variant"],P3=e=>{const{square:n,elevation:t,variant:i,classes:s}=e,o={root:["root",i,!n&&"rounded",i==="elevation"&&`elevation${t}`]};return O1(o,S3,s)},B3=u1("div",{name:"MuiPaper",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,n[t.variant],!t.square&&n.rounded,t.variant==="elevation"&&n[`elevation${t.elevation}`]]}})(({theme:e,ownerState:n})=>{var t;return Z({backgroundColor:(e.vars||e).palette.background.paper,color:(e.vars||e).palette.text.primary,transition:e.transitions.create("box-shadow")},!n.square&&{borderRadius:e.shape.borderRadius},n.variant==="outlined"&&{border:`1px solid ${(e.vars||e).palette.divider}`},n.variant==="elevation"&&Z({boxShadow:(e.vars||e).shadows[n.elevation]},!e.vars&&e.palette.mode==="dark"&&{backgroundImage:`linear-gradient(${F1("#fff",L2(n.elevation))}, ${F1("#fff",L2(n.elevation))})`},e.vars&&{backgroundImage:(t=e.vars.overlays)==null?void 0:t[n.elevation]}))}),T3=H.forwardRef(function(n,t){const i=U1({props:n,name:"MuiPaper"}),{className:s,component:o="div",elevation:l=1,square:C=!1,variant:a="elevation"}=i,h=r1(i,I3),c=Z({},i,{component:o,elevation:l,square:C,variant:a}),u=P3(c);return r.jsx(B3,Z({as:o,ownerState:c,className:c1(u.root,s),ref:t},h))}),N3=T3;function R3(e){return N1("MuiIconButton",e)}const U3=R1("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge"]),O3=U3,A3=["edge","children","className","color","disabled","disableFocusRipple","size"],$3=e=>{const{classes:n,disabled:t,color:i,edge:s,size:o}=e,l={root:["root",t&&"disabled",i!=="default"&&`color${k1(i)}`,s&&`edge${k1(s)}`,`size${k1(o)}`]};return O1(l,R3,n)},z3=u1(w3,{name:"MuiIconButton",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,t.color!=="default"&&n[`color${k1(t.color)}`],t.edge&&n[`edge${k1(t.edge)}`],n[`size${k1(t.size)}`]]}})(({theme:e,ownerState:n})=>Z({textAlign:"center",flex:"0 0 auto",fontSize:e.typography.pxToRem(24),padding:8,borderRadius:"50%",overflow:"visible",color:(e.vars||e).palette.action.active,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest})},!n.disableRipple&&{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:F1(e.palette.action.active,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},n.edge==="start"&&{marginLeft:n.size==="small"?-3:-12},n.edge==="end"&&{marginRight:n.size==="small"?-3:-12}),({theme:e,ownerState:n})=>{var t;const i=(t=(e.vars||e).palette)==null?void 0:t[n.color];return Z({},n.color==="inherit"&&{color:"inherit"},n.color!=="inherit"&&n.color!=="default"&&Z({color:i==null?void 0:i.main},!n.disableRipple&&{"&:hover":Z({},i&&{backgroundColor:e.vars?`rgba(${i.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:F1(i.main,e.palette.action.hoverOpacity)},{"@media (hover: none)":{backgroundColor:"transparent"}})}),n.size==="small"&&{padding:5,fontSize:e.typography.pxToRem(18)},n.size==="large"&&{padding:12,fontSize:e.typography.pxToRem(28)},{[`&.${O3.disabled}`]:{backgroundColor:"transparent",color:(e.vars||e).palette.action.disabled}})}),F3=H.forwardRef(function(n,t){const i=U1({props:n,name:"MuiIconButton"}),{edge:s=!1,children:o,className:l,color:C="default",disabled:a=!1,disableFocusRipple:h=!1,size:c="medium"}=i,u=r1(i,A3),p=Z({},i,{edge:s,color:C,disabled:a,disableFocusRipple:h,size:c}),x=$3(p);return r.jsx(z3,Z({className:c1(x.root,l),centerRipple:!0,focusRipple:!h,disabled:a,ref:t,ownerState:p},u,{children:o}))}),e3=F3;function t3(e){return typeof e=="string"}function D3(e,n,t){return e===void 0||t3(e)?n:Z({},n,{ownerState:Z({},n.ownerState,t)})}function n3(e,n=[]){if(e===void 0)return{};const t={};return Object.keys(e).filter(i=>i.match(/^on[A-Z]/)&&typeof e[i]=="function"&&!n.includes(i)).forEach(i=>{t[i]=e[i]}),t}function q3(e,n,t){return typeof e=="function"?e(n,t):e}function r3(e){var n,t,i="";if(typeof e=="string"||typeof e=="number")i+=e;else if(typeof e=="object")if(Array.isArray(e))for(n=0;n!(t.match(/^on[A-Z]/)&&typeof e[t]=="function")).forEach(t=>{n[t]=e[t]}),n}function G3(e){const{getSlotProps:n,additionalProps:t,externalSlotProps:i,externalForwardedProps:s,className:o}=e;if(!n){const x=M2(t==null?void 0:t.className,o,s==null?void 0:s.className,i==null?void 0:i.className),f=Z({},t==null?void 0:t.style,s==null?void 0:s.style,i==null?void 0:i.style),_=Z({},t,s,i);return x.length>0&&(_.className=x),Object.keys(f).length>0&&(_.style=f),{props:_,internalRef:void 0}}const l=n3(Z({},s,i)),C=V2(i),a=V2(s),h=n(l),c=M2(h==null?void 0:h.className,t==null?void 0:t.className,o,s==null?void 0:s.className,i==null?void 0:i.className),u=Z({},h==null?void 0:h.style,t==null?void 0:t.style,s==null?void 0:s.style,i==null?void 0:i.style),p=Z({},h,t,a,C);return c.length>0&&(p.className=c),Object.keys(u).length>0&&(p.style=u),{props:p,internalRef:h.ref}}const W3=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function q1(e){var n;const{elementType:t,externalSlotProps:i,ownerState:s,skipResolvingSlotProps:o=!1}=e,l=r1(e,W3),C=o?{}:q3(i,s),{props:a,internalRef:h}=G3(Z({},l,{externalSlotProps:C})),c=d1(h,C==null?void 0:C.ref,(n=e.additionalProps)==null?void 0:n.ref);return D3(t,Z({},a,{ref:c}),s)}const X3=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function Y3(e){const n=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(n)?e.contentEditable==="true"||(e.nodeName==="AUDIO"||e.nodeName==="VIDEO"||e.nodeName==="DETAILS")&&e.getAttribute("tabindex")===null?0:e.tabIndex:n}function K3(e){if(e.tagName!=="INPUT"||e.type!=="radio"||!e.name)return!1;const n=i=>e.ownerDocument.querySelector(`input[type="radio"]${i}`);let t=n(`[name="${e.name}"]:checked`);return t||(t=n(`[name="${e.name}"]`)),t!==e}function Q3(e){return!(e.disabled||e.tagName==="INPUT"&&e.type==="hidden"||K3(e))}function J3(e){const n=[],t=[];return Array.from(e.querySelectorAll(X3)).forEach((i,s)=>{const o=Y3(i);o===-1||!Q3(i)||(o===0?n.push(i):t.push({documentOrder:s,tabIndex:o,node:i}))}),t.sort((i,s)=>i.tabIndex===s.tabIndex?i.documentOrder-s.documentOrder:i.tabIndex-s.tabIndex).map(i=>i.node).concat(n)}function e5(){return!0}function t5(e){const{children:n,disableAutoFocus:t=!1,disableEnforceFocus:i=!1,disableRestoreFocus:s=!1,getTabbable:o=J3,isEnabled:l=e5,open:C}=e,a=H.useRef(!1),h=H.useRef(null),c=H.useRef(null),u=H.useRef(null),p=H.useRef(null),x=H.useRef(!1),f=H.useRef(null),_=d1(n.ref,f),w=H.useRef(null);H.useEffect(()=>{!C||!f.current||(x.current=!t)},[t,C]),H.useEffect(()=>{if(!C||!f.current)return;const g=s1(f.current);return f.current.contains(g.activeElement)||(f.current.hasAttribute("tabIndex")||f.current.setAttribute("tabIndex","-1"),x.current&&f.current.focus()),()=>{s||(u.current&&u.current.focus&&(a.current=!0,u.current.focus()),u.current=null)}},[C]),H.useEffect(()=>{if(!C||!f.current)return;const g=s1(f.current),v=j=>{w.current=j,!(i||!l()||j.key!=="Tab")&&g.activeElement===f.current&&j.shiftKey&&(a.current=!0,c.current&&c.current.focus())},m=()=>{const j=f.current;if(j===null)return;if(!g.hasFocus()||!l()||a.current){a.current=!1;return}if(j.contains(g.activeElement)||i&&g.activeElement!==h.current&&g.activeElement!==c.current)return;if(g.activeElement!==p.current)p.current=null;else if(p.current!==null)return;if(!x.current)return;let L=[];if((g.activeElement===h.current||g.activeElement===c.current)&&(L=o(f.current)),L.length>0){var M,S;const P=!!((M=w.current)!=null&&M.shiftKey&&((S=w.current)==null?void 0:S.key)==="Tab"),V=L[0],U=L[L.length-1];typeof V!="string"&&typeof U!="string"&&(P?U.focus():V.focus())}else j.focus()};g.addEventListener("focusin",m),g.addEventListener("keydown",v,!0);const y=setInterval(()=>{g.activeElement&&g.activeElement.tagName==="BODY"&&m()},50);return()=>{clearInterval(y),g.removeEventListener("focusin",m),g.removeEventListener("keydown",v,!0)}},[t,i,s,l,C,o]);const d=g=>{u.current===null&&(u.current=g.relatedTarget),x.current=!0,p.current=g.target;const v=n.props.onFocus;v&&v(g)},k=g=>{u.current===null&&(u.current=g.relatedTarget),x.current=!0};return r.jsxs(H.Fragment,{children:[r.jsx("div",{tabIndex:C?0:-1,onFocus:k,ref:h,"data-testid":"sentinelStart"}),H.cloneElement(n,{ref:_,onFocus:d}),r.jsx("div",{tabIndex:C?0:-1,onFocus:k,ref:c,"data-testid":"sentinelEnd"})]})}function n5(e){return typeof e=="function"?e():e}const r5=H.forwardRef(function(n,t){const{children:i,container:s,disablePortal:o=!1}=n,[l,C]=H.useState(null),a=d1(H.isValidElement(i)?i.ref:null,t);if(_2(()=>{o||C(n5(s)||document.body)},[s,o]),_2(()=>{if(l&&!o)return k2(t,l),()=>{k2(t,null)}},[t,l,o]),o){if(H.isValidElement(i)){const h={ref:a};return H.cloneElement(i,h)}return r.jsx(H.Fragment,{children:i})}return r.jsx(H.Fragment,{children:l&&v3.createPortal(i,l)})});function i5(e){const n=s1(e);return n.body===e?B1(e).innerWidth>n.documentElement.clientWidth:e.scrollHeight>e.clientHeight}function P1(e,n){n?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function Z2(e){return parseInt(B1(e).getComputedStyle(e).paddingRight,10)||0}function s5(e){const t=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].indexOf(e.tagName)!==-1,i=e.tagName==="INPUT"&&e.getAttribute("type")==="hidden";return t||i}function b2(e,n,t,i,s){const o=[n,t,...i];[].forEach.call(e.children,l=>{const C=o.indexOf(l)===-1,a=!s5(l);C&&a&&P1(l,s)})}function Q1(e,n){let t=-1;return e.some((i,s)=>n(i)?(t=s,!0):!1),t}function o5(e,n){const t=[],i=e.container;if(!n.disableScrollLock){if(i5(i)){const l=Z3(s1(i));t.push({value:i.style.paddingRight,property:"padding-right",el:i}),i.style.paddingRight=`${Z2(i)+l}px`;const C=s1(i).querySelectorAll(".mui-fixed");[].forEach.call(C,a=>{t.push({value:a.style.paddingRight,property:"padding-right",el:a}),a.style.paddingRight=`${Z2(a)+l}px`})}let o;if(i.parentNode instanceof DocumentFragment)o=s1(i).body;else{const l=i.parentElement,C=B1(i);o=(l==null?void 0:l.nodeName)==="HTML"&&C.getComputedStyle(l).overflowY==="scroll"?l:i}t.push({value:o.style.overflow,property:"overflow",el:o},{value:o.style.overflowX,property:"overflow-x",el:o},{value:o.style.overflowY,property:"overflow-y",el:o}),o.style.overflow="hidden"}return()=>{t.forEach(({value:o,el:l,property:C})=>{o?l.style.setProperty(C,o):l.style.removeProperty(C)})}}function l5(e){const n=[];return[].forEach.call(e.children,t=>{t.getAttribute("aria-hidden")==="true"&&n.push(t)}),n}class C5{constructor(){this.containers=void 0,this.modals=void 0,this.modals=[],this.containers=[]}add(n,t){let i=this.modals.indexOf(n);if(i!==-1)return i;i=this.modals.length,this.modals.push(n),n.modalRef&&P1(n.modalRef,!1);const s=l5(t);b2(t,n.mount,n.modalRef,s,!0);const o=Q1(this.containers,l=>l.container===t);return o!==-1?(this.containers[o].modals.push(n),i):(this.containers.push({modals:[n],container:t,restore:null,hiddenSiblings:s}),i)}mount(n,t){const i=Q1(this.containers,o=>o.modals.indexOf(n)!==-1),s=this.containers[i];s.restore||(s.restore=o5(s,t))}remove(n,t=!0){const i=this.modals.indexOf(n);if(i===-1)return i;const s=Q1(this.containers,l=>l.modals.indexOf(n)!==-1),o=this.containers[s];if(o.modals.splice(o.modals.indexOf(n),1),this.modals.splice(i,1),o.modals.length===0)o.restore&&o.restore(),n.modalRef&&P1(n.modalRef,t),b2(o.container,n.mount,n.modalRef,o.hiddenSiblings,!1),this.containers.splice(s,1);else{const l=o.modals[o.modals.length-1];l.modalRef&&P1(l.modalRef,!1)}return i}isTopModal(n){return this.modals.length>0&&this.modals[this.modals.length-1]===n}}function a5(e){return typeof e=="function"?e():e}function c5(e){return e?e.props.hasOwnProperty("in"):!1}const h5=new C5;function u5(e){const{container:n,disableEscapeKeyDown:t=!1,disableScrollLock:i=!1,manager:s=h5,closeAfterTransition:o=!1,onTransitionEnter:l,onTransitionExited:C,children:a,onClose:h,open:c,rootRef:u}=e,p=H.useRef({}),x=H.useRef(null),f=H.useRef(null),_=d1(f,u),[w,d]=H.useState(!c),k=c5(a);let g=!0;(e["aria-hidden"]==="false"||e["aria-hidden"]===!1)&&(g=!1);const v=()=>s1(x.current),m=()=>(p.current.modalRef=f.current,p.current.mount=x.current,p.current),y=()=>{s.mount(m(),{disableScrollLock:i}),f.current&&(f.current.scrollTop=0)},j=y2(()=>{const E=a5(n)||v().body;s.add(m(),E),f.current&&y()}),L=H.useCallback(()=>s.isTopModal(m()),[s]),M=y2(E=>{x.current=E,E&&(c&&L()?y():f.current&&P1(f.current,g))}),S=H.useCallback(()=>{s.remove(m(),g)},[g,s]);H.useEffect(()=>()=>{S()},[S]),H.useEffect(()=>{c?j():(!k||!o)&&S()},[c,S,k,o,j]);const P=E=>I=>{var z;(z=E.onKeyDown)==null||z.call(E,I),!(I.key!=="Escape"||I.which===229||!L())&&(t||(I.stopPropagation(),h&&h(I,"escapeKeyDown")))},V=E=>I=>{var z;(z=E.onClick)==null||z.call(E,I),I.target===I.currentTarget&&h&&h(I,"backdropClick")};return{getRootProps:(E={})=>{const I=n3(e);delete I.onTransitionEnter,delete I.onTransitionExited;const z=Z({},I,E);return Z({role:"presentation"},z,{onKeyDown:P(z),ref:_})},getBackdropProps:(E={})=>{const I=E;return Z({"aria-hidden":!0},I,{onClick:V(I),open:c})},getTransitionProps:()=>{const E=()=>{d(!1),l&&l()},I=()=>{d(!0),C&&C(),o&&S()};return{onEnter:j2(E,a==null?void 0:a.props.onEnter),onExited:j2(I,a==null?void 0:a.props.onExited)}},rootRef:_,portalRef:M,isTopModal:L,exited:w,hasTransition:k}}const d5=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"],f5={entering:{opacity:1},entered:{opacity:1}},p5=H.forwardRef(function(n,t){const i=W2(),s={enter:i.transitions.duration.enteringScreen,exit:i.transitions.duration.leavingScreen},{addEndListener:o,appear:l=!0,children:C,easing:a,in:h,onEnter:c,onEntered:u,onEntering:p,onExit:x,onExited:f,onExiting:_,style:w,timeout:d=s,TransitionComponent:k=Q2}=n,g=r1(n,d5),v=H.useRef(null),m=d1(v,C.ref,t),y=B=>b=>{if(B){const E=v.current;b===void 0?B(E):B(E,b)}},j=y(p),L=y((B,b)=>{J2(B);const E=D1({style:w,timeout:d,easing:a},{mode:"enter"});B.style.webkitTransition=i.transitions.create("opacity",E),B.style.transition=i.transitions.create("opacity",E),c&&c(B,b)}),M=y(u),S=y(_),P=y(B=>{const b=D1({style:w,timeout:d,easing:a},{mode:"exit"});B.style.webkitTransition=i.transitions.create("opacity",b),B.style.transition=i.transitions.create("opacity",b),x&&x(B)}),V=y(f),U=B=>{o&&o(v.current,B)};return r.jsx(k,Z({appear:l,in:h,nodeRef:v,onEnter:L,onEntered:M,onEntering:j,onExit:P,onExited:V,onExiting:S,addEndListener:U,timeout:d},g,{children:(B,b)=>H.cloneElement(C,Z({style:Z({opacity:0,visibility:B==="exited"&&!h?"hidden":void 0},f5[B],w,C.props.style),ref:m},b))}))}),x5=p5;function g5(e){return N1("MuiBackdrop",e)}R1("MuiBackdrop",["root","invisible"]);const m5=["children","className","component","components","componentsProps","invisible","open","slotProps","slots","TransitionComponent","transitionDuration"],w5=e=>{const{classes:n,invisible:t}=e;return O1({root:["root",t&&"invisible"]},g5,n)},v5=u1("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,t.invisible&&n.invisible]}})(({ownerState:e})=>Z({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent"},e.invisible&&{backgroundColor:"transparent"})),_5=H.forwardRef(function(n,t){var i,s,o;const l=U1({props:n,name:"MuiBackdrop"}),{children:C,className:a,component:h="div",components:c={},componentsProps:u={},invisible:p=!1,open:x,slotProps:f={},slots:_={},TransitionComponent:w=x5,transitionDuration:d}=l,k=r1(l,m5),g=Z({},l,{component:h,invisible:p}),v=w5(g),m=(i=f.root)!=null?i:u.root;return r.jsx(w,Z({in:x,timeout:d},k,{children:r.jsx(v5,Z({"aria-hidden":!0},m,{as:(s=(o=_.root)!=null?o:c.Root)!=null?s:h,className:c1(v.root,a,m==null?void 0:m.className),ownerState:Z({},g,m==null?void 0:m.ownerState),classes:v,ref:t,children:C}))}))}),k5=_5;function y5(e){return N1("MuiModal",e)}R1("MuiModal",["root","hidden","backdrop"]);const j5=["BackdropComponent","BackdropProps","classes","className","closeAfterTransition","children","container","component","components","componentsProps","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","onBackdropClick","onClose","onTransitionEnter","onTransitionExited","open","slotProps","slots","theme"],L5=e=>{const{open:n,exited:t,classes:i}=e;return O1({root:["root",!n&&t&&"hidden"],backdrop:["backdrop"]},y5,i)},H5=u1("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,n)=>{const{ownerState:t}=e;return[n.root,!t.open&&t.exited&&n.hidden]}})(({theme:e,ownerState:n})=>Z({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0},!n.open&&n.exited&&{visibility:"hidden"})),M5=u1(k5,{name:"MuiModal",slot:"Backdrop",overridesResolver:(e,n)=>n.backdrop})({zIndex:-1}),V5=H.forwardRef(function(n,t){var i,s,o,l,C,a;const h=U1({name:"MuiModal",props:n}),{BackdropComponent:c=M5,BackdropProps:u,className:p,closeAfterTransition:x=!1,children:f,container:_,component:w,components:d={},componentsProps:k={},disableAutoFocus:g=!1,disableEnforceFocus:v=!1,disableEscapeKeyDown:m=!1,disablePortal:y=!1,disableRestoreFocus:j=!1,disableScrollLock:L=!1,hideBackdrop:M=!1,keepMounted:S=!1,onBackdropClick:P,open:V,slotProps:U,slots:B}=h,b=r1(h,j5),E=Z({},h,{closeAfterTransition:x,disableAutoFocus:g,disableEnforceFocus:v,disableEscapeKeyDown:m,disablePortal:y,disableRestoreFocus:j,disableScrollLock:L,hideBackdrop:M,keepMounted:S}),{getRootProps:I,getBackdropProps:z,getTransitionProps:R,portalRef:W,isTopModal:O,exited:A,hasTransition:J}=u5(Z({},E,{rootRef:t})),D=Z({},E,{exited:A}),$=L5(D),p1={};if(f.props.tabIndex===void 0&&(p1.tabIndex="-1"),J){const{onEnter:T,onExited:F}=R();p1.onEnter=T,p1.onExited=F}const x1=(i=(s=B==null?void 0:B.root)!=null?s:d.Root)!=null?i:H5,L1=(o=(l=B==null?void 0:B.backdrop)!=null?l:d.Backdrop)!=null?o:c,H1=(C=U==null?void 0:U.root)!=null?C:k.root,g1=(a=U==null?void 0:U.backdrop)!=null?a:k.backdrop,Y1=q1({elementType:x1,externalSlotProps:H1,externalForwardedProps:b,getSlotProps:I,additionalProps:{ref:t,as:w},ownerState:D,className:c1(p,H1==null?void 0:H1.className,$==null?void 0:$.root,!D.open&&D.exited&&($==null?void 0:$.hidden))}),K1=q1({elementType:L1,externalSlotProps:g1,additionalProps:u,getSlotProps:T=>z(Z({},T,{onClick:F=>{P&&P(F),T!=null&&T.onClick&&T.onClick(F)}})),className:c1(g1==null?void 0:g1.className,u==null?void 0:u.className,$==null?void 0:$.backdrop),ownerState:D});return!S&&!V&&(!J||A)?null:r.jsx(r5,{ref:W,container:_,disablePortal:y,children:r.jsxs(x1,Z({},Y1,{children:[!M&&c?r.jsx(L1,Z({},K1)):null,r.jsx(t5,{disableEnforceFocus:v,disableAutoFocus:g,disableRestoreFocus:j,isEnabled:O,open:V,children:H.cloneElement(f,p1)})]}))})}),Z5=V5,b5=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function s2(e){return`scale(${e}, ${e**2})`}const E5={entering:{opacity:1,transform:s2(1)},entered:{opacity:1,transform:"none"}},J1=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),i3=H.forwardRef(function(n,t){const{addEndListener:i,appear:s=!0,children:o,easing:l,in:C,onEnter:a,onEntered:h,onEntering:c,onExit:u,onExited:p,onExiting:x,style:f,timeout:_="auto",TransitionComponent:w=Q2}=n,d=r1(n,b5),k=H.useRef(),g=H.useRef(),v=W2(),m=H.useRef(null),y=d1(m,o.ref,t),j=b=>E=>{if(b){const I=m.current;E===void 0?b(I):b(I,E)}},L=j(c),M=j((b,E)=>{J2(b);const{duration:I,delay:z,easing:R}=D1({style:f,timeout:_,easing:l},{mode:"enter"});let W;_==="auto"?(W=v.transitions.getAutoHeightDuration(b.clientHeight),g.current=W):W=I,b.style.transition=[v.transitions.create("opacity",{duration:W,delay:z}),v.transitions.create("transform",{duration:J1?W:W*.666,delay:z,easing:R})].join(","),a&&a(b,E)}),S=j(h),P=j(x),V=j(b=>{const{duration:E,delay:I,easing:z}=D1({style:f,timeout:_,easing:l},{mode:"exit"});let R;_==="auto"?(R=v.transitions.getAutoHeightDuration(b.clientHeight),g.current=R):R=E,b.style.transition=[v.transitions.create("opacity",{duration:R,delay:I}),v.transitions.create("transform",{duration:J1?R:R*.666,delay:J1?I:I||R*.333,easing:z})].join(","),b.style.opacity=0,b.style.transform=s2(.75),u&&u(b)}),U=j(p),B=b=>{_==="auto"&&(k.current=setTimeout(b,g.current||0)),i&&i(m.current,b)};return H.useEffect(()=>()=>{clearTimeout(k.current)},[]),r.jsx(w,Z({appear:s,in:C,nodeRef:m,onEnter:M,onEntered:S,onEntering:L,onExit:V,onExited:U,onExiting:P,addEndListener:B,timeout:_==="auto"?null:_},d,{children:(b,E)=>H.cloneElement(o,Z({style:Z({opacity:0,transform:s2(.75),visibility:b==="exited"&&!C?"hidden":void 0},E5[b],f,o.props.style),ref:y},E))}))});i3.muiSupportAuto=!0;const S5=i3;function I5(e){return N1("MuiPopover",e)}R1("MuiPopover",["root","paper"]);const P5=["onEntering"],B5=["action","anchorEl","anchorOrigin","anchorPosition","anchorReference","children","className","container","elevation","marginThreshold","open","PaperProps","slots","slotProps","transformOrigin","TransitionComponent","transitionDuration","TransitionProps","disableScrollLock"],T5=["slotProps"];function E2(e,n){let t=0;return typeof n=="number"?t=n:n==="center"?t=e.height/2:n==="bottom"&&(t=e.height),t}function S2(e,n){let t=0;return typeof n=="number"?t=n:n==="center"?t=e.width/2:n==="right"&&(t=e.width),t}function I2(e){return[e.horizontal,e.vertical].map(n=>typeof n=="number"?`${n}px`:n).join(" ")}function e2(e){return typeof e=="function"?e():e}const N5=e=>{const{classes:n}=e;return O1({root:["root"],paper:["paper"]},I5,n)},R5=u1(Z5,{name:"MuiPopover",slot:"Root",overridesResolver:(e,n)=>n.root})({}),U5=u1(N3,{name:"MuiPopover",slot:"Paper",overridesResolver:(e,n)=>n.paper})({position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}),O5=H.forwardRef(function(n,t){var i,s,o;const l=U1({props:n,name:"MuiPopover"}),{action:C,anchorEl:a,anchorOrigin:h={vertical:"top",horizontal:"left"},anchorPosition:c,anchorReference:u="anchorEl",children:p,className:x,container:f,elevation:_=8,marginThreshold:w=16,open:d,PaperProps:k={},slots:g,slotProps:v,transformOrigin:m={vertical:"top",horizontal:"left"},TransitionComponent:y=S5,transitionDuration:j="auto",TransitionProps:{onEntering:L}={},disableScrollLock:M=!1}=l,S=r1(l.TransitionProps,P5),P=r1(l,B5),V=(i=v==null?void 0:v.paper)!=null?i:k,U=H.useRef(),B=d1(U,V.ref),b=Z({},l,{anchorOrigin:h,anchorReference:u,elevation:_,marginThreshold:w,externalPaperSlotProps:V,transformOrigin:m,TransitionComponent:y,transitionDuration:j,TransitionProps:S}),E=N5(b),I=H.useCallback(()=>{if(u==="anchorPosition")return c;const T=e2(a),e1=(T&&T.nodeType===1?T:s1(U.current).body).getBoundingClientRect();return{top:e1.top+E2(e1,h.vertical),left:e1.left+S2(e1,h.horizontal)}},[a,h.horizontal,h.vertical,c,u]),z=H.useCallback(T=>({vertical:E2(T,m.vertical),horizontal:S2(T,m.horizontal)}),[m.horizontal,m.vertical]),R=H.useCallback(T=>{const F={width:T.offsetWidth,height:T.offsetHeight},e1=z(F);if(u==="none")return{top:null,left:null,transformOrigin:I2(e1)};const p2=I();let m1=p2.top-e1.vertical,w1=p2.left-e1.horizontal;const x2=m1+F.height,g2=w1+F.width,m2=B1(e2(a)),w2=m2.innerHeight-w,v2=m2.innerWidth-w;if(w!==null&&m1w2){const n1=x2-w2;m1-=n1,e1.vertical+=n1}if(w!==null&&w1v2){const n1=g2-v2;w1-=n1,e1.horizontal+=n1}return{top:`${Math.round(m1)}px`,left:`${Math.round(w1)}px`,transformOrigin:I2(e1)}},[a,u,I,z,w]),[W,O]=H.useState(d),A=H.useCallback(()=>{const T=U.current;if(!T)return;const F=R(T);F.top!==null&&(T.style.top=F.top),F.left!==null&&(T.style.left=F.left),T.style.transformOrigin=F.transformOrigin,O(!0)},[R]);H.useEffect(()=>(M&&window.addEventListener("scroll",A),()=>window.removeEventListener("scroll",A)),[a,M,A]);const J=(T,F)=>{L&&L(T,F),A()},D=()=>{O(!1)};H.useEffect(()=>{d&&A()}),H.useImperativeHandle(C,()=>d?{updatePosition:()=>{A()}}:null,[d,A]),H.useEffect(()=>{if(!d)return;const T=V3(()=>{A()}),F=B1(a);return F.addEventListener("resize",T),()=>{T.clear(),F.removeEventListener("resize",T)}},[a,d,A]);let $=j;j==="auto"&&!y.muiSupportAuto&&($=void 0);const p1=f||(a?s1(e2(a)).body:void 0),x1=(s=g==null?void 0:g.root)!=null?s:R5,L1=(o=g==null?void 0:g.paper)!=null?o:U5,H1=q1({elementType:L1,externalSlotProps:Z({},V,{style:W?V.style:Z({},V.style,{opacity:0})}),additionalProps:{elevation:_,ref:B},ownerState:b,className:c1(E.paper,V==null?void 0:V.className)}),g1=q1({elementType:x1,externalSlotProps:(v==null?void 0:v.root)||{},externalForwardedProps:P,additionalProps:{ref:t,slotProps:{backdrop:{invisible:!0}},container:p1,open:d},ownerState:b,className:c1(E.root,x)}),{slotProps:Y1}=g1,K1=r1(g1,T5);return r.jsx(x1,Z({},K1,!t3(x1)&&{slotProps:Y1,disableScrollLock:M},{children:r.jsx(y,Z({appear:!0,in:d,onEntering:J,onExited:D,timeout:$},S,{children:r.jsx(L1,Z({},H1,{children:p}))}))}))}),b7=O5;function A5(e,n){if(Object.is(e,n))return!0;if(typeof e!="object"||e===null||typeof n!="object"||n===null)return!1;if(e instanceof Map&&n instanceof Map){if(e.size!==n.size)return!1;for(const[i,s]of e)if(!Object.is(s,n.get(i)))return!1;return!0}if(e instanceof Set&&n instanceof Set){if(e.size!==n.size)return!1;for(const i of e)if(!n.has(i))return!1;return!0}const t=Object.keys(e);if(t.length!==Object.keys(n).length)return!1;for(let i=0;i{const i=e(t);return A5(n.current,i)?n.current:n.current=i}}const F5=e=>r.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:r.jsxs("g",{id:"bubble_chart",children:[r.jsx("mask",{id:"mask0_1551_42",maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"20",height:"20",children:r.jsx("rect",{id:"Bounding box",width:"1em",height:"1em",fill:"currentColor"})}),r.jsx("g",{mask:"url(#mask0_1551_42)",children:r.jsx("path",{id:"bubble_chart_2",d:"M5.83333 15C4.91667 15 4.13194 14.6736 3.47917 14.0208C2.82639 13.3681 2.5 12.5833 2.5 11.6667C2.5 10.75 2.82639 9.96528 3.47917 9.3125C4.13194 8.65972 4.91667 8.33333 5.83333 8.33333C6.75 8.33333 7.53472 8.65972 8.1875 9.3125C8.84028 9.96528 9.16667 10.75 9.16667 11.6667C9.16667 12.5833 8.84028 13.3681 8.1875 14.0208C7.53472 14.6736 6.75 15 5.83333 15ZM13.75 11.6667C12.4722 11.6667 11.3889 11.2222 10.5 10.3333C9.61111 9.44444 9.16667 8.36111 9.16667 7.08333C9.16667 5.80556 9.61111 4.72222 10.5 3.83333C11.3889 2.94444 12.4722 2.5 13.75 2.5C15.0278 2.5 16.1111 2.94444 17 3.83333C17.8889 4.72222 18.3333 5.80556 18.3333 7.08333C18.3333 8.36111 17.8889 9.44444 17 10.3333C16.1111 11.2222 15.0278 11.6667 13.75 11.6667ZM12.0833 17.5C11.3889 17.5 10.7986 17.2569 10.3125 16.7708C9.82639 16.2847 9.58333 15.6944 9.58333 15C9.58333 14.3056 9.82639 13.7153 10.3125 13.2292C10.7986 12.7431 11.3889 12.5 12.0833 12.5C12.7778 12.5 13.3681 12.7431 13.8542 13.2292C14.3403 13.7153 14.5833 14.3056 14.5833 15C14.5833 15.6944 14.3403 16.2847 13.8542 16.7708C13.3681 17.2569 12.7778 17.5 12.0833 17.5Z",fill:"currentColor"})})]})}),D5=e=>r.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:r.jsxs("g",{id:"communities",children:[r.jsx("mask",{id:"mask0_1551_39",maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"20",height:"20",children:r.jsx("rect",{id:"Bounding box",width:"1em",height:"1em",fill:"currentColor"})}),r.jsx("g",{mask:"url(#mask0_1551_39)",children:r.jsx("path",{id:"communities_2",d:"M7.50002 13.125C7.90494 13.125 8.24921 12.9832 8.53285 12.6995C8.81651 12.4159 8.95833 12.0716 8.95833 11.6667C8.95833 11.2618 8.81651 10.9175 8.53285 10.6339C8.24921 10.3502 7.90494 10.2084 7.50002 10.2084C7.0951 10.2084 6.75083 10.3502 6.46719 10.6339C6.18353 10.9175 6.04171 11.2618 6.04171 11.6667C6.04171 12.0716 6.18353 12.4159 6.46719 12.6995C6.75083 12.9832 7.0951 13.125 7.50002 13.125ZM12.5 13.125C12.9049 13.125 13.2492 12.9832 13.5329 12.6995C13.8165 12.4159 13.9583 12.0716 13.9583 11.6667C13.9583 11.2618 13.8165 10.9175 13.5329 10.6339C13.2492 10.3502 12.9049 10.2084 12.5 10.2084C12.0951 10.2084 11.7508 10.3502 11.4672 10.6339C11.1835 10.9175 11.0417 11.2618 11.0417 11.6667C11.0417 12.0716 11.1835 12.4159 11.4672 12.6995C11.7508 12.9832 12.0951 13.125 12.5 13.125ZM10 8.95833C10.4049 8.95833 10.7492 8.81651 11.0329 8.53285C11.3165 8.24922 11.4583 7.90494 11.4583 7.50002C11.4583 7.0951 11.3165 6.75083 11.0329 6.46719C10.7492 6.18354 10.4049 6.04171 10 6.04171C9.5951 6.04171 9.25083 6.18354 8.96719 6.46719C8.68354 6.75083 8.54171 7.0951 8.54171 7.50002C8.54171 7.90494 8.68354 8.24922 8.96719 8.53285C9.25083 8.81651 9.5951 8.95833 10 8.95833ZM10.0014 17.9167C8.90647 17.9167 7.87728 17.7089 6.91383 17.2933C5.95037 16.8778 5.1123 16.3138 4.39962 15.6015C3.68693 14.8891 3.12271 14.0514 2.70698 13.0884C2.29124 12.1253 2.08337 11.0964 2.08337 10.0014C2.08337 8.90647 2.29115 7.87728 2.70671 6.91383C3.12226 5.95037 3.68622 5.11231 4.39858 4.39963C5.11096 3.68693 5.94866 3.12272 6.91169 2.70698C7.8747 2.29124 8.90368 2.08337 9.99862 2.08337C11.0936 2.08337 12.1228 2.29115 13.0862 2.70671C14.0497 3.12226 14.8877 3.68622 15.6004 4.39858C16.3131 5.11096 16.8773 5.94866 17.2931 6.91169C17.7088 7.8747 17.9167 8.90368 17.9167 9.99863C17.9167 11.0936 17.7089 12.1228 17.2933 13.0862C16.8778 14.0497 16.3138 14.8877 15.6015 15.6004C14.8891 16.3131 14.0514 16.8773 13.0884 17.2931C12.1253 17.7088 11.0964 17.9167 10.0014 17.9167ZM10 16.6667C11.8611 16.6667 13.4375 16.0209 14.7292 14.7292C16.0209 13.4375 16.6667 11.8611 16.6667 10C16.6667 8.13891 16.0209 6.56252 14.7292 5.27085C13.4375 3.97919 11.8611 3.33335 10 3.33335C8.13891 3.33335 6.56252 3.97919 5.27085 5.27085C3.97919 6.56252 3.33335 8.13891 3.33335 10C3.33335 11.8611 3.97919 13.4375 5.27085 14.7292C6.56252 16.0209 8.13891 16.6667 10 16.6667Z",fill:"currentColor"})})]})}),q5=e=>r.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:r.jsxs("g",{id:"grain",children:[r.jsx("mask",{id:"mask0_1551_45",maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"20",height:"20",children:r.jsx("rect",{id:"Bounding box",width:"1em",height:"1em",fill:"currentColor"})}),r.jsx("g",{mask:"url(#mask0_1551_45)",children:r.jsx("path",{id:"grain_2",d:"M4.99999 16.5064C4.57906 16.5064 4.22276 16.3605 3.93109 16.0689C3.63942 15.7772 3.49359 15.4209 3.49359 15C3.49359 14.5791 3.63942 14.2228 3.93109 13.9311C4.22276 13.6394 4.57906 13.4936 4.99999 13.4936C5.42092 13.4936 5.77722 13.6394 6.06888 13.9311C6.36055 14.2228 6.50638 14.5791 6.50638 15C6.50638 15.4209 6.36055 15.7772 6.06888 16.0689C5.77722 16.3605 5.42092 16.5064 4.99999 16.5064ZM11.6667 16.5064C11.2457 16.5064 10.8894 16.3605 10.5978 16.0689C10.3061 15.7772 10.1603 15.4209 10.1603 15C10.1603 14.5791 10.3061 14.2228 10.5978 13.9311C10.8894 13.6394 11.2457 13.4936 11.6667 13.4936C12.0876 13.4936 12.4439 13.6394 12.7355 13.9311C13.0272 14.2228 13.1731 14.5791 13.1731 15C13.1731 15.4209 13.0272 15.7772 12.7355 16.0689C12.4439 16.3605 12.0876 16.5064 11.6667 16.5064ZM8.33332 13.1731C7.91239 13.1731 7.55609 13.0272 7.26442 12.7355C6.97276 12.4439 6.82692 12.0876 6.82692 11.6667C6.82692 11.2457 6.97276 10.8894 7.26442 10.5978C7.55609 10.3061 7.91239 10.1603 8.33332 10.1603C8.75425 10.1603 9.11055 10.3061 9.40222 10.5978C9.69388 10.8894 9.83972 11.2457 9.83972 11.6667C9.83972 12.0876 9.69388 12.4439 9.40222 12.7355C9.11055 13.0272 8.75425 13.1731 8.33332 13.1731ZM15 13.1731C14.5791 13.1731 14.2228 13.0272 13.9311 12.7355C13.6394 12.4439 13.4936 12.0876 13.4936 11.6667C13.4936 11.2457 13.6394 10.8894 13.9311 10.5978C14.2228 10.3061 14.5791 10.1603 15 10.1603C15.4209 10.1603 15.7772 10.3061 16.0689 10.5978C16.3605 10.8894 16.5064 11.2457 16.5064 11.6667C16.5064 12.0876 16.3605 12.4439 16.0689 12.7355C15.7772 13.0272 15.4209 13.1731 15 13.1731ZM4.99999 9.83972C4.57906 9.83972 4.22276 9.69388 3.93109 9.40222C3.63942 9.11055 3.49359 8.75425 3.49359 8.33332C3.49359 7.91239 3.63942 7.55609 3.93109 7.26442C4.22276 6.97276 4.57906 6.82692 4.99999 6.82692C5.42092 6.82692 5.77722 6.97276 6.06888 7.26442C6.36055 7.55609 6.50638 7.91239 6.50638 8.33332C6.50638 8.75425 6.36055 9.11055 6.06888 9.40222C5.77722 9.69388 5.42092 9.83972 4.99999 9.83972ZM11.6667 9.83972C11.2457 9.83972 10.8894 9.69388 10.5978 9.40222C10.3061 9.11055 10.1603 8.75425 10.1603 8.33332C10.1603 7.91239 10.3061 7.55609 10.5978 7.26442C10.8894 6.97276 11.2457 6.82692 11.6667 6.82692C12.0876 6.82692 12.4439 6.97276 12.7355 7.26442C13.0272 7.55609 13.1731 7.91239 13.1731 8.33332C13.1731 8.75425 13.0272 9.11055 12.7355 9.40222C12.4439 9.69388 12.0876 9.83972 11.6667 9.83972ZM8.33332 6.50638C7.91239 6.50638 7.55609 6.36055 7.26442 6.06888C6.97276 5.77722 6.82692 5.42092 6.82692 4.99999C6.82692 4.57906 6.97276 4.22276 7.26442 3.93109C7.55609 3.63942 7.91239 3.49359 8.33332 3.49359C8.75425 3.49359 9.11055 3.63942 9.40222 3.93109C9.69388 4.22276 9.83972 4.57906 9.83972 4.99999C9.83972 5.42092 9.69388 5.77722 9.40222 6.06888C9.11055 6.36055 8.75425 6.50638 8.33332 6.50638ZM15 6.50638C14.5791 6.50638 14.2228 6.36055 13.9311 6.06888C13.6394 5.77722 13.4936 5.42092 13.4936 4.99999C13.4936 4.57906 13.6394 4.22276 13.9311 3.93109C14.2228 3.63942 14.5791 3.49359 15 3.49359C15.4209 3.49359 15.7772 3.63942 16.0689 3.93109C16.3605 4.22276 16.5064 4.57906 16.5064 4.99999C16.5064 5.42092 16.3605 5.77722 16.0689 6.06888C15.7772 6.36055 15.4209 6.50638 15 6.50638Z",fill:"currentColor"})})]})}),G5=e=>r.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 20 20",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:r.jsxs("g",{id:"public",children:[r.jsx("mask",{id:"mask0_1551_36",maskUnits:"userSpaceOnUse",x:"0",y:"0",width:"20",height:"20",children:r.jsx("rect",{id:"Bounding box",width:"1em",height:"1em",fill:"currentColor"})}),r.jsx("g",{mask:"url(#mask0_1551_36)",children:r.jsx("path",{id:"public_2",d:"M10.0028 17.5C8.96567 17.5 7.9906 17.3032 7.07758 16.9096C6.16457 16.516 5.37037 15.9818 4.69498 15.3071C4.0196 14.6323 3.48493 13.8389 3.09096 12.9267C2.69699 12.0145 2.5 11.0399 2.5 10.0028C2.5 8.96567 2.6968 7.9906 3.0904 7.07758C3.48401 6.16457 4.01819 5.37037 4.69294 4.69498C5.36769 4.0196 6.16114 3.48493 7.07329 3.09096C7.98546 2.69699 8.9601 2.5 9.99721 2.5C11.0343 2.5 12.0094 2.6968 12.9224 3.0904C13.8354 3.48401 14.6296 4.01819 15.305 4.69294C15.9804 5.36769 16.5151 6.16114 16.909 7.07329C17.303 7.98546 17.5 8.9601 17.5 9.99721C17.5 11.0343 17.3032 12.0094 16.9096 12.9224C16.516 13.8354 15.9818 14.6296 15.3071 15.305C14.6323 15.9804 13.8389 16.5151 12.9267 16.909C12.0145 17.303 11.0399 17.5 10.0028 17.5ZM9.16667 16.625V15C8.70833 15 8.31597 14.8368 7.98958 14.5104C7.66319 14.184 7.5 13.7917 7.5 13.3333V12.5L3.5 8.5C3.45833 8.75 3.42014 9 3.38542 9.25C3.35069 9.5 3.33333 9.75 3.33333 10C3.33333 11.6806 3.88542 13.1528 4.98958 14.4167C6.09375 15.6806 7.48611 16.4167 9.16667 16.625ZM14.9167 14.5C15.1944 14.1944 15.4444 13.8646 15.6667 13.5104C15.8889 13.1562 16.0729 12.7882 16.2187 12.4062C16.3646 12.0243 16.4757 11.6319 16.5521 11.2292C16.6285 10.8264 16.6667 10.4167 16.6667 10C16.6667 8.63083 16.2909 7.38042 15.5393 6.24877C14.7877 5.11712 13.7746 4.30129 12.5 3.80129V4.16667C12.5 4.625 12.3368 5.01736 12.0104 5.34375C11.684 5.67014 11.2917 5.83333 10.8333 5.83333H9.16667V7.5C9.16667 7.73611 9.08681 7.93403 8.92708 8.09375C8.76736 8.25347 8.56944 8.33333 8.33333 8.33333H6.66667V10H11.6667C11.9028 10 12.1007 10.0799 12.2604 10.2396C12.4201 10.3993 12.5 10.5972 12.5 10.8333V13.3333H13.3333C13.6944 13.3333 14.0208 13.441 14.3125 13.6562C14.6042 13.8715 14.8056 14.1528 14.9167 14.5Z",fill:"currentColor"})})]})});function P2(e,n,t){var i,s=1;e==null&&(e=0),n==null&&(n=0),t==null&&(t=0);function o(){var l,C=i.length,a,h=0,c=0,u=0;for(l=0;l=(a=(l+C)/2))?l=a:C=a,i=s,!(s=s[u=+c]))return i[u]=o,e;if(h=+e._x.call(null,s.data),n===h)return o.next=s,i?i[u]=o:e._root=o,e;do i=i?i[u]=new Array(2):e._root=new Array(2),(c=n>=(a=(l+C)/2))?l=a:C=a;while((u=+c)==(p=+(h>=a)));return i[p]=s,i[u]=o,e}function X5(e){Array.isArray(e)||(e=Array.from(e));const n=e.length,t=new Float64Array(n);let i=1/0,s=-1/0;for(let o=0,l;os&&(s=l));if(i>s)return this;this.cover(i).cover(s);for(let o=0;oe||e>=t;)switch(l=+(el||(o=h.x1)=u))&&(h=C[C.length-1],C[C.length-1]=C[C.length-1-c],C[C.length-1-c]=h)}else{var p=Math.abs(e-+this._x.call(null,a.data));p=(h=(l+C)/2))?l=h:C=h,n=t,!(t=t[u=+c]))return this;if(!t.length)break;n[u+1&1]&&(i=n,p=u)}for(;t.data!==e;)if(s=t,!(t=t.next))return this;return(o=t.next)&&delete t.next,s?(o?s.next=o:delete s.next,this):n?(o?n[u]=o:delete n[u],(t=n[0]||n[1])&&t===(n[1]||n[0])&&!t.length&&(i?i[p]=t:this._root=t),this):(this._root=o,this)}function t0(e){for(var n=0,t=e.length;n=(u=(C+h)/2))?C=u:h=u,(w=t>=(p=(a+c)/2))?a=p:c=p,s=o,!(o=o[d=w<<1|_]))return s[d]=l,e;if(x=+e._x.call(null,o.data),f=+e._y.call(null,o.data),n===x&&t===f)return l.next=o,s?s[d]=l:e._root=l,e;do s=s?s[d]=new Array(4):e._root=new Array(4),(_=n>=(u=(C+h)/2))?C=u:h=u,(w=t>=(p=(a+c)/2))?a=p:c=p;while((d=w<<1|_)===(k=(f>=p)<<1|x>=u));return s[k]=o,s[d]=l,e}function a0(e){var n,t,i=e.length,s,o,l=new Array(i),C=new Array(i),a=1/0,h=1/0,c=-1/0,u=-1/0;for(t=0;tc&&(c=s),ou&&(u=o));if(a>c||h>u)return this;for(this.cover(a,h).cover(c,u),t=0;te||e>=s||i>n||n>=o;)switch(h=(nc||(C=f.y0)>u||(a=f.x1)=d)<<1|e>=w)&&(f=p[p.length-1],p[p.length-1]=p[p.length-1-_],p[p.length-1-_]=f)}else{var k=e-+this._x.call(null,x.data),g=n-+this._y.call(null,x.data),v=k*k+g*g;if(v=(p=(l+a)/2))?l=p:a=p,(_=u>=(x=(C+h)/2))?C=x:h=x,n=t,!(t=t[w=_<<1|f]))return this;if(!t.length)break;(n[w+1&3]||n[w+2&3]||n[w+3&3])&&(i=n,d=w)}for(;t.data!==e;)if(s=t,!(t=t.next))return this;return(o=t.next)&&delete t.next,s?(o?s.next=o:delete s.next,this):n?(o?n[w]=o:delete n[w],(t=n[0]||n[1]||n[2]||n[3])&&t===(n[3]||n[2]||n[1]||n[0])&&!t.length&&(i?i[d]=t:this._root=t),this):(this._root=o,this)}function p0(e){for(var n=0,t=e.length;n=(f=(a+u)/2))?a=f:u=f,(m=t>=(_=(h+p)/2))?h=_:p=_,(y=i>=(w=(c+x)/2))?c=w:x=w,o=l,!(l=l[j=y<<2|m<<1|v]))return o[j]=C,e;if(d=+e._x.call(null,l.data),k=+e._y.call(null,l.data),g=+e._z.call(null,l.data),n===d&&t===k&&i===g)return C.next=l,o?o[j]=C:e._root=C,e;do o=o?o[j]=new Array(8):e._root=new Array(8),(v=n>=(f=(a+u)/2))?a=f:u=f,(m=t>=(_=(h+p)/2))?h=_:p=_,(y=i>=(w=(c+x)/2))?c=w:x=w;while((j=y<<2|m<<1|v)===(L=(g>=w)<<2|(k>=_)<<1|d>=f));return o[L]=l,o[j]=C,e}function L0(e){Array.isArray(e)||(e=Array.from(e));const n=e.length,t=new Float64Array(n),i=new Float64Array(n),s=new Float64Array(n);let o=1/0,l=1/0,C=1/0,a=-1/0,h=-1/0,c=-1/0;for(let u=0,p,x,f,_;ua&&(a=x),fh&&(h=f),_c&&(c=_));if(o>a||l>h||C>c)return this;this.cover(o,l,C).cover(a,h,c);for(let u=0;ue||e>=l||s>n||n>=C||o>t||t>=a;)switch(p=(tf||(h=g.y0)>_||(c=g.z0)>w||(u=g.x1)=j)<<2|(n>=y)<<1|e>=m)&&(g=d[d.length-1],d[d.length-1]=d[d.length-1-v],d[d.length-1-v]=g)}else{var L=e-+this._x.call(null,k.data),M=n-+this._y.call(null,k.data),S=t-+this._z.call(null,k.data),P=L*L+M*M+S*S;if(P=(_=(l+h)/2))?l=_:h=_,(g=x>=(w=(C+c)/2))?C=w:c=w,(v=f>=(d=(a+u)/2))?a=d:u=d,n=t,!(t=t[m=v<<2|g<<1|k]))return this;if(!t.length)break;(n[m+1&7]||n[m+2&7]||n[m+3&7]||n[m+4&7]||n[m+5&7]||n[m+6&7]||n[m+7&7])&&(i=n,y=m)}for(;t.data!==e;)if(s=t,!(t=t.next))return this;return(o=t.next)&&delete t.next,s?(o?s.next=o:delete s.next,this):n?(o?n[m]=o:delete n[m],(t=n[0]||n[1]||n[2]||n[3]||n[4]||n[5]||n[6]||n[7])&&t===(n[7]||n[6]||n[5]||n[4]||n[3]||n[2]||n[1]||n[0])&&!t.length&&(i?i[y]=t:this._root=t),this):(this._root=o,this)}function E0(e){for(var n=0,t=e.length;n1&&(_=x.y+x.vy),t>2&&(w=x.z+x.vz),p.visit(v);function v(m,y,j,L,M,S,P){var V=[y,j,L,M,S,P],U=V[0],B=V[1],b=V[2],E=V[t],I=V[t+1],z=V[t+2],R=m.data,W=m.r,O=d+W;if(R){if(R.index>x.index){var A=f-R.x-R.vx,J=t>1?_-R.y-R.vy:0,D=t>2?w-R.z-R.vz:0,$=A*A+J*J+D*D;$1&&J===0&&(J=t1(s),$+=J*J),t>2&&D===0&&(D=t1(s),$+=D*D),$=(O-($=Math.sqrt($)))/$*o,x.vx+=(A*=$)*(O=(W*=W)/(k+W)),t>1&&(x.vy+=(J*=$)*O),t>2&&(x.vz+=(D*=$)*O),R.vx-=A*(O=1-O),t>1&&(R.vy-=J*O),t>2&&(R.vz-=D*O))}return}return U>f+O||E1&&(B>_+O||I<_-O)||t>2&&(b>w+O||zc.r&&(c.r=c[u].r)}function h(){if(n){var c,u=n.length,p;for(i=new Array(u),c=0;ctypeof p=="function")||Math.random,t=u.find(p=>[1,2,3].includes(p))||2,h()},C.iterations=function(c){return arguments.length?(l=+c,C):l},C.strength=function(c){return arguments.length?(o=+c,C):o},C.radius=function(c){return arguments.length?(e=typeof c=="function"?c:Y(+c),h(),C):e},C}function z0(e){return e.index}function U2(e,n){var t=e.get(n);if(!t)throw new Error("node not found: "+n);return t}function F0(e){var n=z0,t=p,i,s=Y(30),o,l,C,a,h,c,u=1;e==null&&(e=[]);function p(d){return 1/Math.min(a[d.source.index],a[d.target.index])}function x(d){for(var k=0,g=e.length;k1&&(M=j.y+j.vy-y.y-y.vy||t1(c)),C>2&&(S=j.z+j.vz-y.z-y.vz||t1(c)),P=Math.sqrt(L*L+M*M+S*S),P=(P-o[v])/P*d*i[v],L*=P,M*=P,S*=P,j.vx-=L*(V=h[v]),C>1&&(j.vy-=M*V),C>2&&(j.vz-=S*V),y.vx+=L*(V=1-V),C>1&&(y.vy+=M*V),C>2&&(y.vz+=S*V)}function f(){if(l){var d,k=l.length,g=e.length,v=new Map(l.map((y,j)=>[n(y,j,l),y])),m;for(d=0,a=new Array(k);dtypeof g=="function")||Math.random,C=k.find(g=>[1,2,3].includes(g))||2,f()},x.links=function(d){return arguments.length?(e=d,f(),x):e},x.id=function(d){return arguments.length?(n=d,x):n},x.iterations=function(d){return arguments.length?(u=+d,x):u},x.strength=function(d){return arguments.length?(t=typeof d=="function"?d:Y(+d),_(),x):t},x.distance=function(d){return arguments.length?(s=typeof d=="function"?d:Y(+d),w(),x):s},x}var D0={value:()=>{}};function C3(){for(var e=0,n=arguments.length,t={},i;e=0&&(i=t.slice(s+1),t=t.slice(0,s)),t&&!n.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:i}})}z1.prototype=C3.prototype={constructor:z1,on:function(e,n){var t=this._,i=q0(e+"",t),s,o=-1,l=i.length;if(arguments.length<2){for(;++o0)for(var t=new Array(s),i=0,s,o;i=0&&e._call.call(void 0,n),e=e._next;--y1}function A2(){h1=(W1=T1.now())+X1,y1=E1=0;try{X0()}finally{y1=0,K0(),h1=0}}function Y0(){var e=T1.now(),n=e-W1;n>a3&&(X1-=n,W1=e)}function K0(){for(var e,n=G1,t,i=1/0;n;)n._call?(i>n._time&&(i=n._time),e=n,n=n._next):(t=n._next,n._next=null,n=e?e._next=t:G1=t);S1=e,l2(i)}function l2(e){if(!y1){E1&&(E1=clearTimeout(E1));var n=e-h1;n>24?(e<1/0&&(E1=setTimeout(A2,e-T1.now()-X1)),M1&&(M1=clearInterval(M1))):(M1||(W1=T1.now(),M1=setInterval(Y0,a3)),y1=1,c3(A2))}}const Q0=1664525,J0=1013904223,$2=4294967296;function e6(){let e=1;return()=>(e=(Q0*e+J0)%$2)/$2}var z2=3;function r2(e){return e.x}function F2(e){return e.y}function t6(e){return e.z}var n6=10,r6=Math.PI*(3-Math.sqrt(5)),i6=Math.PI*20/(9+Math.sqrt(221));function s6(e,n){n=n||2;var t=Math.min(z2,Math.max(1,Math.round(n))),i,s=1,o=.001,l=1-Math.pow(o,1/300),C=0,a=.6,h=new Map,c=u3(x),u=C3("tick","end"),p=e6();e==null&&(e=[]);function x(){f(),u.call("tick",i),s1&&(v.fy==null?v.y+=v.vy*=a:(v.y=v.fy,v.vy=0)),t>2&&(v.fz==null?v.z+=v.vz*=a:(v.z=v.fz,v.vz=0));return i}function _(){for(var d=0,k=e.length,g;d1&&isNaN(g.y)||t>2&&isNaN(g.z)){var v=n6*(t>2?Math.cbrt(.5+d):t>1?Math.sqrt(.5+d):d),m=d*r6,y=d*i6;t===1?g.x=v:t===2?(g.x=v*Math.cos(m),g.y=v*Math.sin(m)):(g.x=v*Math.sin(m)*Math.cos(y),g.y=v*Math.cos(m),g.z=v*Math.sin(m)*Math.sin(y))}(isNaN(g.vx)||t>1&&isNaN(g.vy)||t>2&&isNaN(g.vz))&&(g.vx=0,t>1&&(g.vy=0),t>2&&(g.vz=0))}}function w(d){return d.initialize&&d.initialize(e,p,t),d}return _(),i={tick:f,restart:function(){return c.restart(x),i},stop:function(){return c.stop(),i},numDimensions:function(d){return arguments.length?(t=Math.min(z2,Math.max(1,Math.round(d))),h.forEach(w),i):t},nodes:function(d){return arguments.length?(e=d,_(),h.forEach(w),i):e},alpha:function(d){return arguments.length?(s=+d,i):s},alphaMin:function(d){return arguments.length?(o=+d,i):o},alphaDecay:function(d){return arguments.length?(l=+d,i):+l},alphaTarget:function(d){return arguments.length?(C=+d,i):C},velocityDecay:function(d){return arguments.length?(a=1-d,i):1-a},randomSource:function(d){return arguments.length?(p=d,h.forEach(w),i):p},force:function(d,k){return arguments.length>1?(k==null?h.delete(d):h.set(d,w(k)),i):h.get(d)},find:function(){var d=Array.prototype.slice.call(arguments),k=d.shift()||0,g=(t>1?d.shift():null)||0,v=(t>2?d.shift():null)||0,m=d.shift()||1/0,y=0,j=e.length,L,M,S,P,V,U;for(m*=m,y=0;y1?(u.on(d,k),i):u.on(d)}}}function D2(){var e,n,t,i,s,o=Y(-30),l,C=1,a=1/0,h=.81;function c(f){var _,w=e.length,d=(n===1?a2(e,r2):n===2?h2(e,r2,F2):n===3?d2(e,r2,F2,t6):null).visitAfter(p);for(s=f,_=0;_1&&(f.y=v/k),n>2&&(f.z=m/k)}else{w=f,w.x=w.data.x,n>1&&(w.y=w.data.y),n>2&&(w.z=w.data.z);do _+=l[w.data.index];while(w=w.next)}f.value=_}function x(f,_,w,d,k){if(!f.value)return!0;var g=[w,d,k][n-1],v=f.x-t.x,m=n>1?f.y-t.y:0,y=n>2?f.z-t.z:0,j=g-_,L=v*v+m*m+y*y;if(j*j/h1&&m===0&&(m=t1(i),L+=m*m),n>2&&y===0&&(y=t1(i),L+=y*y),L1&&(t.vy+=m*f.value*s/L),n>2&&(t.vz+=y*f.value*s/L)),!0;if(f.length||L>=a)return;(f.data!==t||f.next)&&(v===0&&(v=t1(i),L+=v*v),n>1&&m===0&&(m=t1(i),L+=m*m),n>2&&y===0&&(y=t1(i),L+=y*y),L1&&(t.vy+=m*j),n>2&&(t.vz+=y*j));while(f=f.next)}return c.initialize=function(f,..._){e=f,i=_.find(w=>typeof w=="function")||Math.random,n=_.find(w=>[1,2,3].includes(w))||2,u()},c.strength=function(f){return arguments.length?(o=typeof f=="function"?f:Y(+f),u(),c):o},c.distanceMin=function(f){return arguments.length?(C=f*f,c):Math.sqrt(C)},c.distanceMax=function(f){return arguments.length?(a=f*f,c):Math.sqrt(a)},c.theta=function(f){return arguments.length?(h=f*f,c):Math.sqrt(h)},c}function q2(e,n,t,i){var s,o,l=Y(.1),C,a;typeof e!="function"&&(e=Y(+e)),n==null&&(n=0),t==null&&(t=0),i==null&&(i=0);function h(u){for(var p=0,x=s.length;p1&&(f.vy+=w*g),o>2&&(f.vz+=d*g)}}function c(){if(s){var u,p=s.length;for(C=new Array(p),a=new Array(p),u=0;u[1,2,3].includes(x))||2,c()},h.strength=function(u){return arguments.length?(l=typeof u=="function"?u:Y(+u),c(),h):l},h.radius=function(u){return arguments.length?(e=typeof u=="function"?u:Y(+u),c(),h):e},h.x=function(u){return arguments.length?(n=+u,h):n},h.y=function(u){return arguments.length?(t=+u,h):t},h.z=function(u){return arguments.length?(i=+u,h):i},h}function o6(e){var n=Y(.1),t,i,s;typeof e!="function"&&(e=Y(e==null?0:+e));function o(C){for(var a=0,h=t.length,c;a{},setForces:()=>{},addRadialForce:()=>{},addDefaultForce:()=>{},addClusterForce:()=>{},addSplitForce:()=>{},simulationRestart:()=>{},getLinks:()=>[]},C6={data:null,simulation:null,selectionGraphData:{nodes:[],links:[]},disableCameraRotation:!0,scrollEventsDisabled:!1,graphRadius:1500,selectionGraphRadius:200,graphStyle:"sphere",hoveredNode:null,hoveredNodeSiblings:[],selectedNode:null,activeEdge:null,cameraFocusTrigger:!1,nearbyNodeIds:[],showSelectionGraph:!1,simulationHelpers:l6,isHovering:!1,selectionPath:[],activeNode:null,highlightNodes:[],searchQuery:"",selectedNodeTypes:[],selectedLinkTypes:[]},j1=X2()((e,n)=>({...C6,setData:t=>{e({data:t})},setSelectedNodeTypes:t=>{const{selectedNodeTypes:i}=n(),s=i.includes(t)?i.filter(o=>o!==t):[...i,t];e({selectedNodeTypes:s})},setSelectedLinkTypes:t=>{const{selectedLinkTypes:i}=n(),s=i.includes(t)?i.filter(o=>o!==t):[...i,t];e({selectedLinkTypes:s})},resetSelectedNodeTypes:()=>e({selectedNodeTypes:[]}),resetSelectedLinkTypes:()=>e({selectedLinkTypes:[]}),setSelectionData:t=>e({selectionGraphData:t}),setScrollEventsDisabled:t=>e({scrollEventsDisabled:t}),setDisableCameraRotation:t=>e({disableCameraRotation:t}),setIsHovering:t=>e({isHovering:t}),setGraphRadius:t=>e({graphRadius:t}),setSelectionGraphRadius:t=>e({selectionGraphRadius:t}),setGraphStyle:t=>e({graphStyle:"sphere"}),setHoveredNode:t=>{const{nodesNormalized:i}=I1.getState()||{};if(t){const s=i.get(t.ref_id),o=[...(s==null?void 0:s.targets)||[],...(s==null?void 0:s.sources)||[]];e({hoveredNode:t,hoveredNodeSiblings:o})}else e({hoveredNode:t,hoveredNodeSiblings:[]})},setActiveEdge:t=>{e({activeEdge:t})},setActiveNode:t=>{e({activeNode:t})},setHighlightNodes:t=>{e({highlightNodes:t})},addToSelectionPath:t=>{const{selectionPath:i}=n();e({selectionPath:[...i,t]})},setSelectedNode:t=>{const{nodesNormalized:i}=I1.getState()||{};t||e({hoveredNode:null,selectedNode:null,disableCameraRotation:!1,showSelectionGraph:!1,selectionPath:[]});const{selectedNode:s,simulation:o,selectionPath:l}=n();if((s==null?void 0:s.ref_id)!==(t==null?void 0:t.ref_id)){const C=o.nodes().find(a=>a.ref_id===(t==null?void 0:t.ref_id))||null;if(t!=null&&t.ref_id){const a=(i==null?void 0:i.get(t==null?void 0:t.ref_id))||{};e({hoveredNode:null,selectedNode:{...C,...a},disableCameraRotation:!0,showSelectionGraph:!!t,selectionPath:[...l,C.ref_id]})}}},setCameraFocusTrigger:t=>e({cameraFocusTrigger:t}),setNearbyNodeIds:t=>{const i=n().nearbyNodeIds;(t.length!==i.length||t[0]!==i[0])&&e({nearbyNodeIds:t})},setShowSelectionGraph:t=>e({showSelectionGraph:t}),simulationHelpers:{addNodesAndLinks:(t,i,s)=>{const{simulation:o,simulationHelpers:l}=n();console.log(o.nodes()),console.log(t),o.stop();const C=structuredClone(t),a=structuredClone(i);o.stop();const h=s?[]:o.nodes(),c=s?[]:o.force("link").links();h.push(...C),c.push(...a),o.nodes(h),o.force("link").links([]).links(c),l.simulationRestart();try{console.log("try")}catch(u){console.error(u)}},addRadialForce:()=>{const{simulation:t}=n();t.nodes(t.nodes().map(i=>({...i,...$1}))).force("y",null).force("center",P2().strength(1)).force("charge",D2().strength(-1)).force("collide",n2().radius(i=>(i.scale||1)*95).strength(.5).iterations(1))},addClusterForce:()=>{const{simulation:t,highlightNodes:i}=n();t.nodes(t.nodes().map(s=>({...s,...$1}))).force("cluster",q2(s=>i.includes(s.ref_id)?25:500).strength(1))},addDefaultForce:()=>{const{simulation:t}=n();t.nodes(t.nodes().map(i=>({...i,...$1}))).force("y",null).force("charge",D2().strength(-20)).force("center",P2().strength(1)).force("collide",n2().radius(()=>250).strength(1).iterations(1))},addSplitForce:()=>{const{simulation:t}=n(),{nodeTypes:i}=I1.getState();t.stop().nodes(t.nodes().map(s=>({...s,...$1}))).force("radial",q2(200,0,0,0).strength(.1)).force("collide",n2().radius(()=>250).strength(1).iterations(1)).force("y",o6().y(s=>{const o=i.indexOf(s.node_type),l=Math.floor(o/2)*400;return o%2===0?l:-l}).strength(10))},getLinks:()=>{const{simulation:t}=n();return t?t.force("link").links():[]},setForces:()=>{const{graphStyle:t,simulationHelpers:i}=n();t==="split"&&i.addSplitForce(),t==="sphere"&&i.addRadialForce(),t==="force"&&i.addDefaultForce(),i.simulationRestart()},simulationRestart:()=>{const{simulation:t}=n();t.alpha(1).restart()}},simulationCreate:(t,i)=>{const s=structuredClone(t),o=structuredClone(i),l=s6([]).numDimensions(3).stop().nodes(s).force("link",F0().strength(0).links(o).id(C=>C.ref_id));e({simulation:l})},removeSimulation:()=>e({simulation:null}),setSearchQuery:t=>e({searchQuery:t})})),d3=()=>j1(e=>e.selectedNode),E7=()=>j1(e=>e.hoveredNode),a6=()=>j1(e=>e.setSelectedNode),c6=()=>(j1(z5(e=>[e.graphStyle,e.setGraphStyle])),null);q(f1).attrs({direction:"row",align:"center",justify:"space-between"})` padding: 6px 6px 6px 11px; background: ${i1.BG1}; border-radius: 200px; diff --git a/build/assets/index-25ee1701.js b/build/assets/index-aff6ba6e.js similarity index 95% rename from build/assets/index-25ee1701.js rename to build/assets/index-aff6ba6e.js index cfcbfa514..0ea514b59 100644 --- a/build/assets/index-25ee1701.js +++ b/build/assets/index-aff6ba6e.js @@ -1,4 +1,4 @@ -import{b0 as j,b1 as E,b2 as y,b3 as R,b4 as T,b5 as U,b6 as D,b7 as O,s as p,a as u,b as Z,r as f,j as e,F as r,B as C,a_ as J,T as z,b8 as K,aY as X,aZ as Q,e as ee,u as te,t as se,aW as ne,aX as m,a$ as oe,v as re,b9 as ae,ah as ie,ba as ce,bb as le,ag as de,w as ue,bc as pe}from"./index-4bb27744.js";import{a8 as xe}from"./index-7730ff6f.js";import{f as he}from"./index-5ca84596.js";import{C as fe}from"./ClipLoader-1ef5878d.js";const A=/\b(?:twitter\.com|x\.com)\/(?:@)?([\w_]+)(?:$|\?[^/]*$)/,we=/(https?:\/\/)?(www\.)?youtube\.com\/watch\?v=([A-Za-z0-9_-]+)/,ge=/(https?:\/\/)?(www\.)?youtube\.com\/live\/([A-Za-z0-9_-]+)/,me=/(https?:\/\/)?(www\.)?youtu\.be\/([A-Za-z0-9_-]+)/,be=/https:\/\/twitter\.com\/i\/spaces\/([A-Za-z0-9_-]+)/,ye=/https:\/\/(twitter\.com|x\.com)\/[^/]+\/status\/(\d+)/,je=/(https?:\/\/)?([A-Za-z0-9_-]+)\.mp3/,Se=/(https?:\/\/)?(.*\.)?.+\/(feed|rss|rss\.xml|.*\?(feed|format)=rss)(\/.*)?$/,ve=/https?:\/\/(www\.)?youtube\.com\/(user\/)?(@)?([\w-]+)/,_e=/^(https?|ftp):\/\/[^\s/$.?#].[^\s]*$/,Ee=/https:\/\/twitter\.com\/i\/broadcasts\/([A-Za-z0-9_-]+)/,Re=/https:\/\/github\.com\/[\w-]+\/[\w-]+/;async function Ce(t){try{const n=(await fetch(t,{method:"HEAD"})).headers.get("Content-Type");return(n==null?void 0:n.includes("application/rss+xml"))??!1}catch{return!1}}async function ze(t){return[ge,Ee,we,me,be,je].some(n=>n.test(t))?T:ve.test(t)?E:A.test(t)?j:ye.test(t)?U:Se.test(t)?y:Re.test(t)?R:_e.test(t)?await Ce(t)?y:D:O}const $e=(t,s="")=>{const o=(s===j?A:/@(\w+)/).exec(t);return o?o[1]:null},_=t=>!!t&&[j,E,y,R].includes(t),Be=({onClick:t,loading:s,type:n,error:o})=>{const b=Z(i=>i.budget),[a,x]=f.useState(10),d=_(n)?"radar":"add_node";return f.useEffect(()=>{(async()=>{try{const c=await K(d);x(c.data.price)}catch(c){console.error("cannot fetch",c)}})()},[d]),e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:20,children:e.jsx(r,{align:"center",direction:"row",children:e.jsx(ke,{children:"Approve Cost"})})}),e.jsxs(r,{align:"center",direction:"row",justify:"space-between",mb:20,children:[e.jsxs(Te,{children:[e.jsx("div",{className:"title",children:"COST"}),e.jsxs("div",{className:"value","data-testid":"check-price",children:[a," sats"]})]}),e.jsxs(Ae,{children:[e.jsx("div",{className:"title",children:"BUDGET"}),e.jsxs("div",{className:"value",children:[he(b)," sats"]})]})]}),e.jsx(r,{children:e.jsx(C,{color:"secondary","data-testid":"check-icon",disabled:s||!!o,onClick:t,size:"large",startIcon:s?e.jsx(L,{children:e.jsx(fe,{color:u.lightGray,size:12})}):e.jsxs(L,{children:[" ",e.jsx(xe,{})]}),type:"submit",variant:"contained",children:"Approve"})}),o?e.jsx(Pe,{children:e.jsxs(Ne,{children:[e.jsx(J,{className:"errorIcon"}),e.jsx("span",{children:o})]})}):null]})},Te=p(r).attrs({direction:"column",align:"space-between",justify:"flex-start"})` +import{a$ as j,b0 as E,b1 as y,b2 as R,b3 as T,b4 as U,b5 as D,b6 as O,s as p,a as u,b as Z,r as f,j as e,F as r,B as C,aZ as J,T as z,b7 as K,aX as X,aY as Q,e as ee,u as te,t as se,aV as ne,aW as m,a_ as oe,v as re,b8 as ae,ag as ie,b9 as ce,ba as le,af as de,w as ue,bb as pe}from"./index-4e60c9e2.js";import{a8 as xe}from"./index-af5a3f81.js";import{f as he}from"./index-763b7c2d.js";import{C as fe}from"./ClipLoader-8590c2f1.js";const A=/\b(?:twitter\.com|x\.com)\/(?:@)?([\w_]+)(?:$|\?[^/]*$)/,we=/(https?:\/\/)?(www\.)?youtube\.com\/watch\?v=([A-Za-z0-9_-]+)/,ge=/(https?:\/\/)?(www\.)?youtube\.com\/live\/([A-Za-z0-9_-]+)/,me=/(https?:\/\/)?(www\.)?youtu\.be\/([A-Za-z0-9_-]+)/,be=/https:\/\/twitter\.com\/i\/spaces\/([A-Za-z0-9_-]+)/,ye=/https:\/\/(twitter\.com|x\.com)\/[^/]+\/status\/(\d+)/,je=/(https?:\/\/)?([A-Za-z0-9_-]+)\.mp3/,Se=/(https?:\/\/)?(.*\.)?.+\/(feed|rss|rss\.xml|.*\?(feed|format)=rss)(\/.*)?$/,ve=/https?:\/\/(www\.)?youtube\.com\/(user\/)?(@)?([\w-]+)/,_e=/^(https?|ftp):\/\/[^\s/$.?#].[^\s]*$/,Ee=/https:\/\/twitter\.com\/i\/broadcasts\/([A-Za-z0-9_-]+)/,Re=/https:\/\/github\.com\/[\w-]+\/[\w-]+/;async function Ce(t){try{const n=(await fetch(t,{method:"HEAD"})).headers.get("Content-Type");return(n==null?void 0:n.includes("application/rss+xml"))??!1}catch{return!1}}async function ze(t){return[ge,Ee,we,me,be,je].some(n=>n.test(t))?T:ve.test(t)?E:A.test(t)?j:ye.test(t)?U:Se.test(t)?y:Re.test(t)?R:_e.test(t)?await Ce(t)?y:D:O}const $e=(t,s="")=>{const o=(s===j?A:/@(\w+)/).exec(t);return o?o[1]:null},_=t=>!!t&&[j,E,y,R].includes(t),Be=({onClick:t,loading:s,type:n,error:o})=>{const b=Z(i=>i.budget),[a,x]=f.useState(10),d=_(n)?"radar":"add_node";return f.useEffect(()=>{(async()=>{try{const c=await K(d);x(c.data.price)}catch(c){console.error("cannot fetch",c)}})()},[d]),e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:20,children:e.jsx(r,{align:"center",direction:"row",children:e.jsx(ke,{children:"Approve Cost"})})}),e.jsxs(r,{align:"center",direction:"row",justify:"space-between",mb:20,children:[e.jsxs(Te,{children:[e.jsx("div",{className:"title",children:"COST"}),e.jsxs("div",{className:"value","data-testid":"check-price",children:[a," sats"]})]}),e.jsxs(Ae,{children:[e.jsx("div",{className:"title",children:"BUDGET"}),e.jsxs("div",{className:"value",children:[he(b)," sats"]})]})]}),e.jsx(r,{children:e.jsx(C,{color:"secondary","data-testid":"check-icon",disabled:s||!!o,onClick:t,size:"large",startIcon:s?e.jsx(L,{children:e.jsx(fe,{color:u.lightGray,size:12})}):e.jsxs(L,{children:[" ",e.jsx(xe,{})]}),type:"submit",variant:"contained",children:"Approve"})}),o?e.jsx(Pe,{children:e.jsxs(Ne,{children:[e.jsx(J,{className:"errorIcon"}),e.jsx("span",{children:o})]})}):null]})},Te=p(r).attrs({direction:"column",align:"space-between",justify:"flex-start"})` width: 141px; height: 61px; border: 1px solid ${u.GRAY7}; diff --git a/build/assets/index-005a3994.js b/build/assets/index-b8b4f42e.js similarity index 95% rename from build/assets/index-005a3994.js rename to build/assets/index-b8b4f42e.js index d74aa8f9e..b0340963c 100644 --- a/build/assets/index-005a3994.js +++ b/build/assets/index-b8b4f42e.js @@ -1,5 +1,5 @@ -import{r as h,L as X,M as Q,N as F,O as I,S as K,H as Z,j as e,U as J,V as ee,Y as D,al as gt,P as ne,am as ft,s as c,a as x,T as N,B as W,F as g,e as M,bi as mt,ad as se,J as re,u as le,bj as bt,bk as jt,ah as yt,bl as wt,bm as Ve,x as ae,bn as qe,i as we,b0 as _e,b1 as Ne,b2 as ze,bo as Ct,bp as vt,ac as Tt,bq as $t,b as Xe,C as te,br as St,bg as Qe,bs as Ke,t as Ce,a$ as ce,v as ve,bt as kt,aY as _t,aZ as Nt,bu as de,bv as zt,k as Lt,q as It,a7 as Rt}from"./index-4bb27744.js";import{an as Bt,q as Mt,P as Te,ao as je,e as q,ap as Et,aq as At,r as Ft,X as Ze,ar as Je,as as et,at as tt,a8 as st,au as Ot,av as Wt,aw as Ht,ax as Le,ay as Ie,n as Re,az as ge,aA as Pt,o as Dt}from"./index-7730ff6f.js";import{T as Be,s as U,a as ot,S as nt,A as $e,E as Ut,D as Gt,b as rt,Q as at,V as it,c as Yt}from"./constants-bc1d79ca.js";import{C as z}from"./ClipLoader-1ef5878d.js";import{I as Vt,A as Se,T as lt}from"./index-22c3582f.js";import{u as R}from"./index-d0e3c339.js";import{T as Me}from"./Typography-f76555b9.js";import{T as qt,a as Xt}from"./Tabs-7ecc0b57.js";import"./index-5111ebdb.js";import"./Stack-6038813c.js";import"./createSvgIcon-41051178.js";import"./TextareaAutosize-b716e8d1.js";const Qt=h.createContext(),ct=Qt;function Kt(t){return X("MuiTable",t)}Q("MuiTable",["root","stickyHeader"]);const Zt=["className","component","padding","size","stickyHeader"],Jt=t=>{const{classes:s,stickyHeader:n}=t;return ee({root:["root",n&&"stickyHeader"]},Kt,s)},es=F("table",{name:"MuiTable",slot:"Root",overridesResolver:(t,s)=>{const{ownerState:n}=t;return[s.root,n.stickyHeader&&s.stickyHeader]}})(({theme:t,ownerState:s})=>I({display:"table",width:"100%",borderCollapse:"collapse",borderSpacing:0,"& caption":I({},t.typography.body2,{padding:t.spacing(2),color:(t.vars||t).palette.text.secondary,textAlign:"left",captionSide:"bottom"})},s.stickyHeader&&{borderCollapse:"separate"})),Ee="table",ts=h.forwardRef(function(s,n){const r=K({props:s,name:"MuiTable"}),{className:l,component:i=Ee,padding:a="normal",size:o="medium",stickyHeader:d=!1}=r,u=Z(r,Zt),m=I({},r,{component:i,padding:a,size:o,stickyHeader:d}),p=Jt(m),b=h.useMemo(()=>({padding:a,size:o,stickyHeader:d}),[a,o,d]);return e.jsx(ct.Provider,{value:b,children:e.jsx(es,I({as:i,role:i===Ee?null:"table",ref:n,className:J(p.root,l),ownerState:m},u))})}),pe=ts,ss=h.createContext(),xe=ss;function os(t){return X("MuiTableBody",t)}Q("MuiTableBody",["root"]);const ns=["className","component"],rs=t=>{const{classes:s}=t;return ee({root:["root"]},os,s)},as=F("tbody",{name:"MuiTableBody",slot:"Root",overridesResolver:(t,s)=>s.root})({display:"table-row-group"}),is={variant:"body"},Ae="tbody",ls=h.forwardRef(function(s,n){const r=K({props:s,name:"MuiTableBody"}),{className:l,component:i=Ae}=r,a=Z(r,ns),o=I({},r,{component:i}),d=rs(o);return e.jsx(xe.Provider,{value:is,children:e.jsx(as,I({className:J(d.root,l),as:i,ref:n,role:i===Ae?null:"rowgroup",ownerState:o},a))})}),cs=ls;function ds(t){return X("MuiTableCell",t)}const ps=Q("MuiTableCell",["root","head","body","footer","sizeSmall","sizeMedium","paddingCheckbox","paddingNone","alignLeft","alignCenter","alignRight","alignJustify","stickyHeader"]),xs=ps,hs=["align","className","component","padding","scope","size","sortDirection","variant"],us=t=>{const{classes:s,variant:n,align:r,padding:l,size:i,stickyHeader:a}=t,o={root:["root",n,a&&"stickyHeader",r!=="inherit"&&`align${D(r)}`,l!=="normal"&&`padding${D(l)}`,`size${D(i)}`]};return ee(o,ds,s)},gs=F("td",{name:"MuiTableCell",slot:"Root",overridesResolver:(t,s)=>{const{ownerState:n}=t;return[s.root,s[n.variant],s[`size${D(n.size)}`],n.padding!=="normal"&&s[`padding${D(n.padding)}`],n.align!=="inherit"&&s[`align${D(n.align)}`],n.stickyHeader&&s.stickyHeader]}})(({theme:t,ownerState:s})=>I({},t.typography.body2,{display:"table-cell",verticalAlign:"inherit",borderBottom:t.vars?`1px solid ${t.vars.palette.TableCell.border}`:`1px solid - ${t.palette.mode==="light"?gt(ne(t.palette.divider,1),.88):ft(ne(t.palette.divider,1),.68)}`,textAlign:"left",padding:16},s.variant==="head"&&{color:(t.vars||t).palette.text.primary,lineHeight:t.typography.pxToRem(24),fontWeight:t.typography.fontWeightMedium},s.variant==="body"&&{color:(t.vars||t).palette.text.primary},s.variant==="footer"&&{color:(t.vars||t).palette.text.secondary,lineHeight:t.typography.pxToRem(21),fontSize:t.typography.pxToRem(12)},s.size==="small"&&{padding:"6px 16px",[`&.${xs.paddingCheckbox}`]:{width:24,padding:"0 12px 0 16px","& > *":{padding:0}}},s.padding==="checkbox"&&{width:48,padding:"0 0 0 4px"},s.padding==="none"&&{padding:0},s.align==="left"&&{textAlign:"left"},s.align==="center"&&{textAlign:"center"},s.align==="right"&&{textAlign:"right",flexDirection:"row-reverse"},s.align==="justify"&&{textAlign:"justify"},s.stickyHeader&&{position:"sticky",top:0,zIndex:2,backgroundColor:(t.vars||t).palette.background.default})),fs=h.forwardRef(function(s,n){const r=K({props:s,name:"MuiTableCell"}),{align:l="inherit",className:i,component:a,padding:o,scope:d,size:u,sortDirection:m,variant:p}=r,b=Z(r,hs),j=h.useContext(ct),y=h.useContext(xe),C=y&&y.variant==="head";let w;a?w=a:w=C?"th":"td";let $=d;w==="td"?$=void 0:!$&&C&&($="col");const S=p||y&&y.variant,A=I({},r,{align:l,component:w,padding:o||(j&&j.padding?j.padding:"normal"),size:u||(j&&j.size?j.size:"medium"),sortDirection:m,stickyHeader:S==="head"&&j&&j.stickyHeader,variant:S}),O=us(A);let L=null;return m&&(L=m==="asc"?"ascending":"descending"),e.jsx(gs,I({as:w,ref:n,className:J(O.root,i),"aria-sort":L,scope:$,ownerState:A},b))}),ms=fs;function bs(t){return X("MuiTableHead",t)}Q("MuiTableHead",["root"]);const js=["className","component"],ys=t=>{const{classes:s}=t;return ee({root:["root"]},bs,s)},ws=F("thead",{name:"MuiTableHead",slot:"Root",overridesResolver:(t,s)=>s.root})({display:"table-header-group"}),Cs={variant:"head"},Fe="thead",vs=h.forwardRef(function(s,n){const r=K({props:s,name:"MuiTableHead"}),{className:l,component:i=Fe}=r,a=Z(r,js),o=I({},r,{component:i}),d=ys(o);return e.jsx(xe.Provider,{value:Cs,children:e.jsx(ws,I({as:i,className:J(d.root,l),ref:n,role:i===Fe?null:"rowgroup",ownerState:o},a))})}),dt=vs;function Ts(t){return X("MuiTableRow",t)}const $s=Q("MuiTableRow",["root","selected","hover","head","footer"]),Oe=$s,Ss=["className","component","hover","selected"],ks=t=>{const{classes:s,selected:n,hover:r,head:l,footer:i}=t;return ee({root:["root",n&&"selected",r&&"hover",l&&"head",i&&"footer"]},Ts,s)},_s=F("tr",{name:"MuiTableRow",slot:"Root",overridesResolver:(t,s)=>{const{ownerState:n}=t;return[s.root,n.head&&s.head,n.footer&&s.footer]}})(({theme:t})=>({color:"inherit",display:"table-row",verticalAlign:"middle",outline:0,[`&.${Oe.hover}:hover`]:{backgroundColor:(t.vars||t).palette.action.hover},[`&.${Oe.selected}`]:{backgroundColor:t.vars?`rgba(${t.vars.palette.primary.mainChannel} / ${t.vars.palette.action.selectedOpacity})`:ne(t.palette.primary.main,t.palette.action.selectedOpacity),"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.primary.mainChannel} / calc(${t.vars.palette.action.selectedOpacity} + ${t.vars.palette.action.hoverOpacity}))`:ne(t.palette.primary.main,t.palette.action.selectedOpacity+t.palette.action.hoverOpacity)}}})),We="tr",Ns=h.forwardRef(function(s,n){const r=K({props:s,name:"MuiTableRow"}),{className:l,component:i=We,hover:a=!1,selected:o=!1}=r,d=Z(r,Ss),u=h.useContext(xe),m=I({},r,{component:i,hover:a,selected:o,head:u&&u.variant==="head",footer:u&&u.variant==="footer"}),p=ks(m);return e.jsx(_s,I({as:i,ref:n,className:J(p.root,l),role:i===We?null:"row",ownerState:m},d))}),G=Ns;function ye(t){const s=new Date(Number(t)*1e3),n=s.getFullYear(),r=(1+s.getMonth()).toString().padStart(2,"0");return`${s.getDate().toString().padStart(2,"0")}/${r}/${n}`}const f=c(ms)` +import{r as h,K as X,L as K,M as F,N as I,P as Q,G as Z,j as e,S as J,U as ee,X as D,ak as gt,O as ne,al as ft,s as c,a as x,T as N,B as W,F as g,e as M,bh as mt,ac as se,H as re,u as le,bi as bt,bj as jt,ag as yt,bk as wt,bl as Ve,x as ae,bm as qe,i as we,a$ as _e,b0 as Ne,b1 as ze,bn as Ct,bo as vt,ab as Tt,bp as $t,b as Xe,C as te,bq as St,bf as Ke,br as Qe,t as Ce,a_ as ce,v as ve,bs as kt,aX as _t,aY as Nt,bt as de,bu as zt,k as Lt,q as It,a6 as Rt}from"./index-4e60c9e2.js";import{an as Bt,q as Mt,P as Te,ao as je,e as q,ap as Et,aq as At,r as Ft,X as Ze,ar as Je,as as et,at as tt,a8 as st,au as Ot,av as Wt,aw as Ht,ax as Le,ay as Ie,n as Re,az as ge,aA as Pt,o as Dt}from"./index-af5a3f81.js";import{T as Be,s as U,a as ot,S as nt,A as $e,E as Ut,D as Gt,b as rt,Q as at,V as it,c as Yt}from"./constants-b9d9206a.js";import{C as z}from"./ClipLoader-8590c2f1.js";import{I as Vt,A as Se,T as lt}from"./index-d96216bb.js";import{u as R}from"./index-aa1facf3.js";import{T as Me}from"./Typography-2a31701b.js";import{T as qt,a as Xt}from"./Tabs-71f3fbcc.js";import"./index-569670a3.js";import"./Stack-5870980a.js";import"./createSvgIcon-c125a9c8.js";import"./TextareaAutosize-f6242cb8.js";const Kt=h.createContext(),ct=Kt;function Qt(t){return X("MuiTable",t)}K("MuiTable",["root","stickyHeader"]);const Zt=["className","component","padding","size","stickyHeader"],Jt=t=>{const{classes:s,stickyHeader:n}=t;return ee({root:["root",n&&"stickyHeader"]},Qt,s)},es=F("table",{name:"MuiTable",slot:"Root",overridesResolver:(t,s)=>{const{ownerState:n}=t;return[s.root,n.stickyHeader&&s.stickyHeader]}})(({theme:t,ownerState:s})=>I({display:"table",width:"100%",borderCollapse:"collapse",borderSpacing:0,"& caption":I({},t.typography.body2,{padding:t.spacing(2),color:(t.vars||t).palette.text.secondary,textAlign:"left",captionSide:"bottom"})},s.stickyHeader&&{borderCollapse:"separate"})),Ee="table",ts=h.forwardRef(function(s,n){const r=Q({props:s,name:"MuiTable"}),{className:l,component:i=Ee,padding:a="normal",size:o="medium",stickyHeader:d=!1}=r,u=Z(r,Zt),m=I({},r,{component:i,padding:a,size:o,stickyHeader:d}),p=Jt(m),b=h.useMemo(()=>({padding:a,size:o,stickyHeader:d}),[a,o,d]);return e.jsx(ct.Provider,{value:b,children:e.jsx(es,I({as:i,role:i===Ee?null:"table",ref:n,className:J(p.root,l),ownerState:m},u))})}),pe=ts,ss=h.createContext(),xe=ss;function os(t){return X("MuiTableBody",t)}K("MuiTableBody",["root"]);const ns=["className","component"],rs=t=>{const{classes:s}=t;return ee({root:["root"]},os,s)},as=F("tbody",{name:"MuiTableBody",slot:"Root",overridesResolver:(t,s)=>s.root})({display:"table-row-group"}),is={variant:"body"},Ae="tbody",ls=h.forwardRef(function(s,n){const r=Q({props:s,name:"MuiTableBody"}),{className:l,component:i=Ae}=r,a=Z(r,ns),o=I({},r,{component:i}),d=rs(o);return e.jsx(xe.Provider,{value:is,children:e.jsx(as,I({className:J(d.root,l),as:i,ref:n,role:i===Ae?null:"rowgroup",ownerState:o},a))})}),cs=ls;function ds(t){return X("MuiTableCell",t)}const ps=K("MuiTableCell",["root","head","body","footer","sizeSmall","sizeMedium","paddingCheckbox","paddingNone","alignLeft","alignCenter","alignRight","alignJustify","stickyHeader"]),xs=ps,hs=["align","className","component","padding","scope","size","sortDirection","variant"],us=t=>{const{classes:s,variant:n,align:r,padding:l,size:i,stickyHeader:a}=t,o={root:["root",n,a&&"stickyHeader",r!=="inherit"&&`align${D(r)}`,l!=="normal"&&`padding${D(l)}`,`size${D(i)}`]};return ee(o,ds,s)},gs=F("td",{name:"MuiTableCell",slot:"Root",overridesResolver:(t,s)=>{const{ownerState:n}=t;return[s.root,s[n.variant],s[`size${D(n.size)}`],n.padding!=="normal"&&s[`padding${D(n.padding)}`],n.align!=="inherit"&&s[`align${D(n.align)}`],n.stickyHeader&&s.stickyHeader]}})(({theme:t,ownerState:s})=>I({},t.typography.body2,{display:"table-cell",verticalAlign:"inherit",borderBottom:t.vars?`1px solid ${t.vars.palette.TableCell.border}`:`1px solid + ${t.palette.mode==="light"?gt(ne(t.palette.divider,1),.88):ft(ne(t.palette.divider,1),.68)}`,textAlign:"left",padding:16},s.variant==="head"&&{color:(t.vars||t).palette.text.primary,lineHeight:t.typography.pxToRem(24),fontWeight:t.typography.fontWeightMedium},s.variant==="body"&&{color:(t.vars||t).palette.text.primary},s.variant==="footer"&&{color:(t.vars||t).palette.text.secondary,lineHeight:t.typography.pxToRem(21),fontSize:t.typography.pxToRem(12)},s.size==="small"&&{padding:"6px 16px",[`&.${xs.paddingCheckbox}`]:{width:24,padding:"0 12px 0 16px","& > *":{padding:0}}},s.padding==="checkbox"&&{width:48,padding:"0 0 0 4px"},s.padding==="none"&&{padding:0},s.align==="left"&&{textAlign:"left"},s.align==="center"&&{textAlign:"center"},s.align==="right"&&{textAlign:"right",flexDirection:"row-reverse"},s.align==="justify"&&{textAlign:"justify"},s.stickyHeader&&{position:"sticky",top:0,zIndex:2,backgroundColor:(t.vars||t).palette.background.default})),fs=h.forwardRef(function(s,n){const r=Q({props:s,name:"MuiTableCell"}),{align:l="inherit",className:i,component:a,padding:o,scope:d,size:u,sortDirection:m,variant:p}=r,b=Z(r,hs),j=h.useContext(ct),y=h.useContext(xe),C=y&&y.variant==="head";let w;a?w=a:w=C?"th":"td";let $=d;w==="td"?$=void 0:!$&&C&&($="col");const S=p||y&&y.variant,A=I({},r,{align:l,component:w,padding:o||(j&&j.padding?j.padding:"normal"),size:u||(j&&j.size?j.size:"medium"),sortDirection:m,stickyHeader:S==="head"&&j&&j.stickyHeader,variant:S}),O=us(A);let L=null;return m&&(L=m==="asc"?"ascending":"descending"),e.jsx(gs,I({as:w,ref:n,className:J(O.root,i),"aria-sort":L,scope:$,ownerState:A},b))}),ms=fs;function bs(t){return X("MuiTableHead",t)}K("MuiTableHead",["root"]);const js=["className","component"],ys=t=>{const{classes:s}=t;return ee({root:["root"]},bs,s)},ws=F("thead",{name:"MuiTableHead",slot:"Root",overridesResolver:(t,s)=>s.root})({display:"table-header-group"}),Cs={variant:"head"},Fe="thead",vs=h.forwardRef(function(s,n){const r=Q({props:s,name:"MuiTableHead"}),{className:l,component:i=Fe}=r,a=Z(r,js),o=I({},r,{component:i}),d=ys(o);return e.jsx(xe.Provider,{value:Cs,children:e.jsx(ws,I({as:i,className:J(d.root,l),ref:n,role:i===Fe?null:"rowgroup",ownerState:o},a))})}),dt=vs;function Ts(t){return X("MuiTableRow",t)}const $s=K("MuiTableRow",["root","selected","hover","head","footer"]),Oe=$s,Ss=["className","component","hover","selected"],ks=t=>{const{classes:s,selected:n,hover:r,head:l,footer:i}=t;return ee({root:["root",n&&"selected",r&&"hover",l&&"head",i&&"footer"]},Ts,s)},_s=F("tr",{name:"MuiTableRow",slot:"Root",overridesResolver:(t,s)=>{const{ownerState:n}=t;return[s.root,n.head&&s.head,n.footer&&s.footer]}})(({theme:t})=>({color:"inherit",display:"table-row",verticalAlign:"middle",outline:0,[`&.${Oe.hover}:hover`]:{backgroundColor:(t.vars||t).palette.action.hover},[`&.${Oe.selected}`]:{backgroundColor:t.vars?`rgba(${t.vars.palette.primary.mainChannel} / ${t.vars.palette.action.selectedOpacity})`:ne(t.palette.primary.main,t.palette.action.selectedOpacity),"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.primary.mainChannel} / calc(${t.vars.palette.action.selectedOpacity} + ${t.vars.palette.action.hoverOpacity}))`:ne(t.palette.primary.main,t.palette.action.selectedOpacity+t.palette.action.hoverOpacity)}}})),We="tr",Ns=h.forwardRef(function(s,n){const r=Q({props:s,name:"MuiTableRow"}),{className:l,component:i=We,hover:a=!1,selected:o=!1}=r,d=Z(r,Ss),u=h.useContext(xe),m=I({},r,{component:i,hover:a,selected:o,head:u&&u.variant==="head",footer:u&&u.variant==="footer"}),p=ks(m);return e.jsx(_s,I({as:i,ref:n,className:J(p.root,l),role:i===We?null:"row",ownerState:m},d))}),G=Ns;function ye(t){const s=new Date(Number(t)*1e3),n=s.getFullYear(),r=(1+s.getMonth()).toString().padStart(2,"0");return`${s.getDate().toString().padStart(2,"0")}/${r}/${n}`}const f=c(ms)` && { color: ${x.white}; border: none; @@ -253,7 +253,7 @@ import{r as h,L as X,M as Q,N as F,O as I,S as K,H as Z,j as e,U as J,V as ee,Y } `,Xs=c.div` margin-right: 40px; -`,Qs=()=>{const[t,s]=h.useState(!0),[n,r]=h.useState(""),[l,i]=le(d=>[d.queuedSources,d.setQueuedSources]);h.useEffect(()=>{(async()=>{s(!0);try{const u=await qe({approved:"False"});i(u.data)}catch(u){console.warn(u)}finally{s(!1)}})()},[i]);const a=d=>{r(n===d||!d?"":d)},o=l==null?void 0:l.filter(d=>!n||d.source_type===n);return e.jsxs(Ks,{align:"stretch",direction:"column",justify:"flex-end",children:[e.jsxs(ke,{align:"flex-start",justify:"space-between",children:[e.jsx(N,{className:"title",children:"Queued Sources"}),e.jsx(N,{className:"subtitle",children:"This is a queue of pending sources waiting for approval or denial from graph users. If you think a source will provide good content for the graph, you can pay to approve it. Think of this as an investment: you pay to add it to the source table, and if the content is popular you will earn from it. If content is not relevant to the graph, you should deny it."})]}),e.jsxs(g,{className:"filters",direction:"row",pb:16,px:36,children:[e.jsx(ie,{className:ae({selected:!n}),onClick:()=>a(""),size:"small",children:"All"}),Object.keys(U).map(d=>e.jsx(ie,{className:ae({selected:d===n}),onClick:()=>a(d),size:"small",children:U[d]},d))]}),e.jsx(Zs,{align:"center",justify:t?"center":"flex-start",children:t?e.jsx(z,{color:x.white}):e.jsx(qs,{data:o})})]})},Ks=c(g)` +`,Ks=()=>{const[t,s]=h.useState(!0),[n,r]=h.useState(""),[l,i]=le(d=>[d.queuedSources,d.setQueuedSources]);h.useEffect(()=>{(async()=>{s(!0);try{const u=await qe({approved:"False"});i(u.data)}catch(u){console.warn(u)}finally{s(!1)}})()},[i]);const a=d=>{r(n===d||!d?"":d)},o=l==null?void 0:l.filter(d=>!n||d.source_type===n);return e.jsxs(Qs,{align:"stretch",direction:"column",justify:"flex-end",children:[e.jsxs(ke,{align:"flex-start",justify:"space-between",children:[e.jsx(N,{className:"title",children:"Queued Sources"}),e.jsx(N,{className:"subtitle",children:"This is a queue of pending sources waiting for approval or denial from graph users. If you think a source will provide good content for the graph, you can pay to approve it. Think of this as an investment: you pay to add it to the source table, and if the content is popular you will earn from it. If content is not relevant to the graph, you should deny it."})]}),e.jsxs(g,{className:"filters",direction:"row",pb:16,px:36,children:[e.jsx(ie,{className:ae({selected:!n}),onClick:()=>a(""),size:"small",children:"All"}),Object.keys(U).map(d=>e.jsx(ie,{className:ae({selected:d===n}),onClick:()=>a(d),size:"small",children:U[d]},d))]}),e.jsx(Zs,{align:"center",justify:t?"center":"flex-start",children:t?e.jsx(z,{color:x.white}):e.jsx(qs,{data:o})})]})},Qs=c(g)` flex: 1; .title { @@ -462,7 +462,7 @@ import{r as h,L as X,M as Q,N as F,O as I,S as K,H as Z,j as e,U as J,V as ee,Y width: 100%; `,xo=c(g)` margin: 0 0 16px 36px; -`,ho=({selectedType:t,setSelectedType:s})=>{const[n,r]=h.useState([]);h.useEffect(()=>{(async()=>{try{const{data:o}=await St();r(o.edge_types)}catch(o){console.warn(o)}})()},[r]);const l=a=>({label:a,value:a}),i=a=>{s((a==null?void 0:a.value)||"")};return e.jsx(Se,{onSelect:i,options:n.map(l),selectedValue:t?l(t):null})},uo=({onSelect:t,selectedValue:s,topicId:n})=>{const[r,l]=h.useState([]),[i,a]=h.useState(!1),o=h.useMemo(()=>{const b=async j=>{const y={is_muted:"False",sort_by:$e,search:j,skip:"0",limit:"1000"};a(!0);try{const w=(await Ke(y.search)).data.filter($=>($==null?void 0:$.ref_id)!==n);l(w)}catch{l([])}finally{a(!1)}};return we.debounce(b,300)},[n]),d=b=>{const j=b.trim();if(!j){l([]);return}j.length>2&&o(b)},u=b=>{const j=b?r.find(y=>y.ref_id===b.value):null;t(j||null)},m=b=>({label:b.search_value,value:b.ref_id,type:b.node_type}),p=b=>b.map(m);return s?e.jsxs(g,{align:"center",basis:"100%",direction:"row",grow:1,shrink:1,children:[e.jsx("span",{children:s.search_value}),e.jsx(nt,{onClick:()=>t(null),size:"medium",children:e.jsx(te,{})})]}):e.jsx(Se,{handleInputChange:d,isLoading:i,onSelect:u,options:p(r)||Qe,selectedValue:s?m(s):null})},go=({from:t,onSelect:s,selectedType:n,setSelectedType:r,isSwapped:l,setIsSwapped:i,selectedToNode:a})=>e.jsxs(g,{mb:20,children:[e.jsx(g,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(g,{align:"center",direction:"row",children:e.jsx(fo,{children:"Add edge"})})}),e.jsxs(jo,{swap:l,children:[e.jsx(g,{children:e.jsx(yo,{disabled:!0,label:l?"To":"From",swap:l,value:t==null?void 0:t.name})}),e.jsxs(g,{my:16,children:[e.jsx(bo,{children:"Type"}),e.jsx(ho,{selectedType:n,setSelectedType:r})]}),e.jsx(g,{children:e.jsxs(wo,{children:[e.jsx(Co,{children:l?"From":"To"}),e.jsx(uo,{onSelect:s,selectedValue:a,topicId:t==null?void 0:t.ref_id})]})}),e.jsxs(mo,{children:[e.jsx(vo,{children:e.jsx(Je,{})}),e.jsx(To,{onClick:i,children:e.jsx(et,{})}),e.jsx($o,{children:e.jsx(tt,{})})]})]})]}),fo=c(N)` +`,ho=({selectedType:t,setSelectedType:s})=>{const[n,r]=h.useState([]);h.useEffect(()=>{(async()=>{try{const{data:o}=await St();r(o.edge_types)}catch(o){console.warn(o)}})()},[r]);const l=a=>({label:a,value:a}),i=a=>{s((a==null?void 0:a.value)||"")};return e.jsx(Se,{onSelect:i,options:n.map(l),selectedValue:t?l(t):null})},uo=({onSelect:t,selectedValue:s,topicId:n})=>{const[r,l]=h.useState([]),[i,a]=h.useState(!1),o=h.useMemo(()=>{const b=async j=>{const y={is_muted:"False",sort_by:$e,search:j,skip:"0",limit:"1000"};a(!0);try{const w=(await Qe(y.search)).data.filter($=>($==null?void 0:$.ref_id)!==n);l(w)}catch{l([])}finally{a(!1)}};return we.debounce(b,300)},[n]),d=b=>{const j=b.trim();if(!j){l([]);return}j.length>2&&o(b)},u=b=>{const j=b?r.find(y=>y.ref_id===b.value):null;t(j||null)},m=b=>({label:b.search_value,value:b.ref_id,type:b.node_type}),p=b=>b.map(m);return s?e.jsxs(g,{align:"center",basis:"100%",direction:"row",grow:1,shrink:1,children:[e.jsx("span",{children:s.search_value}),e.jsx(nt,{onClick:()=>t(null),size:"medium",children:e.jsx(te,{})})]}):e.jsx(Se,{handleInputChange:d,isLoading:i,onSelect:u,options:p(r)||Ke,selectedValue:s?m(s):null})},go=({from:t,onSelect:s,selectedType:n,setSelectedType:r,isSwapped:l,setIsSwapped:i,selectedToNode:a})=>e.jsxs(g,{mb:20,children:[e.jsx(g,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(g,{align:"center",direction:"row",children:e.jsx(fo,{children:"Add edge"})})}),e.jsxs(jo,{swap:l,children:[e.jsx(g,{children:e.jsx(yo,{disabled:!0,label:l?"To":"From",swap:l,value:t==null?void 0:t.name})}),e.jsxs(g,{my:16,children:[e.jsx(bo,{children:"Type"}),e.jsx(ho,{selectedType:n,setSelectedType:r})]}),e.jsx(g,{children:e.jsxs(wo,{children:[e.jsx(Co,{children:l?"From":"To"}),e.jsx(uo,{onSelect:s,selectedValue:a,topicId:t==null?void 0:t.ref_id})]})}),e.jsxs(mo,{children:[e.jsx(vo,{children:e.jsx(Je,{})}),e.jsx(To,{onClick:i,children:e.jsx(et,{})}),e.jsx($o,{children:e.jsx(tt,{})})]})]})]}),fo=c(N)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; @@ -560,7 +560,7 @@ import{r as h,L as X,M as Q,N as F,O as I,S as K,H as Z,j as e,U as J,V as ee,Y font-family: 'Barlow'; `,Lo=({topic:t,onClose:s})=>{const{close:n}=M("editTopic"),[r]=R(w=>[w.data]),l=Ce({mode:"onChange"}),{watch:i,setValue:a,reset:o,getValues:d}=l,[u,m]=h.useState(!1);h.useEffect(()=>(t&&a("name",t==null?void 0:t.name),()=>{o()}),[t,a,o]);const p=i("name"),b=p==null?void 0:p.trim(),j=()=>{s(),n()},y=async()=>{m(!0);try{if(await de(t==null?void 0:t.ref_id,{node_type:t==null?void 0:t.node_type,node_data:{name:b}}),r){const w={...r};w[t==null?void 0:t.ref_id].name=b,R.setState({data:w})}j()}catch(w){console.warn(w)}finally{m(!1)}},C=d().name&&(t==null?void 0:t.name)!==d().name;return e.jsx(ce,{id:"editTopic",kind:"regular",onClose:j,preventOutsideClose:!0,children:e.jsxs(ve,{...l,children:[e.jsx(No,{}),e.jsxs(W,{color:"secondary",disabled:u||!b||!C,onClick:y,size:"large",variant:"contained",children:["Save Changes",u&&e.jsx(Io,{children:e.jsx(z,{color:x.lightGray,size:12})})]})]})})},Io=c.span` margin-top: 2px; -`,Ro=({topicId:t,onSelect:s,selectedValue:n,dataId:r})=>{const[l,i]=h.useState([]),[a,o]=h.useState(!1),d=h.useMemo(()=>{const j=async y=>{const C={is_muted:"False",sort_by:$e,search:y,skip:"0",limit:"1000"};o(!0);try{const $=(await Ke(C.search)).data.filter(S=>(S==null?void 0:S.ref_id)!==t);i($)}catch{i([])}finally{o(!1)}};return we.debounce(j,300)},[t]),u=j=>{const y=j.trim();if(!y){i([]);return}y.length>2&&d(j)},m=j=>{const y=j?l.find(C=>C.ref_id===j.value):null;s(y||null)},p=j=>({label:j.search_value,value:j.ref_id,type:j.node_type}),b=j=>j.map(p);return n?e.jsxs(g,{align:"center",basis:"100%",direction:"row",grow:1,shrink:1,children:[e.jsx("span",{children:n.search_value}),e.jsx(nt,{onClick:()=>s(null),size:"medium",children:e.jsx(te,{})})]}):e.jsx(Se,{dataId:r,handleInputChange:u,isLoading:a,onSelect:m,options:b(l)||Qe,selectedValue:n?p(n):null})},Bo=({from:t,onSelect:s,selectedToNode:n,isSwapped:r,setIsSwapped:l})=>{var o;const i=t==null?void 0:t.map(d=>d.name).join(", "),a=t&&t.length===1?t[0].name:`${i==null?void 0:i.substring(0,25)} ...`;return e.jsxs(g,{mb:20,children:[e.jsx(g,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(g,{align:"center",direction:"row",children:e.jsx(Mo,{children:"Merge topic"})})}),e.jsxs(Fo,{swap:r,children:[e.jsx(Eo,{children:e.jsx(Oo,{disabled:!0,label:r?"To":"From",swap:r,value:a})}),e.jsxs(g,{my:16,children:[e.jsx(Ho,{children:"Type"}),e.jsx(N,{children:"IS ALIAS"})]}),e.jsx(g,{children:e.jsxs(Wo,{children:[e.jsx(Po,{children:r?"From":"To"}),e.jsx(Ro,{dataId:"to-node",onSelect:s,selectedValue:n,topicId:(o=t[t.length-1])==null?void 0:o.ref_id})]})}),e.jsxs(Ao,{children:[e.jsx(Do,{children:e.jsx(Je,{})}),e.jsx(Uo,{"data-testid":"swap-icon",disabled:(t==null?void 0:t.length)!==1,onClick:(t==null?void 0:t.length)===1?l:void 0,children:e.jsx(et,{})}),e.jsx(Go,{children:e.jsx(tt,{})})]})]})]})},Mo=c(N)` +`,Ro=({topicId:t,onSelect:s,selectedValue:n,dataId:r})=>{const[l,i]=h.useState([]),[a,o]=h.useState(!1),d=h.useMemo(()=>{const j=async y=>{const C={is_muted:"False",sort_by:$e,search:y,skip:"0",limit:"1000"};o(!0);try{const $=(await Qe(C.search)).data.filter(S=>(S==null?void 0:S.ref_id)!==t);i($)}catch{i([])}finally{o(!1)}};return we.debounce(j,300)},[t]),u=j=>{const y=j.trim();if(!y){i([]);return}y.length>2&&d(j)},m=j=>{const y=j?l.find(C=>C.ref_id===j.value):null;s(y||null)},p=j=>({label:j.search_value,value:j.ref_id,type:j.node_type}),b=j=>j.map(p);return n?e.jsxs(g,{align:"center",basis:"100%",direction:"row",grow:1,shrink:1,children:[e.jsx("span",{children:n.search_value}),e.jsx(nt,{onClick:()=>s(null),size:"medium",children:e.jsx(te,{})})]}):e.jsx(Se,{dataId:r,handleInputChange:u,isLoading:a,onSelect:m,options:b(l)||Ke,selectedValue:n?p(n):null})},Bo=({from:t,onSelect:s,selectedToNode:n,isSwapped:r,setIsSwapped:l})=>{var o;const i=t==null?void 0:t.map(d=>d.name).join(", "),a=t&&t.length===1?t[0].name:`${i==null?void 0:i.substring(0,25)} ...`;return e.jsxs(g,{mb:20,children:[e.jsx(g,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(g,{align:"center",direction:"row",children:e.jsx(Mo,{children:"Merge topic"})})}),e.jsxs(Fo,{swap:r,children:[e.jsx(Eo,{children:e.jsx(Oo,{disabled:!0,label:r?"To":"From",swap:r,value:a})}),e.jsxs(g,{my:16,children:[e.jsx(Ho,{children:"Type"}),e.jsx(N,{children:"IS ALIAS"})]}),e.jsx(g,{children:e.jsxs(Wo,{children:[e.jsx(Po,{children:r?"From":"To"}),e.jsx(Ro,{dataId:"to-node",onSelect:s,selectedValue:n,topicId:(o=t[t.length-1])==null?void 0:o.ref_id})]})}),e.jsxs(Ao,{children:[e.jsx(Do,{children:e.jsx(Je,{})}),e.jsx(Uo,{"data-testid":"swap-icon",disabled:(t==null?void 0:t.length)!==1,onClick:(t==null?void 0:t.length)===1?l:void 0,children:e.jsx(et,{})}),e.jsx(Go,{children:e.jsx(tt,{})})]})]})]})},Mo=c(N)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; @@ -654,9 +654,9 @@ import{r as h,L as X,M as Q,N as F,O as I,S as K,H as Z,j as e,U as J,V as ee,Y margin: 0 0 10px auto !important; `,qo=c.span` margin-top: 2px; -`,Xo=({topic:t,onClick:s,onSearch:n,checkedStates:r,setCheckedStates:l,isMuteDisabled:i})=>{const[a,o]=R(k=>[k.ids,k.total]),[d,u]=h.useState(!1),[m,p]=h.useState(!1),b=ye(t.date_added_to_graph),j=async(k,v)=>{u(!0);try{await de(k,{node_type:t==null?void 0:t.node_type,node_data:{is_muted:v}}),R.setState({ids:a.filter(_=>_!==k),total:o-1})}catch(_){console.warn(_)}},y=k=>{l(v=>({...v,[k]:!v[k]}))},C=(k,v)=>{var _;(_=window.getSelection())!=null&&_.toString()?k.preventDefault():n(v.name)},w=t.edgeList.slice(0,1),$=t.edgeList.length-w.length,[S,A]=re.useState(null),O=k=>{A(k.currentTarget),p(!0)},L=()=>{p(!1)},H=!!S&&m,B=r[t.ref_id]?"visible":"";return e.jsxs(he,{className:r[t.ref_id]?"checked":"",children:[e.jsx(f,{children:e.jsx(Zo,{className:`checkbox-section ${B}`,"data-testid":"topic-check-box",onClick:()=>y(t.ref_id),children:e.jsx(Jo,{checked:r[t.ref_id],children:e.jsx(en,{children:r[t.ref_id]&&e.jsx(st,{})})})})}),e.jsx(f,{onClick:k=>C(k,t),children:e.jsx(Ko,{children:t.name})}),e.jsx(f,{children:t.node_type}),e.jsx(f,{children:e.jsx(tn,{children:t.edgeCount})}),e.jsxs(f,{children:[e.jsx(Te,{anchorEl:S,anchorOrigin:{vertical:"top",horizontal:"center"},disableRestoreFocus:!0,id:"mouse-over-popover",onClose:L,onMouseEnter:()=>p(!0),onMouseLeave:L,open:H,sx:{pointerEvents:"auto","& .MuiPaper-root":{backgroundColor:"rgba(0, 0, 0, 0.9)",borderRadius:"4px",width:"160px",maxHeight:"200px",overflowY:"scroll"}},transformOrigin:{vertical:"bottom",horizontal:"center"},children:e.jsx(Me,{sx:{p:1.5,fontSize:"13px",fontWeight:400,lineHeight:"1.8",wordWrap:"break-word"},children:t.edgeList.join(", ")})}),w.join(", "),$>0&&e.jsx(Me,{"aria-haspopup":"true","aria-owns":H?"mouse-over-popover":void 0,component:"span",onMouseEnter:O,onMouseLeave:L,sx:{cursor:"pointer"},children:",..."})]}),e.jsx(f,{children:e.jsx("span",{children:b})}),e.jsx(f,{className:"cell-center",children:e.jsx(g,{direction:"row",justify:"space-between",children:e.jsx("div",{className:"approve-wrapper",children:d?e.jsx(Qo,{children:e.jsx(z,{color:x.white,size:16})}):e.jsxs(g,{direction:"row",children:[t.is_muted?e.jsx(q,{className:"centered",disabled:i,onClick:()=>j(t.ref_id,!1),children:e.jsx(Ot,{})}):e.jsx(q,{className:"centered",disabled:i,onClick:()=>j(t.ref_id,!0),children:e.jsx(Wt,{})}),e.jsx(q,{disabled:i,onClick:k=>s(k,t.ref_id),children:e.jsx(Ht,{"data-testid":"ThreeDotsIcons"})})]})})})})]},t.name)},Qo=c.span` +`,Xo=({topic:t,onClick:s,onSearch:n,checkedStates:r,setCheckedStates:l,isMuteDisabled:i})=>{const[a,o]=R(k=>[k.ids,k.total]),[d,u]=h.useState(!1),[m,p]=h.useState(!1),b=ye(t.date_added_to_graph),j=async(k,v)=>{u(!0);try{await de(k,{node_type:t==null?void 0:t.node_type,node_data:{is_muted:v}}),R.setState({ids:a.filter(_=>_!==k),total:o-1})}catch(_){console.warn(_)}},y=k=>{l(v=>({...v,[k]:!v[k]}))},C=(k,v)=>{var _;(_=window.getSelection())!=null&&_.toString()?k.preventDefault():n(v.name)},w=t.edgeList.slice(0,1),$=t.edgeList.length-w.length,[S,A]=re.useState(null),O=k=>{A(k.currentTarget),p(!0)},L=()=>{p(!1)},H=!!S&&m,B=r[t.ref_id]?"visible":"";return e.jsxs(he,{className:r[t.ref_id]?"checked":"",children:[e.jsx(f,{children:e.jsx(Zo,{className:`checkbox-section ${B}`,"data-testid":"topic-check-box",onClick:()=>y(t.ref_id),children:e.jsx(Jo,{checked:r[t.ref_id],children:e.jsx(en,{children:r[t.ref_id]&&e.jsx(st,{})})})})}),e.jsx(f,{onClick:k=>C(k,t),children:e.jsx(Qo,{children:t.name})}),e.jsx(f,{children:t.node_type}),e.jsx(f,{children:e.jsx(tn,{children:t.edgeCount})}),e.jsxs(f,{children:[e.jsx(Te,{anchorEl:S,anchorOrigin:{vertical:"top",horizontal:"center"},disableRestoreFocus:!0,id:"mouse-over-popover",onClose:L,onMouseEnter:()=>p(!0),onMouseLeave:L,open:H,sx:{pointerEvents:"auto","& .MuiPaper-root":{backgroundColor:"rgba(0, 0, 0, 0.9)",borderRadius:"4px",width:"160px",maxHeight:"200px",overflowY:"scroll"}},transformOrigin:{vertical:"bottom",horizontal:"center"},children:e.jsx(Me,{sx:{p:1.5,fontSize:"13px",fontWeight:400,lineHeight:"1.8",wordWrap:"break-word"},children:t.edgeList.join(", ")})}),w.join(", "),$>0&&e.jsx(Me,{"aria-haspopup":"true","aria-owns":H?"mouse-over-popover":void 0,component:"span",onMouseEnter:O,onMouseLeave:L,sx:{cursor:"pointer"},children:",..."})]}),e.jsx(f,{children:e.jsx("span",{children:b})}),e.jsx(f,{className:"cell-center",children:e.jsx(g,{direction:"row",justify:"space-between",children:e.jsx("div",{className:"approve-wrapper",children:d?e.jsx(Ko,{children:e.jsx(z,{color:x.white,size:16})}):e.jsxs(g,{direction:"row",children:[t.is_muted?e.jsx(q,{className:"centered",disabled:i,onClick:()=>j(t.ref_id,!1),children:e.jsx(Ot,{})}):e.jsx(q,{className:"centered",disabled:i,onClick:()=>j(t.ref_id,!0),children:e.jsx(Wt,{})}),e.jsx(q,{disabled:i,onClick:k=>s(k,t.ref_id),children:e.jsx(Ht,{"data-testid":"ThreeDotsIcons"})})]})})})})]},t.name)},Ko=c.span` margin-left: 12px; -`,Ko=c.span` +`,Qo=c.span` cursor: pointer; :hover { text-decoration: underline; @@ -821,7 +821,7 @@ import{r as h,L as X,M as Q,N as F,O as I,S as K,H as Z,j as e,U as J,V as ee,Y width: 100%; `,mn=c(g)` margin: 0 0 16px 36px; -`,bn=[{label:it,component:Fs},{label:Yt,component:lo},{label:at,component:Qs},{label:rt,component:un}],jn=t=>{const{children:s,value:n,index:r,...l}=t;return n===r?e.jsx(Tn,{"aria-labelledby":`simple-tab-${r}`,hidden:n!==r,id:`simple-tabpanel-${r}`,role:"tabpanel",...l,children:s}):null};function yn(t){return{id:`simple-tab-${t}`,"aria-controls":`simple-tabpanel-${t}`}}const wn=()=>{const[t,s]=h.useState(0),[n]=Xe(o=>[o.isAdmin]),[r]=It(o=>[o.queuedSourcesFeatureFlag]),l=Rt(),i=(o,d)=>{s(d)},a=bn.filter(({label:o})=>o===rt?n:o===at?n&&r:o===it?l:!0);return e.jsxs($n,{"data-testid":"sources-table",direction:"column",children:[e.jsx(Cn,{"aria-label":"sources tabs",onChange:i,value:t,children:a.map((o,d)=>e.jsx(vn,{color:x.white,disableRipple:!0,label:o.label,...yn(d)},o.label))}),a.map((o,d)=>e.jsx(jn,{index:d,value:t,children:e.jsx(o.component,{})},o.label))]})},Cn=c(qt)` +`,bn=[{label:it,component:Fs},{label:Yt,component:lo},{label:at,component:Ks},{label:rt,component:un}],jn=t=>{const{children:s,value:n,index:r,...l}=t;return n===r?e.jsx(Tn,{"aria-labelledby":`simple-tab-${r}`,hidden:n!==r,id:`simple-tabpanel-${r}`,role:"tabpanel",...l,children:s}):null};function yn(t){return{id:`simple-tab-${t}`,"aria-controls":`simple-tabpanel-${t}`}}const wn=()=>{const[t,s]=h.useState(0),[n]=Xe(o=>[o.isAdmin]),[r]=It(o=>[o.queuedSourcesFeatureFlag]),l=Rt(),i=(o,d)=>{s(d)},a=bn.filter(({label:o})=>o===rt?n:o===at?n&&r:o===it?l:!0);return e.jsxs($n,{"data-testid":"sources-table",direction:"column",children:[e.jsx(Cn,{"aria-label":"sources tabs",onChange:i,value:t,children:a.map((o,d)=>e.jsx(vn,{color:x.white,disableRipple:!0,label:o.label,...yn(d)},o.label))}),a.map((o,d)=>e.jsx(jn,{index:d,value:t,children:e.jsx(o.component,{})},o.label))]})},Cn=c(qt)` && { background: rgba(0, 0, 0, 0.2); border-radius: 9px 9px 0 0; diff --git a/build/assets/index-686eedfc.js b/build/assets/index-c2e413fd.js similarity index 72% rename from build/assets/index-686eedfc.js rename to build/assets/index-c2e413fd.js index 2ea7fcd99..0dde6e06c 100644 --- a/build/assets/index-686eedfc.js +++ b/build/assets/index-c2e413fd.js @@ -1,4 +1,4 @@ -import{ag as F,bZ as k,b_ as g,b$ as M,s as B,T as C,F as d,ao as V,r as x,b as E,j as n,aY as z,aZ as K,B as S,e as _,t as U,v as R,aW as A,a$ as G}from"./index-4bb27744.js";import{l as I}from"./index-7730ff6f.js";import{A as N}from"./index-22c3582f.js";import"./index-5111ebdb.js";import"./Stack-6038813c.js";import"./createSvgIcon-41051178.js";import"./TextareaAutosize-b716e8d1.js";const D="https://community.sphinx.chat",O=async e=>await F.post("/bounty",JSON.stringify(e)),W=async e=>await k(`${D}/person/${e}`,{headers:{"Content-Type":"application/json"},method:"GET"}),P=async e=>await k(`${D}/workspaces/user/${e}`,{headers:{"Content-Type":"application/json"},method:"GET"});async function q(){try{const e=Math.floor(Date.now()/1e3),t=g.Buffer.from(e.toString(16),"hex"),s=g.Buffer.from(t).toString("base64"),o=await M.signMessage(s),a=v(o.signature),l=g.Buffer.concat([t,a],a.length+t.length);return L(l)}catch(e){return console.log("error from signing more message: ",e),""}}function v(e){const t=e.replace(/_/g,"/").replace(/-/g,"+"),s=t.padEnd(t.length+(4-t.length%4)%4,"=");return g.Buffer.from(s,"base64")}function L(e){let t="";const s=e.byteLength;for(let a=0;a{const t=e.trim();return!!(t&&$.test(t))},H=({errMessage:e,handleClose:t})=>{const{setValue:s,watch:o}=V(),[a,l]=x.useState([]),{pubKey:p}=E();x.useEffect(()=>{async function r(){try{const c=await W(p);if(!c.id){l([{label:"SecondBrain",value:"SecondBrain"}]);return}const u=await P(c.id);if(u.length>0){const w=[];for(let b=0;b{const c=(r==null?void 0:r.label)||"SecondBrain",u=(r==null?void 0:r.value)||"ck9drb84nncjnaefo090";s("nodeType",c,{shouldValidate:!0}),s("workspaceUuid",u)},y=Z(i)&&!!m,h=r=>{r.key===" "&&r.preventDefault()};return n.jsxs(d,{children:[n.jsx(d,{align:"center",direction:"row",justify:"space-between",mb:18,children:n.jsx(J,{children:"Create Bounty"})}),n.jsxs(d,{mb:20,children:[n.jsx(T,{children:"Select Workspace"}),n.jsx(N,{autoFocus:!0,onSelect:f,options:a})]}),n.jsxs(d,{mb:20,children:[n.jsx(T,{children:"Set Budget"}),n.jsx(z,{id:"budget",name:"budget",onKeyDown:h,placeholder:"Enter budget",rules:{...K,pattern:{value:$,message:"Please enter a valid number"}},value:i})]}),n.jsxs(d,{direction:"row",children:[n.jsx(d,{grow:1,children:n.jsx(S,{color:"secondary",onClick:()=>t(),size:"large",variant:"contained",children:"Cancel"})}),n.jsx(d,{grow:1,ml:20,children:n.jsx(S,{color:"secondary",disabled:!y,size:"large",type:"submit",variant:"contained",children:"Confirm"})})]}),e&&n.jsx(Y,{children:e})]})},T=B(C)` +import{af as V,bY as k,bZ as g,b_ as M,s as B,T as C,F as d,an as $,r as x,b as E,j as n,aX as z,aY as K,B as S,e as _,t as U,v as R,aV as A,a_ as G}from"./index-4e60c9e2.js";import{l as I}from"./index-af5a3f81.js";import{A as N}from"./index-d96216bb.js";import"./index-569670a3.js";import"./Stack-5870980a.js";import"./createSvgIcon-c125a9c8.js";import"./TextareaAutosize-f6242cb8.js";const D="https://community.sphinx.chat",O=async e=>await V.post("/bounty",JSON.stringify(e)),P=async e=>await k(`${D}/person/${e}`,{headers:{"Content-Type":"application/json"},method:"GET"}),W=async e=>await k(`${D}/workspaces/user/${e}`,{headers:{"Content-Type":"application/json"},method:"GET"});async function q(){try{const e=Math.floor(Date.now()/1e3),t=g.Buffer.from(e.toString(16),"hex"),s=g.Buffer.from(t).toString("base64"),o=await M.signMessage(s),a=v(o.signature),l=g.Buffer.concat([t,a],a.length+t.length);return L(l)}catch(e){return console.log("error from signing more message: ",e),""}}function v(e){const t=e.replace(/_/g,"/").replace(/-/g,"+"),s=t.padEnd(t.length+(4-t.length%4)%4,"=");return g.Buffer.from(s,"base64")}function L(e){let t="";const s=e.byteLength;for(let a=0;a{const t=e.trim();return!!(t&&F.test(t))},H=({errMessage:e,handleClose:t})=>{const{setValue:s,watch:o}=$(),[a,l]=x.useState([]),{pubKey:p}=E();x.useEffect(()=>{async function r(){try{const c=await P(p);if(!c.id){l([{label:"SecondBrain",value:"SecondBrain"}]);return}const u=await W(c.id);if(u.length>0){const w=[];for(let b=0;b{const c=(r==null?void 0:r.label)||"SecondBrain",u=(r==null?void 0:r.value)||"ck9drb84nncjnaefo090";s("nodeType",c,{shouldValidate:!0}),s("workspaceUuid",u)},y=Y(i)&&!!m,h=r=>{r.key===" "&&r.preventDefault()};return n.jsxs(d,{children:[n.jsx(d,{align:"center",direction:"row",justify:"space-between",mb:18,children:n.jsx(J,{children:"Create Bounty"})}),n.jsxs(d,{mb:20,children:[n.jsx(T,{children:"Select Workspace"}),n.jsx(N,{autoFocus:!0,onSelect:f,options:a})]}),n.jsxs(d,{mb:20,children:[n.jsx(T,{children:"Set Budget"}),n.jsx(z,{id:"budget",name:"budget",onKeyDown:h,placeholder:"Enter budget",rules:{...K,pattern:{value:F,message:"Please enter a valid number"}},value:i})]}),n.jsxs(d,{direction:"row",children:[n.jsx(d,{grow:1,children:n.jsx(S,{color:"secondary",onClick:()=>t(),size:"large",variant:"contained",children:"Cancel"})}),n.jsx(d,{grow:1,ml:20,children:n.jsx(S,{color:"secondary",disabled:!y,size:"large",type:"submit",variant:"contained",children:"Confirm"})})]}),e&&n.jsx(X,{children:e})]})},T=B(C)` font-size: 14px; font-weight: 600; font-family: 'Barlow'; @@ -8,11 +8,11 @@ import{ag as F,bZ as k,b_ as g,b$ as M,s as B,T as C,F as d,ao as V,r as x,b as font-weight: 600; font-family: 'Barlow'; margin-bottom: 6px; -`,Y=B(d)` +`,X=B(d)` font-size: 13px; font-family: Barlow; color: #ff8f80; line-height: 0.2px; margin-top: 12px; padding-top: 20px; -`,Q=()=>{const[e,t]=x.useState(""),{close:s}=_("createBounty"),o=I(),{pubKey:a}=E(),l=U({mode:"onChange"}),{handleSubmit:p,setValue:i}=l,m=()=>{i("budget",""),i("nodeType",""),i("workspaceUuid",""),s()},f=async y=>{const{budget:h,workspaceUuid:r}=y;try{const c=await q(),u={type:"code_generation",amount:Number(h),workspace_uuid:r||"ck9drb84nncjnaefo090",ref_id:o==null?void 0:o.ref_id,node_data:(o==null?void 0:o.properties)||{},jwt_token:c,pub_key:a};await O(u),A("Bounty Created")}catch(c){t(c)}finally{i("budget",""),i("nodeType",""),i("workspaceUuid",""),m()}};return n.jsx(R,{...l,children:n.jsx("form",{id:"create-bounty-form",onSubmit:p(f),children:n.jsx(H,{errMessage:e,handleClose:m})})})},ae=()=>{const{close:e}=_("createBounty"),t=U({mode:"onChange"}),{setValue:s}=t,o=()=>{s("budget",""),s("nodeType",""),e()},a="small";return n.jsx(G,{id:"createBounty",kind:a,onClose:o,preventOutsideClose:!0,children:n.jsx(Q,{})})};export{ae as CreateBountyModal}; +`,Z=()=>{const[e,t]=x.useState(""),{close:s}=_("createBounty"),o=I(),{pubKey:a}=E(),l=U({mode:"onChange"}),{handleSubmit:p,setValue:i}=l,m=()=>{i("budget",""),i("nodeType",""),i("workspaceUuid",""),s()},f=async y=>{const{budget:h,workspaceUuid:r}=y;try{const c=await q(),u={type:"code_generation",amount:Number(h),workspace_uuid:r||"ck9drb84nncjnaefo090",ref_id:o==null?void 0:o.ref_id,node_data:(o==null?void 0:o.properties)||{},jwt_token:c,pub_key:a};await O(u),A("Bounty Created")}catch(c){t(c)}finally{i("budget",""),i("nodeType",""),i("workspaceUuid",""),m()}};return n.jsx(R,{...l,children:n.jsx("form",{id:"create-bounty-form",onSubmit:p(f),children:n.jsx(H,{errMessage:e,handleClose:m})})})},ae=()=>{const{close:e}=_("createBounty"),t=U({mode:"onChange"}),{setValue:s}=t,o=()=>{s("budget",""),s("nodeType",""),e()},a="small";return n.jsx(G,{id:"createBounty",kind:a,onClose:o,preventOutsideClose:!0,children:n.jsx(Z,{})})};export{ae as CreateBountyModal}; diff --git a/build/assets/index-dc12854c.js b/build/assets/index-c715ffeb.js similarity index 99% rename from build/assets/index-dc12854c.js rename to build/assets/index-c715ffeb.js index 128615111..2b9ac493c 100644 --- a/build/assets/index-dc12854c.js +++ b/build/assets/index-c715ffeb.js @@ -1,4 +1,4 @@ -import{r as P,a9 as hf,O as qr,bM as pf,J as er,bN as $d,j as L,a as fo,bO as e1,bP as t1}from"./index-4bb27744.js";import{A as Aa,H as vl,I as n1,U as r1,d as mf,j as i1,C as wo,J as o1,O as yl,x as xl,K as Rs,N as Da,X as s1,Y as a1,Z as l1,_ as u1,$ as c1,a0 as f1,a1 as d1,V as ct,b as $r,a2 as h1,h as p1,g as Sl,r as Is,a3 as gf,e as el,a4 as tl,a5 as Mi,a6 as m1,s as wl,a7 as g1,a8 as nl,a9 as oc,aa as v1,k as vf,ab as y1,l as Co,ac as Ai,ad as yf,ae as x1,af as S1,ag as w1,ah as C1,ai as _1,aj as sc,ak as E1,al as k1,M as T1,q as P1,am as Cl,an as ac,ao as Zr,ap as M1,i as Ia}from"./three.module-71ec604c.js";var xf={exports:{}},ei={};/** +import{r as P,a8 as hf,N as qr,bL as pf,H as er,bM as $d,j as L,a as fo,bN as e1,bO as t1}from"./index-4e60c9e2.js";import{A as Aa,H as vl,I as n1,U as r1,d as mf,j as i1,C as wo,J as o1,O as yl,x as xl,K as Rs,N as Da,X as s1,Y as a1,Z as l1,_ as u1,$ as c1,a0 as f1,a1 as d1,V as ct,b as $r,a2 as h1,h as p1,g as Sl,r as Is,a3 as gf,e as el,a4 as tl,a5 as Mi,a6 as m1,s as wl,a7 as g1,a8 as nl,a9 as oc,aa as v1,k as vf,ab as y1,l as Co,ac as Ai,ad as yf,ae as x1,af as S1,ag as w1,ah as C1,ai as _1,aj as sc,ak as E1,al as k1,M as T1,q as P1,am as Cl,an as ac,ao as Zr,ap as M1,i as Ia}from"./three.module-71ec604c.js";var xf={exports:{}},ei={};/** * @license React * react-reconciler-constants.production.min.js * diff --git a/build/assets/index-555c3317.js b/build/assets/index-cf343a35.js similarity index 82% rename from build/assets/index-555c3317.js rename to build/assets/index-cf343a35.js index 13a23fb6e..a566d0ed1 100644 --- a/build/assets/index-555c3317.js +++ b/build/assets/index-cf343a35.js @@ -1,4 +1,4 @@ -import{s as v,a as q,T as F,F as r,r as f,ao as $,j as e,aY as J,aZ as K,bd as X,B as E,be as U,q as Z,bf as Q,e as D,t as N,aX as O,a$ as ee,v as te,bw as ne,bB as re}from"./index-4bb27744.js";import{p as V}from"./index-5fe8c70d.js";import{C as Y}from"./ClipLoader-1ef5878d.js";import{l as G}from"./index-7730ff6f.js";import{A as W}from"./index-22c3582f.js";import{c as oe}from"./index-64f1c910.js";import"./three.module-71ec604c.js";import"./index-5111ebdb.js";import"./Stack-6038813c.js";import"./createSvgIcon-41051178.js";import"./TextareaAutosize-b716e8d1.js";const M=a=>a.charAt(0).toUpperCase()+a.slice(1).replace(/_/g," "),k=a=>a?[...a].sort((l,x)=>Number(x.required)-Number(l.required)):[],H=a=>a?a.filter(l=>l.key!=="node_key"):[],ae=({handleSelectType:a,skipToStep:l,nodeType:x,selectedValues:n})=>{const[h,w]=f.useState(!1),[m,C]=f.useState(),{watch:j,formState:{isValid:t}}=$();f.useEffect(()=>{(async()=>{w(!0);const o=await U(x),T=V(o),A=H(T);C(A),w(!1)})()},[x,j]);const s=c=>c.charAt(0).toUpperCase()+c.slice(1).replace(/_/g," "),p=(m?[...m].sort((c,o)=>c.required&&!o.required?-1:!c.required&&o.required?1:0):[]).filter(c=>!!(c.required&&!Object.values(n).includes(c.key))),S=()=>{a(""),l("sourceType")},b=!t||h||p.some(c=>{var o;return c.required&&!((o=j(c.key))!=null&&o.trim())});return e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(r,{align:"center",direction:"row",children:e.jsx(se,{children:"Required Properties"})})}),e.jsx(ie,{children:h?e.jsx(r,{style:{margin:"auto"},children:e.jsx(Y,{color:q.SECONDARY_BLUE})}):e.jsx(r,{className:"input__wrapper",children:p==null?void 0:p.map(({key:c,required:o})=>e.jsx(e.Fragment,{children:e.jsxs(ce,{children:[e.jsx(F,{children:s(c)}),e.jsx(J,{id:"item-name",maxLength:50,name:c,placeholder:o?"Required":"Optional",rules:{...o?{...K,pattern:{message:"No leading whitespace allowed",value:X}}:{}}})]})}))})}),e.jsxs(r,{direction:"row",children:[e.jsx(r,{grow:1,children:e.jsx(E,{color:"secondary",onClick:S,size:"large",variant:"contained",children:"Prev"})}),e.jsx(r,{grow:1,ml:20,children:e.jsx(E,{color:"secondary",disabled:b,onClick:()=>l("createConfirmation"),size:"large",variant:"contained",children:"Next"})})]})]})},se=v(F)` +import{s as v,a as B,T as F,F as r,r as f,an as $,j as e,aX as J,aY as K,bc as X,B as E,bd as U,q as Q,be as Z,e as D,t as N,aW as O,a_ as ee,v as te,bv as ne,bA as re}from"./index-4e60c9e2.js";import{p as V}from"./index-5fe8c70d.js";import{C as W}from"./ClipLoader-8590c2f1.js";import{l as Y}from"./index-af5a3f81.js";import{A as G}from"./index-d96216bb.js";import{c as oe}from"./index-64f1c910.js";import"./three.module-71ec604c.js";import"./index-569670a3.js";import"./Stack-5870980a.js";import"./createSvgIcon-c125a9c8.js";import"./TextareaAutosize-f6242cb8.js";const q=a=>a.charAt(0).toUpperCase()+a.slice(1).replace(/_/g," "),k=a=>a?[...a].sort((l,x)=>Number(x.required)-Number(l.required)):[],H=a=>a?a.filter(l=>l.key!=="node_key"):[],ae=({handleSelectType:a,skipToStep:l,nodeType:x,selectedValues:n})=>{const[h,w]=f.useState(!1),[m,C]=f.useState(),{watch:j,formState:{isValid:t}}=$();f.useEffect(()=>{(async()=>{w(!0);const o=await U(x),T=V(o),A=H(T);C(A),w(!1)})()},[x,j]);const s=c=>c.charAt(0).toUpperCase()+c.slice(1).replace(/_/g," "),p=(m?[...m].sort((c,o)=>c.required&&!o.required?-1:!c.required&&o.required?1:0):[]).filter(c=>!!(c.required&&!Object.values(n).includes(c.key))),S=()=>{a(""),l("sourceType")},b=!t||h||p.some(c=>{var o;return c.required&&!((o=j(c.key))!=null&&o.trim())});return e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(r,{align:"center",direction:"row",children:e.jsx(se,{children:"Required Properties"})})}),e.jsx(ie,{children:h?e.jsx(r,{style:{margin:"auto"},children:e.jsx(W,{color:B.SECONDARY_BLUE})}):e.jsx(r,{className:"input__wrapper",children:p==null?void 0:p.map(({key:c,required:o})=>e.jsx(e.Fragment,{children:e.jsxs(ce,{children:[e.jsx(F,{children:s(c)}),e.jsx(J,{id:"item-name",maxLength:50,name:c,placeholder:o?"Required":"Optional",rules:{...o?{...K,pattern:{message:"No leading whitespace allowed",value:X}}:{}}})]})}))})}),e.jsxs(r,{direction:"row",children:[e.jsx(r,{grow:1,children:e.jsx(E,{color:"secondary",onClick:S,size:"large",variant:"contained",children:"Prev"})}),e.jsx(r,{grow:1,ml:20,children:e.jsx(E,{color:"secondary",disabled:b,onClick:()=>l("createConfirmation"),size:"large",variant:"contained",children:"Next"})})]})]})},se=v(F)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; @@ -22,14 +22,14 @@ import{s as v,a as q,T as F,F as r,r as f,ao as $,j as e,aY as J,aZ as K,bd as X gap: 10px; #item-name { - color: ${q.GRAY7}; - -webkit-text-fill-color: ${q.GRAY7}; + color: ${B.GRAY7}; + -webkit-text-fill-color: ${B.GRAY7}; } `,le=({nodeType:a,onclose:l,selectedNodeType:x})=>e.jsxs(r,{children:[e.jsx(r,{mb:20,children:e.jsx(R,{children:"Confirm Type Change"})}),e.jsx(r,{mb:25,children:e.jsxs(R,{children:["From: ",x]})}),e.jsx(r,{mb:25,children:e.jsxs(R,{children:["To: ",a]})}),e.jsxs(r,{direction:"row",children:[e.jsx(r,{grow:1,children:e.jsx(E,{color:"secondary",onClick:l,size:"large",variant:"contained",children:"Cancel"})}),e.jsx(r,{grow:1,ml:20,children:e.jsx(E,{color:"secondary",size:"large",type:"submit",variant:"contained",children:"Confirm"})})]})]}),R=v(F)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; -`,pe=({handleSelectType:a,skipToStep:l,selectedNodeType:x,nodeType:n,selectedValues:h,setSelectedValues:w})=>{const[m,C]=f.useState(!1),[j,t]=f.useState(),[s,i]=f.useState(),{watch:p}=$();f.useEffect(()=>{const d=async(u,y)=>{C(!0);const g=await U(u),z=V(g),_=H(z);y(_),C(!1)};n&&d(n,t),x&&d(x,i)},[n,x,p]);const S=f.useMemo(()=>k(j),[j]),b=f.useMemo(()=>k(s),[s]),c=()=>{a(""),l("sourceType")};f.useEffect(()=>{if(j&&s){const d=s.reduce((u,y)=>{const g=j.find(z=>z.key===y.key);return u[y.key]=g?y.key:"none",u},{});w(d)}},[j,s,w]);const o=(d,u)=>{w(y=>({...y,[d]:u}))},T=()=>{const d=S.every(({key:u,required:y})=>!y||y&&h[u]&&h[u]!=="none");l(d?"createConfirmation":"requiredProperties")},A=f.useMemo(()=>b.map(({key:d})=>{const u=h[d]||"none",y=S.filter(g=>!Object.values(h).includes(g.key)||g.key===u).map(g=>({label:M(g.key),value:g.key}));return y.unshift({label:"None",value:"none"}),{key:d,autoCompleteOptions:y,selectedValue:u}}),[b,S,h]);return e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(r,{align:"center",direction:"row",children:e.jsx(de,{children:"Map Properties"})})}),e.jsx(ue,{children:m?e.jsx(r,{style:{margin:"auto"},children:e.jsx(Y,{color:q.lightGray})}):e.jsxs(xe,{children:[e.jsxs(fe,{children:[e.jsx(I,{children:M(x)}),b.map(({key:d})=>e.jsx(he,{children:e.jsx(F,{children:M(d)})},d))]}),e.jsxs(me,{children:[e.jsx(I,{children:M(n)}),A.map(({key:d,autoCompleteOptions:u,selectedValue:y})=>e.jsx(r,{children:e.jsx(W,{isLoading:m,onSelect:g=>o(d,g?g.value:"none"),options:u,selectedValue:u.find(g=>g.value===y)})},d))]})]})}),e.jsxs(r,{direction:"row",children:[e.jsx(r,{grow:1,children:e.jsx(E,{color:"secondary",onClick:c,size:"large",variant:"contained",children:"Prev"})}),e.jsx(r,{grow:1,ml:20,children:e.jsx(E,{color:"secondary",disabled:m,onClick:T,size:"large",variant:"contained",children:"Next"})})]})]})},de=v(F)` +`,pe=({handleSelectType:a,skipToStep:l,selectedNodeType:x,nodeType:n,selectedValues:h,setSelectedValues:w})=>{const[m,C]=f.useState(!1),[j,t]=f.useState(),[s,i]=f.useState(),{watch:p}=$();f.useEffect(()=>{const d=async(u,y)=>{C(!0);const g=await U(u),z=V(g),_=H(z);y(_),C(!1)};n&&d(n,t),x&&d(x,i)},[n,x,p]);const S=f.useMemo(()=>k(j),[j]),b=f.useMemo(()=>k(s),[s]),c=()=>{a(""),l("sourceType")};f.useEffect(()=>{if(j&&s){const d=s.reduce((u,y)=>{const g=j.find(z=>z.key===y.key);return u[y.key]=g?y.key:"none",u},{});w(d)}},[j,s,w]);const o=(d,u)=>{w(y=>({...y,[d]:u}))},T=()=>{const d=S.every(({key:u,required:y})=>!y||y&&h[u]&&h[u]!=="none");l(d?"createConfirmation":"requiredProperties")},A=f.useMemo(()=>b.map(({key:d})=>{const u=h[d]||"none",y=S.filter(g=>!Object.values(h).includes(g.key)||g.key===u).map(g=>({label:q(g.key),value:g.key}));return y.unshift({label:"None",value:"none"}),{key:d,autoCompleteOptions:y,selectedValue:u}}),[b,S,h]);return e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(r,{align:"center",direction:"row",children:e.jsx(de,{children:"Map Properties"})})}),e.jsx(ue,{children:m?e.jsx(r,{style:{margin:"auto"},children:e.jsx(W,{color:B.lightGray})}):e.jsxs(xe,{children:[e.jsxs(fe,{children:[e.jsx(I,{children:q(x)}),b.map(({key:d})=>e.jsx(he,{children:e.jsx(F,{children:q(d)})},d))]}),e.jsxs(me,{children:[e.jsx(I,{children:q(n)}),A.map(({key:d,autoCompleteOptions:u,selectedValue:y})=>e.jsx(r,{children:e.jsx(G,{isLoading:m,onSelect:g=>o(d,g?g.value:"none"),options:u,selectedValue:u.find(g=>g.value===y)})},d))]})]})}),e.jsxs(r,{direction:"row",children:[e.jsx(r,{grow:1,children:e.jsx(E,{color:"secondary",onClick:c,size:"large",variant:"contained",children:"Prev"})}),e.jsx(r,{grow:1,ml:20,children:e.jsx(E,{color:"secondary",disabled:m,onClick:T,size:"large",variant:"contained",children:"Next"})})]})]})},de=v(F)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; @@ -70,8 +70,8 @@ import{s as v,a as q,T as F,F as r,r as f,ao as $,j as e,aY as J,aZ as K,bd as X font-family: 'Barlow'; color: white; margin-bottom: 15px; -`,ye={label:"Not Selected",value:"Not Selected"},ge=[{label:"Corporation",value:"Corporation"},{label:"Event",value:"Event"},{label:"Image",value:"Image"},{label:"Organization",value:"Organization"},{label:"Person",value:"Person"},{label:"Place",value:"Place"},{label:"Project",value:"Project"},{label:"Software",value:"Software"},{label:"Topic",value:"Topic"}],je=({skipToStep:a,allowNextStep:l,onSelectType:x,selectedType:n})=>{const[h]=Z(i=>[i.customSchemaFeatureFlag]),[w,m]=f.useState(null),[C,j]=f.useState(!1),t=G();f.useEffect(()=>{(async()=>{var p;if(h){j(!0);try{const S=await Q(),b=["about","schema",(p=t==null?void 0:t.node_type)==null?void 0:p.toLowerCase()],c=S.schemas.filter(o=>o.ref_id&&!b.includes(o.type.toLowerCase())&&!o.is_deleted).map(o=>({label:oe(o.type),value:o.type,action:()=>a("mapProperties")}));m(c)}catch(S){console.warn(S)}finally{j(!1)}}else m([...ge,ye])})()},[t==null?void 0:t.node_type,n,h,a]);const s=i=>{x((i==null?void 0:i.label)||"")};return e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:20,children:e.jsx(r,{align:"center",direction:"row",children:e.jsx(be,{children:"Select Type"})})}),e.jsx(r,{direction:"row",mb:20,children:e.jsx(W,{autoFocus:!0,isLoading:C,onSelect:s,options:w})}),e.jsx(r,{children:e.jsx(E,{color:"secondary",disabled:!l,onClick:()=>a("mapProperties"),size:"large",type:"button",variant:"contained",children:"Next"})})]})},be=v(F)` +`,ye={label:"Not Selected",value:"Not Selected"},ge=[{label:"Corporation",value:"Corporation"},{label:"Event",value:"Event"},{label:"Image",value:"Image"},{label:"Organization",value:"Organization"},{label:"Person",value:"Person"},{label:"Place",value:"Place"},{label:"Project",value:"Project"},{label:"Software",value:"Software"},{label:"Topic",value:"Topic"}],je=({skipToStep:a,allowNextStep:l,onSelectType:x,selectedType:n})=>{const[h]=Q(i=>[i.customSchemaFeatureFlag]),[w,m]=f.useState(null),[C,j]=f.useState(!1),t=Y();f.useEffect(()=>{(async()=>{var p;if(h){j(!0);try{const S=await Z(),b=["about","schema",(p=t==null?void 0:t.node_type)==null?void 0:p.toLowerCase()],c=S.schemas.filter(o=>o.ref_id&&!b.includes(o.type.toLowerCase())&&!o.is_deleted).map(o=>({label:oe(o.type),value:o.type,action:()=>a("mapProperties")}));m(c)}catch(S){console.warn(S)}finally{j(!1)}}else m([...ge,ye])})()},[t==null?void 0:t.node_type,n,h,a]);const s=i=>{x((i==null?void 0:i.label)||"")};return e.jsxs(r,{children:[e.jsx(r,{align:"center",direction:"row",justify:"space-between",mb:20,children:e.jsx(r,{align:"center",direction:"row",children:e.jsx(be,{children:"Select Type"})})}),e.jsx(r,{direction:"row",mb:20,children:e.jsx(G,{autoFocus:!0,isLoading:C,onSelect:s,options:w})}),e.jsx(r,{children:e.jsx(E,{color:"secondary",disabled:!l,onClick:()=>a("mapProperties"),size:"large",type:"button",variant:"contained",children:"Next"})})]})},be=v(F)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; -`,we=async(a,l,x,n)=>{const h={},w=[];Object.entries(x).forEach(([t,s])=>{s!=="none"&&(h[s]=t),t!==s&&w.push(t)});const m={};Object.keys(n||{}).forEach(t=>{const s=n==null?void 0:n[t];Object.entries(h).forEach(([i,p])=>{p===t&&(m[h[i]]=s)})}),Object.keys(a).forEach(t=>{t!=="nodeType"&&(m[t]=a[t])});const C=n?n.node_type.charAt(0).toUpperCase()+n.node_type.slice(1):void 0,j={node_type:l,node_data:m,properties_to_be_deleted:w,type_to_be_deleted:C?[C]:[]};try{let t=n==null?void 0:n.ref_id;if((n==null?void 0:n.type)==="topic"){const{data:i}=await ne({search:n==null?void 0:n.name}),p=i.find(S=>S.name===n.name);t=p==null?void 0:p.ref_id}const s=t||(n==null?void 0:n.ref_id);s&&await re(s,j)}catch(t){console.error(t);let s=O;if(t.status===400)try{const i=await t.json();s=i.message||i.errorCode||(i==null?void 0:i.status)||O}catch{s=O}else t instanceof Error&&(s=t.message);throw new Error(s)}},Be=()=>{const[a,l]=f.useState("sourceType"),{close:x,visible:n}=D("changeNodeType"),{open:h}=D("editNodeName"),{open:w}=D("addType"),m=N({mode:"onChange"}),{watch:C,setValue:j,reset:t}=m,[s,i]=f.useState(""),[p,S]=f.useState({});f.useEffect(()=>()=>{l("sourceType"),t()},[n,t]);const b=G(),c=b!=null&&b.node_type?b.node_type.charAt(0).toUpperCase()+b.node_type.slice(1):"",o=C("nodeType");C("title");const T=()=>{x()},A=_=>{l(_)},d=m.handleSubmit(async _=>{try{await we(_,o,p,b),T()}catch(P){let L=O;if(T(),(P==null?void 0:P.status)===400){const B=await P.json();L=B.errorCode||(B==null?void 0:B.status)||O}else P instanceof Error&&(L=P.message);i(String(L))}}),u=_=>{_==="Create custom type"?w():j("nodeType",_)},y={sourceType:e.jsx(je,{allowNextStep:!!o,onSelectType:u,selectedType:o,skipToStep:A}),requiredProperties:e.jsx(ae,{handleSelectType:u,nodeType:o,selectedValues:p,skipToStep:A}),createConfirmation:e.jsx(le,{nodeType:o,onclose:T,selectedNodeType:c}),mapProperties:e.jsx(pe,{handleSelectType:u,nodeType:o,selectedNodeType:c,selectedValues:p,setSelectedValues:S,skipToStep:A})},g=a==="mapProperties"?"regular":"small",z=()=>{x(),h()};return e.jsx(ee,{id:"changeNodeType",kind:g,onClose:z,preventOutsideClose:!0,children:e.jsx(te,{...m,children:e.jsx("form",{id:"add-node-form",onSubmit:d,children:y[a]})})})};export{Be as ChangeNodeTypeModal}; +`,we=async(a,l,x,n)=>{const h={},w=[];Object.entries(x).forEach(([t,s])=>{s!=="none"&&(h[s]=t),t!==s&&w.push(t)});const m={};Object.keys(n||{}).forEach(t=>{const s=n==null?void 0:n[t];Object.entries(h).forEach(([i,p])=>{p===t&&(m[h[i]]=s)})}),Object.keys(a).forEach(t=>{t!=="nodeType"&&(m[t]=a[t])});const C=n?n.node_type.charAt(0).toUpperCase()+n.node_type.slice(1):void 0,j={node_type:l,node_data:m,properties_to_be_deleted:w,type_to_be_deleted:C?[C]:[]};try{let t=n==null?void 0:n.ref_id;if((n==null?void 0:n.type)==="topic"){const{data:i}=await ne({search:n==null?void 0:n.name}),p=i.find(S=>S.name===n.name);t=p==null?void 0:p.ref_id}const s=t||(n==null?void 0:n.ref_id);s&&await re(s,j)}catch(t){console.error(t);let s=O;if(t.status===400)try{const i=await t.json();s=i.message||i.errorCode||(i==null?void 0:i.status)||O}catch{s=O}else t instanceof Error&&(s=t.message);throw new Error(s)}},Me=()=>{const[a,l]=f.useState("sourceType"),{close:x,visible:n}=D("changeNodeType"),{open:h}=D("editNodeName"),{open:w}=D("addType"),m=N({mode:"onChange"}),{watch:C,setValue:j,reset:t}=m,[s,i]=f.useState(""),[p,S]=f.useState({});f.useEffect(()=>()=>{l("sourceType"),t()},[n,t]);const b=Y(),c=b!=null&&b.node_type?b.node_type.charAt(0).toUpperCase()+b.node_type.slice(1):"",o=C("nodeType");C("title");const T=()=>{x()},A=_=>{l(_)},d=m.handleSubmit(async _=>{try{await we(_,o,p,b),T()}catch(P){let L=O;if(T(),(P==null?void 0:P.status)===400){const M=await P.json();L=M.errorCode||(M==null?void 0:M.status)||O}else P instanceof Error&&(L=P.message);i(String(L))}}),u=_=>{_==="Create custom type"?w():j("nodeType",_)},y={sourceType:e.jsx(je,{allowNextStep:!!o,onSelectType:u,selectedType:o,skipToStep:A}),requiredProperties:e.jsx(ae,{handleSelectType:u,nodeType:o,selectedValues:p,skipToStep:A}),createConfirmation:e.jsx(le,{nodeType:o,onclose:T,selectedNodeType:c}),mapProperties:e.jsx(pe,{handleSelectType:u,nodeType:o,selectedNodeType:c,selectedValues:p,setSelectedValues:S,skipToStep:A})},g=a==="mapProperties"?"regular":"small",z=()=>{x(),h()};return e.jsx(ee,{id:"changeNodeType",kind:g,onClose:z,preventOutsideClose:!0,children:e.jsx(te,{...m,children:e.jsx("form",{id:"add-node-form",onSubmit:d,children:y[a]})})})};export{Me as ChangeNodeTypeModal}; diff --git a/build/assets/index-ea85a09b.js b/build/assets/index-cfa9dcd8.js similarity index 89% rename from build/assets/index-ea85a09b.js rename to build/assets/index-cfa9dcd8.js index 6c9ed50a5..2f98b53b0 100644 --- a/build/assets/index-ea85a09b.js +++ b/build/assets/index-cfa9dcd8.js @@ -1,4 +1,4 @@ -import{r,j as e,br as k,i as A,F as h,C as F,bg as O,bs as _,s as l,T as z,e as E,t as N,v as D,a as C,B as M,bt as Y,a$ as P}from"./index-4bb27744.js";import{ar as X,as as G,at as H,l as R}from"./index-7730ff6f.js";import{A as I,T as $}from"./index-22c3582f.js";import{S as V,A as W}from"./constants-bc1d79ca.js";import{C as T}from"./ClipLoader-1ef5878d.js";import"./index-5111ebdb.js";import"./Stack-6038813c.js";import"./createSvgIcon-41051178.js";import"./TextareaAutosize-b716e8d1.js";const q=({selectedType:t,setSelectedType:c})=>{const[p,d]=r.useState([]);r.useEffect(()=>{(async()=>{try{const{data:x}=await k();d(x.edge_types)}catch(x){console.warn(x)}})()},[d]);const n=o=>({label:o,value:o}),f=o=>{c((o==null?void 0:o.value)||"")};return e.jsx(I,{onSelect:f,options:p.map(n),selectedValue:t?n(t):null})},J=({onSelect:t,selectedValue:c,topicId:p})=>{const[d,n]=r.useState([]),[f,o]=r.useState(!1),x=r.useMemo(()=>{const s=async u=>{const i={is_muted:"False",sort_by:W,search:u,skip:"0",limit:"1000"};o(!0);try{const w=(await _(i.search)).data.filter(b=>(b==null?void 0:b.ref_id)!==p);n(w)}catch{n([])}finally{o(!1)}};return A.debounce(s,300)},[p]),m=s=>{const u=s.trim();if(!u){n([]);return}u.length>2&&x(s)},j=s=>{const u=s?d.find(i=>i.ref_id===s.value):null;t(u||null)},a=s=>({label:s.search_value,value:s.ref_id,type:s.node_type}),v=s=>s.map(a);return c?e.jsxs(h,{align:"center",basis:"100%",direction:"row",grow:1,shrink:1,children:[e.jsx("span",{children:c.search_value}),e.jsx(V,{onClick:()=>t(null),size:"medium",children:e.jsx(F,{})})]}):e.jsx(I,{handleInputChange:m,isLoading:f,onSelect:j,options:v(d)||O,selectedValue:c?a(c):null})},K=({from:t,onSelect:c,selectedType:p,setSelectedType:d,selectedToNode:n,setIsSwapped:f,isSwapped:o})=>{const x=()=>{f()},m=t&&("search_value"in t?t.search_value:t.name);return e.jsxs(h,{mb:20,children:[e.jsx(h,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(h,{align:"center",direction:"row",children:e.jsx(U,{children:"Add Edge"})})}),e.jsxs(Z,{swap:o,children:[e.jsx(h,{children:e.jsx(ee,{disabled:!0,label:o?"To":"From",swap:o,value:m})}),e.jsxs(h,{my:16,children:[e.jsx(oe,{children:"Type"}),e.jsx(q,{selectedType:p,setSelectedType:d})]}),e.jsx(h,{children:e.jsxs(te,{children:[e.jsx(se,{children:o?"From":"To"}),e.jsx(J,{onSelect:c,selectedValue:n,topicId:t==null?void 0:t.ref_id})]})}),e.jsxs(Q,{children:[e.jsx(ne,{children:e.jsx(X,{})}),e.jsx(ae,{onClick:x,children:e.jsx(G,{})}),e.jsx(ie,{children:e.jsx(H,{})})]})]})]})},Q=l.div` +import{r,j as e,bq as k,i as A,F as h,C as F,bf as O,br as _,s as l,T as z,e as E,t as N,v as D,a as C,B as M,bs as Y,a_ as P}from"./index-4e60c9e2.js";import{ar as X,as as G,at as H,l as R}from"./index-af5a3f81.js";import{A as I,T as q}from"./index-d96216bb.js";import{S as V,A as W}from"./constants-b9d9206a.js";import{C as T}from"./ClipLoader-8590c2f1.js";import"./index-569670a3.js";import"./Stack-5870980a.js";import"./createSvgIcon-c125a9c8.js";import"./TextareaAutosize-f6242cb8.js";const $=({selectedType:t,setSelectedType:c})=>{const[p,d]=r.useState([]);r.useEffect(()=>{(async()=>{try{const{data:x}=await k();d(x.edge_types)}catch(x){console.warn(x)}})()},[d]);const n=o=>({label:o,value:o}),f=o=>{c((o==null?void 0:o.value)||"")};return e.jsx(I,{onSelect:f,options:p.map(n),selectedValue:t?n(t):null})},J=({onSelect:t,selectedValue:c,topicId:p})=>{const[d,n]=r.useState([]),[f,o]=r.useState(!1),x=r.useMemo(()=>{const s=async u=>{const i={is_muted:"False",sort_by:W,search:u,skip:"0",limit:"1000"};o(!0);try{const w=(await _(i.search)).data.filter(b=>(b==null?void 0:b.ref_id)!==p);n(w)}catch{n([])}finally{o(!1)}};return A.debounce(s,300)},[p]),m=s=>{const u=s.trim();if(!u){n([]);return}u.length>2&&x(s)},j=s=>{const u=s?d.find(i=>i.ref_id===s.value):null;t(u||null)},a=s=>({label:s.search_value,value:s.ref_id,type:s.node_type}),v=s=>s.map(a);return c?e.jsxs(h,{align:"center",basis:"100%",direction:"row",grow:1,shrink:1,children:[e.jsx("span",{children:c.search_value}),e.jsx(V,{onClick:()=>t(null),size:"medium",children:e.jsx(F,{})})]}):e.jsx(I,{handleInputChange:m,isLoading:f,onSelect:j,options:v(d)||O,selectedValue:c?a(c):null})},K=({from:t,onSelect:c,selectedType:p,setSelectedType:d,selectedToNode:n,setIsSwapped:f,isSwapped:o})=>{const x=()=>{f()},m=t&&("search_value"in t?t.search_value:t.name);return e.jsxs(h,{mb:20,children:[e.jsx(h,{align:"center",direction:"row",justify:"space-between",mb:18,children:e.jsx(h,{align:"center",direction:"row",children:e.jsx(U,{children:"Add Edge"})})}),e.jsxs(Z,{swap:o,children:[e.jsx(h,{children:e.jsx(ee,{disabled:!0,label:o?"To":"From",swap:o,value:m})}),e.jsxs(h,{my:16,children:[e.jsx(oe,{children:"Type"}),e.jsx($,{selectedType:p,setSelectedType:d})]}),e.jsx(h,{children:e.jsxs(te,{children:[e.jsx(se,{children:o?"From":"To"}),e.jsx(J,{onSelect:c,selectedValue:n,topicId:t==null?void 0:t.ref_id})]})}),e.jsxs(Q,{children:[e.jsx(ne,{children:e.jsx(X,{})}),e.jsx(ae,{onClick:x,children:e.jsx(G,{})}),e.jsx(ie,{children:e.jsx(H,{})})]})]})]})},Q=l.div` position: absolute; top: 26px; bottom: 26px; @@ -19,7 +19,7 @@ import{r,j as e,br as k,i as A,F as h,C as F,bg as O,bs as _,s as l,T as z,e as flex-direction: ${t=>t.swap?"column-reverse":"column"}; margin-bottom: 10px; padding-left: 38px; -`,ee=l($)` +`,ee=l(q)` position: relative; width: 100%; padding: 16px; diff --git a/build/assets/index-d07244c7.js b/build/assets/index-d07244c7.js new file mode 100644 index 000000000..131b32e0c --- /dev/null +++ b/build/assets/index-d07244c7.js @@ -0,0 +1,246 @@ +import{c as te,j as e,s as p,a as k,F as v,T as re,r as s,d as se,u as U,A as ne,x as oe,o as ie,y as ae,z as ce,D as Z}from"./index-4e60c9e2.js";import{Universe as le}from"./index-88446b65.js";import{b as M,M as de,V as pe,c as ue,d as fe,e as ge,f as X,a as xe}from"./index-af5a3f81.js";import{S as he,R as me,s as V,M as ye}from"./index-a46872c4.js";import"./index-c715ffeb.js";import"./three.module-71ec604c.js";import"./index-37b3c15b.js";import"./TextareaAutosize-f6242cb8.js";import"./index-569670a3.js";import"./index-7fe50db2.js";import"./ClipLoader-8590c2f1.js";import"./Skeleton-7af13a79.js";import"./Stack-5870980a.js";import"./isPlainObject-1f2f9f4b.js";import"./Typography-2a31701b.js";import"./createSvgIcon-c125a9c8.js";import"./index-5c5c5836.js";const we={selectedEpisodeId:"",selectedEpisodeLink:"",selectedEpisode:null,clips:[]},D=te(t=>({...we,setSelectedEpisodeId:i=>t({selectedEpisodeId:i}),setSelectedEpisodeLink:i=>t({selectedEpisodeLink:i}),setSelectedEpisode:i=>t({selectedEpisode:i}),setClips:i=>t({clips:i})})),Ce=t=>e.jsxs("svg",{width:"1em",height:"1em",viewBox:"0 0 30 28",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",children:[e.jsx("path",{d:"M7.2998 2.55199C7.2998 1.51094 8.11675 0.666992 9.1245 0.666992H12.1299C13.1376 0.666992 13.9546 1.51094 13.9546 2.55199C13.9546 3.59305 13.1376 4.43699 12.1299 4.43699H9.1245C8.11675 4.43699 7.2998 3.59305 7.2998 2.55199Z",fill:"currentColor"}),e.jsx("path",{d:"M7.2998 25.449C7.2998 26.49 8.11675 27.334 9.1245 27.334H12.1299C13.1376 27.334 13.9546 26.49 13.9546 25.449C13.9546 24.4079 13.1376 23.564 12.1299 23.564H9.1245C8.11675 23.564 7.2998 24.4079 7.2998 25.449Z",fill:"currentColor"}),e.jsx("path",{d:"M2.79102 8.29613C2.79102 7.25508 3.60796 6.41113 4.61571 6.41113H12.1292C13.1369 6.41113 13.9539 7.25508 13.9539 8.29613C13.9539 9.33719 13.1369 10.1811 12.1292 10.1811H4.61571C3.60796 10.1811 2.79102 9.33719 2.79102 8.29613Z",fill:"currentColor"}),e.jsx("path",{d:"M2.79102 19.7039C2.79102 20.7449 3.60796 21.5889 4.61571 21.5889H12.1292C13.1369 21.5889 13.9539 20.7449 13.9539 19.7039C13.9539 18.6628 13.1369 17.8189 12.1292 17.8189H4.61571C3.60796 17.8189 2.79102 18.6628 2.79102 19.7039Z",fill:"currentColor"}),e.jsx("path",{d:"M0 14.094C0 13.0529 0.816945 12.209 1.8247 12.209H12.1289C13.1366 12.209 13.9536 13.0529 13.9536 14.094C13.9536 15.135 13.1366 15.979 12.1289 15.979H1.8247C0.816946 15.979 0 15.135 0 14.094Z",fill:"currentColor"}),e.jsx("path",{d:"M22.7002 25.448C22.7002 26.4891 21.8833 27.333 20.8755 27.333H17.8701C16.8624 27.333 16.0454 26.4891 16.0454 25.448C16.0454 24.407 16.8624 23.563 17.8701 23.563H20.8755C21.8832 23.563 22.7002 24.407 22.7002 25.448Z",fill:"currentColor"}),e.jsx("path",{d:"M22.7002 2.55199C22.7002 1.51094 21.8833 0.666992 20.8755 0.666992H17.8701C16.8624 0.666992 16.0454 1.51094 16.0454 2.55199C16.0454 3.59305 16.8624 4.43699 17.8701 4.43699H20.8755C21.8832 4.43699 22.7002 3.59305 22.7002 2.55199Z",fill:"currentColor"}),e.jsx("path",{d:"M27.209 19.7029C27.209 20.7439 26.392 21.5879 25.3843 21.5879H17.8708C16.8631 21.5879 16.0461 20.7439 16.0461 19.7029C16.0461 18.6618 16.8631 17.8179 17.8708 17.8179H25.3843C26.392 17.8179 27.209 18.6618 27.209 19.7029Z",fill:"currentColor"}),e.jsx("path",{d:"M27.209 8.29613C27.209 7.25508 26.392 6.41113 25.3843 6.41113H17.8708C16.8631 6.41113 16.0461 7.25508 16.0461 8.29613C16.0461 9.33719 16.8631 10.1811 17.8708 10.1811H25.3843C26.392 10.1811 27.209 9.33719 27.209 8.29613Z",fill:"currentColor"}),e.jsx("path",{d:"M30 14.093C30 13.052 29.1831 12.208 28.1753 12.208H17.8711C16.8634 12.208 16.0464 13.052 16.0464 14.093C16.0464 15.1341 16.8634 15.978 17.8711 15.978H28.1753C29.1831 15.978 30 15.1341 30 14.093Z",fill:"currentColor"})]}),je=()=>e.jsxs(be,{children:[e.jsx(ve,{children:e.jsx(Se,{children:e.jsx(Ce,{})})}),e.jsx(ke,{children:"Graph Mindset"})]}),be=p(v).attrs({align:"center",direction:"row",grow:1,justify:"flex-start"})` + height: 64px; + box-sizing: border-box; + padding: 20px 23px; + gap: 0px; + z-index: 50; + position: relative; +`,ve=p(v)` + align-items: center; + justify-content: center; + cursor: pointer; +`,Se=p.div` + display: flex; + align-items: center; + justify-content: center; + + svg { + width: 30px; + height: 27px; + color: ${k.white}; + } +`,ke=p(re)` + width: 127px; + height: 24px; + color: ${k.white}; + font-family: Barlow; + font-size: 22px; + font-style: normal; + font-weight: 700; + line-height: 24px; + letter-spacing: 0.22px; + margin-left: 16px; + white-space: nowrap; +`,Y=s.memo(()=>{const t=M(n=>n.isPlaying),i=M(n=>n.setIsPlaying),r=M(n=>n.setVolume),c=M(n=>n.setPlaybackSpeed),g=M(n=>n.playbackSpeed),a=M(n=>n.playerRef),[w,j]=s.useState(!1),u=[.5,1,1.5,2],h=()=>{if(a){const n=a.getCurrentTime()-15;a.seekTo(n,"seconds")}},d=()=>{if(a){const n=a.getCurrentTime()+15;a.seekTo(n,"seconds")}},I=()=>{i(!t)},l=()=>{j(!w),r(w?1:0)},f=()=>{const S=(u.indexOf(g)+1)%u.length,E=u[S];if(c(E),a){const T=a.getInternalPlayer();T&&typeof T.playbackRate<"u"&&(T.playbackRate=E)}};return e.jsxs(Te,{children:[e.jsx(Me,{onClick:l,children:w?e.jsx(de,{}):e.jsx(pe,{})}),e.jsx(Ee,{onClick:h,children:e.jsx("img",{alt:"",src:"RewindIcon.svg"})}),e.jsx(Ie,{"data-testid":"play-pause-button",onClick:I,size:"small",children:t?e.jsx(ue,{"data-testid":"pause-icon"}):e.jsx(fe,{"data-testid":"play-icon"})}),e.jsx(Pe,{onClick:d,children:e.jsx("img",{alt:"",src:"ForwardIcon.svg"})}),e.jsxs(Re,{onClick:f,children:[g,"x"]})]})});Y.displayName="Controls";const Te=p(v).attrs({direction:"row",align:"center",justify:"flex-start"})` + width: 200px; + height: 54px; + background: ${k.BG1}; + border-radius: 40px; + margin-right: 30px; + color: ${k.white}; + font-size: 20px; + padding: 12px; + justify-content: space-between; + box-sizing: border-box; +`,Ie=p(ge)` + && { + font-size: 36px; + padding: 2px; + overflow: hidden; + } +`,Ee=p.div` + display: flex; + align-items: center; + justify-content: center; + margin: 1px 0 0 1px; + cursor: pointer; + img { + width: 20px; + height: auto; + } +`,Pe=p.div` + display: flex; + align-items: center; + justify-content: center; + cursor: pointer; + img { + width: 24px; + height: auto; + } +`,Me=p.div` + display: flex; + align-items: center; + justify-content: center; + width: 40px; + height: 40px; + cursor: pointer; + border-radius: 50%; + transition: background-color 0.3s ease; + color: ${k.GRAY6}; + + svg { + margin-top: 3px; + width: 24px; + height: 24px; + } + + &:hover { + background-color: ${k.DROPDOWN_BG}; + } +`,Re=p.button` + margin-top: 4px; + background: ${k.BG1}; + color: ${k.GRAY6}; + border: none; + width: 8px; + border-radius: 20px; + padding: 8px 20px 8px 8px; + font-size: 14px; + cursor: pointer; + transition: background-color 0.3s ease; +`,J=s.memo(({type:t,left:i,img:r})=>{var u,h;const c=se(d=>d.normalizedSchemasByType),g=(u=c[t])==null?void 0:u.primary_color,a=(h=c[t])==null?void 0:h.icon,w=a?`svg-icons/${a}.svg`:"",j={iconStart:r||w,color:g??k.THING};return e.jsx($e,{style:{left:`${i}%`},children:e.jsx(K,{...j,label:t})})});J.displayName="Marker";const K=s.memo(({iconStart:t,color:i,label:r})=>e.jsx(_e,{color:i,children:t&&e.jsx("img",{alt:r,className:"badge__img",src:t})}));K.displayName="Badge";const _e=p(v).attrs({direction:"row"})` + cursor: pointer; + background: ${({color:t})=>t}; + border-radius: 3px; + overflow: hidden; + justify-content: center; + align-items: center; + + .badge__img { + width: 10px; + height: 10px; + object-fit: contain; + } +`,$e=p.div` + position: absolute; + top: -6px; + width: 12px; + height: 12px; + border-radius: 4px; + background-color: ${k.white}; + transform: translateX(-50%); + transform: translateX(-50%) translateY(-50%); + top: 50%; + display: flex; + align-items: center; + justify-content: center; +`,Q=s.memo(({markers:t,duration:i})=>e.jsx(e.Fragment,{children:t.map((r,c)=>{var j;const g=Math.floor(((r==null?void 0:r.start)||0)/i*200),a=(r==null?void 0:r.node_type)||"",w=((j=r==null?void 0:r.properties)==null?void 0:j.image_url)||"";return e.jsx(J,{img:w,left:g,type:a},`${r.ref_id}_${c}`)})}));Q.displayName="Markers";const He=({duration:t,markers:i,handleProgressChange:r,playingTIme:c})=>{const g=10/t*100;return e.jsxs(We,{children:[e.jsx(Be,{max:t,onChange:r,value:c,width:g}),e.jsx(Q,{duration:t,markers:i})]})},We=p(v)` + position: relative; + flex: 1 1 100%; +`,Be=p(he)` + && { + z-index: 20; + color: ${k.white}; + height: 3px; + width: calc(100% - 12px); + box-sizing: border-box; + .MuiSlider-track { + border: none; + } + .MuiSlider-thumb { + width: ${({width:t})=>`${t}%`}; + height: 54px; + border-radius: 8px; + background-color: ${k.primaryBlue}; + opacity: 0.2; + &:before { + box-shadow: '0 4px 8px rgba(0,0,0,0.4)'; + } + &:hover, + &.Mui-focusVisible, + &.Mui-active { + box-shadow: none; + } + } + } +`,Fe=({markers:t})=>{const{playingNode:i,playerRef:r}=M(u=>u),[c,g]=s.useState(0),a=i,w=s.useCallback((u,h)=>{const d=Array.isArray(h)?h[0]:h;r&&r.seekTo(d,"seconds")},[r]);s.useEffect(()=>{const u=setInterval(()=>{if(r&&g){const h=r.getCurrentTime();g(h)}},500);return()=>clearInterval(u)},[r,g]);const j=(r==null?void 0:r.getDuration())||0;return a?e.jsxs(Ae,{children:[e.jsx(Y,{}),e.jsx(He,{duration:j,handleProgressChange:w,markers:t,playingTIme:c})]}):null},Ae=p(v).attrs({direction:"row",align:"center",justify:"space-between"})` + padding: 20px; + background: ${k.BG2}; + height: 96px; + /* margin-top: 16px; */ + border-radius: 8px; + box-sizing: border-box; + margin-right: 4px; +`,ze=(t,i)=>{let r=0,c=t.length-1;for(;r<=c;){const g=Math.floor((r+c)/2),a=t[g],{start:w,end:j}=a.properties;if(i>=w&&i<=j)return a;i{const i=s.useRef(null),[r,c]=s.useState("ready"),[g,a]=s.useState(!1),{setActiveEdge:w}=X(b=>b),{dataInitial:j}=U(b=>b),{isPlaying:u,playingTime:h,setIsPlaying:d,setPlayingTime:I,setDuration:l,playingNode:f,volume:n,setHasError:S,resetPlayer:E,isSeeking:T,setIsSeeking:W,setPlayerRef:B,playerRef:R,playbackSpeed:x}=M(b=>b);s.useEffect(()=>()=>E(),[E]),s.useEffect(()=>{f&&!g&&(I(0),l(0),a(!1))},[f,I,l,a,g]),s.useEffect(()=>{T&&R&&(R.seekTo(h,"seconds"),W(!1))},[h,T,W,R]);const m=s.useCallback(()=>{d(!u)},[u,d]),o=()=>{S(!0),c("error")},C=s.useCallback(b=>{b.code},[m]);s.useEffect(()=>(window.addEventListener("keydown",C),()=>{window.removeEventListener("keydown",C)}),[C]);const _=s.useMemo(()=>((j==null?void 0:j.links.filter(y=>{var P;return(P=y==null?void 0:y.properties)==null?void 0:P.start}))||[]).slice().sort((y,P)=>{var z,q;return((z=y==null?void 0:y.properties)==null?void 0:z.start)-((q=P==null?void 0:P.properties)==null?void 0:q.start)}),[j]),F=b=>{if(!T){const H=b.playedSeconds,y=ze(_,H);w(y||null)}},$=()=>{R&&c("ready")},A=s.useCallback(()=>{u||d(!0)},[d,u]),G=s.useCallback(()=>{u&&d(!1)},[d,u]),N=b=>{b.stopPropagation()},L=s.useCallback(b=>{!R&&b&&B(b)},[B,R]);return t?e.jsxs(Ne,{ref:i,tabIndex:0,children:[e.jsx(Ge,{isFullScreen:!1,children:e.jsx(ne,{size:120,src:(f==null?void 0:f.image_url)||"",type:"clip"})}),e.jsx(Ze,{isFullScreen:!1,onClick:N,children:e.jsx(me,{ref:L,height:"219px",onBuffer:()=>c("buffering"),onBufferEnd:()=>c("ready"),onError:o,onPause:G,onPlay:A,onProgress:F,onReady:$,playbackRate:x,playing:u,url:t||"",volume:n,width:"100%"})}),r==="error"?e.jsx(Le,{className:"error-wrapper",children:"Error happened, please try later"}):null]}):null},Ne=p(v)` + border-bottom: 1px solid rgba(0, 0, 0, 0.25); + background: rgba(0, 0, 0, 0.2); + position: relative; + overflow: hidden; + height: auto; + &:focus { + outline: none; + } +`,Ge=p(v)` + position: absolute; + top: ${t=>t.isFullScreen?"38%":"18%"}; + left: 50%; + transform: translateX(-50%); + z-index: -1; +`,Le=p(v)` + height: 60px; + padding: 12px 16px; + color: ${k.primaryRed}; +`,Ze=p.div` + margin: ${t=>t.isFullScreen?"80px auto":"0"}; + width: 100%; + cursor: pointer; +`,Ve=s.memo(De),ee=s.forwardRef(({active:t,start:i,text:r},c)=>e.jsxs(Oe,{ref:c,className:oe({active:t}),children:[e.jsx(qe,{children:i}),e.jsx(Ue,{children:e.jsx("span",{children:r})})]}));ee.displayName="ParagraphComponent";const O=s.memo(ee,(t,i)=>t.active===i.active),Oe=p(v)` + flex-direction: row; + align-items: flex-start; + font-size: 14px; + padding: 8px 24px; + &.active { + background: ${k.AI_HIGHLIGHT}; + } +`,qe=p.span` + background: ${k.lightBlue100}; + color: ${k.lightBlue500}; + padding: 2px; + margin-right: 8px; + border-radius: 4px; +`,Ue=p.div` + margin: 0 2px; + word-break: break-word; + + &.active { + background: ${k.AI_HIGHLIGHT}; + } +`,Xe=({transcriptString:t,isFirst:i})=>{const[r,c]=s.useState(0),[g,a]=s.useState(!1),{playerRef:w}=M(l=>l),j=t.replace(/^["']|["']$/g,""),u=JSON.parse(j),h=s.useRef(null),d=s.useRef(null),I=s.useRef(null);return s.useEffect(()=>{const l=setInterval(()=>{if(w&&c){const f=w.getCurrentTime();c(f)}},100);return()=>clearInterval(l)},[w,c]),s.useEffect(()=>{const l=()=>{a(!0),I.current&&clearTimeout(I.current),I.current=setTimeout(()=>{a(!1)},1e3)},f=d.current;return f&&f.addEventListener("scroll",l),()=>{f&&f.removeEventListener("scroll",l)}},[]),s.useEffect(()=>{!g&&h.current&&h.current.scrollIntoView({behavior:"smooth",block:"center"})},[r,g]),e.jsx(Ye,{ref:d,children:e.jsx(e.Fragment,{children:i?e.jsx(e.Fragment,{children:u[0].start>r?e.jsx(O,{active:!1,start:V(u[0].start),text:u[0].text}):e.jsx(e.Fragment,{children:u.map(l=>{const f=V(l.start),n=l.start{const f=V(l.start),n=l.start{var f;const i=D(n=>n.clips),{playerRef:r}=M(n=>n),[c,g]=s.useState(0),[a,w]=s.useState(null),[j,u]=s.useState(!0),[h,d,I]=X(n=>[n.setActiveNode,n.activeNode,n.simulation]);s.useEffect(()=>{const n=setInterval(()=>{if(r&&g){const S=r.getCurrentTime();g(S)}},100);return()=>clearInterval(n)},[r,g]),s.useEffect(()=>{c&&(()=>{var E;const S=i.find(T=>{var R;const[W,B]=l((R=T==null?void 0:T.properties)==null?void 0:R.timestamp);return W<=c&&c{if(a&&(!d||a.ref_id!==d.ref_id)){const n=I==null?void 0:I.nodes().find(S=>S.ref_id===a.ref_id);typeof(n==null?void 0:n.fx)=="number"&&h(n)}},[a,d,h,I]);const l=n=>n?n.split("-").map(Number):[0,0];return e.jsxs(Ke,{children:[e.jsx(v,{className:"heading",children:t}),a?e.jsx(Qe,{direction:"row",children:((f=a.properties)==null?void 0:f.transcript)&&e.jsx(Xe,{isFirst:j,transcriptString:a.properties.transcript})}):null]})},Ke=p(v)` + .heading { + font-weight: 700; + font-size: 16px; + margin-bottom: 16px; + } + color: ${k.white}; + background: ${k.BG1}; + border-radius: 8px; + padding: 24px; + overflow-y: auto; + flex: 1 1 100%; +`,Qe=p(v)` + flex-wrap: wrap; + flex: 1 1 100%; + margin-left: -24px; + margin-right: -24px; +`,et=()=>{var i;const t=D(r=>r.selectedEpisode);return e.jsxs(tt,{align:"stretch",basis:"100%",grow:1,shrink:1,children:[e.jsx(rt,{children:((i=t==null?void 0:t.properties)==null?void 0:i.source_link)&&e.jsx(Ve,{mediaUrl:t.properties.source_link})}),e.jsx(Je,{name:(t==null?void 0:t.name)||""})]})},tt=p(v)(({theme:t})=>({position:"relative",display:"flex",padding:"0 20px 0 20px",background:"transparent",width:"100%",height:"calc(100vh - 180px)",overflow:"auto",[t.breakpoints.up("sm")]:{width:ye,gap:"10px"}})),rt=p(v)(({theme:t})=>({width:"100%",marginBottom:"20px",[t.breakpoints.up("sm")]:{width:"390px",margin:"0 auto"}})),St=()=>{const{addNewNode:t,isFetching:i,runningProjectId:r}=U(x=>x),[c,g]=s.useState(null),[a,w]=s.useState(!1),j=D(x=>x.setSelectedEpisode),u=D(x=>x.setClips),h=D(x=>x.clips),d=xe(),I=s.useRef(null),l=s.useRef(null),f=s.useRef(null),n=s.useRef(null),S=s.useRef(null),E=ie(),{episodeId:T}=ae(),{setPlayingNode:W}=M(x=>x);s.useEffect(()=>{T&&(async m=>{try{const o=await ce(m);o&&(W(o),j(o),t({nodes:[o],edges:[]}))}catch(o){E("/"),console.error(o)}})(T)},[T,W,j,t,E]),s.useEffect(()=>{T&&(async()=>{try{const m=await Z(T||"",0,50,{nodeType:["Show","Host","Guest"],useSubGraph:!1}),o=await Z(T||"",0,50,{nodeType:["Clip"],useSubGraph:!1});t({nodes:m!=null&&m.nodes?m==null?void 0:m.nodes:[],edges:m!=null&&m.edges?m.edges:[]}),o!=null&&o.nodes&&u(o==null?void 0:o.nodes)}catch(m){E("/"),console.error("Error fetching initial data:",m)}})()},[T,t,u,E]),s.useEffect(()=>{if(!h)return;(async()=>{var m,o;try{const C=(h==null?void 0:h.map(F=>F.ref_id).filter(Boolean))||[],_={nodes:((m=f.current)==null?void 0:m.nodes)||[],edges:((o=f.current)==null?void 0:o.edges)||[]};for(const F of C){const $=await Z(F,0,50);$&&(_.nodes.push(...($==null?void 0:$.nodes)||[]),_.edges.push(...($==null?void 0:$.edges)||[]),f.current=_,g({..._}))}}catch(C){console.error("Error processing clip nodes:",C)}})()},[h]);const B=s.useCallback(x=>{i||(n.current||(n.current={nodes:[],edges:[]}),x.edges&&n.current.edges.push(...x.edges),x.nodes&&n.current.nodes.push(...x.nodes),S.current&&clearTimeout(S.current),S.current=setTimeout(()=>{if(n.current){const{nodes:m,edges:o}=n.current,C={nodes:m,edges:o};n.current={nodes:[],edges:[]},t(C)}},3e3))},[t,i]);s.useEffect(()=>(d&&(d.connect(),d.on("connect_error",x=>{console.error("Socket connection error:",x)}),r&&d.on("new_node_created",B)),()=>{d&&d.off()}),[d,B,r]),s.useEffect(()=>{const x=m=>{const{playerRef:o}=M.getState();if(l.current!==null){if(m-l.current>1e3){if(f.current&&o){const{nodes:_,edges:F}=f.current,$=o==null?void 0:o.getCurrentTime(),[A,G]=F.reduce(([b,H],y)=>{var P,z;return((P=y==null?void 0:y.properties)==null?void 0:P.start)!==void 0&&((z=y==null?void 0:y.properties)==null?void 0:z.start)<$+1?b.push(y):H.push(y),[b,H]},[[],[]]),[N,L]=_.reduce(([b,H],y)=>(A.some(P=>P.target===y.ref_id||P.source===y.ref_id)?b.push(y):H.push(y),[b,H]),[[],[]]);f.current={nodes:L,edges:G},(N.length||A.length)&&t({nodes:N,edges:A})}l.current=m}}else l.current=m;I.current=requestAnimationFrame(x)};return I.current=requestAnimationFrame(x),()=>{I.current&&cancelAnimationFrame(I.current)}},[f,t]),s.useEffect(()=>{if(r)try{d==null||d.emit("update_project_id",{id:r})}catch(x){console.error(x)}},[r,d]);const R=s.useMemo(()=>{if(c){const x=c.edges.filter(o=>{var C;return(C=o==null?void 0:o.properties)==null?void 0:C.start}).map(o=>{var C;return{source:o.source,target:o.target,start:(C=o.properties)==null?void 0:C.start}});return c.nodes.filter(o=>c.edges.some(C=>C.source===o.ref_id||C.target===o.ref_id)).map(o=>{const C=x.find(_=>o.ref_id===_.source||o.ref_id===_.target);return{...o,start:(C==null?void 0:C.start)||0}}).filter(o=>o&&o.node_type!=="Clip"&&o.node_type!=="Episode"&&o.node_type!=="Show")}return[]},[c]);return e.jsxs(st,{children:[e.jsx(nt,{direction:"row",children:e.jsxs(e.Fragment,{children:[e.jsxs(v,{children:[e.jsx(v,{onClick:()=>w(!a),children:e.jsx(je,{})}),e.jsx(et,{})]}),e.jsx(ot,{children:e.jsx(v,{basis:"100%",grow:1,shrink:1,children:e.jsx(le,{})})})]})}),e.jsx(it,{children:e.jsx(Fe,{markers:R})})]})},st=p.div` + display: flex; + flex-direction: column; + height: 100vh; + width: 100%; +`,nt=p(v)` + flex: 1; + overflow: hidden; +`,ot=p(v)` + flex-basis: 100%; + flex-shrink: 1; + flex-grow: 1; + padding: 16px 16px 16px 0; +`,it=p(v)` + padding: 16px 16px 16px 0; + margin-left: 18px; +`;export{St as MindSet}; diff --git a/build/assets/index-d96216bb.js b/build/assets/index-d96216bb.js new file mode 100644 index 000000000..18dfc6f76 --- /dev/null +++ b/build/assets/index-d96216bb.js @@ -0,0 +1,71 @@ +import{r as u,j as f,b$ as kt,c0 as Rt,a1 as xo,$ as Ot,N as a,K as ye,L as $e,M as w,X as L,P as Pe,G as ae,S as ne,U as Ie,O as Re,Y as lo,V as Uo,c1 as Lt,c2 as wt,Z as st,c3 as it,by as ct,bz as dt,aj as Xe,c4 as To,a2 as Mt,am as Ft,s as Tt,a as je,F as At}from"./index-4e60c9e2.js";import{T as Nt}from"./index-569670a3.js";import{a as Ao,u as fo,b as so,f as io,i as ut,c as zt,P as No,F as Dt,S as Et}from"./Stack-5870980a.js";import{L as Ho,e as pt,ap as ft,aL as Bt,w as Fo,P as jt,aM as Wt,Q as Vo}from"./index-af5a3f81.js";import{c as zo}from"./createSvgIcon-c125a9c8.js";import{T as _t}from"./TextareaAutosize-f6242cb8.js";const Ut=e=>{const o=u.useRef({});return u.useEffect(()=>{o.current=e}),o.current},Ht=Ut;function Vt(e){return e==null||Object.keys(e).length===0}function Kt(e){const{styles:o,defaultTheme:t={}}=e,r=typeof o=="function"?s=>o(Vt(s)?t:s):o;return f.jsx(kt,{styles:r})}function qt({styles:e,themeId:o,defaultTheme:t={}}){const r=Rt(t),s=typeof e=="function"?e(o&&r[o]||r):e;return f.jsx(Kt,{styles:s})}const Gt=zo(f.jsx("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close");function Ko(e){return typeof e.normalize<"u"?e.normalize("NFD").replace(/[\u0300-\u036f]/g,""):e}function Xt(e={}){const{ignoreAccents:o=!0,ignoreCase:t=!0,limit:r,matchFrom:s="any",stringify:c,trim:d=!1}=e;return(i,{inputValue:b,getOptionLabel:p})=>{let m=d?b.trim():b;t&&(m=m.toLowerCase()),o&&(m=Ko(m));const h=m?i.filter($=>{let v=(c||p)($);return t&&(v=v.toLowerCase()),o&&(v=Ko(v)),s==="start"?v.indexOf(m)===0:v.indexOf(m)>-1}):i;return typeof r=="number"?h.slice(0,r):h}}function wo(e,o){for(let t=0;t{var o;return e.current!==null&&((o=e.current.parentElement)==null?void 0:o.contains(document.activeElement))};function Qt(e){const{unstable_isActiveElementInListbox:o=Zt,unstable_classNamePrefix:t="Mui",autoComplete:r=!1,autoHighlight:s=!1,autoSelect:c=!1,blurOnSelect:d=!1,clearOnBlur:i=!e.freeSolo,clearOnEscape:b=!1,componentName:p="useAutocomplete",defaultValue:m=e.multiple?[]:null,disableClearable:h=!1,disableCloseOnSelect:$=!1,disabled:v,disabledItemsFocusable:R=!1,disableListWrap:M=!1,filterOptions:P=Yt,filterSelectedOptions:O=!1,freeSolo:k=!1,getOptionDisabled:C,getOptionKey:I,getOptionLabel:E=l=>{var n;return(n=l.label)!=null?n:l},groupBy:N,handleHomeEndKeys:F=!e.freeSolo,id:q,includeInputInList:le=!1,inputValue:de,isOptionEqualToValue:oe=(l,n)=>l===n,multiple:T=!1,onChange:Q,onClose:G,onHighlightChange:se,onInputChange:J,onOpen:re,open:U,openOnFocus:A=!1,options:ie,readOnly:Se=!1,selectOnFocus:we=!e.freeSolo,value:ue}=e,W=Ao(q);let ee=E;ee=l=>{const n=E(l);return typeof n!="string"?String(n):n};const fe=u.useRef(!1),We=u.useRef(!0),Z=u.useRef(null),be=u.useRef(null),[Me,Y]=u.useState(null),[H,ze]=u.useState(-1),_e=s?0:-1,te=u.useRef(_e),[S,to]=fo({controlled:ue,default:m,name:p}),[_,xe]=fo({controlled:de,default:"",name:p,state:"inputValue"}),[Fe,ce]=u.useState(!1),Te=u.useCallback((l,n)=>{if(!(T?S.length!(O&&(T?S:[S]).some(n=>n!==null&&oe(l,n)))),{inputValue:Ee&&Ye?"":_,getOptionLabel:ee}):[],he=Ht({filteredOptions:j,value:S,inputValue:_});u.useEffect(()=>{const l=S!==he.value;Fe&&!l||k&&!l||Te(null,S)},[S,Te,Fe,he.value,k]);const Ke=me&&j.length>0&&!Se,qe=xo(l=>{l===-1?Z.current.focus():Me.querySelector(`[data-tag-index="${l}"]`).focus()});u.useEffect(()=>{T&&H>S.length-1&&(ze(-1),qe(-1))},[S,T,H,qe]);function y(l,n){if(!be.current||l<0||l>=j.length)return-1;let g=l;for(;;){const x=be.current.querySelector(`[data-option-index="${g}"]`),K=R?!1:!x||x.disabled||x.getAttribute("aria-disabled")==="true";if(x&&x.hasAttribute("tabindex")&&!K)return g;if(n==="next"?g=(g+1)%j.length:g=(g-1+j.length)%j.length,g===l)return-1}}const B=xo(({event:l,index:n,reason:g="auto"})=>{if(te.current=n,n===-1?Z.current.removeAttribute("aria-activedescendant"):Z.current.setAttribute("aria-activedescendant",`${W}-option-${n}`),se&&se(l,n===-1?null:j[n],g),!be.current)return;const x=be.current.querySelector(`[role="option"].${t}-focused`);x&&(x.classList.remove(`${t}-focused`),x.classList.remove(`${t}-focusVisible`));let K=be.current;if(be.current.getAttribute("role")!=="listbox"&&(K=be.current.parentElement.querySelector('[role="listbox"]')),!K)return;if(n===-1){K.scrollTop=0;return}const pe=be.current.querySelector(`[data-option-index="${n}"]`);if(pe&&(pe.classList.add(`${t}-focused`),g==="keyboard"&&pe.classList.add(`${t}-focusVisible`),K.scrollHeight>K.clientHeight&&g!=="mouse"&&g!=="touch")){const ge=pe,He=K.clientHeight+K.scrollTop,_o=ge.offsetTop+ge.offsetHeight;_o>He?K.scrollTop=_o-K.clientHeight:ge.offsetTop-ge.offsetHeight*(N?1.3:0){if(!z)return;const pe=y((()=>{const ge=j.length-1;if(n==="reset")return _e;if(n==="start")return 0;if(n==="end")return ge;const He=te.current+n;return He<0?He===-1&&le?-1:M&&te.current!==-1||Math.abs(n)>1?0:ge:He>ge?He===ge+1&&le?-1:M||Math.abs(n)>1?ge:0:He})(),g);if(B({index:pe,reason:x,event:l}),r&&n!=="reset")if(pe===-1)Z.current.value=_;else{const ge=ee(j[pe]);Z.current.value=ge,ge.toLowerCase().indexOf(_.toLowerCase())===0&&_.length>0&&Z.current.setSelectionRange(_.length,ge.length)}}),ke=()=>{const l=(n,g)=>{const x=n?ee(n):"",K=g?ee(g):"";return x===K};if(te.current!==-1&&he.filteredOptions&&he.filteredOptions.length!==j.length&&he.inputValue===_&&(T?S.length===he.value.length&&he.value.every((n,g)=>ee(S[g])===ee(n)):l(he.value,S))){const n=he.filteredOptions[te.current];if(n&&j.some(x=>ee(x)===ee(n)))return!0}return!1},Ze=u.useCallback(()=>{if(!z||ke())return;const l=T?S[0]:S;if(j.length===0||l==null){X({diff:"reset"});return}if(be.current){if(l!=null){const n=j[te.current];if(T&&n&&wo(S,x=>oe(n,x))!==-1)return;const g=wo(j,x=>oe(x,l));g===-1?X({diff:"reset"}):B({index:g});return}if(te.current>=j.length-1){B({index:j.length-1});return}B({index:te.current})}},[j.length,T?!1:S,O,X,B,z,_,T]),Po=xo(l=>{Ot(be,l),l&&Ze()});u.useEffect(()=>{Ze()},[Ze]);const Ne=l=>{me||(Ae(!0),De(!0),re&&re(l))},Ge=(l,n)=>{me&&(Ae(!1),G&&G(l,n))},Ue=(l,n,g,x)=>{if(T){if(S.length===n.length&&S.every((K,pe)=>K===n[pe]))return}else if(S===n)return;Q&&Q(l,n,g,x),to(n)},no=u.useRef(!1),eo=(l,n,g="selectOption",x="options")=>{let K=g,pe=n;if(T){pe=Array.isArray(S)?S.slice():[];const ge=wo(pe,He=>oe(n,He));ge===-1?pe.push(n):x!=="freeSolo"&&(pe.splice(ge,1),K="removeOption")}Te(l,pe),Ue(l,pe,K,{option:n}),!$&&(!l||!l.ctrlKey&&!l.metaKey)&&Ge(l,K),(d===!0||d==="touch"&&no.current||d==="mouse"&&!no.current)&&Z.current.blur()};function go(l,n){if(l===-1)return-1;let g=l;for(;;){if(n==="next"&&g===S.length||n==="previous"&&g===-1)return-1;const x=Me.querySelector(`[data-tag-index="${g}"]`);if(!x||!x.hasAttribute("tabindex")||x.disabled||x.getAttribute("aria-disabled")==="true")g+=n==="next"?1:-1;else return g}}const mo=(l,n)=>{if(!T)return;_===""&&Ge(l,"toggleInput");let g=H;H===-1?_===""&&n==="previous"&&(g=S.length-1):(g+=n==="next"?1:-1,g<0&&(g=0),g===S.length&&(g=-1)),g=go(g,n),ze(g),qe(g)},ho=l=>{fe.current=!0,xe(""),J&&J(l,"","clear"),Ue(l,T?[]:null,"clear")},ko=l=>n=>{if(l.onKeyDown&&l.onKeyDown(n),!n.defaultMuiPrevented&&(H!==-1&&["ArrowLeft","ArrowRight"].indexOf(n.key)===-1&&(ze(-1),qe(-1)),n.which!==229))switch(n.key){case"Home":z&&F&&(n.preventDefault(),X({diff:"start",direction:"next",reason:"keyboard",event:n}));break;case"End":z&&F&&(n.preventDefault(),X({diff:"end",direction:"previous",reason:"keyboard",event:n}));break;case"PageUp":n.preventDefault(),X({diff:-qo,direction:"previous",reason:"keyboard",event:n}),Ne(n);break;case"PageDown":n.preventDefault(),X({diff:qo,direction:"next",reason:"keyboard",event:n}),Ne(n);break;case"ArrowDown":n.preventDefault(),X({diff:1,direction:"next",reason:"keyboard",event:n}),Ne(n);break;case"ArrowUp":n.preventDefault(),X({diff:-1,direction:"previous",reason:"keyboard",event:n}),Ne(n);break;case"ArrowLeft":mo(n,"previous");break;case"ArrowRight":mo(n,"next");break;case"Enter":if(te.current!==-1&&z){const g=j[te.current],x=C?C(g):!1;if(n.preventDefault(),x)return;eo(n,g,"selectOption"),r&&Z.current.setSelectionRange(Z.current.value.length,Z.current.value.length)}else k&&_!==""&&Ee===!1&&(T&&n.preventDefault(),eo(n,_,"createOption","freeSolo"));break;case"Escape":z?(n.preventDefault(),n.stopPropagation(),Ge(n,"escape")):b&&(_!==""||T&&S.length>0)&&(n.preventDefault(),n.stopPropagation(),ho(n));break;case"Backspace":if(T&&!Se&&_===""&&S.length>0){const g=H===-1?S.length-1:H,x=S.slice();x.splice(g,1),Ue(n,x,"removeOption",{option:S[g]})}break;case"Delete":if(T&&!Se&&_===""&&S.length>0&&H!==-1){const g=H,x=S.slice();x.splice(g,1),Ue(n,x,"removeOption",{option:S[g]})}break}},jo=l=>{ce(!0),A&&!fe.current&&Ne(l)},ro=l=>{if(o(be)){Z.current.focus();return}ce(!1),We.current=!0,fe.current=!1,c&&te.current!==-1&&z?eo(l,j[te.current],"blur"):c&&k&&_!==""?eo(l,_,"blur","freeSolo"):i&&Te(l,S),Ge(l,"blur")},Ce=l=>{const n=l.target.value;_!==n&&(xe(n),De(!1),J&&J(l,n,"input")),n===""?!h&&!T&&Ue(l,null,"clear"):Ne(l)},ve=l=>{const n=Number(l.currentTarget.getAttribute("data-option-index"));te.current!==n&&B({event:l,index:n,reason:"mouse"})},Be=l=>{B({event:l,index:Number(l.currentTarget.getAttribute("data-option-index")),reason:"touch"}),no.current=!0},Wo=l=>{const n=Number(l.currentTarget.getAttribute("data-option-index"));eo(l,j[n],"selectOption"),no.current=!1},Ro=l=>n=>{const g=S.slice();g.splice(l,1),Ue(n,g,"removeOption",{option:S[l]})},Oo=l=>{me?Ge(l,"toggleInput"):Ne(l)},Lo=l=>{l.currentTarget.contains(l.target)&&l.target.getAttribute("id")!==W&&l.preventDefault()},vo=l=>{l.currentTarget.contains(l.target)&&(Z.current.focus(),we&&We.current&&Z.current.selectionEnd-Z.current.selectionStart===0&&Z.current.select(),We.current=!1)},co=l=>{!v&&(_===""||!me)&&Oo(l)};let oo=k&&_.length>0;oo=oo||(T?S.length>0:S!==null);let ao=j;return N&&(ao=j.reduce((l,n,g)=>{const x=N(n);return l.length>0&&l[l.length-1].group===x?l[l.length-1].options.push(n):l.push({key:g,index:g,group:x,options:[n]}),l},[])),v&&Fe&&ro(),{getRootProps:(l={})=>a({"aria-owns":Ke?`${W}-listbox`:null},l,{onKeyDown:ko(l),onMouseDown:Lo,onClick:vo}),getInputLabelProps:()=>({id:`${W}-label`,htmlFor:W}),getInputProps:()=>({id:W,value:_,onBlur:ro,onFocus:jo,onChange:Ce,onMouseDown:co,"aria-activedescendant":z?"":null,"aria-autocomplete":r?"both":"list","aria-controls":Ke?`${W}-listbox`:void 0,"aria-expanded":Ke,autoComplete:"off",ref:Z,autoCapitalize:"none",spellCheck:"false",role:"combobox",disabled:v}),getClearProps:()=>({tabIndex:-1,type:"button",onClick:ho}),getPopupIndicatorProps:()=>({tabIndex:-1,type:"button",onClick:Oo}),getTagProps:({index:l})=>a({key:l,"data-tag-index":l,tabIndex:-1},!Se&&{onDelete:Ro(l)}),getListboxProps:()=>({role:"listbox",id:`${W}-listbox`,"aria-labelledby":`${W}-label`,ref:Po,onMouseDown:l=>{l.preventDefault()}}),getOptionProps:({index:l,option:n})=>{var g;const x=(T?S:[S]).some(pe=>pe!=null&&oe(n,pe)),K=C?C(n):!1;return{key:(g=I==null?void 0:I(n))!=null?g:ee(n),tabIndex:-1,role:"option",id:`${W}-option-${l}`,onMouseMove:ve,onClick:Wo,onTouchStart:Be,"data-option-index":l,"aria-disabled":K,"aria-selected":x}},id:W,inputValue:_,value:S,dirty:oo,expanded:z&&Me,popupOpen:z,focused:Fe||H!==-1,anchorEl:Me,setAnchorEl:Y,focusedTag:H,groupedOptions:ao}}function Jt(e){return ye("MuiListSubheader",e)}$e("MuiListSubheader",["root","colorPrimary","colorInherit","gutters","inset","sticky"]);const en=["className","color","component","disableGutters","disableSticky","inset"],on=e=>{const{classes:o,color:t,disableGutters:r,inset:s,disableSticky:c}=e,d={root:["root",t!=="default"&&`color${L(t)}`,!r&&"gutters",s&&"inset",!c&&"sticky"]};return Ie(d,Jt,o)},tn=w("li",{name:"MuiListSubheader",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.root,t.color!=="default"&&o[`color${L(t.color)}`],!t.disableGutters&&o.gutters,t.inset&&o.inset,!t.disableSticky&&o.sticky]}})(({theme:e,ownerState:o})=>a({boxSizing:"border-box",lineHeight:"48px",listStyle:"none",color:(e.vars||e).palette.text.secondary,fontFamily:e.typography.fontFamily,fontWeight:e.typography.fontWeightMedium,fontSize:e.typography.pxToRem(14)},o.color==="primary"&&{color:(e.vars||e).palette.primary.main},o.color==="inherit"&&{color:"inherit"},!o.disableGutters&&{paddingLeft:16,paddingRight:16},o.inset&&{paddingLeft:72},!o.disableSticky&&{position:"sticky",top:0,zIndex:1,backgroundColor:(e.vars||e).palette.background.paper})),bt=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiListSubheader"}),{className:s,color:c="default",component:d="li",disableGutters:i=!1,disableSticky:b=!1,inset:p=!1}=r,m=ae(r,en),h=a({},r,{color:c,component:d,disableGutters:i,disableSticky:b,inset:p}),$=on(h);return f.jsx(tn,a({as:d,className:ne($.root,s),ref:t,ownerState:h},m))});bt.muiSkipListHighlight=!0;const nn=bt,rn=zo(f.jsx("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"}),"Cancel");function an(e){return ye("MuiChip",e)}const ln=$e("MuiChip",["root","sizeSmall","sizeMedium","colorError","colorInfo","colorPrimary","colorSecondary","colorSuccess","colorWarning","disabled","clickable","clickableColorPrimary","clickableColorSecondary","deletable","deletableColorPrimary","deletableColorSecondary","outlined","filled","outlinedPrimary","outlinedSecondary","filledPrimary","filledSecondary","avatar","avatarSmall","avatarMedium","avatarColorPrimary","avatarColorSecondary","icon","iconSmall","iconMedium","iconColorPrimary","iconColorSecondary","label","labelSmall","labelMedium","deleteIcon","deleteIconSmall","deleteIconMedium","deleteIconColorPrimary","deleteIconColorSecondary","deleteIconOutlinedColorPrimary","deleteIconOutlinedColorSecondary","deleteIconFilledColorPrimary","deleteIconFilledColorSecondary","focusVisible"]),V=ln,sn=["avatar","className","clickable","color","component","deleteIcon","disabled","icon","label","onClick","onDelete","onKeyDown","onKeyUp","size","variant","tabIndex","skipFocusWhenDisabled"],cn=e=>{const{classes:o,disabled:t,size:r,color:s,iconColor:c,onDelete:d,clickable:i,variant:b}=e,p={root:["root",b,t&&"disabled",`size${L(r)}`,`color${L(s)}`,i&&"clickable",i&&`clickableColor${L(s)}`,d&&"deletable",d&&`deletableColor${L(s)}`,`${b}${L(s)}`],label:["label",`label${L(r)}`],avatar:["avatar",`avatar${L(r)}`,`avatarColor${L(s)}`],icon:["icon",`icon${L(r)}`,`iconColor${L(c)}`],deleteIcon:["deleteIcon",`deleteIcon${L(r)}`,`deleteIconColor${L(s)}`,`deleteIcon${L(b)}Color${L(s)}`]};return Ie(p,an,o)},dn=w("div",{name:"MuiChip",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e,{color:r,iconColor:s,clickable:c,onDelete:d,size:i,variant:b}=t;return[{[`& .${V.avatar}`]:o.avatar},{[`& .${V.avatar}`]:o[`avatar${L(i)}`]},{[`& .${V.avatar}`]:o[`avatarColor${L(r)}`]},{[`& .${V.icon}`]:o.icon},{[`& .${V.icon}`]:o[`icon${L(i)}`]},{[`& .${V.icon}`]:o[`iconColor${L(s)}`]},{[`& .${V.deleteIcon}`]:o.deleteIcon},{[`& .${V.deleteIcon}`]:o[`deleteIcon${L(i)}`]},{[`& .${V.deleteIcon}`]:o[`deleteIconColor${L(r)}`]},{[`& .${V.deleteIcon}`]:o[`deleteIcon${L(b)}Color${L(r)}`]},o.root,o[`size${L(i)}`],o[`color${L(r)}`],c&&o.clickable,c&&r!=="default"&&o[`clickableColor${L(r)})`],d&&o.deletable,d&&r!=="default"&&o[`deletableColor${L(r)}`],o[b],o[`${b}${L(r)}`]]}})(({theme:e,ownerState:o})=>{const t=e.palette.mode==="light"?e.palette.grey[700]:e.palette.grey[300];return a({maxWidth:"100%",fontFamily:e.typography.fontFamily,fontSize:e.typography.pxToRem(13),display:"inline-flex",alignItems:"center",justifyContent:"center",height:32,color:(e.vars||e).palette.text.primary,backgroundColor:(e.vars||e).palette.action.selected,borderRadius:32/2,whiteSpace:"nowrap",transition:e.transitions.create(["background-color","box-shadow"]),cursor:"unset",outline:0,textDecoration:"none",border:0,padding:0,verticalAlign:"middle",boxSizing:"border-box",[`&.${V.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity,pointerEvents:"none"},[`& .${V.avatar}`]:{marginLeft:5,marginRight:-6,width:24,height:24,color:e.vars?e.vars.palette.Chip.defaultAvatarColor:t,fontSize:e.typography.pxToRem(12)},[`& .${V.avatarColorPrimary}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.dark},[`& .${V.avatarColorSecondary}`]:{color:(e.vars||e).palette.secondary.contrastText,backgroundColor:(e.vars||e).palette.secondary.dark},[`& .${V.avatarSmall}`]:{marginLeft:4,marginRight:-4,width:18,height:18,fontSize:e.typography.pxToRem(10)},[`& .${V.icon}`]:a({marginLeft:5,marginRight:-6},o.size==="small"&&{fontSize:18,marginLeft:4,marginRight:-4},o.iconColor===o.color&&a({color:e.vars?e.vars.palette.Chip.defaultIconColor:t},o.color!=="default"&&{color:"inherit"})),[`& .${V.deleteIcon}`]:a({WebkitTapHighlightColor:"transparent",color:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / 0.26)`:Re(e.palette.text.primary,.26),fontSize:22,cursor:"pointer",margin:"0 5px 0 -6px","&:hover":{color:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / 0.4)`:Re(e.palette.text.primary,.4)}},o.size==="small"&&{fontSize:16,marginRight:4,marginLeft:-4},o.color!=="default"&&{color:e.vars?`rgba(${e.vars.palette[o.color].contrastTextChannel} / 0.7)`:Re(e.palette[o.color].contrastText,.7),"&:hover, &:active":{color:(e.vars||e).palette[o.color].contrastText}})},o.size==="small"&&{height:24},o.color!=="default"&&{backgroundColor:(e.vars||e).palette[o.color].main,color:(e.vars||e).palette[o.color].contrastText},o.onDelete&&{[`&.${V.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Re(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},o.onDelete&&o.color!=="default"&&{[`&.${V.focusVisible}`]:{backgroundColor:(e.vars||e).palette[o.color].dark}})},({theme:e,ownerState:o})=>a({},o.clickable&&{userSelect:"none",WebkitTapHighlightColor:"transparent",cursor:"pointer","&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Re(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity)},[`&.${V.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Re(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)},"&:active":{boxShadow:(e.vars||e).shadows[1]}},o.clickable&&o.color!=="default"&&{[`&:hover, &.${V.focusVisible}`]:{backgroundColor:(e.vars||e).palette[o.color].dark}}),({theme:e,ownerState:o})=>a({},o.variant==="outlined"&&{backgroundColor:"transparent",border:e.vars?`1px solid ${e.vars.palette.Chip.defaultBorder}`:`1px solid ${e.palette.mode==="light"?e.palette.grey[400]:e.palette.grey[700]}`,[`&.${V.clickable}:hover`]:{backgroundColor:(e.vars||e).palette.action.hover},[`&.${V.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`& .${V.avatar}`]:{marginLeft:4},[`& .${V.avatarSmall}`]:{marginLeft:2},[`& .${V.icon}`]:{marginLeft:4},[`& .${V.iconSmall}`]:{marginLeft:2},[`& .${V.deleteIcon}`]:{marginRight:5},[`& .${V.deleteIconSmall}`]:{marginRight:3}},o.variant==="outlined"&&o.color!=="default"&&{color:(e.vars||e).palette[o.color].main,border:`1px solid ${e.vars?`rgba(${e.vars.palette[o.color].mainChannel} / 0.7)`:Re(e.palette[o.color].main,.7)}`,[`&.${V.clickable}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette[o.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:Re(e.palette[o.color].main,e.palette.action.hoverOpacity)},[`&.${V.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette[o.color].mainChannel} / ${e.vars.palette.action.focusOpacity})`:Re(e.palette[o.color].main,e.palette.action.focusOpacity)},[`& .${V.deleteIcon}`]:{color:e.vars?`rgba(${e.vars.palette[o.color].mainChannel} / 0.7)`:Re(e.palette[o.color].main,.7),"&:hover, &:active":{color:(e.vars||e).palette[o.color].main}}})),un=w("span",{name:"MuiChip",slot:"Label",overridesResolver:(e,o)=>{const{ownerState:t}=e,{size:r}=t;return[o.label,o[`label${L(r)}`]]}})(({ownerState:e})=>a({overflow:"hidden",textOverflow:"ellipsis",paddingLeft:12,paddingRight:12,whiteSpace:"nowrap"},e.variant==="outlined"&&{paddingLeft:11,paddingRight:11},e.size==="small"&&{paddingLeft:8,paddingRight:8},e.size==="small"&&e.variant==="outlined"&&{paddingLeft:7,paddingRight:7}));function Go(e){return e.key==="Backspace"||e.key==="Delete"}const pn=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiChip"}),{avatar:s,className:c,clickable:d,color:i="default",component:b,deleteIcon:p,disabled:m=!1,icon:h,label:$,onClick:v,onDelete:R,onKeyDown:M,onKeyUp:P,size:O="medium",variant:k="filled",tabIndex:C,skipFocusWhenDisabled:I=!1}=r,E=ae(r,sn),N=u.useRef(null),F=lo(N,t),q=A=>{A.stopPropagation(),R&&R(A)},le=A=>{A.currentTarget===A.target&&Go(A)&&A.preventDefault(),M&&M(A)},de=A=>{A.currentTarget===A.target&&(R&&Go(A)?R(A):A.key==="Escape"&&N.current&&N.current.blur()),P&&P(A)},oe=d!==!1&&v?!0:d,T=oe||R?Uo:b||"div",Q=a({},r,{component:T,disabled:m,size:O,color:i,iconColor:u.isValidElement(h)&&h.props.color||i,onDelete:!!R,clickable:oe,variant:k}),G=cn(Q),se=T===Uo?a({component:b||"div",focusVisibleClassName:G.focusVisible},R&&{disableRipple:!0}):{};let J=null;R&&(J=p&&u.isValidElement(p)?u.cloneElement(p,{className:ne(p.props.className,G.deleteIcon),onClick:q}):f.jsx(rn,{className:ne(G.deleteIcon),onClick:q}));let re=null;s&&u.isValidElement(s)&&(re=u.cloneElement(s,{className:ne(G.avatar,s.props.className)}));let U=null;return h&&u.isValidElement(h)&&(U=u.cloneElement(h,{className:ne(G.icon,h.props.className)})),f.jsxs(dn,a({as:T,className:ne(G.root,c),disabled:oe&&m?!0:void 0,onClick:v,onKeyDown:le,onKeyUp:de,ref:F,tabIndex:I&&m?-1:C,ownerState:Q},se,E,{children:[re||U,f.jsx(un,{className:ne(G.label),ownerState:Q,children:$}),J]}))}),fn=pn;function bn(e){return f.jsx(qt,a({},e,{defaultTheme:Lt,themeId:wt}))}function gn(e){return ye("MuiInputBase",e)}const mn=$e("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]),Oe=mn,hn=["aria-describedby","autoComplete","autoFocus","className","color","components","componentsProps","defaultValue","disabled","disableInjectingGlobalStyles","endAdornment","error","fullWidth","id","inputComponent","inputProps","inputRef","margin","maxRows","minRows","multiline","name","onBlur","onChange","onClick","onFocus","onKeyDown","onKeyUp","placeholder","readOnly","renderSuffix","rows","size","slotProps","slots","startAdornment","type","value"],Co=(e,o)=>{const{ownerState:t}=e;return[o.root,t.formControl&&o.formControl,t.startAdornment&&o.adornedStart,t.endAdornment&&o.adornedEnd,t.error&&o.error,t.size==="small"&&o.sizeSmall,t.multiline&&o.multiline,t.color&&o[`color${L(t.color)}`],t.fullWidth&&o.fullWidth,t.hiddenLabel&&o.hiddenLabel]},yo=(e,o)=>{const{ownerState:t}=e;return[o.input,t.size==="small"&&o.inputSizeSmall,t.multiline&&o.inputMultiline,t.type==="search"&&o.inputTypeSearch,t.startAdornment&&o.inputAdornedStart,t.endAdornment&&o.inputAdornedEnd,t.hiddenLabel&&o.inputHiddenLabel]},vn=e=>{const{classes:o,color:t,disabled:r,error:s,endAdornment:c,focused:d,formControl:i,fullWidth:b,hiddenLabel:p,multiline:m,readOnly:h,size:$,startAdornment:v,type:R}=e,M={root:["root",`color${L(t)}`,r&&"disabled",s&&"error",b&&"fullWidth",d&&"focused",i&&"formControl",$&&$!=="medium"&&`size${L($)}`,m&&"multiline",v&&"adornedStart",c&&"adornedEnd",p&&"hiddenLabel",h&&"readOnly"],input:["input",r&&"disabled",R==="search"&&"inputTypeSearch",m&&"inputMultiline",$==="small"&&"inputSizeSmall",p&&"inputHiddenLabel",v&&"inputAdornedStart",c&&"inputAdornedEnd",h&&"readOnly"]};return Ie(M,gn,o)},$o=w("div",{name:"MuiInputBase",slot:"Root",overridesResolver:Co})(({theme:e,ownerState:o})=>a({},e.typography.body1,{color:(e.vars||e).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${Oe.disabled}`]:{color:(e.vars||e).palette.text.disabled,cursor:"default"}},o.multiline&&a({padding:"4px 0 5px"},o.size==="small"&&{paddingTop:1}),o.fullWidth&&{width:"100%"})),Io=w("input",{name:"MuiInputBase",slot:"Input",overridesResolver:yo})(({theme:e,ownerState:o})=>{const t=e.palette.mode==="light",r=a({color:"currentColor"},e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5},{transition:e.transitions.create("opacity",{duration:e.transitions.duration.shorter})}),s={opacity:"0 !important"},c=e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5};return a({font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%",animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&::-webkit-input-placeholder":r,"&::-moz-placeholder":r,"&:-ms-input-placeholder":r,"&::-ms-input-placeholder":r,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${Oe.formControl} &`]:{"&::-webkit-input-placeholder":s,"&::-moz-placeholder":s,"&:-ms-input-placeholder":s,"&::-ms-input-placeholder":s,"&:focus::-webkit-input-placeholder":c,"&:focus::-moz-placeholder":c,"&:focus:-ms-input-placeholder":c,"&:focus::-ms-input-placeholder":c},[`&.${Oe.disabled}`]:{opacity:1,WebkitTextFillColor:(e.vars||e).palette.text.disabled},"&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}},o.size==="small"&&{paddingTop:1},o.multiline&&{height:"auto",resize:"none",padding:0,paddingTop:0},o.type==="search"&&{MozAppearance:"textfield"})}),xn=f.jsx(bn,{styles:{"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}}),Cn=u.forwardRef(function(o,t){var r;const s=Pe({props:o,name:"MuiInputBase"}),{"aria-describedby":c,autoComplete:d,autoFocus:i,className:b,components:p={},componentsProps:m={},defaultValue:h,disabled:$,disableInjectingGlobalStyles:v,endAdornment:R,fullWidth:M=!1,id:P,inputComponent:O="input",inputProps:k={},inputRef:C,maxRows:I,minRows:E,multiline:N=!1,name:F,onBlur:q,onChange:le,onClick:de,onFocus:oe,onKeyDown:T,onKeyUp:Q,placeholder:G,readOnly:se,renderSuffix:J,rows:re,slotProps:U={},slots:A={},startAdornment:ie,type:Se="text",value:we}=s,ue=ae(s,hn),W=k.value!=null?k.value:we,{current:ee}=u.useRef(W!=null),fe=u.useRef(),We=u.useCallback(z=>{},[]),Z=lo(fe,C,k.ref,We),[be,Me]=u.useState(!1),Y=so(),H=io({props:s,muiFormControl:Y,states:["color","disabled","error","hiddenLabel","size","required","filled"]});H.focused=Y?Y.focused:be,u.useEffect(()=>{!Y&&$&&be&&(Me(!1),q&&q())},[Y,$,be,q]);const ze=Y&&Y.onFilled,_e=Y&&Y.onEmpty,te=u.useCallback(z=>{ut(z)?ze&&ze():_e&&_e()},[ze,_e]);st(()=>{ee&&te({value:W})},[W,te,ee]);const S=z=>{if(H.disabled){z.stopPropagation();return}oe&&oe(z),k.onFocus&&k.onFocus(z),Y&&Y.onFocus?Y.onFocus(z):Me(!0)},to=z=>{q&&q(z),k.onBlur&&k.onBlur(z),Y&&Y.onBlur?Y.onBlur(z):Me(!1)},_=(z,...j)=>{if(!ee){const he=z.target||fe.current;if(he==null)throw new Error(it(1));te({value:he.value})}k.onChange&&k.onChange(z,...j),le&&le(z,...j)};u.useEffect(()=>{te(fe.current)},[]);const xe=z=>{fe.current&&z.currentTarget===z.target&&fe.current.focus(),de&&de(z)};let Fe=O,ce=k;N&&Fe==="input"&&(re?ce=a({type:void 0,minRows:re,maxRows:re},ce):ce=a({type:void 0,maxRows:I,minRows:E},ce),Fe=_t);const Te=z=>{te(z.animationName==="mui-auto-fill-cancel"?fe.current:{value:"x"})};u.useEffect(()=>{Y&&Y.setAdornedStart(!!ie)},[Y,ie]);const me=a({},s,{color:H.color||"primary",disabled:H.disabled,endAdornment:R,error:H.error,focused:H.focused,formControl:Y,fullWidth:M,hiddenLabel:H.hiddenLabel,multiline:N,size:H.size,startAdornment:ie,type:Se}),Ae=vn(me),Ye=A.root||p.Root||$o,De=U.root||m.root||{},Ee=A.input||p.Input||Io;return ce=a({},ce,(r=U.input)!=null?r:m.input),f.jsxs(u.Fragment,{children:[!v&&xn,f.jsxs(Ye,a({},De,!Ho(Ye)&&{ownerState:a({},me,De.ownerState)},{ref:t,onClick:xe},ue,{className:ne(Ae.root,De.className,b,se&&"MuiInputBase-readOnly"),children:[ie,f.jsx(zt.Provider,{value:null,children:f.jsx(Ee,a({ownerState:me,"aria-invalid":H.error,"aria-describedby":c,autoComplete:d,autoFocus:i,defaultValue:h,disabled:H.disabled,id:P,onAnimationStart:Te,name:F,placeholder:G,readOnly:se,required:H.required,rows:re,value:W,onKeyDown:T,onKeyUp:Q,type:Se},ce,!Ho(Ee)&&{as:Fe,ownerState:a({},me,ce.ownerState)},{ref:Z,className:ne(Ae.input,ce.className,se&&"MuiInputBase-readOnly"),onBlur:to,onChange:_,onFocus:S}))}),R,J?J(a({},H,{startAdornment:ie})):null]}))]})}),Do=Cn;function yn(e){return ye("MuiInput",e)}const $n=a({},Oe,$e("MuiInput",["root","underline","input"])),Je=$n;function In(e){return ye("MuiOutlinedInput",e)}const Sn=a({},Oe,$e("MuiOutlinedInput",["root","notchedOutline","input"])),Ve=Sn;function Pn(e){return ye("MuiFilledInput",e)}const kn=a({},Oe,$e("MuiFilledInput",["root","underline","input"])),Le=kn,gt=zo(f.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown");function Rn(e){return ye("MuiAutocomplete",e)}const On=$e("MuiAutocomplete",["root","expanded","fullWidth","focused","focusVisible","tag","tagSizeSmall","tagSizeMedium","hasPopupIcon","hasClearIcon","inputRoot","input","inputFocused","endAdornment","clearIndicator","popupIndicator","popupIndicatorOpen","popper","popperDisablePortal","paper","listbox","loading","noOptions","option","groupLabel","groupUl"]),D=On;var Xo,Yo;const Ln=["autoComplete","autoHighlight","autoSelect","blurOnSelect","ChipProps","className","clearIcon","clearOnBlur","clearOnEscape","clearText","closeText","componentsProps","defaultValue","disableClearable","disableCloseOnSelect","disabled","disabledItemsFocusable","disableListWrap","disablePortal","filterOptions","filterSelectedOptions","forcePopupIcon","freeSolo","fullWidth","getLimitTagsText","getOptionDisabled","getOptionKey","getOptionLabel","isOptionEqualToValue","groupBy","handleHomeEndKeys","id","includeInputInList","inputValue","limitTags","ListboxComponent","ListboxProps","loading","loadingText","multiple","noOptionsText","onChange","onClose","onHighlightChange","onInputChange","onOpen","open","openOnFocus","openText","options","PaperComponent","PopperComponent","popupIcon","readOnly","renderGroup","renderInput","renderOption","renderTags","selectOnFocus","size","slotProps","value"],wn=["ref"],Mn=["key"],Fn=e=>{const{classes:o,disablePortal:t,expanded:r,focused:s,fullWidth:c,hasClearIcon:d,hasPopupIcon:i,inputFocused:b,popupOpen:p,size:m}=e,h={root:["root",r&&"expanded",s&&"focused",c&&"fullWidth",d&&"hasClearIcon",i&&"hasPopupIcon"],inputRoot:["inputRoot"],input:["input",b&&"inputFocused"],tag:["tag",`tagSize${L(m)}`],endAdornment:["endAdornment"],clearIndicator:["clearIndicator"],popupIndicator:["popupIndicator",p&&"popupIndicatorOpen"],popper:["popper",t&&"popperDisablePortal"],paper:["paper"],listbox:["listbox"],loading:["loading"],noOptions:["noOptions"],option:["option"],groupLabel:["groupLabel"],groupUl:["groupUl"]};return Ie(h,Rn,o)},Tn=w("div",{name:"MuiAutocomplete",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e,{fullWidth:r,hasClearIcon:s,hasPopupIcon:c,inputFocused:d,size:i}=t;return[{[`& .${D.tag}`]:o.tag},{[`& .${D.tag}`]:o[`tagSize${L(i)}`]},{[`& .${D.inputRoot}`]:o.inputRoot},{[`& .${D.input}`]:o.input},{[`& .${D.input}`]:d&&o.inputFocused},o.root,r&&o.fullWidth,c&&o.hasPopupIcon,s&&o.hasClearIcon]}})(({ownerState:e})=>a({[`&.${D.focused} .${D.clearIndicator}`]:{visibility:"visible"},"@media (pointer: fine)":{[`&:hover .${D.clearIndicator}`]:{visibility:"visible"}}},e.fullWidth&&{width:"100%"},{[`& .${D.tag}`]:a({margin:3,maxWidth:"calc(100% - 6px)"},e.size==="small"&&{margin:2,maxWidth:"calc(100% - 4px)"}),[`& .${D.inputRoot}`]:{flexWrap:"wrap",[`.${D.hasPopupIcon}&, .${D.hasClearIcon}&`]:{paddingRight:26+4},[`.${D.hasPopupIcon}.${D.hasClearIcon}&`]:{paddingRight:52+4},[`& .${D.input}`]:{width:0,minWidth:30}},[`& .${Je.root}`]:{paddingBottom:1,"& .MuiInput-input":{padding:"4px 4px 4px 0px"}},[`& .${Je.root}.${Oe.sizeSmall}`]:{[`& .${Je.input}`]:{padding:"2px 4px 3px 0"}},[`& .${Ve.root}`]:{padding:9,[`.${D.hasPopupIcon}&, .${D.hasClearIcon}&`]:{paddingRight:26+4+9},[`.${D.hasPopupIcon}.${D.hasClearIcon}&`]:{paddingRight:52+4+9},[`& .${D.input}`]:{padding:"7.5px 4px 7.5px 5px"},[`& .${D.endAdornment}`]:{right:9}},[`& .${Ve.root}.${Oe.sizeSmall}`]:{paddingTop:6,paddingBottom:6,paddingLeft:6,[`& .${D.input}`]:{padding:"2.5px 4px 2.5px 8px"}},[`& .${Le.root}`]:{paddingTop:19,paddingLeft:8,[`.${D.hasPopupIcon}&, .${D.hasClearIcon}&`]:{paddingRight:26+4+9},[`.${D.hasPopupIcon}.${D.hasClearIcon}&`]:{paddingRight:52+4+9},[`& .${Le.input}`]:{padding:"7px 4px"},[`& .${D.endAdornment}`]:{right:9}},[`& .${Le.root}.${Oe.sizeSmall}`]:{paddingBottom:1,[`& .${Le.input}`]:{padding:"2.5px 4px"}},[`& .${Oe.hiddenLabel}`]:{paddingTop:8},[`& .${Le.root}.${Oe.hiddenLabel}`]:{paddingTop:0,paddingBottom:0,[`& .${D.input}`]:{paddingTop:16,paddingBottom:17}},[`& .${Le.root}.${Oe.hiddenLabel}.${Oe.sizeSmall}`]:{[`& .${D.input}`]:{paddingTop:8,paddingBottom:9}},[`& .${D.input}`]:a({flexGrow:1,textOverflow:"ellipsis",opacity:0},e.inputFocused&&{opacity:1})})),An=w("div",{name:"MuiAutocomplete",slot:"EndAdornment",overridesResolver:(e,o)=>o.endAdornment})({position:"absolute",right:0,top:"calc(50% - 14px)"}),Nn=w(pt,{name:"MuiAutocomplete",slot:"ClearIndicator",overridesResolver:(e,o)=>o.clearIndicator})({marginRight:-2,padding:4,visibility:"hidden"}),zn=w(pt,{name:"MuiAutocomplete",slot:"PopupIndicator",overridesResolver:({ownerState:e},o)=>a({},o.popupIndicator,e.popupOpen&&o.popupIndicatorOpen)})(({ownerState:e})=>a({padding:2,marginRight:-2},e.popupOpen&&{transform:"rotate(180deg)"})),Dn=w(No,{name:"MuiAutocomplete",slot:"Popper",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[{[`& .${D.option}`]:o.option},o.popper,t.disablePortal&&o.popperDisablePortal]}})(({theme:e,ownerState:o})=>a({zIndex:(e.vars||e).zIndex.modal},o.disablePortal&&{position:"absolute"})),En=w(ft,{name:"MuiAutocomplete",slot:"Paper",overridesResolver:(e,o)=>o.paper})(({theme:e})=>a({},e.typography.body1,{overflow:"auto"})),Bn=w("div",{name:"MuiAutocomplete",slot:"Loading",overridesResolver:(e,o)=>o.loading})(({theme:e})=>({color:(e.vars||e).palette.text.secondary,padding:"14px 16px"})),jn=w("div",{name:"MuiAutocomplete",slot:"NoOptions",overridesResolver:(e,o)=>o.noOptions})(({theme:e})=>({color:(e.vars||e).palette.text.secondary,padding:"14px 16px"})),Wn=w("div",{name:"MuiAutocomplete",slot:"Listbox",overridesResolver:(e,o)=>o.listbox})(({theme:e})=>({listStyle:"none",margin:0,padding:"8px 0",maxHeight:"40vh",overflow:"auto",position:"relative",[`& .${D.option}`]:{minHeight:48,display:"flex",overflow:"hidden",justifyContent:"flex-start",alignItems:"center",cursor:"pointer",paddingTop:6,boxSizing:"border-box",outline:"0",WebkitTapHighlightColor:"transparent",paddingBottom:6,paddingLeft:16,paddingRight:16,[e.breakpoints.up("sm")]:{minHeight:"auto"},[`&.${D.focused}`]:{backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},'&[aria-disabled="true"]':{opacity:(e.vars||e).palette.action.disabledOpacity,pointerEvents:"none"},[`&.${D.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},'&[aria-selected="true"]':{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:Re(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${D.focused}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:Re(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:(e.vars||e).palette.action.selected}},[`&.${D.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:Re(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}}}})),_n=w(nn,{name:"MuiAutocomplete",slot:"GroupLabel",overridesResolver:(e,o)=>o.groupLabel})(({theme:e})=>({backgroundColor:(e.vars||e).palette.background.paper,top:-8})),Un=w("ul",{name:"MuiAutocomplete",slot:"GroupUl",overridesResolver:(e,o)=>o.groupUl})({padding:0,[`& .${D.option}`]:{paddingLeft:24}}),Hn=u.forwardRef(function(o,t){var r,s,c,d;const i=Pe({props:o,name:"MuiAutocomplete"}),{autoComplete:b=!1,autoHighlight:p=!1,autoSelect:m=!1,blurOnSelect:h=!1,ChipProps:$,className:v,clearIcon:R=Xo||(Xo=f.jsx(Gt,{fontSize:"small"})),clearOnBlur:M=!i.freeSolo,clearOnEscape:P=!1,clearText:O="Clear",closeText:k="Close",componentsProps:C={},defaultValue:I=i.multiple?[]:null,disableClearable:E=!1,disableCloseOnSelect:N=!1,disabled:F=!1,disabledItemsFocusable:q=!1,disableListWrap:le=!1,disablePortal:de=!1,filterSelectedOptions:oe=!1,forcePopupIcon:T="auto",freeSolo:Q=!1,fullWidth:G=!1,getLimitTagsText:se=n=>`+${n}`,getOptionLabel:J,groupBy:re,handleHomeEndKeys:U=!i.freeSolo,includeInputInList:A=!1,limitTags:ie=-1,ListboxComponent:Se="ul",ListboxProps:we,loading:ue=!1,loadingText:W="Loading…",multiple:ee=!1,noOptionsText:fe="No options",openOnFocus:We=!1,openText:Z="Open",PaperComponent:be=ft,PopperComponent:Me=No,popupIcon:Y=Yo||(Yo=f.jsx(gt,{})),readOnly:H=!1,renderGroup:ze,renderInput:_e,renderOption:te,renderTags:S,selectOnFocus:to=!i.freeSolo,size:_="medium",slotProps:xe={}}=i,Fe=ae(i,Ln),{getRootProps:ce,getInputProps:Te,getInputLabelProps:me,getPopupIndicatorProps:Ae,getClearProps:Ye,getTagProps:De,getListboxProps:Ee,getOptionProps:z,value:j,dirty:he,expanded:Ke,id:qe,popupOpen:y,focused:B,focusedTag:X,anchorEl:ke,setAnchorEl:Ze,inputValue:Po,groupedOptions:Ne}=Qt(a({},i,{componentName:"Autocomplete"})),Ge=!E&&!F&&he&&!H,Ue=(!Q||T===!0)&&T!==!1,{onMouseDown:no}=Te(),{ref:eo}=we??{},go=Ee(),{ref:mo}=go,ho=ae(go,wn),ko=lo(mo,eo),ro=J||(n=>{var g;return(g=n.label)!=null?g:n}),Ce=a({},i,{disablePortal:de,expanded:Ke,focused:B,fullWidth:G,getOptionLabel:ro,hasClearIcon:Ge,hasPopupIcon:Ue,inputFocused:X===-1,popupOpen:y,size:_}),ve=Fn(Ce);let Be;if(ee&&j.length>0){const n=g=>a({className:ve.tag,disabled:F},De(g));S?Be=S(j,n,Ce):Be=j.map((g,x)=>f.jsx(fn,a({label:ro(g),size:_},n({index:x}),$)))}if(ie>-1&&Array.isArray(Be)){const n=Be.length-ie;!B&&n>0&&(Be=Be.splice(0,ie),Be.push(f.jsx("span",{className:ve.tag,children:se(n)},Be.length)))}const Ro=ze||(n=>f.jsxs("li",{children:[f.jsx(_n,{className:ve.groupLabel,ownerState:Ce,component:"div",children:n.group}),f.jsx(Un,{className:ve.groupUl,ownerState:Ce,children:n.children})]},n.key)),Lo=te||((n,g)=>{const{key:x}=n,K=ae(n,Mn);return f.jsx("li",a({},K,{children:ro(g)}),x)}),vo=(n,g)=>{const x=z({option:n,index:g});return Lo(a({},x,{className:ve.option}),n,{selected:x["aria-selected"],index:g,inputValue:Po},Ce)},co=(r=xe.clearIndicator)!=null?r:C.clearIndicator,oo=(s=xe.paper)!=null?s:C.paper,ao=(c=xe.popper)!=null?c:C.popper,l=(d=xe.popupIndicator)!=null?d:C.popupIndicator;return f.jsxs(u.Fragment,{children:[f.jsx(Tn,a({ref:t,className:ne(ve.root,v),ownerState:Ce},ce(Fe),{children:_e({id:qe,disabled:F,fullWidth:!0,size:_==="small"?"small":void 0,InputLabelProps:me(),InputProps:a({ref:Ze,className:ve.inputRoot,startAdornment:Be,onClick:n=>{n.target===n.currentTarget&&no(n)}},(Ge||Ue)&&{endAdornment:f.jsxs(An,{className:ve.endAdornment,ownerState:Ce,children:[Ge?f.jsx(Nn,a({},Ye(),{"aria-label":O,title:O,ownerState:Ce},co,{className:ne(ve.clearIndicator,co==null?void 0:co.className),children:R})):null,Ue?f.jsx(zn,a({},Ae(),{disabled:F,"aria-label":y?k:Z,title:y?k:Z,ownerState:Ce},l,{className:ne(ve.popupIndicator,l==null?void 0:l.className),children:Y})):null]})}),inputProps:a({className:ve.input,disabled:F,readOnly:H},Te())})})),ke?f.jsx(Dn,a({as:Me,disablePortal:de,style:{width:ke?ke.clientWidth:null},ownerState:Ce,role:"presentation",anchorEl:ke,open:y},ao,{className:ne(ve.popper,ao==null?void 0:ao.className),children:f.jsxs(En,a({ownerState:Ce,as:be},oo,{className:ne(ve.paper,oo==null?void 0:oo.className),children:[ue&&Ne.length===0?f.jsx(Bn,{className:ve.loading,ownerState:Ce,children:W}):null,Ne.length===0&&!Q&&!ue?f.jsx(jn,{className:ve.noOptions,ownerState:Ce,role:"presentation",onMouseDown:n=>{n.preventDefault()},children:fe}):null,Ne.length>0?f.jsx(Wn,a({as:Se,className:ve.listbox,ownerState:Ce},ho,we,{ref:ko,children:Ne.map((n,g)=>re?Ro({key:n.key,group:n.group,children:n.options.map((x,K)=>vo(x,n.index+K))}):vo(n,g))})):null]}))})):null]})}),Vn=Hn;function Kn(e){return ye("MuiCircularProgress",e)}$e("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const qn=["className","color","disableShrink","size","style","thickness","value","variant"];let So=e=>e,Zo,Qo,Jo,et;const Qe=44,Gn=ct(Zo||(Zo=So` + 0% { + transform: rotate(0deg); + } + + 100% { + transform: rotate(360deg); + } +`)),Xn=ct(Qo||(Qo=So` + 0% { + stroke-dasharray: 1px, 200px; + stroke-dashoffset: 0; + } + + 50% { + stroke-dasharray: 100px, 200px; + stroke-dashoffset: -15px; + } + + 100% { + stroke-dasharray: 100px, 200px; + stroke-dashoffset: -125px; + } +`)),Yn=e=>{const{classes:o,variant:t,color:r,disableShrink:s}=e,c={root:["root",t,`color${L(r)}`],svg:["svg"],circle:["circle",`circle${L(t)}`,s&&"circleDisableShrink"]};return Ie(c,Kn,o)},Zn=w("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.root,o[t.variant],o[`color${L(t.color)}`]]}})(({ownerState:e,theme:o})=>a({display:"inline-block"},e.variant==="determinate"&&{transition:o.transitions.create("transform")},e.color!=="inherit"&&{color:(o.vars||o).palette[e.color].main}),({ownerState:e})=>e.variant==="indeterminate"&&dt(Jo||(Jo=So` + animation: ${0} 1.4s linear infinite; + `),Gn)),Qn=w("svg",{name:"MuiCircularProgress",slot:"Svg",overridesResolver:(e,o)=>o.svg})({display:"block"}),Jn=w("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.circle,o[`circle${L(t.variant)}`],t.disableShrink&&o.circleDisableShrink]}})(({ownerState:e,theme:o})=>a({stroke:"currentColor"},e.variant==="determinate"&&{transition:o.transitions.create("stroke-dashoffset")},e.variant==="indeterminate"&&{strokeDasharray:"80px, 200px",strokeDashoffset:0}),({ownerState:e})=>e.variant==="indeterminate"&&!e.disableShrink&&dt(et||(et=So` + animation: ${0} 1.4s ease-in-out infinite; + `),Xn)),er=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiCircularProgress"}),{className:s,color:c="primary",disableShrink:d=!1,size:i=40,style:b,thickness:p=3.6,value:m=0,variant:h="indeterminate"}=r,$=ae(r,qn),v=a({},r,{color:c,disableShrink:d,size:i,thickness:p,value:m,variant:h}),R=Yn(v),M={},P={},O={};if(h==="determinate"){const k=2*Math.PI*((Qe-p)/2);M.strokeDasharray=k.toFixed(3),O["aria-valuenow"]=Math.round(m),M.strokeDashoffset=`${((100-m)/100*k).toFixed(3)}px`,P.transform="rotate(-90deg)"}return f.jsx(Zn,a({className:ne(R.root,s),style:a({width:i,height:i},P,b),ownerState:v,ref:t,role:"progressbar"},O,$,{children:f.jsx(Qn,{className:R.svg,ownerState:v,viewBox:`${Qe/2} ${Qe/2} ${Qe} ${Qe}`,children:f.jsx(Jn,{className:R.circle,style:M,ownerState:v,cx:Qe,cy:Qe,r:(Qe-p)/2,fill:"none",strokeWidth:p})})}))}),or=er,tr=["disableUnderline","components","componentsProps","fullWidth","hiddenLabel","inputComponent","multiline","slotProps","slots","type"],nr=e=>{const{classes:o,disableUnderline:t}=e,s=Ie({root:["root",!t&&"underline"],input:["input"]},Pn,o);return a({},o,s)},rr=w($o,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiFilledInput",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[...Co(e,o),!t.disableUnderline&&o.underline]}})(({theme:e,ownerState:o})=>{var t;const r=e.palette.mode==="light",s=r?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",c=r?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",d=r?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",i=r?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return a({position:"relative",backgroundColor:e.vars?e.vars.palette.FilledInput.bg:c,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:d,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:c}},[`&.${Le.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:c},[`&.${Le.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:i}},!o.disableUnderline&&{"&:after":{borderBottom:`2px solid ${(t=(e.vars||e).palette[o.color||"primary"])==null?void 0:t.main}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Le.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Le.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&:before":{borderBottom:`1px solid ${e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`:s}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Le.disabled}, .${Le.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${Le.disabled}:before`]:{borderBottomStyle:"dotted"}},o.startAdornment&&{paddingLeft:12},o.endAdornment&&{paddingRight:12},o.multiline&&a({padding:"25px 12px 8px"},o.size==="small"&&{paddingTop:21,paddingBottom:4},o.hiddenLabel&&{paddingTop:16,paddingBottom:17},o.hiddenLabel&&o.size==="small"&&{paddingTop:8,paddingBottom:9}))}),ar=w(Io,{name:"MuiFilledInput",slot:"Input",overridesResolver:yo})(({theme:e,ownerState:o})=>a({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12},!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}},e.vars&&{"&:-webkit-autofill":{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},o.size==="small"&&{paddingTop:21,paddingBottom:4},o.hiddenLabel&&{paddingTop:16,paddingBottom:17},o.startAdornment&&{paddingLeft:0},o.endAdornment&&{paddingRight:0},o.hiddenLabel&&o.size==="small"&&{paddingTop:8,paddingBottom:9},o.multiline&&{paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0})),mt=u.forwardRef(function(o,t){var r,s,c,d;const i=Pe({props:o,name:"MuiFilledInput"}),{components:b={},componentsProps:p,fullWidth:m=!1,inputComponent:h="input",multiline:$=!1,slotProps:v,slots:R={},type:M="text"}=i,P=ae(i,tr),O=a({},i,{fullWidth:m,inputComponent:h,multiline:$,type:M}),k=nr(i),C={root:{ownerState:O},input:{ownerState:O}},I=v??p?To(C,v??p):C,E=(r=(s=R.root)!=null?s:b.Root)!=null?r:rr,N=(c=(d=R.input)!=null?d:b.Input)!=null?c:ar;return f.jsx(Do,a({slots:{root:E,input:N},componentsProps:I,fullWidth:m,inputComponent:h,multiline:$,ref:t,type:M},P,{classes:k}))});mt.muiName="Input";const ht=mt;function lr(e){return ye("MuiFormHelperText",e)}const sr=$e("MuiFormHelperText",["root","error","disabled","sizeSmall","sizeMedium","contained","focused","filled","required"]),ot=sr;var tt;const ir=["children","className","component","disabled","error","filled","focused","margin","required","variant"],cr=e=>{const{classes:o,contained:t,size:r,disabled:s,error:c,filled:d,focused:i,required:b}=e,p={root:["root",s&&"disabled",c&&"error",r&&`size${L(r)}`,t&&"contained",i&&"focused",d&&"filled",b&&"required"]};return Ie(p,lr,o)},dr=w("p",{name:"MuiFormHelperText",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.root,t.size&&o[`size${L(t.size)}`],t.contained&&o.contained,t.filled&&o.filled]}})(({theme:e,ownerState:o})=>a({color:(e.vars||e).palette.text.secondary},e.typography.caption,{textAlign:"left",marginTop:3,marginRight:0,marginBottom:0,marginLeft:0,[`&.${ot.disabled}`]:{color:(e.vars||e).palette.text.disabled},[`&.${ot.error}`]:{color:(e.vars||e).palette.error.main}},o.size==="small"&&{marginTop:4},o.contained&&{marginLeft:14,marginRight:14})),ur=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiFormHelperText"}),{children:s,className:c,component:d="p"}=r,i=ae(r,ir),b=so(),p=io({props:r,muiFormControl:b,states:["variant","size","disabled","error","filled","focused","required"]}),m=a({},r,{component:d,contained:p.variant==="filled"||p.variant==="outlined",variant:p.variant,size:p.size,disabled:p.disabled,error:p.error,filled:p.filled,focused:p.focused,required:p.required}),h=cr(m);return f.jsx(dr,a({as:d,ownerState:m,className:ne(h.root,c),ref:t},i,{children:s===" "?tt||(tt=f.jsx("span",{className:"notranslate",children:"​"})):s}))}),pr=ur;function fr(e){return ye("MuiFormLabel",e)}const br=$e("MuiFormLabel",["root","colorSecondary","focused","disabled","error","filled","required","asterisk"]),bo=br,gr=["children","className","color","component","disabled","error","filled","focused","required"],mr=e=>{const{classes:o,color:t,focused:r,disabled:s,error:c,filled:d,required:i}=e,b={root:["root",`color${L(t)}`,s&&"disabled",c&&"error",d&&"filled",r&&"focused",i&&"required"],asterisk:["asterisk",c&&"error"]};return Ie(b,fr,o)},hr=w("label",{name:"MuiFormLabel",slot:"Root",overridesResolver:({ownerState:e},o)=>a({},o.root,e.color==="secondary"&&o.colorSecondary,e.filled&&o.filled)})(({theme:e,ownerState:o})=>a({color:(e.vars||e).palette.text.secondary},e.typography.body1,{lineHeight:"1.4375em",padding:0,position:"relative",[`&.${bo.focused}`]:{color:(e.vars||e).palette[o.color].main},[`&.${bo.disabled}`]:{color:(e.vars||e).palette.text.disabled},[`&.${bo.error}`]:{color:(e.vars||e).palette.error.main}})),vr=w("span",{name:"MuiFormLabel",slot:"Asterisk",overridesResolver:(e,o)=>o.asterisk})(({theme:e})=>({[`&.${bo.error}`]:{color:(e.vars||e).palette.error.main}})),xr=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiFormLabel"}),{children:s,className:c,component:d="label"}=r,i=ae(r,gr),b=so(),p=io({props:r,muiFormControl:b,states:["color","required","focused","disabled","error","filled"]}),m=a({},r,{color:p.color||"primary",component:d,disabled:p.disabled,error:p.error,filled:p.filled,focused:p.focused,required:p.required}),h=mr(m);return f.jsxs(hr,a({as:d,ownerState:m,className:ne(h.root,c),ref:t},i,{children:[s,p.required&&f.jsxs(vr,{ownerState:m,"aria-hidden":!0,className:h.asterisk,children:[" ","*"]})]}))}),Cr=xr,yr=["disableUnderline","components","componentsProps","fullWidth","inputComponent","multiline","slotProps","slots","type"],$r=e=>{const{classes:o,disableUnderline:t}=e,s=Ie({root:["root",!t&&"underline"],input:["input"]},yn,o);return a({},o,s)},Ir=w($o,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiInput",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[...Co(e,o),!t.disableUnderline&&o.underline]}})(({theme:e,ownerState:o})=>{let r=e.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(r=`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`),a({position:"relative"},o.formControl&&{"label + &":{marginTop:16}},!o.disableUnderline&&{"&:after":{borderBottom:`2px solid ${(e.vars||e).palette[o.color].main}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Je.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Je.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&:before":{borderBottom:`1px solid ${r}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Je.disabled}, .${Je.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${r}`}},[`&.${Je.disabled}:before`]:{borderBottomStyle:"dotted"}})}),Sr=w(Io,{name:"MuiInput",slot:"Input",overridesResolver:yo})({}),vt=u.forwardRef(function(o,t){var r,s,c,d;const i=Pe({props:o,name:"MuiInput"}),{disableUnderline:b,components:p={},componentsProps:m,fullWidth:h=!1,inputComponent:$="input",multiline:v=!1,slotProps:R,slots:M={},type:P="text"}=i,O=ae(i,yr),k=$r(i),I={root:{ownerState:{disableUnderline:b}}},E=R??m?To(R??m,I):I,N=(r=(s=M.root)!=null?s:p.Root)!=null?r:Ir,F=(c=(d=M.input)!=null?d:p.Input)!=null?c:Sr;return f.jsx(Do,a({slots:{root:N,input:F},slotProps:E,fullWidth:h,inputComponent:$,multiline:v,ref:t,type:P},O,{classes:k}))});vt.muiName="Input";const xt=vt;function Pr(e){return ye("MuiInputLabel",e)}$e("MuiInputLabel",["root","focused","disabled","error","required","asterisk","formControl","sizeSmall","shrink","animated","standard","filled","outlined"]);const kr=["disableAnimation","margin","shrink","variant","className"],Rr=e=>{const{classes:o,formControl:t,size:r,shrink:s,disableAnimation:c,variant:d,required:i}=e,b={root:["root",t&&"formControl",!c&&"animated",s&&"shrink",r&&r!=="normal"&&`size${L(r)}`,d],asterisk:[i&&"asterisk"]},p=Ie(b,Pr,o);return a({},o,p)},Or=w(Cr,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiInputLabel",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[{[`& .${bo.asterisk}`]:o.asterisk},o.root,t.formControl&&o.formControl,t.size==="small"&&o.sizeSmall,t.shrink&&o.shrink,!t.disableAnimation&&o.animated,t.focused&&o.focused,o[t.variant]]}})(({theme:e,ownerState:o})=>a({display:"block",transformOrigin:"top left",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:"100%"},o.formControl&&{position:"absolute",left:0,top:0,transform:"translate(0, 20px) scale(1)"},o.size==="small"&&{transform:"translate(0, 17px) scale(1)"},o.shrink&&{transform:"translate(0, -1.5px) scale(0.75)",transformOrigin:"top left",maxWidth:"133%"},!o.disableAnimation&&{transition:e.transitions.create(["color","transform","max-width"],{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut})},o.variant==="filled"&&a({zIndex:1,pointerEvents:"none",transform:"translate(12px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"},o.size==="small"&&{transform:"translate(12px, 13px) scale(1)"},o.shrink&&a({userSelect:"none",pointerEvents:"auto",transform:"translate(12px, 7px) scale(0.75)",maxWidth:"calc(133% - 24px)"},o.size==="small"&&{transform:"translate(12px, 4px) scale(0.75)"})),o.variant==="outlined"&&a({zIndex:1,pointerEvents:"none",transform:"translate(14px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"},o.size==="small"&&{transform:"translate(14px, 9px) scale(1)"},o.shrink&&{userSelect:"none",pointerEvents:"auto",maxWidth:"calc(133% - 32px)",transform:"translate(14px, -9px) scale(0.75)"}))),Lr=u.forwardRef(function(o,t){const r=Pe({name:"MuiInputLabel",props:o}),{disableAnimation:s=!1,shrink:c,className:d}=r,i=ae(r,kr),b=so();let p=c;typeof p>"u"&&b&&(p=b.filled||b.focused||b.adornedStart);const m=io({props:r,muiFormControl:b,states:["size","variant","required","focused"]}),h=a({},r,{disableAnimation:s,formControl:b,shrink:p,size:m.size,variant:m.variant,required:m.required,focused:m.focused}),$=Rr(h);return f.jsx(Or,a({"data-shrink":p,ownerState:h,ref:t,className:ne($.root,d)},i,{classes:$}))}),wr=Lr,Mr=u.createContext({}),Fr=Mr;function Tr(e){return ye("MuiList",e)}$e("MuiList",["root","padding","dense","subheader"]);const Ar=["children","className","component","dense","disablePadding","subheader"],Nr=e=>{const{classes:o,disablePadding:t,dense:r,subheader:s}=e;return Ie({root:["root",!t&&"padding",r&&"dense",s&&"subheader"]},Tr,o)},zr=w("ul",{name:"MuiList",slot:"Root",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.root,!t.disablePadding&&o.padding,t.dense&&o.dense,t.subheader&&o.subheader]}})(({ownerState:e})=>a({listStyle:"none",margin:0,padding:0,position:"relative"},!e.disablePadding&&{paddingTop:8,paddingBottom:8},e.subheader&&{paddingTop:0})),Dr=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiList"}),{children:s,className:c,component:d="ul",dense:i=!1,disablePadding:b=!1,subheader:p}=r,m=ae(r,Ar),h=u.useMemo(()=>({dense:i}),[i]),$=a({},r,{component:d,dense:i,disablePadding:b}),v=Nr($);return f.jsx(Fr.Provider,{value:h,children:f.jsxs(zr,a({as:d,className:ne(v.root,c),ref:t,ownerState:$},m,{children:[p,s]}))})}),Er=Dr,Br=["actions","autoFocus","autoFocusItem","children","className","disabledItemsFocusable","disableListWrap","onKeyDown","variant"];function Mo(e,o,t){return e===o?e.firstChild:o&&o.nextElementSibling?o.nextElementSibling:t?null:e.firstChild}function nt(e,o,t){return e===o?t?e.firstChild:e.lastChild:o&&o.previousElementSibling?o.previousElementSibling:t?null:e.lastChild}function Ct(e,o){if(o===void 0)return!0;let t=e.innerText;return t===void 0&&(t=e.textContent),t=t.trim().toLowerCase(),t.length===0?!1:o.repeating?t[0]===o.keys[0]:t.indexOf(o.keys.join(""))===0}function uo(e,o,t,r,s,c){let d=!1,i=s(e,o,o?t:!1);for(;i;){if(i===e.firstChild){if(d)return!1;d=!0}const b=r?!1:i.disabled||i.getAttribute("aria-disabled")==="true";if(!i.hasAttribute("tabindex")||!Ct(i,c)||b)i=s(e,i,t);else return i.focus(),!0}return!1}const jr=u.forwardRef(function(o,t){const{actions:r,autoFocus:s=!1,autoFocusItem:c=!1,children:d,className:i,disabledItemsFocusable:b=!1,disableListWrap:p=!1,onKeyDown:m,variant:h="selectedMenu"}=o,$=ae(o,Br),v=u.useRef(null),R=u.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});st(()=>{s&&v.current.focus()},[s]),u.useImperativeHandle(r,()=>({adjustStyleForScrollbar:(C,I)=>{const E=!v.current.style.width;if(C.clientHeight{const I=v.current,E=C.key,N=Fo(I).activeElement;if(E==="ArrowDown")C.preventDefault(),uo(I,N,p,b,Mo);else if(E==="ArrowUp")C.preventDefault(),uo(I,N,p,b,nt);else if(E==="Home")C.preventDefault(),uo(I,null,p,b,Mo);else if(E==="End")C.preventDefault(),uo(I,null,p,b,nt);else if(E.length===1){const F=R.current,q=E.toLowerCase(),le=performance.now();F.keys.length>0&&(le-F.lastTime>500?(F.keys=[],F.repeating=!0,F.previousKeyMatched=!0):F.repeating&&q!==F.keys[0]&&(F.repeating=!1)),F.lastTime=le,F.keys.push(q);const de=N&&!F.repeating&&Ct(N,F);F.previousKeyMatched&&(de||uo(I,N,!1,b,Mo,F))?C.preventDefault():F.previousKeyMatched=!1}m&&m(C)},P=lo(v,t);let O=-1;u.Children.forEach(d,(C,I)=>{if(!u.isValidElement(C)){O===I&&(O+=1,O>=d.length&&(O=-1));return}C.props.disabled||(h==="selectedMenu"&&C.props.selected||O===-1)&&(O=I),O===I&&(C.props.disabled||C.props.muiSkipListHighlight||C.type.muiSkipListHighlight)&&(O+=1,O>=d.length&&(O=-1))});const k=u.Children.map(d,(C,I)=>{if(I===O){const E={};return c&&(E.autoFocus=!0),C.props.tabIndex===void 0&&h==="selectedMenu"&&(E.tabIndex=0),u.cloneElement(C,E)}return C});return f.jsx(Er,a({role:"menu",ref:P,className:i,onKeyDown:M,tabIndex:s?0:-1},$,{children:k}))}),Wr=jr;function _r(e){return ye("MuiMenu",e)}$e("MuiMenu",["root","paper","list"]);const Ur=["onEntering"],Hr=["autoFocus","children","className","disableAutoFocusItem","MenuListProps","onClose","open","PaperProps","PopoverClasses","transitionDuration","TransitionProps","variant","slots","slotProps"],Vr={vertical:"top",horizontal:"right"},Kr={vertical:"top",horizontal:"left"},qr=e=>{const{classes:o}=e;return Ie({root:["root"],paper:["paper"],list:["list"]},_r,o)},Gr=w(jt,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiMenu",slot:"Root",overridesResolver:(e,o)=>o.root})({}),Xr=w(Wt,{name:"MuiMenu",slot:"Paper",overridesResolver:(e,o)=>o.paper})({maxHeight:"calc(100% - 96px)",WebkitOverflowScrolling:"touch"}),Yr=w(Wr,{name:"MuiMenu",slot:"List",overridesResolver:(e,o)=>o.list})({outline:0}),Zr=u.forwardRef(function(o,t){var r,s;const c=Pe({props:o,name:"MuiMenu"}),{autoFocus:d=!0,children:i,className:b,disableAutoFocusItem:p=!1,MenuListProps:m={},onClose:h,open:$,PaperProps:v={},PopoverClasses:R,transitionDuration:M="auto",TransitionProps:{onEntering:P}={},variant:O="selectedMenu",slots:k={},slotProps:C={}}=c,I=ae(c.TransitionProps,Ur),E=ae(c,Hr),N=Mt(),F=N.direction==="rtl",q=a({},c,{autoFocus:d,disableAutoFocusItem:p,MenuListProps:m,onEntering:P,PaperProps:v,transitionDuration:M,TransitionProps:I,variant:O}),le=qr(q),de=d&&!p&&$,oe=u.useRef(null),T=(A,ie)=>{oe.current&&oe.current.adjustStyleForScrollbar(A,N),P&&P(A,ie)},Q=A=>{A.key==="Tab"&&(A.preventDefault(),h&&h(A,"tabKeyDown"))};let G=-1;u.Children.map(i,(A,ie)=>{u.isValidElement(A)&&(A.props.disabled||(O==="selectedMenu"&&A.props.selected||G===-1)&&(G=ie))});const se=(r=k.paper)!=null?r:Xr,J=(s=C.paper)!=null?s:v,re=Vo({elementType:k.root,externalSlotProps:C.root,ownerState:q,className:[le.root,b]}),U=Vo({elementType:se,externalSlotProps:J,ownerState:q,className:le.paper});return f.jsx(Gr,a({onClose:h,anchorOrigin:{vertical:"bottom",horizontal:F?"right":"left"},transformOrigin:F?Vr:Kr,slots:{paper:se,root:k.root},slotProps:{root:re,paper:U},open:$,ref:t,transitionDuration:M,TransitionProps:a({onEntering:T},I),ownerState:q},E,{classes:R,children:f.jsx(Yr,a({onKeyDown:Q,actions:oe,autoFocus:d&&(G===-1||p),autoFocusItem:de,variant:O},m,{className:ne(le.list,m.className),children:i}))}))}),Qr=Zr;function Jr(e){return ye("MuiNativeSelect",e)}const ea=$e("MuiNativeSelect",["root","select","multiple","filled","outlined","standard","disabled","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]),Eo=ea,oa=["className","disabled","error","IconComponent","inputRef","variant"],ta=e=>{const{classes:o,variant:t,disabled:r,multiple:s,open:c,error:d}=e,i={select:["select",t,r&&"disabled",s&&"multiple",d&&"error"],icon:["icon",`icon${L(t)}`,c&&"iconOpen",r&&"disabled"]};return Ie(i,Jr,o)},yt=({ownerState:e,theme:o})=>a({MozAppearance:"none",WebkitAppearance:"none",userSelect:"none",borderRadius:0,cursor:"pointer","&:focus":a({},o.vars?{backgroundColor:`rgba(${o.vars.palette.common.onBackgroundChannel} / 0.05)`}:{backgroundColor:o.palette.mode==="light"?"rgba(0, 0, 0, 0.05)":"rgba(255, 255, 255, 0.05)"},{borderRadius:0}),"&::-ms-expand":{display:"none"},[`&.${Eo.disabled}`]:{cursor:"default"},"&[multiple]":{height:"auto"},"&:not([multiple]) option, &:not([multiple]) optgroup":{backgroundColor:(o.vars||o).palette.background.paper},"&&&":{paddingRight:24,minWidth:16}},e.variant==="filled"&&{"&&&":{paddingRight:32}},e.variant==="outlined"&&{borderRadius:(o.vars||o).shape.borderRadius,"&:focus":{borderRadius:(o.vars||o).shape.borderRadius},"&&&":{paddingRight:32}}),na=w("select",{name:"MuiNativeSelect",slot:"Select",shouldForwardProp:Xe,overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.select,o[t.variant],t.error&&o.error,{[`&.${Eo.multiple}`]:o.multiple}]}})(yt),$t=({ownerState:e,theme:o})=>a({position:"absolute",right:0,top:"calc(50% - .5em)",pointerEvents:"none",color:(o.vars||o).palette.action.active,[`&.${Eo.disabled}`]:{color:(o.vars||o).palette.action.disabled}},e.open&&{transform:"rotate(180deg)"},e.variant==="filled"&&{right:7},e.variant==="outlined"&&{right:7}),ra=w("svg",{name:"MuiNativeSelect",slot:"Icon",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.icon,t.variant&&o[`icon${L(t.variant)}`],t.open&&o.iconOpen]}})($t),aa=u.forwardRef(function(o,t){const{className:r,disabled:s,error:c,IconComponent:d,inputRef:i,variant:b="standard"}=o,p=ae(o,oa),m=a({},o,{disabled:s,variant:b,error:c}),h=ta(m);return f.jsxs(u.Fragment,{children:[f.jsx(na,a({ownerState:m,className:ne(h.select,r),disabled:s,ref:i||t},p)),o.multiple?null:f.jsx(ra,{as:d,ownerState:m,className:h.icon})]})}),la=aa;var rt;const sa=["children","classes","className","label","notched"],ia=w("fieldset",{shouldForwardProp:Xe})({textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%"}),ca=w("legend",{shouldForwardProp:Xe})(({ownerState:e,theme:o})=>a({float:"unset",width:"auto",overflow:"hidden"},!e.withLabel&&{padding:0,lineHeight:"11px",transition:o.transitions.create("width",{duration:150,easing:o.transitions.easing.easeOut})},e.withLabel&&a({display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:o.transitions.create("max-width",{duration:50,easing:o.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}},e.notched&&{maxWidth:"100%",transition:o.transitions.create("max-width",{duration:100,easing:o.transitions.easing.easeOut,delay:50})})));function da(e){const{className:o,label:t,notched:r}=e,s=ae(e,sa),c=t!=null&&t!=="",d=a({},e,{notched:r,withLabel:c});return f.jsx(ia,a({"aria-hidden":!0,className:o,ownerState:d},s,{children:f.jsx(ca,{ownerState:d,children:c?f.jsx("span",{children:t}):rt||(rt=f.jsx("span",{className:"notranslate",children:"​"}))})}))}const ua=["components","fullWidth","inputComponent","label","multiline","notched","slots","type"],pa=e=>{const{classes:o}=e,r=Ie({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},In,o);return a({},o,r)},fa=w($o,{shouldForwardProp:e=>Xe(e)||e==="classes",name:"MuiOutlinedInput",slot:"Root",overridesResolver:Co})(({theme:e,ownerState:o})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return a({position:"relative",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${Ve.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${Ve.notchedOutline}`]:{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}},[`&.${Ve.focused} .${Ve.notchedOutline}`]:{borderColor:(e.vars||e).palette[o.color].main,borderWidth:2},[`&.${Ve.error} .${Ve.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},[`&.${Ve.disabled} .${Ve.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled}},o.startAdornment&&{paddingLeft:14},o.endAdornment&&{paddingRight:14},o.multiline&&a({padding:"16.5px 14px"},o.size==="small"&&{padding:"8.5px 14px"}))}),ba=w(da,{name:"MuiOutlinedInput",slot:"NotchedOutline",overridesResolver:(e,o)=>o.notchedOutline})(({theme:e})=>{const o=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:o}}),ga=w(Io,{name:"MuiOutlinedInput",slot:"Input",overridesResolver:yo})(({theme:e,ownerState:o})=>a({padding:"16.5px 14px"},!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderRadius:"inherit"}},e.vars&&{"&:-webkit-autofill":{borderRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},o.size==="small"&&{padding:"8.5px 14px"},o.multiline&&{padding:0},o.startAdornment&&{paddingLeft:0},o.endAdornment&&{paddingRight:0})),It=u.forwardRef(function(o,t){var r,s,c,d,i;const b=Pe({props:o,name:"MuiOutlinedInput"}),{components:p={},fullWidth:m=!1,inputComponent:h="input",label:$,multiline:v=!1,notched:R,slots:M={},type:P="text"}=b,O=ae(b,ua),k=pa(b),C=so(),I=io({props:b,muiFormControl:C,states:["color","disabled","error","focused","hiddenLabel","size","required"]}),E=a({},b,{color:I.color||"primary",disabled:I.disabled,error:I.error,focused:I.focused,formControl:C,fullWidth:m,hiddenLabel:I.hiddenLabel,multiline:v,size:I.size,type:P}),N=(r=(s=M.root)!=null?s:p.Root)!=null?r:fa,F=(c=(d=M.input)!=null?d:p.Input)!=null?c:ga;return f.jsx(Do,a({slots:{root:N,input:F},renderSuffix:q=>f.jsx(ba,{ownerState:E,className:k.notchedOutline,label:$!=null&&$!==""&&I.required?i||(i=f.jsxs(u.Fragment,{children:[$," ","*"]})):$,notched:typeof R<"u"?R:!!(q.startAdornment||q.filled||q.focused)}),fullWidth:m,inputComponent:h,multiline:v,ref:t,type:P},O,{classes:a({},k,{notchedOutline:null})}))});It.muiName="Input";const St=It;function ma(e){return ye("MuiSelect",e)}const ha=$e("MuiSelect",["root","select","multiple","filled","outlined","standard","disabled","focused","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]),po=ha;var at;const va=["aria-describedby","aria-label","autoFocus","autoWidth","children","className","defaultOpen","defaultValue","disabled","displayEmpty","error","IconComponent","inputRef","labelId","MenuProps","multiple","name","onBlur","onChange","onClose","onFocus","onOpen","open","readOnly","renderValue","SelectDisplayProps","tabIndex","type","value","variant"],xa=w("div",{name:"MuiSelect",slot:"Select",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[{[`&.${po.select}`]:o.select},{[`&.${po.select}`]:o[t.variant]},{[`&.${po.error}`]:o.error},{[`&.${po.multiple}`]:o.multiple}]}})(yt,{[`&.${po.select}`]:{height:"auto",minHeight:"1.4375em",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}}),Ca=w("svg",{name:"MuiSelect",slot:"Icon",overridesResolver:(e,o)=>{const{ownerState:t}=e;return[o.icon,t.variant&&o[`icon${L(t.variant)}`],t.open&&o.iconOpen]}})($t),ya=w("input",{shouldForwardProp:e=>Ft(e)&&e!=="classes",name:"MuiSelect",slot:"NativeInput",overridesResolver:(e,o)=>o.nativeInput})({bottom:0,left:0,position:"absolute",opacity:0,pointerEvents:"none",width:"100%",boxSizing:"border-box"});function lt(e,o){return typeof o=="object"&&o!==null?e===o:String(e)===String(o)}function $a(e){return e==null||typeof e=="string"&&!e.trim()}const Ia=e=>{const{classes:o,variant:t,disabled:r,multiple:s,open:c,error:d}=e,i={select:["select",t,r&&"disabled",s&&"multiple",d&&"error"],icon:["icon",`icon${L(t)}`,c&&"iconOpen",r&&"disabled"],nativeInput:["nativeInput"]};return Ie(i,ma,o)},Sa=u.forwardRef(function(o,t){var r;const{"aria-describedby":s,"aria-label":c,autoFocus:d,autoWidth:i,children:b,className:p,defaultOpen:m,defaultValue:h,disabled:$,displayEmpty:v,error:R=!1,IconComponent:M,inputRef:P,labelId:O,MenuProps:k={},multiple:C,name:I,onBlur:E,onChange:N,onClose:F,onFocus:q,onOpen:le,open:de,readOnly:oe,renderValue:T,SelectDisplayProps:Q={},tabIndex:G,value:se,variant:J="standard"}=o,re=ae(o,va),[U,A]=fo({controlled:se,default:h,name:"Select"}),[ie,Se]=fo({controlled:de,default:m,name:"Select"}),we=u.useRef(null),ue=u.useRef(null),[W,ee]=u.useState(null),{current:fe}=u.useRef(de!=null),[We,Z]=u.useState(),be=lo(t,P),Me=u.useCallback(y=>{ue.current=y,y&&ee(y)},[]),Y=W==null?void 0:W.parentNode;u.useImperativeHandle(be,()=>({focus:()=>{ue.current.focus()},node:we.current,value:U}),[U]),u.useEffect(()=>{m&&ie&&W&&!fe&&(Z(i?null:Y.clientWidth),ue.current.focus())},[W,i]),u.useEffect(()=>{d&&ue.current.focus()},[d]),u.useEffect(()=>{if(!O)return;const y=Fo(ue.current).getElementById(O);if(y){const B=()=>{getSelection().isCollapsed&&ue.current.focus()};return y.addEventListener("click",B),()=>{y.removeEventListener("click",B)}}},[O]);const H=(y,B)=>{y?le&&le(B):F&&F(B),fe||(Z(i?null:Y.clientWidth),Se(y))},ze=y=>{y.button===0&&(y.preventDefault(),ue.current.focus(),H(!0,y))},_e=y=>{H(!1,y)},te=u.Children.toArray(b),S=y=>{const B=te.find(X=>X.props.value===y.target.value);B!==void 0&&(A(B.props.value),N&&N(y,B))},to=y=>B=>{let X;if(B.currentTarget.hasAttribute("tabindex")){if(C){X=Array.isArray(U)?U.slice():[];const ke=U.indexOf(y.props.value);ke===-1?X.push(y.props.value):X.splice(ke,1)}else X=y.props.value;if(y.props.onClick&&y.props.onClick(B),U!==X&&(A(X),N)){const ke=B.nativeEvent||B,Ze=new ke.constructor(ke.type,ke);Object.defineProperty(Ze,"target",{writable:!0,value:{value:X,name:I}}),N(Ze,y)}C||H(!1,B)}},_=y=>{oe||[" ","ArrowUp","ArrowDown","Enter"].indexOf(y.key)!==-1&&(y.preventDefault(),H(!0,y))},xe=W!==null&&ie,Fe=y=>{!xe&&E&&(Object.defineProperty(y,"target",{writable:!0,value:{value:U,name:I}}),E(y))};delete re["aria-invalid"];let ce,Te;const me=[];let Ae=!1;(ut({value:U})||v)&&(T?ce=T(U):Ae=!0);const Ye=te.map(y=>{if(!u.isValidElement(y))return null;let B;if(C){if(!Array.isArray(U))throw new Error(it(2));B=U.some(X=>lt(X,y.props.value)),B&&Ae&&me.push(y.props.children)}else B=lt(U,y.props.value),B&&Ae&&(Te=y.props.children);return u.cloneElement(y,{"aria-selected":B?"true":"false",onClick:to(y),onKeyUp:X=>{X.key===" "&&X.preventDefault(),y.props.onKeyUp&&y.props.onKeyUp(X)},role:"option",selected:B,value:void 0,"data-value":y.props.value})});Ae&&(C?me.length===0?ce=null:ce=me.reduce((y,B,X)=>(y.push(B),X{const{classes:o}=e;return o},Bo={name:"MuiSelect",overridesResolver:(e,o)=>o.root,shouldForwardProp:e=>Xe(e)&&e!=="variant",slot:"Root"},La=w(xt,Bo)(""),wa=w(St,Bo)(""),Ma=w(ht,Bo)(""),Pt=u.forwardRef(function(o,t){const r=Pe({name:"MuiSelect",props:o}),{autoWidth:s=!1,children:c,classes:d={},className:i,defaultOpen:b=!1,displayEmpty:p=!1,IconComponent:m=gt,id:h,input:$,inputProps:v,label:R,labelId:M,MenuProps:P,multiple:O=!1,native:k=!1,onClose:C,onOpen:I,open:E,renderValue:N,SelectDisplayProps:F,variant:q="outlined"}=r,le=ae(r,ka),de=k?la:Pa,oe=so(),T=io({props:r,muiFormControl:oe,states:["variant","error"]}),Q=T.variant||q,G=a({},r,{variant:Q,classes:d}),se=Oa(G),J=ae(se,Ra),re=$||{standard:f.jsx(La,{ownerState:G}),outlined:f.jsx(wa,{label:R,ownerState:G}),filled:f.jsx(Ma,{ownerState:G})}[Q],U=lo(t,re.ref);return f.jsx(u.Fragment,{children:u.cloneElement(re,a({inputComponent:de,inputProps:a({children:c,error:T.error,IconComponent:m,variant:Q,type:void 0,multiple:O},k?{id:h}:{autoWidth:s,defaultOpen:b,displayEmpty:p,labelId:M,MenuProps:P,onClose:C,onOpen:I,open:E,renderValue:N,SelectDisplayProps:a({id:h},F)},v,{classes:v?To(J,v.classes):J},$?$.props.inputProps:{})},O&&k&&Q==="outlined"?{notched:!0}:{},{ref:U,className:ne(re.props.className,i,se.root)},!$&&{variant:Q},le))})});Pt.muiName="Select";const Fa=Pt;function Ta(e){return ye("MuiTextField",e)}$e("MuiTextField",["root"]);const Aa=["autoComplete","autoFocus","children","className","color","defaultValue","disabled","error","FormHelperTextProps","fullWidth","helperText","id","InputLabelProps","inputProps","InputProps","inputRef","label","maxRows","minRows","multiline","name","onBlur","onChange","onFocus","placeholder","required","rows","select","SelectProps","type","value","variant"],Na={standard:xt,filled:ht,outlined:St},za=e=>{const{classes:o}=e;return Ie({root:["root"]},Ta,o)},Da=w(Dt,{name:"MuiTextField",slot:"Root",overridesResolver:(e,o)=>o.root})({}),Ea=u.forwardRef(function(o,t){const r=Pe({props:o,name:"MuiTextField"}),{autoComplete:s,autoFocus:c=!1,children:d,className:i,color:b="primary",defaultValue:p,disabled:m=!1,error:h=!1,FormHelperTextProps:$,fullWidth:v=!1,helperText:R,id:M,InputLabelProps:P,inputProps:O,InputProps:k,inputRef:C,label:I,maxRows:E,minRows:N,multiline:F=!1,name:q,onBlur:le,onChange:de,onFocus:oe,placeholder:T,required:Q=!1,rows:G,select:se=!1,SelectProps:J,type:re,value:U,variant:A="outlined"}=r,ie=ae(r,Aa),Se=a({},r,{autoFocus:c,color:b,disabled:m,error:h,fullWidth:v,multiline:F,required:Q,select:se,variant:A}),we=za(Se),ue={};A==="outlined"&&(P&&typeof P.shrink<"u"&&(ue.notched=P.shrink),ue.label=I),se&&((!J||!J.native)&&(ue.id=void 0),ue["aria-describedby"]=void 0);const W=Ao(M),ee=R&&W?`${W}-helper-text`:void 0,fe=I&&W?`${W}-label`:void 0,We=Na[A],Z=f.jsx(We,a({"aria-describedby":ee,autoComplete:s,autoFocus:c,defaultValue:p,fullWidth:v,multiline:F,name:q,rows:G,maxRows:E,minRows:N,type:re,value:U,id:W,inputRef:C,onBlur:le,onChange:de,onFocus:oe,placeholder:T,inputProps:O},ue,k));return f.jsxs(Da,a({className:ne(we.root,i),disabled:m,error:h,fullWidth:v,ref:t,required:Q,color:b,variant:A,ownerState:Se},ie,{children:[I!=null&&I!==""&&f.jsx(wr,a({htmlFor:W,id:fe},P,{children:I})),se?f.jsx(Fa,a({"aria-describedby":ee,id:W,labelId:fe,value:U,input:Z},J,{children:d})):Z,R&&f.jsx(pr,a({id:ee},$,{children:R}))]}))}),Ba=Ea,ja={options:[],getOptionLabel:e=>e.label,handleInputChange:e=>e},Ga=({options:e,onSelect:o,selectedValue:t=null,handleInputChange:r,isLoading:s=!1,autoFocus:c=!1,disabled:d=!1,dataTestId:i,dataId:b,placeholder:p,className:m})=>{const h=u.useRef(null),[$,v]=u.useState(!1);u.useEffect(()=>{c&&h.current&&(h.current.focus(),v(!0))},[c]);const R=(M,P)=>{o(P)};return f.jsx(Et,{flexGrow:1,spacing:1,children:f.jsx(Vn,{...ja,autoFocus:!0,autoHighlight:!0,blurOnSelect:!0,className:m,"data-testid":b,disableClearable:!0,disabled:d,disablePortal:!0,id:"blur-on-select",ListboxProps:{sx:{backgroundColor:je.DROPDOWN_BG,"&::-webkit-scrollbar":{width:"3px"},"&::-webkit-scrollbar-thumb":{backgroundClip:"padding-box",backgroundColor:je.SCROLL_BAR,borderRadius:"6px"}},ref:h},loading:s,onChange:R,onClose:()=>v(!1),onInputChange:(M,P)=>r==null?void 0:r(P),onOpen:()=>v(!0),open:$,options:e??[],PopperComponent:({children:M,...P})=>f.jsx(No,{...P,placement:"bottom-start",children:M}),renderInput:M=>f.jsx(Wa,{inputRef:h,...M,"data-testid":i,InputProps:{...M.InputProps,disableUnderline:!0,endAdornment:f.jsx(f.Fragment,{children:s?f.jsx(or,{color:"inherit",size:20}):M.InputProps.endAdornment})},placeholder:p,size:"medium",variant:"standard"}),renderOption:(M,P)=>f.jsx("li",{...M,children:f.jsxs(At,{align:"center","data-testid":P.label,direction:"row",grow:1,justify:"space-between",onClick:P==null?void 0:P.action,shrink:1,style:{fontSize:"14px",wordBreak:"break-word"},children:[f.jsx("div",{className:"option",children:P.label!==""?P.label:"Not Selected"}),(P==null?void 0:P.type)&&f.jsx(Nt,{type:P.type})]})}),sx:{"&.MuiAutocomplete-option:hover":{backgroundColor:je.DROPDOWN_HOVER},"&.MuiAutocomplete-option[aria-selected='true']":{backgroundColor:je.DROPDOWN_SELECTED}},value:t||void 0})})},Wa=Tt(Ba)` + && { + z-index: 2; + width: 100%; + color: #fff; + font-size: 15px; + box-shadow: none; + border-radius: 6px; + pointer-events: auto; + background-color: ${je.BG2}; + box-shadow: 0px 1px 6px rgba(0, 0, 0, 0.1); + padding: 0 8px; + + &:focus, + &:active { + color: ${je.white}; + background-color: ${je.BG2_ACTIVE_INPUT}; + outline: 1px solid ${je.primaryBlue}; + } + + &:hover { + background-color: ${je.BG2_ACTIVE_INPUT}; + box-shadow: 0 0 0 1px ${je.primaryBlue}; + } + + &::placeholder { + font-size: 15px; + text-align: left; + font-weight: 500; + line-height: 16px; + letter-spacing: 0em; + font-family: Barlow; + color: ${je.GRAY7}; + } + + .MuiInput-input.MuiInputBase-input { + padding: 8px; + } + + .MuiInput-root { + padding: 0; + } + } +`;export{Ga as A,Do as I,Ba as T}; diff --git a/build/assets/index-39d7c317.js b/build/assets/index-f0bb1f56.js similarity index 86% rename from build/assets/index-39d7c317.js rename to build/assets/index-f0bb1f56.js index 18c8caf13..2943af0d5 100644 --- a/build/assets/index-39d7c317.js +++ b/build/assets/index-f0bb1f56.js @@ -1,4 +1,4 @@ -import{ag as Q,s as g,a as b,F as t,T,b as V,r as y,j as e,B as C,a_ as ee,b8 as te,ao as se,aY as L,aZ as F,bd as B,be as ne,q as oe,bf as re,bg as ie,bh as ae,e as O,t as ce,u as le,aW as de,aX as I,a$ as pe,v as xe,ai as me,ah as ue,bb as he}from"./index-4bb27744.js";import{a8 as fe,f as ye}from"./index-7730ff6f.js";import{f as ge}from"./index-5ca84596.js";import{C as W}from"./ClipLoader-1ef5878d.js";import{p as q}from"./index-5fe8c70d.js";import{A as je}from"./index-22c3582f.js";import{c as we}from"./index-64f1c910.js";import"./three.module-71ec604c.js";import"./index-5111ebdb.js";import"./Stack-6038813c.js";import"./createSvgIcon-41051178.js";import"./TextareaAutosize-b716e8d1.js";const be=async(o,a,c="")=>await Q.post(`/${o}`,JSON.stringify(a),{Authorization:c}),Se=async(o,a,c,m,d,r)=>{const x=o==="Create custom type"?"schema":"node",l={node_data:{...a,...o==="Image"&&{source_link:c}},node_type:o,name:m,pubkey:r};return be(x,l,d)},Ne=({onClick:o,loading:a,error:c})=>{const m=V(l=>l.budget),[d,r]=y.useState(10),x="node";return y.useEffect(()=>{(async()=>{try{const h=await te(x);r(h.data.price)}catch(h){console.error("cannot fetch",h)}})()},[x]),e.jsxs(t,{children:[e.jsx(t,{align:"center",direction:"row",justify:"space-between",mb:20,children:e.jsx(t,{align:"center",direction:"row",children:e.jsx(ke,{children:"Approve Cost"})})}),e.jsxs(t,{align:"center",direction:"row",justify:"space-between",mb:20,children:[e.jsxs(Te,{children:[e.jsx("div",{className:"title",children:"COST"}),e.jsxs("div",{className:"value","data-testid":"check-price",children:[d," sats"]})]}),e.jsxs(Ce,{children:[e.jsx("div",{className:"title",children:"BUDGET"}),e.jsxs("div",{className:"value",children:[ge(m)," sats"]})]})]}),e.jsx(t,{children:e.jsx(C,{color:"secondary","data-testid":"check-icon",disabled:a||!!c,onClick:o,size:"large",startIcon:a?e.jsx(R,{children:e.jsx(W,{color:b.lightGray,size:12})}):e.jsxs(R,{children:[" ",e.jsx(fe,{})]}),type:"submit",variant:"contained",children:"Approve"})}),c?e.jsx(ze,{children:e.jsxs(ve,{children:[e.jsx(ee,{className:"errorIcon"}),e.jsx("span",{children:c})]})}):null]})},Te=g(t).attrs({direction:"column",align:"space-between",justify:"flex-start"})` +import{af as Q,s as g,a as b,F as t,T,b as V,r as y,j as e,B as C,aZ as ee,b7 as te,an as se,aX as L,aY as F,bc as B,bd as ne,q as oe,be as re,bf as ie,bg as ae,e as O,t as ce,u as le,aV as de,aW as I,a_ as pe,v as xe,ah as me,ag as ue,ba as he}from"./index-4e60c9e2.js";import{a8 as fe,f as ye}from"./index-af5a3f81.js";import{f as ge}from"./index-763b7c2d.js";import{C as W}from"./ClipLoader-8590c2f1.js";import{p as q}from"./index-5fe8c70d.js";import{A as je}from"./index-d96216bb.js";import{c as we}from"./index-64f1c910.js";import"./three.module-71ec604c.js";import"./index-569670a3.js";import"./Stack-5870980a.js";import"./createSvgIcon-c125a9c8.js";import"./TextareaAutosize-f6242cb8.js";const be=async(o,a,c="")=>await Q.post(`/${o}`,JSON.stringify(a),{Authorization:c}),Se=async(o,a,c,m,d,r)=>{const x=o==="Create custom type"?"schema":"node",l={node_data:{...a,...o==="Image"&&{source_link:c}},node_type:o,name:m,pubkey:r};return be(x,l,d)},Ne=({onClick:o,loading:a,error:c})=>{const m=V(l=>l.budget),[d,r]=y.useState(10),x="node";return y.useEffect(()=>{(async()=>{try{const h=await te(x);r(h.data.price)}catch(h){console.error("cannot fetch",h)}})()},[x]),e.jsxs(t,{children:[e.jsx(t,{align:"center",direction:"row",justify:"space-between",mb:20,children:e.jsx(t,{align:"center",direction:"row",children:e.jsx(ke,{children:"Approve Cost"})})}),e.jsxs(t,{align:"center",direction:"row",justify:"space-between",mb:20,children:[e.jsxs(Te,{children:[e.jsx("div",{className:"title",children:"COST"}),e.jsxs("div",{className:"value","data-testid":"check-price",children:[d," sats"]})]}),e.jsxs(Ce,{children:[e.jsx("div",{className:"title",children:"BUDGET"}),e.jsxs("div",{className:"value",children:[ge(m)," sats"]})]})]}),e.jsx(t,{children:e.jsx(C,{color:"secondary","data-testid":"check-icon",disabled:a||!!c,onClick:o,size:"large",startIcon:a?e.jsx(R,{children:e.jsx(W,{color:b.lightGray,size:12})}):e.jsxs(R,{children:[" ",e.jsx(fe,{})]}),type:"submit",variant:"contained",children:"Approve"})}),c?e.jsx(ze,{children:e.jsxs(ve,{children:[e.jsx(ee,{className:"errorIcon"}),e.jsx("span",{children:c})]})}):null]})},Te=g(t).attrs({direction:"column",align:"space-between",justify:"flex-start"})` width: 141px; height: 61px; border: 1px solid ${b.GRAY7}; @@ -116,8 +116,8 @@ import{ag as Q,s as g,a as b,F as t,T,b as V,r as y,j as e,B as C,a_ as ee,b8 as font-size: 22px; font-weight: 600; font-family: 'Barlow'; -`,$e=({skipToStep:o,allowNextStep:a,onSelectType:c,selectedType:m})=>{const[d]=oe(f=>[f.customSchemaFeatureFlag]),[r,x]=y.useState(null),[l,h]=y.useState(!1);y.useEffect(()=>{(async()=>{if(d){h(!0);try{const n=await re(),j=["about","schema"],p=n.schemas.filter(s=>s.ref_id&&!j.includes(s.type)&&!s.is_deleted).map(s=>({label:we(s.type),value:s.type}));x(p)}catch(n){console.warn(n)}finally{h(!1)}}else x([...ie,ae])})()},[m,d,o]);const w=f=>{c((f==null?void 0:f.label)||""),o("setAttribues")};return e.jsxs(t,{children:[e.jsx(t,{align:"center",direction:"row",justify:"space-between",mb:20,children:e.jsx(t,{align:"center",direction:"row",children:e.jsx(Me,{children:"Select Type"})})}),e.jsx(t,{direction:"row",mb:20,children:e.jsx(je,{autoFocus:!0,isLoading:l,onSelect:w,options:r})}),e.jsx(t,{children:e.jsx(C,{color:"secondary",disabled:!a,onClick:()=>o("source"),size:"large",type:"button",variant:"contained",children:"Next"})})]})},Me=g(T)` +`,Me=({skipToStep:o,allowNextStep:a,onSelectType:c,selectedType:m})=>{const[d]=oe(f=>[f.customSchemaFeatureFlag]),[r,x]=y.useState(null),[l,h]=y.useState(!1);y.useEffect(()=>{(async()=>{if(d){h(!0);try{const n=await re(),j=["about","schema"],p=n.schemas.filter(s=>s.ref_id&&!j.includes(s.type)&&!s.is_deleted).map(s=>({label:we(s.type),value:s.type}));x(p)}catch(n){console.warn(n)}finally{h(!1)}}else x([...ie,ae])})()},[m,d,o]);const w=f=>{c((f==null?void 0:f.label)||""),o("setAttribues")};return e.jsxs(t,{children:[e.jsx(t,{align:"center",direction:"row",justify:"space-between",mb:20,children:e.jsx(t,{align:"center",direction:"row",children:e.jsx(Pe,{children:"Select Type"})})}),e.jsx(t,{direction:"row",mb:20,children:e.jsx(je,{autoFocus:!0,isLoading:l,onSelect:w,options:r})}),e.jsx(t,{children:e.jsx(C,{color:"secondary",disabled:!a,onClick:()=>o("source"),size:"large",type:"button",variant:"contained",children:"Next"})})]})},Pe=g(T)` font-size: 22px; font-weight: 600; font-family: 'Barlow'; -`,Pe=async(o,a,c)=>{var f;const m=Object.entries(o).reduce((n,[j,p])=>(p!=null&&p!==""&&(n[j]=p),n),{}),{nodeType:d,typeName:r,sourceLink:x,...l}=m;let h="",w="";d!=="Create custom type"&&await me(async()=>{const n=await ue.enable();w=n==null?void 0:n.pubkey,h=await he()});try{const n=await Se(d,l,x,r,h,w);c(o,(f=n==null?void 0:n.data)==null?void 0:f.ref_id)}catch(n){let j=I;if(n.status===400){const p=await n.json();j=p.message||p.errorCode||(p==null?void 0:p.status)||I}else n instanceof Error&&(j=n.message);throw new Error(j)}},Xe=()=>{const[o,a]=y.useState("sourceType"),{close:c,visible:m}=O("addItem"),{open:d}=O("addType"),{setBudget:r}=V(i=>i),x=ce({mode:"onChange"}),{watch:l,setValue:h,reset:w}=x,[f,n]=y.useState(!1),[j,p]=y.useState(""),{addNewNode:s}=le(i=>i),[u]=ye(i=>[i.setSelectedNode]);y.useEffect(()=>()=>{a("sourceType"),w()},[m,w]);const S=l("nodeType"),_=l("typeName"),A=l("sourceLink"),Y=l("type");l("title");const $=()=>{c()},E=i=>{p(""),a(i)},U=(i,N)=>{const v=N||`new-id-${Math.random()}`,k=i.nodeType.toLocaleLowerCase(),X=Object.entries(i).reduce((D,[Z,z])=>(z!=null&&z!==""&&(D[Z]=z),D),{}),P={name:i.typeName??i.name,type:k,label:i.typeName??i.name,node_type:k,id:v,edge_count:0,ref_id:v,x:Math.random(),y:Math.random(),z:Math.random(),date:parseInt((new Date().getTime()/1e3).toFixed(0),10),weight:4,...i.source_link?{source_link:i.source_link}:{},properties:{...X}};s({nodes:[P],edges:[]}),u(P)},J=x.handleSubmit(async i=>{p(""),n(!0);try{await Pe(i,r,U),de("Item Added"),$()}catch(N){let v=I;if((N==null?void 0:N.status)===400){const k=await N.json();v=k.errorCode||(k==null?void 0:k.status)||I}else N instanceof Error&&(v=N.message);p(String(v))}finally{n(!1)}}),M=i=>{i==="Create custom type"?d():h("nodeType",i)},H={sourceType:e.jsx($e,{allowNextStep:!!S,onSelectType:M,selectedType:S,skipToStep:E}),source:e.jsx(Le,{name:_,skipToStep:E,sourceLink:A||"",type:S}),setBudget:e.jsx(Ne,{error:j,loading:f,onClick:()=>null}),createConfirmation:e.jsx(Be,{onclose:$,type:Y}),setAttribues:e.jsx(Ie,{handleSelectType:M,nodeType:S,skipToStep:E})},K="small";return e.jsx(pe,{id:"addItem",kind:K,onClose:c,preventOutsideClose:!0,children:e.jsx(xe,{...x,children:e.jsx("form",{id:"add-node-form",onSubmit:J,children:H[o]})})})};export{Xe as AddItemModal}; +`,$e=async(o,a,c)=>{var f;const m=Object.entries(o).reduce((n,[j,p])=>(p!=null&&p!==""&&(n[j]=p),n),{}),{nodeType:d,typeName:r,sourceLink:x,...l}=m;let h="",w="";d!=="Create custom type"&&await me(async()=>{const n=await ue.enable();w=n==null?void 0:n.pubkey,h=await he()});try{const n=await Se(d,l,x,r,h,w);c(o,(f=n==null?void 0:n.data)==null?void 0:f.ref_id)}catch(n){let j=I;if(n.status===400){const p=await n.json();j=p.message||p.errorCode||(p==null?void 0:p.status)||I}else n instanceof Error&&(j=n.message);throw new Error(j)}},Xe=()=>{const[o,a]=y.useState("sourceType"),{close:c,visible:m}=O("addItem"),{open:d}=O("addType"),{setBudget:r}=V(i=>i),x=ce({mode:"onChange"}),{watch:l,setValue:h,reset:w}=x,[f,n]=y.useState(!1),[j,p]=y.useState(""),{addNewNode:s}=le(i=>i),[u]=ye(i=>[i.setSelectedNode]);y.useEffect(()=>()=>{a("sourceType"),w()},[m,w]);const S=l("nodeType"),_=l("typeName"),A=l("sourceLink"),Y=l("type");l("title");const M=()=>{c()},E=i=>{p(""),a(i)},U=(i,N)=>{const v=N||`new-id-${Math.random()}`,k=i.nodeType.toLocaleLowerCase(),X=Object.entries(i).reduce((D,[Z,z])=>(z!=null&&z!==""&&(D[Z]=z),D),{}),$={name:i.typeName??i.name,type:k,label:i.typeName??i.name,node_type:k,id:v,edge_count:0,ref_id:v,x:Math.random(),y:Math.random(),z:Math.random(),date:parseInt((new Date().getTime()/1e3).toFixed(0),10),weight:4,...i.source_link?{source_link:i.source_link}:{},properties:{...X}};s({nodes:[$],edges:[]}),u($)},J=x.handleSubmit(async i=>{p(""),n(!0);try{await $e(i,r,U),de("Item Added"),M()}catch(N){let v=I;if((N==null?void 0:N.status)===400){const k=await N.json();v=k.errorCode||(k==null?void 0:k.status)||I}else N instanceof Error&&(v=N.message);p(String(v))}finally{n(!1)}}),P=i=>{i==="Create custom type"?d():h("nodeType",i)},H={sourceType:e.jsx(Me,{allowNextStep:!!S,onSelectType:P,selectedType:S,skipToStep:E}),source:e.jsx(Le,{name:_,skipToStep:E,sourceLink:A||"",type:S}),setBudget:e.jsx(Ne,{error:j,loading:f,onClick:()=>null}),createConfirmation:e.jsx(Be,{onclose:M,type:Y}),setAttribues:e.jsx(Ie,{handleSelectType:P,nodeType:S,skipToStep:E})},K="small";return e.jsx(pe,{id:"addItem",kind:K,onClose:c,preventOutsideClose:!0,children:e.jsx(xe,{...x,children:e.jsx("form",{id:"add-node-form",onSubmit:J,children:H[o]})})})};export{Xe as AddItemModal}; diff --git a/build/assets/isPlainObject-1f2f9f4b.js b/build/assets/isPlainObject-1f2f9f4b.js new file mode 100644 index 000000000..a885f1d3b --- /dev/null +++ b/build/assets/isPlainObject-1f2f9f4b.js @@ -0,0 +1 @@ +import{K as de,L as pe,M,V as Ne,N as S,aj as Ge,r as U,G as ge,j as E,S as K,X as H,U as be,P as Ue,av as z,aw as B,aC as T,bP as he,aA as ve,a8 as X,bQ as Ke,aG as He,bR as ze,bS as ye,bT as Xe,bU as Ye,bV as Ze,aJ as ke,aM as _e,aB as Je,aI as Qe,bW as We,aH as me,bX as je}from"./index-4e60c9e2.js";import{u as Ve,b as $e,f as er,S as rr}from"./Stack-5870980a.js";import{T as W}from"./Typography-2a31701b.js";function ar(e){return de("PrivateSwitchBase",e)}pe("PrivateSwitchBase",["root","checked","disabled","input","edgeStart","edgeEnd"]);const nr=["autoFocus","checked","checkedIcon","className","defaultChecked","disabled","disableFocusRipple","edge","icon","id","inputProps","inputRef","name","onBlur","onChange","onFocus","readOnly","required","tabIndex","type","value"],tr=e=>{const{classes:r,checked:a,disabled:n,edge:s}=e,t={root:["root",a&&"checked",n&&"disabled",s&&`edge${H(s)}`],input:["input"]};return be(t,ar,r)},sr=M(Ne)(({ownerState:e})=>S({padding:9,borderRadius:"50%"},e.edge==="start"&&{marginLeft:e.size==="small"?-3:-12},e.edge==="end"&&{marginRight:e.size==="small"?-3:-12})),ir=M("input",{shouldForwardProp:Ge})({cursor:"inherit",position:"absolute",opacity:0,width:"100%",height:"100%",top:0,left:0,margin:0,padding:0,zIndex:1}),or=U.forwardRef(function(r,a){const{autoFocus:n,checked:s,checkedIcon:t,className:i,defaultChecked:o,disabled:l,disableFocusRipple:c=!1,edge:d=!1,icon:f,id:u,inputProps:h,inputRef:p,name:g,onBlur:b,onChange:y,onFocus:v,readOnly:O,required:$=!1,tabIndex:_,type:P,value:L}=r,A=ge(r,nr),[w,xe]=Ve({controlled:s,default:!!o,name:"SwitchBase",state:"checked"}),C=$e(),Me=m=>{v&&v(m),C&&C.onFocus&&C.onFocus(m)},Be=m=>{b&&b(m),C&&C.onBlur&&C.onBlur(m)},qe=m=>{if(m.nativeEvent.defaultPrevented)return;const Q=m.target.checked;xe(Q),y&&y(m,Q)};let I=l;C&&typeof I>"u"&&(I=C.disabled);const De=P==="checkbox"||P==="radio",D=S({},r,{checked:w,disabled:I,disableFocusRipple:c,edge:d}),J=tr(D);return E.jsxs(sr,S({component:"span",className:K(J.root,i),centerRipple:!0,focusRipple:!c,disabled:I,tabIndex:null,role:void 0,onFocus:Me,onBlur:Be,ownerState:D,ref:a},A,{children:[E.jsx(ir,S({autoFocus:n,checked:s,defaultChecked:o,className:J.input,disabled:I,id:De?u:void 0,name:g,onChange:qe,readOnly:O,ref:p,required:$,ownerState:D,tabIndex:_,type:P},P==="checkbox"&&L===void 0?{}:{value:L},h)),w?t:f]}))}),ss=or;function lr(e){return de("MuiFormControlLabel",e)}const ur=pe("MuiFormControlLabel",["root","labelPlacementStart","labelPlacementTop","labelPlacementBottom","disabled","label","error","required","asterisk"]),F=ur,cr=["checked","className","componentsProps","control","disabled","disableTypography","inputRef","label","labelPlacement","name","onChange","required","slotProps","value"],fr=e=>{const{classes:r,disabled:a,labelPlacement:n,error:s,required:t}=e,i={root:["root",a&&"disabled",`labelPlacement${H(n)}`,s&&"error",t&&"required"],label:["label",a&&"disabled"],asterisk:["asterisk",s&&"error"]};return be(i,lr,r)},dr=M("label",{name:"MuiFormControlLabel",slot:"Root",overridesResolver:(e,r)=>{const{ownerState:a}=e;return[{[`& .${F.label}`]:r.label},r.root,r[`labelPlacement${H(a.labelPlacement)}`]]}})(({theme:e,ownerState:r})=>S({display:"inline-flex",alignItems:"center",cursor:"pointer",verticalAlign:"middle",WebkitTapHighlightColor:"transparent",marginLeft:-11,marginRight:16,[`&.${F.disabled}`]:{cursor:"default"}},r.labelPlacement==="start"&&{flexDirection:"row-reverse",marginLeft:16,marginRight:-11},r.labelPlacement==="top"&&{flexDirection:"column-reverse",marginLeft:16},r.labelPlacement==="bottom"&&{flexDirection:"column",marginLeft:16},{[`& .${F.label}`]:{[`&.${F.disabled}`]:{color:(e.vars||e).palette.text.disabled}}})),pr=M("span",{name:"MuiFormControlLabel",slot:"Asterisk",overridesResolver:(e,r)=>r.asterisk})(({theme:e})=>({[`&.${F.error}`]:{color:(e.vars||e).palette.error.main}})),gr=U.forwardRef(function(r,a){var n,s;const t=Ue({props:r,name:"MuiFormControlLabel"}),{className:i,componentsProps:o={},control:l,disabled:c,disableTypography:d,label:f,labelPlacement:u="end",required:h,slotProps:p={}}=t,g=ge(t,cr),b=$e(),y=(n=c??l.props.disabled)!=null?n:b==null?void 0:b.disabled,v=h??l.props.required,O={disabled:y,required:v};["checked","name","onChange","value","inputRef"].forEach(w=>{typeof l.props[w]>"u"&&typeof t[w]<"u"&&(O[w]=t[w])});const $=er({props:t,muiFormControl:b,states:["error"]}),_=S({},t,{disabled:y,labelPlacement:u,required:v,error:$.error}),P=fr(_),L=(s=p.typography)!=null?s:o.typography;let A=f;return A!=null&&A.type!==W&&!d&&(A=E.jsx(W,S({component:"span"},L,{className:K(P.label,L==null?void 0:L.className),children:A}))),E.jsxs(dr,S({className:K(P.root,i),ownerState:_,ref:a},g,{children:[U.cloneElement(l,O),v?E.jsxs(rr,{display:"block",children:[A,E.jsxs(pr,{ownerState:_,"aria-hidden":!0,className:P.asterisk,children:[" ","*"]})]}):A]}))}),is=gr;var br=z,hr=B,vr="[object Symbol]";function yr(e){return typeof e=="symbol"||hr(e)&&br(e)==vr}var Y=yr,_r=T,mr=Y,$r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Pr=/^\w*$/;function Ar(e,r){if(_r(e))return!1;var a=typeof e;return a=="number"||a=="symbol"||a=="boolean"||e==null||mr(e)?!0:Pr.test(e)||!$r.test(e)||r!=null&&e in Object(r)}var Z=Ar,Pe=he,Cr="Expected a function";function k(e,r){if(typeof e!="function"||r!=null&&typeof r!="function")throw new TypeError(Cr);var a=function(){var n=arguments,s=r?r.apply(this,n):n[0],t=a.cache;if(t.has(s))return t.get(s);var i=e.apply(this,n);return a.cache=t.set(s,i)||t,i};return a.cache=new(k.Cache||Pe),a}k.Cache=Pe;var Sr=k,Tr=Sr,Or=500;function wr(e){var r=Tr(e,function(n){return a.size===Or&&a.clear(),n}),a=r.cache;return r}var Lr=wr,Er=Lr,Ir=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Fr=/\\(\\)?/g,Rr=Er(function(e){var r=[];return e.charCodeAt(0)===46&&r.push(""),e.replace(Ir,function(a,n,s,t){r.push(s?t.replace(Fr,"$1"):n||a)}),r}),xr=Rr;function Mr(e,r){for(var a=-1,n=e==null?0:e.length,s=Array(n);++ao))return!1;var c=t.get(e),d=t.get(r);if(c&&d)return c==r&&d==e;var f=-1,u=!0,h=a&Ta?new Pa:void 0;for(t.set(e,r),t.set(r,e);++f{const{classes:r,checked:a,disabled:n,edge:s}=e,t={root:["root",a&&"checked",n&&"disabled",s&&`edge${K(s)}`],input:["input"]};return be(t,ar,r)},sr=M(Ne)(({ownerState:e})=>S({padding:9,borderRadius:"50%"},e.edge==="start"&&{marginLeft:e.size==="small"?-3:-12},e.edge==="end"&&{marginRight:e.size==="small"?-3:-12})),ir=M("input",{shouldForwardProp:Ge})({cursor:"inherit",position:"absolute",opacity:0,width:"100%",height:"100%",top:0,left:0,margin:0,padding:0,zIndex:1}),or=U.forwardRef(function(r,a){const{autoFocus:n,checked:s,checkedIcon:t,className:i,defaultChecked:o,disabled:l,disableFocusRipple:c=!1,edge:d=!1,icon:f,id:u,inputProps:h,inputRef:p,name:g,onBlur:b,onChange:y,onFocus:v,readOnly:O,required:$=!1,tabIndex:_,type:P,value:L}=r,A=ge(r,nr),[w,xe]=Ve({controlled:s,default:!!o,name:"SwitchBase",state:"checked"}),C=$e(),Me=m=>{v&&v(m),C&&C.onFocus&&C.onFocus(m)},Be=m=>{b&&b(m),C&&C.onBlur&&C.onBlur(m)},qe=m=>{if(m.nativeEvent.defaultPrevented)return;const Q=m.target.checked;xe(Q),y&&y(m,Q)};let I=l;C&&typeof I>"u"&&(I=C.disabled);const De=P==="checkbox"||P==="radio",D=S({},r,{checked:w,disabled:I,disableFocusRipple:c,edge:d}),J=tr(D);return E.jsxs(sr,S({component:"span",className:H(J.root,i),centerRipple:!0,focusRipple:!c,disabled:I,tabIndex:null,role:void 0,onFocus:Me,onBlur:Be,ownerState:D,ref:a},A,{children:[E.jsx(ir,S({autoFocus:n,checked:s,defaultChecked:o,className:J.input,disabled:I,id:De?u:void 0,name:g,onChange:qe,readOnly:O,ref:p,required:$,ownerState:D,tabIndex:_,type:P},P==="checkbox"&&L===void 0?{}:{value:L},h)),w?t:f]}))}),ss=or;function lr(e){return de("MuiFormControlLabel",e)}const ur=pe("MuiFormControlLabel",["root","labelPlacementStart","labelPlacementTop","labelPlacementBottom","disabled","label","error","required","asterisk"]),F=ur,cr=["checked","className","componentsProps","control","disabled","disableTypography","inputRef","label","labelPlacement","name","onChange","required","slotProps","value"],fr=e=>{const{classes:r,disabled:a,labelPlacement:n,error:s,required:t}=e,i={root:["root",a&&"disabled",`labelPlacement${K(n)}`,s&&"error",t&&"required"],label:["label",a&&"disabled"],asterisk:["asterisk",s&&"error"]};return be(i,lr,r)},dr=M("label",{name:"MuiFormControlLabel",slot:"Root",overridesResolver:(e,r)=>{const{ownerState:a}=e;return[{[`& .${F.label}`]:r.label},r.root,r[`labelPlacement${K(a.labelPlacement)}`]]}})(({theme:e,ownerState:r})=>S({display:"inline-flex",alignItems:"center",cursor:"pointer",verticalAlign:"middle",WebkitTapHighlightColor:"transparent",marginLeft:-11,marginRight:16,[`&.${F.disabled}`]:{cursor:"default"}},r.labelPlacement==="start"&&{flexDirection:"row-reverse",marginLeft:16,marginRight:-11},r.labelPlacement==="top"&&{flexDirection:"column-reverse",marginLeft:16},r.labelPlacement==="bottom"&&{flexDirection:"column",marginLeft:16},{[`& .${F.label}`]:{[`&.${F.disabled}`]:{color:(e.vars||e).palette.text.disabled}}})),pr=M("span",{name:"MuiFormControlLabel",slot:"Asterisk",overridesResolver:(e,r)=>r.asterisk})(({theme:e})=>({[`&.${F.error}`]:{color:(e.vars||e).palette.error.main}})),gr=U.forwardRef(function(r,a){var n,s;const t=Ue({props:r,name:"MuiFormControlLabel"}),{className:i,componentsProps:o={},control:l,disabled:c,disableTypography:d,label:f,labelPlacement:u="end",required:h,slotProps:p={}}=t,g=ge(t,cr),b=$e(),y=(n=c??l.props.disabled)!=null?n:b==null?void 0:b.disabled,v=h??l.props.required,O={disabled:y,required:v};["checked","name","onChange","value","inputRef"].forEach(w=>{typeof l.props[w]>"u"&&typeof t[w]<"u"&&(O[w]=t[w])});const $=er({props:t,muiFormControl:b,states:["error"]}),_=S({},t,{disabled:y,labelPlacement:u,required:v,error:$.error}),P=fr(_),L=(s=p.typography)!=null?s:o.typography;let A=f;return A!=null&&A.type!==W&&!d&&(A=E.jsx(W,S({component:"span"},L,{className:H(P.label,L==null?void 0:L.className),children:A}))),E.jsxs(dr,S({className:H(P.root,i),ownerState:_,ref:a},g,{children:[U.cloneElement(l,O),v?E.jsxs(rr,{display:"block",children:[A,E.jsxs(pr,{ownerState:_,"aria-hidden":!0,className:P.asterisk,children:[" ","*"]})]}):A]}))}),is=gr;var br=z,hr=B,vr="[object Symbol]";function yr(e){return typeof e=="symbol"||hr(e)&&br(e)==vr}var Y=yr,_r=T,mr=Y,$r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Pr=/^\w*$/;function Ar(e,r){if(_r(e))return!1;var a=typeof e;return a=="number"||a=="symbol"||a=="boolean"||e==null||mr(e)?!0:Pr.test(e)||!$r.test(e)||r!=null&&e in Object(r)}var k=Ar,Pe=he,Cr="Expected a function";function Z(e,r){if(typeof e!="function"||r!=null&&typeof r!="function")throw new TypeError(Cr);var a=function(){var n=arguments,s=r?r.apply(this,n):n[0],t=a.cache;if(t.has(s))return t.get(s);var i=e.apply(this,n);return a.cache=t.set(s,i)||t,i};return a.cache=new(Z.Cache||Pe),a}Z.Cache=Pe;var Sr=Z,Tr=Sr,Or=500;function wr(e){var r=Tr(e,function(n){return a.size===Or&&a.clear(),n}),a=r.cache;return r}var Lr=wr,Er=Lr,Ir=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Fr=/\\(\\)?/g,Rr=Er(function(e){var r=[];return e.charCodeAt(0)===46&&r.push(""),e.replace(Ir,function(a,n,s,t){r.push(s?t.replace(Fr,"$1"):n||a)}),r}),xr=Rr;function Mr(e,r){for(var a=-1,n=e==null?0:e.length,s=Array(n);++ao))return!1;var c=t.get(e),d=t.get(r);if(c&&d)return c==r&&d==e;var f=-1,u=!0,h=a&Ta?new Pa:void 0;for(t.set(e,r),t.set(r,e);++f Second Brain - +