mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2026-09-09 18:03:21 +00:00
AAE-48934 Eslint v9 migration (#12110)
* update * update * update * working * cr * cr * update * use nx boundaries * fixes * fixes * fixes * cr * cr * update * update * update * cr * fix null * cr * cr * cr * cr * cr * update * update * update * update * update * remove some duplications * fix units
This commit is contained in:
@@ -1,2 +0,0 @@
|
||||
.storybook
|
||||
coverage
|
||||
@@ -1,97 +0,0 @@
|
||||
{
|
||||
"extends": ["../../.eslintrc.js"],
|
||||
"ignorePatterns": ["!**/*"],
|
||||
"overrides": [
|
||||
{
|
||||
"files": ["*.ts"],
|
||||
"extends": ["plugin:@nx/angular"],
|
||||
"parserOptions": {
|
||||
"project": ["lib/core/tsconfig.lib.json", "lib/core/tsconfig.spec.json", "lib/core/.storybook/tsconfig.json"],
|
||||
"createDefaultProgram": true
|
||||
},
|
||||
"rules": {
|
||||
"jsdoc/tag-lines": [
|
||||
"error",
|
||||
"any",
|
||||
{
|
||||
"startLines": 1
|
||||
}
|
||||
],
|
||||
"@typescript-eslint/naming-convention": "off",
|
||||
"@typescript-eslint/consistent-type-assertions": "warn",
|
||||
"@typescript-eslint/prefer-for-of": "off",
|
||||
"@typescript-eslint/member-ordering": "off",
|
||||
"no-underscore-dangle": [
|
||||
"error",
|
||||
{
|
||||
"allowAfterThis": true
|
||||
}
|
||||
],
|
||||
"no-shadow": "warn",
|
||||
"quote-props": "off",
|
||||
"object-shorthand": "warn",
|
||||
"no-restricted-syntax": "warn",
|
||||
"prefer-const": "warn",
|
||||
"arrow-body-style": "warn",
|
||||
"@angular-eslint/no-output-native": "off",
|
||||
"space-before-function-paren": "off",
|
||||
"@angular-eslint/component-selector": [
|
||||
"error",
|
||||
{
|
||||
"type": "element",
|
||||
"prefix": ["adf", "app"],
|
||||
"style": "kebab-case"
|
||||
}
|
||||
],
|
||||
"@angular-eslint/directive-selector": [
|
||||
"error",
|
||||
{
|
||||
"type": ["element", "attribute"],
|
||||
"prefix": ["adf", "app"],
|
||||
"style": "kebab-case"
|
||||
}
|
||||
],
|
||||
"@angular-eslint/no-input-prefix": "error",
|
||||
"@typescript-eslint/consistent-type-definitions": "error",
|
||||
"@typescript-eslint/dot-notation": "off",
|
||||
"@typescript-eslint/explicit-member-accessibility": [
|
||||
"off",
|
||||
{
|
||||
"accessibility": "explicit"
|
||||
}
|
||||
],
|
||||
"@typescript-eslint/no-inferrable-types": "off",
|
||||
"@typescript-eslint/no-require-imports": "off",
|
||||
"@typescript-eslint/no-var-requires": "error",
|
||||
"comma-dangle": "error",
|
||||
"default-case": "error",
|
||||
"import/order": "off",
|
||||
"max-len": [
|
||||
"error",
|
||||
{
|
||||
"code": 240
|
||||
}
|
||||
],
|
||||
"no-bitwise": "off",
|
||||
"no-duplicate-imports": "error",
|
||||
"no-multiple-empty-lines": "error",
|
||||
"no-return-await": "error",
|
||||
"rxjs/no-create": "error",
|
||||
"rxjs/no-subject-unsubscribe": "error",
|
||||
"rxjs/no-subject-value": "error",
|
||||
"rxjs/no-unsafe-takeuntil": "error",
|
||||
"unicorn/filename-case": "error",
|
||||
"@angular-eslint/prefer-standalone": "off"
|
||||
}
|
||||
},
|
||||
{
|
||||
"files": ["*.html"],
|
||||
"extends": ["plugin:@nx/angular-template"],
|
||||
"rules": {
|
||||
"@angular-eslint/template/no-autofocus": "error",
|
||||
"@angular-eslint/template/no-positive-tabindex": "error",
|
||||
"@angular-eslint/template/no-negated-async": "off"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -1,6 +1,24 @@
|
||||
/*!
|
||||
* @license
|
||||
* Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { fileURLToPath } from 'node:url';
|
||||
import { dirname } from 'node:path';
|
||||
import type { StorybookConfig } from '@storybook/angular';
|
||||
// eslint-disable-next-line @nx/enforce-module-boundaries
|
||||
import rootMain from '../../../.storybook/main';
|
||||
|
||||
const config: StorybookConfig = {
|
||||
@@ -21,6 +39,12 @@ const config: StorybookConfig = {
|
||||
|
||||
export default config;
|
||||
|
||||
/**
|
||||
* Resolve absolute path for a package.
|
||||
*
|
||||
* @param value package name
|
||||
* @returns absolute path to the package
|
||||
*/
|
||||
function getAbsolutePath(value: string): any {
|
||||
return dirname(fileURLToPath(import.meta.resolve(`${value}/package.json`)));
|
||||
}
|
||||
|
||||
@@ -1,3 +1,20 @@
|
||||
/*!
|
||||
* @license
|
||||
* Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import type { Preview } from '@storybook/angular';
|
||||
import rootPreview from '../../../.storybook/preview';
|
||||
|
||||
|
||||
@@ -78,7 +78,7 @@ describe('AdfHttpClient', () => {
|
||||
.request('http://example.com', options, securityOptions, emitters)
|
||||
.then((res: ResultListDataRepresentationTaskRepresentation) => {
|
||||
expect(res instanceof ResultListDataRepresentationTaskRepresentation).toBeTruthy();
|
||||
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
||||
|
||||
expect(res.data![0].created instanceof Date).toBeTruthy();
|
||||
done();
|
||||
})
|
||||
|
||||
@@ -0,0 +1,71 @@
|
||||
/*!
|
||||
* @license
|
||||
* Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import rootConfig from '../../eslint.config.mjs';
|
||||
|
||||
|
||||
export default [
|
||||
...rootConfig,
|
||||
{
|
||||
files: ['**/*.ts'],
|
||||
rules: {
|
||||
'@nx/enforce-module-boundaries': [
|
||||
'error',
|
||||
{
|
||||
enforceBuildableLibDependency: true,
|
||||
allow: [],
|
||||
depConstraints: [
|
||||
{
|
||||
sourceTag: 'scope:core',
|
||||
onlyDependOnLibsWithTags: ['scope:js-api', 'scope:extensions']
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
'@typescript-eslint/consistent-type-assertions': 'warn',
|
||||
'@typescript-eslint/prefer-for-of': 'off',
|
||||
'no-underscore-dangle': [
|
||||
'error',
|
||||
{
|
||||
allowAfterThis: true
|
||||
}
|
||||
],
|
||||
'no-shadow': 'warn',
|
||||
'quote-props': 'off',
|
||||
'object-shorthand': 'warn',
|
||||
'no-restricted-syntax': 'warn',
|
||||
'prefer-const': 'warn',
|
||||
'arrow-body-style': 'warn',
|
||||
'space-before-function-paren': 'off',
|
||||
'@angular-eslint/prefer-standalone': 'off'
|
||||
}
|
||||
},
|
||||
{
|
||||
files: ['**/*.html'],
|
||||
rules: {
|
||||
'@angular-eslint/template/no-autofocus': 'error',
|
||||
'@angular-eslint/template/no-positive-tabindex': 'error',
|
||||
'@angular-eslint/template/no-negated-async': 'off'
|
||||
}
|
||||
},
|
||||
{
|
||||
files: ['**/.storybook/**/*.ts'],
|
||||
rules: {
|
||||
'@nx/enforce-module-boundaries': 'off'
|
||||
}
|
||||
}
|
||||
];
|
||||
@@ -4,6 +4,7 @@
|
||||
"projectType": "library",
|
||||
"sourceRoot": "lib/core",
|
||||
"prefix": "adf",
|
||||
"tags": ["scope:core", "type:library"],
|
||||
"targets": {
|
||||
"build": {
|
||||
"executor": "@angular/build:ng-packagr",
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
*/
|
||||
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { AboutLicenseListComponent, UnitTestingUtils } from '@alfresco/adf-core';
|
||||
import { AboutLicenseListComponent } from './about-license-list.component';
|
||||
import { UnitTestingUtils } from '../../testing/unit-testing-utils';
|
||||
import { TestbedHarnessEnvironment } from '@angular/cdk/testing/testbed';
|
||||
|
||||
describe('AboutLicenseListComponent', () => {
|
||||
|
||||
+3
-1
@@ -16,7 +16,9 @@
|
||||
*/
|
||||
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { AboutRepositoryInfoComponent, RepositoryInfo, UnitTestingUtils } from '@alfresco/adf-core';
|
||||
import { AboutRepositoryInfoComponent } from './about-repository-info.component';
|
||||
import { RepositoryInfo } from './repository-info.interface';
|
||||
import { UnitTestingUtils } from '../../testing/unit-testing-utils';
|
||||
|
||||
describe('AboutRepositoryInfoComponent', () => {
|
||||
let component: AboutRepositoryInfoComponent;
|
||||
|
||||
+1
-1
@@ -18,7 +18,7 @@
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { AboutServerSettingsComponent } from './about-server-settings.component';
|
||||
import { AppConfigService } from '../../app-config/app-config.service';
|
||||
import { provideAppConfigTesting } from '@alfresco/adf-core';
|
||||
import { provideAppConfigTesting } from '../../testing/app-config-testing';
|
||||
|
||||
const aboutGithubDetails = {
|
||||
url: 'https://github.com/componany/repository/commits/',
|
||||
|
||||
@@ -26,7 +26,6 @@ import { OauthConfigModel } from '../auth/models/oauth-config.model';
|
||||
|
||||
/* spellchecker: disable */
|
||||
|
||||
// eslint-disable-next-line no-shadow
|
||||
export const AppConfigValues = {
|
||||
APP_CONFIG_LANGUAGES_KEY: 'languages',
|
||||
PROVIDERS: 'providers',
|
||||
@@ -210,7 +209,6 @@ export class AppConfigService {
|
||||
this.onDataLoaded();
|
||||
},
|
||||
() => {
|
||||
// eslint-disable-next-line no-console
|
||||
console.error('app.config.json contains validation errors');
|
||||
resolve(this.config);
|
||||
}
|
||||
@@ -238,7 +236,6 @@ export class AppConfigService {
|
||||
resolve(res);
|
||||
},
|
||||
error: (err: any) => {
|
||||
// eslint-disable-next-line no-console
|
||||
console.error('hostIdp not correctly configured or unreachable');
|
||||
reject(err);
|
||||
}
|
||||
|
||||
@@ -18,7 +18,8 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
import { OidcAuthenticationService } from './oidc-authentication.service';
|
||||
import { OAuthService, OAuthStorage } from 'angular-oauth2-oidc';
|
||||
import { AppConfigService, AuthService } from '@alfresco/adf-core';
|
||||
import { AppConfigService } from '../../app-config/app-config.service';
|
||||
import { AuthService } from './auth.service';
|
||||
import { AUTH_MODULE_CONFIG } from './auth-config';
|
||||
import { firstValueFrom, of, take, throwError } from 'rxjs';
|
||||
|
||||
|
||||
@@ -21,7 +21,6 @@ import { CardViewItem } from '../interfaces/card-view.interfaces';
|
||||
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
||||
|
||||
@Directive()
|
||||
// eslint-disable-next-line @angular-eslint/directive-class-suffix
|
||||
export abstract class BaseCardView<T extends CardViewItem> {
|
||||
protected cardViewUpdateService = inject(CardViewUpdateService);
|
||||
|
||||
|
||||
-1
@@ -106,7 +106,6 @@ export class CardViewItemDispatcherComponent implements OnChanges {
|
||||
|
||||
private proxy(methodName, ...args) {
|
||||
if (this.componentReference.instance[methodName]) {
|
||||
// eslint-disable-next-line prefer-spread
|
||||
this.componentReference.instance[methodName].apply(this.componentReference.instance, args);
|
||||
}
|
||||
}
|
||||
|
||||
+3
-1
@@ -18,7 +18,9 @@
|
||||
import { Component, Input } from '@angular/core';
|
||||
import { CardViewPropertyValidatorDirective } from './card-view-property-validator.directive';
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { CardViewBaseItemModel, CardViewTextItemModel, UnitTestingUtils } from '@alfresco/adf-core';
|
||||
import { CardViewBaseItemModel } from '../models/card-view-baseitem.model';
|
||||
import { CardViewTextItemModel } from '../models/card-view-textitem.model';
|
||||
import { UnitTestingUtils } from '../../testing/unit-testing-utils';
|
||||
import { FormControl, ReactiveFormsModule } from '@angular/forms';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ export class ClipboardDirective {
|
||||
private readonly translate = inject(TranslateService, { optional: true });
|
||||
|
||||
/** Translation key or message for the tooltip. */
|
||||
// eslint-disable-next-line @angular-eslint/no-input-rename
|
||||
|
||||
@Input('adf-clipboard')
|
||||
placeholder: string;
|
||||
|
||||
@@ -42,7 +42,7 @@ export class ClipboardDirective {
|
||||
target: HTMLInputElement | HTMLTextAreaElement;
|
||||
|
||||
/** Translation key or message for snackbar notification. */
|
||||
// eslint-disable-next-line @angular-eslint/no-input-rename
|
||||
|
||||
@Input('clipboard-notification') message: string;
|
||||
|
||||
@HostListener('mouseenter')
|
||||
|
||||
@@ -39,7 +39,6 @@ export class HighlightTransformService {
|
||||
let result = text;
|
||||
|
||||
if (search && text) {
|
||||
// eslint-disable-next-line no-useless-escape
|
||||
let pattern = search.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, '\\$&');
|
||||
pattern = pattern
|
||||
.split(' ')
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
import { AppConfigService } from '../../app-config/app-config.service';
|
||||
import { StorageService } from '../../common/services/storage.service';
|
||||
import { provideCoreAuthTesting } from '@alfresco/adf-core';
|
||||
import { provideCoreAuthTesting } from '../../testing/noop-auth.module';
|
||||
|
||||
describe('StorageService', () => {
|
||||
let storage: StorageService;
|
||||
|
||||
@@ -19,7 +19,7 @@ import { Component } from '@angular/core';
|
||||
import { TestBed, ComponentFixture } from '@angular/core/testing';
|
||||
import { TestbedHarnessEnvironment } from '@angular/cdk/testing/testbed';
|
||||
import { UnitTestingUtils } from '../testing/unit-testing-utils';
|
||||
import { ContextMenuDirective } from '@alfresco/adf-core';
|
||||
import { ContextMenuDirective } from './context-menu.directive';
|
||||
|
||||
@Component({
|
||||
selector: 'adf-test-component',
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/no-input-rename */
|
||||
|
||||
import { Directive, HostListener, Input, inject } from '@angular/core';
|
||||
import { ContextMenuOverlayService } from './context-menu-overlay.service';
|
||||
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/no-conflicting-lifecycle */
|
||||
|
||||
import {
|
||||
AfterContentInit,
|
||||
AfterViewInit,
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector, @angular-eslint/no-input-rename */
|
||||
|
||||
import { AfterContentInit, Component, ContentChild, TemplateRef, inject } from '@angular/core';
|
||||
import { DataColumnComponent } from './data-column.component';
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector, @angular-eslint/no-input-rename */
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { Component, ContentChild, Input, OnInit, TemplateRef } from '@angular/core';
|
||||
import { DataColumnType } from '@alfresco/adf-extensions';
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable id-blacklist */
|
||||
|
||||
import { TemplateRef } from '@angular/core';
|
||||
import { DataColumnType } from '@alfresco/adf-extensions';
|
||||
|
||||
|
||||
@@ -23,7 +23,6 @@ import { DataColumn } from './data-column.model';
|
||||
import { ObjectDataColumn } from './object-datacolumn.model';
|
||||
|
||||
@Directive()
|
||||
// eslint-disable-next-line @angular-eslint/directive-class-suffix
|
||||
export abstract class DataTableSchema<T = unknown> {
|
||||
@ContentChild(DataColumnListComponent)
|
||||
columnList: DataColumnListComponent;
|
||||
|
||||
+3
-1
@@ -16,7 +16,9 @@
|
||||
*/
|
||||
|
||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { AppConfigValues, UnsavedChangesDialogComponent, UserPreferencesService } from '@alfresco/adf-core';
|
||||
import { AppConfigValues } from '../../app-config/app-config.service';
|
||||
import { UnsavedChangesDialogComponent } from './unsaved-changes-dialog.component';
|
||||
import { UserPreferencesService } from '../../common/services/user-preferences.service';
|
||||
import { DebugElement } from '@angular/core';
|
||||
import { MAT_DIALOG_DATA, MatDialogClose } from '@angular/material/dialog';
|
||||
import { UnsavedChangesDialogData } from './unsaved-changes-dialog.model';
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/no-input-rename */
|
||||
|
||||
import { Directive, ElementRef, Input, Renderer2, AfterViewChecked, inject } from '@angular/core';
|
||||
import { HighlightTransformService, HighlightTransformResult } from '../common/services/highlight-transform.service';
|
||||
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/no-input-rename */
|
||||
|
||||
import { Directive, ElementRef, HostListener, Input, NgZone, OnDestroy, OnInit, Renderer2, inject } from '@angular/core';
|
||||
import { FileInfo, FileUtils } from '../common/utils/file-utils';
|
||||
|
||||
|
||||
@@ -22,7 +22,6 @@ import { isOutcomeButtonVisible } from './helpers/buttons-visibility';
|
||||
@Directive({
|
||||
standalone: true
|
||||
})
|
||||
// eslint-disable-next-line @angular-eslint/directive-class-suffix
|
||||
export abstract class FormBaseComponent {
|
||||
protected _form: FormModel;
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector, @angular-eslint/no-input-rename */
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { NgClass, NgIf } from '@angular/common';
|
||||
import { Component, ViewEncapsulation } from '@angular/core';
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { FormFieldModel } from './form-field.model';
|
||||
import { FormWidgetModel } from './form-widget.model';
|
||||
import { ContainerColumnModel } from './container-column.model';
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export class ContentLinkModel {
|
||||
contentAvailable: boolean;
|
||||
created: Date;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export interface DisplayableCMProperties {
|
||||
name?: string;
|
||||
prefixedName?: string;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export class ErrorMessageModel {
|
||||
message: string = '';
|
||||
attributes: Map<string, string> = null;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export interface ExternalContentLink {
|
||||
contentAvailable: boolean;
|
||||
created: string;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export interface ExternalContent {
|
||||
folder: boolean;
|
||||
id: string;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { FormFieldSelectedFolder } from './form-field-selected-folder';
|
||||
|
||||
export interface DestinationFolderPath {
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { DisplayableCMProperties } from './displayable-cm-properties.model';
|
||||
import { FormFieldFileSource } from './form-field-file-source';
|
||||
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export interface FormFieldOption {
|
||||
id: string;
|
||||
name: string;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export interface FormFieldSelectedFolder {
|
||||
accountId: string;
|
||||
folderTree: [any];
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export interface FormFieldTemplates {
|
||||
[key: string]: string;
|
||||
[key: string]: string;
|
||||
}
|
||||
|
||||
@@ -17,8 +17,6 @@
|
||||
|
||||
import { MaybeReactiveFormWidget, ReactiveFormWidget } from '../reactive-widget.interface';
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export class FormFieldTypes {
|
||||
static CONTAINER: string = 'container';
|
||||
static GROUP: string = 'group';
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { FormFieldTypes } from './form-field-types';
|
||||
import { isNumberValue } from './form-field-utils';
|
||||
import { FormFieldModel } from './form-field.model';
|
||||
|
||||
@@ -15,7 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
import { WidgetVisibilityModel } from '../../../models/widget-visibility.model';
|
||||
import { ContainerColumnModel } from './container-column.model';
|
||||
import { ErrorMessageModel } from './error-message.model';
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { FormOutcomeModel } from './form-outcome.model';
|
||||
|
||||
export class FormOutcomeEvent {
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { FormWidgetModel } from './form-widget.model';
|
||||
import { WidgetVisibilityModel } from '../../../models/widget-visibility.model';
|
||||
|
||||
|
||||
@@ -15,10 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
/* eslint-disable */
|
||||
import { FormFieldMetadata } from './form-field-metadata';
|
||||
|
||||
export interface FormValues extends FormFieldMetadata {
|
||||
}
|
||||
export interface FormValues extends FormFieldMetadata {}
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export abstract class FormWidgetModel {
|
||||
readonly fieldType: string;
|
||||
readonly id: string;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
export * from './form-field-metadata';
|
||||
export * from './form-values';
|
||||
export * from './form-field-types';
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { WidgetVisibilityModel } from '../../../models/widget-visibility.model';
|
||||
import { FormWidgetModel } from './form-widget.model';
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector, @angular-eslint/no-input-rename */
|
||||
/* eslint-disable @angular-eslint/component-selector */
|
||||
|
||||
import { NgIf } from '@angular/common';
|
||||
import { Component, inject, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/component-selector, @typescript-eslint/no-use-before-define, @angular-eslint/no-input-rename */
|
||||
|
||||
import { Directive, ElementRef, forwardRef, HostListener, Input, OnChanges, Renderer2, SimpleChanges, inject } from '@angular/core';
|
||||
import { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ import { filter } from 'rxjs/operators';
|
||||
import { FormRulesEvent } from '../../events';
|
||||
import { FormFieldModel, FormModel } from './core';
|
||||
import { WidgetComponent } from './widget.component';
|
||||
import { FormService } from '@alfresco/adf-core';
|
||||
import { FormService } from '../../services/form.service';
|
||||
|
||||
describe('WidgetComponent', () => {
|
||||
let widget: WidgetComponent;
|
||||
|
||||
@@ -24,7 +24,6 @@ import { Injectable, Type } from '@angular/core';
|
||||
import * as widgets from '../components/widgets';
|
||||
import { FormFieldTypes } from '../components/widgets';
|
||||
|
||||
/* eslint-disable id-blacklist */
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
|
||||
@@ -19,7 +19,7 @@ import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { NavbarItemComponent } from './navbar-item.component';
|
||||
import { RouterTestingModule } from '@angular/router/testing';
|
||||
import { Router } from '@angular/router';
|
||||
import { UnitTestingUtils } from '@alfresco/adf-core';
|
||||
import { UnitTestingUtils } from '../../testing/unit-testing-utils';
|
||||
|
||||
describe('NavbarItemComponent', () => {
|
||||
let component: NavbarItemComponent;
|
||||
|
||||
@@ -21,7 +21,7 @@ import { CommonModule } from '@angular/common';
|
||||
import { RouterModule } from '@angular/router';
|
||||
import { NavbarComponent } from './navbar.component';
|
||||
import { UnitTestingUtils } from '../../testing/unit-testing-utils';
|
||||
import { NavbarItemComponent } from '@alfresco/adf-core';
|
||||
import { NavbarItemComponent } from './navbar-item.component';
|
||||
|
||||
describe('NavbarComponent', () => {
|
||||
let component: NavbarComponent;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @cspell/spellchecker */
|
||||
|
||||
export const mockTabText = `Lorem ipsum dolor sit amet, consectetur adipiscing elit. Etiam urna odio, sagittis vel nulla vel, condimentum egestas dolor.
|
||||
Interdum et malesuada fames ac ante ipsum primis in faucibus. Mauris eu hendrerit lectus. Aliquam et ex imperdiet, sodales tellus finibus, malesuada eros.
|
||||
Vestibulum aliquet eros sed diam euismod tincidunt.
|
||||
|
||||
@@ -20,7 +20,7 @@ import { LanguagePickerComponent } from './language-picker.component';
|
||||
import { MatMenuItem, MatMenuTrigger } from '@angular/material/menu';
|
||||
import { LanguageMenuComponent } from './language-menu.component';
|
||||
import { QueryList } from '@angular/core';
|
||||
import { UnitTestingUtils } from '@alfresco/adf-core';
|
||||
import { UnitTestingUtils } from '../testing/unit-testing-utils';
|
||||
|
||||
describe('LanguagePickerComponent', () => {
|
||||
let component: LanguagePickerComponent;
|
||||
|
||||
+1
-1
@@ -53,7 +53,7 @@ describe('SidebarActionMenuComponent', () => {
|
||||
|
||||
@Component({
|
||||
imports: [CommonModule, SidebarActionMenuComponent, IconModule, MatMenuModule],
|
||||
// eslint-disable-next-line @alfresco/eslint-angular/no-angular-material-selectors
|
||||
|
||||
template: `
|
||||
<adf-sidebar-action-menu [expanded]="expanded" [title]="title">
|
||||
<mat-icon adf-sidebar-menu-title-icon adf-icon="arrow_drop_down" />
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
import { applicationConfig, Meta, StoryObj, moduleMetadata } from '@storybook/angular';
|
||||
import { LoginComponent } from './login.component';
|
||||
import { provideStoryCore } from '../../../stories/core-story.providers';
|
||||
import { NoopAuthModule } from '@alfresco/adf-core';
|
||||
import { NoopAuthModule } from '../../../testing/noop-auth.module';
|
||||
|
||||
type LoginStoryArgs = LoginComponent & {
|
||||
correct?: any;
|
||||
|
||||
@@ -38,7 +38,6 @@ import { LoginSuccessEvent } from '../../models/login-success.event';
|
||||
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
||||
import { IconModule } from '../../../icon/icon.module';
|
||||
|
||||
// eslint-disable-next-line no-shadow
|
||||
enum LoginSteps {
|
||||
Landing = 0,
|
||||
Checking = 1,
|
||||
|
||||
@@ -15,9 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/no-input-rename */
|
||||
/* eslint-disable rxjs/no-subject-value */
|
||||
|
||||
import {
|
||||
ChangeDetectionStrategy,
|
||||
ChangeDetectorRef,
|
||||
|
||||
@@ -102,7 +102,7 @@ export class PaginationComponent implements OnInit, PaginationComponentInterface
|
||||
}
|
||||
|
||||
/** Emitted when pagination changes in any way. */
|
||||
// eslint-disable-next-line @angular-eslint/no-output-native
|
||||
|
||||
@Output()
|
||||
change = new EventEmitter<PaginationModel>();
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ import { TestBed } from '@angular/core/testing';
|
||||
import { UserPreferencesService } from '../common/services/user-preferences.service';
|
||||
import { of } from 'rxjs';
|
||||
import { DecimalNumberPipe } from './decimal-number.pipe';
|
||||
import { AppConfigService } from '@alfresco/adf-core';
|
||||
import { AppConfigService } from '../app-config/app-config.service';
|
||||
|
||||
describe('DecimalNumberPipe', () => {
|
||||
let pipe: DecimalNumberPipe;
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @angular-eslint/no-input-rename, @typescript-eslint/no-use-before-define, @angular-eslint/no-input-rename */
|
||||
|
||||
import { ENTER, ESCAPE } from '@angular/cdk/keycodes';
|
||||
import { ChangeDetectorRef, DestroyRef, Directive, ElementRef, forwardRef, inject, Input, NgZone, OnDestroy } from '@angular/core';
|
||||
import { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';
|
||||
|
||||
@@ -72,11 +72,9 @@ export class ImgViewerComponent implements AfterViewInit, OnChanges, OnDestroy {
|
||||
@Input()
|
||||
fileName: string;
|
||||
|
||||
// eslint-disable-next-line @angular-eslint/no-output-native
|
||||
@Output()
|
||||
error = new EventEmitter<void>();
|
||||
|
||||
// eslint-disable-next-line @angular-eslint/no-output-native
|
||||
@Output()
|
||||
submit = new EventEmitter<Blob>();
|
||||
|
||||
|
||||
@@ -25,7 +25,9 @@ import { UnitTestingUtils } from '../../../testing';
|
||||
import { ViewerRenderComponent } from './viewer-render.component';
|
||||
import { PDF_VIEWER_COMPONENT } from '../../tokens/pdf-viewer.token';
|
||||
import { PdfViewerRef } from '../../tokens/pdf-viewer-ref';
|
||||
import { ImgViewerComponent, MediaPlayerComponent, ViewerExtensionDirective } from '@alfresco/adf-core';
|
||||
import { ImgViewerComponent } from '../img-viewer/img-viewer.component';
|
||||
import { MediaPlayerComponent } from '../media-player/media-player.component';
|
||||
import { ViewerExtensionDirective } from '../../directives/viewer-extension.directive';
|
||||
|
||||
@Component({
|
||||
selector: 'adf-pdf-viewer',
|
||||
|
||||
@@ -15,9 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
/* eslint-disable @typescript-eslint/naming-convention */
|
||||
/* eslint-disable no-underscore-dangle */
|
||||
/* eslint-disable @angular-eslint/no-output-native */
|
||||
|
||||
import { NgIf, NgStyle, NgTemplateOutlet } from '@angular/common';
|
||||
import {
|
||||
|
||||
Reference in New Issue
Block a user