@schibsted/account-sdk-browser 5.2.1 → 5.2.3

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/es5/global.js CHANGED
@@ -1865,7 +1865,7 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
1865
1865
  * `password` (will force password confirmation, even if user is already logged in), `eid`. Those values might
1866
1866
  * be mixed as space-separated string. To make sure that user has authenticated with 2FA you need
1867
1867
  * to verify AMR (Authentication Methods References) claim in ID token.
1868
- * Might also be used to ensure additional acr (sms, otp) for already logged in users.
1868
+ * Might also be used to ensure additional acr (sms, otp) for already logged-in users.
1869
1869
  * Supported value is also 'otp-email' means one time password using email.
1870
1870
  * @property {string} [scope] - The OAuth scopes for the tokens. This is a list of
1871
1871
  * scopes, separated by space. If the list of scopes contains `openid`, the generated tokens
@@ -1875,7 +1875,7 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
1875
1875
  * @property {string} [redirectUri] - Redirect uri that will receive the
1876
1876
  * code. Must exactly match a redirectUri from your client in self-service
1877
1877
  * @property {boolean} [preferPopup] - Should we try to open a popup window?
1878
- * @property {string} [loginHint] - user email or UUID hint
1878
+ * @property {string} [loginHint] - User email or UUID hint
1879
1879
  * @property {string} [tag] - Pulse tag
1880
1880
  * @property {string} [teaser] - Teaser slug. Teaser with given slug will be displayed
1881
1881
  * in place of default teaser
@@ -1885,9 +1885,12 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
1885
1885
  * spec section 3.1.2.1 for more information
1886
1886
  * @property {string} [locale] - Optional parameter to overwrite client locale setting.
1887
1887
  * New flows supports nb_NO, fi_FI, sv_SE, en_US
1888
- * @property {boolean} [oneStepLogin] - display username and password on one screen
1888
+ * @property {boolean} [oneStepLogin] - Display username and password on one screen
1889
1889
  * @property {string} [prompt] - String that specifies whether the Authorization Server prompts the
1890
- * End-User for reauthentication or confirm account screen. Supported values: `select_account` or `login`
1890
+ * End-User for re-authentication or confirm account screen. Supported values: `select_account` or `login`
1891
+ * @property {string} [xDomainId] - Identifier for cross-domain tracking in Pulse
1892
+ * @property {string} [xEnvironmentId] - Environment for cross-domain tracking in Pulse
1893
+ * @property {string} [originCampaign] - Campaign identifier for tracking in Pulse
1891
1894
  */
1892
1895
  /**
1893
1896
  * @typedef {object} SimplifiedLoginWidgetLoginOptions
@@ -1899,7 +1902,7 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
1899
1902
  * `password` (will force password confirmation, even if user is already logged in). Those values might
1900
1903
  * be mixed as space-separated string. To make sure that user has authenticated with 2FA you need
1901
1904
  * to verify AMR (Authentication Methods References) claim in ID token.
1902
- * Might also be used to ensure additional acr (sms, otp) for already logged in users.
1905
+ * Might also be used to ensure additional acr (sms, otp) for already logged-in users.
1903
1906
  * Supported value is also 'otp-email' means one time password using email.
1904
1907
  * @property {string} [scope] - The OAuth scopes for the tokens. This is a list of
1905
1908
  * scopes, separated by space. If the list of scopes contains `openid`, the generated tokens
@@ -1909,7 +1912,7 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
1909
1912
  * @property {string} [redirectUri] - Redirect uri that will receive the
1910
1913
  * code. Must exactly match a redirectUri from your client in self-service
1911
1914
  * @property {boolean} [preferPopup] - Should we try to open a popup window?
1912
- * @property {string} [loginHint] - user email or UUID hint
1915
+ * @property {string} [loginHint] - User email or UUID hint
1913
1916
  * @property {string} [tag] - Pulse tag
1914
1917
  * @property {string} [teaser] - Teaser slug. Teaser with given slug will be displayed
1915
1918
  * in place of default teaser
@@ -1919,9 +1922,12 @@ function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.g
1919
1922
  * spec section 3.1.2.1 for more information
1920
1923
  * @property {string} [locale] - Optional parameter to overwrite client locale setting.
1921
1924
  * New flows supports nb_NO, fi_FI, sv_SE, en_US
1922
- * @property {boolean} [oneStepLogin] - display username and password on one screen
1925
+ * @property {boolean} [oneStepLogin] - Display username and password on one screen
1923
1926
  * @property {string} [prompt] - String that specifies whether the Authorization Server prompts the
1924
1927
  * End-User for reauthentication or confirm account screen. Supported values: `select_account` or `login`
1928
+ * @property {string} [xDomainId] - Identifier for cross-domain tracking in Pulse
1929
+ * @property {string} [xEnvironmentId] - Environment for cross-domain tracking in Pulse
1930
+ * @property {string} [originCampaign] - Campaign identifier for tracking in Pulse
1925
1931
  */
1926
1932
 
1927
1933
  /**
@@ -2051,7 +2057,7 @@ var Identity = /*#__PURE__*/function (_EventEmitter) {
2051
2057
  // Old session
2052
2058
  _this._session = {};
2053
2059
  _this._setSessionServiceUrl(sessionDomain);
2054
- _this._usedSessionServiceGetSessionEndpoint = _this._sessionService.url.pathname && _this._sessionService.url.pathname.length <= 1 ? 'session' : 'v2/session';
2060
+ _this._usedSessionServiceGetSessionEndpoint = _this._sessionService.url.pathname && _this._sessionService.url.pathname.length <= 1 ? 'v2/session' : 'session';
2055
2061
  _this._setSpidServerUrl(env);
2056
2062
  _this._setBffServerUrl(env);
2057
2063
  _this._setOauthServerUrl(env);
@@ -2940,6 +2946,8 @@ var Identity = /*#__PURE__*/function (_EventEmitter) {
2940
2946
  * @param {boolean} [options.oneStepLogin=false]
2941
2947
  * @param {string} [options.prompt=select_account]
2942
2948
  * @param {string} [options.xDomainId]
2949
+ * @param {string} [options.xEnvironmentId]
2950
+ * @param {string} [options.originCampaign]
2943
2951
  * @return {Window|null} - Reference to popup window if created (or `null` otherwise)
2944
2952
  */
2945
2953
  }, {
@@ -2969,7 +2977,11 @@ var Identity = /*#__PURE__*/function (_EventEmitter) {
2969
2977
  _ref4$prompt = _ref4.prompt,
2970
2978
  prompt = _ref4$prompt === void 0 ? 'select_account' : _ref4$prompt,
2971
2979
  _ref4$xDomainId = _ref4.xDomainId,
2972
- xDomainId = _ref4$xDomainId === void 0 ? '' : _ref4$xDomainId;
2980
+ xDomainId = _ref4$xDomainId === void 0 ? '' : _ref4$xDomainId,
2981
+ _ref4$xEnvironmentId = _ref4.xEnvironmentId,
2982
+ xEnvironmentId = _ref4$xEnvironmentId === void 0 ? '' : _ref4$xEnvironmentId,
2983
+ _ref4$originCampaign = _ref4.originCampaign,
2984
+ originCampaign = _ref4$originCampaign === void 0 ? '' : _ref4$originCampaign;
2973
2985
  this._closePopup();
2974
2986
  this.sessionStorageCache.delete(HAS_SESSION_CACHE_KEY);
2975
2987
  var url = this.loginUrl({
@@ -2984,7 +2996,9 @@ var Identity = /*#__PURE__*/function (_EventEmitter) {
2984
2996
  locale: locale,
2985
2997
  oneStepLogin: oneStepLogin,
2986
2998
  prompt: prompt,
2987
- xDomainId: xDomainId
2999
+ xDomainId: xDomainId,
3000
+ xEnvironmentId: xEnvironmentId,
3001
+ originCampaign: originCampaign
2988
3002
  });
2989
3003
  if (preferPopup) {
2990
3004
  this.popup = _popup_js__WEBPACK_IMPORTED_MODULE_61__["open"](this.window, url, 'Schibsted account', {
@@ -3065,6 +3079,9 @@ var Identity = /*#__PURE__*/function (_EventEmitter) {
3065
3079
  * @param {string} [options.locale]
3066
3080
  * @param {boolean} [options.oneStepLogin=false]
3067
3081
  * @param {string} [options.prompt=select_account]
3082
+ * @param {string} [options.xDomainId]
3083
+ * @param {string} [options.xEnvironmentId]
3084
+ * @param {string} [options.originCampaign]
3068
3085
  * @return {string} - The url
3069
3086
  */
3070
3087
  }, {
@@ -3092,7 +3109,11 @@ var Identity = /*#__PURE__*/function (_EventEmitter) {
3092
3109
  _ref5$prompt = _ref5.prompt,
3093
3110
  prompt = _ref5$prompt === void 0 ? 'select_account' : _ref5$prompt,
3094
3111
  _ref5$xDomainId = _ref5.xDomainId,
3095
- xDomainId = _ref5$xDomainId === void 0 ? '' : _ref5$xDomainId;
3112
+ xDomainId = _ref5$xDomainId === void 0 ? '' : _ref5$xDomainId,
3113
+ _ref5$xEnvironmentId = _ref5.xEnvironmentId,
3114
+ xEnvironmentId = _ref5$xEnvironmentId === void 0 ? '' : _ref5$xEnvironmentId,
3115
+ _ref5$originCampaign = _ref5.originCampaign,
3116
+ originCampaign = _ref5$originCampaign === void 0 ? '' : _ref5$originCampaign;
3096
3117
  if (_typeof(arguments[0]) !== 'object') {
3097
3118
  // backward compatibility
3098
3119
  state = arguments[0];
@@ -3123,7 +3144,9 @@ var Identity = /*#__PURE__*/function (_EventEmitter) {
3123
3144
  locale: locale,
3124
3145
  one_step_login: oneStepLogin || '',
3125
3146
  prompt: acrValues ? '' : prompt,
3126
- x_domain_id: xDomainId
3147
+ x_domain_id: xDomainId,
3148
+ x_env_id: xEnvironmentId,
3149
+ utm_campaign: originCampaign
3127
3150
  });
3128
3151
  }
3129
3152
 
@@ -12177,7 +12200,7 @@ __webpack_require__.r(__webpack_exports__);
12177
12200
 
12178
12201
 
12179
12202
 
12180
- var version = '5.2.1';
12203
+ var version = '5.2.3';
12181
12204
  /* harmony default export */ __webpack_exports__["default"] = (version);
12182
12205
 
12183
12206
  /***/ }),