import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { MatCardModule } from '@angular/material/card';
import { MatRippleModule } from '@angular/material/core';
import { MatPaginatorModule } from '@angular/material/paginator';
import { MatTableModule } from "@angular/material/table"
import { ApiModule } from './api/api.module';
import { HttpClientModule } from '@angular/common/http';
import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
import { MatListModule } from '@angular/material/list';
import { MatCheckboxModule } from '@angular/material/checkbox';
import { ReactiveFormsModule, FormsModule } from '@angular/forms';
import { MatSortModule } from '@angular/material/sort';
import { MatInputModule } from "@angular/material/input";
import { MatButtonModule } from '@angular/material/button';
import { MatIconModule } from '@angular/material/icon';
import { MatDialogModule } from "@angular/material/dialog";
import { PackageDialogComponent } from './components/package-dialog/package-dialog.component';
import { MatMenuModule } from '@angular/material/menu';
import { MatRadioModule } from '@angular/material/radio';
import { MatSnackBarModule } from '@angular/material/snack-bar';
import { ConfirmDialogComponent } from './components/confirm-dialog/confirm-dialog.component';
import { MatSelectModule } from '@angular/material/select';
import { MessageService } from './services/message/message.service';
import { ConfirmService } from './services/confirm/confirm.service';
import { PackageListComponent } from './components/package-list/package-list.component';
import { PackagesService } from './services/packages/packages.service';
import { PkgdashService } from './api/services';
import { AppConstants } from './app.constants';
import { PackageComponent } from './components/package/package.component';

@NgModule({
  declarations: [
    AppComponent,
    PackageListComponent,
    PackageDialogComponent,
    ConfirmDialogComponent,
    PackageComponent,
  ],
  imports: [
    BrowserModule,
    AppRoutingModule,
    MatCardModule,
    MatRippleModule,
    MatPaginatorModule,
    MatProgressSpinnerModule,
    MatTableModule,
    MatListModule,
    MatPaginatorModule,
    MatSortModule,
    MatInputModule,
    MatCheckboxModule,
    MatButtonModule,
    FormsModule,
    ReactiveFormsModule,
    BrowserAnimationsModule,
    MatDialogModule,
    MatIconModule,
    HttpClientModule,
    MatMenuModule,
    MatRadioModule,
    MatSelectModule,
    MatSnackBarModule,
    ApiModule.forRoot({
      rootUrl: AppConstants.API,
    })
  ],
  exports: [
    MatSnackBarModule,
    MatSelectModule,
    MatRadioModule,
    MatMenuModule,
    MatDialogModule,
    MatIconModule,
    MatButtonModule,
    MatInputModule,
    MatPaginatorModule,
    MatSortModule,
    ReactiveFormsModule,
    FormsModule,
    MatCheckboxModule,
    MatListModule,
    MatProgressSpinnerModule,
    MatCardModule,
    MatRippleModule,
    MatPaginatorModule,
    MatTableModule,
    HttpClientModule,
    PackageDialogComponent,
  ],
  providers: [
    PkgdashService,
    PackagesService,
    ConfirmService,
    MessageService,
  ],
  bootstrap: [AppComponent]
})
export class AppModule { }
