import{S as D,i as G,s as H,u as w,v as S,x as B,y as C,z as j,C as T,e as g,m as E,f as K,a as d,b as v,g as h,_ as q,c as z,h as R,j as k,r as A,aa as F,E as I,K as J,H as L,G as M}from"./index.bbdd6a1e.js";import{B as N}from"./Block.aea3d209.js";import{B as O}from"./BlockTitle.5d44bbf1.js";function P(a){let l;return{c(){l=K(a[5])},m(t,n){v(t,l,n)},p(t,n){n&32&&R(l,t[5])},d(t){t&&k(l)}}}function Q(a){let l,t,n,m,c,i,s,f,u,_,o,r;return m=new O({props:{$$slots:{default:[P]},$$scope:{ctx:a}}}),{c(){l=g("div"),t=g("div"),n=g("label"),w(m.$$.fragment),c=E(),i=g("div"),s=K(a[0]),f=E(),u=g("input"),d(n,"for",a[6]),d(i,"class","font-medium"),d(t,"class","flex justify-between"),d(l,"class","w-full flex flex-col"),d(u,"type","range"),d(u,"id",a[6]),d(u,"name","cowbell"),d(u,"class","w-full disabled:cursor-not-allowed"),d(u,"min",a[1]),d(u,"max",a[2]),d(u,"step",a[3]),u.disabled=a[4]},m(e,b){v(e,l,b),h(l,t),h(t,n),S(m,n,null),h(t,c),h(t,i),h(i,s),v(e,f,b),v(e,u,b),q(u,a[0]),_=!0,o||(r=[z(u,"change",a[8]),z(u,"input",a[8])],o=!0)},p(e,b){const y={};b&1056&&(y.$$scope={dirty:b,ctx:e}),m.$set(y),(!_||b&1)&&R(s,e[0]),(!_||b&2)&&d(u,"min",e[1]),(!_||b&4)&&d(u,"max",e[2]),(!_||b&8)&&d(u,"step",e[3]),(!_||b&16)&&(u.disabled=e[4]),b&1&&q(u,e[0])},i(e){_||(B(m.$$.fragment,e),_=!0)},o(e){C(m.$$.fragment,e),_=!1},d(e){e&&k(l),j(m),e&&k(f),e&&k(u),o=!1,A(r)}}}function U(a){let l,t;return l=new N({props:{$$slots:{default:[Q]},$$scope:{ctx:a}}}),{c(){w(l.$$.fragment)},m(n,m){S(l,n,m),t=!0},p(n,[m]){const c={};m&1087&&(c.$$scope={dirty:m,ctx:n}),l.$set(c)},i(n){t||(B(l.$$.fragment,n),t=!0)},o(n){C(l.$$.fragment,n),t=!1},d(n){j(l,n)}}}let V=0;function W(a,l,t){let{value:n=0}=l,{style:m=""}=l,{minimum:c=0}=l,{maximum:i=100}=l,{step:s=1}=l,{disabled:f=!1}=l,{label:u}=l;const _=`range_id_${V++}`,o=T();function r(){n=F(this.value),t(0,n)}return a.$$set=e=>{"value"in e&&t(0,n=e.value),"style"in e&&t(7,m=e.style),"minimum"in e&&t(1,c=e.minimum),"maximum"in e&&t(2,i=e.maximum),"step"in e&&t(3,s=e.step),"disabled"in e&&t(4,f=e.disabled),"label"in e&&t(5,u=e.label)},a.$$.update=()=>{a.$$.dirty&1&&o("change",n)},[n,c,i,s,f,u,_,m,r]}class X extends D{constructor(l){super(),G(this,l,W,U,H,{value:0,style:7,minimum:1,maximum:2,step:3,disabled:4,label:5})}}function Y(a){let l,t,n;function m(i){a[8](i)}let c={label:a[1],style:a[2],minimum:a[3],maximum:a[4],step:a[5],disabled:a[6]==="static"};return a[0]!==void 0&&(c.value=a[0]),l=new X({props:c}),I.push(()=>J(l,"value",m)),l.$on("change",a[9]),{c(){w(l.$$.fragment)},m(i,s){S(l,i,s),n=!0},p(i,[s]){const f={};s&2&&(f.label=i[1]),s&4&&(f.style=i[2]),s&8&&(f.minimum=i[3]),s&16&&(f.maximum=i[4]),s&32&&(f.step=i[5]),s&64&&(f.disabled=i[6]==="static"),!t&&s&1&&(t=!0,f.value=i[0],L(()=>t=!1)),l.$set(f)},i(i){n||(B(l.$$.fragment,i),n=!0)},o(i){C(l.$$.fragment,i),n=!1},d(i){j(l,i)}}}function Z(a,l,t){let{value:n=0}=l,{label:m="Slider"}=l,{default_value:c}=l,{style:i=""}=l,{minimum:s}=l,{maximum:f}=l,{step:u}=l,{mode:_}=l;c&&(n=c);function o(e){n=e,t(0,n)}function r(e){M.call(this,a,e)}return a.$$set=e=>{"value"in e&&t(0,n=e.value),"label"in e&&t(1,m=e.label),"default_value"in e&&t(7,c=e.default_value),"style"in e&&t(2,i=e.style),"minimum"in e&&t(3,s=e.minimum),"maximum"in e&&t(4,f=e.maximum),"step"in e&&t(5,u=e.step),"mode"in e&&t(6,_=e.mode)},[n,m,i,s,f,u,_,c,o,r]}class x extends D{constructor(l){super(),G(this,l,Z,Y,H,{value:0,label:1,default_value:7,style:2,minimum:3,maximum:4,step:5,mode:6})}}var le=x;const te=["static","dynamic"];export{le as Component,te as modes};
