@intra-mart/smartlime 1.2.0 → 1.3.0

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.
@@ -84,7 +84,10 @@ const useLogin = (props, webviewRef) => {
84
84
  `);
85
85
  }
86
86
  else if (currentUrlRef.current === logoutUrl) {
87
- webviewRef.current?.injectJavaScript(`
87
+ const url = new URL(event.nativeEvent.url);
88
+ // because im_hybrid_sso may be called in the logoutUrl as an iframe when IM-HybridSSO is enabled
89
+ if (join(url.origin, url.pathname).replace(/\/$/, '') === logoutUrl) {
90
+ webviewRef.current?.injectJavaScript(`
88
91
  fetch('${getSessionUrl}', {
89
92
  headers: {
90
93
  'X-Intramart-Session': 'keep',
@@ -98,6 +101,7 @@ const useLogin = (props, webviewRef) => {
98
101
  });
99
102
  true;
100
103
  `);
104
+ }
101
105
  }
102
106
  else if (currentUrlRef.current === targetUrl && !isLogin) {
103
107
  setIsLogin(true);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@intra-mart/smartlime",
3
3
  "description": "expoで使用できるintra mart accelplatform SDK",
4
- "version": "1.2.0",
4
+ "version": "1.3.0",
5
5
  "keywords": [
6
6
  "intra-mart",
7
7
  "AccelPlatform",