mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-07-28 18:24:38 -05:00
Migrate frontend prefix to -pngx
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<app-page-header title="Dashboard" [subTitle]="subtitle" i18n-title>
|
||||
<app-logo extra_classes="d-none d-md-block"></app-logo>
|
||||
</app-page-header>
|
||||
<pngx-page-header title="Dashboard" [subTitle]="subtitle" i18n-title>
|
||||
<pngx-logo extra_classes="d-none d-md-block"></pngx-logo>
|
||||
</pngx-page-header>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-lg-8">
|
||||
@@ -10,20 +10,20 @@
|
||||
<ng-container i18n>Loading...</ng-container>
|
||||
</ng-container>
|
||||
|
||||
<app-welcome-widget *ngIf="settingsService.offerTour()" (dismiss)="completeTour()"></app-welcome-widget>
|
||||
<pngx-welcome-widget *ngIf="settingsService.offerTour()" (dismiss)="completeTour()"></pngx-welcome-widget>
|
||||
|
||||
<div *appIfPermissions="{ action: PermissionAction.View, type: PermissionType.SavedView }">
|
||||
<div *pngxIfPermissions="{ action: PermissionAction.View, type: PermissionType.SavedView }">
|
||||
<ng-container *ngFor="let v of savedViewService.dashboardViews; first as isFirst">
|
||||
<app-saved-view-widget [savedView]="v"></app-saved-view-widget>
|
||||
<pngx-saved-view-widget [savedView]="v"></pngx-saved-view-widget>
|
||||
</ng-container>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-4">
|
||||
|
||||
<app-statistics-widget></app-statistics-widget>
|
||||
<pngx-statistics-widget></pngx-statistics-widget>
|
||||
|
||||
<app-upload-file-widget></app-upload-file-widget>
|
||||
<pngx-upload-file-widget></pngx-upload-file-widget>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
@@ -5,7 +5,7 @@ import { ComponentWithPermissions } from '../with-permissions/with-permissions.c
|
||||
import { TourService } from 'ngx-ui-tour-ng-bootstrap'
|
||||
|
||||
@Component({
|
||||
selector: 'app-dashboard',
|
||||
selector: 'pngx-dashboard',
|
||||
templateUrl: './dashboard.component.html',
|
||||
styleUrls: ['./dashboard.component.scss'],
|
||||
})
|
||||
|
@@ -1,6 +1,6 @@
|
||||
<app-widget-frame [title]="savedView.name" [loading]="loading">
|
||||
<pngx-widget-frame [title]="savedView.name" [loading]="loading">
|
||||
|
||||
<a class="btn-link" header-buttons [routerLink]="[]" (click)="showAll()" *appIfPermissions="{ action: PermissionAction.View, type: PermissionType.Document }" i18n>Show all</a>
|
||||
<a class="btn-link" header-buttons [routerLink]="[]" (click)="showAll()" *pngxIfPermissions="{ action: PermissionAction.View, type: PermissionType.Document }" i18n>Show all</a>
|
||||
|
||||
|
||||
<table content class="table table-sm table-hover table-borderless mb-0">
|
||||
@@ -10,11 +10,11 @@
|
||||
<th scope="col" i18n>Title</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody *appIfPermissions="{ action: PermissionAction.View, type: PermissionType.Document }">
|
||||
<tbody *pngxIfPermissions="{ action: PermissionAction.View, type: PermissionType.Document }">
|
||||
<tr *ngFor="let doc of documents" (mouseleave)="mouseLeaveCard()">
|
||||
<td><a routerLink="/documents/{{doc.id}}" class="d-block text-dark text-decoration-none">{{doc.created_date | customDate}}</a></td>
|
||||
<td class="position-relative">
|
||||
<a routerLink="/documents/{{doc.id}}" title="Edit" i18n-title class="d-block text-dark text-decoration-none">{{doc.title | documentTitle}}<app-tag [tag]="t" *ngFor="let t of doc.tags$ | async" class="ms-1" (click)="clickTag(t, $event)"></app-tag></a>
|
||||
<a routerLink="/documents/{{doc.id}}" title="Edit" i18n-title class="d-block text-dark text-decoration-none">{{doc.title | documentTitle}}<pngx-tag [tag]="t" *ngFor="let t of doc.tags$ | async" class="ms-1" (click)="clickTag(t, $event)"></pngx-tag></a>
|
||||
<div class="btn-group position-absolute top-50 end-0 translate-middle-y">
|
||||
<a [href]="getPreviewUrl(doc)" title="View Preview" i18n-title target="_blank" class="btn btn-sm px-4 py-0 btn-dark border-dark-subtle"
|
||||
[ngbPopover]="previewContent" [popoverTitle]="doc.title | documentTitle"
|
||||
@@ -37,4 +37,4 @@
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</app-widget-frame>
|
||||
</pngx-widget-frame>
|
||||
|
@@ -20,7 +20,7 @@ import { ComponentWithPermissions } from 'src/app/components/with-permissions/wi
|
||||
import { NgbPopover } from '@ng-bootstrap/ng-bootstrap'
|
||||
|
||||
@Component({
|
||||
selector: 'app-saved-view-widget',
|
||||
selector: 'pngx-saved-view-widget',
|
||||
templateUrl: './saved-view-widget.component.html',
|
||||
styleUrls: [
|
||||
'./saved-view-widget.component.scss',
|
||||
|
@@ -1,4 +1,4 @@
|
||||
<app-widget-frame title="Statistics" [loading]="loading" i18n-title>
|
||||
<pngx-widget-frame title="Statistics" [loading]="loading" i18n-title>
|
||||
<ng-container content>
|
||||
<div class="list-group border-light">
|
||||
<a class="list-group-item list-group-item-action d-flex justify-content-between align-items-center" title="Go to inbox" i18n-title href="javascript:void(0)" *ngIf="statistics?.documents_inbox !== null" (click)="goToInbox()">
|
||||
@@ -43,4 +43,4 @@
|
||||
</div>
|
||||
</div>
|
||||
</ng-container>
|
||||
</app-widget-frame>
|
||||
</pngx-widget-frame>
|
||||
|
@@ -21,7 +21,7 @@ interface DocumentFileType {
|
||||
}
|
||||
|
||||
@Component({
|
||||
selector: 'app-statistics-widget',
|
||||
selector: 'pngx-statistics-widget',
|
||||
templateUrl: './statistics-widget.component.html',
|
||||
styleUrls: ['./statistics-widget.component.scss'],
|
||||
})
|
||||
|
@@ -1,4 +1,4 @@
|
||||
<app-widget-frame title="Upload new documents" i18n-title>
|
||||
<pngx-widget-frame title="Upload new documents" i18n-title>
|
||||
<div header-buttons>
|
||||
<a *ngIf="getStatusSuccess().length > 0" (click)="dismissCompleted()" [routerLink]="[]" >
|
||||
<span class="me-1" i18n="This button dismisses all status messages about processed documents on the dashboard (failed and successful)">Dismiss completed</span>
|
||||
@@ -9,7 +9,7 @@
|
||||
</a>
|
||||
</div>
|
||||
<div content tourAnchor="tour.upload-widget">
|
||||
<form *appIfPermissions="{ action: PermissionAction.Add, type: PermissionType.Document }">
|
||||
<form *pngxIfPermissions="{ action: PermissionAction.Add, type: PermissionType.Document }">
|
||||
<ngx-file-drop dropZoneLabel="Drop documents here or" browseBtnLabel="Browse files" (onFileDrop)="dropped($event)"
|
||||
(onFileOver)="fileOver($event)" (onFileLeave)="fileLeave($event)" dropZoneClassName="bg-light card"
|
||||
multiple="true" contentClassName="justify-content-center d-flex align-items-center py-5 px-2" [showBrowseBtn]=true
|
||||
@@ -33,14 +33,14 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</app-widget-frame>
|
||||
</pngx-widget-frame>
|
||||
|
||||
<ng-template #consumerAlert let-status>
|
||||
<ngb-alert type="secondary" class="mt-2 mb-0" [dismissible]="isFinished(status)" (closed)="dismiss(status)">
|
||||
<h6 class="alert-heading">{{status.filename}}</h6>
|
||||
<p class="mb-0 pb-1" *ngIf="!isFinished(status) || (isFinished(status) && !status.documentId)">{{status.message}}</p>
|
||||
<ngb-progressbar [value]="status.getProgress()" [max]="1" [type]="getStatusColor(status)"></ngb-progressbar>
|
||||
<div *appIfPermissions="{ action: PermissionAction.View, type: PermissionType.Document }">
|
||||
<div *pngxIfPermissions="{ action: PermissionAction.View, type: PermissionType.Document }">
|
||||
<div *ngIf="isFinished(status)">
|
||||
<button *ngIf="status.documentId" class="btn btn-sm btn-outline-primary btn-open" routerLink="/documents/{{status.documentId}}" (click)="dismiss(status)">
|
||||
<small i18n>Open document</small>
|
||||
|
@@ -11,7 +11,7 @@ import { UploadDocumentsService } from 'src/app/services/upload-documents.servic
|
||||
const MAX_ALERTS = 5
|
||||
|
||||
@Component({
|
||||
selector: 'app-upload-file-widget',
|
||||
selector: 'pngx-upload-file-widget',
|
||||
templateUrl: './upload-file-widget.component.html',
|
||||
styleUrls: ['./upload-file-widget.component.scss'],
|
||||
})
|
||||
|
@@ -2,7 +2,7 @@ import { Component, EventEmitter, Output } from '@angular/core'
|
||||
import { TourService } from 'ngx-ui-tour-ng-bootstrap'
|
||||
|
||||
@Component({
|
||||
selector: 'app-welcome-widget',
|
||||
selector: 'pngx-welcome-widget',
|
||||
templateUrl: './welcome-widget.component.html',
|
||||
styleUrls: ['./welcome-widget.component.scss'],
|
||||
})
|
||||
|
@@ -9,7 +9,7 @@ import { WidgetFrameComponent } from './widget-frame.component'
|
||||
template: `
|
||||
<div>
|
||||
<button
|
||||
*appIfObjectPermissions="{
|
||||
*pngxIfObjectPermissions="{
|
||||
object: { id: 2, owner: user1 },
|
||||
action: 'view'
|
||||
}"
|
||||
|
@@ -1,7 +1,7 @@
|
||||
import { Component, Input } from '@angular/core'
|
||||
|
||||
@Component({
|
||||
selector: 'app-widget-frame',
|
||||
selector: 'pngx-widget-frame',
|
||||
templateUrl: './widget-frame.component.html',
|
||||
styleUrls: ['./widget-frame.component.scss'],
|
||||
})
|
||||
|
Reference in New Issue
Block a user