@stytch/vanilla-js 4.7.5 → 4.7.7
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/CHANGELOG.md +14 -0
- package/dist/b2b/index.esm.js +8 -3
- package/dist/b2b/index.headless.esm.js +8 -3
- package/dist/b2b/index.headless.js +8 -3
- package/dist/b2b/index.js +8 -3
- package/dist/index.esm.js +3 -3
- package/dist/index.headless.esm.js +23 -23
- package/dist/index.headless.js +3 -3
- package/dist/index.js +3 -3
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @stytch/vanilla-js
|
|
2
2
|
|
|
3
|
+
## 4.7.7
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [cae4f3d]
|
|
8
|
+
- @stytch/core@2.11.0
|
|
9
|
+
|
|
10
|
+
## 4.7.6
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies [bf6f8f6]
|
|
15
|
+
- @stytch/core@2.10.2
|
|
16
|
+
|
|
3
17
|
## 4.7.5
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
package/dist/b2b/index.esm.js
CHANGED
|
@@ -1523,8 +1523,8 @@ var Ue,
|
|
|
1523
1523
|
executeRecaptcha: i
|
|
1524
1524
|
});
|
|
1525
1525
|
case 2:
|
|
1526
|
-
return r.next = 4,
|
|
1527
|
-
return window;
|
|
1526
|
+
return r.next = 4, ze("".concat("https://elements.stytch.com", "/telemetry.js"), function () {
|
|
1527
|
+
return window.GetTelemetryID;
|
|
1528
1528
|
});
|
|
1529
1529
|
case 4:
|
|
1530
1530
|
return r.abrupt("return", {
|
|
@@ -2893,6 +2893,11 @@ var Xe = Promise.resolve({
|
|
|
2893
2893
|
value: function value() {
|
|
2894
2894
|
return this._subscriptionService.getTokens();
|
|
2895
2895
|
}
|
|
2896
|
+
}, {
|
|
2897
|
+
key: "updateSession",
|
|
2898
|
+
value: function value(e) {
|
|
2899
|
+
this._subscriptionService.updateTokens(e);
|
|
2900
|
+
}
|
|
2896
2901
|
}]), e;
|
|
2897
2902
|
}(),
|
|
2898
2903
|
at = _e(function e(t, n) {
|
|
@@ -4125,7 +4130,7 @@ var wt = /*#__PURE__*/function () {
|
|
|
4125
4130
|
},
|
|
4126
4131
|
sdk: {
|
|
4127
4132
|
identifier: "Stytch.js Javascript SDK",
|
|
4128
|
-
version: "4.7.
|
|
4133
|
+
version: "4.7.7"
|
|
4129
4134
|
}
|
|
4130
4135
|
});
|
|
4131
4136
|
}
|
|
@@ -1399,8 +1399,8 @@ var Ne,
|
|
|
1399
1399
|
executeRecaptcha: o
|
|
1400
1400
|
});
|
|
1401
1401
|
case 2:
|
|
1402
|
-
return n.next = 4,
|
|
1403
|
-
return window;
|
|
1402
|
+
return n.next = 4, Be("".concat("https://elements.stytch.com", "/telemetry.js"), function () {
|
|
1403
|
+
return window.GetTelemetryID;
|
|
1404
1404
|
});
|
|
1405
1405
|
case 4:
|
|
1406
1406
|
return n.abrupt("return", {
|
|
@@ -2769,6 +2769,11 @@ var Ze = Promise.resolve({
|
|
|
2769
2769
|
value: function value() {
|
|
2770
2770
|
return this._subscriptionService.getTokens();
|
|
2771
2771
|
}
|
|
2772
|
+
}, {
|
|
2773
|
+
key: "updateSession",
|
|
2774
|
+
value: function value(e) {
|
|
2775
|
+
this._subscriptionService.updateTokens(e);
|
|
2776
|
+
}
|
|
2772
2777
|
}]), e;
|
|
2773
2778
|
}(),
|
|
2774
2779
|
ot = ve(function e(t, r) {
|
|
@@ -4001,7 +4006,7 @@ var yt = /*#__PURE__*/function () {
|
|
|
4001
4006
|
},
|
|
4002
4007
|
sdk: {
|
|
4003
4008
|
identifier: "Stytch.js Javascript SDK",
|
|
4004
|
-
version: "4.7.
|
|
4009
|
+
version: "4.7.7"
|
|
4005
4010
|
}
|
|
4006
4011
|
});
|
|
4007
4012
|
}
|
|
@@ -1310,8 +1310,8 @@ var Ne,
|
|
|
1310
1310
|
executeRecaptcha: o
|
|
1311
1311
|
});
|
|
1312
1312
|
case 2:
|
|
1313
|
-
return n.next = 4,
|
|
1314
|
-
return window;
|
|
1313
|
+
return n.next = 4, je("".concat("https://elements.stytch.com", "/telemetry.js"), function () {
|
|
1314
|
+
return window.GetTelemetryID;
|
|
1315
1315
|
});
|
|
1316
1316
|
case 4:
|
|
1317
1317
|
return n.abrupt("return", {
|
|
@@ -2680,6 +2680,11 @@ var Xe = Promise.resolve({
|
|
|
2680
2680
|
value: function value() {
|
|
2681
2681
|
return this._subscriptionService.getTokens();
|
|
2682
2682
|
}
|
|
2683
|
+
}, {
|
|
2684
|
+
key: "updateSession",
|
|
2685
|
+
value: function value(e) {
|
|
2686
|
+
this._subscriptionService.updateTokens(e);
|
|
2687
|
+
}
|
|
2683
2688
|
}]), e;
|
|
2684
2689
|
}(),
|
|
2685
2690
|
it = me(function e(t, r) {
|
|
@@ -3912,7 +3917,7 @@ var yt = /*#__PURE__*/function () {
|
|
|
3912
3917
|
},
|
|
3913
3918
|
sdk: {
|
|
3914
3919
|
identifier: "Stytch.js Javascript SDK",
|
|
3915
|
-
version: "4.7.
|
|
3920
|
+
version: "4.7.7"
|
|
3916
3921
|
}
|
|
3917
3922
|
});
|
|
3918
3923
|
}
|
package/dist/b2b/index.js
CHANGED
|
@@ -1434,8 +1434,8 @@ var Ne,
|
|
|
1434
1434
|
executeRecaptcha: i
|
|
1435
1435
|
});
|
|
1436
1436
|
case 2:
|
|
1437
|
-
return r.next = 4,
|
|
1438
|
-
return window;
|
|
1437
|
+
return r.next = 4, Le("".concat("https://elements.stytch.com", "/telemetry.js"), function () {
|
|
1438
|
+
return window.GetTelemetryID;
|
|
1439
1439
|
});
|
|
1440
1440
|
case 4:
|
|
1441
1441
|
return r.abrupt("return", {
|
|
@@ -2804,6 +2804,11 @@ var Ze = Promise.resolve({
|
|
|
2804
2804
|
value: function value() {
|
|
2805
2805
|
return this._subscriptionService.getTokens();
|
|
2806
2806
|
}
|
|
2807
|
+
}, {
|
|
2808
|
+
key: "updateSession",
|
|
2809
|
+
value: function value(e) {
|
|
2810
|
+
this._subscriptionService.updateTokens(e);
|
|
2811
|
+
}
|
|
2807
2812
|
}]), e;
|
|
2808
2813
|
}(),
|
|
2809
2814
|
it = ge(function e(t, n) {
|
|
@@ -4036,7 +4041,7 @@ var bt = /*#__PURE__*/function () {
|
|
|
4036
4041
|
},
|
|
4037
4042
|
sdk: {
|
|
4038
4043
|
identifier: "Stytch.js Javascript SDK",
|
|
4039
|
-
version: "4.7.
|
|
4044
|
+
version: "4.7.7"
|
|
4040
4045
|
}
|
|
4041
4046
|
});
|
|
4042
4047
|
}
|
package/dist/index.esm.js
CHANGED
|
@@ -1546,8 +1546,8 @@ var Ve,
|
|
|
1546
1546
|
executeRecaptcha: i
|
|
1547
1547
|
});
|
|
1548
1548
|
case 2:
|
|
1549
|
-
return r.next = 4,
|
|
1550
|
-
return window;
|
|
1549
|
+
return r.next = 4, He("".concat("https://elements.stytch.com", "/telemetry.js"), function () {
|
|
1550
|
+
return window.GetTelemetryID;
|
|
1551
1551
|
});
|
|
1552
1552
|
case 4:
|
|
1553
1553
|
return r.abrupt("return", {
|
|
@@ -3927,7 +3927,7 @@ var qt = /*#__PURE__*/function () {
|
|
|
3927
3927
|
},
|
|
3928
3928
|
sdk: {
|
|
3929
3929
|
identifier: "Stytch.js Javascript SDK",
|
|
3930
|
-
version: "4.7.
|
|
3930
|
+
version: "4.7.7"
|
|
3931
3931
|
}
|
|
3932
3932
|
});
|
|
3933
3933
|
}
|
|
@@ -302,13 +302,13 @@ var g,
|
|
|
302
302
|
}
|
|
303
303
|
return a(t, R), r(t);
|
|
304
304
|
}(),
|
|
305
|
-
|
|
305
|
+
G = function (e) {
|
|
306
306
|
function t() {
|
|
307
307
|
return i(this, t), s(this, t, ["MissingPKCEError", "Make sure this flow is completed on the same device on which it was started."]);
|
|
308
308
|
}
|
|
309
309
|
return a(t, R), r(t);
|
|
310
310
|
}(),
|
|
311
|
-
|
|
311
|
+
H = function (e) {
|
|
312
312
|
function t() {
|
|
313
313
|
return i(this, t), s(this, t, ["MissingAuthorizationCredentialIDTokenError", "The authorization credential is missing an ID token."]);
|
|
314
314
|
}
|
|
@@ -450,7 +450,7 @@ function le(e) {
|
|
|
450
450
|
case "google_onetap_missing_id_token":
|
|
451
451
|
case "oauth_apple_missing_id_token":
|
|
452
452
|
case "missing_authorization_credential_id_token":
|
|
453
|
-
return new
|
|
453
|
+
return new H();
|
|
454
454
|
case "google_onetap_missing_member":
|
|
455
455
|
case "oauth_apple_credential_invalid":
|
|
456
456
|
case "invalid_authorization_credential":
|
|
@@ -1183,7 +1183,7 @@ function qe(e, t) {
|
|
|
1183
1183
|
function We(e, t) {
|
|
1184
1184
|
return new Promise(function (r, n) {
|
|
1185
1185
|
var i = function (e) {
|
|
1186
|
-
var t =
|
|
1186
|
+
var t = Ge(e);
|
|
1187
1187
|
if (t[0]) return t[0];
|
|
1188
1188
|
}(e);
|
|
1189
1189
|
if (i && "true" === i.dataset.loaded) try {
|
|
@@ -1207,10 +1207,10 @@ function We(e, t) {
|
|
|
1207
1207
|
});
|
|
1208
1208
|
});
|
|
1209
1209
|
}
|
|
1210
|
-
var
|
|
1210
|
+
var Ge = function Ge(e) {
|
|
1211
1211
|
return document.querySelectorAll('script[src="'.concat(e, '"]'));
|
|
1212
1212
|
};
|
|
1213
|
-
var
|
|
1213
|
+
var He,
|
|
1214
1214
|
ze = ["[Stytch]"],
|
|
1215
1215
|
Ve = function Ve() {
|
|
1216
1216
|
for (var e, t = arguments.length, r = new Array(t), n = 0; n < t; n++) r[n] = arguments[n];
|
|
@@ -1414,8 +1414,8 @@ var Ge,
|
|
|
1414
1414
|
executeRecaptcha: s
|
|
1415
1415
|
});
|
|
1416
1416
|
case 2:
|
|
1417
|
-
return n.next = 4,
|
|
1418
|
-
return window;
|
|
1417
|
+
return n.next = 4, qe("".concat("https://elements.stytch.com", "/telemetry.js"), function () {
|
|
1418
|
+
return window.GetTelemetryID;
|
|
1419
1419
|
});
|
|
1420
1420
|
case 4:
|
|
1421
1421
|
return n.abrupt("return", {
|
|
@@ -1594,7 +1594,7 @@ var Ge,
|
|
|
1594
1594
|
}();
|
|
1595
1595
|
!function (e) {
|
|
1596
1596
|
e.LoginOrCreateEML = "login_or_create_eml", e.LoginOrCreateOTP = "login_or_create_otp", e.ResetPassword = "reset_password";
|
|
1597
|
-
}(
|
|
1597
|
+
}(He || (He = {}));
|
|
1598
1598
|
var nt = ye(function e(t, r) {
|
|
1599
1599
|
var n = this;
|
|
1600
1600
|
be(this, e), this._networkClient = t, this._subscriptionService = r, this.get = function () {
|
|
@@ -3744,9 +3744,9 @@ var Wt = /*#__PURE__*/function (_ct) {
|
|
|
3744
3744
|
}
|
|
3745
3745
|
return _createClass(Wt);
|
|
3746
3746
|
}(ct);
|
|
3747
|
-
var
|
|
3748
|
-
function
|
|
3749
|
-
_classCallCheck(this,
|
|
3747
|
+
var Gt = /*#__PURE__*/function () {
|
|
3748
|
+
function Gt(e, t, r, n) {
|
|
3749
|
+
_classCallCheck(this, Gt);
|
|
3750
3750
|
this._publicToken = e, this._subscriptionDataLayer = t, this.baseURL = r, this.additionalTelemetryDataFn = n, this.updateSessionToken = function () {
|
|
3751
3751
|
return null;
|
|
3752
3752
|
}, this.eventLogger = new rt({
|
|
@@ -3755,7 +3755,7 @@ var Ht = /*#__PURE__*/function () {
|
|
|
3755
3755
|
logEventURL: this.buildSDKUrl("/events")
|
|
3756
3756
|
});
|
|
3757
3757
|
}
|
|
3758
|
-
_createClass(
|
|
3758
|
+
_createClass(Gt, [{
|
|
3759
3759
|
key: "logEvent",
|
|
3760
3760
|
value: function logEvent(_ref) {
|
|
3761
3761
|
var e = _ref.name,
|
|
@@ -3786,7 +3786,7 @@ var Ht = /*#__PURE__*/function () {
|
|
|
3786
3786
|
},
|
|
3787
3787
|
sdk: {
|
|
3788
3788
|
identifier: "Stytch.js Javascript SDK",
|
|
3789
|
-
version: "4.7.
|
|
3789
|
+
version: "4.7.7"
|
|
3790
3790
|
}
|
|
3791
3791
|
});
|
|
3792
3792
|
}
|
|
@@ -3898,14 +3898,14 @@ var Ht = /*#__PURE__*/function () {
|
|
|
3898
3898
|
return "".concat(this.baseURL, "/sdk/v1").concat(e);
|
|
3899
3899
|
}
|
|
3900
3900
|
}]);
|
|
3901
|
-
return
|
|
3901
|
+
return Gt;
|
|
3902
3902
|
}();
|
|
3903
|
-
var
|
|
3904
|
-
function
|
|
3905
|
-
_classCallCheck(this,
|
|
3903
|
+
var Ht = /*#__PURE__*/function () {
|
|
3904
|
+
function Ht(e, t, r) {
|
|
3905
|
+
_classCallCheck(this, Ht);
|
|
3906
3906
|
this._googleClient = e, this._publicToken = t, this._clientId = r;
|
|
3907
3907
|
}
|
|
3908
|
-
_createClass(
|
|
3908
|
+
_createClass(Ht, [{
|
|
3909
3909
|
key: "cancel",
|
|
3910
3910
|
value: function cancel() {
|
|
3911
3911
|
this._googleClient.cancel();
|
|
@@ -3958,7 +3958,7 @@ var Gt = /*#__PURE__*/function () {
|
|
|
3958
3958
|
});
|
|
3959
3959
|
}
|
|
3960
3960
|
}]);
|
|
3961
|
-
return
|
|
3961
|
+
return Ht;
|
|
3962
3962
|
}();
|
|
3963
3963
|
var zt = /*#__PURE__*/function () {
|
|
3964
3964
|
function zt(e, t) {
|
|
@@ -4030,7 +4030,7 @@ var zt = /*#__PURE__*/function () {
|
|
|
4030
4030
|
});
|
|
4031
4031
|
case 12:
|
|
4032
4032
|
_context8.t1 = !0;
|
|
4033
|
-
_context8.t2 =
|
|
4033
|
+
_context8.t2 = Ht;
|
|
4034
4034
|
_context8.next = 16;
|
|
4035
4035
|
return qe(Ae, function () {
|
|
4036
4036
|
return window.google.accounts.id;
|
|
@@ -4627,7 +4627,7 @@ var dr = /*#__PURE__*/_createClass(function dr(e, t) {
|
|
|
4627
4627
|
var s, o, a, c, u, l, d, h, p, f, _;
|
|
4628
4628
|
this._dataLayer = sr(e, n), this._subscriptionService = new ur(e, this._dataLayer);
|
|
4629
4629
|
var m = new Yt(this._dataLayer, "passwords");
|
|
4630
|
-
this._networkClient = new
|
|
4630
|
+
this._networkClient = new Gt(e, this._dataLayer, i.endpoints.sdkBackendURL, function () {
|
|
4631
4631
|
var e, t, r, n;
|
|
4632
4632
|
return {
|
|
4633
4633
|
stytch_user_id: null === (t = null === (e = _this12._dataLayer.state) || void 0 === e ? void 0 : e.user) || void 0 === t ? void 0 : t.user_id,
|
|
@@ -4663,4 +4663,4 @@ var dr = /*#__PURE__*/_createClass(function dr(e, t) {
|
|
|
4663
4663
|
networkClient: this._networkClient
|
|
4664
4664
|
}, Object.assign(S, _defineProperty({}, lr, C));
|
|
4665
4665
|
});
|
|
4666
|
-
export { b as AuthFlowType, k as B2BMFAProducts, w as B2BOAuthProviders, g as B2BProducts, Q as BiometricsFailedError, L as BiometricsUnavailableError, Y as ChallengeSigningFailedError, q as DeviceCredentialsNotAllowedError, $ as FailedCodeChallengeError, Z as FailedToDecryptDataError, F as InternalError, z as InvalidAuthorizationCredentialError, ne as InvalidCredentialTypeError, te as InvalidRedirectSchemeError, ee as InvalidStartUrlError, se as JSONDataNotConvertibleToStringError, B as KeyInvalidatedError, M as KeystoreUnavailableError, ie as MissingAttestationObjectError,
|
|
4666
|
+
export { b as AuthFlowType, k as B2BMFAProducts, w as B2BOAuthProviders, g as B2BProducts, Q as BiometricsFailedError, L as BiometricsUnavailableError, Y as ChallengeSigningFailedError, q as DeviceCredentialsNotAllowedError, $ as FailedCodeChallengeError, Z as FailedToDecryptDataError, F as InternalError, z as InvalidAuthorizationCredentialError, ne as InvalidCredentialTypeError, te as InvalidRedirectSchemeError, ee as InvalidStartUrlError, se as JSONDataNotConvertibleToStringError, B as KeyInvalidatedError, M as KeystoreUnavailableError, ie as MissingAttestationObjectError, H as MissingAuthorizationCredentialIDTokenError, W as MissingGoogleClientIDError, G as MissingPKCEError, V as MissingPublicKeyError, re as MissingUrlError, N as NoBiometricsEnrolledError, j as NoBiometricsRegistrationError, I as NoCurrentSessionError, p as OAuthProviders, m as OTPMethods, _ as OneTapPositions, ae as PasskeysInvalidEncoding, ce as PasskeysMisconfigured, X as PasskeysUnsupportedError, h as Products, y as RNUIProducts, oe as RandomNumberGenerationFailed, S as SDKAPIUnreachableError, J as SDKNotConfiguredError, ue as SignInWithAppleMisconfigured, D as StytchAPIError, E as StytchAPISchemaError, x as StytchAPIUnreachableError, A as StytchError, v as StytchEventType, dr as StytchHeadlessClient, O as StytchSDKAPIError, R as StytchSDKError, T as StytchSDKSchemaError, C as StytchSDKUsageError, P as UNRECOVERABLE_ERROR_TYPES, U as UserCancellationError, K as UserLockedOutError, f as Wallets, le as errorToStytchError };
|
package/dist/index.headless.js
CHANGED
|
@@ -1325,8 +1325,8 @@ var Ge,
|
|
|
1325
1325
|
executeRecaptcha: s
|
|
1326
1326
|
});
|
|
1327
1327
|
case 2:
|
|
1328
|
-
return n.next = 4,
|
|
1329
|
-
return window;
|
|
1328
|
+
return n.next = 4, Ke("".concat("https://elements.stytch.com", "/telemetry.js"), function () {
|
|
1329
|
+
return window.GetTelemetryID;
|
|
1330
1330
|
});
|
|
1331
1331
|
case 4:
|
|
1332
1332
|
return n.abrupt("return", {
|
|
@@ -3697,7 +3697,7 @@ var Wt = /*#__PURE__*/function () {
|
|
|
3697
3697
|
},
|
|
3698
3698
|
sdk: {
|
|
3699
3699
|
identifier: "Stytch.js Javascript SDK",
|
|
3700
|
-
version: "4.7.
|
|
3700
|
+
version: "4.7.7"
|
|
3701
3701
|
}
|
|
3702
3702
|
});
|
|
3703
3703
|
}
|
package/dist/index.js
CHANGED
|
@@ -1457,8 +1457,8 @@ var Ze,
|
|
|
1457
1457
|
executeRecaptcha: i
|
|
1458
1458
|
});
|
|
1459
1459
|
case 2:
|
|
1460
|
-
return r.next = 4,
|
|
1461
|
-
return window;
|
|
1460
|
+
return r.next = 4, Qe("".concat("https://elements.stytch.com", "/telemetry.js"), function () {
|
|
1461
|
+
return window.GetTelemetryID;
|
|
1462
1462
|
});
|
|
1463
1463
|
case 4:
|
|
1464
1464
|
return r.abrupt("return", {
|
|
@@ -3838,7 +3838,7 @@ var Kt = /*#__PURE__*/function () {
|
|
|
3838
3838
|
},
|
|
3839
3839
|
sdk: {
|
|
3840
3840
|
identifier: "Stytch.js Javascript SDK",
|
|
3841
|
-
version: "4.7.
|
|
3841
|
+
version: "4.7.7"
|
|
3842
3842
|
}
|
|
3843
3843
|
});
|
|
3844
3844
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stytch/vanilla-js",
|
|
3
|
-
"version": "4.7.
|
|
3
|
+
"version": "4.7.7",
|
|
4
4
|
"description": "Stytch's official Javascript Client Library",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.esm.js",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"hoistingLimits": "workspaces"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@stytch/core": "2.
|
|
40
|
+
"@stytch/core": "2.11.0",
|
|
41
41
|
"@types/google-one-tap": "^1.2.0"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|