import{S as C,i as E,s as N,u as m,v as _,x as d,y as g,z as h,C as j,e as v,m as q,a as b,b as p,g as k,_ as y,c as w,aa as D,j as S,r as z,a0 as G,f as H,h as K,E as T,K as A,H as F,G as B}from"./index.65fb5956.js";import{B as I}from"./Block.3fbf618d.js";import{B as J}from"./BlockTitle.87c2b95a.js";function L(l){let e;return{c(){e=H(l[2])},m(t,a){p(t,e,a)},p(t,a){a&4&&K(e,t[2])},d(t){t&&S(e)}}}function M(l){let e,t,a,s,f,u,r;return t=new J({props:{$$slots:{default:[L]},$$scope:{ctx:l}}}),{c(){e=v("label"),m(t.$$.fragment),a=q(),s=v("input"),b(s,"type","number"),b(s,"class","gr-box gr-input w-full gr-text-input"),s.disabled=l[1],b(e,"class","block")},m(i,c){p(i,e,c),_(t,e,null),k(e,a),k(e,s),y(s,l[0]),f=!0,u||(r=[w(s,"input",l[5]),w(s,"keypress",l[3])],u=!0)},p(i,c){const o={};c&260&&(o.$$scope={dirty:c,ctx:i}),t.$set(o),(!f||c&2)&&(s.disabled=i[1]),c&1&&D(s.value)!==i[0]&&y(s,i[0])},i(i){f||(d(t.$$.fragment,i),f=!0)},o(i){g(t.$$.fragment,i),f=!1},d(i){i&&S(e),h(t),u=!1,z(r)}}}function O(l){let e,t;return e=new I({props:{$$slots:{default:[M]},$$scope:{ctx:l}}}),{c(){m(e.$$.fragment)},m(a,s){_(e,a,s),t=!0},p(a,[s]){const f={};s&263&&(f.$$scope={dirty:s,ctx:a}),e.$set(f)},i(a){t||(d(e.$$.fragment,a),t=!0)},o(a){g(e.$$.fragment,a),t=!1},d(a){h(e,a)}}}function P(l,e,t){let{value:a=0}=e,{disabled:s=!1}=e,{label:f}=e,{style:u=""}=e;const r=j();function i(n){r("change",n)}async function c(n){await G(),n.key==="Enter"&&(n.preventDefault(),r("submit"))}function o(){a=D(this.value),t(0,a)}return l.$$set=n=>{"value"in n&&t(0,a=n.value),"disabled"in n&&t(1,s=n.disabled),"label"in n&&t(2,f=n.label),"style"in n&&t(4,u=n.style)},l.$$.update=()=>{l.$$.dirty&1&&i(a)},[a,s,f,c,u,o]}class Q extends C{constructor(e){super(),E(this,e,P,O,N,{value:0,disabled:1,label:2,style:4})}}function R(l){let e,t,a;function s(u){l[5](u)}let f={label:l[1],style:l[2],disabled:l[3]==="static"};return l[0]!==void 0&&(f.value=l[0]),e=new Q({props:f}),T.push(()=>A(e,"value",s)),e.$on("change",l[6]),e.$on("submit",l[7]),{c(){m(e.$$.fragment)},m(u,r){_(e,u,r),a=!0},p(u,[r]){const i={};r&2&&(i.label=u[1]),r&4&&(i.style=u[2]),r&8&&(i.disabled=u[3]==="static"),!t&&r&1&&(t=!0,i.value=u[0],F(()=>t=!1)),e.$set(i)},i(u){a||(d(e.$$.fragment,u),a=!0)},o(u){g(e.$$.fragment,u),a=!1},d(u){h(e,u)}}}function U(l,e,t){let{label:a}=e,{value:s=0}=e,{default_value:f}=e,{style:u=""}=e,{mode:r}=e;f&&(s=f);function i(n){s=n,t(0,s)}function c(n){B.call(this,l,n)}function o(n){B.call(this,l,n)}return l.$$set=n=>{"label"in n&&t(1,a=n.label),"value"in n&&t(0,s=n.value),"default_value"in n&&t(4,f=n.default_value),"style"in n&&t(2,u=n.style),"mode"in n&&t(3,r=n.mode)},[s,a,u,r,f,i,c,o]}class V extends C{constructor(e){super(),E(this,e,U,R,N,{label:1,value:0,default_value:4,style:2,mode:3})}}var Z=V;const x=["static","dynamic"];export{Z as Component,x as modes};
