blob: ab6ecaa0826b2a484a9ac7532e5cb11191dafac8 [file] [log] [blame]
Sonsino, Ofir (os0695)ff76b5e2018-07-10 15:57:37 +03001import {NgModule, ModuleWithProviders} from '@angular/core';
2import {CommonModule} from '@angular/common';
3import {RouterModule} from '@angular/router';
4import { BrowserModule } from '@angular/platform-browser';
5import { HttpClientModule } from '@angular/common/http';
6import { ServiceInfoService } from './server/serviceInfo/serviceInfo.service';
7import { PopoverModule } from 'ngx-bootstrap';
8import { AngularSvgIconModule } from 'angular-svg-icon';
9import { SvgDirective } from './directives/svg/svg.directive';
10import { PopoverComponent } from './components/popover/popover.component';
11import { EllipsisComponent } from './components/ellipsis/ellipsis.component';
12import { MessageBoxComponent } from './components/messageBox/messageBox.component';
13import { MessageBoxService } from './components/messageBox/messageBox.service';
14import { SdcUiComponentsModule , SdcUiComponents} from 'sdc-ui/lib/angular';
15import { HttpInterceptorService } from './utils/httpInterceptor/httpInterceptor.service';
16import { FormControlErrorComponent } from './components/formControlError/formControlError.component';
17import { InputPreventionPatternDirective } from './directives/inputPrevention/inputPreventionPattern.directive';
18import { FormGeneralErrorsComponent } from './components/formGeneralErrors/formGeneralErrors.component';
19import { NumbersLettersUnderscoreValidator } from './components/validators/numbersLettersUnderscore/numbersLettersUnderscore.validator';
20import { SpinnerComponent } from './components/spinner/spinner.component';
21import { NoContentMessageAndIconComponent } from './components/no-content-message-and-icon/no-content-message-and-icon.component';
22import { ModelInformationComponent } from './components/model-information/model-information.component';
23import { TooltipModule } from 'ngx-tooltip';
24import {IframeService} from "./utils/iframe.service";
25import {CapitalizeAndFormatPipe} from "./pipes/capitalize/capitalize-and-format.pipe";
26import { DefaultDataGeneratorService } from './services/defaultDataServiceGenerator/default.data.generator.service';
27import {ServiceInfoPipe} from "./pipes/serviceInfo/serviceInfo.pipe";
28import {HealthStatusService} from "./server/healthStatusService/health-status.service";
29import {ConfigurationService} from "../services/configuration.service";
30import {FlagsResolve} from "../services/flags.resolve";
31
32
33@NgModule({
34 imports: [
35 BrowserModule,
36 HttpClientModule,
37 CommonModule,
38 RouterModule,
39 PopoverModule.forRoot(),
40 AngularSvgIconModule,
41 TooltipModule,
42 SdcUiComponentsModule,
43 ],
44 declarations: [
45 PopoverComponent,
46 SvgDirective,
47 EllipsisComponent,
48 MessageBoxComponent,
49 FormControlErrorComponent,
50 InputPreventionPatternDirective,
51 FormGeneralErrorsComponent,
52 SpinnerComponent,
53 NoContentMessageAndIconComponent,
54 ModelInformationComponent,
55 CapitalizeAndFormatPipe,
56 ServiceInfoPipe,
57 ],
58 exports: [
59 PopoverComponent,
60 SvgDirective,
61 EllipsisComponent,
62 MessageBoxComponent,
63 FormControlErrorComponent,
64 InputPreventionPatternDirective,
65 FormGeneralErrorsComponent,
66 SpinnerComponent,
67 NoContentMessageAndIconComponent,
68 ModelInformationComponent,
69 CapitalizeAndFormatPipe,
70 ServiceInfoPipe,
71 ],
72 providers: [
73 ServiceInfoService,
74 MessageBoxService,
75 SdcUiComponents.ModalService,
76 HttpInterceptorService,
77 IframeService,
78 NumbersLettersUnderscoreValidator,
79 DefaultDataGeneratorService,
80 HealthStatusService,
81 ConfigurationService,
82 FlagsResolve
83 ]
84})
85export class SharedModule {
86 static forRoot(): ModuleWithProviders {
87 return {
88 ngModule: SharedModule,
89 providers: [MessageBoxService]
90 };
91 }
92}