From 269a2e505f2bb0908f3f35d1645468260ded28ba Mon Sep 17 00:00:00 2001 From: IFenton Date: Tue, 17 Dec 2024 04:26:57 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20alan-tur?= =?UTF-8?q?ing-institute/scivision@8e98e078e5744f41a2f259413e264e9391da81d?= =?UTF-8?q?6=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 404.html | 2 +- assets/{Preview-Bf0dPt-k.js => Preview-cuDAfGXO.js} | 2 +- assets/{index-CsxYmkwZ.js => index-GK_pa31r.js} | 8 ++++---- index.html | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) rename assets/{Preview-Bf0dPt-k.js => Preview-cuDAfGXO.js} (97%) rename assets/{index-CsxYmkwZ.js => index-GK_pa31r.js} (99%) diff --git a/404.html b/404.html index 329c2f47..2a598163 100644 --- a/404.html +++ b/404.html @@ -17,7 +17,7 @@ Scivision - + diff --git a/assets/Preview-Bf0dPt-k.js b/assets/Preview-cuDAfGXO.js similarity index 97% rename from assets/Preview-Bf0dPt-k.js rename to assets/Preview-cuDAfGXO.js index 28306a5a..6917fc47 100644 --- a/assets/Preview-Bf0dPt-k.js +++ b/assets/Preview-cuDAfGXO.js @@ -1 +1 @@ -import{g as y,r as v}from"./index-CsxYmkwZ.js";function w(r,e){for(var t=0;tn[a]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var P=Object.create,s=Object.defineProperty,O=Object.getOwnPropertyDescriptor,x=Object.getOwnPropertyNames,I=Object.getPrototypeOf,j=Object.prototype.hasOwnProperty,E=(r,e,t)=>e in r?s(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,S=(r,e)=>{for(var t in e)s(r,t,{get:e[t],enumerable:!0})},_=(r,e,t,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of x(e))!j.call(r,a)&&a!==t&&s(r,a,{get:()=>e[a],enumerable:!(n=O(e,a))||n.enumerable});return r},C=(r,e,t)=>(t=r!=null?P(I(r)):{},_(!r||!r.__esModule?s(t,"default",{value:r,enumerable:!0}):t,r)),N=r=>_(s({},"__esModule",{value:!0}),r),p=(r,e,t)=>(E(r,typeof e!="symbol"?e+"":e,t),t),g={};S(g,{default:()=>k});var m=N(g),i=C(v);const u="64px",d={};class k extends i.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(!i.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,previewAriaLabel:o}=this.props,{image:f}=this.state,l=i.default.isValidElement(e),h={display:"flex",alignItems:"center",justifyContent:"center"},c={preview:{width:"100%",height:"100%",backgroundImage:f&&!l?`url(${f})`:void 0,backgroundSize:"cover",backgroundPosition:"center",cursor:"pointer",...h},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,...h},playIcon:{borderStyle:"solid",borderWidth:"16px 0 16px 26px",borderColor:"transparent transparent transparent white",marginLeft:"7px"}},b=i.default.createElement("div",{style:c.shadow,className:"react-player__shadow"},i.default.createElement("div",{style:c.playIcon,className:"react-player__play-icon"}));return i.default.createElement("div",{style:c.preview,className:"react-player__preview",onClick:t,tabIndex:a,onKeyPress:this.handleKeyPress,...o?{"aria-label":o}:{}},l?e:null,n||b)}}const D=y(m),A=w({__proto__:null,default:D},[m]);export{A as P}; +import{g as y,r as v}from"./index-GK_pa31r.js";function w(r,e){for(var t=0;tn[a]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}var P=Object.create,s=Object.defineProperty,O=Object.getOwnPropertyDescriptor,x=Object.getOwnPropertyNames,I=Object.getPrototypeOf,j=Object.prototype.hasOwnProperty,E=(r,e,t)=>e in r?s(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,S=(r,e)=>{for(var t in e)s(r,t,{get:e[t],enumerable:!0})},_=(r,e,t,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of x(e))!j.call(r,a)&&a!==t&&s(r,a,{get:()=>e[a],enumerable:!(n=O(e,a))||n.enumerable});return r},C=(r,e,t)=>(t=r!=null?P(I(r)):{},_(!r||!r.__esModule?s(t,"default",{value:r,enumerable:!0}):t,r)),N=r=>_(s({},"__esModule",{value:!0}),r),p=(r,e,t)=>(E(r,typeof e!="symbol"?e+"":e,t),t),g={};S(g,{default:()=>k});var m=N(g),i=C(v);const u="64px",d={};class k extends i.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(!i.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,previewAriaLabel:o}=this.props,{image:f}=this.state,l=i.default.isValidElement(e),h={display:"flex",alignItems:"center",justifyContent:"center"},c={preview:{width:"100%",height:"100%",backgroundImage:f&&!l?`url(${f})`:void 0,backgroundSize:"cover",backgroundPosition:"center",cursor:"pointer",...h},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,...h},playIcon:{borderStyle:"solid",borderWidth:"16px 0 16px 26px",borderColor:"transparent transparent transparent white",marginLeft:"7px"}},b=i.default.createElement("div",{style:c.shadow,className:"react-player__shadow"},i.default.createElement("div",{style:c.playIcon,className:"react-player__play-icon"}));return i.default.createElement("div",{style:c.preview,className:"react-player__preview",onClick:t,tabIndex:a,onKeyPress:this.handleKeyPress,...o?{"aria-label":o}:{}},l?e:null,n||b)}}const D=y(m),A=w({__proto__:null,default:D},[m]);export{A as P}; diff --git a/assets/index-CsxYmkwZ.js b/assets/index-GK_pa31r.js similarity index 99% rename from assets/index-CsxYmkwZ.js rename to assets/index-GK_pa31r.js index a11bacb1..e89ec539 100644 --- a/assets/index-CsxYmkwZ.js +++ b/assets/index-GK_pa31r.js @@ -125,7 +125,7 @@ The Scivision project is building: If you use Scivision in you research, please [cite us](https://github.com/alan-turing-institute/scivision/blob/main/CITATION.cff). You can also view and contribute to the Scivision community on [Zenodo](https://zenodo.org/communities/scivision/). The Scivision Project was founded by [The Alan Turing Institute](https://www.turing.ac.uk/). -`;var isMergeableObject=function(nt){return isNonNullObject(nt)&&!isSpecial(nt)};function isNonNullObject(rt){return!!rt&&typeof rt=="object"}function isSpecial(rt){var nt=Object.prototype.toString.call(rt);return nt==="[object RegExp]"||nt==="[object Date]"||isReactElement(rt)}var canUseSymbol=typeof Symbol=="function"&&Symbol.for,REACT_ELEMENT_TYPE=canUseSymbol?Symbol.for("react.element"):60103;function isReactElement(rt){return rt.$$typeof===REACT_ELEMENT_TYPE}function emptyTarget(rt){return Array.isArray(rt)?[]:{}}function cloneUnlessOtherwiseSpecified(rt,nt){return nt.clone!==!1&&nt.isMergeableObject(rt)?deepmerge(emptyTarget(rt),rt,nt):rt}function defaultArrayMerge(rt,nt,at){return rt.concat(nt).map(function(st){return cloneUnlessOtherwiseSpecified(st,at)})}function getMergeFunction(rt,nt){if(!nt.customMerge)return deepmerge;var at=nt.customMerge(rt);return typeof at=="function"?at:deepmerge}function getEnumerableOwnPropertySymbols(rt){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(rt).filter(function(nt){return Object.propertyIsEnumerable.call(rt,nt)}):[]}function getKeys(rt){return Object.keys(rt).concat(getEnumerableOwnPropertySymbols(rt))}function propertyIsOnObject(rt,nt){try{return nt in rt}catch{return!1}}function propertyIsUnsafe(rt,nt){return propertyIsOnObject(rt,nt)&&!(Object.hasOwnProperty.call(rt,nt)&&Object.propertyIsEnumerable.call(rt,nt))}function mergeObject(rt,nt,at){var st={};return at.isMergeableObject(rt)&&getKeys(rt).forEach(function(ct){st[ct]=cloneUnlessOtherwiseSpecified(rt[ct],at)}),getKeys(nt).forEach(function(ct){propertyIsUnsafe(rt,ct)||(propertyIsOnObject(rt,ct)&&at.isMergeableObject(nt[ct])?st[ct]=getMergeFunction(ct,at)(rt[ct],nt[ct],at):st[ct]=cloneUnlessOtherwiseSpecified(nt[ct],at))}),st}function deepmerge(rt,nt,at){at=at||{},at.arrayMerge=at.arrayMerge||defaultArrayMerge,at.isMergeableObject=at.isMergeableObject||isMergeableObject,at.cloneUnlessOtherwiseSpecified=cloneUnlessOtherwiseSpecified;var st=Array.isArray(nt),ct=Array.isArray(rt),ut=st===ct;return ut?st?at.arrayMerge(rt,nt,at):mergeObject(rt,nt,at):cloneUnlessOtherwiseSpecified(nt,at)}deepmerge.all=function(nt,at){if(!Array.isArray(nt))throw new Error("first argument should be an array");return nt.reduce(function(st,ct){return deepmerge(st,ct,at)},{})};var deepmerge_1=deepmerge,cjs$1=deepmerge_1,safeIsNaN=Number.isNaN||function(nt){return typeof nt=="number"&&nt!==nt};function isEqual$4(rt,nt){return!!(rt===nt||safeIsNaN(rt)&&safeIsNaN(nt))}function areInputsEqual(rt,nt){if(rt.length!==nt.length)return!1;for(var at=0;at{for(var at in nt)__defProp$5(rt,at,{get:nt[at],enumerable:!0})},__copyProps$5=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$5(nt))!__hasOwnProp$5.call(rt,ct)&&ct!==at&&__defProp$5(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$5(nt,ct))||st.enumerable});return rt},__toESM$4=(rt,nt,at)=>(at=rt!=null?__create$4(__getProtoOf$4(rt)):{},__copyProps$5(!rt||!rt.__esModule?__defProp$5(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS$5=rt=>__copyProps$5(__defProp$5({},"__esModule",{value:!0}),rt),props_exports={};__export$5(props_exports,{defaultProps:()=>defaultProps$4,propTypes:()=>propTypes$1});var props=__toCommonJS$5(props_exports),import_prop_types=__toESM$4(propTypesExports);const{string:string$2,bool:bool$1,number:number$1,array,oneOfType,shape,object,func,node:node$2}=import_prop_types.default,propTypes$1={url:oneOfType([string$2,array,object]),playing:bool$1,loop:bool$1,controls:bool$1,volume:number$1,muted:bool$1,playbackRate:number$1,width:oneOfType([string$2,number$1]),height:oneOfType([string$2,number$1]),style:object,progressInterval:number$1,playsinline:bool$1,pip:bool$1,stopOnUnmount:bool$1,light:oneOfType([bool$1,string$2,object]),playIcon:node$2,previewTabIndex:number$1,previewAriaLabel:string$2,fallback:node$2,oEmbedUrl:string$2,wrapper:oneOfType([string$2,func,shape({render:func.isRequired})]),config:shape({soundcloud:shape({options:object}),youtube:shape({playerVars:object,embedOptions:object,onUnstarted:func}),facebook:shape({appId:string$2,version:string$2,playerId:string$2,attributes:object}),dailymotion:shape({params:object}),vimeo:shape({playerOptions:object,title:string$2}),mux:shape({attributes:object,version:string$2}),file:shape({attributes:object,tracks:array,forceVideo:bool$1,forceAudio:bool$1,forceHLS:bool$1,forceSafariHLS:bool$1,forceDisableHls:bool$1,forceDASH:bool$1,forceFLV:bool$1,hlsOptions:object,hlsVersion:string$2,dashVersion:string$2,flvVersion:string$2}),wistia:shape({options:object,playerId:string$2,customControls:array}),mixcloud:shape({options:object}),twitch:shape({options:object,playerId:string$2}),vidyard:shape({options:object})}),onReady:func,onStart:func,onPlay:func,onPause:func,onBuffer:func,onBufferEnd:func,onEnded:func,onError:func,onDuration:func,onSeek:func,onPlaybackRateChange:func,onPlaybackQualityChange:func,onProgress:func,onClickPreview:func,onEnablePIP:func,onDisablePIP:func},noop$3=()=>{},defaultProps$4={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,previewAriaLabel:"",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:noop$3},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},mux:{attributes:{},version:"2"},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:noop$3,onStart:noop$3,onPlay:noop$3,onPause:noop$3,onBuffer:noop$3,onBufferEnd:noop$3,onEnded:noop$3,onError:noop$3,onDuration:noop$3,onSeek:noop$3,onPlaybackRateChange:noop$3,onPlaybackQualityChange:noop$3,onProgress:noop$3,onClickPreview:noop$3,onEnablePIP:noop$3,onDisablePIP:noop$3};var loadScript=function(nt,at,st){var ct=document.head||document.getElementsByTagName("head")[0],ut=document.createElement("script");typeof at=="function"&&(st=at,at={}),at=at||{},st=st||function(){},ut.type=at.type||"text/javascript",ut.charset=at.charset||"utf8",ut.async="async"in at?!!at.async:!0,ut.src=nt,at.attrs&&setAttributes(ut,at.attrs),at.text&&(ut.text=""+at.text);var dt="onload"in ut?stdOnEnd:ieOnEnd;dt(ut,st),ut.onload||stdOnEnd(ut,st),ct.appendChild(ut)};function setAttributes(rt,nt){for(var at in nt)rt.setAttribute(at,nt[at])}function stdOnEnd(rt,nt){rt.onload=function(){this.onerror=this.onload=null,nt(null,rt)},rt.onerror=function(){this.onerror=this.onload=null,nt(new Error("Failed to load "+this.src),rt)}}function ieOnEnd(rt,nt){rt.onreadystatechange=function(){this.readyState!="complete"&&this.readyState!="loaded"||(this.onreadystatechange=null,nt(null,rt))}}var __create$3=Object.create,__defProp$4=Object.defineProperty,__getOwnPropDesc$4=Object.getOwnPropertyDescriptor,__getOwnPropNames$4=Object.getOwnPropertyNames,__getProtoOf$3=Object.getPrototypeOf,__hasOwnProp$4=Object.prototype.hasOwnProperty,__export$4=(rt,nt)=>{for(var at in nt)__defProp$4(rt,at,{get:nt[at],enumerable:!0})},__copyProps$4=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$4(nt))!__hasOwnProp$4.call(rt,ct)&&ct!==at&&__defProp$4(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$4(nt,ct))||st.enumerable});return rt},__toESM$3=(rt,nt,at)=>(at=rt!=null?__create$3(__getProtoOf$3(rt)):{},__copyProps$4(!rt||!rt.__esModule?__defProp$4(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS$4=rt=>__copyProps$4(__defProp$4({},"__esModule",{value:!0}),rt),utils_exports={};__export$4(utils_exports,{callPlayer:()=>callPlayer,getConfig:()=>getConfig,getSDK:()=>getSDK,isBlobUrl:()=>isBlobUrl,isMediaStream:()=>isMediaStream,lazy:()=>lazy,omit:()=>omit$2,parseEndTime:()=>parseEndTime,parseStartTime:()=>parseStartTime,queryString:()=>queryString,randomString:()=>randomString,supportsWebKitPresentationMode:()=>supportsWebKitPresentationMode});var utils$4=__toCommonJS$4(utils_exports),import_react$3=__toESM$3(reactExports),import_load_script=__toESM$3(loadScript),import_deepmerge$1=__toESM$3(cjs$1);const lazy=rt=>import_react$3.default.lazy(async()=>{const nt=await rt();return typeof nt.default=="function"?nt:nt.default}),MATCH_START_QUERY=/[?&#](?:start|t)=([0-9hms]+)/,MATCH_END_QUERY=/[?&#]end=([0-9hms]+)/,MATCH_START_STAMP=/(\d+)(h|m|s)/g,MATCH_NUMERIC=/^\d+$/;function parseTimeParam(rt,nt){if(rt instanceof Array)return;const at=rt.match(nt);if(at){const st=at[1];if(st.match(MATCH_START_STAMP))return parseTimeString(st);if(MATCH_NUMERIC.test(st))return parseInt(st)}}function parseTimeString(rt){let nt=0,at=MATCH_START_STAMP.exec(rt);for(;at!==null;){const[,st,ct]=at;ct==="h"&&(nt+=parseInt(st,10)*60*60),ct==="m"&&(nt+=parseInt(st,10)*60),ct==="s"&&(nt+=parseInt(st,10)),at=MATCH_START_STAMP.exec(rt)}return nt}function parseStartTime(rt){return parseTimeParam(rt,MATCH_START_QUERY)}function parseEndTime(rt){return parseTimeParam(rt,MATCH_END_QUERY)}function randomString(){return Math.random().toString(36).substr(2,5)}function queryString(rt){return Object.keys(rt).map(nt=>`${nt}=${rt[nt]}`).join("&")}function getGlobal(rt){return window[rt]?window[rt]:window.exports&&window.exports[rt]?window.exports[rt]:window.module&&window.module.exports&&window.module.exports[rt]?window.module.exports[rt]:null}const requests={},getSDK=function(nt,at,st=null,ct=()=>!0,ut=import_load_script.default){const dt=getGlobal(at);return dt&&ct(dt)?Promise.resolve(dt):new Promise((pt,ft)=>{if(requests[nt]){requests[nt].push({resolve:pt,reject:ft});return}requests[nt]=[{resolve:pt,reject:ft}];const mt=ht=>{requests[nt].forEach(yt=>yt.resolve(ht))};if(st){const ht=window[st];window[st]=function(){ht&&ht(),mt(getGlobal(at))}}ut(nt,ht=>{ht?(requests[nt].forEach(yt=>yt.reject(ht)),requests[nt]=null):st||mt(getGlobal(at))})})};function getConfig(rt,nt){return(0,import_deepmerge$1.default)(nt.config,rt.config)}function omit$2(rt,...nt){const at=[].concat(...nt),st={},ct=Object.keys(rt);for(const ut of ct)at.indexOf(ut)===-1&&(st[ut]=rt[ut]);return st}function callPlayer(rt,...nt){if(!this.player||!this.player[rt]){let at=`ReactPlayer: ${this.constructor.displayName} player could not call %c${rt}%c – `;return this.player?this.player[rt]||(at+="The method was not available"):at+="The player was not available",console.warn(at,"font-weight: bold",""),null}return this.player[rt](...nt)}function isMediaStream(rt){return typeof window<"u"&&typeof window.MediaStream<"u"&&rt instanceof window.MediaStream}function isBlobUrl(rt){return/^blob:/.test(rt)}function supportsWebKitPresentationMode(rt=document.createElement("video")){const nt=/iPhone|iPod/.test(navigator.userAgent)===!1;return rt.webkitSupportsPresentationMode&&typeof rt.webkitSetPresentationMode=="function"&&nt}function enableStubOn(rt){return rt}var __create$2=Object.create,__defProp$3=Object.defineProperty,__getOwnPropDesc$3=Object.getOwnPropertyDescriptor,__getOwnPropNames$3=Object.getOwnPropertyNames,__getProtoOf$2=Object.getPrototypeOf,__hasOwnProp$3=Object.prototype.hasOwnProperty,__defNormalProp$2=(rt,nt,at)=>nt in rt?__defProp$3(rt,nt,{enumerable:!0,configurable:!0,writable:!0,value:at}):rt[nt]=at,__export$3=(rt,nt)=>{for(var at in nt)__defProp$3(rt,at,{get:nt[at],enumerable:!0})},__copyProps$3=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$3(nt))!__hasOwnProp$3.call(rt,ct)&&ct!==at&&__defProp$3(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$3(nt,ct))||st.enumerable});return rt},__toESM$2=(rt,nt,at)=>(at=rt!=null?__create$2(__getProtoOf$2(rt)):{},__copyProps$3(!rt||!rt.__esModule?__defProp$3(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS$3=rt=>__copyProps$3(__defProp$3({},"__esModule",{value:!0}),rt),__publicField$2=(rt,nt,at)=>(__defNormalProp$2(rt,typeof nt!="symbol"?nt+"":nt,at),at),Player_exports={};__export$3(Player_exports,{default:()=>Player$1});var Player_1=__toCommonJS$3(Player_exports),import_react$2=__toESM$2(reactExports),import_react_fast_compare$1=__toESM$2(reactFastCompare),import_props$1=props,import_utils$3=utils$4;const SEEK_ON_PLAY_EXPIRY=5e3;let Player$1=class extends import_react$2.Component{constructor(){super(...arguments),__publicField$2(this,"mounted",!1),__publicField$2(this,"isReady",!1),__publicField$2(this,"isPlaying",!1),__publicField$2(this,"isLoading",!0),__publicField$2(this,"loadOnReady",null),__publicField$2(this,"startOnPlay",!0),__publicField$2(this,"seekOnPlay",null),__publicField$2(this,"onDurationCalled",!1),__publicField$2(this,"handlePlayerMount",nt=>{if(this.player){this.progress();return}this.player=nt,this.player.load(this.props.url),this.progress()}),__publicField$2(this,"getInternalPlayer",nt=>this.player?this.player[nt]:null),__publicField$2(this,"progress",()=>{if(this.props.url&&this.player&&this.isReady){const nt=this.getCurrentTime()||0,at=this.getSecondsLoaded(),st=this.getDuration();if(st){const ct={playedSeconds:nt,played:nt/st};at!==null&&(ct.loadedSeconds=at,ct.loaded=at/st),(ct.playedSeconds!==this.prevPlayed||ct.loadedSeconds!==this.prevLoaded)&&this.props.onProgress(ct),this.prevPlayed=ct.playedSeconds,this.prevLoaded=ct.loadedSeconds}}this.progressTimeout=setTimeout(this.progress,this.props.progressFrequency||this.props.progressInterval)}),__publicField$2(this,"handleReady",()=>{if(!this.mounted)return;this.isReady=!0,this.isLoading=!1;const{onReady:nt,playing:at,volume:st,muted:ct}=this.props;nt(),!ct&&st!==null&&this.player.setVolume(st),this.loadOnReady?(this.player.load(this.loadOnReady,!0),this.loadOnReady=null):at&&this.player.play(),this.handleDurationCheck()}),__publicField$2(this,"handlePlay",()=>{this.isPlaying=!0,this.isLoading=!1;const{onStart:nt,onPlay:at,playbackRate:st}=this.props;this.startOnPlay&&(this.player.setPlaybackRate&&st!==1&&this.player.setPlaybackRate(st),nt(),this.startOnPlay=!1),at(),this.seekOnPlay&&(this.seekTo(this.seekOnPlay),this.seekOnPlay=null),this.handleDurationCheck()}),__publicField$2(this,"handlePause",nt=>{this.isPlaying=!1,this.isLoading||this.props.onPause(nt)}),__publicField$2(this,"handleEnded",()=>{const{activePlayer:nt,loop:at,onEnded:st}=this.props;nt.loopOnEnded&&at&&this.seekTo(0),at||(this.isPlaying=!1,st())}),__publicField$2(this,"handleError",(...nt)=>{this.isLoading=!1,this.props.onError(...nt)}),__publicField$2(this,"handleDurationCheck",()=>{clearTimeout(this.durationCheckTimeout);const nt=this.getDuration();nt?this.onDurationCalled||(this.props.onDuration(nt),this.onDurationCalled=!0):this.durationCheckTimeout=setTimeout(this.handleDurationCheck,100)}),__publicField$2(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(nt){if(!this.player)return;const{url:at,playing:st,volume:ct,muted:ut,playbackRate:dt,pip:pt,loop:ft,activePlayer:mt,disableDeferredLoading:ht}=this.props;if(!(0,import_react_fast_compare$1.default)(nt.url,at)){if(this.isLoading&&!mt.forceLoad&&!ht&&!(0,import_utils$3.isMediaStream)(at)){console.warn(`ReactPlayer: the attempt to load ${at} is being deferred until the player has loaded`),this.loadOnReady=at;return}this.isLoading=!0,this.startOnPlay=!0,this.onDurationCalled=!1,this.player.load(at,this.isReady)}!nt.playing&&st&&!this.isPlaying&&this.player.play(),nt.playing&&!st&&this.isPlaying&&this.player.pause(),!nt.pip&&pt&&this.player.enablePIP&&this.player.enablePIP(),nt.pip&&!pt&&this.player.disablePIP&&this.player.disablePIP(),nt.volume!==ct&&ct!==null&&this.player.setVolume(ct),nt.muted!==ut&&(ut?this.player.mute():(this.player.unmute(),ct!==null&&setTimeout(()=>this.player.setVolume(ct)))),nt.playbackRate!==dt&&this.player.setPlaybackRate&&this.player.setPlaybackRate(dt),nt.loop!==ft&&this.player.setLoop&&this.player.setLoop(ft)}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(nt,at,st){if(!this.isReady){nt!==0&&(this.seekOnPlay=nt,setTimeout(()=>{this.seekOnPlay=null},SEEK_ON_PLAY_EXPIRY));return}if(at?at==="fraction":nt>0&&nt<1){const ut=this.player.getDuration();if(!ut){console.warn("ReactPlayer: could not seek using fraction – duration not yet available");return}this.player.seekTo(ut*nt,st);return}this.player.seekTo(nt,st)}render(){const nt=this.props.activePlayer;return nt?import_react$2.default.createElement(nt,{...this.props,onMount:this.handlePlayerMount,onReady:this.handleReady,onPlay:this.handlePlay,onPause:this.handlePause,onEnded:this.handleEnded,onLoaded:this.handleLoaded,onError:this.handleError}):null}};__publicField$2(Player$1,"displayName","Player");__publicField$2(Player$1,"propTypes",import_props$1.propTypes);__publicField$2(Player$1,"defaultProps",import_props$1.defaultProps);var define_global_default$1={},__create$1=Object.create,__defProp$2=Object.defineProperty,__getOwnPropDesc$2=Object.getOwnPropertyDescriptor,__getOwnPropNames$2=Object.getOwnPropertyNames,__getProtoOf$1=Object.getPrototypeOf,__hasOwnProp$2=Object.prototype.hasOwnProperty,__defNormalProp$1=(rt,nt,at)=>nt in rt?__defProp$2(rt,nt,{enumerable:!0,configurable:!0,writable:!0,value:at}):rt[nt]=at,__export$2=(rt,nt)=>{for(var at in nt)__defProp$2(rt,at,{get:nt[at],enumerable:!0})},__copyProps$2=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$2(nt))!__hasOwnProp$2.call(rt,ct)&&ct!==at&&__defProp$2(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$2(nt,ct))||st.enumerable});return rt},__toESM$1=(rt,nt,at)=>(at=rt!=null?__create$1(__getProtoOf$1(rt)):{},__copyProps$2(!rt||!rt.__esModule?__defProp$2(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS$2=rt=>__copyProps$2(__defProp$2({},"__esModule",{value:!0}),rt),__publicField$1=(rt,nt,at)=>(__defNormalProp$1(rt,typeof nt!="symbol"?nt+"":nt,at),at),ReactPlayer_exports={};__export$2(ReactPlayer_exports,{createReactPlayer:()=>createReactPlayer$1});var ReactPlayer$1=__toCommonJS$2(ReactPlayer_exports),import_react$1=__toESM$1(reactExports),import_deepmerge=__toESM$1(cjs$1),import_memoize_one=__toESM$1(require$$2),import_react_fast_compare=__toESM$1(reactFastCompare),import_props=props,import_utils$2=utils$4,import_Player=__toESM$1(Player_1);const Preview=(0,import_utils$2.lazy)(()=>__vitePreload(()=>import("./Preview-Bf0dPt-k.js").then(rt=>rt.P),[])),IS_BROWSER=typeof window<"u"&&window.document&&typeof document<"u",IS_GLOBAL=typeof define_global_default$1<"u"&&define_global_default$1.window&&define_global_default$1.window.document,SUPPORTED_PROPS=Object.keys(import_props.propTypes),UniversalSuspense=IS_BROWSER||IS_GLOBAL?import_react$1.Suspense:()=>null,customPlayers=[],createReactPlayer$1=(rt,nt)=>{var at;return at=class extends import_react$1.Component{constructor(){super(...arguments),__publicField$1(this,"state",{showPreview:!!this.props.light}),__publicField$1(this,"references",{wrapper:st=>{this.wrapper=st},player:st=>{this.player=st}}),__publicField$1(this,"handleClickPreview",st=>{this.setState({showPreview:!1}),this.props.onClickPreview(st)}),__publicField$1(this,"showPreview",()=>{this.setState({showPreview:!0})}),__publicField$1(this,"getDuration",()=>this.player?this.player.getDuration():null),__publicField$1(this,"getCurrentTime",()=>this.player?this.player.getCurrentTime():null),__publicField$1(this,"getSecondsLoaded",()=>this.player?this.player.getSecondsLoaded():null),__publicField$1(this,"getInternalPlayer",(st="player")=>this.player?this.player.getInternalPlayer(st):null),__publicField$1(this,"seekTo",(st,ct,ut)=>{if(!this.player)return null;this.player.seekTo(st,ct,ut)}),__publicField$1(this,"handleReady",()=>{this.props.onReady(this)}),__publicField$1(this,"getActivePlayer",(0,import_memoize_one.default)(st=>{for(const ct of[...customPlayers,...rt])if(ct.canPlay(st))return ct;return nt||null})),__publicField$1(this,"getConfig",(0,import_memoize_one.default)((st,ct)=>{const{config:ut}=this.props;return import_deepmerge.default.all([import_props.defaultProps.config,import_props.defaultProps.config[ct]||{},ut,ut[ct]||{}])})),__publicField$1(this,"getAttributes",(0,import_memoize_one.default)(st=>(0,import_utils$2.omit)(this.props,SUPPORTED_PROPS))),__publicField$1(this,"renderActivePlayer",st=>{if(!st)return null;const ct=this.getActivePlayer(st);if(!ct)return null;const ut=this.getConfig(st,ct.key);return import_react$1.default.createElement(import_Player.default,{...this.props,key:ct.key,ref:this.references.player,config:ut,activePlayer:ct.lazyPlayer||ct,onReady:this.handleReady})})}shouldComponentUpdate(st,ct){return!(0,import_react_fast_compare.default)(this.props,st)||!(0,import_react_fast_compare.default)(this.state,ct)}componentDidUpdate(st){const{light:ct}=this.props;!st.light&&ct&&this.setState({showPreview:!0}),st.light&&!ct&&this.setState({showPreview:!1})}renderPreview(st){if(!st)return null;const{light:ct,playIcon:ut,previewTabIndex:dt,oEmbedUrl:pt,previewAriaLabel:ft}=this.props;return import_react$1.default.createElement(Preview,{url:st,light:ct,playIcon:ut,previewTabIndex:dt,previewAriaLabel:ft,oEmbedUrl:pt,onClick:this.handleClickPreview})}render(){const{url:st,style:ct,width:ut,height:dt,fallback:pt,wrapper:ft}=this.props,{showPreview:mt}=this.state,ht=this.getAttributes(st),yt=typeof ft=="string"?this.references.wrapper:void 0;return import_react$1.default.createElement(ft,{ref:yt,style:{...ct,width:ut,height:dt},...ht},import_react$1.default.createElement(UniversalSuspense,{fallback:pt},mt?this.renderPreview(st):this.renderActivePlayer(st)))}},__publicField$1(at,"displayName","ReactPlayer"),__publicField$1(at,"propTypes",import_props.propTypes),__publicField$1(at,"defaultProps",import_props.defaultProps),__publicField$1(at,"addCustomPlayer",st=>{customPlayers.push(st)}),__publicField$1(at,"removeCustomPlayers",()=>{customPlayers.length=0}),__publicField$1(at,"canPlay",st=>{for(const ct of[...customPlayers,...rt])if(ct.canPlay(st))return!0;return!1}),__publicField$1(at,"canEnablePIP",st=>{for(const ct of[...customPlayers,...rt])if(ct.canEnablePIP&&ct.canEnablePIP(st))return!0;return!1}),at};var __defProp$1=Object.defineProperty,__getOwnPropDesc$1=Object.getOwnPropertyDescriptor,__getOwnPropNames$1=Object.getOwnPropertyNames,__hasOwnProp$1=Object.prototype.hasOwnProperty,__export$1=(rt,nt)=>{for(var at in nt)__defProp$1(rt,at,{get:nt[at],enumerable:!0})},__copyProps$1=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$1(nt))!__hasOwnProp$1.call(rt,ct)&&ct!==at&&__defProp$1(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$1(nt,ct))||st.enumerable});return rt},__toCommonJS$1=rt=>__copyProps$1(__defProp$1({},"__esModule",{value:!0}),rt),patterns_exports={};__export$1(patterns_exports,{AUDIO_EXTENSIONS:()=>AUDIO_EXTENSIONS,DASH_EXTENSIONS:()=>DASH_EXTENSIONS,FLV_EXTENSIONS:()=>FLV_EXTENSIONS,HLS_EXTENSIONS:()=>HLS_EXTENSIONS,MATCH_URL_DAILYMOTION:()=>MATCH_URL_DAILYMOTION,MATCH_URL_FACEBOOK:()=>MATCH_URL_FACEBOOK,MATCH_URL_FACEBOOK_WATCH:()=>MATCH_URL_FACEBOOK_WATCH,MATCH_URL_KALTURA:()=>MATCH_URL_KALTURA,MATCH_URL_MIXCLOUD:()=>MATCH_URL_MIXCLOUD,MATCH_URL_MUX:()=>MATCH_URL_MUX,MATCH_URL_SOUNDCLOUD:()=>MATCH_URL_SOUNDCLOUD,MATCH_URL_STREAMABLE:()=>MATCH_URL_STREAMABLE,MATCH_URL_TWITCH_CHANNEL:()=>MATCH_URL_TWITCH_CHANNEL,MATCH_URL_TWITCH_VIDEO:()=>MATCH_URL_TWITCH_VIDEO,MATCH_URL_VIDYARD:()=>MATCH_URL_VIDYARD,MATCH_URL_VIMEO:()=>MATCH_URL_VIMEO,MATCH_URL_WISTIA:()=>MATCH_URL_WISTIA,MATCH_URL_YOUTUBE:()=>MATCH_URL_YOUTUBE,VIDEO_EXTENSIONS:()=>VIDEO_EXTENSIONS,canPlay:()=>canPlay});var patterns=__toCommonJS$1(patterns_exports),import_utils$1=utils$4;const MATCH_URL_YOUTUBE=/(?:youtu\.be\/|youtube(?:-nocookie|education)?\.com\/(?:embed\/|v\/|watch\/|watch\?v=|watch\?.+&v=|shorts\/|live\/))((\w|-){11})|youtube\.com\/playlist\?list=|youtube\.com\/user\//,MATCH_URL_SOUNDCLOUD=/(?:soundcloud\.com|snd\.sc)\/[^.]+$/,MATCH_URL_VIMEO=/vimeo\.com\/(?!progressive_redirect).+/,MATCH_URL_MUX=/stream\.mux\.com\/(?!\w+\.m3u8)(\w+)/,MATCH_URL_FACEBOOK=/^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/,MATCH_URL_FACEBOOK_WATCH=/^https?:\/\/fb\.watch\/.+$/,MATCH_URL_STREAMABLE=/streamable\.com\/([a-z0-9]+)$/,MATCH_URL_WISTIA=/(?:wistia\.(?:com|net)|wi\.st)\/(?:medias|embed)\/(?:iframe\/)?([^?]+)/,MATCH_URL_TWITCH_VIDEO=/(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/,MATCH_URL_TWITCH_CHANNEL=/(?:www\.|go\.)?twitch\.tv\/([a-zA-Z0-9_]+)($|\?)/,MATCH_URL_DAILYMOTION=/^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?(?:[\w.#_-]+)?/,MATCH_URL_MIXCLOUD=/mixcloud\.com\/([^/]+\/[^/]+)/,MATCH_URL_VIDYARD=/vidyard.com\/(?:watch\/)?([a-zA-Z0-9-_]+)/,MATCH_URL_KALTURA=/^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-_].*)$/,AUDIO_EXTENSIONS=/\.(m4a|m4b|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i,VIDEO_EXTENSIONS=/\.(mp4|og[gv]|webm|mov|m4v)(#t=[,\d+]+)?($|\?)/i,HLS_EXTENSIONS=/\.(m3u8)($|\?)/i,DASH_EXTENSIONS=/\.(mpd)($|\?)/i,FLV_EXTENSIONS=/\.(flv)($|\?)/i,canPlayFile=rt=>{if(rt instanceof Array){for(const nt of rt)if(typeof nt=="string"&&canPlayFile(nt)||canPlayFile(nt.src))return!0;return!1}return(0,import_utils$1.isMediaStream)(rt)||(0,import_utils$1.isBlobUrl)(rt)?!0:AUDIO_EXTENSIONS.test(rt)||VIDEO_EXTENSIONS.test(rt)||HLS_EXTENSIONS.test(rt)||DASH_EXTENSIONS.test(rt)||FLV_EXTENSIONS.test(rt)},canPlay={youtube:rt=>rt instanceof Array?rt.every(nt=>MATCH_URL_YOUTUBE.test(nt)):MATCH_URL_YOUTUBE.test(rt),soundcloud:rt=>MATCH_URL_SOUNDCLOUD.test(rt)&&!AUDIO_EXTENSIONS.test(rt),vimeo:rt=>MATCH_URL_VIMEO.test(rt)&&!VIDEO_EXTENSIONS.test(rt)&&!HLS_EXTENSIONS.test(rt),mux:rt=>MATCH_URL_MUX.test(rt),facebook:rt=>MATCH_URL_FACEBOOK.test(rt)||MATCH_URL_FACEBOOK_WATCH.test(rt),streamable:rt=>MATCH_URL_STREAMABLE.test(rt),wistia:rt=>MATCH_URL_WISTIA.test(rt),twitch:rt=>MATCH_URL_TWITCH_VIDEO.test(rt)||MATCH_URL_TWITCH_CHANNEL.test(rt),dailymotion:rt=>MATCH_URL_DAILYMOTION.test(rt),mixcloud:rt=>MATCH_URL_MIXCLOUD.test(rt),vidyard:rt=>MATCH_URL_VIDYARD.test(rt),kaltura:rt=>MATCH_URL_KALTURA.test(rt),file:canPlayFile};var __create=Object.create,__defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty,__defNormalProp=(rt,nt,at)=>nt in rt?__defProp(rt,nt,{enumerable:!0,configurable:!0,writable:!0,value:at}):rt[nt]=at,__export=(rt,nt)=>{for(var at in nt)__defProp(rt,at,{get:nt[at],enumerable:!0})},__copyProps=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames(nt))!__hasOwnProp.call(rt,ct)&&ct!==at&&__defProp(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc(nt,ct))||st.enumerable});return rt},__toESM=(rt,nt,at)=>(at=rt!=null?__create(__getProtoOf(rt)):{},__copyProps(!rt||!rt.__esModule?__defProp(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS=rt=>__copyProps(__defProp({},"__esModule",{value:!0}),rt),__publicField=(rt,nt,at)=>(__defNormalProp(rt,typeof nt!="symbol"?nt+"":nt,at),at),YouTube_exports={};__export(YouTube_exports,{default:()=>YouTube});var YouTube_1=__toCommonJS(YouTube_exports),import_react=__toESM(reactExports),import_utils=utils$4,import_patterns=patterns;const SDK_URL="https://www.youtube.com/iframe_api",SDK_GLOBAL="YT",SDK_GLOBAL_READY="onYouTubeIframeAPIReady",MATCH_PLAYLIST=/[?&](?:list|channel)=([a-zA-Z0-9_-]+)/,MATCH_USER_UPLOADS=/user\/([a-zA-Z0-9_-]+)\/?/,MATCH_NOCOOKIE=/youtube-nocookie\.com/,NOCOOKIE_HOST="https://www.youtube-nocookie.com";class YouTube extends import_react.Component{constructor(){super(...arguments),__publicField(this,"callPlayer",import_utils.callPlayer),__publicField(this,"parsePlaylist",nt=>{if(nt instanceof Array)return{listType:"playlist",playlist:nt.map(this.getID).join(",")};if(MATCH_PLAYLIST.test(nt)){const[,at]=nt.match(MATCH_PLAYLIST);return{listType:"playlist",list:at.replace(/^UC/,"UU")}}if(MATCH_USER_UPLOADS.test(nt)){const[,at]=nt.match(MATCH_USER_UPLOADS);return{listType:"user_uploads",list:at}}return{}}),__publicField(this,"onStateChange",nt=>{const{data:at}=nt,{onPlay:st,onPause:ct,onBuffer:ut,onBufferEnd:dt,onEnded:pt,onReady:ft,loop:mt,config:{playerVars:ht,onUnstarted:yt}}=this.props,{UNSTARTED:$t,PLAYING:_t,PAUSED:bt,BUFFERING:xt,ENDED:Rt,CUED:St}=window[SDK_GLOBAL].PlayerState;if(at===$t&&yt(),at===_t&&(st(),dt()),at===bt&&ct(),at===xt&&ut(),at===Rt){const kt=!!this.callPlayer("getPlaylist");mt&&!kt&&(ht.start?this.seekTo(ht.start):this.play()),pt()}at===St&&ft()}),__publicField(this,"mute",()=>{this.callPlayer("mute")}),__publicField(this,"unmute",()=>{this.callPlayer("unMute")}),__publicField(this,"ref",nt=>{this.container=nt})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}getID(nt){return!nt||nt instanceof Array||MATCH_PLAYLIST.test(nt)?null:nt.match(import_patterns.MATCH_URL_YOUTUBE)[1]}load(nt,at){const{playing:st,muted:ct,playsinline:ut,controls:dt,loop:pt,config:ft,onError:mt}=this.props,{playerVars:ht,embedOptions:yt}=ft,$t=this.getID(nt);if(at){if(MATCH_PLAYLIST.test(nt)||MATCH_USER_UPLOADS.test(nt)||nt instanceof Array){this.player.loadPlaylist(this.parsePlaylist(nt));return}this.player.cueVideoById({videoId:$t,startSeconds:(0,import_utils.parseStartTime)(nt)||ht.start,endSeconds:(0,import_utils.parseEndTime)(nt)||ht.end});return}(0,import_utils.getSDK)(SDK_URL,SDK_GLOBAL,SDK_GLOBAL_READY,_t=>_t.loaded).then(_t=>{this.container&&(this.player=new _t.Player(this.container,{width:"100%",height:"100%",videoId:$t,playerVars:{autoplay:st?1:0,mute:ct?1:0,controls:dt?1:0,start:(0,import_utils.parseStartTime)(nt),end:(0,import_utils.parseEndTime)(nt),origin:window.location.origin,playsinline:ut?1:0,...this.parsePlaylist(nt),...ht},events:{onReady:()=>{pt&&this.player.setLoop(!0),this.props.onReady()},onPlaybackRateChange:bt=>this.props.onPlaybackRateChange(bt.data),onPlaybackQualityChange:bt=>this.props.onPlaybackQualityChange(bt),onStateChange:this.onStateChange,onError:bt=>mt(bt.data)},host:MATCH_NOCOOKIE.test(nt)?NOCOOKIE_HOST:void 0,...yt}))},mt),yt.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(nt,at=!1){this.callPlayer("seekTo",nt),!at&&!this.props.playing&&this.pause()}setVolume(nt){this.callPlayer("setVolume",nt*100)}setPlaybackRate(nt){this.callPlayer("setPlaybackRate",nt)}setLoop(nt){this.callPlayer("setLoop",nt)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentTime")}getSecondsLoaded(){return this.callPlayer("getVideoLoadedFraction")*this.getDuration()}render(){const{display:nt}=this.props,at={width:"100%",height:"100%",display:nt};return import_react.default.createElement("div",{style:at},import_react.default.createElement("div",{ref:this.ref}))}}__publicField(YouTube,"displayName","YouTube");__publicField(YouTube,"canPlay",import_patterns.canPlay.youtube);var createReactPlayer=ReactPlayer$1.createReactPlayer,Player=YouTube_1.default,youtube=createReactPlayer([{key:"youtube",canPlay:Player.canPlay,lazyPlayer:Player}]);const ReactPlayer=getDefaultExportFromCjs$1(youtube);function n$3(){return n$3=Object.assign?Object.assign.bind():function(rt){for(var nt=1;nt(rt[nt.toLowerCase()]=nt,rt),{for:"htmlFor"}),o={amp:"&",apos:"'",gt:">",lt:"<",nbsp:" ",quot:"“"},c$3=["style","script"],a=/([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi,s$1=/mailto:/i,d$3=/\n{2,}$/,u$2=/^(\s*>[\s\S]*?)(?=\n{2,})/,p$3=/^ *> ?/gm,f$3=/^ {2,}\n/,h$3=/^(?:( *[-*_])){3,} *(?:\n *)+\n/,m$4=/^\s*(`{3,}|~{3,}) *(\S+)?([^\n]*?)?\n([\s\S]+?)\s*\1 *(?:\n *)*\n?/,g$4=/^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/,y$3=/^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,k$4=/^(?:\n *)*\n/,x$3=/\r\n?/g,v$4=/^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/,b$4=/^\[\^([^\]]+)]/,$$2=/\f/g,E$2=/^---[ \t]*\n(.|\n)*\n---[ \t]*\n/,w$3=/^\s*?\[(x|\s)\]/,S$2=/^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,C$2=/^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,A$2=/^([^\n]+)\n *(=|-){3,} *(?:\n *)+\n/,O$1=/^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?((?:[^>]*[^/])?)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i,T$2=/&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi,L$2=/^)/,R$1=/^(data|aria|x)-[a-z_][a-z\d_.-]*$/,z$3=/^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i,M$2=/^\{.*\}$/,I$2=/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,U$2=/^<([^ >]+@[^ >]+)>/,j$2=/^<([^ >]+:\/[^ >]+)>/,B$2=/-([a-z])?/gi,N$2=/^(.*\|.*)\n(?: *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*))?\n?/,H$2=/^\[([^\]]*)\]:\s+]+)>?\s*("([^"]*)")?/,D$2=/^!\[([^\]]*)\] ?\[([^\]]*)\]/,P$1=/^\[([^\]]*)\] ?\[([^\]]*)\]/,_$2=/(\[|\])/g,F$2=/(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/,W$2=/\t/g,G$2=/(^ *\||\| *$)/g,Z$2=/^ *:-+: *$/,q$4=/^ *:-+ *$/,V$2=/^ *-+: *$/,X$2="((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|~~.*?~~|==.*?==|.|\\n)*?)",Q$2=new RegExp(`^([*_])\\1${X$2}\\1\\1(?!\\1)`),J$2=new RegExp(`^([*_])${X$2}\\1(?!\\1|\\w)`),K$2=new RegExp(`^==${X$2}==`),Y$2=new RegExp(`^~~${X$2}~~`),ee$3=/^\\([^0-9A-Za-z\s])/,ne$3=/^[\s\S]+?(?=[^0-9A-Z\s\u00c0-\uffff&#;.()'"]|\d+\.|\n\n| {2,}\n|\w+:\S|$)/i,te$2=/^\n+/,re$3=/^([ \t]*)/,ie$2=/\\([^\\])/g,le$3=/ *\n+$/,oe$2=/(?:^|\n)( *)$/,ce$2="(?:\\d+\\.)",ae$2="(?:[*+-])";function se$2(rt){return"( *)("+(rt===1?ce$2:ae$2)+") +"}const de$2=se$2(1),ue$1=se$2(2);function pe$2(rt){return new RegExp("^"+(rt===1?de$2:ue$1))}const fe$2=pe$2(1),he$2=pe$2(2);function me$1(rt){return new RegExp("^"+(rt===1?de$2:ue$1)+"[^\\n]*(?:\\n(?!\\1"+(rt===1?ce$2:ae$2)+" )[^\\n]*)*(\\n|$)","gm")}const ge$3=me$1(1),ye$2=me$1(2);function ke$2(rt){const nt=rt===1?ce$2:ae$2;return new RegExp("^( *)("+nt+") [\\s\\S]+?(?:\\n{2,}(?! )(?!\\1"+nt+" (?!"+nt+" ))\\n*|\\s*\\n*$)")}const xe$2=ke$2(1),ve$2=ke$2(2);function be$2(rt,nt){const at=nt===1,st=at?xe$2:ve$2,ct=at?ge$3:ye$2,ut=at?fe$2:he$2;return{match(dt,pt,ft){const mt=oe$2.exec(ft);return mt&&(pt.list||!pt.inline&&!pt.simple)?st.exec(dt=mt[1]+dt):null},order:1,parse(dt,pt,ft){const mt=at?+dt[2]:void 0,ht=dt[0].replace(d$3,` +`;var isMergeableObject=function(nt){return isNonNullObject(nt)&&!isSpecial(nt)};function isNonNullObject(rt){return!!rt&&typeof rt=="object"}function isSpecial(rt){var nt=Object.prototype.toString.call(rt);return nt==="[object RegExp]"||nt==="[object Date]"||isReactElement(rt)}var canUseSymbol=typeof Symbol=="function"&&Symbol.for,REACT_ELEMENT_TYPE=canUseSymbol?Symbol.for("react.element"):60103;function isReactElement(rt){return rt.$$typeof===REACT_ELEMENT_TYPE}function emptyTarget(rt){return Array.isArray(rt)?[]:{}}function cloneUnlessOtherwiseSpecified(rt,nt){return nt.clone!==!1&&nt.isMergeableObject(rt)?deepmerge(emptyTarget(rt),rt,nt):rt}function defaultArrayMerge(rt,nt,at){return rt.concat(nt).map(function(st){return cloneUnlessOtherwiseSpecified(st,at)})}function getMergeFunction(rt,nt){if(!nt.customMerge)return deepmerge;var at=nt.customMerge(rt);return typeof at=="function"?at:deepmerge}function getEnumerableOwnPropertySymbols(rt){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(rt).filter(function(nt){return Object.propertyIsEnumerable.call(rt,nt)}):[]}function getKeys(rt){return Object.keys(rt).concat(getEnumerableOwnPropertySymbols(rt))}function propertyIsOnObject(rt,nt){try{return nt in rt}catch{return!1}}function propertyIsUnsafe(rt,nt){return propertyIsOnObject(rt,nt)&&!(Object.hasOwnProperty.call(rt,nt)&&Object.propertyIsEnumerable.call(rt,nt))}function mergeObject(rt,nt,at){var st={};return at.isMergeableObject(rt)&&getKeys(rt).forEach(function(ct){st[ct]=cloneUnlessOtherwiseSpecified(rt[ct],at)}),getKeys(nt).forEach(function(ct){propertyIsUnsafe(rt,ct)||(propertyIsOnObject(rt,ct)&&at.isMergeableObject(nt[ct])?st[ct]=getMergeFunction(ct,at)(rt[ct],nt[ct],at):st[ct]=cloneUnlessOtherwiseSpecified(nt[ct],at))}),st}function deepmerge(rt,nt,at){at=at||{},at.arrayMerge=at.arrayMerge||defaultArrayMerge,at.isMergeableObject=at.isMergeableObject||isMergeableObject,at.cloneUnlessOtherwiseSpecified=cloneUnlessOtherwiseSpecified;var st=Array.isArray(nt),ct=Array.isArray(rt),ut=st===ct;return ut?st?at.arrayMerge(rt,nt,at):mergeObject(rt,nt,at):cloneUnlessOtherwiseSpecified(nt,at)}deepmerge.all=function(nt,at){if(!Array.isArray(nt))throw new Error("first argument should be an array");return nt.reduce(function(st,ct){return deepmerge(st,ct,at)},{})};var deepmerge_1=deepmerge,cjs$1=deepmerge_1,safeIsNaN=Number.isNaN||function(nt){return typeof nt=="number"&&nt!==nt};function isEqual$4(rt,nt){return!!(rt===nt||safeIsNaN(rt)&&safeIsNaN(nt))}function areInputsEqual(rt,nt){if(rt.length!==nt.length)return!1;for(var at=0;at{for(var at in nt)__defProp$5(rt,at,{get:nt[at],enumerable:!0})},__copyProps$5=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$5(nt))!__hasOwnProp$5.call(rt,ct)&&ct!==at&&__defProp$5(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$5(nt,ct))||st.enumerable});return rt},__toESM$4=(rt,nt,at)=>(at=rt!=null?__create$4(__getProtoOf$4(rt)):{},__copyProps$5(!rt||!rt.__esModule?__defProp$5(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS$5=rt=>__copyProps$5(__defProp$5({},"__esModule",{value:!0}),rt),props_exports={};__export$5(props_exports,{defaultProps:()=>defaultProps$4,propTypes:()=>propTypes$1});var props=__toCommonJS$5(props_exports),import_prop_types=__toESM$4(propTypesExports);const{string:string$2,bool:bool$1,number:number$1,array,oneOfType,shape,object,func,node:node$2}=import_prop_types.default,propTypes$1={url:oneOfType([string$2,array,object]),playing:bool$1,loop:bool$1,controls:bool$1,volume:number$1,muted:bool$1,playbackRate:number$1,width:oneOfType([string$2,number$1]),height:oneOfType([string$2,number$1]),style:object,progressInterval:number$1,playsinline:bool$1,pip:bool$1,stopOnUnmount:bool$1,light:oneOfType([bool$1,string$2,object]),playIcon:node$2,previewTabIndex:number$1,previewAriaLabel:string$2,fallback:node$2,oEmbedUrl:string$2,wrapper:oneOfType([string$2,func,shape({render:func.isRequired})]),config:shape({soundcloud:shape({options:object}),youtube:shape({playerVars:object,embedOptions:object,onUnstarted:func}),facebook:shape({appId:string$2,version:string$2,playerId:string$2,attributes:object}),dailymotion:shape({params:object}),vimeo:shape({playerOptions:object,title:string$2}),mux:shape({attributes:object,version:string$2}),file:shape({attributes:object,tracks:array,forceVideo:bool$1,forceAudio:bool$1,forceHLS:bool$1,forceSafariHLS:bool$1,forceDisableHls:bool$1,forceDASH:bool$1,forceFLV:bool$1,hlsOptions:object,hlsVersion:string$2,dashVersion:string$2,flvVersion:string$2}),wistia:shape({options:object,playerId:string$2,customControls:array}),mixcloud:shape({options:object}),twitch:shape({options:object,playerId:string$2}),vidyard:shape({options:object})}),onReady:func,onStart:func,onPlay:func,onPause:func,onBuffer:func,onBufferEnd:func,onEnded:func,onError:func,onDuration:func,onSeek:func,onPlaybackRateChange:func,onPlaybackQualityChange:func,onProgress:func,onClickPreview:func,onEnablePIP:func,onDisablePIP:func},noop$3=()=>{},defaultProps$4={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,previewAriaLabel:"",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:noop$3},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},mux:{attributes:{},version:"2"},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:noop$3,onStart:noop$3,onPlay:noop$3,onPause:noop$3,onBuffer:noop$3,onBufferEnd:noop$3,onEnded:noop$3,onError:noop$3,onDuration:noop$3,onSeek:noop$3,onPlaybackRateChange:noop$3,onPlaybackQualityChange:noop$3,onProgress:noop$3,onClickPreview:noop$3,onEnablePIP:noop$3,onDisablePIP:noop$3};var loadScript=function(nt,at,st){var ct=document.head||document.getElementsByTagName("head")[0],ut=document.createElement("script");typeof at=="function"&&(st=at,at={}),at=at||{},st=st||function(){},ut.type=at.type||"text/javascript",ut.charset=at.charset||"utf8",ut.async="async"in at?!!at.async:!0,ut.src=nt,at.attrs&&setAttributes(ut,at.attrs),at.text&&(ut.text=""+at.text);var dt="onload"in ut?stdOnEnd:ieOnEnd;dt(ut,st),ut.onload||stdOnEnd(ut,st),ct.appendChild(ut)};function setAttributes(rt,nt){for(var at in nt)rt.setAttribute(at,nt[at])}function stdOnEnd(rt,nt){rt.onload=function(){this.onerror=this.onload=null,nt(null,rt)},rt.onerror=function(){this.onerror=this.onload=null,nt(new Error("Failed to load "+this.src),rt)}}function ieOnEnd(rt,nt){rt.onreadystatechange=function(){this.readyState!="complete"&&this.readyState!="loaded"||(this.onreadystatechange=null,nt(null,rt))}}var __create$3=Object.create,__defProp$4=Object.defineProperty,__getOwnPropDesc$4=Object.getOwnPropertyDescriptor,__getOwnPropNames$4=Object.getOwnPropertyNames,__getProtoOf$3=Object.getPrototypeOf,__hasOwnProp$4=Object.prototype.hasOwnProperty,__export$4=(rt,nt)=>{for(var at in nt)__defProp$4(rt,at,{get:nt[at],enumerable:!0})},__copyProps$4=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$4(nt))!__hasOwnProp$4.call(rt,ct)&&ct!==at&&__defProp$4(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$4(nt,ct))||st.enumerable});return rt},__toESM$3=(rt,nt,at)=>(at=rt!=null?__create$3(__getProtoOf$3(rt)):{},__copyProps$4(!rt||!rt.__esModule?__defProp$4(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS$4=rt=>__copyProps$4(__defProp$4({},"__esModule",{value:!0}),rt),utils_exports={};__export$4(utils_exports,{callPlayer:()=>callPlayer,getConfig:()=>getConfig,getSDK:()=>getSDK,isBlobUrl:()=>isBlobUrl,isMediaStream:()=>isMediaStream,lazy:()=>lazy,omit:()=>omit$2,parseEndTime:()=>parseEndTime,parseStartTime:()=>parseStartTime,queryString:()=>queryString,randomString:()=>randomString,supportsWebKitPresentationMode:()=>supportsWebKitPresentationMode});var utils$4=__toCommonJS$4(utils_exports),import_react$3=__toESM$3(reactExports),import_load_script=__toESM$3(loadScript),import_deepmerge$1=__toESM$3(cjs$1);const lazy=rt=>import_react$3.default.lazy(async()=>{const nt=await rt();return typeof nt.default=="function"?nt:nt.default}),MATCH_START_QUERY=/[?&#](?:start|t)=([0-9hms]+)/,MATCH_END_QUERY=/[?&#]end=([0-9hms]+)/,MATCH_START_STAMP=/(\d+)(h|m|s)/g,MATCH_NUMERIC=/^\d+$/;function parseTimeParam(rt,nt){if(rt instanceof Array)return;const at=rt.match(nt);if(at){const st=at[1];if(st.match(MATCH_START_STAMP))return parseTimeString(st);if(MATCH_NUMERIC.test(st))return parseInt(st)}}function parseTimeString(rt){let nt=0,at=MATCH_START_STAMP.exec(rt);for(;at!==null;){const[,st,ct]=at;ct==="h"&&(nt+=parseInt(st,10)*60*60),ct==="m"&&(nt+=parseInt(st,10)*60),ct==="s"&&(nt+=parseInt(st,10)),at=MATCH_START_STAMP.exec(rt)}return nt}function parseStartTime(rt){return parseTimeParam(rt,MATCH_START_QUERY)}function parseEndTime(rt){return parseTimeParam(rt,MATCH_END_QUERY)}function randomString(){return Math.random().toString(36).substr(2,5)}function queryString(rt){return Object.keys(rt).map(nt=>`${nt}=${rt[nt]}`).join("&")}function getGlobal(rt){return window[rt]?window[rt]:window.exports&&window.exports[rt]?window.exports[rt]:window.module&&window.module.exports&&window.module.exports[rt]?window.module.exports[rt]:null}const requests={},getSDK=function(nt,at,st=null,ct=()=>!0,ut=import_load_script.default){const dt=getGlobal(at);return dt&&ct(dt)?Promise.resolve(dt):new Promise((pt,ft)=>{if(requests[nt]){requests[nt].push({resolve:pt,reject:ft});return}requests[nt]=[{resolve:pt,reject:ft}];const mt=ht=>{requests[nt].forEach(yt=>yt.resolve(ht))};if(st){const ht=window[st];window[st]=function(){ht&&ht(),mt(getGlobal(at))}}ut(nt,ht=>{ht?(requests[nt].forEach(yt=>yt.reject(ht)),requests[nt]=null):st||mt(getGlobal(at))})})};function getConfig(rt,nt){return(0,import_deepmerge$1.default)(nt.config,rt.config)}function omit$2(rt,...nt){const at=[].concat(...nt),st={},ct=Object.keys(rt);for(const ut of ct)at.indexOf(ut)===-1&&(st[ut]=rt[ut]);return st}function callPlayer(rt,...nt){if(!this.player||!this.player[rt]){let at=`ReactPlayer: ${this.constructor.displayName} player could not call %c${rt}%c – `;return this.player?this.player[rt]||(at+="The method was not available"):at+="The player was not available",console.warn(at,"font-weight: bold",""),null}return this.player[rt](...nt)}function isMediaStream(rt){return typeof window<"u"&&typeof window.MediaStream<"u"&&rt instanceof window.MediaStream}function isBlobUrl(rt){return/^blob:/.test(rt)}function supportsWebKitPresentationMode(rt=document.createElement("video")){const nt=/iPhone|iPod/.test(navigator.userAgent)===!1;return rt.webkitSupportsPresentationMode&&typeof rt.webkitSetPresentationMode=="function"&&nt}function enableStubOn(rt){return rt}var __create$2=Object.create,__defProp$3=Object.defineProperty,__getOwnPropDesc$3=Object.getOwnPropertyDescriptor,__getOwnPropNames$3=Object.getOwnPropertyNames,__getProtoOf$2=Object.getPrototypeOf,__hasOwnProp$3=Object.prototype.hasOwnProperty,__defNormalProp$2=(rt,nt,at)=>nt in rt?__defProp$3(rt,nt,{enumerable:!0,configurable:!0,writable:!0,value:at}):rt[nt]=at,__export$3=(rt,nt)=>{for(var at in nt)__defProp$3(rt,at,{get:nt[at],enumerable:!0})},__copyProps$3=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$3(nt))!__hasOwnProp$3.call(rt,ct)&&ct!==at&&__defProp$3(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$3(nt,ct))||st.enumerable});return rt},__toESM$2=(rt,nt,at)=>(at=rt!=null?__create$2(__getProtoOf$2(rt)):{},__copyProps$3(!rt||!rt.__esModule?__defProp$3(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS$3=rt=>__copyProps$3(__defProp$3({},"__esModule",{value:!0}),rt),__publicField$2=(rt,nt,at)=>(__defNormalProp$2(rt,typeof nt!="symbol"?nt+"":nt,at),at),Player_exports={};__export$3(Player_exports,{default:()=>Player$1});var Player_1=__toCommonJS$3(Player_exports),import_react$2=__toESM$2(reactExports),import_react_fast_compare$1=__toESM$2(reactFastCompare),import_props$1=props,import_utils$3=utils$4;const SEEK_ON_PLAY_EXPIRY=5e3;let Player$1=class extends import_react$2.Component{constructor(){super(...arguments),__publicField$2(this,"mounted",!1),__publicField$2(this,"isReady",!1),__publicField$2(this,"isPlaying",!1),__publicField$2(this,"isLoading",!0),__publicField$2(this,"loadOnReady",null),__publicField$2(this,"startOnPlay",!0),__publicField$2(this,"seekOnPlay",null),__publicField$2(this,"onDurationCalled",!1),__publicField$2(this,"handlePlayerMount",nt=>{if(this.player){this.progress();return}this.player=nt,this.player.load(this.props.url),this.progress()}),__publicField$2(this,"getInternalPlayer",nt=>this.player?this.player[nt]:null),__publicField$2(this,"progress",()=>{if(this.props.url&&this.player&&this.isReady){const nt=this.getCurrentTime()||0,at=this.getSecondsLoaded(),st=this.getDuration();if(st){const ct={playedSeconds:nt,played:nt/st};at!==null&&(ct.loadedSeconds=at,ct.loaded=at/st),(ct.playedSeconds!==this.prevPlayed||ct.loadedSeconds!==this.prevLoaded)&&this.props.onProgress(ct),this.prevPlayed=ct.playedSeconds,this.prevLoaded=ct.loadedSeconds}}this.progressTimeout=setTimeout(this.progress,this.props.progressFrequency||this.props.progressInterval)}),__publicField$2(this,"handleReady",()=>{if(!this.mounted)return;this.isReady=!0,this.isLoading=!1;const{onReady:nt,playing:at,volume:st,muted:ct}=this.props;nt(),!ct&&st!==null&&this.player.setVolume(st),this.loadOnReady?(this.player.load(this.loadOnReady,!0),this.loadOnReady=null):at&&this.player.play(),this.handleDurationCheck()}),__publicField$2(this,"handlePlay",()=>{this.isPlaying=!0,this.isLoading=!1;const{onStart:nt,onPlay:at,playbackRate:st}=this.props;this.startOnPlay&&(this.player.setPlaybackRate&&st!==1&&this.player.setPlaybackRate(st),nt(),this.startOnPlay=!1),at(),this.seekOnPlay&&(this.seekTo(this.seekOnPlay),this.seekOnPlay=null),this.handleDurationCheck()}),__publicField$2(this,"handlePause",nt=>{this.isPlaying=!1,this.isLoading||this.props.onPause(nt)}),__publicField$2(this,"handleEnded",()=>{const{activePlayer:nt,loop:at,onEnded:st}=this.props;nt.loopOnEnded&&at&&this.seekTo(0),at||(this.isPlaying=!1,st())}),__publicField$2(this,"handleError",(...nt)=>{this.isLoading=!1,this.props.onError(...nt)}),__publicField$2(this,"handleDurationCheck",()=>{clearTimeout(this.durationCheckTimeout);const nt=this.getDuration();nt?this.onDurationCalled||(this.props.onDuration(nt),this.onDurationCalled=!0):this.durationCheckTimeout=setTimeout(this.handleDurationCheck,100)}),__publicField$2(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(nt){if(!this.player)return;const{url:at,playing:st,volume:ct,muted:ut,playbackRate:dt,pip:pt,loop:ft,activePlayer:mt,disableDeferredLoading:ht}=this.props;if(!(0,import_react_fast_compare$1.default)(nt.url,at)){if(this.isLoading&&!mt.forceLoad&&!ht&&!(0,import_utils$3.isMediaStream)(at)){console.warn(`ReactPlayer: the attempt to load ${at} is being deferred until the player has loaded`),this.loadOnReady=at;return}this.isLoading=!0,this.startOnPlay=!0,this.onDurationCalled=!1,this.player.load(at,this.isReady)}!nt.playing&&st&&!this.isPlaying&&this.player.play(),nt.playing&&!st&&this.isPlaying&&this.player.pause(),!nt.pip&&pt&&this.player.enablePIP&&this.player.enablePIP(),nt.pip&&!pt&&this.player.disablePIP&&this.player.disablePIP(),nt.volume!==ct&&ct!==null&&this.player.setVolume(ct),nt.muted!==ut&&(ut?this.player.mute():(this.player.unmute(),ct!==null&&setTimeout(()=>this.player.setVolume(ct)))),nt.playbackRate!==dt&&this.player.setPlaybackRate&&this.player.setPlaybackRate(dt),nt.loop!==ft&&this.player.setLoop&&this.player.setLoop(ft)}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(nt,at,st){if(!this.isReady){nt!==0&&(this.seekOnPlay=nt,setTimeout(()=>{this.seekOnPlay=null},SEEK_ON_PLAY_EXPIRY));return}if(at?at==="fraction":nt>0&&nt<1){const ut=this.player.getDuration();if(!ut){console.warn("ReactPlayer: could not seek using fraction – duration not yet available");return}this.player.seekTo(ut*nt,st);return}this.player.seekTo(nt,st)}render(){const nt=this.props.activePlayer;return nt?import_react$2.default.createElement(nt,{...this.props,onMount:this.handlePlayerMount,onReady:this.handleReady,onPlay:this.handlePlay,onPause:this.handlePause,onEnded:this.handleEnded,onLoaded:this.handleLoaded,onError:this.handleError}):null}};__publicField$2(Player$1,"displayName","Player");__publicField$2(Player$1,"propTypes",import_props$1.propTypes);__publicField$2(Player$1,"defaultProps",import_props$1.defaultProps);var define_global_default$1={},__create$1=Object.create,__defProp$2=Object.defineProperty,__getOwnPropDesc$2=Object.getOwnPropertyDescriptor,__getOwnPropNames$2=Object.getOwnPropertyNames,__getProtoOf$1=Object.getPrototypeOf,__hasOwnProp$2=Object.prototype.hasOwnProperty,__defNormalProp$1=(rt,nt,at)=>nt in rt?__defProp$2(rt,nt,{enumerable:!0,configurable:!0,writable:!0,value:at}):rt[nt]=at,__export$2=(rt,nt)=>{for(var at in nt)__defProp$2(rt,at,{get:nt[at],enumerable:!0})},__copyProps$2=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$2(nt))!__hasOwnProp$2.call(rt,ct)&&ct!==at&&__defProp$2(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$2(nt,ct))||st.enumerable});return rt},__toESM$1=(rt,nt,at)=>(at=rt!=null?__create$1(__getProtoOf$1(rt)):{},__copyProps$2(!rt||!rt.__esModule?__defProp$2(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS$2=rt=>__copyProps$2(__defProp$2({},"__esModule",{value:!0}),rt),__publicField$1=(rt,nt,at)=>(__defNormalProp$1(rt,typeof nt!="symbol"?nt+"":nt,at),at),ReactPlayer_exports={};__export$2(ReactPlayer_exports,{createReactPlayer:()=>createReactPlayer$1});var ReactPlayer$1=__toCommonJS$2(ReactPlayer_exports),import_react$1=__toESM$1(reactExports),import_deepmerge=__toESM$1(cjs$1),import_memoize_one=__toESM$1(require$$2),import_react_fast_compare=__toESM$1(reactFastCompare),import_props=props,import_utils$2=utils$4,import_Player=__toESM$1(Player_1);const Preview=(0,import_utils$2.lazy)(()=>__vitePreload(()=>import("./Preview-cuDAfGXO.js").then(rt=>rt.P),[])),IS_BROWSER=typeof window<"u"&&window.document&&typeof document<"u",IS_GLOBAL=typeof define_global_default$1<"u"&&define_global_default$1.window&&define_global_default$1.window.document,SUPPORTED_PROPS=Object.keys(import_props.propTypes),UniversalSuspense=IS_BROWSER||IS_GLOBAL?import_react$1.Suspense:()=>null,customPlayers=[],createReactPlayer$1=(rt,nt)=>{var at;return at=class extends import_react$1.Component{constructor(){super(...arguments),__publicField$1(this,"state",{showPreview:!!this.props.light}),__publicField$1(this,"references",{wrapper:st=>{this.wrapper=st},player:st=>{this.player=st}}),__publicField$1(this,"handleClickPreview",st=>{this.setState({showPreview:!1}),this.props.onClickPreview(st)}),__publicField$1(this,"showPreview",()=>{this.setState({showPreview:!0})}),__publicField$1(this,"getDuration",()=>this.player?this.player.getDuration():null),__publicField$1(this,"getCurrentTime",()=>this.player?this.player.getCurrentTime():null),__publicField$1(this,"getSecondsLoaded",()=>this.player?this.player.getSecondsLoaded():null),__publicField$1(this,"getInternalPlayer",(st="player")=>this.player?this.player.getInternalPlayer(st):null),__publicField$1(this,"seekTo",(st,ct,ut)=>{if(!this.player)return null;this.player.seekTo(st,ct,ut)}),__publicField$1(this,"handleReady",()=>{this.props.onReady(this)}),__publicField$1(this,"getActivePlayer",(0,import_memoize_one.default)(st=>{for(const ct of[...customPlayers,...rt])if(ct.canPlay(st))return ct;return nt||null})),__publicField$1(this,"getConfig",(0,import_memoize_one.default)((st,ct)=>{const{config:ut}=this.props;return import_deepmerge.default.all([import_props.defaultProps.config,import_props.defaultProps.config[ct]||{},ut,ut[ct]||{}])})),__publicField$1(this,"getAttributes",(0,import_memoize_one.default)(st=>(0,import_utils$2.omit)(this.props,SUPPORTED_PROPS))),__publicField$1(this,"renderActivePlayer",st=>{if(!st)return null;const ct=this.getActivePlayer(st);if(!ct)return null;const ut=this.getConfig(st,ct.key);return import_react$1.default.createElement(import_Player.default,{...this.props,key:ct.key,ref:this.references.player,config:ut,activePlayer:ct.lazyPlayer||ct,onReady:this.handleReady})})}shouldComponentUpdate(st,ct){return!(0,import_react_fast_compare.default)(this.props,st)||!(0,import_react_fast_compare.default)(this.state,ct)}componentDidUpdate(st){const{light:ct}=this.props;!st.light&&ct&&this.setState({showPreview:!0}),st.light&&!ct&&this.setState({showPreview:!1})}renderPreview(st){if(!st)return null;const{light:ct,playIcon:ut,previewTabIndex:dt,oEmbedUrl:pt,previewAriaLabel:ft}=this.props;return import_react$1.default.createElement(Preview,{url:st,light:ct,playIcon:ut,previewTabIndex:dt,previewAriaLabel:ft,oEmbedUrl:pt,onClick:this.handleClickPreview})}render(){const{url:st,style:ct,width:ut,height:dt,fallback:pt,wrapper:ft}=this.props,{showPreview:mt}=this.state,ht=this.getAttributes(st),yt=typeof ft=="string"?this.references.wrapper:void 0;return import_react$1.default.createElement(ft,{ref:yt,style:{...ct,width:ut,height:dt},...ht},import_react$1.default.createElement(UniversalSuspense,{fallback:pt},mt?this.renderPreview(st):this.renderActivePlayer(st)))}},__publicField$1(at,"displayName","ReactPlayer"),__publicField$1(at,"propTypes",import_props.propTypes),__publicField$1(at,"defaultProps",import_props.defaultProps),__publicField$1(at,"addCustomPlayer",st=>{customPlayers.push(st)}),__publicField$1(at,"removeCustomPlayers",()=>{customPlayers.length=0}),__publicField$1(at,"canPlay",st=>{for(const ct of[...customPlayers,...rt])if(ct.canPlay(st))return!0;return!1}),__publicField$1(at,"canEnablePIP",st=>{for(const ct of[...customPlayers,...rt])if(ct.canEnablePIP&&ct.canEnablePIP(st))return!0;return!1}),at};var __defProp$1=Object.defineProperty,__getOwnPropDesc$1=Object.getOwnPropertyDescriptor,__getOwnPropNames$1=Object.getOwnPropertyNames,__hasOwnProp$1=Object.prototype.hasOwnProperty,__export$1=(rt,nt)=>{for(var at in nt)__defProp$1(rt,at,{get:nt[at],enumerable:!0})},__copyProps$1=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames$1(nt))!__hasOwnProp$1.call(rt,ct)&&ct!==at&&__defProp$1(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc$1(nt,ct))||st.enumerable});return rt},__toCommonJS$1=rt=>__copyProps$1(__defProp$1({},"__esModule",{value:!0}),rt),patterns_exports={};__export$1(patterns_exports,{AUDIO_EXTENSIONS:()=>AUDIO_EXTENSIONS,DASH_EXTENSIONS:()=>DASH_EXTENSIONS,FLV_EXTENSIONS:()=>FLV_EXTENSIONS,HLS_EXTENSIONS:()=>HLS_EXTENSIONS,MATCH_URL_DAILYMOTION:()=>MATCH_URL_DAILYMOTION,MATCH_URL_FACEBOOK:()=>MATCH_URL_FACEBOOK,MATCH_URL_FACEBOOK_WATCH:()=>MATCH_URL_FACEBOOK_WATCH,MATCH_URL_KALTURA:()=>MATCH_URL_KALTURA,MATCH_URL_MIXCLOUD:()=>MATCH_URL_MIXCLOUD,MATCH_URL_MUX:()=>MATCH_URL_MUX,MATCH_URL_SOUNDCLOUD:()=>MATCH_URL_SOUNDCLOUD,MATCH_URL_STREAMABLE:()=>MATCH_URL_STREAMABLE,MATCH_URL_TWITCH_CHANNEL:()=>MATCH_URL_TWITCH_CHANNEL,MATCH_URL_TWITCH_VIDEO:()=>MATCH_URL_TWITCH_VIDEO,MATCH_URL_VIDYARD:()=>MATCH_URL_VIDYARD,MATCH_URL_VIMEO:()=>MATCH_URL_VIMEO,MATCH_URL_WISTIA:()=>MATCH_URL_WISTIA,MATCH_URL_YOUTUBE:()=>MATCH_URL_YOUTUBE,VIDEO_EXTENSIONS:()=>VIDEO_EXTENSIONS,canPlay:()=>canPlay});var patterns=__toCommonJS$1(patterns_exports),import_utils$1=utils$4;const MATCH_URL_YOUTUBE=/(?:youtu\.be\/|youtube(?:-nocookie|education)?\.com\/(?:embed\/|v\/|watch\/|watch\?v=|watch\?.+&v=|shorts\/|live\/))((\w|-){11})|youtube\.com\/playlist\?list=|youtube\.com\/user\//,MATCH_URL_SOUNDCLOUD=/(?:soundcloud\.com|snd\.sc)\/[^.]+$/,MATCH_URL_VIMEO=/vimeo\.com\/(?!progressive_redirect).+/,MATCH_URL_MUX=/stream\.mux\.com\/(?!\w+\.m3u8)(\w+)/,MATCH_URL_FACEBOOK=/^https?:\/\/(www\.)?facebook\.com.*\/(video(s)?|watch|story)(\.php?|\/).+$/,MATCH_URL_FACEBOOK_WATCH=/^https?:\/\/fb\.watch\/.+$/,MATCH_URL_STREAMABLE=/streamable\.com\/([a-z0-9]+)$/,MATCH_URL_WISTIA=/(?:wistia\.(?:com|net)|wi\.st)\/(?:medias|embed)\/(?:iframe\/)?([^?]+)/,MATCH_URL_TWITCH_VIDEO=/(?:www\.|go\.)?twitch\.tv\/videos\/(\d+)($|\?)/,MATCH_URL_TWITCH_CHANNEL=/(?:www\.|go\.)?twitch\.tv\/([a-zA-Z0-9_]+)($|\?)/,MATCH_URL_DAILYMOTION=/^(?:(?:https?):)?(?:\/\/)?(?:www\.)?(?:(?:dailymotion\.com(?:\/embed)?\/video)|dai\.ly)\/([a-zA-Z0-9]+)(?:_[\w_-]+)?(?:[\w.#_-]+)?/,MATCH_URL_MIXCLOUD=/mixcloud\.com\/([^/]+\/[^/]+)/,MATCH_URL_VIDYARD=/vidyard.com\/(?:watch\/)?([a-zA-Z0-9-_]+)/,MATCH_URL_KALTURA=/^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-_].*)$/,AUDIO_EXTENSIONS=/\.(m4a|m4b|mp4a|mpga|mp2|mp2a|mp3|m2a|m3a|wav|weba|aac|oga|spx)($|\?)/i,VIDEO_EXTENSIONS=/\.(mp4|og[gv]|webm|mov|m4v)(#t=[,\d+]+)?($|\?)/i,HLS_EXTENSIONS=/\.(m3u8)($|\?)/i,DASH_EXTENSIONS=/\.(mpd)($|\?)/i,FLV_EXTENSIONS=/\.(flv)($|\?)/i,canPlayFile=rt=>{if(rt instanceof Array){for(const nt of rt)if(typeof nt=="string"&&canPlayFile(nt)||canPlayFile(nt.src))return!0;return!1}return(0,import_utils$1.isMediaStream)(rt)||(0,import_utils$1.isBlobUrl)(rt)?!0:AUDIO_EXTENSIONS.test(rt)||VIDEO_EXTENSIONS.test(rt)||HLS_EXTENSIONS.test(rt)||DASH_EXTENSIONS.test(rt)||FLV_EXTENSIONS.test(rt)},canPlay={youtube:rt=>rt instanceof Array?rt.every(nt=>MATCH_URL_YOUTUBE.test(nt)):MATCH_URL_YOUTUBE.test(rt),soundcloud:rt=>MATCH_URL_SOUNDCLOUD.test(rt)&&!AUDIO_EXTENSIONS.test(rt),vimeo:rt=>MATCH_URL_VIMEO.test(rt)&&!VIDEO_EXTENSIONS.test(rt)&&!HLS_EXTENSIONS.test(rt),mux:rt=>MATCH_URL_MUX.test(rt),facebook:rt=>MATCH_URL_FACEBOOK.test(rt)||MATCH_URL_FACEBOOK_WATCH.test(rt),streamable:rt=>MATCH_URL_STREAMABLE.test(rt),wistia:rt=>MATCH_URL_WISTIA.test(rt),twitch:rt=>MATCH_URL_TWITCH_VIDEO.test(rt)||MATCH_URL_TWITCH_CHANNEL.test(rt),dailymotion:rt=>MATCH_URL_DAILYMOTION.test(rt),mixcloud:rt=>MATCH_URL_MIXCLOUD.test(rt),vidyard:rt=>MATCH_URL_VIDYARD.test(rt),kaltura:rt=>MATCH_URL_KALTURA.test(rt),file:canPlayFile};var __create=Object.create,__defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty,__defNormalProp=(rt,nt,at)=>nt in rt?__defProp(rt,nt,{enumerable:!0,configurable:!0,writable:!0,value:at}):rt[nt]=at,__export=(rt,nt)=>{for(var at in nt)__defProp(rt,at,{get:nt[at],enumerable:!0})},__copyProps=(rt,nt,at,st)=>{if(nt&&typeof nt=="object"||typeof nt=="function")for(let ct of __getOwnPropNames(nt))!__hasOwnProp.call(rt,ct)&&ct!==at&&__defProp(rt,ct,{get:()=>nt[ct],enumerable:!(st=__getOwnPropDesc(nt,ct))||st.enumerable});return rt},__toESM=(rt,nt,at)=>(at=rt!=null?__create(__getProtoOf(rt)):{},__copyProps(!rt||!rt.__esModule?__defProp(at,"default",{value:rt,enumerable:!0}):at,rt)),__toCommonJS=rt=>__copyProps(__defProp({},"__esModule",{value:!0}),rt),__publicField=(rt,nt,at)=>(__defNormalProp(rt,typeof nt!="symbol"?nt+"":nt,at),at),YouTube_exports={};__export(YouTube_exports,{default:()=>YouTube});var YouTube_1=__toCommonJS(YouTube_exports),import_react=__toESM(reactExports),import_utils=utils$4,import_patterns=patterns;const SDK_URL="https://www.youtube.com/iframe_api",SDK_GLOBAL="YT",SDK_GLOBAL_READY="onYouTubeIframeAPIReady",MATCH_PLAYLIST=/[?&](?:list|channel)=([a-zA-Z0-9_-]+)/,MATCH_USER_UPLOADS=/user\/([a-zA-Z0-9_-]+)\/?/,MATCH_NOCOOKIE=/youtube-nocookie\.com/,NOCOOKIE_HOST="https://www.youtube-nocookie.com";class YouTube extends import_react.Component{constructor(){super(...arguments),__publicField(this,"callPlayer",import_utils.callPlayer),__publicField(this,"parsePlaylist",nt=>{if(nt instanceof Array)return{listType:"playlist",playlist:nt.map(this.getID).join(",")};if(MATCH_PLAYLIST.test(nt)){const[,at]=nt.match(MATCH_PLAYLIST);return{listType:"playlist",list:at.replace(/^UC/,"UU")}}if(MATCH_USER_UPLOADS.test(nt)){const[,at]=nt.match(MATCH_USER_UPLOADS);return{listType:"user_uploads",list:at}}return{}}),__publicField(this,"onStateChange",nt=>{const{data:at}=nt,{onPlay:st,onPause:ct,onBuffer:ut,onBufferEnd:dt,onEnded:pt,onReady:ft,loop:mt,config:{playerVars:ht,onUnstarted:yt}}=this.props,{UNSTARTED:$t,PLAYING:_t,PAUSED:bt,BUFFERING:xt,ENDED:Rt,CUED:St}=window[SDK_GLOBAL].PlayerState;if(at===$t&&yt(),at===_t&&(st(),dt()),at===bt&&ct(),at===xt&&ut(),at===Rt){const kt=!!this.callPlayer("getPlaylist");mt&&!kt&&(ht.start?this.seekTo(ht.start):this.play()),pt()}at===St&&ft()}),__publicField(this,"mute",()=>{this.callPlayer("mute")}),__publicField(this,"unmute",()=>{this.callPlayer("unMute")}),__publicField(this,"ref",nt=>{this.container=nt})}componentDidMount(){this.props.onMount&&this.props.onMount(this)}getID(nt){return!nt||nt instanceof Array||MATCH_PLAYLIST.test(nt)?null:nt.match(import_patterns.MATCH_URL_YOUTUBE)[1]}load(nt,at){const{playing:st,muted:ct,playsinline:ut,controls:dt,loop:pt,config:ft,onError:mt}=this.props,{playerVars:ht,embedOptions:yt}=ft,$t=this.getID(nt);if(at){if(MATCH_PLAYLIST.test(nt)||MATCH_USER_UPLOADS.test(nt)||nt instanceof Array){this.player.loadPlaylist(this.parsePlaylist(nt));return}this.player.cueVideoById({videoId:$t,startSeconds:(0,import_utils.parseStartTime)(nt)||ht.start,endSeconds:(0,import_utils.parseEndTime)(nt)||ht.end});return}(0,import_utils.getSDK)(SDK_URL,SDK_GLOBAL,SDK_GLOBAL_READY,_t=>_t.loaded).then(_t=>{this.container&&(this.player=new _t.Player(this.container,{width:"100%",height:"100%",videoId:$t,playerVars:{autoplay:st?1:0,mute:ct?1:0,controls:dt?1:0,start:(0,import_utils.parseStartTime)(nt),end:(0,import_utils.parseEndTime)(nt),origin:window.location.origin,playsinline:ut?1:0,...this.parsePlaylist(nt),...ht},events:{onReady:()=>{pt&&this.player.setLoop(!0),this.props.onReady()},onPlaybackRateChange:bt=>this.props.onPlaybackRateChange(bt.data),onPlaybackQualityChange:bt=>this.props.onPlaybackQualityChange(bt),onStateChange:this.onStateChange,onError:bt=>mt(bt.data)},host:MATCH_NOCOOKIE.test(nt)?NOCOOKIE_HOST:void 0,...yt}))},mt),yt.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(nt,at=!1){this.callPlayer("seekTo",nt),!at&&!this.props.playing&&this.pause()}setVolume(nt){this.callPlayer("setVolume",nt*100)}setPlaybackRate(nt){this.callPlayer("setPlaybackRate",nt)}setLoop(nt){this.callPlayer("setLoop",nt)}getDuration(){return this.callPlayer("getDuration")}getCurrentTime(){return this.callPlayer("getCurrentTime")}getSecondsLoaded(){return this.callPlayer("getVideoLoadedFraction")*this.getDuration()}render(){const{display:nt}=this.props,at={width:"100%",height:"100%",display:nt};return import_react.default.createElement("div",{style:at},import_react.default.createElement("div",{ref:this.ref}))}}__publicField(YouTube,"displayName","YouTube");__publicField(YouTube,"canPlay",import_patterns.canPlay.youtube);var createReactPlayer=ReactPlayer$1.createReactPlayer,Player=YouTube_1.default,youtube=createReactPlayer([{key:"youtube",canPlay:Player.canPlay,lazyPlayer:Player}]);const ReactPlayer=getDefaultExportFromCjs$1(youtube);function n$3(){return n$3=Object.assign?Object.assign.bind():function(rt){for(var nt=1;nt(rt[nt.toLowerCase()]=nt,rt),{for:"htmlFor"}),o={amp:"&",apos:"'",gt:">",lt:"<",nbsp:" ",quot:"“"},c$3=["style","script"],a=/([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi,s$1=/mailto:/i,d$3=/\n{2,}$/,u$2=/^(\s*>[\s\S]*?)(?=\n{2,})/,p$3=/^ *> ?/gm,f$3=/^ {2,}\n/,h$3=/^(?:( *[-*_])){3,} *(?:\n *)+\n/,m$4=/^\s*(`{3,}|~{3,}) *(\S+)?([^\n]*?)?\n([\s\S]+?)\s*\1 *(?:\n *)*\n?/,g$4=/^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/,y$3=/^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,k$4=/^(?:\n *)*\n/,x$3=/\r\n?/g,v$4=/^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/,b$4=/^\[\^([^\]]+)]/,$$2=/\f/g,E$2=/^---[ \t]*\n(.|\n)*\n---[ \t]*\n/,w$3=/^\s*?\[(x|\s)\]/,S$2=/^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,C$2=/^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/,A$2=/^([^\n]+)\n *(=|-){3,} *(?:\n *)+\n/,O$1=/^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?((?:[^>]*[^/])?)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i,T$2=/&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi,L$2=/^)/,R$1=/^(data|aria|x)-[a-z_][a-z\d_.-]*$/,z$3=/^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i,M$2=/^\{.*\}$/,I$2=/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,U$2=/^<([^ >]+@[^ >]+)>/,j$2=/^<([^ >]+:\/[^ >]+)>/,B$2=/-([a-z])?/gi,N$2=/^(.*\|.*)\n(?: *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*))?\n?/,H$2=/^\[([^\]]*)\]:\s+]+)>?\s*("([^"]*)")?/,D$2=/^!\[([^\]]*)\] ?\[([^\]]*)\]/,P$1=/^\[([^\]]*)\] ?\[([^\]]*)\]/,_$2=/(\[|\])/g,F$2=/(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/,W$2=/\t/g,G$2=/(^ *\||\| *$)/g,Z$2=/^ *:-+: *$/,q$4=/^ *:-+ *$/,V$2=/^ *-+: *$/,X$2="((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|~~.*?~~|==.*?==|.|\\n)*?)",Q$2=new RegExp(`^([*_])\\1${X$2}\\1\\1(?!\\1)`),J$2=new RegExp(`^([*_])${X$2}\\1(?!\\1|\\w)`),K$2=new RegExp(`^==${X$2}==`),Y$2=new RegExp(`^~~${X$2}~~`),ee$3=/^\\([^0-9A-Za-z\s])/,ne$3=/^[\s\S]+?(?=[^0-9A-Z\s\u00c0-\uffff&#;.()'"]|\d+\.|\n\n| {2,}\n|\w+:\S|$)/i,te$2=/^\n+/,re$3=/^([ \t]*)/,ie$2=/\\([^\\])/g,le$3=/ *\n+$/,oe$2=/(?:^|\n)( *)$/,ce$2="(?:\\d+\\.)",ae$2="(?:[*+-])";function se$2(rt){return"( *)("+(rt===1?ce$2:ae$2)+") +"}const de$2=se$2(1),ue$1=se$2(2);function pe$2(rt){return new RegExp("^"+(rt===1?de$2:ue$1))}const fe$2=pe$2(1),he$2=pe$2(2);function me$1(rt){return new RegExp("^"+(rt===1?de$2:ue$1)+"[^\\n]*(?:\\n(?!\\1"+(rt===1?ce$2:ae$2)+" )[^\\n]*)*(\\n|$)","gm")}const ge$3=me$1(1),ye$2=me$1(2);function ke$2(rt){const nt=rt===1?ce$2:ae$2;return new RegExp("^( *)("+nt+") [\\s\\S]+?(?:\\n{2,}(?! )(?!\\1"+nt+" (?!"+nt+" ))\\n*|\\s*\\n*$)")}const xe$2=ke$2(1),ve$2=ke$2(2);function be$2(rt,nt){const at=nt===1,st=at?xe$2:ve$2,ct=at?ge$3:ye$2,ut=at?fe$2:he$2;return{match(dt,pt,ft){const mt=oe$2.exec(ft);return mt&&(pt.list||!pt.inline&&!pt.simple)?st.exec(dt=mt[1]+dt):null},order:1,parse(dt,pt,ft){const mt=at?+dt[2]:void 0,ht=dt[0].replace(d$3,` `).match(ct);let yt=!1;return{items:ht.map(function($t,_t){const bt=ut.exec($t)[0].length,xt=new RegExp("^ {1,"+bt+"}","gm"),Rt=$t.replace(xt,"").replace(ut,""),St=_t===ht.length-1,kt=Rt.indexOf(` `)!==-1||St&&yt;yt=kt;const At=ft.inline,vt=ft.list;let wt;ft.list=!0,kt?(ft.inline=!1,wt=Rt.replace(le$3,` @@ -340,7 +340,7 @@ events. The Scivision project was set up by a team at the Alan Turing Institute. In addition to the channels above, you can email the team at [scivision@turing.ac.uk](mailto:scivision@turing.ac.uk) -`;function Community(){return jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{children:jsxRuntimeExports.jsx(ParseMarkdown,{markdown:content$2})})}function ModelGrid(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(ModelsHeader,{}),jsxRuntimeExports.jsx("div",{className:"mt-6 grid grid-cols-1 gap-x-6 gap-y-12 sm:gap-x-6 md:grid-cols-4 md:gap-y-12 lg:gap-x-8",children:models$1.entries.map(rt=>jsxRuntimeExports.jsx(Card,{name:rt.name,description:makeExcerpt(rt.description),tasks:rt.tasks,scivision_usable:rt.scivision_usable,type:"model"},rt.name))})]})}const global_CheckModelReport={time:"2024-12-16T03:44:47.900022",report:{stardist:{url:"https://github.com/stardist/stardist",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},PlantCV:{url:"https://github.com/danforthcenter/plantcv",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},greenotyper:{url:"https://github.com/MarniTausen/Greenotyper",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},"mapreader-plant":{url:"https://github.com/alan-turing-institute/mapreader-plant-scivision",check_result:"Fail",response:null},"resnet50-plankton":{url:"https://github.com/alan-turing-institute/plankton-cefas-scivision/tree/main/",check_result:"Fail",response:null},"vedge-detector":{url:"https://github.com/MartinSJRogers/VEdge_Detector_scivision/blob/main/",check_result:"Fail",response:null},"image-classifiers":{url:"https://github.com/alan-turing-institute/scivision_classifier",check_result:"Fail",response:null},"huggingface-classifiers":{url:"https://github.com/alan-turing-institute/scivision_huggingface",check_result:"Fail",response:null},"huggingface-segmentation":{url:"https://github.com/alan-turing-institute/scivision_huggingface_segmentation/tree/main",check_result:"Fail",response:null},"huggingface-object-detection":{url:"https://github.com/alan-turing-institute/scivision_huggingface_objectdetection/tree/main",check_result:"Fail",response:null},"detectreeRGB-forest":{url:"https://github.com/shmh40/detectreeRGB-treecrown-scivision",check_result:"Fail",response:null},"flower-classification-model":{url:"https://github.com/alan-turing-institute/flower_classification_model/tree/main",check_result:"Fail",response:null},"butterfly-classification-model":{url:"https://github.com/alan-turing-institute/butterfly_classification_model/tree/main/",check_result:"Fail",response:null},"Affinity-VAE":{url:"https://github.com/alan-turing-institute/affinity-vae",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},btrack:{url:"https://github.com/quantumjot/btrack",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},"StarDist Seed":{url:"https://raw.githubusercontent.com/alan-turing-institute/stardist-seed-pod/main/.scivision/model.yml",check_result:"Fail",response:""},"canopy-quality":{url:"https://github.com/johnfrancis13/canopy_quality_scivision/blob/main/.scivision/model.yaml",check_result:"Fail",response:""}}};var reactIs$2={exports:{}},reactIs_production_min$1={};/** +`;function Community(){return jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{children:jsxRuntimeExports.jsx(ParseMarkdown,{markdown:content$2})})}function ModelGrid(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(ModelsHeader,{}),jsxRuntimeExports.jsx("div",{className:"mt-6 grid grid-cols-1 gap-x-6 gap-y-12 sm:gap-x-6 md:grid-cols-4 md:gap-y-12 lg:gap-x-8",children:models$1.entries.map(rt=>jsxRuntimeExports.jsx(Card,{name:rt.name,description:makeExcerpt(rt.description),tasks:rt.tasks,scivision_usable:rt.scivision_usable,type:"model"},rt.name))})]})}const global_CheckModelReport={time:"2024-12-17T03:42:58.135848",report:{stardist:{url:"https://github.com/stardist/stardist",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},PlantCV:{url:"https://github.com/danforthcenter/plantcv",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},greenotyper:{url:"https://github.com/MarniTausen/Greenotyper",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},"mapreader-plant":{url:"https://github.com/alan-turing-institute/mapreader-plant-scivision",check_result:"Fail",response:null},"resnet50-plankton":{url:"https://github.com/alan-turing-institute/plankton-cefas-scivision/tree/main/",check_result:"Fail",response:null},"vedge-detector":{url:"https://github.com/MartinSJRogers/VEdge_Detector_scivision/blob/main/",check_result:"Fail",response:null},"image-classifiers":{url:"https://github.com/alan-turing-institute/scivision_classifier",check_result:"Fail",response:null},"huggingface-classifiers":{url:"https://github.com/alan-turing-institute/scivision_huggingface",check_result:"Fail",response:null},"huggingface-segmentation":{url:"https://github.com/alan-turing-institute/scivision_huggingface_segmentation/tree/main",check_result:"Fail",response:null},"huggingface-object-detection":{url:"https://github.com/alan-turing-institute/scivision_huggingface_objectdetection/tree/main",check_result:"Fail",response:null},"detectreeRGB-forest":{url:"https://github.com/shmh40/detectreeRGB-treecrown-scivision",check_result:"Fail",response:null},"flower-classification-model":{url:"https://github.com/alan-turing-institute/flower_classification_model/tree/main",check_result:"Fail",response:null},"butterfly-classification-model":{url:"https://github.com/alan-turing-institute/butterfly_classification_model/tree/main/",check_result:"Fail",response:null},"Affinity-VAE":{url:"https://github.com/alan-turing-institute/affinity-vae",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},btrack:{url:"https://github.com/quantumjot/btrack",check_result:"Pass",response:"Scivision_usable = False but model url response: 200"},"StarDist Seed":{url:"https://raw.githubusercontent.com/alan-turing-institute/stardist-seed-pod/main/.scivision/model.yml",check_result:"Fail",response:""},"canopy-quality":{url:"https://github.com/johnfrancis13/canopy_quality_scivision/blob/main/.scivision/model.yaml",check_result:"Fail",response:""}}};var reactIs$2={exports:{}},reactIs_production_min$1={};/** * @license React * react-is.production.min.js * @@ -913,9 +913,9 @@ This might be just the name of your package if your model is a python package on - Good example :white_check_mark:: \`sampleproject\` (install sampleproject from PyPI) - Good example :white_check_mark:: \`git+https://github.com/pypa/sampleproject@main\` (install sampleproject directly from GitHub, main branch) - Bad example :x:: \`pip install my-python-package\` (don't include the actual pip command, just the package name) -`,type:"string"},scivision_usable:{title:"Model runs with Scivision?",description:"Can the model be installed and loaded with the Scivision Python package, using the command below?\n\n```\nscivision.load_pretrained_model(, allow_install=True)\n```\n\nSelect 'no' if not sure",default:!1,type:"boolean"},url:{title:"Scivision metadata URL",description:"The URL to the Scivision metadata yaml file if the model runs with Scivision (leave blank if not)\n\n- Good example :white_check_mark:: `https://raw.githubusercontent.com/alan-turing-institute/scivision_classifier/main/.scivision/model.yml`",minLength:1,maxLength:65536,format:"uri",type:"string"},institution:{title:"Institutions or organizations",description:"A list of institutions or organizations that produced or are associated with the model (one per item)",default:[],type:"array",items:{type:"string"}},tags:{title:"Tags",description:"A list of free-form labels to associate with a model",default:[],type:"array",items:{type:"string"}}},required:["name","pkg_url"],additionalProperties:!1,definitions:{TaskEnum:{title:"TaskEnum",description:"An enumeration.",enum:["classification","object-detection","segmentation","thresholding","shape-analysis","object-tracking","other"],type:"string"}}};function ModelNew(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(PageTitle,{children:"Add a model to the catalog"}),jsxRuntimeExports.jsx("div",{className:"mt-6 border-t border-gray-100",children:jsxRuntimeExports.jsxs("dl",{className:"divide-y divide-gray-100",children:[jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"What is this?"})}),jsxRuntimeExports.jsxs("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0 md:text-base",children:[jsxRuntimeExports.jsxs("p",{children:["Use this form to propose a pre-trained model for inclusion in the catalog.",jsxRuntimeExports.jsx("br",{}),jsxRuntimeExports.jsx("br",{})]}),jsxRuntimeExports.jsx(CatalogFormHowItWorksBox,{})]})]}),jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"Prerequisites"})}),jsxRuntimeExports.jsx("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0",children:jsxRuntimeExports.jsx("div",{className:"prose mt-1 max-w-2xl text-sm leading-6 text-gray-500 md:text-base",children:jsxRuntimeExports.jsxs("ul",{className:"",children:[jsxRuntimeExports.jsxs("li",{children:["You have a GitHub account",jsxRuntimeExports.jsx("ul",{children:jsxRuntimeExports.jsxs("li",{children:["You can sign up for a free account by going to"," ",jsxRuntimeExports.jsx("a",{href:"https://github.com/",children:"https://github.com/"})]})})]}),jsxRuntimeExports.jsxs("li",{children:["Your model is publically available from a source repository or on a package server",jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsx("li",{children:"The Scivision catalog does not host your model, just a link to it, so it must be publically accessible somewhere"}),jsxRuntimeExports.jsx("li",{children:"For example, your model may be published on PyPI or have its source code available on GitHub, GitLab or elsewhere"})]})]}),jsxRuntimeExports.jsxs("li",{children:["Your model includes everything needed to run it, including any weights and parameters",jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsxs("li",{children:["Not ",jsxRuntimeExports.jsx("em",{children:"just"})," model weights"]}),jsxRuntimeExports.jsxs("li",{children:["Note: Models that require training or fitting to data before running can be suggested, but answer 'No' to"," ",jsxRuntimeExports.jsx("em",{children:"Model runs with Scivision?"})," ","below"]})]})]}),jsxRuntimeExports.jsxs("li",{children:["Your model is set up as a Python package, and is installable with pip",jsxRuntimeExports.jsx("ul",{children:jsxRuntimeExports.jsx("li",{children:"Your model could be published to PyPI or another package server, but installing from a direct link to the source repository is also accepted"})})]}),jsxRuntimeExports.jsxs("li",{children:[" ",jsxRuntimeExports.jsx("strong",{children:"(Optionally)"})," your model is in the"," ",jsxRuntimeExports.jsx("a",{href:"https://scivision.readthedocs.io/en/latest/model_repository_template.html#api",children:"correct format for Scivision"}),jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsxs("li",{children:["This has the benefit of allowing programmatic access to the model through"," ",jsxRuntimeExports.jsx("a",{href:"/scivisionpy",children:"Scivision.Py"})]}),jsxRuntimeExports.jsxs("li",{children:[" ","In this case,"," ",jsxRuntimeExports.jsx("em",{children:"Scivision metadata URL "}),"should be a direct link to the"," ",jsxRuntimeExports.jsx("a",{href:"https://scivision.readthedocs.io/en/latest/model_repository_template.html#model-config-file",children:"model config file"})," ","in your repository"]})]})]})]})})})]})]})}),jsxRuntimeExports.jsx("h2",{children:"Add your model"}),jsxRuntimeExports.jsxs("div",{className:"",children:[jsxRuntimeExports.jsx(CatalogEntryForm,{schema:schema$2,uiSchema:{"ui:title":" ",description:{"ui:widget":"textarea"},tasks:{"ui:widget":"checkboxes","ui:options":{inline:!0}},labels_provided:{"ui:widget":"radio"},scivision_usable:{"ui:widget":"radio"}},formData:JSON.parse(sessionStorage.getItem("new-model-form-data")),onChange:rt=>sessionStorage.setItem("new-model-form-data",JSON.stringify(rt.formData)),catalog_kind:"model",catalog_path:"src/scivision/catalog/data/models.json",download_filename:"one-model.json"}),jsxRuntimeExports.jsx("div",{className:"p-3"})]})]})}function DatasourceGrid(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(DataHeader,{}),jsxRuntimeExports.jsx("div",{className:"mt-6 grid grid-cols-1 gap-x-6 gap-y-12 sm:gap-x-6 md:grid-cols-4 md:gap-y-12 lg:gap-x-8",children:datasources.entries.map(rt=>jsxRuntimeExports.jsx(Card,{name:rt.name,description:makeExcerpt(rt.description),tasks:rt.tasks,type:"datasource"},rt.name))})]})}const global_CheckDatasetReport={time:"2024-12-16T03:32:16.726224",report:{"stardist-cell-nuclei-2D":{url:"https://github.com/stardist/stardist/releases/download/0.3.0/demo3D.zip",check_result:"Fail",response:null},"oppd-seedlings":{url:"https://github.com/alan-turing-institute/oppd-seedlings",check_result:"Pass",response:null},"scivision-test-data":{url:"https://github.com/alan-turing-institute/scivision-test-data",check_result:"Pass",response:null},"cefas-plankton":{url:"https://raw.githubusercontent.com/alan-turing-institute/plankton-cefas-scivision/test_data_catalog/scivision.yml",check_result:"Pass",response:null},"coastal-edges":{url:"https://github.com/MartinSJRogers/VEdge_Detector_scivision",check_result:"Pass",response:null},treecrowns:{url:"https://github.com/shmh40/detectreeRGB-treecrown-scivision",check_result:"Pass",response:null},sentinel2_stac:{url:"https://github.com/alan-turing-institute/scivision_sentinel2_stac",check_result:"Pass",response:null},flowers:{url:"https://github.com/nbarlowATI/flowers_data_repo",check_result:"Pass",response:null},butterflies:{url:"https://github.com/nbarlowATI/butterfly_data_repo",check_result:"Pass",response:null},Parakeet:{url:"https://github.com/rosalindfranklininstitute/scivision-parakeet-datasource/",check_result:"Pass",response:null},"cell-cycle-scivision":{url:"https://github.com/lowe-lab-ucl/cell-cycle-scivision",check_result:"Fail",response:null},"Phenotypic Profiling":{url:"https://github.com/Tonks684/phenotypic_profiling/blob/main/data.yml",check_result:"Fail",response:null},MapReader_Data_SIGSPATIAL_2022:{url:"https://github.com/alan-turing-institute/mapreader-scivision",check_result:"Pass",response:null},NPPC_B_napus:{url:"https://raw.githubusercontent.com/alan-turing-institute/nppc-bnapus-data/main/.scivision/data.yml",check_result:"Pass",response:null},"NHM-pinned-insects":{url:"https://raw.githubusercontent.com/LittleAri/Pinned_Insect_Labels/main/.scivision/data.yml",check_result:"Pass",response:null},"debug-zenodo":{url:"https://raw.githubusercontent.com/evangeline-corcoran/scivision-zenodo-debug/main/.scivision/data.yml",check_result:"Pass",response:null},fathomnet23:{url:"https://github.com/asthanameghna/FathomNet23/blob/main/scivision/data.yaml",check_result:"Pass",response:null},"Pixelflow Seed Demo Data":{url:"https://zenodo.org/api/records/8355920/files-archive",check_result:"Fail",response:null}}};function DatasourceDefinitionList({data:rt}){return jsxRuntimeExports.jsxs("dl",{className:"row",children:[jsxRuntimeExports.jsx("dt",{className:"col-sm-3",children:"Description"}),jsxRuntimeExports.jsx("dd",{className:"col-sm-9",children:rt.description?rt.description:"(none provided)"}),jsxRuntimeExports.jsx("dt",{className:"col-sm-3",children:"Location"}),jsxRuntimeExports.jsx("dd",{className:"col-sm-9",children:jsxRuntimeExports.jsx("a",{href:rt.url,children:rt.url})})]})}function DatasourceTableContents(){const rt=global_CheckDatasetReport;function nt(ut){if(rt!==null){const dt=rt.report[ut];return dt!==void 0?dt.check_result:"Unknown"}else return"Unknown"}function at(){if(rt){var ut=new Date(rt.time);return ut.toUTCString()}else return"(never)"}function st(){return`last run ${at()}`}const ct=[{name:"Thumbnail",width:"150px",selector:ut=>extractThumbnailFromName("datasource",ut.name)===void 0,sortable:!0,cell:ut=>{const dt=extractThumbnailFromName("datasource",ut.name);return renderThumbnailForTable(dt,ut.name,"datasource")}},{selector:ut=>ut.name,name:"Name",sortable:!0,grow:.5},{selector:ut=>ut.tasks,name:"Tasks",cell:ut=>ut.tasks.map(dt=>jsxRuntimeExports.jsx(TaskBadge,{taskName:dt},dt))},{selector:ut=>{const dt=nt(ut.name);return dt==="Pass"?jsxRuntimeExports.jsx("img",{src:"https://img.shields.io/badge/scivision_metadata-pass-green",title:"The metadata for this datasource was successfully loaded by scivision, from the location in the catalog"}):dt==="Fail"?jsxRuntimeExports.jsx("img",{src:"https://img.shields.io/badge/scivision_metadata-fail-red",title:"Scivision metadata (yaml) file for this datasource failed to load or was missing at the indicated location"}):jsxRuntimeExports.jsx("img",{src:"https://img.shields.io/badge/scivision_metadata-unknown-lightgray",title:"Could not access the result for this validation check"})},name:jsxRuntimeExports.jsx("span",{className:"tooltip-available",title:st(),children:"Validation checks"}),grow:.5}];return jsxRuntimeExports.jsx(Xe,{columns:ct,data:datasources.entries,defaultSortFieldId:2,title:"",expandableRowsComponent:ut=>jsxRuntimeExports.jsx(TableCardDropdown,{element:jsxRuntimeExports.jsx(DatasourceDefinitionList,{...ut})}),expandableRows:!0,expandableRowsHideExpander:!0,expandOnRowClicked:!0})}function DatasourceTable(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(DataHeader,{}),jsxRuntimeExports.jsx(DatasourceTableContents,{})]})}function DatasourceDetails(){const{datasource_name_encoded:rt}=useParams(),nt=rt&&decodeURIComponent(rt),at=datasources.entries.find(st=>st.name===nt);return console.log(at),jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[at?jsxRuntimeExports.jsx(DatasourceSingleView,{name:at.name,description:at.description,tasks:at.tasks,labels_provided:at.labels_provided,type:"datasource",url:at.url,tags:at.tags,domains:at.domains,institution:at.institution},at.name):jsxRuntimeExports.jsx("p",{children:"There is no data source with this name."}),jsxRuntimeExports.jsx("div",{className:" border-t-2 border-scipurple",children:jsxRuntimeExports.jsxs(Link,{to:"/datasource-grid",className:"flex gap-2 py-4 no-underline",children:[jsxRuntimeExports.jsx(ForwardRef$6,{className:"w-4"}),jsxRuntimeExports.jsx("span",{children:"Back to all data sources"})]})})]})}const schema$1={title:"Datasource catalog entry",type:"object",properties:{name:{title:"Name",description:`Short, unique name for the datasource (one or two words, under 20 characters recommended) +`,type:"string"},scivision_usable:{title:"Model runs with Scivision?",description:"Can the model be installed and loaded with the Scivision Python package, using the command below?\n\n```\nscivision.load_pretrained_model(, allow_install=True)\n```\n\nSelect 'no' if not sure",default:!1,type:"boolean"},url:{title:"Scivision metadata URL",description:"The URL to the Scivision metadata yaml file if the model runs with Scivision (leave blank if not)\n\n- Good example :white_check_mark:: `https://raw.githubusercontent.com/alan-turing-institute/scivision_classifier/main/.scivision/model.yml`",minLength:1,maxLength:65536,format:"uri",type:"string"},institution:{title:"Institutions or organizations",description:"A list of institutions or organizations that produced or are associated with the model (one per item)",default:[],type:"array",items:{type:"string"}},tags:{title:"Tags",description:"A list of free-form labels to associate with a model",default:[],type:"array",items:{type:"string"}}},required:["name","pkg_url"],additionalProperties:!1,definitions:{TaskEnum:{title:"TaskEnum",description:"An enumeration.",enum:["classification","object-detection","segmentation","thresholding","shape-analysis","object-tracking","other"],type:"string"}}};function ModelNew(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(PageTitle,{children:"Add a model to the catalog"}),jsxRuntimeExports.jsx("div",{className:"mt-6 border-t border-gray-100",children:jsxRuntimeExports.jsxs("dl",{className:"divide-y divide-gray-100",children:[jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"What is this?"})}),jsxRuntimeExports.jsxs("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0 md:text-base",children:[jsxRuntimeExports.jsxs("p",{children:["Use this form to propose a pre-trained model for inclusion in the catalog.",jsxRuntimeExports.jsx("br",{}),jsxRuntimeExports.jsx("br",{})]}),jsxRuntimeExports.jsx(CatalogFormHowItWorksBox,{})]})]}),jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"Prerequisites"})}),jsxRuntimeExports.jsx("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0",children:jsxRuntimeExports.jsx("div",{className:"prose mt-1 max-w-2xl text-sm leading-6 text-gray-500 md:text-base",children:jsxRuntimeExports.jsxs("ul",{className:"",children:[jsxRuntimeExports.jsxs("li",{children:["You have a GitHub account",jsxRuntimeExports.jsx("ul",{children:jsxRuntimeExports.jsxs("li",{children:["You can sign up for a free account by going to"," ",jsxRuntimeExports.jsx("a",{href:"https://github.com/",children:"https://github.com/"})]})})]}),jsxRuntimeExports.jsxs("li",{children:["Your model is publically available from a source repository or on a package server",jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsx("li",{children:"The Scivision catalog does not host your model, just a link to it, so it must be publically accessible somewhere"}),jsxRuntimeExports.jsx("li",{children:"For example, your model may be published on PyPI or have its source code available on GitHub, GitLab or elsewhere"})]})]}),jsxRuntimeExports.jsxs("li",{children:["Your model includes everything needed to run it, including any weights and parameters",jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsxs("li",{children:["Not ",jsxRuntimeExports.jsx("em",{children:"just"})," model weights"]}),jsxRuntimeExports.jsxs("li",{children:["Note: Models that require training or fitting to data before running can be suggested, but answer 'No' to"," ",jsxRuntimeExports.jsx("em",{children:"Model runs with Scivision?"})," ","below"]})]})]}),jsxRuntimeExports.jsxs("li",{children:["Your model is set up as a Python package, and is installable with pip",jsxRuntimeExports.jsx("ul",{children:jsxRuntimeExports.jsx("li",{children:"Your model could be published to PyPI or another package server, but installing from a direct link to the source repository is also accepted"})})]}),jsxRuntimeExports.jsxs("li",{children:[" ",jsxRuntimeExports.jsx("strong",{children:"(Optionally)"})," your model is in the"," ",jsxRuntimeExports.jsx("a",{href:"https://scivision.readthedocs.io/en/latest/model_repository_template.html#api",children:"correct format for Scivision"}),jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsxs("li",{children:["This has the benefit of allowing programmatic access to the model through"," ",jsxRuntimeExports.jsx("a",{href:"/scivisionpy",children:"Scivision.Py"})]}),jsxRuntimeExports.jsxs("li",{children:[" ","In this case,"," ",jsxRuntimeExports.jsx("em",{children:"Scivision metadata URL "}),"should be a direct link to the"," ",jsxRuntimeExports.jsx("a",{href:"https://scivision.readthedocs.io/en/latest/model_repository_template.html#model-config-file",children:"model config file"})," ","in your repository"]})]})]})]})})})]})]})}),jsxRuntimeExports.jsx("h2",{children:"Add your model"}),jsxRuntimeExports.jsxs("div",{className:"",children:[jsxRuntimeExports.jsx(CatalogEntryForm,{schema:schema$2,uiSchema:{"ui:title":" ",description:{"ui:widget":"textarea"},tasks:{"ui:widget":"checkboxes","ui:options":{inline:!0}},labels_provided:{"ui:widget":"radio"},scivision_usable:{"ui:widget":"radio"}},formData:JSON.parse(sessionStorage.getItem("new-model-form-data")),onChange:rt=>sessionStorage.setItem("new-model-form-data",JSON.stringify(rt.formData)),catalog_kind:"model",catalog_path:"src/scivision/catalog/data/models.json",download_filename:"one-model.json"}),jsxRuntimeExports.jsx("div",{className:"p-3"})]})]})}function DatasourceGrid(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(DataHeader,{}),jsxRuntimeExports.jsx("div",{className:"mt-6 grid grid-cols-1 gap-x-6 gap-y-12 sm:gap-x-6 md:grid-cols-4 md:gap-y-12 lg:gap-x-8",children:datasources.entries.map(rt=>jsxRuntimeExports.jsx(Card,{name:rt.name,description:makeExcerpt(rt.description),tasks:rt.tasks,type:"datasource"},rt.name))})]})}const global_CheckDatasetReport={time:"2024-12-17T03:31:09.207765",report:{"stardist-cell-nuclei-2D":{url:"https://github.com/stardist/stardist/releases/download/0.3.0/demo3D.zip",check_result:"Fail",response:null},"oppd-seedlings":{url:"https://github.com/alan-turing-institute/oppd-seedlings",check_result:"Pass",response:null},"scivision-test-data":{url:"https://github.com/alan-turing-institute/scivision-test-data",check_result:"Pass",response:null},"cefas-plankton":{url:"https://raw.githubusercontent.com/alan-turing-institute/plankton-cefas-scivision/test_data_catalog/scivision.yml",check_result:"Pass",response:null},"coastal-edges":{url:"https://github.com/MartinSJRogers/VEdge_Detector_scivision",check_result:"Pass",response:null},treecrowns:{url:"https://github.com/shmh40/detectreeRGB-treecrown-scivision",check_result:"Pass",response:null},sentinel2_stac:{url:"https://github.com/alan-turing-institute/scivision_sentinel2_stac",check_result:"Pass",response:null},flowers:{url:"https://github.com/nbarlowATI/flowers_data_repo",check_result:"Pass",response:null},butterflies:{url:"https://github.com/nbarlowATI/butterfly_data_repo",check_result:"Pass",response:null},Parakeet:{url:"https://github.com/rosalindfranklininstitute/scivision-parakeet-datasource/",check_result:"Pass",response:null},"cell-cycle-scivision":{url:"https://github.com/lowe-lab-ucl/cell-cycle-scivision",check_result:"Fail",response:null},"Phenotypic Profiling":{url:"https://github.com/Tonks684/phenotypic_profiling/blob/main/data.yml",check_result:"Fail",response:null},MapReader_Data_SIGSPATIAL_2022:{url:"https://github.com/alan-turing-institute/mapreader-scivision",check_result:"Pass",response:null},NPPC_B_napus:{url:"https://raw.githubusercontent.com/alan-turing-institute/nppc-bnapus-data/main/.scivision/data.yml",check_result:"Pass",response:null},"NHM-pinned-insects":{url:"https://raw.githubusercontent.com/LittleAri/Pinned_Insect_Labels/main/.scivision/data.yml",check_result:"Pass",response:null},"debug-zenodo":{url:"https://raw.githubusercontent.com/evangeline-corcoran/scivision-zenodo-debug/main/.scivision/data.yml",check_result:"Pass",response:null},fathomnet23:{url:"https://github.com/asthanameghna/FathomNet23/blob/main/scivision/data.yaml",check_result:"Pass",response:null},"Pixelflow Seed Demo Data":{url:"https://zenodo.org/api/records/8355920/files-archive",check_result:"Fail",response:null}}};function DatasourceDefinitionList({data:rt}){return jsxRuntimeExports.jsxs("dl",{className:"row",children:[jsxRuntimeExports.jsx("dt",{className:"col-sm-3",children:"Description"}),jsxRuntimeExports.jsx("dd",{className:"col-sm-9",children:rt.description?rt.description:"(none provided)"}),jsxRuntimeExports.jsx("dt",{className:"col-sm-3",children:"Location"}),jsxRuntimeExports.jsx("dd",{className:"col-sm-9",children:jsxRuntimeExports.jsx("a",{href:rt.url,children:rt.url})})]})}function DatasourceTableContents(){const rt=global_CheckDatasetReport;function nt(ut){if(rt!==null){const dt=rt.report[ut];return dt!==void 0?dt.check_result:"Unknown"}else return"Unknown"}function at(){if(rt){var ut=new Date(rt.time);return ut.toUTCString()}else return"(never)"}function st(){return`last run ${at()}`}const ct=[{name:"Thumbnail",width:"150px",selector:ut=>extractThumbnailFromName("datasource",ut.name)===void 0,sortable:!0,cell:ut=>{const dt=extractThumbnailFromName("datasource",ut.name);return renderThumbnailForTable(dt,ut.name,"datasource")}},{selector:ut=>ut.name,name:"Name",sortable:!0,grow:.5},{selector:ut=>ut.tasks,name:"Tasks",cell:ut=>ut.tasks.map(dt=>jsxRuntimeExports.jsx(TaskBadge,{taskName:dt},dt))},{selector:ut=>{const dt=nt(ut.name);return dt==="Pass"?jsxRuntimeExports.jsx("img",{src:"https://img.shields.io/badge/scivision_metadata-pass-green",title:"The metadata for this datasource was successfully loaded by scivision, from the location in the catalog"}):dt==="Fail"?jsxRuntimeExports.jsx("img",{src:"https://img.shields.io/badge/scivision_metadata-fail-red",title:"Scivision metadata (yaml) file for this datasource failed to load or was missing at the indicated location"}):jsxRuntimeExports.jsx("img",{src:"https://img.shields.io/badge/scivision_metadata-unknown-lightgray",title:"Could not access the result for this validation check"})},name:jsxRuntimeExports.jsx("span",{className:"tooltip-available",title:st(),children:"Validation checks"}),grow:.5}];return jsxRuntimeExports.jsx(Xe,{columns:ct,data:datasources.entries,defaultSortFieldId:2,title:"",expandableRowsComponent:ut=>jsxRuntimeExports.jsx(TableCardDropdown,{element:jsxRuntimeExports.jsx(DatasourceDefinitionList,{...ut})}),expandableRows:!0,expandableRowsHideExpander:!0,expandOnRowClicked:!0})}function DatasourceTable(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(DataHeader,{}),jsxRuntimeExports.jsx(DatasourceTableContents,{})]})}function DatasourceDetails(){const{datasource_name_encoded:rt}=useParams(),nt=rt&&decodeURIComponent(rt),at=datasources.entries.find(st=>st.name===nt);return console.log(at),jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[at?jsxRuntimeExports.jsx(DatasourceSingleView,{name:at.name,description:at.description,tasks:at.tasks,labels_provided:at.labels_provided,type:"datasource",url:at.url,tags:at.tags,domains:at.domains,institution:at.institution},at.name):jsxRuntimeExports.jsx("p",{children:"There is no data source with this name."}),jsxRuntimeExports.jsx("div",{className:" border-t-2 border-scipurple",children:jsxRuntimeExports.jsxs(Link,{to:"/datasource-grid",className:"flex gap-2 py-4 no-underline",children:[jsxRuntimeExports.jsx(ForwardRef$6,{className:"w-4"}),jsxRuntimeExports.jsx("span",{children:"Back to all data sources"})]})})]})}const schema$1={title:"Datasource catalog entry",type:"object",properties:{name:{title:"Name",description:`Short, unique name for the datasource (one or two words, under 20 characters recommended) - Good example :white_check_mark:: **Foobar Penguins** - Okay example :heavy_check_mark:: **foobar-penguins** - Bad example :x:: **dataset-123** (prefer a descriptive name) -- Bad example :x:: **Data from the Foobar penguin study** (too long; no need to include 'data' in the title)`,type:"string"},description:{title:"Description",description:"Detailed description of the dataset (no length limit)",type:"string"},url:{title:"URL",description:"The URL to the datasource. If your datasource has an associated Scivision yaml file, this should point to it. Otherwise, give a URL for downloading the data\n\n- Good example :white_check_mark:: `https://example.com/path/to/datasource.yml` (location of the Scivision yml file)\n- Good example :white_check_mark:: `https://example.com/dataset/download/data.zip` (data download URL)\n- Bad example :x:: `example.com/path/to/datasource.yml` (missing URL scheme, like 'https://')\n",minLength:1,maxLength:65536,format:"uri",type:"string"},tasks:{title:"Suitable tasks",description:"For which computer vision task or tasks is this datasource likely to be suitable? Select any number",type:"array",items:{$ref:"#/definitions/TaskEnum"},uniqueItems:!0},labels_provided:{title:"Labels included?",description:"Does the datasource contain labelled examples, suitable for model training or validation?",default:!1,type:"boolean"},domains:{title:"Domain areas",description:"Which domain area or areas is this datasource from? (One per item, no duplicates)",uniqueItems:!0,type:"array",items:{type:"string",examples:["optical-microscopy","multispectral","hyperspectral","computer-vision","earth-observation","ecology",null,"optical microscopy","cell biology","fluorescent microscopy","urban-planning","history","biology","agriculture","plant-biology","entomology","marine-biology"]}},institution:{title:"Institutions or organizations",description:"A list of institutions or organizations that produced or are associated with the dataset (one per item)",default:[],type:"array",items:{type:"string",examples:["epfl","Aarhus University","Wikipedia by Erik Veland","Centre for Environment, Fisheries and Aquaculture Science (CEFAS)","Cambridge University","The Alan Turing Institute","Rosalind Franklin Institute","UCL","Broad Institute","Aberystwyth University","National Plant Phenomics Centre","Natural History Museum","Rothamsted Research"]}},tags:{title:"Tags",description:"A list of free-form labels to associate with a datasource",default:[],type:"array",items:{type:"string",examples:["help-needed","3D","cell","cell-counting","biology","biomedical-science","2D","plant-phenotyping","agriculture","climate-change-and-agriculture","demo","plankton","ecology","environmental-science","satellite","remote-sensing","drone","aerial","butterflies","insects","animals","CryoEM",NaN,"fluorescence microscopy ","bioimaging","humanities","museum-collections","ocr","pinned-insects","debugging","marine-biology","species-classification"]}}},required:["name"],additionalProperties:!1,definitions:{TaskEnum:{title:"TaskEnum",description:"An enumeration.",enum:["classification","object-detection","segmentation","thresholding","shape-analysis","object-tracking","other"],type:"string"}}};function DatasourceNew(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(PageTitle,{children:"Add a datasource to the catalog"}),jsxRuntimeExports.jsx("div",{className:"mt-6 border-t border-gray-100",children:jsxRuntimeExports.jsxs("dl",{className:"divide-y divide-gray-100",children:[jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"What is this?"})}),jsxRuntimeExports.jsxs("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0 md:text-base",children:[jsxRuntimeExports.jsxs("p",{children:["Use this form if you have a dataset you would like to be included in the Datasource catalog.",jsxRuntimeExports.jsx("br",{}),jsxRuntimeExports.jsx("br",{})]}),jsxRuntimeExports.jsx(CatalogFormHowItWorksBox,{})]})]}),jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"Prerequisites"})}),jsxRuntimeExports.jsx("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0",children:jsxRuntimeExports.jsx("div",{className:"prose mt-1 max-w-2xl text-sm leading-6 text-gray-500 md:text-base",children:jsxRuntimeExports.jsxs("ul",{className:"list-spaced",children:[jsxRuntimeExports.jsxs("li",{children:["You have a GitHub account",jsxRuntimeExports.jsx("ul",{children:jsxRuntimeExports.jsxs("li",{children:["You can sign up for a free account by going to"," ",jsxRuntimeExports.jsx("a",{href:"https://github.com/",children:"https://github.com/"})]})})]}),jsxRuntimeExports.jsxs("li",{children:[" ","Your data is in a publicly accessible location (for example, on"," ",jsxRuntimeExports.jsx("a",{href:"https://zenodo.org/",children:"Zenodo"}),")",jsxRuntimeExports.jsx("ul",{children:jsxRuntimeExports.jsx("li",{children:"The Scivision catalog does not host your data directly, just some metadata about it, so this must be accessible elsewhere"})})]}),jsxRuntimeExports.jsxs("li",{children:[" ",jsxRuntimeExports.jsx("strong",{children:"(Optionally)"})," Your data repository is in the"," ",jsxRuntimeExports.jsx("a",{href:"https://scivision.readthedocs.io/en/latest/data_repository_template.html#requirements-for-the-scivision-api",children:"format expected by Scivision"})," ",jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsxs("li",{children:["This has the benefit of allowing programmatic access to the data using"," "," ",jsxRuntimeExports.jsx("a",{href:"/scivisionpy",children:"Scivision.Py"})]}),jsxRuntimeExports.jsxs("li",{children:[" ","If it is in the Scivision format, ",jsxRuntimeExports.jsx("em",{children:"URL "}),"should be a direct link to the"," ",jsxRuntimeExports.jsx("a",{href:"https://scivision.readthedocs.io/en/latest/data_repository_template.html#data-config-file",children:"data config file"})," ","in your repository"]})]})]})]})})})]})]})}),jsxRuntimeExports.jsx("h2",{children:"Add your datasource"}),jsxRuntimeExports.jsxs("div",{className:"",children:[jsxRuntimeExports.jsx(CatalogEntryForm,{schema:schema$1,uiSchema:{"ui:title":" ",description:{"ui:widget":"textarea"},tasks:{"ui:widget":"checkboxes","ui:options":{inline:!0}},labels_provided:{"ui:widget":"radio"}},formData:JSON.parse(sessionStorage.getItem("new-datasource-form-data")),onChange:rt=>sessionStorage.setItem("new-datasource-form-data",JSON.stringify(rt.formData)),catalog_kind:"datasource",catalog_path:"src/scivision/catalog/data/datasources.json",download_filename:"one-datasource.json"}),jsxRuntimeExports.jsx("div",{className:"p-3"})]})]})}function ProjectGrid(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(ProjectsHeader,{}),jsxRuntimeExports.jsx("div",{className:"mt-6 grid grid-cols-1 gap-x-6 gap-y-12 sm:gap-x-6 md:grid-cols-2 md:gap-y-12 lg:gap-x-8",children:projects.entries.map(rt=>jsxRuntimeExports.jsx(ProjectCard,{name:rt.name,description:makeExcerpt(rt.description),tasks:rt.tasks,type:"project",header:rt.header},rt.name))})]})}function ProjectDefinitionList({data:rt}){return jsxRuntimeExports.jsxs("dl",{className:"row",children:[jsxRuntimeExports.jsx("dt",{className:"col-sm-3",children:rt.header?rt.header:"(none provided)"}),jsxRuntimeExports.jsx("dd",{className:"col-sm-9",children:rt.description?rt.description:"(none provided)"})]})}function ProjectTableContents(){const rt=[{name:"Thumbnail",width:"150px",selector:nt=>extractThumbnailFromName("project",nt.name)===void 0,sortable:!0,cell:nt=>{const at=extractThumbnailFromName("project",nt.name);return renderThumbnailForTable(at,nt.name,"project")}},{selector:nt=>nt.name,name:"Name",sortable:!0,grow:.3},{selector:nt=>nt.tasks,name:"Tasks",cell:nt=>nt.tasks.map(at=>jsxRuntimeExports.jsx(TaskBadge,{taskName:at},at))}];return jsxRuntimeExports.jsx(Xe,{columns:rt,data:projects.entries,defaultSortFieldId:2,title:"",expandableRowsComponent:nt=>jsxRuntimeExports.jsx(TableCardDropdown,{element:jsxRuntimeExports.jsx(ProjectDefinitionList,{...nt})}),expandableRows:!0,expandableRowsHideExpander:!0,expandOnRowClicked:!0})}function ProjectTable(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(ProjectsHeader,{}),jsxRuntimeExports.jsx(ProjectTableContents,{})]})}function ProjectDetails(){const{project_name_encoded:rt}=useParams(),nt=rt&&decodeURIComponent(rt),at=projects.entries.find(st=>st.name===nt);return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[at?jsxRuntimeExports.jsx(ProjectSingleView,{name:at.name,description:at.description,tasks:at.tasks,type:"project",page:at.page,header:at.header,tags:at.tags,models:at.models,datasources:at.datasources,institution:at.institution},at.name):jsxRuntimeExports.jsx("p",{children:"There is no project with this name."}),jsxRuntimeExports.jsx("div",{className:" border-t-2 border-scipurple",children:jsxRuntimeExports.jsxs(Link,{to:"/project-grid",className:"flex gap-2 py-4 no-underline",children:[jsxRuntimeExports.jsx(ForwardRef$6,{className:"w-4"}),jsxRuntimeExports.jsx("span",{children:"Back to all projects"})]})})]})}const schema={title:"A project catalog entry",type:"object",properties:{name:{title:"Name",description:"Short, unique name for the project (one or two words, under 20 characters recommended)",type:"string"},header:{title:"Header",description:"Header that will display at the top of the project page",type:"string"},description:{title:"Description",description:"Short description of the project (that will appear when hovering on the project thumbnail)",type:"string"},page:{title:"Page",description:"Markdown formatted content for the project page",type:"string"},models:{title:"Models",description:"Which model(s) from the Scivision catalog are used in the project? (There must be at least one model)",default:[],type:"array",items:{type:"string"}},datasources:{title:"Datasources",description:"Which datasource(s) from the Scivision catalog are used in the project? (There must be at least one datasource)",default:[],type:"array",items:{type:"string"}},tasks:{title:"Tasks",description:"Which task (or tasks) do the CV models used in the project perform?",default:[],type:"array",items:{$ref:"#/definitions/TaskEnum"},uniqueItems:!0},institution:{title:"Institutions or organizations",description:"A list of institutions or organizations that produced or are associated with the project (one per item)",default:[],type:"array",items:{type:"string"}},tags:{title:"Tags",type:"array",items:{type:"string"}}},required:["name","header","tags"],additionalProperties:!1,definitions:{TaskEnum:{title:"TaskEnum",description:"An enumeration.",enum:["classification","object-detection","segmentation","thresholding","shape-analysis","object-tracking","other"],type:"string"}}};function ProjectNew(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(PageTitle,{children:"Create a Scivision project page for your research"}),jsxRuntimeExports.jsx("div",{className:"mt-6 border-t border-gray-100",children:jsxRuntimeExports.jsxs("dl",{className:"divide-y divide-gray-100",children:[jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"Prerequisites"})}),jsxRuntimeExports.jsx("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0 md:text-base",children:jsxRuntimeExports.jsx("div",{className:"prose mt-1 max-w-2xl text-sm leading-6 text-gray-500",children:jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsxs("li",{children:["You have already added the datasource(s) used in your project to the"," ",jsxRuntimeExports.jsx(Link,{to:"../datasource-grid",children:"Scivision Data catalog"}),". Click here to add a"," ",jsxRuntimeExports.jsx(Link,{to:"../new-datasource",children:"new datasource"}),"."]}),jsxRuntimeExports.jsxs("li",{children:["You have already added the computer vision model(s) used in your project to the"," ",jsxRuntimeExports.jsx(Link,{to:"../model-grid",children:"Scivision Model catalog"}),". Click here to add a"," ",jsxRuntimeExports.jsx(Link,{to:"../new-model",children:"new model"}),"."]})]})})})]}),jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"Add your project"})}),jsxRuntimeExports.jsx("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0 md:text-base",children:jsxRuntimeExports.jsxs("div",{className:"prose mt-1 max-w-2xl text-sm leading-6 text-gray-500",children:[jsxRuntimeExports.jsxs("p",{children:["Add the details that will form the basis of your project's Scivision page below. You can format the text with"," ",jsxRuntimeExports.jsx("a",{href:"https://daringfireball.net/projects/markdown/basics",children:"Markdown"}),", which will allow you to include any headers, lists and links you feel are appropriate. You can then link to your model(s) / data."]}),jsxRuntimeExports.jsxs("p",{children:["Using this form will generate a json file in the right format for you to submit to GitHub. Open an issue in the"," ",jsxRuntimeExports.jsx("a",{href:"https://github.com/alan-turing-institute/scivision",children:"scivision repository"}),", attaching this json file and an appropriate thumbnail, to add your project to the catalog. Further discussion is possible at that point, so it doesn't need to be complete or perfect at this stage."]})]})})]})]})}),jsxRuntimeExports.jsx("h2",{children:"Add your project"}),jsxRuntimeExports.jsxs("div",{className:"",children:[jsxRuntimeExports.jsx(CatalogEntryForm,{schema,uiSchema:{"ui:title":" ",page:{"ui:widget":"textarea"},tasks:{"ui:widget":"checkboxes","ui:options":{inline:!0}}},formData:JSON.parse(sessionStorage.getItem("new-project-form-data")),onChange:rt=>sessionStorage.setItem("new-project-form-data",JSON.stringify(rt.formData)),catalog_kind:"project",catalog_path:"src/scivision/catalog/data/projects.json",download_filename:"one-project.json"}),jsxRuntimeExports.jsx("div",{className:"p-3"})]})]})}const router=createBrowserRouter(createRoutesFromChildren(jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(HomeLayout,{}),children:jsxRuntimeExports.jsx(Route,{index:!0,element:jsxRuntimeExports.jsx(Home,{})})}),jsxRuntimeExports.jsxs(Route,{element:jsxRuntimeExports.jsx(DefaultLayout,{}),children:[jsxRuntimeExports.jsx(Route,{path:"/about",element:jsxRuntimeExports.jsx(About,{})}),jsxRuntimeExports.jsx(Route,{path:"/model-grid",element:jsxRuntimeExports.jsx(ModelGrid,{})}),jsxRuntimeExports.jsx(Route,{path:"/model-table",element:jsxRuntimeExports.jsx(ModelTable,{})}),jsxRuntimeExports.jsx(Route,{path:"/model/:model_name_encoded",element:jsxRuntimeExports.jsx(ModelDetails,{})}),jsxRuntimeExports.jsx(Route,{path:"/new-model",element:jsxRuntimeExports.jsx(ModelNew,{})}),jsxRuntimeExports.jsx(Route,{path:"/datasource-grid",element:jsxRuntimeExports.jsx(DatasourceGrid,{})}),jsxRuntimeExports.jsx(Route,{path:"/datasource-table",element:jsxRuntimeExports.jsx(DatasourceTable,{})}),jsxRuntimeExports.jsx(Route,{path:"/datasource/:datasource_name_encoded",element:jsxRuntimeExports.jsx(DatasourceDetails,{})}),jsxRuntimeExports.jsx(Route,{path:"/new-datasource",element:jsxRuntimeExports.jsx(DatasourceNew,{})}),jsxRuntimeExports.jsx(Route,{path:"/project-grid",element:jsxRuntimeExports.jsx(ProjectGrid,{})}),jsxRuntimeExports.jsx(Route,{path:"/project-table",element:jsxRuntimeExports.jsx(ProjectTable,{})}),jsxRuntimeExports.jsx(Route,{path:"/project/:project_name_encoded",element:jsxRuntimeExports.jsx(ProjectDetails,{})}),jsxRuntimeExports.jsx(Route,{path:"/new-project",element:jsxRuntimeExports.jsx(ProjectNew,{})}),jsxRuntimeExports.jsx(Route,{path:"/contribute",element:jsxRuntimeExports.jsx(Contribute,{})}),jsxRuntimeExports.jsx(Route,{path:"/scivisionpy",element:jsxRuntimeExports.jsx(ScivisionPy,{})}),jsxRuntimeExports.jsx(Route,{path:"/community",element:jsxRuntimeExports.jsx(Community,{})})]})]})));client.createRoot(document.getElementById("root")).render(jsxRuntimeExports.jsx(React.StrictMode,{children:jsxRuntimeExports.jsx(RouterProvider,{router})}));export{getDefaultExportFromCjs$1 as g,reactExports as r}; +- Bad example :x:: **Data from the Foobar penguin study** (too long; no need to include 'data' in the title)`,type:"string"},description:{title:"Description",description:"Detailed description of the dataset (no length limit)",type:"string"},url:{title:"URL",description:"The URL to the datasource. If your datasource has an associated Scivision yaml file, this should point to it. Otherwise, give a URL for downloading the data\n\n- Good example :white_check_mark:: `https://example.com/path/to/datasource.yml` (location of the Scivision yml file)\n- Good example :white_check_mark:: `https://example.com/dataset/download/data.zip` (data download URL)\n- Bad example :x:: `example.com/path/to/datasource.yml` (missing URL scheme, like 'https://')\n",minLength:1,maxLength:65536,format:"uri",type:"string"},tasks:{title:"Suitable tasks",description:"For which computer vision task or tasks is this datasource likely to be suitable? Select any number",type:"array",items:{$ref:"#/definitions/TaskEnum"},uniqueItems:!0},labels_provided:{title:"Labels included?",description:"Does the datasource contain labelled examples, suitable for model training or validation?",default:!1,type:"boolean"},domains:{title:"Domain areas",description:"Which domain area or areas is this datasource from? (One per item, no duplicates)",uniqueItems:!0,type:"array",items:{type:"string",examples:["optical-microscopy","multispectral","hyperspectral","computer-vision","ecology","earth-observation",null,"optical microscopy","cell biology","fluorescent microscopy","urban-planning","history","agriculture","biology","plant-biology","entomology","marine-biology"]}},institution:{title:"Institutions or organizations",description:"A list of institutions or organizations that produced or are associated with the dataset (one per item)",default:[],type:"array",items:{type:"string",examples:["epfl","Aarhus University","Wikipedia by Erik Veland","Centre for Environment, Fisheries and Aquaculture Science (CEFAS)","Cambridge University","The Alan Turing Institute","Rosalind Franklin Institute","UCL","Broad Institute","Aberystwyth University","National Plant Phenomics Centre","Natural History Museum","Rothamsted Research"]}},tags:{title:"Tags",description:"A list of free-form labels to associate with a datasource",default:[],type:"array",items:{type:"string",examples:["help-needed","3D","cell","cell-counting","biology","biomedical-science","2D","plant-phenotyping","agriculture","climate-change-and-agriculture","demo","plankton","ecology","environmental-science","satellite","remote-sensing","drone","aerial","butterflies","insects","animals","CryoEM",NaN,"fluorescence microscopy ","bioimaging","humanities","museum-collections","ocr","pinned-insects","debugging","marine-biology","species-classification"]}}},required:["name"],additionalProperties:!1,definitions:{TaskEnum:{title:"TaskEnum",description:"An enumeration.",enum:["classification","object-detection","segmentation","thresholding","shape-analysis","object-tracking","other"],type:"string"}}};function DatasourceNew(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(PageTitle,{children:"Add a datasource to the catalog"}),jsxRuntimeExports.jsx("div",{className:"mt-6 border-t border-gray-100",children:jsxRuntimeExports.jsxs("dl",{className:"divide-y divide-gray-100",children:[jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"What is this?"})}),jsxRuntimeExports.jsxs("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0 md:text-base",children:[jsxRuntimeExports.jsxs("p",{children:["Use this form if you have a dataset you would like to be included in the Datasource catalog.",jsxRuntimeExports.jsx("br",{}),jsxRuntimeExports.jsx("br",{})]}),jsxRuntimeExports.jsx(CatalogFormHowItWorksBox,{})]})]}),jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"Prerequisites"})}),jsxRuntimeExports.jsx("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0",children:jsxRuntimeExports.jsx("div",{className:"prose mt-1 max-w-2xl text-sm leading-6 text-gray-500 md:text-base",children:jsxRuntimeExports.jsxs("ul",{className:"list-spaced",children:[jsxRuntimeExports.jsxs("li",{children:["You have a GitHub account",jsxRuntimeExports.jsx("ul",{children:jsxRuntimeExports.jsxs("li",{children:["You can sign up for a free account by going to"," ",jsxRuntimeExports.jsx("a",{href:"https://github.com/",children:"https://github.com/"})]})})]}),jsxRuntimeExports.jsxs("li",{children:[" ","Your data is in a publicly accessible location (for example, on"," ",jsxRuntimeExports.jsx("a",{href:"https://zenodo.org/",children:"Zenodo"}),")",jsxRuntimeExports.jsx("ul",{children:jsxRuntimeExports.jsx("li",{children:"The Scivision catalog does not host your data directly, just some metadata about it, so this must be accessible elsewhere"})})]}),jsxRuntimeExports.jsxs("li",{children:[" ",jsxRuntimeExports.jsx("strong",{children:"(Optionally)"})," Your data repository is in the"," ",jsxRuntimeExports.jsx("a",{href:"https://scivision.readthedocs.io/en/latest/data_repository_template.html#requirements-for-the-scivision-api",children:"format expected by Scivision"})," ",jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsxs("li",{children:["This has the benefit of allowing programmatic access to the data using"," "," ",jsxRuntimeExports.jsx("a",{href:"/scivisionpy",children:"Scivision.Py"})]}),jsxRuntimeExports.jsxs("li",{children:[" ","If it is in the Scivision format, ",jsxRuntimeExports.jsx("em",{children:"URL "}),"should be a direct link to the"," ",jsxRuntimeExports.jsx("a",{href:"https://scivision.readthedocs.io/en/latest/data_repository_template.html#data-config-file",children:"data config file"})," ","in your repository"]})]})]})]})})})]})]})}),jsxRuntimeExports.jsx("h2",{children:"Add your datasource"}),jsxRuntimeExports.jsxs("div",{className:"",children:[jsxRuntimeExports.jsx(CatalogEntryForm,{schema:schema$1,uiSchema:{"ui:title":" ",description:{"ui:widget":"textarea"},tasks:{"ui:widget":"checkboxes","ui:options":{inline:!0}},labels_provided:{"ui:widget":"radio"}},formData:JSON.parse(sessionStorage.getItem("new-datasource-form-data")),onChange:rt=>sessionStorage.setItem("new-datasource-form-data",JSON.stringify(rt.formData)),catalog_kind:"datasource",catalog_path:"src/scivision/catalog/data/datasources.json",download_filename:"one-datasource.json"}),jsxRuntimeExports.jsx("div",{className:"p-3"})]})]})}function ProjectGrid(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(ProjectsHeader,{}),jsxRuntimeExports.jsx("div",{className:"mt-6 grid grid-cols-1 gap-x-6 gap-y-12 sm:gap-x-6 md:grid-cols-2 md:gap-y-12 lg:gap-x-8",children:projects.entries.map(rt=>jsxRuntimeExports.jsx(ProjectCard,{name:rt.name,description:makeExcerpt(rt.description),tasks:rt.tasks,type:"project",header:rt.header},rt.name))})]})}function ProjectDefinitionList({data:rt}){return jsxRuntimeExports.jsxs("dl",{className:"row",children:[jsxRuntimeExports.jsx("dt",{className:"col-sm-3",children:rt.header?rt.header:"(none provided)"}),jsxRuntimeExports.jsx("dd",{className:"col-sm-9",children:rt.description?rt.description:"(none provided)"})]})}function ProjectTableContents(){const rt=[{name:"Thumbnail",width:"150px",selector:nt=>extractThumbnailFromName("project",nt.name)===void 0,sortable:!0,cell:nt=>{const at=extractThumbnailFromName("project",nt.name);return renderThumbnailForTable(at,nt.name,"project")}},{selector:nt=>nt.name,name:"Name",sortable:!0,grow:.3},{selector:nt=>nt.tasks,name:"Tasks",cell:nt=>nt.tasks.map(at=>jsxRuntimeExports.jsx(TaskBadge,{taskName:at},at))}];return jsxRuntimeExports.jsx(Xe,{columns:rt,data:projects.entries,defaultSortFieldId:2,title:"",expandableRowsComponent:nt=>jsxRuntimeExports.jsx(TableCardDropdown,{element:jsxRuntimeExports.jsx(ProjectDefinitionList,{...nt})}),expandableRows:!0,expandableRowsHideExpander:!0,expandOnRowClicked:!0})}function ProjectTable(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(ProjectsHeader,{}),jsxRuntimeExports.jsx(ProjectTableContents,{})]})}function ProjectDetails(){const{project_name_encoded:rt}=useParams(),nt=rt&&decodeURIComponent(rt),at=projects.entries.find(st=>st.name===nt);return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[at?jsxRuntimeExports.jsx(ProjectSingleView,{name:at.name,description:at.description,tasks:at.tasks,type:"project",page:at.page,header:at.header,tags:at.tags,models:at.models,datasources:at.datasources,institution:at.institution},at.name):jsxRuntimeExports.jsx("p",{children:"There is no project with this name."}),jsxRuntimeExports.jsx("div",{className:" border-t-2 border-scipurple",children:jsxRuntimeExports.jsxs(Link,{to:"/project-grid",className:"flex gap-2 py-4 no-underline",children:[jsxRuntimeExports.jsx(ForwardRef$6,{className:"w-4"}),jsxRuntimeExports.jsx("span",{children:"Back to all projects"})]})})]})}const schema={title:"A project catalog entry",type:"object",properties:{name:{title:"Name",description:"Short, unique name for the project (one or two words, under 20 characters recommended)",type:"string"},header:{title:"Header",description:"Header that will display at the top of the project page",type:"string"},description:{title:"Description",description:"Short description of the project (that will appear when hovering on the project thumbnail)",type:"string"},page:{title:"Page",description:"Markdown formatted content for the project page",type:"string"},models:{title:"Models",description:"Which model(s) from the Scivision catalog are used in the project? (There must be at least one model)",default:[],type:"array",items:{type:"string"}},datasources:{title:"Datasources",description:"Which datasource(s) from the Scivision catalog are used in the project? (There must be at least one datasource)",default:[],type:"array",items:{type:"string"}},tasks:{title:"Tasks",description:"Which task (or tasks) do the CV models used in the project perform?",default:[],type:"array",items:{$ref:"#/definitions/TaskEnum"},uniqueItems:!0},institution:{title:"Institutions or organizations",description:"A list of institutions or organizations that produced or are associated with the project (one per item)",default:[],type:"array",items:{type:"string"}},tags:{title:"Tags",type:"array",items:{type:"string"}}},required:["name","header","tags"],additionalProperties:!1,definitions:{TaskEnum:{title:"TaskEnum",description:"An enumeration.",enum:["classification","object-detection","segmentation","thresholding","shape-analysis","object-tracking","other"],type:"string"}}};function ProjectNew(){return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(PageTitle,{children:"Create a Scivision project page for your research"}),jsxRuntimeExports.jsx("div",{className:"mt-6 border-t border-gray-100",children:jsxRuntimeExports.jsxs("dl",{className:"divide-y divide-gray-100",children:[jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"Prerequisites"})}),jsxRuntimeExports.jsx("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0 md:text-base",children:jsxRuntimeExports.jsx("div",{className:"prose mt-1 max-w-2xl text-sm leading-6 text-gray-500",children:jsxRuntimeExports.jsxs("ul",{children:[jsxRuntimeExports.jsxs("li",{children:["You have already added the datasource(s) used in your project to the"," ",jsxRuntimeExports.jsx(Link,{to:"../datasource-grid",children:"Scivision Data catalog"}),". Click here to add a"," ",jsxRuntimeExports.jsx(Link,{to:"../new-datasource",children:"new datasource"}),"."]}),jsxRuntimeExports.jsxs("li",{children:["You have already added the computer vision model(s) used in your project to the"," ",jsxRuntimeExports.jsx(Link,{to:"../model-grid",children:"Scivision Model catalog"}),". Click here to add a"," ",jsxRuntimeExports.jsx(Link,{to:"../new-model",children:"new model"}),"."]})]})})})]}),jsxRuntimeExports.jsxs("div",{className:"px-4 py-6 sm:grid sm:grid-cols-4 sm:gap-4 sm:px-0",children:[jsxRuntimeExports.jsx("dt",{className:"text-sm font-medium leading-6 text-gray-900",children:jsxRuntimeExports.jsx("h3",{children:"Add your project"})}),jsxRuntimeExports.jsx("dd",{className:"mt-1 text-sm leading-6 text-gray-700 sm:col-span-3 sm:mt-0 md:text-base",children:jsxRuntimeExports.jsxs("div",{className:"prose mt-1 max-w-2xl text-sm leading-6 text-gray-500",children:[jsxRuntimeExports.jsxs("p",{children:["Add the details that will form the basis of your project's Scivision page below. You can format the text with"," ",jsxRuntimeExports.jsx("a",{href:"https://daringfireball.net/projects/markdown/basics",children:"Markdown"}),", which will allow you to include any headers, lists and links you feel are appropriate. You can then link to your model(s) / data."]}),jsxRuntimeExports.jsxs("p",{children:["Using this form will generate a json file in the right format for you to submit to GitHub. Open an issue in the"," ",jsxRuntimeExports.jsx("a",{href:"https://github.com/alan-turing-institute/scivision",children:"scivision repository"}),", attaching this json file and an appropriate thumbnail, to add your project to the catalog. Further discussion is possible at that point, so it doesn't need to be complete or perfect at this stage."]})]})})]})]})}),jsxRuntimeExports.jsx("h2",{children:"Add your project"}),jsxRuntimeExports.jsxs("div",{className:"",children:[jsxRuntimeExports.jsx(CatalogEntryForm,{schema,uiSchema:{"ui:title":" ",page:{"ui:widget":"textarea"},tasks:{"ui:widget":"checkboxes","ui:options":{inline:!0}}},formData:JSON.parse(sessionStorage.getItem("new-project-form-data")),onChange:rt=>sessionStorage.setItem("new-project-form-data",JSON.stringify(rt.formData)),catalog_kind:"project",catalog_path:"src/scivision/catalog/data/projects.json",download_filename:"one-project.json"}),jsxRuntimeExports.jsx("div",{className:"p-3"})]})]})}const router=createBrowserRouter(createRoutesFromChildren(jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(Route,{element:jsxRuntimeExports.jsx(HomeLayout,{}),children:jsxRuntimeExports.jsx(Route,{index:!0,element:jsxRuntimeExports.jsx(Home,{})})}),jsxRuntimeExports.jsxs(Route,{element:jsxRuntimeExports.jsx(DefaultLayout,{}),children:[jsxRuntimeExports.jsx(Route,{path:"/about",element:jsxRuntimeExports.jsx(About,{})}),jsxRuntimeExports.jsx(Route,{path:"/model-grid",element:jsxRuntimeExports.jsx(ModelGrid,{})}),jsxRuntimeExports.jsx(Route,{path:"/model-table",element:jsxRuntimeExports.jsx(ModelTable,{})}),jsxRuntimeExports.jsx(Route,{path:"/model/:model_name_encoded",element:jsxRuntimeExports.jsx(ModelDetails,{})}),jsxRuntimeExports.jsx(Route,{path:"/new-model",element:jsxRuntimeExports.jsx(ModelNew,{})}),jsxRuntimeExports.jsx(Route,{path:"/datasource-grid",element:jsxRuntimeExports.jsx(DatasourceGrid,{})}),jsxRuntimeExports.jsx(Route,{path:"/datasource-table",element:jsxRuntimeExports.jsx(DatasourceTable,{})}),jsxRuntimeExports.jsx(Route,{path:"/datasource/:datasource_name_encoded",element:jsxRuntimeExports.jsx(DatasourceDetails,{})}),jsxRuntimeExports.jsx(Route,{path:"/new-datasource",element:jsxRuntimeExports.jsx(DatasourceNew,{})}),jsxRuntimeExports.jsx(Route,{path:"/project-grid",element:jsxRuntimeExports.jsx(ProjectGrid,{})}),jsxRuntimeExports.jsx(Route,{path:"/project-table",element:jsxRuntimeExports.jsx(ProjectTable,{})}),jsxRuntimeExports.jsx(Route,{path:"/project/:project_name_encoded",element:jsxRuntimeExports.jsx(ProjectDetails,{})}),jsxRuntimeExports.jsx(Route,{path:"/new-project",element:jsxRuntimeExports.jsx(ProjectNew,{})}),jsxRuntimeExports.jsx(Route,{path:"/contribute",element:jsxRuntimeExports.jsx(Contribute,{})}),jsxRuntimeExports.jsx(Route,{path:"/scivisionpy",element:jsxRuntimeExports.jsx(ScivisionPy,{})}),jsxRuntimeExports.jsx(Route,{path:"/community",element:jsxRuntimeExports.jsx(Community,{})})]})]})));client.createRoot(document.getElementById("root")).render(jsxRuntimeExports.jsx(React.StrictMode,{children:jsxRuntimeExports.jsx(RouterProvider,{router})}));export{getDefaultExportFromCjs$1 as g,reactExports as r}; diff --git a/index.html b/index.html index 329c2f47..2a598163 100644 --- a/index.html +++ b/index.html @@ -17,7 +17,7 @@ Scivision - +