mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
[ADF-859] add codelyzer in core and datatable (#2056)
* add codelyzer in core and datatable * add codelyzer in the main build * order imports * fix import in test * fix import test * import reorder form * tasklist and processlist import reorder
This commit is contained in:
committed by
Eugenio Romano
parent
9870964c0e
commit
53a614bfbf
@@ -39,7 +39,8 @@ module.exports = {
|
||||
loader: 'tslint-loader',
|
||||
options: {
|
||||
emitErrors: true,
|
||||
failOnHint: true
|
||||
failOnHint: true,
|
||||
fix:true
|
||||
},
|
||||
exclude: [/node_modules/, /bundles/, /dist/, /demo/]
|
||||
},
|
||||
|
@@ -15,57 +15,58 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { NgModule, ModuleWithProviders } from '@angular/core';
|
||||
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
||||
import { HttpModule, Http } from '@angular/http';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { ModuleWithProviders, NgModule } from '@angular/core';
|
||||
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
||||
import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
|
||||
import { Http, HttpModule } from '@angular/http';
|
||||
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
||||
import { TranslateLoader, TranslateModule } from '@ngx-translate/core';
|
||||
|
||||
import { MaterialModule } from './src/material.module';
|
||||
import { ContextMenuModule } from './src/components/context-menu/context-menu.module';
|
||||
import { CardViewModule } from './src/components/view/card-view.module';
|
||||
import { CollapsableModule } from './src/components/collapsable/collapsable.module';
|
||||
import { ContextMenuModule } from './src/components/context-menu/context-menu.module';
|
||||
import { AdfToolbarComponent } from './src/components/toolbar/toolbar.component';
|
||||
import { CardViewModule } from './src/components/view/card-view.module';
|
||||
import { MaterialModule } from './src/material.module';
|
||||
import { AppConfigModule } from './src/services/app-config.service';
|
||||
import { UserPreferencesService } from './src/services/user-preferences.service';
|
||||
|
||||
import {
|
||||
AlfrescoApiService,
|
||||
AlfrescoAuthenticationService,
|
||||
AlfrescoContentService,
|
||||
AlfrescoSettingsService,
|
||||
StorageService,
|
||||
CookieService,
|
||||
AlfrescoApiService,
|
||||
AlfrescoTranslateLoader,
|
||||
AlfrescoTranslationService,
|
||||
RenditionsService,
|
||||
AppConfigService,
|
||||
AuthGuard,
|
||||
AuthGuardEcm,
|
||||
AuthGuardBpm,
|
||||
AuthGuardEcm,
|
||||
ContentService,
|
||||
CookieService,
|
||||
InitAppConfigServiceProvider,
|
||||
LogService,
|
||||
LogServiceMock,
|
||||
NotificationService,
|
||||
ContentService,
|
||||
AppConfigService,
|
||||
InitAppConfigServiceProvider,
|
||||
RenditionsService,
|
||||
StorageService,
|
||||
ThumbnailService
|
||||
} from './src/services/index';
|
||||
|
||||
import { FileSizePipe } from './src/pipes/file-size.pipe';
|
||||
import { UploadDirective } from './src/directives/upload.directive';
|
||||
import { DataColumnComponent } from './src/components/data-column/data-column.component';
|
||||
import { DataColumnListComponent } from './src/components/data-column/data-column-list.component';
|
||||
import { DataColumnComponent } from './src/components/data-column/data-column.component';
|
||||
import { UploadDirective } from './src/directives/upload.directive';
|
||||
import { FileSizePipe } from './src/pipes/file-size.pipe';
|
||||
|
||||
import { MDL } from './src/components/material/mdl-upgrade-element.directive';
|
||||
import { AlfrescoMdlButtonDirective } from './src/components/material/mdl-button.directive';
|
||||
import { AlfrescoMdlMenuDirective } from './src/components/material/mdl-menu.directive';
|
||||
import { AlfrescoMdlTextFieldDirective } from './src/components/material/mdl-textfield.directive';
|
||||
import { AlfrescoMdlTooltipDirective } from './src/components/material/mdl-tooltip.directive';
|
||||
import { MDLDirective } from './src/components/material/mdl-upgrade-element.directive';
|
||||
|
||||
export { ContextMenuModule } from './src/components/context-menu/context-menu.module';
|
||||
export { CardViewModule } from './src/components/view/card-view.module';
|
||||
export { CollapsableModule } from './src/components/collapsable/collapsable.module';
|
||||
export { UserPreferencesService } from './src/services/user-preferences.service';
|
||||
export * from './src/services/index';
|
||||
export * from './src/components/data-column/data-column.component';
|
||||
export * from './src/components/data-column/data-column-list.component';
|
||||
@@ -75,7 +76,6 @@ export * from './src/events/base.event';
|
||||
export * from './src/events/base-ui.event';
|
||||
export * from './src/events/folder-created.event';
|
||||
export * from './src/models/index';
|
||||
export { UserPreferencesService } from './src/services/user-preferences.service';
|
||||
|
||||
export * from './src/models/index';
|
||||
|
||||
|
40
ng2-components/ng2-alfresco-core/package-lock.json
generated
40
ng2-components/ng2-alfresco-core/package-lock.json
generated
@@ -247,6 +247,12 @@
|
||||
"integrity": "sha1-o+Uvo5FoyCX/V7AkgSbOWo/5VQc=",
|
||||
"dev": true
|
||||
},
|
||||
"app-root-path": {
|
||||
"version": "2.0.1",
|
||||
"resolved": "https://registry.npmjs.org/app-root-path/-/app-root-path-2.0.1.tgz",
|
||||
"integrity": "sha1-zWLc+OT9WkF+/GZNLlsQZTxlG0Y=",
|
||||
"dev": true
|
||||
},
|
||||
"aproba": {
|
||||
"version": "1.1.2",
|
||||
"resolved": "https://registry.npmjs.org/aproba/-/aproba-1.1.2.tgz",
|
||||
@@ -953,6 +959,20 @@
|
||||
"integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=",
|
||||
"dev": true
|
||||
},
|
||||
"codelyzer": {
|
||||
"version": "3.1.2",
|
||||
"resolved": "https://registry.npmjs.org/codelyzer/-/codelyzer-3.1.2.tgz",
|
||||
"integrity": "sha1-n/HwQfubXuXb60W6hm368EmDrwQ=",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"css-selector-tokenizer": {
|
||||
"version": "0.7.0",
|
||||
"resolved": "https://registry.npmjs.org/css-selector-tokenizer/-/css-selector-tokenizer-0.7.0.tgz",
|
||||
"integrity": "sha1-5piEdK6MlTR3v15+/s/OzNnPTIY=",
|
||||
"dev": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"color": {
|
||||
"version": "0.11.4",
|
||||
"resolved": "https://registry.npmjs.org/color/-/color-0.11.4.tgz",
|
||||
@@ -1286,6 +1306,12 @@
|
||||
"integrity": "sha1-lGfQMsOM+u+58teVASUwYvh/ob0=",
|
||||
"dev": true
|
||||
},
|
||||
"cssauron": {
|
||||
"version": "1.4.0",
|
||||
"resolved": "https://registry.npmjs.org/cssauron/-/cssauron-1.4.0.tgz",
|
||||
"integrity": "sha1-pmAt/34EqDBtwNuaVR6S6LVmKtg=",
|
||||
"dev": true
|
||||
},
|
||||
"cssesc": {
|
||||
"version": "0.1.0",
|
||||
"resolved": "https://registry.npmjs.org/cssesc/-/cssesc-0.1.0.tgz",
|
||||
@@ -5879,6 +5905,20 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"semver-dsl": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/semver-dsl/-/semver-dsl-1.0.1.tgz",
|
||||
"integrity": "sha1-02eN5VVeimH2Ke7QJTZq5fJzQKA=",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"semver": {
|
||||
"version": "5.3.0",
|
||||
"resolved": "https://registry.npmjs.org/semver/-/semver-5.3.0.tgz",
|
||||
"integrity": "sha1-myzl094C0XxgEq0yaqa00M9U+U8=",
|
||||
"dev": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"send": {
|
||||
"version": "0.15.3",
|
||||
"resolved": "https://registry.npmjs.org/send/-/send-0.15.3.tgz",
|
||||
|
@@ -70,6 +70,7 @@
|
||||
"@types/node": "6.0.45",
|
||||
"angular2-template-loader": "0.6.2",
|
||||
"autoprefixer": "6.5.4",
|
||||
"codelyzer": "3.1.2",
|
||||
"copy-webpack-plugin": "4.0.1",
|
||||
"css-loader": "0.23.1",
|
||||
"css-to-string-loader": "0.1.2",
|
||||
|
@@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { ComponentFixture, TestBed, async } from '@angular/core/testing';
|
||||
import { AccordionComponent } from './accordion.component';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { AccordionGroupComponent } from './accordion-group.component';
|
||||
import { AccordionComponent } from './accordion.component';
|
||||
|
||||
describe('AccordionGroupComponent', () => {
|
||||
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Component, Input, OnDestroy, Output, EventEmitter, ViewChild } from '@angular/core';
|
||||
import { Component, EventEmitter, Input, OnDestroy, Output, ViewChild } from '@angular/core';
|
||||
import { AccordionComponent } from './accordion.component';
|
||||
|
||||
@Component({
|
||||
|
@@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { ComponentFixture, TestBed, async } from '@angular/core/testing';
|
||||
import { AccordionComponent } from './accordion.component';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { AccordionGroupComponent } from './accordion-group.component';
|
||||
import { AccordionComponent } from './accordion.component';
|
||||
|
||||
describe('AccordionComponent', () => {
|
||||
|
||||
|
@@ -15,11 +15,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { NgModule } from '@angular/core';
|
||||
|
||||
import { AccordionComponent } from './accordion.component';
|
||||
import { AccordionGroupComponent } from './accordion-group.component';
|
||||
import { AccordionComponent } from './accordion.component';
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
|
@@ -15,8 +15,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { ContextMenuService } from './context-menu.service';
|
||||
import { ContextMenuHolderComponent } from './context-menu-holder.component';
|
||||
import { ContextMenuService } from './context-menu.service';
|
||||
|
||||
describe('ContextMenuHolderComponent', () => {
|
||||
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Directive, Input, HostListener } from '@angular/core';
|
||||
import { Directive, HostListener, Input } from '@angular/core';
|
||||
import { ContextMenuService } from './context-menu.service';
|
||||
|
||||
@Directive({
|
||||
|
@@ -15,8 +15,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { NgModule } from '@angular/core';
|
||||
|
||||
import { ContextMenuHolderComponent } from './context-menu-holder.component';
|
||||
import { ContextMenuDirective } from './context-menu.directive';
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async } from '@angular/core/testing';
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { DataColumnListComponent } from './data-column-list.component';
|
||||
|
||||
describe('DataColumnListComponent', () => {
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async } from '@angular/core/testing';
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { DataColumnComponent } from './data-column.component';
|
||||
|
||||
describe('DataColumnListComponent', () => {
|
||||
|
@@ -15,13 +15,13 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Component, Input, ContentChild, TemplateRef } from '@angular/core';
|
||||
import { Component, ContentChild, Input, OnInit, TemplateRef } from '@angular/core';
|
||||
|
||||
@Component({
|
||||
selector: 'data-column',
|
||||
template: ''
|
||||
})
|
||||
export class DataColumnComponent {
|
||||
export class DataColumnComponent implements OnInit {
|
||||
|
||||
@Input()
|
||||
key: string;
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Directive, ElementRef, AfterViewInit } from '@angular/core';
|
||||
import { AfterViewInit, Directive, ElementRef } from '@angular/core';
|
||||
|
||||
declare var componentHandler;
|
||||
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Directive, ElementRef, AfterViewInit } from '@angular/core';
|
||||
import { AfterViewInit, Directive, ElementRef } from '@angular/core';
|
||||
|
||||
declare var componentHandler;
|
||||
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Directive, ElementRef, AfterViewInit } from '@angular/core';
|
||||
import { AfterViewInit, Directive, ElementRef } from '@angular/core';
|
||||
|
||||
declare var componentHandler;
|
||||
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Directive, ElementRef, AfterViewInit } from '@angular/core';
|
||||
import { AfterViewInit, Directive, ElementRef } from '@angular/core';
|
||||
|
||||
declare var componentHandler;
|
||||
|
||||
|
@@ -15,13 +15,13 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Directive, AfterViewInit } from '@angular/core';
|
||||
import { AfterViewInit, Directive } from '@angular/core';
|
||||
declare var componentHandler;
|
||||
|
||||
@Directive({
|
||||
selector: '[mdl]'
|
||||
})
|
||||
export class MDL implements AfterViewInit {
|
||||
export class MDLDirective implements AfterViewInit {
|
||||
ngAfterViewInit() {
|
||||
componentHandler.upgradeAllRegistered();
|
||||
}
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Component, Input, ChangeDetectionStrategy, ViewEncapsulation } from '@angular/core';
|
||||
import { ChangeDetectionStrategy, Component, Input, ViewEncapsulation } from '@angular/core';
|
||||
|
||||
@Component({
|
||||
selector: 'adf-toolbar',
|
||||
|
@@ -15,20 +15,20 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { ComponentFixture, TestBed, async } from '@angular/core/testing';
|
||||
import { CardView } from './adf-card-view.component';
|
||||
import { CardViewModel } from '../../models/card-view.model';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { By } from '@angular/platform-browser';
|
||||
import { CardViewModel } from '../../models/card-view.model';
|
||||
import { CardViewComponent } from './adf-card-view.component';
|
||||
|
||||
describe('AdfCardView', () => {
|
||||
|
||||
let fixture: ComponentFixture<CardView>;
|
||||
let component: CardView;
|
||||
let fixture: ComponentFixture<CardViewComponent>;
|
||||
let component: CardViewComponent;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [
|
||||
CardView
|
||||
CardViewComponent
|
||||
],
|
||||
providers: [
|
||||
]
|
||||
@@ -36,7 +36,7 @@ describe('AdfCardView', () => {
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(CardView);
|
||||
fixture = TestBed.createComponent(CardViewComponent);
|
||||
component = fixture.componentInstance;
|
||||
});
|
||||
|
||||
|
@@ -16,15 +16,15 @@
|
||||
*/
|
||||
|
||||
import { Component, Input } from '@angular/core';
|
||||
import { CardViewModel } from '../../models/card-view.model';
|
||||
import * as moment from 'moment';
|
||||
import { CardViewModel } from '../../models/card-view.model';
|
||||
|
||||
@Component({
|
||||
selector: 'adf-card-view',
|
||||
templateUrl: './adf-card-view.component.html',
|
||||
styleUrls: ['./adf-card-view.component.css']
|
||||
})
|
||||
export class CardView {
|
||||
export class CardViewComponent {
|
||||
|
||||
@Input()
|
||||
properties: CardViewModel [];
|
||||
|
@@ -15,19 +15,19 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { CardView } from './adf-card-view.component';
|
||||
import { NgModule } from '@angular/core';
|
||||
import { CardViewComponent } from './adf-card-view.component';
|
||||
|
||||
@NgModule({
|
||||
imports: [
|
||||
CommonModule
|
||||
],
|
||||
declarations: [
|
||||
CardView
|
||||
CardViewComponent
|
||||
],
|
||||
exports: [
|
||||
CardView
|
||||
CardViewComponent
|
||||
]
|
||||
})
|
||||
export class CardViewModule {}
|
||||
|
@@ -16,8 +16,8 @@
|
||||
*/
|
||||
|
||||
import { ElementRef } from '@angular/core';
|
||||
import { UploadDirective } from './upload.directive';
|
||||
import { FileInfo } from './../utils/file-utils';
|
||||
import { UploadDirective } from './upload.directive';
|
||||
|
||||
describe('UploadDirective', () => {
|
||||
|
||||
|
@@ -15,8 +15,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Directive, Input, HostListener, ElementRef, Renderer, OnInit, NgZone, OnDestroy } from '@angular/core';
|
||||
import { FileUtils, FileInfo } from '../utils/file-utils';
|
||||
import { Directive, ElementRef, HostListener, Input, NgZone, OnDestroy, OnInit, Renderer } from '@angular/core';
|
||||
import { FileInfo, FileUtils } from '../utils/file-utils';
|
||||
|
||||
@Directive({
|
||||
selector: '[adf-upload]'
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
import { NgModule } from '@angular/core';
|
||||
import { MdSnackBarModule, MdToolbarModule, MdButtonModule } from '@angular/material';
|
||||
import { MdButtonModule, MdSnackBarModule, MdToolbarModule } from '@angular/material';
|
||||
|
||||
export function modules() {
|
||||
return [
|
||||
|
@@ -16,8 +16,8 @@
|
||||
*/
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import { AlfrescoApi } from 'alfresco-js-api';
|
||||
import * as alfrescoApi from 'alfresco-js-api';
|
||||
import { AlfrescoApi } from 'alfresco-js-api';
|
||||
import * as alfrescoApi from 'alfresco-js-api';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigService } from './app-config.service';
|
||||
import { StorageService } from './storage.service';
|
||||
|
@@ -15,15 +15,15 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async } from '@angular/core/testing';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { CookieServiceMock } from './../assets/cookie.service.mock';
|
||||
import { LogService } from './log.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { LogService } from './log.service';
|
||||
import { StorageService } from './storage.service';
|
||||
|
||||
declare let jasmine: any;
|
||||
|
||||
|
@@ -17,11 +17,11 @@
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable, Subject } from 'rxjs/Rx';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { LogService } from './log.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { StorageService } from './storage.service';
|
||||
|
||||
const REMEMBER_ME_COOKIE_KEY = 'ALFRESCO_REMEMBER_ME';
|
||||
const REMEMBER_ME_UNTIL = 1000 * 60 * 60 * 24 * 30 ;
|
||||
|
@@ -15,16 +15,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async } from '@angular/core/testing';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { CookieServiceMock } from './../assets/cookie.service.mock';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoContentService } from './alfresco-content.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { CookieServiceMock } from './../assets/cookie.service.mock';
|
||||
import { LogService } from './log.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { LogService } from './log.service';
|
||||
import { StorageService } from './storage.service';
|
||||
|
||||
declare let jasmine: any;
|
||||
|
||||
|
@@ -17,10 +17,10 @@
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable, Subject } from 'rxjs/Rx';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { LogService } from './log.service';
|
||||
import { FolderCreatedEvent } from '../events/folder-created.event';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { LogService } from './log.service';
|
||||
|
||||
@Injectable()
|
||||
export class AlfrescoContentService {
|
||||
|
@@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async } from '@angular/core/testing';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
|
||||
describe('AlfrescoSettingsService', () => {
|
||||
|
||||
|
@@ -16,9 +16,9 @@
|
||||
*/
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Response, Http } from '@angular/http';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Http, Response } from '@angular/http';
|
||||
import { TranslateLoader } from '@ngx-translate/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { ComponentTranslationModel } from '../models/component.model';
|
||||
import { LogService } from './log.service';
|
||||
|
||||
|
@@ -15,11 +15,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
|
||||
import { Injector } from '@angular/core';
|
||||
import { ResponseOptions, Response, XHRBackend, HttpModule } from '@angular/http';
|
||||
import { MockBackend, MockConnection } from '@angular/http/testing';
|
||||
import {getTestBed, TestBed} from '@angular/core/testing';
|
||||
import { HttpModule, Response, ResponseOptions, XHRBackend } from '@angular/http';
|
||||
import { MockBackend, MockConnection } from '@angular/http/testing';
|
||||
import { TranslateLoader, TranslateModule } from '@ngx-translate/core';
|
||||
|
||||
import { AlfrescoTranslateLoader } from './alfresco-translate-loader.service';
|
||||
import { AlfrescoTranslationService } from './alfresco-translation.service';
|
||||
|
@@ -15,14 +15,14 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
|
||||
import { Injector } from '@angular/core';
|
||||
import { ResponseOptions, Response, XHRBackend, HttpModule } from '@angular/http';
|
||||
import { MockBackend, MockConnection } from '@angular/http/testing';
|
||||
import { getTestBed, TestBed } from '@angular/core/testing';
|
||||
import { HttpModule, Response, ResponseOptions, XHRBackend } from '@angular/http';
|
||||
import { MockBackend, MockConnection } from '@angular/http/testing';
|
||||
import { TranslateLoader, TranslateModule } from '@ngx-translate/core';
|
||||
|
||||
import { AlfrescoTranslationService } from './alfresco-translation.service';
|
||||
import { AlfrescoTranslateLoader } from './alfresco-translate-loader.service';
|
||||
import { AlfrescoTranslationService } from './alfresco-translation.service';
|
||||
import { LogService } from './log.service';
|
||||
|
||||
const mockBackendResponse = (connection: MockConnection, response: string) => {
|
||||
|
@@ -16,8 +16,8 @@
|
||||
*/
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { AlfrescoTranslateLoader } from './alfresco-translate-loader.service';
|
||||
|
||||
@Injectable()
|
||||
|
@@ -15,8 +15,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, inject } from '@angular/core/testing';
|
||||
import { HttpModule, XHRBackend, Response, ResponseOptions } from '@angular/http';
|
||||
import { inject, TestBed } from '@angular/core/testing';
|
||||
import { HttpModule, Response, ResponseOptions, XHRBackend } from '@angular/http';
|
||||
import { MockBackend, MockConnection } from '@angular/http/testing';
|
||||
import { AppConfigModule, AppConfigService } from './app-config.service';
|
||||
|
||||
|
@@ -15,8 +15,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Injectable, APP_INITIALIZER, NgModule, ModuleWithProviders } from '@angular/core';
|
||||
import { HttpModule, Http } from '@angular/http';
|
||||
import { APP_INITIALIZER, Injectable, ModuleWithProviders, NgModule } from '@angular/core';
|
||||
import { Http, HttpModule } from '@angular/http';
|
||||
import { ObjectUtils } from '../utils/object-utils';
|
||||
|
||||
@Injectable()
|
||||
|
@@ -15,19 +15,19 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async, inject } from '@angular/core/testing';
|
||||
import { async, inject, TestBed } from '@angular/core/testing';
|
||||
import { Router} from '@angular/router';
|
||||
import { RouterTestingModule } from '@angular/router/testing';
|
||||
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { LogService } from './log.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { CookieServiceMock } from './../assets/cookie.service.mock';
|
||||
import { AuthGuardBpm } from './auth-guard-bpm.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
import { AuthGuardBpm } from './auth-guard-bpm.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { LogService } from './log.service';
|
||||
import { StorageService } from './storage.service';
|
||||
|
||||
describe('AuthGuardService BPM', () => {
|
||||
|
||||
|
@@ -17,8 +17,8 @@
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import {
|
||||
CanActivate, Router, CanActivateChild,
|
||||
ActivatedRouteSnapshot,
|
||||
ActivatedRouteSnapshot, CanActivate, CanActivateChild,
|
||||
Router,
|
||||
RouterStateSnapshot
|
||||
} from '@angular/router';
|
||||
|
||||
|
@@ -15,19 +15,19 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async, inject } from '@angular/core/testing';
|
||||
import { async, inject, TestBed } from '@angular/core/testing';
|
||||
import { Router} from '@angular/router';
|
||||
import { RouterTestingModule } from '@angular/router/testing';
|
||||
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { CookieServiceMock } from './../assets/cookie.service.mock';
|
||||
import { LogService } from './log.service';
|
||||
import { AuthGuardEcm } from './auth-guard-ecm.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
import { AuthGuardEcm } from './auth-guard-ecm.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { LogService } from './log.service';
|
||||
import { StorageService } from './storage.service';
|
||||
|
||||
describe('AuthGuardService ECM', () => {
|
||||
|
||||
|
@@ -17,8 +17,8 @@
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import {
|
||||
CanActivate, Router, CanActivateChild,
|
||||
ActivatedRouteSnapshot,
|
||||
ActivatedRouteSnapshot, CanActivate, CanActivateChild,
|
||||
Router,
|
||||
RouterStateSnapshot
|
||||
} from '@angular/router';
|
||||
|
||||
|
@@ -15,19 +15,19 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async, inject } from '@angular/core/testing';
|
||||
import { async, inject, TestBed } from '@angular/core/testing';
|
||||
import { Router} from '@angular/router';
|
||||
import { RouterTestingModule } from '@angular/router/testing';
|
||||
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { CookieServiceMock } from './../assets/cookie.service.mock';
|
||||
import { LogService } from './log.service';
|
||||
import { AuthGuard } from './auth-guard.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
import { AuthGuard } from './auth-guard.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { LogService } from './log.service';
|
||||
import { StorageService } from './storage.service';
|
||||
|
||||
describe('AuthGuardService', () => {
|
||||
|
||||
|
@@ -17,8 +17,8 @@
|
||||
|
||||
import { Injectable } from '@angular/core';
|
||||
import {
|
||||
CanActivate, Router, CanActivateChild,
|
||||
ActivatedRouteSnapshot,
|
||||
ActivatedRouteSnapshot, CanActivate, CanActivateChild,
|
||||
Router,
|
||||
RouterStateSnapshot
|
||||
} from '@angular/router';
|
||||
|
||||
|
@@ -15,11 +15,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
||||
import { Component } from '@angular/core';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { LiveAnnouncer, MdSnackBar, MdSnackBarModule, OVERLAY_PROVIDERS, OverlayModule } from '@angular/material';
|
||||
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
||||
import { NotificationService } from './notification.service';
|
||||
import { MdSnackBarModule, MdSnackBar, OverlayModule, OVERLAY_PROVIDERS, LiveAnnouncer } from '@angular/material';
|
||||
|
||||
describe('NotificationService', () => {
|
||||
let fixture: ComponentFixture<ComponentThatProvidesNotificationService>;
|
||||
|
@@ -15,14 +15,14 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async } from '@angular/core/testing';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { RenditionsService } from './renditions.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { LogService } from './log.service';
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { fakeRedition, fakeReditionCreated, fakeReditionsList } from '../assets/renditionsService.mock';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
import { LogService } from './log.service';
|
||||
import { RenditionsService } from './renditions.service';
|
||||
import { StorageService } from './storage.service';
|
||||
|
||||
declare let jasmine: any;
|
||||
|
||||
|
@@ -42,7 +42,7 @@ export class RenditionsService {
|
||||
}
|
||||
observer.next(isAvailable);
|
||||
observer.complete();
|
||||
}, () => {
|
||||
}, () => {
|
||||
observer.next(false);
|
||||
observer.complete();
|
||||
});
|
||||
@@ -54,7 +54,7 @@ export class RenditionsService {
|
||||
this.getRendition(nodeId, encoding).subscribe(() => {
|
||||
observer.next(true);
|
||||
observer.complete();
|
||||
}, () => {
|
||||
}, () => {
|
||||
observer.next(false);
|
||||
observer.complete();
|
||||
});
|
||||
|
@@ -15,18 +15,18 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async } from '@angular/core/testing';
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { HttpModule } from '@angular/http';
|
||||
import { ThumbnailService } from './thumbnail.service';
|
||||
import { AlfrescoContentService } from './alfresco-content.service';
|
||||
import { CookieServiceMock } from './../assets/cookie.service.mock';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { AlfrescoAuthenticationService } from './alfresco-authentication.service';
|
||||
import { AlfrescoContentService } from './alfresco-content.service';
|
||||
import { AlfrescoSettingsService } from './alfresco-settings.service';
|
||||
import { AppConfigService } from './app-config.service';
|
||||
import { LogService } from './log.service';
|
||||
import { AlfrescoApiService } from './alfresco-api.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { CookieService } from './cookie.service';
|
||||
import { CookieServiceMock } from './../assets/cookie.service.mock';
|
||||
import { LogService } from './log.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { ThumbnailService } from './thumbnail.service';
|
||||
|
||||
describe('ThumbnailService', () => {
|
||||
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { TestBed, async } from '@angular/core/testing';
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { AppConfigModule } from './app-config.service';
|
||||
import { StorageService } from './storage.service';
|
||||
import { UserPreferencesService } from './user-preferences.service';
|
||||
|
@@ -1,4 +1,7 @@
|
||||
{
|
||||
"rulesDirectory": [
|
||||
"node_modules/codelyzer"
|
||||
],
|
||||
"rules": {
|
||||
"align": [
|
||||
true,
|
||||
@@ -105,14 +108,50 @@
|
||||
"allow-leading-underscore",
|
||||
"ban-keywords"
|
||||
],
|
||||
"callable-types": true,
|
||||
"import-blacklist": [
|
||||
true,
|
||||
"rxjs"
|
||||
],
|
||||
"import-spacing": true,
|
||||
"interface-over-type-literal": true,
|
||||
"member-access": false,
|
||||
"no-empty-interface": true,
|
||||
"no-string-literal": false,
|
||||
"no-string-throw": true,
|
||||
"prefer-const": false,
|
||||
"typeof-compare": true,
|
||||
"unified-signatures": true,
|
||||
"whitespace": [
|
||||
true,
|
||||
"check-branch",
|
||||
"check-decl",
|
||||
"check-operator",
|
||||
"check-separator",
|
||||
"check-type",
|
||||
"check-module",
|
||||
"check-decl"
|
||||
]
|
||||
"check-type"
|
||||
],
|
||||
"directive-selector": [
|
||||
true,
|
||||
"attribute",
|
||||
"app",
|
||||
"camelCase"
|
||||
],
|
||||
"component-selector": [
|
||||
true,
|
||||
"element",
|
||||
"app",
|
||||
"kebab-case"
|
||||
],
|
||||
"ordered-imports": true,
|
||||
"use-input-property-decorator": true,
|
||||
"use-output-property-decorator": true,
|
||||
"use-host-property-decorator": true,
|
||||
"use-life-cycle-interface": true,
|
||||
"use-pipe-transform-interface": true,
|
||||
"component-class-suffix": true,
|
||||
"directive-class-suffix": true,
|
||||
"no-access-missing-member": true,
|
||||
"templates-use-public": true,
|
||||
"invoke-injectable": true
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user