2 * Licensed to the Apache Software Foundation (ASF) under one
3 * or more contributor license agreements. See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership. The ASF licenses this file
6 * to you under the Apache License, Version 2.0 (the
7 * "License"); you may not use this file except in compliance
8 * with the License. You may obtain a copy of the License at
10 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing,
12 * software distributed under the License is distributed on an
13 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14 * KIND, either express or implied. See the License for the
15 * specific language governing permissions and limitations
19 import { NgModule } from '@angular/core';
20 import { CommonModule } from '@angular/common';
21 import {PaginatedEntitiesComponent} from "./paginated-entities/paginated-entities.component";
22 import {SortedTableHeaderComponent} from "./sorted-table-header/sorted-table-header.component";
23 import {SortedTableHeaderRowComponent} from "./sorted-table-header-row/sorted-table-header-row.component";
24 import {NgbPaginationModule, NgbTooltipModule} from "@ng-bootstrap/ng-bootstrap";
25 import {TranslateCompiler, TranslateLoader, TranslateModule} from "@ngx-translate/core";
26 import {TranslateMessageFormatCompiler} from "ngx-translate-messageformat-compiler";
27 import {HttpClient} from "@angular/common/http";
28 import {TranslateHttpLoader} from "@ngx-translate/http-loader";
29 import {RouterModule} from "@angular/router";
35 PaginatedEntitiesComponent,
36 SortedTableHeaderComponent,
37 SortedTableHeaderRowComponent
45 PaginatedEntitiesComponent,
46 SortedTableHeaderComponent,
47 SortedTableHeaderRowComponent
54 TranslateModule.forChild({
56 provide: TranslateCompiler,
57 useClass: TranslateMessageFormatCompiler
60 provide: TranslateLoader,
61 useFactory: httpTranslateLoader,
67 export class SharedModule { }
68 export function httpTranslateLoader(http: HttpClient) {
69 return new TranslateHttpLoader(http);