@rxap/oauth 12.0.9 → 12.1.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.
- package/bundles/rxap-oauth-single-sign-on.umd.js +29 -31
- package/bundles/rxap-oauth-single-sign-on.umd.js.map +1 -1
- package/bundles/rxap-oauth.umd.js +86 -62
- package/bundles/rxap-oauth.umd.js.map +1 -1
- package/esm2015/lib/container/container.component.js +3 -3
- package/esm2015/lib/container/container.component.js.map +1 -1
- package/esm2015/lib/container/container.component.module.js +4 -4
- package/esm2015/lib/container/container.component.module.js.map +1 -1
- package/esm2015/lib/get-o-auth-profile.method.js +3 -3
- package/esm2015/lib/get-o-auth-profile.method.js.map +1 -1
- package/esm2015/lib/loading/loading.component.js +3 -3
- package/esm2015/lib/loading/loading.component.js.map +1 -1
- package/esm2015/lib/loading/loading.component.module.js +4 -4
- package/esm2015/lib/loading/loading.component.module.js.map +1 -1
- package/esm2015/lib/o-auth-extract.guard.js +3 -3
- package/esm2015/lib/o-auth-extract.guard.js.map +1 -1
- package/esm2015/lib/o-auth-redirect.guard.js +3 -3
- package/esm2015/lib/o-auth-redirect.guard.js.map +1 -1
- package/esm2015/lib/o-auth-routing.module.js +4 -4
- package/esm2015/lib/o-auth-routing.module.js.map +1 -1
- package/esm2015/lib/o-auth.method.js +12 -7
- package/esm2015/lib/o-auth.method.js.map +1 -1
- package/esm2015/lib/o-auth.module.js +4 -4
- package/esm2015/lib/o-auth.module.js.map +1 -1
- package/esm2015/lib/o-auth.service.js +23 -4
- package/esm2015/lib/o-auth.service.js.map +1 -1
- package/esm2015/lib/profile.resolve.js +3 -3
- package/esm2015/lib/profile.resolve.js.map +1 -1
- package/esm2015/lib/sign-in-with-redirect/sign-in-with-redirect.component.js +3 -3
- package/esm2015/lib/sign-in-with-redirect/sign-in-with-redirect.component.js.map +1 -1
- package/esm2015/lib/sign-in-with-redirect/sign-in-with-redirect.component.module.js +4 -4
- package/esm2015/lib/sign-in-with-redirect/sign-in-with-redirect.component.module.js.map +1 -1
- package/esm2015/single-sign-on/lib/continue/continue.component.js +3 -3
- package/esm2015/single-sign-on/lib/continue/continue.component.js.map +1 -1
- package/esm2015/single-sign-on/lib/continue/continue.component.module.js +4 -4
- package/esm2015/single-sign-on/lib/continue/continue.component.module.js.map +1 -1
- package/esm2015/single-sign-on/lib/error/error.component.js +3 -3
- package/esm2015/single-sign-on/lib/error/error.component.js.map +1 -1
- package/esm2015/single-sign-on/lib/error/error.component.module.js +4 -4
- package/esm2015/single-sign-on/lib/error/error.component.module.js.map +1 -1
- package/esm2015/single-sign-on/lib/o-auth-single-sign-on-routing.module.js +4 -4
- package/esm2015/single-sign-on/lib/o-auth-single-sign-on-routing.module.js.map +1 -1
- package/esm2015/single-sign-on/lib/o-auth-single-sign-on.guard.js +3 -3
- package/esm2015/single-sign-on/lib/o-auth-single-sign-on.guard.js.map +1 -1
- package/esm2015/single-sign-on/lib/o-auth-single-sign-on.service.js +3 -3
- package/esm2015/single-sign-on/lib/o-auth-single-sign-on.service.js.map +1 -1
- package/fesm2015/rxap-oauth-single-sign-on.js +24 -24
- package/fesm2015/rxap-oauth-single-sign-on.js.map +1 -1
- package/fesm2015/rxap-oauth.js +77 -53
- package/fesm2015/rxap-oauth.js.map +1 -1
- package/lib/o-auth.method.d.ts +2 -0
- package/lib/o-auth.service.d.ts +7 -2
- package/package.json +15 -5
- package/src/schematics/ng-add/index.js +1 -1
- package/src/schematics/ng-add/index.js.map +1 -1
package/fesm2015/rxap-oauth.js
CHANGED
|
@@ -5,6 +5,8 @@ import { HttpClient, HttpHeaders } from '@angular/common/http';
|
|
|
5
5
|
import { __awaiter } from 'tslib';
|
|
6
6
|
import * as i1$1 from '@angular/router';
|
|
7
7
|
import { Router, RouterModule } from '@angular/router';
|
|
8
|
+
import { ReplaySubject } from 'rxjs';
|
|
9
|
+
import { AuthenticationEventType } from '@rxap/authentication';
|
|
8
10
|
import { trigger, transition, style, animate, state } from '@angular/animations';
|
|
9
11
|
import * as i1$2 from '@angular/material/progress-bar';
|
|
10
12
|
import { MatProgressBarModule } from '@angular/material/progress-bar';
|
|
@@ -39,9 +41,9 @@ class GetOAuthProfileMethod {
|
|
|
39
41
|
.toPromise();
|
|
40
42
|
}
|
|
41
43
|
}
|
|
42
|
-
GetOAuthProfileMethod.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
43
|
-
GetOAuthProfileMethod.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.
|
|
44
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
44
|
+
GetOAuthProfileMethod.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: GetOAuthProfileMethod, deps: [{ token: HttpClient }, { token: PROFILE_AUTH_ENDPOINT, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
45
|
+
GetOAuthProfileMethod.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: GetOAuthProfileMethod, providedIn: 'root' });
|
|
46
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: GetOAuthProfileMethod, decorators: [{
|
|
45
47
|
type: Injectable,
|
|
46
48
|
args: [{ providedIn: 'root' }]
|
|
47
49
|
}], ctorParameters: function () { return [{ type: i1.HttpClient, decorators: [{
|
|
@@ -123,10 +125,15 @@ class OAuthMethod {
|
|
|
123
125
|
default:
|
|
124
126
|
throw new Error('Not supported grant type');
|
|
125
127
|
}
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
128
|
+
let headers = new HttpHeaders();
|
|
129
|
+
headers = headers.append('Content-type', 'application/x-www-form-urlencoded; charset=utf-8');
|
|
130
|
+
if (parameters.secret && parameters.clientId) {
|
|
131
|
+
params.append('client_id', parameters.clientId);
|
|
132
|
+
params.append('client_secret', parameters.secret);
|
|
133
|
+
}
|
|
134
|
+
else {
|
|
135
|
+
headers = headers.append('Authorization', `Basic ${parameters.secret}`);
|
|
136
|
+
}
|
|
130
137
|
const response = yield this.http
|
|
131
138
|
.post(parameters.authEndpoint, params.toString(), {
|
|
132
139
|
headers,
|
|
@@ -154,9 +161,9 @@ class OAuthMethod {
|
|
|
154
161
|
throw new Error('Could not guess the grant type');
|
|
155
162
|
}
|
|
156
163
|
}
|
|
157
|
-
OAuthMethod.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
158
|
-
OAuthMethod.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.
|
|
159
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
164
|
+
OAuthMethod.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthMethod, deps: [{ token: HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
165
|
+
OAuthMethod.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthMethod, providedIn: 'root' });
|
|
166
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthMethod, decorators: [{
|
|
160
167
|
type: Injectable,
|
|
161
168
|
args: [{ providedIn: 'root' }]
|
|
162
169
|
}], ctorParameters: function () { return [{ type: i1.HttpClient, decorators: [{
|
|
@@ -183,12 +190,13 @@ const RXAP_O_AUTH_REDIRECT_URL = new InjectionToken('rxap/o-auth/redirect-url',
|
|
|
183
190
|
const OAUTH_SECRET = new InjectionToken('OAUTH_SECRET');
|
|
184
191
|
const OAUTH_AUTH_ENDPOINT = new InjectionToken('OAUTH_AUTH_ENDPOINT');
|
|
185
192
|
const OAUTH_SSO_URL = new InjectionToken('OAUTH_SSO_URL');
|
|
193
|
+
const OAUTH_CLIENT_ID = new InjectionToken('OAUTH_CLIENT_ID');
|
|
186
194
|
const ACCESS_TOKEN_LOCAL_STORAGE_KEY = 'access_token';
|
|
187
195
|
const REFRESH_TOKEN_LOCAL_STORAGE_KEY = 'refresh_token';
|
|
188
196
|
const EXPIRES_AT_LOCAL_STORAGE_KEY = 'expires_at';
|
|
189
197
|
const REMEMBER_LOCAL_STORAGE_KEY = 'remember';
|
|
190
198
|
class OAuthService {
|
|
191
|
-
constructor(oAuthMethod, getOAuthProfileMethod, router, profileEndpoint = null, authEndpoint = null, secret = null, ssoUrl = null, redirectSignOut = null, redirectUrl = null) {
|
|
199
|
+
constructor(oAuthMethod, getOAuthProfileMethod, router, profileEndpoint = null, authEndpoint = null, secret = null, ssoUrl = null, redirectSignOut = null, redirectUrl = null, clientId = null) {
|
|
192
200
|
this.oAuthMethod = oAuthMethod;
|
|
193
201
|
this.getOAuthProfileMethod = getOAuthProfileMethod;
|
|
194
202
|
this.router = router;
|
|
@@ -198,6 +206,8 @@ class OAuthService {
|
|
|
198
206
|
this.ssoUrl = ssoUrl;
|
|
199
207
|
this.redirectSignOut = redirectSignOut;
|
|
200
208
|
this.redirectUrl = redirectUrl;
|
|
209
|
+
this.clientId = clientId;
|
|
210
|
+
this.events$ = new ReplaySubject();
|
|
201
211
|
this._isAuthenticated = null;
|
|
202
212
|
}
|
|
203
213
|
get expiresAt() {
|
|
@@ -320,6 +330,7 @@ class OAuthService {
|
|
|
320
330
|
});
|
|
321
331
|
}
|
|
322
332
|
signInWithEmailAndPassword(email, password, remember) {
|
|
333
|
+
var _a;
|
|
323
334
|
return __awaiter(this, void 0, void 0, function* () {
|
|
324
335
|
if (!this.secret) {
|
|
325
336
|
throw new Error('The oauth secret is not defined');
|
|
@@ -332,6 +343,10 @@ class OAuthService {
|
|
|
332
343
|
password: password,
|
|
333
344
|
authEndpoint: this.authEndpoint,
|
|
334
345
|
secret: this.secret,
|
|
346
|
+
clientId: (_a = this.clientId) !== null && _a !== void 0 ? _a : undefined
|
|
347
|
+
}).catch(e => {
|
|
348
|
+
this.events$.next({ type: AuthenticationEventType.OnAuthError });
|
|
349
|
+
throw e;
|
|
335
350
|
});
|
|
336
351
|
this.authenticated(response, remember);
|
|
337
352
|
return response;
|
|
@@ -376,6 +391,7 @@ class OAuthService {
|
|
|
376
391
|
}
|
|
377
392
|
location.replace(`${this.ssoUrl}?redirect=${btoa(this.redirectUrl)}&secret=${this.secret}&action=signOut`);
|
|
378
393
|
}
|
|
394
|
+
this.events$.next({ type: AuthenticationEventType.OnLogout });
|
|
379
395
|
});
|
|
380
396
|
}
|
|
381
397
|
authenticated(response, remember) {
|
|
@@ -404,6 +420,7 @@ class OAuthService {
|
|
|
404
420
|
this.removeItem(EXPIRES_AT_LOCAL_STORAGE_KEY);
|
|
405
421
|
}
|
|
406
422
|
this._isAuthenticated = true;
|
|
423
|
+
this.events$.next({ type: AuthenticationEventType.OnAuthSuccess });
|
|
407
424
|
}
|
|
408
425
|
getKey(key) {
|
|
409
426
|
return [this.secret, key].join('__');
|
|
@@ -424,6 +441,7 @@ class OAuthService {
|
|
|
424
441
|
this.removeItem(EXPIRES_AT_LOCAL_STORAGE_KEY);
|
|
425
442
|
}
|
|
426
443
|
signInWithRefreshToken(refreshToken) {
|
|
444
|
+
var _a;
|
|
427
445
|
return __awaiter(this, void 0, void 0, function* () {
|
|
428
446
|
if (!this.secret) {
|
|
429
447
|
throw new Error('The oauth secret is not defined');
|
|
@@ -435,15 +453,16 @@ class OAuthService {
|
|
|
435
453
|
refreshToken,
|
|
436
454
|
authEndpoint: this.authEndpoint,
|
|
437
455
|
secret: this.secret,
|
|
456
|
+
clientId: (_a = this.clientId) !== null && _a !== void 0 ? _a : undefined,
|
|
438
457
|
});
|
|
439
458
|
this.authenticated(response);
|
|
440
459
|
return response;
|
|
441
460
|
});
|
|
442
461
|
}
|
|
443
462
|
}
|
|
444
|
-
OAuthService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
445
|
-
OAuthService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.
|
|
446
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
463
|
+
OAuthService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthService, deps: [{ token: OAuthMethod }, { token: GetOAuthProfileMethod }, { token: Router }, { token: PROFILE_AUTH_ENDPOINT, optional: true }, { token: OAUTH_AUTH_ENDPOINT, optional: true }, { token: OAUTH_SECRET, optional: true }, { token: OAUTH_SSO_URL, optional: true }, { token: RXAP_O_AUTH_REDIRECT_SIGN_OUT, optional: true }, { token: RXAP_O_AUTH_REDIRECT_URL, optional: true }, { token: OAUTH_CLIENT_ID, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
464
|
+
OAuthService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthService, providedIn: 'root' });
|
|
465
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthService, decorators: [{
|
|
447
466
|
type: Injectable,
|
|
448
467
|
args: [{ providedIn: 'root' }]
|
|
449
468
|
}], ctorParameters: function () { return [{ type: OAuthMethod, decorators: [{
|
|
@@ -485,6 +504,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
|
|
|
485
504
|
}, {
|
|
486
505
|
type: Inject,
|
|
487
506
|
args: [RXAP_O_AUTH_REDIRECT_URL]
|
|
507
|
+
}] }, { type: undefined, decorators: [{
|
|
508
|
+
type: Optional
|
|
509
|
+
}, {
|
|
510
|
+
type: Inject,
|
|
511
|
+
args: [OAUTH_CLIENT_ID]
|
|
488
512
|
}] }]; } });
|
|
489
513
|
|
|
490
514
|
class OAuthExtractGuard {
|
|
@@ -529,9 +553,9 @@ class OAuthExtractGuard {
|
|
|
529
553
|
return this.router.createUrlTree([...route.url.map(url => url.path), 'redirect']);
|
|
530
554
|
}
|
|
531
555
|
}
|
|
532
|
-
OAuthExtractGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
533
|
-
OAuthExtractGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.
|
|
534
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
556
|
+
OAuthExtractGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthExtractGuard, deps: [{ token: i1$1.Router }, { token: OAuthService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
557
|
+
OAuthExtractGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthExtractGuard, providedIn: 'root' });
|
|
558
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthExtractGuard, decorators: [{
|
|
535
559
|
type: Injectable,
|
|
536
560
|
args: [{ providedIn: 'root' }]
|
|
537
561
|
}], ctorParameters: function () { return [{ type: i1$1.Router }, { type: OAuthService }]; } });
|
|
@@ -555,9 +579,9 @@ class OAuthRedirectGuard {
|
|
|
555
579
|
return this.canActivate(childRoute, state);
|
|
556
580
|
}
|
|
557
581
|
}
|
|
558
|
-
OAuthRedirectGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
559
|
-
OAuthRedirectGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.
|
|
560
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
582
|
+
OAuthRedirectGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthRedirectGuard, deps: [{ token: OAuthService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
583
|
+
OAuthRedirectGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthRedirectGuard, providedIn: 'root' });
|
|
584
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthRedirectGuard, decorators: [{
|
|
561
585
|
type: Injectable,
|
|
562
586
|
args: [{ providedIn: 'root' }]
|
|
563
587
|
}], ctorParameters: function () { return [{ type: OAuthService, decorators: [{
|
|
@@ -583,10 +607,10 @@ class OAuthModule {
|
|
|
583
607
|
};
|
|
584
608
|
}
|
|
585
609
|
}
|
|
586
|
-
OAuthModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
587
|
-
OAuthModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.
|
|
588
|
-
OAuthModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.
|
|
589
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
610
|
+
OAuthModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
611
|
+
OAuthModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthModule });
|
|
612
|
+
OAuthModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthModule });
|
|
613
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthModule, decorators: [{
|
|
590
614
|
type: NgModule
|
|
591
615
|
}] });
|
|
592
616
|
|
|
@@ -595,8 +619,8 @@ class ContainerComponent {
|
|
|
595
619
|
return outlet.isActivated ? outlet.activatedRoute : 'true';
|
|
596
620
|
}
|
|
597
621
|
}
|
|
598
|
-
ContainerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
599
|
-
ContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.
|
|
622
|
+
ContainerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ContainerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
623
|
+
ContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: ContainerComponent, selector: "rxap-container", host: { classAttribute: "rxap-container" }, ngImport: i0, template: "<div [@routeAnimations]=\"prepareRoute(outlet)\" class=\"container\">\n\n <div class=\"split mat-elevation-z3\"></div>\n\n <router-outlet #outlet=\"outlet\"></router-outlet>\n\n</div>\n", styles: [".container{height:100vh;width:100vw;display:flex;align-items:center;justify-content:center}.container .split{position:absolute;top:0;left:0;right:0;bottom:65vh;z-index:-10}"], directives: [{ type: i1$1.RouterOutlet, selector: "router-outlet", outputs: ["activate", "deactivate"], exportAs: ["outlet"] }], animations: [
|
|
600
624
|
trigger('routeAnimations', [
|
|
601
625
|
transition(':enter', [
|
|
602
626
|
style({ opacity: 0 }),
|
|
@@ -608,7 +632,7 @@ ContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ver
|
|
|
608
632
|
])
|
|
609
633
|
])
|
|
610
634
|
], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
611
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
635
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ContainerComponent, decorators: [{
|
|
612
636
|
type: Component,
|
|
613
637
|
args: [{
|
|
614
638
|
selector: 'rxap-container',
|
|
@@ -633,9 +657,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
|
|
|
633
657
|
|
|
634
658
|
class LoadingComponent {
|
|
635
659
|
}
|
|
636
|
-
LoadingComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
637
|
-
LoadingComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.
|
|
638
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
660
|
+
LoadingComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LoadingComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
661
|
+
LoadingComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: LoadingComponent, selector: "rxap-loading", host: { classAttribute: "rxap-loading" }, ngImport: i0, template: "<mat-progress-bar class=\"loading-bar\" mode=\"indeterminate\"></mat-progress-bar>\n", styles: [""], components: [{ type: i1$2.MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "mode", "value", "bufferValue"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
662
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LoadingComponent, decorators: [{
|
|
639
663
|
type: Component,
|
|
640
664
|
args: [{
|
|
641
665
|
selector: 'rxap-loading',
|
|
@@ -654,8 +678,8 @@ class SignInWithRedirectComponent {
|
|
|
654
678
|
this.authService.signInWithRedirect();
|
|
655
679
|
}
|
|
656
680
|
}
|
|
657
|
-
SignInWithRedirectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
658
|
-
SignInWithRedirectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.
|
|
681
|
+
SignInWithRedirectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SignInWithRedirectComponent, deps: [{ token: OAuthService }], target: i0.ɵɵFactoryTarget.Component });
|
|
682
|
+
SignInWithRedirectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: SignInWithRedirectComponent, selector: "rxap-sign-in-with-redirect", host: { classAttribute: "rxap-sign-in-with-redirect" }, ngImport: i0, template: "<div [@fadeAnimation]=\"'in'\" class=\"inner mat-elevation-z5\" fxLayout=\"column\" fxLayoutAlign=\"center center\" fxLayoutGap=\"32px\">\n\n <div class=\"header\" fxFlex=\"nogrow\" fxLayout=\"column\" fxLayoutAlign=\"center center\">\n\n <mat-icon class=\"avatar-icon\" color=\"primary\" fxFlex=\"nogrow\">account_circle</mat-icon>\n\n </div>\n\n <div fxFlex=\"nogrow\" fxLayout=\"row\" fxLayoutAlign=\"center center\">\n\n <div fxFlex=\"nogrow\">\n <button (click)=\"signIn()\" color=\"primary\" fxFlex=\"nogrow\" mat-raised-button>\n <span fxLayout=\"row\" fxLayoutAlign=\"start center\" fxLayoutGap=\"16px\">\n <mat-icon fxFlex=\"nogrow\">login</mat-icon>\n <span fxFlex=\"nogrow\">Sign In</span>\n </span>\n </button>\n </div>\n\n </div>\n\n</div>\n\n", styles: [".inner{padding:64px;position:relative}.inner .header .avatar-icon{width:100px;height:100px;font-size:100px}"], components: [{ type: i2.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i3.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i4.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { type: i4.DefaultLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg]", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { type: i4.DefaultLayoutGapDirective, selector: " [fxLayoutGap], [fxLayoutGap.xs], [fxLayoutGap.sm], [fxLayoutGap.md], [fxLayoutGap.lg], [fxLayoutGap.xl], [fxLayoutGap.lt-sm], [fxLayoutGap.lt-md], [fxLayoutGap.lt-lg], [fxLayoutGap.lt-xl], [fxLayoutGap.gt-xs], [fxLayoutGap.gt-sm], [fxLayoutGap.gt-md], [fxLayoutGap.gt-lg]", inputs: ["fxLayoutGap", "fxLayoutGap.xs", "fxLayoutGap.sm", "fxLayoutGap.md", "fxLayoutGap.lg", "fxLayoutGap.xl", "fxLayoutGap.lt-sm", "fxLayoutGap.lt-md", "fxLayoutGap.lt-lg", "fxLayoutGap.lt-xl", "fxLayoutGap.gt-xs", "fxLayoutGap.gt-sm", "fxLayoutGap.gt-md", "fxLayoutGap.gt-lg"] }, { type: i4.DefaultFlexDirective, selector: " [fxFlex], [fxFlex.xs], [fxFlex.sm], [fxFlex.md], [fxFlex.lg], [fxFlex.xl], [fxFlex.lt-sm], [fxFlex.lt-md], [fxFlex.lt-lg], [fxFlex.lt-xl], [fxFlex.gt-xs], [fxFlex.gt-sm], [fxFlex.gt-md], [fxFlex.gt-lg]", inputs: ["fxFlex", "fxFlex.xs", "fxFlex.sm", "fxFlex.md", "fxFlex.lg", "fxFlex.xl", "fxFlex.lt-sm", "fxFlex.lt-md", "fxFlex.lt-lg", "fxFlex.lt-xl", "fxFlex.gt-xs", "fxFlex.gt-sm", "fxFlex.gt-md", "fxFlex.gt-lg"] }], animations: [
|
|
659
683
|
trigger('fadeAnimation', [
|
|
660
684
|
// the "in" style determines the "resting" state of the element when it is visible.
|
|
661
685
|
state('in', style({ opacity: 1 })),
|
|
@@ -668,7 +692,7 @@ SignInWithRedirectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.
|
|
|
668
692
|
transition(':leave', animate(300, style({ opacity: 0 })))
|
|
669
693
|
])
|
|
670
694
|
], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
671
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
695
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SignInWithRedirectComponent, decorators: [{
|
|
672
696
|
type: Component,
|
|
673
697
|
args: [{
|
|
674
698
|
selector: 'rxap-sign-in-with-redirect',
|
|
@@ -730,9 +754,9 @@ class ProfileResolve {
|
|
|
730
754
|
});
|
|
731
755
|
}
|
|
732
756
|
}
|
|
733
|
-
ProfileResolve.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
734
|
-
ProfileResolve.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.
|
|
735
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
757
|
+
ProfileResolve.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ProfileResolve, deps: [{ token: OAuthService }, { token: Router }, { token: RXAP_O_AUTH_REDIRECT_SIGN_IN }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
758
|
+
ProfileResolve.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ProfileResolve, providedIn: 'root' });
|
|
759
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ProfileResolve, decorators: [{
|
|
736
760
|
type: Injectable,
|
|
737
761
|
args: [{ providedIn: 'root' }]
|
|
738
762
|
}], ctorParameters: function () { return [{ type: OAuthService, decorators: [{
|
|
@@ -748,12 +772,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
|
|
|
748
772
|
|
|
749
773
|
class ContainerComponentModule {
|
|
750
774
|
}
|
|
751
|
-
ContainerComponentModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
752
|
-
ContainerComponentModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.
|
|
753
|
-
ContainerComponentModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.
|
|
775
|
+
ContainerComponentModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ContainerComponentModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
776
|
+
ContainerComponentModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ContainerComponentModule, declarations: [ContainerComponent], imports: [RouterModule], exports: [ContainerComponent] });
|
|
777
|
+
ContainerComponentModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ContainerComponentModule, imports: [[
|
|
754
778
|
RouterModule
|
|
755
779
|
]] });
|
|
756
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
780
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ContainerComponentModule, decorators: [{
|
|
757
781
|
type: NgModule,
|
|
758
782
|
args: [{
|
|
759
783
|
declarations: [ContainerComponent],
|
|
@@ -766,12 +790,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
|
|
|
766
790
|
|
|
767
791
|
class LoadingComponentModule {
|
|
768
792
|
}
|
|
769
|
-
LoadingComponentModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
770
|
-
LoadingComponentModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.
|
|
771
|
-
LoadingComponentModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.
|
|
793
|
+
LoadingComponentModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LoadingComponentModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
794
|
+
LoadingComponentModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LoadingComponentModule, declarations: [LoadingComponent], imports: [MatProgressBarModule], exports: [LoadingComponent] });
|
|
795
|
+
LoadingComponentModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LoadingComponentModule, imports: [[
|
|
772
796
|
MatProgressBarModule
|
|
773
797
|
]] });
|
|
774
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
798
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LoadingComponentModule, decorators: [{
|
|
775
799
|
type: NgModule,
|
|
776
800
|
args: [{
|
|
777
801
|
declarations: [
|
|
@@ -788,20 +812,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
|
|
|
788
812
|
|
|
789
813
|
class SignInWithRedirectComponentModule {
|
|
790
814
|
}
|
|
791
|
-
SignInWithRedirectComponentModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
792
|
-
SignInWithRedirectComponentModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.
|
|
815
|
+
SignInWithRedirectComponentModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SignInWithRedirectComponentModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
816
|
+
SignInWithRedirectComponentModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SignInWithRedirectComponentModule, declarations: [SignInWithRedirectComponent], imports: [MatCardModule,
|
|
793
817
|
MatButtonModule,
|
|
794
818
|
FlexLayoutModule,
|
|
795
819
|
MatIconModule,
|
|
796
820
|
CommonModule], exports: [SignInWithRedirectComponent] });
|
|
797
|
-
SignInWithRedirectComponentModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.
|
|
821
|
+
SignInWithRedirectComponentModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SignInWithRedirectComponentModule, imports: [[
|
|
798
822
|
MatCardModule,
|
|
799
823
|
MatButtonModule,
|
|
800
824
|
FlexLayoutModule,
|
|
801
825
|
MatIconModule,
|
|
802
826
|
CommonModule
|
|
803
827
|
]] });
|
|
804
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
828
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: SignInWithRedirectComponentModule, decorators: [{
|
|
805
829
|
type: NgModule,
|
|
806
830
|
args: [{
|
|
807
831
|
declarations: [SignInWithRedirectComponent],
|
|
@@ -818,14 +842,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
|
|
|
818
842
|
|
|
819
843
|
class OAuthRoutingModule {
|
|
820
844
|
}
|
|
821
|
-
OAuthRoutingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.
|
|
822
|
-
OAuthRoutingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.
|
|
845
|
+
OAuthRoutingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
846
|
+
OAuthRoutingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthRoutingModule, exports: [ContainerComponentModule,
|
|
823
847
|
LoadingComponentModule,
|
|
824
848
|
SignInWithRedirectComponentModule] });
|
|
825
|
-
OAuthRoutingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.
|
|
849
|
+
OAuthRoutingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthRoutingModule, imports: [ContainerComponentModule,
|
|
826
850
|
LoadingComponentModule,
|
|
827
851
|
SignInWithRedirectComponentModule] });
|
|
828
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.
|
|
852
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: OAuthRoutingModule, decorators: [{
|
|
829
853
|
type: NgModule,
|
|
830
854
|
args: [{
|
|
831
855
|
exports: [
|
|
@@ -840,5 +864,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
|
|
|
840
864
|
* Generated bundle index. Do not edit.
|
|
841
865
|
*/
|
|
842
866
|
|
|
843
|
-
export { ACCESS_TOKEN_LOCAL_STORAGE_KEY, AssertOAuthMethodParameters, AssertOAuthMethodWithRefreshTokenParameters, AssertOAuthMethodWithUsernamePasswordParameters, ContainerComponent, ContainerComponentModule, DefaultRedirectSignInFactory, DefaultRedirectUrl, EXPIRES_AT_LOCAL_STORAGE_KEY, GetOAuthProfileMethod, IsOAuthMethodWithRefreshTokenParameters, IsOAuthMethodWithUsernamePasswordParameters, LoadingComponent, LoadingComponentModule, OAUTH_AUTH_ENDPOINT, OAUTH_SECRET, OAUTH_SSO_URL, OAuthExtractGuard, OAuthMethod, OAuthModule, OAuthRedirectGuard, OAuthRoutingModule, OAuthService, PROFILE_AUTH_ENDPOINT, ProfileResolve, REFRESH_TOKEN_LOCAL_STORAGE_KEY, REMEMBER_LOCAL_STORAGE_KEY, RXAP_O_AUTH_REDIRECT_SIGN_IN, RXAP_O_AUTH_REDIRECT_SIGN_OUT, RXAP_O_AUTH_REDIRECT_URL, RXAP_O_AUTH_ROUTES, SignInWithRedirectComponent, SignInWithRedirectComponentModule };
|
|
867
|
+
export { ACCESS_TOKEN_LOCAL_STORAGE_KEY, AssertOAuthMethodParameters, AssertOAuthMethodWithRefreshTokenParameters, AssertOAuthMethodWithUsernamePasswordParameters, ContainerComponent, ContainerComponentModule, DefaultRedirectSignInFactory, DefaultRedirectUrl, EXPIRES_AT_LOCAL_STORAGE_KEY, GetOAuthProfileMethod, IsOAuthMethodWithRefreshTokenParameters, IsOAuthMethodWithUsernamePasswordParameters, LoadingComponent, LoadingComponentModule, OAUTH_AUTH_ENDPOINT, OAUTH_CLIENT_ID, OAUTH_SECRET, OAUTH_SSO_URL, OAuthExtractGuard, OAuthMethod, OAuthModule, OAuthRedirectGuard, OAuthRoutingModule, OAuthService, PROFILE_AUTH_ENDPOINT, ProfileResolve, REFRESH_TOKEN_LOCAL_STORAGE_KEY, REMEMBER_LOCAL_STORAGE_KEY, RXAP_O_AUTH_REDIRECT_SIGN_IN, RXAP_O_AUTH_REDIRECT_SIGN_OUT, RXAP_O_AUTH_REDIRECT_URL, RXAP_O_AUTH_ROUTES, SignInWithRedirectComponent, SignInWithRedirectComponentModule };
|
|
844
868
|
//# sourceMappingURL=rxap-oauth.js.map
|