2019-10-25 04:16:11 +00:00
|
|
|
import { DateToStringForChatRoomListPipe } from './pipes/dates.pipe';
|
2019-09-18 06:02:21 +00:00
|
|
|
import { NgModule, ModuleWithProviders } from '@angular/core';
|
|
|
|
import { CommonModule } from '@angular/common';
|
|
|
|
|
2019-10-21 04:36:58 +00:00
|
|
|
import { FlexLayoutModule } from '@angular/flex-layout';
|
|
|
|
|
2019-09-18 06:02:21 +00:00
|
|
|
import { MatButtonModule } from '@angular/material/button';
|
|
|
|
import { MatCardModule } from '@angular/material/card';
|
|
|
|
import { MatDialogModule } from '@angular/material/dialog';
|
2019-10-21 04:36:58 +00:00
|
|
|
import { MatIconModule } from '@angular/material/icon';
|
2019-10-16 09:05:18 +00:00
|
|
|
import { MatSnackBarModule } from '@angular/material/snack-bar';
|
2019-09-18 06:02:21 +00:00
|
|
|
|
2019-09-24 05:53:22 +00:00
|
|
|
import { DragDropModule } from '@angular/cdk/drag-drop';
|
|
|
|
|
2019-10-21 04:36:58 +00:00
|
|
|
import { FileUploadQueueComponent } from './components/file-upload-queue.component';
|
2019-10-17 09:11:38 +00:00
|
|
|
import { ImageComponent } from './components/image.component';
|
2019-10-21 04:36:58 +00:00
|
|
|
const COMPONENTS = [ImageComponent, FileUploadQueueComponent];
|
2019-10-17 07:57:37 +00:00
|
|
|
|
2019-09-18 06:02:21 +00:00
|
|
|
import { BottomSheetService } from './services/bottom-sheet.service';
|
2019-10-16 09:05:18 +00:00
|
|
|
import { ClipboardService } from './services/clipboard.service';
|
2019-09-18 06:02:21 +00:00
|
|
|
import { DialogService } from './services/dialog.service';
|
2019-10-16 09:05:18 +00:00
|
|
|
import { SnackBarService } from './services/snack-bar.service';
|
|
|
|
const SERVICES = [
|
|
|
|
BottomSheetService,
|
|
|
|
ClipboardService,
|
|
|
|
DialogService,
|
|
|
|
SnackBarService
|
|
|
|
];
|
2019-09-18 06:02:21 +00:00
|
|
|
|
2019-10-21 04:36:58 +00:00
|
|
|
import { FileUploadForDirective } from './directives/file-upload-for.directive';
|
|
|
|
const DIRECTIVES = [FileUploadForDirective];
|
|
|
|
|
2019-09-18 06:02:21 +00:00
|
|
|
import { AlertDialogComponent } from './dialogs/alert.dialog.component';
|
|
|
|
import { ConfirmDialogComponent } from './dialogs/confirm.dialog.component';
|
|
|
|
const DIALOGS = [AlertDialogComponent, ConfirmDialogComponent];
|
|
|
|
|
2019-10-21 04:36:58 +00:00
|
|
|
import { BytesPipe } from './pipes/bytes.pipe';
|
2019-10-25 04:16:11 +00:00
|
|
|
import { LinefeedToHtmlPipe, HtmlToLinefeedPipe } from './pipes/linefeed.pipe';
|
|
|
|
const PIPES = [
|
|
|
|
BytesPipe,
|
|
|
|
LinefeedToHtmlPipe,
|
|
|
|
HtmlToLinefeedPipe,
|
|
|
|
DateToStringForChatRoomListPipe
|
|
|
|
];
|
2019-10-17 07:57:37 +00:00
|
|
|
|
2019-09-18 06:02:21 +00:00
|
|
|
@NgModule({
|
2019-09-24 05:53:22 +00:00
|
|
|
imports: [
|
|
|
|
CommonModule,
|
2019-10-21 04:36:58 +00:00
|
|
|
FlexLayoutModule,
|
2019-09-24 05:53:22 +00:00
|
|
|
MatButtonModule,
|
|
|
|
MatCardModule,
|
|
|
|
MatDialogModule,
|
2019-10-21 04:36:58 +00:00
|
|
|
MatIconModule,
|
2019-10-16 09:05:18 +00:00
|
|
|
MatSnackBarModule,
|
2019-09-24 05:53:22 +00:00
|
|
|
DragDropModule
|
|
|
|
],
|
2019-10-21 04:36:58 +00:00
|
|
|
exports: [...COMPONENTS, ...DIRECTIVES, ...PIPES],
|
|
|
|
declarations: [...COMPONENTS, ...DIALOGS, ...DIRECTIVES, ...PIPES],
|
2019-09-18 06:02:21 +00:00
|
|
|
entryComponents: [...DIALOGS]
|
|
|
|
})
|
|
|
|
export class UCapUiModule {
|
|
|
|
public static forRoot(): ModuleWithProviders<UCapUiModule> {
|
|
|
|
return {
|
|
|
|
ngModule: UCapUiModule,
|
|
|
|
providers: [...SERVICES]
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|