4 Commits

Author SHA1 Message Date
adf4a7ee05 1.0.6 2020-09-19 15:18:28 +00:00
cf7e064074 fix(core): update 2020-09-19 15:18:28 +00:00
dc9bb6a4a7 1.0.5 2020-09-18 16:13:57 +00:00
3b513c9efd fix(core): update 2020-09-18 16:13:57 +00:00
7 changed files with 140 additions and 59 deletions

84
package-lock.json generated
View File

@ -1,6 +1,6 @@
{
"name": "@consentsoftware/webclient",
"version": "1.0.4",
"version": "1.0.6",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@ -8,7 +8,6 @@
"version": "1.0.43",
"resolved": "https://verdaccio.lossless.one/@apiglobal%2ftypedrequest/-/typedrequest-1.0.43.tgz",
"integrity": "sha512-BUY6o7vzh36zUn7tH3pHGS0XTKIUJ9pp6CUxL0PT99GOWaS6aStqwAN6JwtmVuibbu/uKgPvXvIjET90vXeeHg==",
"dev": true,
"requires": {
"@apiglobal/typedrequest-interfaces": "^1.0.15",
"@pushrocks/isounique": "^1.0.4",
@ -21,8 +20,7 @@
"@apiglobal/typedrequest-interfaces": {
"version": "1.0.15",
"resolved": "https://verdaccio.lossless.one/@apiglobal%2ftypedrequest-interfaces/-/typedrequest-interfaces-1.0.15.tgz",
"integrity": "sha512-KncX168fUQJ73FeT22Cvls41mkJmtasP8dB2s9+9/OyWZpNsCzk9NEmtdRhulW2vLQwuAbQc1eoloe7ffCmhcA==",
"dev": true
"integrity": "sha512-KncX168fUQJ73FeT22Cvls41mkJmtasP8dB2s9+9/OyWZpNsCzk9NEmtdRhulW2vLQwuAbQc1eoloe7ffCmhcA=="
},
"@babel/code-frame": {
"version": "7.10.4",
@ -1126,6 +1124,14 @@
"to-fast-properties": "^2.0.0"
}
},
"@consentsoftware/interfaces": {
"version": "1.0.5",
"resolved": "https://verdaccio.lossless.one/@consentsoftware%2finterfaces/-/interfaces-1.0.5.tgz",
"integrity": "sha512-IcdWxVfTznNaTs4tVCkrWpYr2NSewBkQIuoznDhnZaRhRrS6ni5VN5WsRqeZOy5QY4733Kr9aQ8i6FL6OCnpqA==",
"requires": {
"@apiglobal/typedrequest-interfaces": "^1.0.15"
}
},
"@gitzone/tsbuild": {
"version": "2.1.25",
"resolved": "https://verdaccio.lossless.one/@gitzone%2ftsbuild/-/tsbuild-2.1.25.tgz",
@ -1379,14 +1385,12 @@
"@pushrocks/isounique": {
"version": "1.0.4",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fisounique/-/isounique-1.0.4.tgz",
"integrity": "sha512-P1xLsuA1+8LQpoWCo2nP2vIQXKGUl5wDWU6CD7xTDZc3uw0He5V/qCPHM5zpIZsS7IuZOxDDpWb7aFveB11tXw==",
"dev": true
"integrity": "sha512-P1xLsuA1+8LQpoWCo2nP2vIQXKGUl5wDWU6CD7xTDZc3uw0He5V/qCPHM5zpIZsS7IuZOxDDpWb7aFveB11tXw=="
},
"@pushrocks/lik": {
"version": "4.0.17",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2flik/-/lik-4.0.17.tgz",
"integrity": "sha512-K5dX3k3i7iVxFMJ+IYwJRljewukJCc2zgj6+88R18/8SajVAq7ITOl3/FTbmEPFCJv5rl/LQ9FtcMynWlwSlzQ==",
"dev": true,
"requires": {
"@pushrocks/smartdelay": "^2.0.10",
"@pushrocks/smartmatch": "^1.0.7",
@ -1428,7 +1432,6 @@
"version": "2.0.10",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartdelay/-/smartdelay-2.0.10.tgz",
"integrity": "sha512-JOFpEfYiKnqcQYoUrL/jDyBDZUmlgJNm5U30MQQ3f+yci+rlFnMY5VvBBEYn5WgoX0ilwU+E15mtpDWhXcmhzg==",
"dev": true,
"requires": {
"@pushrocks/smartpromise": "^3.0.6"
}
@ -1437,7 +1440,6 @@
"version": "4.0.10",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartenv/-/smartenv-4.0.10.tgz",
"integrity": "sha512-b9jJbBSaOl0nlujyEu/0q5lkOFSMmfcOwPGb3pYrF1B37O15qmVpuqYwA5T8BXj8A6y+oA2bwrrtDzQ7hYp1zg==",
"dev": true,
"requires": {
"@pushrocks/smartparam": "^1.1.6",
"@pushrocks/smartpromise": "^3.0.6",
@ -1447,8 +1449,7 @@
"@types/node": {
"version": "14.11.1",
"resolved": "https://verdaccio.lossless.one/@types%2fnode/-/node-14.11.1.tgz",
"integrity": "sha512-oTQgnd0hblfLsJ6BvJzzSL+Inogp3lq9fGgqRkMB/ziKMgEUaFl801OncOzUmalfzt14N0oPHMK47ipl+wbTIw==",
"dev": true
"integrity": "sha512-oTQgnd0hblfLsJ6BvJzzSL+Inogp3lq9fGgqRkMB/ziKMgEUaFl801OncOzUmalfzt14N0oPHMK47ipl+wbTIw=="
}
}
},
@ -1800,7 +1801,6 @@
"version": "1.0.7",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartmatch/-/smartmatch-1.0.7.tgz",
"integrity": "sha512-D+lK5HIKO4Kj1Jm/ycKvy1VzDJ3V6ucHqmf5DMBFdm18BrMj2Zb6M7wN8HUKtkfHvOI7ig85JMuANSEyO7kAPg==",
"dev": true,
"requires": {
"matcher": "^3.0.0"
}
@ -1835,7 +1835,6 @@
"version": "1.1.6",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartparam/-/smartparam-1.1.6.tgz",
"integrity": "sha512-1El/F2QTWYDGy4Nh6vz9Ry1JVg1FEeyexB7Uvi4zHElpXYVxwso6xImRTLj+SW50JAg7nwEZ+ljkzTG9XvnwWA==",
"dev": true,
"requires": {
"@pushrocks/smartpromise": "^3.0.6",
"is-promise": "^2.1.0",
@ -1931,8 +1930,7 @@
"@pushrocks/smartpromise": {
"version": "3.0.6",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartpromise/-/smartpromise-3.0.6.tgz",
"integrity": "sha512-vlQlBGNVIjfClgnsfgQBU6GIKcskYSFzEcKLt18ngPzPEcjKklXcxaqzLXpnoxR+KBh30QPE8255ncYHXuPPOg==",
"dev": true
"integrity": "sha512-vlQlBGNVIjfClgnsfgQBU6GIKcskYSFzEcKLt18ngPzPEcjKklXcxaqzLXpnoxR+KBh30QPE8255ncYHXuPPOg=="
},
"@pushrocks/smartpuppeteer": {
"version": "1.0.15",
@ -1961,7 +1959,6 @@
"version": "2.0.18",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmartrx/-/smartrx-2.0.18.tgz",
"integrity": "sha512-DqUmtS7mONO6bvWEZmSLy4M9hlxNWysMYc7XOZLr50BMaa0HUNYWI1myUFCMNcbUUOxuQNig01XqR1smfIN69g==",
"dev": true,
"requires": {
"@pushrocks/lik": "^4.0.14",
"@pushrocks/smartpromise": "^3.0.6",
@ -1999,7 +1996,6 @@
"version": "3.0.35",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fsmarttime/-/smarttime-3.0.35.tgz",
"integrity": "sha512-KBDprr2gMcw+21kD6GkJ0Y9fc/SuMijhFPDKoBmuCW9Nhn+KAnabCB8Qn8OzeUuQcoHQ3SFJ/4KioJWNxMgxaQ==",
"dev": true,
"requires": {
"@pushrocks/lik": "^4.0.17",
"@pushrocks/smartdelay": "^2.0.10",
@ -2046,13 +2042,21 @@
"version": "2.0.10",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fwebrequest/-/webrequest-2.0.10.tgz",
"integrity": "sha512-uQ8MvKclGqdLaUjah3SUsr8RplvtEUDXpFYjyO1dsHabbLWNVPQipt70CAMvS/8hOzDDD/G+dUEHIz2yZSVKNQ==",
"dev": true,
"requires": {
"@pushrocks/smartdelay": "^2.0.9",
"@pushrocks/smartenv": "^4.0.10",
"node-fetch": "^2.6.0"
}
},
"@pushrocks/webstore": {
"version": "1.0.14",
"resolved": "https://verdaccio.lossless.one/@pushrocks%2fwebstore/-/webstore-1.0.14.tgz",
"integrity": "sha512-RmI6m1VOW92Vw6I+HUKSrDRJ8vyUBaHpusOoMv0QXraSiwyPlEudEFzi0Ji0nN4++i+ejKIxOuD/gh/jruA4NA==",
"requires": {
"@pushrocks/smartpromise": "^3.0.6",
"idb": "^5.0.6"
}
},
"@rollup/plugin-commonjs": {
"version": "14.0.0",
"resolved": "https://verdaccio.lossless.one/@rollup%2fplugin-commonjs/-/plugin-commonjs-14.0.0.tgz",
@ -2309,8 +2313,7 @@
"@types/minimatch": {
"version": "3.0.3",
"resolved": "https://verdaccio.lossless.one/@types%2fminimatch/-/minimatch-3.0.3.tgz",
"integrity": "sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA==",
"dev": true
"integrity": "sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA=="
},
"@types/node": {
"version": "14.11.1",
@ -2811,8 +2814,7 @@
"balanced-match": {
"version": "1.0.0",
"resolved": "https://verdaccio.lossless.one/balanced-match/-/balanced-match-1.0.0.tgz",
"integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=",
"dev": true
"integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c="
},
"base": {
"version": "0.11.2",
@ -2981,7 +2983,6 @@
"version": "1.1.11",
"resolved": "https://verdaccio.lossless.one/brace-expansion/-/brace-expansion-1.1.11.tgz",
"integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==",
"dev": true,
"requires": {
"balanced-match": "^1.0.0",
"concat-map": "0.0.1"
@ -3656,8 +3657,7 @@
"concat-map": {
"version": "0.0.1",
"resolved": "https://verdaccio.lossless.one/concat-map/-/concat-map-0.0.1.tgz",
"integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=",
"dev": true
"integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s="
},
"concat-stream": {
"version": "1.6.2",
@ -3879,8 +3879,7 @@
"croner": {
"version": "1.1.23",
"resolved": "https://verdaccio.lossless.one/croner/-/croner-1.1.23.tgz",
"integrity": "sha512-VsSyKBVtshU8qd2yPEWsBv5xxTLbRUuq6DX5bgUb4TTn/H6hmFGtfJtr0NKswu1UEsZZ6uhYc0kSOAvPlicQUA==",
"dev": true
"integrity": "sha512-VsSyKBVtshU8qd2yPEWsBv5xxTLbRUuq6DX5bgUb4TTn/H6hmFGtfJtr0NKswu1UEsZZ6uhYc0kSOAvPlicQUA=="
},
"cross-spawn": {
"version": "6.0.5",
@ -4241,8 +4240,7 @@
"dayjs": {
"version": "1.8.36",
"resolved": "https://verdaccio.lossless.one/dayjs/-/dayjs-1.8.36.tgz",
"integrity": "sha512-3VmRXEtw7RZKAf+4Tv1Ym9AGeo8r8+CjDi26x+7SYQil1UqtqdaokhzoEJohqlzt0m5kacJSDhJQkG/LWhpRBw==",
"dev": true
"integrity": "sha512-3VmRXEtw7RZKAf+4Tv1Ym9AGeo8r8+CjDi26x+7SYQil1UqtqdaokhzoEJohqlzt0m5kacJSDhJQkG/LWhpRBw=="
},
"deasync": {
"version": "0.1.20",
@ -4347,7 +4345,6 @@
"version": "1.1.3",
"resolved": "https://verdaccio.lossless.one/define-properties/-/define-properties-1.1.3.tgz",
"integrity": "sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ==",
"dev": true,
"requires": {
"object-keys": "^1.0.12"
}
@ -4756,8 +4753,7 @@
"escape-string-regexp": {
"version": "4.0.0",
"resolved": "https://verdaccio.lossless.one/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz",
"integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==",
"dev": true
"integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA=="
},
"escodegen": {
"version": "1.9.1",
@ -6529,6 +6525,11 @@
"integrity": "sha1-Bupvg2ead0njhs/h/oEq5dsiPe0=",
"dev": true
},
"idb": {
"version": "5.0.6",
"resolved": "https://verdaccio.lossless.one/idb/-/idb-5.0.6.tgz",
"integrity": "sha512-/PFvOWPzRcEPmlDt5jEvzVZVs0wyd/EvGvkDIcbBpGuMMLQKrTPG0TxvE2UJtgZtCQCmOtM2QD7yQJBVEjKGOw=="
},
"ieee754": {
"version": "1.1.13",
"resolved": "https://verdaccio.lossless.one/ieee754/-/ieee754-1.1.13.tgz",
@ -6773,7 +6774,6 @@
"version": "1.3.0",
"resolved": "https://verdaccio.lossless.one/is-nan/-/is-nan-1.3.0.tgz",
"integrity": "sha512-z7bbREymOqt2CCaZVly8aC4ML3Xhfi0ekuOnjO2L8vKdl+CttdVoGZQhd4adMFAsxQ5VeRVwORs4tU8RH+HFtQ==",
"dev": true,
"requires": {
"define-properties": "^1.1.3"
}
@ -6822,8 +6822,7 @@
"is-promise": {
"version": "2.2.2",
"resolved": "https://verdaccio.lossless.one/is-promise/-/is-promise-2.2.2.tgz",
"integrity": "sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==",
"dev": true
"integrity": "sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ=="
},
"is-reference": {
"version": "1.2.1",
@ -7355,7 +7354,6 @@
"version": "3.0.0",
"resolved": "https://verdaccio.lossless.one/matcher/-/matcher-3.0.0.tgz",
"integrity": "sha512-OkeDaAZ/bQCxeFAozM55PKcKU0yJMPGifLwV4Qgjitu+5MoAfSQN4lsLJeXZ1b8w0x+/Emda6MZgXS1jvsapng==",
"dev": true,
"requires": {
"escape-string-regexp": "^4.0.0"
}
@ -7516,7 +7514,6 @@
"version": "3.0.4",
"resolved": "https://verdaccio.lossless.one/minimatch/-/minimatch-3.0.4.tgz",
"integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
"dev": true,
"requires": {
"brace-expansion": "^1.1.7"
}
@ -7637,8 +7634,7 @@
"node-fetch": {
"version": "2.6.1",
"resolved": "https://verdaccio.lossless.one/node-fetch/-/node-fetch-2.6.1.tgz",
"integrity": "sha512-V4aYg89jEoVRxRb2fJdAg8FHvI7cEyYdVAh94HH0UIK8oJxUfkjlDQN9RbMx+bEjP7+ggMiFRprSti032Oipxw==",
"dev": true
"integrity": "sha512-V4aYg89jEoVRxRb2fJdAg8FHvI7cEyYdVAh94HH0UIK8oJxUfkjlDQN9RbMx+bEjP7+ggMiFRprSti032Oipxw=="
},
"node-forge": {
"version": "0.7.6",
@ -7831,8 +7827,7 @@
"object-keys": {
"version": "1.1.1",
"resolved": "https://verdaccio.lossless.one/object-keys/-/object-keys-1.1.1.tgz",
"integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==",
"dev": true
"integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA=="
},
"object-visit": {
"version": "1.0.1",
@ -9573,7 +9568,6 @@
"version": "6.6.3",
"resolved": "https://verdaccio.lossless.one/rxjs/-/rxjs-6.6.3.tgz",
"integrity": "sha512-trsQc+xYYXZ3urjOiJOuCOa5N3jAZ3eiSpQB5hIT8zGlL2QfnHLJ2r7GMkBGuIausdJN1OneaI6gQlsqNHHmZQ==",
"dev": true,
"requires": {
"tslib": "^1.9.0"
}
@ -10437,8 +10431,7 @@
"symbol-tree": {
"version": "3.2.4",
"resolved": "https://verdaccio.lossless.one/symbol-tree/-/symbol-tree-3.2.4.tgz",
"integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==",
"dev": true
"integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw=="
},
"systeminformation": {
"version": "4.27.4",
@ -10603,8 +10596,7 @@
"tslib": {
"version": "1.13.0",
"resolved": "https://verdaccio.lossless.one/tslib/-/tslib-1.13.0.tgz",
"integrity": "sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q==",
"dev": true
"integrity": "sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q=="
},
"tslint": {
"version": "6.1.3",

View File

@ -1,6 +1,6 @@
{
"name": "@consentsoftware/webclient",
"version": "1.0.4",
"version": "1.0.6",
"private": false,
"description": "a webclient for using consent.software in your website. Works with vanilla js, angular, react, you name it.",
"main": "dist_ts/index.js",
@ -19,7 +19,12 @@
"tslint": "^6.1.3",
"tslint-config-prettier": "^1.15.0"
},
"dependencies": {},
"dependencies": {
"@apiglobal/typedrequest": "^1.0.43",
"@consentsoftware/interfaces": "^1.0.5",
"@pushrocks/smarttime": "^3.0.35",
"@pushrocks/webstore": "^1.0.14"
},
"browserslist": [
"last 1 chrome versions"
],

View File

@ -27,6 +27,8 @@ Platform support | [![Supports Windows 10](https://badgen.net/badge/supports%20W
Use TypeScript for best in class intellisense
This WebClient allows you to use the consent.software api in your webproject
## Contribution
We are always happy for code contributions. If you are not the code contributing type that is ok. Still, maintaining Open Source repositories takes considerable time and thought. If you like the quality of what we do and our modules are useful to you we would appreciate a little monthly contribution: You can [contribute one time](https://lossless.link/contribute-onetime) or [contribute monthly](https://lossless.link/contribute). :)

32
test/test.browser.ts Normal file
View File

@ -0,0 +1,32 @@
import { expect, tap } from '@pushrocks/tapbundle';
import * as webclient from '../ts/index';
let testClient: webclient.CsWebclient;
tap.test('should create an instance of webclient', async () => {
testClient = new webclient.CsWebclient();
expect(testClient).to.be.instanceOf(webclient.CsWebclient);
});
tap.test('should return false when asked for present settings', async () => {
const result = await testClient.isCookieLevelSet();
expect(result).to.be.false;
});
tap.test('should create a cookielevel setting', async () => {
await testClient.setCookieLevels(['functional']);
const result = await testClient.getCookieLevels();
expect(result).to.contain('functional');
});
tap.test('should return true when asked for present settings', async () => {
const result = await testClient.isCookieLevelSet();
expect(result).to.be.true;
});
tap.test('should validity for present settings', async () => {
const result = await testClient.isCookieLevelStillValid();
expect(result).to.be.true;
});
tap.start();

View File

@ -1,8 +0,0 @@
import { expect, tap } from '@pushrocks/tapbundle';
import * as webclient from '../ts/index';
tap.test('first test', async () => {
console.log(webclient.standardExport);
});
tap.start();

View File

@ -1,3 +1,41 @@
import * as plugins from './webclient.plugins';
export let standardExport = 'Hi there! :) This is an exported string';
export class CsWebclient {
webstore: plugins.webstore.WebStore<plugins.csInterfaces.IWebclientSettings>;
constructor() {
this.webstore = new plugins.webstore.WebStore<plugins.csInterfaces.IWebclientSettings>({
dbName: 'consentsoftware',
storeName: 'webclient'
});
}
public async isCookieLevelSet(): Promise<boolean> {
const result = await this.webstore.get('acceptedCookieLevels');
return !!result;
}
public async setCookieLevels(cookieLevelsArg: plugins.csInterfaces.TCookieLevel[]): Promise<boolean> {
await this.webstore.set('acceptedCookieLevels', {
acceptanceTimestamp: Date.now(),
acceptedCookieLevels: cookieLevelsArg
});
return true;
}
public async getCookieLevels(): Promise<plugins.csInterfaces.IWebclientSettings['acceptedCookieLevels']> {
const result = await this.webstore.get('acceptedCookieLevels');
return result.acceptedCookieLevels;
}
public async isCookieLevelStillValid(): Promise<boolean> {
if(!this.isCookieLevelSet) {
return false;
}
const result = await this.webstore.get('acceptedCookieLevels');
if (result.acceptanceTimestamp < (Date.now() - plugins.smarttime.getMilliSecondsFromUnits({months: 3}))) {
return false;
}
return true;
}
}

View File

@ -1,2 +1,22 @@
const removeme = {};
export { removeme };
// consentsoftware scope
import * as csInterfaces from '@consentsoftware/interfaces';
export {
csInterfaces
};
// apiglobal scope
import * as typedrequest from '@apiglobal/typedrequest';
export {
typedrequest
};
// @pushrocks scope
import * as smarttime from '@pushrocks/smarttime';
import * as webstore from '@pushrocks/webstore';
export {
smarttime,
webstore
};