@saasquatch/mint-components 1.13.0-31 → 1.13.0-33

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.
@@ -2030,11 +2030,13 @@ function usePortalLogin(props) {
2030
2030
  return;
2031
2031
  const result = await loginWithGoogle({ idToken: e.detail.credential });
2032
2032
  if (result instanceof Error) {
2033
+ console.log(result, "resultGoogleError");
2033
2034
  if ((result === null || result === void 0 ? void 0 : result.message) || ((_b = result === null || result === void 0 ? void 0 : result["response"]) === null || _b === void 0 ? void 0 : _b["error"]))
2034
2035
  setError(props.networkErrorMessage);
2035
2036
  return;
2036
2037
  }
2037
2038
  if ((_c = result.authenticateManagedIdentityWithGoogle) === null || _c === void 0 ? void 0 : _c.token) {
2039
+ console.log(result, "resultGoogle");
2038
2040
  urlParams.delete("nextPage");
2039
2041
  const url = utils.sanitizeUrlPath(nextPageOverride || props.nextPage);
2040
2042
  index_module.jn.push(url.href);
@@ -2050,11 +2052,13 @@ function usePortalLogin(props) {
2050
2052
  const variables = { email: formData.email, password: formData.password };
2051
2053
  const result = await request(variables);
2052
2054
  if (result instanceof Error) {
2055
+ console.log(result, "resultRegular");
2053
2056
  if ((result === null || result === void 0 ? void 0 : result.message) || ((_a = result === null || result === void 0 ? void 0 : result["response"]) === null || _a === void 0 ? void 0 : _a["error"]))
2054
2057
  setError(props.networkErrorMessage);
2055
2058
  return;
2056
2059
  }
2057
2060
  if ((_b = result.authenticateManagedIdentityWithEmailAndPassword) === null || _b === void 0 ? void 0 : _b.token) {
2061
+ console.log(result, "resultRegular");
2058
2062
  urlParams.delete("nextPage");
2059
2063
  const url = utils.sanitizeUrlPath(nextPageOverride || props.nextPage);
2060
2064
  index_module.jn.push(url.href);
@@ -93,7 +93,7 @@ const GoogleSignIn = class {
93
93
  }
94
94
  }
95
95
  render() {
96
- const { setGoogleButtonDiv } = index_module.isDemo
96
+ const { setGoogleButtonDiv } = index_module.isDemo()
97
97
  ? useDemoGoogleSignIn(this)
98
98
  : useGoogleSignIn(this);
99
99
  return (index.h("div", { ref: setGoogleButtonDiv, style: { width: "100%" } }));
@@ -10134,7 +10134,7 @@ const emailVerifiedTemplate = "<sqm-portal-verify-email></sqm-portal-verify-emai
10134
10134
 
10135
10135
  const emailVerificationTemplate = "<sqm-portal-protected-route redirect-to=\"/login\"></sqm-portal-protected-route>\n<sqm-portal-email-verification></sqm-portal-email-verification>\n";
10136
10136
 
10137
- const LoginReadme = "# sqm-portal-login\n\n\n\n<!-- Auto Generated Below -->\n\n\n## Properties\n\n| Property | Attribute | Description | Type | Default |\n| ------------------------------ | ---------------------------------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |\n| `demoData` | -- | | `{ states?: { error: string; loading: boolean; forgotPasswordPath: string; registerPath: string; }; content?: { googleButton?: VNode; forgotPasswordButton?: any; secondaryButton?: any; emailLabel?: string; passwordLabel?: string; submitLabel?: string; pageLabel?: string; }; }` | `undefined` |\n| `emailLabel` | `email-label` | | `string` | `\"Email\"` |\n| `forgotPasswordLabel` | `forgot-password-label` | | `string` | `\"Forgot Password?\"` |\n| `forgotPasswordPath` | `forgot-password-path` | Redirect participants to this page to reset their password | `string` | `\"/forgotPassword\"` |\n| `googleUserNotRegisteredError` | `google-user-not-registered-error` | | `string` | `\"Google user has not registered on our platform. Please complete the registration process with your Google account.\"` |\n| `networkErrorMessage` | `network-error-message` | | `string` | `\"An error occurred while logging you in. Please refresh the page and try again.\"` |\n| `nextPage` | `next-page` | Redirect participants to this page after they successfully login. | `string` | `\"/\"` |\n| `pageLabel` | `page-label` | | `string` | `\"Sign in to your account\"` |\n| `passwordLabel` | `password-label` | | `string` | `\"Password\"` |\n| `registerCTA` | `register-c-t-a` | | `string` | `\"Don't have an account?\"` |\n| `registerLabel` | `register-label` | | `string` | `\"Register\"` |\n| `registerPath` | `register-path` | Redirect participants to this page to start registration. | `string` | `\"/register\"` |\n| `showGoogleLogin` | `show-google-login` | | `boolean` | `false` |\n| `submitLabel` | `submit-label` | | `string` | `\"Sign In\"` |\n\n\n## Dependencies\n\n### Used by\n\n - [sqm-stencilbook](../sqm-stencilbook)\n\n### Depends on\n\n- [sqm-google-sign-in](../sqm-google-sign-in)\n- [sqm-form-message](../sqm-form-message)\n\n### Graph\n```mermaid\ngraph TD;\n sqm-portal-login --> sqm-google-sign-in\n sqm-portal-login --> sqm-form-message\n sqm-stencilbook --> sqm-portal-login\n style sqm-portal-login fill:#f9f,stroke:#333,stroke-width:4px\n```\n\n----------------------------------------------\n\n*Built with [StencilJS](https://stenciljs.com/)*\n";
10137
+ const LoginReadme = "# sqm-portal-login\n\n\n\n<!-- Auto Generated Below -->\n\n\n## Properties\n\n| Property | Attribute | Description | Type | Default |\n| --------------------- | ----------------------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- |\n| `demoData` | -- | | `{ states?: { error: string; loading: boolean; forgotPasswordPath: string; registerPath: string; }; content?: { googleButton?: VNode; forgotPasswordButton?: any; secondaryButton?: any; emailLabel?: string; passwordLabel?: string; submitLabel?: string; pageLabel?: string; }; }` | `undefined` |\n| `emailLabel` | `email-label` | | `string` | `\"Email\"` |\n| `forgotPasswordLabel` | `forgot-password-label` | | `string` | `\"Forgot Password?\"` |\n| `forgotPasswordPath` | `forgot-password-path` | Redirect participants to this page to reset their password | `string` | `\"/forgotPassword\"` |\n| `networkErrorMessage` | `network-error-message` | | `string` | `\"An error occurred while logging you in. Please refresh the page and try again.\"` |\n| `nextPage` | `next-page` | Redirect participants to this page after they successfully login. | `string` | `\"/\"` |\n| `pageLabel` | `page-label` | | `string` | `\"Sign in to your account\"` |\n| `passwordLabel` | `password-label` | | `string` | `\"Password\"` |\n| `registerCTA` | `register-c-t-a` | | `string` | `\"Don't have an account?\"` |\n| `registerLabel` | `register-label` | | `string` | `\"Register\"` |\n| `registerPath` | `register-path` | Redirect participants to this page to start registration. | `string` | `\"/register\"` |\n| `showGoogleLogin` | `show-google-login` | | `boolean` | `false` |\n| `submitLabel` | `submit-label` | | `string` | `\"Sign In\"` |\n\n\n## Dependencies\n\n### Used by\n\n - [sqm-stencilbook](../sqm-stencilbook)\n\n### Depends on\n\n- [sqm-google-sign-in](../sqm-google-sign-in)\n- [sqm-form-message](../sqm-form-message)\n\n### Graph\n```mermaid\ngraph TD;\n sqm-portal-login --> sqm-google-sign-in\n sqm-portal-login --> sqm-form-message\n sqm-stencilbook --> sqm-portal-login\n style sqm-portal-login fill:#f9f,stroke:#333,stroke-width:4px\n```\n\n----------------------------------------------\n\n*Built with [StencilJS](https://stenciljs.com/)*\n";
10138
10138
 
10139
10139
  const ReferralIframeReadme = "# sqm-referral-iframe\n\n\n\n<!-- Auto Generated Below -->\n\n\n## Properties\n\n| Property | Attribute | Description | Type | Default |\n| -------------- | --------------- | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ | ----------- |\n| `demoData` | -- | | `{ states?: { content: { iframeSrc: string; iframeHeight: string; iframeWidth: string; }; }; data?: { shareCode: string; }; }` | `undefined` |\n| `iframeHeight` | `iframe-height` | Define the height of the iframe with any valid CSS height value. Example: 100px, 5rem, or auto. | `string` | `\"100%\"` |\n| `iframeSrc` | `iframe-src` | URL of iframe to display | `string` | `undefined` |\n| `iframeWidth` | `iframe-width` | Define the width of the iframe with any valid CSS width value. Example: 100px, 5rem, or auto. | `string` | `\"100%\"` |\n\n\n## Dependencies\n\n### Used by\n\n - [sqm-stencilbook](../sqm-stencilbook)\n\n### Graph\n```mermaid\ngraph TD;\n sqm-stencilbook --> sqm-referral-iframe\n style sqm-referral-iframe fill:#f9f,stroke:#333,stroke-width:4px\n```\n\n----------------------------------------------\n\n*Built with [StencilJS](https://stenciljs.com/)*\n";
10140
10140
 
@@ -23,7 +23,7 @@ export class GoogleSignIn {
23
23
  }
24
24
  }
25
25
  render() {
26
- const { setGoogleButtonDiv } = isDemo
26
+ const { setGoogleButtonDiv } = isDemo()
27
27
  ? useDemoGoogleSignIn(this)
28
28
  : useGoogleSignIn(this);
29
29
  return (h("div", { ref: setGoogleButtonDiv, style: { width: "100%" } }));
@@ -15,11 +15,13 @@ export function usePortalLogin(props) {
15
15
  return;
16
16
  const result = await loginWithGoogle({ idToken: e.detail.credential });
17
17
  if (result instanceof Error) {
18
+ console.log(result, "resultGoogleError");
18
19
  if ((result === null || result === void 0 ? void 0 : result.message) || ((_b = result === null || result === void 0 ? void 0 : result["response"]) === null || _b === void 0 ? void 0 : _b["error"]))
19
20
  setError(props.networkErrorMessage);
20
21
  return;
21
22
  }
22
23
  if ((_c = result.authenticateManagedIdentityWithGoogle) === null || _c === void 0 ? void 0 : _c.token) {
24
+ console.log(result, "resultGoogle");
23
25
  urlParams.delete("nextPage");
24
26
  const url = sanitizeUrlPath(nextPageOverride || props.nextPage);
25
27
  navigation.push(url.href);
@@ -35,11 +37,13 @@ export function usePortalLogin(props) {
35
37
  const variables = { email: formData.email, password: formData.password };
36
38
  const result = await request(variables);
37
39
  if (result instanceof Error) {
40
+ console.log(result, "resultRegular");
38
41
  if ((result === null || result === void 0 ? void 0 : result.message) || ((_a = result === null || result === void 0 ? void 0 : result["response"]) === null || _a === void 0 ? void 0 : _a["error"]))
39
42
  setError(props.networkErrorMessage);
40
43
  return;
41
44
  }
42
45
  if ((_b = result.authenticateManagedIdentityWithEmailAndPassword) === null || _b === void 0 ? void 0 : _b.token) {
46
+ console.log(result, "resultRegular");
43
47
  urlParams.delete("nextPage");
44
48
  const url = sanitizeUrlPath(nextPageOverride || props.nextPage);
45
49
  navigation.push(url.href);
@@ -2026,11 +2026,13 @@ function usePortalLogin(props) {
2026
2026
  return;
2027
2027
  const result = await loginWithGoogle({ idToken: e.detail.credential });
2028
2028
  if (result instanceof Error) {
2029
+ console.log(result, "resultGoogleError");
2029
2030
  if ((result === null || result === void 0 ? void 0 : result.message) || ((_b = result === null || result === void 0 ? void 0 : result["response"]) === null || _b === void 0 ? void 0 : _b["error"]))
2030
2031
  setError(props.networkErrorMessage);
2031
2032
  return;
2032
2033
  }
2033
2034
  if ((_c = result.authenticateManagedIdentityWithGoogle) === null || _c === void 0 ? void 0 : _c.token) {
2035
+ console.log(result, "resultGoogle");
2034
2036
  urlParams.delete("nextPage");
2035
2037
  const url = sanitizeUrlPath(nextPageOverride || props.nextPage);
2036
2038
  jn.push(url.href);
@@ -2046,11 +2048,13 @@ function usePortalLogin(props) {
2046
2048
  const variables = { email: formData.email, password: formData.password };
2047
2049
  const result = await request(variables);
2048
2050
  if (result instanceof Error) {
2051
+ console.log(result, "resultRegular");
2049
2052
  if ((result === null || result === void 0 ? void 0 : result.message) || ((_a = result === null || result === void 0 ? void 0 : result["response"]) === null || _a === void 0 ? void 0 : _a["error"]))
2050
2053
  setError(props.networkErrorMessage);
2051
2054
  return;
2052
2055
  }
2053
2056
  if ((_b = result.authenticateManagedIdentityWithEmailAndPassword) === null || _b === void 0 ? void 0 : _b.token) {
2057
+ console.log(result, "resultRegular");
2054
2058
  urlParams.delete("nextPage");
2055
2059
  const url = sanitizeUrlPath(nextPageOverride || props.nextPage);
2056
2060
  jn.push(url.href);
@@ -89,7 +89,7 @@ const GoogleSignIn = class {
89
89
  }
90
90
  }
91
91
  render() {
92
- const { setGoogleButtonDiv } = isDemo
92
+ const { setGoogleButtonDiv } = isDemo()
93
93
  ? useDemoGoogleSignIn(this)
94
94
  : useGoogleSignIn(this);
95
95
  return (h$1("div", { ref: setGoogleButtonDiv, style: { width: "100%" } }));
@@ -10130,7 +10130,7 @@ const emailVerifiedTemplate = "<sqm-portal-verify-email></sqm-portal-verify-emai
10130
10130
 
10131
10131
  const emailVerificationTemplate = "<sqm-portal-protected-route redirect-to=\"/login\"></sqm-portal-protected-route>\n<sqm-portal-email-verification></sqm-portal-email-verification>\n";
10132
10132
 
10133
- const LoginReadme = "# sqm-portal-login\n\n\n\n<!-- Auto Generated Below -->\n\n\n## Properties\n\n| Property | Attribute | Description | Type | Default |\n| ------------------------------ | ---------------------------------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |\n| `demoData` | -- | | `{ states?: { error: string; loading: boolean; forgotPasswordPath: string; registerPath: string; }; content?: { googleButton?: VNode; forgotPasswordButton?: any; secondaryButton?: any; emailLabel?: string; passwordLabel?: string; submitLabel?: string; pageLabel?: string; }; }` | `undefined` |\n| `emailLabel` | `email-label` | | `string` | `\"Email\"` |\n| `forgotPasswordLabel` | `forgot-password-label` | | `string` | `\"Forgot Password?\"` |\n| `forgotPasswordPath` | `forgot-password-path` | Redirect participants to this page to reset their password | `string` | `\"/forgotPassword\"` |\n| `googleUserNotRegisteredError` | `google-user-not-registered-error` | | `string` | `\"Google user has not registered on our platform. Please complete the registration process with your Google account.\"` |\n| `networkErrorMessage` | `network-error-message` | | `string` | `\"An error occurred while logging you in. Please refresh the page and try again.\"` |\n| `nextPage` | `next-page` | Redirect participants to this page after they successfully login. | `string` | `\"/\"` |\n| `pageLabel` | `page-label` | | `string` | `\"Sign in to your account\"` |\n| `passwordLabel` | `password-label` | | `string` | `\"Password\"` |\n| `registerCTA` | `register-c-t-a` | | `string` | `\"Don't have an account?\"` |\n| `registerLabel` | `register-label` | | `string` | `\"Register\"` |\n| `registerPath` | `register-path` | Redirect participants to this page to start registration. | `string` | `\"/register\"` |\n| `showGoogleLogin` | `show-google-login` | | `boolean` | `false` |\n| `submitLabel` | `submit-label` | | `string` | `\"Sign In\"` |\n\n\n## Dependencies\n\n### Used by\n\n - [sqm-stencilbook](../sqm-stencilbook)\n\n### Depends on\n\n- [sqm-google-sign-in](../sqm-google-sign-in)\n- [sqm-form-message](../sqm-form-message)\n\n### Graph\n```mermaid\ngraph TD;\n sqm-portal-login --> sqm-google-sign-in\n sqm-portal-login --> sqm-form-message\n sqm-stencilbook --> sqm-portal-login\n style sqm-portal-login fill:#f9f,stroke:#333,stroke-width:4px\n```\n\n----------------------------------------------\n\n*Built with [StencilJS](https://stenciljs.com/)*\n";
10133
+ const LoginReadme = "# sqm-portal-login\n\n\n\n<!-- Auto Generated Below -->\n\n\n## Properties\n\n| Property | Attribute | Description | Type | Default |\n| --------------------- | ----------------------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- |\n| `demoData` | -- | | `{ states?: { error: string; loading: boolean; forgotPasswordPath: string; registerPath: string; }; content?: { googleButton?: VNode; forgotPasswordButton?: any; secondaryButton?: any; emailLabel?: string; passwordLabel?: string; submitLabel?: string; pageLabel?: string; }; }` | `undefined` |\n| `emailLabel` | `email-label` | | `string` | `\"Email\"` |\n| `forgotPasswordLabel` | `forgot-password-label` | | `string` | `\"Forgot Password?\"` |\n| `forgotPasswordPath` | `forgot-password-path` | Redirect participants to this page to reset their password | `string` | `\"/forgotPassword\"` |\n| `networkErrorMessage` | `network-error-message` | | `string` | `\"An error occurred while logging you in. Please refresh the page and try again.\"` |\n| `nextPage` | `next-page` | Redirect participants to this page after they successfully login. | `string` | `\"/\"` |\n| `pageLabel` | `page-label` | | `string` | `\"Sign in to your account\"` |\n| `passwordLabel` | `password-label` | | `string` | `\"Password\"` |\n| `registerCTA` | `register-c-t-a` | | `string` | `\"Don't have an account?\"` |\n| `registerLabel` | `register-label` | | `string` | `\"Register\"` |\n| `registerPath` | `register-path` | Redirect participants to this page to start registration. | `string` | `\"/register\"` |\n| `showGoogleLogin` | `show-google-login` | | `boolean` | `false` |\n| `submitLabel` | `submit-label` | | `string` | `\"Sign In\"` |\n\n\n## Dependencies\n\n### Used by\n\n - [sqm-stencilbook](../sqm-stencilbook)\n\n### Depends on\n\n- [sqm-google-sign-in](../sqm-google-sign-in)\n- [sqm-form-message](../sqm-form-message)\n\n### Graph\n```mermaid\ngraph TD;\n sqm-portal-login --> sqm-google-sign-in\n sqm-portal-login --> sqm-form-message\n sqm-stencilbook --> sqm-portal-login\n style sqm-portal-login fill:#f9f,stroke:#333,stroke-width:4px\n```\n\n----------------------------------------------\n\n*Built with [StencilJS](https://stenciljs.com/)*\n";
10134
10134
 
10135
10135
  const ReferralIframeReadme = "# sqm-referral-iframe\n\n\n\n<!-- Auto Generated Below -->\n\n\n## Properties\n\n| Property | Attribute | Description | Type | Default |\n| -------------- | --------------- | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ | ----------- |\n| `demoData` | -- | | `{ states?: { content: { iframeSrc: string; iframeHeight: string; iframeWidth: string; }; }; data?: { shareCode: string; }; }` | `undefined` |\n| `iframeHeight` | `iframe-height` | Define the height of the iframe with any valid CSS height value. Example: 100px, 5rem, or auto. | `string` | `\"100%\"` |\n| `iframeSrc` | `iframe-src` | URL of iframe to display | `string` | `undefined` |\n| `iframeWidth` | `iframe-width` | Define the width of the iframe with any valid CSS width value. Example: 100px, 5rem, or auto. | `string` | `\"100%\"` |\n\n\n## Dependencies\n\n### Used by\n\n - [sqm-stencilbook](../sqm-stencilbook)\n\n### Graph\n```mermaid\ngraph TD;\n sqm-stencilbook --> sqm-referral-iframe\n style sqm-referral-iframe fill:#f9f,stroke:#333,stroke-width:4px\n```\n\n----------------------------------------------\n\n*Built with [StencilJS](https://stenciljs.com/)*\n";
10136
10136