]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/core/core.module.ts
provide specific engine boundaries for nodejs and yarn
[github/Chocobozzz/PeerTube.git] / client / src / app / core / core.module.ts
CommitLineData
df98563e 1import { CommonModule } from '@angular/common'
78967fca 2import { NgModule, Optional, SkipSelf } from '@angular/core'
1f30a185 3import { FormsModule } from '@angular/forms'
e7dbeae8 4import { BrowserAnimationsModule } from '@angular/platform-browser/animations'
78967fca 5import { RouterModule } from '@angular/router'
68e24d72
C
6import { LoadingBarModule } from '@ngx-loading-bar/core'
7import { LoadingBarHttpClientModule } from '@ngx-loading-bar/http-client'
998acc22 8import { LoadingBarRouterModule } from '@ngx-loading-bar/router'
693b1aba 9
954605a8 10import { AuthService } from './auth'
457bb213 11import { ConfirmService } from './confirm'
df98563e 12import { throwIfAlreadyLoaded } from './module-import-guard'
901637bb 13import { LoginGuard, RedirectService, UserRightGuard } from './routing'
78967fca 14import { ServerService } from './server'
1a00c561 15import { ThemeService } from './theme'
3b20bdd6 16import { MenuService } from './menu'
bcb0c895 17import { HotkeyModule } from 'angular2-hotkeys'
f8b2c1b4
C
18import { CheatSheetComponent } from './hotkeys'
19import { ToastModule } from 'primeng/toast'
20import { Notifier } from './notification'
21import { MessageService } from 'primeng/api'
9a39392a 22import { UserNotificationSocket } from '@app/core/notification/user-notification-socket.service'
f3ae606c 23import { ServerConfigResolver } from './routing/server-config-resolver.service'
b247a132 24import { UnloggedGuard } from '@app/core/routing/unlogged-guard.service'
18a6f04c 25import { PluginService } from '@app/core/plugins/plugin.service'
93cae479 26import { HooksService } from '@app/core/plugins/hooks.service'
693b1aba
C
27
28@NgModule({
29 imports: [
30 CommonModule,
7ddd02c9 31 RouterModule,
1f30a185 32 FormsModule,
e7dbeae8 33 BrowserAnimationsModule,
7ddd02c9 34
68e24d72 35 LoadingBarHttpClientModule,
998acc22 36 LoadingBarRouterModule,
06471769 37 LoadingBarModule,
f8b2c1b4 38 ToastModule,
bcb0c895
C
39
40 HotkeyModule.forRoot({
41 cheatSheetCloseEsc: true
42 })
693b1aba 43 ],
5769e1db 44
b99290b1 45 declarations: [
bcb0c895 46 CheatSheetComponent
b99290b1 47 ],
5769e1db 48
b99290b1 49 exports: [
68e24d72
C
50 LoadingBarHttpClientModule,
51 LoadingBarModule,
7ddd02c9 52
f8b2c1b4
C
53 ToastModule,
54
bcb0c895 55 CheatSheetComponent
b99290b1 56 ],
5769e1db
C
57
58 providers: [
59 AuthService,
92fb909c 60 ConfirmService,
f47bf2e1 61 ServerService,
1a00c561 62 ThemeService,
3b20bdd6 63 MenuService,
954605a8 64 LoginGuard,
901637bb 65 UserRightGuard,
b247a132
C
66 UnloggedGuard,
67
18a6f04c 68 PluginService,
93cae479 69 HooksService,
18a6f04c 70
f8b2c1b4
C
71 RedirectService,
72 Notifier,
9a39392a 73 MessageService,
f3ae606c
C
74 UserNotificationSocket,
75 ServerConfigResolver
5769e1db 76 ]
693b1aba
C
77})
78export class CoreModule {
7a8032bb 79 constructor (@Optional() @SkipSelf() parentModule: CoreModule) {
df98563e 80 throwIfAlreadyLoaded(parentModule, 'CoreModule')
693b1aba
C
81 }
82}