import{S as R,i as U,s as W,y as I,z as C,A as D,g as _,d as b,B as V,k as x,q as A,a as F,l as S,m as E,r as J,h,c as O,n as w,b as L,J as g,v as M,f as Q,a1 as P,ab as j,e as G,a4 as X}from"../chunks/index.8c57c90c.js";import{P as Y}from"../chunks/Page.e3c4f184.js";import{a as Z,S as ee}from"../chunks/signalQueries.0b4f9031.js";import{g as te}from"../chunks/settingsStore.ca891065.js";import{S as se,a as ne}from"../chunks/SelectItem.5cf70406.js";function H(o,t,n){const e=o.slice();return e[5]=t[n],e}function re(o){let t,n;return t=new se({props:{labelText:"Preferred embedding",selected:o[3].embedding,$$slots:{default:[ae]},$$scope:{ctx:o}}}),t.$on("change",o[4]),{c(){I(t.$$.fragment)},l(e){C(t.$$.fragment,e)},m(e,s){D(t,e,s),n=!0},p(e,s){const c={};s&8&&(c.selected=e[3].embedding),s&260&&(c.$$scope={dirty:s,ctx:e}),t.$set(c)},i(e){n||(_(t.$$.fragment,e),n=!0)},o(e){b(t.$$.fragment,e),n=!1},d(e){V(t,e)}}}function le(o){let t,n;return t=new ee({}),{c(){I(t.$$.fragment)},l(e){C(t.$$.fragment,e)},m(e,s){D(t,e,s),n=!0},p:P,i(e){n||(_(t.$$.fragment,e),n=!0)},o(e){b(t.$$.fragment,e),n=!1},d(e){V(t,e)}}}function K(o){let t,n;return t=new ne({props:{value:o[5].name}}),{c(){I(t.$$.fragment)},l(e){C(t.$$.fragment,e)},m(e,s){D(t,e,s),n=!0},p(e,s){const c={};s&4&&(c.value=e[5].name),t.$set(c)},i(e){n||(_(t.$$.fragment,e),n=!0)},o(e){b(t.$$.fragment,e),n=!1},d(e){V(t,e)}}}function ae(o){let t,n,e=o[2].data||[],s=[];for(let r=0;r<e.length;r+=1)s[r]=K(H(o,e,r));const c=r=>b(s[r],1,1,()=>{s[r]=null});return{c(){for(let r=0;r<s.length;r+=1)s[r].c();t=G()},l(r){for(let a=0;a<s.length;a+=1)s[a].l(r);t=G()},m(r,a){for(let l=0;l<s.length;l+=1)s[l]&&s[l].m(r,a);L(r,t,a),n=!0},p(r,a){if(a&4){e=r[2].data||[];let l;for(l=0;l<e.length;l+=1){const d=H(r,e,l);s[l]?(s[l].p(d,a),_(s[l],1)):(s[l]=K(d),s[l].c(),_(s[l],1),s[l].m(t.parentNode,t))}for(M(),l=e.length;l<s.length;l+=1)c(l);Q()}},i(r){if(!n){for(let a=0;a<e.length;a+=1)_(s[a]);n=!0}},o(r){s=s.filter(Boolean);for(let a=0;a<s.length;a+=1)b(s[a]);n=!1},d(r){X(s,r),r&&h(t)}}}function oe(o){let t,n,e,s,c,r,a,l,d,m,f,i,v;const T=[le,re],p=[];function q(u,$){return u[2].isFetching?0:1}return f=q(o),i=p[f]=T[f](o),{c(){t=x("div"),n=x("div"),e=x("section"),s=x("div"),c=A("Settings"),r=F(),a=x("div"),l=A(`Changes will apply to all datasets for your session. These settings are not saved
          server-side.`),d=F(),m=x("div"),i.c(),this.h()},l(u){t=S(u,"DIV",{class:!0});var $=E(t);n=S($,"DIV",{class:!0});var y=E(n);e=S(y,"SECTION",{class:!0});var k=E(e);s=S(k,"DIV",{class:!0});var B=E(s);c=J(B,"Settings"),B.forEach(h),r=O(k),a=S(k,"DIV",{class:!0});var N=E(a);l=J(N,`Changes will apply to all datasets for your session. These settings are not saved
          server-side.`),N.forEach(h),d=O(k),m=S(k,"DIV",{class:!0});var z=E(m);i.l(z),z.forEach(h),k.forEach(h),y.forEach(h),$.forEach(h),this.h()},h(){w(s,"class","text-lg text-gray-700"),w(a,"class","mb-4 text-sm text-gray-500"),w(m,"class","w-60"),w(e,"class","flex flex-col gap-y-1"),w(n,"class","flex flex-col gap-y-6"),w(t,"class","lilac-page flex p-8")},m(u,$){L(u,t,$),g(t,n),g(n,e),g(e,s),g(s,c),g(e,r),g(e,a),g(a,l),g(e,d),g(e,m),p[f].m(m,null),v=!0},p(u,$){let y=f;f=q(u),f===y?p[f].p(u,$):(M(),b(p[y],1,1,()=>{p[y]=null}),Q(),i=p[f],i?i.p(u,$):(i=p[f]=T[f](u),i.c()),_(i,1),i.m(m,null))},i(u){v||(_(i),v=!0)},o(u){b(i),v=!1},d(u){u&&h(t),p[f].d()}}}function ce(o){let t,n;return t=new Y({props:{$$slots:{default:[oe]},$$scope:{ctx:o}}}),{c(){I(t.$$.fragment)},l(e){C(t.$$.fragment,e)},m(e,s){D(t,e,s),n=!0},p(e,[s]){const c={};s&268&&(c.$$scope={dirty:s,ctx:e}),t.$set(c)},i(e){n||(_(t.$$.fragment,e),n=!0)},o(e){b(t.$$.fragment,e),n=!1},d(e){V(t,e)}}}function ie(o,t,n){let e,s,c,r=P,a=()=>(r(),r=j(e,i=>n(2,c=i)),e),l,d=P,m=()=>(d(),d=j(s,i=>n(3,l=i)),s);o.$$.on_destroy.push(()=>r()),o.$$.on_destroy.push(()=>d());function f(i){const v=i.target.value;s.setEmbedding(v)}return a(n(1,e=Z())),m(n(0,s=te())),[s,e,c,l,f]}class _e extends R{constructor(t){super(),U(this,t,ie,ce,W,{})}}export{_e as component};
