connect/src/app/app.module.ts

68 lines
2.9 KiB
TypeScript
Raw Normal View History

import {NgModule} from '@angular/core';
import {FormsModule} from '@angular/forms';
import {CommonModule} from '@angular/common';
import {HTTP_INTERCEPTORS, HttpClientModule} from "@angular/common/http";
import {BrowserModule, BrowserTransferStateModule} from '@angular/platform-browser';
import {NoopAnimationsModule} from '@angular/platform-browser/animations';
import {AppComponent} from './app.component';
import {OpenaireErrorPageComponent} from './error/errorPage.component';
import {AppRoutingModule} from './app-routing.module';
import {SharedModule} from './shared/shared.module';
import {CookieLawModule} from './openaireLibrary/sharedComponents/cookie-law/cookie-law.module';
import {BottomModule} from './openaireLibrary/sharedComponents/bottom.module';
import {ErrorModule} from './openaireLibrary/error/error.module';
import {NavigationBarModule} from './openaireLibrary/sharedComponents/navigationBar.module';
import {EnvironmentSpecificResolver} from './openaireLibrary/utils/properties/environmentSpecificResolver';
import {CommunitiesService} from './openaireLibrary/connect/communities/communities.service';
import {LayoutService} from "./openaireLibrary/services/layout.service";
import {SubscribeModule} from './utils/subscribe/subscribe.module';
import {ThemeComponent} from "./test/theme.component";
import {CustomizationModule} from "./utils/customization/customization.module";
import {HttpInterceptorService} from "./openaireLibrary/http-interceptor.service";
import {PageURLResolverComponent} from "./openaireLibrary/utils/pageURLResolver.component";
[Trunk | Connect]: Connect redesing 1. app.component.ts: <subscribe> and <invite> components added (floating buttons on the right side of each page for communities). 2. community.component.html: 3. community.component.ts: a. 'projectsCalculated' and 'contentProvidersCalculated' fields added, to calculate tootlip after both requests complete b. added methods for building tootips c. 'activeTab' set to 'summary'. 4. affiliations.component.html: minor phrasing changes (e.g. title). 5. curators.component.html: shortview changed. 6. results.component.ts: Title changed | 'View all' moved to the bottom. 7. customization.component.ts: Changed '--portal-main-color' from '#4C9CD5' to '#4687E6' | Changed '--portal-dark-color' from '#24857F' to '#2D72D6'. 8. invite.component.html: shortview changed. 9. invite.component.ts: 'properties' field as input (get it is called from app.component). 10. invite.module.ts & inviteBasic.module.ts: InviteBasicModule created to declare InviteComponent without routing and login guard | InviteModule imports InviteBasicModule and adds routing and login guar$ 11. subscribe.component.ts: Changes for subscribe button and members | 'properties' field as input (get it is called from app.component). 12. connect-custom.css: css for subscribe and invite buttons and for tooltip with 'community-page-tooltip' class. 13. customization.css: class 'communityBackground' added and css for 'subtitle' class inside 'communityBackground'. git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@58549 d315682c-612b-4755-9ff5-7f18f6832af3
2020-04-24 18:38:35 +02:00
import {InviteModule} from "./utils/subscribe/invite/invite.module";
import {FreeGuard} from "./openaireLibrary/login/freeGuard.guard";
import {PreviousRouteRecorder} from "./openaireLibrary/utils/piwik/previousRouteRecorder.guard";
import {PiwikService} from "./openaireLibrary/utils/piwik/piwik.service";
import {CommunityService} from "./openaireLibrary/connect/community/community.service";
import {InviteBasicModule} from "./utils/subscribe/invite/inviteBasic.module";
[Trunk | Connect]: 1. app-routing.module.ts: Add route '/subjects'. 2. app.component.ts: Group subscribe and invite buttons under id="subscribeAndInviteBtn" (keep distance between them alwayes the same) | uncomment menu item 'Subjects' in About. 3. app.module.ts: import 'SubscribeService' (singleton service to update everywhere subscriber status). 4. libUser.module.ts & subscribe.module.ts: remove import of 'SubscribeService' (singleton service to update everywhere subscriber status). 5. community.component.html: a. Improve some checks b. In main tabs of the page (class main-tabs) add class 'uk-text-truncate' and remove class 'uk-width-3-4' (each tab has max-width) c. Add icon in 'Analytics' tab d. [Bug fix] In description, fix overflow and max height of box 6. community.component.ts: Add field '@ViewChild(SubscribeComponent) subscribeComponent: SubscribeComponent' to add some checks in html. 7. curators.component.html: Remove div with class 'image-front-topbar' | Update css for title | Add <breadcrumbs> | Add user icon for each curator. 8. curators.component.ts: Initialize breadcrumb | [Bug fix] In methods 'getPageContents()' and 'getDivContents()' use communityId (instead of 'connect'). 9. curators.module.ts & organizationsPage.module.ts & inviteBasic.module.ts: import 'BreadcrumbsModule'. 10. organizationsPage.component.ts: Update css for title | Add <breadcrumbs> | Initialize breadcrumb. 11. subjects.component.ts, subjects.module.ts, subjects-routing.module.ts: Add page for Subjects. 12. invite.component.html: Add <breadcrumbs> in longView | Add icon in button 'Invite users'. 13. invite.component.ts: Initialize breadcrumb. 14. subscribe.component.ts: a. Add icon in button "Subscribe"/ "Subscribed" b. Add class 'uk-display-inline-block' in showNumbers (members) c. Initialize and get subscriber status with new methods of service (initIsSubscribedToCommunity() & isSubscribed - BehaviorSubject instead of isSubscribedToCommunity()) 15. connect-custom.css: Group css for #subscribeBtn, #inviteBtn into #subscribeAndInviteBtn | Add css for class 'user-circle-background' (background of user icon in curators). git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@58574 d315682c-612b-4755-9ff5-7f18f6832af3
2020-04-28 13:07:36 +02:00
import {SubscribeService} from "./openaireLibrary/utils/subscribe/subscribe.service";
@NgModule({
imports: [
SharedModule,
NoopAnimationsModule,
CommonModule,
HttpClientModule,
ErrorModule,
FormsModule,
NavigationBarModule,
BottomModule,
CookieLawModule,
CustomizationModule,
[Trunk | Connect]: Connect redesing 1. app.component.ts: <subscribe> and <invite> components added (floating buttons on the right side of each page for communities). 2. community.component.html: 3. community.component.ts: a. 'projectsCalculated' and 'contentProvidersCalculated' fields added, to calculate tootlip after both requests complete b. added methods for building tootips c. 'activeTab' set to 'summary'. 4. affiliations.component.html: minor phrasing changes (e.g. title). 5. curators.component.html: shortview changed. 6. results.component.ts: Title changed | 'View all' moved to the bottom. 7. customization.component.ts: Changed '--portal-main-color' from '#4C9CD5' to '#4687E6' | Changed '--portal-dark-color' from '#24857F' to '#2D72D6'. 8. invite.component.html: shortview changed. 9. invite.component.ts: 'properties' field as input (get it is called from app.component). 10. invite.module.ts & inviteBasic.module.ts: InviteBasicModule created to declare InviteComponent without routing and login guard | InviteModule imports InviteBasicModule and adds routing and login guar$ 11. subscribe.component.ts: Changes for subscribe button and members | 'properties' field as input (get it is called from app.component). 12. connect-custom.css: css for subscribe and invite buttons and for tooltip with 'community-page-tooltip' class. 13. customization.css: class 'communityBackground' added and css for 'subtitle' class inside 'communityBackground'. git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@58549 d315682c-612b-4755-9ff5-7f18f6832af3
2020-04-24 18:38:35 +02:00
SubscribeModule.forRoot(), InviteBasicModule,
BrowserModule.withServerTransition({appId: 'my-app'}),
AppRoutingModule,
BrowserTransferStateModule
],
declarations: [ AppComponent, OpenaireErrorPageComponent, ThemeComponent, PageURLResolverComponent],
exports: [ AppComponent ],
providers:[
[Trunk | Connect]: 1. app-routing.module.ts: Add route '/subjects'. 2. app.component.ts: Group subscribe and invite buttons under id="subscribeAndInviteBtn" (keep distance between them alwayes the same) | uncomment menu item 'Subjects' in About. 3. app.module.ts: import 'SubscribeService' (singleton service to update everywhere subscriber status). 4. libUser.module.ts & subscribe.module.ts: remove import of 'SubscribeService' (singleton service to update everywhere subscriber status). 5. community.component.html: a. Improve some checks b. In main tabs of the page (class main-tabs) add class 'uk-text-truncate' and remove class 'uk-width-3-4' (each tab has max-width) c. Add icon in 'Analytics' tab d. [Bug fix] In description, fix overflow and max height of box 6. community.component.ts: Add field '@ViewChild(SubscribeComponent) subscribeComponent: SubscribeComponent' to add some checks in html. 7. curators.component.html: Remove div with class 'image-front-topbar' | Update css for title | Add <breadcrumbs> | Add user icon for each curator. 8. curators.component.ts: Initialize breadcrumb | [Bug fix] In methods 'getPageContents()' and 'getDivContents()' use communityId (instead of 'connect'). 9. curators.module.ts & organizationsPage.module.ts & inviteBasic.module.ts: import 'BreadcrumbsModule'. 10. organizationsPage.component.ts: Update css for title | Add <breadcrumbs> | Initialize breadcrumb. 11. subjects.component.ts, subjects.module.ts, subjects-routing.module.ts: Add page for Subjects. 12. invite.component.html: Add <breadcrumbs> in longView | Add icon in button 'Invite users'. 13. invite.component.ts: Initialize breadcrumb. 14. subscribe.component.ts: a. Add icon in button "Subscribe"/ "Subscribed" b. Add class 'uk-display-inline-block' in showNumbers (members) c. Initialize and get subscriber status with new methods of service (initIsSubscribedToCommunity() & isSubscribed - BehaviorSubject instead of isSubscribedToCommunity()) 15. connect-custom.css: Group css for #subscribeBtn, #inviteBtn into #subscribeAndInviteBtn | Add css for class 'user-circle-background' (background of user icon in curators). git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@58574 d315682c-612b-4755-9ff5-7f18f6832af3
2020-04-28 13:07:36 +02:00
EnvironmentSpecificResolver, CommunitiesService, LayoutService, SubscribeService,
[Trunk | Connect]: Connect redesing 1. app.component.ts: <subscribe> and <invite> components added (floating buttons on the right side of each page for communities). 2. community.component.html: 3. community.component.ts: a. 'projectsCalculated' and 'contentProvidersCalculated' fields added, to calculate tootlip after both requests complete b. added methods for building tootips c. 'activeTab' set to 'summary'. 4. affiliations.component.html: minor phrasing changes (e.g. title). 5. curators.component.html: shortview changed. 6. results.component.ts: Title changed | 'View all' moved to the bottom. 7. customization.component.ts: Changed '--portal-main-color' from '#4C9CD5' to '#4687E6' | Changed '--portal-dark-color' from '#24857F' to '#2D72D6'. 8. invite.component.html: shortview changed. 9. invite.component.ts: 'properties' field as input (get it is called from app.component). 10. invite.module.ts & inviteBasic.module.ts: InviteBasicModule created to declare InviteComponent without routing and login guard | InviteModule imports InviteBasicModule and adds routing and login guar$ 11. subscribe.component.ts: Changes for subscribe button and members | 'properties' field as input (get it is called from app.component). 12. connect-custom.css: css for subscribe and invite buttons and for tooltip with 'community-page-tooltip' class. 13. customization.css: class 'communityBackground' added and css for 'subtitle' class inside 'communityBackground'. git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-connect-portal/trunk@58549 d315682c-612b-4755-9ff5-7f18f6832af3
2020-04-24 18:38:35 +02:00
//FreeGuard, PreviousRouteRecorder, PiwikService, CommunityService,
{
provide: HTTP_INTERCEPTORS,
useClass: HttpInterceptorService,
multi: true
}
],
bootstrap: [AppComponent]
})
//
export class AppModule {}