step 1 - convert al lcomponents, directives and pipes to standalone

see https://v17.angular.io/guide/standalone-migration
I executed:
ng g @angular/core:standalone
and selected "Convert all components, directives and pipes to standalone"
This commit is contained in:
2024-10-13 09:55:07 +02:00
parent 526e1d842e
commit 08a481b5ba
44 changed files with 315 additions and 162 deletions

View File

@@ -8,8 +8,8 @@ describe('AddTextDialogComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ AddTextDialogComponent ]
})
imports: [AddTextDialogComponent]
})
.compileComponents();
fixture = TestBed.createComponent(AddTextDialogComponent);

View File

@@ -1,9 +1,18 @@
import { Component, ElementRef, Inject, ViewChild } from '@angular/core';
import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { MatDialogRef, MAT_DIALOG_DATA, MatDialogTitle, MatDialogContent, MatDialogActions, MatDialogClose } from '@angular/material/dialog';
import { CdkScrollable } from '@angular/cdk/scrolling';
import { MatFormField, MatLabel } from '@angular/material/form-field';
import { MatInput } from '@angular/material/input';
import { FormsModule } from '@angular/forms';
import { FocusDirective } from '../../../focus.directive';
import { MarkdownComponent } from 'ngx-markdown';
import { MatButton } from '@angular/material/button';
@Component({
selector: 'app-add-text-dialog',
templateUrl: './add-text-dialog.component.html'
selector: 'app-add-text-dialog',
templateUrl: './add-text-dialog.component.html',
standalone: true,
imports: [MatDialogTitle, CdkScrollable, MatDialogContent, MatFormField, MatLabel, MatInput, FormsModule, FocusDirective, MarkdownComponent, MatDialogActions, MatButton, MatDialogClose]
})
export class AddTextDialogComponent {
text = "";