mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-08-20 00:56:26 +00:00
Rename comments --> notes
This commit is contained in:
@@ -13,20 +13,20 @@
|
||||
<div class="tags d-flex flex-column text-end position-absolute me-1 fs-6">
|
||||
<app-tag *ngFor="let t of getTagsLimited$() | async" [tag]="t" (click)="clickTag.emit(t.id);$event.stopPropagation()" [clickable]="true" linkTitle="Toggle tag filter" i18n-linkTitle></app-tag>
|
||||
<div *ngIf="moreTags">
|
||||
<span class="badge badge-secondary">+ {{moreTags}}</span>
|
||||
<span class="badge text-dark">+ {{moreTags}}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<a routerLink="/documents/{{document.id}}/comments" *ngIf="document.comments.length" class="document-card-comments py-2 px-1">
|
||||
<a *ngIf="notesEnabled && document.notes.length" routerLink="/documents/{{document.id}}/notes" class="document-card-notes py-2 px-1">
|
||||
<span class="badge rounded-pill bg-light border text-primary">
|
||||
<svg class="metadata-icon ms-1 me-1" fill="currentColor">
|
||||
<use xlink:href="assets/bootstrap-icons.svg#chat-left-text"/>
|
||||
</svg>
|
||||
{{document.comments.length}}</span>
|
||||
{{document.notes.length}}</span>
|
||||
</a>
|
||||
|
||||
<div class="card-body p-2">
|
||||
<div class="card-body bg-light p-2">
|
||||
<p class="card-text">
|
||||
<ng-container *ngIf="document.correspondent">
|
||||
<a title="Toggle correspondent filter" i18n-title (click)="clickCorrespondent.emit(document.correspondent);$event.stopPropagation()" class="fw-bold btn-link">{{(document.correspondent$ | async)?.name}}</a>:
|
||||
|
@@ -34,10 +34,10 @@
|
||||
display: block;
|
||||
}
|
||||
|
||||
.document-card-comments {
|
||||
.document-card-notes {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
bottom: 170px;
|
||||
top: 142px;
|
||||
}
|
||||
|
||||
.card-selected {
|
||||
|
@@ -74,7 +74,7 @@ export class DocumentCardSmallComponent extends ComponentWithPermissions {
|
||||
}
|
||||
|
||||
getTagsLimited$() {
|
||||
const limit = this.document.comments.length > 0 ? 6 : 7
|
||||
const limit = this.document.notes.length > 0 ? 6 : 7
|
||||
return this.document.tags$.pipe(
|
||||
map((tags) => {
|
||||
if (tags.length > limit) {
|
||||
@@ -111,4 +111,8 @@ export class DocumentCardSmallComponent extends ComponentWithPermissions {
|
||||
mouseLeaveCard() {
|
||||
this.popover.close()
|
||||
}
|
||||
|
||||
get notesEnabled(): boolean {
|
||||
return this.settingsService.get(SETTINGS_KEYS.NOTES_ENABLED)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user