1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7359],{1450:(e,o,r)=>{r.d(o,{Tt:()=>n});function n(e,o){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>o.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var t=0,n=Object.getOwnPropertySymbols(e);t<n.length;t++)0>o.indexOf(n[t])&&Object.prototype.propertyIsEnumerable.call(e,n[t])&&(r[n[t]]=e[n[t]]);return r}Object.create;Object.create,"function"==typeof SuppressedError&&SuppressedError},7359:(e,o,r)=>{r.r(o),r.d(o,{SocialLogin:()=>a,SocialLoginAuthConnect:()=>E,SocialLoginBase:()=>i,createAuthConnectClient:()=>z});let n=(0,r(2587).F3)("SocialLogin",{web:()=>r.e(7386).then(r.bind(r,7386)).then(e=>new e.SocialLoginWeb)});class t{constructor(){this.initialize=this.initialize.bind(this),this.refresh=this.refresh.bind(this)}async initialize(e){await n.initialize(e),this.initializeOptions=e}async login(e){return n.login(e)}async logout(e){return n.logout(e)}async isLoggedIn(e){return n.isLoggedIn(e)}async getAuthorizationCode(e){return n.getAuthorizationCode(e)}async refresh(e){var o,r;return"google"===e.provider&&(null==(r=null==(o=this.initializeOptions)?void 0:o.google)?void 0:r.mode)==="offline"&&console.warn("[SocialLogin] Google refresh() is not available when using offline mode. Offline mode only returns serverAuthCode for backend token exchange. Send serverAuthCode to your backend and refresh tokens there, or switch google.mode to 'online' for client-side refresh."),n.refresh(e)}async refreshToken(e){return n.refreshToken(e)}async handleRedirectCallback(){return n.handleRedirectCallback()}async decodeIdToken(e){return n.decodeIdToken(e)}async getAccessTokenExpirationDate(e){return n.getAccessTokenExpirationDate(e)}async isAccessTokenAvailable(e){return n.isAccessTokenAvailable(e)}async isAccessTokenExpired(e){return n.isAccessTokenExpired(e)}async isRefreshTokenAvailable(e){return n.isRefreshTokenAvailable(e)}async providerSpecificCall(e){return n.providerSpecificCall(e)}async getPluginVersion(){return n.getPluginVersion()}async openSecureWindow(e){return n.openSecureWindow(e)}}let i=n,a=new t;var l=r(1450);let s=["auth0","azure","cognito","okta","onelogin"],u={auth0:"openid profile email offline_access",azure:"openid profile email",cognito:"openid profile email",okta:"openid profile email offline_access",onelogin:"openid profile email"},c={azure:"https://graph.microsoft.com/v1.0/me"},d=e=>e.startsWith("http://")||e.startsWith("https://")?e:`https://${e}`,h=e=>e.replace(/\/+$/,""),g=(e,o)=>{let r=h(e),n=o.replace(/^\/+/,"");return`${r}/${n}`},p=(e,o)=>{if(e||o)return Object.assign(Object.assign({},null!=e?e:{}),null!=o?o:{})},f=(e,o)=>{if(!o.clientId)throw Error(`[authConnect] ${e} requires clientId.`);if(!o.redirectUrl)throw Error(`[authConnect] ${e} requires redirectUrl.`)},k=(e,o,r)=>{var n,t,i,a,l,s,c,d,h,g,f,k;let v=p(r.additionalParameters,o.additionalParameters),y=p(r.additionalResourceHeaders,o.additionalResourceHeaders),b={appId:o.clientId,authorizationBaseUrl:null!=(t=null!=(n=o.authorizationBaseUrl)?n:r.authorizationBaseUrl)?t:"",accessTokenEndpoint:null!=(i=o.accessTokenEndpoint)?i:r.accessTokenEndpoint,redirectUrl:o.redirectUrl,resourceUrl:null!=(a=o.resourceUrl)?a:r.resourceUrl,responseType:null!=(s=null!=(l=o.responseType)?l:r.responseType)?s:"code",pkceEnabled:null==(d=null!=(c=o.pkceEnabled)?c:r.pkceEnabled)||d,scope:null!=(g=null!=(h=o.scope)?h:r.scope)?g:u[e],additionalParameters:v,additionalResourceHeaders:y,logoutUrl:null!=(f=o.logoutUrl)?f:r.logoutUrl,logsEnabled:null!=(k=o.logsEnabled)?k:r.logsEnabled};if(!b.authorizationBaseUrl)throw Error(`[authConnect] ${e} authorizationBaseUrl is required.`);return b},v=e=>s.includes(e),y=e=>{var o;return v(e.provider)?{provider:"oauth2",options:Object.assign({providerId:e.provider},null!=(o=e.options)?o:{})}:e},b=e=>v(e.provider)?{provider:"oauth2",providerId:e.provider}:e,z=e=>({initialize:async o=>{let{authConnect:r,oauth2:n}=o,t=(0,l.Tt)(o,["authConnect","oauth2"]),i=((e,o)=>Object.keys(e).length||o?Object.assign(Object.assign({},e),null!=o?o:{}):o)((e=>{if(!e)return{};let o={};return e.auth0&&(o.auth0=(e=>{if(f("auth0",e),!e.domain)throw Error("[authConnect] auth0 requires domain.");let o=h(d(e.domain));return k("auth0",e,{authorizationBaseUrl:g(o,"authorize"),accessTokenEndpoint:g(o,"oauth/token"),resourceUrl:g(o,"userinfo"),logoutUrl:g(o,"v2/logout"),additionalParameters:e.audience?{audience:e.audience}:void 0})})(e.auth0)),e.azure&&(o.azure=(e=>{var o,r;f("azure",e);let n=null!=(o=e.tenantId)?o:"common",t=g(h(d(null!=(r=e.authorityHost)?r:"https://login.microsoftonline.com")),`${n}/oauth2/v2.0`);return k("azure",e,{authorizationBaseUrl:g(t,"authorize"),accessTokenEndpoint:g(t,"token"),resourceUrl:c.azure})})(e.azure)),e.cognito&&(o.cognito=(e=>{if(f("cognito",e),!e.domain)throw Error("[authConnect] cognito requires domain.");let o=h(d(e.domain));return k("cognito",e,{authorizationBaseUrl:g(o,"oauth2/authorize"),accessTokenEndpoint:g(o,"oauth2/token"),resourceUrl:g(o,"oauth2/userInfo"),logoutUrl:g(o,"logout")})})(e.cognito)),e.okta&&(o.okta=(e=>{if(f("okta",e),!e.issuer)throw Error("[authConnect] okta requires issuer.");let o=h(d(e.issuer));return k("okta",e,{authorizationBaseUrl:g(o,"v1/authorize"),accessTokenEndpoint:g(o,"v1/token"),resourceUrl:g(o,"v1/userinfo"),logoutUrl:g(o,"v1/logout")})})(e.okta)),e.onelogin&&(o.onelogin=(e=>{if(f("onelogin",e),!e.issuer)throw Error("[authConnect] onelogin requires issuer.");let o=h(d(e.issuer));return k("onelogin",e,{authorizationBaseUrl:g(o,"auth"),accessTokenEndpoint:g(o,"token"),resourceUrl:g(o,"me"),logoutUrl:g(o,"logout")})})(e.onelogin)),o})(r),n),a=Object.assign(Object.assign({},t),i?{oauth2:i}:{});return e.initialize(a)},login:async o=>{if(v(o.provider)){let r=y(o),n=await e.login(r);return{provider:o.provider,result:n.result}}return e.login(o)},logout:async o=>e.logout(b(o)),isLoggedIn:async o=>e.isLoggedIn(b(o)),getAuthorizationCode:async o=>e.getAuthorizationCode(b(o)),refresh:async o=>e.refresh(y(o)),providerSpecificCall:async o=>e.providerSpecificCall(o),getPluginVersion:async()=>e.getPluginVersion()}),E=z(i)}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.