mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-05-12 17:04:46 +00:00
update prettier (#790)
* update prettier * enable auto-formatting for html
This commit is contained in:
parent
2dc2f51944
commit
cb3754e29d
3
.vscode/settings.json
vendored
3
.vscode/settings.json
vendored
@ -4,9 +4,6 @@
|
|||||||
"typescript.preferences.quoteStyle": "single",
|
"typescript.preferences.quoteStyle": "single",
|
||||||
"typescript.preferences.importModuleSpecifier": "relative",
|
"typescript.preferences.importModuleSpecifier": "relative",
|
||||||
"editor.formatOnSave": true,
|
"editor.formatOnSave": true,
|
||||||
"[html]": {
|
|
||||||
"editor.formatOnSave": false
|
|
||||||
},
|
|
||||||
"[json]": {
|
"[json]": {
|
||||||
"editor.formatOnSave": false
|
"editor.formatOnSave": false
|
||||||
}
|
}
|
||||||
|
6
package-lock.json
generated
6
package-lock.json
generated
@ -12486,9 +12486,9 @@
|
|||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"prettier": {
|
"prettier": {
|
||||||
"version": "1.14.2",
|
"version": "1.15.1",
|
||||||
"resolved": "https://registry.npmjs.org/prettier/-/prettier-1.14.2.tgz",
|
"resolved": "https://registry.npmjs.org/prettier/-/prettier-1.15.1.tgz",
|
||||||
"integrity": "sha512-McHPg0n1pIke+A/4VcaS2en+pTNjy4xF+Uuq86u/5dyDO59/TtFZtQ708QIRkEZ3qwKz3GVkVa6mpxK/CpB8Rg==",
|
"integrity": "sha512-4rgV2hyc/5Pk0XHH4VjJWHRgVjgRbpMfLQjREAhHBtyW1UvTFkjJEsueGYNYYZd9mn97K+1qv0EBwm11zoaSgA==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"process": {
|
"process": {
|
||||||
|
@ -90,7 +90,7 @@
|
|||||||
"karma-jasmine": "~1.1.0",
|
"karma-jasmine": "~1.1.0",
|
||||||
"karma-jasmine-html-reporter": "^0.2.2",
|
"karma-jasmine-html-reporter": "^0.2.2",
|
||||||
"ng-packagr": "^4.4.0",
|
"ng-packagr": "^4.4.0",
|
||||||
"prettier": "^1.14.2",
|
"prettier": "^1.15.1",
|
||||||
"protractor": "^5.4.0",
|
"protractor": "^5.4.0",
|
||||||
"rimraf": "2.6.2",
|
"rimraf": "2.6.2",
|
||||||
"rxjs-tslint-rules": "^4.8.0",
|
"rxjs-tslint-rules": "^4.8.0",
|
||||||
|
@ -41,7 +41,9 @@ import { ExtensionService } from '@alfresco/adf-extensions';
|
|||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-dynamic-column',
|
selector: 'app-dynamic-column',
|
||||||
template: `<ng-container #content></ng-container>`,
|
template: `
|
||||||
|
<ng-container #content></ng-container>
|
||||||
|
`,
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
host: { class: 'app-dynamic-column' },
|
host: { class: 'app-dynamic-column' },
|
||||||
|
@ -37,9 +37,7 @@ import { ShareDataRow } from '@alfresco/adf-content-services';
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'app-library-name-column',
|
selector: 'app-library-name-column',
|
||||||
template: `
|
template: `
|
||||||
<span
|
<span title="{{ displayTooltip }}" (click)="onClick()">
|
||||||
title="{{ displayTooltip }}"
|
|
||||||
(click)="onClick()">
|
|
||||||
{{ displayText }}
|
{{ displayText }}
|
||||||
</span>
|
</span>
|
||||||
`,
|
`,
|
||||||
|
@ -42,10 +42,10 @@ import { ContentApiService } from '../../../services/content-api.service';
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'aca-location-link',
|
selector: 'aca-location-link',
|
||||||
template: `
|
template: `
|
||||||
<a href="" [title]="nodeLocation$ | async" (click)="goToLocation()">
|
<a href="" [title]="nodeLocation$ | async" (click)="goToLocation()">
|
||||||
{{ displayText | async }}
|
{{ displayText | async }}
|
||||||
</a>
|
</a>
|
||||||
`,
|
`,
|
||||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
host: { class: 'aca-location-link adf-location-cell' }
|
host: { class: 'aca-location-link adf-location-cell' }
|
||||||
|
@ -36,9 +36,7 @@ import { MinimalNodeEntity } from 'alfresco-js-api';
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'app-name-column',
|
selector: 'app-name-column',
|
||||||
template: `
|
template: `
|
||||||
<span
|
<span title="{{ node | adfNodeNameTooltip }}" (click)="onClick()">
|
||||||
title="{{ node | adfNodeNameTooltip }}"
|
|
||||||
(click)="onClick()">
|
|
||||||
{{ displayText }}
|
{{ displayText }}
|
||||||
</span>
|
</span>
|
||||||
`,
|
`,
|
||||||
|
@ -35,10 +35,7 @@ import { MinimalNodeEntity } from 'alfresco-js-api';
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'app-trashcan-name-column',
|
selector: 'app-trashcan-name-column',
|
||||||
template: `
|
template: `
|
||||||
<span
|
<span title="{{ node | adfNodeNameTooltip }}">{{ displayText }}</span>
|
||||||
title="{{ node | adfNodeNameTooltip }}">
|
|
||||||
{{ displayText }}
|
|
||||||
</span>
|
|
||||||
`,
|
`,
|
||||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
|
@ -30,8 +30,11 @@ import { NodePermissionService } from '../../../services/node-permission.service
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'app-comments-tab',
|
selector: 'app-comments-tab',
|
||||||
template: `
|
template: `
|
||||||
<adf-comments [readOnly]="!canUpdateNode" [nodeId]="node?.id"></adf-comments>
|
<adf-comments
|
||||||
`
|
[readOnly]="!canUpdateNode"
|
||||||
|
[nodeId]="node?.id"
|
||||||
|
></adf-comments>
|
||||||
|
`
|
||||||
})
|
})
|
||||||
export class CommentsTabComponent {
|
export class CommentsTabComponent {
|
||||||
@Input()
|
@Input()
|
||||||
|
@ -36,9 +36,10 @@ import { AppConfigService } from '@alfresco/adf-core';
|
|||||||
[readOnly]="!canUpdateNode"
|
[readOnly]="!canUpdateNode"
|
||||||
[displayEmpty]="canUpdateNode"
|
[displayEmpty]="canUpdateNode"
|
||||||
[preset]="'custom'"
|
[preset]="'custom'"
|
||||||
[node]="node">
|
[node]="node"
|
||||||
|
>
|
||||||
</adf-content-metadata-card>
|
</adf-content-metadata-card>
|
||||||
`,
|
`,
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
host: { class: 'app-metadata-tab' }
|
host: { class: 'app-metadata-tab' }
|
||||||
})
|
})
|
||||||
|
@ -29,21 +29,26 @@ import { MinimalNodeEntryEntity } from 'alfresco-js-api';
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'app-versions-tab',
|
selector: 'app-versions-tab',
|
||||||
template: `
|
template: `
|
||||||
<ng-container *ngIf="isFileSelected;else empty">
|
<ng-container *ngIf="isFileSelected; else: empty">
|
||||||
<adf-version-manager
|
<adf-version-manager
|
||||||
[showComments]="'adf-version-manager.allowComments' | adfAppConfig:true"
|
[showComments]="
|
||||||
[allowDownload]="'adf-version-manager.allowDownload' | adfAppConfig:true"
|
'adf-version-manager.allowComments' | adfAppConfig: true
|
||||||
[node]="node">
|
"
|
||||||
</adf-version-manager>
|
[allowDownload]="
|
||||||
</ng-container>
|
'adf-version-manager.allowDownload' | adfAppConfig: true
|
||||||
|
"
|
||||||
|
[node]="node"
|
||||||
|
>
|
||||||
|
</adf-version-manager>
|
||||||
|
</ng-container>
|
||||||
|
|
||||||
<ng-template #empty>
|
<ng-template #empty>
|
||||||
<div class="adf-manage-versions-empty">
|
<div class="adf-manage-versions-empty">
|
||||||
<mat-icon class="adf-manage-versions-empty-icon">face</mat-icon>
|
<mat-icon class="adf-manage-versions-empty-icon">face</mat-icon>
|
||||||
{{ 'VERSION.SELECTION.EMPTY' | translate }}
|
{{ 'VERSION.SELECTION.EMPTY' | translate }}
|
||||||
</div>
|
</div>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
`
|
`
|
||||||
})
|
})
|
||||||
export class VersionsTabComponent implements OnInit, OnChanges {
|
export class VersionsTabComponent implements OnInit, OnChanges {
|
||||||
@Input()
|
@Input()
|
||||||
|
@ -33,7 +33,9 @@ import {
|
|||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-page-layout-content',
|
selector: 'app-page-layout-content',
|
||||||
template: `<ng-content></ng-content>`,
|
template: `
|
||||||
|
<ng-content></ng-content>
|
||||||
|
`,
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
host: { class: 'app-page-layout-content' }
|
host: { class: 'app-page-layout-content' }
|
||||||
|
@ -31,7 +31,9 @@ import {
|
|||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-page-layout-error',
|
selector: 'app-page-layout-error',
|
||||||
template: `<ng-content></ng-content>`,
|
template: `
|
||||||
|
<ng-content></ng-content>
|
||||||
|
`,
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||||
host: { class: 'app-page-layout-error' }
|
host: { class: 'app-page-layout-error' }
|
||||||
|
@ -39,7 +39,9 @@ import { MinimalNodeEntryEntity } from 'alfresco-js-api';
|
|||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-preview-extension',
|
selector: 'app-preview-extension',
|
||||||
template: `<div #content></div>`
|
template: `
|
||||||
|
<div #content></div>
|
||||||
|
`
|
||||||
})
|
})
|
||||||
export class PreviewExtensionComponent implements OnInit, OnChanges, OnDestroy {
|
export class PreviewExtensionComponent implements OnInit, OnChanges, OnDestroy {
|
||||||
@ViewChild('content', { read: ViewContainerRef })
|
@ViewChild('content', { read: ViewContainerRef })
|
||||||
|
@ -33,10 +33,7 @@ import { ToggleDocumentDisplayMode } from '../../../store/actions';
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'app-document-display-mode',
|
selector: 'app-document-display-mode',
|
||||||
template: `
|
template: `
|
||||||
<button
|
<button mat-icon-button color="primary" (click)="onClick()">
|
||||||
mat-icon-button
|
|
||||||
color="primary"
|
|
||||||
(click)="onClick()">
|
|
||||||
<mat-icon *ngIf="(displayMode$ | async) === 'list'">view_comfy</mat-icon>
|
<mat-icon *ngIf="(displayMode$ | async) === 'list'">view_comfy</mat-icon>
|
||||||
<mat-icon *ngIf="(displayMode$ | async) === 'gallery'">list</mat-icon>
|
<mat-icon *ngIf="(displayMode$ | async) === 'gallery'">list</mat-icon>
|
||||||
</button>
|
</button>
|
||||||
|
@ -35,15 +35,16 @@ import { ContentManagementService } from '../../../services/content-management.s
|
|||||||
selector: 'app-toggle-favorite',
|
selector: 'app-toggle-favorite',
|
||||||
template: `
|
template: `
|
||||||
<button
|
<button
|
||||||
mat-menu-item
|
mat-menu-item
|
||||||
#favorites="adfFavorite"
|
#favorites="adfFavorite"
|
||||||
(toggle)="onToggleEvent()"
|
(toggle)="onToggleEvent()"
|
||||||
[adf-node-favorite]="(selection$ | async).nodes">
|
[adf-node-favorite]="(selection$ | async).nodes"
|
||||||
<mat-icon *ngIf="favorites.hasFavorites()">star</mat-icon>
|
>
|
||||||
<mat-icon *ngIf="!favorites.hasFavorites()">star_border</mat-icon>
|
<mat-icon *ngIf="favorites.hasFavorites()">star</mat-icon>
|
||||||
<span>{{ 'APP.ACTIONS.FAVORITE' | translate }}</span>
|
<mat-icon *ngIf="!favorites.hasFavorites()">star_border</mat-icon>
|
||||||
|
<span>{{ 'APP.ACTIONS.FAVORITE' | translate }}</span>
|
||||||
</button>
|
</button>
|
||||||
`,
|
`,
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
host: { class: 'app-toggle-favorite' }
|
host: { class: 'app-toggle-favorite' }
|
||||||
})
|
})
|
||||||
|
@ -33,14 +33,15 @@ import { ToggleInfoDrawerAction } from '../../../store/actions';
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'app-toggle-info-drawer',
|
selector: 'app-toggle-info-drawer',
|
||||||
template: `
|
template: `
|
||||||
<button
|
<button
|
||||||
mat-icon-button
|
mat-icon-button
|
||||||
[color]="(infoDrawerOpened$ | async) ? 'accent' : 'primary'"
|
[color]="(infoDrawerOpened$ | async) ? 'accent' : 'primary'"
|
||||||
[attr.title]="'APP.ACTIONS.DETAILS' | translate"
|
[attr.title]="'APP.ACTIONS.DETAILS' | translate"
|
||||||
(click)="onClick()">
|
(click)="onClick()"
|
||||||
<mat-icon>info_outline</mat-icon>
|
>
|
||||||
</button>
|
<mat-icon>info_outline</mat-icon>
|
||||||
`,
|
</button>
|
||||||
|
`,
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
host: { class: 'app-toggle-info-drawer' }
|
host: { class: 'app-toggle-info-drawer' }
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user