mirror of
https://github.com/LibreSign/libresign.git
synced 2025-12-18 05:20:45 +01:00
Merge pull request #6228 from LibreSign/fix/show-only-current-signer-position
fix: show only current signer's signature position
This commit is contained in:
commit
6d52807e47
1 changed files with 11 additions and 12 deletions
|
|
@ -136,18 +136,17 @@ export default {
|
|||
this.pdfBlob = new File([blob], 'arquivo.pdf', { type: 'application/pdf' })
|
||||
},
|
||||
updateSigners(data) {
|
||||
this.signStore.document.signers.forEach(signer => {
|
||||
if (signer.visibleElements.length > 0) {
|
||||
signer.visibleElements.forEach(element => {
|
||||
const object = structuredClone(signer)
|
||||
object.readOnly = true
|
||||
element.coordinates.ury = Math.round(data.measurement[element.coordinates.page].height)
|
||||
- element.coordinates.ury
|
||||
object.element = element
|
||||
this.$refs.pdfEditor.addSigner(object)
|
||||
})
|
||||
}
|
||||
})
|
||||
const currentSigner = this.signStore.document.signers.find(signer => signer.me)
|
||||
if (currentSigner && currentSigner.visibleElements.length > 0) {
|
||||
currentSigner.visibleElements.forEach(element => {
|
||||
const object = structuredClone(currentSigner)
|
||||
object.readOnly = true
|
||||
element.coordinates.ury = Math.round(data.measurement[element.coordinates.page].height)
|
||||
- element.coordinates.ury
|
||||
object.element = element
|
||||
this.$refs.pdfEditor.addSigner(object)
|
||||
})
|
||||
}
|
||||
this.signStore.mounted = true
|
||||
},
|
||||
toggleSidebar() {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue