diff --git a/css/app.d1886bd3.css b/css/app.9436b4cb.css similarity index 99% rename from css/app.d1886bd3.css rename to css/app.9436b4cb.css index c1342e6c..2a018322 100644 --- a/css/app.d1886bd3.css +++ b/css/app.9436b4cb.css @@ -1,4 +1,4 @@ -@import url(https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap);body,html{overflow:auto!important;width:100vw;height:100vh;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;overscroll-behavior-y:none}#app,body,html{background:#fff}.card{margin-bottom:3rem}.content-wrapper{margin-top:3rem}.card-footer-item{font-size:12px;font-weight:400}.card-header-title{display:block}.card-content p{margin-bottom:2rem}.container{max-width:95%}.fa-code,.fa-search{margin-right:.5vw}.width-limited{max-width:1080px;margin-left:auto!important;margin-right:auto!important;float:none!important}.container[data-v-1f19381b]{width:860px}.dropdown-panel[data-v-1f19381b]{width:100%;max-width:580px;padding:15px;height:400px;overflow-y:scroll;max-height:100vh}.card[data-v-1f19381b]{height:360px}.card-content[data-v-1f19381b]{padding:1rem}.authors[data-v-1f19381b]{font-size:.9em;font-weight:600}.model-description[data-v-1f19381b]{font-size:.9em}.action-btn[data-v-1f19381b]{width:33px}.button.is-small[data-v-1f19381b]{border-radius:30px;font-size:1rem;background-color:rgba(210,235,255,.7803921568627451);color:#19191a}.card-image[data-v-1f19381b]{max-height:200px}.center[data-v-1f19381b]{display:flex;justify-content:center;align-items:center}.tag[data-v-1f19381b]:hover{background:#2196f3!important;color:#fff}.tags-button[data-v-1f19381b]{top:1px;height:34px;left:4px;text-transform:none}.searchbar[data-v-1f19381b]{width:500px;max-width:calc(100% - 110px);margin-left:10px;border-style:solid;border-width:3px;border-color:#2196f3;height:42px;margin-top:-3px}.display-mode-btn[data-v-1f19381b]{top:1px;margin-left:7px;height:34px}.app-icons[data-v-e10eb140]{margin-top:5px;margin-left:5px;display:inline-block}.app-icon[data-v-e10eb140]{width:20px!important;max-width:22px;max-height:22px;-o-object-fit:contain;object-fit:contain;transform:translateY(2px)}.action-btn[data-v-e10eb140]{width:33px}.action-btn .icon[data-v-e10eb140]{font-size:1.4rem}.button.is-small[data-v-e10eb140]{border-radius:30px;font-size:.8rem;background-color:hsla(0,0%,100%,.85);color:#2196f3}a.badge[data-v-68bfc2b0]{display:inline-block;padding:1px}.badge-img[data-v-68bfc2b0]{position:relative;transform:translateY(6px)}.badge[data-v-68bfc2b0]{display:inline-block;padding:1px;margin-top:-5px;margin-bottom:-5px}.tags[data-v-68bfc2b0]:not(:last-child){margin-bottom:-10px}.badges[data-v-68bfc2b0]{display:inline-block}.tag[data-v-68bfc2b0]:not(body){padding-left:4px;padding-right:4px;font-size:.7rem;font-weight:520;height:20px;border-radius:3px;font-family:DejaVu Sans,Verdana,Geneva,sans-serif}.action-btn[data-v-3ba6a4a2]{width:33px}.action-btn .icon[data-v-3ba6a4a2]{font-size:1.4rem}.resource-item-card[data-v-19aa8d02]{max-width:500px}.card[data-v-19aa8d02]{height:360px}.card-image[data-v-19aa8d02]{height:160px}.card-content[data-v-19aa8d02]{padding-left:1rem;padding-right:1rem;padding-top:4px}.resource-item-title[data-v-19aa8d02]{margin-top:6px;margin-bottom:2px;font-size:1.2em;font-weight:400;cursor:pointer;color:#2196f3}.authors[data-v-19aa8d02]{font-size:.9em;font-weight:600}.resource-item-description[data-v-19aa8d02]{font-size:.9em}.floating-buttons[data-v-19aa8d02]{position:absolute;top:0;left:5px}.cover-image[data-v-19aa8d02]{height:160px;max-height:180px;-o-object-fit:contain;object-fit:contain}.carousel-image[data-v-19aa8d02]{max-height:180px;background:#000;text-align:center}.item-icon[data-v-19aa8d02]{position:absolute;top:125px;display:inline-block;margin-top:auto;margin-bottom:auto;border:3px solid transparent;margin-right:4px;width:32px;max-width:100px}.badges[data-v-19aa8d02]{position:absolute;left:5px;bottom:5px}.truncated[data-v-19aa8d02]{width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.resource-pagination[data-v-af27f312]{margin-top:10px}.resource-item-list[data-v-af27f312]{min-height:60vh}.badges[data-v-af27f312]{left:5px;bottom:5px}a.badge[data-v-af27f312]{display:inline-block;padding:1px}.action-btn[data-v-af27f312]{width:33px}.action-btn .icon[data-v-af27f312]{font-size:1.4rem}.button.is-small[data-v-af27f312]{border-radius:30px;font-size:.8rem;background-color:hsla(0,0%,100%,.85);color:#2196f3}.resource-card[data-v-af27f312]{height:400px;min-width:320px}#bioengine-web-client[data-v-7853cd72]{width:100%;height:100%;margin-bottom:10px}#ij-tips[data-v-7853cd72]{margin-bottom:10px}#ij-container[data-v-7853cd72]{width:100%;height:600px;border:1px solid #ccc}.resource-item-info[data-v-429d117f]{padding:20px;height:calc(100% - 50px);overflow:auto;-ms-scroll-chaining:none;overscroll-behavior:contain}@media screen and (max-width:768px){.resource-item-info[data-v-429d117f]{padding:5px}}.card-image[data-v-429d117f]{max-height:500px}.citation[data-v-429d117f]{list-style-type:circle}.cover-image[data-v-429d117f]{-o-object-fit:contain;object-fit:contain}.badge[data-v-429d117f]{display:inline-block;padding:1px;margin-top:-5px;margin-bottom:-5px}.tags[data-v-429d117f]:not(:last-child){margin-bottom:-10px}.authors[data-v-429d117f]{margin-left:10px}.resource-id[data-v-429d117f]{padding:3px;font-size:1.1rem;display:inline-block;margin-right:5px}.not-available[data-v-429d117f]{color:red}.partners>h2[data-v-a2e6d4aa]{margin-top:2px;margin-bottom:10px;font-size:1.3rem;color:#407ae6}.partners[data-v-a2e6d4aa]{width:100%!important;background-color:hsla(0,0%,99.2%,.9921568627450981);text-align:center;width:100vw;max-width:100vw;bottom:0;right:0;left:0;margin-right:0;margin-left:0}.carousel-list[data-v-a2e6d4aa]{padding-left:100px;padding-right:100px}.partner-logo[data-v-a2e6d4aa]{height:80px;max-height:100px;width:auto;margin-bottom:10px}@media screen and (max-width:1024px){.carousel-list[data-v-a2e6d4aa]{padding-left:30px;padding-right:30px}}@media screen and (max-width:500px){.partner-logo[data-v-a2e6d4aa]{height:60px}.partners>h2[data-v-a2e6d4aa]{font-size:1.2rem}.carousel-list[data-v-a2e6d4aa]{padding-left:10px;padding-right:10px}}@media screen and (max-height:500px){.partners[data-v-a2e6d4aa]{height:100px}.partner-logo[data-v-a2e6d4aa]{height:50px}.partners>h2[data-v-a2e6d4aa]{display:none}}.carousel-list.has-shadow[data-v-a2e6d4aa]{box-shadow:unset!important}.pagination-list{list-style:none}.pagination{width:80%}.modal-card-title{font-size:1.1rem;overflow-wrap:break-word;text-overflow:ellipsis;width:100%}.navbar-item,.navbar-link{font-size:1.5rem}.navbar-item:focus,.navbar-item:hover{background:#a8d8ff!important}.resource-item-card:hover{transition:all .4s;-webkit-transition:all .4s;box-shadow:0 10px 16px 0 rgba(0,0,0,.2),0 6px 20px 0 rgba(0,0,0,.19)}.b-tooltip.is-primary:after{background:#2196f3!important}.card-image{max-height:200px}.vm--modal{max-height:100%;max-width:100%}.dialog-header{height:40px;font-size:1.4rem;cursor:move;background-color:#2196f3;color:#fff;text-align:center;line-height:40px}.dialog-control-button{cursor:pointer;width:34px!important;min-width:34px!important;max-width:34px!important;height:36px;line-height:30px;padding-bottom:7px;border:0;font-size:2rem;position:relative;color:#fff;top:2px;font-family:Lucida Console,Monaco,monospace}.dialog-control-button:focus{outline:none}.item-lists{padding-bottom:2px;width:110px;display:inline-block;margin:10px;text-align:center;cursor:pointer;font-size:1.2em;color:#4f5050;border-bottom:2px solid;border-radius:5px}.item-lists:hover{font-weight:500}.item-lists.active{color:#2396f3;font-weight:800}.noselect{-webkit-touch-callout:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.background-img{position:absolute;bottom:142px;right:0;opacity:.8;width:55%;transition:.9s ease;max-height:30%;max-width:100%;-o-object-fit:contain;object-fit:contain}.hero:hover .background-img{width:45%;transition:.4s ease}.feature-list{padding-left:30px;font-size:1.5em}.explore-btn{font-size:1.3rem}.site-title{font-size:2.2em;padding-top:10px;padding-left:4px}.site-icon{font-size:3em;margin-left:10px}.dialog-title{font-size:1.4rem}@media screen and (max-width:500px){.feature-list{font-size:1em}}@media screen and (max-height:700px){.feature-list{display:none}}@media screen and (max-width:768px){.dialog-title{font-size:1.1rem}.site-title{font-size:2em!important}.site-icon{font-size:2.3em}.title{font-size:1.8rem!important}.subtitle{font-size:1.5rem!important}.feature-list{font-size:1em!important}.explore-btn{font-size:1.1rem!important}.hide-on-small-screen{display:none}}.hover-show{opacity:0;transition:.3s ease}.card:hover .hover-show{opacity:1;transition:.3s ease}.markdown-container{padding:20px;overflow:auto;-ms-scroll-chaining:none;overscroll-behavior:contain;height:calc(100% - 40px)}body,html{overflow-x:hidden}form{max-width:100%!important}.autocomplete .dropdown-content{display:block!important;width:100%}.autocomplete>.dropdown-menu>.dropdown-content{display:block!important;width:100%}.upload[data-v-cd23c57a]{padding:10px;width:100%;overflow:auto;display:block;background:#fff;background-repeat:no-repeat;background-position:bottom} +@import url(https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap);body,html{overflow:auto!important;width:100vw;height:100vh;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;overscroll-behavior-y:none}#app,body,html{background:#fff}.card{margin-bottom:3rem}.content-wrapper{margin-top:3rem}.card-footer-item{font-size:12px;font-weight:400}.card-header-title{display:block}.card-content p{margin-bottom:2rem}.container{max-width:95%}.fa-code,.fa-search{margin-right:.5vw}.width-limited{max-width:1080px;margin-left:auto!important;margin-right:auto!important;float:none!important}.container[data-v-1f19381b]{width:860px}.dropdown-panel[data-v-1f19381b]{width:100%;max-width:580px;padding:15px;height:400px;overflow-y:scroll;max-height:100vh}.card[data-v-1f19381b]{height:360px}.card-content[data-v-1f19381b]{padding:1rem}.authors[data-v-1f19381b]{font-size:.9em;font-weight:600}.model-description[data-v-1f19381b]{font-size:.9em}.action-btn[data-v-1f19381b]{width:33px}.button.is-small[data-v-1f19381b]{border-radius:30px;font-size:1rem;background-color:rgba(210,235,255,.7803921568627451);color:#19191a}.card-image[data-v-1f19381b]{max-height:200px}.center[data-v-1f19381b]{display:flex;justify-content:center;align-items:center}.tag[data-v-1f19381b]:hover{background:#2196f3!important;color:#fff}.tags-button[data-v-1f19381b]{top:1px;height:34px;left:4px;text-transform:none}.searchbar[data-v-1f19381b]{width:500px;max-width:calc(100% - 110px);margin-left:10px;border-style:solid;border-width:3px;border-color:#2196f3;height:42px;margin-top:-3px}.display-mode-btn[data-v-1f19381b]{top:1px;margin-left:7px;height:34px}.app-icons[data-v-e10eb140]{margin-top:5px;margin-left:5px;display:inline-block}.app-icon[data-v-e10eb140]{width:20px!important;max-width:22px;max-height:22px;-o-object-fit:contain;object-fit:contain;transform:translateY(2px)}.action-btn[data-v-e10eb140]{width:33px}.action-btn .icon[data-v-e10eb140]{font-size:1.4rem}.button.is-small[data-v-e10eb140]{border-radius:30px;font-size:.8rem;background-color:hsla(0,0%,100%,.85);color:#2196f3}a.badge[data-v-68bfc2b0]{display:inline-block;padding:1px}.badge-img[data-v-68bfc2b0]{position:relative;transform:translateY(6px)}.badge[data-v-68bfc2b0]{display:inline-block;padding:1px;margin-top:-5px;margin-bottom:-5px}.tags[data-v-68bfc2b0]:not(:last-child){margin-bottom:-10px}.badges[data-v-68bfc2b0]{display:inline-block}.tag[data-v-68bfc2b0]:not(body){padding-left:4px;padding-right:4px;font-size:.7rem;font-weight:520;height:20px;border-radius:3px;font-family:DejaVu Sans,Verdana,Geneva,sans-serif}.action-btn[data-v-3ba6a4a2]{width:33px}.action-btn .icon[data-v-3ba6a4a2]{font-size:1.4rem}.resource-item-card[data-v-19aa8d02]{max-width:500px}.card[data-v-19aa8d02]{height:360px}.card-image[data-v-19aa8d02]{height:160px}.card-content[data-v-19aa8d02]{padding-left:1rem;padding-right:1rem;padding-top:4px}.resource-item-title[data-v-19aa8d02]{margin-top:6px;margin-bottom:2px;font-size:1.2em;font-weight:400;cursor:pointer;color:#2196f3}.authors[data-v-19aa8d02]{font-size:.9em;font-weight:600}.resource-item-description[data-v-19aa8d02]{font-size:.9em}.floating-buttons[data-v-19aa8d02]{position:absolute;top:0;left:5px}.cover-image[data-v-19aa8d02]{height:160px;max-height:180px;-o-object-fit:contain;object-fit:contain}.carousel-image[data-v-19aa8d02]{max-height:180px;background:#000;text-align:center}.item-icon[data-v-19aa8d02]{position:absolute;top:125px;display:inline-block;margin-top:auto;margin-bottom:auto;border:3px solid transparent;margin-right:4px;width:32px;max-width:100px}.badges[data-v-19aa8d02]{position:absolute;left:5px;bottom:5px}.truncated[data-v-19aa8d02]{width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.resource-pagination[data-v-af27f312]{margin-top:10px}.resource-item-list[data-v-af27f312]{min-height:60vh}.badges[data-v-af27f312]{left:5px;bottom:5px}a.badge[data-v-af27f312]{display:inline-block;padding:1px}.action-btn[data-v-af27f312]{width:33px}.action-btn .icon[data-v-af27f312]{font-size:1.4rem}.button.is-small[data-v-af27f312]{border-radius:30px;font-size:.8rem;background-color:hsla(0,0%,100%,.85);color:#2196f3}.resource-card[data-v-af27f312]{height:400px;min-width:320px}#bioengine-web-client[data-v-7853cd72]{width:100%;height:100%;margin-bottom:10px}#ij-tips[data-v-7853cd72]{margin-bottom:10px}#ij-container[data-v-7853cd72]{width:100%;height:600px;border:1px solid #ccc}.resource-item-info[data-v-23d78b12]{padding:20px;height:calc(100% - 50px);overflow:auto;-ms-scroll-chaining:none;overscroll-behavior:contain}@media screen and (max-width:768px){.resource-item-info[data-v-23d78b12]{padding:5px}}.card-image[data-v-23d78b12]{max-height:500px}.citation[data-v-23d78b12]{list-style-type:circle}.cover-image[data-v-23d78b12]{-o-object-fit:contain;object-fit:contain}.badge[data-v-23d78b12]{display:inline-block;padding:1px;margin-top:-5px;margin-bottom:-5px}.tags[data-v-23d78b12]:not(:last-child){margin-bottom:-10px}.authors[data-v-23d78b12]{margin-left:10px}.resource-id[data-v-23d78b12]{padding:3px;font-size:1.1rem;display:inline-block;margin-right:5px}.not-available[data-v-23d78b12]{color:red}.partners>h2[data-v-a2e6d4aa]{margin-top:2px;margin-bottom:10px;font-size:1.3rem;color:#407ae6}.partners[data-v-a2e6d4aa]{width:100%!important;background-color:hsla(0,0%,99.2%,.9921568627450981);text-align:center;width:100vw;max-width:100vw;bottom:0;right:0;left:0;margin-right:0;margin-left:0}.carousel-list[data-v-a2e6d4aa]{padding-left:100px;padding-right:100px}.partner-logo[data-v-a2e6d4aa]{height:80px;max-height:100px;width:auto;margin-bottom:10px}@media screen and (max-width:1024px){.carousel-list[data-v-a2e6d4aa]{padding-left:30px;padding-right:30px}}@media screen and (max-width:500px){.partner-logo[data-v-a2e6d4aa]{height:60px}.partners>h2[data-v-a2e6d4aa]{font-size:1.2rem}.carousel-list[data-v-a2e6d4aa]{padding-left:10px;padding-right:10px}}@media screen and (max-height:500px){.partners[data-v-a2e6d4aa]{height:100px}.partner-logo[data-v-a2e6d4aa]{height:50px}.partners>h2[data-v-a2e6d4aa]{display:none}}.carousel-list.has-shadow[data-v-a2e6d4aa]{box-shadow:unset!important}.pagination-list{list-style:none}.pagination{width:80%}.modal-card-title{font-size:1.1rem;overflow-wrap:break-word;text-overflow:ellipsis;width:100%}.navbar-item,.navbar-link{font-size:1.5rem}.navbar-item:focus,.navbar-item:hover{background:#a8d8ff!important}.resource-item-card:hover{transition:all .4s;-webkit-transition:all .4s;box-shadow:0 10px 16px 0 rgba(0,0,0,.2),0 6px 20px 0 rgba(0,0,0,.19)}.b-tooltip.is-primary:after{background:#2196f3!important}.card-image{max-height:200px}.vm--modal{max-height:100%;max-width:100%}.dialog-header{height:40px;font-size:1.4rem;cursor:move;background-color:#2196f3;color:#fff;text-align:center;line-height:40px}.dialog-control-button{cursor:pointer;width:34px!important;min-width:34px!important;max-width:34px!important;height:36px;line-height:30px;padding-bottom:7px;border:0;font-size:2rem;position:relative;color:#fff;top:2px;font-family:Lucida Console,Monaco,monospace}.dialog-control-button:focus{outline:none}.item-lists{padding-bottom:2px;width:110px;display:inline-block;margin:10px;text-align:center;cursor:pointer;font-size:1.2em;color:#4f5050;border-bottom:2px solid;border-radius:5px}.item-lists:hover{font-weight:500}.item-lists.active{color:#2396f3;font-weight:800}.noselect{-webkit-touch-callout:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.background-img{position:absolute;bottom:142px;right:0;opacity:.8;width:55%;transition:.9s ease;max-height:30%;max-width:100%;-o-object-fit:contain;object-fit:contain}.hero:hover .background-img{width:45%;transition:.4s ease}.feature-list{padding-left:30px;font-size:1.5em}.explore-btn{font-size:1.3rem}.site-title{font-size:2.2em;padding-top:10px;padding-left:4px}.site-icon{font-size:3em;margin-left:10px}.dialog-title{font-size:1.4rem}@media screen and (max-width:500px){.feature-list{font-size:1em}}@media screen and (max-height:700px){.feature-list{display:none}}@media screen and (max-width:768px){.dialog-title{font-size:1.1rem}.site-title{font-size:2em!important}.site-icon{font-size:2.3em}.title{font-size:1.8rem!important}.subtitle{font-size:1.5rem!important}.feature-list{font-size:1em!important}.explore-btn{font-size:1.1rem!important}.hide-on-small-screen{display:none}}.hover-show{opacity:0;transition:.3s ease}.card:hover .hover-show{opacity:1;transition:.3s ease}.markdown-container{padding:20px;overflow:auto;-ms-scroll-chaining:none;overscroll-behavior:contain;height:calc(100% - 40px)}body,html{overflow-x:hidden}form{max-width:100%!important}.autocomplete .dropdown-content{display:block!important;width:100%}.autocomplete>.dropdown-menu>.dropdown-content{display:block!important;width:100%}.upload[data-v-cd23c57a]{padding:10px;width:100%;overflow:auto;display:block;background:#fff;background-repeat:no-repeat;background-position:bottom} /*! Buefy v0.8.20 | MIT License | github.com/buefy/buefy */@-webkit-keyframes fadeOut{0%{opacity:1}to{opacity:0}}@-webkit-keyframes fadeOutDown{0%{opacity:1}to{opacity:0;transform:translate3d(0,100%,0)}}@-webkit-keyframes fadeOutUp{0%{opacity:1}to{opacity:0;transform:translate3d(0,-100%,0)}}@-webkit-keyframes fadeIn{0%{opacity:0}to{opacity:1}}@-webkit-keyframes fadeInDown{0%{opacity:0;transform:translate3d(0,-100%,0)}to{opacity:1;transform:none}}@-webkit-keyframes fadeInUp{0%{opacity:0;transform:translate3d(0,100%,0)}to{opacity:1;transform:none}} diff --git a/index.html b/index.html index 29ced1a4..7dccb3c3 100644 --- a/index.html +++ b/index.html @@ -48,7 +48,7 @@ })(); - +
- + \ No newline at end of file diff --git a/js/app.24c33c94.js b/js/app.24c33c94.js new file mode 100644 index 00000000..faac0b81 --- /dev/null +++ b/js/app.24c33c94.js @@ -0,0 +1,2 @@ +(function(e){function t(t){for(var i,r,s=t[0],c=t[1],l=t[2],u=0,d=[];u",MAX_RDF_VERSION))throw new Error("Unsupported format version ".concat(e.format_version," (it must <=").concat(MAX_RDF_VERSION,")"));if(!spdx_license_list_full__WEBPACK_IMPORTED_MODULE_29___default.a[e.license])throw new Error("Invalid license, the license identifier must be one from the SPDX license list (https://spdx.org/licenses/)");if(!e.type)throw new Error("`type` key is not defined in the RDF.");e.covers=e.covers||[];var i,r=e.covers.map((function(e){return e.startsWith("http")?e:new URL(e,t).href})),o=[],a=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_createForOfIteratorHelper__WEBPACK_IMPORTED_MODULE_25__["a"])(r);try{for(a.s();!(i=a.n()).done;){var s=i.value;if(s.includes("access_token="))throw new Error("Cover URL should not contain access token: "+s);o.push({relation:"hasPart",identifier:s,resource_type:"image-figure",scheme:"url"})}}catch(h){a.e(h)}finally{a.f()}e.links=e.links||[];var c,l=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_createForOfIteratorHelper__WEBPACK_IMPORTED_MODULE_25__["a"])(e.links);try{for(l.s();!(c=l.n()).done;){var u=c.value;if(u.includes("access_token="))throw new Error("Link should not contain access token: "+u);o.push({identifier:"https://bioimage.io/#/r/"+encodeURIComponent(u),relation:"references",resource_type:"other",scheme:"url"})}}catch(h){l.e(h)}finally{l.f()}if(!e.rdf_source)throw new Error("`rdf_source` key is not found in the RDF");var d=e.rdf_source.startsWith("http")?e.rdf_source:new URL(e.rdf_source,t).href;if(d.startsWith("http")&&d.includes("api/files")&&(d=d.split("/"),d=d[d.length-1],d=new URL(d,t).href),o.push({identifier:d,relation:"isCompiledBy",resource_type:"other",scheme:"url"}),e.documentation){if(e.documentation.includes("access_token="))throw new Error("Documentation URL should not contain access token");o.push({identifier:e.documentation.startsWith("http")?e.documentation:new URL(e.documentation,t).href,relation:"isDocumentedBy",resource_type:"publication-technicalnote",scheme:"url"})}e.authors=e.authors||[];var p=e.authors.map((function(e){return"string"===typeof e?{name:e.split(";")[0],affiliation:""}:{name:e.name.split(";")[0],affiliation:e.affiliation,orcid:e.orcid}})),_='Download RDF Package
')+(n&&"

".concat(n,"

")||""),m=["bioimage.io","bioimage.io:"+e.type],f={title:e.name,description:_,access_right:"open",license:e.license,upload_type:"other",creators:p,publication_date:(new Date).toISOString().split("T")[0],keywords:m.concat(e.tags),notes:e.description+additionalNote,related_identifiers:o,communities:[]};return f}function depositionToRdf(e){var t=e.metadata,n=t.keywords.filter((function(e){return e.startsWith("bioimage.io:")}))[0];if(!n)throw new Error("deposit (".concat(e.id,') does not contain a bioimage.io type keyword starts with "bioimage.io:"'));n=n.replace("bioimage.io:","");var i,r=[],o=[],a=null,s=null,c=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_createForOfIteratorHelper__WEBPACK_IMPORTED_MODULE_25__["a"])(t.related_identifiers);try{for(c.s();!(i=c.n()).done;){var l=i.value;if("isCompiledBy"===l.relation&&"url"===l.scheme)if(a=l.identifier,a.startsWith("file://"))a=a.replace("file://",e.links.bucket+"/");else{if(!a.includes("/files/"))throw new Error("Invalid file identifier: "+l.identifier);var u=a.includes("/api/files/")?/.*zenodo.org\/api\/files\/.*\/(.*)/:/.*zenodo.org\/.*\/files\/(.*)/,d=u.exec(a);if(!d)throw new Error("Invalid file identifier: "+l.identifier);var p=d[1];a="".concat(e.links.bucket,"/").concat(p)}else if("hasPart"===l.relation&&"image-figure"===l.resource_type&&"url"===l.scheme){var _=l.identifier;if(_.startsWith("file://"))_=_.replace("file://",e.links.bucket+"/");else if(_.includes("".concat(e.id,"/files/"))){var m=_.includes("/api/files/")?/.*zenodo.org\/api\/files\/.*\/(.*)/:/.*zenodo.org\/.*\/files\/(.*)/,f=m.exec(_);f?_="".concat(e.links.bucket,"/").concat(f[1]):console.error("Invalid cover image file identifier: "+l.identifier)}else console.error("Invalid cover image file identifier: "+l.identifier);r.push(_)}else if("references"===l.relation&&"url"===l.scheme&&l.identifier.startsWith("https://bioimage.io/#/r/")){var h=l.identifier.replace("https://bioimage.io/#/r/","");o.push(decodeURIComponent(h))}else if("isDocumentedBy"===l.relation&&"url"===l.scheme){var g=l.identifier.split("/files/")[1];s=g?"".concat(e.links.bucket,"/").concat(g):l.identifier}}}catch(y){c.e(y)}finally{c.f()}var b=t.notes.replace(additionalNote,"");if(!a)throw new Error("Invalid deposit (".concat(e.id,'), rdf.yaml or model.yaml is not defined in the metadata (as part of the "related_identifiers")'));return{id:e.conceptdoi,name:t.title,type:n,authors:t.creators,tags:t.keywords.filter((function(e){return"bioimage.io"!==e||!e.startsWith("bioimage.io:")})).concat(["zenodo"]),description:b,stats:e.stats,license:"string"===typeof t.license?t.license:t.license.id,documentation:s,covers:r,links:o,rdf_source:a,config:{_doi:e.doi,_conceptdoi:e.conceptdoi,_deposit:e}}}function getUserId(e){return e&&(e.credential&&e.credential.user_id||e.lastUserId)}var ZenodoClient=function(){function e(t,n,i){Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_classCallCheck__WEBPACK_IMPORTED_MODULE_23__["a"])(this,e),this.baseURL=t,this.clientId=n,this.isSandbox=i,this.lastUserId=null,this.callbackUrl=encodeURIComponent("https://imjoy.io/login-helper"),this.credential=null,this.credentialKey=i?"sandbox_zenodo_credential":"production_zenodo_credential",this.userIdKey=i?"sandbox_zenodo_user_id":"production_zenodo_user_id";try{this.lastUserId=localStorage.getItem(this.userIdKey),this.lastUserId&&(this.lastUserId=parseInt(this.lastUserId));var r=localStorage.getItem(this.credentialKey);r&&(this.credential=JSON.parse(r),this.getCredential(),this.credential&&this.lastUserId!==this.credential.user_id&&(this.lastUserId=this.credential.user_id,localStorage.setItem(this.userIdKey,this.lastUserId)))}catch(o){console.error("Failed to reset ".concat(this.credentialKey,": ").concat(o)),localStorage.removeItem(this.credentialKey)}}return Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_createClass__WEBPACK_IMPORTED_MODULE_24__["a"])(e,[{key:"getCredential",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t,n){return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=60*(n||40)*1e3,!this.credential){e.next=8;break}if(!(this.credential.create_at+1e3*parseInt(this.credential.expires_in)>Date.now()+n)){e.next=6;break}return e.abrupt("return",this.credential);case 6:this.credential=null;try{localStorage.removeItem(this.credentialKey)}catch(i){console.error("Failed to reset ".concat(this.credentialKey,": ").concat(i))}case 8:if(!t){e.next=21;break}return e.prev=9,e.next=12,this.login();case 12:e.next=21;break;case 14:if(e.prev=14,e.t0=e["catch"](9),!confirm("Failed to login: ".concat(e.t0,", would you like to try again?"))){e.next=20;break}return e.next=19,this.getCredential(t);case 19:return e.abrupt("return",e.sent);case 20:throw e.t0;case 21:return e.abrupt("return",this.credential);case 22:case"end":return e.stop()}}),e,this,[[9,14]])})));function t(t,n){return e.apply(this,arguments)}return t}()},{key:"getResourceItems",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t){var n,i,r,o,a,s,c,l,u,d,p,_,m,f,h;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.community,i=t.page,r=t.type,o=t.keywords,a=t.query,s=t.sort,c=t.size,i=i||1,r=r||"all",o=o||[],o.includes("bioimage.io")||o.push("bioimage.io"),c=c||20,s=s||"mostrecent",l="all"!==r?"&keywords=bioimage.io:"+r:"",u=l+(o.length>0?"&"+o.map((function(e){return"keywords="+encodeURIComponent(e)})).join("&"):"")+(a?"&q="+a:""),d="".concat(this.baseURL,"/api/records/?").concat(n?"communities="+n:"","&sort=").concat(s,"&page=").concat(i,"&size=").concat(c)+u,e.next=12,fetch(d);case 12:return p=e.sent,e.t0=JSON,e.next=16,p.text();case 16:if(e.t1=e.sent,_=e.t0.parse.call(e.t0,e.t1),!_||400!==_.status){e.next=21;break}return alert(_.message),e.abrupt("return");case 21:return _&&_.hits||(alert("Failed to find similar items, please try it again."),console.warn("Hitting rate limit, retrying in 1s")),m=_.hits.hits,f=m.map((function(e){try{return depositionToRdf(e)}catch(t){return console.warn(t),null}})),console.log("Get items from URL: ",f.map((function(e){return e.id})),d),h=f.filter((function(e){return!!e})),_.aggregations.access_right.buckets.length>0?h.total=_.aggregations.access_right.buckets[0].doc_count:h.total=0,e.abrupt("return",h);case 28:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"getUserId",value:function(){return this.credential&&this.credential.user_id||this.lastUserId}},{key:"logout",value:function(){var e=this;return new Promise((function(t,n){e.credential=null;try{localStorage.removeItem(e.credentialKey)}catch(a){console.error("Failed to reset ".concat(e.credentialKey))}var i=window.open("".concat(e.baseURL,"/logout"),"Logout");try{i.focus()}catch(a){return void n("Logout window blocked. If you have a popup blocker enabled, please add bioimage.io to your exception list.")}var r=120,o=setInterval((function(){i.closed?(clearInterval(o),t()):(r--,r<=0&&(clearInterval(o),i.close(),n("Timeout error")))}),1e3);setTimeout((function(){i.close()}),1e3)}))}},{key:"login",value:function(){var e=this;return new Promise((function(t,n){if(e.lastUserId||confirm("Redirecting to Zenodo.org. If you failed to login, please come back here to try it again.")){var i=randId(),r=window.open("".concat(e.baseURL,"/oauth/authorize?scope=deposit%3Awrite+deposit%3Aactions&state=").concat(i,"&redirect_uri=").concat(e.callbackUrl,"&response_type=token&client_id=").concat(e.clientId),"Login");try{r.focus()}catch(l){return void n("Login window blocked. If you have a popup blocker enabled, please add bioimage.io to your exception list.")}e.credential=null;var o=120,a=!1,s=setInterval((function(){a?clearInterval(s):r.closed?(clearInterval(s),n("The login window was closed unexpectedly")):(o--,o<=0&&(clearInterval(s),r.close(),n("Timeout error")))}),1e3),c=function o(c){if(r===c.source){if(window.removeEventListener("message",o),clearInterval(s),r.close(),a=!0,e.credential)return;if(c.data.error)return void setTimeout((function(){n(c.data.error)}),1);if(!c.data.access_token||c.data.state!==i)return void n("Failed to obtain the access token, please make sure your account is valid and try it again.");console.log("Successfully logged in",c.data),e.credential=c.data,e.credential.user_id=parseInt(/'id': u'([0-9]+)'/gm.exec(c.data.user)[1]),e.credential.create_at=Date.now(),e.lastUserId!==e.credential.user_id&&(e.lastUserId=e.credential.user_id,localStorage.setItem(e.userIdKey,e.lastUserId)),localStorage.setItem(e.credentialKey,JSON.stringify(e.credential)),t(c.data)}};window.addEventListener("message",c,!1)}}))}},{key:"createDeposition",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(){var t,n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return t={"Content-Type":"application/json"},e.next=3,fetch("".concat(this.baseURL,"/api/deposit/depositions?access_token=").concat(this.credential.access_token),{method:"POST",body:JSON.stringify({}),headers:t});case 3:if(n=e.sent,!n.ok){e.next=10;break}return e.next=7,n.json();case 7:return e.abrupt("return",e.sent);case 10:return e.t0=Error,e.next=13,n.text();case 13:throw e.t1=e.sent,e.t2="Failed to create deposition, error: "+e.t1,new e.t0(e.t2);case 16:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},{key:"getDeposit",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t){var n,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.id?t.id:t,e.next=3,fetch("".concat(this.baseURL,"/api/records/").concat(n),{method:"GET"});case 3:if(i=e.sent,!i.ok){e.next=10;break}return e.next=7,i.json();case 7:return e.abrupt("return",e.sent);case 10:throw new Error("Failed to get deposit: "+n);case 11:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"retrieve",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t){var n,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.id?t.id:t,e.next=3,fetch("".concat(this.baseURL,"/api/deposit/depositions/").concat(n,"?access_token=").concat(this.credential.access_token),{method:"GET"});case 3:if(i=e.sent,!i.ok){e.next=10;break}return e.next=7,i.json();case 7:return e.abrupt("return",e.sent);case 10:throw new Error("Failed to retrieve deposit: "+n);case 11:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"edit",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t){var n,i,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.id?t.id:t,i={"Content-Type":"application/json"},e.next=4,fetch("".concat(this.baseURL,"/api/deposit/depositions/").concat(n,"/actions/edit?access_token=").concat(this.credential.access_token),{method:"POST",body:JSON.stringify({}),headers:i});case 4:if(r=e.sent,!r.ok){e.next=11;break}return e.next=8,r.json();case 8:return e.abrupt("return",e.sent);case 11:throw new Error("Failed to edit deposit: "+n);case 12:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"discard",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t){var n,i,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n="string"===typeof t?t:t.id,i={"Content-Type":"application/json"},e.next=4,fetch("".concat(this.baseURL,"/api/deposit/depositions/").concat(n,"/actions/discard?access_token=").concat(this.credential.access_token),{method:"POST",body:JSON.stringify({}),headers:i});case 4:if(r=e.sent,!r.ok){e.next=11;break}return e.next=8,r.json();case 8:return e.abrupt("return",e.sent);case 11:throw new Error("Failed to discard deposit: "+n);case 12:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"createNewVersion",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t){var n,i,r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n="string"===typeof t?t:t.id,i={"Content-Type":"application/json"},e.next=4,fetch("".concat(this.baseURL,"/api/deposit/depositions/").concat(n,"/actions/newversion?access_token=").concat(this.credential.access_token),{method:"POST",body:JSON.stringify({}),headers:i});case 4:if(r=e.sent,!r.ok){e.next=11;break}return e.next=8,r.json();case 8:return e.abrupt("return",e.sent);case 11:throw new Error("Failed to create a new version for deposit: "+n);case 12:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()},{key:"updateMetadata",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t,n){var i,r,o,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return i="string"===typeof t?t:t.id,console.log("Updating deposition metadata of ".concat(i,":"),n),r={"Content-Type":"application/json"},e.next=5,fetch("".concat(this.baseURL,"/api/deposit/depositions/").concat(i,"?access_token=").concat(this.credential.access_token),{method:"PUT",body:JSON.stringify({metadata:n}),headers:r});case 5:if(o=e.sent,!o.ok){e.next=12;break}return e.next=9,o.json();case 9:return e.abrupt("return",e.sent);case 12:return e.next=14,o.json();case 14:throw a=e.sent,new Error("Failed to update metadata, error: "+JSON.stringify(a.errors||a.message));case 16:case"end":return e.stop()}}),e,this)})));function t(t,n){return e.apply(this,arguments)}return t}()},{key:"uploadFile",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t,n,i,r){var o,a,s,c,l,u;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return o=t.links.bucket,a=i||n.name,s={headers:{"Content-Type":n.type},onUploadProgress:function(e){if(r)r(e.loaded);else{var t=Math.round(1*e.loaded/n.size*100);console.log("uploading annotation, size: "+Math.round(e.loaded/1e6)+"MB, "+t+"% uploaded.")}}},e.prev=3,l="".concat(o,"/").concat(a,"?access_token=").concat(this.credential.access_token),e.next=7,axios__WEBPACK_IMPORTED_MODULE_27___default.a.put(l,n,s);case 7:c=e.sent,e.next=21;break;case 10:return e.prev=10,e.t0=e["catch"](3),console.error(e.t0),console.error("Failed to upload, possibly due to access token expired:",e.t0),alert("Authentication information expired, please login to Zenodo and authorize ShareLoc.XYZ again."),e.next=17,this.login();case 17:return u="".concat(o,"/").concat(a,"?access_token=").concat(this.credential.access_token),e.next=20,axios__WEBPACK_IMPORTED_MODULE_27___default.a.put(u,n,s);case 20:c=e.sent;case 21:return e.abrupt("return",c.data);case 22:case"end":return e.stop()}}),e,this,[[3,10]])})));function t(t,n,i,r){return e.apply(this,arguments)}return t}()},{key:"publish",value:function(){var e=Object(_home_runner_work_bioimage_io_bioimage_io_node_modules_babel_runtime_helpers_esm_asyncToGenerator__WEBPACK_IMPORTED_MODULE_26__["a"])(regeneratorRuntime.mark((function e(t){var n,i,r,o,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n=t.id?t.id:t,i={"Content-Type":"application/json"},e.next=4,fetch("".concat(this.baseURL,"/api/deposit/depositions/").concat(n,"/actions/publish?access_token=").concat(this.credential.access_token),{method:"POST",body:JSON.stringify({}),headers:i});case 4:if(r=e.sent,!r.ok){e.next=16;break}return e.next=8,r.json();case 8:if(o=e.sent,!o.submitted||!o.doi_url){e.next=13;break}return e.abrupt("return",o);case 13:throw new Error("Failed to publish, error: "+JSON.stringify(o));case 14:e.next=20;break;case 16:return e.next=18,r.json();case 18:throw a=e.sent,new Error("Failed to publish, error: "+JSON.stringify(a.errors||a.message));case 20:case"end":return e.stop()}}),e,this)})));function t(t){return e.apply(this,arguments)}return t}()}]),e}();function compareVersions(v1,comparator,v2){if(comparator="="==comparator?"==":comparator,-1==["==","===","<","<=",">",">=","!=","!=="].indexOf(comparator))throw new Error("Invalid comparator. "+comparator);for(var v1parts=v1.split("."),v2parts=v2.split("."),maxLen=Math.max(v1parts.length,v2parts.length),part1,part2,cmp=0,i=0;ipart2&&(cmp=-1);return eval("0"+comparator+cmp)}function debounce(e,t,n){var i;return function(){var r=this,o=arguments,a=function(){i=null,n||e.apply(r,o)},s=n&&!i;clearTimeout(i),i=setTimeout(a,t),s&&e.apply(r,o)}}function concatAndResolveUrl(e,t){for(var n=e.split("/"),i=t.split("/"),r=[],o=0,a=n.length;o/g,"%3E"),e}function replaceAllRelByAbs(e,t){var n="[^-a-z0-9:._]";t.endsWith("/")||(t+="/");var i="(?:;|(?!\\d))",r={" ":"(?:\\s| ?|�*32"+i+"|�*20"+i+")","(":"(?:\\(|�*40"+i+"|�*28"+i+")",")":"(?:\\)|�*41"+i+"|�*29"+i+")",".":"(?:\\.|�*46"+i+"|�*2e"+i+")"},o={},a=r[" "]+"*",s="(?:[^>\"']*(?:\"[^\"]*\"|'[^']*'))*?[^>]*";function c(e){var t=e.toLowerCase();if(r[e])return r[e];for(var n=e.toUpperCase(),a="",s=0;s"+o+"]*"+a+")","gi");e=e.replace(t,(function(e){return e.replace(s,l).replace(c,l).replace(u,l)}))}function m(t,i,r,o,a,s){"string"==typeof t&&(t=new RegExp(t,"gi")),i=n+i,o="string"==typeof o?o:"gi";var c,l=new RegExp("("+i+'\\s*=\\s*")([^"]*)',"gi"),u=new RegExp("("+i+"\\s*=\\s*')([^']+)","gi"),d=new RegExp("("+r+')([^"]+)(")',o),_=new RegExp("("+r+")([^']+)(')",o);if("string"==typeof a){s="string"==typeof s?s:"";var m=new RegExp("("+r+")([^\"'][^"+a+"]*"+(s?"?)("+s+")":")()"),o);c=function(e,t,n){return t+n.replace(d,p).replace(_,p).replace(m,p)}}else c=function(e,t,n){return t+n.replace(d,p).replace(_,p)};e=e.replace(t,(function(e){return e.replace(l,c).replace(u,c)}))}return m("|'"+c("refresh")+"'"+s+">|"+c("refresh")+"(?:"+c(" ")+s+">|>))","content",c("url")+a+c("=")+a,"i"),_("<"+s+n+"href\\s*="+s+">","href"),_("<"+s+n+"src\\s*="+s+">","src"),_("","data"),_("","codebase"),_("|'"+c("movie")+"'"+s+">|"+c("movie")+"(?:"+c(" ")+s+">|>))","value"),_(/]*>(?:[^"']*(?:"[^"]*"|'[^']*'))*?[^'"]*(?:<\/style|$)/gi,"url","\\s*\\(\\s*","","\\s*\\)"),m("<"+s+n+"style\\s*="+s+">","style",c("url")+a+c("(")+a,0,a+c(")"),c(")")),e}},"034f":function(e,t,n){"use strict";var i=n("85ec"),r=n.n(i);r.a},"106f":function(e,t,n){"use strict";var i=n("944d"),r=n.n(i);r.a},"132b":function(e,t,n){"use strict";var i=n("c9e7"),r=n.n(i);r.a},"133d":function(e){e.exports=JSON.parse('{"site_name":"BioImage.IO","site_icon":"🦒","site_logo":"/static/img/bioimage-io-logo-white.svg","author":"BioImage.IO Team","keywords":"Bioimaging, AI, deep learning, image processing","description":"BioImage.IO -- an AI model repository for deep learning.","twitter_site":"@bioimageio","twitter_creator":"@weioyang","twitter_image":"https://bioimage.io/static/img/bioimage-io-banner.png","og_url":"https://bioimage.io","og_title":"BioImage.IO","og_image":"https://bioimage.io/static/img/bioimage-io-banner.png","og_description":"Advanced AI models in one-click","background_image":"static/img/zoo-background.svg","manifest_url":"https://uk1s3.embassy.ebi.ac.uk/public-datasets/bioimage.io/collection.json","explore_button_text":"🚀 Explore the Zoo","subscribe_url":"https://docs.google.com/forms/d/e/1FAIpQLSfQhTjXOuTXZNtalprbsXMPd4ct2ydiMhlPc2lhcs6WY4yo0w/viewform?embedded=true","contact_form_url":"https://oeway.typeform.com/to/K3j2tJt7","contribute_url":"https://bioimage.io/docs/#/contribute_models/README","join_partners_url":"https://bioimage.io/docs/community_partners/README.md","about_url":null,"footer":[{"label":"Question","tooltip":"Ask a question on image.sc forum","logo":"/static/img/imagesc-logo.png","url":"https://forum.image.sc/tag/bioimageio"},{"label":"Feedback Form","tooltip":"Give us some feedback through this Google Form","logo":"/static/img/feedback-icon.png","url":"https://docs.google.com/forms/d/e/1FAIpQLSfhRaldWH-CSJvSxHzxpG1_HGnNzQ-evpMcaJMo1HaSuLaCMA/viewform?usp=sf_link"},{"label":"Source Code","tooltip":"Github Repository","logo":"/static/img/github.png","url":"https://github.com/bioimage-io/bioimage.io"},{"label":"Contact Us","tooltip":"Send us a message","logo":"/static/img/contact.png","url":"https://oeway.typeform.com/to/K3j2tJt7"},{"label":"AI4Life","tooltip":"We receive funding through the AI4Life project with support from the European Union’s Horizon Europe research and innovation programme under grant agreement number 101057970","logo":"/static/img/AI4Life-logo-giraffe.png","url":"https://ai4life.eurobioimaging.eu/"},{"label":"Deploys By Netlify","tooltip":"This site is powered by Netlify","logo":"https://www.netlify.com/img/global/badges/netlify-color-accent.svg","url":"https://www.netlify.com"}],"rdf_root_repo":"bioimage-io/collection-bioimage-io","enable_comment":true,"splash_title":"BioImage Model Zoo","splash_subtitle":"Advanced AI models in one-click","splash_feature_list":["Integrated with Fiji, ilastik, ImJoy and more","Try model instantly with BioEngine","Contribute your models via Github","Link models to datasets and applications"],"table_view":{"columns":["name","authors","badges","apps"]},"zenodo_config":{"enabled":true,"sandbox_client_id":"0Zb8YkwXBqt2zelL9WyorERRzJufdTJMgxxuibmQ","production_client_id":"nO6VNWAiRjklxcVx0roedRnQncQTyEMRkTDzg6kd","community":"bioimage-io","use_sandbox":false},"attachment_table":{"columns":[{"field":"name","label":"Name","width":80,"sortable":true},{"field":"description","label":"Description","width":100,"max_length":100,"sortable":true},{"field":"timestamp","label":"Timestamp","class":"tag is-success","sortable":true},{"field":"source","label":"Source","type":"url","text":"open","class":"button is-small"},{"field":"download_url","label":"Download","type":"url","text":"Download","class":"button is-small"}],"detailed":true,"detailed_image":null,"detailed_body":"description"},"footnote":"BioImage.IO -- a collaborative effort to bring AI models to the bioimaging community. We receive funding support from the European Union’s Horizon Europe research and innovation programme under grant agreement number 101057970 (https://ai4life.eurobioimaging.eu/)","partners":[],"excluded_partners":["bioimageio"],"excluded_tags":["bioimage.io","bioimage.io:model","bioimage.io:application","bioimage.io:workflow","bioimage.io:notebook","bioimage.io:dataset","zenodo"],"resource_categories":[{"name":"models","type":"model","description":"list ai models","outline_color":"rgb(36 0 236)","tag_categories":{"modality":["electron-microscopy","cryo-electron-microscopy","fluorescence-light-microscopy","transmission-light-microscopy","super-resolution-microscopy","x-ray-microscopy","force-microscopy","high-content-imaging","whole-slide-imaging","other"],"dims":["2d","3d","2d-t","3d-t"],"content":["cells","nuclei","extracellular-vesicles","tissue","plant","mitochondria","vasculature","cell-membrane","brain","whole-organism"],"framework":["tensorflow","pytorch","tensorflow.js"],"software":["ilastik","imagej","fiji","imjoy","deepimagej","napari"],"method":["stardist","cellpose","yolo","care","n2v","denoiseg"],"network":["unet","densenet","resnet","inception","shufflenet"],"task":["semantic-segmentation","instance-segmentation","object-detection","image-classification","denoising","image-restoration","image-reconstruction","in-silico-labeling"]}},{"name":"applications","type":"application","outline_color":"rgb(83 230 7)","common_tags":["software","notebook","bioengine","workflow","macro"],"description":"list software, web apps, notebooks and utility tools"},{"name":"datasets","type":"dataset","outline_color":"rgb(236 0 185)","description":"list datasets"}]}')},"17ec":function(e,t,n){"use strict";var i=n("dd68"),r=n.n(i);r.a},"276d":function(e,t,n){},"3a38":function(e,t,n){},"423d":function(e,t,n){},4871:function(e,t,n){},"524f":function(e,t,n){"use strict";var i=n("7411"),r=n.n(i);r.a},"560e":function(e,t,n){},"56d7":function(e,t,n){"use strict";n.r(t);n("4160"),n("b64b"),n("159b");var i,r,o=n("5530"),a=(n("e260"),n("e6cf"),n("cca6"),n("a79d"),n("2b0e")),s=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("nav",{staticClass:"navbar is-link is-fixed-top"},[n("div",{staticClass:"navbar-brand"},[n("a",{attrs:{href:"#/"}},[n("img",{staticStyle:{width:"264px","margin-left":"8px","margin-top":"6px"},attrs:{src:e.siteConfig.site_logo}})]),n("div",{staticClass:"navbar-burger burger",class:{"is-active":e.showMenu},attrs:{"data-target":"navbarExampleTransparentExample"},on:{click:function(t){e.showMenu=!e.showMenu}}},[n("span"),n("span"),n("span")])]),n("div",{staticClass:"navbar-menu",class:{"is-active":e.showMenu},attrs:{id:"navbarExampleTransparentExample"}},[n("div",{staticClass:"navbar-end"},[n("a",{staticClass:"navbar-item",attrs:{href:"#/upload"}},[n("b-icon",{attrs:{icon:"plus"}}),n("span",[e._v("Upload")])],1),n("a",{staticClass:"navbar-item",attrs:{href:"/docs"}},[n("b-icon",{attrs:{icon:"playlist-check"}}),n("span",[e._v("Documentation")])],1),n("a",{staticClass:"navbar-item",attrs:{href:"#/about"}},[n("b-icon",{attrs:{icon:"information-outline"}}),n("span",[e._v("About")])],1),n("a",{staticClass:"navbar-item",attrs:{id:"imjoy-menu"}})])])]),n("router-view",{style:{marginTop:e.showNavbar?"64px":"0px"}})],1)},c=[],l=n("2f62"),u=(n("fb6a"),n("d3b7"),n("ac1f"),n("3ca3"),n("1276"),n("2ca0"),n("ddb0"),n("2b3d"),n("b85c")),d=(n("96cf"),n("1da1")),p=n("025e"),_="\n.window>.titlebar {\n cursor: move;\n}\n.window>.titlebar>.title {\n font-size: 1rem!important;\n}\n\n.window>.titlebar>.title>div>.button {\n height: 18px!important;\n line-height: 18px!important;\n}\n\n/* hide the fullscreen button */\n.window>.titlebar>.title>div>.button:nth-child(3){\n display:none!important;\n}\n.imjoy-windows > img {\n display: none;\n}\n",m=new Promise((function(e,t){i=e,r=t}));function f(){return h.apply(this,arguments)}function h(){return h=Object(d["a"])(regeneratorRuntime.mark((function e(){var t,n,o,a,s,c,l,m;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:l=function(){return l=Object(d["a"])(regeneratorRuntime.mark((function e(t,n){var i,r,o,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(t&&t.config.namespace&&t.config.namespace&&(r=document.getElementById("output_"+t.config.namespace),n.dialog||n.window_id&&document.getElementById(n.window_id)||(i=document.createElement("div"),i.id=Object(p["f"])(),i.classList.add("imjoy-window"),r.style.height="600px",r.appendChild(i),n.window_id=i.id)),!(n.type&&n.type.startsWith("imjoy/")||"joy"===n.type)){e.next=10;break}return e.next=4,window.imjoy.pm.createWindow(t,{src:"https://grid.imjoy.io/#/app",window_id:n.window_id,namespace:n.namespace});case 4:return a=e.sent,e.next=7,a.createWindow(n);case 7:o=e.sent,e.next=12;break;case 10:n.window_manager_container||(n.dialog=!0),o=window.imjoy.pm.createWindow(t,n);case 12:return e.abrupt("return",o);case 13:case"end":return e.stop()}}),e)}))),l.apply(this,arguments)},c=function(e,t){return l.apply(this,arguments)},t=window.location.href.split("#")[1].split("?")[1],n=new URLSearchParams(t),o=n.get("dev"),o&&o&&(a=document.createElement("style"),a.innerText=_,document.head.appendChild(a),s=document.createElement("div"),s.id="window-container",document.body.appendChild(s)),m={getPlugin:function(e,t,n){return Object(d["a"])(regeneratorRuntime.mark((function i(){return regeneratorRuntime.wrap((function(i){while(1)switch(i.prev=i.next){case 0:return n=n||{},t&&t.namespace||(n.namespace=n.namespace||e&&e.config.namespace),i.next=4,window.imjoy.pm.getPlugin(e,t,n);case 4:return i.abrupt("return",i.sent);case 5:case"end":return i.stop()}}),i)})))()},showStatus:function(e,t){return Object(d["a"])(regeneratorRuntime.mark((function n(){var i;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(!e||!e.config.namespace){n.next=5;break}if(!e.config.namespace){n.next=5;break}return i=document.getElementById("status_"+e.config.namespace),i.innerHTML="".concat(t.slice(0,128)),n.abrupt("return");case 5:window.app.showSnackbar(t,5);case 6:case"end":return n.stop()}}),n)})))()},showProgress:function(e,t){return Object(d["a"])(regeneratorRuntime.mark((function n(){var i;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(!e||!e.config.namespace){n.next=7;break}if(!e.config.namespace){n.next=7;break}return i=document.getElementById("progress_"+e.config.namespace),t<1&&(t*=100),t>100&&(t=100),i.style.width="".concat(t,"%"),n.abrupt("return");case 7:t=t||0,t<1&&(t*=100),window.app.progress=t,window.app.$forceUpdate();case 11:case"end":return n.stop()}}),n)})))()},resizeWindow:function(e,t,n){return Object(d["a"])(regeneratorRuntime.mark((function i(){var r;return regeneratorRuntime.wrap((function(i){while(1)switch(i.prev=i.next){case 0:console.log(e,t,n),r=e.window_id,r&&(r.style.width=t,r.style.height=n);case 3:case"end":return i.stop()}}),i)})))()},showMessage:function(e,t,n){return Object(d["a"])(regeneratorRuntime.mark((function i(){var r;return regeneratorRuntime.wrap((function(i){while(1)switch(i.prev=i.next){case 0:n=n||5,e&&e.config.namespace&&e.config.namespace&&(r=document.getElementById("status_"+e.config.namespace),r.innerHTML="".concat(t.slice(0,128))),window.app.showSnackbar(t,n);case 3:case"end":return i.stop()}}),i)})))()},showDialog:function(e,t){return Object(d["a"])(regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return t.dialog=!0,n.next=3,c(e,t);case 3:return n.abrupt("return",n.sent);case 4:case"end":return n.stop()}}),n)})))()},createWindow:c},window.loadImJoyBasicApp({version:"0.14.4",process_url_query:!0,show_window_title:!1,show_progress_bar:!0,show_empty_window:!0,hide_about_imjoy:!0,menu_style:{},window_style:{width:"100%",height:"100%"},main_container:null,menu_container:"imjoy-menu",window_manager_container:o?"window-container":null,imjoy_api:m}).then(function(){var e=Object(d["a"])(regeneratorRuntime.mark((function e(t){var r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:r=t.imjoy.api,t.$on("window-size-pos-changing",(function(e){var t,n=document.querySelectorAll(".reveal iframe"),i=Object(u["a"])(n);try{for(i.s();!(t=i.n()).done;){var r=t.value;r.style.pointerEvents=e?"none":"all"}}catch(o){i.e(o)}finally{i.f()}})),t.addMenuItem({label:"➕ Load Plugin",callback:function(){var e=prompt("Please type a ImJoy plugin URL","https://github.com/imjoy-team/imjoy-plugins/blob/master/repository/ImageAnnotator.imjoy.html");e&&t.loadPlugin(e)}}),t.addMenuItem({label:"🤖 Chatbot",callback:function(){return Object(d["a"])(regeneratorRuntime.mark((function e(){var n;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,r.showMessage("Loading BioImage.IO Chatbot...");case 2:return e.next=4,r.createWindow({src:"https://bioimage.io/chat",name:"BioImage.IO Chatbot"});case 4:return n=location.origin,e.next=7,r.showMessage("Loading BioImage Model Zoo extension for the chatbot, this may take a while...");case 7:return e.next=9,t.loadPlugin("".concat(n,"/chat/bioimage-model-zoo-extension.imjoy.html"));case 9:case"end":return e.stop()}}),e)})))()}}),t.addMenuItem({label:"🎢 Playground",callback:function(){r.createWindow({src:"https://if.imjoy.io"})}}),t.addMenuItem({label:"📓 Notebooks",callback:function(){r.createWindow({src:"https://jupyter.imjoy.io"})}}),window.api=r,window.imjoy=t.imjoy,window.app=t,i(t.imjoy),t.imjoy.pm.reloadPluginRecursively({uri:"https://raw.githubusercontent.com/imjoy-team/imjoy-core-plugins/master/docs/WebPythonWorker.imjoy.html"}),t.imjoy.pm.reloadPluginRecursively({uri:"https://imjoy-team.github.io/jupyter-engine-manager/Jupyter-Engine-Manager.imjoy.html"}).then((function(e){var t=n.get("engine"),i=n.get("spec");t?e.api.createEngine({name:"MyCustomEngine",nbUrl:t,url:t.split("?")[0]}).then((function(){console.log("Jupyter Engine connected!")})).catch((function(e){console.error("Failed to connect to Jupyter Engine",e)})):e.api.createEngine({name:"MyBinder Engine",url:"https://mybinder.org",spec:i||"oeway/imjoy-binder-image/master"}).then((function(){console.log("Binder Engine connected!")})).catch((function(e){console.error("Failed to connect to MyBinder Engine",e)}))})),t.addMenuItem({label:"ℹ️ Github",callback:function(){window.open("https://github.com/bioimage-io/bioimage.io")}});case 13:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).catch((function(e){console.error(e),r()}));case 8:case"end":return e.stop()}}),e)}))),h.apply(this,arguments)}function g(e){return b.apply(this,arguments)}function b(){return b=Object(d["a"])(regeneratorRuntime.mark((function e(t){var n,i,r,o;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(n=window.location.href.split("#")[1].split("?")[1],i=new URLSearchParams(n),r=i.get("dev"),r){e.next=5;break}return e.abrupt("return");case 5:return e.next=7,m;case 7:o=window.app,o.loadPlugin("https://if.imjoy.io").then((function(){o.imjoy.event_bus.on("plugin_loaded",(function(e){t("add",e)})),o.imjoy.event_bus.on("plugin_unloaded",(function(e){t("remove",e)})),o.imjoy.event_bus.on("add_window",(function(e){window.scrollTo(0,0),setTimeout((function(){if(!e.dialog){var t=document.getElementById(e.window_id).parentElement.parentElement;t.style.top="100px"}}),200)}))}));case 9:case"end":return e.stop()}}),e)}))),b.apply(this,arguments)}function y(e,t,n){return v.apply(this,arguments)}function v(){return v=Object(d["a"])(regeneratorRuntime.mark((function e(t,n,i){var r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(console.log(n,i),t.showLoader(!0),e.prev=2,!n.passive){e.next=7;break}return e.next=6,window.api.createWindow({src:n.source,passive:!0});case 6:return e.abrupt("return");case 7:return e.next=9,window.api.getPlugin({src:n.source});case 9:return r=e.sent,e.next=12,r.run({config:{referer:window.location.href,mode:"all",type:"bioengine"},data:i});case 12:t.showLoader(!1),e.next=18;break;case 15:e.prev=15,e.t0=e["catch"](2),console.error(e.t0);case 18:return e.prev=18,t.showLoader(!1),e.finish(18);case 21:case"end":return e.stop()}}),e,null,[[2,15,18,21]])}))),v.apply(this,arguments)}function w(e,t,n){return k.apply(this,arguments)}function k(){return k=Object(d["a"])(regeneratorRuntime.mark((function e(t,n,i){var r;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(console.log(n,i),t.showLoader(!0),e.prev=2,!n.passive){e.next=7;break}return e.next=6,window.api.createWindow({src:n.source,passive:!0});case 6:return e.abrupt("return");case 7:return e.next=9,window.api.getPlugin({src:n.source});case 9:return r=e.sent,e.next=12,r.run({config:{referer:window.location.href,mode:"one",type:"bioengine"},data:i});case 12:e.next=17;break;case 14:e.prev=14,e.t0=e["catch"](2),console.error(e.t0);case 17:return e.prev=17,t.showLoader(!1),e.finish(17);case 20:case"end":return e.stop()}}),e,null,[[2,14,17,20]])}))),k.apply(this,arguments)}var x={name:"App",data:function(){return{showMenu:!1}},computed:Object(o["a"])({},Object(l["b"])({showNavbar:function(e){return e.showNavbar},siteConfig:function(e){return e.siteConfig}})),mounted:function(){var e=this;f().then((function(){e.$store.commit("setBioEngineReady",!0)})).catch((function(t){console.error(t),e.$store.commit("setBioEngineReady",!1)}))}},I=x,C=(n("034f"),n("2877")),O=Object(C["a"])(I,s,c,!1,null,null,null),E=O.exports,R=n("8c4f"),j=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"home"},[n("section",{staticClass:"hero is-link is-fullheight is-fullheight-with-navbar",staticStyle:{"max-height":"1024px!important",height:"100%","min-height":"640px"}},[n("div",{staticClass:"hero-body",staticStyle:{position:"relative"}},[e.selectedPartner?n("img",{staticClass:"background-img",attrs:{src:e.selectedPartner.background_image}}):n("img",{staticClass:"background-img",attrs:{src:e.siteConfig.background_image}}),e.partners?n("partners-component",{staticStyle:{position:"absolute",bottom:"0px"},attrs:{partners:e.partners},on:{switchPartner:e.switchPartner}}):e._e(),e.selectedPartner?n("div",{staticClass:"container",staticStyle:{"margin-bottom":"100px"}},[n("h1",{staticClass:"title is-1"},[e._v(" "+e._s(e.selectedPartner.splash_title)+" ")]),n("h2",{staticClass:"subtitle is-3"},[e._v(" "+e._s(e.selectedPartner.splash_subtitle)+" ")]),e.selectedPartner.splash_feature_list?n("ul",{staticClass:"feature-list"},e._l(e.selectedPartner.splash_feature_list,(function(t){return n("li",{key:t},[e._v(" "+e._s(t)+" ")])})),0):e._e(),n("br"),e.selectedPartner.about_url?n("b-button",{staticStyle:{"text-transform":"none"},attrs:{rounded:""},on:{click:function(t){return e.showAboutPartner(e.selectedPartner)}}},[n("span",{staticClass:"explore-btn"},[e._v("About")])]):e._e(),e._v(" "),n("b-button",{staticStyle:{"text-transform":"none"},attrs:{rounded:""},on:{click:e.enter}},[n("span",{staticClass:"explore-btn"},[e._v(e._s(e.selectedPartner.explore_button_text))])])],1):n("div",{staticClass:"container",staticStyle:{"margin-bottom":"100px"}},[n("h1",{staticClass:"title is-1"},[e._v(" "+e._s(e.siteConfig.splash_title)+" ")]),n("h2",{staticClass:"subtitle is-3"},[e._v(" "+e._s(e.siteConfig.splash_subtitle)+" ")]),e.siteConfig.splash_feature_list?n("ul",{staticClass:"feature-list"},e._l(e.siteConfig.splash_feature_list,(function(t){return n("li",{key:t},[e._v(" "+e._s(t)+" ")])})),0):e._e(),n("br"),n("b-button",{staticStyle:{"text-transform":"none"},attrs:{rounded:""},on:{click:e.enter}},[n("span",{staticClass:"explore-btn"},[e._v(e._s(e.siteConfig.explore_button_text))])])],1)],1)]),n("span",{ref:"search_anchor"}),n("br"),n("section",{staticStyle:{"margin-top":"-30px",opacity:"0.6"}},[n("b-progress",{attrs:{value:e.progress}})],1),n("br"),e.resourceCategories.length>1?n("div",{staticClass:"container",staticStyle:{"text-align":"center"}},[n("b-tooltip",{attrs:{label:"List all items",position:"is-bottom"}},[n("div",{staticClass:"item-lists is-link",class:{active:!e.selectedCategory},staticStyle:{width:"30px","margin-left":"-16px","border-bottom-color":"gray"},on:{click:function(t){e.selectedCategory=null,e.updateQueryTags()}}},[e._v(" All ")])]),e._l(e.resourceCategories,(function(t){return n("b-tooltip",{key:t.name,attrs:{label:t.description,position:"is-bottom"}},[n("div",{staticClass:"item-lists is-link",class:{active:e.selectedCategory===t},style:{"border-bottom-color":t.outline_color},on:{click:function(n){e.selectedCategory=t,e.updateQueryTags()}}},[e._v(" "+e._s(t.name)+" ")])])}))],2):e._e(),n("resource-item-selector",{attrs:{allItems:e.resourceItems,fullLabelList:e.fullLabelList,tagCategories:e.tagCategories,type:e.selectedCategory&&e.selectedCategory.type,showDisplayMode:e.screenWidth>700,searchTags:e.searchTags},on:{"selection-changed":e.updateResourceItemList,"display-mode-change":e.displayModeChanged,"tags-updated":e.updateQueryTags,"input-change":e.removePartner}}),n("br"),e.selectedItems?n("resource-item-list",{attrs:{allItems:e.selectedItems,displayMode:e.screenWidth>700?e.displayMode:"card",bioEngineReady:e.bioEngineReady},on:{"show-resource-item-info":e.showResourceItemInfo,"select-tag":function(t){e.searchTags=[t]}}}):e._e(),n("br"),n("footer",{staticClass:"footer"},[e.siteConfig.footer?n("div",{staticClass:"columns is-mobile is-centered"},e._l(e.siteConfig.footer,(function(t){return n("div",{key:t.label,staticClass:"column is-one-quarter",staticStyle:{"text-align":"center",width:"16%"}},[n("b-tooltip",{attrs:{label:t.tooltip,position:"is-top"}},[n("a",{attrs:{href:t.url,target:"_blank"}},[n("figure",[n("img",{staticStyle:{"max-height":"55px"},attrs:{src:t.logo}}),n("figcaption",{staticClass:"hide-on-small-screen"},[e._v(" "+e._s(t.label)+" ")])])])])],1)})),0):e._e(),e.siteConfig.footnote?n("div",{staticStyle:{"text-align":"center"}},[n("p",[e._v(e._s(e.siteConfig.footnote))])]):e._e()]),n("modal",{staticStyle:{"max-width":"100%","max-height":"100%","z-index":"9999"},attrs:{name:"window-modal-dialog",resizable:!e.dialogWindowConfig.fullscreen,width:e.dialogWindowConfig.width,height:e.dialogWindowConfig.height,adaptive_size:e.dialogWindowConfig.adaptive_size,minWidth:200,minHeight:150,fullscreen:e.dialogWindowConfig.fullscreen,draggable:".drag-handle",scrollable:!0}},[e.selectedDialogWindow?n("div",{staticClass:"dialog-header",class:{"drag-handle":!e.isTouchDevice},on:{dblclick:function(t){return e.maximizeDialogWindow()}}},[n("div",{staticStyle:{position:"absolute",left:"2px","margin-top":"-1px"}},[n("button",{staticClass:"noselect dialog-control-button",staticStyle:{background:"#ff0000c4"},on:{click:function(t){return e.closeDialogWindow(e.selectedDialogWindow)}}},[e._v(" x ")]),e.screenWidth>700?n("button",{staticClass:"noselect dialog-control-button",staticStyle:{background:"#00cdff61"},on:{click:function(t){return e.minimizeDialogWindow()}}},[e._v(" - ")]):e._e(),e.screenWidth>700?n("button",{staticClass:"noselect dialog-control-button",staticStyle:{background:"#00cdff61"},on:{click:function(t){return e.maximizeDialogWindow()}}},[e._v(" "+e._s(e.dialogWindowConfig.fullscreen?"=":"+")+" ")]):e._e()]),n("span",{staticClass:"noselect dialog-title"},[e._v(" "+e._s(e.selectedDialogWindow.name))]),n("b-dropdown",{staticStyle:{position:"absolute",right:"1px"},attrs:{"aria-role":"list",position:"is-bottom-left"}},[n("button",{staticClass:"button",staticStyle:{background:"rgba(0, 205, 255, 0.38)",color:"white",width:"34px"},attrs:{slot:"trigger"},slot:"trigger"},[n("b-icon",{attrs:{icon:"dots-horizontal"}})],1),e._l(e.dialogWindows,(function(t){return n("b-dropdown-item",{key:t.id,attrs:{"aria-role":"listitem"},on:{click:function(n){return e.selectWindow(t)}}},[e._v(e._s(t.name))])}))],2)],1):e._e(),e._l(e.dialogWindows,(function(t){return[n("div",{directives:[{name:"show",rawName:"v-show",value:t===e.selectedDialogWindow,expression:"wdialog === selectedDialogWindow"}],key:t.window_id,staticStyle:{height:"calc(100% - 18px)"}},[n("div",{staticClass:"noselect",staticStyle:{width:"100%",height:"100%"},attrs:{id:t.window_id}})])]}))],2),n("modal",{staticStyle:{"max-width":"100%","max-height":"100%"},attrs:{name:"info-dialog",resizable:!0,minWidth:200,minHeight:150,height:600,width:800,fullscreen:e.infoDialogFullscreen,draggable:".drag-handle",scrollable:!0}},[n("div",{staticClass:"dialog-header",class:{"drag-handle":!e.isTouchDevice},on:{dblclick:function(t){return e.maximizeInfoWindow()}}},[n("div",{staticStyle:{position:"absolute",left:"2px","margin-top":"-1px"}},[n("button",{staticClass:"noselect dialog-control-button",staticStyle:{background:"#ff0000c4"},on:{click:function(t){return e.closeInfoWindow()}}},[e._v(" x ")]),e.screenWidth>700?n("button",{staticClass:"noselect dialog-control-button",staticStyle:{background:"#00cdff61"},on:{click:function(t){return e.maximizeInfoWindow()}}},[e._v(" "+e._s(e.infoDialogFullscreen?"=":"+")+" ")]):e._e()]),n("span",{staticClass:"noselect dialog-title"},[e._v(" "+e._s(e.infoDialogTitle))])]),"markdown"===e.showInfoDialogMode?n("div",{staticClass:"markdown-container"},[n("markdown-component",{attrs:{content:e.infoMarkdownContent,url:e.infoMarkdownUrl}}),e.infoCommentBoxTitle?n("comment-box",{attrs:{title:e.infoCommentBoxTitle}}):e._e()],1):"attachments"===e.showInfoDialogMode&&e.selectedResourceItem?n("div",{staticClass:"markdown-container"},[n("attachments-component",{attrs:{attachments:e.selectedResourceItem.attachments,focusTarget:e.selectedResourceItem._focus}})],1):"model"===e.showInfoDialogMode&&e.selectedResourceItem?n("resource-item-info",{attrs:{"resource-item":e.selectedResourceItem,"show-resource-item-info":e.showResourceItemInfo}}):e._e()],1)],1)},D=[],P=(n("a4d3"),n("e01a"),n("99af"),n("4de4"),n("a630"),n("caad"),n("c975"),n("a15b"),n("d81d"),n("a434"),n("b0c0"),n("6062"),n("8a79"),n("2532"),n("5319"),n("841c"),n("e2c1")),T=n("0d52"),L=n.n(T),M=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"container content-wrapper"},[n("section",{staticClass:"center "},[n("b-field",{staticStyle:{"max-width":"calc(100vw - 10px)","margin-bottom":"20px"},on:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.search(t)}}},[n("div",{staticStyle:{position:"absolute",top:"36px",left:"50%",transform:"translate3d(-50%, 0, 0)"}},e._l(e.commonTags,(function(t,i){return n("a",{key:t,staticStyle:{margin:"3px"},on:{click:function(n){e.selectedTags=[t]}}},[e._v(e._s(t)+e._s(i===e.commonTags.length-1?"":","))])})),0),n("b-taginput",{staticClass:"searchbar",attrs:{loading:e.loading,type:"is-info","allow-new":"",data:e.filteredTags,"open-on-focus":!0,autocomplete:"",ellipsis:"",icon:"magnify",placeholder:"Type a keyword and press enter"},on:{input:e.updateSelectedTags,typing:e.getFilteredTags},scopedSlots:e._u([{key:"default",fn:function(t){return[e._v(" "+e._s(t.option)+" ")]}}]),model:{value:e.selectedTags,callback:function(t){e.selectedTags=t},expression:"selectedTags"}}),n("b-dropdown",{attrs:{"aria-role":"list",position:"is-bottom-left"}},[n("button",{staticClass:"button tags-button",attrs:{slot:"trigger"},slot:"trigger"},[n("span",[e._v("Tags & Filters")]),n("b-icon",{attrs:{icon:"menu-down"}})],1),n("div",{staticClass:"dropdown-panel",attrs:{"aria-role":"listitem"}},[n("div",{staticClass:"container",staticStyle:{"max-width":"100%"}},[n("div",{staticClass:"field"},[n("b-switch",{model:{value:e.matchingAll,callback:function(t){e.matchingAll=t},expression:"matchingAll"}},[e._v("Match: "+e._s(e.matchingAll?" All":"Any"))]),n("b-switch",{model:{value:e.freeTextMode,callback:function(t){e.freeTextMode=t},expression:"freeTextMode"}},[e._v("Free text: "+e._s(e.freeTextMode?" Enabled":"Disabled"))]),n("b-tooltip",{attrs:{label:"⚠️Include unverified resource items contributed by users on Zenodo.",position:"is-bottom"}},[n("b-switch",{model:{value:e.includeWilderness,callback:function(t){e.includeWilderness=t},expression:"includeWilderness"}},[e._v("Include wilderness: "+e._s(e.includeWilderness?" Yes":"No"))])],1)],1),e._l(e.categories.grouped,(function(t,i){return n("div",{key:i,staticClass:"column"},[e._v(" "+e._s(i)+": "),n("br"),e._l(t,(function(t){return n("a",{key:t,staticStyle:{display:"inline-block"},on:{click:function(n){return e.addTagSelection(t)}}},[n("b-tag",{staticStyle:{cursor:"pointer"},attrs:{rounded:""}},[e._v(e._s(t))])],1)}))],2)})),n("div",{staticClass:"column"},[Object.keys(e.categories.grouped).length>0?n("span",[e._v("other: "),n("br")]):e._e(),e._l(e.categories.other,(function(t){return n("a",{key:t,staticStyle:{display:"inline-block"},on:{click:function(n){return e.addTagSelection(t)}}},[n("b-tag",{staticStyle:{cursor:"pointer"},attrs:{rounded:""}},[e._v(e._s(t))])],1)}))],2)],2)])]),e.showDisplayMode?n("b-field",{staticClass:"display-mode-btn"},[n("p",{staticClass:"control"},[n("b-tooltip",{attrs:{label:"Display mode: list",position:"is-top"}},[n("button",{staticClass:"button",class:{"is-primary":"list"===e.displayMode},staticStyle:{top:"1px",height:"34px"},on:{click:function(t){return e.switchDisplayMode("list")}}},[n("b-icon",{attrs:{icon:"format-list-bulleted"}})],1)])],1),n("p",{staticClass:"control"},[n("b-tooltip",{attrs:{label:"Display mode: card",position:"is-top"}},[n("button",{staticClass:"button",class:{"is-primary":"card"===e.displayMode},staticStyle:{top:"1px",height:"34px"},on:{click:function(t){return e.switchDisplayMode("card")}}},[n("b-icon",{attrs:{icon:"view-grid"}})],1)])],1)]):e._e()],1)],1)])},S=[],A=(n("a623"),n("45fc"),n("498a"),{name:"ResourceItemSelector",props:{allItems:{type:Array,default:null},type:{type:String,default:null},fullLabelList:{type:Array,default:null},tagCategories:{type:Object,default:null},showDisplayMode:{type:Boolean,default:!1},searchTags:{type:Array,default:null}},data:function(){return{selectedTags:[],filteredTags:[],loading:!1,matchingAll:!0,freeTextMode:!0,includeWilderness:!0,displayMode:"card"}},watch:{type:function(e){this.allItems&&(this.type=e,this.applySearch(this.selectedTags))},selectedTags:function(e){this.applySearch(e)},allItems:function(){this.applySearch(this.selectedTags)},searchTags:function(e){var t=this;if(e){var n=e&&e.length==this.selectedTags.length&&e.every((function(e,n){return e===t.selectedTags[n]}));n||(e=e.filter((function(e){return e&&""!=e.trim()})),this.selectedTags=Array.from(new Set(e)))}else this.selectedTags=[]}},mounted:function(){this.filteredTags=this.fullLabelList},computed:Object(o["a"])({commonTags:function(){var e,t=this;return(null===(e=this.siteConfig.resource_categories.filter((function(e){return e.type===t.type}))[0])||void 0===e?void 0:e.common_tags)||[]},categories:function(){if(!this.tagCategories)return{grouped:{},other:this.fullLabelList};var e,t={},n=[],i=this.selectedTags.map((function(e){return e.toLowerCase()})),r=Object(u["a"])(this.fullLabelList);try{for(r.s();!(e=r.n()).done;){var o=e.value;if(!(i.indexOf(o.toLowerCase())>=0)){for(var a=!1,s=0,c=Object.keys(this.tagCategories);s=0}));n=i.filter((function(n){var i;i=t.matchingAll?r.length>0&&r.every((function(e){return n.allLabels.includes(e.toLowerCase())})):r.length>0&&r.some((function(e){return n.allLabels.includes(e.toLowerCase())}));var o=function(e){return e=e.replace(/-/g,"").toLowerCase(),n.name.replace(/-/g,"").toLowerCase().includes(e)||n.description&&n.description.replace(/-/g,"").toLowerCase().split(/[ .:;?!~,`"&|()<>{}[\]\r\n/\\]+/).includes(e)||n.authors&&n.authors.some((function(t){return t.name.toLowerCase().includes(e)}))||n.apps&&n.apps.some((function(t){return t.name&&t.name.toLowerCase().includes(e)}))};return(!t.type||n.type===t.type)&&(i||t.freeTextMode&&e.every(o))}))}t.$emit("selection-changed",n),t.loading=!1,t.$forceUpdate()}),400)())},switchDisplayMode:function(e){this.displayMode!==e&&(this.displayMode=e,this.$emit("display-mode-change",e))},updateSelectedTags:function(){var e=this;this.$emit("input-change"),this.filteredTags=this.fullLabelList.filter((function(t){return e.selectedTags.indexOf(t)<0}))},getFilteredTags:function(e){this.filteredTags=this.fullLabelList.filter((function(t){return t.toLowerCase().indexOf(e.toLowerCase())>=0}))},addTagSelection:function(e){this.selectedTags.indexOf(e)<0&&this.selectedTags.push(e)}}}),U=A,W=(n("e88b"),Object(C["a"])(U,M,S,!1,null,"1f19381b",null)),B=W.exports,F=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"resource-item-list"},[n("div",{staticClass:"container content-wrapper"},["card"===e.displayMode?n("div",{staticClass:"columns is-multiline"},[e._l(e.allItems.slice((e.currentPage-1)*e.itemsPerPage,e.currentPage*e.itemsPerPage),(function(t){return n("div",{key:t.id,staticClass:"column is-4-desktop is-3-widescreen is-half-tablet resource-card"},[n("resource-item-card",{attrs:{resourceItem:t,bioEngineReady:e.bioEngineReady},on:{"show-info":e.showResourceItemInfo,"select-tag":function(t){return e.$emit("select-tag",t)}}})],1)})),e.allItems&&0===e.allItems.length?n("span",{staticClass:"column",staticStyle:{"text-align":"center"}},[e._v("The list is empty.")]):e._e()],2):n("b-table",{attrs:{data:e.allItems,detailed:!0,"show-detail-icon":!0},scopedSlots:e._u([{key:"default",fn:function(t){return[e.siteConfig.table_view.columns.includes("name")?n("b-table-column",{attrs:{label:"Name",width:"20",field:"name",sortable:""}},[n("a",{on:{click:function(n){return e.showResourceItemInfo(t.row)}}},[e._v(" "+e._s(t.row.name)+" ")]),n("p",[e._v(" "+e._s(t.row.description.slice(0,100)+(t.row.description.length>100?"...":""))+" ")])]):e._e(),e.siteConfig.table_view.columns.includes("authors")?n("b-table-column",{attrs:{label:"Author(s)",width:"20",sortable:"",field:"authors"}},e._l(t.row.authors,(function(t){return n("b-tooltip",{key:t.name,attrs:{label:t.affiliation,position:"is-bottom"}},[n("span",[e._v(e._s(t.name))])])})),1):e._e(),e.siteConfig.table_view.columns.includes("badges")?n("b-table-column",{attrs:{label:"Badges",width:"50",field:"badges",sortable:""}},[t.row.badges?n("div",{staticClass:"badges"},e._l(t.row.badges,(function(t){return n("a",{key:t.label,staticClass:"badge",attrs:{href:t.url,target:"_blank"},on:{click:function(e){!t.url&&t.run&&t.run()}}},[t.icon?n("img",{attrs:{alt:t.label,src:t.icon}}):n("b-taglist",{attrs:{attached:"",rounded:""}},[n("b-tag",{attrs:{type:t.label_type||"is-dark"}},[e._v(e._s(t.label))]),t.ext?n("b-tag",{attrs:{type:t.ext_type||"is-success"}},[e._v(e._s(t.ext))]):e._e()],1)],1)})),0):e._e()]):e._e(),e.siteConfig.table_view.columns.includes("apps")?n("b-table-column",{attrs:{label:"Apps",width:"30",field:"apps",sortable:"",disabled:!e.bioEngineReady}},[n("app-icons",{attrs:{apps:t.row.apps}})],1):e._e(),n("b-table-column",{attrs:{label:"Created",width:"30",field:"created",sortable:""}},[n("span",[e._v(e._s(t.row.created))])])]}},{key:"detail",fn:function(t){return[n("resource-item-card",{attrs:{resourceItem:t.row},on:{"show-info":e.showResourceItemInfo,"select-tag":function(t){return e.$emit("select-tag",t)}}})]}}])}),n("b-pagination",{staticClass:"resource-pagination",attrs:{total:e.totalItems,current:e.currentPage,"range-before":3,"range-after":1,"per-page":e.itemsPerPage,"icon-prev":"arrow-left","icon-next":"arrow-right","aria-next-label":"Next page","aria-previous-label":"Previous page","aria-page-label":"Page","aria-current-label":"Current page"},on:{"update:current":function(t){e.currentPage=t}}})],1)])},z=[],q=function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.apps?n("div",{staticClass:"app-icons"},[e._l(e.apps,(function(t){return[n("b-tooltip",{directives:[{name:"show",rawName:"v-show",value:!e.onlyLinked||t.isLinkedApp,expression:"!onlyLinked || app.isLinkedApp"}],key:t.name,class:{"hover-show":t.show_on_hover&&e.enableHover},attrs:{label:t.name,position:"is-bottom"}},[n("b-button",{staticClass:"is-small action-btn",attrs:{rounded:"",tag:"a",href:t.url,target:"_blank",disabled:e.disabled},on:{click:function(e){!t.url&&t.run&&t.run()}}},[t.icon?t.icon.startsWith("http")?n("img",{staticClass:"app-icon",attrs:{src:t.icon,alt:t.name}}):n("b-icon",{attrs:{icon:t.icon,size:"is-small"}}):n("b-icon",{attrs:{icon:"puzzle",size:"is-small"}})],1)],1)]}))],2):e._e()},$=[],K={name:"AppIcons",props:{apps:{type:Array,default:null},enableHover:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},onlyLinked:{type:Boolean,default:!1}}},N=K,J=(n("132b"),Object(C["a"])(N,q,$,!1,null,"e10eb140",null)),H=J.exports,V=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"resource-item-card"},[n("div",{staticClass:"card is-shady",style:{"box-shadow":e.boxShadow}},[n("div",{staticClass:"card-image"},[e.resourceItem.covers&&e.resourceItem.covers.length>0?n("b-carousel",{attrs:{indicator:e.resourceItem.covers.length>1,arrow:e.resourceItem.covers.length>1,"pause-info":!1}},e._l(e.resourceItem.covers,(function(t){return n("b-carousel-item",{key:t,staticClass:"carousel-image"},[n("img",{staticClass:"cover-image",attrs:{loading:"lazy",src:t,alt:e.resourceItem.name}})])})),1):n("img",{staticClass:"cover-image",staticStyle:{"background-color":"black",width:"100%",height:"160px"}})],1),n("div",{staticClass:"card-content"},[n("div",{staticClass:"content"},[n("h4",{staticClass:"resource-item-title truncated",on:{click:e.showResourceItemInfo}},["img"===e.icon.type?n("img",{staticClass:"item-icon",staticStyle:{"border-radius":"4px",background:"#ffffffd0"},attrs:{src:e.icon.src}}):"emoji"===e.icon.type?n("span",{staticClass:"icon"},[e._v(" "+e._s(e.icon.src)+" ")]):"animal"===e.icon.type?n("img",{staticClass:"item-icon",staticStyle:{"border-radius":"50%",background:"#167cf0b8"},attrs:{src:"/static/anonymousAnimals/"+e.icon.src+".png"}}):n("b-icon",{staticClass:"item-icon",attrs:{icon:e.icon.src}}),e._v(" "+e._s(e.resourceItem.name)+" ")],1),n("div",{staticClass:"buttons floating-buttons"},[n("dev-menu",{attrs:{resourceItem:e.resourceItem}}),n("app-icons",{attrs:{apps:e.resourceItem.apps,enableHover:!e.isTouchDevice,disabled:!e.bioEngineReady}})],1),e.resourceItem.description?n("p",{staticClass:"resource-item-description"},[e._v(" "+e._s(e.resourceItem.description.slice(0,64)+(e.resourceItem.description.length>64?"...":""))+" ")]):e._e(),n("span",{staticStyle:{"margin-top":"3px",display:"block"}},[e._l(e.resourceItem.tags.slice(0,4),(function(t){return n("span",{key:t},[n("b-tag",{staticStyle:{cursor:"pointer"},attrs:{rounded:""},nativeOn:{click:function(n){return e.selectTag(t)}}},[e._v(e._s(t))])],1)})),e.resourceItem.tags.length>4?n("span",[n("b-tag",{staticStyle:{cursor:"pointer"},attrs:{rounded:""},nativeOn:{click:function(t){return e.showResourceItemInfo(t)}}},[e._v("...")])],1):e._e()],2),n("badges",{staticClass:"badges",attrs:{badges:e.resourceItem.badges}})],1)])])])},G=[],Z=function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.badges?n("div",{staticClass:"badges"},e._l(e.badges,(function(t){return n("a",{key:t.label+t.ext,staticClass:"badge",attrs:{href:t.url,target:"_blank"},on:{click:function(e){!t.url&&t.run&&t.run()}}},[t.icon?n("img",{staticClass:"badge-img",attrs:{alt:t.label,src:t.icon}}):n("b-taglist",{attrs:{attached:"",rounded:""}},[t.label_short&&e.badges.length>3?n("b-tag",{attrs:{type:t.label_type||"is-dark"}},[e._v(e._s(t.label_short))]):n("b-tag",{attrs:{type:t.label_type||"is-dark"}},[e._v(e._s(t.label))]),void 0!==t.ext?n("b-tag",{attrs:{type:t.ext_type||"is-success"}},[e._v(e._s(t.ext))]):e._e()],1)],1)})),0):e._e()},Y=[],Q={name:"Badges",props:{badges:{type:Array,default:null}}},X=Q,ee=(n("94f5"),Object(C["a"])(X,Z,Y,!1,null,"68bfc2b0",null)),te=ee.exports,ne=function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.devPlugins&&e.devPlugins.length>0?n("b-dropdown",{attrs:{triggers:["hover"],"aria-role":"list"},scopedSlots:e._u([{key:"trigger",fn:function(){return[n("b-button",{staticClass:"is-small action-btn",attrs:{rounded:""}},[n("b-icon",{attrs:{icon:"dev-to",size:"is-small"}})],1)]},proxy:!0}],null,!1,64769206)},e._l(e.devPlugins,(function(t){return n("b-dropdown-item",{key:t.id,attrs:{"aria-role":"listitem"},on:{click:function(n){return e.runPlugin(t)}}},[e._v(e._s(t.name))])})),1):e._e()},ie=[],re={name:"dev-menu",props:["resourceItem"],computed:Object(o["a"])({},Object(l["b"])({devPlugins:function(e){return e.devPlugins},resourceItems:function(e){return e.resourceItems}})),methods:{runPlugin:function(e){var t=this;return Object(d["a"])(regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(!t.resourceItem){n.next=5;break}return n.next=3,e.api.run({config:{referer:window.location.href,mode:"one",type:"bioengine"},data:t.resourceItem});case 3:n.next=7;break;case 5:return n.next=7,e.api.run({config:{referer:window.location.href,mode:"all",type:"bioengine"},data:t.resourceItems});case 7:case"end":return n.stop()}}),n)})))()},showLoader:function(e){e?this.loadingComponent=this.$buefy.loading.open({canCancel:!0,container:this.$el}):this.loadingComponent&&(this.loadingComponent.close(),this.loadingComponent=null)}}},oe=re,ae=(n("d7c4"),Object(C["a"])(oe,ne,ie,!1,null,"3ba6a4a2",null)),se=ae.exports,ce=function(){try{return document.createEvent("TouchEvent"),!0}catch(e){return!1}}(),le={name:"ResourceItemCard",props:{resourceItem:{type:Object,default:null},bioEngineReady:{type:Boolean,default:!1}},data:function(){return{isTouchDevice:ce}},components:{badges:te,"app-icons":H,"dev-menu":se},computed:Object(o["a"])({boxShadow:function(){var e=this.colorMap[this.resourceItem.type]||"rgba(0,0,0,.2)";return"0 3px 1px -2px ".concat(e,", 0 2px 2px 0 ").concat(e,", 0 1px 5px 0 rgba(0,0,0,.12)")},icon:function(){return this.resourceItem.icon?this.resourceItem.icon.startsWith("http")?{type:"img",src:this.resourceItem.icon}:{type:"material",src:this.resourceItem.icon}:this.resourceItem.nickname_icon?{type:"emoji",src:this.resourceItem.nickname_icon}:{type:"none"}}},Object(l["b"])({siteConfig:function(e){return e.siteConfig}})),created:function(){this.colorMap={};var e,t=Object(u["a"])(this.siteConfig.resource_categories);try{for(t.s();!(e=t.n()).done;){var n=e.value;this.colorMap[n.type]=n.outline_color}}catch(i){t.e(i)}finally{t.f()}},methods:{etAl:function(e){return e=e.map((function(e){return e.name.split(";")[0]})),e.length<3?e.join(", "):e.slice(0,3).join(", ")+" et al."},affil:function(e){var t=e.map((function(e){return e.affiliation}));return Array.from(new Set(t)).join("; ")},showResourceItemInfo:function(){this.$emit("show-info",this.resourceItem)},selectTag:function(e){this.$emit("select-tag",e)}}},ue=le,de=(n("ebec"),Object(C["a"])(ue,V,G,!1,null,"19aa8d02",null)),pe=de.exports,_e=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);a["default"].component("label-selector",{props:["all-labels"],template:document.getElementById("label-selector")});var me={name:"ResourceItemList",components:{"resource-item-card":pe,"app-icons":H},props:{allItems:{type:Array,default:null},displayMode:{type:String,default:"card"},bioEngineReady:{type:Boolean,default:!1}},computed:Object(o["a"])({totalItems:function(){return this.allItems?this.allItems.length:0},filteredItems:function(){var e=this,t=this.allItems.filter((function(e){return e.cover_image})),n=t.concat(this.allItems.filter((function(e){return!e.cover_image})));return n.filter((function(t){return e.filters.every((function(e){return t.allLabels.includes(e)}))}))}},Object(l["b"])({siteConfig:function(e){return e.siteConfig}})),data:function(){return{isSafari:_e,currentPage:1,itemsPerPage:16}},mounted:function(){},beforeDestroy:function(){},methods:{showResourceItemInfo:function(e){this.$emit("show-resource-item-info",e)}}},fe=me,he=(n("c1ab"),Object(C["a"])(fe,F,z,!1,null,"af27f312",null)),ge=he.exports,be=function(){var e=this,t=e.$createElement,n=e._self._c||t;return e.resourceItem?n("div",{staticClass:"resource-item-info"},[n("section",{staticStyle:{"margin-bottom":"10px"}},[n("app-icons",{attrs:{apps:e.resourceItem.apps}}),e._v(" "),n("badges",{attrs:{badges:e.resourceItem.badges}})],1),n("section",[e.resourceItem.id!==e.resourceItem.nickname?[n("pre",{staticClass:"resource-id"},[e._v("🆔")]),n("pre",{ref:"resourceId",staticClass:"resource-id"},[e._v(e._s(e.resourceItem.id))]),n("b-button",{attrs:{size:"is-small","icon-left":"content-copy"},on:{click:function(t){return e.copyText(e.resourceItem.id)}}})]:e._e(),e.resourceItem.nickname_icon?n("pre",{staticClass:"resource-id",staticStyle:{"margin-left":"20px"}},[e._v(e._s(e.resourceItem.nickname_icon))]):e._e(),e.resourceItem.nickname?n("pre",{ref:"resourceNickname",staticClass:"resource-id"},[e._v(e._s(e.resourceItem.nickname))]):e._e(),e.resourceItem.nickname?n("b-button",{attrs:{size:"is-small","icon-left":"content-copy"},on:{click:function(t){return e.copyText(e.resourceItem.nickname)}}}):e._e()],2),e.resourceItem.covers&&e.resourceItem.covers.length>0?n("b-carousel",{staticStyle:{"max-width":"1024px"},attrs:{indicator:e.resourceItem.covers.length>1,arrow:e.resourceItem.covers.length>1,"pause-info":!1}},e._l(e.resourceItem.covers,(function(t){return n("b-carousel-item",{key:t},[n("figure",{staticClass:"image is-16by9"},[n("img",{staticClass:"cover-image",attrs:{loading:"lazy",src:t,alt:e.resourceItem.name,"data-target":"modal-image2"}})])])})),1):e._e(),e.resourceItem.authors&&e.resourceItem.authors.length>0?n("p",{staticClass:"authors"},[e._v(" "+e._s(e.resourceItem.authors.length>1?"Contributors: ":"Contributor: ")+" "),e._l(e.resourceItem.authors,(function(t){return n("b-tooltip",{key:t.name,attrs:{label:t.affiliation,position:"is-bottom"}},[n("span",{staticClass:"authors"},[e._v(e._s(t.name||t))])])}))],2):e._e(),n("br"),n("span",{staticStyle:{"margin-top":"3px",display:"block"}},e._l(e.resourceItem.tags,(function(t){return n("span",{key:t},[n("b-tag",{staticStyle:{cursor:"pointer"},attrs:{rounded:""}},[e._v(e._s(t))])],1)})),0),n("br"),e.resourceItem.description?n("p",[e._v(" "+e._s(e.resourceItem.description.slice(0,e.maxDescriptionLetters))+" "),e.resourceItem.description.length>e.maxDescriptionLetters?n("a",{on:{click:function(t){e.maxDescriptionLetters=e.resourceItem.description.length}}},[e._v("...show all.")]):e._e()]):e._e(),n("attachments",{attrs:{attachments:e.resourceItem.attachments,focusTarget:e.resourceItem._focus}}),n("div",{staticClass:"markdown-body"},[e.resourceItem.docs?n("markdown",{attrs:{"enable-run-buttons":!0,"run-button-context":e.runButtonContext,baseUrl:e.resourceItem.baseUrl,content:e.resourceItem.docs.slice(0,e.maxDocsLetters)}}):e._e(),e.resourceItem.docs&&e.resourceItem.docs.length>e.maxDocsLetters?n("a",{staticStyle:{color:"#0366d6"},on:{click:function(t){e.maxDocsLetters=e.resourceItem.docs.length}}},[e._v("+ click here to see the full documentation")]):e._e(),n("br"),"model"===e.resourceItem.type&&e.modelAvailable?n("test-run-form",{attrs:{resourceItem:e.resourceItem}}):e._e(),"model"!==e.resourceItem.type||e.modelAvailable?e._e():n("div",{staticClass:"not-available"},[e._v(" This model is not available for testing. ")]),n("br"),e.resourceItem.training_data_item?n("div",[n("h2",[e._v("Training Data")]),n("resource-item-card",{attrs:{resourceItem:e.resourceItem.training_data_item},on:{"show-info":function(t){return e.showResourceItemInfo(e.resourceItem.training_data_item)}}})],1):e._e(),n("h2",[e._v(" Test Summary ")]),"model"==e.resourceItem.type?n("span",[e._v(" This "+e._s(e.resourceItem.type)+" can be used in: "),n("app-icons",{attrs:{onlyLinked:!0,apps:e.resourceItem.apps}}),n("br"),n("br")],1):e._e(),e.resourceItem.test_summary&&Object.keys(e.resourceItem.test_summary).length>0?n("test-summary",{attrs:{summary:e.resourceItem.test_summary}}):e._e(),e.formatedCitation?n("h2",{attrs:{id:"citation"}},[e._v("How to cite")]):e._e(),e.formatedCitation?n("ul",{staticClass:"citation"},e._l(e.formatedCitation,(function(t){return n("li",{key:t.text},[e._v(" "+e._s(t.text)+" "),t.url?n("a",{attrs:{href:t.url,target:"_blank"}},[e._v("["+e._s(t.url_text)+"]")]):e._e()])})),0):e._e()],1),n("comment-box",{attrs:{title:e.resourceItem.name}})],1):n("h2",[e._v("Resource not found: "+e._s(e.resourceId))])},ye=[],ve=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"attachments"},[e._l(e.normalizedAttachments,(function(t,i){return[t?n("h2",{key:i+"_title",staticStyle:{"font-size":"1.5rem","font-weight":"600","margin-top":"24px","margin-bottom":"16px","text-transform":"capitalize"},attrs:{id:i}},[e._v(" "+e._s(i)+" ")]):e._e(),t?n("b-table",{key:i+"_table",attrs:{data:e.convert2Array(t),detailed:!!t.type,"show-detail-icon":!!t.type},scopedSlots:e._u([{key:"default",fn:function(t){return e._l(e.availableColumns,(function(i){return n("b-table-column",{key:i.field,attrs:{field:i.field,label:i.label,width:i.width||40,sortable:i.sortable}},[t.row[i.field]?["url"===i.type?n("a",{class:i.class,attrs:{href:t.row[i.field],target:"_blank"}},[e._v(" "+e._s(i.text)+" ")]):n("span",{class:i.class},[e._v(" "+e._s(t.row[i.field]&&t.row[i.field].slice(0,i.max_length)+(t.row[i.field].length>i.max_length?"...":""))+" ")])]:e._e()],2)}))}},{key:"detail",fn:function(e){return[n("resource-item-card",{attrs:{resourceItem:e.row}})]}}],null,!0)}):e._e()]}))],2)},we=[],ke=n("53ca"),xe={name:"Attachments",props:{attachments:{type:Object,default:null},focusTarget:{type:String,default:null}},components:{"resource-item-card":pe},data:function(){return{columns:[]}},mounted:function(){var e=this;setTimeout((function(){e.focus(e.focusTarget)}),100)},watch:{focusTarget:function(e){this.focus(e)}},computed:Object(o["a"])({availableColumns:function(){var e=this;return this.siteConfig.attachment_table.columns.filter((function(t){return e.columns.includes(t.field)}))},normalizedAttachments:function(){var e={};if(this.attachments)for(var t=0,n=Object.keys(this.attachments);t0&&void 0!==arguments[0]?arguments[0]:1e4;return new Promise((function(t,n){var i=setInterval((function(){window.app&&void 0!==window.app.imjoy&&(clearInterval(i),t(window.app.imjoy))}),100);setTimeout((function(){clearInterval(i),n(new Error("Timeout waiting for window.app.imjoy"))}),e)}))},t.next=3,n();case 3:i=t.sent,console.log("ImJoy is ready:",i),r=window.app.imjoy.api,e.api=r;case 7:case"end":return t.stop()}}),t)})))()},loadBioengineWebClient:function(){var e=this;return Object(d["a"])(regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:n=e.api,n.createWindow({src:"https://ij.imjoy.io/",name:"ImageJ.JS",fullscreen:!1,window_id:"ij-container"}),n.createWindow({src:"https://bioimage-io.github.io/bioengine-web-client/?model=".concat(e.resourceItem.id),title:"Bioengine Web Client",window_id:"bioengine-web-client"});case 3:case"end":return t.stop()}}),t)})))()}}},$e=qe,Ke=(n("e698"),Object(C["a"])($e,Fe,ze,!1,null,"7853cd72",null)),Ne=Ke.exports;function Je(e){return He.apply(this,arguments)}function He(){return He=Object(d["a"])(regeneratorRuntime.mark((function e(t){var n,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,fetch(t);case 2:if(n=e.sent,!n.ok){e.next=10;break}return e.next=6,n.text();case 6:return i=e.sent,e.abrupt("return",P["a"].load(i));case 10:throw new Error("Oops, failed to fetch test summary.");case 11:case"end":return e.stop()}}),e)}))),He.apply(this,arguments)}var Ve={name:"ResourceItemInfo",props:{resourceItem:{type:Object,default:null},showResourceItemInfo:{type:Function,default:null}},components:{markdown:Ee["a"],"test-summary":Le,badges:te,attachments:Oe,"app-icons":H,"comment-box":Be,"resource-item-card":pe,"test-run-form":Ne},data:function(){return{maxDescriptionLetters:100,maxDocsLetters:500,showSource:!1,modelAvailable:!1}},mounted:function(){var e=this,t=function(){if(e.resourceItem._focus){var t=document.getElementById(e.resourceItem._focus);t&&(t.parentNode.scrollTop=t.offsetTop-40)}};if(this.resourceItem.documentation&&this.getDocs(this.resourceItem).then(t),!this.resourceItem.test_summary){var n=this.resourceItem.source.replace(/rdf\.yaml$/,"test_summary.yaml");Je(n).then((function(t){e.resourceItem.test_summary=t,e.$forceUpdate()}))}this.getManifestList()},computed:Object(o["a"])({runButtonContext:function(){return{config:{referer:window.location.href,mode:"one",type:"bioengine"},data:this.resourceItem}},formatedCitation:function(){var e=this.resourceItem.cite;if(!e||e.length<=0)return null;this.resourceItem.cite&&!Array.isArray(this.resourceItem.cite)&&(e=[this.resourceItem.cite]);var t,n=[],i=Object(u["a"])(e);try{for(i.s();!(t=i.n()).done;){var r=t.value;if("string"===typeof r)n.push({text:r});else{var o=r.url,a="link";r.doi&&(o=r.doi.startsWith("http")?r.doi:"https://doi.org/"+r.doi,a="doi"),n.push({text:r.text,url:o,url_text:a})}}}catch(s){i.e(s)}finally{i.f()}return n}},Object(l["b"])({resourceItems:function(e){return e.resourceItems},siteConfig:function(e){return e.siteConfig}})),methods:{copyText:function(e){var t=document.createElement("input");t.style="position: absolute; left: -1000px; top: -1000px",t.value=e,document.body.appendChild(t),t.select(),document.execCommand("copy"),document.body.removeChild(t);var n={message:"Copied to your clipboard!",duration:1e3,queue:!1};this.$buefy.snackbar.open(n)},getDocs:function(e){var t=this;return Object(d["a"])(regeneratorRuntime.mark((function n(){var i,r,o,a,s,c;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return e.docs="@loading...",n.prev=1,i=e.documentation.startsWith("http")?e.documentation:Object(p["c"])(e.root_url,e.documentation),i.includes("github.")&&(i=i+"?"+Object(p["f"])()),n.next=6,fetch(i);case 6:if(r=n.sent,200!=r.status){n.next=15;break}return n.next=10,r.text();case 10:o=n.sent,e.documentation.startsWith("http")?(c=e.documentation.split("/"),a=c.slice(0,c.length-1).join("/")):(s=(e.root_url+"/"+e.documentation).split("/"),a=s.slice(0,s.length-1).join("/")),e.documentation.endsWith(".md")||e.documentation.endsWith(".md/content")?(e.baseUrl=a,e.docs=o):e.documentation&&(e.docs="### [Documentation](".concat(e.documentation,")")),n.next=16;break;case 15:e.docs=null;case 16:t.$forceUpdate(),n.next=23;break;case 19:n.prev=19,n.t0=n["catch"](1),e.docs=null,t.$forceUpdate();case 23:return n.prev=23,e.docs&&(t.maxDocsLetters=e.docs.split("\n").slice(0,5).join("\n").length),n.finish(23);case 26:case"end":return n.stop()}}),n,null,[[1,19,23,26]])})))()},getManifestList:function(){var e=this;return Object(d["a"])(regeneratorRuntime.mark((function t(){var n,i,r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return n="https://raw.githubusercontent.com/bioimage-io/bioengine-model-runner/gh-pages/manifest.bioengine.json",t.next=3,fetch(n).then((function(e){return e.json()}));case 3:i=t.sent,r=i.collection.map((function(e){return e.id})),e.modelAvailable=r.includes(e.resourceItem.id);case 6:case"end":return t.stop()}}),t)})))()}}},Ge=Ve,Ze=(n("cbfe"),Object(C["a"])(Ge,be,ye,!1,null,"23d78b12",null)),Ye=Ze.exports,Qe=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"container partners"},[n("h2",[e._v("Community Partners")]),n("b-carousel-list",{attrs:{data:e.partners,arrow:!0,"arrow-hover":!0,"items-to-list":1,"items-to-show":e.items2Show,repeat:!1,"has-drag":!0,"has-grayscale":!1,"has-opacity":!1,"icon-size":"is-large"},scopedSlots:e._u([{key:"item",fn:function(t){return[n("figure",{staticClass:"image"},[n("b-tooltip",{attrs:{label:t.list.name,position:"is-right"}},[n("a",{on:{click:function(n){return e.switchPartner(t.list)}}},[n("img",{staticClass:"partner-logo",attrs:{src:t.list.icon}})])])],1)]}}]),model:{value:e.selectedPartnerIndex,callback:function(t){e.selectedPartnerIndex=t},expression:"selectedPartnerIndex"}})],1)},Xe=[],et={name:"Partners",props:{partners:{type:Array,default:null}},data:function(){return{icon_width:140,selectedPartnerIndex:0,items2Show:window.innerWidth/140}},mounted:function(){window.addEventListener("resize",this.updateSize),window.dispatchEvent(new Event("resize"))},beforeDestroy:function(){window.removeEventListener("resize",this.updateSize)},methods:{updateSize:function(){window.innerWidth<512?this.icon_width=80:this.icon_width=140,this.items2Show=window.innerWidth/this.icon_width,this.$forceUpdate()},switchPartner:function(e){this.$emit("switchPartner",e)}}},tt=et,nt=(n("17ec"),Object(C["a"])(tt,Qe,Xe,!1,null,"a2e6d4aa",null)),it=nt.exports,rt={notebook:"notebook-outline",dataset:"database",application:"puzzle",model:"hubspot"};function ot(e){return e.replace(/_/g," ").replace(/(^|\s)\S/g,(function(e){return e.toUpperCase()}))}var at=function(){try{return document.createEvent("TouchEvent"),!0}catch(e){return!1}}();function st(e,t,n){var i,r;if(t=Object.assign({},t),t.covers=t.covers||[],t.authors=t.authors||[],t.description=t.description||"",t.covers&&!Array.isArray(t.covers)&&(t.covers=[t.covers]),"extension"===t.icon&&(t.icon="puzzle"),"dataset"===t.type&&!t.download_url&&t.source&&(t.download_url=t.source),t.covers=t.covers.map((function(e){return!e.startsWith("http")&&t.root_url?encodeURI(Object(p["c"])(t.root_url,e)):e.includes(" ")?encodeURI(e):e})),t.covers.length<=0&&(null===(i=t)||void 0===i||null===(r=i.icon)||void 0===r?void 0:r.startsWith("http"))&&t.covers.push(t.icon),t.allLabels=t.labels||[],t.license&&t.allLabels.push(t.license),t.allLabels.push(t.id),t.applications&&(t.allLabels=t.allLabels.concat(t.applications)),t.nickname&&t.allLabels.push(t.nickname),t.tags&&(t.tags=t.tags.filter((function(t){return"string"===typeof t&&!e.siteConfig.excluded_tags.includes(t)})),t.allLabels=t.allLabels.concat(t.tags.filter((function(e){return"string"===typeof e})).map((function(e){return e.toLowerCase()})))),t.allLabels=Array.from(new Set(t.allLabels.map((function(e){return e.toLowerCase()})))),t.apps=[],t.owners&&t.owners.includes(e.userId)&&t.apps.unshift({name:"Edit",icon:"pencil",show_on_hover:!0,run:function(){e.$router.push({name:"Update",params:{updateDepositId:t.id}})}}),t.apps.unshift({name:"Share",icon:"share-variant",show_on_hover:!0,run:function(){var n=Object.assign({},e.$route.query);n.id=t.id,e.$router.replace({query:n}).catch((function(){})),e.$buefy.dialog.alert({title:"Sharing "+t.type,hasIcon:!0,icon:"share",message:"Here is the URL for sharing ".concat(t.name,":
").concat(window.location.href,""),confirmText:"OK"})}}),t.config&&t.rdf_source&&t.apps.unshift({name:"Source",icon:"code-tags",show_on_hover:!0,run:function(){e.showSource(t)}}),t.download_url&&t.apps.unshift({name:"Download",icon:"download",url:t.download_url,show_on_hover:!0}),t.git_repo&&t.apps.unshift({name:"Git Repository",icon:"github",url:t.git_repo,show_on_hover:!0}),"application"===t.type)if(e.allApps[t.id])t.apps.unshift({name:"Run",icon:"play",run:function(){y(e,e.allApps[t.id],e.resourceItems)}});else if(t.tags.includes("colab")&&t.source&&t.source.endsWith(".ipynb"))if(t.config=t.config||{},t.source&&t.source.startsWith("https://raw.githubusercontent.com/")){var o=t.source.split("/");t.config._colab_url="https://colab.research.google.com/github/".concat(o[3],"/").concat(o[4],"/blob/").concat(o[5],"/").concat(o.slice(6).join("/")),t.apps.unshift({name:"Run",icon:"play",run:function(){window.open(t.config._colab_url)}})}else console.warn("Invalid colab source URL: "+t.source+" (the URL must be a raw github URL starts with https://raw.githubusercontent.com/)");t.links=t.links||[],t.id in n&&t.links.push("imjoy/imjoy"),t.training_data&&!t.links.includes(t.training_data.id)&&t.links.push(t.training_data.id);var a,s=Object(u["a"])(t.links);try{var c=function(){var n=a.value;if(["imjoy/bioimageio-packager","imjoy/genericbioengineapp"].includes(n))return"continue";var i,r=e.resourceItems.filter((function(e){return e.id.toLowerCase()===n.toLowerCase()})),o=Object(u["a"])(r);try{var s=function(){var r=i.value;t.apps.unshift({name:r.name,icon:r.icon||rt[r.type],isLinkedApp:e.allApps[n],run:function(){return Object(d["a"])(regeneratorRuntime.mark((function i(){return regeneratorRuntime.wrap((function(i){while(1)switch(i.prev=i.next){case 0:if(!e.allApps[n]){i.next=7;break}return i.next=3,e.updateFullRDF(t);case 3:return i.next=5,w(e,e.allApps[n],t);case 5:i.next=8;break;case 7:e.showResourceItemInfo(r);case 8:case"end":return i.stop()}}),i)})))()}})};for(o.s();!(i=o.n()).done;)s()}catch(c){o.e(c)}finally{o.f()}};for(s.s();!(a=s.n()).done;)c()}catch(v){s.e(v)}finally{s.f()}t.badges=t.badges||[],t.attachments=t.attachments||{};var l,_=e.resourceItems.filter((function(e){return e.links&&e.links.includes(t.id)})),m=Object(u["a"])(_);try{for(m.s();!(l=m.n()).done;){var f=l.value;t.attachments[f.type]?t.attachments[f.type].push(f):t.attachments[f.type]=[f]}}catch(v){m.e(v)}finally{m.f()}for(var h=function(){var n=b[g];Array.isArray(t.attachments[n])&&"files"!==n&&t.badges.unshift({label:n,label_type:"is-dark",ext:t.attachments[n].length,ext_type:"is-primary",run:function(){e.showAttachmentsDialog(t,n)}})},g=0,b=Object.keys(t.attachments);g0?this.currentTags=e:this.currentTags=null);var t=Object.assign({},this.$route.query);this.selectedCategory?"model"===this.selectedCategory.type&&Object.keys(t).length<=1?delete t.type:t.type=this.selectedCategory.type:t.type="all",this.currentTags?t.tags=this.currentTags.join(","):delete t.tags,this.selectedPartner?this.selectedPartner.tags&&JSON.stringify(this.selectedPartner.tags)==JSON.stringify(this.currentTags)&&delete t.tags:delete t.partner,this.$router.replace({query:t}).catch((function(){}))}},displayModeChanged:function(e){this.displayMode=e},addWindow:function(e){this.selectedDialogWindow&&this.selectedWindowsStack.push(this.selectedDialogWindow),this.selectWindow(e),this.dialogWindows.push(e),this.screenWidth<700&&(this.dialogWindowConfig.fullscreen=!0),this.$modal.show("window-modal-dialog"),this.$forceUpdate()},selectWindow:function(e){e.closing||(this.selectedDialogWindow=e)},updateSize:function(){var e=this;Object(p["d"])((function(){e.screenWidth=window.innerWidth,e.screenWidth<700&&(e.infoDialogFullscreen=!0),e.$forceUpdate()}),250)()},showLoader:function(e){e?this.loadingComponent=this.$buefy.loading.open({canCancel:!0}):this.loadingComponent&&(this.loadingComponent.close(),this.loadingComponent=null)},showAboutPartner:function(e){e.about_url.startsWith("http")?e.about_url.endsWith(".md")?(this.infoDialogTitle="About "+e.name,this.infoMarkdownUrl=e.about_url,this.showInfoDialogMode="markdown",this.screenWidth<700&&(this.infoDialogFullscreen=!0),this.$modal.show("info-dialog")):window.open(e.about_url):e.description?this.$buefy.dialog.alert({title:"About "+e.name,message:e.description,confirmText:"OK"}):this.$buefy.dialog.alert({title:"Oops, no details about "+e.name,message:"This partner is did not provide any details!",confirmText:"OK"})},showSource:function(e){e.rdf_source.endsWith(".yaml")||e.rdf_source.endsWith(".yml")?(this.infoDialogTitle="Source: "+e.name,this.infoMarkdownUrl=e.rdf_source,this.infoCommentBoxTitle=e.name,this.showInfoDialogMode="markdown",this.screenWidth<700&&(this.infoDialogFullscreen=!0),this.$modal.show("info-dialog")):e.rdf_source.startsWith("http")?window.open(e.rdf_source):this.$buefy.dialog.alert({title:"Source: "+e.name,hasIcon:!0,icon:"code-tags",message:e.rdf_source,confirmText:"OK"})},showResourceItemInfo:function(e,t){var n=this;return Object(d["a"])(regeneratorRuntime.mark((function i(){var r;return regeneratorRuntime.wrap((function(i){while(1)switch(i.prev=i.next){case 0:return n.showInfoDialogMode="model",i.next=3,n.updateFullRDF(e);case 3:e._focus=t,n.selectedResourceItem=e,n.infoDialogTitle=n.selectedResourceItem.name,n.screenWidth<700&&(n.infoDialogFullscreen=!0),n.$modal.show("info-dialog"),e.id&&!window.location.href.includes("#/r/")&&(r=Object.assign({},n.$route.query),r.id=e.id,n.initialized&&n.$router.replace({query:r}).catch((function(){})));case 9:case"end":return i.stop()}}),i)})))()},updateStatus:function(e){!0===e.loading&&this.showMessage("Loading..."),!1===e.loading&&this.showMessage("Loading done.")},closeInfoWindow:function(){this.selectedResourceItem=null,this.showInfoDialogMode=null,this.infoMarkdownUrl=null,this.infoMarkdownContent=null,this.infoCommentBoxTitle=null,this.$modal.hide("info-dialog");var e=Object.assign({},this.$route.query);delete e.id,delete e.show,this.initialized&&this.$router.replace({query:e}).catch((function(){}))},maximizeInfoWindow:function(){this.infoDialogFullscreen=!this.infoDialogFullscreen},closeDialogWindow:function(e){if(this.selectedDialogWindow.id===e.id){var t=this.dialogWindows.indexOf(e);t>=0&&this.dialogWindows.splice(t,1),this.selectedDialogWindow=this.selectedWindowsStack.pop(),this.selectedDialogWindow||this.$modal.hide("window-modal-dialog")}else console.warn("ignore close window: "+e.id)},minimizeDialogWindow:function(){this.$modal.hide("window-modal-dialog")},maximizeDialogWindow:function(){this.dialogWindowConfig.fullscreen=!this.dialogWindowConfig.fullscreen},enter:function(){this.$refs.search_anchor.scrollIntoView()},updateResourceItemList:function(e){this.selectedItems=e},updateViewByUrlQuery:function(){var e=this,t=!1;if(this.$route.query.show&&("about"===this.$route.query.show?this.showAboutDialog():"contribute"===this.$route.query.show?this.showContributeDialog():"join"===this.$route.query.show&&this.showJoinDialog()),this.$route.query.id){var n=this.resourceItems.filter((function(t){return t.id===e.$route.query.id}))[0];n?(this.showResourceItemInfo(n),t=!0):alert("Oops, resource item not found: "+this.$route.query.id+". Possibly because it has not been approved yet.")}else if(this.$route.query.nickname){var i=this.resourceItems.filter((function(t){return t.nickname===e.$route.query.nickname}))[0];i?(this.showResourceItemInfo(i),t=!0):alert("Oops, resource item not found: "+this.$route.query.nickname)}if(this.$route.query.tags){var r=null;r="string"===typeof this.$route.query.tags?this.$route.query.tags.split(","):this.$route.query.tags,setTimeout((function(){e.searchTags=r}),0),t=!0}this.$route.query.type&&("all"===this.$route.query.type?this.selectedCategory=null:this.selectedCategory=this.resourceCategories.filter((function(t){return t.type===e.$route.query.type}))[0],t=!0),this.$route.query.partner&&this.siteConfig.partners&&(this.selectedPartner=this.siteConfig.partners.filter((function(t){return t.id===e.$route.query.partner}))[0],this.selectedPartner&&(this.$nextTick((function(){e.searchTags?e.searchTags=e.searchTags.concat(e.selectedPartner.tags):e.searchTags=e.selectedPartner.tags})),t=!1)),t&&this.enter(),this.initialized=!0},showProgress:function(e){this.progress=e,this.$forceUpdate()},showMessage:function(e,t){t=t||5e3;var n={message:e.slice(0,200),onAction:function(){},actionText:"Close",duration:t,queue:!1};this.$buefy.snackbar.open(n)},showWindowDialog:function(){},closeWindowDialog:function(){},getLabelCount:function(e){return this.filteredModels.filter((function(t){return t.allLabels.includes(e)})).length},getModelsCount:function(){return this.filteredModels.length}}},lt=ct,ut=(n("cccb"),Object(C["a"])(lt,j,D,!1,null,null,null)),dt=ut.exports,pt=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"upload width-limited",style:{height:e.client.credential?"":"calc(100vh - 70px)","background-image":e.client.credential?null:"url("+e.siteConfig.background_image+")"}},[n("b-notification",{attrs:{type:"is-warning","has-icon":"","aria-close-label":"Close notification",role:"alert"}},[e._v(" Due to a significant API change in Zenodo (https://zenodo.org), you can only upload the model by login directly to "),n("a",{attrs:{href:"https://zenodo.org"}},[e._v("Zenodo")]),e._v(" by following the tutorial: "),n("br"),n("b-button",{on:{click:function(t){return e.openUrl("https://bioimage.io/docs/#/contribute_models/contribute_zenodo.md")}}},[e._v("Upload models via Zenodo")])],1),e.client.isSandbox?n("b-notification",{attrs:{type:"is-warning","has-icon":"","aria-close-label":"Close notification",role:"alert"}},[e._v(" You are using the development mode of the upload feature, this means files will be uploaded to the sandbox version of Zenodo (https://sandbox.zenodo.org). The uploaded files can be removed from Zenodo at any time without notice. This is temporary. In the future, the upload feature will connect to the main Zenodo storage and allow permanent storage of your data. ")]):e._e(),n("b-steps",{directives:[{name:"show",rawName:"v-show",value:!1,expression:"false"}],staticStyle:{"margin-top":"20px"},attrs:{position:"left","has-navigation":!1,"label-position":"right"},model:{value:e.stepIndex,callback:function(t){e.stepIndex=t},expression:"stepIndex"}},[n("b-step-item",{attrs:{disabled:e.rdfYaml,label:"Start",icon:"file"}},[e.client.credential?n("b-field",{attrs:{label:"You have already logged in via Zenodo",message:"BioImage.IO uses https://zenodo.org as storage service, you will need to sign up or login to Zenodo, and allow BioImage.IO to upload files to zenodo on your behalf.",expanded:""}},[n("b-button",{staticClass:"button is-small",staticStyle:{"text-transform":"none"},attrs:{"icon-left":"logout"},on:{click:function(t){return e.client.logout()}}},[e._v("Logout")])],1):n("b-field",{attrs:{label:"Please login or signup to Zenodo.org",message:"BioImage.IO uses https://zenodo.org as storage service, you will need to sign up or login to Zenodo, and allow BioImage.IO to upload files to zenodo on your behalf.",expanded:""}},[n("b-button",{staticClass:"button is-fullwidth is-primary",staticStyle:{"text-transform":"none"},attrs:{expanded:"","icon-left":"login"},on:{click:function(t){return e.login()}}},[e._v("Login to Zenodo")])],1),e.client.credential?n("b-field",{attrs:{label:"Option 1: Select a local file",expanded:""}},[n("b-upload",{attrs:{"drag-drop":"",expanded:""},on:{input:function(t){return e.fileSelected(e.dropFile)}},model:{value:e.dropFile,callback:function(t){e.dropFile=t},expression:"dropFile"}},[n("section",{staticClass:"section"},[n("div",{staticClass:"content has-text-centered"},[n("p",[n("b-icon",{attrs:{icon:"upload",size:"is-large"}})],1),n("p",[e._v(" Please select the zip package (*.zip) or the RDF file (*.yaml) ")]),n("p",[e._v("Drop your files here or click to upload")])])])])],1):e._e(),e.client.credential?n("b-field",{attrs:{label:"Option 2: Input RDF fields manually"}},[n("b-button",{staticClass:"button is-fullwidth",staticStyle:{"text-transform":"none"},attrs:{expanded:""},on:{click:function(t){return e.initializeRdfForm()}}},[e._v("Fill the RDF form")])],1):e._e(),e.client.credential?n("b-field",{attrs:{label:"Option 3: Load from DOI or URL",message:"A URI can be a Zenodo DOI, Zenodo URL or Github URL to the RDF file"}},[n("b-input",{attrs:{type:"url",placeholder:"Type a DOI or URL here"},model:{value:e.URI4Load,callback:function(t){e.URI4Load=t},expression:"URI4Load"}})],1):e._e(),e.client.credential?n("b-button",{staticClass:"button is-fullwidth",staticStyle:{"text-transform":"none"},attrs:{expanded:""},on:{click:function(t){return e.loadRdfFromURL(e.URI4Load)}}},[e._v("Load")]):e._e()],1),n("b-step-item",{attrs:{label:"Edit",icon:"pencil",disabled:!e.rdfYaml}},[n("section",{staticStyle:{padding:"20px"}},[e.jsonFields&&e.jsonFields.length>0?n("form-json",{attrs:{btnReset:{value:"Reset"},btnSubmit:{value:"OK"},camelizePayloadKeys:!1,formFields:e.jsonFields,formName:"metadata",components:e.components},on:{formSubmitted:e.formSubmitted}}):e._e(),n("br"),n("b-field",{attrs:{label:"Optionally, you can update the form with values from an local RDF file",message:"Note: This operation will overwrite the values in the above RDF form, if you have further changes to make, please load the local RDF file first, then make changes in the form.",expanded:""}},[n("b-upload",{staticClass:"file-label",on:{input:function(t){return e.updateFormWithLocalFile(e.newRDFFile)}},model:{value:e.newRDFFile,callback:function(t){e.newRDFFile=t},expression:"newRDFFile"}},[n("span",{staticClass:"file-cta"},[n("b-icon",{staticClass:"file-icon",attrs:{icon:"upload"}}),n("span",{staticClass:"file-label"},[e._v("Load a local RDF file ["+e._s(e.newRDFFile?e.newRDFFile.name:"")+"]")])],1)])],1)],1)]),n("b-step-item",{attrs:{label:"Review & Upload",icon:"upload"}},[e.rdfYaml?n("b-field",{staticStyle:{height:"260px",overflow:"auto"},attrs:{label:"RDF content"}},[e.rdfYaml?n("markdown",{attrs:{baseUrl:"",content:e.formatedModelYaml}}):e._e()],1):e._e(),e.zipPackage?n("b-field",{attrs:{label:"Files",message:"These files will be uploaded"}},[n("b-taglist",{attrs:{attached:"",rounded:""}},e._l(e.zipPackage.files,(function(t,i){return n("b-tag",{key:i,attrs:{rounded:""}},[e._v(e._s(i))])})),1)],1):e.editedFiles?n("b-field",{attrs:{label:"Files",message:"The following files will be updated"}},[n("b-taglist",{attrs:{attached:"",rounded:""}},e._l(e.editedFiles,(function(t){return n("b-tag",{key:t.name,attrs:{rounded:""}},[e._v(e._s(t.name))])})),1)],1):e._e(),n("div",{staticClass:"column"},[e.zipPackage||e.editedFiles?n("b-button",{staticClass:"button is-fullwidth",staticStyle:{"text-transform":"none"},attrs:{expanded:"","icon-left":"download"},on:{click:function(t){return e.exportPackage()}}},[e._v("Export package locally")]):e._e()],1),n("br"),e.similarDeposits&&e.similarDeposits.length>0?n("div",[n("label",{staticClass:"label"},[e._v("Similar Existing Items")]),n("p",[e._v(" The following published deposit(s) are similar to yours (matched by name), please make sure you are using distinctive names to avoid confusion to the users. ")]),e._l(e.similarDeposits,(function(t){return n("b-notification",{key:t.id,attrs:{type:t.name===e.rdf.name?"is-danger":null,"aria-close-label":"Close notification"}},[n("h1",[n("a",{attrs:{href:t.config._deposit.links.html,target:"_blank"}},[e._v(e._s(t.name))])]),n("p",[e._v(e._s(t.description.slice(0,200)))]),n("p",[e._v(" Authors: "+e._s(t.authors.map((function(e){return e.name.split(";")[0]})).join(","))+" ")]),n("p",[e._v("Uploaded: "+e._s(t.config._deposit.updated))]),n("br"),n("div",{staticClass:"columns"},[e.userId&&t.config._deposit&&t.config._deposit.owners.includes(e.userId)?n("b-button",{staticClass:"column button is-primary is-light is-fullwidth",attrs:{expanded:"","icon-left":"autorenew"},on:{click:function(n){return e.createOrUpdateDeposit(t.config._deposit.id,!1)}}},[n("span",[e._v("Update as a new version")])]):e._e()],1)])})),n("b-button",{staticClass:"button is-fullwidth",class:{"is-primary":e.sameNameDeposits&&e.sameNameDeposits.length>0},staticStyle:{"text-transform":"none"},attrs:{expanded:"","icon-left":"arrow-left"},on:{click:function(t){e.stepIndex=1}}},[e._v("Go back to rename")])],2):e._e(),n("br"),n("b-field",[n("b-switch",{model:{value:e.requestedJoinCommunity,callback:function(t){e.requestedJoinCommunity=t},expression:"requestedJoinCommunity"}},[e._v(" Apply for listing in the "),n("a",{attrs:{href:e.client.baseURL+"/communities/"+e.siteConfig.zenodo_config.community,target:"_blank"}},[e._v("bioimage.io community list")])])],1),e.uploadStatus?n("p",[e._v(e._s(e.uploadStatus))]):e._e(),e.uploadProgress?n("b-progress",{attrs:{type:"is-primary",value:e.uploadProgress,size:"is-small",expanded:""}}):e._e(),n("div",{staticClass:"columns"},[e.client&&(e.zipPackage||e.editedFiles)?n("div",{staticClass:"column"},[n("b-button",{staticClass:"button is-primary is-light is-fullwidth",attrs:{disabled:e.uploadProgress||e.sameNameDeposits&&e.sameNameDeposits.length>0,expanded:"","icon-left":"plus"},on:{click:function(t){return e.createOrUpdateDeposit()}}},[n("span",[e._v("Upload as new deposit")])])],1):e._e(),e.client&&(e.zipPackage||e.editedFiles)&&e.depositId?n("div",{staticClass:"column"},[n("b-button",{staticClass:"button is-primary is-light is-fullwidth",attrs:{disabled:e.uploadProgress,expanded:"","icon-left":"autorenew"},on:{click:function(t){return e.createOrUpdateDeposit(e.depositId,!1)}}},[n("span",[e._v("Add new version to deposit")])])],1):e._e()])],1),n("b-step-item",{attrs:{label:"Publish",icon:"share-variant",disabled:""}},[e.publishedUrl?n("b-notification",{attrs:{type:"is-success","has-icon":"","aria-close-label":"Close notification"}},[n("h1",[e._v("Published on Zenodo")]),n("h2",[e._v("DOI: "+e._s(e.publishedDOI))]),n("h2",[n("a",{attrs:{href:e.publishedUrl,target:"_blank"}},[e._v(e._s(e.publishedUrl))])]),n("p",[e._v(" Note: Newly uploaded item may not appear immediately in the resource list. ")]),e.requestedJoinCommunity?n("p",[e._v(" To be listed as part of the verified bioimage.io community list, a notification will be sent to the admin team and we will review request soon. ")]):e._e()]):e.prereserveDOI?n("b-notification",{attrs:{"has-icon":"","aria-close-label":"Close notification"}},[n("h1",[e._v("Ready to publish")]),n("h2",[e._v("Preserved DOI: "+e._s(e.prereserveDOI.doi))]),n("h2",[e._v(" You can also review and add additional information on Zenodo: "),n("a",{attrs:{href:e.prereserveUrl,target:"_blank"}},[e._v(e._s(e.prereserveUrl))])]),n("p",[e._v(" Note: Please check carefully before publishing. It is generally not possible to remove items after they have been published. Changes will be added as a new version, but will not erase the previous version. ")])]):e._e(),e.notifyCIStatus?n("b-notification",{ref:"ci_status",attrs:{"has-icon":"","aria-close-label":"Close notification"}},[n("h3",[e._v(" "+e._s(e.notifyCIStatus)+" ")]),e.notifyCIFailed?n("b-button",{staticClass:"button is-fullwidth",staticStyle:{"text-transform":"none"},attrs:{expanded:""},on:{click:function(t){return e.notifyBot()}}},[e._v("Try Again")]):e._e()],1):e._e(),"update"===e.uploadMode?n("b-notification",{attrs:{"has-icon":"",type:"is-info","aria-close-label":"Close notification"}},[n("p",[e._v(" Note: After publishing the updated deposit, you may see the item disappear from the website, this is normal because Zenodo need some time to index the new version. It should combe back in a while. ")])]):e._e(),e.client&&e.client.credential&&e.uploaded&&!e.publishedUrl?n("b-button",{staticClass:"button is-primary is-fullwidth",attrs:{expanded:""},on:{click:function(t){return e.publishDeposition()}}},[n("b-icon",{attrs:{icon:"upload"}}),n("span",[e._v("Publish")])],1):e._e()],1)],1),n("section",{staticStyle:{padding:"10px"}})],1)},_t=[],mt=(n("07ac"),n("466d"),n("21a6")),ft=(n("fb5f"),n("0df0")),ht=n.n(ft),gt=n("c4e3"),bt=n.n(gt),yt=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("label",{staticClass:"label",attrs:{for:e.item.label}},[e._v(" "+e._s(e.item.label)+" "),!1!==e.item.isRequired?n("sup",{staticClass:"has-text-grey-light is-size-7"},[e._v("*")]):e._e()]),n("div",{staticClass:"control"},[n("b-taginput",{attrs:{id:e.item.label,data:e.filteredTags,"allow-new":!1!==e.item.allow_new,"open-on-focus":e.item.options&&e.item.options.length>0,autocomplete:"",icon:e.item.icon||"label",placeholder:e.item.placeholder},on:{input:function(t){return e.$emit("input",e.value)},typing:e.getFilteredTags},model:{value:e.value,callback:function(t){e.value=t},expression:"value"}}),e.error?n("p",{staticClass:"help is-danger"},[e._v(" "+e._s(e.error)+" ")]):e._e()],1)])},vt=[],wt={name:"tags",props:{error:{type:String,default:null},item:{type:Object,required:!0}},data:function(){return{value:void 0,filteredTags:[]}},mounted:function(){this.filteredTags=this.item.options},created:function(){this.value=this.item.value,this.item.value&&this.$emit("input",this.item.value)},methods:{getFilteredTags:function(e){this.filteredTags=this.item.options&&this.item.options.filter((function(t){return t.toString().toLowerCase().indexOf(e.toLowerCase())>=0}))}}},kt=wt,xt=(n("106f"),Object(C["a"])(kt,yt,vt,!1,null,null,null)),It=xt.exports,Ct=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[e.item.showLabel?n("label",{staticClass:"label",attrs:{for:e.item.label}},[e._v(" "+e._s(e.item.label)+" "),e.item.help?n("span",{staticClass:"helpLabel has-text-grey-light is-size-7 is-italic",staticStyle:{"margin-left":"0.5rem","font-weight":"400"}},[e._v(" "+e._s(e.item.help)+" ")]):e._e(),!1!==e.item.isRequired?n("sup",{staticClass:"has-text-grey-light is-size-7"},[e._v("*")]):e._e()]):e._e(),n("div",{staticClass:"control"},[n("b-button",{staticClass:"select-button",style:e.item.style,attrs:{expanded:"",type:e.callbackError?"is-danger":e.item.value?"is-success":"is-warning is-light",id:e.item.label,"icon-left":e.item.icon},on:{click:function(t){return e.resolveCallback(e.item)}}},[e._v(" "+e._s(e.item.label)+" ")]),e.callbackError?n("pre",[e._v(e._s(e.callbackError))]):e._e(),n("p",{staticClass:"help is-info"},[e._v(e._s(e.trimEllip(e.item.value,20)))]),e.error?n("p",{staticClass:"help is-danger"},[e._v(" "+e._s(e.error)+" ")]):e._e()],1)])},Ot=[],Et={name:"button",props:{error:{type:String,default:null},item:{type:Object,required:!0}},data:function(){return{value:void 0,callbackError:null}},created:function(){this.value=this.item.value,this.item.value&&this.$emit("input",this.item.value)},methods:{trimEllip:function(e,t){return e?("object"===Object(ke["a"])(e)&&(e=e.toString()),e.length>t?e.substring(0,t)+"...":e):e},syntaxHighlight:function(e){return"string"!=typeof e&&(e=JSON.stringify(e,void 0,2)),e=e.replace(/&/g,"&").replace(//g,">"),e.replace(/("(\\u[a-zA-Z0-9]{4}|\\[^u]|[^\\"])*"(\s*:)?|\b(true|false|null)\b|-?\d+(?:\.\d*)?(?:[eE][+-]?\d+)?)/g,(function(e){var t="number";return/^"/.test(e)?t=/:$/.test(e)?"key":"string":/true|false/.test(e)?t="boolean":/null/.test(e)&&(t="null"),''+e+""}))},resolveCallback:function(e){var t=this;return Object(d["a"])(regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return n.prev=0,n.next=3,Promise.resolve(e.callback());case 3:t.item.value=n.sent,t.$emit("input",t.item.value),n.next=10;break;case 7:n.prev=7,n.t0=n["catch"](0),t.callbackError="".concat(n.t0);case 10:t.$forceUpdate();case 11:case"end":return n.stop()}}),n,null,[[0,7]])})))()}}},Rt=Et,jt=Object(C["a"])(Rt,Ct,Ot,!1,null,null,null),Dt=jt.exports,Pt=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("label",{staticClass:"label",attrs:{for:e.item.label}},[e._v(" "+e._s(e.item.label)+" "),!1!==e.item.isRequired?n("sup",{staticClass:"has-text-grey-light is-size-7"},[e._v("*")]):e._e()]),n("div",{staticClass:"control"},[n("section",[n("b-field",[n("b-upload",{attrs:{id:e.item.label,multiple:"","drag-drop":"",expanded:""},on:{input:function(t){return e.updateFiles()}},model:{value:e.value,callback:function(t){e.value=t},expression:"value"}},[n("section",{staticClass:"section"},[n("div",{staticClass:"content has-text-centered"},[n("b-icon",{attrs:{icon:"upload",size:"is-large"}}),e._v(" Drop additional files here "),n("br"),e._l(e.value,(function(t,i){return n("span",{key:i,staticClass:"tag is-primary"},[e._v(" "+e._s(t.name.slice(0,20)+(t.name.length>20?"...":""))+" "),n("button",{staticClass:"delete is-small",attrs:{type:"button"},on:{click:function(t){return t.preventDefault(),e.removeFile(e.item.label,i)}}})])})),n("br"),e.value&&e.value.length>0?n("b-button",{staticClass:"is-small",on:{click:function(t){return t.preventDefault(),e.clearFiles()}}},[e._v("Clear files")]):e._e()],2)])])],1)],1),e.error?n("p",{staticClass:"help is-danger"},[e._v(" "+e._s(e.error)+" ")]):e._e()])])},Tt=[],Lt={name:"files",props:{error:{type:String,default:null},item:{type:Object,required:!0}},data:function(){return{value:void 0}},created:function(){this.value=this.item.value,this.item.value&&this.$emit("input",this.item.value)},methods:{removeFile:function(e,t){this.value.splice(t,1),this.$forceUpdate()},clearFiles:function(){this.value=null,this.$emit("input",null),this.$forceUpdate()},updateFiles:function(){this.$emit("input",this.value),this.$forceUpdate()},trimEllip:function(e,t){return e?("object"===Object(ke["a"])(e)&&(e=e.toString()),e.length>t?e.substring(0,t)+"...":e):e}}},Mt=Lt,St=Object(C["a"])(Mt,Pt,Tt,!1,null,null,null),At=St.exports,Ut=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("label",{staticClass:"label",attrs:{for:e.item.label}},[e._v(" "+e._s(e.item.label)+" "),n("span",{staticClass:"helpLabel has-text-grey-light is-size-7 is-italic",staticStyle:{"margin-left":".5rem","font-weight":"400"}},[e._v(e._s(e.item.help))]),!1!==e.item.isRequired?n("sup",{staticClass:"has-text-grey-light is-size-7"},[e._v("*")]):e._e()]),n("div",{staticClass:"control"},[e._l(e.value,(function(t,i){return n("div",{key:i},[n("b-field",[n("b-input",{attrs:{type:"text",placeholder:"Citation text",maxlength:"1000"},on:{input:e.commitValue},model:{value:t.text,callback:function(n){e.$set(t,"text",n)},expression:"citation.text"}}),n("b-input",{attrs:{type:"text",placeholder:"DOI (optional)",maxlength:"100"},on:{input:e.commitValue},model:{value:t.doi,callback:function(n){e.$set(t,"doi",n)},expression:"citation.doi"}}),n("b-input",{attrs:{type:"text",placeholder:"URL (optional)",maxlength:"1000"},on:{input:e.commitValue},model:{value:t.url,callback:function(n){e.$set(t,"url",n)},expression:"citation.url"}}),e.value.length>1?n("b-button",{staticClass:"button",staticStyle:{"text-transform":"none"},attrs:{"icon-left":"delete"},on:{click:function(n){return e.removeCitation(t)}}}):e._e(),i===e.value.length-1&&t.text&&""!==t.text?n("b-button",{staticClass:"button",staticStyle:{"text-transform":"none"},attrs:{"icon-left":"plus"},on:{click:e.addNewCitation}}):e._e()],1)],1)})),e.error?n("p",{staticClass:"help is-danger"},[e._v(" "+e._s(e.error)+" ")]):e._e()],2)])},Wt=[],Bt={name:"citation",props:{error:{type:String,default:null},item:{type:Object,required:!0}},data:function(){return{value:void 0,filteredTags:[]}},mounted:function(){this.filteredTags=this.item.options},created:function(){this.value=this.item.value,"string"===typeof this.value&&(this.value=[{text:this.value}]),this.value&&!Array.isArray(this.value)&&(this.value=[this.value]),this.value=this.value||[],this.value.length<=0&&this.value.push({text:"",doi:"",url:""}),this.commitValue()},methods:{commitValue:function(){this.value.length<=0?this.$emit("input",null):""===this.value[this.value.length-1].text?this.$emit("input",this.value.slice(0,this.value.length-1)):this.$emit("input",this.value)},addNewCitation:function(){""!==this.value[this.value.length-1].text&&this.value.push({}),this.commitValue()},removeCitation:function(e){var t=this.value.indexOf(e);t>=0&&this.value.splice(t,1),this.commitValue()}}},Ft=Bt,zt=(n("fff7"),Object(C["a"])(Ft,Ut,Wt,!1,null,null,null)),qt=zt.exports,$t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("label",{staticClass:"label",attrs:{for:e.item.label}},[e._v(" "+e._s(e.item.label)+" "),n("span",{staticClass:"helpLabel has-text-grey-light is-size-7 is-italic",staticStyle:{"margin-left":".5rem","font-weight":"400"}},[e._v(e._s(e.item.help))]),!1!==e.item.isRequired?n("sup",{staticClass:"has-text-grey-light is-size-7"},[e._v("*")]):e._e()]),n("div",{staticClass:"control"},[e._l(e.value,(function(t,i){return n("div",{key:i},[n("b-field",[n("b-input",{attrs:{type:"text",placeholder:"Full Name (required)",maxlength:"1000"},on:{input:e.commitValue},model:{value:t.name,callback:function(n){e.$set(t,"name",n)},expression:"author.name"}}),e.item.options.includes("affiliation")?n("b-input",{attrs:{type:"text",placeholder:"Affiliation (optional)",maxlength:"100"},on:{input:e.commitValue},model:{value:t.affiliation,callback:function(n){e.$set(t,"affiliation",n)},expression:"author.affiliation"}}):e._e(),e.item.options.includes("orcid")?n("b-input",{attrs:{type:"text",placeholder:"ORCID (optional)",maxlength:"1000"},on:{input:e.commitValue},model:{value:t.orcid,callback:function(n){e.$set(t,"orcid",n)},expression:"author.orcid"}}):e._e(),e.item.options.includes("github_user")?n("b-input",{attrs:{type:"text",placeholder:"Github User (required)",maxlength:"100"},on:{input:e.commitValue},model:{value:t.github_user,callback:function(n){e.$set(t,"github_user",n)},expression:"author.github_user"}}):e._e(),e.item.options.includes("email")?n("b-input",{attrs:{type:"text",placeholder:"Email (optional)",maxlength:"1000"},on:{input:e.commitValue},model:{value:t.email,callback:function(n){e.$set(t,"email",n)},expression:"author.email"}}):e._e(),e.value.length>1?n("b-button",{staticClass:"button",staticStyle:{"text-transform":"none"},attrs:{"icon-left":"delete"},on:{click:function(n){return e.removeAuthor(t)}}}):e._e(),i===e.value.length-1&&t.name&&""!==t.name?n("b-button",{staticClass:"button",staticStyle:{"text-transform":"none"},attrs:{"icon-left":"plus"},on:{click:e.addNewAuthor}}):e._e()],1)],1)})),e.error?n("p",{staticClass:"help is-danger"},[e._v(" "+e._s(e.error)+" ")]):e._e()],2)])},Kt=[],Nt={name:"author",props:{error:{type:String,default:null},item:{type:Object,required:!0}},data:function(){return{value:void 0,filteredTags:[]}},mounted:function(){this.filteredTags=this.item.options},created:function(){this.value=this.item.value,this.value&&!Array.isArray(this.value)&&(this.value=[this.value]),this.value=this.value||[],this.value.forEach((function(e){return e.name=e.name||e.github_user})),this.value=this.value.filter((function(e){return e.name&&""!=e.name})),this.commitValue(),this.value.length<=0&&this.value.push({})},methods:{commitValue:function(){this.value.length<=0?this.$emit("input",null):""===this.value[this.value.length-1].name?this.$emit("input",this.value.slice(0,this.value.length-1)):this.$emit("input",this.value)},addNewAuthor:function(){""!==this.value[this.value.length-1].name&&this.value.push({}),this.commitValue()},removeAuthor:function(e){var t=this.value.indexOf(e);t>=0&&this.value.splice(t,1),this.commitValue()}}},Jt=Nt,Ht=(n("e067"),Object(C["a"])(Jt,$t,Kt,!1,null,null,null)),Vt=Ht.exports,Gt=n("67be"),Zt=n.n(Gt),Yt=n("0e54"),Qt=n.n(Yt),Xt=n("c0c4"),en=n.n(Xt),tn={name:"upload",props:["updateDepositId"],components:{"form-json":ht.a,markdown:Ee["a"],TagInputField:It,SelectButtonField:Dt,DropFilesField:At,AuthorInputField:Vt,CitationInputField:qt},mounted:function(){this.dropFile=null,this.uploadStatus="",this.uploadProgress=0,this.$root.$on("formSubmitted",this.formSubmitted),this.updateDepositId&&this.startFromDepositURL().catch((function(e){alert("Failed to load from deposit URL: ".concat(e))}))},computed:Object(o["a"])({sameNameDeposits:function(){var e=this;return this.similarDeposits&&this.similarDeposits.filter((function(t){return t.name===e.rdf.name}))},formatedModelYaml:function(){return this.rdfYaml&&"```yaml\n"+this.rdfYaml+"\n```\n"},prereserveUrl:function(){return this.prereserveDOI?"".concat(this.$store.state.zenodoBaseURL,"/deposit/").concat(this.prereserveDOI.recid):null},userId:function(){return this.client&&this.client.getUserId()},components:function(){return{TagInputField:It,SelectButtonField:Dt,DropFilesField:At,AuthorInputField:Vt,CitationInputField:qt}}},Object(l["b"])({allTags:function(e){return e.allTags},resourceItems:function(e){return e.resourceItems},client:function(e){return e.zenodoClient},zenodoBaseURL:function(e){return e.zenodoBaseURL},siteConfig:function(e){return e.siteConfig}})),data:function(){return{dropFile:null,uploadProgress:0,uploadStatus:"",uploaded:!1,jsonFields:null,zipFiles:null,rdfYaml:null,rdf:null,stepIndex:0,publishedUrl:null,publishedDOI:null,notifyCIStatus:null,notifyCIFailed:!1,requestedJoinCommunity:!0,rdfType:"model",zipPackage:null,editedFiles:null,prereserveDOI:null,URI4Load:null,similarDeposits:null,depositId:null,newRDFFile:null,uploadMode:null}},methods:{openUrl:function(e){window.open(e)},startFromDepositURL:function(){var e=this;return Object(d["a"])(regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(n=e.$buefy.loading.open({container:e.$el}),t.prev=1,e.client.credential){t.next=5;break}return t.next=5,e.login();case 5:return e.URI4Load="".concat(e.zenodoBaseURL,"/record/").concat(e.updateDepositId.split("zenodo.")[1]),t.next=8,e.loadRdfFromURL(e.URI4Load);case 8:t.next=13;break;case 10:t.prev=10,t.t0=t["catch"](1),alert("Failed to load resource: "+e.updateDepositId);case 13:return t.prev=13,n.close(),t.finish(13);case 16:case"end":return t.stop()}}),t,null,[[1,10,13,16]])})))()},fileSelected:function(e){var t=this;return Object(d["a"])(regeneratorRuntime.mark((function n(){var i,r,o,a;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(i=t.$buefy.loading.open({container:t.$el}),n.prev=1,!e.name.endsWith(".yaml")){n.next=11;break}return n.next=5,new Promise((function(t,n){var i=new FileReader;i.onload=function(e){t(e.target.result)},i.onerror=n,i.readAsText(e)}));case 5:t.rdfYaml=n.sent,r=e,t.zipPackage=new bt.a,t.zipPackage.file(e.name,e),n.next=28;break;case 11:if(e.name.endsWith(".zip")){n.next=16;break}throw alert("Only .zip and .yaml file are supported."),new Error("Only zip and .yaml file are supported");case 16:return o=new bt.a,n.next=19,o.loadAsync(e);case 19:if(t.zipPackage=n.sent,console.log(t.zipPackage.files),t.zipPackage.files["model.yaml"]||t.zipPackage.files["rdf.yaml"]){n.next=24;break}throw alert("Invalid file: no model.yaml or rdf.yaml found in the model package."),new Error("Invalid file: no rdf file found in the package");case 24:return r=t.zipPackage.files["rdf.yaml"]||t.zipPackage.files["model.yaml"],n.next=27,r.async("string");case 27:t.rdfYaml=n.sent;case 28:if(a=P["a"].load(t.rdfYaml),"model.yaml"===r.name&&(a.type="model"),a.type){n.next=33;break}throw alert("Invalid rdf file: type key is not found"),new Error("Invalid rdf file: type key is not found");case 33:a.config=a.config||{},a.rdf_source="./"+r.name,"model"===a.type&&(a.links=a.links||[],a.links.push("imjoy/BioImageIO-Packager")),t.initializeRdfForm(a,Object.values(t.zipPackage.files)),n.next=42;break;case 39:n.prev=39,n.t0=n["catch"](1),console.error(n.t0);case 42:return n.prev=42,i.close(),n.finish(42);case 45:case"end":return n.stop()}}),n,null,[[1,39,42,45]])})))()},loadRdfFromURL:function(e){var t=this;return Object(d["a"])(regeneratorRuntime.mark((function n(){var i,r,o,a,s;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(n.prev=0,i=Zt.a.resolvePath(),!i.test(e)){n.next=8;break}return n.next=5,Object(p["i"])(e.match(i)[4]);case 5:e=n.sent,n.next=12;break;case 8:if(!Zt()().test(e)){n.next=12;break}return n.next=11,Object(p["i"])(e);case 11:e=n.sent;case 12:if(r=/zenodo.org\/(record|deposit)\/([0-9]+)/g,o=r.exec(e),!o){n.next=33;break}if(t.depositId=parseInt(o[2]),!e.includes("/record/")){n.next=22;break}return n.next=19,t.client.getDeposit(t.depositId);case 19:a=n.sent,n.next=27;break;case 22:return n.next=24,t.client.getCredential(!0);case 24:return n.next=26,t.client.retrieve(t.depositId);case 26:a=n.sent;case 27:return console.log("orcid matched: "+t.depositId,a),n.next=30,Object(p["e"])(a);case 30:s=n.sent,t.zipPackage=null,t.initializeRdfForm(s,a.files.map((function(e){return{type:"remote",name:e.filename||e.key,size:e.filesize||e.size,url:e.links.self,checksum:e.checksum}})));case 33:n.next=38;break;case 35:n.prev=35,n.t0=n["catch"](0),alert("Oops, failed to fetch RDF from ".concat(e,", error: ").concat(n.t0));case 38:case"end":return n.stop()}}),n,null,[[0,35]])})))()},updateFormWithLocalFile:function(e){var t=this;return Object(d["a"])(regeneratorRuntime.mark((function n(){var i,r;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return n.next=2,new Promise((function(t,n){var i=new FileReader;i.onload=function(e){t(e.target.result)},i.onerror=n,i.readAsText(e)}));case 2:i=n.sent,r=P["a"].load(i),r.config=r.config||{},r.rdf_source="./"+e.name,t.jsonFields=null,setTimeout((function(){t.initializeRdfForm(r)}),10);case 8:case"end":return n.stop()}}),n)})))()},initializeRdfForm:function(e,t){var n=this;this.stepIndex=1,this.rdf=e||{},delete this.rdf.id,this.rdf.links=this.rdf.links||[],t=t||this.files||[];var i=this.siteConfig.resource_categories.map((function(e){return e.type}));this.rdf.tags=this.rdf.tags||[],this.rdf.tags=this.rdf.tags.map((function(e){return e.toLowerCase().replace(/ /g,"-")})),this.jsonFields=this.transformFields([{label:"Type",type:"select",placeholder:"Select resource type",options:i.map((function(e){return{text:e,value:e,selected:n.rdf.type===e}}))},{label:"Name",placeholder:"name",value:this.rdf.name,help:"The name of your deposit (note: / is not allowed in the name)"},{label:"Description",placeholder:"description",value:this.rdf.description},{label:"Authors",type:"author",options:["name","orcid","affiliation"],value:this.rdf.authors,help:"The authors who contributed to this resource item"},{label:"Maintainers",type:"author",options:["name","email","github_user"],value:this.rdf.maintainers,help:"The maintainers who maintain this resource item. Importantly, the first maintainer will be contacted for the approval process to the BioImage.IO"},{label:"Version",placeholder:"Version in MAJOR.MINOR.PATCH format(e.g. 0.1.0)",isRequired:!1,value:this.rdf.version||"0.1.0"},{html:'

LicenseChoose the license that fits you most, we recommend to use CC-BY-4.0 (free to share and adapt under the condition of attribution). For other license options, please visit here https://spdx.org/licenses *

'},{label:"License",showLabel:!1,type:"select",placeholder:"Select your license",options:Object.keys(L.a).map((function(e){return{text:e,value:e,selected:n.rdf.license===e}})),help:"A short description in one sentence"},{label:"Git repository",placeholder:"Git repository URL",value:this.rdf.git_repo,isRequired:!1},{label:"Tags",type:"tags",value:this.rdf.tags,help:"Tags should contain only lower case letters with numbers, or the following characters: +*#;./%@, but no space",placeholder:"Add a tag and press ENTER to confirm (lower case, numbers, or any of +*#;./%@, but no space)",options:this.allTags.map((function(e){return e.toLowerCase().replace(/ /g,"-")})),pattern:/^[-0-9a-z+*#;./%@:]*$/,allow_new:!0,icon:"label",isRequired:!1},{label:"Citation",type:"citation",value:this.rdf.cite,help:"How this resource item should be cited",isRequired:!1},{label:"Source",placeholder:"source",value:this.rdf.source,isRequired:!1,help:"The source url of your deposit (optional)"},{label:"Links",type:"tags",value:this.rdf.links,placeholder:"Add a link (resource item ID)",options:this.resourceItems.map((function(e){return e.id})),allow_new:!0,icon:"vector-link",isRequired:!1},{label:"Files",type:"files",value:t,isRequired:!1},{html:'

ValidationValidate the RDF fields against the bioimageio RDF specification using the python module, see Specifications for BioImage.IO.
Note: It may take a while to load for the first time. *

'},{type:"button",showLabel:!1,label:"Validate",callback:function(){var e=Object(d["a"])(regeneratorRuntime.mark((function e(){var t,i,r,o;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return n.showLoader(!0),e.prev=1,i=P["a"].load(P["a"].dump(n.rdf)),delete i._metadata,(null===i||void 0===i||null===(t=i.config)||void 0===t?void 0:t._deposit)&&delete i.config._deposit,console.log("RDF: ",i),e.next=8,window.api.getPlugin("https://raw.githubusercontent.com/bioimage-io/spec-bioimage-io/main/scripts/bio-rdf-validator.imjoy.html");case 8:return r=e.sent,e.next=11,r.validate(i);case 11:if(o=e.sent,o.error){e.next=16;break}return e.abrupt("return","Validation passed!");case 16:throw new Error(JSON.stringify(o,null," "));case 17:e.next=22;break;case 19:throw e.prev=19,e.t0=e["catch"](1),e.t0;case 22:return e.prev=22,n.showLoader(!1),e.finish(22);case 25:case"end":return e.stop()}}),e,null,[[1,19,22,25]])})));function t(){return e.apply(this,arguments)}return t}()}]),this.files=t},transformFields:function(e){var t={};for(var n in this.components)t[this.components[n].name]=n;var i,r=Object(u["a"])(e);try{for(r.s();!(i=r.n()).done;){var o=i.value;t[o.type]&&(o.is=t[o.type],delete o.type)}}catch(a){r.e(a)}finally{r.f()}return e},formSubmitted:function(e){var t=this;return Object(d["a"])(regeneratorRuntime.mark((function n(){var i,r,o,a,s,c,l,d,_,m,f,h,g,b,y,v;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:for(s in o={type:"Type",name:"Name",description:"Description",version:"Version",license:"License",source:"Source",git_repo:"Git Repository",tags:"Tags",links:"Links",cite:"Citation",authors:"Authors",maintainers:"Maintainers"},a=e.values,o)t.rdf[s]=a[o[s]];if(!t.rdf.name.includes("/")){n.next=6;break}return alert("RDF name should not contain '/'"),n.abrupt("return");case 6:if(!t.zipPackage){n.next=29;break}c=Object.values(t.zipPackage.files),l=Object(u["a"])(a["Files"]),n.prev=9,l.s();case 11:if((d=l.n()).done){n.next=18;break}if(_=d.value,!c.includes(_)){n.next=15;break}return n.abrupt("continue",16);case 15:_ instanceof Blob?t.zipPackage.file(_.name,_):console.error("Invalid file type",_);case 16:n.next=11;break;case 18:n.next=23;break;case 20:n.prev=20,n.t0=n["catch"](9),l.e(n.t0);case 23:return n.prev=23,l.f(),n.finish(23);case 26:for(m=0,f=c;m0)){n.next=47;break}return n.next=47,t.client.getCredential(!0);case 47:t.stepIndex=2;case 48:case"end":return n.stop()}}),n,null,[[9,20,23,26]])})))()},notifyBot:function(){var e=this,t="https://bioimage.netlify.app/.netlify/functions/bioimageiobot?action=notify&source=".concat(this.client.baseURL,"/record/").concat(this.depositId,"/files/rdf.yaml");this.notifyCIStatus="⌛ Trying to notify bioimage-bot for the new item...",this.notifyCIFailed=!1;var n=this.$buefy.loading.open({container:this.$refs.ci_status});fetch(t).then(function(){var t=Object(d["a"])(regeneratorRuntime.mark((function t(n){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(200!==n.status){t.next=8;break}return t.next=3,n.json();case 3:t.t0=t.sent["message"],e.notifyCIStatus="🎉 bioimage-bot has successfully detected the item: "+t.t0,e.notifyCIFailed=!1,t.next=13;break;case 8:return e.notifyCIFailed=!0,t.next=11,n.text();case 11:t.t1=t.sent,e.notifyCIStatus="😬 bioimage-bot failed to detected the new item, please report the issue to the admin team of bioimage.io: "+t.t1;case 13:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}()).catch((function(t){e.notifyCIStatus="😬 Failed to reach to the bioimageio-bot, please report the issue to the admin team of bioimage.io: ".concat(t),e.notifyCIFailed=!0})).finally((function(){n.close()}))},publishDeposition:function(){var e=this;return Object(d["a"])(regeneratorRuntime.mark((function t(){var n,i;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return n=e.$buefy.loading.open({container:e.$el}),t.prev=1,t.next=4,e.client.publish(e.depositId);case 4:i=t.sent,console.log("Published",i),e.publishedDOI=i.doi,e.publishedUrl="".concat(e.$store.state.zenodoBaseURL,"/record/").concat(e.depositId),e.notifyBot(),t.next=15;break;case 11:t.prev=11,t.t0=t["catch"](1),console.error(t.t0),alert("Failed to publish: ".concat(t.t0));case 15:return t.prev=15,n.close(),t.finish(15);case 18:case"end":return t.stop()}}),t,null,[[1,11,15,18]])})))()},exportPackage:function(){var e=this;return Object(d["a"])(regeneratorRuntime.mark((function t(){var n,i,r,o,a,s,c,l;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(n=e.zipPackage,n){t.next=37;break}n=new bt.a,i=0,r=Object(u["a"])(e.editedFiles),t.prev=5,r.s();case 7:if((o=r.n()).done){t.next=29;break}if(a=o.value,e.uploadProgress=i/e.editedFiles.length*100,i++,"remote"!==a.type){t.next=26;break}return e.uploadStatus="Download fille "+a.name,t.next=15,fetch(a.url);case 15:if(s=t.sent,!s.ok){t.next=23;break}return t.next=19,s.blob();case 19:c=t.sent,n.file(a.name,c),t.next=24;break;case 23:throw new Error("Failed to download file: "+a.url);case 24:t.next=27;break;case 26:a instanceof Blob&&n.file(a.name,a);case 27:t.next=7;break;case 29:t.next=34;break;case 31:t.prev=31,t.t0=t["catch"](5),r.e(t.t0);case 34:return t.prev=34,r.f(),t.finish(34);case 37:return console.log("downloading",n),t.next=40,n.generateAsync({type:"blob",compression:"DEFLATE",compressionOptions:{level:9}},(function(t){e.uploadProgress=t.percent,e.uploadStatus="Zipping package..."}));case 40:l=t.sent,e.uploadStatus="Exporting zip package...",Object(mt["saveAs"])(l,e.rdf.name+".bioimage.io.zip"),e.uploadStatus="Done!";case 44:case"end":return t.stop()}}),t,null,[[5,31,34,37]])})))()},showLoader:function(e){e?this.loadingComponent=this.$buefy.loading.open({canCancel:!0}):this.loadingComponent&&(this.loadingComponent.close(),this.loadingComponent=null)},login:function(){var e=this;return Object(d["a"])(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,e.client.getCredential(!0);case 3:e.$forceUpdate(),t.next=9;break;case 6:t.prev=6,t.t0=t["catch"](0),alert("Failed to login: ".concat(t.t0));case 9:case"end":return t.stop()}}),t,null,[[0,6]])})))()},createOrUpdateDeposit:function(e,t){var n=this;return Object(d["a"])(regeneratorRuntime.mark((function i(){var r,o;return regeneratorRuntime.wrap((function(i){while(1)switch(i.prev=i.next){case 0:return i.prev=0,i.next=3,n.client.getCredential(!0);case 3:n.$forceUpdate(),i.next=10;break;case 6:return i.prev=6,i.t0=i["catch"](0),alert("Failed to login: ".concat(i.t0)),i.abrupt("return");case 10:return r=n.$buefy.loading.open({container:n.$el}),i.prev=11,i.delegateYield(regeneratorRuntime.mark((function i(){var r,o,a,s,c,l,u,d,_,m,f,h;return regeneratorRuntime.wrap((function(i){while(1)switch(i.prev=i.next){case 0:if(n.uploadProgress=1,n.uploadMode="new",!e){i.next=29;break}return i.prev=3,i.next=6,n.client.retrieve(e);case 6:if(r=i.sent,t){i.next=16;break}return i.next=10,n.client.createNewVersion(r);case 10:return o=i.sent,a=o.links.latest_draft.split("/"),e=parseInt(a[a.length-1]),i.next=15,n.client.retrieve(e);case 15:r=i.sent;case 16:if("inprogress"===r.state||"unsubmitted"===r.state){i.next=19;break}return i.next=19,n.client.edit(e);case 19:n.uploadMode="update",i.next=27;break;case 22:if(i.prev=22,i.t0=i["catch"](3),console.error(i.t0),confirm("Failed to retrieve existing deposit (id: ".concat(e,"), would you like to create a new deposit instead?"))){i.next=27;break}return i.abrupt("return",{v:void 0});case 27:i.next=32;break;case 29:return i.next=31,n.client.createDeposition();case 31:r=i.sent;case 32:if(n.depositId=r.id,s="".concat(n.client.baseURL,"/record/").concat(n.depositId,"/files/"),c=null,!n.rdf.documentation||n.rdf.documentation.startsWith("http")||!n.rdf.documentation.endsWith(".md")){i.next=42;break}if(l=n.zipPackage.files[n.rdf.documentation.replace("./","")],!l){i.next=42;break}return i.next=40,l.async("string");case 40:c=i.sent,c=en.a.sanitize(Qt()(c));case 42:return n.rdf.config=n.rdf.config||{},n.rdf.config._deposit=r,n.rdf.rdf_source=n.rdf.rdf_source||"rdf.yaml",u=Object(p["g"])(n.rdf,s,c),n.requestedJoinCommunity&&u.communities.push({identifier:n.siteConfig.zenodo_config.community}),u.prereserve_doi=!0,i.next=50,n.client.updateMetadata(r,u);case 50:if(r=i.sent,n.prereserveDOI=r.metadata.prereserve_doi,n.rdf.id=n.prereserveDOI.doi,n.rdf.config._doi=r.metadata.prereserve_doi.doi,n.rdf.config._conceptdoi=r.conceptdoi,!t){i.next=58;break}return n.stepIndex=3,i.abrupt("return",{v:r});case 58:d=Object.values(n.zipPackage.files),n.rdf.covers&&n.rdf.covers.length>0&&(_=n.rdf.covers,d.sort((function(e,t){return _.includes("./"+e.name)&&!_.includes("./"+t.name)?1:!_.includes("./"+e.name)&&_.includes("./"+t.name)?-1:0}))),m=regeneratorRuntime.mark((function e(t){var i,o;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(!d[t].dir){e.next=3;break}return console.warn("Skipping directory: "+d[t].name),e.abrupt("return","continue");case 3:return e.next=5,d[t].async("blob");case 5:return i=e.sent,o=new File([i],d[t].name),e.next=9,n.client.uploadFile(r,o,o.name,(function(e){n.uploadProgress=Math.round(e/o.size*100),n.uploadStatus="Uploading ".concat(t+1,"/").concat(d.length,"(").concat(n.uploadProgress,"%): ").concat(o.name.slice(0,40),"... "),n.$forceUpdate()}));case 9:case"end":return e.stop()}}),e)})),f=0;case 62:if(!(f=0&&e.resourceItems.splice(n,1)},normalizeItems:function(e,t){e.resourceItems=e.resourceItems.map((function(e){return e.id=e.id||Object(p["f"])(),e.nickname=e.nickname||e.id,e.id=e.id.toLowerCase(),e.links=e.links||[],e.tags=e.tags||[],e.links=e.links.map((function(e){return e.toLowerCase()})),e.links=Object(un["a"])(new Set(e.links)),e.tags=e.tags||[],e.tags=e.tags.map((function(e){return e.toLowerCase()})),e.links=Object(un["a"])(new Set(e.links)),t?t(e):e}))},setBioEngineReady:function(e,t){e.bioEngineReady=!!t}}}),wn=(n("f935"),n("1881")),kn=n.n(wn),xn=(n("5363"),n("7bb1")),In=n("4c93"),Cn=n("2593");a["default"].component("ValidationProvider",xn["a"]),Object.keys(In).forEach((function(e){Object(xn["b"])(e,Object(o["a"])(Object(o["a"])({},In[e]),{},{message:Cn["a"][e]}))})),a["default"].use(kn.a),a["default"].use(ln["a"]),a["default"].config.productionTip=!1,new a["default"]({router:cn,render:function(e){return e(E)},store:vn}).$mount("#app")},"5ced":function(e,t,n){},"6a05":function(e,t,n){},7411:function(e,t,n){},"74ab":function(e,t,n){},"85ec":function(e,t,n){},"89db":function(e,t,n){},"8cd4":function(e,t,n){},"944d":function(e,t,n){},"94a4":function(e,t,n){},"94f5":function(e,t,n){"use strict";var i=n("423d"),r=n.n(i);r.a},c1ab:function(e,t,n){"use strict";var i=n("74ab"),r=n.n(i);r.a},c9e7:function(e,t,n){},cbfe:function(e,t,n){"use strict";var i=n("276d"),r=n.n(i);r.a},cccb:function(e,t,n){"use strict";var i=n("5ced"),r=n.n(i);r.a},ccd0:function(e,t,n){},d7c4:function(e,t,n){"use strict";var i=n("89db"),r=n.n(i);r.a},dd68:function(e,t,n){},e067:function(e,t,n){"use strict";var i=n("4871"),r=n.n(i);r.a},e698:function(e,t,n){"use strict";var i=n("94a4"),r=n.n(i);r.a},e6e0:function(e,t,n){"use strict";var i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"markdown-body"},[n("b-loading",{attrs:{"is-full-page":!1,active:e.loading,"can-cancel":!1},on:{"update:active":function(t){e.loading=t}}}),e.docs?n("div",{domProps:{innerHTML:e._s(e.docs)}}):e._e()],1)},r=[],o=(n("a15b"),n("fb6a"),n("d3b7"),n("ac1f"),n("8a79"),n("5319"),n("1276"),n("9911"),n("96cf"),n("1da1")),a=(n("e4cb"),n("2c43"),n("0e54")),s=n.n(a),c=n("c0c4"),l=n.n(c),u=n("1487"),d=n.n(u),p=(n("a4d3"),n("e01a"),n("99af"),n("4160"),n("caad"),n("b0c0"),n("b64b"),n("25f0"),n("2532"),n("2ca0"),n("498a"),n("159b"),n("b85c")),_=n("025e"),m={runButtonText:"Run",editButtonText:"Edit",errorText:"Error",successText:"Done"};function f(e,t,n){return h.apply(this,arguments)}function h(){return h=Object(o["a"])(regeneratorRuntime.mark((function e(t,n,i){var r,a,s,c,l,u,d,p,m=this;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:if("js"===n.lang&&(n.lang="javascript"),"py"===n.lang&&(n.lang="python"),"ijm"===n.lang&&(n.lang="javascript"),r=function(e,t){if(t.type&&!t._parsed){"macro"===t.type&&(t.passive=!1,e="\n async function setup(){\n const source = `".concat(e,'`;\n let ij = await api.getWindow("ImageJ.JS-').concat(t.namespace,'")\n if(!ij){\n ij = await api.createWindow({src:"https://ij.imjoy.io", name:"ImageJ.JS-').concat(t.namespace,'"})\n }\n await ij.runMacro(source)\n }\n api.export({setup}); \n '),t.type="web-worker");var n=Object.assign({},t);n.api_version=n.api_version||"0.1.8",n.name=n.name||t.id&&"Plugin-"+t.id||"Plugin-"+Object(_["f"])(),n.description=n.description||"[TODO: describe this plugin with one sentence.]",n.tags=n.tags||[],n.version=n.version||"0.1.0",n.ui=n.ui||"",n.cover=n.cover||"",n.icon=n.icon||"extension",n.inputs=n.inputs||null,n.outputs=n.outputs||null,n.env=n.env||"",n.permissions=n.permissions||[],n.requirements=n.requirements||[],n.dependencies=n.dependencies||[],"window"===t.type&&(n.defaults={}),t.lang||(n.type.includes("python")?t.lang="python":n.type.includes("javascript")?t.lang="javascript":console.error('"lang" is not specified, please make sure decorate the code block with the name of the language.')),e="html"!==t.lang?'\n'.concat(JSON.stringify(n,null,1),'\n\n