@unidy.io/sdk 1.1.4 → 1.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{auth-NU3DBc-6.js → auth-B83pzi0f.js} +126 -125
- package/dist/cjs/auth-B83pzi0f.js.map +1 -0
- package/dist/cjs/{auth-store-BaxuIp4z.js → auth-store-DPHWWmXf.js} +2 -4
- package/dist/cjs/auth-store-DPHWWmXf.js.map +1 -0
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/{newsletter-helpers-DR0vsegt.js → newsletter-helpers-D-V_8kiN.js} +3 -3
- package/dist/cjs/{newsletter-helpers-DR0vsegt.js.map → newsletter-helpers-D-V_8kiN.js.map} +1 -1
- package/dist/cjs/u-conditional-render.cjs.entry.js +3 -3
- package/dist/cjs/u-config.cjs.entry.js +7 -7
- package/dist/cjs/u-config.entry.cjs.js.map +1 -1
- package/dist/cjs/u-email-field.cjs.entry.js +1 -1
- package/dist/cjs/u-error-message.cjs.entry.js +1 -1
- package/dist/cjs/u-logout-button.cjs.entry.js +4 -4
- package/dist/cjs/u-magic-code-field.cjs.entry.js +3 -3
- package/dist/cjs/u-missing-field.cjs.entry.js +1 -1
- package/dist/cjs/u-missing-fields-submit-button.cjs.entry.js +1 -1
- package/dist/cjs/u-newsletter-checkbox.cjs.entry.js +3 -3
- package/dist/cjs/u-newsletter-logout-button.cjs.entry.js +3 -3
- package/dist/cjs/u-newsletter-preference-checkbox.cjs.entry.js +3 -3
- package/dist/cjs/u-newsletter-resend-doi-button.cjs.entry.js +3 -3
- package/dist/cjs/u-newsletter-root.cjs.entry.js +5 -5
- package/dist/cjs/u-newsletter-toggle-subscription-button.cjs.entry.js +3 -3
- package/dist/cjs/u-passkey.cjs.entry.js +3 -3
- package/dist/cjs/u-password-field.cjs.entry.js +1 -1
- package/dist/cjs/u-password-field.entry.cjs.js.map +1 -1
- package/dist/cjs/u-profile.u-submit-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-profile_2.cjs.entry.js +3 -3
- package/dist/cjs/u-registration-button.cjs.entry.js +1 -1
- package/dist/cjs/u-reset-password-button.cjs.entry.js +3 -3
- package/dist/cjs/u-send-magic-code-button.cjs.entry.js +3 -3
- package/dist/cjs/u-signed-in.cjs.entry.js +1 -1
- package/dist/cjs/u-signin-root.cjs.entry.js +1 -1
- package/dist/cjs/u-signin-step.cjs.entry.js +3 -3
- package/dist/cjs/u-signin-strategy.cjs.entry.js +1 -1
- package/dist/cjs/u-social-login-button.cjs.entry.js +1 -1
- package/dist/cjs/u-spinner.cjs.entry.js +1 -1
- package/dist/cjs/u-spinner.entry.cjs.js.map +1 -1
- package/dist/collection/auth/auth-helpers.js +115 -117
- package/dist/collection/auth/auth-helpers.js.map +1 -1
- package/dist/collection/auth/auth.js +9 -6
- package/dist/collection/auth/auth.js.map +1 -1
- package/dist/collection/auth/components/password-field/password-field.js.map +1 -1
- package/dist/collection/auth/store/auth-store.js +0 -2
- package/dist/collection/auth/store/auth-store.js.map +1 -1
- package/dist/collection/shared/components/config/config.js +6 -6
- package/dist/collection/shared/components/config/config.js.map +1 -1
- package/dist/collection/shared/components/spinner/spinner.css +1 -1
- package/dist/collection/shared/components/submit-button/submit-button.css +1 -1
- package/dist/components/auth-store.js +0 -2
- package/dist/components/auth-store.js.map +1 -1
- package/dist/components/auth.js +124 -123
- package/dist/components/auth.js.map +1 -1
- package/dist/components/spinner.js +1 -1
- package/dist/components/spinner.js.map +1 -1
- package/dist/components/submit-button.js +1 -1
- package/dist/components/submit-button.js.map +1 -1
- package/dist/components/u-config.js +6 -6
- package/dist/components/u-config.js.map +1 -1
- package/dist/components/u-password-field.js.map +1 -1
- package/dist/esm/{auth-nsjRdpvS.js → auth-B0RIcDM-.js} +126 -125
- package/dist/esm/auth-B0RIcDM-.js.map +1 -0
- package/dist/esm/{auth-store-CVvBlKGv.js → auth-store-BGMYm_jK.js} +2 -4
- package/dist/esm/auth-store-BGMYm_jK.js.map +1 -0
- package/dist/esm/index.js +2 -2
- package/dist/esm/{newsletter-helpers-Dc_24im3.js → newsletter-helpers-CONtbKYi.js} +3 -3
- package/dist/esm/{newsletter-helpers-Dc_24im3.js.map → newsletter-helpers-CONtbKYi.js.map} +1 -1
- package/dist/esm/u-conditional-render.entry.js +3 -3
- package/dist/esm/u-config.entry.js +7 -7
- package/dist/esm/u-config.entry.js.map +1 -1
- package/dist/esm/u-email-field.entry.js +1 -1
- package/dist/esm/u-error-message.entry.js +1 -1
- package/dist/esm/u-logout-button.entry.js +4 -4
- package/dist/esm/u-magic-code-field.entry.js +3 -3
- package/dist/esm/u-missing-field.entry.js +1 -1
- package/dist/esm/u-missing-fields-submit-button.entry.js +1 -1
- package/dist/esm/u-newsletter-checkbox.entry.js +3 -3
- package/dist/esm/u-newsletter-logout-button.entry.js +3 -3
- package/dist/esm/u-newsletter-preference-checkbox.entry.js +3 -3
- package/dist/esm/u-newsletter-resend-doi-button.entry.js +3 -3
- package/dist/esm/u-newsletter-root.entry.js +5 -5
- package/dist/esm/u-newsletter-toggle-subscription-button.entry.js +3 -3
- package/dist/esm/u-passkey.entry.js +3 -3
- package/dist/esm/u-password-field.entry.js +1 -1
- package/dist/esm/u-password-field.entry.js.map +1 -1
- package/dist/esm/u-profile.u-submit-button.entry.js.map +1 -1
- package/dist/esm/u-profile_2.entry.js +3 -3
- package/dist/esm/u-registration-button.entry.js +1 -1
- package/dist/esm/u-reset-password-button.entry.js +3 -3
- package/dist/esm/u-send-magic-code-button.entry.js +3 -3
- package/dist/esm/u-signed-in.entry.js +1 -1
- package/dist/esm/u-signin-root.entry.js +1 -1
- package/dist/esm/u-signin-step.entry.js +3 -3
- package/dist/esm/u-signin-strategy.entry.js +1 -1
- package/dist/esm/u-social-login-button.entry.js +1 -1
- package/dist/esm/u-spinner.entry.js +1 -1
- package/dist/esm/u-spinner.entry.js.map +1 -1
- package/dist/sdk/auth-BopPjv7G.js.map +1 -0
- package/dist/sdk/auth-C0vldOq6.js.map +1 -0
- package/dist/sdk/auth-store-DQaam_Qh.js.map +1 -0
- package/dist/sdk/auth-store-sOmplc4z.js.map +1 -0
- package/dist/sdk/component-utils-D1lzXl_Z.js.map +1 -0
- package/dist/sdk/flash-store-Cgu7WoSN.js.map +1 -0
- package/dist/sdk/flash-store-DNcSEn2p.js.map +1 -0
- package/dist/sdk/helpers-BqFCd65h.js.map +1 -0
- package/dist/sdk/helpers-DUHc_Cx7.js.map +1 -0
- package/dist/sdk/i18n-B6rRU-m3.js.map +1 -0
- package/dist/sdk/i18n-CZii1E-s.js.map +1 -0
- package/dist/sdk/index-B1aDcaWd.js.map +1 -0
- package/dist/sdk/index-BnBstyfp.js.map +1 -0
- package/dist/sdk/index-BqL27K_R.js.map +1 -0
- package/dist/sdk/index-C5jZjlU8.js.map +1 -0
- package/dist/sdk/index-Df-7P3r0.js.map +1 -0
- package/dist/sdk/index-Eu7hg2ii.js.map +1 -0
- package/dist/sdk/index-Iulyfmzq.js.map +1 -0
- package/dist/sdk/index-O6h7SI7-.js.map +1 -0
- package/dist/sdk/index.esm.js +1 -1
- package/dist/sdk/newsletter-helpers-8ByV38YW.js.map +1 -0
- package/dist/sdk/newsletter-helpers-B-Md6T9k.js.map +1 -0
- package/dist/sdk/newsletter-store-CqD-GcDC.js.map +1 -0
- package/dist/sdk/newsletter-store-CvULKmsu.js.map +1 -0
- package/dist/sdk/{p-c6816542.entry.js → p-08ff2de2.entry.js} +2 -2
- package/dist/sdk/{p-39b61f33.entry.js → p-1ea49938.entry.js} +2 -2
- package/dist/sdk/{p-bfb04b17.entry.js → p-2a65bcbb.entry.js} +2 -2
- package/dist/sdk/{p-80034205.entry.js → p-2af8b45f.entry.js} +2 -2
- package/dist/sdk/{p-0d324822.entry.js → p-3411c743.entry.js} +2 -2
- package/dist/sdk/{p-4ec3302d.entry.js → p-467c7304.entry.js} +2 -2
- package/dist/sdk/{p-e54d5d38.entry.js → p-56abb377.entry.js} +2 -2
- package/dist/sdk/p-5703102b.entry.js +2 -0
- package/dist/sdk/{p-319c5d3b.entry.js → p-593c6dde.entry.js} +2 -2
- package/dist/sdk/{p-a4f5940f.entry.js → p-5b627aea.entry.js} +2 -2
- package/dist/sdk/{p-9e71a36c.entry.js → p-5cc20a8b.entry.js} +2 -2
- package/dist/sdk/p-628ccd68.entry.js +2 -0
- package/dist/sdk/{p-66587fdd.entry.js → p-675eb13d.entry.js} +2 -2
- package/dist/sdk/{p-312b919e.entry.js → p-6a642433.entry.js} +2 -2
- package/dist/sdk/p-7a0cefff.entry.js +2 -0
- package/dist/sdk/{p-e81bbd62.entry.js.map → p-7a0cefff.entry.js.map} +1 -1
- package/dist/sdk/{p-e2e7061b.entry.js → p-91bb8b59.entry.js} +2 -2
- package/dist/sdk/{p-90e2253e.entry.js → p-9f59909b.entry.js} +2 -2
- package/dist/sdk/p-BlAULXyw.js +2 -0
- package/dist/sdk/p-BlAULXyw.js.map +1 -0
- package/dist/sdk/p-C3fhudPT.js +2 -0
- package/dist/sdk/p-C3fhudPT.js.map +1 -0
- package/dist/sdk/{p-BiILQPdb.js → p-S3-2d2Qd.js} +2 -2
- package/dist/sdk/{p-BiILQPdb.js.map → p-S3-2d2Qd.js.map} +1 -1
- package/dist/sdk/{p-568eabbc.entry.js → p-a4b7ffd8.entry.js} +2 -2
- package/dist/sdk/{p-0fb37ee9.entry.js → p-a5db968f.entry.js} +2 -2
- package/dist/sdk/{p-0ab98e7a.entry.js → p-a6393d19.entry.js} +2 -2
- package/dist/sdk/{p-2cb6a2d0.entry.js → p-c31dbbb4.entry.js} +2 -2
- package/dist/sdk/{p-f232929b.entry.js → p-c5bffd90.entry.js} +2 -2
- package/dist/sdk/{p-f961fbea.entry.js → p-e3611b71.entry.js} +2 -2
- package/dist/sdk/{p-f961fbea.entry.js.map → p-e3611b71.entry.js.map} +1 -1
- package/dist/sdk/p-f0598e42.entry.js +2 -0
- package/dist/sdk/{p-34b98f55.entry.js.map → p-f0598e42.entry.js.map} +1 -1
- package/dist/sdk/{p-a69b83ec.entry.js → p-f369a996.entry.js} +2 -2
- package/dist/sdk/{p-3049e73f.entry.js → p-ffac964c.entry.js} +2 -2
- package/dist/sdk/profile-helpers-BDjk573F.js.map +1 -0
- package/dist/sdk/profile-helpers-b8Koj20a.js.map +1 -0
- package/dist/sdk/profile-store-BZKApsQm.js.map +1 -0
- package/dist/sdk/profile-store-DD6sq42i.js.map +1 -0
- package/dist/sdk/sdk.esm.js +1 -1
- package/dist/sdk/u-config.entry.esm.js.map +1 -1
- package/dist/sdk/u-password-field.entry.esm.js.map +1 -1
- package/dist/sdk/u-password-field.entry.js +104 -0
- package/dist/sdk/u-profile.u-submit-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-reset-password-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-reset-password-button.entry.js +54 -0
- package/dist/sdk/u-spinner.entry.esm.js.map +1 -1
- package/dist/sdk/unidy-store-BwZym11Y.js.map +1 -0
- package/dist/sdk/unidy-store-CtifvCkV.js.map +1 -0
- package/dist/types/auth/auth-helpers.d.ts +5 -7
- package/dist/types/auth/auth.d.ts +1 -1
- package/dist/types/auth/components/reset-pass-button/reset-pass-button.d.ts +1 -0
- package/dist/types/auth/store/auth-store.d.ts +3 -3
- package/dist/types/shared/components/config/config.d.ts +1 -1
- package/package.json +1 -1
- package/dist/cjs/auth-NU3DBc-6.js.map +0 -1
- package/dist/cjs/auth-store-BaxuIp4z.js.map +0 -1
- package/dist/esm/auth-nsjRdpvS.js.map +0 -1
- package/dist/esm/auth-store-CVvBlKGv.js.map +0 -1
- package/dist/sdk/p-34b98f55.entry.js +0 -2
- package/dist/sdk/p-5b40a68b.entry.js +0 -2
- package/dist/sdk/p-88d93d64.entry.js +0 -2
- package/dist/sdk/p-PKvQIsOt.js +0 -2
- package/dist/sdk/p-PKvQIsOt.js.map +0 -1
- package/dist/sdk/p-aMrLKr2m.js +0 -2
- package/dist/sdk/p-aMrLKr2m.js.map +0 -1
- package/dist/sdk/p-e81bbd62.entry.js +0 -2
- /package/dist/sdk/{p-c6816542.entry.js.map → p-08ff2de2.entry.js.map} +0 -0
- /package/dist/sdk/{p-39b61f33.entry.js.map → p-1ea49938.entry.js.map} +0 -0
- /package/dist/sdk/{p-bfb04b17.entry.js.map → p-2a65bcbb.entry.js.map} +0 -0
- /package/dist/sdk/{p-80034205.entry.js.map → p-2af8b45f.entry.js.map} +0 -0
- /package/dist/sdk/{p-0d324822.entry.js.map → p-3411c743.entry.js.map} +0 -0
- /package/dist/sdk/{p-4ec3302d.entry.js.map → p-467c7304.entry.js.map} +0 -0
- /package/dist/sdk/{p-e54d5d38.entry.js.map → p-56abb377.entry.js.map} +0 -0
- /package/dist/sdk/{p-5b40a68b.entry.js.map → p-5703102b.entry.js.map} +0 -0
- /package/dist/sdk/{p-319c5d3b.entry.js.map → p-593c6dde.entry.js.map} +0 -0
- /package/dist/sdk/{p-a4f5940f.entry.js.map → p-5b627aea.entry.js.map} +0 -0
- /package/dist/sdk/{p-9e71a36c.entry.js.map → p-5cc20a8b.entry.js.map} +0 -0
- /package/dist/sdk/{p-88d93d64.entry.js.map → p-628ccd68.entry.js.map} +0 -0
- /package/dist/sdk/{p-66587fdd.entry.js.map → p-675eb13d.entry.js.map} +0 -0
- /package/dist/sdk/{p-312b919e.entry.js.map → p-6a642433.entry.js.map} +0 -0
- /package/dist/sdk/{p-e2e7061b.entry.js.map → p-91bb8b59.entry.js.map} +0 -0
- /package/dist/sdk/{p-90e2253e.entry.js.map → p-9f59909b.entry.js.map} +0 -0
- /package/dist/sdk/{p-568eabbc.entry.js.map → p-a4b7ffd8.entry.js.map} +0 -0
- /package/dist/sdk/{p-0fb37ee9.entry.js.map → p-a5db968f.entry.js.map} +0 -0
- /package/dist/sdk/{p-0ab98e7a.entry.js.map → p-a6393d19.entry.js.map} +0 -0
- /package/dist/sdk/{p-2cb6a2d0.entry.js.map → p-c31dbbb4.entry.js.map} +0 -0
- /package/dist/sdk/{p-f232929b.entry.js.map → p-c5bffd90.entry.js.map} +0 -0
- /package/dist/sdk/{p-a69b83ec.entry.js.map → p-f369a996.entry.js.map} +0 -0
- /package/dist/sdk/{p-3049e73f.entry.js.map → p-ffac964c.entry.js.map} +0 -0
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as t,c as e,d as i,h as o,H as s,g as n}from"./p-Ci3aTmzp.js";import{g as a}from"./p-DdUvQelg.js";import{a as r,b as l,s as u}from"./p-aMrLKr2m.js";import{A as d}from"./p-PKvQIsOt.js";import{t as f}from"./p-CbRhHGU5.js";import{o as c,u as p}from"./p-BlOjABPD.js";import{v as h,b as m}from"./p-DA84OuuU.js";import{s as w,a as g}from"./p-C0feI0p8.js";import{g as b}from"./p-DUHc_Cx7.js";import{n as y}from"./p-CPPYdoIv.js";import{g as v}from"./p-BqFCd65h.js";import{h as x}from"./p-D1lzXl_Z.js";import"./p-BZ1kW_eK.js";import"./p-DYtgart8.js";const k=class{profileId;initialData="";uProfileSuccess;uProfileError;fetchingProfileData=false;constructor(i){t(this,i);this.uProfileSuccess=e(this,"uProfileSuccess");this.uProfileError=e(this,"uProfileError");c("locale",(async t=>{if(r.state.authenticated)await this.getTokenAndFetchProfile()}))}async componentWillLoad(){if(this.initialData!==""){w.data=typeof this.initialData==="string"?JSON.parse(this.initialData):this.initialData}else if(r.state.authenticated){await this.getTokenAndFetchProfile()}w.loading=false}async getTokenAndFetchProfile(){const t=await d.getInstance();const e=await t.getToken();if(e&&typeof e==="string"){await this.fetchProfileData(e)}}async fetchProfileData(t){if(this.fetchingProfileData)return;this.fetchingProfileData=true;try{const e=await a().profile.fetchProfile({idToken:t,lang:p.locale});if(e.success){w.configuration=JSON.parse(JSON.stringify(e.data));w.configUpdateSource="fetch";w.errors={};w.flashErrors={};w.data=JSON.parse(JSON.stringify(e.data))}else{w.flashErrors={[String(e?.status)]:String(e?.error)}}}catch(t){i("Failed to fetch profile data:",t);w.flashErrors={error:f("errors.failed_to_load_profile")}}this.fetchingProfileData=false}async submitProfile(){const t=await d.getInstance();w.loading=true;const{configuration:e,...i}=w;if(!h(i.data)){w.loading=false;return}const o=m(i.data);const s=await a().profile.updateProfile({idToken:await t.getToken(),data:o,lang:p.locale});if(s?.success){w.loading=false;w.configuration=JSON.parse(JSON.stringify(s.data));w.configUpdateSource="submit";w.errors={};this.uProfileSuccess.emit({message:"profile_updated_successfully",payload:s.data})}else{if(s?.data&&"flatErrors"in s.data){w.errors=s.data.flatErrors;this.uProfileError.emit({error:"profile_update_field_errors",details:{fieldErrors:w.errors,httpStatus:s?.status,responseData:s?.data}})}else{w.flashErrors={[String(s?.status)]:String(s?.error)};this.uProfileError.emit({error:"profile_update_failed",details:{flashErrors:w.flashErrors,httpStatus:s?.status,responseData:s?.data}})}w.loading=false}}componentDidLoad(){g("configuration",(t=>{w.data=t}));l("token",(t=>{const e=t??"";if(e){this.fetchProfileData(e)}}))}render(){const t=Object.values(w.errors).some(Boolean);const e=Object.values(w.flashErrors).filter(Boolean).join(", ");const i=w.configUpdateSource==="submit";if(r.state.authenticated){return this.fetchingProfileData?o("div",null,f("loading")):o(s,null,o("slot",null),!t&&e&&o("flash-message",{variant:"error",message:e}),i&&!e&&!t&&o("flash-message",{variant:"success",message:f("profile.updated")}))}return o("h2",null,f("profile.signInToView"))}};const j={handleClick:async(t,e,i)=>{t.preventDefault();await(b(e)?.submit())},isDisabled(t,e){if(e||u.loading)return true;if(u.step==="email"&&t==="email"){return u.email===""}if(u.step==="verification"&&t==="password"){return u.password===""}if(u.step==="reset-password"&&t==="resetPassword"){return!u.resetPassword.newPassword||!u.resetPassword.passwordConfirmation}return false},isLoading(){return u.loading},getButtonText(t,e){if(e)return e;switch(u.step){case"email":return f("buttons.continue");case"verification":if(t==="password"){return f("auth.password.button_text",{defaultValue:"Sign In with Password"})}return f("buttons.submit");case"reset-password":if(t==="resetPassword"){return f("auth.resetPassword.button_text_set",{defaultValue:"Set Password"})}return f("buttons.submit");default:return f("buttons.submit")}},shouldRender(t){if(!u.availableLoginOptions?.password&&t==="password"){return false}if(u.step==="email"){return t==="email"}if(u.step==="verification"){return t==="password"&&u.magicCodeStep!=="sent"}if(u.step==="reset-password"){return t==="resetPassword"}return false}};const S={handleClick:async(t,e,i)=>{t.preventDefault();return await(v(e)?.submit(i))},isDisabled(t,e){if(t==="login"){return e||!y.state.email}return e||!y.state.email||Object.keys(y.state.checkedNewsletters).length===0},isLoading(){return false}};function C(t){return t.closest("u-profile")}const M={async handleClick(t,e,i){t.preventDefault();await(C(e)?.submitProfile())},isDisabled(t,e){return e||w.errors&&Object.keys(w.errors).length>0||w.phoneValid===false},isLoading(){return w.loading}};const I={async handleClick(){},isDisabled(t,e=false){return e||false},isLoading(){return false}};const L='/*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */@layer theme{:host,:root{--u-font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--u-font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--u-default-font-family:var(--u-font-sans);--u-default-mono-font-family:var(--u-font-mono);--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,::backdrop,:after,:before{border:0 solid;box-sizing:border-box;margin:0;padding:0}::file-selector-button{appearance:button;background-color:#0000;border:0 solid;border-radius:0;box-sizing:border-box;color:inherit;font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;margin:0;margin-inline-end:4px;opacity:1;padding:0}:host,html{font-family:var(--u-default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--u-default-font-feature-settings,normal);font-variation-settings:var(--u-default-font-variation-settings,normal);-webkit-text-size-adjust:100%;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);tab-size:4;-webkit-tap-highlight-color:transparent;line-height:1.5}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:var(--u-default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--u-default-mono-font-feature-settings,normal);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-size:1em;font-variation-settings:var(--u-default-mono-font-variation-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal)}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}menu,ol,ul{list-style:none}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}button,input,optgroup,select,textarea{background-color:#0000;border-radius:0;color:inherit;font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;opacity:1}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:currentColor;color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex;padding-block:0}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field,::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-meridiem-field,::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.u\\:flex{display:flex}.u\\:justify-center{justify-content:center}.u\\:disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.u\\:disabled\\:opacity-50:disabled{opacity:.5}.u\\:justify-end{justify-content:flex-end}} /*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */@layer base{}@layer components;@layer utilities{} /*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */@layer base{}@layer components,utilities; /*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */@layer base{}@layer components,utilities; /*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */@layer base{}@layer components,utilities; /*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,::backdrop,:after,:before{--tw-ring-offset-width:0px;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000}}}@layer base{}@layer components;@layer utilities{.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}';const _=class{constructor(e){t(this,e)}get el(){return n(this)}for;text;disabled=false;componentClassName="";context="auth";contextModule=I;hasSlot=false;async componentWillLoad(){this.hasSlot=x(this.el);this.context=this.detectContext();switch(this.context){case"auth":this.contextModule=j;break;case"profile":this.contextModule=M;break;case"newsletter":this.contextModule=S;break;default:this.contextModule=I}}detectContext(){if(this.el.closest("u-signin-root")||this.el.closest("u-signin-step"))return"auth";if(this.el.closest("u-profile"))return"profile";if(this.el.closest("u-newsletter-root"))return"newsletter";throw new Error("No context found for submit button. Make sure you are using the component within a u-signin-root, u-profile, or u-newsletter-root.")}handleClick=async t=>{await this.contextModule.handleClick(t,this.el,this.for)};isDisabled(){return this.contextModule.isDisabled(this.for,this.disabled)}isLoading(){return this.contextModule.isLoading()}getButtonText(){if(this.contextModule.getButtonText){return this.contextModule.getButtonText(this.for,this.text)}if(this.text){return this.text}return f("buttons.submit")}getButtonContent(){const t=this.isLoading();if(t){return o("u-spinner",null)}if(this.hasSlot){return o("slot",null)}return this.getButtonText()}render(){if(this.contextModule.shouldRender&&!this.contextModule.shouldRender(this.for)){return null}const t=[this.componentClassName,this.context==="auth"?"u:flex u:justify-center":"","u:disabled:opacity-50 u:disabled:cursor-not-allowed"].join(" ");const e={type:"submit",part:`${this.context}-submit-button`,disabled:this.isDisabled()||this.isLoading(),class:t,onClick:this.handleClick,"aria-live":"polite"};return o("button",{...e},this.getButtonContent())}};_.style=L;export{k as u_profile,_ as u_submit_button};
|
|
2
|
-
//# sourceMappingURL=p-e81bbd62.entry.js.map
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|