feat: angular 7+ update (#1910)

Closes #1890

BREAKING CHANGES:
Angular 7+ now required.
The following libraries were updated:
- @agm/core
- @ng-bootstrap/ng-bootstrap
- @swimlane/ngx-charts
- ng2-ckeditor
- ngx-echarts
This commit is contained in:
Nikita Poltoratsky 2018-11-19 15:40:01 +02:00 committed by Dmitry Nehaychik
parent 3f422db62e
commit aa7579ccd6
13 changed files with 4568 additions and 1504 deletions

5979
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -34,27 +34,27 @@
"release:changelog": "npm run conventional-changelog -- -p angular -i CHANGELOG.md -s" "release:changelog": "npm run conventional-changelog -- -p angular -i CHANGELOG.md -s"
}, },
"dependencies": { "dependencies": {
"@agm/core": "1.0.0-beta.2", "@agm/core": "^1.0.0-beta.5",
"@angular/animations": "6.0.0", "@angular/animations": "^7.0.3",
"@angular/cdk": "^6.4.7", "@angular/cdk": "^7.0.3",
"@angular/common": "6.0.0", "@angular/common": "^7.0.3",
"@angular/compiler": "6.0.0", "@angular/compiler": "^7.0.3",
"@angular/core": "6.0.0", "@angular/core": "^7.0.3",
"@angular/forms": "6.0.0", "@angular/forms": "^7.0.3",
"@angular/http": "6.0.0", "@angular/http": "^7.0.3",
"@angular/platform-browser": "6.0.0", "@angular/platform-browser": "^7.0.3",
"@angular/platform-browser-dynamic": "6.0.0", "@angular/platform-browser-dynamic": "^7.0.3",
"@angular/router": "6.0.0", "@angular/router": "^7.0.3",
"@asymmetrik/ngx-leaflet": "3.0.1", "@asymmetrik/ngx-leaflet": "3.0.1",
"@nebular/auth": "2.0.1", "@nebular/auth": "2.0.1",
"@nebular/bootstrap": "2.0.1", "@nebular/bootstrap": "2.0.1",
"@nebular/security": "2.0.1", "@nebular/security": "2.0.1",
"@nebular/theme": "2.0.1", "@nebular/theme": "2.0.1",
"@ng-bootstrap/ng-bootstrap": "1.0.0", "@ng-bootstrap/ng-bootstrap": "^4.0.0",
"@swimlane/ngx-charts": "7.0.1", "@swimlane/ngx-charts": "^10.0.0",
"angular-tree-component": "7.2.0", "angular-tree-component": "7.2.0",
"angular2-chartjs": "0.4.1", "angular2-chartjs": "0.4.1",
"angular2-toaster": "6.0.0", "angular2-toaster": "^6.1.0",
"bootstrap": "4.0.0", "bootstrap": "4.0.0",
"chart.js": "2.7.1", "chart.js": "2.7.1",
"ckeditor": "4.7.3", "ckeditor": "4.7.3",
@ -65,15 +65,15 @@
"ionicons": "2.0.1", "ionicons": "2.0.1",
"leaflet": "1.2.0", "leaflet": "1.2.0",
"nebular-icons": "1.0.9", "nebular-icons": "1.0.9",
"ng2-ckeditor": "1.1.13", "ng2-ckeditor": "^1.2.2",
"ng2-completer": "2.0.8", "ng2-completer": "2.0.8",
"ng2-smart-table": "1.3.5", "ng2-smart-table": "1.3.5",
"ngx-echarts": "2.0.1", "ngx-echarts": "^4.0.1",
"normalize.css": "6.0.0", "normalize.css": "6.0.0",
"pace-js": "1.0.2", "pace-js": "1.0.2",
"roboto-fontface": "0.8.0", "roboto-fontface": "0.8.0",
"rxjs": "^6.1.0", "rxjs": "6.3.0",
"rxjs-compat": "^6.1.0", "rxjs-compat": "6.3.0",
"socicon": "3.0.5", "socicon": "3.0.5",
"tinymce": "4.5.7", "tinymce": "4.5.7",
"typeface-exo": "0.0.22", "typeface-exo": "0.0.22",
@ -81,18 +81,19 @@
"zone.js": "^0.8.26" "zone.js": "^0.8.26"
}, },
"devDependencies": { "devDependencies": {
"@angular/cli": "6.0.0", "@angular-devkit/build-angular": "0.10.2",
"@angular/compiler-cli": "6.0.0", "@angular/compiler-cli": "^7.0.3",
"@angular/language-service": "6.0.0", "@angular/cli": "^7.0.3",
"@angular/language-service": "7.0.0",
"@compodoc/compodoc": "1.0.1", "@compodoc/compodoc": "1.0.1",
"@fortawesome/fontawesome-free": "^5.2.0", "@fortawesome/fontawesome-free": "^5.2.0",
"@types/d3-color": "1.0.5", "@types/d3-color": "1.0.5",
"@types/googlemaps": "3.30.4", "@types/googlemaps": "^3.30.4",
"@types/jasmine": "2.5.54", "@types/jasmine": "2.5.54",
"@types/jasminewd2": "2.0.3", "@types/jasminewd2": "2.0.3",
"@types/leaflet": "1.2.3", "@types/leaflet": "1.2.3",
"@types/node": "6.0.90", "@types/node": "6.0.90",
"codelyzer": "4.0.2", "codelyzer": "^4.5.0",
"conventional-changelog-cli": "1.3.4", "conventional-changelog-cli": "1.3.4",
"husky": "0.13.3", "husky": "0.13.3",
"jasmine-core": "2.6.4", "jasmine-core": "2.6.4",
@ -109,8 +110,7 @@
"stylelint": "7.13.0", "stylelint": "7.13.0",
"ts-node": "3.2.2", "ts-node": "3.2.2",
"tslint": "5.7.0", "tslint": "5.7.0",
"tslint-language-service": "0.9.6", "tslint-language-service": "^0.9.9",
"typescript": "2.7.2", "typescript": "3.1.3"
"@angular-devkit/build-angular": "~0.6.0"
} }
} }

View file

@ -1,6 +1,6 @@
import { Component, OnDestroy, Input } from '@angular/core'; import { Component, OnDestroy, Input } from '@angular/core';
import { NbLayoutDirectionService, NbLayoutDirection } from '@nebular/theme'; import { NbLayoutDirectionService, NbLayoutDirection } from '@nebular/theme';
import { takeWhile } from 'rxjs/operators/takeWhile'; import { takeWhile } from 'rxjs/operators';
@Component({ @Component({
selector: 'ngx-layout-direction-switcher', selector: 'ngx-layout-direction-switcher',

View file

@ -1,6 +1,6 @@
import { Component, OnDestroy } from '@angular/core'; import { Component, OnDestroy } from '@angular/core';
import { NbThemeService } from '@nebular/theme'; import { NbThemeService } from '@nebular/theme';
import { takeWhile } from 'rxjs/operators/takeWhile'; import { takeWhile } from 'rxjs/operators';
// TODO: move layouts into the framework // TODO: move layouts into the framework
@Component({ @Component({

View file

@ -1,6 +1,6 @@
import { Component, OnDestroy } from '@angular/core'; import { Component, OnDestroy } from '@angular/core';
import { NbThemeService } from '@nebular/theme'; import { NbThemeService } from '@nebular/theme';
import { takeWhile } from 'rxjs/operators/takeWhile'; import { takeWhile } from 'rxjs/operators';
// TODO: move layouts into the framework // TODO: move layouts into the framework
@Component({ @Component({

View file

@ -1,6 +1,6 @@
import { Component, OnDestroy } from '@angular/core'; import { Component, OnDestroy } from '@angular/core';
import { NbThemeService } from '@nebular/theme'; import { NbThemeService } from '@nebular/theme';
import { takeWhile } from 'rxjs/operators/takeWhile'; import { takeWhile } from 'rxjs/operators';
// TODO: move layouts into the framework // TODO: move layouts into the framework
@Component({ @Component({

View file

@ -1,6 +1,6 @@
import {Component, OnDestroy} from '@angular/core'; import {Component, OnDestroy} from '@angular/core';
import { NbThemeService } from '@nebular/theme'; import { NbThemeService } from '@nebular/theme';
import { takeWhile } from 'rxjs/operators/takeWhile' ; import { takeWhile } from 'rxjs/operators' ;
interface CardSettings { interface CardSettings {
title: string; title: string;

View file

@ -22,7 +22,7 @@ export class TemperatureDraggerComponent implements AfterViewInit, OnChanges {
@Input() maxLeap = 0.4; @Input() maxLeap = 0.4;
value = 50; value = 50;
@Output('valueChange') valueChange = new EventEmitter<Number>(); @Output() valueChange = new EventEmitter<Number>();
@Input('value') set setValue(value) { @Input('value') set setValue(value) {
this.value = value; this.value = value;
} }

View file

@ -1,6 +1,6 @@
import { Injectable } from '@angular/core'; import { Injectable } from '@angular/core';
import { HttpClient } from '@angular/common/http'; import { HttpClient } from '@angular/common/http';
import { Observable } from 'rxjs/Observable'; import { Observable } from 'rxjs';
@Injectable() @Injectable()

View file

@ -1,9 +1,8 @@
import { Component, Input, OnDestroy, OnInit } from '@angular/core'; import { Component, Input, OnDestroy, OnInit } from '@angular/core';
import { NbThemeService } from '@nebular/theme'; import { NbThemeService } from '@nebular/theme';
import { interval } from 'rxjs'; import { interval , Subscription } from 'rxjs';
import { switchMap, takeWhile } from 'rxjs/operators'; import { switchMap, takeWhile } from 'rxjs/operators';
import { EarningService, LiveUpdateChart } from '../../../../@core/data/earning.service'; import { EarningService, LiveUpdateChart } from '../../../../@core/data/earning.service';
import { Subscription } from 'rxjs/Subscription';
@Component({ @Component({
selector: 'ngx-earning-card-front', selector: 'ngx-earning-card-front',

View file

@ -2,8 +2,8 @@ import { Component, OnDestroy } from '@angular/core';
import { HttpClient } from '@angular/common/http'; import { HttpClient } from '@angular/common/http';
import { combineLatest } from 'rxjs'; import { combineLatest } from 'rxjs';
import { takeWhile } from 'rxjs/operators'; import { takeWhile } from 'rxjs/operators';
import { NgxEchartsService } from 'ngx-echarts';
import { NbThemeService } from '@nebular/theme'; import { NbThemeService } from '@nebular/theme';
import { registerMap } from 'echarts';
@Component({ @Component({
selector: 'ngx-bubble-map', selector: 'ngx-bubble-map',
@ -31,8 +31,7 @@ export class BubbleMapComponent implements OnDestroy {
private alive = true; private alive = true;
constructor(private theme: NbThemeService, constructor(private theme: NbThemeService,
private http: HttpClient, private http: HttpClient) {
private es: NgxEchartsService) {
combineLatest([ combineLatest([
this.http.get('assets/map/world.json'), this.http.get('assets/map/world.json'),
@ -41,7 +40,7 @@ export class BubbleMapComponent implements OnDestroy {
.pipe(takeWhile(() => this.alive)) .pipe(takeWhile(() => this.alive))
.subscribe(([map, config]: [any, any]) => { .subscribe(([map, config]: [any, any]) => {
this.es.registerMap('world', map); registerMap('world', map);
const colors = config.variables; const colors = config.variables;
this.bubbleTheme = config.variables.bubbleMap; this.bubbleTheme = config.variables.bubbleMap;

View file

@ -1,7 +1,7 @@
import { Component, ElementRef, EventEmitter, NgZone, OnInit, Output, ViewChild } from '@angular/core'; import { Component, ElementRef, EventEmitter, NgZone, OnInit, Output, ViewChild } from '@angular/core';
import { MapsAPILoader } from '@agm/core'; import { MapsAPILoader } from '@agm/core';
import { Location } from '../entity/Location'; import { Location } from '../entity/Location';
import {} from 'googlemaps';
@Component({ @Component({
selector: 'ngx-search', selector: 'ngx-search',

View file

@ -4,7 +4,6 @@
"outDir": "../out-tsc/app", "outDir": "../out-tsc/app",
"module": "es2015", "module": "es2015",
"baseUrl": "./", "baseUrl": "./",
"types": [],
"paths": { "paths": {
"@angular/*": [ "@angular/*": [
"../node_modules/@angular/*" "../node_modules/@angular/*"