import{p as r,e as F,s as J,a as H,b as K,f as L,q as k,m as Q,r as X}from"./i18n-eTakDDhg.js";import{R as M,a4 as Z,ay as ee,aa as te,a1 as S,G as a,w as u,a2 as se,a6 as N,S as O,a as T,t as ae,z as re,T as P,a3 as q,U as l,V as le,ad as ie,W as ne,x as C,M as oe,Y as de}from"./index-BkylzejB.js";import{G as ce}from"./utils.svelte-DZ62NrTu.js";import{T as _e}from"./Walkthrough.svelte_svelte_type_style_lang-CisfhIGd.js";import{B as me}from"./Index.svelte_svelte_type_style_lang-Cn03ZAkL.js";import"./clone-IGppQJ7B.js";import"./event-modifiers-CdEA5IGF.js";import"./index-C-r_2iGV.js";import"./StreamingBar.svelte_svelte_type_style_lang-CFNH9sqm.js";import"./html-DvOIMrhY.js";import"./ScrollFade.svelte_svelte_type_style_lang-De9nUaYy.js";import"./snippet-CC9u6I34.js";import"./index-B_pwUImq.js";import"./Clear-Daql2pLY.js";var ue=ne('<div role="tabpanel"><!></div>');function pe(y,t){M(t,!1);const v=()=>k(R,"$selected_tab_index",d),s=()=>k(E,"$selected_tab",d),[d,w]=Q(),c=q();let i=r(t,"elem_id",12,""),f=r(t,"elem_classes",28,()=>[]),o=r(t,"label",12),_=r(t,"id",28,()=>({})),p=r(t,"visible",12),b=r(t,"interactive",12),g=r(t,"order",12),n=r(t,"scale",12),h=r(t,"component_id",12);const z=Z(),{register_tab:A,unregister_tab:D,selected_tab:E,selected_tab_index:R}=ee(_e);let x=q();function U(e,$){return e=JSON.parse(e),A(e,$)}te(()=>()=>D({label:o(),id:_(),elem_id:i()},g())),S(()=>(a(o()),a(_()),a(i()),a(p()),a(b()),a(n()),a(h())),()=>{C(c,JSON.stringify({label:o(),id:_(),elem_id:i(),visible:p(),interactive:b(),scale:n(),component_id:h()}))}),S(()=>(u(c),a(g())),()=>{C(x,U(u(c),g()))}),S(()=>(v(),u(x),a(o())),()=>{v()===u(x)&&oe().then(()=>z("select",{value:o(),index:u(x)}))}),se();var V={get elem_id(){return i()},set elem_id(e){i(e),l()},get elem_classes(){return f()},set elem_classes(e){f(e),l()},get label(){return o()},set label(e){o(e),l()},get id(){return _()},set id(e){_(e),l()},get visible(){return p()},set visible(e){p(e),l()},get interactive(){return b()},set interactive(e){b(e),l()},get order(){return g()},set order(e){g(e),l()},get scale(){return n()},set scale(e){n(e),l()},get component_id(){return h()},set component_id(e){h(e),l()}};F();var m=ue();let B,G;var W=le(m);{let e=ie(()=>n()>=1?n():null);me(W,{get scale(){return u(e)},children:($,ge)=>{var I=N(),j=O(I);J(j,t,"default",{}),T($,I)},$$slots:{default:!0}})}de(m),ae(e=>{H(m,"id",i()),B=K(m,1,`tabitem ${e??""}`,"svelte-dmtrd3",B,{"grow-children":n()>=1}),G=L(m,"",G,{display:s()===_()&&p()!==!1?"flex":"none","flex-grow":n()})},[()=>(a(f()),re(()=>f().join(" ")))]),T(y,m);var Y=P(V);return w(),Y}function qe(y,t){M(t,!0);let v=X(t,["$$slots","$$events","$$legacy"]);const s=new ce(v);pe(y,{get elem_id(){return s.shared.elem_id},get elem_classes(){return s.shared.elem_classes},get label(){return s.shared.label},get visible(){return s.shared.visible},get interactive(){return s.shared.interactive},get id(){return s.props.id},get order(){return s.props.order},get scale(){return s.props.scale},get component_id(){return s.props.component_id},$$events:{select:({detail:d})=>s.dispatch("select",d)},children:(d,w)=>{var c=N(),i=O(c);J(i,t,"default",{}),T(d,c)},$$slots:{default:!0}}),P()}export{pe as BaseTabItem,qe as default};
