Merge branch 'ng10' into 'master'
Migration vers Angular 11 See merge request color-recipes-explorer/frontend!19
This commit is contained in:
commit
30d3becd0a
|
@ -46,7 +46,6 @@
|
|||
"optimization": true,
|
||||
"outputHashing": "all",
|
||||
"sourceMap": false,
|
||||
"extractCss": true,
|
||||
"namedChunks": false,
|
||||
"extractLicenses": true,
|
||||
"vendorChunk": false,
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
"compilerOptions": {
|
||||
"outDir": "../out-tsc/e2e",
|
||||
"module": "commonjs",
|
||||
"target": "es5",
|
||||
"target": "es2018",
|
||||
"types": [
|
||||
"jasmine",
|
||||
"jasminewd2",
|
||||
|
|
File diff suppressed because it is too large
Load Diff
54
package.json
54
package.json
|
@ -11,16 +11,16 @@
|
|||
},
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"@angular/animations": "~9.0.5",
|
||||
"@angular/cdk": "^9.2.4",
|
||||
"@angular/common": "~9.0.5",
|
||||
"@angular/compiler": "~9.0.5",
|
||||
"@angular/core": "~9.0.5",
|
||||
"@angular/forms": "~9.0.5",
|
||||
"@angular/material": "^9.2.4",
|
||||
"@angular/platform-browser": "~9.0.5",
|
||||
"@angular/platform-browser-dynamic": "~9.0.5",
|
||||
"@angular/router": "~9.0.5",
|
||||
"@angular/animations": "~11.2.10",
|
||||
"@angular/cdk": "^11.2.9",
|
||||
"@angular/common": "~11.2.10",
|
||||
"@angular/compiler": "~11.2.10",
|
||||
"@angular/core": "~11.2.10",
|
||||
"@angular/forms": "~11.2.10",
|
||||
"@angular/material": "^11.2.9",
|
||||
"@angular/platform-browser": "~11.2.10",
|
||||
"@angular/platform-browser-dynamic": "~11.2.10",
|
||||
"@angular/router": "~11.2.10",
|
||||
"@mdi/angular-material": "^5.7.55",
|
||||
"bootstrap": "^4.5.2",
|
||||
"copy-webpack-plugin": "^6.2.1",
|
||||
|
@ -28,28 +28,28 @@
|
|||
"material-design-icons": "^3.0.1",
|
||||
"ngx-material-file-input": "^2.1.1",
|
||||
"rxjs": "~6.5.4",
|
||||
"tslib": "^1.10.0",
|
||||
"tslib": "^2.0.0",
|
||||
"zone.js": "~0.10.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@angular-devkit/build-angular": "~0.900.5",
|
||||
"@angular/cli": "~9.0.5",
|
||||
"@angular/compiler-cli": "~9.0.5",
|
||||
"@angular/language-service": "~9.0.5",
|
||||
"@types/node": "^12.11.1",
|
||||
"@types/jasmine": "~3.5.0",
|
||||
"@angular-devkit/build-angular": "^0.1102.9",
|
||||
"@angular/cli": "~11.2.9",
|
||||
"@angular/compiler-cli": "~11.2.10",
|
||||
"@angular/language-service": "~11.2.10",
|
||||
"@types/jasmine": "~3.6.0",
|
||||
"@types/jasminewd2": "~2.0.3",
|
||||
"codelyzer": "^5.1.2",
|
||||
"jasmine-core": "~3.5.0",
|
||||
"jasmine-spec-reporter": "~4.2.1",
|
||||
"karma": "~4.3.0",
|
||||
"@types/node": "^12.11.1",
|
||||
"codelyzer": "^6.0.0",
|
||||
"jasmine-core": "~3.6.0",
|
||||
"jasmine-spec-reporter": "~5.0.0",
|
||||
"karma": "~6.3.2",
|
||||
"karma-chrome-launcher": "~3.1.0",
|
||||
"karma-coverage-istanbul-reporter": "~2.1.0",
|
||||
"karma-jasmine": "~2.0.1",
|
||||
"karma-jasmine-html-reporter": "^1.4.2",
|
||||
"protractor": "~5.4.3",
|
||||
"karma-coverage-istanbul-reporter": "~3.0.2",
|
||||
"karma-jasmine": "~4.0.0",
|
||||
"karma-jasmine-html-reporter": "^1.5.0",
|
||||
"protractor": "~7.0.0",
|
||||
"ts-node": "~8.3.0",
|
||||
"tslint": "~5.18.0",
|
||||
"typescript": "~3.7.5"
|
||||
"tslint": "~6.1.0",
|
||||
"typescript": "~4.0.7"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -41,7 +41,7 @@ const routes: Routes = [{
|
|||
{path: 'material', loadChildren: () => import('./modules/material/material.module').then(m => m.MaterialModule)}];
|
||||
|
||||
@NgModule({
|
||||
imports: [RouterModule.forRoot(routes)],
|
||||
imports: [RouterModule.forRoot(routes, { relativeLinkResolution: 'legacy' })],
|
||||
exports: [RouterModule]
|
||||
})
|
||||
export class AppRoutingModule {
|
||||
|
|
|
@ -1,11 +1,12 @@
|
|||
import {take, takeUntil} from 'rxjs/operators'
|
||||
import {OnDestroy, OnInit} from '@angular/core'
|
||||
import { OnDestroy, OnInit, Directive } from '@angular/core'
|
||||
import {Observable, Subject} from 'rxjs'
|
||||
import {ActivatedRoute, Router} from '@angular/router'
|
||||
import {UrlUtils} from '../utils/url.utils'
|
||||
import {ErrorHandler, ErrorHandlerComponent, ErrorService} from '../service/error.service'
|
||||
import {globalLoadingWheel} from './loading-wheel/loading-wheel.component'
|
||||
|
||||
@Directive()
|
||||
export abstract class SubscribingComponent implements OnInit, OnDestroy {
|
||||
protected subscribers$ = []
|
||||
protected destroy$ = new Subject<boolean>()
|
||||
|
@ -84,6 +85,7 @@ export abstract class SubscribingComponent implements OnInit, OnDestroy {
|
|||
}
|
||||
}
|
||||
|
||||
@Directive()
|
||||
export abstract class ErrorHandlingComponent extends SubscribingComponent implements ErrorHandlerComponent {
|
||||
errorHandlers: ErrorHandler[] = []
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import {Injectable, OnDestroy} from '@angular/core'
|
||||
import {Directive, Injectable, OnDestroy} from '@angular/core';
|
||||
import {interval, Subject} from 'rxjs'
|
||||
import {takeUntil} from 'rxjs/operators'
|
||||
|
||||
|
@ -37,6 +37,8 @@ export class AlertService {
|
|||
/**
|
||||
* An alert handler component is a component that will show the alerts pushed by the alert system to the user.
|
||||
*/
|
||||
@Directive()
|
||||
// tslint:disable-next-line:directive-class-suffix
|
||||
export abstract class AlertHandlerComponent implements OnDestroy {
|
||||
protected static readonly DEFAULT_ALERT_BUFFER_SIZE = 3
|
||||
protected static readonly DEFAULT_ALERT_DURATION = 5
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
export const environment = {
|
||||
production: false,
|
||||
apiUrl: 'http://localhost:9101/api'
|
||||
apiUrl: 'http://localhost:9090/api'
|
||||
};
|
||||
|
||||
/*
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
"declaration": false,
|
||||
"downlevelIteration": true,
|
||||
"experimentalDecorators": true,
|
||||
"module": "esnext",
|
||||
"module": "es2020",
|
||||
"moduleResolution": "node",
|
||||
"importHelpers": true,
|
||||
"target": "es2015",
|
||||
|
|
68
tslint.json
68
tslint.json
|
@ -1,13 +1,21 @@
|
|||
{
|
||||
"extends": "tslint:recommended",
|
||||
"rules": {
|
||||
"align": {
|
||||
"options": [
|
||||
"parameters",
|
||||
"statements"
|
||||
]
|
||||
},
|
||||
"array-type": false,
|
||||
"arrow-parens": false,
|
||||
"arrow-return-shorthand": true,
|
||||
"deprecation": {
|
||||
"severity": "warning"
|
||||
},
|
||||
"component-class-suffix": true,
|
||||
"contextual-lifecycle": true,
|
||||
"curly": true,
|
||||
"directive-class-suffix": true,
|
||||
"directive-selector": [
|
||||
true,
|
||||
|
@ -21,14 +29,21 @@
|
|||
"cre",
|
||||
"kebab-case"
|
||||
],
|
||||
"eofline": true,
|
||||
"import-blacklist": [
|
||||
true,
|
||||
"rxjs/Rx"
|
||||
],
|
||||
"import-spacing": true,
|
||||
"indent": {
|
||||
"options": [
|
||||
"spaces"
|
||||
]
|
||||
},
|
||||
"interface-name": false,
|
||||
"max-classes-per-file": false,
|
||||
"max-line-length": [
|
||||
true,
|
||||
false,
|
||||
140
|
||||
],
|
||||
"member-access": false,
|
||||
|
@ -80,12 +95,59 @@
|
|||
"no-output-on-prefix": true,
|
||||
"no-output-rename": true,
|
||||
"no-outputs-metadata-property": true,
|
||||
"space-before-function-paren": {
|
||||
"options": {
|
||||
"anonymous": "never",
|
||||
"asyncArrow": "always",
|
||||
"constructor": "never",
|
||||
"method": "never",
|
||||
"named": "never"
|
||||
}
|
||||
},
|
||||
"template-banana-in-box": true,
|
||||
"template-no-negated-async": true,
|
||||
"use-lifecycle-interface": true,
|
||||
"use-pipe-transform-interface": true
|
||||
"use-pipe-transform-interface": true,
|
||||
"typedef-whitespace": {
|
||||
"options": [
|
||||
{
|
||||
"call-signature": "nospace",
|
||||
"index-signature": "nospace",
|
||||
"parameter": "nospace",
|
||||
"property-declaration": "nospace",
|
||||
"variable-declaration": "nospace"
|
||||
},
|
||||
{
|
||||
"call-signature": "onespace",
|
||||
"index-signature": "onespace",
|
||||
"parameter": "onespace",
|
||||
"property-declaration": "onespace",
|
||||
"variable-declaration": "onespace"
|
||||
}
|
||||
]
|
||||
},
|
||||
"semicolon": [false, "never"],
|
||||
"triple-equals": false,
|
||||
"variable-name": {
|
||||
"options": [
|
||||
"ban-keywords",
|
||||
"check-format",
|
||||
"allow-pascal-case"
|
||||
]
|
||||
},
|
||||
"whitespace": {
|
||||
"options": [
|
||||
"check-branch",
|
||||
"check-decl",
|
||||
"check-operator",
|
||||
"check-separator",
|
||||
"check-type",
|
||||
"check-typecast"
|
||||
]
|
||||
},
|
||||
"ban-types": false
|
||||
},
|
||||
"rulesDirectory": [
|
||||
"codelyzer"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue