funky-framadate-front/src/app/shared/shared.module.ts

84 lines
4.1 KiB
TypeScript
Raw Normal View History

import { CommonModule } from '@angular/common';
2020-04-22 12:56:18 +02:00
import { NgModule } from '@angular/core';
2020-05-05 18:17:12 +02:00
import { FormsModule } from '@angular/forms';
import { MatLegacyButtonModule as MatButtonModule } from '@angular/material/legacy-button';
import { MatLegacyCheckboxModule as MatCheckboxModule } from '@angular/material/legacy-checkbox';
import { MatDatepickerModule } from '@angular/material/datepicker';
import { MatLegacyDialogModule as MatDialogModule } from '@angular/material/legacy-dialog';
import { MatLegacyFormFieldModule as MatFormFieldModule } from '@angular/material/legacy-form-field';
import { MatLegacyInputModule as MatInputModule } from '@angular/material/legacy-input';
import { MatLegacyProgressSpinnerModule as MatProgressSpinnerModule } from '@angular/material/legacy-progress-spinner';
import { MatSidenavModule } from '@angular/material/sidenav';
import { MatLegacySlideToggleModule as MatSlideToggleModule } from '@angular/material/legacy-slide-toggle';
import { MatLegacySnackBarModule as MatSnackBarModule } from '@angular/material/legacy-snack-bar';
import { MatStepperModule } from '@angular/material/stepper';
2020-04-22 12:56:18 +02:00
import { TranslateModule } from '@ngx-translate/core';
import { NgChartsModule } from 'ng2-charts';
2020-05-01 19:10:17 +02:00
2020-05-12 19:16:23 +02:00
import { ChoiceDetailsComponent } from './components/choice-details/choice-details.component';
import { CommentsComponent } from './components/comments/comments.component';
2020-05-05 18:17:12 +02:00
import { FeedbackComponent } from './components/feedback/feedback.component';
2020-05-01 19:10:17 +02:00
import { PageNotFoundComponent } from './components/page-not-found/page-not-found.component';
2020-05-05 18:17:12 +02:00
import { LanguageSelectorComponent } from './components/selectors/language-selector/language-selector.component';
import { ThemeSelectorComponent } from './components/selectors/theme-selector/theme-selector.component';
import { SettingsComponent } from './components/settings/settings.component';
import { SpinnerComponent } from './components/spinner/spinner.component';
2020-11-13 09:38:42 +01:00
import { CopyTextComponent } from './components/ui/copy-text/copy-text.component';
import { ErasableInputComponent } from './components/ui/erasable-input/erasable-input.component';
import { WipTodoComponent } from './components/ui/wip-todo/wip-todo.component';
2021-05-04 09:33:28 +02:00
import { ErrorsListComponent } from '../features/shared/components/ui/form/errors-list/errors-list.component';
import { ShortcutsHelpComponent } from '../features/shared/components/ui/shortcuts-help/shortcuts-help.component';
2021-11-17 15:06:36 +01:00
import { ConfirmDialogModule } from 'primeng/confirmdialog';
import { ConfirmationService } from 'primeng/api';
2021-11-19 15:25:54 +01:00
import { AboutComponent } from '../features/shared/components/ui/static-pages/about/about.component';
import { RouterModule } from '@angular/router';
import { ChoiceButtonDinumComponent } from '../features/shared/components/choice-button-dinum/choice-button-dinum.component';
2022-02-08 13:44:17 +01:00
import { DialogModule } from 'primeng/dialog';
2022-02-09 11:30:22 +01:00
import { HeaderComponent } from '../core/components/header/header.component';
import { FooterComponent } from '../core/components/footer/footer.component';
import { SkipLinksComponent } from 'src/app/features/shared/components/rgaa/skip-links/skip-links.component';
2020-05-05 18:17:12 +02:00
const COMPONENTS = [
2021-11-19 15:25:54 +01:00
AboutComponent,
2020-05-12 19:16:23 +02:00
ChoiceDetailsComponent,
CommentsComponent,
FeedbackComponent,
2020-05-05 18:17:12 +02:00
LanguageSelectorComponent,
PageNotFoundComponent,
SettingsComponent,
SpinnerComponent,
ThemeSelectorComponent,
2020-11-13 09:38:42 +01:00
CopyTextComponent,
ErasableInputComponent,
2021-05-04 09:33:28 +02:00
ErrorsListComponent,
WipTodoComponent,
ShortcutsHelpComponent,
ChoiceButtonDinumComponent,
2022-02-09 11:30:22 +01:00
HeaderComponent,
FooterComponent,
];
const ANGULAR_MODULES = [CommonModule, NgChartsModule, FormsModule, TranslateModule];
const MATERIAL_MODULES = [
MatButtonModule,
MatCheckboxModule,
MatDatepickerModule,
MatDialogModule,
MatFormFieldModule,
MatInputModule,
MatProgressSpinnerModule,
MatSidenavModule,
MatSlideToggleModule,
MatSnackBarModule,
MatStepperModule,
2020-05-05 18:17:12 +02:00
];
@NgModule({
declarations: [COMPONENTS, SkipLinksComponent],
2022-02-08 13:44:17 +01:00
imports: [...ANGULAR_MODULES, ...MATERIAL_MODULES, ConfirmDialogModule, RouterModule, DialogModule],
exports: [...ANGULAR_MODULES, ...MATERIAL_MODULES, ...COMPONENTS, SkipLinksComponent],
2021-11-17 15:06:36 +01:00
providers: [ConfirmationService],
})
export class SharedModule {}