[DURACOM-191] Fix missing import for ngIf and ngFor directive

This commit is contained in:
Giuseppe Digilio
2024-03-19 18:04:09 +01:00
parent dfad3f3fad
commit 2826ff5536
15 changed files with 39 additions and 4 deletions

View File

@@ -1,6 +1,7 @@
import {
AsyncPipe,
NgClass,
NgFor,
NgIf,
} from '@angular/common';
import {
@@ -83,6 +84,7 @@ import { ValidateEmailNotTaken } from './validators/email-taken.validator';
imports: [
FormComponent,
NgIf,
NgFor,
AsyncPipe,
TranslateModule,
NgClass,

View File

@@ -1,6 +1,7 @@
import {
AsyncPipe,
NgClass,
NgFor,
NgIf,
} from '@angular/common';
import {
@@ -54,6 +55,7 @@ import { LdnService } from '../ldn-services-model/ldn-services.model';
changeDetection: ChangeDetectionStrategy.Default,
imports: [
NgIf,
NgFor,
TranslateModule,
AsyncPipe,
PaginationComponent,

View File

@@ -1,6 +1,7 @@
import {
AsyncPipe,
NgForOf,
NgIf,
} from '@angular/common';
import {
Component,
@@ -59,6 +60,7 @@ import { QueryPredicate } from './query-predicate.model';
NgbAccordionModule,
TranslateModule,
AsyncPipe,
NgIf,
NgForOf,
FiltersComponent,
],

View File

@@ -24,6 +24,7 @@ import { AuthenticateAction } from '../../core/auth/auth.actions';
import { CoreState } from '../../core/core-state.model';
import { EPersonDataService } from '../../core/eperson/eperson-data.service';
import { Registration } from '../../core/shared/registration.model';
import { ProfilePageSecurityFormComponent } from '../../profile-page/profile-page-security-form/profile-page-security-form.component';
import { NotificationsService } from '../../shared/notifications/notifications.service';
import {
createFailedRemoteDataObject$,
@@ -84,6 +85,8 @@ describe('ForgotPasswordFormComponent', () => {
{ provide: NotificationsService, useValue: notificationsService },
],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
}).overrideComponent(ForgotPasswordFormComponent, {
remove: { imports: [ ProfilePageSecurityFormComponent ] },
}).compileComponents();
}));
beforeEach(() => {

View File

@@ -1,4 +1,7 @@
import { NgIf } from '@angular/common';
import {
NgFor,
NgIf,
} from '@angular/common';
import {
Component,
Input,
@@ -20,6 +23,7 @@ import { ObjectKeysPipe } from '../../../shared/utils/object-keys-pipe';
imports: [
TranslateModule,
NgIf,
NgFor,
ObjectKeysPipe,
],
standalone: true,

View File

@@ -1,3 +1,4 @@
import { NgIf } from '@angular/common';
import {
Component,
EventEmitter,
@@ -26,6 +27,7 @@ import { SuggestionEvidencesComponent } from './suggestion-evidences/suggestion-
templateUrl: './suggestion-list-element.component.html',
animations: [fadeIn],
imports: [
NgIf,
TranslateModule,
ItemSearchResultListElementComponent,
SuggestionActionsComponent,

View File

@@ -1,5 +1,6 @@
import {
AsyncPipe,
NgFor,
NgIf,
} from '@angular/common';
import {
@@ -44,6 +45,7 @@ import { SuggestionTargetsStateService } from '../suggestion-targets.state.servi
TranslateModule,
PaginationComponent,
NgIf,
NgFor,
RouterLink,
],
standalone: true,

View File

@@ -13,7 +13,9 @@ import { of as observableOf } from 'rxjs';
import { RestResponse } from '../../core/cache/response.models';
import { EPersonDataService } from '../../core/eperson/eperson-data.service';
import { AlertComponent } from '../../shared/alert/alert.component';
import { FormBuilderService } from '../../shared/form/builder/form-builder.service';
import { FormComponent } from '../../shared/form/form.component';
import { NotificationsService } from '../../shared/notifications/notifications.service';
import { VarDirective } from '../../shared/utils/var.directive';
import { ProfilePageSecurityFormComponent } from './profile-page-security-form.component';
@@ -52,6 +54,8 @@ describe('ProfilePageSecurityFormComponent', () => {
FormBuilderService,
],
schemas: [NO_ERRORS_SCHEMA],
}).overrideComponent(ProfilePageSecurityFormComponent, {
remove: { imports: [ FormComponent, AlertComponent ] },
}).compileComponents();
}));

View File

@@ -1,3 +1,4 @@
import { NgIf } from '@angular/common';
import {
Component,
EventEmitter,
@@ -32,6 +33,7 @@ import { NotificationsService } from '../../shared/notifications/notifications.s
selector: 'ds-profile-page-security-form',
templateUrl: './profile-page-security-form.component.html',
imports: [
NgIf,
FormComponent,
AlertComponent,
TranslateModule,

View File

@@ -4,6 +4,7 @@ import {
Inject,
OnInit,
} from '@angular/core';
import { RouterLinkActive } from '@angular/router';
import { TranslateModule } from '@ngx-translate/core';
import { isNotEmpty } from '../../empty.util';
@@ -17,7 +18,7 @@ import { ExternalLinkMenuItemModel } from './models/external-link.model';
styleUrls: ['./menu-item.component.scss'],
templateUrl: './external-link-menu-item.component.html',
standalone: true,
imports: [NgClass, TranslateModule],
imports: [NgClass, TranslateModule, RouterLinkActive],
})
export class ExternalLinkMenuItemComponent implements OnInit {
item: ExternalLinkMenuItemModel;

View File

@@ -3,6 +3,7 @@ import {
Component,
Inject,
} from '@angular/core';
import { RouterLinkActive } from '@angular/router';
import { TranslateModule } from '@ngx-translate/core';
import { OnClickMenuItemModel } from './models/onclick.model';
@@ -15,7 +16,7 @@ import { OnClickMenuItemModel } from './models/onclick.model';
styleUrls: ['./menu-item.component.scss', './onclick-menu-item.component.scss'],
templateUrl: './onclick-menu-item.component.html',
standalone: true,
imports: [NgIf, TranslateModule],
imports: [NgIf, TranslateModule, RouterLinkActive],
})
export class OnClickMenuItemComponent {
item: OnClickMenuItemModel;

View File

@@ -10,6 +10,7 @@ import { Item } from '../../../../core/shared/item.model';
import { WorkflowItem } from '../../../../core/submission/models/workflowitem.model';
import { ClaimedTask } from '../../../../core/tasks/models/claimed-task-object.model';
import { AbstractComponentLoaderComponent } from '../../../abstract-component-loader/abstract-component-loader.component';
import { DynamicComponentLoaderDirective } from '../../../abstract-component-loader/dynamic-component-loader.directive';
import { MyDSpaceActionsResult } from '../../mydspace-actions';
import { ClaimedTaskActionsAbstractComponent } from '../abstract/claimed-task-actions-abstract.component';
import { getComponentByWorkflowTaskOption } from './claimed-task-actions-decorator';
@@ -18,6 +19,7 @@ import { getComponentByWorkflowTaskOption } from './claimed-task-actions-decorat
selector: 'ds-claimed-task-actions-loader',
templateUrl: '../../../abstract-component-loader/abstract-component-loader.component.html',
standalone: true,
imports: [ DynamicComponentLoaderDirective ],
})
/**
* Component for loading a ClaimedTaskAction component depending on the "option" input

View File

@@ -15,6 +15,7 @@ import { ListableObject } from '../listable-object.model';
@Component({
selector: 'ds-objects-collection-tabulatable',
template: ``,
standalone: true,
})
/**

View File

@@ -11,6 +11,7 @@ import {
providers: [
{ provide: NG_VALIDATORS, useExisting: IpV4Validator, multi: true },
],
standalone: true,
})
/**
* Validator to validate if an Ip is in the right format

View File

@@ -46,7 +46,13 @@
"angularCompilerOptions": {
"fullTemplateTypeCheck": true,
"strictInjectionParameters": true,
"strictInputAccessModifiers": true
"strictInputAccessModifiers": true,
"extendedDiagnostics": {
// The categories to use for specific diagnostics.
"checks": {
"missingControlFlowDirective": "error"
},
}
},
"exclude": [
"cypress.config.ts"