@tapni/auth 1.0.49 → 1.0.52

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tapni/auth",
3
- "version": "1.0.49",
3
+ "version": "1.0.52",
4
4
  "type": "module",
5
5
  "main": "./dist/TapniAuth.umd.js",
6
6
  "module": "./dist/TapniAuth.es.js",
package/src/main.js CHANGED
@@ -45,7 +45,7 @@ router.beforeEach((to, from, next) => {
45
45
  * @param data
46
46
  */
47
47
  function redirectToProfile(data) {
48
- if (data && data.url) {
48
+ if (data && data.url && data.url !== '/undefined') {
49
49
  let url = new URL(data.url);
50
50
  let pathname = url.pathname || '';
51
51
  let queryParams = url.search || '';
@@ -63,7 +63,7 @@
63
63
  :isClearable="false"
64
64
  placeholder="Select region"
65
65
  />
66
- <p>Default currency for this region is {{account.billing?.currency?.toUpperCase()}}</p>
66
+ <p v-if="false">Default currency for this region is {{account.billing?.currency?.toUpperCase()}}</p>
67
67
 
68
68
 
69
69
  <h3 class="full-top bold">{{ssoLang[appLanguage].app_language}}</h3>
@@ -126,6 +126,19 @@ export default {
126
126
  loading: false,
127
127
  }
128
128
  },
129
+ watch: {
130
+ 'account.lang': {
131
+ handler(newLang) {
132
+ if (newLang) {
133
+ this.updateLang(newLang);
134
+ if (this.display === 'npm') {
135
+ this.$store.commit('setLanguage', newLang);
136
+ }
137
+ }
138
+ },
139
+ immediate: true
140
+ }
141
+ },
129
142
  async mounted() {
130
143
  if (!this.isLoggedIn) this.$router.push('/login');
131
144
  if (this.isEmpty(this.account)) this.$router.push('/account');
@@ -361,7 +361,6 @@ export default {
361
361
  else {
362
362
  ssoTypes = Object.keys(response.sso);
363
363
  if (!ssoTypes.length) {
364
- this.forceClose();
365
364
  return this.errorSnack(this.ssoLang[this.appLanguage].no_sso_logins);
366
365
  } else {
367
366
  if (ssoTypes[0] === "azure")