import{c as m,a as i,d as H,s as K,e as L,f as F}from"./BLoZk-4Q.js";import"./DnbEMVOy.js";import{f as u,P as Q,Q as U,R as k,T as f,t as V,K as l,U as j,V as B}from"./CkWh75VR.js";import{I as D,s as E,e as G,a as J,i as O}from"./Bmr4jBBJ.js";import{l as W,s as X,p as n,i as y}from"./BIAtSU2q.js";import{s as M}from"./CjJ88ejz.js";import{M as Y}from"./Dm3B8RZy.js";function nt(_,a){const c=W(a,["children","$$slots","$$events","$$legacy"]);/**
 * @license lucide-svelte v0.469.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const h=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}],["path",{d:"M3 3v5h5"}]];D(_,X({name:"rotate-ccw"},()=>c,{get iconNode(){return h},children:(b,T)=>{var v=m(),d=u(v);E(d,a,"default",{}),i(b,v)},$$slots:{default:!0}}))}var Z=F("<button> </button>"),$=F('<div class="file-tabs-layout svelte-1kr7grw"><nav class="file-tabs-nav svelte-1kr7grw"></nav> <div class="file-tabs-content svelte-1kr7grw"><!></div></div>');function it(_,a){Q(a,!0);let c=n(a,"tabs",19,()=>[]),h=n(a,"activeTab",3,""),b=n(a,"content",3,""),T=n(a,"onSelectTab",3,e=>{}),v=n(a,"chatSlot",3,null),d=n(a,"testsSlot",3,null),g=B(()=>{var e;return h()||((e=c()[0])==null?void 0:e.id)||""});function R(e){T()(e),e==="chat"&&requestAnimationFrame(()=>{const r=document.querySelector(".main");r&&r.scrollTo({top:r.scrollHeight,behavior:"smooth"})})}var w=m(),q=u(w);{var C=e=>{var r=$(),p=k(r);G(p,21,c,O,(t,s)=>{var o=Z();let x;var A=k(o,!0);f(o),V(()=>{x=J(o,1,"tab-item svelte-1kr7grw",null,x,{active:l(g)===l(s).id}),K(A,l(s).label)}),L("click",o,()=>R(l(s).id)),i(t,o)}),f(p);var S=j(p,2),I=k(S);{var N=t=>{var s=m(),o=u(s);M(o,v),i(t,s)},P=t=>{var s=m(),o=u(s);M(o,d),i(t,s)},z=t=>{Y(t,{get content(){return b()}})};y(I,t=>{l(g)==="chat"&&v()?t(N):l(g)==="tests"&&d()?t(P,1):t(z,!1)})}f(S),f(r),i(e,r)};y(q,e=>{c().length>0&&e(C)})}i(_,w),U()}H(["click"]);export{it as F,nt as R};
