Skip to content
Snippets Groups Projects
Commit 322e4625 authored by Reiter, Christoph's avatar Reiter, Christoph :snake:
Browse files

Fix existing signatures not showing

They now check in multiple places for the signature, so replace all occurences.
To prevent this happening in the future also pin the release.
parent 8f0fccaf
No related branches found
No related tags found
No related merge requests found
Pipeline #17448 failed
......@@ -52,7 +52,7 @@
"jszip": "^3.5.0",
"lit-element": "^2.3.1",
"lit-html": "^1.2.1",
"pdfjs-dist": "^2.4.456",
"pdfjs-dist": "2.6.347",
"universal-router": "^9.0.1",
"webdav": "^3.3.0"
},
......
......@@ -73,6 +73,9 @@ httpbin.org ${getOrigin(config.nextcloudBaseURL)} www.handy-signatur.at \
${getOrigin(config.pdfAsQualifiedlySigningServer)}; \
img-src * blob: data:`;
function replaceAll(string, search, replace) {
return string.split(search).join(replace);
}
export default (async () => {
let privatePath = await getDistPath(pkg.name)
......@@ -190,7 +193,7 @@ Dependencies:
src: await getPackagePath('pdfjs-dist', 'es5/build/pdf.worker.js'),
dest: 'dist/' + await getDistPath(pkg.name, 'pdfjs'),
// enable signatures in pdf preview
transform: (contents) => contents.toString().replace('"Sig"', '"Sig-patched-show-anyway"')
transform: (contents) => replaceAll(contents.toString(), '"Sig"', '"Sig-patched-show-anyway"')
},
{src: await getPackagePath('pdfjs-dist', 'cmaps/*'), dest: 'dist/' + await getDistPath(pkg.name, 'pdfjs')}, // do we want all map files?
{src: await getPackagePath('@dbp-toolkit/font-source-sans-pro', 'files/*'), dest: 'dist/' + await getDistPath(pkg.name, 'fonts/source-sans-pro')},
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment