Skip to content

Commit

Permalink
Merge pull request #2088 from musicEnfanthen/feature/update-angular
Browse files Browse the repository at this point in the history
build(app): update angular
  • Loading branch information
musicEnfanthen authored Dec 23, 2024
2 parents 693f720 + 43b8732 commit c9cb060
Show file tree
Hide file tree
Showing 171 changed files with 2,508 additions and 1,625 deletions.
8 changes: 4 additions & 4 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@
},
{
"type": "anyComponentStyle",
"maximumWarning": "2kB",
"maximumError": "4kB"
"maximumWarning": "4kB",
"maximumError": "8kB"
}
],
"fileReplacements": [
Expand Down Expand Up @@ -83,8 +83,8 @@
},
{
"type": "anyComponentStyle",
"maximumWarning": "2kB",
"maximumError": "4kB"
"maximumWarning": "4kB",
"maximumError": "8kB"
}
]
}
Expand Down
34 changes: 17 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -84,16 +84,16 @@
"deploy:ci": "ng deploy --no-build --message=\"Release $npm_package_name (v$npm_package_version) on gh-pages\""
},
"dependencies": {
"@angular/animations": "^18.2.13",
"@angular/common": "^18.2.13",
"@angular/compiler": "^18.2.13",
"@angular/core": "^18.2.13",
"@angular/forms": "^18.2.13",
"@angular/localize": "^18.2.13",
"@angular/platform-browser": "^18.2.13",
"@angular/platform-browser-dynamic": "^18.2.13",
"@angular/platform-server": "^18.2.13",
"@angular/router": "^18.2.13",
"@angular/animations": "^19.0.5",
"@angular/common": "^19.0.5",
"@angular/compiler": "^19.0.5",
"@angular/core": "^19.0.5",
"@angular/forms": "^19.0.5",
"@angular/localize": "^19.0.5",
"@angular/platform-browser": "^19.0.5",
"@angular/platform-browser-dynamic": "^19.0.5",
"@angular/platform-server": "^19.0.5",
"@angular/router": "^19.0.5",
"@codemirror/legacy-modes": "^6.4.2",
"@fortawesome/angular-fontawesome": "^0.15.0",
"@fortawesome/free-solid-svg-icons": "^6.7.2",
Expand All @@ -113,13 +113,13 @@
"rdfstore": "musicenfanthen/rdfstore-js#v0.9.18-alpha.17",
"rxjs": "~7.8.1",
"stream": "^0.0.3",
"tslib": "^2.7.0",
"zone.js": "~0.14.10"
"tslib": "^2.8.1",
"zone.js": "~0.15.0"
},
"devDependencies": {
"@angular-devkit/build-angular": "^18.2.12",
"@angular/cli": "^18.2.12",
"@angular/compiler-cli": "^18.2.13",
"@angular-devkit/build-angular": "^19.0.6",
"@angular/cli": "^19.0.6",
"@angular/compiler-cli": "^19.0.5",
"@commitlint/cli": "^19.6.1",
"@commitlint/config-angular": "^19.6.0",
"@compodoc/compodoc": "^1.1.26",
Expand All @@ -129,7 +129,7 @@
"@types/jasmine": "~5.1.4",
"@types/node": "^22.10.2",
"angular-cli-ghpages": "^2.0.3",
"angular-eslint": "^18.4.3",
"angular-eslint": "^19.0.2",
"commit-and-tag-version": "^12.5.0",
"conventional-recommended-bump": "^10.0.0",
"eslint": "^9.17.0",
Expand All @@ -150,7 +150,7 @@
"lint-staged": "^15.2.11",
"prettier": "^3.4.2",
"source-map-explorer": "^2.5.3",
"typescript": "~5.5.4",
"typescript": "~5.6.3",
"typescript-eslint": "^8.18.1",
"webpack-bundle-analyzer": "^4.10.2"
},
Expand Down
36 changes: 30 additions & 6 deletions src/app/app.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,24 +14,48 @@ import { AnalyticsService, EditionInitService } from '@awg-core/services';
import { AppComponent } from './app.component';

// Mock components
@Component({ selector: 'awg-navbar', template: '' })
@Component({
selector: 'awg-navbar',
template: '',
standalone: false,
})
class NavbarStubComponent {}

@Component({ selector: 'awg-view-container', template: '' })
@Component({
selector: 'awg-view-container',
template: '',
standalone: false,
})
class ViewContainerStubComponent {
@Input() activateSideOutlet: boolean;
}

@Component({ selector: 'awg-footer', template: '' })
@Component({
selector: 'awg-footer',
template: '',
standalone: false,
})
class FooterStubComponent {}

@Component({ selector: 'awg-test', template: 'test' })
@Component({
selector: 'awg-test',
template: 'test',
standalone: false,
})
export class RoutedTestMockComponent {}

@Component({ selector: 'awg-test2', template: 'test2' })
@Component({
selector: 'awg-test2',
template: 'test2',
standalone: false,
})
export class RoutedTest2MockComponent {}

@Component({ selector: 'awg-side', template: 'test' })
@Component({
selector: 'awg-side',
template: 'test',
standalone: false,
})
export class RoutedSideMockComponent {}

export const MOCK_ROUTES: Routes = [
Expand Down
1 change: 1 addition & 0 deletions src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import { AnalyticsService, EditionInitService } from '@awg-core/services';
selector: 'awg-app',
templateUrl: './app.component.html',
styleUrls: ['./app.component.scss'],
standalone: false,
})
export class AppComponent {
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { MetaPage } from '@awg-core/core-models';
templateUrl: './footer-copyright.component.html',
styleUrls: ['./footer-copyright.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class FooterCopyrightComponent {
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import { MetaPage } from '@awg-core/core-models';
templateUrl: './footer-declaration.component.html',
styleUrls: ['./footer-declaration.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class FooterDeclarationComponent {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/core/footer/footer-logo/footer-logo.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import { Logo } from '@awg-core/core-models';
templateUrl: './footer-logo.component.html',
styleUrls: ['./footer-logo.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class FooterLogoComponent {
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@ import { Logo, Logos, MetaPage, MetaSectionTypes } from '@awg-core/core-models';

import { FooterPoweredbyComponent } from './footer-poweredby.component';

@Component({ selector: 'awg-footer-logo', template: '' })
@Component({
selector: 'awg-footer-logo',
template: '',
standalone: false,
})
class FooterLogoStubComponent {
@Input()
logo: Logo;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import { Logos, MetaPage } from '@awg-core/core-models';
templateUrl: './footer-poweredby.component.html',
styleUrls: ['./footer-poweredby.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class FooterPoweredbyComponent {
/**
Expand Down
24 changes: 20 additions & 4 deletions src/app/core/footer/footer.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,25 +17,41 @@ import { CoreService } from '@awg-core/services';
import { FooterComponent } from './footer.component';

// Mock components
@Component({ selector: 'awg-footer-copyright', template: '' })
@Component({
selector: 'awg-footer-copyright',
template: '',
standalone: false,
})
class FooterCopyrightStubComponent {
@Input()
pageMetaData: MetaPage;
}

@Component({ selector: 'awg-footer-declaration', template: '' })
@Component({
selector: 'awg-footer-declaration',
template: '',
standalone: false,
})
class FooterDeclarationStubComponent {
@Input()
pageMetaData: MetaPage;
}

@Component({ selector: 'awg-footer-logo', template: '' })
@Component({
selector: 'awg-footer-logo',
template: '',
standalone: false,
})
class FooterLogoStubComponent {
@Input()
logo: Logo;
}

@Component({ selector: 'awg-footer-poweredby', template: '' })
@Component({
selector: 'awg-footer-poweredby',
template: '',
standalone: false,
})
class FooterPoweredbyStubComponent {
@Input()
logos: Logos;
Expand Down
1 change: 1 addition & 0 deletions src/app/core/footer/footer.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import { CoreService } from '@awg-core/services';
selector: 'awg-footer',
templateUrl: './footer.component.html',
styleUrls: ['./footer.component.scss'],
standalone: false,
})
export class FooterComponent implements OnInit {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/core/navbar/navbar.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import { EditionComplexesService } from '@awg-views/edition-view/services';
selector: 'awg-navbar',
templateUrl: './navbar.component.html',
styleUrls: ['./navbar.component.scss'],
standalone: false,
})
export class NavbarComponent implements OnInit {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/core/view-container/view-container.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import { ChangeDetectionStrategy, Component, Input } from '@angular/core';
templateUrl: './view-container.component.html',
styleUrls: ['./view-container.component.scss'],
changeDetection: ChangeDetectionStrategy.Default,
standalone: false,
})
export class ViewContainerComponent {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/abbr/abbr.directive.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { AbbrDirective } from './abbr.directive';
// Test abbr component
@Component({
template: `<p [awgAbbr]="text"></p>`,
standalone: false,
})
class TestAbbrComponent {
text = 'This is a test with Klav. and Klav. o. and Ges. It is located in CH-Bps.';
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/abbr/abbr.directive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import { Directive, ElementRef, inject, Input, OnInit } from '@angular/core';
*/
@Directive({
selector: '[awgAbbr]',
standalone: false,
})
export class AbbrDirective implements OnInit {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/address/address.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import { MetaContact, MetaPage } from '@awg-core/core-models';
templateUrl: './address.component.html',
styleUrls: ['./address.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class AddressComponent {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/alert-error/alert-error.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import { ChangeDetectionStrategy, Component, Input } from '@angular/core';
templateUrl: './alert-error.component.html',
styleUrl: './alert-error.component.scss',
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class AlertErrorComponent {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/alert-info/alert-info.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import { faCircleInfo } from '@fortawesome/free-solid-svg-icons';
templateUrl: './alert-info.component.html',
styleUrls: ['./alert-info.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class AlertInfoComponent {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/codemirror/codemirror.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ type EditorStateConfig = Parameters<typeof EditorState.create>[0];
styleUrls: ['./codemirror.component.scss'],
encapsulation: ViewEncapsulation.None,
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class CodeMirrorComponent implements AfterViewInit, OnChanges {
/**
Expand Down
2 changes: 2 additions & 0 deletions src/app/shared/compile-html/compile-html.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ const nextId = (): string => {
<ng-container *ngComponentOutlet="dynamicComponent; ngModuleFactory: dynamicModule"></ng-container>
}
`,
standalone: false,
})
@Injectable()
export class CompileHtmlComponent implements OnChanges {
Expand Down Expand Up @@ -241,6 +242,7 @@ export class CompileHtmlComponent implements OnChanges {
@Component({
selector: nextId(),
template: html,
standalone: false,
})
class DynamicComponent {
ref: any = ref;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { NgbPopoverConfig } from '@ng-bootstrap/ng-bootstrap';
selector: 'awg-disclaimer-workeditions',
templateUrl: './disclaimer-workeditions.component.html',
styleUrls: ['./disclaimer-workeditions.component.scss'],
standalone: false,
})
export class DisclaimerWorkeditionsComponent {
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import { ExternalLinkDirective } from './external-link.directive';
<br /><br />
<a (click)="doSomething()" (keyup.enter)="doSomething()" role="link" tabindex="0">Link without href</a>`,
standalone: false,
})
class TestExernalLinkComponent {
hostname = location.hostname;
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/external-link/external-link.directive.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { Directive, HostBinding, inject, Input, OnChanges, PLATFORM_ID } from '@
*/
@Directive({
selector: 'a[href]',
standalone: false,
})
export class ExternalLinkDirective implements OnChanges {
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import { FullscreenService } from '@awg-app/core/services';
templateUrl: './fullscreen-toggle.component.html',
styleUrls: ['./fullscreen-toggle.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class FullscreenToggleComponent {
/**
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/heading/heading.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import { ChangeDetectionStrategy, Component, Input } from '@angular/core';
templateUrl: 'heading.component.html',
styleUrls: ['heading.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class HeadingComponent {
/**
Expand Down
6 changes: 5 additions & 1 deletion src/app/shared/json-viewer/json-viewer.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,11 @@ function expectNavPanel(fixture: ComponentFixture<any>, expectedLinks: boolean[]
}

// Mock ngx-json-viewer component
@Component({ selector: 'ngx-json-viewer', template: '' })
@Component({
selector: 'ngx-json-viewer',
template: '',
standalone: false,
})
class NgxJsonViewerStubComponent {
@Input()
json: ResourceFullResponseJson | {};
Expand Down
1 change: 1 addition & 0 deletions src/app/shared/json-viewer/json-viewer.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import { ResourceDetail } from '@awg-views/data-view/models';
templateUrl: './json-viewer.component.html',
styleUrls: ['./json-viewer.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class JsonViewerComponent {
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import { ChangeDetectionStrategy, Component, EventEmitter, Input, Output } from
templateUrl: './language-switcher.component.html',
styleUrls: ['./language-switcher.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: false,
})
export class LanguageSwitcherComponent {
/**
Expand Down
Loading

0 comments on commit c9cb060

Please sign in to comment.