import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { DatePipe } from '@angular/common';
import { NgbActiveModal } from "@ng-bootstrap/ng-bootstrap";
import { NgZorroAntdModule } from 'ng-zorro-antd';
import { EmitService } from "./event/eventEmitter";
import {
    BootappSharedLibsModule,
    BootappSharedCommonModule,
    CSRFService,
    AuthServerProvider,
    AccountService,
    UserService,
    StateStorageService,
    LoginService,
    LoginModalService,
    JhiLoginModalComponent,
    Principal,
    HasAnyAuthorityDirective,
} from './';
import {ToTree} from './common/toTree';
import {ReactiveFormsModule} from '@angular/forms';

@NgModule({
    imports: [
        ReactiveFormsModule,
        NgZorroAntdModule,
        BootappSharedLibsModule,
        BootappSharedCommonModule
    ],
    declarations: [
        JhiLoginModalComponent,
        HasAnyAuthorityDirective
    ],
    providers: [
        LoginService,
        LoginModalService,
        AccountService,
        StateStorageService,
        Principal,
        CSRFService,
        AuthServerProvider,
        UserService,
        DatePipe,
        EmitService,
        NgbActiveModal,
        ToTree,
    ],
    entryComponents: [JhiLoginModalComponent],
    exports: [
        BootappSharedCommonModule,
        JhiLoginModalComponent,
        HasAnyAuthorityDirective,
        DatePipe
    ],
    schemas: [CUSTOM_ELEMENTS_SCHEMA]

})
export class BootappSharedModule {}
