Interne Schaltflächen wurden entfernt. Stattdessen wurden externe Sende- und Aktualisierungsschaltflächen hinzugefügt.

This commit is contained in:
Developer 02
2024-05-23 13:52:37 +02:00
parent 60afdc23da
commit 2014f6149d
5 changed files with 39 additions and 5 deletions

View File

@@ -7,9 +7,26 @@
#app {
background: gray;
width: 100vw;
height: 1vh;
height: 80vh;
}
.btn-group {
margin-right: 10vw;
margin-bottom: 10vh;
}
.btn_refresh, .btn_complete {
height:4vh
}
.btn_refresh {
}
.btn_complete{
}
.btn_complete .icon {
width: 2vh;
}
.btn_complete span {
vertical-align: middle;
}
.button-finish {
transition: background-color linear 300ms;

View File

@@ -65,7 +65,6 @@ class App {
)
// Load annotations into PSPDFKit
try {
this.signatureCount = this.currentDocument.elements.length
const annotations = this.Annotation.createAnnotations(
@@ -84,6 +83,10 @@ class App {
}
} catch (e) {
}
//add click events of external buttons
[...document.getElementsByClassName('btn_refresh')].forEach(btn => btn.addEventListener('click', _ => this.handleClick('RESET')));
[...document.getElementsByClassName('btn_complete')].forEach(btn => btn.addEventListener('click', _ => this.handleClick('FINISH')));
}
handleAnnotationsLoad(loadedAnnotations) {
@@ -165,7 +168,6 @@ class App {
}
async handleFinish(event) {
const validationResult = await this.validateAnnotations(this.signatureCount)
if (validationResult === false) {
Swal.fire({

View File

@@ -68,6 +68,7 @@
}
getCustomItems = function (callback) {
return []
return [
{
type: 'custom',