@unidy.io/sdk 1.2.0-alpha9 → 1.2.0
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/_commonjsHelpers-CFO10eej.js +10 -0
- package/dist/cjs/_commonjsHelpers-CFO10eej.js.map +1 -0
- package/dist/cjs/app-globals-C-Wl5lPS.js +10 -0
- package/dist/cjs/app-globals-C-Wl5lPS.js.map +1 -0
- package/dist/cjs/{auth-store-DPmGKHZ2.js → auth-store-0vv3uOib.js} +4 -4
- package/dist/cjs/{auth-store-DPmGKHZ2.js.map → auth-store-0vv3uOib.js.map} +1 -1
- package/dist/cjs/component-DLxnZCW6.js +34 -0
- package/dist/cjs/component-DLxnZCW6.js.map +1 -0
- package/dist/cjs/component-utils-XXctnOM9.js +38 -0
- package/dist/cjs/component-utils-XXctnOM9.js.map +1 -0
- package/dist/cjs/de-BWF6Glzg.js +704 -0
- package/dist/cjs/de-BWF6Glzg.js.map +1 -0
- package/dist/cjs/en-GB-DhD5mdQw.js +119 -0
- package/dist/cjs/en-GB-DhD5mdQw.js.map +1 -0
- package/dist/cjs/{flash-store-gbSYhPAV.js → flash-store-CR6Umh1O.js} +3 -3
- package/dist/cjs/{flash-store-gbSYhPAV.js.map → flash-store-CR6Umh1O.js.map} +1 -1
- package/dist/cjs/fr-j2wwoj-A.js +577 -0
- package/dist/cjs/fr-j2wwoj-A.js.map +1 -0
- package/dist/cjs/has-slot-content-CfJbU4t-.js +37 -0
- package/dist/cjs/has-slot-content-CfJbU4t-.js.map +1 -0
- package/dist/cjs/{i18n-D5j_Zl-4.js → i18n-ClWrNmGh.js} +100 -4
- package/dist/cjs/{i18n-D5j_Zl-4.js.map → i18n-ClWrNmGh.js.map} +1 -1
- package/dist/cjs/{index-B325yXfO.js → index-2Fz3r5o0.js} +5 -41
- package/dist/cjs/index-2Fz3r5o0.js.map +1 -0
- package/dist/cjs/{index-yaeiYlfa.js → index-C6ZBKFYr.js} +3 -3
- package/dist/cjs/{index-yaeiYlfa.js.map → index-C6ZBKFYr.js.map} +1 -1
- package/dist/cjs/{index-BzPYBLYC.js → index-CpPKy1CZ.js} +1170 -1087
- package/dist/cjs/index-CpPKy1CZ.js.map +1 -0
- package/dist/cjs/index.cjs.js +24 -11
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/cjs/loader.cjs.js +3 -3
- package/dist/cjs/{newsletter-helpers-hdDC5X-V.js → newsletter-helpers-BHvOI8M4.js} +46 -9
- package/dist/cjs/newsletter-helpers-BHvOI8M4.js.map +1 -0
- package/dist/cjs/{newsletter-store-CupsLgO9.js → newsletter-store-22Jswiqe.js} +5 -3
- package/dist/cjs/newsletter-store-22Jswiqe.js.map +1 -0
- package/dist/cjs/nl-BE-yKvOp1-G.js +542 -0
- package/dist/cjs/nl-BE-yKvOp1-G.js.map +1 -0
- package/dist/cjs/{profile-helpers-Bprrm-Xl.js → profile-helpers-BBpAqHjK.js} +4 -4
- package/dist/cjs/{profile-helpers-Bprrm-Xl.js.map → profile-helpers-BBpAqHjK.js.map} +1 -1
- package/dist/cjs/{profile-store-C_q-TuA_.js → profile-store-CQEQhPQD.js} +4 -4
- package/dist/cjs/{profile-store-C_q-TuA_.js.map → profile-store-CQEQhPQD.js.map} +1 -1
- package/dist/cjs/redirect-with-token-wupYX97S.js +37 -0
- package/dist/cjs/redirect-with-token-wupYX97S.js.map +1 -0
- package/dist/cjs/ro-CXq9d1lv.js +578 -0
- package/dist/cjs/ro-CXq9d1lv.js.map +1 -0
- package/dist/cjs/sdk.cjs.js +3 -3
- package/dist/cjs/sv-CMln4V33.js +597 -0
- package/dist/cjs/sv-CMln4V33.js.map +1 -0
- package/dist/cjs/u-conditional-render.cjs.entry.js +14 -14
- package/dist/cjs/u-conditional-render.entry.cjs.js.map +1 -1
- package/dist/cjs/u-config.cjs.entry.js +24 -11
- package/dist/cjs/u-config.entry.cjs.js.map +1 -1
- package/dist/cjs/u-email-field.cjs.entry.js +7 -7
- package/dist/cjs/u-error-message.cjs.entry.js +49 -22
- package/dist/cjs/u-error-message.entry.cjs.js.map +1 -1
- package/dist/cjs/u-field.u-raw-field.entry.cjs.js.map +1 -1
- package/dist/cjs/u-field_2.cjs.entry.js +124 -12
- package/dist/cjs/u-flash-message.cjs.entry.js +3 -3
- package/dist/cjs/u-full-profile.cjs.entry.js +6 -6
- package/dist/cjs/u-jump-to-service.cjs.entry.js +23 -44
- package/dist/cjs/u-jump-to-service.entry.cjs.js.map +1 -1
- package/dist/cjs/u-jump-to-unidy.cjs.entry.js +22 -43
- package/dist/cjs/u-jump-to-unidy.entry.cjs.js.map +1 -1
- package/dist/cjs/u-logout-button.u-signed-in.entry.cjs.js.map +1 -1
- package/dist/cjs/u-logout-button_2.cjs.entry.js +15 -22
- package/dist/cjs/u-magic-code-field.cjs.entry.js +8 -9
- package/dist/cjs/u-magic-code-field.entry.cjs.js.map +1 -1
- package/dist/cjs/u-missing-field.cjs.entry.js +6 -5
- package/dist/cjs/u-missing-field.entry.cjs.js.map +1 -1
- package/dist/cjs/u-missing-fields-submit-button.cjs.entry.js +16 -14
- package/dist/cjs/u-missing-fields-submit-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-newsletter-checkbox.cjs.entry.js +11 -12
- package/dist/cjs/u-newsletter-checkbox.entry.cjs.js.map +1 -1
- package/dist/cjs/u-newsletter-consent-checkbox.cjs.entry.js +4 -4
- package/dist/cjs/u-newsletter-logout-button.cjs.entry.js +15 -20
- package/dist/cjs/u-newsletter-logout-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-newsletter-preference-checkbox.cjs.entry.js +11 -12
- package/dist/cjs/u-newsletter-preference-checkbox.entry.cjs.js.map +1 -1
- package/dist/cjs/u-newsletter-resend-doi-button.cjs.entry.js +10 -11
- package/dist/cjs/u-newsletter-resend-doi-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-newsletter-root.cjs.entry.js +45 -22
- package/dist/cjs/u-newsletter-root.entry.cjs.js.map +1 -1
- package/dist/cjs/u-newsletter-toggle-subscription-button.cjs.entry.js +11 -12
- package/dist/cjs/u-newsletter-toggle-subscription-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-pagination-button.cjs.entry.js +4 -4
- package/dist/cjs/u-pagination-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-pagination-page.cjs.entry.js +4 -4
- package/dist/cjs/u-pagination-page.entry.cjs.js.map +1 -1
- package/dist/cjs/u-passkey.cjs.entry.js +8 -9
- package/dist/cjs/u-passkey.entry.cjs.js.map +1 -1
- package/dist/cjs/u-password-field.cjs.entry.js +5 -5
- package/dist/cjs/u-profile.u-submit-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-profile_2.cjs.entry.js +31 -33
- package/dist/cjs/u-registration-button.cjs.entry.js +5 -5
- package/dist/cjs/u-reset-password-button.cjs.entry.js +12 -15
- package/dist/cjs/u-reset-password-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-send-magic-code-button.cjs.entry.js +8 -9
- package/dist/cjs/u-send-magic-code-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-signin-root.cjs.entry.js +6 -8
- package/dist/cjs/u-signin-root.entry.cjs.js.map +1 -1
- package/dist/cjs/u-signin-step.cjs.entry.js +17 -21
- package/dist/cjs/u-signin-step.entry.cjs.js.map +1 -1
- package/dist/cjs/u-social-login-button.cjs.entry.js +16 -15
- package/dist/cjs/u-social-login-button.entry.cjs.js.map +1 -1
- package/dist/cjs/u-spinner.cjs.entry.js +3 -3
- package/dist/cjs/u-spinner.entry.cjs.js.map +1 -1
- package/dist/cjs/u-ticketable-export.cjs.entry.js +76 -0
- package/dist/cjs/u-ticketable-export.entry.cjs.js.map +1 -0
- package/dist/cjs/u-ticketable-list-D3M8iA-g.js +3991 -0
- package/dist/cjs/u-ticketable-list-D3M8iA-g.js.map +1 -0
- package/dist/cjs/u-ticketable-list.cjs.entry.js +11 -6118
- package/dist/cjs/u-ticketable-list.entry.cjs.js.map +1 -1
- package/dist/cjs/{unidy-store-BGnWn9pc.js → unidy-store-Bvnl24i9.js} +3 -3
- package/dist/cjs/{unidy-store-BGnWn9pc.js.map → unidy-store-Bvnl24i9.js.map} +1 -1
- package/dist/collection/api/base-service.js.map +1 -1
- package/dist/collection/api/client.js.map +1 -1
- package/dist/collection/api/index.js +6 -6
- package/dist/collection/api/index.js.map +1 -1
- package/dist/collection/api/standalone.js +88 -39
- package/dist/collection/api/standalone.js.map +1 -1
- package/dist/collection/auth/api/auth.js.map +1 -1
- package/dist/collection/auth/api/schemas.js +5 -5
- package/dist/collection/auth/api/schemas.js.map +1 -1
- package/dist/collection/auth/auth-helpers.js +7 -8
- package/dist/collection/auth/auth-helpers.js.map +1 -1
- package/dist/collection/auth/auth.js +1 -0
- package/dist/collection/auth/auth.js.map +1 -1
- package/dist/collection/auth/components/jump-to-service/jump-to-service.js +20 -40
- package/dist/collection/auth/components/jump-to-service/jump-to-service.js.map +1 -1
- package/dist/collection/auth/components/jump-to-unidy/jump-to-unidy.js +20 -39
- package/dist/collection/auth/components/jump-to-unidy/jump-to-unidy.js.map +1 -1
- package/dist/collection/auth/components/logout-button/logout-button.js +7 -11
- package/dist/collection/auth/components/logout-button/logout-button.js.map +1 -1
- package/dist/collection/auth/components/missing-field/missing-field.js +25 -1
- package/dist/collection/auth/components/missing-field/missing-field.js.map +1 -1
- package/dist/collection/auth/components/missing-fields-submit-button/missing-fields-submit-button.js +33 -7
- package/dist/collection/auth/components/missing-fields-submit-button/missing-fields-submit-button.js.map +1 -1
- package/dist/collection/auth/components/password-field/password-field.js +1 -1
- package/dist/collection/auth/components/reset-pass-button/reset-pass-button.js +6 -8
- package/dist/collection/auth/components/reset-pass-button/reset-pass-button.js.map +1 -1
- package/dist/collection/auth/components/signed-in/signed-in.js +2 -5
- package/dist/collection/auth/components/signed-in/signed-in.js.map +1 -1
- package/dist/collection/auth/components/signin-root/signin-root.js +2 -5
- package/dist/collection/auth/components/signin-root/signin-root.js.map +1 -1
- package/dist/collection/auth/components/signin-step/signin-step.js +9 -13
- package/dist/collection/auth/components/signin-step/signin-step.js.map +1 -1
- package/dist/collection/auth/components/social-logins/social-login-button.css +1 -1
- package/dist/collection/auth/components/social-logins/social-login-button.js +11 -12
- package/dist/collection/auth/components/social-logins/social-login-button.js.map +1 -1
- package/dist/collection/auth/components/submit-button/auth-submit-button.js +10 -0
- package/dist/collection/auth/components/submit-button/auth-submit-button.js.map +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/locales/de.json +16 -0
- package/dist/collection/locales/en.json +16 -0
- package/dist/collection/locales/fr.json +16 -0
- package/dist/collection/locales/it.json +16 -0
- package/dist/collection/locales/nl_be.json +16 -0
- package/dist/collection/locales/ro.json +16 -0
- package/dist/collection/logger.js +0 -37
- package/dist/collection/logger.js.map +1 -1
- package/dist/collection/newsletter/api/newsletters.js +19 -18
- package/dist/collection/newsletter/api/newsletters.js.map +1 -1
- package/dist/collection/newsletter/components/consent-checkbox/consent-checkbox.js +1 -1
- package/dist/collection/newsletter/components/logout-button/logout-button.js +6 -10
- package/dist/collection/newsletter/components/logout-button/logout-button.js.map +1 -1
- package/dist/collection/newsletter/components/newsletter-checkbox/newsletter-checkbox.js +1 -1
- package/dist/collection/newsletter/components/newsletter-root/newsletter-root.js +65 -10
- package/dist/collection/newsletter/components/newsletter-root/newsletter-root.js.map +1 -1
- package/dist/collection/newsletter/components/preference-checkbox/preference-checkbox.js +1 -1
- package/dist/collection/newsletter/components/toggle-subscription-button/toggle-subscription-button.js +1 -1
- package/dist/collection/newsletter/newsletter-helpers.js +39 -2
- package/dist/collection/newsletter/newsletter-helpers.js.map +1 -1
- package/dist/collection/newsletter/store/newsletter-store.js +2 -0
- package/dist/collection/newsletter/store/newsletter-store.js.map +1 -1
- package/dist/collection/profile/api/profile.js.map +1 -1
- package/dist/collection/profile/api/schemas.js +1 -1
- package/dist/collection/profile/api/schemas.js.map +1 -1
- package/dist/collection/profile/components/field/field.js +3 -1
- package/dist/collection/profile/components/field/field.js.map +1 -1
- package/dist/collection/profile/components/full-profile/full-profile.js +1 -1
- package/dist/collection/profile/components/raw-field/raw-field.js +40 -7
- package/dist/collection/profile/components/raw-field/raw-field.js.map +1 -1
- package/dist/collection/profile/store/profile-store.js +1 -1
- package/dist/collection/profile/store/profile-store.js.map +1 -1
- package/dist/collection/shared/base/component.js +28 -0
- package/dist/collection/shared/base/component.js.map +1 -0
- package/dist/collection/shared/base/has-slot-content.js +31 -0
- package/dist/collection/shared/base/has-slot-content.js.map +1 -0
- package/dist/collection/shared/component-utils.js +23 -27
- package/dist/collection/shared/component-utils.js.map +1 -1
- package/dist/collection/shared/components/conditional-render/conditional-render.js +4 -5
- package/dist/collection/shared/components/conditional-render/conditional-render.js.map +1 -1
- package/dist/collection/shared/components/config/config.js +18 -5
- package/dist/collection/shared/components/config/config.js.map +1 -1
- package/dist/collection/shared/components/email-field/email-field.js +1 -1
- package/dist/collection/shared/components/error-message/error-message.css +1 -1
- package/dist/collection/shared/components/error-message/error-message.js +44 -17
- package/dist/collection/shared/components/error-message/error-message.js.map +1 -1
- package/dist/collection/shared/components/spinner/spinner.css +1 -1
- package/dist/collection/shared/components/spinner/spinner.js +1 -1
- package/dist/collection/shared/components/submit-button/submit-button.css +1 -1
- package/dist/collection/shared/components/submit-button/submit-button.js +12 -23
- package/dist/collection/shared/components/submit-button/submit-button.js.map +1 -1
- package/dist/collection/shared/context-utils.js +96 -0
- package/dist/collection/shared/context-utils.js.map +1 -0
- package/dist/collection/shared/utils/redirect-with-token.js +30 -0
- package/dist/collection/shared/utils/redirect-with-token.js.map +1 -0
- package/dist/collection/shared/utils/url-utils.js +25 -0
- package/dist/collection/shared/utils/url-utils.js.map +1 -0
- package/dist/collection/ticketable/api/schemas.js +10 -2
- package/dist/collection/ticketable/api/schemas.js.map +1 -1
- package/dist/collection/ticketable/api/subscriptions.js +22 -1
- package/dist/collection/ticketable/api/subscriptions.js.map +1 -1
- package/dist/collection/ticketable/api/tickets.js +22 -1
- package/dist/collection/ticketable/api/tickets.js.map +1 -1
- package/dist/collection/ticketable/components/pagination/pagination-button.js +3 -5
- package/dist/collection/ticketable/components/pagination/pagination-button.js.map +1 -1
- package/dist/collection/ticketable/components/pagination/pagination-page.js +3 -5
- package/dist/collection/ticketable/components/pagination/pagination-page.js.map +1 -1
- package/dist/collection/ticketable/components/ticketable-export/ticketable-export.js +175 -0
- package/dist/collection/ticketable/components/ticketable-export/ticketable-export.js.map +1 -0
- package/dist/collection/ticketable/components/ticketable-list/ticketable-list.js +163 -25
- package/dist/collection/ticketable/components/ticketable-list/ticketable-list.js.map +1 -1
- package/dist/collection/ticketable/index.js +1 -0
- package/dist/collection/ticketable/index.js.map +1 -1
- package/dist/components/_commonjsHelpers.js +8 -0
- package/dist/components/_commonjsHelpers.js.map +1 -0
- package/dist/components/component-utils.js +25 -28
- package/dist/components/component-utils.js.map +1 -1
- package/dist/components/component.js +33 -0
- package/dist/components/component.js.map +1 -0
- package/dist/components/de.js +702 -0
- package/dist/components/de.js.map +1 -0
- package/dist/components/en-GB.js +117 -0
- package/dist/components/en-GB.js.map +1 -0
- package/dist/components/field.js +3 -1
- package/dist/components/field.js.map +1 -1
- package/dist/components/fr.js +575 -0
- package/dist/components/fr.js.map +1 -0
- package/dist/components/has-slot-content.js +35 -0
- package/dist/components/has-slot-content.js.map +1 -0
- package/dist/components/i18n.js +96 -0
- package/dist/components/i18n.js.map +1 -1
- package/dist/components/index.js +11 -3
- package/dist/components/index.js.map +1 -1
- package/dist/components/index2.js +1158 -1083
- package/dist/components/index2.js.map +1 -1
- package/dist/components/logger.js +1 -39
- package/dist/components/logger.js.map +1 -1
- package/dist/components/newsletter-helpers.js +39 -2
- package/dist/components/newsletter-helpers.js.map +1 -1
- package/dist/components/newsletter-store.js +2 -0
- package/dist/components/newsletter-store.js.map +1 -1
- package/dist/components/nl-BE.js +540 -0
- package/dist/components/nl-BE.js.map +1 -0
- package/dist/components/profile-store.js +1 -1
- package/dist/components/profile-store.js.map +1 -1
- package/dist/components/raw-field.js +116 -7
- package/dist/components/raw-field.js.map +1 -1
- package/dist/components/redirect-with-token.js +35 -0
- package/dist/components/redirect-with-token.js.map +1 -0
- package/dist/components/ro.js +576 -0
- package/dist/components/ro.js.map +1 -0
- package/dist/components/spinner.js +2 -2
- package/dist/components/spinner.js.map +1 -1
- package/dist/components/submit-button.js +21 -24
- package/dist/components/submit-button.js.map +1 -1
- package/dist/components/sv.js +595 -0
- package/dist/components/sv.js.map +1 -0
- package/dist/components/u-conditional-render.js +5 -6
- package/dist/components/u-conditional-render.js.map +1 -1
- package/dist/components/u-config.js +16 -3
- package/dist/components/u-config.js.map +1 -1
- package/dist/components/u-email-field.js +1 -1
- package/dist/components/u-error-message.js +44 -19
- package/dist/components/u-error-message.js.map +1 -1
- package/dist/components/u-full-profile.js +1 -1
- package/dist/components/u-jump-to-service.js +16 -38
- package/dist/components/u-jump-to-service.js.map +1 -1
- package/dist/components/u-jump-to-unidy.js +16 -37
- package/dist/components/u-jump-to-unidy.js.map +1 -1
- package/dist/components/u-logout-button.js +5 -11
- package/dist/components/u-logout-button.js.map +1 -1
- package/dist/components/u-missing-field.js +5 -2
- package/dist/components/u-missing-field.js.map +1 -1
- package/dist/components/u-missing-fields-submit-button.js +10 -8
- package/dist/components/u-missing-fields-submit-button.js.map +1 -1
- package/dist/components/u-newsletter-checkbox.js +1 -1
- package/dist/components/u-newsletter-consent-checkbox.js +1 -1
- package/dist/components/u-newsletter-logout-button.js +6 -12
- package/dist/components/u-newsletter-logout-button.js.map +1 -1
- package/dist/components/u-newsletter-preference-checkbox.js +1 -1
- package/dist/components/u-newsletter-root.js +35 -12
- package/dist/components/u-newsletter-root.js.map +1 -1
- package/dist/components/u-newsletter-toggle-subscription-button.js +1 -1
- package/dist/components/u-pagination-button.js +3 -4
- package/dist/components/u-pagination-button.js.map +1 -1
- package/dist/components/u-pagination-page.js +3 -4
- package/dist/components/u-pagination-page.js.map +1 -1
- package/dist/components/u-reset-password-button.js +4 -8
- package/dist/components/u-reset-password-button.js.map +1 -1
- package/dist/components/u-signed-in.js +3 -6
- package/dist/components/u-signed-in.js.map +1 -1
- package/dist/components/u-signin-root.js +3 -6
- package/dist/components/u-signin-root.js.map +1 -1
- package/dist/components/u-signin-step.js +10 -14
- package/dist/components/u-signin-step.js.map +1 -1
- package/dist/components/u-social-login-button.js +13 -14
- package/dist/components/u-social-login-button.js.map +1 -1
- package/dist/components/u-ticketable-export.d.ts +11 -0
- package/dist/components/u-ticketable-export.js +93 -0
- package/dist/components/u-ticketable-export.js.map +1 -0
- package/dist/components/u-ticketable-list.js +256 -2396
- package/dist/components/u-ticketable-list.js.map +1 -1
- package/dist/esm/_commonjsHelpers-B85MJLTf.js +8 -0
- package/dist/esm/_commonjsHelpers-B85MJLTf.js.map +1 -0
- package/dist/esm/app-globals-J743qnJf.js +8 -0
- package/dist/esm/app-globals-J743qnJf.js.map +1 -0
- package/dist/esm/{auth-store-DBlGNGhq.js → auth-store-CSpEdi46.js} +4 -4
- package/dist/esm/{auth-store-DBlGNGhq.js.map → auth-store-CSpEdi46.js.map} +1 -1
- package/dist/esm/component-qfegGRWr.js +32 -0
- package/dist/esm/component-qfegGRWr.js.map +1 -0
- package/dist/esm/component-utils-WEof9bTg.js +36 -0
- package/dist/esm/component-utils-WEof9bTg.js.map +1 -0
- package/dist/esm/de-C6AnCqsA.js +702 -0
- package/dist/esm/de-C6AnCqsA.js.map +1 -0
- package/dist/esm/en-GB-DO63WPxt.js +117 -0
- package/dist/esm/en-GB-DO63WPxt.js.map +1 -0
- package/dist/esm/{flash-store-Df2YkLTB.js → flash-store-Dn1Bava8.js} +3 -3
- package/dist/esm/{flash-store-Df2YkLTB.js.map → flash-store-Dn1Bava8.js.map} +1 -1
- package/dist/esm/fr-C0oU6-EJ.js +575 -0
- package/dist/esm/fr-C0oU6-EJ.js.map +1 -0
- package/dist/esm/has-slot-content-DSMkJu9G.js +35 -0
- package/dist/esm/has-slot-content-DSMkJu9G.js.map +1 -0
- package/dist/esm/{i18n-Da7S9Oqf.js → i18n-ioyZxWsT.js} +100 -4
- package/dist/esm/{i18n-Da7S9Oqf.js.map → i18n-ioyZxWsT.js.map} +1 -1
- package/dist/esm/{index-FTKB5a1d.js → index-BsJDptgj.js} +4 -40
- package/dist/esm/index-BsJDptgj.js.map +1 -0
- package/dist/esm/{index-BnAYOYR5.js → index-C8kmD3tu.js} +3 -3
- package/dist/esm/{index-BnAYOYR5.js.map → index-C8kmD3tu.js.map} +1 -1
- package/dist/esm/{index-BVlbCQEX.js → index-kgGjfc-n.js} +1163 -1088
- package/dist/esm/index-kgGjfc-n.js.map +1 -0
- package/dist/esm/index.js +18 -12
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/loader.js +4 -4
- package/dist/esm/{newsletter-helpers-fCpxzovf.js → newsletter-helpers-DoKGN_Kq.js} +46 -9
- package/dist/esm/newsletter-helpers-DoKGN_Kq.js.map +1 -0
- package/dist/esm/{newsletter-store-BB618FgS.js → newsletter-store-DpR85vaC.js} +5 -3
- package/dist/esm/newsletter-store-DpR85vaC.js.map +1 -0
- package/dist/esm/nl-BE-C8uPYb_H.js +540 -0
- package/dist/esm/nl-BE-C8uPYb_H.js.map +1 -0
- package/dist/esm/{profile-helpers-CXK2X6Ts.js → profile-helpers-BMJy0ei_.js} +4 -4
- package/dist/esm/{profile-helpers-CXK2X6Ts.js.map → profile-helpers-BMJy0ei_.js.map} +1 -1
- package/dist/esm/{profile-store-CHlSKuTY.js → profile-store-7wBS3gBH.js} +4 -4
- package/dist/esm/{profile-store-CHlSKuTY.js.map → profile-store-7wBS3gBH.js.map} +1 -1
- package/dist/esm/redirect-with-token-StCLJlSp.js +35 -0
- package/dist/esm/redirect-with-token-StCLJlSp.js.map +1 -0
- package/dist/esm/ro-BlDHz7d-.js +576 -0
- package/dist/esm/ro-BlDHz7d-.js.map +1 -0
- package/dist/esm/sdk.js +4 -4
- package/dist/esm/sv-B_Gq29K0.js +595 -0
- package/dist/esm/sv-B_Gq29K0.js.map +1 -0
- package/dist/esm/u-conditional-render.entry.js +14 -14
- package/dist/esm/u-conditional-render.entry.js.map +1 -1
- package/dist/esm/u-config.entry.js +24 -11
- package/dist/esm/u-config.entry.js.map +1 -1
- package/dist/esm/u-email-field.entry.js +7 -7
- package/dist/esm/u-error-message.entry.js +49 -22
- package/dist/esm/u-error-message.entry.js.map +1 -1
- package/dist/esm/u-field.u-raw-field.entry.js.map +1 -1
- package/dist/esm/u-field_2.entry.js +124 -12
- package/dist/esm/u-flash-message.entry.js +3 -3
- package/dist/esm/u-full-profile.entry.js +6 -6
- package/dist/esm/u-jump-to-service.entry.js +23 -44
- package/dist/esm/u-jump-to-service.entry.js.map +1 -1
- package/dist/esm/u-jump-to-unidy.entry.js +22 -43
- package/dist/esm/u-jump-to-unidy.entry.js.map +1 -1
- package/dist/esm/u-logout-button.u-signed-in.entry.js.map +1 -1
- package/dist/esm/u-logout-button_2.entry.js +15 -22
- package/dist/esm/u-magic-code-field.entry.js +8 -9
- package/dist/esm/u-magic-code-field.entry.js.map +1 -1
- package/dist/esm/u-missing-field.entry.js +6 -5
- package/dist/esm/u-missing-field.entry.js.map +1 -1
- package/dist/esm/u-missing-fields-submit-button.entry.js +16 -14
- package/dist/esm/u-missing-fields-submit-button.entry.js.map +1 -1
- package/dist/esm/u-newsletter-checkbox.entry.js +11 -12
- package/dist/esm/u-newsletter-checkbox.entry.js.map +1 -1
- package/dist/esm/u-newsletter-consent-checkbox.entry.js +4 -4
- package/dist/esm/u-newsletter-logout-button.entry.js +15 -20
- package/dist/esm/u-newsletter-logout-button.entry.js.map +1 -1
- package/dist/esm/u-newsletter-preference-checkbox.entry.js +11 -12
- package/dist/esm/u-newsletter-preference-checkbox.entry.js.map +1 -1
- package/dist/esm/u-newsletter-resend-doi-button.entry.js +10 -11
- package/dist/esm/u-newsletter-resend-doi-button.entry.js.map +1 -1
- package/dist/esm/u-newsletter-root.entry.js +42 -19
- package/dist/esm/u-newsletter-root.entry.js.map +1 -1
- package/dist/esm/u-newsletter-toggle-subscription-button.entry.js +11 -12
- package/dist/esm/u-newsletter-toggle-subscription-button.entry.js.map +1 -1
- package/dist/esm/u-pagination-button.entry.js +4 -4
- package/dist/esm/u-pagination-button.entry.js.map +1 -1
- package/dist/esm/u-pagination-page.entry.js +4 -4
- package/dist/esm/u-pagination-page.entry.js.map +1 -1
- package/dist/esm/u-passkey.entry.js +8 -9
- package/dist/esm/u-passkey.entry.js.map +1 -1
- package/dist/esm/u-password-field.entry.js +5 -5
- package/dist/esm/u-profile.u-submit-button.entry.js.map +1 -1
- package/dist/esm/u-profile_2.entry.js +31 -33
- package/dist/esm/u-registration-button.entry.js +5 -5
- package/dist/esm/u-reset-password-button.entry.js +12 -15
- package/dist/esm/u-reset-password-button.entry.js.map +1 -1
- package/dist/esm/u-send-magic-code-button.entry.js +8 -9
- package/dist/esm/u-send-magic-code-button.entry.js.map +1 -1
- package/dist/esm/u-signin-root.entry.js +6 -8
- package/dist/esm/u-signin-root.entry.js.map +1 -1
- package/dist/esm/u-signin-step.entry.js +17 -21
- package/dist/esm/u-signin-step.entry.js.map +1 -1
- package/dist/esm/u-social-login-button.entry.js +16 -15
- package/dist/esm/u-social-login-button.entry.js.map +1 -1
- package/dist/esm/u-spinner.entry.js +3 -3
- package/dist/esm/u-spinner.entry.js.map +1 -1
- package/dist/esm/u-ticketable-export.entry.js +74 -0
- package/dist/esm/u-ticketable-export.entry.js.map +1 -0
- package/dist/esm/u-ticketable-list-D2p21JjR.js +3981 -0
- package/dist/esm/u-ticketable-list-D2p21JjR.js.map +1 -0
- package/dist/esm/u-ticketable-list.entry.js +10 -6121
- package/dist/esm/u-ticketable-list.entry.js.map +1 -1
- package/dist/esm/{unidy-store-Bg7IaIMd.js → unidy-store-B5Bf4Vit.js} +3 -3
- package/dist/esm/{unidy-store-Bg7IaIMd.js.map → unidy-store-B5Bf4Vit.js.map} +1 -1
- package/dist/sdk/index.esm.js +1 -1
- package/dist/sdk/index.esm.js.map +1 -1
- package/dist/sdk/locales/de.json +16 -0
- package/dist/sdk/locales/en.json +16 -0
- package/dist/sdk/locales/fr.json +16 -0
- package/dist/sdk/locales/it.json +16 -0
- package/dist/sdk/locales/nl_be.json +16 -0
- package/dist/sdk/locales/ro.json +16 -0
- package/dist/sdk/p-02dce5da.entry.js +2 -0
- package/dist/sdk/p-02dce5da.entry.js.map +1 -0
- package/dist/sdk/p-043c7643.entry.js +2 -0
- package/dist/sdk/p-043c7643.entry.js.map +1 -0
- package/dist/sdk/p-18c17747.entry.js +2 -0
- package/dist/sdk/p-18c17747.entry.js.map +1 -0
- package/dist/sdk/p-1a1c1af0.entry.js +2 -0
- package/dist/sdk/p-1a1c1af0.entry.js.map +1 -0
- package/dist/sdk/p-271781c7.entry.js +2 -0
- package/dist/sdk/{p-1a8973a6.entry.js.map → p-271781c7.entry.js.map} +1 -1
- package/dist/sdk/p-29473a55.entry.js +2 -0
- package/dist/sdk/p-29473a55.entry.js.map +1 -0
- package/dist/sdk/p-2a25d62e.entry.js +2 -0
- package/dist/sdk/p-2a25d62e.entry.js.map +1 -0
- package/dist/sdk/{p-C8lRzJEX.js → p-2bKltz_F.js} +2 -2
- package/dist/sdk/{p-C8lRzJEX.js.map → p-2bKltz_F.js.map} +1 -1
- package/dist/sdk/p-2cc3a00d.entry.js +2 -0
- package/dist/sdk/p-2cc3a00d.entry.js.map +1 -0
- package/dist/sdk/p-2f49e0cb.entry.js +2 -0
- package/dist/sdk/p-2f49e0cb.entry.js.map +1 -0
- package/dist/sdk/p-34f5d201.entry.js +2 -0
- package/dist/sdk/p-34f5d201.entry.js.map +1 -0
- package/dist/sdk/p-52c4bdd9.entry.js +2 -0
- package/dist/sdk/p-52c4bdd9.entry.js.map +1 -0
- package/dist/sdk/p-585a0efa.entry.js +2 -0
- package/dist/sdk/p-585a0efa.entry.js.map +1 -0
- package/dist/sdk/p-60675019.entry.js +2 -0
- package/dist/sdk/p-60675019.entry.js.map +1 -0
- package/dist/sdk/p-79ef9a70.entry.js +2 -0
- package/dist/sdk/p-79ef9a70.entry.js.map +1 -0
- package/dist/sdk/p-7d88e21c.entry.js +2 -0
- package/dist/sdk/p-7d88e21c.entry.js.map +1 -0
- package/dist/sdk/p-7eaf3468.entry.js +2 -0
- package/dist/sdk/p-7eaf3468.entry.js.map +1 -0
- package/dist/sdk/{p-88beb872.entry.js → p-8412762c.entry.js} +2 -2
- package/dist/sdk/p-8ea70c08.entry.js +2 -0
- package/dist/sdk/p-8ea70c08.entry.js.map +1 -0
- package/dist/sdk/p-946cdb0a.entry.js +2 -0
- package/dist/sdk/p-946cdb0a.entry.js.map +1 -0
- package/dist/sdk/p-94bb0217.entry.js +2 -0
- package/dist/sdk/p-94bb0217.entry.js.map +1 -0
- package/dist/sdk/{p-bcca06f1.entry.js → p-96860b09.entry.js} +2 -2
- package/dist/sdk/p-B1A6Nu24.js +2 -0
- package/dist/sdk/p-B1A6Nu24.js.map +1 -0
- package/dist/sdk/p-B85MJLTf.js +2 -0
- package/dist/sdk/p-B85MJLTf.js.map +1 -0
- package/dist/sdk/p-B8N6Bwsa.js +2 -0
- package/dist/sdk/{p-DCG3L43i.js.map → p-B8N6Bwsa.js.map} +1 -1
- package/dist/sdk/p-Ba5szISo.js +2 -0
- package/dist/sdk/p-Ba5szISo.js.map +1 -0
- package/dist/sdk/p-BsJDptgj.js +14 -0
- package/dist/sdk/p-BsJDptgj.js.map +1 -0
- package/dist/sdk/{p-bpXpOZY_.js → p-C0Mo15qt.js} +2 -2
- package/dist/sdk/{p-bpXpOZY_.js.map → p-C0Mo15qt.js.map} +1 -1
- package/dist/sdk/p-C10MAuCE.js +2 -0
- package/dist/sdk/p-C10MAuCE.js.map +1 -0
- package/dist/sdk/p-CTy6pQSg.js +2 -0
- package/dist/sdk/p-CTy6pQSg.js.map +1 -0
- package/dist/sdk/p-CW6kGAuQ.js +2 -0
- package/dist/sdk/p-CW6kGAuQ.js.map +1 -0
- package/dist/sdk/{p-DdMKVWx8.js → p-CbSP8My1.js} +2 -2
- package/dist/sdk/{p-DdMKVWx8.js.map → p-CbSP8My1.js.map} +1 -1
- package/dist/sdk/p-CbzzI4uW.js +2 -0
- package/dist/sdk/p-CbzzI4uW.js.map +1 -0
- package/dist/sdk/p-CgT6fZjb.js +2 -0
- package/dist/sdk/p-CgT6fZjb.js.map +1 -0
- package/dist/sdk/p-CuHZ3IkE.js +2 -0
- package/dist/sdk/p-CuHZ3IkE.js.map +1 -0
- package/dist/sdk/p-Cysk_vik.js +2 -0
- package/dist/sdk/p-Cysk_vik.js.map +1 -0
- package/dist/sdk/p-D0ut3waq.js +2 -0
- package/dist/sdk/p-D0ut3waq.js.map +1 -0
- package/dist/sdk/{p-BigbTrKk.js → p-D2Rf-QGm.js} +2 -2
- package/dist/sdk/{p-BigbTrKk.js.map → p-D2Rf-QGm.js.map} +1 -1
- package/dist/sdk/{p-6rqGeAfT.js → p-D9yFO_ID.js} +2 -2
- package/dist/sdk/{p-6rqGeAfT.js.map → p-D9yFO_ID.js.map} +1 -1
- package/dist/sdk/p-DD_5soRi.js +2 -0
- package/dist/sdk/p-DD_5soRi.js.map +1 -0
- package/dist/sdk/p-DHuvvagO.js +2 -0
- package/dist/sdk/p-DHuvvagO.js.map +1 -0
- package/dist/sdk/p-DSMkJu9G.js +2 -0
- package/dist/sdk/p-DSMkJu9G.js.map +1 -0
- package/dist/sdk/p-DcirMfca.js +2 -0
- package/dist/sdk/p-DcirMfca.js.map +1 -0
- package/dist/sdk/p-J0cv5IOA.js +2 -0
- package/dist/sdk/p-J0cv5IOA.js.map +1 -0
- package/dist/sdk/p-_5evboqW.js +2 -0
- package/dist/sdk/{p-DSktNM_k.js.map → p-_5evboqW.js.map} +1 -1
- package/dist/sdk/{p-7ee2f2ab.entry.js → p-ac3a6bbf.entry.js} +2 -2
- package/dist/sdk/p-b498bcdd.entry.js +2 -0
- package/dist/sdk/p-b498bcdd.entry.js.map +1 -0
- package/dist/sdk/p-b5dd5b4c.entry.js +2 -0
- package/dist/sdk/p-b5dd5b4c.entry.js.map +1 -0
- package/dist/sdk/{p-6b061b18.entry.js → p-b99588a8.entry.js} +2 -2
- package/dist/sdk/p-bf9c27a8.entry.js +2 -0
- package/dist/sdk/p-bf9c27a8.entry.js.map +1 -0
- package/dist/sdk/p-c10d9b8e.entry.js +2 -0
- package/dist/sdk/p-c10d9b8e.entry.js.map +1 -0
- package/dist/sdk/{p-10e20afd.entry.js → p-c2634439.entry.js} +2 -2
- package/dist/sdk/p-d6777395.entry.js +2 -0
- package/dist/sdk/p-d6777395.entry.js.map +1 -0
- package/dist/sdk/p-dbfe7b29.entry.js +2 -0
- package/dist/sdk/p-dbfe7b29.entry.js.map +1 -0
- package/dist/sdk/p-def4e874.entry.js +2 -0
- package/dist/sdk/p-def4e874.entry.js.map +1 -0
- package/dist/sdk/p-e872a012.entry.js +2 -0
- package/dist/sdk/p-e872a012.entry.js.map +1 -0
- package/dist/sdk/p-eaaf3989.entry.js +2 -0
- package/dist/sdk/p-eaaf3989.entry.js.map +1 -0
- package/dist/sdk/p-fd46b459.entry.js +2 -0
- package/dist/sdk/{p-830778eb.entry.js.map → p-fd46b459.entry.js.map} +1 -1
- package/dist/sdk/sdk.esm.js +1 -1
- package/dist/sdk/u-conditional-render.entry.esm.js.map +1 -1
- package/dist/sdk/u-config.entry.esm.js.map +1 -1
- package/dist/sdk/u-error-message.entry.esm.js.map +1 -1
- package/dist/sdk/u-field.u-raw-field.entry.esm.js.map +1 -1
- package/dist/sdk/u-jump-to-service.entry.esm.js.map +1 -1
- package/dist/sdk/u-jump-to-unidy.entry.esm.js.map +1 -1
- package/dist/sdk/u-logout-button.u-signed-in.entry.esm.js.map +1 -1
- package/dist/sdk/u-magic-code-field.entry.esm.js.map +1 -1
- package/dist/sdk/u-missing-field.entry.esm.js.map +1 -1
- package/dist/sdk/u-missing-fields-submit-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-newsletter-checkbox.entry.esm.js.map +1 -1
- package/dist/sdk/u-newsletter-logout-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-newsletter-preference-checkbox.entry.esm.js.map +1 -1
- package/dist/sdk/u-newsletter-resend-doi-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-newsletter-root.entry.esm.js.map +1 -1
- package/dist/sdk/u-newsletter-toggle-subscription-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-pagination-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-pagination-page.entry.esm.js.map +1 -1
- package/dist/sdk/u-passkey.entry.esm.js.map +1 -1
- 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-send-magic-code-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-signin-root.entry.esm.js.map +1 -1
- package/dist/sdk/u-signin-step.entry.esm.js.map +1 -1
- package/dist/sdk/u-social-login-button.entry.esm.js.map +1 -1
- package/dist/sdk/u-spinner.entry.esm.js.map +1 -1
- package/dist/sdk/u-ticketable-export.entry.esm.js.map +1 -0
- package/dist/sdk/u-ticketable-list.entry.esm.js.map +1 -1
- package/dist/types/api/client.d.ts +1 -1
- package/dist/types/api/index.d.ts +4 -4
- package/dist/types/api/standalone.d.ts +9 -9
- package/dist/types/auth/api/auth.d.ts +2 -3
- package/dist/types/auth/api/schemas.d.ts +19 -19
- package/dist/types/auth/auth-helpers.d.ts +1 -0
- package/dist/types/auth/components/jump-to-service/jump-to-service.d.ts +13 -5
- package/dist/types/auth/components/jump-to-unidy/jump-to-unidy.d.ts +13 -9
- package/dist/types/auth/components/logout-button/logout-button.d.ts +13 -4
- package/dist/types/auth/components/missing-field/missing-field.d.ts +1 -0
- package/dist/types/auth/components/missing-fields-submit-button/missing-fields-submit-button.d.ts +14 -2
- package/dist/types/auth/components/reset-pass-button/reset-pass-button.d.ts +13 -4
- package/dist/types/auth/components/social-logins/social-login-button.d.ts +11 -7
- package/dist/types/components.d.ts +73 -0
- package/dist/types/logger.d.ts +0 -34
- package/dist/types/newsletter/components/logout-button/logout-button.d.ts +13 -4
- package/dist/types/newsletter/components/newsletter-root/newsletter-root.d.ts +16 -2
- package/dist/types/newsletter/newsletter-helpers.d.ts +8 -2
- package/dist/types/newsletter/store/newsletter-store.d.ts +8 -1
- package/dist/types/profile/api/profile.d.ts +2 -2
- package/dist/types/profile/api/schemas.d.ts +21 -21
- package/dist/types/profile/components/raw-field/raw-field.d.ts +14 -2
- package/dist/types/shared/base/component.d.ts +46 -0
- package/dist/types/shared/base/has-slot-content.d.ts +10 -0
- package/dist/types/shared/component-utils.d.ts +20 -12
- package/dist/types/shared/components/conditional-render/conditional-render.d.ts +7 -2
- package/dist/types/shared/components/config/config.d.ts +7 -2
- package/dist/types/shared/components/error-message/error-message.d.ts +14 -2
- package/dist/types/shared/components/submit-button/submit-button.d.ts +13 -4
- package/dist/types/shared/context-utils.d.ts +73 -0
- package/dist/types/shared/utils/redirect-with-token.d.ts +21 -0
- package/dist/types/shared/utils/url-utils.d.ts +16 -0
- package/dist/types/ticketable/api/schemas.d.ts +16 -2
- package/dist/types/ticketable/api/subscriptions.d.ts +8 -3
- package/dist/types/ticketable/api/tickets.d.ts +8 -3
- package/dist/types/ticketable/components/pagination/pagination-button.d.ts +8 -4
- package/dist/types/ticketable/components/pagination/pagination-page.d.ts +8 -4
- package/dist/types/ticketable/components/ticketable-export/ticketable-export.d.ts +24 -0
- package/dist/types/ticketable/components/ticketable-list/ticketable-list.d.ts +10 -4
- package/dist/types/ticketable/index.d.ts +1 -0
- package/package.json +6 -2
- package/readme.md +248 -27
- package/dist/cjs/app-globals-hdkLqF51.js +0 -10
- package/dist/cjs/app-globals-hdkLqF51.js.map +0 -1
- package/dist/cjs/component-utils-bu3SY4dE.js +0 -42
- package/dist/cjs/component-utils-bu3SY4dE.js.map +0 -1
- package/dist/cjs/index-B325yXfO.js.map +0 -1
- package/dist/cjs/index-BzPYBLYC.js.map +0 -1
- package/dist/cjs/newsletter-helpers-hdDC5X-V.js.map +0 -1
- package/dist/cjs/newsletter-store-CupsLgO9.js.map +0 -1
- package/dist/cjs/pagination-store-zo48QpTm.js +0 -16
- package/dist/cjs/pagination-store-zo48QpTm.js.map +0 -1
- package/dist/components/pagination-store.js +0 -14
- package/dist/components/pagination-store.js.map +0 -1
- package/dist/esm/app-globals-iHhGdwBB.js +0 -8
- package/dist/esm/app-globals-iHhGdwBB.js.map +0 -1
- package/dist/esm/component-utils-BGq0leDV.js +0 -39
- package/dist/esm/component-utils-BGq0leDV.js.map +0 -1
- package/dist/esm/index-BVlbCQEX.js.map +0 -1
- package/dist/esm/index-FTKB5a1d.js.map +0 -1
- package/dist/esm/newsletter-helpers-fCpxzovf.js.map +0 -1
- package/dist/esm/newsletter-store-BB618FgS.js.map +0 -1
- package/dist/esm/pagination-store-DxmcQH8R.js +0 -14
- package/dist/esm/pagination-store-DxmcQH8R.js.map +0 -1
- package/dist/sdk/p-1a8973a6.entry.js +0 -2
- package/dist/sdk/p-35ad60ab.entry.js +0 -2
- package/dist/sdk/p-35ad60ab.entry.js.map +0 -1
- package/dist/sdk/p-3f352f38.entry.js +0 -2
- package/dist/sdk/p-3f352f38.entry.js.map +0 -1
- package/dist/sdk/p-468aaf62.entry.js +0 -2
- package/dist/sdk/p-468aaf62.entry.js.map +0 -1
- package/dist/sdk/p-4e2e6a13.entry.js +0 -2
- package/dist/sdk/p-4e2e6a13.entry.js.map +0 -1
- package/dist/sdk/p-57c8dc68.entry.js +0 -2
- package/dist/sdk/p-57c8dc68.entry.js.map +0 -1
- package/dist/sdk/p-594aec0c.entry.js +0 -2
- package/dist/sdk/p-594aec0c.entry.js.map +0 -1
- package/dist/sdk/p-60c8be64.entry.js +0 -2
- package/dist/sdk/p-60c8be64.entry.js.map +0 -1
- package/dist/sdk/p-760718d3.entry.js +0 -2
- package/dist/sdk/p-760718d3.entry.js.map +0 -1
- package/dist/sdk/p-77f541f3.entry.js +0 -2
- package/dist/sdk/p-77f541f3.entry.js.map +0 -1
- package/dist/sdk/p-830778eb.entry.js +0 -2
- package/dist/sdk/p-8839648e.entry.js +0 -2
- package/dist/sdk/p-8839648e.entry.js.map +0 -1
- package/dist/sdk/p-B6MYe-dh.js +0 -2
- package/dist/sdk/p-B6MYe-dh.js.map +0 -1
- package/dist/sdk/p-BGq0leDV.js +0 -2
- package/dist/sdk/p-BGq0leDV.js.map +0 -1
- package/dist/sdk/p-C_UZBwdm.js +0 -2
- package/dist/sdk/p-C_UZBwdm.js.map +0 -1
- package/dist/sdk/p-CbazSxaZ.js +0 -2
- package/dist/sdk/p-CbazSxaZ.js.map +0 -1
- package/dist/sdk/p-DCG3L43i.js +0 -2
- package/dist/sdk/p-DEUPZOH-.js +0 -2
- package/dist/sdk/p-DEUPZOH-.js.map +0 -1
- package/dist/sdk/p-DSktNM_k.js +0 -2
- package/dist/sdk/p-FTKB5a1d.js +0 -14
- package/dist/sdk/p-FTKB5a1d.js.map +0 -1
- package/dist/sdk/p-a7ffcff9.entry.js +0 -2
- package/dist/sdk/p-a7ffcff9.entry.js.map +0 -1
- package/dist/sdk/p-acaba1d5.entry.js +0 -2
- package/dist/sdk/p-acaba1d5.entry.js.map +0 -1
- package/dist/sdk/p-ae47a7a3.entry.js +0 -2
- package/dist/sdk/p-ae47a7a3.entry.js.map +0 -1
- package/dist/sdk/p-aec580e4.entry.js +0 -2
- package/dist/sdk/p-aec580e4.entry.js.map +0 -1
- package/dist/sdk/p-b63438ff.entry.js +0 -2
- package/dist/sdk/p-b63438ff.entry.js.map +0 -1
- package/dist/sdk/p-baaaa7f5.entry.js +0 -2
- package/dist/sdk/p-baaaa7f5.entry.js.map +0 -1
- package/dist/sdk/p-bba2da84.entry.js +0 -2
- package/dist/sdk/p-bba2da84.entry.js.map +0 -1
- package/dist/sdk/p-bc47f42b.entry.js +0 -2
- package/dist/sdk/p-bc47f42b.entry.js.map +0 -1
- package/dist/sdk/p-bd51e26f.entry.js +0 -2
- package/dist/sdk/p-bd51e26f.entry.js.map +0 -1
- package/dist/sdk/p-c3552f75.entry.js +0 -2
- package/dist/sdk/p-c3552f75.entry.js.map +0 -1
- package/dist/sdk/p-d9900482.entry.js +0 -2
- package/dist/sdk/p-d9900482.entry.js.map +0 -1
- package/dist/sdk/p-e6796c38.entry.js +0 -2
- package/dist/sdk/p-e6796c38.entry.js.map +0 -1
- package/dist/sdk/p-f272eb38.entry.js +0 -2
- package/dist/sdk/p-f272eb38.entry.js.map +0 -1
- package/dist/sdk/p-f4a47ef8.entry.js +0 -2
- package/dist/sdk/p-f4a47ef8.entry.js.map +0 -1
- package/dist/sdk/p-f608e64a.entry.js +0 -2
- package/dist/sdk/p-f608e64a.entry.js.map +0 -1
- package/dist/sdk/p-f762ac70.entry.js +0 -2
- package/dist/sdk/p-f762ac70.entry.js.map +0 -1
- package/dist/sdk/p-l6NinBiD.js +0 -2
- package/dist/sdk/p-l6NinBiD.js.map +0 -1
- /package/dist/sdk/{p-88beb872.entry.js.map → p-8412762c.entry.js.map} +0 -0
- /package/dist/sdk/{p-bcca06f1.entry.js.map → p-96860b09.entry.js.map} +0 -0
- /package/dist/sdk/{p-7ee2f2ab.entry.js.map → p-ac3a6bbf.entry.js.map} +0 -0
- /package/dist/sdk/{p-6b061b18.entry.js.map → p-b99588a8.entry.js.map} +0 -0
- /package/dist/sdk/{p-10e20afd.entry.js.map → p-c2634439.entry.js.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"u-conditional-render.js","mappings":";;;;;;;;AAQA,MAAM,qBAAqB,GAAoD;IAC7E,qBAAqB,EAAE,MAAMA,KAAS,CAAC,qBAAqB,EAAE,OAAO;IACrE,sBAAsB,EAAE,MAAMA,KAAS,CAAC,qBAAqB,EAAE,QAAQ;IACvE,uBAAuB,EAAE,MAAMA,KAAS,CAAC,qBAAqB,EAAE,UAAU;AAC1E,IAAA,0BAA0B,EAAE,MAAM,CAACA,KAAS,CAAC,qBAAqB,EAAE,aAAa,EAAE,MAAM,IAAI,CAAC,IAAI,CAAC;AACnG,IAAA,qBAAqB,EAAE,CAAC,QAAg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IAAI,IAAI,CAAC,EAAE,KAAK,SAAS,EAAE;AAChC,YAAA,MAAM,GAAG,QAAQ,CAAC,KAAK,CAAC;;aACnB,IAAI,YAAY,KAAK,SAAS,IAAI,YAAY,KAAK,MAAM,EAAE;AAChE,YAAA,MAAM,GAAG,QAAQ,CAAC,KAAK,CAAC;;aACnB,IAAI,YAAY,KAAK,UAAU,IAAI,YAAY,KAAK,OAAO,EAAE;AAClE,YAAA,MAAM,GAAG,CAAC,QAAQ,CAAC,KAAK,CAAC;;aACpB;AACL,YAAA,MAAM,GAAG,MAAM,CAAC,KAAK,CAAC,KAAK,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;;AAG7C,QAAA,OAAO,IAAI,CAAC,GAAG,GAAG,CAAC,MAAM,GAAG,MAAM;;IAGpC,MAAM,GAAA;AACJ,QAAA,MAAM,UAAU,GAAG,IAAI,CAAC,YAAY,EAAE;AAEtC,QAAA,QACE,CAAC,CAAA,IAAI,EACH,EAAA,GAAA,EAAA,0CAAA,EAAA,MAAM,EAAE,CAAC,UAAU,EACnB,KAAK,EAAE,EAAE,OAAO,EAAE,UAAU,GAAG,UAAU,GAAG,SAAS,EAAE,EAAA,aAAA,EAC1C,CAAC,UAAU,GAAG,MAAM,GAAG,IAAI,eAC9B,QAAQ,EAAA,EAElB,CAAQ,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACH;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["authState","NewsletterHelpers.isSubscribed","NewsletterHelpers.isConfirmed","__stencil_proxyCustomElement"],"sources":["src/shared/components/conditional-render/conditional-render.tsx"],"sourcesContent":["import { Component, Host, h, Prop } from \"@stencil/core\";\nimport { type AuthState, authState } from \"../../../auth/store/auth-store\";\nimport * as NewsletterHelpers from \"../../../newsletter/newsletter-helpers\";\nimport { newsletterStore } from \"../../../newsletter/store/newsletter-store\";\nimport { profileStore } from \"../../../profile/store/profile-store\";\nimport { UnidyComponent } from \"../../base/component\";\nimport { flashState } from \"../../store/flash-store\";\n\nconst PREDEFINED_CONDITIONS: Record<string, (...args: unknown[]) => unknown> = {\n \"auth.passkeyEnabled\": () => authState.availableLoginOptions?.passkey,\n \"auth.passwordEnabled\": () => authState.availableLoginOptions?.password,\n \"auth.magicCodeEnabled\": () => authState.availableLoginOptions?.magic_link,\n \"auth.socialLoginsEnabled\": () => (authState.availableLoginOptions?.social_logins?.length ?? 0) > 0,\n \"auth.hasSocialLogin\": (provider: string) => authState.availableLoginOptions?.social_logins?.includes(provider) ?? false,\n \"auth.loading\": () => authState.loading,\n \"auth.authenticated\": () => authState.authenticated,\n \"auth.magicCodeSent\": () => authState.magicCodeStep === \"sent\" || authState.magicCodeStep === \"requested\",\n \"auth.magicCodeRequested\": () => authState.magicCodeStep === \"requested\",\n \"auth.resetPasswordSent\": () => authState.resetPassword.step === \"sent\" || authState.resetPassword.step === \"requested\",\n \"auth.resetPasswordRequested\": () => authState.resetPassword.step === \"requested\",\n\n \"newsletter.hasCheckedNewsletters\": () => Object.keys(newsletterStore.state.checkedNewsletters).length > 0,\n \"newsletter.hasPreferenceToken\": () => !!newsletterStore.state.preferenceToken,\n \"newsletter.hasEmail\": () => !!newsletterStore.state.email,\n \"newsletter.subscribed\": (newsletterInternalName: string) => NewsletterHelpers.isSubscribed(newsletterInternalName),\n \"newsletter.confirmed\": (newsletterInternalName: string) => NewsletterHelpers.isConfirmed(newsletterInternalName),\n \"newsletter.loggedIn\": () => newsletterStore.state.isAuthenticated || newsletterStore.state.preferenceToken !== \"\",\n\n \"profile.loading\": () => profileStore.state.loading,\n \"profile.hasErrors\": () => Object.keys(profileStore.state.errors).some((key) => profileStore.state.errors[key] !== null),\n \"profile.hasFlashErrors\": () => flashState.messages.some((m) => m.variant === \"error\"),\n \"profile.phoneValid\": () => profileStore.state.phoneValid,\n \"profile.hasData\": () => Object.keys(profileStore.state.data).length > 0,\n};\n\nfunction isTruthy(value: unknown): boolean {\n return Boolean(value);\n}\n\n@Component({\n tag: \"u-conditional-render\",\n shadow: false,\n})\nexport class ConditionalRender extends UnidyComponent() {\n @Prop() when?: string; // condition to check\n @Prop() is?: string; // optional value to compare against\n @Prop() not = false;\n @Prop() conditionFunction?: (state: AuthState) => boolean;\n\n private evaluateCondition(): unknown {\n const predefinedFunction = PREDEFINED_CONDITIONS[this.when];\n if (predefinedFunction) {\n return predefinedFunction(this.is);\n }\n\n return null;\n }\n\n private shouldRender(): boolean {\n if (!this.when && !this.conditionFunction) {\n this.logger.error(\"[u-conditional-render] Either 'when' or 'conditionFunction' prop is required\");\n }\n\n if (this.conditionFunction) {\n const result = this.conditionFunction(authState);\n return this.not ? !result : result;\n }\n\n const value = this.evaluateCondition();\n if (value === null) {\n return false;\n }\n\n const normalizedIs = this.is?.toString().toLowerCase();\n let result: boolean;\n\n if (typeof value === \"boolean\") {\n if (normalizedIs === \"false\" || normalizedIs === \"disabled\") {\n result = !value;\n } else {\n result = value;\n }\n } else if (this.is === undefined) {\n result = isTruthy(value);\n } else if (normalizedIs === \"enabled\" || normalizedIs === \"true\") {\n result = isTruthy(value);\n } else if (normalizedIs === \"disabled\" || normalizedIs === \"false\") {\n result = !isTruthy(value);\n } else {\n result = String(value) === String(this.is); // to compare exact value\n }\n\n return this.not ? !result : result;\n }\n\n render() {\n const shouldShow = this.shouldRender();\n\n return (\n <Host\n hidden={!shouldShow}\n style={{ display: shouldShow ? \"contents\" : undefined }}\n aria-hidden={!shouldShow ? \"true\" : null}\n aria-live=\"polite\"\n >\n <slot />\n </Host>\n );\n }\n}\n"],"version":3}
|
|
@@ -2,11 +2,12 @@ import { proxyCustomElement, createEvent, h } from '@stencil/core/internal/clien
|
|
|
2
2
|
import { i as Auth, g as getUnidyClient } from './index2.js';
|
|
3
3
|
import './auth-store.js';
|
|
4
4
|
import { i as instance } from './i18n.js';
|
|
5
|
-
import { U as UnidyComponent } from './
|
|
5
|
+
import { U as UnidyComponent } from './component.js';
|
|
6
6
|
import { u as unidyState } from './unidy-store.js';
|
|
7
7
|
import { _ as captureException } from './exports.js';
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
let configInstance = null;
|
|
10
|
+
const UnidyConfig = /*@__PURE__*/ proxyCustomElement(class UnidyConfig extends UnidyComponent() {
|
|
10
11
|
constructor(registerHost) {
|
|
11
12
|
super();
|
|
12
13
|
if (registerHost !== false) {
|
|
@@ -25,6 +26,11 @@ const UnidyConfig = /*@__PURE__*/ proxyCustomElement(class UnidyConfig extends U
|
|
|
25
26
|
unidyInitialized;
|
|
26
27
|
configChange;
|
|
27
28
|
async componentWillLoad() {
|
|
29
|
+
if (configInstance !== null) {
|
|
30
|
+
this.logger.error("Only one <u-config> element is allowed per page.");
|
|
31
|
+
return;
|
|
32
|
+
}
|
|
33
|
+
configInstance = this;
|
|
28
34
|
if (!this.baseUrl || !this.apiKey) {
|
|
29
35
|
this.logger.error("baseUrl and apiKey are required");
|
|
30
36
|
return;
|
|
@@ -46,6 +52,13 @@ const UnidyConfig = /*@__PURE__*/ proxyCustomElement(class UnidyConfig extends U
|
|
|
46
52
|
if (this.checkSignedIn) {
|
|
47
53
|
auth.helpers.checkSignedIn();
|
|
48
54
|
}
|
|
55
|
+
this.logger.debug("Unidy SDK initialized successfully");
|
|
56
|
+
}
|
|
57
|
+
disconnectedCallback() {
|
|
58
|
+
if (configInstance === this) {
|
|
59
|
+
configInstance = null;
|
|
60
|
+
unidyState.isConfigured = false;
|
|
61
|
+
}
|
|
49
62
|
}
|
|
50
63
|
// extend the list of properties that should be watched when new properties are added to the Config
|
|
51
64
|
onPropChange(newValue, oldValue, propName) {
|
|
@@ -61,7 +74,7 @@ const UnidyConfig = /*@__PURE__*/ proxyCustomElement(class UnidyConfig extends U
|
|
|
61
74
|
});
|
|
62
75
|
}
|
|
63
76
|
render() {
|
|
64
|
-
return h("slot", { key: '
|
|
77
|
+
return h("slot", { key: 'd8c63b2abf7d7032823546f4598e9d2fb671bf16' });
|
|
65
78
|
}
|
|
66
79
|
loadCustomTranslations() {
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AAA,QAAI,CAAC,iBAAiB,CAAC,IAAI,EAAE,aAAa,EAAE,YAAY,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC;;;;YAG/E,OAAO,KAAK,EAAE;AACd,gBAAAC,gBAAuB,CAAC,oCAAoC,EAAE,KAAK,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","i18n","Sentry.captureException"],"sources":["src/shared/components/config/config.tsx"],"sourcesContent":["import * as Sentry from \"@sentry/browser\";\nimport { Component, Event, type EventEmitter, h, Prop, Watch } from \"@stencil/core\";\nimport { getUnidyClient } from \"../../../api/\";\nimport { Auth } from \"../../../auth\";\nimport i18n from \"../../../i18n\";\nimport { UnidyComponent } from \"../../base/component\";\nimport { unidyState } from \"../../store/unidy-store\";\n\nlet configInstance: UnidyConfig | null = null;\n\nexport interface Config {\n apiKey: string;\n baseUrl: string;\n locale: string;\n mode: \"production\" | \"development\";\n}\n\nexport interface ConfigChange {\n key: string;\n value: string;\n previousValue: string;\n}\n\ntype TranslationTree = {\n [key: string]: string | TranslationTree;\n};\n\n@Component({\n tag: \"u-config\",\n shadow: false,\n})\nexport class UnidyConfig extends UnidyComponent() {\n @Prop() mode: \"production\" | \"development\" = \"production\";\n @Prop() baseUrl = \"\";\n @Prop() apiKey = \"\";\n @Prop() customTranslations: string | Record<string, TranslationTree> = \"\";\n @Prop() fallbackLocale = \"en\";\n @Prop() locale = \"en\";\n @Prop() checkSignedIn = false;\n\n @Event() unidyInitialized!: EventEmitter<Config>;\n @Event() configChange!: EventEmitter<ConfigChange>;\n\n async componentWillLoad() {\n if (configInstance !== null) {\n this.logger.error(\"Only one <u-config> element is allowed per page.\");\n return;\n }\n configInstance = this;\n\n if (!this.baseUrl || !this.apiKey) {\n this.logger.error(\"baseUrl and apiKey are required\");\n return;\n }\n\n unidyState.apiKey = this.apiKey;\n unidyState.baseUrl = this.baseUrl;\n unidyState.locale = this.locale;\n unidyState.isConfigured = true;\n\n this.unidyInitialized.emit({\n apiKey: this.apiKey,\n baseUrl: this.baseUrl,\n locale: this.locale,\n mode: this.mode,\n });\n\n i18n.options.fallbackLng = this.fallbackLocale;\n\n this.loadCustomTranslations();\n unidyState.locale = this.locale;\n\n const auth = await Auth.initialize(getUnidyClient());\n\n if (this.checkSignedIn) {\n auth.helpers.checkSignedIn();\n }\n\n this.logger.debug(\"Unidy SDK initialized successfully\");\n }\n\n disconnectedCallback() {\n if (configInstance === this) {\n configInstance = null;\n unidyState.isConfigured = false;\n }\n }\n\n // extend the list of properties that should be watched when new properties are added to the Config\n @Watch(\"mode\")\n @Watch(\"locale\")\n onPropChange(newValue: string, oldValue: string, propName: keyof Config) {\n if (oldValue === undefined) return;\n\n if (propName in unidyState) {\n (unidyState as Record<keyof Config, string>)[propName] = newValue;\n }\n\n this.configChange.emit({\n key: propName,\n value: newValue,\n previousValue: oldValue,\n });\n }\n\n render() {\n return <slot />;\n }\n\n private loadCustomTranslations() {\n if (this.customTranslations) {\n try {\n const translations = typeof this.customTranslations === \"string\" ? JSON.parse(this.customTranslations) : this.customTranslations;\n\n for (const lang in translations) {\n if (Object.hasOwn(translations, lang)) {\n i18n.addResourceBundle(lang, \"translation\", translations[lang], true, true);\n }\n }\n } catch (error) {\n Sentry.captureException(\"Failed to parse customTranslations\", error);\n }\n }\n }\n}\n"],"version":3}
|
|
@@ -67,7 +67,7 @@ const EmailField = /*@__PURE__*/ proxyCustomElement(class EmailField extends HTM
|
|
|
67
67
|
}
|
|
68
68
|
render() {
|
|
69
69
|
const placeholderText = t("auth.email.placeholder", { defaultValue: "Enter your email" });
|
|
70
|
-
return (h("form", { key: '
|
|
70
|
+
return (h("form", { key: '5033ba72842a4cd9125a58170a733c6ec2aaed5a', onSubmit: this.handleSubmit }, h("input", { key: 'f97c1f8881e08fcfcffdf252862e63469b483cbd', id: "email", type: "email", value: this.store.state.email, autocomplete: "email", placeholder: placeholderText, disabled: this.isDisabled(), class: `${this.componentClassName} u:disabled:opacity-40 u:disabled:bg-gray-200 u:disabled:cursor-not-allowed`, onInput: this.handleInput, "aria-label": this.ariaLabel }), h("slot", { key: 'd4d403e19c003e80119be01587d9cd00244908ae' })));
|
|
71
71
|
}
|
|
72
72
|
static get style() { return emailFieldCss; }
|
|
73
73
|
}, [772, "u-email-field", {
|
|
@@ -1,30 +1,29 @@
|
|
|
1
|
-
import { proxyCustomElement,
|
|
1
|
+
import { proxyCustomElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
import { s as state } from './auth-store.js';
|
|
3
3
|
import { t } from './i18n.js';
|
|
4
4
|
import { n as newsletterStore } from './newsletter-store.js';
|
|
5
|
-
import {
|
|
5
|
+
import { U as UnidyComponent } from './component.js';
|
|
6
|
+
import { H as HasSlotContent } from './has-slot-content.js';
|
|
6
7
|
import { u as unidyState } from './unidy-store.js';
|
|
7
8
|
|
|
8
|
-
const errorMessageCss = "/*! tailwindcss v4.1.18 | 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,utilities; /*! tailwindcss v4.1.18 | 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)}}
|
|
9
|
+
const errorMessageCss = "/*! tailwindcss v4.1.18 | 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\\:block{display:block}} /*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer base{}@layer components,utilities; /*! tailwindcss v4.1.18 | MIT License | https://tailwindcss.com */@layer base{}@layer components,utilities; /*! tailwindcss v4.1.18 | 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{.visible{visibility:visible}.hidden{display:none}.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}";
|
|
9
10
|
|
|
10
|
-
const ErrorMessage = /*@__PURE__*/ proxyCustomElement(class ErrorMessage extends
|
|
11
|
+
const ErrorMessage = /*@__PURE__*/ proxyCustomElement(class ErrorMessage extends UnidyComponent(HasSlotContent) {
|
|
11
12
|
constructor(registerHost) {
|
|
12
13
|
super();
|
|
13
14
|
if (registerHost !== false) {
|
|
14
15
|
this.__registerHost();
|
|
15
16
|
}
|
|
16
|
-
this.__attachShadow();
|
|
17
17
|
}
|
|
18
18
|
componentClassName = "";
|
|
19
19
|
for;
|
|
20
20
|
errorMessages;
|
|
21
|
-
get el() { return this; }
|
|
22
21
|
detectContext() {
|
|
23
|
-
if (this.
|
|
22
|
+
if (this.element.closest("u-signin-root") || this.element.closest("u-signin-step"))
|
|
24
23
|
return "auth";
|
|
25
|
-
if (this.
|
|
24
|
+
if (this.element.closest("u-profile"))
|
|
26
25
|
return "profile";
|
|
27
|
-
if (this.
|
|
26
|
+
if (this.element.closest("u-newsletter-root"))
|
|
28
27
|
return "newsletter";
|
|
29
28
|
if (this.for === "general" || this.for === "connection")
|
|
30
29
|
return "other";
|
|
@@ -44,14 +43,36 @@ const ErrorMessage = /*@__PURE__*/ proxyCustomElement(class ErrorMessage extends
|
|
|
44
43
|
return errorCode || t("errors.unknown", { defaultValue: "An error occurred" });
|
|
45
44
|
}
|
|
46
45
|
getNewsletterErrorMessage(errorIdentifier) {
|
|
47
|
-
|
|
46
|
+
const translationKey = `newsletter.errors.${errorIdentifier}`;
|
|
47
|
+
const translated = t(translationKey);
|
|
48
|
+
if (translated !== translationKey) {
|
|
49
|
+
return translated;
|
|
50
|
+
}
|
|
51
|
+
return t("errors.unknown", { defaultValue: "An unknown error occurred" });
|
|
48
52
|
}
|
|
49
53
|
getErrorMessage(errorCode) {
|
|
50
54
|
if (this.context === "auth") {
|
|
51
55
|
return this.getAuthErrorMessage(errorCode);
|
|
52
56
|
}
|
|
57
|
+
const fieldError = newsletterStore.state.additionalFieldErrors[this.for];
|
|
58
|
+
if (fieldError) {
|
|
59
|
+
return this.translateValidationError(fieldError);
|
|
60
|
+
}
|
|
53
61
|
return this.getNewsletterErrorMessage(errorCode);
|
|
54
62
|
}
|
|
63
|
+
translateValidationError(errorIdentifier) {
|
|
64
|
+
const fieldSpecificKey = `errors.${this.for}.${errorIdentifier}`;
|
|
65
|
+
const fieldSpecific = t(fieldSpecificKey);
|
|
66
|
+
if (fieldSpecific !== fieldSpecificKey) {
|
|
67
|
+
return fieldSpecific;
|
|
68
|
+
}
|
|
69
|
+
const genericKey = `errors.validation.${errorIdentifier}`;
|
|
70
|
+
const generic = t(genericKey);
|
|
71
|
+
if (generic !== genericKey) {
|
|
72
|
+
return generic;
|
|
73
|
+
}
|
|
74
|
+
return t("errors.unknown", { defaultValue: "An unknown error occurred" });
|
|
75
|
+
}
|
|
55
76
|
getAuthErrorCode() {
|
|
56
77
|
const forValue = this.for;
|
|
57
78
|
if (forValue === "connection") {
|
|
@@ -63,24 +84,28 @@ const ErrorMessage = /*@__PURE__*/ proxyCustomElement(class ErrorMessage extends
|
|
|
63
84
|
return state.errors[forValue];
|
|
64
85
|
}
|
|
65
86
|
getNewsletterErrorCode() {
|
|
66
|
-
const
|
|
67
|
-
|
|
87
|
+
const newsletterError = newsletterStore.state.errors[this.for];
|
|
88
|
+
if (newsletterError)
|
|
89
|
+
return newsletterError;
|
|
90
|
+
const fieldError = newsletterStore.state.additionalFieldErrors[this.for];
|
|
91
|
+
return fieldError ?? null;
|
|
68
92
|
}
|
|
69
93
|
render() {
|
|
70
94
|
const errorCode = this.context === "newsletter" ? this.getNewsletterErrorCode() : this.getAuthErrorCode();
|
|
71
|
-
if
|
|
72
|
-
|
|
73
|
-
}
|
|
95
|
+
// Check if we should show the error
|
|
96
|
+
let shouldShow = !!errorCode;
|
|
74
97
|
// Only render connection_failed for "general" and "connection" types
|
|
75
98
|
if (errorCode === "connection_failed" && this.for !== "general" && this.for !== "connection") {
|
|
76
|
-
|
|
99
|
+
shouldShow = false;
|
|
77
100
|
}
|
|
78
|
-
const errorMessage = this.getErrorMessage(errorCode);
|
|
101
|
+
const errorMessage = shouldShow ? this.getErrorMessage(errorCode) : null;
|
|
79
102
|
const formattedMessage = errorMessage?.includes("\n") ? h("div", { style: { whiteSpace: "pre-line" } }, errorMessage) : errorMessage;
|
|
80
|
-
|
|
103
|
+
// For shadow: false components with slots, we must always render Host but use hidden/display
|
|
104
|
+
// to control visibility, otherwise slotted content remains visible in the light DOM
|
|
105
|
+
return (h(Host, { key: '3389f45bb7effe946394ec1b3e84ff867257d4bc', class: `u:block ${this.componentClassName}`, hidden: !shouldShow, style: { display: shouldShow ? undefined : "none" }, "aria-hidden": !shouldShow ? "true" : null, "aria-live": "polite" }, this.hasSlot ? h("slot", null) : formattedMessage));
|
|
81
106
|
}
|
|
82
107
|
static get style() { return errorMessageCss; }
|
|
83
|
-
}, [
|
|
108
|
+
}, [772, "u-error-message", {
|
|
84
109
|
"componentClassName": [1, "class-name"],
|
|
85
110
|
"for": [1],
|
|
86
111
|
"errorMessages": [16]
|
|
@@ -1 +1 @@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,EAAG,YAAY,CAAO,GAAG,YAAY;;;AAInI,QAAA,QACE,CAAC,CAAA,IAAI,EACH,EAAA,GAAA,EAAA,0CAAA,EAAA,KAAK,EAAE,CAAW,QAAA,EAAA,IAAI,CAAC,kBAAkB,CAAA,CAAE,EAC3C,MAAM,EAAE,CAAC,UAAU,EACnB,KAAK,EAAE,EAAE,OAAO,EAAE,UAAU,GAAG,SAAS,GAAG,MAAM,EAAE,EAAA,aAAA,EACtC,CAAC,UAAU,GAAG,MAAM,GAAG,IAAI,EAC9B,WAAA,EAAA,QAAQ,EAEjB,EAAA,IAAI,CAAC,OAAO,GAAG,CAAA,CAAA,MAAA,EAAA,IAAA,CAAQ,GAAG,gBAAgB,CACtC;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","authState"],"sources":["src/shared/components/error-message/error-message.css?tag=u-error-message","src/shared/components/error-message/error-message.tsx"],"sourcesContent":["/* This file is required for stencil-tailwind-plugin to generate Tailwind CSS for this component */\n","import { Component, Host, h, Prop } from \"@stencil/core\";\nimport { authState } from \"../../../auth/store/auth-store\";\nimport { t } from \"../../../i18n\";\nimport { type NewsletterErrorIdentifier, newsletterStore } from \"../../../newsletter/store/newsletter-store\";\nimport { UnidyComponent } from \"../../base/component\";\nimport { HasSlotContent } from \"../../base/has-slot-content\";\nimport { unidyState } from \"../../store/unidy-store\";\n\nexport type AuthErrorType = \"email\" | \"password\" | \"magicCode\" | \"resetPassword\" | \"general\" | \"connection\" | \"passkey\";\n\n@Component({\n tag: \"u-error-message\",\n shadow: false,\n styleUrl: \"error-message.css\",\n})\nexport class ErrorMessage extends UnidyComponent(HasSlotContent) {\n @Prop({ attribute: \"class-name\" }) componentClassName = \"\";\n @Prop() for!: string;\n\n @Prop() errorMessages?: Record<string, string>;\n\n private detectContext(): \"auth\" | \"newsletter\" | \"profile\" | \"other\" {\n if (this.element.closest(\"u-signin-root\") || this.element.closest(\"u-signin-step\")) return \"auth\";\n\n if (this.element.closest(\"u-profile\")) return \"profile\";\n\n if (this.element.closest(\"u-newsletter-root\")) return \"newsletter\";\n\n if (this.for === \"general\" || this.for === \"connection\") return \"other\";\n\n throw new Error(\n \"No context found for error message. Make sure you are using the component within a u-signin-root, u-profile, or u-newsletter-root.\",\n );\n }\n\n private get context(): \"auth\" | \"newsletter\" | \"profile\" | \"other\" {\n return this.detectContext();\n }\n\n private getAuthErrorMessage(errorCode: string): string {\n if (this.errorMessages?.[errorCode]) {\n return this.errorMessages[errorCode];\n }\n\n const translatedError = t(`errors.${errorCode}`);\n if (translatedError !== `errors.${errorCode}`) {\n return translatedError;\n }\n\n return errorCode || t(\"errors.unknown\", { defaultValue: \"An error occurred\" });\n }\n\n private getNewsletterErrorMessage(errorIdentifier: NewsletterErrorIdentifier): string {\n const translationKey = `newsletter.errors.${errorIdentifier}`;\n const translated = t(translationKey);\n\n if (translated !== translationKey) {\n return translated;\n }\n return t(\"errors.unknown\", { defaultValue: \"An unknown error occurred\" });\n }\n\n private getErrorMessage(errorCode: string): string | null {\n if (this.context === \"auth\") {\n return this.getAuthErrorMessage(errorCode);\n }\n\n const fieldError = newsletterStore.state.additionalFieldErrors[this.for];\n if (fieldError) {\n return this.translateValidationError(fieldError);\n }\n\n return this.getNewsletterErrorMessage(errorCode as NewsletterErrorIdentifier);\n }\n\n private translateValidationError(errorIdentifier: string): string {\n const fieldSpecificKey = `errors.${this.for}.${errorIdentifier}`;\n const fieldSpecific = t(fieldSpecificKey);\n if (fieldSpecific !== fieldSpecificKey) {\n return fieldSpecific;\n }\n\n const genericKey = `errors.validation.${errorIdentifier}`;\n const generic = t(genericKey);\n if (generic !== genericKey) {\n return generic;\n }\n\n return t(\"errors.unknown\", { defaultValue: \"An unknown error occurred\" });\n }\n\n private getAuthErrorCode(): string | null {\n const forValue = this.for as AuthErrorType;\n\n if (forValue === \"connection\") {\n return unidyState.backendConnected ? null : \"connection_failed\";\n }\n\n if (forValue === \"general\") {\n return authState.globalErrors.auth;\n }\n\n return authState.errors[forValue];\n }\n\n private getNewsletterErrorCode(): string | null {\n const newsletterError = newsletterStore.state.errors[this.for];\n if (newsletterError) return newsletterError;\n\n const fieldError = newsletterStore.state.additionalFieldErrors[this.for];\n return fieldError ?? null;\n }\n\n render() {\n const errorCode = this.context === \"newsletter\" ? this.getNewsletterErrorCode() : this.getAuthErrorCode();\n\n // Check if we should show the error\n let shouldShow = !!errorCode;\n\n // Only render connection_failed for \"general\" and \"connection\" types\n if (errorCode === \"connection_failed\" && this.for !== \"general\" && this.for !== \"connection\") {\n shouldShow = false;\n }\n\n const errorMessage = shouldShow ? this.getErrorMessage(errorCode) : null;\n const formattedMessage = errorMessage?.includes(\"\\n\") ? <div style={{ whiteSpace: \"pre-line\" }}>{errorMessage}</div> : errorMessage;\n\n // For shadow: false components with slots, we must always render Host but use hidden/display\n // to control visibility, otherwise slotted content remains visible in the light DOM\n return (\n <Host\n class={`u:block ${this.componentClassName}`}\n hidden={!shouldShow}\n style={{ display: shouldShow ? undefined : \"none\" }}\n aria-hidden={!shouldShow ? \"true\" : null}\n aria-live=\"polite\"\n >\n {this.hasSlot ? <slot /> : formattedMessage}\n </Host>\n );\n }\n}\n"],"version":3}
|
|
@@ -32,7 +32,7 @@ const FullProfile = /*@__PURE__*/ proxyCustomElement(class FullProfile extends H
|
|
|
32
32
|
];
|
|
33
33
|
}
|
|
34
34
|
render() {
|
|
35
|
-
return (h("u-profile", { key: '
|
|
35
|
+
return (h("u-profile", { key: '7de2b4fa3359b1baf43d1bd4e413b793a67efe58' }, this.list().map((field) => (h("u-field", { key: field, field: field, countryCodeDisplayOption: this.countryCodeDisplayOption }))), h("div", { key: 'f2dfeb0539ff4da9e3a9ca164ce3305516866ff1', class: "u:flex u:justify-end" }, h("u-submit-button", { key: '276be0b12438b6feb4df1277635e57ec15a5699f' }, t("buttons.submit")))));
|
|
36
36
|
}
|
|
37
37
|
static get style() { return fullProfileCss; }
|
|
38
38
|
}, [768, "u-full-profile", {
|
|
@@ -1,18 +1,20 @@
|
|
|
1
|
-
import { proxyCustomElement,
|
|
1
|
+
import { proxyCustomElement, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { i as Auth, g as getUnidyClient } from './index2.js';
|
|
3
|
-
import { b as authStoreOnChange, s as state } from './auth-store.js';
|
|
4
|
-
import { u as unidyState } from './unidy-store.js';
|
|
5
3
|
import { t } from './i18n.js';
|
|
4
|
+
import { U as UnidyComponent } from './component.js';
|
|
5
|
+
import { H as HasSlotContent } from './has-slot-content.js';
|
|
6
|
+
import { s as slotFallbackText } from './component-utils.js';
|
|
7
|
+
import { r as redirectWithToken } from './redirect-with-token.js';
|
|
8
|
+
import { s as state } from './auth-store.js';
|
|
6
9
|
import { d as defineCustomElement$2 } from './spinner.js';
|
|
7
10
|
|
|
8
|
-
const JumpToService = /*@__PURE__*/ proxyCustomElement(class JumpToService extends
|
|
11
|
+
const JumpToService = /*@__PURE__*/ proxyCustomElement(class JumpToService extends UnidyComponent(HasSlotContent) {
|
|
9
12
|
constructor(registerHost) {
|
|
10
13
|
super();
|
|
11
14
|
if (registerHost !== false) {
|
|
12
15
|
this.__registerHost();
|
|
13
16
|
}
|
|
14
17
|
}
|
|
15
|
-
get el() { return this; }
|
|
16
18
|
/**
|
|
17
19
|
* The OAuth Application ID (service ID) to jump to.
|
|
18
20
|
* @example "2"
|
|
@@ -42,18 +44,6 @@ const JumpToService = /*@__PURE__*/ proxyCustomElement(class JumpToService exten
|
|
|
42
44
|
*/
|
|
43
45
|
skipOauthAuthorization = false;
|
|
44
46
|
loading = false;
|
|
45
|
-
// TODO: Figure out a way to share this across components
|
|
46
|
-
unsubscribe;
|
|
47
|
-
connectedCallback() {
|
|
48
|
-
this.unsubscribe = authStoreOnChange("authenticated", () => {
|
|
49
|
-
forceUpdate(this);
|
|
50
|
-
});
|
|
51
|
-
}
|
|
52
|
-
disconnectedCallback() {
|
|
53
|
-
if (this.unsubscribe) {
|
|
54
|
-
this.unsubscribe();
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
47
|
handleClick = async (event) => {
|
|
58
48
|
event.preventDefault();
|
|
59
49
|
if (!this.serviceId) {
|
|
@@ -61,21 +51,19 @@ const JumpToService = /*@__PURE__*/ proxyCustomElement(class JumpToService exten
|
|
|
61
51
|
return;
|
|
62
52
|
}
|
|
63
53
|
const auth = await Auth.getInstance();
|
|
64
|
-
|
|
65
|
-
if (!isAuthenticated) {
|
|
54
|
+
if (!(await auth.isAuthenticated())) {
|
|
66
55
|
console.error("[u-jump-to-service] User is not authenticated. Please log in first.");
|
|
67
56
|
return;
|
|
68
57
|
}
|
|
69
58
|
const userData = await auth.userData();
|
|
70
|
-
if (!userData
|
|
59
|
+
if (!userData?.email) {
|
|
71
60
|
console.error("Failed to get user email from authentication token");
|
|
72
61
|
return;
|
|
73
62
|
}
|
|
74
63
|
this.loading = true;
|
|
75
64
|
try {
|
|
76
65
|
const client = getUnidyClient();
|
|
77
|
-
|
|
78
|
-
const scopesArray = this.scopes ? this.scopes.split(",").map((s) => s.trim()) : undefined;
|
|
66
|
+
const scopesArray = this.scopes?.split(",").map((s) => s.trim());
|
|
79
67
|
const [error, token] = await client.auth.jumpToService(this.serviceId, {
|
|
80
68
|
email: userData.email,
|
|
81
69
|
redirect_uri: this.redirectUri,
|
|
@@ -84,22 +72,13 @@ const JumpToService = /*@__PURE__*/ proxyCustomElement(class JumpToService exten
|
|
|
84
72
|
});
|
|
85
73
|
if (error) {
|
|
86
74
|
console.error("Failed to get jump token:", error);
|
|
87
|
-
this.loading = false;
|
|
88
75
|
return;
|
|
89
76
|
}
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
}
|
|
96
|
-
const finalUrl = redirectUrl.toString();
|
|
97
|
-
if (this.newtab) {
|
|
98
|
-
window.open(finalUrl, "_blank");
|
|
99
|
-
}
|
|
100
|
-
else {
|
|
101
|
-
window.location.href = finalUrl;
|
|
102
|
-
}
|
|
77
|
+
redirectWithToken({
|
|
78
|
+
token: token,
|
|
79
|
+
newTab: this.newtab,
|
|
80
|
+
extraParams: this.redirectUri ? { redirect_uri: this.redirectUri } : undefined,
|
|
81
|
+
});
|
|
103
82
|
}
|
|
104
83
|
catch (error) {
|
|
105
84
|
console.error("Error jumping to service:", error);
|
|
@@ -112,8 +91,7 @@ const JumpToService = /*@__PURE__*/ proxyCustomElement(class JumpToService exten
|
|
|
112
91
|
return !state.authenticated || this.loading || !this.serviceId;
|
|
113
92
|
}
|
|
114
93
|
render() {
|
|
115
|
-
|
|
116
|
-
return (h("button", { key: '3f0526c3a12b73cada7b044dfe55fd74757031cf', type: "button", disabled: this.isDisabled(), class: this.componentClassName, onClick: this.handleClick, "aria-live": "polite" }, this.loading ? h("u-spinner", null) : hasSlot ? h("slot", null) : t("buttons.jump_to_service")));
|
|
94
|
+
return (h("button", { key: 'dc593d260c7b74bbfa108c1201b02c1ed7a414c0', type: "button", disabled: this.isDisabled(), class: this.componentClassName, onClick: this.handleClick, "aria-live": "polite" }, slotFallbackText(t("buttons.jump_to_service"), { hasSlot: this.hasSlot, loading: this.loading })));
|
|
117
95
|
}
|
|
118
96
|
}, [772, "u-jump-to-service", {
|
|
119
97
|
"serviceId": [1, "service-id"],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"u-jump-to-service.js","mappings":"
|
|
1
|
+
{"file":"u-jump-to-service.js","mappings":";;;;;;;;;;AAca,MAAA,aAAc,iBAAAA,kBAAA,CAAA,MAAA,aAAA,SAAQ,cAAc,CAAC,cAAc,CAAC,CAAA;;;;;;;AAC/D;;;AAGG;AACgC,IAAA,SAAS;AAE5C;;AAEG;IACK,MAAM,GAAG,KAAK;AAEtB;;AAEG;IACgC,kBAAkB,GAAG,EAAE;AAE1D;;;AAGG;AACkC,IAAA,WAAW;AAEhD;;;;AAIG;AACK,IAAA,MAAM;AAEd;;AAEG;IAC8C,sBAAsB,GAAG,KAAK;IAEtE,OAAO,GAAG,KAAK;AAEhB,IAAA,WAAW,GAAG,OAAO,K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,WAAW,EAAE,IAAI,CAAC,WAAW,GAAG,EAAE,YAAY,EAAE,IAAI,CAAC,WAAW,EAAE,GAAG,SAAS;AAC/E,aAAA,CAAC;;QACF,OAAO,KAAK,EAAE;AACd,YAAA,OAAO,CAAC,KAAK,CAAC,2BAA2B,EAAE,KAAK,CAAC;;gBACzC;AACR,YAAA,IAAI,CAAC,OAAO,GAAG,KAAK;;AAExB,KAAC;IAEO,UAAU,GAAA;AAChB,QAAA,OAAO,CAACC,KAAS,CAAC,aAAa,IAAI,IAAI,CAAC,OAAO,IAAI,CAAC,IAAI,CAAC,SAAS;;IAGpE,MAAM,GAAA;AACJ,QAAA,QACE,+DAAQ,IAAI,EAAC,QAAQ,EAAC,QAAQ,EAAE,IAAI,CAAC,UAAU,EAAE,EAAE,KAAK,EAAE,IAAI,CAAC,kBAAkB,EAAE,OAAO,EAAE,IAAI,CAAC,WAAW,EAAA,WAAA,EAAY,QAAQ,EAC7H,EAAA,gBAAgB,CAAC,CAAC,CAAC,yBAAyB,CAAC,EAAE,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,CAAC,CAC1F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement","authState"],"sources":["src/auth/components/jump-to-service/jump-to-service.tsx"],"sourcesContent":["import { Component, h, Prop, State } from \"@stencil/core\";\nimport { getUnidyClient } from \"../../../api\";\nimport { t } from \"../../../i18n\";\nimport { UnidyComponent } from \"../../../shared/base/component\";\nimport { HasSlotContent } from \"../../../shared/base/has-slot-content\";\nimport { slotFallbackText } from \"../../../shared/component-utils\";\nimport { redirectWithToken } from \"../../../shared/utils/redirect-with-token\";\nimport { Auth } from \"../../auth\";\nimport { authState } from \"../../store/auth-store\";\n\n@Component({\n tag: \"u-jump-to-service\",\n shadow: false,\n})\nexport class JumpToService extends UnidyComponent(HasSlotContent) {\n /**\n * The OAuth Application ID (service ID) to jump to.\n * @example \"2\"\n */\n @Prop({ attribute: \"service-id\" }) serviceId!: string;\n\n /**\n * If true, opens the URL in a new tab. Defaults to false.\n */\n @Prop() newtab = false;\n\n /**\n * Custom CSS class name(s) to apply to the button element.\n */\n @Prop({ attribute: \"class-name\" }) componentClassName = \"\";\n\n /**\n * Optional redirect URI for the OAuth flow.\n * Must match one of the application's allowed redirect URIs.\n */\n @Prop({ attribute: \"redirect-uri\" }) redirectUri?: string;\n\n /**\n * Comma-separated list of OAuth scopes to request.\n * Defaults to [\"openid\"] if not provided.\n * @example \"openid,profile\"\n */\n @Prop() scopes?: string;\n\n /**\n * If true, skips the OAuth authorization step (if already authorized once). Defaults to false.\n */\n @Prop({ attribute: \"skip-oauth-authorization\" }) skipOauthAuthorization = false;\n\n @State() loading = false;\n\n private handleClick = async (event: Event) => {\n event.preventDefault();\n\n if (!this.serviceId) {\n console.error(\"[u-jump-to-service] service-id is required\");\n return;\n }\n\n const auth = await Auth.getInstance();\n if (!(await auth.isAuthenticated())) {\n console.error(\"[u-jump-to-service] User is not authenticated. Please log in first.\");\n return;\n }\n\n const userData = await auth.userData();\n if (!userData?.email) {\n console.error(\"Failed to get user email from authentication token\");\n return;\n }\n\n this.loading = true;\n\n try {\n const client = getUnidyClient();\n const scopesArray = this.scopes?.split(\",\").map((s) => s.trim());\n\n const [error, token] = await client.auth.jumpToService(this.serviceId, {\n email: userData.email,\n redirect_uri: this.redirectUri,\n scopes: scopesArray,\n skip_oauth_authorization: this.skipOauthAuthorization,\n });\n\n if (error) {\n console.error(\"Failed to get jump token:\", error);\n return;\n }\n\n redirectWithToken({\n token: token as string,\n newTab: this.newtab,\n extraParams: this.redirectUri ? { redirect_uri: this.redirectUri } : undefined,\n });\n } catch (error) {\n console.error(\"Error jumping to service:\", error);\n } finally {\n this.loading = false;\n }\n };\n\n private isDisabled(): boolean {\n return !authState.authenticated || this.loading || !this.serviceId;\n }\n\n render() {\n return (\n <button type=\"button\" disabled={this.isDisabled()} class={this.componentClassName} onClick={this.handleClick} aria-live=\"polite\">\n {slotFallbackText(t(\"buttons.jump_to_service\"), { hasSlot: this.hasSlot, loading: this.loading })}\n </button>\n );\n }\n}\n"],"version":3}
|
|
@@ -1,18 +1,21 @@
|
|
|
1
|
-
import { proxyCustomElement,
|
|
1
|
+
import { proxyCustomElement, h } from '@stencil/core/internal/client';
|
|
2
2
|
import { i as Auth, g as getUnidyClient } from './index2.js';
|
|
3
|
-
import { b as authStoreOnChange, s as state } from './auth-store.js';
|
|
4
|
-
import { u as unidyState } from './unidy-store.js';
|
|
5
3
|
import { t } from './i18n.js';
|
|
4
|
+
import { U as UnidyComponent } from './component.js';
|
|
5
|
+
import { H as HasSlotContent } from './has-slot-content.js';
|
|
6
|
+
import { s as slotFallbackText } from './component-utils.js';
|
|
7
|
+
import { u as unidyState } from './unidy-store.js';
|
|
8
|
+
import { r as redirectWithToken } from './redirect-with-token.js';
|
|
9
|
+
import { s as state } from './auth-store.js';
|
|
6
10
|
import { d as defineCustomElement$2 } from './spinner.js';
|
|
7
11
|
|
|
8
|
-
const JumpToUnidy = /*@__PURE__*/ proxyCustomElement(class JumpToUnidy extends
|
|
12
|
+
const JumpToUnidy = /*@__PURE__*/ proxyCustomElement(class JumpToUnidy extends UnidyComponent(HasSlotContent) {
|
|
9
13
|
constructor(registerHost) {
|
|
10
14
|
super();
|
|
11
15
|
if (registerHost !== false) {
|
|
12
16
|
this.__registerHost();
|
|
13
17
|
}
|
|
14
18
|
}
|
|
15
|
-
get el() { return this; }
|
|
16
19
|
/**
|
|
17
20
|
* The Unidy path to redirect to. Must start with "/".
|
|
18
21
|
* @example "/subscriptions"
|
|
@@ -33,11 +36,6 @@ const JumpToUnidy = /*@__PURE__*/ proxyCustomElement(class JumpToUnidy extends H
|
|
|
33
36
|
*/
|
|
34
37
|
componentClassName = "";
|
|
35
38
|
loading = false;
|
|
36
|
-
unsubscribe;
|
|
37
|
-
/**
|
|
38
|
-
* Validates that the path prop is valid (not empty and starts with "/").
|
|
39
|
-
* @returns true if path is valid, false otherwise
|
|
40
|
-
*/
|
|
41
39
|
isValidPath() {
|
|
42
40
|
return !!this.path && this.path.startsWith("/");
|
|
43
41
|
}
|
|
@@ -46,17 +44,6 @@ const JumpToUnidy = /*@__PURE__*/ proxyCustomElement(class JumpToUnidy extends H
|
|
|
46
44
|
console.error(`[u-jump-to-unidy] Invalid path prop: "${this.path}". Path must be provided and start with "/".`);
|
|
47
45
|
}
|
|
48
46
|
}
|
|
49
|
-
// TODO: Figure out a way to share this across components
|
|
50
|
-
connectedCallback() {
|
|
51
|
-
this.unsubscribe = authStoreOnChange("authenticated", () => {
|
|
52
|
-
forceUpdate(this);
|
|
53
|
-
});
|
|
54
|
-
}
|
|
55
|
-
disconnectedCallback() {
|
|
56
|
-
if (this.unsubscribe) {
|
|
57
|
-
this.unsubscribe();
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
47
|
handleClick = async (event) => {
|
|
61
48
|
event.preventDefault();
|
|
62
49
|
if (!this.isValidPath()) {
|
|
@@ -75,13 +62,12 @@ const JumpToUnidy = /*@__PURE__*/ proxyCustomElement(class JumpToUnidy extends H
|
|
|
75
62
|
return;
|
|
76
63
|
}
|
|
77
64
|
const auth = await Auth.getInstance();
|
|
78
|
-
|
|
79
|
-
if (!isAuthenticated) {
|
|
65
|
+
if (!(await auth.isAuthenticated())) {
|
|
80
66
|
console.error("[u-jump-to-unidy] User is not authenticated. Please log in first.");
|
|
81
67
|
return;
|
|
82
68
|
}
|
|
83
69
|
const userData = await auth.userData();
|
|
84
|
-
if (!userData
|
|
70
|
+
if (!userData?.email) {
|
|
85
71
|
console.error("Failed to get user email from authentication token");
|
|
86
72
|
return;
|
|
87
73
|
}
|
|
@@ -94,19 +80,13 @@ const JumpToUnidy = /*@__PURE__*/ proxyCustomElement(class JumpToUnidy extends H
|
|
|
94
80
|
});
|
|
95
81
|
if (error) {
|
|
96
82
|
console.error("Failed to get jump token:", error);
|
|
97
|
-
this.loading = false;
|
|
98
83
|
return;
|
|
99
84
|
}
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
window.open(finalUrl, "_blank");
|
|
106
|
-
}
|
|
107
|
-
else {
|
|
108
|
-
window.location.href = finalUrl;
|
|
109
|
-
}
|
|
85
|
+
redirectWithToken({
|
|
86
|
+
// @ts-expect-error - TOKEN IS A STRING, BUT we need to enable strict for it to work
|
|
87
|
+
token,
|
|
88
|
+
newTab: this.newtab,
|
|
89
|
+
});
|
|
110
90
|
}
|
|
111
91
|
catch (error) {
|
|
112
92
|
console.error("Error jumping to Unidy:", error);
|
|
@@ -122,8 +102,7 @@ const JumpToUnidy = /*@__PURE__*/ proxyCustomElement(class JumpToUnidy extends H
|
|
|
122
102
|
return !state.authenticated || this.loading || !this.isValidPath();
|
|
123
103
|
}
|
|
124
104
|
render() {
|
|
125
|
-
|
|
126
|
-
return (h("button", { key: 'bcf35a95e8ea304da27320e6f4406dd57e94aaf7', type: "button", disabled: this.isDisabled(), class: this.componentClassName, onClick: this.handleClick, "aria-live": "polite" }, this.loading ? h("u-spinner", null) : hasSlot ? h("slot", null) : t("buttons.jump_to_unidy")));
|
|
105
|
+
return (h("button", { key: 'b5747e752d731be9281f82ca0487841ee7baf2d3', type: "button", disabled: this.isDisabled(), class: this.componentClassName, onClick: this.handleClick, "aria-live": "polite" }, slotFallbackText(t("buttons.jump_to_unidy"), { hasSlot: this.hasSlot, loading: this.loading })));
|
|
127
106
|
}
|
|
128
107
|
}, [772, "u-jump-to-unidy", {
|
|
129
108
|
"path": [1],
|