diff --git a/src/app/access-control/access-control.module.ts b/src/app/access-control/access-control.module.ts index 4625726765..87685bc295 100644 --- a/src/app/access-control/access-control.module.ts +++ b/src/app/access-control/access-control.module.ts @@ -1,7 +1,6 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; import { RouterModule } from '@angular/router'; -import { SharedModule } from '../shared/shared.module'; import { AccessControlRoutingModule } from './access-control-routing.module'; import { EPeopleRegistryComponent } from './epeople-registry/epeople-registry.component'; import { EPersonFormComponent } from './epeople-registry/eperson-form/eperson-form.component'; @@ -30,7 +29,6 @@ export const ValidateEmailErrorStateMatcher: DynamicErrorMessagesMatcher = @NgModule({ imports: [ CommonModule, - SharedModule, RouterModule, AccessControlRoutingModule, FormModule, diff --git a/src/app/admin/admin-notifications/admin-notifications.module.ts b/src/app/admin/admin-notifications/admin-notifications.module.ts index a31792027f..27d8d46597 100644 --- a/src/app/admin/admin-notifications/admin-notifications.module.ts +++ b/src/app/admin/admin-notifications/admin-notifications.module.ts @@ -1,7 +1,6 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; import { CoreModule } from '../../core/core.module'; -import { SharedModule } from '../../shared/shared.module'; import { AdminNotificationsRoutingModule } from './admin-notifications-routing.module'; import { AdminQualityAssuranceTopicsPageComponent } from './admin-quality-assurance-topics-page/admin-quality-assurance-topics-page.component'; import { AdminQualityAssuranceEventsPageComponent } from './admin-quality-assurance-events-page/admin-quality-assurance-events-page.component'; @@ -11,7 +10,6 @@ import {NotificationsModule} from '../../notifications/notifications.module'; @NgModule({ imports: [ CommonModule, - SharedModule, CoreModule.forRoot(), AdminNotificationsRoutingModule, NotificationsModule, diff --git a/src/app/admin/admin-registries/admin-registries.module.ts b/src/app/admin/admin-registries/admin-registries.module.ts index b438838aa7..1cfc1a9251 100644 --- a/src/app/admin/admin-registries/admin-registries.module.ts +++ b/src/app/admin/admin-registries/admin-registries.module.ts @@ -4,7 +4,6 @@ import { AdminRegistriesRoutingModule } from './admin-registries-routing.module' import { CommonModule } from '@angular/common'; import { MetadataSchemaComponent } from './metadata-schema/metadata-schema.component'; import { RouterModule } from '@angular/router'; -import { SharedModule } from '../../shared/shared.module'; import { MetadataSchemaFormComponent } from './metadata-registry/metadata-schema-form/metadata-schema-form.component'; import { MetadataFieldFormComponent } from './metadata-schema/metadata-field-form/metadata-field-form.component'; import { BitstreamFormatsModule } from './bitstream-formats/bitstream-formats.module'; @@ -13,7 +12,6 @@ import { FormModule } from '../../shared/form/form.module'; @NgModule({ imports: [ CommonModule, - SharedModule, RouterModule, BitstreamFormatsModule, AdminRegistriesRoutingModule, diff --git a/src/app/admin/admin-registries/bitstream-formats/bitstream-formats.module.ts b/src/app/admin/admin-registries/bitstream-formats/bitstream-formats.module.ts index fe4d453578..10565fa271 100644 --- a/src/app/admin/admin-registries/bitstream-formats/bitstream-formats.module.ts +++ b/src/app/admin/admin-registries/bitstream-formats/bitstream-formats.module.ts @@ -2,7 +2,6 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { RouterModule } from '@angular/router'; import { BitstreamFormatsComponent } from './bitstream-formats.component'; -import { SharedModule } from '../../../shared/shared.module'; import { FormatFormComponent } from './format-form/format-form.component'; import { EditBitstreamFormatComponent } from './edit-bitstream-format/edit-bitstream-format.component'; import { BitstreamFormatsRoutingModule } from './bitstream-formats-routing.module'; @@ -12,7 +11,6 @@ import { FormModule } from '../../../shared/form/form.module'; @NgModule({ imports: [ CommonModule, - SharedModule, RouterModule, BitstreamFormatsRoutingModule, FormModule, diff --git a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/collection-search-result/collection-admin-search-result-grid-element.component.spec.ts b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/collection-search-result/collection-admin-search-result-grid-element.component.spec.ts index 385888baa6..f437b6ca3d 100644 --- a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/collection-search-result/collection-admin-search-result-grid-element.component.spec.ts +++ b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/collection-search-result/collection-admin-search-result-grid-element.component.spec.ts @@ -2,7 +2,6 @@ import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { NoopAnimationsModule } from '@angular/platform-browser/animations'; import { BitstreamDataService } from '../../../../../core/data/bitstream-data.service'; import { mockTruncatableService } from '../../../../../shared/mocks/mock-trucatable.service'; -import { SharedModule } from '../../../../../shared/shared.module'; import { CollectionAdminSearchResultGridElementComponent } from './collection-admin-search-result-grid-element.component'; import { TranslateModule } from '@ngx-translate/core'; import { TruncatableService } from '../../../../../shared/truncatable/truncatable.service'; @@ -47,7 +46,6 @@ describe('CollectionAdminSearchResultGridElementComponent', () => { NoopAnimationsModule, TranslateModule.forRoot(), RouterTestingModule.withRoutes([]), - SharedModule, CollectionAdminSearchResultGridElementComponent ], providers: [ diff --git a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/community-search-result/community-admin-search-result-grid-element.component.spec.ts b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/community-search-result/community-admin-search-result-grid-element.component.spec.ts index 33de48884c..9db507db97 100644 --- a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/community-search-result/community-admin-search-result-grid-element.component.spec.ts +++ b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/community-search-result/community-admin-search-result-grid-element.component.spec.ts @@ -5,7 +5,6 @@ import { NoopAnimationsModule } from '@angular/platform-browser/animations'; import { TranslateModule } from '@ngx-translate/core'; import { BitstreamDataService } from '../../../../../core/data/bitstream-data.service'; import { mockTruncatableService } from '../../../../../shared/mocks/mock-trucatable.service'; -import { SharedModule } from '../../../../../shared/shared.module'; import { TruncatableService } from '../../../../../shared/truncatable/truncatable.service'; import { CollectionElementLinkType } from '../../../../../shared/object-collection/collection-element-link.type'; import { ViewMode } from '../../../../../core/shared/view-mode.model'; @@ -49,7 +48,6 @@ describe('CommunityAdminSearchResultGridElementComponent', () => { NoopAnimationsModule, TranslateModule.forRoot(), RouterTestingModule.withRoutes([]), - SharedModule, CommunityAdminSearchResultGridElementComponent ], providers: [ diff --git a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/item-search-result/item-admin-search-result-grid-element.component.spec.ts b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/item-search-result/item-admin-search-result-grid-element.component.spec.ts index 6ef5832119..bfab3840ec 100644 --- a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/item-search-result/item-admin-search-result-grid-element.component.spec.ts +++ b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/item-search-result/item-admin-search-result-grid-element.component.spec.ts @@ -8,7 +8,6 @@ import { RemoteData } from '../../../../../core/data/remote-data'; import { Bitstream } from '../../../../../core/shared/bitstream.model'; import { Item } from '../../../../../core/shared/item.model'; import { mockTruncatableService } from '../../../../../shared/mocks/mock-trucatable.service'; -import { SharedModule } from '../../../../../shared/shared.module'; import { TruncatableService } from '../../../../../shared/truncatable/truncatable.service'; import { CollectionElementLinkType } from '../../../../../shared/object-collection/collection-element-link.type'; import { ViewMode } from '../../../../../core/shared/view-mode.model'; @@ -62,7 +61,6 @@ describe('ItemAdminSearchResultGridElementComponent', () => { NoopAnimationsModule, TranslateModule.forRoot(), RouterTestingModule.withRoutes([]), - SharedModule, ItemAdminSearchResultGridElementComponent ], providers: [ diff --git a/src/app/admin/admin-search-page/admin-search.module.ts b/src/app/admin/admin-search-page/admin-search.module.ts index e88fc8b5b5..d7221514bb 100644 --- a/src/app/admin/admin-search-page/admin-search.module.ts +++ b/src/app/admin/admin-search-page/admin-search.module.ts @@ -1,5 +1,4 @@ import { NgModule } from '@angular/core'; -import { SharedModule } from '../../shared/shared.module'; import { AdminSearchPageComponent } from './admin-search-page.component'; import { ItemAdminSearchResultListElementComponent } from './admin-search-results/admin-search-result-list-element/item-search-result/item-admin-search-result-list-element.component'; import { CommunityAdminSearchResultListElementComponent } from './admin-search-results/admin-search-result-list-element/community-search-result/community-admin-search-result-list-element.component'; @@ -26,7 +25,6 @@ const ENTRY_COMPONENTS = [ @NgModule({ imports: [ SearchModule, - SharedModule.withEntryComponents(), JournalEntitiesModule.withEntryComponents(), ResearchEntitiesModule.withEntryComponents(), AdminSearchPageComponent, @@ -40,7 +38,7 @@ export class AdminSearchModule { */ static withEntryComponents() { return { - ngModule: SharedModule, + ngModule: AdminSearchModule, providers: ENTRY_COMPONENTS.map((component) => ({provide: component})) }; } diff --git a/src/app/admin/admin-workflow-page/admin-workflow.module.ts b/src/app/admin/admin-workflow-page/admin-workflow.module.ts index 64f3747be3..19b4145ee5 100644 --- a/src/app/admin/admin-workflow-page/admin-workflow.module.ts +++ b/src/app/admin/admin-workflow-page/admin-workflow.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; -import { SharedModule } from '../../shared/shared.module'; import { WorkflowItemSearchResultAdminWorkflowGridElementComponent } from './admin-workflow-search-results/admin-workflow-search-result-grid-element/workflow-item/workflow-item-search-result-admin-workflow-grid-element.component'; @@ -39,7 +38,6 @@ const ENTRY_COMPONENTS = [ @NgModule({ imports: [ SearchModule, - SharedModule.withEntryComponents(), AdminWorkflowPageComponent, SupervisionOrderGroupSelectorComponent, SupervisionOrderStatusComponent, @@ -58,7 +56,7 @@ export class AdminWorkflowModuleModule { */ static withEntryComponents() { return { - ngModule: SharedModule, + ngModule: AdminWorkflowModuleModule, providers: ENTRY_COMPONENTS.map((component) => ({provide: component})) }; } diff --git a/src/app/admin/admin.module.ts b/src/app/admin/admin.module.ts index 4da844f728..2ec3e06abf 100644 --- a/src/app/admin/admin.module.ts +++ b/src/app/admin/admin.module.ts @@ -1,5 +1,4 @@ import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { AccessControlModule } from '../access-control/access-control.module'; import { MetadataImportPageComponent } from './admin-import-metadata-page/metadata-import-page.component'; import { AdminRegistriesModule } from './admin-registries/admin-registries.module'; @@ -27,7 +26,6 @@ const ENTRY_COMPONENTS = [ AccessControlModule, AdminSearchModule.withEntryComponents(), AdminWorkflowModuleModule.withEntryComponents(), - SharedModule, UiSwitchModule, UploadModule, AdminCurationTasksComponent, diff --git a/src/app/app.module.ts b/src/app/app.module.ts index 9df6537231..321c43b4c5 100644 --- a/src/app/app.module.ts +++ b/src/app/app.module.ts @@ -19,7 +19,6 @@ import { appReducers, AppState, storeModuleConfig } from './app.reducer'; import { ClientCookieService } from './core/services/client-cookie.service'; import { NavbarModule } from './navbar/navbar.module'; import { DSpaceRouterStateSerializer } from './shared/ngrx/dspace-router-state-serializer'; -import { SharedModule } from './shared/shared.module'; import { environment } from '../environments/environment'; import { AuthInterceptor } from './core/auth/auth.interceptor'; import { LocaleInterceptor } from './core/locale/locale.interceptor'; @@ -31,6 +30,7 @@ import { StoreDevModules } from '../config/store/devtools'; import { RootModule } from './root.module'; import { models, provideCore } from './core/provide-core'; import { ThemedRootComponent } from './root/themed-root.component'; +import { listableObjects } from './core/provide-listable-objects'; export function getConfig() { return environment; @@ -48,7 +48,6 @@ export function getMetaReducers(appConfig: AppConfig): MetaReducer[] { const IMPORTS = [ CommonModule, - SharedModule, NavbarModule, HttpClientModule, AppRoutingModule, @@ -127,4 +126,5 @@ export class AppModule { /* Use models object so all decorators are actually called */ modelList = models; + listableObjects = listableObjects; } diff --git a/src/app/bitstream-page/bitstream-page.module.ts b/src/app/bitstream-page/bitstream-page.module.ts index dbe897c8c6..6793ee0af6 100644 --- a/src/app/bitstream-page/bitstream-page.module.ts +++ b/src/app/bitstream-page/bitstream-page.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { EditBitstreamPageComponent } from './edit-bitstream-page/edit-bitstream-page.component'; import { BitstreamPageRoutingModule } from './bitstream-page-routing.module'; import { BitstreamAuthorizationsComponent } from './bitstream-authorizations/bitstream-authorizations.component'; @@ -15,7 +14,6 @@ import { ThemedEditBitstreamPageComponent } from './edit-bitstream-page/themed-e @NgModule({ imports: [ CommonModule, - SharedModule, BitstreamPageRoutingModule, FormModule, ResourcePoliciesModule, diff --git a/src/app/browse-by/browse-by.module.ts b/src/app/browse-by/browse-by.module.ts index ca14f06da7..e82536a9e4 100644 --- a/src/app/browse-by/browse-by.module.ts +++ b/src/app/browse-by/browse-by.module.ts @@ -14,7 +14,6 @@ import { ThemedBrowseByTaxonomyPageComponent } from './browse-by-taxonomy-page/t import { SharedBrowseByModule } from '../shared/browse-by/shared-browse-by.module'; import { DsoPageModule } from '../shared/dso-page/dso-page.module'; import { FormModule } from '../shared/form/form.module'; -import { SharedModule } from '../shared/shared.module'; const ENTRY_COMPONENTS = [ // put only entry components that use custom decorator @@ -38,7 +37,6 @@ const ENTRY_COMPONENTS = [ FormModule, BrowseBySwitcherComponent, ThemedBrowseBySwitcherComponent, - SharedModule, ...ENTRY_COMPONENTS ], exports: [ diff --git a/src/app/collection-page/collection-form/collection-form.module.ts b/src/app/collection-page/collection-form/collection-form.module.ts index 88debb1957..c7e284230a 100644 --- a/src/app/collection-page/collection-form/collection-form.module.ts +++ b/src/app/collection-page/collection-form/collection-form.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { CollectionFormComponent } from './collection-form.component'; -import { SharedModule } from '../../shared/shared.module'; import { ComcolModule } from '../../shared/comcol/comcol.module'; import { FormModule } from '../../shared/form/form.module'; @@ -9,7 +8,6 @@ import { FormModule } from '../../shared/form/form.module'; imports: [ ComcolModule, FormModule, - SharedModule, CollectionFormComponent ], exports: [ diff --git a/src/app/collection-page/collection-page.module.ts b/src/app/collection-page/collection-page.module.ts index ba908f9fcc..220008774a 100644 --- a/src/app/collection-page/collection-page.module.ts +++ b/src/app/collection-page/collection-page.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { CollectionPageComponent } from './collection-page.component'; import { CollectionPageRoutingModule } from './collection-page-routing.module'; @@ -22,7 +21,6 @@ import { DsoPageModule } from '../shared/dso-page/dso-page.module'; @NgModule({ imports: [ CommonModule, - SharedModule, CollectionPageRoutingModule, StatisticsModule.forRoot(), EditItemPageModule, diff --git a/src/app/collection-page/create-collection-page/create-collection-page.component.spec.ts b/src/app/collection-page/create-collection-page/create-collection-page.component.spec.ts index 9aacde2507..df8dd99c81 100644 --- a/src/app/collection-page/create-collection-page/create-collection-page.component.spec.ts +++ b/src/app/collection-page/create-collection-page/create-collection-page.component.spec.ts @@ -5,7 +5,6 @@ import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { NO_ERRORS_SCHEMA } from '@angular/core'; import { RouteService } from '../../core/services/route.service'; -import { SharedModule } from '../../shared/shared.module'; import { CollectionDataService } from '../../core/data/collection-data.service'; import { of as observableOf } from 'rxjs'; import { CommunityDataService } from '../../core/data/community-data.service'; @@ -25,7 +24,7 @@ describe('CreateCollectionPageComponent', () => { beforeEach(waitForAsync(() => { return TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, CreateCollectionPageComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, CreateCollectionPageComponent], providers: [ { provide: DSONameService, useValue: new DSONameServiceMock() }, { provide: CollectionDataService, useValue: {} }, diff --git a/src/app/collection-page/delete-collection-page/delete-collection-page.component.spec.ts b/src/app/collection-page/delete-collection-page/delete-collection-page.component.spec.ts index b95b8958fb..1e14f3d9a9 100644 --- a/src/app/collection-page/delete-collection-page/delete-collection-page.component.spec.ts +++ b/src/app/collection-page/delete-collection-page/delete-collection-page.component.spec.ts @@ -4,7 +4,6 @@ import { TranslateModule } from '@ngx-translate/core'; import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { NO_ERRORS_SCHEMA } from '@angular/core'; -import { SharedModule } from '../../shared/shared.module'; import { of as observableOf } from 'rxjs'; import { NotificationsService } from '../../shared/notifications/notifications.service'; import { DeleteCollectionPageComponent } from './delete-collection-page.component'; @@ -19,7 +18,7 @@ describe('DeleteCollectionPageComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, DeleteCollectionPageComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, DeleteCollectionPageComponent], providers: [ { provide: DSONameService, useValue: new DSONameServiceMock() }, { provide: CollectionDataService, useValue: {} }, diff --git a/src/app/collection-page/edit-collection-page/collection-metadata/collection-metadata.component.spec.ts b/src/app/collection-page/edit-collection-page/collection-metadata/collection-metadata.component.spec.ts index ce820d93df..66d5909bbd 100644 --- a/src/app/collection-page/edit-collection-page/collection-metadata/collection-metadata.component.spec.ts +++ b/src/app/collection-page/edit-collection-page/collection-metadata/collection-metadata.component.spec.ts @@ -1,6 +1,5 @@ import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { TranslateModule } from '@ngx-translate/core'; -import { SharedModule } from '../../../shared/shared.module'; import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { CollectionDataService } from '../../../core/data/collection-data.service'; @@ -63,7 +62,7 @@ describe('CollectionMetadataComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, CollectionMetadataComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, CollectionMetadataComponent], providers: [ { provide: CollectionDataService, useValue: {} }, { provide: ItemTemplateDataService, useValue: itemTemplateServiceStub }, diff --git a/src/app/collection-page/edit-collection-page/collection-roles/collection-roles.component.spec.ts b/src/app/collection-page/edit-collection-page/collection-roles/collection-roles.component.spec.ts index fd75a00173..fbfb1036d6 100644 --- a/src/app/collection-page/edit-collection-page/collection-roles/collection-roles.component.spec.ts +++ b/src/app/collection-page/edit-collection-page/collection-roles/collection-roles.component.spec.ts @@ -6,7 +6,6 @@ import { DebugElement, NO_ERRORS_SCHEMA } from '@angular/core'; import { By } from '@angular/platform-browser'; import { CollectionRolesComponent } from './collection-roles.component'; import { Collection } from '../../../core/shared/collection.model'; -import { SharedModule } from '../../../shared/shared.module'; import { GroupDataService } from '../../../core/eperson/group-data.service'; import { RequestService } from '../../../core/data/request.service'; import { RouterTestingModule } from '@angular/router/testing'; @@ -71,7 +70,6 @@ describe('CollectionRolesComponent', () => { TestBed.configureTestingModule({ imports: [ ComcolModule, - SharedModule, RouterTestingModule.withRoutes([]), TranslateModule.forRoot(), NoopAnimationsModule, diff --git a/src/app/collection-page/edit-collection-page/edit-collection-page.component.spec.ts b/src/app/collection-page/edit-collection-page/edit-collection-page.component.spec.ts index c60a34f8b9..290a9ca5d1 100644 --- a/src/app/collection-page/edit-collection-page/edit-collection-page.component.spec.ts +++ b/src/app/collection-page/edit-collection-page/edit-collection-page.component.spec.ts @@ -5,7 +5,6 @@ import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { NO_ERRORS_SCHEMA } from '@angular/core'; import { EditCollectionPageComponent } from './edit-collection-page.component'; -import { SharedModule } from '../../shared/shared.module'; import { CollectionDataService } from '../../core/data/collection-data.service'; import { of as observableOf } from 'rxjs'; @@ -38,7 +37,7 @@ describe('EditCollectionPageComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, EditCollectionPageComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, EditCollectionPageComponent], providers: [ { provide: CollectionDataService, useValue: {} }, { provide: ActivatedRoute, useValue: routeStub }, diff --git a/src/app/collection-page/edit-collection-page/edit-collection-page.module.ts b/src/app/collection-page/edit-collection-page/edit-collection-page.module.ts index adaa964a7c..0648b7d604 100644 --- a/src/app/collection-page/edit-collection-page/edit-collection-page.module.ts +++ b/src/app/collection-page/edit-collection-page/edit-collection-page.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { EditCollectionPageComponent } from './edit-collection-page.component'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../../shared/shared.module'; import { EditCollectionPageRoutingModule } from './edit-collection-page.routing.module'; import { CollectionMetadataComponent } from './collection-metadata/collection-metadata.component'; import { CollectionRolesComponent } from './collection-roles/collection-roles.component'; @@ -24,7 +23,6 @@ import { AccessControlFormModule } from '../../shared/access-control-form-contai @NgModule({ imports: [ CommonModule, - SharedModule, EditCollectionPageRoutingModule, CollectionFormModule, ResourcePoliciesModule, diff --git a/src/app/collection-page/edit-item-template-page/edit-item-template-page.component.spec.ts b/src/app/collection-page/edit-item-template-page/edit-item-template-page.component.spec.ts index cf206384d6..098337c67b 100644 --- a/src/app/collection-page/edit-item-template-page/edit-item-template-page.component.spec.ts +++ b/src/app/collection-page/edit-item-template-page/edit-item-template-page.component.spec.ts @@ -1,7 +1,6 @@ import { EditItemTemplatePageComponent } from './edit-item-template-page.component'; import { waitForAsync, ComponentFixture, TestBed } from '@angular/core/testing'; import { TranslateModule } from '@ngx-translate/core'; -import { SharedModule } from '../../shared/shared.module'; import { RouterTestingModule } from '@angular/router/testing'; import { CommonModule } from '@angular/common'; import { ItemTemplateDataService } from '../../core/data/item-template-data.service'; @@ -32,7 +31,7 @@ describe('EditItemTemplatePageComponent', () => { findByCollectionID: createSuccessfulRemoteDataObject$({}) }); TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, EditItemTemplatePageComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, EditItemTemplatePageComponent], providers: [ { provide: ItemTemplateDataService, useValue: itemTemplateService }, { provide: ActivatedRoute, useValue: { parent: { data: observableOf({ dso: createSuccessfulRemoteDataObject(collection) }) } } }, diff --git a/src/app/community-list-page/community-list-page.module.ts b/src/app/community-list-page/community-list-page.module.ts index 73b7ed6421..945a3bf9ea 100644 --- a/src/app/community-list-page/community-list-page.module.ts +++ b/src/app/community-list-page/community-list-page.module.ts @@ -1,6 +1,5 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { CommunityListPageComponent } from './community-list-page.component'; import { CommunityListPageRoutingModule } from './community-list-page.routing.module'; import { CommunityListComponent } from './community-list/community-list.component'; @@ -21,7 +20,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, CommunityListPageRoutingModule, CdkTreeModule, ...DECLARATIONS diff --git a/src/app/community-page/community-form/community-form.module.ts b/src/app/community-page/community-form/community-form.module.ts index a8bddb5ffe..43de3e66d4 100644 --- a/src/app/community-page/community-form/community-form.module.ts +++ b/src/app/community-page/community-form/community-form.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { CommunityFormComponent } from './community-form.component'; -import { SharedModule } from '../../shared/shared.module'; import { ComcolModule } from '../../shared/comcol/comcol.module'; import { FormModule } from '../../shared/form/form.module'; @@ -9,7 +8,6 @@ import { FormModule } from '../../shared/form/form.module'; imports: [ ComcolModule, FormModule, - SharedModule, CommunityFormComponent ], exports: [ diff --git a/src/app/community-page/community-page.module.ts b/src/app/community-page/community-page.module.ts index d997351bca..2acefe19bb 100644 --- a/src/app/community-page/community-page.module.ts +++ b/src/app/community-page/community-page.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { CommunityPageComponent } from './community-page.component'; import { CommunityPageSubCollectionListComponent } from './sub-collection-list/community-page-sub-collection-list.component'; @@ -33,7 +32,6 @@ const DECLARATIONS = [CommunityPageComponent, @NgModule({ imports: [ CommonModule, - SharedModule, CommunityPageRoutingModule, StatisticsModule.forRoot(), CommunityFormModule, diff --git a/src/app/community-page/create-community-page/create-community-page.component.spec.ts b/src/app/community-page/create-community-page/create-community-page.component.spec.ts index 5f2391662d..6be7926c3d 100644 --- a/src/app/community-page/create-community-page/create-community-page.component.spec.ts +++ b/src/app/community-page/create-community-page/create-community-page.component.spec.ts @@ -5,7 +5,6 @@ import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { NO_ERRORS_SCHEMA } from '@angular/core'; import { RouteService } from '../../core/services/route.service'; -import { SharedModule } from '../../shared/shared.module'; import { of as observableOf } from 'rxjs'; import { CommunityDataService } from '../../core/data/community-data.service'; import { CreateCommunityPageComponent } from './create-community-page.component'; @@ -22,7 +21,7 @@ describe('CreateCommunityPageComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, CreateCommunityPageComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, CreateCommunityPageComponent], providers: [ { provide: CommunityDataService, useValue: { findById: () => observableOf({}) } }, { provide: RouteService, useValue: { getQueryParameterValue: () => observableOf('1234') } }, diff --git a/src/app/community-page/delete-community-page/delete-community-page.component.spec.ts b/src/app/community-page/delete-community-page/delete-community-page.component.spec.ts index 4fcc1cc26f..4fea19f274 100644 --- a/src/app/community-page/delete-community-page/delete-community-page.component.spec.ts +++ b/src/app/community-page/delete-community-page/delete-community-page.component.spec.ts @@ -7,7 +7,6 @@ import { TranslateModule } from '@ngx-translate/core'; import { of as observableOf } from 'rxjs'; import { CommunityDataService } from '../../core/data/community-data.service'; import { NotificationsService } from '../../shared/notifications/notifications.service'; -import { SharedModule } from '../../shared/shared.module'; import { DeleteCommunityPageComponent } from './delete-community-page.component'; import { RequestService } from '../../core/data/request.service'; import { DSONameService } from '../../core/breadcrumbs/dso-name.service'; @@ -19,7 +18,7 @@ describe('DeleteCommunityPageComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, DeleteCommunityPageComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, DeleteCommunityPageComponent], providers: [ { provide: DSONameService, useValue: new DSONameServiceMock() }, { provide: CommunityDataService, useValue: {} }, diff --git a/src/app/community-page/edit-community-page/community-metadata/community-metadata.component.spec.ts b/src/app/community-page/edit-community-page/community-metadata/community-metadata.component.spec.ts index e7f2ccc26d..e1df0d981e 100644 --- a/src/app/community-page/edit-community-page/community-metadata/community-metadata.component.spec.ts +++ b/src/app/community-page/edit-community-page/community-metadata/community-metadata.component.spec.ts @@ -1,6 +1,5 @@ import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { TranslateModule } from '@ngx-translate/core'; -import { SharedModule } from '../../../shared/shared.module'; import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { ActivatedRoute } from '@angular/router'; @@ -18,7 +17,7 @@ describe('CommunityMetadataComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, CommunityMetadataComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, CommunityMetadataComponent], providers: [ { provide: CommunityDataService, useValue: {} }, { provide: ActivatedRoute, useValue: { parent: { data: observableOf({ dso: { payload: {} } }) } } }, diff --git a/src/app/community-page/edit-community-page/community-roles/community-roles.component.spec.ts b/src/app/community-page/edit-community-page/community-roles/community-roles.component.spec.ts index 615baf8897..0e0bc02b11 100644 --- a/src/app/community-page/edit-community-page/community-roles/community-roles.component.spec.ts +++ b/src/app/community-page/edit-community-page/community-roles/community-roles.component.spec.ts @@ -8,7 +8,6 @@ import { Community } from '../../../core/shared/community.model'; import { By } from '@angular/platform-browser'; import { RequestService } from '../../../core/data/request.service'; import { GroupDataService } from '../../../core/eperson/group-data.service'; -import { SharedModule } from '../../../shared/shared.module'; import { RouterTestingModule } from '@angular/router/testing'; import { createSuccessfulRemoteDataObject, createSuccessfulRemoteDataObject$ } from '../../../shared/remote-data.utils'; import { NoopAnimationsModule } from '@angular/platform-browser/animations'; @@ -56,7 +55,6 @@ describe('CommunityRolesComponent', () => { TestBed.configureTestingModule({ imports: [ ComcolModule, - SharedModule, RouterTestingModule.withRoutes([]), TranslateModule.forRoot(), NoopAnimationsModule, diff --git a/src/app/community-page/edit-community-page/edit-community-page.component.spec.ts b/src/app/community-page/edit-community-page/edit-community-page.component.spec.ts index 0843366fbc..5feddd0f98 100644 --- a/src/app/community-page/edit-community-page/edit-community-page.component.spec.ts +++ b/src/app/community-page/edit-community-page/edit-community-page.component.spec.ts @@ -4,7 +4,6 @@ import { TranslateModule } from '@ngx-translate/core'; import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { NO_ERRORS_SCHEMA } from '@angular/core'; -import { SharedModule } from '../../shared/shared.module'; import { of as observableOf } from 'rxjs'; import { EditCommunityPageComponent } from './edit-community-page.component'; import { CommunityDataService } from '../../core/data/community-data.service'; @@ -38,7 +37,7 @@ describe('EditCommunityPageComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule, EditCommunityPageComponent], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule, EditCommunityPageComponent], providers: [ { provide: CommunityDataService, useValue: {} }, { provide: ActivatedRoute, useValue: routeStub }, diff --git a/src/app/community-page/edit-community-page/edit-community-page.module.ts b/src/app/community-page/edit-community-page/edit-community-page.module.ts index 65ad5e3df7..8b2086494a 100644 --- a/src/app/community-page/edit-community-page/edit-community-page.module.ts +++ b/src/app/community-page/edit-community-page/edit-community-page.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../../shared/shared.module'; import { EditCommunityPageRoutingModule } from './edit-community-page.routing.module'; import { EditCommunityPageComponent } from './edit-community-page.component'; import { CommunityCurateComponent } from './community-curate/community-curate.component'; @@ -21,7 +20,6 @@ import { @NgModule({ imports: [ CommonModule, - SharedModule, EditCommunityPageRoutingModule, CommunityFormModule, ComcolModule, diff --git a/src/app/community-page/sub-collection-list/community-page-sub-collection-list.component.spec.ts b/src/app/community-page/sub-collection-list/community-page-sub-collection-list.component.spec.ts index dd7a6411cd..90310af6f2 100644 --- a/src/app/community-page/sub-collection-list/community-page-sub-collection-list.component.spec.ts +++ b/src/app/community-page/sub-collection-list/community-page-sub-collection-list.component.spec.ts @@ -9,7 +9,6 @@ import { NgbModule } from '@ng-bootstrap/ng-bootstrap'; import { CommunityPageSubCollectionListComponent } from './community-page-sub-collection-list.component'; import { Community } from '../../core/shared/community.model'; -import { SharedModule } from '../../shared/shared.module'; import { CollectionDataService } from '../../core/data/collection-data.service'; import { createSuccessfulRemoteDataObject$ } from '../../shared/remote-data.utils'; import { buildPaginatedList } from '../../core/data/paginated-list.model'; @@ -149,7 +148,6 @@ describe('CommunityPageSubCollectionList Component', () => { TestBed.configureTestingModule({ imports: [ TranslateModule.forRoot(), - SharedModule, RouterTestingModule.withRoutes([]), NgbModule, NoopAnimationsModule, diff --git a/src/app/community-page/sub-community-list/community-page-sub-community-list.component.spec.ts b/src/app/community-page/sub-community-list/community-page-sub-community-list.component.spec.ts index a5a8feda59..4d728311b4 100644 --- a/src/app/community-page/sub-community-list/community-page-sub-community-list.component.spec.ts +++ b/src/app/community-page/sub-community-list/community-page-sub-community-list.component.spec.ts @@ -11,7 +11,6 @@ import { CommunityPageSubCommunityListComponent } from './community-page-sub-com import { Community } from '../../core/shared/community.model'; import { buildPaginatedList } from '../../core/data/paginated-list.model'; import { PageInfo } from '../../core/shared/page-info.model'; -import { SharedModule } from '../../shared/shared.module'; import { createSuccessfulRemoteDataObject$ } from '../../shared/remote-data.utils'; import { HostWindowService } from '../../shared/host-window.service'; import { HostWindowServiceStub } from '../../shared/testing/host-window-service.stub'; @@ -150,7 +149,6 @@ describe('CommunityPageSubCommunityListComponent Component', () => { TestBed.configureTestingModule({ imports: [ TranslateModule.forRoot(), - SharedModule, RouterTestingModule.withRoutes([]), NgbModule, NoopAnimationsModule, diff --git a/src/app/core/provide-listable-objects.ts b/src/app/core/provide-listable-objects.ts new file mode 100644 index 0000000000..b4906015f8 --- /dev/null +++ b/src/app/core/provide-listable-objects.ts @@ -0,0 +1,244 @@ +import { BundleListElementComponent } from '../shared/object-list/bundle-list-element/bundle-list-element.component'; +import { + CollectionListElementComponent +} from '../shared/object-list/collection-list-element/collection-list-element.component'; +import { + CommunityListElementComponent +} from '../shared/object-list/community-list-element/community-list-element.component'; +import { + SearchResultListElementComponent +} from '../shared/object-list/search-result-list-element/search-result-list-element.component'; +import { + CommunitySearchResultListElementComponent +} from '../shared/object-list/search-result-list-element/community-search-result/community-search-result-list-element.component'; +import { + CollectionSearchResultListElementComponent +} from '../shared/object-list/search-result-list-element/collection-search-result/collection-search-result-list-element.component'; +import { + CollectionGridElementComponent +} from '../shared/object-grid/collection-grid-element/collection-grid-element.component'; +import { + CommunityGridElementComponent +} from '../shared/object-grid/community-grid-element/community-grid-element.component'; +import { + CommunitySearchResultGridElementComponent +} from '../shared/object-grid/search-result-grid-element/community-search-result/community-search-result-grid-element.component'; +import { + CollectionSearchResultGridElementComponent +} from '../shared/object-grid/search-result-grid-element/collection-search-result/collection-search-result-grid-element.component'; +import { + SearchResultGridElementComponent +} from '../shared/object-grid/search-result-grid-element/search-result-grid-element.component'; +import { + ItemListElementComponent +} from '../shared/object-list/item-list-element/item-types/item/item-list-element.component'; +import { + ItemGridElementComponent +} from '../shared/object-grid/item-grid-element/item-types/item/item-grid-element.component'; +import { BitstreamListItemComponent } from '../shared/object-list/bitstream-list-item/bitstream-list-item.component'; +import { + ItemSearchResultListElementComponent +} from '../shared/object-list/search-result-list-element/item-search-result/item-types/item/item-search-result-list-element.component'; +import { + ItemSearchResultGridElementComponent +} from '../shared/object-grid/search-result-grid-element/item-search-result/item/item-search-result-grid-element.component'; +import { + BrowseEntryListElementComponent +} from '../shared/object-list/browse-entry-list-element/browse-entry-list-element.component'; +import { + SearchResultDetailElementComponent +} from '../shared/object-detail/my-dspace-result-detail-element/search-result-detail-element.component'; +import { StartsWithDateComponent } from '../shared/starts-with/date/starts-with-date.component'; +import { StartsWithTextComponent } from '../shared/starts-with/text/starts-with-text.component'; +import { + CreateCommunityParentSelectorComponent +} from '../shared/dso-selector/modal-wrappers/create-community-parent-selector/create-community-parent-selector.component'; +import { + ThemedCreateCommunityParentSelectorComponent +} from '../shared/dso-selector/modal-wrappers/create-community-parent-selector/themed-create-community-parent-selector.component'; +import { + CreateCollectionParentSelectorComponent +} from '../shared/dso-selector/modal-wrappers/create-collection-parent-selector/create-collection-parent-selector.component'; +import { + ThemedCreateCollectionParentSelectorComponent +} from '../shared/dso-selector/modal-wrappers/create-collection-parent-selector/themed-create-collection-parent-selector.component'; +import { + CreateItemParentSelectorComponent +} from '../shared/dso-selector/modal-wrappers/create-item-parent-selector/create-item-parent-selector.component'; +import { + ThemedCreateItemParentSelectorComponent +} from '../shared/dso-selector/modal-wrappers/create-item-parent-selector/themed-create-item-parent-selector.component'; +import { + EditCommunitySelectorComponent +} from '../shared/dso-selector/modal-wrappers/edit-community-selector/edit-community-selector.component'; +import { + ThemedEditCommunitySelectorComponent +} from '../shared/dso-selector/modal-wrappers/edit-community-selector/themed-edit-community-selector.component'; +import { + EditCollectionSelectorComponent +} from '../shared/dso-selector/modal-wrappers/edit-collection-selector/edit-collection-selector.component'; +import { + ThemedEditCollectionSelectorComponent +} from '../shared/dso-selector/modal-wrappers/edit-collection-selector/themed-edit-collection-selector.component'; +import { + EditItemSelectorComponent +} from '../shared/dso-selector/modal-wrappers/edit-item-selector/edit-item-selector.component'; +import { + ThemedEditItemSelectorComponent +} from '../shared/dso-selector/modal-wrappers/edit-item-selector/themed-edit-item-selector.component'; +import { + PlainTextMetadataListElementComponent +} from '../shared/object-list/metadata-representation-list-element/plain-text/plain-text-metadata-list-element.component'; +import { + BrowseLinkMetadataListElementComponent +} from '../shared/object-list/metadata-representation-list-element/browse-link/browse-link-metadata-list-element.component'; +import { + ItemMetadataListElementComponent +} from '../shared/object-list/metadata-representation-list-element/item/item-metadata-list-element.component'; +import { + MetadataRepresentationListElementComponent +} from '../shared/object-list/metadata-representation-list-element/metadata-representation-list-element.component'; +import { + ItemMetadataRepresentationListElementComponent +} from '../shared/object-list/metadata-representation-list-element/item/item-metadata-representation-list-element.component'; +import { LogInPasswordComponent } from '../shared/log-in/methods/password/log-in-password.component'; +import { + LogInExternalProviderComponent +} from '../shared/log-in/methods/log-in-external-provider/log-in-external-provider.component'; +import { + ClaimedTaskActionsDeclineTaskComponent +} from '../shared/mydspace-actions/claimed-task/decline-task/claimed-task-actions-decline-task.component'; +import { CollectionDropdownComponent } from '../shared/collection-dropdown/collection-dropdown.component'; +import { ThemedCollectionDropdownComponent } from '../shared/collection-dropdown/themed-collection-dropdown.component'; +import { FileDownloadLinkComponent } from '../shared/file-download-link/file-download-link.component'; +import { ThemedFileDownloadLinkComponent } from '../shared/file-download-link/themed-file-download-link.component'; +import { CurationFormComponent } from '../curation-form/curation-form.component'; +import { + ExportMetadataSelectorComponent +} from '../shared/dso-selector/modal-wrappers/export-metadata-selector/export-metadata-selector.component'; +import { + ImportBatchSelectorComponent +} from '../shared/dso-selector/modal-wrappers/import-batch-selector/import-batch-selector.component'; +import { + ExportBatchSelectorComponent +} from '../shared/dso-selector/modal-wrappers/export-batch-selector/export-batch-selector.component'; +import { ConfirmationModalComponent } from '../shared/confirmation-modal/confirmation-modal.component'; +import { + SidebarSearchListElementComponent +} from '../shared/object-list/sidebar-search-list-element/sidebar-search-list-element.component'; +import { + PublicationSidebarSearchListElementComponent +} from '../shared/object-list/sidebar-search-list-element/item-types/publication/publication-sidebar-search-list-element.component'; +import { + CollectionSidebarSearchListElementComponent +} from '../shared/object-list/sidebar-search-list-element/collection/collection-sidebar-search-list-element.component'; +import { + CommunitySidebarSearchListElementComponent +} from '../shared/object-list/sidebar-search-list-element/community/community-sidebar-search-list-element.component'; +import { ScopeSelectorModalComponent } from '../shared/search-form/scope-selector-modal/scope-selector-modal.component'; +import { + ListableNotificationObjectComponent +} from '../shared/object-list/listable-notification-object/listable-notification-object.component'; +import { + AdvancedClaimedTaskActionSelectReviewerComponent +} from '../shared/mydspace-actions/claimed-task/select-reviewer/advanced-claimed-task-action-select-reviewer.component'; +import { + AdvancedClaimedTaskActionRatingComponent +} from '../shared/mydspace-actions/claimed-task/rating/advanced-claimed-task-action-rating.component'; +import { EpersonGroupListComponent } from '../shared/eperson-group-list/eperson-group-list.component'; +import { + EpersonSearchBoxComponent +} from '../shared/eperson-group-list/eperson-search-box/eperson-search-box.component'; +import { GroupSearchBoxComponent } from '../shared/eperson-group-list/group-search-box/group-search-box.component'; + + +// export const provideCore = () => { +// console.log('provideCore'); +// return makeEnvironmentProviders([ +// {provide: DspaceRestService, useFactory: restServiceFactory, deps: [MOCK_RESPONSE_MAP, HttpClient]}, +// +// importProvidersFrom( +// StoreModule.forFeature('core', coreReducers, storeModuleConfig as StoreConfig), +// EffectsModule.forFeature(coreEffects) +// ), +// ]); +// }; +// +// /** +// * When not in production, endpoint responses can be mocked for testing purposes +// * If there is no mock version available for the endpoint, the actual REST response will be used just like in production mode +// */ +// export const restServiceFactory = (mocks: ResponseMapMock, http: HttpClient) => { +// if (environment.production) { +// return new DspaceRestService(http); +// } else { +// return new EndpointMockingRestService(mocks, http); +// } +// }; + +/** + * Declaration needed to make sure all decorator functions are called in time + */ +export const listableObjects = + [ + BundleListElementComponent, + CollectionListElementComponent, + CommunityListElementComponent, + SearchResultListElementComponent, + CommunitySearchResultListElementComponent, + CollectionSearchResultListElementComponent, + CollectionGridElementComponent, + CommunityGridElementComponent, + CommunitySearchResultGridElementComponent, + CollectionSearchResultGridElementComponent, + SearchResultGridElementComponent, + ItemListElementComponent, + ItemGridElementComponent, + BitstreamListItemComponent, + ItemSearchResultListElementComponent, + ItemSearchResultGridElementComponent, + BrowseEntryListElementComponent, + SearchResultDetailElementComponent, + StartsWithDateComponent, + StartsWithTextComponent, + CreateCommunityParentSelectorComponent, + ThemedCreateCommunityParentSelectorComponent, + CreateCollectionParentSelectorComponent, + ThemedCreateCollectionParentSelectorComponent, + CreateItemParentSelectorComponent, + ThemedCreateItemParentSelectorComponent, + EditCommunitySelectorComponent, + ThemedEditCommunitySelectorComponent, + EditCollectionSelectorComponent, + ThemedEditCollectionSelectorComponent, + EditItemSelectorComponent, + ThemedEditItemSelectorComponent, + PlainTextMetadataListElementComponent, + BrowseLinkMetadataListElementComponent, + ItemMetadataListElementComponent, + MetadataRepresentationListElementComponent, + ItemMetadataRepresentationListElementComponent, + LogInPasswordComponent, + LogInExternalProviderComponent, + ClaimedTaskActionsDeclineTaskComponent, + CollectionDropdownComponent, + ThemedCollectionDropdownComponent, + FileDownloadLinkComponent, + ThemedFileDownloadLinkComponent, + CurationFormComponent, + ExportMetadataSelectorComponent, + ImportBatchSelectorComponent, + ExportBatchSelectorComponent, + ConfirmationModalComponent, + SidebarSearchListElementComponent, + PublicationSidebarSearchListElementComponent, + CollectionSidebarSearchListElementComponent, + CommunitySidebarSearchListElementComponent, + ScopeSelectorModalComponent, + ListableNotificationObjectComponent, + AdvancedClaimedTaskActionSelectReviewerComponent, + AdvancedClaimedTaskActionRatingComponent, + EpersonGroupListComponent, + EpersonSearchBoxComponent, + GroupSearchBoxComponent + ]; diff --git a/src/app/dso-shared/dso-shared.module.ts b/src/app/dso-shared/dso-shared.module.ts index e5fc3ce149..937ecc167f 100644 --- a/src/app/dso-shared/dso-shared.module.ts +++ b/src/app/dso-shared/dso-shared.module.ts @@ -1,5 +1,4 @@ import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { DsoEditMetadataComponent } from './dso-edit-metadata/dso-edit-metadata.component'; import { MetadataFieldSelectorComponent } from './dso-edit-metadata/metadata-field-selector/metadata-field-selector.component'; import { DsoEditMetadataFieldValuesComponent } from './dso-edit-metadata/dso-edit-metadata-field-values/dso-edit-metadata-field-values.component'; @@ -10,7 +9,6 @@ import { ThemedDsoEditMetadataComponent } from './dso-edit-metadata/themed-dso-e @NgModule({ imports: [ - SharedModule, DsoEditMetadataComponent, ThemedDsoEditMetadataComponent, MetadataFieldSelectorComponent, diff --git a/src/app/entity-groups/journal-entities/journal-entities.module.ts b/src/app/entity-groups/journal-entities/journal-entities.module.ts index 77392fd1db..75f4a546a9 100644 --- a/src/app/entity-groups/journal-entities/journal-entities.module.ts +++ b/src/app/entity-groups/journal-entities/journal-entities.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../../shared/shared.module'; import { JournalComponent } from './item-pages/journal/journal.component'; import { JournalIssueComponent } from './item-pages/journal-issue/journal-issue.component'; import { JournalVolumeComponent } from './item-pages/journal-volume/journal-volume.component'; @@ -49,7 +48,6 @@ const ENTRY_COMPONENTS = [ imports: [ CommonModule, ItemSharedModule, - SharedModule, ResultsBackButtonModule, DsoPageModule, ...ENTRY_COMPONENTS diff --git a/src/app/entity-groups/research-entities/research-entities.module.ts b/src/app/entity-groups/research-entities/research-entities.module.ts index 0f8c6d0667..d93e2f9bc7 100644 --- a/src/app/entity-groups/research-entities/research-entities.module.ts +++ b/src/app/entity-groups/research-entities/research-entities.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { NgbTooltipModule } from '@ng-bootstrap/ng-bootstrap'; -import { SharedModule } from '../../shared/shared.module'; import { OrgUnitComponent } from './item-pages/org-unit/org-unit.component'; import { PersonComponent } from './item-pages/person/person.component'; import { ProjectComponent } from './item-pages/project/project.component'; @@ -72,7 +71,6 @@ const COMPONENTS = [ imports: [ CommonModule, ItemSharedModule, - SharedModule, NgbTooltipModule, ResultsBackButtonModule, DsoPageModule, diff --git a/src/app/forgot-password/forgot-password.module.ts b/src/app/forgot-password/forgot-password.module.ts index 23e03619ad..654f5a4bd7 100644 --- a/src/app/forgot-password/forgot-password.module.ts +++ b/src/app/forgot-password/forgot-password.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { ForgotEmailComponent } from './forgot-password-email/forgot-email.component'; import { ForgotPasswordRoutingModule } from './forgot-password-routing.module'; import { RegisterEmailFormModule } from '../register-email-form/register-email-form.module'; @@ -12,7 +11,6 @@ import { ThemedForgotEmailComponent } from './forgot-password-email/themed-forgo @NgModule({ imports: [ CommonModule, - SharedModule, ForgotPasswordRoutingModule, RegisterEmailFormModule, ProfilePageModule, diff --git a/src/app/health-page/health-page.module.ts b/src/app/health-page/health-page.module.ts index 5b27a0ab35..391d17f1ca 100644 --- a/src/app/health-page/health-page.module.ts +++ b/src/app/health-page/health-page.module.ts @@ -7,7 +7,6 @@ import { TranslateModule } from '@ngx-translate/core'; import { HealthPageRoutingModule } from './health-page.routing.module'; import { HealthPanelComponent } from './health-panel/health-panel.component'; import { HealthStatusComponent } from './health-panel/health-status/health-status.component'; -import { SharedModule } from '../shared/shared.module'; import { HealthPageComponent } from './health-page.component'; import { HealthComponentComponent } from './health-panel/health-component/health-component.component'; import { HealthInfoComponent } from './health-info/health-info.component'; @@ -19,7 +18,6 @@ import { HealthInfoComponentComponent } from './health-info/health-info-componen CommonModule, HealthPageRoutingModule, NgbModule, - SharedModule, TranslateModule, HealthPageComponent, HealthPanelComponent, diff --git a/src/app/home-page/home-page.module.ts b/src/app/home-page/home-page.module.ts index 1d9f6f9bc0..78c086772d 100644 --- a/src/app/home-page/home-page.module.ts +++ b/src/app/home-page/home-page.module.ts @@ -1,6 +1,5 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { HomeNewsComponent } from './home-news/home-news.component'; import { HomePageRoutingModule } from './home-page-routing.module'; @@ -27,7 +26,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule.withEntryComponents(), JournalEntitiesModule.withEntryComponents(), ResearchEntitiesModule.withEntryComponents(), HomePageRoutingModule, diff --git a/src/app/home-page/top-level-community-list/top-level-community-list.component.spec.ts b/src/app/home-page/top-level-community-list/top-level-community-list.component.spec.ts index 58f4159e1c..4150e6091b 100644 --- a/src/app/home-page/top-level-community-list/top-level-community-list.component.spec.ts +++ b/src/app/home-page/top-level-community-list/top-level-community-list.component.spec.ts @@ -11,7 +11,6 @@ import { TopLevelCommunityListComponent } from './top-level-community-list.compo import { Community } from '../../core/shared/community.model'; import { buildPaginatedList } from '../../core/data/paginated-list.model'; import { PageInfo } from '../../core/shared/page-info.model'; -import { SharedModule } from '../../shared/shared.module'; import { createSuccessfulRemoteDataObject$ } from '../../shared/remote-data.utils'; import { HostWindowService } from '../../shared/host-window.service'; import { HostWindowServiceStub } from '../../shared/testing/host-window-service.stub'; @@ -143,7 +142,6 @@ describe('TopLevelCommunityList Component', () => { TestBed.configureTestingModule({ imports: [ TranslateModule.forRoot(), - SharedModule, RouterTestingModule.withRoutes([]), NgbModule, NoopAnimationsModule, diff --git a/src/app/import-external-page/import-external-page.module.ts b/src/app/import-external-page/import-external-page.module.ts index c80d9de3b2..1378ee47f2 100644 --- a/src/app/import-external-page/import-external-page.module.ts +++ b/src/app/import-external-page/import-external-page.module.ts @@ -1,7 +1,6 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { ImportExternalRoutingModule } from './import-external-routing.module'; import { SubmissionModule } from '../submission/submission.module'; import { ImportExternalPageComponent } from './import-external-page.component'; @@ -11,7 +10,6 @@ import { ResearchEntitiesModule } from '../entity-groups/research-entities/resea @NgModule({ imports: [ CommonModule, - SharedModule.withEntryComponents(), ImportExternalRoutingModule, SubmissionModule, JournalEntitiesModule.withEntryComponents(), diff --git a/src/app/info/info.module.ts b/src/app/info/info.module.ts index 7c7a9c4647..d02334d40b 100644 --- a/src/app/info/info.module.ts +++ b/src/app/info/info.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { EndUserAgreementComponent } from './end-user-agreement/end-user-agreement.component'; import { InfoRoutingModule } from './info-routing.module'; import { EndUserAgreementContentComponent } from './end-user-agreement/end-user-agreement-content/end-user-agreement-content.component'; @@ -31,7 +30,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, InfoRoutingModule, ...DECLARATIONS ], diff --git a/src/app/item-page/edit-item-page/edit-item-page.module.ts b/src/app/item-page/edit-item-page/edit-item-page.module.ts index e33a0a0b2b..0245f617c7 100644 --- a/src/app/item-page/edit-item-page/edit-item-page.module.ts +++ b/src/app/item-page/edit-item-page/edit-item-page.module.ts @@ -3,7 +3,6 @@ import { CommonModule } from '@angular/common'; import { NgbTooltipModule, NgbModule } from '@ng-bootstrap/ng-bootstrap'; -import { SharedModule } from '../../shared/shared.module'; import { EditItemPageRoutingModule } from './edit-item-page.routing.module'; import { EditItemPageComponent } from './edit-item-page.component'; import { ItemStatusComponent } from './item-status/item-status.component'; @@ -53,7 +52,6 @@ import { @NgModule({ imports: [ CommonModule, - SharedModule, NgbTooltipModule, EditItemPageRoutingModule, SearchPageModule, diff --git a/src/app/item-page/edit-item-page/item-relationships/edit-relationship-list/edit-relationship-list.component.spec.ts b/src/app/item-page/edit-item-page/item-relationships/edit-relationship-list/edit-relationship-list.component.spec.ts index a574c3f690..6c8d1f1bde 100644 --- a/src/app/item-page/edit-item-page/item-relationships/edit-relationship-list/edit-relationship-list.component.spec.ts +++ b/src/app/item-page/edit-item-page/item-relationships/edit-relationship-list/edit-relationship-list.component.spec.ts @@ -11,7 +11,6 @@ import { RelationshipType } from '../../../../core/shared/item-relationships/rel import { Relationship } from '../../../../core/shared/item-relationships/relationship.model'; import { Item } from '../../../../core/shared/item.model'; import { SelectableListService } from '../../../../shared/object-list/selectable-list/selectable-list.service'; -import { SharedModule } from '../../../../shared/shared.module'; import { EditRelationshipListComponent } from './edit-relationship-list.component'; import { createSuccessfulRemoteDataObject$ } from '../../../../shared/remote-data.utils'; import { createPaginatedList } from '../../../../shared/testing/utils.test'; @@ -229,7 +228,7 @@ describe('EditRelationshipListComponent', () => { }; TestBed.configureTestingModule({ - imports: [SharedModule, TranslateModule.forRoot(), EditRelationshipListComponent], + imports: [TranslateModule.forRoot(), EditRelationshipListComponent], providers: [ provideMockStore({initialState}), { provide: ObjectUpdatesService, useValue: objectUpdatesService }, diff --git a/src/app/item-page/edit-item-page/item-relationships/item-relationships.component.spec.ts b/src/app/item-page/edit-item-page/item-relationships/item-relationships.component.spec.ts index f843b92df1..b3e41f2e36 100644 --- a/src/app/item-page/edit-item-page/item-relationships/item-relationships.component.spec.ts +++ b/src/app/item-page/edit-item-page/item-relationships/item-relationships.component.spec.ts @@ -19,7 +19,6 @@ import { Item } from '../../../core/shared/item.model'; import { NotificationType } from '../../../shared/notifications/models/notification-type'; import { INotification, Notification } from '../../../shared/notifications/models/notification.model'; import { NotificationsService } from '../../../shared/notifications/notifications.service'; -import { SharedModule } from '../../../shared/shared.module'; import { RouterStub } from '../../../shared/testing/router.stub'; import { ItemRelationshipsComponent } from './item-relationships.component'; import { createSuccessfulRemoteDataObject, createSuccessfulRemoteDataObject$ } from '../../../shared/remote-data.utils'; @@ -210,7 +209,7 @@ describe('ItemRelationshipsComponent', () => { scheduler = getTestScheduler(); TestBed.configureTestingModule({ - imports: [SharedModule, TranslateModule.forRoot(), ItemRelationshipsComponent], + imports: [TranslateModule.forRoot(), ItemRelationshipsComponent], providers: [ { provide: ThemeService, useValue: getMockThemeService() }, { provide: ItemDataService, useValue: itemService }, diff --git a/src/app/item-page/item-page.module.ts b/src/app/item-page/item-page.module.ts index 79a994f766..9d71021027 100644 --- a/src/app/item-page/item-page.module.ts +++ b/src/app/item-page/item-page.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { ItemPageComponent } from './simple/item-page.component'; import { ItemPageRoutingModule } from './item-page-routing.module'; @@ -108,7 +107,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule.withEntryComponents(), ItemPageRoutingModule, EditItemPageModule, ItemVersionsModule, diff --git a/src/app/item-page/item-shared.module.ts b/src/app/item-page/item-shared.module.ts index 10ea5f4171..5dc718b802 100644 --- a/src/app/item-page/item-shared.module.ts +++ b/src/app/item-page/item-shared.module.ts @@ -2,7 +2,6 @@ import { RelatedEntitiesSearchComponent } from './simple/related-entities/relate import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { SearchModule } from '../shared/search/search.module'; -import { SharedModule } from '../shared/shared.module'; import { TranslateModule } from '@ngx-translate/core'; import { DYNAMIC_FORM_CONTROL_MAP_FN } from '@ng-dynamic-forms/core'; import { dsDynamicFormControlMapFn } from '../shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component'; @@ -38,7 +37,6 @@ const COMPONENTS = [ imports: [ CommonModule, SearchModule, - SharedModule, TranslateModule, ...COMPONENTS ], diff --git a/src/app/item-page/simple/field-components/specific-field/abstract/item-page-abstract-field.component.spec.ts b/src/app/item-page/simple/field-components/specific-field/abstract/item-page-abstract-field.component.spec.ts index 035c7d1385..9d0d107e8b 100644 --- a/src/app/item-page/simple/field-components/specific-field/abstract/item-page-abstract-field.component.spec.ts +++ b/src/app/item-page/simple/field-components/specific-field/abstract/item-page-abstract-field.component.spec.ts @@ -3,7 +3,6 @@ import { ChangeDetectionStrategy, NO_ERRORS_SCHEMA } from '@angular/core'; import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { ItemPageAbstractFieldComponent } from './item-page-abstract-field.component'; import { TranslateLoaderMock } from '../../../../../shared/testing/translate-loader.mock'; -import { SharedModule } from '../../../../../shared/shared.module'; import { APP_CONFIG } from '../../../../../../config/app-config.interface'; import { environment } from '../../../../../../environments/environment'; import { By } from '@angular/platform-browser'; @@ -23,7 +22,6 @@ describe('ItemPageAbstractFieldComponent', () => { useClass: TranslateLoaderMock } }), - SharedModule, ItemPageAbstractFieldComponent ], providers: [ diff --git a/src/app/item-page/simple/field-components/specific-field/item-page-field.component.spec.ts b/src/app/item-page/simple/field-components/specific-field/item-page-field.component.spec.ts index e2706be0bd..6452405fcb 100644 --- a/src/app/item-page/simple/field-components/specific-field/item-page-field.component.spec.ts +++ b/src/app/item-page/simple/field-components/specific-field/item-page-field.component.spec.ts @@ -10,7 +10,6 @@ import { createSuccessfulRemoteDataObject$ } from '../../../../shared/remote-dat import { createPaginatedList } from '../../../../shared/testing/utils.test'; import { environment } from '../../../../../environments/environment'; import { MarkdownPipe } from '../../../../shared/utils/markdown.pipe'; -import { SharedModule } from '../../../../shared/shared.module'; import { APP_CONFIG } from '../../../../../config/app-config.interface'; import { By } from '@angular/platform-browser'; import { BrowseDefinitionDataService } from '../../../../core/browse/browse-definition-data.service'; @@ -47,7 +46,6 @@ describe('ItemPageFieldComponent', () => { useClass: TranslateLoaderMock } }), - SharedModule, ItemPageFieldComponent, MetadataValuesComponent ], providers: [ diff --git a/src/app/item-page/versions/item-versions.module.ts b/src/app/item-page/versions/item-versions.module.ts index a6a70a4fc6..fef871c2eb 100644 --- a/src/app/item-page/versions/item-versions.module.ts +++ b/src/app/item-page/versions/item-versions.module.ts @@ -7,7 +7,6 @@ */ import { NgModule } from '@angular/core'; -import { SharedModule } from '../../shared/shared.module'; import { ItemVersionsComponent } from './item-versions.component'; import { ItemVersionsNoticeComponent } from './notice/item-versions-notice.component'; @@ -18,7 +17,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ - SharedModule, ...DECLARATIONS ], exports: [ diff --git a/src/app/login-page/login-page.module.ts b/src/app/login-page/login-page.module.ts index 58f4ee6108..5532045258 100644 --- a/src/app/login-page/login-page.module.ts +++ b/src/app/login-page/login-page.module.ts @@ -1,6 +1,5 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { LoginPageComponent } from './login-page.component'; import { LoginPageRoutingModule } from './login-page-routing.module'; import { ThemedLoginPageComponent } from './themed-login-page.component'; @@ -9,7 +8,6 @@ import { ThemedLoginPageComponent } from './themed-login-page.component'; imports: [ LoginPageRoutingModule, CommonModule, - SharedModule, LoginPageComponent, ThemedLoginPageComponent ] diff --git a/src/app/logout-page/logout-page.module.ts b/src/app/logout-page/logout-page.module.ts index 289b06fa5c..f66f540554 100644 --- a/src/app/logout-page/logout-page.module.ts +++ b/src/app/logout-page/logout-page.module.ts @@ -1,6 +1,5 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { LogoutPageComponent } from './logout-page.component'; import { LogoutPageRoutingModule } from './logout-page-routing.module'; import { ThemedLogoutPageComponent } from './themed-logout-page.component'; @@ -9,7 +8,6 @@ import { ThemedLogoutPageComponent } from './themed-logout-page.component'; imports: [ LogoutPageRoutingModule, CommonModule, - SharedModule, LogoutPageComponent, ThemedLogoutPageComponent ] diff --git a/src/app/lookup-by-id/lookup-by-id.module.ts b/src/app/lookup-by-id/lookup-by-id.module.ts index bcc5f01677..2ea0258ae6 100644 --- a/src/app/lookup-by-id/lookup-by-id.module.ts +++ b/src/app/lookup-by-id/lookup-by-id.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { LookupRoutingModule } from './lookup-by-id-routing.module'; import { ObjectNotFoundComponent } from './objectnotfound/objectnotfound.component'; import { DsoRedirectService } from '../core/data/dso-redirect.service'; @@ -10,7 +9,6 @@ import { ThemedObjectNotFoundComponent } from './objectnotfound/themed-objectnot imports: [ LookupRoutingModule, CommonModule, - SharedModule, ObjectNotFoundComponent, ThemedObjectNotFoundComponent ], diff --git a/src/app/my-dspace-page/my-dspace-page.module.ts b/src/app/my-dspace-page/my-dspace-page.module.ts index 8049ec9266..5f9a49ff9b 100644 --- a/src/app/my-dspace-page/my-dspace-page.module.ts +++ b/src/app/my-dspace-page/my-dspace-page.module.ts @@ -1,7 +1,6 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { MyDspacePageRoutingModule } from './my-dspace-page-routing.module'; import { MyDSpacePageComponent } from './my-dspace-page.component'; @@ -28,7 +27,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, SearchModule, MyDspacePageRoutingModule, MyDspaceSearchModule.withEntryComponents(), diff --git a/src/app/my-dspace-page/my-dspace-search.module.ts b/src/app/my-dspace-page/my-dspace-search.module.ts index 115e0a4a53..a79dc3faae 100644 --- a/src/app/my-dspace-page/my-dspace-search.module.ts +++ b/src/app/my-dspace-page/my-dspace-search.module.ts @@ -1,7 +1,6 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { MyDspacePageRoutingModule } from './my-dspace-page-routing.module'; import { WorkspaceItemSearchResultListElementComponent } from '../shared/object-list/my-dspace-result-list-element/workspace-item-search-result/workspace-item-search-result-list-element.component'; @@ -56,7 +55,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, MyDspacePageRoutingModule, MyDSpaceActionsModule, ResearchEntitiesModule.withEntryComponents(), diff --git a/src/app/navbar/navbar.module.ts b/src/app/navbar/navbar.module.ts index ab3a553ec3..3c41b96d1f 100644 --- a/src/app/navbar/navbar.module.ts +++ b/src/app/navbar/navbar.module.ts @@ -9,7 +9,6 @@ import { ExpandableNavbarSectionComponent } from './expandable-navbar-section/ex import { ThemedExpandableNavbarSectionComponent } from './expandable-navbar-section/themed-expandable-navbar-section.component'; import { NavbarComponent } from './navbar.component'; import { MenuModule } from '../shared/menu/menu.module'; -import { SharedModule } from '../shared/shared.module'; import { FormsModule } from '@angular/forms'; import { ThemedNavbarComponent } from './themed-navbar.component'; @@ -27,7 +26,6 @@ const ENTRY_COMPONENTS = [ @NgModule({ imports: [ CommonModule, - SharedModule, MenuModule, FormsModule, EffectsModule.forFeature(effects), diff --git a/src/app/notifications/notifications.module.ts b/src/app/notifications/notifications.module.ts index 8f20e20717..484213c72d 100644 --- a/src/app/notifications/notifications.module.ts +++ b/src/app/notifications/notifications.module.ts @@ -4,7 +4,6 @@ import { Action, StoreConfig, StoreModule } from '@ngrx/store'; import { EffectsModule } from '@ngrx/effects'; import { CoreModule } from '../core/core.module'; -import { SharedModule } from '../shared/shared.module'; import { storeModuleConfig } from '../app.reducer'; import { QualityAssuranceTopicsComponent } from './qa/topics/quality-assurance-topics.component'; import { QualityAssuranceEventsComponent } from './qa/events/quality-assurance-events.component'; @@ -29,7 +28,6 @@ import { const MODULES = [ CommonModule, - SharedModule, SearchModule, CoreModule.forRoot(), StoreModule.forFeature('suggestionNotifications', suggestionNotificationsReducers, storeModuleConfig as StoreConfig), diff --git a/src/app/process-page/process-page-shared.module.ts b/src/app/process-page/process-page-shared.module.ts index 70eb8d0ecf..84e8f5c26c 100644 --- a/src/app/process-page/process-page-shared.module.ts +++ b/src/app/process-page/process-page-shared.module.ts @@ -1,5 +1,4 @@ import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { NewProcessComponent } from './new/new-process.component'; import { ScriptsSelectComponent } from './form/scripts-select/scripts-select.component'; import { ScriptHelpComponent } from './form/script-help/script-help.component'; @@ -19,7 +18,6 @@ import { ProcessFormComponent } from './form/process-form.component'; @NgModule({ imports: [ - SharedModule, NewProcessComponent, ScriptsSelectComponent, ScriptHelpComponent, diff --git a/src/app/process-page/process-page.module.ts b/src/app/process-page/process-page.module.ts index 2587813998..2a859eadda 100644 --- a/src/app/process-page/process-page.module.ts +++ b/src/app/process-page/process-page.module.ts @@ -1,12 +1,10 @@ import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { ProcessPageRoutingModule } from './process-page-routing.module'; import { ProcessPageSharedModule } from './process-page-shared.module'; @NgModule({ imports: [ ProcessPageRoutingModule, - SharedModule, ProcessPageSharedModule, ], declarations: [ diff --git a/src/app/profile-page/profile-page.module.ts b/src/app/profile-page/profile-page.module.ts index 4f61a3a4d1..000414e0ea 100644 --- a/src/app/profile-page/profile-page.module.ts +++ b/src/app/profile-page/profile-page.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { ProfilePageRoutingModule } from './profile-page-routing.module'; import { ProfilePageComponent } from './profile-page.component'; import { ProfilePageMetadataFormComponent } from './profile-page-metadata-form/profile-page-metadata-form.component'; @@ -18,7 +17,6 @@ import { ProfileClaimItemModalComponent } from './profile-claim-item-modal/profi imports: [ ProfilePageRoutingModule, CommonModule, - SharedModule, FormModule, UiSwitchModule, ProfilePageComponent, diff --git a/src/app/register-email-form/register-email-form.module.ts b/src/app/register-email-form/register-email-form.module.ts index 2cf7572c78..f1ce1a0e9b 100644 --- a/src/app/register-email-form/register-email-form.module.ts +++ b/src/app/register-email-form/register-email-form.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { RegisterEmailFormComponent } from './register-email-form.component'; import { ThemedRegisterEmailFormComponent } from './themed-registry-email-form.component'; @@ -12,7 +11,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, ...DECLARATIONS, ], providers: [], diff --git a/src/app/register-page/register-page.module.ts b/src/app/register-page/register-page.module.ts index ce29c7f8ae..40b6e01853 100644 --- a/src/app/register-page/register-page.module.ts +++ b/src/app/register-page/register-page.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { RegisterPageRoutingModule } from './register-page-routing.module'; import { RegisterEmailComponent } from './register-email/register-email.component'; import { CreateProfileComponent } from './create-profile/create-profile.component'; @@ -12,7 +11,6 @@ import { ThemedRegisterEmailComponent } from './register-email/themed-register-e @NgModule({ imports: [ CommonModule, - SharedModule, RegisterPageRoutingModule, RegisterEmailFormModule, ProfilePageModule, diff --git a/src/app/request-copy/request-copy.module.ts b/src/app/request-copy/request-copy.module.ts index bfc57d7c44..28b23fdb56 100644 --- a/src/app/request-copy/request-copy.module.ts +++ b/src/app/request-copy/request-copy.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { GrantDenyRequestCopyComponent } from './grant-deny-request-copy/grant-deny-request-copy.component'; import { RequestCopyRoutingModule } from './request-copy-routing.module'; import { DenyRequestCopyComponent } from './deny-request-copy/deny-request-copy.component'; @@ -13,7 +12,6 @@ import { ThemedGrantRequestCopyComponent } from './grant-request-copy/themed-gra @NgModule({ imports: [ CommonModule, - SharedModule, RequestCopyRoutingModule, GrantDenyRequestCopyComponent, DenyRequestCopyComponent, diff --git a/src/app/root.module.ts b/src/app/root.module.ts index 3d5fb651d2..3e83e94925 100644 --- a/src/app/root.module.ts +++ b/src/app/root.module.ts @@ -20,7 +20,6 @@ import { NotificationComponent } from './shared/notifications/notification/notif import { NotificationsBoardComponent } from './shared/notifications/notifications-board/notifications-board.component'; -import { SharedModule } from './shared/shared.module'; import { BreadcrumbsComponent } from './breadcrumbs/breadcrumbs.component'; import { ForbiddenComponent } from './forbidden/forbidden.component'; import { RootComponent } from './root/root.component'; @@ -47,7 +46,6 @@ import { SystemWideAlertModule } from './system-wide-alert/system-wide-alert.mod const IMPORTS = [ CommonModule, - SharedModule.withEntryComponents(), NavbarModule, SystemWideAlertModule, NgbModule, diff --git a/src/app/search-page/search-page.module.ts b/src/app/search-page/search-page.module.ts index 5e98640049..784d7eaaaa 100644 --- a/src/app/search-page/search-page.module.ts +++ b/src/app/search-page/search-page.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { SidebarService } from '../shared/sidebar/sidebar.service'; import { ConfigurationSearchPageGuard } from './configuration-search-page.guard'; import { StatisticsModule } from '../statistics/statistics.module'; @@ -21,7 +20,6 @@ const components = [ imports: [ CommonModule, SearchModule, - SharedModule.withEntryComponents(), StatisticsModule.forRoot(), JournalEntitiesModule.withEntryComponents(), ResearchEntitiesModule.withEntryComponents(), diff --git a/src/app/shared/access-control-form-container/access-control-form.module.ts b/src/app/shared/access-control-form-container/access-control-form.module.ts index c4b2745f9b..b0521b5caa 100644 --- a/src/app/shared/access-control-form-container/access-control-form.module.ts +++ b/src/app/shared/access-control-form-container/access-control-form.module.ts @@ -5,7 +5,6 @@ import {TranslateModule} from '@ngx-translate/core'; import {UiSwitchModule} from 'ngx-ui-switch'; import {AccessControlArrayFormComponent} from './access-control-array-form/access-control-array-form.component'; -import {SharedModule} from '../shared.module'; import { ItemAccessControlSelectBitstreamsModalComponent } from './item-access-control-select-bitstreams-modal/item-access-control-select-bitstreams-modal.component'; @@ -16,7 +15,6 @@ import {ToDatePipe} from './access-control-array-form/to-date.pipe'; @NgModule({ imports: [ CommonModule, - SharedModule, TranslateModule, UiSwitchModule, NgbDatepickerModule, diff --git a/src/app/shared/browse-by/browse-by.component.spec.ts b/src/app/shared/browse-by/browse-by.component.spec.ts index f4f684a360..34c4607850 100644 --- a/src/app/shared/browse-by/browse-by.component.spec.ts +++ b/src/app/shared/browse-by/browse-by.component.spec.ts @@ -44,7 +44,6 @@ import { ConfigurationProperty } from '../../core/shared/configuration-property. import { SearchConfigurationServiceStub } from '../testing/search-configuration-service.stub'; import { SearchConfigurationService } from '../../core/shared/search/search-configuration.service'; import { getMockThemeService } from '../mocks/theme-service.mock'; -import { SharedModule } from '../shared.module'; import { BrowseByRoutingModule } from '../../browse-by/browse-by-routing.module'; import { AccessControlRoutingModule } from '../../access-control/access-control-routing.module'; @@ -119,7 +118,6 @@ describe('BrowseByComponent', () => { BrowseByRoutingModule, AccessControlRoutingModule, CommonModule, - SharedModule, NgbModule, TranslateModule.forRoot({ loader: { diff --git a/src/app/shared/browse-by/shared-browse-by.module.ts b/src/app/shared/browse-by/shared-browse-by.module.ts index 219829d8bc..91dd6e3284 100644 --- a/src/app/shared/browse-by/shared-browse-by.module.ts +++ b/src/app/shared/browse-by/shared-browse-by.module.ts @@ -2,7 +2,6 @@ import { NgModule } from '@angular/core'; import { BrowseByComponent } from './browse-by.component'; import { ThemedBrowseByComponent } from './themed-browse-by.component'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared.module'; import { ResultsBackButtonModule } from '../results-back-button/results-back-button.module'; import { BrowseByRoutingModule } from '../../browse-by/browse-by-routing.module'; import { AccessControlRoutingModule } from '../../access-control/access-control-routing.module'; @@ -18,12 +17,10 @@ const DECLARATIONS = [ BrowseByRoutingModule, AccessControlRoutingModule, CommonModule, - SharedModule, ...DECLARATIONS, ], exports: [ ...DECLARATIONS, - SharedModule, ] }) export class SharedBrowseByModule { } diff --git a/src/app/shared/comcol/comcol-forms/create-comcol-page/create-comcol-page.component.spec.ts b/src/app/shared/comcol/comcol-forms/create-comcol-page/create-comcol-page.component.spec.ts index f4c05344fa..b11304e450 100644 --- a/src/app/shared/comcol/comcol-forms/create-comcol-page/create-comcol-page.component.spec.ts +++ b/src/app/shared/comcol/comcol-forms/create-comcol-page/create-comcol-page.component.spec.ts @@ -5,7 +5,6 @@ import { Router } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; import { of as observableOf } from 'rxjs'; import { Community } from '../../../../core/shared/community.model'; -import { SharedModule } from '../../../shared.module'; import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { NO_ERRORS_SCHEMA } from '@angular/core'; @@ -97,7 +96,7 @@ describe('CreateComColPageComponent', () => { beforeEach(waitForAsync(() => { initializeVars(); TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule], providers: [ { provide: ComColDataService, useValue: communityDataServiceStub }, { provide: CommunityDataService, useValue: communityDataServiceStub }, diff --git a/src/app/shared/comcol/comcol-forms/delete-comcol-page/delete-comcol-page.component.spec.ts b/src/app/shared/comcol/comcol-forms/delete-comcol-page/delete-comcol-page.component.spec.ts index 1040e31c57..e9c6e3e743 100644 --- a/src/app/shared/comcol/comcol-forms/delete-comcol-page/delete-comcol-page.component.spec.ts +++ b/src/app/shared/comcol/comcol-forms/delete-comcol-page/delete-comcol-page.component.spec.ts @@ -4,7 +4,6 @@ import { ActivatedRoute, Router } from '@angular/router'; import { TranslateModule, TranslateService } from '@ngx-translate/core'; import { of as observableOf } from 'rxjs'; import { Community } from '../../../../core/shared/community.model'; -import { SharedModule } from '../../../shared.module'; import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { NO_ERRORS_SCHEMA } from '@angular/core'; @@ -86,7 +85,7 @@ describe('DeleteComColPageComponent', () => { beforeEach(waitForAsync(() => { initializeVars(); TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule], providers: [ { provide: ComColDataService, useValue: dsoDataService }, { provide: Router, useValue: routerStub }, diff --git a/src/app/shared/comcol/comcol-forms/edit-comcol-page/comcol-metadata/comcol-metadata.component.spec.ts b/src/app/shared/comcol/comcol-forms/edit-comcol-page/comcol-metadata/comcol-metadata.component.spec.ts index ef69e82c8c..f5b82a207d 100644 --- a/src/app/shared/comcol/comcol-forms/edit-comcol-page/comcol-metadata/comcol-metadata.component.spec.ts +++ b/src/app/shared/comcol/comcol-forms/edit-comcol-page/comcol-metadata/comcol-metadata.component.spec.ts @@ -8,7 +8,6 @@ import { of as observableOf } from 'rxjs'; import { ComColDataService } from '../../../../../core/data/comcol-data.service'; import { Community } from '../../../../../core/shared/community.model'; import { NotificationsService } from '../../../../notifications/notifications.service'; -import { SharedModule } from '../../../../shared.module'; import { NotificationsServiceStub } from '../../../../testing/notifications-service.stub'; import { createFailedRemoteDataObject$, @@ -71,7 +70,7 @@ describe('ComColMetadataComponent', () => { beforeEach(waitForAsync(() => { initializeVars(); TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule], providers: [ { provide: ComColDataService, useValue: communityDataServiceStub }, { provide: Router, useValue: routerStub }, diff --git a/src/app/shared/comcol/comcol-forms/edit-comcol-page/edit-comcol-page.component.spec.ts b/src/app/shared/comcol/comcol-forms/edit-comcol-page/edit-comcol-page.component.spec.ts index d3d936c9f7..7f9cb467ff 100644 --- a/src/app/shared/comcol/comcol-forms/edit-comcol-page/edit-comcol-page.component.spec.ts +++ b/src/app/shared/comcol/comcol-forms/edit-comcol-page/edit-comcol-page.component.spec.ts @@ -3,7 +3,6 @@ import { ActivatedRoute, Router } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; import { of as observableOf } from 'rxjs'; import { Community } from '../../../../core/shared/community.model'; -import { SharedModule } from '../../../shared.module'; import { CommonModule } from '@angular/common'; import { RouterTestingModule } from '@angular/router/testing'; import { NO_ERRORS_SCHEMA } from '@angular/core'; @@ -62,7 +61,7 @@ describe('EditComColPageComponent', () => { beforeEach(waitForAsync(() => { initializeVars(); TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, CommonModule, RouterTestingModule], + imports: [TranslateModule.forRoot(), CommonModule, RouterTestingModule], providers: [ { provide: Router, useValue: routerStub }, { provide: ActivatedRoute, useValue: routeStub }, diff --git a/src/app/shared/comcol/comcol.module.ts b/src/app/shared/comcol/comcol.module.ts index 7fdd98b4ac..4ca212a651 100644 --- a/src/app/shared/comcol/comcol.module.ts +++ b/src/app/shared/comcol/comcol.module.ts @@ -13,7 +13,6 @@ import { DeleteComColPageComponent } from './comcol-forms/delete-comcol-page/del import { ComcolPageBrowseByComponent } from './comcol-page-browse-by/comcol-page-browse-by.component'; import { ThemedComcolPageBrowseByComponent } from './comcol-page-browse-by/themed-comcol-page-browse-by.component'; import { ComcolRoleComponent } from './comcol-forms/edit-comcol-page/comcol-role/comcol-role.component'; -import { SharedModule } from '../shared.module'; import { FormModule } from '../form/form.module'; import { UploadModule } from '../upload/upload.module'; @@ -36,7 +35,6 @@ const COMPONENTS = [ imports: [ CommonModule, FormModule, - SharedModule, UploadModule, ...COMPONENTS ], diff --git a/src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.spec.ts b/src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.spec.ts index 355e10b9a0..5e9069cb5c 100644 --- a/src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.spec.ts +++ b/src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.spec.ts @@ -43,7 +43,6 @@ import { DsDynamicFormControlContainerComponent, dsDynamicFormControlMapFn } from './ds-dynamic-form-control-container.component'; -import { SharedModule } from '../../../shared.module'; import { DynamicDsDatePickerModel } from './models/date-picker/date-picker.model'; import { DynamicRelationGroupModel } from './models/relation-group/dynamic-relation-group.model'; import { DynamicListCheckboxGroupModel } from './models/list/dynamic-list-checkbox-group.model'; @@ -211,7 +210,6 @@ describe('DsDynamicFormControlContainerComponent test suite', () => { ReactiveFormsModule, NgbModule, DynamicFormsCoreModule.forRoot(), - SharedModule, TranslateModule.forRoot(), NgxMaskModule.forRoot(), ], diff --git a/src/app/shared/form/form.module.ts b/src/app/shared/form/form.module.ts index 6ba1c938fe..d737815a32 100644 --- a/src/app/shared/form/form.module.ts +++ b/src/app/shared/form/form.module.ts @@ -18,7 +18,6 @@ import { DsDatePickerInlineComponent } from './builder/ds-dynamic-form-ui/models import { DsDynamicLookupRelationSearchTabComponent } from './builder/ds-dynamic-form-ui/relation-lookup-modal/search-tab/dynamic-lookup-relation-search-tab.component'; import { DsDynamicLookupRelationSelectionTabComponent } from './builder/ds-dynamic-form-ui/relation-lookup-modal/selection-tab/dynamic-lookup-relation-selection-tab.component'; import { DsDynamicLookupRelationExternalSourceTabComponent } from './builder/ds-dynamic-form-ui/relation-lookup-modal/external-source-tab/dynamic-lookup-relation-external-source-tab.component'; -import { SharedModule } from '../shared.module'; import { TranslateModule } from '@ngx-translate/core'; import { SearchModule } from '../search/search.module'; import { DYNAMIC_FORM_CONTROL_MAP_FN, DynamicFormLayoutService, DynamicFormsCoreModule, DynamicFormService, DynamicFormValidationService } from '@ng-dynamic-forms/core'; @@ -85,7 +84,6 @@ const DIRECTIVES = [ DynamicFormsCoreModule, DynamicFormsNGBootstrapUIModule, SearchModule, - SharedModule, TranslateModule, SortablejsModule, NgxMaskModule.forRoot(), diff --git a/src/app/shared/log-in/container/log-in-container.component.spec.ts b/src/app/shared/log-in/container/log-in-container.component.spec.ts index bd4e461709..248989d3b4 100644 --- a/src/app/shared/log-in/container/log-in-container.component.spec.ts +++ b/src/app/shared/log-in/container/log-in-container.component.spec.ts @@ -7,7 +7,6 @@ import { TranslateModule } from '@ngx-translate/core'; import { LogInContainerComponent } from './log-in-container.component'; import { authReducer } from '../../../core/auth/auth.reducer'; -import { SharedModule } from '../../shared.module'; import { AuthService } from '../../../core/auth/auth.service'; import { AuthMethod } from '../../../core/auth/models/auth.method'; import { AuthServiceStub } from '../../testing/auth-service.stub'; @@ -38,7 +37,6 @@ describe('LogInContainerComponent', () => { FormsModule, ReactiveFormsModule, StoreModule.forRoot(authReducer), - SharedModule, TranslateModule.forRoot(), RouterTestingModule, TestComponent @@ -116,7 +114,6 @@ describe('LogInContainerComponent', () => { standalone: true, imports: [FormsModule, ReactiveFormsModule, - SharedModule, RouterTestingModule] }) class TestComponent { diff --git a/src/app/shared/log-in/log-in.component.spec.ts b/src/app/shared/log-in/log-in.component.spec.ts index 72b4a6a933..0bb9847ae2 100644 --- a/src/app/shared/log-in/log-in.component.spec.ts +++ b/src/app/shared/log-in/log-in.component.spec.ts @@ -10,7 +10,6 @@ import { TranslateModule } from '@ngx-translate/core'; import { AuthService } from '../../core/auth/auth.service'; import { authMethodsMock, AuthServiceStub } from '../testing/auth-service.stub'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { SharedModule } from '../shared.module'; import { NativeWindowMockFactory } from '../mocks/mock-native-window-ref'; import { ActivatedRouteStub } from '../testing/active-router.stub'; import { ActivatedRoute } from '@angular/router'; @@ -63,7 +62,6 @@ describe('LogInComponent', () => { } }), RouterTestingModule, - SharedModule, TranslateModule.forRoot(), TestComponent ], @@ -138,8 +136,7 @@ describe('LogInComponent', () => { standalone: true, imports: [FormsModule, ReactiveFormsModule, - RouterTestingModule, - SharedModule] + RouterTestingModule] }) class TestComponent { diff --git a/src/app/shared/mydspace-actions/mydspace-actions.module.ts b/src/app/shared/mydspace-actions/mydspace-actions.module.ts index 0c56e7f75e..d4f7481c77 100644 --- a/src/app/shared/mydspace-actions/mydspace-actions.module.ts +++ b/src/app/shared/mydspace-actions/mydspace-actions.module.ts @@ -7,7 +7,6 @@ */ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared.module'; import { ClaimedTaskActionsApproveComponent } from './claimed-task/approve/claimed-task-actions-approve.component'; import { ClaimedTaskActionsRejectComponent } from './claimed-task/reject/claimed-task-actions-reject.component'; import { ClaimedTaskActionsReturnToPoolComponent } from './claimed-task/return-to-pool/claimed-task-actions-return-to-pool.component'; @@ -42,7 +41,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, ...DECLARATIONS ], providers: [ diff --git a/src/app/shared/object-list/bitstream-list-item/bitstream-list-item.component.spec.ts b/src/app/shared/object-list/bitstream-list-item/bitstream-list-item.component.spec.ts index f6f81c9d53..78606d2d3f 100644 --- a/src/app/shared/object-list/bitstream-list-item/bitstream-list-item.component.spec.ts +++ b/src/app/shared/object-list/bitstream-list-item/bitstream-list-item.component.spec.ts @@ -2,7 +2,6 @@ import {CommonModule} from '@angular/common'; import {ComponentFixture, TestBed} from '@angular/core/testing'; import {RouterTestingModule} from '@angular/router/testing'; import {TranslateModule} from '@ngx-translate/core'; -import {SharedModule} from '../../shared.module'; import {BitstreamListItemComponent} from './bitstream-list-item.component'; import {DSONameService} from '../../../core/breadcrumbs/dso-name.service'; @@ -14,7 +13,7 @@ describe('BitstreamListItemComponent', () => { beforeEach(async () => { await TestBed.configureTestingModule({ - imports: [CommonModule, SharedModule, TranslateModule, RouterTestingModule, BitstreamListItemComponent], + imports: [CommonModule, TranslateModule, RouterTestingModule, BitstreamListItemComponent], providers: [{ provide: DSONameService, useValue: new DSONameServiceMock() }] }) .compileComponents(); diff --git a/src/app/shared/object-select/collection-select/collection-select.component.spec.ts b/src/app/shared/object-select/collection-select/collection-select.component.spec.ts index c2ac0a12fa..b71b0c7ad1 100644 --- a/src/app/shared/object-select/collection-select/collection-select.component.spec.ts +++ b/src/app/shared/object-select/collection-select/collection-select.component.spec.ts @@ -2,7 +2,6 @@ import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing'; import { RouterTestingModule } from '@angular/router/testing'; import { PaginationComponentOptions } from '../../pagination/pagination-component-options.model'; import { TranslateModule } from '@ngx-translate/core'; -import { SharedModule } from '../../shared.module'; import { ObjectSelectServiceStub } from '../../testing/object-select-service.stub'; import { ObjectSelectService } from '../object-select.service'; import { HostWindowService } from '../../host-window.service'; @@ -72,7 +71,7 @@ describe('CollectionSelectComponent', () => { const paginationService = new PaginationServiceStub(); beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, RouterTestingModule.withRoutes([])], + imports: [TranslateModule.forRoot(), RouterTestingModule.withRoutes([])], providers: [ { provide: ObjectSelectService, useValue: new ObjectSelectServiceStub([mockCollectionList[1].id]) }, { provide: HostWindowService, useValue: new HostWindowServiceStub(0) }, diff --git a/src/app/shared/object-select/item-select/item-select.component.spec.ts b/src/app/shared/object-select/item-select/item-select.component.spec.ts index 05c703c61a..d56cba0e33 100644 --- a/src/app/shared/object-select/item-select/item-select.component.spec.ts +++ b/src/app/shared/object-select/item-select/item-select.component.spec.ts @@ -4,7 +4,6 @@ import { RouterTestingModule } from '@angular/router/testing'; import { Item } from '../../../core/shared/item.model'; import { PaginationComponentOptions } from '../../pagination/pagination-component-options.model'; import { TranslateModule } from '@ngx-translate/core'; -import { SharedModule } from '../../shared.module'; import { ObjectSelectServiceStub } from '../../testing/object-select-service.stub'; import { ObjectSelectService } from '../object-select.service'; import { HostWindowService } from '../../host-window.service'; @@ -97,7 +96,7 @@ describe('ItemSelectComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot(), SharedModule, RouterTestingModule.withRoutes([])], + imports: [TranslateModule.forRoot(), RouterTestingModule.withRoutes([])], providers: [ { provide: ObjectSelectService, useValue: new ObjectSelectServiceStub([mockItemList[1].id]) }, { provide: HostWindowService, useValue: new HostWindowServiceStub(0) }, diff --git a/src/app/shared/resource-policies/resource-policies.module.ts b/src/app/shared/resource-policies/resource-policies.module.ts index c58d570820..d91e05d3d2 100644 --- a/src/app/shared/resource-policies/resource-policies.module.ts +++ b/src/app/shared/resource-policies/resource-policies.module.ts @@ -11,7 +11,6 @@ import { FormModule } from '../form/form.module'; import { ResourcePolicyResolver } from './resolvers/resource-policy.resolver'; import { ResourcePolicyTargetResolver } from './resolvers/resource-policy-target.resolver'; import { NgbModule } from '@ng-bootstrap/ng-bootstrap'; -import { SharedModule } from '../shared.module'; import { ResourcePolicyEntryComponent } from './entry/resource-policy-entry.component'; const COMPONENTS = [ @@ -33,7 +32,6 @@ const PROVIDERS = [ CommonModule, FormModule, TranslateModule, - SharedModule, ...COMPONENTS ], providers: [ diff --git a/src/app/shared/search/search.module.ts b/src/app/shared/search/search.module.ts index 4b41f71829..61690bc8b9 100644 --- a/src/app/shared/search/search.module.ts +++ b/src/app/shared/search/search.module.ts @@ -25,7 +25,6 @@ import { FacetValues } from './models/facet-values.model'; import { SearchResult } from './models/search-result.model'; import { MissingTranslationHandler, TranslateModule } from '@ngx-translate/core'; import { MissingTranslationHelper } from '../translate/missing-translation.helper'; -import { SharedModule } from '../shared.module'; import { SearchResultsComponent } from './search-results/search-results.component'; import { SearchComponent } from './search.component'; import { ThemedSearchComponent } from './themed-search.component'; @@ -93,7 +92,6 @@ export const MODELS = [ missingTranslationHandler: { provide: MissingTranslationHandler, useClass: MissingTranslationHelper }, useDefaultLang: true }), - SharedModule.withEntryComponents(), NouisliderModule, ...COMPONENTS ], diff --git a/src/app/shared/shared.module.ts b/src/app/shared/shared.module.ts deleted file mode 100644 index f346437791..0000000000 --- a/src/app/shared/shared.module.ts +++ /dev/null @@ -1,534 +0,0 @@ -import { NgModule } from '@angular/core'; -import { CommonModule } from '@angular/common'; -import { RouterModule } from '@angular/router'; -import { FormsModule, ReactiveFormsModule } from '@angular/forms'; -import { DragDropModule } from '@angular/cdk/drag-drop'; -import { - NgbDropdownModule, - NgbNavModule, - NgbPaginationModule, - NgbTooltipModule, - NgbTypeaheadModule, -} from '@ng-bootstrap/ng-bootstrap'; -import { MissingTranslationHandler, TranslateModule } from '@ngx-translate/core'; -import { InfiniteScrollModule } from 'ngx-infinite-scroll'; -import { ConfirmationModalComponent } from './confirmation-modal/confirmation-modal.component'; -import { - ExportMetadataSelectorComponent -} from './dso-selector/modal-wrappers/export-metadata-selector/export-metadata-selector.component'; -import { - ExportBatchSelectorComponent -} from './dso-selector/modal-wrappers/export-batch-selector/export-batch-selector.component'; -import { - ImportBatchSelectorComponent -} from './dso-selector/modal-wrappers/import-batch-selector/import-batch-selector.component'; -import { ItemListElementComponent } from './object-list/item-list-element/item-types/item/item-list-element.component'; -import { EnumKeysPipe } from './utils/enum-keys-pipe'; -import { FileSizePipe } from './utils/file-size-pipe'; -import { MetadataFieldValidator } from './utils/metadatafield-validator.directive'; -import { SafeUrlPipe } from './utils/safe-url-pipe'; -import { ConsolePipe } from './utils/console.pipe'; -import { - CollectionListElementComponent -} from './object-list/collection-list-element/collection-list-element.component'; -import { CommunityListElementComponent } from './object-list/community-list-element/community-list-element.component'; -import { - SearchResultListElementComponent -} from './object-list/search-result-list-element/search-result-list-element.component'; -import { ObjectListComponent } from './object-list/object-list.component'; -import { ThemedObjectListComponent } from './object-list/themed-object-list.component'; -import { - CollectionGridElementComponent -} from './object-grid/collection-grid-element/collection-grid-element.component'; -import { CommunityGridElementComponent } from './object-grid/community-grid-element/community-grid-element.component'; -import { - AbstractListableElementComponent -} from './object-collection/shared/object-collection-element/abstract-listable-element.component'; -import { ObjectGridComponent } from './object-grid/object-grid.component'; -import { ObjectCollectionComponent } from './object-collection/object-collection.component'; -import { ErrorComponent } from './error/error.component'; -import { LoadingComponent } from './loading/loading.component'; -import { PaginationComponent } from './pagination/pagination.component'; -import { ThumbnailComponent } from '../thumbnail/thumbnail.component'; -import { ThemedThumbnailComponent } from '../thumbnail/themed-thumbnail.component'; -import { SearchFormComponent } from './search-form/search-form.component'; -import { ThemedSearchFormComponent } from './search-form/themed-search-form.component'; -import { - SearchResultGridElementComponent -} from './object-grid/search-result-grid-element/search-result-grid-element.component'; -import { ViewModeSwitchComponent } from './view-mode-switch/view-mode-switch.component'; -import { VarDirective } from './utils/var.directive'; -import { AuthNavMenuComponent } from './auth-nav-menu/auth-nav-menu.component'; -import { ThemedAuthNavMenuComponent } from './auth-nav-menu/themed-auth-nav-menu.component'; -import { LogOutComponent } from './log-out/log-out.component'; -import { DragClickDirective } from './utils/drag-click.directive'; -import { TruncatePipe } from './utils/truncate.pipe'; -import { TruncatableComponent } from './truncatable/truncatable.component'; -import { TruncatableService } from './truncatable/truncatable.service'; -import { TruncatablePartComponent } from './truncatable/truncatable-part/truncatable-part.component'; -import { MockAdminGuard } from './mocks/admin-guard.service.mock'; -import { AlertComponent } from './alert/alert.component'; -import { - SearchResultDetailElementComponent -} from './object-detail/my-dspace-result-detail-element/search-result-detail-element.component'; -import { ObjectDetailComponent } from './object-detail/object-detail.component'; -import { ObjNgFor } from './utils/object-ngfor.pipe'; -import { - BrowseEntryListElementComponent -} from './object-list/browse-entry-list-element/browse-entry-list-element.component'; -import { DebounceDirective } from './utils/debounce.directive'; -import { ClickOutsideDirective } from './utils/click-outside.directive'; -import { EmphasizePipe } from './utils/emphasize.pipe'; -import { InputSuggestionsComponent } from './input-suggestions/input-suggestions.component'; -import { CapitalizePipe } from './utils/capitalize.pipe'; -import { ObjectKeysPipe } from './utils/object-keys-pipe'; -import { LangSwitchComponent } from './lang-switch/lang-switch.component'; -import { - PlainTextMetadataListElementComponent -} from './object-list/metadata-representation-list-element/plain-text/plain-text-metadata-list-element.component'; -import { - BrowseLinkMetadataListElementComponent -} from './object-list/metadata-representation-list-element/browse-link/browse-link-metadata-list-element.component'; -import { - ItemMetadataListElementComponent -} from './object-list/metadata-representation-list-element/item/item-metadata-list-element.component'; -import { - MetadataRepresentationListElementComponent -} from './object-list/metadata-representation-list-element/metadata-representation-list-element.component'; -import { ObjectValuesPipe } from './utils/object-values-pipe'; -import { InListValidator } from './utils/in-list-validator.directive'; -import { AutoFocusDirective } from './utils/auto-focus.directive'; -import { StartsWithDateComponent } from './starts-with/date/starts-with-date.component'; -import { StartsWithTextComponent } from './starts-with/text/starts-with-text.component'; -import { DSOSelectorComponent } from './dso-selector/dso-selector/dso-selector.component'; -import { - CreateCommunityParentSelectorComponent -} from './dso-selector/modal-wrappers/create-community-parent-selector/create-community-parent-selector.component'; -import { - ThemedCreateCommunityParentSelectorComponent -} from './dso-selector/modal-wrappers/create-community-parent-selector/themed-create-community-parent-selector.component'; -import { - CreateItemParentSelectorComponent -} from './dso-selector/modal-wrappers/create-item-parent-selector/create-item-parent-selector.component'; -import { - ThemedCreateItemParentSelectorComponent -} from './dso-selector/modal-wrappers/create-item-parent-selector/themed-create-item-parent-selector.component'; -import { - CreateCollectionParentSelectorComponent -} from './dso-selector/modal-wrappers/create-collection-parent-selector/create-collection-parent-selector.component'; -import { - ThemedCreateCollectionParentSelectorComponent -} from './dso-selector/modal-wrappers/create-collection-parent-selector/themed-create-collection-parent-selector.component'; -import { - CommunitySearchResultListElementComponent -} from './object-list/search-result-list-element/community-search-result/community-search-result-list-element.component'; -import { - CollectionSearchResultListElementComponent -} from './object-list/search-result-list-element/collection-search-result/collection-search-result-list-element.component'; -import { - EditItemSelectorComponent -} from './dso-selector/modal-wrappers/edit-item-selector/edit-item-selector.component'; -import { - ThemedEditItemSelectorComponent -} from './dso-selector/modal-wrappers/edit-item-selector/themed-edit-item-selector.component'; -import { - EditCommunitySelectorComponent -} from './dso-selector/modal-wrappers/edit-community-selector/edit-community-selector.component'; -import { - ThemedEditCommunitySelectorComponent -} from './dso-selector/modal-wrappers/edit-community-selector/themed-edit-community-selector.component'; -import { - EditCollectionSelectorComponent -} from './dso-selector/modal-wrappers/edit-collection-selector/edit-collection-selector.component'; -import { - ThemedEditCollectionSelectorComponent -} from './dso-selector/modal-wrappers/edit-collection-selector/themed-edit-collection-selector.component'; -import { RoleDirective } from './roles/role.directive'; -import { UserMenuComponent } from './auth-nav-menu/user-menu/user-menu.component'; -import { - CollectionSearchResultGridElementComponent -} from './object-grid/search-result-grid-element/collection-search-result/collection-search-result-grid-element.component'; -import { - CommunitySearchResultGridElementComponent -} from './object-grid/search-result-grid-element/community-search-result/community-search-result-grid-element.component'; -import { PageSizeSelectorComponent } from './page-size-selector/page-size-selector.component'; -import { AbstractTrackableComponent } from './trackable/abstract-trackable.component'; -import { - ComcolMetadataComponent -} from './comcol/comcol-forms/edit-comcol-page/comcol-metadata/comcol-metadata.component'; -import { ItemSelectComponent } from './object-select/item-select/item-select.component'; -import { CollectionSelectComponent } from './object-select/collection-select/collection-select.component'; -import { - FilterInputSuggestionsComponent -} from './input-suggestions/filter-suggestions/filter-input-suggestions.component'; -import { - DsoInputSuggestionsComponent -} from './input-suggestions/dso-input-suggestions/dso-input-suggestions.component'; -import { ItemGridElementComponent } from './object-grid/item-grid-element/item-types/item/item-grid-element.component'; -import { TypeBadgeComponent } from './object-collection/shared/badges/type-badge/type-badge.component'; -import { AccessStatusBadgeComponent } from './object-collection/shared/badges/access-status-badge/access-status-badge.component'; -import { - MetadataRepresentationLoaderComponent -} from './metadata-representation/metadata-representation-loader.component'; -import { MetadataRepresentationDirective } from './metadata-representation/metadata-representation.directive'; -import { - ListableObjectComponentLoaderComponent -} from './object-collection/shared/listable-object/listable-object-component-loader.component'; -import { - ItemSearchResultListElementComponent -} from './object-list/search-result-list-element/item-search-result/item-types/item/item-search-result-list-element.component'; -import { ListableObjectDirective } from './object-collection/shared/listable-object/listable-object.directive'; -import { - ItemMetadataRepresentationListElementComponent -} from './object-list/metadata-representation-list-element/item/item-metadata-representation-list-element.component'; -import { PageWithSidebarComponent } from './sidebar/page-with-sidebar.component'; -import { SidebarDropdownComponent } from './sidebar/sidebar-dropdown.component'; -import { - SelectableListItemControlComponent -} from './object-collection/shared/selectable-list-item-control/selectable-list-item-control.component'; -import { - ImportableListItemControlComponent -} from './object-collection/shared/importable-list-item-control/importable-list-item-control.component'; -import { LogInContainerComponent } from './log-in/container/log-in-container.component'; -import { LogInPasswordComponent } from './log-in/methods/password/log-in-password.component'; -import { LogInComponent } from './log-in/log-in.component'; -import { ThemedLogInComponent } from './log-in/themed-log-in.component'; -import { MissingTranslationHelper } from './translate/missing-translation.helper'; -import { FileValidator } from './utils/require-file.validator'; -import { FileValueAccessorDirective } from './utils/file-value-accessor.directive'; -import { - ModifyItemOverviewComponent -} from '../item-page/edit-item-page/modify-item-overview/modify-item-overview.component'; -import { ClaimedTaskActionsDirective } from './mydspace-actions/claimed-task/switcher/claimed-task-actions.directive'; -import { ImpersonateNavbarComponent } from './impersonate-navbar/impersonate-navbar.component'; -import { NgForTrackByIdDirective } from './ng-for-track-by-id.directive'; -import { FileDownloadLinkComponent } from './file-download-link/file-download-link.component'; -import { ThemedFileDownloadLinkComponent } from './file-download-link/themed-file-download-link.component'; -import { CollectionDropdownComponent } from './collection-dropdown/collection-dropdown.component'; -import { EntityDropdownComponent } from './entity-dropdown/entity-dropdown.component'; -import { CurationFormComponent } from '../curation-form/curation-form.component'; -import { - PublicationSidebarSearchListElementComponent -} from './object-list/sidebar-search-list-element/item-types/publication/publication-sidebar-search-list-element.component'; -import { - SidebarSearchListElementComponent -} from './object-list/sidebar-search-list-element/sidebar-search-list-element.component'; -import { - CollectionSidebarSearchListElementComponent -} from './object-list/sidebar-search-list-element/collection/collection-sidebar-search-list-element.component'; -import { - CommunitySidebarSearchListElementComponent -} from './object-list/sidebar-search-list-element/community/community-sidebar-search-list-element.component'; -import { - BundleListElementComponent -} from './object-list/bundle-list-element/bundle-list-element.component'; -import { - AuthorizedCollectionSelectorComponent -} from './dso-selector/dso-selector/authorized-collection-selector/authorized-collection-selector.component'; -import { HoverClassDirective } from './hover-class.directive'; -import { - ValidationSuggestionsComponent -} from './input-suggestions/validation-suggestions/validation-suggestions.component'; -import { - ItemSearchResultGridElementComponent -} from './object-grid/search-result-grid-element/item-search-result/item/item-search-result-grid-element.component'; -import { SearchNavbarComponent } from '../search-navbar/search-navbar.component'; -import { ThemedSearchNavbarComponent } from '../search-navbar/themed-search-navbar.component'; -import { ScopeSelectorModalComponent } from './search-form/scope-selector-modal/scope-selector-modal.component'; -import { DsSelectComponent } from './ds-select/ds-select.component'; -import { ContextHelpDirective } from './context-help.directive'; -import { ContextHelpWrapperComponent } from './context-help-wrapper/context-help-wrapper.component'; -import { RSSComponent } from './rss-feed/rss.component'; -import { BrowserOnlyPipe } from './utils/browser-only.pipe'; -import { ThemedLoadingComponent } from './loading/themed-loading.component'; -import { SearchExportCsvComponent } from './search/search-export-csv/search-export-csv.component'; -import { - ItemPageTitleFieldComponent -} from '../item-page/simple/field-components/specific-field/title/item-page-title-field.component'; -import { MarkdownPipe } from './utils/markdown.pipe'; -import { GoogleRecaptchaModule } from '../core/google-recaptcha/google-recaptcha.module'; -import { MenuModule } from './menu/menu.module'; -import { - ListableNotificationObjectComponent -} from './object-list/listable-notification-object/listable-notification-object.component'; -import { ThemedCollectionDropdownComponent } from './collection-dropdown/themed-collection-dropdown.component'; -import { MetadataFieldWrapperComponent } from './metadata-field-wrapper/metadata-field-wrapper.component'; - -import { StatusBadgeComponent } from './object-collection/shared/badges/status-badge/status-badge.component'; -import { BadgesComponent } from './object-collection/shared/badges/badges.component'; -import { ThemedBadgesComponent } from './object-collection/shared/badges/themed-badges.component'; -import { ThemedStatusBadgeComponent } from './object-collection/shared/badges/status-badge/themed-status-badge.component'; -import { ThemedTypeBadgeComponent } from './object-collection/shared/badges/type-badge/themed-type-badge.component'; -import { ThemedMyDSpaceStatusBadgeComponent } from './object-collection/shared/badges/my-dspace-status-badge/themed-my-dspace-status-badge.component'; -import { ThemedAccessStatusBadgeComponent } from './object-collection/shared/badges/access-status-badge/themed-access-status-badge.component'; -import { MyDSpaceStatusBadgeComponent } from './object-collection/shared/badges/my-dspace-status-badge/my-dspace-status-badge.component'; - -import { ShortNumberPipe } from './utils/short-number.pipe'; -import { - LogInExternalProviderComponent -} from './log-in/methods/log-in-external-provider/log-in-external-provider.component'; -import { - AdvancedClaimedTaskActionSelectReviewerComponent -} from './mydspace-actions/claimed-task/select-reviewer/advanced-claimed-task-action-select-reviewer.component'; -import { - AdvancedClaimedTaskActionRatingComponent -} from './mydspace-actions/claimed-task/rating/advanced-claimed-task-action-rating.component'; -import { ClaimedTaskActionsDeclineTaskComponent } from './mydspace-actions/claimed-task/decline-task/claimed-task-actions-decline-task.component'; -import { EpersonGroupListComponent } from './eperson-group-list/eperson-group-list.component'; -import { EpersonSearchBoxComponent } from './eperson-group-list/eperson-search-box/eperson-search-box.component'; -import { GroupSearchBoxComponent } from './eperson-group-list/group-search-box/group-search-box.component'; -import { - ThemedItemPageTitleFieldComponent -} from '../item-page/simple/field-components/specific-field/title/themed-item-page-field.component'; -import { BitstreamListItemComponent } from './object-list/bitstream-list-item/bitstream-list-item.component'; -import { NgxPaginationModule } from 'ngx-pagination'; -import { ThemedUserMenuComponent } from './auth-nav-menu/user-menu/themed-user-menu.component'; -import { ThemedLangSwitchComponent } from './lang-switch/themed-lang-switch.component'; - -const MODULES = [ - CommonModule, - FormsModule, - InfiniteScrollModule, - NgbNavModule, - NgbTypeaheadModule, - NgbPaginationModule, - NgbDropdownModule, - NgbTooltipModule, - ReactiveFormsModule, - RouterModule, - DragDropModule, - GoogleRecaptchaModule, - MenuModule, - NgxPaginationModule -]; - -const ROOT_MODULES = [ - TranslateModule.forChild({ - missingTranslationHandler: { provide: MissingTranslationHandler, useClass: MissingTranslationHelper }, - useDefaultLang: true - }) -]; - -const PIPES = [ - // put shared pipes here - EnumKeysPipe, - FileSizePipe, - SafeUrlPipe, - TruncatePipe, - EmphasizePipe, - CapitalizePipe, - ObjectKeysPipe, - ObjectValuesPipe, - ConsolePipe, - ObjNgFor, - BrowserOnlyPipe, - MarkdownPipe, - ShortNumberPipe -]; - -const COMPONENTS = [ - // put shared components here - AlertComponent, - AuthNavMenuComponent, - ThemedAuthNavMenuComponent, - UserMenuComponent, - ThemedUserMenuComponent, - DsSelectComponent, - ErrorComponent, - LangSwitchComponent, - ThemedLangSwitchComponent, - LoadingComponent, - ThemedLoadingComponent, - LogInComponent, - ThemedLogInComponent, - LogOutComponent, - ObjectListComponent, - ThemedObjectListComponent, - ObjectDetailComponent, - ObjectGridComponent, - AbstractListableElementComponent, - ObjectCollectionComponent, - PaginationComponent, - RSSComponent, - SearchFormComponent, - ThemedSearchFormComponent, - PageWithSidebarComponent, - SidebarDropdownComponent, - ThumbnailComponent, - ThemedThumbnailComponent, - MyDSpaceStatusBadgeComponent, - ThemedMyDSpaceStatusBadgeComponent, - ViewModeSwitchComponent, - TruncatableComponent, - TruncatablePartComponent, - InputSuggestionsComponent, - FilterInputSuggestionsComponent, - ValidationSuggestionsComponent, - DsoInputSuggestionsComponent, - DSOSelectorComponent, - SearchExportCsvComponent, - PageSizeSelectorComponent, - ListableObjectComponentLoaderComponent, - AbstractTrackableComponent, - ComcolMetadataComponent, - TypeBadgeComponent, - AccessStatusBadgeComponent, - ThemedAccessStatusBadgeComponent, - ThemedTypeBadgeComponent, - StatusBadgeComponent, - ThemedStatusBadgeComponent, - BadgesComponent, - ThemedBadgesComponent, - - ItemSelectComponent, - CollectionSelectComponent, - MetadataRepresentationLoaderComponent, - SelectableListItemControlComponent, - ImportableListItemControlComponent, - LogInContainerComponent, - ModifyItemOverviewComponent, - ImpersonateNavbarComponent, - EntityDropdownComponent, - ExportMetadataSelectorComponent, - ImportBatchSelectorComponent, - ExportBatchSelectorComponent, - ConfirmationModalComponent, - AuthorizedCollectionSelectorComponent, - SearchNavbarComponent, - ItemPageTitleFieldComponent, - ThemedSearchNavbarComponent, - ListableNotificationObjectComponent, - MetadataFieldWrapperComponent, - ContextHelpWrapperComponent, - EpersonGroupListComponent, - EpersonSearchBoxComponent, - GroupSearchBoxComponent, - ThemedItemPageTitleFieldComponent, -]; - -const ENTRY_COMPONENTS = [ - // put only entry components that use custom decorator - BundleListElementComponent, - CollectionListElementComponent, - CommunityListElementComponent, - SearchResultListElementComponent, - CommunitySearchResultListElementComponent, - CollectionSearchResultListElementComponent, - CollectionGridElementComponent, - CommunityGridElementComponent, - CommunitySearchResultGridElementComponent, - CollectionSearchResultGridElementComponent, - SearchResultGridElementComponent, - ItemListElementComponent, - ItemGridElementComponent, - BitstreamListItemComponent, - ItemSearchResultListElementComponent, - ItemSearchResultGridElementComponent, - BrowseEntryListElementComponent, - SearchResultDetailElementComponent, - StartsWithDateComponent, - StartsWithTextComponent, - CreateCommunityParentSelectorComponent, - ThemedCreateCommunityParentSelectorComponent, - CreateCollectionParentSelectorComponent, - ThemedCreateCollectionParentSelectorComponent, - CreateItemParentSelectorComponent, - ThemedCreateItemParentSelectorComponent, - EditCommunitySelectorComponent, - ThemedEditCommunitySelectorComponent, - EditCollectionSelectorComponent, - ThemedEditCollectionSelectorComponent, - EditItemSelectorComponent, - ThemedEditItemSelectorComponent, - PlainTextMetadataListElementComponent, - BrowseLinkMetadataListElementComponent, - ItemMetadataListElementComponent, - MetadataRepresentationListElementComponent, - ItemMetadataRepresentationListElementComponent, - LogInPasswordComponent, - LogInExternalProviderComponent, - ClaimedTaskActionsDeclineTaskComponent, - CollectionDropdownComponent, - ThemedCollectionDropdownComponent, - FileDownloadLinkComponent, - ThemedFileDownloadLinkComponent, - CurationFormComponent, - ExportMetadataSelectorComponent, - ImportBatchSelectorComponent, - ExportBatchSelectorComponent, - ConfirmationModalComponent, - SidebarSearchListElementComponent, - PublicationSidebarSearchListElementComponent, - CollectionSidebarSearchListElementComponent, - CommunitySidebarSearchListElementComponent, - ScopeSelectorModalComponent, - ListableNotificationObjectComponent, - AdvancedClaimedTaskActionSelectReviewerComponent, - AdvancedClaimedTaskActionRatingComponent, - EpersonGroupListComponent, - EpersonSearchBoxComponent, - GroupSearchBoxComponent -]; - -const PROVIDERS = [ - TruncatableService, - MockAdminGuard, - AbstractTrackableComponent -]; - -const DIRECTIVES = [ - VarDirective, - DragClickDirective, - DebounceDirective, - ClickOutsideDirective, - InListValidator, - AutoFocusDirective, - RoleDirective, - MetadataRepresentationDirective, - ListableObjectDirective, - ClaimedTaskActionsDirective, - FileValueAccessorDirective, - FileValidator, - NgForTrackByIdDirective, - MetadataFieldValidator, - HoverClassDirective, - ContextHelpDirective, -]; - -@NgModule({ - imports: [ - ...MODULES, - ...ROOT_MODULES, - ...PIPES, - ...COMPONENTS, - ...ENTRY_COMPONENTS, - ...DIRECTIVES - ], - providers: [ - ...PROVIDERS - ], - exports: [ - ...MODULES, - ...PIPES, - ...COMPONENTS, - ...ENTRY_COMPONENTS, - ...DIRECTIVES, - TranslateModule, - ] -}) - -/** - * This module handles all components and pipes that need to be shared among multiple other modules - */ -export class SharedModule { - /** - * NOTE: this method allows to resolve issue with components that using a custom decorator - * which are not loaded during SSR otherwise - */ - static withEntryComponents() { - return { - ngModule: SharedModule, - providers: ENTRY_COMPONENTS.map((component) => ({ provide: component })) - }; - } -} diff --git a/src/app/shared/subscriptions/subscriptions.module.ts b/src/app/shared/subscriptions/subscriptions.module.ts index 8dc795e886..bf9987ec1a 100644 --- a/src/app/shared/subscriptions/subscriptions.module.ts +++ b/src/app/shared/subscriptions/subscriptions.module.ts @@ -6,7 +6,6 @@ import { SubscriptionViewComponent } from './subscription-view/subscription-view import { SubscriptionModalComponent } from './subscription-modal/subscription-modal.component'; import { TranslateModule } from '@ngx-translate/core'; import { RouterModule } from '@angular/router'; -import { SharedModule } from '../shared.module'; import { NgbModalModule } from '@ng-bootstrap/ng-bootstrap'; const COMPONENTS = [ @@ -21,7 +20,6 @@ const COMPONENTS = [ ReactiveFormsModule, TranslateModule, RouterModule, - SharedModule, ...COMPONENTS ], exports: [ diff --git a/src/app/shared/testing/browser-only-mock.pipe.ts b/src/app/shared/testing/browser-only-mock.pipe.ts index 12e5a7b2d7..51fca0a296 100644 --- a/src/app/shared/testing/browser-only-mock.pipe.ts +++ b/src/app/shared/testing/browser-only-mock.pipe.ts @@ -4,7 +4,8 @@ import { Pipe, PipeTransform } from '@angular/core'; * Support dsBrowserOnly in unit tests. */ @Pipe({ - name: 'dsBrowserOnly' + name: 'dsBrowserOnly', + standalone: true }) export class BrowserOnlyMockPipe implements PipeTransform { transform(value: string): string | undefined { diff --git a/src/app/shared/testing/ng-component-outlet-directive.stub.ts b/src/app/shared/testing/ng-component-outlet-directive.stub.ts index 7b413e7443..3b4851a46a 100644 --- a/src/app/shared/testing/ng-component-outlet-directive.stub.ts +++ b/src/app/shared/testing/ng-component-outlet-directive.stub.ts @@ -4,6 +4,7 @@ import { Directive, Input } from '@angular/core'; @Directive({ // eslint-disable-next-line @angular-eslint/directive-selector selector: '[ngComponentOutlet]', + standalone: true }) export class NgComponentOutletDirectiveStub { @Input() ngComponentOutlet: any; diff --git a/src/app/shared/testing/test-module.ts b/src/app/shared/testing/test-module.ts index 29846cb830..3fdbcce4e5 100644 --- a/src/app/shared/testing/test-module.ts +++ b/src/app/shared/testing/test-module.ts @@ -1,7 +1,6 @@ import { CommonModule } from '@angular/common'; import { CUSTOM_ELEMENTS_SCHEMA, NgModule } from '@angular/core'; import { MySimpleItemActionComponent } from '../../item-page/edit-item-page/simple-item-action/abstract-simple-item-action.component.spec'; -import { SharedModule } from '../shared.module'; import { NgComponentOutletDirectiveStub } from './ng-component-outlet-directive.stub'; import { QueryParamsDirectiveStub } from './query-params-directive.stub'; import { RouterLinkDirectiveStub } from './router-link-directive.stub'; @@ -16,9 +15,6 @@ import { BrowserOnlyMockPipe } from './browser-only-mock.pipe'; @NgModule({ imports: [ CommonModule, - SharedModule - ], - declarations: [ QueryParamsDirectiveStub, MySimpleItemActionComponent, RouterLinkDirectiveStub, diff --git a/src/app/shared/upload/upload.module.ts b/src/app/shared/upload/upload.module.ts index 12b6567e4f..7b818b0690 100644 --- a/src/app/shared/upload/upload.module.ts +++ b/src/app/shared/upload/upload.module.ts @@ -7,7 +7,6 @@ */ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared.module'; import { FileUploadModule } from 'ng2-file-upload'; import { UploaderComponent } from './uploader/uploader.component'; import { FileDropzoneNoUploaderComponent } from './file-dropzone-no-uploader/file-dropzone-no-uploader.component'; @@ -20,7 +19,6 @@ const COMPONENTS = [ @NgModule({ imports: [ CommonModule, - SharedModule, FileUploadModule, ...COMPONENTS ], diff --git a/src/app/statistics-page/collection-statistics-page/collection-statistics-page.component.spec.ts b/src/app/statistics-page/collection-statistics-page/collection-statistics-page.component.spec.ts index b7b10f5c67..e506923250 100644 --- a/src/app/statistics-page/collection-statistics-page/collection-statistics-page.component.spec.ts +++ b/src/app/statistics-page/collection-statistics-page/collection-statistics-page.component.spec.ts @@ -9,7 +9,6 @@ import { Collection } from '../../core/shared/collection.model'; import { DebugElement } from '@angular/core'; import { By } from '@angular/platform-browser'; import { UsageReport } from '../../core/statistics/models/usage-report.model'; -import { SharedModule } from '../../shared/shared.module'; import { CommonModule } from '@angular/common'; import { DSONameService } from '../../core/breadcrumbs/dso-name.service'; import { DSpaceObjectDataService } from '../../core/data/dspace-object-data.service'; @@ -65,7 +64,6 @@ describe('CollectionStatisticsPageComponent', () => { imports: [ TranslateModule.forRoot(), CommonModule, - SharedModule, CollectionStatisticsPageComponent, StatisticsTableComponent ], diff --git a/src/app/statistics-page/community-statistics-page/community-statistics-page.component.spec.ts b/src/app/statistics-page/community-statistics-page/community-statistics-page.component.spec.ts index 3e55c70148..904ee06923 100644 --- a/src/app/statistics-page/community-statistics-page/community-statistics-page.component.spec.ts +++ b/src/app/statistics-page/community-statistics-page/community-statistics-page.component.spec.ts @@ -9,7 +9,6 @@ import { Community } from '../../core/shared/community.model'; import { DebugElement } from '@angular/core'; import { By } from '@angular/platform-browser'; import { UsageReport } from '../../core/statistics/models/usage-report.model'; -import { SharedModule } from '../../shared/shared.module'; import { CommonModule } from '@angular/common'; import { DSONameService } from '../../core/breadcrumbs/dso-name.service'; import { DSpaceObjectDataService } from '../../core/data/dspace-object-data.service'; @@ -65,7 +64,6 @@ describe('CommunityStatisticsPageComponent', () => { imports: [ TranslateModule.forRoot(), CommonModule, - SharedModule, CommunityStatisticsPageComponent, StatisticsTableComponent ], diff --git a/src/app/statistics-page/item-statistics-page/item-statistics-page.component.spec.ts b/src/app/statistics-page/item-statistics-page/item-statistics-page.component.spec.ts index 0e11b1e66e..8afad8c24b 100644 --- a/src/app/statistics-page/item-statistics-page/item-statistics-page.component.spec.ts +++ b/src/app/statistics-page/item-statistics-page/item-statistics-page.component.spec.ts @@ -9,7 +9,6 @@ import { Item } from '../../core/shared/item.model'; import { DebugElement } from '@angular/core'; import { By } from '@angular/platform-browser'; import { UsageReport } from '../../core/statistics/models/usage-report.model'; -import { SharedModule } from '../../shared/shared.module'; import { CommonModule } from '@angular/common'; import { DSONameService } from '../../core/breadcrumbs/dso-name.service'; import { DSpaceObjectDataService } from '../../core/data/dspace-object-data.service'; @@ -65,7 +64,6 @@ describe('ItemStatisticsPageComponent', () => { imports: [ TranslateModule.forRoot(), CommonModule, - SharedModule, ItemStatisticsPageComponent, StatisticsTableComponent ], diff --git a/src/app/statistics-page/site-statistics-page/site-statistics-page.component.spec.ts b/src/app/statistics-page/site-statistics-page/site-statistics-page.component.spec.ts index 597b4094c1..c6cbf258ac 100644 --- a/src/app/statistics-page/site-statistics-page/site-statistics-page.component.spec.ts +++ b/src/app/statistics-page/site-statistics-page/site-statistics-page.component.spec.ts @@ -9,7 +9,6 @@ import { Site } from '../../core/shared/site.model'; import { DebugElement } from '@angular/core'; import { By } from '@angular/platform-browser'; import { UsageReport } from '../../core/statistics/models/usage-report.model'; -import { SharedModule } from '../../shared/shared.module'; import { CommonModule } from '@angular/common'; import { DSONameService } from '../../core/breadcrumbs/dso-name.service'; import { DSpaceObjectDataService } from '../../core/data/dspace-object-data.service'; @@ -65,7 +64,6 @@ describe('SiteStatisticsPageComponent', () => { imports: [ TranslateModule.forRoot(), CommonModule, - SharedModule, SiteStatisticsPageComponent, StatisticsTableComponent ], diff --git a/src/app/statistics-page/statistics-page.module.ts b/src/app/statistics-page/statistics-page.module.ts index 1a68d249d4..137a023b66 100644 --- a/src/app/statistics-page/statistics-page.module.ts +++ b/src/app/statistics-page/statistics-page.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { StatisticsModule } from '../statistics/statistics.module'; import { UsageReportDataService } from '../core/statistics/usage-report-data.service'; import { SiteStatisticsPageComponent } from './site-statistics-page/site-statistics-page.component'; @@ -29,7 +28,6 @@ const components = [ @NgModule({ imports: [ CommonModule, - SharedModule, StatisticsModule.forRoot(), ...components ], diff --git a/src/app/statistics/statistics.module.ts b/src/app/statistics/statistics.module.ts index 72a68d6b12..8553aa941e 100644 --- a/src/app/statistics/statistics.module.ts +++ b/src/app/statistics/statistics.module.ts @@ -1,6 +1,5 @@ import { ModuleWithProviders, NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../shared/shared.module'; import { ViewTrackerComponent } from './angulartics/dspace/view-tracker.component'; import { StatisticsEndpoint } from './statistics-endpoint.model'; @@ -14,7 +13,6 @@ export const models = [ @NgModule({ imports: [ CommonModule, - SharedModule, ViewTrackerComponent ], exports: [ diff --git a/src/app/submission/form/submission-upload-files/submission-upload-files.component.spec.ts b/src/app/submission/form/submission-upload-files/submission-upload-files.component.spec.ts index b028a65c92..8a8ec6601a 100644 --- a/src/app/submission/form/submission-upload-files/submission-upload-files.component.spec.ts +++ b/src/app/submission/form/submission-upload-files/submission-upload-files.component.spec.ts @@ -26,7 +26,6 @@ import { getMockTranslateService } from '../../../shared/mocks/translate.service import { cold, hot } from 'jasmine-marbles'; import { SubmissionJsonPatchOperationsServiceStub } from '../../../shared/testing/submission-json-patch-operations-service.stub'; import { SubmissionJsonPatchOperationsService } from '../../../core/submission/submission-json-patch-operations.service'; -import { SharedModule } from '../../../shared/shared.module'; import { createTestComponent } from '../../../shared/testing/utils.test'; import { UploaderOptions } from '../../../shared/upload/uploader/uploader-options.model'; @@ -53,7 +52,6 @@ describe('SubmissionUploadFilesComponent Component', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ imports: [ - SharedModule, TranslateModule.forRoot(), SubmissionUploadFilesComponent, TestComponent @@ -203,8 +201,7 @@ describe('SubmissionUploadFilesComponent Component', () => { @Component({ selector: 'ds-test-cmp', template: ``, - standalone: true, - imports: [SharedModule] + standalone: true }) class TestComponent { diff --git a/src/app/submission/sections/cc-license/submission-section-cc-licenses.component.spec.ts b/src/app/submission/sections/cc-license/submission-section-cc-licenses.component.spec.ts index 287cfcf668..8019bac80c 100644 --- a/src/app/submission/sections/cc-license/submission-section-cc-licenses.component.spec.ts +++ b/src/app/submission/sections/cc-license/submission-section-cc-licenses.component.spec.ts @@ -5,7 +5,6 @@ import { of as observableOf } from 'rxjs'; import { SubmissionCcLicenseDataService } from '../../../core/submission/submission-cc-license-data.service'; import { DebugElement } from '@angular/core'; import { By } from '@angular/platform-browser'; -import { SharedModule } from '../../../shared/shared.module'; import { SectionsService } from '../sections.service'; import { SectionDataObject } from '../models/section-data.model'; import { SectionsType } from '../sections-type'; @@ -171,7 +170,6 @@ describe('SubmissionSectionCcLicensesComponent', () => { beforeEach(waitForAsync(() => { TestBed.configureTestingModule({ imports: [ - SharedModule, TranslateModule.forRoot(), SubmissionSectionCcLicensesComponent ], diff --git a/src/app/submission/sections/sherpa-policies/section-sherpa-policies.component.spec.ts b/src/app/submission/sections/sherpa-policies/section-sherpa-policies.component.spec.ts index 2570022a45..b4c8244324 100644 --- a/src/app/submission/sections/sherpa-policies/section-sherpa-policies.component.spec.ts +++ b/src/app/submission/sections/sherpa-policies/section-sherpa-policies.component.spec.ts @@ -1,4 +1,3 @@ -import { SharedModule } from '../../../shared/shared.module'; import { NgbCollapseModule } from '@ng-bootstrap/ng-bootstrap'; import { SubmissionServiceStub } from '../../../shared/testing/submission-service.stub'; import { SherpaDataResponse } from '../../../shared/mocks/section-sherpa-policies.service.mock'; @@ -66,7 +65,6 @@ describe('SubmissionSectionSherpaPoliciesComponent', () => { } }), NgbCollapseModule, - SharedModule, SubmissionSectionSherpaPoliciesComponent ], providers: [ diff --git a/src/app/submission/submission.module.ts b/src/app/submission/submission.module.ts index 02b7ef87ec..d248f713e6 100644 --- a/src/app/submission/submission.module.ts +++ b/src/app/submission/submission.module.ts @@ -1,5 +1,4 @@ import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { SubmissionSectionFormComponent } from './sections/form/section-form.component'; import { SectionsDirective } from './sections/sections.directive'; @@ -110,7 +109,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, StoreModule.forFeature('submission', submissionReducers, storeModuleConfig as StoreConfig), EffectsModule.forFeature(submissionEffects), JournalEntitiesModule.withEntryComponents(), diff --git a/src/app/submit-page/submit-page.module.ts b/src/app/submit-page/submit-page.module.ts index 6942628e9e..2cae5f4efd 100644 --- a/src/app/submit-page/submit-page.module.ts +++ b/src/app/submit-page/submit-page.module.ts @@ -1,6 +1,5 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { SubmitPageRoutingModule } from './submit-page-routing.module'; import { SubmissionModule } from '../submission/submission.module'; import { FormModule } from '../shared/form/form.module'; @@ -9,7 +8,6 @@ import { FormModule } from '../shared/form/form.module'; imports: [ SubmitPageRoutingModule, CommonModule, - SharedModule, SubmissionModule, FormModule, ], diff --git a/src/app/subscriptions-page/subscriptions-page.module.ts b/src/app/subscriptions-page/subscriptions-page.module.ts index 7264813033..92b10a1401 100644 --- a/src/app/subscriptions-page/subscriptions-page.module.ts +++ b/src/app/subscriptions-page/subscriptions-page.module.ts @@ -1,13 +1,11 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { SubscriptionsPageComponent } from './subscriptions-page.component'; -import { SharedModule } from '../shared/shared.module'; import { SubscriptionsModule } from '../shared/subscriptions/subscriptions.module'; @NgModule({ imports: [ CommonModule, - SharedModule, SubscriptionsModule, SubscriptionsPageComponent ] diff --git a/src/app/system-wide-alert/system-wide-alert.module.ts b/src/app/system-wide-alert/system-wide-alert.module.ts index 7a97fa8049..b450360860 100644 --- a/src/app/system-wide-alert/system-wide-alert.module.ts +++ b/src/app/system-wide-alert/system-wide-alert.module.ts @@ -2,7 +2,6 @@ import { NgModule } from '@angular/core'; import { FormsModule } from '@angular/forms'; import { SystemWideAlertBannerComponent } from './alert-banner/system-wide-alert-banner.component'; import { SystemWideAlertFormComponent } from './alert-form/system-wide-alert-form.component'; -import { SharedModule } from '../shared/shared.module'; import { SystemWideAlertDataService } from '../core/data/system-wide-alert-data.service'; import { SystemWideAlertRoutingModule } from './system-wide-alert-routing.module'; import { UiSwitchModule } from 'ngx-ui-switch'; @@ -11,7 +10,6 @@ import { NgbDatepickerModule, NgbTimepickerModule } from '@ng-bootstrap/ng-boots @NgModule({ imports: [ FormsModule, - SharedModule, UiSwitchModule, SystemWideAlertRoutingModule, NgbTimepickerModule, diff --git a/src/app/workflowitems-edit-page/workflowitems-edit-page.module.ts b/src/app/workflowitems-edit-page/workflowitems-edit-page.module.ts index 92312f4a42..3e14f0d9a3 100644 --- a/src/app/workflowitems-edit-page/workflowitems-edit-page.module.ts +++ b/src/app/workflowitems-edit-page/workflowitems-edit-page.module.ts @@ -1,6 +1,5 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { SubmissionModule } from '../submission/submission.module'; import { WorkflowItemDeleteComponent } from './workflow-item-delete/workflow-item-delete.component'; import { WorkflowItemSendBackComponent } from './workflow-item-send-back/workflow-item-send-back.component'; @@ -35,7 +34,6 @@ import { NgbModule } from '@ng-bootstrap/ng-bootstrap'; @NgModule({ imports: [ CommonModule, - SharedModule, SubmissionModule, StatisticsModule, ItemPageModule, diff --git a/src/app/workspaceitems-edit-page/workspaceitems-edit-page.module.ts b/src/app/workspaceitems-edit-page/workspaceitems-edit-page.module.ts index 3481c70835..a44a32b06c 100644 --- a/src/app/workspaceitems-edit-page/workspaceitems-edit-page.module.ts +++ b/src/app/workspaceitems-edit-page/workspaceitems-edit-page.module.ts @@ -1,6 +1,5 @@ import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; -import { SharedModule } from '../shared/shared.module'; import { WorkspaceitemsEditPageRoutingModule } from './workspaceitems-edit-page-routing.module'; import { SubmissionModule } from '../submission/submission.module'; import { WorkspaceItemsDeletePageComponent } from './workspaceitems-delete-page/workspaceitems-delete-page.component'; @@ -10,7 +9,6 @@ import { ThemedWorkspaceItemsDeletePageComponent } from './workspaceitems-delete imports: [ WorkspaceitemsEditPageRoutingModule, CommonModule, - SharedModule, SubmissionModule, WorkspaceItemsDeletePageComponent, ThemedWorkspaceItemsDeletePageComponent diff --git a/src/themes/custom/eager-theme.module.ts b/src/themes/custom/eager-theme.module.ts index fc98a6d6e5..ace8e1ed15 100644 --- a/src/themes/custom/eager-theme.module.ts +++ b/src/themes/custom/eager-theme.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../../app/shared/shared.module'; import { HomeNewsComponent } from './app/home-page/home-news/home-news.component'; import { NavbarComponent } from './app/navbar/navbar.component'; import { SearchNavbarComponent } from './app/search-navbar/search-navbar.component'; @@ -104,7 +103,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, RootModule, NavbarModule, SharedBrowseByModule, diff --git a/src/themes/custom/lazy-theme.module.ts b/src/themes/custom/lazy-theme.module.ts index e7c7c3b913..8dc7ef51be 100644 --- a/src/themes/custom/lazy-theme.module.ts +++ b/src/themes/custom/lazy-theme.module.ts @@ -22,7 +22,6 @@ import { RegisterEmailFormModule } from '../../app/register-email-form/register- import { ResearchEntitiesModule } from '../../app/entity-groups/research-entities/research-entities.module'; import { ScrollToModule } from '@nicky-lenaers/ngx-scroll-to'; import { SearchPageModule } from '../../app/search-page/search-page.module'; -import { SharedModule } from '../../app/shared/shared.module'; import { StatisticsModule } from '../../app/statistics/statistics.module'; import { StoreModule } from '@ngrx/store'; import { StoreRouterConnectingModule } from '@ngrx/router-store'; @@ -309,7 +308,6 @@ const DECLARATIONS = [ RouterModule, ScrollToModule, SearchPageModule, - SharedModule, SharedBrowseByModule, ResultsBackButtonModule, StatisticsModule, diff --git a/src/themes/dspace/eager-theme.module.ts b/src/themes/dspace/eager-theme.module.ts index 2a59932ff2..de184a3608 100644 --- a/src/themes/dspace/eager-theme.module.ts +++ b/src/themes/dspace/eager-theme.module.ts @@ -1,6 +1,5 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; -import { SharedModule } from '../../app/shared/shared.module'; import { HomeNewsComponent } from './app/home-page/home-news/home-news.component'; import { NavbarComponent } from './app/navbar/navbar.component'; import { HeaderComponent } from './app/header/header.component'; @@ -27,7 +26,6 @@ const DECLARATIONS = [ @NgModule({ imports: [ CommonModule, - SharedModule, SharedBrowseByModule, ResultsBackButtonModule, RootModule, diff --git a/src/themes/dspace/lazy-theme.module.ts b/src/themes/dspace/lazy-theme.module.ts index 6c4ccb66b4..a636077f0c 100644 --- a/src/themes/dspace/lazy-theme.module.ts +++ b/src/themes/dspace/lazy-theme.module.ts @@ -32,7 +32,6 @@ import { } from '../../app/entity-groups/research-entities/research-entities.module'; import { ScrollToModule } from '@nicky-lenaers/ngx-scroll-to'; import { SearchPageModule } from '../../app/search-page/search-page.module'; -import { SharedModule } from '../../app/shared/shared.module'; import { StatisticsModule } from '../../app/statistics/statistics.module'; import { StoreModule } from '@ngrx/store'; import { StoreRouterConnectingModule } from '@ngrx/router-store'; @@ -101,7 +100,6 @@ const DECLARATIONS = [ RouterModule, ScrollToModule, SearchPageModule, - SharedModule, SharedBrowseByModule, StatisticsModule, StatisticsPageModule,