PageSourceSearch

https://kevinwang676-neucosvc-colab.hf.space/assets/index-1a48e3a0.js

js kevinwang676-neucosvc-colab.hf.space collected 2026-10-03 10:19:17 UTC 7,138 bytes, 2 lines download raw bytes

1import{S as te,e as se,s as ae,k as S,o as z,z as I,v as A,x as C,B as ie,E as oe,ad as ue,O as L,N as E,K as d,p as b,q as fe,r as _e,u as re,y as me,A as v,G as j,m as ce,T as D,U as M,M as G,n as V,V as y,P as he,L as F,Q as q,R as ge,a1 as de}from"./index-0b47fbf5.js";import{B as be}from"./Button-3c1b6276.js";import{B as ve}from"./BlockLabel-5615836a.js";import{E as ke}from"./Empty-b6d8e654.js";import{I as p}from"./Image-2067cf3a.js";import{n as H}from"./ModifyUpload.svelte_svelte_type_style_lang-d2acacf0.js";function J(n,e,t){const l=n.slice();return l[27]=e[t][0],l[12]=e[t][1],l[29]=t,l}function W(n,e,t){const l=n.slice();return l[30]=e[t][0],l[12]=e[t][1],l[29]=t,l}function we(n){let e,t,l,s,i,a,r=j(n[13]?n[13][1]:[]),m=[];for(let u=0;u<r.length;u+=1)m[u]=X(W(n,r,u));let c=n[4]&&n[13]&&Y(n);return{c(){e=E("div"),t=E("img"),s=L();for(let u=0;u<m.length;u+=1)m[u].c();i=L(),c&&c.c(),a=ce(),d(t,"class","base-image svelte-m3v3vb"),D(t.src,l=n[13]?n[13][0].data:null)||d(t,"src",l),M(t,"fit-height",n[5]),d(e,"class","image-container svelte-m3v3vb")},m(u,h){b(u,e,h),G(e,t),G(e,s);for(let _=0;_<m.length;_+=1)m[_]&&m[_].m(e,null);b(u,i,h),c&&c.m(u,h),b(u,a,h)},p(u,h){if(h[0]&8192&&!D(t.src,l=u[13]?u[13][0].data:null)&&d(t,"src",l),h[0]&32&&M(t,"fit-height",u[5]),h[0]&24704){r=j(u[13]?u[13][1]:[]);let _;for(_=0;_<r.length;_+=1){const k=W(u,r,_);m[_]?m[_].p(k,h):(m[_]=X(k),m[_].c(),m[_].m(e,null))}for(;_<m.length;_+=1)m[_].d(1);m.length=r.length}u[4]&&u[13]?c?c.p(u,h):(c=Y(u),c.c(),c.m(a.parentNode,a)):c&&(c.d(1),c=null)},i:V,o:V,d(u){u&&(v(e),v(i),v(a)),y(m,u),c&&c.d(u)}}}function Ie(n){let e,t;return e=new ke({props:{size:"large",unpadded_box:!0,$$slots:{default:[Ae]},$$scope:{ctx:n}}}),{c(){S(e.$$.fragment)},m(l,s){z(e,l,s),t=!0},p(l,s){const i={};s[1]&2&&(i.$$scope={dirty:s,ctx:l}),e.$set(i)},i(l){t||(I(e.$$.fragment,l),t=!0)},o(l){A(e.$$.fragment,l),t=!1},d(l){C(e,l)}}}function X(n){let e,t,l;return{c(){e=E("img"),d(e,"class","mask fit-height svelte-m3v3vb"),D(e.src,t=n[30].data)||d(e,"src",t),d(e,"style",l=n[7]&&n[12]in n[7]?null:`filter: hue-rotate(${Math.round(n[29]*360/n[13][1].length)}deg);`),M(e,"active",n[14]==n[12]),M(e,"inactive",n[14]!=n[12]&&n[14]!=null)},m(s,i){b(s,e,i)},p(s,i){i[0]&8192&&!D(e.src,t=s[30].data)&&d(e,"src",t),i[0]&8320&&l!==(l=s[7]&&s[12]in s[7]?null:`filter: hue-rotate(${Math.round(s[29]*360/s[13][1].length)}deg);`)&&d(e,"style",l),i[0]&24576&&M(e,"active",s[14]==s[12]),i[0]&24576&&M(e,"inactive",s[14]!=s[12]&&s[14]!=null)},d(s){s&&v(e)}}}function Y(n){let e,t=j(n[13][1]),l=[];for(let s=0;s<t.length;s+=1)l[s]=Z(J(n,t,s));return{c(){e=E("div");for(let s=0;s<l.length;s+=1)l[s].c();d(e,"class","legend svelte-m3v3vb")},m(s,i){b(s,e,i);for(let a=0;a<l.length;a+=1)l[a]&&l[a].m(e,null)},p(s,i){if(i[0]&237696){t=j(s[13][1]);let a;for(a=0;a<t.length;a+=1){const r=J(s,t,a);l[a]?l[a].p(r,i):(l[a]=Z(r),l[a].c(),l[a].m(e,null))}for(;a<l.length;a+=1)l[a].d(1);l.length=t.length}},d(s){s&&v(e),y(l,s)}}}function Z(n){let e,t=n[12]+"",l,s,i,a;function r(){return n[22](n[12])}function m(){return n[23](n[12])}function c(){return n[26](n[29],n[12])}return{c(){e=E("div"),l=he(t),s=L(),d(e,"class","legend-item svelte-m3v3vb"),F(e,"background-color",n[7]&&n[12]in n[7]?n[7][n[12]]+"88":`hsla(${Math.round(n[29]*360/n[13][1].length)}, 100%, 50%, 0.3)`)},m(u,h){b(u,e,h),G(e,l),G(e,s),i||(a=[q(e,"mouseover",r),q(e,"focus",m),q(e,"mouseout",n[24]),q(e,"blur",n[25]),q(e,"click",c)],i=!0)},p(u,h){n=u,h[0]&8192&&t!==(t=n[12]+"")&&ge(l,t),h[0]&8320&&F(e,"background-color",n[7]&&n[12]in n[7]?n[7][n[12]]+"88":`hsla(${Math.round(n[29]*360/n[13][1].length)}, 100%, 50%, 0.3)`)},d(u){u&&v(e),i=!1,de(a)}}}function Ae(n){let e,t;return e=new p({}),{c(){S(e.$$.fragment)},m(l,s){z(e,l,s),t=!0},i(l){t||(I(e.$$.fragment,l),t=!0)},o(l){A(e.$$.fragment,l),t=!1},d(l){C(e,l)}}}function Be(n){let e,t,l,s,i,a,r,m;const c=[n[11]];let u={};for(let f=0;f<c.length;f+=1)u=oe(u,c[f]);e=new ue({props:u}),l=new ve({props:{show_label:n[3],Icon:p,label:n[12]||"Image"}});const h=[Ie,we],_=[];function k(f,g){return f[13]==null?0:1}return a=k(n),r=_[a]=h[a](n),{c(){S(e.$$.fragment),t=L(),S(l.$$.fragment),s=L(),i=E("div"),r.c(),d(i,"class","container svelte-m3v3vb")},m(f,g){z(e,f,g),b(f,t,g),z(l,f,g),b(f,s,g),b(f,i,g),_[a].m(i,null),m=!0},p(f,g){const N=g[0]&2048?fe(c,[_e(f[11])]):{};e.$set(N);const B={};g[0]&8&&(B.show_label=f[3]),g[0]&4096&&(B.label=f[12]||"Image"),l.$set(B);let w=a;a=k(f),a===w?_[a].p(f,g):(re(),A(_[w],1,1,()=>{_[w]=null}),me(),r=_[a],r?r.p(f,g):(r=_[a]=h[a](f),r.c()),I(r,1),r.m(i,null))},i(f){m||(I(e.$$.fragment,f),I(l.$$.fragment,f),I(r),m=!0)},o(f){A(e.$$.fragment,f),A(l.$$.fragment,f),A(r),m=!1}
1,d(f){f&&(v(t),v(s),v(i)),C(e,f),C(l,f),_[a].d()}}}function Me(n){let e,t;return e=new be({props:{visible:n[2],elem_id:n[0],elem_classes:n[1],padding:!1,height:n[5],width:n[6],allow_overflow:!1,container:n[8],scale:n[9],min_width:n[10],$$slots:{default:[Be]},$$scope:{ctx:n}}}),{c(){S(e.$$.fragment)},m(l,s){z(e,l,s),t=!0},p(l,s){const i={};s[0]&4&&(i.visible=l[2]),s[0]&1&&(i.elem_id=l[0]),s[0]&2&&(i.elem_classes=l[1]),s[0]&32&&(i.height=l[5]),s[0]&64&&(i.width=l[6]),s[0]&256&&(i.container=l[8]),s[0]&512&&(i.scale=l[9]),s[0]&1024&&(i.min_width=l[10]),s[0]&30904|s[1]&2&&(i.$$scope={dirty:s,ctx:l}),e.$set(i)},i(l){t||(I(e.$$.fragment,l),t=!0)},o(l){A(e.$$.fragment,l),t=!1},d(l){C(e,l)}}}function Ee(n,e,t){let{elem_id:l=""}=e,{elem_classes:s=[]}=e,{visible:i=!0}=e,{value:a}=e,r,m,{label:c="Annotated Image"}=e,{show_label:u=!0}=e,{show_legend:h=!0}=e,{height:_}=e,{width:k}=e,{color_map:f}=e,{container:g=!1}=e,{scale:N=null}=e,{min_width:B=void 0}=e,{root:w}=e,{root_url:T}=e,K=null,{loading_status:U}=e;const O=ie();function P(o){t(14,K=o)}function Q(){t(14,K=null)}const x=o=>P(o),$=o=>P(o),ee=()=>Q(),le=()=>Q(),ne=(o,R)=>O("select",{index:o,value:R});return n.$$set=o=>{"elem_id"in o&&t(0,l=o.elem_id),"elem_classes"in o&&t(1,s=o.elem_classes),"visible"in o&&t(2,i=o.visible),"value"in o&&t(18,a=o.value),"label"in o&&t(12,c=o.label),"show_label"in o&&t(3,u=o.show_label),"show_legend"in o&&t(4,h=o.show_legend),"height"in o&&t(5,_=o.height),"width"in o&&t(6,k=o.width),"color_map"in o&&t(7,f=o.color_map),"container"in o&&t(8,g=o.container),"scale"in o&&t(9,N=o.scale),"min_width"in o&&t(10,B=o.min_width),"root"in o&&t(19,w=o.root),"root_url"in o&&t(20,T=o.root_url),"loading_status"in o&&t(11,U=o.loading_status)},n.$$.update=()=>{n.$$.dirty[0]&3932160&&(a!==r&&(t(21,r=a),O("change")),a?t(13,m=[H(a[0],w,T),a[1].map(([o,R])=>[H(o,w,T),R])]):t(13,m=null))},[l,s,i,u,h,_,k,f,g,N,B,U,c,m,K,O,P,Q,a,w,T,r,x,$,ee,le,ne]}class qe extends te{constructor(e){super(),se(this,e,Ee,Me,ae,{elem_id:0,elem_classes:1,visible:2,value:18,label:12,show_label:3,show_legend:4,height:5,width:6,color_map:7,container:8,scale:9,min_width:10,root:19,root_url:20,loading_status:11},null,[-1,-1])}}const je=qe,De=["static"],Ge=n=>({type:{payload:"[string, Array<[string, string]>]"},description:{payload:"path to base image, followed by a list of tuples [mask image path, label]"}});export{je as Component,Ge as document,De as modes};
2//# sourceMappingURL=index-1a48e3a0.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.