Skip to content

Commit

Permalink
deps(platform): update project workspace to Angular 19
Browse files Browse the repository at this point in the history
  • Loading branch information
k-genov committed Jan 13, 2025
1 parent 796aeaa commit 47a5973
Show file tree
Hide file tree
Showing 70 changed files with 7,737 additions and 7,373 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/manual-workflow.deploy-devtools.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: DevTools Deployment
on: workflow_dispatch
env:
NODE_VERSION: 20.14.0
NODE_VERSION: 22.11.0
jobs:
install:
name: 'Installing NPM modules'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/manual-workflow.deploy-testing-app.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Testing App Deployment
on: workflow_dispatch
env:
NODE_VERSION: 20.14.0
NODE_VERSION: 22.11.0
jobs:
install:
name: 'Installing NPM modules'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Publish Developer Guide
on: workflow_dispatch
env:
NODE_VERSION: 20.14.0
NODE_VERSION: 22.11.0
jobs:
install:
name: 'Installing NPM modules'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/manual-workflow.publish-typedoc.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Publish TypeDoc
on: workflow_dispatch
env:
NODE_VERSION: 20.14.0
NODE_VERSION: 22.11.0
jobs:
install:
name: 'Installing NPM modules'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Continuous Integration and Delivery
on: [push, pull_request, workflow_dispatch]
env:
NODE_VERSION: 20.14.0
NODE_VERSION: 22.11.0
jobs:
install:
name: 'Installing NPM modules'
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ This section explains how to submit a pull request.
<summary><strong>Development</strong></summary>
<br>

Make sure to use Node.js version 20.14.0 for contributing to SCION. We suggest using [Node Version Manager](https://github.com/nvm-sh/nvm) if you need different Node.js versions for other projects.
Make sure to use Node.js version 22.11.0 for contributing to SCION. We suggest using [Node Version Manager](https://github.com/nvm-sh/nvm) if you need different Node.js versions for other projects.

For development, you can uncomment the section `PATH-OVERRIDE-FOR-DEVELOPMENT` in `tsconfig.json`. This allows running tests or serving applications without having to build dependent modules first.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ import {SciSashboxComponent, SciSashDirective} from '@scion/components/sashbox';
templateUrl: './app-details.component.html',
styleUrls: ['./app-details.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
ReactiveFormsModule,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
templateUrl: './app-list-item.component.html',
styleUrls: ['./app-list-item.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
SciMaterialIconDirective,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import {SciListComponent, SciListItemDirective} from '@scion/components.internal
templateUrl: './app-list.component.html',
styleUrls: ['./app-list.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
RouterLink,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
templateUrl: './app-menu.component.html',
styleUrls: ['./app-menu.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
RouterLink,
RouterLinkActive,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
templateUrl: './app.component.html',
styleUrls: ['./app.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
RouterOutlet,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
templateUrl: './capability-accordion-item.component.html',
styleUrls: ['./capability-accordion-item.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
SciQualifierChipListComponent,
SciMaterialIconDirective,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ import {SciTabbarComponent, SciTabDirective} from '@scion/components.internal/ta
templateUrl: './capability-accordion-panel.component.html',
styleUrls: ['./capability-accordion-panel.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
JsonPipe,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ import {SciFilterFieldComponent} from '@scion/components.internal/filter-field';
templateUrl: './capability-filter-result.component.html',
styleUrls: ['./capability-filter-result.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
ReactiveFormsModule,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {DevToolsManifestService} from '../dev-tools-manifest.service';
/**
* Resolves to the name of an application's symbolic name.
*/
@Pipe({name: 'devtoolsAppName', standalone: true})
@Pipe({name: 'devtoolsAppName'})
export class AppNamePipe implements PipeTransform {

constructor(private _manifestService: DevToolsManifestService) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {ParamDefinition} from '@scion/microfrontend-platform';
/**
* Extracts custom metadata associated with a param, if any, otherwise, returns `null`.
*/
@Pipe({name: 'devtoolsCustomParamMetadata', standalone: true})
@Pipe({name: 'devtoolsCustomParamMetadata'})
export class CustomParamMetadataPipe implements PipeTransform {

public readonly builtInProperties = new Set<string>()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {Pipe, PipeTransform} from '@angular/core';
/**
* Joins given items by given separator, applying given project function if specified.
*/
@Pipe({name: 'devtoolsJoin', standalone: true})
@Pipe({name: 'devtoolsJoin'})
export class JoinPipe implements PipeTransform {

public transform<T>(items: T[] | null | undefined, separator: string, projectFn?: (value: T) => string): string {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {Pipe, PipeTransform} from '@angular/core';
/**
* Returns `null` if the given object is empty.
*/
@Pipe({name: 'devtoolsNullIfEmpty', standalone: true})
@Pipe({name: 'devtoolsNullIfEmpty'})
export class NullIfEmptyPipe implements PipeTransform {

public transform<T>(value: T): T | null {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import {ParamDefinition} from '@scion/microfrontend-platform';
/**
* Filters required or optional parameters.
*/
@Pipe({name: 'devtoolsParamsFilter', standalone: true})
@Pipe({name: 'devtoolsParamsFilter'})
export class ParamsFilterPipe implements PipeTransform {

public transform(params: ParamDefinition[] | undefined | null, filter?: 'required' | 'optional'): ParamDefinition[] {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
templateUrl: './dependent-intentions.component.html',
styleUrls: ['./dependent-intentions.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
KeyValuePipe,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
templateUrl: './filter-field.component.html',
styleUrls: ['./filter-field.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
ReactiveFormsModule,
A11yModule,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import {AsyncPipe} from '@angular/common';
templateUrl: './find-capabilities.component.html',
styleUrls: ['./find-capabilities.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
SciViewportComponent,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ import {SciQualifierChipListComponent} from '@scion/components.internal/qualifie
templateUrl: './intention-accordion-item.component.html',
styleUrls: ['./intention-accordion-item.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
SciQualifierChipListComponent,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import {AsyncPipe} from '@angular/common';
templateUrl: './intention-accordion-panel.component.html',
styleUrls: ['./intention-accordion-panel.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* SPDX-License-Identifier: EPL-2.0
*/

import {APP_INITIALIZER, EnvironmentProviders, inject, InjectionToken, Injector, makeEnvironmentProviders, NgZone, runInInjectionContext} from '@angular/core';
import {EnvironmentProviders, inject, InjectionToken, Injector, makeEnvironmentProviders, NgZone, provideAppInitializer, runInInjectionContext} from '@angular/core';
import {ContextService, IntentClient, ManifestService, MessageClient, MicrofrontendPlatformClient, ObservableDecorator, OutletRouter} from '@scion/microfrontend-platform';
import {NgZoneObservableDecorator} from './ng-zone-observable-decorator';
import {Beans} from '@scion/toolkit/bean-manager';
Expand All @@ -24,11 +24,7 @@ export const MICROFRONTEND_PLATFORM_POST_CONNECT = new InjectionToken<unknown>('
*/
export function provideMicrofrontendPlatformClient(): EnvironmentProviders {
return makeEnvironmentProviders([
{
provide: APP_INITIALIZER,
useFactory: connectToHostFn,
multi: true,
},
provideAppInitializer(connectToHostFn),
{provide: MessageClient, useFactory: () => Beans.get(MessageClient)},
{provide: IntentClient, useFactory: () => Beans.get(IntentClient)},
{provide: OutletRouter, useFactory: () => Beans.get(OutletRouter)},
Expand All @@ -40,15 +36,12 @@ export function provideMicrofrontendPlatformClient(): EnvironmentProviders {
/**
* Connects devtools to the host.
*/
function connectToHostFn(): () => Promise<void> {
async function connectToHostFn(): Promise<void> {
const zone = inject(NgZone);
const injector = inject(Injector);

return async (): Promise<void> => {
Beans.register(ObservableDecorator, {useValue: new NgZoneObservableDecorator(zone)});
if (await zone.runOutsideAngular(() => MicrofrontendPlatformClient.connect(environment.symbolicName).then(() => true).catch(() => false))) {
await runInInjectionContext(injector, () => inject(MICROFRONTEND_PLATFORM_POST_CONNECT, {optional: true}));
}
};
Beans.register(ObservableDecorator, {useValue: new NgZoneObservableDecorator(zone)});
if (await zone.runOutsideAngular(() => MicrofrontendPlatformClient.connect(environment.symbolicName).then(() => true).catch(() => false))) {
await runInInjectionContext(injector, () => inject(MICROFRONTEND_PLATFORM_POST_CONNECT, {optional: true}));
}
}

Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
templateUrl: './required-capabilities.component.html',
styleUrls: ['./required-capabilities.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
AsyncPipe,
KeyValuePipe,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import {FormControl, ReactiveFormsModule} from '@angular/forms';
selector: 'app-shell',
templateUrl: './app-shell.component.html',
styleUrls: ['./app-shell.component.scss'],
standalone: true,
imports: [
AsyncPipe,
RouterOutlet,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ import {takeUntilDestroyed} from '@angular/core/rxjs-interop';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
standalone: true,
imports: [RouterOutlet],
})
export class AppComponent implements OnDestroy {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
templateUrl: './browser-outlet.component.html',
styleUrls: ['./browser-outlet.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
imports: [
ReactiveFormsModule,
SciMaterialIconDirective,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import {SciSashboxComponent, SciSashDirective} from '@scion/components/sashbox';
selector: 'app-browser-outlets',
templateUrl: './browser-outlets.component.html',
styleUrls: ['./browser-outlets.component.scss'],
standalone: true,
imports: [
AsyncPipe,
SciSashboxComponent,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {Pipe, PipeTransform, Type} from '@angular/core';
/**
* Casts given value to given type.
*/
@Pipe({name: 'appAs', standalone: true})
@Pipe({name: 'appAs'})
export class AppAsPipe implements PipeTransform {

public transform<T>(value: unknown, type: Type<T>): T {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import {ChangeDetectionStrategy, Component, Input} from '@angular/core';
templateUrl: './context-entry.component.html',
styleUrls: ['./context-entry.component.scss'],
changeDetection: ChangeDetectionStrategy.OnPush,
standalone: true,
})
export class ContextEntryComponent {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import {SciThrobberComponent} from '@scion/components/throbber';
selector: 'app-devtools',
templateUrl: './devtools.component.html',
styleUrls: ['./devtools.component.scss'],
standalone: true,
schemas: [CUSTOM_ELEMENTS_SCHEMA], // required because <sci-router-outlet> is a custom element
imports: [
SciThrobberComponent,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
selector: 'app-lookup-capability',
templateUrl: './lookup-capability.component.html',
styleUrls: ['./lookup-capability.component.scss'],
standalone: true,
imports: [
AsyncPipe,
JsonPipe,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import {SciQualifierChipListComponent} from '@scion/components.internal/qualifie
selector: 'app-lookup-intention',
templateUrl: './lookup-intention.component.html',
styleUrls: ['./lookup-intention.component.scss'],
standalone: true,
imports: [
AsyncPipe,
ReactiveFormsModule,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import {parseTypedValues} from '../../common/typed-value-parser.util';
selector: 'app-register-capability',
templateUrl: './register-capability.component.html',
styleUrls: ['./register-capability.component.scss'],
standalone: true,
imports: [
AsyncPipe,
JsonPipe,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ import {SciQualifierChipListComponent} from '@scion/components.internal/qualifie
selector: 'app-register-intention',
templateUrl: './register-intention.component.html',
styleUrls: ['./register-intention.component.scss'],
standalone: true,
imports: [
AsyncPipe,
ReactiveFormsModule,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import {Pipe, PipeTransform} from '@angular/core';
* - `null [null]`
* - `undefined [undefined]`
*/
@Pipe({name: 'appAppendParamDataType', standalone: true})
@Pipe({name: 'appAppendParamDataType'})
export class AppendParamDataTypePipe implements PipeTransform {

public transform(params: Map<string, any> | undefined): Map<string, any> | undefined {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import {SciKeyValueComponent} from '@scion/components.internal/key-value';
selector: 'app-message-list-item',
templateUrl: './message-list-item.component.html',
styleUrls: ['./message-list-item.component.scss'],
standalone: true,
imports: [
SciKeyValueComponent,
AppendParamDataTypePipe,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ import {parseTypedValues} from '../../common/typed-value-parser.util';
selector: 'app-publish-message',
templateUrl: './publish-message.component.html',
styleUrls: ['./publish-message.component.scss'],
standalone: true,
imports: [
AsyncPipe,
ReactiveFormsModule,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import {SciMaterialIconDirective} from '@scion/components.internal/material-icon
selector: 'app-receive-message',
templateUrl: './receive-message.component.html',
styleUrls: ['./receive-message.component.scss'],
standalone: true,
imports: [
ReactiveFormsModule,
SciFormFieldComponent,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import {Beans} from '@scion/toolkit/bean-manager';
/**
* Observes the number of subscribers on a topic.
*/
@Pipe({name: 'appTopicSubscriberCount$', standalone: true})
@Pipe({name: 'appTopicSubscriberCount$'})
export class TopicSubscriberCountPipe implements PipeTransform {

public transform(topic: string): Observable<number> {
Expand Down
Loading

0 comments on commit 47a5973

Please sign in to comment.