@saasquatch/mint-components 1.6.2-3 → 1.6.2-6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{esm/useValidationState-34e24357.js → cjs/AsYouType-6788393a.js} +2 -10
- package/dist/cjs/{ShadowViewAddon-1c9ca20c.js → ShadowViewAddon-33ae7c4f.js} +13 -6
- package/dist/cjs/{global-58e5d657.js → global-b3587dc9.js} +1 -1
- package/dist/cjs/{index.module-7eab8006.js → index.module-ff45cbf1.js} +2 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/mint-components.cjs.js +2 -2
- package/dist/cjs/{re-render-111a3ebb.js → re-render-e5491a50.js} +1 -1
- package/dist/cjs/sqm-asset-card.cjs.entry.js +1 -1
- package/dist/cjs/sqm-big-stat_35.cjs.entry.js +19 -16
- package/dist/cjs/sqm-graphql-client-provider.cjs.entry.js +1 -1
- package/dist/cjs/sqm-leaderboard-rank.cjs.entry.js +2 -2
- package/dist/cjs/{sqm-navigation-sidebar-item-view-6020bdf9.js → sqm-navigation-sidebar-item-view-e8f500f9.js} +1 -1
- package/dist/cjs/sqm-navigation-sidebar-item.cjs.entry.js +2 -2
- package/dist/cjs/sqm-password-field.cjs.entry.js +13 -7
- package/dist/cjs/sqm-popup-container.cjs.entry.js +1 -1
- package/dist/cjs/{sqm-portal-email-verification-view-eebe6329.js → sqm-portal-email-verification-view-dd27bba3.js} +1 -1
- package/dist/cjs/sqm-portal-email-verification.cjs.entry.js +3 -3
- package/dist/cjs/{sqm-portal-footer-view-531c12fe.js → sqm-portal-footer-view-93f8ec0e.js} +1 -1
- package/dist/cjs/sqm-portal-footer.cjs.entry.js +3 -3
- package/dist/cjs/sqm-portal-forgot-password.cjs.entry.js +1 -1
- package/dist/cjs/sqm-portal-logout.cjs.entry.js +1 -1
- package/dist/cjs/{sqm-portal-profile-view-d0818828.js → sqm-portal-profile-view-f9104d25.js} +1 -1
- package/dist/cjs/sqm-portal-profile.cjs.entry.js +4 -4
- package/dist/cjs/sqm-portal-protected-route.cjs.entry.js +1 -1
- package/dist/cjs/sqm-portal-registration-form.cjs.entry.js +70 -23
- package/dist/cjs/sqm-portal-reset-password.cjs.entry.js +1 -1
- package/dist/cjs/sqm-portal-verify-email.cjs.entry.js +1 -2
- package/dist/cjs/sqm-qa-tabs.cjs.entry.js +2 -2
- package/dist/cjs/sqm-referral-table_11.cjs.entry.js +5 -5
- package/dist/cjs/sqm-rewards-table-customer-note-column.cjs.entry.js +2 -2
- package/dist/cjs/sqm-rewards-table_9.cjs.entry.js +5 -5
- package/dist/cjs/sqm-stencilbook.cjs.entry.js +11 -8
- package/dist/cjs/sqm-tabs.cjs.entry.js +2 -2
- package/dist/cjs/{useChildElements-3a4087c1.js → useChildElements-658fefa1.js} +1 -1
- package/dist/cjs/{useReferralTable-a04fa0e5.js → useReferralTable-ae05b785.js} +3 -3
- package/dist/cjs/useRegistrationFormState-793a7958.js +23 -0
- package/dist/collection/components/sqm-name-fields/sqm-name-fields-view.js +9 -2
- package/dist/collection/components/sqm-name-fields/sqm-name-fields.js +1 -1
- package/dist/collection/components/sqm-name-fields/useNameFields.js +3 -0
- package/dist/collection/components/sqm-password-field/PasswordField.stories.js +3 -0
- package/dist/collection/components/sqm-password-field/sqm-password-field-view.js +7 -4
- package/dist/collection/components/sqm-password-field/sqm-password-field.js +1 -0
- package/dist/collection/components/sqm-password-field/usePasswordField.js +5 -2
- package/dist/collection/components/sqm-portal-registration-form/sqm-portal-registration-form-view.js +16 -9
- package/dist/collection/components/sqm-portal-registration-form/sqm-portal-registration-form.js +1 -1
- package/dist/collection/components/sqm-portal-registration-form/usePortalRegistrationForm.js +52 -11
- package/dist/collection/components/sqm-portal-registration-form/useRegistrationFormState.js +8 -0
- package/dist/collection/components/sqm-portal-verify-email/usePortalVerifyEmail.js +0 -1
- package/dist/{cjs/useValidationState-942d11da.js → esm/AsYouType-46f67d0d.js} +1 -15
- package/dist/esm/{ShadowViewAddon-77643eb3.js → ShadowViewAddon-7d94f9d6.js} +13 -6
- package/dist/esm/{global-79d68d1f.js → global-1e714a4d.js} +1 -1
- package/dist/esm/{index.module-8e654eb1.js → index.module-9cd4623b.js} +2 -2
- package/dist/esm/loader.js +2 -2
- package/dist/esm/mint-components.js +2 -2
- package/dist/esm/{re-render-cd65b629.js → re-render-d1b2a0de.js} +1 -1
- package/dist/esm/sqm-asset-card.entry.js +1 -1
- package/dist/esm/sqm-big-stat_35.entry.js +13 -10
- package/dist/esm/sqm-graphql-client-provider.entry.js +1 -1
- package/dist/esm/sqm-leaderboard-rank.entry.js +2 -2
- package/dist/esm/{sqm-navigation-sidebar-item-view-52b5e3b9.js → sqm-navigation-sidebar-item-view-7e6199c2.js} +1 -1
- package/dist/esm/sqm-navigation-sidebar-item.entry.js +2 -2
- package/dist/esm/sqm-password-field.entry.js +13 -7
- package/dist/esm/sqm-popup-container.entry.js +1 -1
- package/dist/esm/{sqm-portal-email-verification-view-7dafea6c.js → sqm-portal-email-verification-view-ba08318b.js} +1 -1
- package/dist/esm/sqm-portal-email-verification.entry.js +3 -3
- package/dist/esm/{sqm-portal-footer-view-a857dd94.js → sqm-portal-footer-view-9bfd61b4.js} +1 -1
- package/dist/esm/sqm-portal-footer.entry.js +3 -3
- package/dist/esm/sqm-portal-forgot-password.entry.js +1 -1
- package/dist/esm/sqm-portal-logout.entry.js +1 -1
- package/dist/esm/{sqm-portal-profile-view-785773e9.js → sqm-portal-profile-view-0f8dd14f.js} +1 -1
- package/dist/esm/sqm-portal-profile.entry.js +4 -4
- package/dist/esm/sqm-portal-protected-route.entry.js +1 -1
- package/dist/esm/sqm-portal-registration-form.entry.js +68 -21
- package/dist/esm/sqm-portal-reset-password.entry.js +1 -1
- package/dist/esm/sqm-portal-verify-email.entry.js +1 -2
- package/dist/esm/sqm-qa-tabs.entry.js +2 -2
- package/dist/esm/sqm-referral-table_11.entry.js +5 -5
- package/dist/esm/sqm-rewards-table-customer-note-column.entry.js +2 -2
- package/dist/esm/sqm-rewards-table_9.entry.js +5 -5
- package/dist/esm/sqm-stencilbook.entry.js +11 -8
- package/dist/esm/sqm-tabs.entry.js +2 -2
- package/dist/esm/{useChildElements-5a1262d5.js → useChildElements-e1a1d3d1.js} +1 -1
- package/dist/esm/{useReferralTable-6c14c78f.js → useReferralTable-68c0823f.js} +3 -3
- package/dist/esm/useRegistrationFormState-699c3e59.js +18 -0
- package/dist/esm-es5/AsYouType-46f67d0d.js +1 -0
- package/dist/esm-es5/{ShadowViewAddon-77643eb3.js → ShadowViewAddon-7d94f9d6.js} +1 -1
- package/dist/esm-es5/{global-79d68d1f.js → global-1e714a4d.js} +1 -1
- package/dist/esm-es5/{index.module-8e654eb1.js → index.module-9cd4623b.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/mint-components.js +1 -1
- package/dist/esm-es5/{re-render-cd65b629.js → re-render-d1b2a0de.js} +1 -1
- package/dist/esm-es5/sqm-asset-card.entry.js +1 -1
- package/dist/esm-es5/sqm-big-stat_35.entry.js +1 -1
- package/dist/esm-es5/sqm-graphql-client-provider.entry.js +1 -1
- package/dist/esm-es5/sqm-leaderboard-rank.entry.js +1 -1
- package/dist/esm-es5/sqm-navigation-sidebar-item-view-7e6199c2.js +1 -0
- package/dist/esm-es5/sqm-navigation-sidebar-item.entry.js +1 -1
- package/dist/esm-es5/sqm-password-field.entry.js +1 -1
- package/dist/esm-es5/sqm-popup-container.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-email-verification-view-7dafea6c.js → sqm-portal-email-verification-view-ba08318b.js} +1 -1
- package/dist/esm-es5/sqm-portal-email-verification.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-footer-view-a857dd94.js → sqm-portal-footer-view-9bfd61b4.js} +1 -1
- package/dist/esm-es5/sqm-portal-footer.entry.js +1 -1
- package/dist/esm-es5/sqm-portal-forgot-password.entry.js +1 -1
- package/dist/esm-es5/sqm-portal-logout.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-profile-view-785773e9.js → sqm-portal-profile-view-0f8dd14f.js} +1 -1
- package/dist/esm-es5/sqm-portal-profile.entry.js +1 -1
- package/dist/esm-es5/sqm-portal-protected-route.entry.js +1 -1
- package/dist/esm-es5/sqm-portal-registration-form.entry.js +1 -1
- package/dist/esm-es5/sqm-portal-reset-password.entry.js +1 -1
- package/dist/esm-es5/sqm-portal-verify-email.entry.js +1 -1
- package/dist/esm-es5/sqm-qa-tabs.entry.js +1 -1
- package/dist/esm-es5/sqm-referral-table_11.entry.js +1 -1
- package/dist/esm-es5/sqm-rewards-table-customer-note-column.entry.js +1 -1
- package/dist/esm-es5/sqm-rewards-table_9.entry.js +1 -1
- package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
- package/dist/esm-es5/sqm-tabs.entry.js +1 -1
- package/dist/esm-es5/{useChildElements-5a1262d5.js → useChildElements-e1a1d3d1.js} +1 -1
- package/dist/esm-es5/{useReferralTable-6c14c78f.js → useReferralTable-68c0823f.js} +1 -1
- package/dist/esm-es5/useRegistrationFormState-699c3e59.js +1 -0
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/mint-components.js +1 -1
- package/dist/mint-components/{p-d5be4f5e.entry.js → p-02e2eab4.entry.js} +2 -2
- package/dist/mint-components/{p-4b34c8b6.system.js → p-07b33645.system.js} +1 -1
- package/dist/mint-components/{p-dc2120a9.entry.js → p-08401205.entry.js} +2 -2
- package/dist/mint-components/p-08fc37fd.system.entry.js +1 -0
- package/dist/mint-components/{p-4cdef37c.system.entry.js → p-10fb0aae.system.entry.js} +1 -1
- package/dist/mint-components/{p-72435015.entry.js → p-1127f297.entry.js} +2 -2
- package/dist/mint-components/p-121cdc60.js +1 -0
- package/dist/mint-components/{p-2db3e574.entry.js → p-17aae439.entry.js} +1 -1
- package/dist/mint-components/{p-cd4ae408.system.entry.js → p-190e24e4.system.entry.js} +1 -1
- package/dist/mint-components/{p-1d11d313.entry.js → p-1ea13deb.entry.js} +12 -12
- package/dist/mint-components/{p-af290d9f.entry.js → p-1fed6a09.entry.js} +1 -1
- package/dist/mint-components/p-273b5c53.system.entry.js +1 -0
- package/dist/mint-components/{p-ad04fd37.js → p-2920efe6.js} +1 -1
- package/dist/mint-components/p-2ce5d3da.js +1 -0
- package/dist/mint-components/p-2d2f7abb.system.entry.js +1 -0
- package/dist/mint-components/{p-fd2e16a3.system.entry.js → p-2de1fadb.system.entry.js} +1 -1
- package/dist/mint-components/{p-b7b610d9.entry.js → p-32f481cb.entry.js} +1 -1
- package/dist/mint-components/{p-cbe1f72a.system.entry.js → p-33910ee5.system.entry.js} +1 -1
- package/dist/mint-components/{p-0049fc60.entry.js → p-36d50757.entry.js} +1 -1
- package/dist/mint-components/p-3fddd002.system.js +1 -0
- package/dist/mint-components/{p-201076d0.system.js → p-40c4165b.system.js} +1 -1
- package/dist/mint-components/{p-4587520e.entry.js → p-4f10205f.entry.js} +1 -1
- package/dist/mint-components/{p-60ae6839.js → p-4f965abe.js} +2 -2
- package/dist/mint-components/{p-0c6077a8.system.entry.js → p-4fdd8b02.system.entry.js} +1 -1
- package/dist/mint-components/{p-250e8ca9.system.entry.js → p-5337c953.system.entry.js} +1 -1
- package/dist/mint-components/p-56bf2c06.system.js +1 -0
- package/dist/mint-components/p-5c347c93.system.entry.js +1 -0
- package/dist/mint-components/{p-cfce9e5c.entry.js → p-5c7c925e.entry.js} +1 -1
- package/dist/mint-components/{p-f79a103c.system.entry.js → p-5d7de7cd.system.entry.js} +1 -1
- package/dist/mint-components/p-5ef24d6c.system.entry.js +1 -0
- package/dist/mint-components/p-69871506.js +1 -0
- package/dist/mint-components/{p-7ba78151.js → p-6c05b2d3.js} +1 -1
- package/dist/mint-components/{p-20f0c0cc.system.js → p-7536759d.system.js} +1 -1
- package/dist/mint-components/{p-c7eaa296.system.entry.js → p-75e425fa.system.entry.js} +1 -1
- package/dist/mint-components/{p-fb8715c9.system.entry.js → p-771b778b.system.entry.js} +1 -1
- package/dist/mint-components/{p-da02c4e6.system.js → p-78c568dc.system.js} +1 -1
- package/dist/mint-components/{p-b2ad0a75.system.entry.js → p-7eb9955b.system.entry.js} +1 -1
- package/dist/mint-components/{p-d8c1aa2f.entry.js → p-91cde020.entry.js} +1 -1
- package/dist/mint-components/p-92e8b7b5.entry.js +1 -0
- package/dist/mint-components/p-9d362d44.system.js +1 -0
- package/dist/mint-components/{p-5aedc3a5.system.js → p-9dd68a9c.system.js} +1 -1
- package/dist/mint-components/{p-45d161fe.entry.js → p-a16556fd.entry.js} +1 -1
- package/dist/mint-components/{p-4e89da81.js → p-a63204e2.js} +1 -1
- package/dist/mint-components/{p-5f2d84e2.js → p-a6bfbb4e.js} +2 -2
- package/dist/mint-components/{p-bdf8f103.js → p-a750f034.js} +1 -1
- package/dist/mint-components/p-a963e9d5.entry.js +9 -0
- package/dist/mint-components/{p-d3c61681.system.js → p-ab7ae098.system.js} +1 -1
- package/dist/mint-components/{p-12b08957.js → p-abc426c4.js} +1 -1
- package/dist/mint-components/p-abffc249.entry.js +13 -0
- package/dist/mint-components/p-ad67b111.system.entry.js +1 -0
- package/dist/mint-components/{p-72dd2010.system.entry.js → p-b5faa04d.system.entry.js} +1 -1
- package/dist/mint-components/{p-986000f9.system.entry.js → p-b7fc1ee1.system.entry.js} +1 -1
- package/dist/mint-components/{p-c14b8c38.entry.js → p-b96505f5.entry.js} +1 -1
- package/dist/mint-components/{p-27557cc8.entry.js → p-ba09e62f.entry.js} +1 -1
- package/dist/mint-components/{p-36ff7a62.entry.js → p-c911a062.entry.js} +1 -1
- package/dist/mint-components/{p-e647c594.entry.js → p-cbb61c41.entry.js} +1 -1
- package/dist/mint-components/{p-9c58002f.entry.js → p-cdf2914a.entry.js} +1 -1
- package/dist/mint-components/p-ce5a3693.system.js +1 -0
- package/dist/mint-components/{p-1670c8d5.system.entry.js → p-cf279181.system.entry.js} +1 -1
- package/dist/mint-components/{p-a94d07d9.system.js → p-d1712ae1.system.js} +1 -1
- package/dist/mint-components/p-de4f0622.entry.js +1 -0
- package/dist/mint-components/{p-1260d387.entry.js → p-e28f4762.entry.js} +1 -1
- package/dist/mint-components/{p-47aa639f.system.entry.js → p-e9fa325e.system.entry.js} +1 -1
- package/dist/mint-components/p-ec18b601.system.js +1 -0
- package/dist/mint-components/{p-c7514dbd.system.entry.js → p-ecf7bfc7.system.entry.js} +1 -1
- package/dist/mint-components/{p-d8f4703a.js → p-ee0c06b3.js} +1 -1
- package/dist/mint-components/{p-bc796bc0.system.js → p-efbc0ee0.system.js} +1 -1
- package/dist/mint-components/{p-4392ba94.js → p-fc8800c0.js} +1 -1
- package/dist/mint-components/{p-89841802.system.entry.js → p-fdc7e95e.system.entry.js} +1 -1
- package/dist/types/components/sqm-name-fields/sqm-name-fields-view.d.ts +2 -0
- package/dist/types/components/sqm-name-fields/useNameFields.d.ts +2 -0
- package/dist/types/components/sqm-password-field/sqm-password-field-view.d.ts +2 -0
- package/dist/types/components/sqm-password-field/sqm-password-field.d.ts +2 -0
- package/dist/types/components/sqm-portal-registration-form/sqm-portal-registration-form-view.d.ts +2 -0
- package/dist/types/components/sqm-portal-registration-form/usePortalRegistrationForm.d.ts +2 -0
- package/dist/types/components/sqm-portal-registration-form/useRegistrationFormState.d.ts +23 -0
- package/docs/docs.docx +0 -0
- package/package.json +2 -2
- package/dist/esm-es5/sqm-navigation-sidebar-item-view-52b5e3b9.js +0 -1
- package/dist/esm-es5/useValidationState-34e24357.js +0 -1
- package/dist/mint-components/p-00893b1e.system.entry.js +0 -1
- package/dist/mint-components/p-2e827a20.system.entry.js +0 -1
- package/dist/mint-components/p-458416a0.system.js +0 -1
- package/dist/mint-components/p-494c99f7.js +0 -1
- package/dist/mint-components/p-6d0a42f8.system.entry.js +0 -1
- package/dist/mint-components/p-9311fb68.entry.js +0 -1
- package/dist/mint-components/p-955ecee3.system.entry.js +0 -1
- package/dist/mint-components/p-a7895b97.system.entry.js +0 -1
- package/dist/mint-components/p-b670cff3.system.js +0 -1
- package/dist/mint-components/p-c6fc021c.js +0 -1
- package/dist/mint-components/p-c7bc2261.entry.js +0 -9
- package/dist/mint-components/p-d78b809c.system.js +0 -1
- package/dist/mint-components/p-e013289c.entry.js +0 -1
- package/dist/mint-components/p-e2fe2d6f.entry.js +0 -1
- package/dist/mint-components/p-e5d4a15d.system.js +0 -1
- package/dist/mint-components/p-f2efaa41.system.entry.js +0 -1
- package/docs/grapesjs.js +0 -54
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1 } from './index-17b4da69.js';
|
|
2
2
|
import { m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { F as Fn, L } from './index.module-
|
|
4
|
+
import { F as Fn, L } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
7
7
|
import './mixins-f60a614c.js';
|
|
8
8
|
import './JSS-f00f9536.js';
|
|
9
9
|
import { g as getProps } from './utils-334c1e34.js';
|
|
10
|
-
import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-view-
|
|
10
|
+
import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-view-7e6199c2.js';
|
|
11
11
|
|
|
12
12
|
function useNavigationSidebarItem(props) {
|
|
13
13
|
const currentPage = Fn();
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { h, r as registerInstance } from './index-17b4da69.js';
|
|
2
2
|
import { o as d, i as useState, m as h$1 } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { L } from './index.module-
|
|
4
|
+
import { L } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
7
7
|
import { E as ErrorStyles } from './mixins-f60a614c.js';
|
|
8
8
|
import { c as createStyleSheet } from './JSS-f00f9536.js';
|
|
9
|
+
import { F as FORM_VALIDATION_CONTEXT, R as REGISTRATION_FORM_STATE_CONTEXT } from './useRegistrationFormState-699c3e59.js';
|
|
9
10
|
|
|
10
11
|
var constants = {
|
|
11
12
|
error: {
|
|
@@ -483,27 +484,30 @@ const vanillaStyle = `
|
|
|
483
484
|
const sheet$1 = createStyleSheet(style$1);
|
|
484
485
|
const styleString$1 = sheet$1.toString();
|
|
485
486
|
function PortalResetPasswordView(props) {
|
|
486
|
-
var _a, _b;
|
|
487
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
487
488
|
const { states, callbacks } = props;
|
|
488
489
|
return (h("div", { class: sheet$1.classes.InputContainer },
|
|
489
490
|
h("style", { type: "text/css" },
|
|
490
491
|
vanillaStyle,
|
|
491
492
|
styleString$1),
|
|
492
|
-
h("sl-input", Object.assign({ exportparts: "label: input-label", type: "password", name: "/password", label: states.content.fieldLabel || "Password", required: true, validationError: ({ value }) => {
|
|
493
|
+
h("sl-input", Object.assign({ exportparts: "label: input-label", type: "password", name: "/password", label: states.content.fieldLabel || "Password", required: true, disabled: ((_a = states.registrationFormState) === null || _a === void 0 ? void 0 : _a.loading) || ((_b = states.registrationFormState) === null || _b === void 0 ? void 0 : _b.disabled), validationError: ({ value }) => {
|
|
493
494
|
if (!value) {
|
|
494
495
|
return "Cannot be empty";
|
|
495
496
|
}
|
|
496
|
-
} }, (((
|
|
497
|
+
} }, (((_d = (_c = states.registrationFormState) === null || _c === void 0 ? void 0 : _c.initialData) === null || _d === void 0 ? void 0 : _d.password) ? {
|
|
498
|
+
value: (_f = (_e = states.registrationFormState) === null || _e === void 0 ? void 0 : _e.initialData) === null || _f === void 0 ? void 0 : _f.password,
|
|
499
|
+
}
|
|
500
|
+
: {}), (((_g = states.validationErrors) === null || _g === void 0 ? void 0 : _g.password) ? {
|
|
497
501
|
class: sheet$1.classes.ErrorStyle,
|
|
498
|
-
helpText: ((
|
|
502
|
+
helpText: ((_h = states.validationErrors) === null || _h === void 0 ? void 0 : _h.password) || "Cannot be empty",
|
|
499
503
|
}
|
|
500
504
|
: []), { onInput: (input) => states.enableValidation && callbacks.onInput(input) })),
|
|
501
505
|
states.dynamicValidation));
|
|
502
506
|
}
|
|
503
507
|
|
|
504
|
-
const CONTEXT_NAME = "sq:validation-state";
|
|
505
508
|
function usePasswordField(props) {
|
|
506
|
-
const validationState = d(
|
|
509
|
+
const validationState = d(FORM_VALIDATION_CONTEXT);
|
|
510
|
+
const registrationFormState = d(REGISTRATION_FORM_STATE_CONTEXT);
|
|
507
511
|
const [dynamicValidation, setDynamicValidation] = useState("");
|
|
508
512
|
function onInput(input) {
|
|
509
513
|
const validation = validateNewPassword(input.target.value);
|
|
@@ -513,6 +517,7 @@ function usePasswordField(props) {
|
|
|
513
517
|
states: {
|
|
514
518
|
enableValidation: props.enableValidation,
|
|
515
519
|
dynamicValidation,
|
|
520
|
+
registrationFormState,
|
|
516
521
|
validationErrors: validationState === null || validationState === void 0 ? void 0 : validationState.validationErrors,
|
|
517
522
|
content: {
|
|
518
523
|
fieldLabel: props.fieldLabel,
|
|
@@ -567,6 +572,7 @@ function usePasswordFieldDemo(props) {
|
|
|
567
572
|
enableValidation: true,
|
|
568
573
|
dynamicValidation,
|
|
569
574
|
validationErrors: ((_f = (_e = props === null || props === void 0 ? void 0 : props.demoData) === null || _e === void 0 ? void 0 : _e.states) === null || _f === void 0 ? void 0 : _f.validationErrors) || {},
|
|
575
|
+
registrationFormState: {},
|
|
570
576
|
content: {
|
|
571
577
|
fieldLabel: "Password",
|
|
572
578
|
},
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { h, c as Host, r as registerInstance } from './index-17b4da69.js';
|
|
2
2
|
import { m as h$1 } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { J } from './index.module-
|
|
4
|
+
import { J } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
import { g as getProps } from './utils-334c1e34.js';
|
|
7
7
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from './index-17b4da69.js';
|
|
2
|
-
import { i as intl } from './global-
|
|
2
|
+
import { i as intl } from './global-1e714a4d.js';
|
|
3
3
|
import { A as AuthWrapper, a as AuthColumn } from './mixins-f60a614c.js';
|
|
4
4
|
import { c as createStyleSheet } from './JSS-f00f9536.js';
|
|
5
5
|
import { T as TextSpanView } from './sqm-text-span-view-0ba1484d.js';
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1 } from './index-17b4da69.js';
|
|
2
2
|
import { i as useState, e as useEffect, m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
|
-
import './global-
|
|
3
|
+
import './global-1e714a4d.js';
|
|
4
4
|
import './use-callback-69ec5c5c.js';
|
|
5
|
-
import { v as vn, a as ae, L } from './index.module-
|
|
5
|
+
import { v as vn, a as ae, L } from './index.module-9cd4623b.js';
|
|
6
6
|
import './extends-c31f1eff.js';
|
|
7
7
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
8
8
|
import './mixins-f60a614c.js';
|
|
9
9
|
import './JSS-f00f9536.js';
|
|
10
10
|
import './sqm-text-span-view-0ba1484d.js';
|
|
11
|
-
import { P as PortalEmailVerificationView } from './sqm-portal-email-verification-view-
|
|
11
|
+
import { P as PortalEmailVerificationView } from './sqm-portal-email-verification-view-ba08318b.js';
|
|
12
12
|
|
|
13
13
|
function usePortalEmailVerification(props) {
|
|
14
14
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from './index-17b4da69.js';
|
|
2
|
-
import { i as intl } from './global-
|
|
2
|
+
import { i as intl } from './global-1e714a4d.js';
|
|
3
3
|
import { c as createStyleSheet } from './JSS-f00f9536.js';
|
|
4
4
|
|
|
5
5
|
function PoweredByImg({ color = "#A6A6A6", width = 190, height = 29, }) {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1 } from './index-17b4da69.js';
|
|
2
2
|
import { m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
|
-
import './global-
|
|
3
|
+
import './global-1e714a4d.js';
|
|
4
4
|
import './use-callback-69ec5c5c.js';
|
|
5
|
-
import './index.module-
|
|
5
|
+
import './index.module-9cd4623b.js';
|
|
6
6
|
import './extends-c31f1eff.js';
|
|
7
7
|
import './JSS-f00f9536.js';
|
|
8
8
|
import { g as getProps } from './utils-334c1e34.js';
|
|
9
|
-
import { P as PortalFooterView } from './sqm-portal-footer-view-
|
|
9
|
+
import { P as PortalFooterView } from './sqm-portal-footer-view-9bfd61b4.js';
|
|
10
10
|
|
|
11
11
|
const PortalFooter = class {
|
|
12
12
|
constructor(hostRef) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1 } from './index-17b4da69.js';
|
|
2
2
|
import { i as useState, e as useEffect, m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { f as fn, L, I as In } from './index.module-
|
|
4
|
+
import { f as fn, L, I as In } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
import { j as jsonpointer } from './jsonpointer-388a7082.js';
|
|
7
7
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance } from './index-17b4da69.js';
|
|
2
2
|
import { m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { t as te, I as In, L } from './index.module-
|
|
4
|
+
import { t as te, I as In, L } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
|
|
7
7
|
function usePortalLogout({ nextPage }) {
|
package/dist/esm/{sqm-portal-profile-view-785773e9.js → sqm-portal-profile-view-0f8dd14f.js}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { h } from './index-17b4da69.js';
|
|
2
|
-
import { i as intl } from './global-
|
|
2
|
+
import { i as intl } from './global-1e714a4d.js';
|
|
3
3
|
import { c as createStyleSheet } from './JSS-f00f9536.js';
|
|
4
4
|
import { T as TextSpanView } from './sqm-text-span-view-0ba1484d.js';
|
|
5
5
|
import { P as PortalContainerView } from './sqm-portal-container-view-ca454627.js';
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1 } from './index-17b4da69.js';
|
|
2
2
|
import { i as useState, e as useEffect, m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
|
-
import './global-
|
|
3
|
+
import './global-1e714a4d.js';
|
|
4
4
|
import './use-callback-69ec5c5c.js';
|
|
5
|
-
import { d as dist, a as ae, w as wn,
|
|
5
|
+
import { d as dist, a as ae, w as wn, $ as $e, L } from './index.module-9cd4623b.js';
|
|
6
6
|
import './extends-c31f1eff.js';
|
|
7
7
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
8
8
|
import './JSS-f00f9536.js';
|
|
9
9
|
import { g as getProps } from './utils-334c1e34.js';
|
|
10
10
|
import './sqm-text-span-view-0ba1484d.js';
|
|
11
11
|
import './sqm-portal-container-view-ca454627.js';
|
|
12
|
-
import { P as PortalProfileView } from './sqm-portal-profile-view-
|
|
12
|
+
import { P as PortalProfileView } from './sqm-portal-profile-view-0f8dd14f.js';
|
|
13
13
|
|
|
14
14
|
const GET_USER = dist.gql `
|
|
15
15
|
query {
|
|
@@ -60,7 +60,7 @@ function usePortalProfile(props) {
|
|
|
60
60
|
const [userData, setUserData] = useState(undefined);
|
|
61
61
|
const [formState, setFormState] = useState(defaultFormState);
|
|
62
62
|
const userDataResponse = wn(GET_USER, {}, !(userIdent === null || userIdent === void 0 ? void 0 : userIdent.jwt));
|
|
63
|
-
const [upsertUser, upsertUserResponse] =
|
|
63
|
+
const [upsertUser, upsertUserResponse] = $e(UPSERT_USER);
|
|
64
64
|
useEffect(() => {
|
|
65
65
|
if (upsertUserResponse === null || upsertUserResponse === void 0 ? void 0 : upsertUserResponse.loading)
|
|
66
66
|
return;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1, c as Host } from './index-17b4da69.js';
|
|
2
2
|
import { e as useEffect, m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { a as ae, F as Fn, I as In, L } from './index.module-
|
|
4
|
+
import { a as ae, F as Fn, I as In, L } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
|
|
7
7
|
function usePortalProtectedRoute({ requireEmailVerification, redirectTo, redirectToUnverified, }) {
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { h, r as registerInstance } from './index-17b4da69.js';
|
|
2
2
|
import { j as useRef, e as useEffect, m as h$1 } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import { u as useCallback } from './use-callback-69ec5c5c.js';
|
|
4
|
-
import { W as We, I as In, L } from './index.module-
|
|
4
|
+
import { d as dist, W as We, w as wn, I as In, L } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
import { j as jsonpointer } from './jsonpointer-388a7082.js';
|
|
7
7
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
8
8
|
import { A as AuthWrapper, a as AuthColumn, H as HostBlock, b as AuthButtonsContainer, E as ErrorStyles } from './mixins-f60a614c.js';
|
|
9
9
|
import { c as createStyleSheet } from './JSS-f00f9536.js';
|
|
10
10
|
import { T as TextSpanView } from './sqm-text-span-view-0ba1484d.js';
|
|
11
|
-
import {
|
|
11
|
+
import { A as AsYouType } from './AsYouType-46f67d0d.js';
|
|
12
|
+
import { u as useRegistrationFormState, a as useValidationState } from './useRegistrationFormState-699c3e59.js';
|
|
12
13
|
|
|
13
14
|
const style = {
|
|
14
15
|
Wrapper: { ...AuthWrapper, "max-width": "600px" },
|
|
@@ -39,7 +40,7 @@ sqm-portal-register {
|
|
|
39
40
|
const sheet = createStyleSheet(style);
|
|
40
41
|
const styleString = sheet.toString();
|
|
41
42
|
function PortalRegistrationFormView(props) {
|
|
42
|
-
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
43
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u;
|
|
43
44
|
const { states, refs, callbacks, content } = props;
|
|
44
45
|
if (states.error) {
|
|
45
46
|
window.scrollTo({ top: 0, left: 0, behavior: "smooth" });
|
|
@@ -50,10 +51,11 @@ function PortalRegistrationFormView(props) {
|
|
|
50
51
|
styleString),
|
|
51
52
|
h(TextSpanView, { type: "h3" }, content.pageLabel),
|
|
52
53
|
h("sl-form", { class: sheet.classes.Column, "onSl-submit": callbacks.submit, ref: (el) => (refs.formRef.current = el), novalidate: true },
|
|
53
|
-
states.
|
|
54
|
-
h("div", { part: "erroralert-text" },
|
|
54
|
+
((_a = states.registrationFormState) === null || _a === void 0 ? void 0 : _a.disabled) ? (h("sqm-form-message", { type: "error", exportparts: "erroralert-icon" },
|
|
55
|
+
h("div", { part: "erroralert-text" }, states.registrationFormState.disabledMessage))) : (states.error && (h("sqm-form-message", { type: "error", exportparts: "erroralert-icon" },
|
|
56
|
+
h("div", { part: "erroralert-text" }, props.states.error)))),
|
|
55
57
|
content.formData,
|
|
56
|
-
!states.hideInputs && (h("sl-input", Object.assign({ exportparts: "label: input-label", type: "email", name: "/email", label: content.emailLabel || "Email", disabled: states.loading, required: true, validationError: ({ value }) => {
|
|
58
|
+
!states.hideInputs && (h("sl-input", Object.assign({ exportparts: "label: input-label", type: "email", name: "/email", label: content.emailLabel || "Email", disabled: states.loading || ((_b = states.registrationFormState) === null || _b === void 0 ? void 0 : _b.disabled), required: true, validationError: ({ value }) => {
|
|
57
59
|
if (!value) {
|
|
58
60
|
return "Cannot be empty";
|
|
59
61
|
}
|
|
@@ -61,40 +63,78 @@ function PortalRegistrationFormView(props) {
|
|
|
61
63
|
if (!value.includes("@")) {
|
|
62
64
|
return "Must be a valid email address";
|
|
63
65
|
}
|
|
64
|
-
} }, (((
|
|
66
|
+
} }, (((_d = (_c = states.registrationFormState) === null || _c === void 0 ? void 0 : _c.initialData) === null || _d === void 0 ? void 0 : _d.email) ? {
|
|
67
|
+
value: (_f = (_e = states.registrationFormState) === null || _e === void 0 ? void 0 : _e.initialData) === null || _f === void 0 ? void 0 : _f.email,
|
|
68
|
+
}
|
|
69
|
+
: {}), (((_h = (_g = states.validationState) === null || _g === void 0 ? void 0 : _g.validationErrors) === null || _h === void 0 ? void 0 : _h.email) ? {
|
|
65
70
|
class: sheet.classes.ErrorStyle,
|
|
66
|
-
helpText: ((
|
|
71
|
+
helpText: ((_k = (_j = states.validationState) === null || _j === void 0 ? void 0 : _j.validationErrors) === null || _k === void 0 ? void 0 : _k.email) ||
|
|
67
72
|
"Cannot be empty",
|
|
68
73
|
}
|
|
69
74
|
: [])))),
|
|
70
75
|
!states.hideInputs && (h("sqm-password-field", { fieldLabel: content.passwordLabel, "enable-validation": states.enablePasswordValidation })),
|
|
71
76
|
content.passwordField,
|
|
72
|
-
!states.hideInputs && states.confirmPassword && (h("sl-input", Object.assign({ exportparts: "label: input-label", type: "password", name: "/confirmPassword", label: content.confirmPasswordLabel, disabled: states.loading, required: true }, (((
|
|
77
|
+
!states.hideInputs && states.confirmPassword && (h("sl-input", Object.assign({ exportparts: "label: input-label", type: "password", name: "/confirmPassword", label: content.confirmPasswordLabel, disabled: states.loading, required: true }, (((_m = (_l = states.registrationFormState) === null || _l === void 0 ? void 0 : _l.initialData) === null || _m === void 0 ? void 0 : _m.confirmPassword) ? {
|
|
78
|
+
value: (_p = (_o = states.registrationFormState) === null || _o === void 0 ? void 0 : _o.initialData) === null || _p === void 0 ? void 0 : _p.confirmPassword,
|
|
79
|
+
}
|
|
80
|
+
: {}), (((_r = (_q = states.validationState) === null || _q === void 0 ? void 0 : _q.validationErrors) === null || _r === void 0 ? void 0 : _r.confirmPassword) ? {
|
|
73
81
|
class: sheet.classes.ErrorStyle,
|
|
74
|
-
helpText: ((
|
|
82
|
+
helpText: ((_t = (_s = states.validationState) === null || _s === void 0 ? void 0 : _s.validationErrors) === null || _t === void 0 ? void 0 : _t.confirmPassword) ||
|
|
75
83
|
"Cannot be empty",
|
|
76
84
|
}
|
|
77
85
|
: [])))),
|
|
78
86
|
content.terms,
|
|
79
87
|
h("div", { class: sheet.classes.ButtonsContainer },
|
|
80
|
-
h("sl-button", { submit: true, loading: states.loading, exportparts: "base: primarybutton-base", type: "primary" }, content.submitLabel || "Register"),
|
|
88
|
+
h("sl-button", { submit: true, loading: states.loading, disabled: (_u = states.registrationFormState) === null || _u === void 0 ? void 0 : _u.disabled, exportparts: "base: primarybutton-base", type: "primary" }, content.submitLabel || "Register"),
|
|
81
89
|
content.secondaryButton))));
|
|
82
90
|
}
|
|
83
91
|
|
|
92
|
+
const RegistrationFormQuery = dist.gql `
|
|
93
|
+
query RegistrationFormQuery($key: String!) {
|
|
94
|
+
form(key: $key) {
|
|
95
|
+
key
|
|
96
|
+
type
|
|
97
|
+
initialData {
|
|
98
|
+
initialData
|
|
99
|
+
isEnabled
|
|
100
|
+
isEnabledErrorMessage
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
`;
|
|
84
105
|
function usePortalRegistrationForm(props) {
|
|
85
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
106
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
|
|
86
107
|
const formRef = useRef(null);
|
|
108
|
+
const { registrationFormState, setRegistrationFormState } = useRegistrationFormState({});
|
|
87
109
|
const { validationState, setValidationState } = useValidationState({});
|
|
88
110
|
const [request, { loading, errors, data, formError }] = We();
|
|
111
|
+
const queryResponse = wn(RegistrationFormQuery, { key: props.formKey });
|
|
112
|
+
const formLoading = loading || queryResponse.loading;
|
|
113
|
+
useEffect(() => {
|
|
114
|
+
var _a, _b, _c;
|
|
115
|
+
const initialData = (_a = queryResponse === null || queryResponse === void 0 ? void 0 : queryResponse.data) === null || _a === void 0 ? void 0 : _a.form.initialData.initialData;
|
|
116
|
+
const disabled = ((_b = queryResponse === null || queryResponse === void 0 ? void 0 : queryResponse.data) === null || _b === void 0 ? void 0 : _b.form.initialData.isEnabled) === false;
|
|
117
|
+
const disabledMessage = ((_c = queryResponse === null || queryResponse === void 0 ? void 0 : queryResponse.data) === null || _c === void 0 ? void 0 : _c.form.initialData.isEnabledErrorMessage) ||
|
|
118
|
+
"The registration form is currently disabled.";
|
|
119
|
+
const formState = {
|
|
120
|
+
loading: formLoading,
|
|
121
|
+
disabled,
|
|
122
|
+
disabledMessage,
|
|
123
|
+
initialData,
|
|
124
|
+
};
|
|
125
|
+
setRegistrationFormState(formState);
|
|
126
|
+
}, [(_a = queryResponse === null || queryResponse === void 0 ? void 0 : queryResponse.data) === null || _a === void 0 ? void 0 : _a.form.initialData, formLoading]);
|
|
89
127
|
const submit = async (event) => {
|
|
90
128
|
let formControls = event.target.getFormControls();
|
|
91
129
|
let formData = {};
|
|
92
130
|
let validationErrors = {};
|
|
93
131
|
formControls === null || formControls === void 0 ? void 0 : formControls.forEach((control) => {
|
|
132
|
+
console.log({ control }, control.name);
|
|
94
133
|
if (!control.name)
|
|
95
134
|
return;
|
|
96
135
|
const key = control.name;
|
|
97
136
|
const value = control.value;
|
|
137
|
+
// control.value = initialData[key] || control.value;
|
|
98
138
|
jsonpointer.set(formData, key, value);
|
|
99
139
|
// required validation
|
|
100
140
|
if (control.required && !value) {
|
|
@@ -124,14 +164,15 @@ function usePortalRegistrationForm(props) {
|
|
|
124
164
|
delete formData.email;
|
|
125
165
|
delete formData.password;
|
|
126
166
|
delete formData.confirmPassword;
|
|
127
|
-
formData = { ...formData };
|
|
128
167
|
const redirectPath = props.redirectPath;
|
|
129
168
|
const variables = {
|
|
130
169
|
key: props.formKey,
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
170
|
+
formData: {
|
|
171
|
+
email,
|
|
172
|
+
password,
|
|
173
|
+
redirectPath,
|
|
174
|
+
...formData,
|
|
175
|
+
},
|
|
135
176
|
};
|
|
136
177
|
try {
|
|
137
178
|
await request(variables);
|
|
@@ -168,21 +209,27 @@ function usePortalRegistrationForm(props) {
|
|
|
168
209
|
};
|
|
169
210
|
}, [formRef.current]);
|
|
170
211
|
let errorMessage = "";
|
|
171
|
-
if ((
|
|
212
|
+
if (((_b = queryResponse === null || queryResponse === void 0 ? void 0 : queryResponse.data) === null || _b === void 0 ? void 0 : _b.form.initialData.isEnabled) === false) {
|
|
213
|
+
errorMessage =
|
|
214
|
+
((_c = queryResponse === null || queryResponse === void 0 ? void 0 : queryResponse.data) === null || _c === void 0 ? void 0 : _c.form.initialData.isEnabledErrorMessage) ||
|
|
215
|
+
"The registration form is disabled";
|
|
216
|
+
}
|
|
217
|
+
else if ((_d = errors === null || errors === void 0 ? void 0 : errors.response) === null || _d === void 0 ? void 0 : _d["error"]) {
|
|
172
218
|
errorMessage = "Network request failed";
|
|
173
219
|
}
|
|
174
|
-
else if ((errors === null || errors === void 0 ? void 0 : errors.message) && !((
|
|
220
|
+
else if ((errors === null || errors === void 0 ? void 0 : errors.message) && !((_e = errors === null || errors === void 0 ? void 0 : errors.response) === null || _e === void 0 ? void 0 : _e.errors.length)) {
|
|
175
221
|
errorMessage = "Network request failed";
|
|
176
222
|
}
|
|
177
223
|
else {
|
|
178
224
|
errorMessage =
|
|
179
|
-
formError || ((_f = (
|
|
225
|
+
formError || ((_j = (_h = (_g = (_f = queryResponse === null || queryResponse === void 0 ? void 0 : queryResponse.errors) === null || _f === void 0 ? void 0 : _f.response) === null || _g === void 0 ? void 0 : _g.errors) === null || _h === void 0 ? void 0 : _h[0]) === null || _j === void 0 ? void 0 : _j.message) || ((_o = (_m = (_l = (_k = errors === null || errors === void 0 ? void 0 : errors.response) === null || _k === void 0 ? void 0 : _k.errors) === null || _l === void 0 ? void 0 : _l[0]) === null || _m === void 0 ? void 0 : _m.extensions) === null || _o === void 0 ? void 0 : _o.message) || ((_r = (_q = (_p = errors === null || errors === void 0 ? void 0 : errors.response) === null || _p === void 0 ? void 0 : _p.errors) === null || _q === void 0 ? void 0 : _q[0]) === null || _r === void 0 ? void 0 : _r.message) || (validationState === null || validationState === void 0 ? void 0 : validationState.error);
|
|
180
226
|
}
|
|
181
227
|
return {
|
|
182
228
|
states: {
|
|
183
|
-
loading,
|
|
229
|
+
loading: loading || queryResponse.loading,
|
|
184
230
|
error: errorMessage,
|
|
185
231
|
validationState,
|
|
232
|
+
registrationFormState,
|
|
186
233
|
confirmPassword: props.confirmPassword,
|
|
187
234
|
hideInputs: props.hideInputs,
|
|
188
235
|
loginPath: props.loginPath,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1 } from './index-17b4da69.js';
|
|
2
2
|
import { i as useState, e as useEffect, m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { K as Ke, G as Ge, I as In, L } from './index.module-
|
|
4
|
+
import { K as Ke, G as Ge, I as In, L } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
import { j as jsonpointer } from './jsonpointer-388a7082.js';
|
|
7
7
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1 } from './index-17b4da69.js';
|
|
2
2
|
import { i as useState, e as useEffect, m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { a as ae, c as dn, I as In, L } from './index.module-
|
|
4
|
+
import { a as ae, c as dn, I as In, L } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
6
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
7
7
|
import './mixins-f60a614c.js';
|
|
@@ -20,7 +20,6 @@ function usePortalVerifyEmail({ nextPage, failedPage }) {
|
|
|
20
20
|
const urlParams = new URLSearchParams(window.location.search);
|
|
21
21
|
const oobCode = urlParams.get("oobCode");
|
|
22
22
|
const nextPageOverride = urlParams.get("nextPage");
|
|
23
|
-
urlParams.delete("oobCode");
|
|
24
23
|
const failed = () => {
|
|
25
24
|
return In.push({
|
|
26
25
|
pathname: failedPage,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { h, c as Host, r as registerInstance } from './index-17b4da69.js';
|
|
2
2
|
import { l, k as useMemo, e as useEffect, m as h$1 } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { P } from './index.module-
|
|
4
|
+
import { P } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
|
-
import { u as useChildElements } from './useChildElements-
|
|
6
|
+
import { u as useChildElements } from './useChildElements-e1a1d3d1.js';
|
|
7
7
|
import { g as getProps } from './utils-334c1e34.js';
|
|
8
8
|
|
|
9
9
|
const TabsView = ({ content, placement, }) => {
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1, g as getElement, c as Host } from './index-17b4da69.js';
|
|
2
2
|
import { m as h, u as useReducer, k as useMemo, e as useEffect } from './stencil-hooks.module-66fea7dc.js';
|
|
3
|
-
import { i as intl } from './global-
|
|
3
|
+
import { i as intl } from './global-1e714a4d.js';
|
|
4
4
|
import './use-callback-69ec5c5c.js';
|
|
5
|
-
import { L } from './index.module-
|
|
5
|
+
import { L } from './index.module-9cd4623b.js';
|
|
6
6
|
import './extends-c31f1eff.js';
|
|
7
7
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
8
8
|
import './mixins-f60a614c.js';
|
|
9
9
|
import { c as createStyleSheet } from './JSS-f00f9536.js';
|
|
10
10
|
import { G as GenericTableView } from './GenericTableView-59c5d47c.js';
|
|
11
|
-
import { a as useRequestRerender, u as useRerenderListener } from './re-render-
|
|
12
|
-
import { u as useChildElements } from './useChildElements-
|
|
11
|
+
import { a as useRequestRerender, u as useRerenderListener } from './re-render-d1b2a0de.js';
|
|
12
|
+
import { u as useChildElements } from './useChildElements-e1a1d3d1.js';
|
|
13
13
|
import { l as luxon } from './luxon-38ca2169.js';
|
|
14
|
-
import { u as useReferralTable, t as tryMethod } from './useReferralTable-
|
|
14
|
+
import { u as useReferralTable, t as tryMethod } from './useReferralTable-68c0823f.js';
|
|
15
15
|
import { l as luxonLocale } from './utils-334c1e34.js';
|
|
16
16
|
import { T as TextSpanView } from './sqm-text-span-view-0ba1484d.js';
|
|
17
17
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { r as registerInstance, h as h$1, c as Host } from './index-17b4da69.js';
|
|
2
2
|
import { m as h } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import './index.module-
|
|
4
|
+
import './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
|
-
import { a as useRequestRerender } from './re-render-
|
|
6
|
+
import { a as useRequestRerender } from './re-render-d1b2a0de.js';
|
|
7
7
|
|
|
8
8
|
const RewardTableCustomerNoteColumn = class {
|
|
9
9
|
constructor(hostRef) {
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { h, r as registerInstance, c as Host } from './index-17b4da69.js';
|
|
2
2
|
import { b as browser, u as useReducer, e as useEffect, m as h$1, k as useMemo } from './stencil-hooks.module-66fea7dc.js';
|
|
3
|
-
import { i as intl } from './global-
|
|
3
|
+
import { i as intl } from './global-1e714a4d.js';
|
|
4
4
|
import './use-callback-69ec5c5c.js';
|
|
5
|
-
import { d as dist, a as ae, M, O, q as qn, L } from './index.module-
|
|
5
|
+
import { d as dist, a as ae, M, O, q as qn, L } from './index.module-9cd4623b.js';
|
|
6
6
|
import './extends-c31f1eff.js';
|
|
7
7
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
8
8
|
import './mixins-f60a614c.js';
|
|
9
9
|
import { c as createStyleSheet } from './JSS-f00f9536.js';
|
|
10
10
|
import { G as GenericTableView } from './GenericTableView-59c5d47c.js';
|
|
11
|
-
import { u as useRerenderListener, a as useRequestRerender } from './re-render-
|
|
12
|
-
import { u as useChildElements } from './useChildElements-
|
|
11
|
+
import { u as useRerenderListener, a as useRequestRerender } from './re-render-d1b2a0de.js';
|
|
12
|
+
import { u as useChildElements } from './useChildElements-e1a1d3d1.js';
|
|
13
13
|
import { l as luxon } from './luxon-38ca2169.js';
|
|
14
|
-
import { g as generateUserError } from './useReferralTable-
|
|
14
|
+
import { g as generateUserError } from './useReferralTable-68c0823f.js';
|
|
15
15
|
import { l as luxonLocale } from './utils-334c1e34.js';
|
|
16
16
|
|
|
17
17
|
const mockRewardData = (count = 4) => {
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { h, r as registerInstance, c as Host } from './index-17b4da69.js';
|
|
2
2
|
import { a as commonjsGlobal, k as useMemo, i as useState, e as useEffect, c as createCommonjsModule, m as h$1 } from './stencil-hooks.module-66fea7dc.js';
|
|
3
|
-
import './global-
|
|
3
|
+
import './global-1e714a4d.js';
|
|
4
4
|
import './use-callback-69ec5c5c.js';
|
|
5
|
-
import { I as In, F as Fn, t as te$1, d as dist, e as tn, A as A$1 } from './index.module-
|
|
5
|
+
import { I as In, F as Fn, t as te$1, d as dist, e as tn, A as A$1 } from './index.module-9cd4623b.js';
|
|
6
6
|
import './extends-c31f1eff.js';
|
|
7
7
|
import './cjs-bdfb4486.js';
|
|
8
8
|
import './mixins-f60a614c.js';
|
|
9
9
|
import { c as createStyleSheet } from './JSS-f00f9536.js';
|
|
10
10
|
import { G as GenericTableView } from './GenericTableView-59c5d47c.js';
|
|
11
|
-
import './useChildElements-
|
|
11
|
+
import './useChildElements-e1a1d3d1.js';
|
|
12
12
|
import { l as luxon } from './luxon-38ca2169.js';
|
|
13
13
|
import './utils-334c1e34.js';
|
|
14
14
|
import './sqm-text-span-view-0ba1484d.js';
|
|
@@ -16,15 +16,15 @@ import { A as AssetCardView } from './sqm-asset-card-view-08e68656.js';
|
|
|
16
16
|
import { H as HeroView } from './sqm-hero-view-93fac447.js';
|
|
17
17
|
import { L as LeaderboardRankView } from './sqm-leaderboard-rank-view-10657658.js';
|
|
18
18
|
import { N as NavigationSidebarView } from './sqm-navigation-sidebar-view-06d444ca.js';
|
|
19
|
-
import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-view-
|
|
20
|
-
import { P as PortalEmailVerificationView } from './sqm-portal-email-verification-view-
|
|
21
|
-
import { a as PoweredByImg$1, P as PortalFooterView } from './sqm-portal-footer-view-
|
|
19
|
+
import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-view-7e6199c2.js';
|
|
20
|
+
import { P as PortalEmailVerificationView } from './sqm-portal-email-verification-view-ba08318b.js';
|
|
21
|
+
import { a as PoweredByImg$1, P as PortalFooterView } from './sqm-portal-footer-view-9bfd61b4.js';
|
|
22
22
|
import { P as PortalForgotPasswordView } from './sqm-portal-forgot-password-view-86d13eef.js';
|
|
23
23
|
import { P as PortalContainerView } from './sqm-portal-container-view-ca454627.js';
|
|
24
|
-
import { P as PortalProfileView } from './sqm-portal-profile-view-
|
|
24
|
+
import { P as PortalProfileView } from './sqm-portal-profile-view-0f8dd14f.js';
|
|
25
25
|
import { P as PortalResetPasswordView } from './sqm-portal-reset-password-view-213b3af6.js';
|
|
26
26
|
import { P as PortalVerifyEmailView } from './sqm-portal-verify-email-view-c32dfd7e.js';
|
|
27
|
-
import { S as ShareButtonView, L as LeaderboardView, a as ShareLinkView, B as BigStatView, P as PortalFrameView, E as EditProfileView, u as useShareLink, b as useShareButton, c as useDemoBigStat, d as StatContainerView, e as PortalChangePasswordView, f as PortalLoginView, g as PortalRegisterView, T as TaskCardView, h as ProgressBarView, R as ReferralIframeView, N as NameFieldsView, C as CheckboxFieldView, D as DropdownFieldView, I as InputFieldView, i as RewardExchangeView, r as rewardExchangeCustomErrorMsg, j as rewardExchangeLongText, k as rewardExchangeSelected, l as chooseAmountFixed, m as chooseAmountFixedNoDescription, n as chooseAmountVariable, o as chooseAmountVariableNoDescription, p as chooseAmountVariableDisabled, q as chooseAmountVariableUnavailable, s as confirmFixed, t as confirmVariable, v as redemptionError, w as queryError, x as success, y as successVariable, z as loading, A as empty$1, F as rewardExchange, G as CardFeedView, H as autoColorScaleCss, J as ShadowViewAddon } from './ShadowViewAddon-
|
|
27
|
+
import { S as ShareButtonView, L as LeaderboardView, a as ShareLinkView, B as BigStatView, P as PortalFrameView, E as EditProfileView, u as useShareLink, b as useShareButton, c as useDemoBigStat, d as StatContainerView, e as PortalChangePasswordView, f as PortalLoginView, g as PortalRegisterView, T as TaskCardView, h as ProgressBarView, R as ReferralIframeView, N as NameFieldsView, C as CheckboxFieldView, D as DropdownFieldView, I as InputFieldView, i as RewardExchangeView, r as rewardExchangeCustomErrorMsg, j as rewardExchangeLongText, k as rewardExchangeSelected, l as chooseAmountFixed, m as chooseAmountFixedNoDescription, n as chooseAmountVariable, o as chooseAmountVariableNoDescription, p as chooseAmountVariableDisabled, q as chooseAmountVariableUnavailable, s as confirmFixed, t as confirmVariable, v as redemptionError, w as queryError, x as success, y as successVariable, z as loading, A as empty$1, F as rewardExchange, G as CardFeedView, H as autoColorScaleCss, J as ShadowViewAddon } from './ShadowViewAddon-7d94f9d6.js';
|
|
28
28
|
import { P as PortalSectionView } from './sqm-portal-section-view-6c249c74.js';
|
|
29
29
|
|
|
30
30
|
/**
|
|
@@ -5982,6 +5982,7 @@ const Start = () => {
|
|
|
5982
5982
|
initValue: "",
|
|
5983
5983
|
states: {
|
|
5984
5984
|
enableValidation: true,
|
|
5985
|
+
registrationFormState: {},
|
|
5985
5986
|
validationErrors: {},
|
|
5986
5987
|
content: {
|
|
5987
5988
|
fieldLabel: "Password",
|
|
@@ -5995,6 +5996,7 @@ const EmptyError = () => {
|
|
|
5995
5996
|
states: {
|
|
5996
5997
|
enableValidation: true,
|
|
5997
5998
|
validationErrors: { password: "Cannot be empty" },
|
|
5999
|
+
registrationFormState: {},
|
|
5998
6000
|
content: {
|
|
5999
6001
|
fieldLabel: "Password",
|
|
6000
6002
|
},
|
|
@@ -6006,6 +6008,7 @@ const ValidationError = () => {
|
|
|
6006
6008
|
initValue: "asdf",
|
|
6007
6009
|
states: {
|
|
6008
6010
|
enableValidation: true,
|
|
6011
|
+
registrationFormState: {},
|
|
6009
6012
|
validationErrors: { password: "Incomplete" },
|
|
6010
6013
|
content: {
|
|
6011
6014
|
fieldLabel: "Password",
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { h, c as Host, r as registerInstance } from './index-17b4da69.js';
|
|
2
2
|
import { l, k as useMemo, e as useEffect, m as h$1 } from './stencil-hooks.module-66fea7dc.js';
|
|
3
3
|
import './use-callback-69ec5c5c.js';
|
|
4
|
-
import { P } from './index.module-
|
|
4
|
+
import { P } from './index.module-9cd4623b.js';
|
|
5
5
|
import './extends-c31f1eff.js';
|
|
6
|
-
import { u as useChildElements } from './useChildElements-
|
|
6
|
+
import { u as useChildElements } from './useChildElements-e1a1d3d1.js';
|
|
7
7
|
import { g as getProps } from './utils-334c1e34.js';
|
|
8
8
|
|
|
9
9
|
const TabsView = ({ content, placement, }) => {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { h } from './index-17b4da69.js';
|
|
2
2
|
import { b as browser, u as useReducer, e as useEffect } from './stencil-hooks.module-66fea7dc.js';
|
|
3
|
-
import { d as dist, a as ae, M, O, w as wn, q as qn } from './index.module-
|
|
4
|
-
import { u as useRerenderListener } from './re-render-
|
|
5
|
-
import { u as useChildElements } from './useChildElements-
|
|
3
|
+
import { d as dist, a as ae, M, O, w as wn, q as qn } from './index.module-9cd4623b.js';
|
|
4
|
+
import { u as useRerenderListener } from './re-render-d1b2a0de.js';
|
|
5
|
+
import { u as useChildElements } from './useChildElements-e1a1d3d1.js';
|
|
6
6
|
|
|
7
7
|
const debug = browser("sq:useReferralTable");
|
|
8
8
|
const CSS_NAMESPACE = "sqm-referral-table";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { y } from './stencil-hooks.module-66fea7dc.js';
|
|
2
|
+
import { P } from './index.module-9cd4623b.js';
|
|
3
|
+
|
|
4
|
+
const FORM_VALIDATION_CONTEXT = "sq:validation-state";
|
|
5
|
+
function useValidationState(formState) {
|
|
6
|
+
const host = P();
|
|
7
|
+
const [validationState, setValidationState] = y(host, FORM_VALIDATION_CONTEXT, formState);
|
|
8
|
+
return { validationState, setValidationState };
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
const REGISTRATION_FORM_STATE_CONTEXT = "sq:registration-form-state";
|
|
12
|
+
function useRegistrationFormState(formState) {
|
|
13
|
+
const host = P();
|
|
14
|
+
const [registrationFormState, setRegistrationFormState] = y(host, REGISTRATION_FORM_STATE_CONTEXT, formState);
|
|
15
|
+
return { registrationFormState, setRegistrationFormState };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { FORM_VALIDATION_CONTEXT as F, REGISTRATION_FORM_STATE_CONTEXT as R, useValidationState as a, useRegistrationFormState as u };
|