import { BrowserModule } from '@angular/platform-browser';
//import { NgModule } from '@angular/core';
import { CUSTOM_ELEMENTS_SCHEMA, NgModule } from '@angular/core';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { NgMultiSelectDropDownModule } from 'ng-multiselect-dropdown';
import { AuthService } from './auth.service';
import { ModalModule, BsModalService, BsModalRef } from 'ngx-bootstrap/modal';
import { HttpClientModule, HTTP_INTERCEPTORS } from '@angular/common/http';
import { BootstrapModalModule } from 'ng2-bootstrap-modal';
import { AngularDraggableModule } from 'angular2-draggable';
import { ToastrModule } from 'ngx-toastr';
import { CommonModule } from '@angular/common';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { TokenInterceptor } from './token.interceptor';
import { HashLocationStrategy, LocationStrategy, DatePipe } from '@angular/common';
import { SanitizeHtmlPipe } from './sanitizeHtml.pipe';

import { AppComponent } from './app.component';
import { NavMenuComponent } from './Shared/nav-menu/nav-menu.component';
import { HomeComponent } from './home/home.component';
import { LoginlayoutComponent } from './Shared/loginlayout/loginlayout.component';
import { HomelayoutComponent } from './Shared/homelayout/homelayout.component';
import { LoginComponent } from './login/login.component';
import { TopbarComponent } from './Shared/topbar/topbar.component';
import { CommondialogComponent } from './Shared/commondialog/commondialog.component';
import { LogoutComponent } from './logout/logout.component';
import { ChangepasswordComponent } from './changepassword/changepassword.component';
import { ResetpasswordComponent } from './resetpassword/resetpassword.component';
import { SharedModule } from './Shared/shared.module';
import { AppRoutingModule } from './app.routing';
import { DownloaderComponent } from './home/downloader/downloader.component';
import { UploaderComponent } from './home/uploader/uploader.component';
import { CKEditorModule } from 'ng2-ckeditor';
import { NgxPaginationModule } from 'ngx-pagination';
@NgModule({
  declarations: [
    AppComponent,
    NavMenuComponent,
    HomeComponent,
    LoginlayoutComponent,
    HomelayoutComponent,
    LoginComponent,
    TopbarComponent,
    CommondialogComponent,
    LogoutComponent,
    ChangepasswordComponent,
    ResetpasswordComponent,
    DownloaderComponent,
    UploaderComponent,
    SanitizeHtmlPipe
  ],
  entryComponents: [CommondialogComponent],
  imports: [
    BrowserModule,
    BrowserAnimationsModule,
    CommonModule,
    ReactiveFormsModule,
    FormsModule,
    HttpClientModule,
    AngularDraggableModule,
    ModalModule.forRoot(),
    ToastrModule.forRoot(),
    BootstrapModalModule.forRoot({ container: document.body }),
    NgMultiSelectDropDownModule.forRoot(),
    SharedModule,
    AppRoutingModule,
    CKEditorModule,
    NgxPaginationModule
  ],
  providers: [
    AuthService, BsModalRef, BsModalService,SanitizeHtmlPipe,
      {
        provide: HTTP_INTERCEPTORS,
        useClass: TokenInterceptor,
        multi: true
      },
      { provide: LocationStrategy, useClass: HashLocationStrategy }
  ],
  schemas:[CUSTOM_ELEMENTS_SCHEMA],
  bootstrap: [AppComponent]
})
export class AppModule { }
