Skip to content

Commit fb7f28d

Browse files
authored
Merge pull request #3552 from tarlepp/chore(deps)/dependency-update
Chore(deps) - Angular update
2 parents a9f35b0 + 98d5715 commit fb7f28d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+2278
-1886
lines changed

angular.json

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,30 @@
171171
},
172172
"@angular-eslint/schematics:library": {
173173
"setParserOptionsProject": true
174+
},
175+
"@schematics/angular:component": {
176+
"type": "component"
177+
},
178+
"@schematics/angular:directive": {
179+
"type": "directive"
180+
},
181+
"@schematics/angular:service": {
182+
"type": "service"
183+
},
184+
"@schematics/angular:guard": {
185+
"typeSeparator": "."
186+
},
187+
"@schematics/angular:interceptor": {
188+
"typeSeparator": "."
189+
},
190+
"@schematics/angular:module": {
191+
"typeSeparator": "."
192+
},
193+
"@schematics/angular:pipe": {
194+
"typeSeparator": "."
195+
},
196+
"@schematics/angular:resolver": {
197+
"typeSeparator": "."
174198
}
175199
}
176200
}

package.json

Lines changed: 37 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -35,75 +35,75 @@
3535
},
3636
"private": true,
3737
"dependencies": {
38-
"@angular/animations": "19.2.9",
39-
"@angular/cdk": "19.2.14",
40-
"@angular/common": "19.2.9",
41-
"@angular/compiler": "19.2.9",
42-
"@angular/core": "19.2.9",
43-
"@angular/forms": "19.2.9",
44-
"@angular/localize": "19.2.9",
45-
"@angular/material": "19.2.14",
46-
"@angular/platform-browser": "19.2.9",
47-
"@angular/platform-browser-dynamic": "19.2.9",
48-
"@angular/router": "19.2.9",
38+
"@angular/animations": "20.0.3",
39+
"@angular/cdk": "20.0.3",
40+
"@angular/common": "20.0.3",
41+
"@angular/compiler": "20.0.3",
42+
"@angular/core": "20.0.3",
43+
"@angular/forms": "20.0.3",
44+
"@angular/localize": "20.0.3",
45+
"@angular/material": "20.0.3",
46+
"@angular/platform-browser": "20.0.3",
47+
"@angular/platform-browser-dynamic": "20.0.3",
48+
"@angular/router": "20.0.3",
4949
"@auth0/angular-jwt": "5.2.0",
5050
"@jsverse/transloco": "7.6.1",
5151
"@jsverse/transloco-keys-manager": "6.1.0",
5252
"@jsverse/transloco-utils": "7.0.2",
5353
"@ngbracket/ngx-layout": "19.0.0",
54-
"@ngrx/effects": "19.1.0",
55-
"@ngrx/entity": "19.1.0",
56-
"@ngrx/operators": "^19.1.0",
57-
"@ngrx/router-store": "19.1.0",
58-
"@ngrx/store": "19.1.0",
59-
"@ngrx/store-devtools": "19.1.0",
60-
"@snyk/protect": "1.1296.2",
54+
"@ngrx/effects": "19.2.1",
55+
"@ngrx/entity": "19.2.1",
56+
"@ngrx/operators": "19.2.1",
57+
"@ngrx/router-store": "19.2.1",
58+
"@ngrx/store": "19.2.1",
59+
"@ngrx/store-devtools": "19.2.1",
60+
"@snyk/protect": "1.1297.1",
6161
"luxon": "3.6.1",
6262
"luxon-angular": "6.0.0",
6363
"ngrx-store-localstorage": "19.0.1",
6464
"ngx-material-luxon": "1.1.1",
6565
"ngx-webstorage": "19.0.1",
6666
"rxjs": "7.8.2",
6767
"tslib": "2.8.1",
68-
"zone.js": "0.15.0"
68+
"zone.js": "0.15.1"
6969
},
7070
"devDependencies": {
71-
"@angular-devkit/build-angular": "19.2.10",
72-
"@angular-eslint/builder": "19.3.0",
73-
"@angular-eslint/eslint-plugin": "19.3.0",
74-
"@angular-eslint/eslint-plugin-template": "19.3.0",
75-
"@angular-eslint/schematics": "19.3.0",
76-
"@angular-eslint/template-parser": "19.3.0",
77-
"@angular/cli": "19.2.10",
78-
"@angular/compiler-cli": "19.2.9",
79-
"@angular/language-service": "19.2.9",
71+
"@angular-devkit/build-angular": "20.0.2",
72+
"@angular-eslint/builder": "20.0.0",
73+
"@angular-eslint/eslint-plugin": "20.0.0",
74+
"@angular-eslint/eslint-plugin-template": "20.0.0",
75+
"@angular-eslint/schematics": "20.0.0",
76+
"@angular-eslint/template-parser": "20.0.0",
77+
"@angular/cli": "20.0.2",
78+
"@angular/compiler-cli": "20.0.3",
79+
"@angular/language-service": "20.0.3",
8080
"@bartholomej/ngx-translate-extract": "8.0.2",
81-
"@types/jasmine": "5.1.7",
81+
"@types/jasmine": "5.1.8",
8282
"@types/jasminewd2": "2.0.13",
8383
"@types/luxon": "3.6.2",
84-
"@types/node": "22.15.3",
85-
"@typescript-eslint/eslint-plugin": "8.31.1",
84+
"@types/node": "24.0.1",
85+
"@typescript-eslint/eslint-plugin": "8.34.0",
8686
"@typescript-eslint/parser": "7.16.0",
8787
"eslint": "8.57.0",
8888
"eslint-plugin-deprecation": "2.0.0",
8989
"eslint-plugin-import": "2.31.0",
9090
"eslint-plugin-jsdoc": "48.11.0",
9191
"eslint-plugin-ngrx": "2.1.4",
9292
"eslint-plugin-prefer-arrow": "1.2.3",
93-
"jasmine-core": "5.7.1",
93+
"jasmine-core": "5.8.0",
9494
"jasmine-spec-reporter": "7.0.0",
9595
"karma": "6.4.4",
9696
"karma-chrome-launcher": "3.2.0",
9797
"karma-coverage-istanbul-reporter": "3.0.3",
9898
"karma-jasmine": "5.1.0",
9999
"karma-jasmine-html-reporter": "2.1.0",
100-
"ngx-build-plus": "19.0.0",
101-
"postcss": "8.5.3",
100+
"ngx-build-plus": "20.0.0",
101+
"postcss": "8.5.5",
102102
"protractor": "7.0.0",
103-
"stylelint": "16.19.1",
103+
"stylelint": "16.20.0",
104104
"stylelint-config-sass-guidelines": "12.1.0",
105-
"stylelint-config-standard-scss": "14.0.0",
106-
"stylelint-scss": "6.11.1",
105+
"stylelint-config-standard-scss": "15.0.1",
106+
"stylelint-scss": "6.12.1",
107107
"ts-node": "10.9.2",
108108
"typescript": "5.8.3"
109109
},

src/app/app.component.ts

Lines changed: 9 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Component, OnDestroy, OnInit } from '@angular/core';
1+
import { Component, OnDestroy, OnInit, inject } from '@angular/core';
22
import { RouterOutlet } from '@angular/router';
33
import { marker } from '@jsverse/transloco-keys-manager/marker';
44
import { MediaChange, MediaObserver } from '@ngbracket/ngx-layout';
@@ -36,24 +36,14 @@ import { authenticationActions, authenticationSelectors, layoutActions, layoutSe
3636
})
3737

3838
export class AppComponent implements OnInit, OnDestroy {
39-
private loggedIn: boolean;
40-
private tokenInterval: number;
41-
private readonly subscription: Subscription;
42-
43-
/**
44-
* Constructor of the class, where we DI all services that we need to use
45-
* within this component and initialize needed properties.
46-
*/
47-
public constructor(
48-
private readonly localStorage: LocalStorageService,
49-
private readonly mediaObserver: MediaObserver,
50-
private readonly store: Store,
51-
private readonly authenticationService: AuthenticationService,
52-
) {
53-
this.loggedIn = false;
54-
this.tokenInterval = 0;
55-
this.subscription = new Subscription();
56-
}
39+
private loggedIn: boolean = false;
40+
private tokenInterval: number = 0;
41+
42+
private readonly localStorage: LocalStorageService = inject(LocalStorageService);
43+
private readonly mediaObserver: MediaObserver = inject(MediaObserver);
44+
private readonly store: Store = inject(Store);
45+
private readonly authenticationService: AuthenticationService = inject(AuthenticationService);
46+
private readonly subscription: Subscription = new Subscription();
5747

5848
/**
5949
* A callback method that is invoked immediately after the default change

src/app/auth/guards/anonymous.guard.ts

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Injectable } from '@angular/core';
1+
import { Injectable, inject } from '@angular/core';
22
import { ActivatedRouteSnapshot, Router, UrlTree } from '@angular/router';
33
import { Observable } from 'rxjs';
44

@@ -9,14 +9,17 @@ import { AuthenticationService } from 'src/app/auth/services';
99
providedIn: 'root',
1010
})
1111
export class AnonymousGuard extends BaseAuth {
12+
protected readonly router: Router = inject(Router);
13+
protected readonly authenticationService: AuthenticationService = inject(AuthenticationService);
14+
1215
/**
1316
* Constructor of the class, where we DI all services that we need to use
1417
* within this guard.
1518
*/
16-
public constructor(
17-
protected readonly router: Router,
18-
protected readonly authenticationService: AuthenticationService,
19-
) {
19+
public constructor() {
20+
const router: Router = inject(Router);
21+
const authenticationService: AuthenticationService = inject(AuthenticationService);
22+
2023
super(router, authenticationService);
2124
}
2225

src/app/auth/guards/authentication.guard.ts

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Injectable } from '@angular/core';
1+
import { Injectable, inject } from '@angular/core';
22
import { ActivatedRouteSnapshot, Router, UrlTree } from '@angular/router';
33
import { Observable } from 'rxjs';
44

@@ -9,14 +9,17 @@ import { AuthenticationService } from 'src/app/auth/services';
99
providedIn: 'root',
1010
})
1111
export class AuthenticationGuard extends BaseAuth {
12+
protected readonly router: Router = inject(Router);
13+
protected readonly authenticationService: AuthenticationService = inject(AuthenticationService);
14+
1215
/**
1316
* Constructor of the class, where we DI all services that we need to use
1417
* within this guard.
1518
*/
16-
public constructor(
17-
protected readonly router: Router,
18-
protected readonly authenticationService: AuthenticationService,
19-
) {
19+
public constructor() {
20+
const router: Router = inject(Router);
21+
const authenticationService: AuthenticationService = inject(AuthenticationService);
22+
2023
super(router, authenticationService);
2124
}
2225

src/app/auth/guards/role-admin.guard.ts

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Injectable } from '@angular/core';
1+
import { Injectable, inject } from '@angular/core';
22
import { ActivatedRouteSnapshot, Router, UrlTree } from '@angular/router';
33
import { Store } from '@ngrx/store';
44
import { Observable } from 'rxjs';
@@ -10,14 +10,17 @@ import { BaseRole } from 'src/app/auth/guards/base-role';
1010
providedIn: 'root',
1111
})
1212
export class RoleAdminGuard extends BaseRole {
13+
protected readonly router: Router = inject(Router);
14+
protected readonly store: Store = inject(Store);
15+
1316
/**
1417
* Constructor of the class, where we DI all services that we need to use
1518
* within this guard.
1619
*/
17-
public constructor(
18-
protected readonly router: Router,
19-
protected readonly store: Store,
20-
) {
20+
public constructor() {
21+
const router: Router = inject(Router);
22+
const store: Store = inject(Store);
23+
2124
super(router, store);
2225
}
2326

src/app/auth/guards/role-logged.guard.ts

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Injectable } from '@angular/core';
1+
import { Injectable, inject } from '@angular/core';
22
import { ActivatedRouteSnapshot, Router, UrlTree } from '@angular/router';
33
import { Store } from '@ngrx/store';
44
import { Observable } from 'rxjs';
@@ -10,14 +10,17 @@ import { BaseRole } from 'src/app/auth/guards/base-role';
1010
providedIn: 'root',
1111
})
1212
export class RoleALoggedGuard extends BaseRole {
13+
protected readonly router: Router = inject(Router);
14+
protected readonly store: Store = inject(Store);
15+
1316
/**
1417
* Constructor of the class, where we DI all services that we need to use
1518
* within this guard.
1619
*/
17-
public constructor(
18-
protected readonly router: Router,
19-
protected readonly store: Store,
20-
) {
20+
public constructor() {
21+
const router: Router = inject(Router);
22+
const store: Store = inject(Store);
23+
2124
super(router, store);
2225
}
2326

src/app/auth/guards/role-root.guard.ts

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Injectable } from '@angular/core';
1+
import { Injectable, inject } from '@angular/core';
22
import { ActivatedRouteSnapshot, Router, UrlTree } from '@angular/router';
33
import { Store } from '@ngrx/store';
44
import { Observable } from 'rxjs';
@@ -10,14 +10,17 @@ import { BaseRole } from 'src/app/auth/guards/base-role';
1010
providedIn: 'root',
1111
})
1212
export class RoleRootGuard extends BaseRole {
13+
protected readonly router: Router = inject(Router);
14+
protected readonly store: Store = inject(Store);
15+
1316
/**
1417
* Constructor of the class, where we DI all services that we need to use
1518
* within this guard.
1619
*/
17-
public constructor(
18-
protected readonly router: Router,
19-
protected readonly store: Store,
20-
) {
20+
public constructor() {
21+
const router: Router = inject(Router);
22+
const store: Store = inject(Store);
23+
2124
super(router, store);
2225
}
2326

src/app/auth/guards/role-user.guard.ts

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Injectable } from '@angular/core';
1+
import { Injectable, inject } from '@angular/core';
22
import { ActivatedRouteSnapshot, Router, UrlTree } from '@angular/router';
33
import { Store } from '@ngrx/store';
44
import { Observable } from 'rxjs';
@@ -10,14 +10,17 @@ import { BaseRole } from 'src/app/auth/guards/base-role';
1010
providedIn: 'root',
1111
})
1212
export class RoleUserGuard extends BaseRole {
13+
protected readonly router: Router = inject(Router);
14+
protected readonly store: Store = inject(Store);
15+
1316
/**
1417
* Constructor of the class, where we DI all services that we need to use
1518
* within this guard.
1619
*/
17-
public constructor(
18-
protected readonly router: Router,
19-
protected readonly store: Store,
20-
) {
20+
public constructor() {
21+
const router: Router = inject(Router);
22+
const store: Store = inject(Store);
23+
2124
super(router, store);
2225
}
2326

src/app/auth/login/login.component.ts

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core';
1+
import { Component, OnDestroy, OnInit, ViewChild, inject } from '@angular/core';
22
import { UntypedFormBuilder, UntypedFormGroup, NgForm, Validators, ReactiveFormsModule } from '@angular/forms';
33
import { MatButton } from '@angular/material/button';
44
import { MatFormField, MatLabel, MatError } from '@angular/material/form-field';
@@ -41,25 +41,19 @@ export class LoginComponent implements OnInit, OnDestroy {
4141
@ViewChild('loginFormElement') public loginFormElement!: NgForm;
4242

4343
public readonly loginForm: UntypedFormGroup;
44-
public loading: boolean;
45-
public focus: boolean;
44+
public loading: boolean = false;
45+
public focus: boolean = true;
4646

47-
private readonly subscriptions: Subscription;
48-
private isError: boolean;
47+
private isError: boolean = false;
48+
private readonly formBuilder: UntypedFormBuilder = inject(UntypedFormBuilder);
49+
private readonly store: Store = inject(Store);
50+
private readonly subscriptions: Subscription = new Subscription();
4951

5052
/**
5153
* Constructor of the class, where we DI all services that we need to use
5254
* within this component and initialize needed properties.
5355
*/
54-
public constructor(
55-
private readonly formBuilder: UntypedFormBuilder,
56-
private readonly store: Store,
57-
) {
58-
this.loading = false;
59-
this.focus = true;
60-
this.subscriptions = new Subscription();
61-
this.isError = false;
62-
56+
public constructor() {
6357
// Initialize login form
6458
this.loginForm = this.formBuilder.group({
6559
username: [null, [Validators.required, Validators.minLength(3)]],

0 commit comments

Comments
 (0)