Skip to content
Snippets Groups Projects
Unverified Commit c7d7c2bd authored by Bekerle, Patrizio's avatar Bekerle, Patrizio :fire:
Browse files

Refactor dbp-annotation-view to dbp-pdf-annotation-view (#37)

parent 4c8b205a
No related branches found
No related tags found
No related merge requests found
Pipeline #18906 passed
......@@ -18,7 +18,7 @@ import {send as notify} from '@dbp-toolkit/common/notification';
import {OrganizationSelect} from "@dbp-toolkit/organization-select";
import metadata from './dbp-official-signature-pdf-upload.metadata.json';
import {Activity} from './activity.js';
import {AnnotationView} from "./dbp-annotation-view";
import {PdfAnnotationView} from "./dbp-pdf-annotation-view";
const i18n = createI18nInstance();
......@@ -67,7 +67,7 @@ class OfficialSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitElem
'dbp-button': Button,
'dbp-textswitch': TextSwitch,
'dbp-organization-select': OrganizationSelect,
'dbp-annotation-view': AnnotationView,
'dbp-pdf-annotation-view': PdfAnnotationView,
};
}
......@@ -966,9 +966,9 @@ class OfficialSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitElem
<button class="button is-cancel annotation"
@click="${this.hideAnnotationView}"><dbp-icon name="close" id="close-icon"></dbp-icon></button>
</div>
<dbp-annotation-view lang="${this.lang}"
<dbp-pdf-annotation-view lang="${this.lang}"
@dbp-pdf-annotations-save="${this.processAnnotationEvent}"
@dbp-pdf-annotations-cancel="${this.hideAnnotationView}"></dbp-annotation-view>
@dbp-pdf-annotations-cancel="${this.hideAnnotationView}"></dbp-pdf-annotation-view>
</div>
<!-- File upload progress -->
<div id="upload-progress" class="field notification is-info ${classMap({hidden: !this.uploadInProgress})}">
......
......@@ -11,9 +11,9 @@ import * as utils from './utils';
const i18n = createI18nInstance();
/**
* AnnotationView web component
* PdfAnnotationView web component
*/
export class AnnotationView extends ScopedElementsMixin(DBPLitElement) {
export class PdfAnnotationView extends ScopedElementsMixin(DBPLitElement) {
constructor() {
super();
this.lang = 'de';
......
......@@ -18,7 +18,7 @@ import {getPDFSignatureCount} from './utils.js';
import {send as notify} from '@dbp-toolkit/common/notification';
import metadata from './dbp-qualified-signature-pdf-upload.metadata.json';
import {Activity} from './activity.js';
import {AnnotationView} from "./dbp-annotation-view";
import {PdfAnnotationView} from "./dbp-pdf-annotation-view";
const i18n = createI18nInstance();
......@@ -71,7 +71,7 @@ class QualifiedSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitEle
'dbp-mini-spinner': MiniSpinner,
'dbp-button': Button,
'dbp-textswitch': TextSwitch,
'dbp-annotation-view': AnnotationView,
'dbp-pdf-annotation-view': PdfAnnotationView,
};
}
......@@ -1130,9 +1130,9 @@ class QualifiedSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitEle
<button class="button is-cancel annotation"
@click="${this.hideAnnotationView}"><dbp-icon name="close" id="close-icon"></dbp-icon></button>
</div>
<dbp-annotation-view lang="${this.lang}"
<dbp-pdf-annotation-view lang="${this.lang}"
@dbp-pdf-annotations-save="${this.processAnnotationEvent}"
@dbp-pdf-annotations-cancel="${this.hideAnnotationView}"></dbp-annotation-view>
@dbp-pdf-annotations-cancel="${this.hideAnnotationView}"></dbp-pdf-annotation-view>
</div>
<!-- File upload progress -->
<div id="upload-progress" class="field notification is-info ${classMap({hidden: !this.uploadInProgress})}">
......
......@@ -116,7 +116,7 @@ export default class DBPSignatureLitElement extends DBPSignatureBaseLitElement {
*
* @param {*} key
* @param {*} name
* @returns shows AnnotationView
* @returns shows PdfAnnotationView
*/
async showAnnotationView(key, name) {
if (this.signingProcessEnabled) {
......@@ -129,7 +129,7 @@ export default class DBPSignatureLitElement extends DBPSignatureBaseLitElement {
this.currentPreviewQueueKey = key;
console.log(file);
const viewTag = this.constructor.getScopedTagName('dbp-annotation-view');
const viewTag = this.constructor.getScopedTagName('dbp-pdf-annotation-view');
this._(viewTag).setAttribute('key', key);
this.isAnnotationViewVisible = true;
......@@ -153,7 +153,7 @@ export default class DBPSignatureLitElement extends DBPSignatureBaseLitElement {
}
/**
* Hides the AnnotationView
* Hides the PdfAnnotationView
*/
hideAnnotationView() {
this._("#annotation-switch").name = "no-text";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment