mirror of
https://github.com/24eme/signaturepdf.git
synced 2023-08-25 09:33:08 +02:00
Message to inform that in private browsing mode (on firefox) the application does not work because opening the cache is impossible
This commit is contained in:
parent
30e7ffef89
commit
a1509a554f
@ -246,7 +246,14 @@ var pageUpload = async function() {
|
||||
document.getElementById('page-upload').classList.remove('d-none');
|
||||
document.getElementById('page-metadata').classList.add('d-none');
|
||||
document.getElementById('input_pdf_upload').focus();
|
||||
const cache = await caches.open('pdf');
|
||||
let cache;
|
||||
try {
|
||||
cache = await caches.open('pdf');
|
||||
} catch (e) {
|
||||
console.error(e)
|
||||
alert("Erreur d'accès au cache. Cette application ne fonctionne pas en mode de navigation privée");
|
||||
return;
|
||||
}
|
||||
document.getElementById('input_pdf_upload').addEventListener('change', async function(event) {
|
||||
let filename = document.getElementById('input_pdf_upload').files[0].name;
|
||||
let response = new Response(document.getElementById('input_pdf_upload').files[0], { "status" : 200, "statusText" : "OK" });
|
||||
|
@ -740,7 +740,14 @@ var pageUpload = async function() {
|
||||
document.getElementById('page-upload').classList.remove('d-none');
|
||||
document.getElementById('page-organization').classList.add('d-none');
|
||||
document.getElementById('input_pdf_upload').focus();
|
||||
const cache = await caches.open('pdf');
|
||||
let cache;
|
||||
try {
|
||||
cache = await caches.open('pdf');
|
||||
} catch (e) {
|
||||
console.error(e)
|
||||
alert("Erreur d'accès au cache. Cette application ne fonctionne pas en mode de navigation privée");
|
||||
return;
|
||||
}
|
||||
document.getElementById('input_pdf_upload').addEventListener('change', async function(event) {
|
||||
if(document.getElementById('input_pdf_upload').files[0].size > maxSize) {
|
||||
|
||||
|
@ -996,7 +996,14 @@ var pageUpload = async function() {
|
||||
document.getElementById('page-upload').classList.remove('d-none');
|
||||
document.getElementById('page-signature').classList.add('d-none');
|
||||
document.getElementById('input_pdf_upload').focus();
|
||||
const cache = await caches.open('pdf');
|
||||
let cache;
|
||||
try {
|
||||
cache = await caches.open('pdf');
|
||||
} catch (e) {
|
||||
console.error(e)
|
||||
alert("Erreur d'accès au cache. Cette application ne fonctionne pas en mode de navigation privée");
|
||||
return;
|
||||
}
|
||||
document.getElementById('input_pdf_upload').addEventListener('change', async function(event) {
|
||||
if(document.getElementById('input_pdf_upload').files[0].size > maxSize) {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user