TagSpaces is an offline, open source, document manager with tagging support
Tsn238 reintegrate cordova api (#795)
Stanimirc8f109744bb6
diff --git a/app/services/cordova-io.js b/app/services/cordova-io.jsindex f5bf58885..490f5144f 100644--- a/app/services/cordova-io.js+++ b/app/services/cordova-io.js@@ -45,6 +45,10 @@ export default class CordovaIO {onDeviceReady = () => {console.log('Device Ready: ' + window['device'].platform + ' - ' + window['device'].version);++ // attachFastClick(document.body);+ this.getFileSystem();+// iOS specific initializationif (AppConfig.isCordovaiOS) {window.plugins = window.plugins || {};@@ -74,9 +78,6 @@ export default class CordovaIO {});}- // attachFastClick(document.body);- this.getFileSystem();-if (AppConfig.isCordovaiOS) {setTimeout(() => {navigator.splashscreen.hide();@@ -352,7 +353,7 @@ export default class CordovaIO {const paths = {Photos: 'sdcard/DCIM/',Pictures: 'sdcard/Pictures/',- Downloads: 'sdcard/Downloads/',+ Download: 'sdcard/Download/',Music: 'sdcard/Music/',Movies: 'sdcard/Movies/',SDCard: 'sdcard/'diff --git a/cordova/config.xml b/cordova/config.xmlindex aa9789d53..ba75f1299 100644--- a/cordova/config.xml+++ b/cordova/config.xml@@ -15,7 +15,6 @@<allow-intent href="sms:*" /><allow-intent href="mailto:*" /><allow-intent href="geo:*" />- <allow-intent href="*://*.amazonaws.com/*" /><platform name="android"><allow-intent href="market:*" /></platform>@@ -26,6 +25,8 @@<plugin name="cordova-plugin-whitelist" spec="^1.3.3" /><plugin name="cordova-plugin-file" spec="^6.0.1" /><preference name="AndroidPersistentFileLocation" value="Compatibility" />+ <preference name="iosExtraFilesystems" value="library,library-nosync,documents,documents-nosync,cache,bundle,root" />+ <preference name="AndroidExtraFilesystems" value="files,files-external,documents,sdcard,cache,cache-external,assets,root" /><plugin name="cordova-plugin-device" spec="^2.0.2" /><engine name="android" spec="^7.1.4" /></widget>diff --git a/cordova/platforms/android/app/src/main/assets/www/index.html b/cordova/platforms/android/app/src/main/assets/www/index.htmlindex fa2f903ee..531c9e7e8 100644--- a/cordova/platforms/android/app/src/main/assets/www/index.html+++ b/cordova/platforms/android/app/src/main/assets/www/index.html@@ -1,7 +1,7 @@<!DOCTYPE html><html><head>- <meta http-equiv="Content-Security-Policy" content="connect-src *; default-src 'self' data: gap: https://ssl.gstatic.com 'unsafe-eval'; style-src 'self' 'unsafe-inline'; media-src *; img-src 'self' data: content:;">+ <meta http-equiv="Content-Security-Policy" content="connect-src *; default-src 'self' data: gap: cdvfile: https://ssl.gstatic.com amazonaws.com 'unsafe-eval'; style-src 'self' 'unsafe-inline'; media-src *; img-src 'self' data: content:;"><meta name="format-detection" content="telephone=no"><meta name="msapplication-tap-highlight" content="no"><meta charset="utf-8">diff --git a/cordova/platforms/android/app/src/main/res/xml/config.xml b/cordova/platforms/android/app/src/main/res/xml/config.xmlindex c94a36268..235ee5376 100644--- a/cordova/platforms/android/app/src/main/res/xml/config.xml+++ b/cordova/platforms/android/app/src/main/res/xml/config.xml@@ -23,8 +23,9 @@<allow-intent href="sms:*" /><allow-intent href="mailto:*" /><allow-intent href="geo:*" />- <allow-intent href="*://*.amazonaws.com/*" /><allow-intent href="market:*" /><preference name="loglevel" value="DEBUG" /><preference name="AndroidPersistentFileLocation" value="Compatibility" />+ <preference name="iosExtraFilesystems" value="library,library-nosync,documents,documents-nosync,cache,bundle,root" />+ <preference name="AndroidExtraFilesystems" value="files,files-external,documents,sdcard,cache,cache-external,assets,root" /></widget>diff --git a/cordova/www/index.html b/cordova/www/index.htmlindex fa2f903ee..531c9e7e8 100644--- a/cordova/www/index.html+++ b/cordova/www/index.html@@ -1,7 +1,7 @@<!DOCTYPE html><html><head>- <meta http-equiv="Content-Security-Policy" content="connect-src *; default-src 'self' data: gap: https://ssl.gstatic.com 'unsafe-eval'; style-src 'self' 'unsafe-inline'; media-src *; img-src 'self' data: content:;">+ <meta http-equiv="Content-Security-Policy" content="connect-src *; default-src 'self' data: gap: cdvfile: https://ssl.gstatic.com amazonaws.com 'unsafe-eval'; style-src 'self' 'unsafe-inline'; media-src *; img-src 'self' data: content:;"><meta name="format-detection" content="telephone=no"><meta name="msapplication-tap-highlight" content="no"><meta charset="utf-8">diff --git a/cordova/yarn.lock b/cordova/yarn.lockindex 8c109be1a..6ff1f8645 100644--- a/cordova/yarn.lock+++ b/cordova/yarn.lock@@ -2,7 +2,7 @@# yarn lockfile v1-abbrev@*, abbrev@1:+abbrev@1:version "1.1.1"resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8"integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==@@ -14,12 +14,12 @@ [email protected]:dependencies:semver "^5.4.1"-ansi@*, ansi@^0.3.1:+ansi@^0.3.1:version "0.3.1"resolved "https://registry.yarnpkg.com/ansi/-/ansi-0.3.1.tgz#0c42d4fb17160d5a9af1e484bace1c66922c1b21"integrity sha1-DELU+xcWDVqa8eSEus4cZpIsGyE=-balanced-match@*, balanced-match@^1.0.0:+balanced-match@^1.0.0:version "1.0.0"resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767"integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c=@@ -39,14 +39,14 @@ big-integer@^1.6.7:resolved "https://registry.yarnpkg.com/big-integer/-/big-integer-1.6.40.tgz#02e4cd4d6e266c4d9ece2469c05cb6439149fc78"integrity sha512-CjhtJp0BViLzP1ZkEnoywjgtFQXS2pomKjAJtIISTCnuHILkLcAXLdFLG/nxsHc4s9kJfc+82Xpg8WNyhfACzQ==-bplist-parser@*, bplist-parser@^0.1.0:+bplist-parser@^0.1.0:version "0.1.1"resolved "https://registry.yarnpkg.com/bplist-parser/-/bplist-parser-0.1.1.tgz#d60d5dcc20cba6dc7e1f299b35d3e1f95dafbae6"integrity sha1-1g1dzCDLptx+HymbNdPh+V2vuuY=dependencies:big-integer "^1.6.7"-brace-expansion@*, brace-expansion@^1.1.7:+brace-expansion@^1.1.7:version "1.1.11"resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd"integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==@@ -54,7 +54,7 @@ brace-expansion@*, brace-expansion@^1.1.7:balanced-match "^1.0.0"concat-map "0.0.1"-concat-map@*, [email protected]:version "0.0.1"resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=@@ -97,6 +97,11 @@ [email protected]:underscore "^1.8.3"unorm "^1.3.3"+cordova-plugin-device@^2.0.2:+ version "2.0.2"+ resolved "https://registry.yarnpkg.com/cordova-plugin-device/-/cordova-plugin-device-2.0.2.tgz#fc08f3722e67eef7b6c67bfc99a83df6add0baba"+ integrity sha1-/Ajzci5n7ve2xnv8mag99q3Quro=+cordova-plugin-file@^6.0.1:version "6.0.1"resolved "https://registry.yarnpkg.com/cordova-plugin-file/-/cordova-plugin-file-6.0.1.tgz#49606b8c15a5688d4728f92e4a7325a061de07f5"@@ -107,7 +112,7 @@ cordova-plugin-whitelist@^1.3.3:resolved "https://registry.yarnpkg.com/cordova-plugin-whitelist/-/cordova-plugin-whitelist-1.3.3.tgz#b5e85ecdbbfe5aeded40a1bf4ee2372e67d96fb4"integrity sha1-tehezbv+Wu3tQKG/TuI3LmfZb7Q=-cordova-registry-mapper@*, cordova-registry-mapper@^1.1.8:+cordova-registry-mapper@^1.1.8:version "1.1.15"resolved "https://registry.yarnpkg.com/cordova-registry-mapper/-/cordova-registry-mapper-1.1.15.tgz#e244b9185b8175473bff6079324905115f83dc7c"integrity sha1-4kS5GFuBdUc7/2B5MkkFEV+D3Hw=@@ -130,7 +135,7 @@ [email protected], glob@^5.0.13:once "^1.3.0"path-is-absolute "^1.0.0"-inflight@*, inflight@^1.0.4:+inflight@^1.0.4:version "1.0.6"resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9"integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=@@ -138,12 +143,12 @@ inflight@*, inflight@^1.0.4:once "^1.3.0"wrappy "1"-inherits@*, inherits@2:+inherits@2:version "2.0.3"resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de"integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=-minimatch@*, "minimatch@2 || 3", minimatch@^3.0.0:+"minimatch@2 || 3", minimatch@^3.0.0:version "3.0.4"resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083"integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==@@ -157,7 +162,7 @@ [email protected]:dependencies:abbrev "1"-once@*, once@^1.3.0:+once@^1.3.0:version "1.4.0"resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1"integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E=@@ -213,17 +218,17 @@ [email protected], shelljs@^0.5.3:resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.5.3.tgz#c54982b996c76ef0c1e6b59fbdc5825f5b713113"integrity sha1-xUmCuZbHbvDB5rWfvcWCX1txMRM=-underscore@*, underscore@^1.8.3:+underscore@^1.8.3:version "1.9.1"resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.9.1.tgz#06dce34a0e68a7babc29b365b8e74b8925203961"integrity sha512-5/4etnCkd9c8gwgowi5/om/mYO5ajCaOgdzj/oW+0eQV9WxKBDZw5+ycmKmeaTXjInS/W0BzpGLo2xR2aBwZdg==-unorm@*, unorm@^1.3.3:+unorm@^1.3.3:version "1.4.1"resolved "https://registry.yarnpkg.com/unorm/-/unorm-1.4.1.tgz#364200d5f13646ca8bcd44490271335614792300"integrity sha1-NkIA1fE2RsqLzURJAnEzVhR5IwA=-wrappy@*, wrappy@1:+wrappy@1:version "1.0.2"resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f"integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=@@ -233,7 +238,7 @@ [email protected]:resolved "https://registry.yarnpkg.com/xmlbuilder/-/xmlbuilder-8.2.2.tgz#69248673410b4ba42e1a6136551d2922335aa773"integrity sha1-aSSGc0ELS6QuGmE2VR0pIjNap3M=-xmldom@*, [email protected]:version "0.1.27"resolved "https://registry.yarnpkg.com/xmldom/-/xmldom-0.1.27.tgz#d501f97b3bdb403af8ef9ecc20573187aadac0e9"integrity sha1-1QH5ezvbQDr4757MIFcxh6rawOk=diff --git a/webpack.config.renderer.cordova.js b/webpack.config.renderer.cordova.jsindex db01e1c31..3ddb7f966 100644--- a/webpack.config.renderer.cordova.js+++ b/webpack.config.renderer.cordova.js@@ -9,7 +9,8 @@ import merge from 'webpack-merge';import baseConfig from './webpack.config.base';export default merge.smart(baseConfig, {- devtool: 'source-map',+ // devtool: 'source-map',+ devtool: 'inline-source-map',target: 'web',@@ -23,7 +24,7 @@ export default merge.smart(baseConfig, {optimization: {// We no not want to minimize our code. TODO remove this for production- minimize: true+ minimize: false},node: {