Skip to content

Commit 2591018

Browse files
updates custom-login
1 parent 3851bfd commit 2591018

12 files changed

Lines changed: 37 additions & 101 deletions

File tree

custom-login/.browserslistrc

Lines changed: 0 additions & 17 deletions
This file was deleted.

custom-login/angular.json

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,19 +81,19 @@
8181
"serve": {
8282
"builder": "@angular-builders/custom-webpack:dev-server",
8383
"options": {
84-
"browserTarget": "custom-login:build:production",
84+
"buildTarget": "custom-login:build:production",
8585
"port": 8080
8686
},
8787
"configurations": {
8888
"production": {
89-
"browserTarget": "custom-login:build:production"
89+
"buildTarget": "custom-login:build:production"
9090
}
9191
}
9292
},
9393
"extract-i18n": {
9494
"builder": "@angular-devkit/build-angular:extract-i18n",
9595
"options": {
96-
"browserTarget": "custom-login:build"
96+
"buildTarget": "custom-login:build"
9797
}
9898
},
9999
"test": {
@@ -131,5 +131,8 @@
131131
}
132132
}
133133
},
134-
"defaultProject": "custom-login"
134+
"defaultProject": "custom-login",
135+
"cli": {
136+
"analytics": false
137+
}
135138
}

custom-login/package.json

Lines changed: 18 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -11,28 +11,27 @@
1111
},
1212
"private": true,
1313
"dependencies": {
14-
"@angular/animations": "~14.2.0",
15-
"@angular/common": "~14.2.0",
16-
"@angular/compiler": "~14.2.0",
17-
"@angular/core": "~14.2.0",
18-
"@angular/forms": "~14.2.0",
19-
"@angular/platform-browser": "~14.2.0",
20-
"@angular/platform-browser-dynamic": "~14.2.0",
21-
"@angular/router": "~14.2.0",
22-
"@giomamaladze/ng2-semantic-ui": "^1.0.1",
23-
"@okta/okta-angular": "^6.0.0",
24-
"@okta/okta-auth-js": "7.0.2",
25-
"@okta/okta-signin-widget": "7.14.0",
26-
"rxjs": "~6.6.7",
14+
"@angular/animations": "~19.2.17",
15+
"@angular/common": "~19.2.17",
16+
"@angular/compiler": "~19.2.17",
17+
"@angular/core": "~19.2.17",
18+
"@angular/forms": "~19.2.17",
19+
"@angular/platform-browser": "~19.2.17",
20+
"@angular/platform-browser-dynamic": "~19.2.17",
21+
"@angular/router": "~19.2.17",
22+
"@okta/okta-angular": "^7.0.0",
23+
"@okta/okta-auth-js": "7.14.1",
24+
"@okta/okta-signin-widget": "~7.39.0",
25+
"rxjs": "~7.4.0",
2726
"semantic-ui-css": "^2.4.1",
2827
"tslib": "^2.4.0",
29-
"zone.js": "~0.11.4"
28+
"zone.js": "~0.15.0"
3029
},
3130
"devDependencies": {
32-
"@angular-builders/custom-webpack": "^14.0.1",
33-
"@angular-devkit/build-angular": "~14.2.0",
34-
"@angular/cli": "~14.2.0",
35-
"@angular/compiler-cli": "~14.2.0",
31+
"@angular-builders/custom-webpack": "^19.0.1",
32+
"@angular-devkit/build-angular": "~19.2.17",
33+
"@angular/cli": "~19.2.17",
34+
"@angular/compiler-cli": "~19.2.17",
3635
"@types/jasmine": "~3.6.0",
3736
"@types/node": "^12.11.1",
3837
"@types/text-encoding": "0.0.36",
@@ -43,6 +42,6 @@
4342
"text-encoding": "^0.7.0",
4443
"ts-node": "~10.9.1",
4544
"tslint": "~6.1.3",
46-
"typescript": "~4.8.3"
45+
"typescript": "~5.5.4"
4746
}
4847
}

custom-login/src/app/app.component.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ import { OktaAuth } from '@okta/okta-auth-js';
1616

1717
@Component({
1818
selector: 'app-root',
19+
standalone: false,
1920
templateUrl: './app.component.html',
2021
styleUrls: ['./app.component.css']
2122
})

custom-login/src/app/app.module.ts

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ import { Injector, NgModule } from '@angular/core';
1515
import { HttpClientModule } from '@angular/common/http';
1616
import { APP_BASE_HREF } from '@angular/common';
1717
import { Routes, RouterModule, Router } from '@angular/router';
18-
import { SuiModalService, SuiModalModule } from '@giomamaladze/ng2-semantic-ui';
1918
import { OktaAuth } from '@okta/okta-auth-js';
2019
import {
2120
OKTA_CONFIG,
@@ -33,7 +32,7 @@ import { HomeComponent } from './home/home.component';
3332
import { LoginComponent } from './login/login.component';
3433
import { MessagesComponent } from './messages/messages.component';
3534
import { ProfileComponent } from './profile/profile.component';
36-
import { ConfirmModalComponent, ConfirmModal } from './modal/confirm.component';
35+
3736

3837
const appRoutes: Routes = [
3938
{
@@ -67,14 +66,12 @@ const appRoutes: Routes = [
6766
ProfileComponent,
6867
MessagesComponent,
6968
LoginComponent,
70-
ConfirmModalComponent,
7169
],
7270
imports: [
7371
BrowserModule,
7472
HttpClientModule,
75-
RouterModule.forRoot(appRoutes, { relativeLinkResolution: 'legacy' }),
73+
RouterModule.forRoot(appRoutes),
7674
OktaAuthModule,
77-
SuiModalModule,
7875
],
7976
providers: [
8077
{
@@ -94,11 +91,9 @@ const appRoutes: Routes = [
9491
triggerLogin();
9592
} else {
9693
// Ask the user to trigger the login process during token autoRenew process
97-
const modalService = injector.get(SuiModalService);
98-
modalService
99-
.open(new ConfirmModal("Do you want to re-authenticate?", "Auth required", "Yes", "No"))
100-
.onApprove(triggerLogin)
101-
.onDeny(() => {});
94+
if (window.confirm('Do you want to re-authenticate?')) {
95+
triggerLogin();
96+
}
10297
}
10398
}
10499
}
@@ -107,6 +102,5 @@ const appRoutes: Routes = [
107102
{ provide: APP_BASE_HREF, useValue: environment.appBaseHref },
108103
],
109104
bootstrap: [AppComponent],
110-
entryComponents: [ConfirmModalComponent],
111105
})
112106
export class AppModule { }

custom-login/src/app/home/home.component.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ interface ResourceServerExample {
2121

2222
@Component({
2323
selector: 'app-home',
24+
standalone: false,
2425
templateUrl: './home.component.html',
2526
styleUrls: ['./home.component.css']
2627
})

custom-login/src/app/login/login.component.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ const DEFAULT_ORIGINAL_URI = window.location.origin;
2020

2121
@Component({
2222
selector: 'app-login',
23+
standalone: false,
2324
templateUrl: './login.component.html',
2425
styleUrls: ['./login.component.css']
2526
})

custom-login/src/app/messages/messages.component.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ interface Message {
2525

2626
@Component({
2727
selector: 'app-messages',
28+
standalone: false,
2829
templateUrl: './messages.component.html',
2930
styleUrls: ['./messages.component.css']
3031
})

custom-login/src/app/modal/confirm.component.ts

Lines changed: 0 additions & 48 deletions
This file was deleted.

custom-login/src/app/profile/profile.component.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ interface Claim {
2121

2222
@Component({
2323
selector: 'app-profile',
24+
standalone: false,
2425
templateUrl: './profile.component.html',
2526
styleUrls: ['./profile.component.css']
2627
})

0 commit comments

Comments
 (0)