import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';

import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';

import { TooltipModule } from 'ngx-bootstrap/tooltip';
import { NavMenuComponent } from './nav-menu/nav-menu.component';
import { HomeComponent } from './home/home.component';
import { RouterModule } from '@angular/router';

import { StockChartAllModule, AccumulationChartAllModule, RangeNavigatorAllModule } from '@syncfusion/ej2-angular-charts';
import { ChartAllModule } from '@syncfusion/ej2-angular-charts';
import { GridModule, PagerModule } from '@syncfusion/ej2-angular-grids';
import { MultiSelectAllModule, DropDownListAllModule } from '@syncfusion/ej2-angular-dropdowns';
import { GridComponent } from './grid/grid.component';
import { DataService } from './grid/data-service';

@NgModule({
  declarations: [
    AppComponent,
    NavMenuComponent,
    HomeComponent,
    GridComponent
  ],
  imports: [
    StockChartAllModule,
    RangeNavigatorAllModule,
    AccumulationChartAllModule,
    ChartAllModule,
    GridModule,
    PagerModule,
    MultiSelectAllModule,
    DropDownListAllModule,

    BrowserModule,
    AppRoutingModule,
    ChartAllModule,
    TooltipModule.forRoot(),

    RouterModule.forRoot([
      { path: '', redirectTo: 'home', pathMatch: 'full' },
      { path: 'home', component: HomeComponent },
      { path: 'grid', component: GridComponent },
      { path: '**', redirectTo: 'home' }
    ]),
  ],
  providers: [DataService],
  bootstrap: [AppComponent]
})
export class AppModule { }
