diff --git a/docs/config.md b/docs/config.md index 2e36b387..a044b00c 100644 --- a/docs/config.md +++ b/docs/config.md @@ -189,7 +189,7 @@ Then, add the following pipeline: description: 'ocrmypdf (JPG | @:pipeline.high-quality)', get commands() { return [ - 'convert @- -quality 92 tmp-%d.jpg && ls tmp-*.jpg', + 'convert @- -quality 92 tmp-%04d.jpg && ls tmp-*.jpg', 'convert @- pdf:-', `ocrmypdf -l ${config.ocrLanguage} --deskew --rotate-pages - scan_0000.pdf`, 'ls scan_*.*' @@ -212,3 +212,21 @@ module.exports = { } } ``` + +### Change default output directory + +Exercise caution with this recipe - the app is designed not to allow unsafe +paths by default. If you are happy to disable this check, then go ahead. + +```javascript +const dayjs = require('dayjs'); +module.exports = { + afterConfig(config) { + // Set your path here + config.outputDirectory = '/home/me/scanned'; + + // By default paths with `..` or `/` are not allowed + config.allowUnsafePaths = true; + } +} +``` diff --git a/docs/troubleshooting.md b/docs/troubleshooting.md index 285173bc..a2e91037 100644 --- a/docs/troubleshooting.md +++ b/docs/troubleshooting.md @@ -20,4 +20,11 @@ server{ proxy_send_timeout 300; ... } -``` \ No newline at end of file +``` + +## Long scan timeout + +When scanning files with high resolution, e.g. 1200dpi it is very likely for the +request to timeout. This is because node HTTP times out after 2 minutes by +default. The solution is to increase the default timeout. That's possible by +setting `config.timeout = 600000;` (for 10 minutes for example). \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 86058638..5fde73dc 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "scanservjs", - "version": "2.16.0", + "version": "2.16.1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "scanservjs", - "version": "2.16.0", + "version": "2.16.1", "hasInstallScript": true, "license": "GPL-2.0" } diff --git a/package.json b/package.json index cd114377..790637fe 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "scanservjs", - "version": "2.16.0", + "version": "2.16.1", "description": "scanservjs is a simple web-based UI for SANE which allows you to share a scanner on a network without the need for drivers or complicated installation.", "scripts": { "clean": "rm -rf ./dist", diff --git a/packages/client/package-lock.json b/packages/client/package-lock.json index f2b22c92..02c616eb 100644 --- a/packages/client/package-lock.json +++ b/packages/client/package-lock.json @@ -1,12 +1,12 @@ { "name": "scanservjs", - "version": "2.16.0", + "version": "2.16.1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "scanservjs", - "version": "2.16.0", + "version": "2.16.1", "license": "GPL-2.0", "dependencies": { "@mdi/font": "^5.9.55", diff --git a/packages/client/package.json b/packages/client/package.json index 25fc07f1..6f41ce29 100644 --- a/packages/client/package.json +++ b/packages/client/package.json @@ -1,6 +1,6 @@ { "name": "scanservjs", - "version": "2.16.0", + "version": "2.16.1", "description": "scanservjs is a simple web-based UI for SANE which allows you to share a scanner on a network without the need for drivers or complicated installation.", "author": "Sam Strachan", "scripts": { diff --git a/packages/client/src/components/Scan.vue b/packages/client/src/components/Scan.vue index 62f17831..84a1a06d 100644 --- a/packages/client/src/components/Scan.vue +++ b/packages/client/src/components/Scan.vue @@ -4,9 +4,13 @@ - +
+ + mdi-refresh +
{ + this.readContext(); + }); + }, + readPreview() { // Gets the preview image as a base64 encoded jpg and updates the UI this._fetch('preview', { diff --git a/packages/client/src/locales/es.json b/packages/client/src/locales/es.json index 211bd319..550605e1 100644 --- a/packages/client/src/locales/es.json +++ b/packages/client/src/locales/es.json @@ -88,7 +88,7 @@ "left-aligned": "Alineado a la izquierda", "centrally-aligned": "Alineado al centro", "duplex": "Dúplex", - "transparency unit": "Transparency Unit", + "transparency unit": "Unidad de transparencia", "automatic document feeder": "@:source.adf", "automatic document feeder(left aligned)": "@:source.adf (@:source.left-aligned)", @@ -147,10 +147,10 @@ "theme:dark": "Oscuro", "color": "Color", "color:description": "Color. Esto modificará el color de la barra superior.", - "devices": "Devices and storage", - "reset:description": "Clears stored scanner devices and forces a reload", + "devices": "Dispositivos y almacenamiento", + "reset:description": "Limpia los dispositivos almacenados y fuerza la recarga", "reset": "Reestablecer", - "clear-storage:description": "Clears local storage of any cached parameters", - "clear-storage": "Clear" + "clear-storage:description": "Limpia el almacenamiento local y cualquier parámetro en caché", + "clear-storage": "Limpiar" } } diff --git a/packages/server/package-lock.json b/packages/server/package-lock.json index 9a2e1c0b..b9df2a98 100644 --- a/packages/server/package-lock.json +++ b/packages/server/package-lock.json @@ -1,12 +1,12 @@ { "name": "scanservjs-server", - "version": "2.16.0", + "version": "2.16.1", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "scanservjs-server", - "version": "2.16.0", + "version": "2.16.1", "license": "GPL-2.0", "dependencies": { "adm-zip": "^0.5.5", diff --git a/packages/server/package.json b/packages/server/package.json index 22c6c8dc..7b7d2417 100644 --- a/packages/server/package.json +++ b/packages/server/package.json @@ -1,6 +1,6 @@ { "name": "scanservjs-server", - "version": "2.16.0", + "version": "2.16.1", "description": "scanservjs is a simple web-based UI for SANE which allows you to share a scanner on a network without the need for drivers or complicated installation.", "scripts": { "lint": "gulp lint",