@cal.macconnachie/web-components 2.0.2 → 2.0.4

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/index.d.ts CHANGED
@@ -523,7 +523,12 @@ export declare interface SelectOption {
523
523
 
524
524
  declare type SelectSize = 'sm' | 'md' | 'lg';
525
525
 
526
- export declare function showToast(message: string, variant?: ToastVariant, position?: ToastPosition, dismiss?: DismissBehavior): void;
526
+ export declare function showToast({ message, variant, position, dismiss }: {
527
+ message: string;
528
+ variant?: ToastVariant;
529
+ position?: ToastPosition;
530
+ dismiss?: DismissBehavior;
531
+ }): void;
527
532
 
528
533
  export declare interface TabData {
529
534
  id: string;
package/dist/index.js CHANGED
@@ -1456,7 +1456,7 @@ const Mo = [
1456
1456
  class C extends N {
1457
1457
  constructor() {
1458
1458
  super(...arguments), this.initialMode = "signin", this.logoUrl = "", this.oauthDomain = "", this.oauthRegion = "", this.oauthUserPoolId = "", this.oauthClientId = "", this.oauthRedirectUri = "", this.oauthSpaDomain = "", this.disableSignup = !1, this.mockMode = !1, this.mode = "signin", this.resetStep = "none", this.signupStep = "form", this.isLoading = !1, this.isLoggedIn = !1, this.email = "", this.password = "", this.givenName = "", this.familyName = "", this.newPassword = "", this.confirmPassword = "", this.notice = "", this.error = "", this.errors = {}, this.userEmail = null, this.otpDigits = ["", "", "", "", "", ""], this.signupOtpDigits = ["", "", "", "", "", ""], this.hasHandledOAuthCallback = !1, this.handleAuthRefreshFailed = () => {
1459
- this.isLoggedIn = !1, this.userEmail = null, this.error = "Your session has expired. Please sign in again.";
1459
+ this.isLoggedIn = !1, this.userEmail = null;
1460
1460
  };
1461
1461
  }
1462
1462
  getApiService() {
@@ -2289,7 +2289,7 @@ class C extends N {
2289
2289
  }
2290
2290
  async refresh() {
2291
2291
  try {
2292
- await this.getApiService().refresh();
2292
+ await this.getApiService().refresh(), this.checkExistingSession();
2293
2293
  } catch {
2294
2294
  this.isLoggedIn = !1;
2295
2295
  }
@@ -6172,11 +6172,9 @@ class ie extends N {
6172
6172
  @keyframes fadeIn {
6173
6173
  from {
6174
6174
  opacity: 0;
6175
- transform: translateY(8px);
6176
6175
  }
6177
6176
  to {
6178
6177
  opacity: 1;
6179
- transform: translateY(0);
6180
6178
  }
6181
6179
  }
6182
6180
 
@@ -7291,7 +7289,12 @@ je([
7291
7289
  je([
7292
7290
  m({ type: String, attribute: "position", reflect: !0 })
7293
7291
  ], _e.prototype, "position");
7294
- function Ws(r, e = "default", t = "top-right", i = "2s") {
7292
+ function Ws({
7293
+ message: r,
7294
+ variant: e = "default",
7295
+ position: t = "top-right",
7296
+ dismiss: i = "2s"
7297
+ }) {
7295
7298
  const o = document.createElement("base-toast");
7296
7299
  o.id = `toast-${Date.now()}`, o.setAttribute("variant", e), o.setAttribute("position", t), o.setAttribute("dismiss", i), o.textContent = r, document.body.appendChild(o), o.show(), o.addEventListener("toast-hidden", () => {
7297
7300
  o.remove();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cal.macconnachie/web-components",
3
- "version": "2.0.2",
3
+ "version": "2.0.4",
4
4
  "description": "Web components hosted on a CDN",
5
5
  "keywords": [
6
6
  "web-components",