Anvil/assets/LoginForm-35cfa227.js

2 lines
5.2 KiB
JavaScript
Raw Normal View History

2024-02-28 21:15:05 +01:00
import{a as ge,n as he,c as Ee}from"./utils-09ff0c0e.js";import{a as u,s as k,t as I,b as f,f as _,k as C,g as B,d as v,m as se,n as ne,h as i,i as ie,j as t,l as F}from"./lifecycle-9898a056.js";import{S as ke,i as Ce}from"./index-d94d5794.js";import{$ as Pe}from"./runtime-ea3b2d3b.js";function be(s){let e,o=s[2](s[1].validation.missing)+"",p;return{c(){e=u("p"),p=I(o),this.h()},l(l){e=f(l,"P",{class:!0});var r=_(e);p=B(r,o),r.forEach(v),this.h()},h(){i(e,"class","error")},m(l,r){ie(l,e,r),t(e,p)},p(l,r){r&6&&o!==(o=l[2](l[1].validation.missing)+"")&&F(p,o)},d(l){l&&v(e)}}}function ye(s){let e,o=s[2](s[1].validation.incorrect)+"",p;return{c(){e=u("p"),p=I(o),this.h()},l(l){e=f(l,"P",{class:!0});var r=_(e);p=B(r,o),r.forEach(v),this.h()},h(){i(e,"class","error")},m(l,r){ie(l,e,r),t(e,p)},p(l,r){r&6&&o!==(o=l[2](l[1].validation.incorrect)+"")&&F(p,o)},d(l){l&&v(e)}}}function Le(s){var fe,pe;let e,o,p,l,r,P=s[2](s[1].fields.server.label)+"",m,Z,h,b,re="fig.fr33domlover.site",y,oe="grape.fr33domlover.site",g,ue="walnut.fr33domlover.site",$,L,U,V=s[2](s[1].fields.account.label)+"",G,x,E,q,ee,T,D,K=s[2](s[1].fields.passphrase.label)+"",H,te,N,J,le,j,O,M=s[2](s[1].reset)+"",Q,ae,w,R=s[2](s[1].submit)+"",W,c=((fe=s[0])==null?void 0:fe.missing)&&be(s),d=((pe=s[0])==null?void 0:pe.incorrect)&&ye(s);return{c(){e=u("form"),c&&c.c(),o=k(),d&&d.c(),p=k(),l=u("label"),r=u("span"),m=I(P),Z=k(),h=u("select"),b=u("option"),b.textContent=re,y=u("option"),y.textContent=oe,g=u("option"),g.textContent=ue,$=k(),L=u("label"),U=u("span"),G=I(V),x=k(),E=u("input"),ee=k(),T=u("label"),D=u("span"),H=I(K),te=k(),N=u("input"),le=k(),j=u("div"),O=u("a"),Q=I(M),ae=k(),w=u("button"),W=I(R),this.h()},l(a){e=f(a,"FORM",{class:!0,name:!0,method:!0,action:!0});var n=_(e);c&&c.l(n),o=C(n),d&&d.l(n),p=C(n),l=f(n,"LABEL",{class:!0});var A=_(l);r=f(A,"SPAN",{});var z=_(r);m=B(z,P),z.forEach(v),Z=C(A),h=f(A,"SELECT",{class:!0,name:!0});var S=_(h);b=f(S,"OPTION",{"data-svelte-h":!0}),se(b)!=="svelte-hiv3vu"&&(b.textContent=re),y=f(S,"OPTION",{"data-svelte-h":!0}),se(y)!=="svelte-6kp6u8"&&(y.textContent=oe),g=f(S,"OPTION",{"data-svelte-h":!0}),se(g)!=="svelte-1c26wth"&&(g.textContent=ue),S.forEach(v),A.forEach(v),$=C(n),L=f(n,"LABEL",{class:!0});var X=_(L);U=f(X,"SPAN",{});var ce=_(U);G=B(ce,V),ce.forEach(v),x=C(X),E=f(X,"INPUT",{class:!0,name:!0,type:!0}),X.forEach(v),ee=C(n),T=f(n,"LABEL",{class:!0});var Y=_(T);D=f(Y,"SPAN",{});var de=_(D);H=B(de,K),de.forEach(v),te=C(Y),N=f(Y,"INPUT",{class:!0,name:!0,type:!0,placeholder:!0}),Y.forEach(v),le=C(n),j=f(n,"DIV",{class:!0});var ve=_(j);O=f(ve,"A",{href:!0,class:!0});var me=_(O);Q=B(me,M),me.forEach(v),ve.forEach(v),ae=C(n),w=f(n,"BUTTON",{type:!0,class:!0});var _e=_(w);W=B(_e,R),_e.forEach(v),n.forEach(v),this.h()},h(){var a;b.__value="1",ne(b,b.__value),y.__value="2",ne(y,y.__value),g.__value="3",ne(g,g.__value),i(h,"class","select"),i(h,"name","server"),i(l,"class","label"),i(E,"class","input"),i(E,"name","account"),i(E,"type","text"),E.value=q=((a=s[0])==null?void 0:a.account)??"",i(L,"class","label"),i(N,"class","input"),i(N,"name","passphrase"),i(N,"type","password"),i(N,"placeholder",J=s[2](s[1].fields.passphrase.placeholder)),i(T,"class","label"),i(O,"href","/"),i(O,"class","btn btn-bg-initial"),i(j,"class","text-right"),i(w,"type","submit"),i(w,"class","w-full btn variant-filled-primary"),i(e,"class","space-y-4"),i(e,"name","login"),i(e,"method","POST"),i(e,"action","?/login")},m(a,n){ie(a,e,n),c&&c.m(e,null),t(e,o),d&&d.m(e,null),t(e,p),t(e,l),t(l,r),t(r,m),t(l,Z),t(l,h),t(h,b),t(h,y),t(h,g),t(e,$),t(e,L),t(L,U),t(U,G),t(L,x),t(L,E),t(e,ee),t(e,T),t(T,D),t(D,H),t(T,te),t(T,N),t(e,le),t(e,j),t(j,O),t(O,Q),t(e,ae),t(e,w),t(w,W)},p(a,[n]){var A,z,S;(A=a[0])!=null&&A.missing?c?c.p(a,n):(c=be(a),c.c(),c.m(e,o)):c&&(c.d(1),c=null),(z=a[0])!=null&&z.incorrect?d?d.p(a,n):(d=ye(a),d.c(),d.m(e,p)):d&&(d.d(1),d=null),n&6&&P!==(P=a[2](a[1].fields.server.label)+"")&&F(m,P),n&6&&V!==(V=a[2](a[1].fields.account.label)+"")&&F(G,V),n&1&&q!==(q=((S=a[0])==null?void 0:S.account)??"")&&E.value!==q&&(E.value=q),n&6&&K!==(K=a[