diff --git a/package-lock.json b/package-lock.json index 29da6f9..5ae9262 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1355,18 +1355,47 @@ } }, "@vue/cli-plugin-router": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/@vue/cli-plugin-router/-/cli-plugin-router-4.3.1.tgz", - "integrity": "sha512-m0ntr5R6q62oNMODgoyHAVAd/sDtsH15GdBrScZsPNeyHxmzmNBDlsNM38yYGGY064zDRRWif15d1yaTREybrA==", + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@vue/cli-plugin-router/-/cli-plugin-router-4.4.1.tgz", + "integrity": "sha512-kCSsJG7pjDvCJDjGtcCI5l0UjmqwNigOR41RkeGSjSUvzV4ArSniXjFqrOmtpMp36S5xCtwtt9MFm/K4fCubkQ==", "dev": true, "requires": { - "@vue/cli-shared-utils": "^4.3.1" + "@vue/cli-shared-utils": "^4.4.1" + }, + "dependencies": { + "@vue/cli-shared-utils": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@vue/cli-shared-utils/-/cli-shared-utils-4.4.1.tgz", + "integrity": "sha512-teevHgI7XUsKVMOncx3M+6iLjO28woGfRwgUG4hR83moVBHQe5x2OCr2i5t/58bwpv269RD5RYXBQCGtIXuxZw==", + "dev": true, + "requires": { + "@hapi/joi": "^15.0.1", + "chalk": "^2.4.2", + "execa": "^1.0.0", + "launch-editor": "^2.2.1", + "lru-cache": "^5.1.1", + "node-ipc": "^9.1.1", + "open": "^6.3.0", + "ora": "^3.4.0", + "read-pkg": "^5.1.1", + "request": "^2.88.2", + "request-promise-native": "^1.0.8", + "semver": "^6.1.0", + "strip-ansi": "^6.0.0" + } + }, + "semver": { + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", + "dev": true + } } }, "@vue/cli-plugin-vuex": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/@vue/cli-plugin-vuex/-/cli-plugin-vuex-4.3.1.tgz", - "integrity": "sha512-mukwOlhZGBJhkqO2b3wHFFHjK5aP00b1WUHdrOfLR7M18euhaTyb4kA5nwZwEOmU3EzZx6kHzSFCRy/XaMkLug==", + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@vue/cli-plugin-vuex/-/cli-plugin-vuex-4.4.1.tgz", + "integrity": "sha512-FtOFsDP0qznwVaCz0BZmTzUm5vhHSJzX2/XD3L5dLTkrNxyDEbZmbKoX0n1OzBcQwZC7dkJZP2tdoCQx0mX//g==", "dev": true }, "@vue/cli-service": { @@ -2885,9 +2914,9 @@ } }, "buefy": { - "version": "0.8.17", - "resolved": "https://registry.npmjs.org/buefy/-/buefy-0.8.17.tgz", - "integrity": "sha512-lLAnLjc8dQpGnLML+4tKpP2yUi/WAQ38ukR5qAMq7Cc9J0sbwy1kXAHarEPlOZkQFzx6c3VmHgL7/qGsupszrQ==", + "version": "0.8.20", + "resolved": "https://registry.npmjs.org/buefy/-/buefy-0.8.20.tgz", + "integrity": "sha512-pg8Cn0m9cjqp2/vaKT4VIfU8KIumuX/gAT1GtearXRs56+kKqAPx3j9O8cm9W6P4jPUCHajKX6H8AqD0ram2Bg==", "requires": { "bulma": "0.7.5" }, @@ -5021,9 +5050,9 @@ "dev": true }, "electron": { - "version": "6.1.11", - "resolved": "https://registry.npmjs.org/electron/-/electron-6.1.11.tgz", - "integrity": "sha512-HCXp6GT0PIRjYWzRvA/M8XX76K511TRM63SmcPtmcOAjZ9sopVYC5abSojdcGHbcT6BUKBMXSsPxoyZ+SZUFEg==", + "version": "6.1.12", + "resolved": "https://registry.npmjs.org/electron/-/electron-6.1.12.tgz", + "integrity": "sha512-RUPM8xJfTcm53V9EKMBhvpLu1+CQkmuvWDmVCypR5XbUG1OOrOLiKl0CqUZ9+tEDuOmC+DmzmJP2MZXScBU5IA==", "dev": true, "requires": { "@types/node": "^10.12.18", @@ -5032,9 +5061,9 @@ }, "dependencies": { "@types/node": { - "version": "10.17.21", - "resolved": "https://registry.npmjs.org/@types/node/-/node-10.17.21.tgz", - "integrity": "sha512-PQKsydPxYxF1DsAFWmunaxd3sOi3iMt6Zmx/tgaagHYmwJ/9cRH91hQkeJZaUGWbvn0K5HlSVEXkn5U/llWPpQ==", + "version": "10.17.24", + "resolved": "https://registry.npmjs.org/@types/node/-/node-10.17.24.tgz", + "integrity": "sha512-5SCfvCxV74kzR3uWgTYiGxrd69TbT1I6+cMx1A5kEly/IVveJBimtAMlXiEyVFn5DvUFewQWxOOiJhlxeQwxgA==", "dev": true } } @@ -5698,9 +5727,9 @@ "dev": true }, "eventemitter3": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.0.tgz", - "integrity": "sha512-qerSRB0p+UDEssxTtm6EDKcE7W4OaoisfIMl4CngyEhjpYglocpNg6UEqCvemdGhosAsg4sO2dXJOdyBifPGCg==", + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-4.0.4.tgz", + "integrity": "sha512-rlaVLnVxtxvoyLsQQFBx53YmXHDxRIzzTLbdfxqi4yocpSjAxXwkU0cScM5JgSKMqEhrZpnvQ2D9gjylR0AimQ==", "dev": true }, "events": { @@ -6994,9 +7023,9 @@ } }, "http-proxy": { - "version": "1.18.0", - "resolved": "https://registry.npmjs.org/http-proxy/-/http-proxy-1.18.0.tgz", - "integrity": "sha512-84I2iJM/n1d4Hdgc6y2+qY5mDaz2PUVjlg9znE9byl+q0uC3DeByqBGReQu5tpLK0TAqTIXScRUV+dg7+bUPpQ==", + "version": "1.18.1", + "resolved": "https://registry.npmjs.org/http-proxy/-/http-proxy-1.18.1.tgz", + "integrity": "sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ==", "dev": true, "requires": { "eventemitter3": "^4.0.0", @@ -8447,8 +8476,7 @@ "minimist": { "version": "1.2.5", "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", - "dev": true + "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==" }, "minipass": { "version": "3.1.1", @@ -13234,9 +13262,9 @@ "dev": true }, "vue-i18n": { - "version": "8.17.6", - "resolved": "https://registry.npmjs.org/vue-i18n/-/vue-i18n-8.17.6.tgz", - "integrity": "sha512-SsKL5D9Ii3zJPsFhUSllY754XuZvP8uCouUm+Mbylu95h3OwenV09uzIIEjkT7EtWyDQuWSMWObrNaD4ukBGZw==" + "version": "8.18.1", + "resolved": "https://registry.npmjs.org/vue-i18n/-/vue-i18n-8.18.1.tgz", + "integrity": "sha512-K+hFQJksF8Ph23pnhbwSyoQx+4Y1q/rh2o7GiXI/3rLCCrwanUbzudC8+trp0Mb8rn9y83DYF6RXNrMd+VsuCw==" }, "vue-i18n-extract": { "version": "1.0.2", @@ -13401,14 +13429,14 @@ } }, "vue-router": { - "version": "3.1.6", - "resolved": "https://registry.npmjs.org/vue-router/-/vue-router-3.1.6.tgz", - "integrity": "sha512-GYhn2ynaZlysZMkFE5oCHRUTqE8BWs/a9YbKpNLi0i7xD6KG1EzDqpHQmv1F5gXjr8kL5iIVS8EOtRaVUEXTqA==" + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/vue-router/-/vue-router-3.3.2.tgz", + "integrity": "sha512-5sEbcfb7MW8mY8lbUVbF4kgcipGXsagkM/X+pb6n0MhjP+RorWIUTPAPSqgPaiPOxVCXgAItBl8Vwz8vq78faA==" }, "vue-sidebar-menu": { - "version": "4.5.3", - "resolved": "https://registry.npmjs.org/vue-sidebar-menu/-/vue-sidebar-menu-4.5.3.tgz", - "integrity": "sha512-NijPJvUmMNmkMzUHEBYpSdlyhJnhfXefgMEK+D89mdFkZI2mRWnEo5sRlkNoYw7HHoyB0ObPfAyKstNX8pBFmg==", + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/vue-sidebar-menu/-/vue-sidebar-menu-4.5.4.tgz", + "integrity": "sha512-KSH56kwG+R0uPi4hCj3YYp0AMcIAlVQqdOPNYzeN+3bmGF2/2s/T5ks/KpmBPbgvTf0z2LVwcweKrVeGIPq25A==", "requires": { "path-to-regexp": "^1.7.0", "vue": "^2.5.21" @@ -13464,9 +13492,9 @@ "dev": true }, "vuex": { - "version": "3.3.0", - "resolved": "https://registry.npmjs.org/vuex/-/vuex-3.3.0.tgz", - "integrity": "sha512-1MfcBt+YFd20DPwKe0ThhYm1UEXZya4gVKUvCy7AtS11YAOUR+9a6u4fsv1Rr6ePZCDNxW/M1zuIaswp6nNv8Q==" + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/vuex/-/vuex-3.4.0.tgz", + "integrity": "sha512-ajtqwEW/QhnrBZQsZxCLHThZZaa+Db45c92Asf46ZDXu6uHXgbfVuBaJ4gzD2r4UX0oMJHstFwd2r2HM4l8umg==" }, "vuex-persist": { "version": "2.2.0", diff --git a/package.json b/package.json index 00f800b..f3c11f3 100644 --- a/package.json +++ b/package.json @@ -16,27 +16,26 @@ "dependencies": { "@fortawesome/fontawesome-free": "^5.13.0", "axios": "^0.19.2", - "buefy": "^0.8.17", + "buefy": "^0.8.20", "bulma": "^0.8.2", "core-js": "^3.6.4", - "electron-log": "^4.2.0", - "is-electron": "^2.2.0", + "minimist": "^1.2.5", "secure-ls": "^1.2.6", "vue": "^2.6.11", - "vue-i18n": "^8.17.3", - "vue-router": "^3.1.6", - "vue-sidebar-menu": "^4.5.3", - "vuex": "^3.1.3", + "vue-i18n": "^8.18.1", + "vue-router": "^3.3.2", + "vue-sidebar-menu": "^4.5.4", + "vuex": "^3.4.0", "vuex-persist": "^2.2.0" }, "devDependencies": { "@vue/cli-plugin-babel": "~4.3.0", "@vue/cli-plugin-eslint": "~4.3.0", - "@vue/cli-plugin-router": "^4.3.1", - "@vue/cli-plugin-vuex": "^4.3.1", + "@vue/cli-plugin-router": "^4.4.1", + "@vue/cli-plugin-vuex": "^4.4.1", "@vue/cli-service": "~4.3.0", "babel-eslint": "^10.1.0", - "electron": "^6.0.0", + "electron": "^6.1.12", "eslint": "^6.7.2", "eslint-plugin-vue": "^6.2.2", "vue-cli-plugin-electron-builder": "^1.4.6", diff --git a/postman/POEditor.postman_collection.json b/postman/POEditor.postman_collection.json new file mode 100644 index 0000000..b63619c --- /dev/null +++ b/postman/POEditor.postman_collection.json @@ -0,0 +1,175 @@ +{ + "info": { + "_postman_id": "200deb21-86cb-4933-8438-d935b1fa48f4", + "name": "POEditor", + "description": "In this collection, we access the POEditor API\n\nWe use a ReadOnly Token for that, as well as an ID for our translation project", + "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" + }, + "item": [ + { + "name": "Get-Languages", + "request": { + "method": "POST", + "header": [], + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "id", + "value": "{{id}}", + "type": "text" + }, + { + "key": "api_token", + "value": "{{api-token}}", + "type": "text" + } + ] + }, + "url": { + "raw": "https://api.poeditor.com/v2/languages/list", + "protocol": "https", + "host": [ + "api", + "poeditor", + "com" + ], + "path": [ + "v2", + "languages", + "list" + ] + }, + "description": "Get a list of languages avail on the POEditor.com site" + }, + "response": [] + }, + { + "name": "Get-Translators", + "request": { + "method": "POST", + "header": [], + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "api_token", + "value": "{{api-token}}", + "type": "text" + }, + { + "key": "id", + "value": "{{id}}", + "type": "text" + } + ] + }, + "url": { + "raw": "https://api.poeditor.com/v2/contributors/list", + "protocol": "https", + "host": [ + "api", + "poeditor", + "com" + ], + "path": [ + "v2", + "contributors", + "list" + ] + }, + "description": "Get a list of translators, and what they translated" + }, + "response": [] + }, + { + "name": "GetTanslationLink", + "request": { + "method": "POST", + "header": [], + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "id", + "value": "{{id}}", + "description": "id of project. Defined at folder level", + "type": "text" + }, + { + "key": "api_token", + "value": "{{api-token}}", + "description": "api token. Defined at folder level", + "type": "text" + }, + { + "key": "language", + "value": "da", + "description": "language", + "type": "text" + }, + { + "key": "type", + "value": "key_value_json", + "description": "format of file to download", + "type": "text" + } + ] + }, + "url": { + "raw": "https://api.poeditor.com/v2/projects/export", + "protocol": "https", + "host": [ + "api", + "poeditor", + "com" + ], + "path": [ + "v2", + "projects", + "export" + ] + }, + "description": "Retrieves a download link for a translated language" + }, + "response": [] + } + ], + "event": [ + { + "listen": "prerequest", + "script": { + "id": "c5196d1d-7a09-4e04-b536-96d299778cca", + "type": "text/javascript", + "exec": [ + "" + ] + } + }, + { + "listen": "test", + "script": { + "id": "bda2c131-bb1a-467b-8074-18be164c1138", + "type": "text/javascript", + "exec": [ + "" + ] + } + } + ], + "variable": [ + { + "id": "c579020f-38a0-4f03-b6a9-5a621ebb0b57", + "key": "id", + "value": "342617", + "type": "string" + }, + { + "id": "358c824e-cc8d-49e9-9925-e01a4ddcb649", + "key": "api-token", + "value": "5166c4294ff7fb3a82cbdc82958e850e", + "type": "string" + } + ], + "protocolProfileBehavior": {} +} \ No newline at end of file diff --git a/postman/WebTools-NG.postman_environment.json b/postman/WebTools-NG.postman_environment.json new file mode 100644 index 0000000..f9e2840 --- /dev/null +++ b/postman/WebTools-NG.postman_environment.json @@ -0,0 +1,34 @@ +{ + "id": "8a252d90-179f-44a8-9187-1c3f7b61c533", + "name": "WebTools-NG", + "values": [ + { + "key": "AccessToken", + "value": "", + "enabled": true + }, + { + "key": "PMSAddress", + "value": "http://127.0.0.1:32400", + "enabled": true + }, + { + "key": "X-Plex-Token", + "value": "", + "enabled": true + }, + { + "key": "Pwd-PlexTV", + "value": "", + "enabled": true + }, + { + "key": "Usr-PlexTV", + "value": "dane22", + "enabled": true + } + ], + "_postman_variable_scope": "environment", + "_postman_exported_at": "2020-05-22T12:35:23.944Z", + "_postman_exported_using": "Postman/7.25.0" +} diff --git a/postman/plex.tv.postman_collection.json b/postman/plex.tv.postman_collection.json new file mode 100644 index 0000000..145f8b8 --- /dev/null +++ b/postman/plex.tv.postman_collection.json @@ -0,0 +1,137 @@ +{ + "info": { + "_postman_id": "52332b53-b724-431c-b1f4-82b9757ebac0", + "name": "plex.tv", + "description": "Calls agains plex.tv api site\n\nReq. a local defined environtment named plex with the following entries\n\nX-Plex-Token: leave empty, since will be populated after a login\nUser: plex.tv user\nPwd: plex.tv users password\n\n\nWe also has variables defined at this folder level", + "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" + }, + "item": [ + { + "name": "Login", + "event": [ + { + "listen": "test", + "script": { + "id": "06dac4ba-3dd6-477e-978c-9bf94955e33a", + "exec": [ + "var data = JSON.parse(responseBody);", + "postman.setEnvironmentVariable(\"X-Plex-Token\", data.authToken)", + "console.log(\"AuthToken-PlexTV:\", postman.getEnvironmentVariable(\"X-Plex-Token\"))" + ], + "type": "text/javascript" + } + } + ], + "request": { + "method": "POST", + "header": [ + { + "key": "X-Plex-Client-Identifier", + "value": "{{X-Plex-Client-Identifier}}", + "type": "text" + }, + { + "key": "Accept", + "value": "application/json", + "type": "text" + } + ], + "url": { + "raw": "{{plextvapi}}/v2/users/signin?login={{Usr-PlexTV}}&password={{Pwd-PlexTV}}", + "host": [ + "{{plextvapi}}" + ], + "path": [ + "v2", + "users", + "signin" + ], + "query": [ + { + "key": "login", + "value": "{{Usr-PlexTV}}" + }, + { + "key": "password", + "value": "{{Pwd-PlexTV}}" + } + ] + }, + "description": "Use two defined local environtment variables named:\nUser\nPwd\n\nAbove are credentials for plex.tv\n\nA third variable named X-Plex-Token, that after a login will be populated with a token, other calls can use" + }, + "response": [] + }, + { + "name": "Get-Resources", + "request": { + "method": "GET", + "header": [ + { + "key": "X-Plex-Token", + "value": "{{X-Plex-Token}}", + "type": "text" + }, + { + "key": "X-Plex-Client-Identifier", + "value": "{{X-Plex-Client-Identifier}}", + "type": "text" + }, + { + "key": "Accept", + "value": "application/json", + "type": "text" + } + ], + "url": { + "raw": "{{plextvapi}}/v2/resources", + "host": [ + "{{plextvapi}}" + ], + "path": [ + "v2", + "resources" + ] + }, + "description": "Get Resources avail for the current plex.tv user" + }, + "response": [] + } + ], + "event": [ + { + "listen": "prerequest", + "script": { + "id": "0355f113-7ed5-4483-ac99-01f8665a8df5", + "type": "text/javascript", + "exec": [ + "" + ] + } + }, + { + "listen": "test", + "script": { + "id": "3d4cf58b-80b8-415e-b376-16a44cfbbd0d", + "type": "text/javascript", + "exec": [ + "" + ] + } + } + ], + "variable": [ + { + "id": "12749f23-3086-47bd-a268-6e1dfa5bc5c5", + "key": "plextvapi", + "value": "https://plex.tv/api", + "type": "string" + }, + { + "id": "ee6d38c1-4cd1-4fec-9d63-abab0174e473", + "key": "X-Plex-Client-Identifier", + "value": "WebTools-NG", + "type": "string" + } + ], + "protocolProfileBehavior": {} +} \ No newline at end of file diff --git a/postman/pms.postman_collection.json b/postman/pms.postman_collection.json new file mode 100644 index 0000000..f26f0f1 --- /dev/null +++ b/postman/pms.postman_collection.json @@ -0,0 +1,130 @@ +{ + "info": { + "_postman_id": "daa2f31c-1db6-410b-a2ad-c8f4acc01d33", + "name": "pms", + "description": "In the PMS collection, we store calls against a local PMS\n\nIt req. some local variables, named PMSAddress and AccessToken", + "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json" + }, + "item": [ + { + "name": "Get-Sections", + "request": { + "method": "GET", + "header": [ + { + "key": "Accept", + "value": "application/json", + "type": "text" + }, + { + "key": "X-Plex-Token", + "value": "{{AccessToken}}", + "type": "text" + } + ], + "url": { + "raw": "{{PMSAddress}}/library/sections/all", + "host": [ + "{{PMSAddress}}" + ], + "path": [ + "library", + "sections", + "all" + ] + }, + "description": "Will get a list of sections (Libraries) from a PMS\n\nWhat we need, is the key, type and title" + }, + "response": [] + }, + { + "name": "Get-MovieSection", + "request": { + "method": "GET", + "header": [ + { + "key": "Accept", + "type": "text", + "value": "application/json" + }, + { + "key": "X-Plex-Token", + "type": "text", + "value": "{{AccessToken}}" + } + ], + "url": { + "raw": "{{PMSAddress}}/library/sections/{{MovieSection}}/all?type=1&X-Plex-Container-Start=31&X-Plex-Container-Size={{CONTAINERSIZEMOVIES}}", + "host": [ + "{{PMSAddress}}" + ], + "path": [ + "library", + "sections", + "{{MovieSection}}", + "all" + ], + "query": [ + { + "key": "type", + "value": "1" + }, + { + "key": "X-Plex-Container-Start", + "value": "31" + }, + { + "key": "X-Plex-Container-Size", + "value": "{{CONTAINERSIZEMOVIES}}" + } + ] + }, + "description": "Will get a list of sections (Libraries) from a PMS\n\nWhat we need, is the key, type and title" + }, + "response": [] + } + ], + "event": [ + { + "listen": "prerequest", + "script": { + "id": "fe0095c1-f667-415f-bd56-9f081ad198e4", + "type": "text/javascript", + "exec": [ + "" + ] + } + }, + { + "listen": "test", + "script": { + "id": "83a53476-85dc-43a7-a656-9c273ff0c0d1", + "type": "text/javascript", + "exec": [ + "" + ] + } + } + ], + "variable": [ + { + "id": "e101680f-7df5-4c66-8b17-ab7df3aee299", + "key": "X-Plex-Client-Identifier", + "value": "WebTools-NG", + "type": "string" + }, + { + "id": "11c72d02-77f6-4698-afbc-989b4557bc94", + "key": "MovieSection", + "value": "4", + "type": "string" + }, + { + "id": "7694f803-748a-428d-b762-e7441becd677", + "key": "CONTAINERSIZEMOVIES", + "value": "30", + "type": "string" + } + ], + "protocolProfileBehavior": {} +} \ No newline at end of file diff --git a/src/App.vue b/src/App.vue index 3f53039..4c5957b 100644 --- a/src/App.vue +++ b/src/App.vue @@ -1,10 +1,8 @@