Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update develop #334

Merged
merged 26 commits into from
Dec 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
522ccc8
Merge pull request #312 from aesirxio/develop
vietredweb Oct 3, 2024
53a229b
Fix rollup
vietredweb Oct 3, 2024
0ef8732
Merge branch 'master' into upgrade-package
vietredweb Oct 3, 2024
01f4f43
Merge pull request #315 from vietredweb/upgrade-package
vietredweb Oct 3, 2024
70d92ae
Update block js
vietredweb Oct 5, 2024
a5505c5
Update
vietredweb Oct 5, 2024
1b214ff
update reload
vietredweb Oct 5, 2024
dbbbcc8
Merge pull request #316 from vietredweb/update-blockjs
NguyenBao10 Oct 5, 2024
c35701d
prepare to release
vietredweb Oct 5, 2024
a4e5cfe
Merge branch 'master' into update-blockjs
vietredweb Oct 5, 2024
8ff3d27
Merge pull request #317 from vietredweb/update-blockjs
NguyenBao10 Oct 5, 2024
4f08ac6
Update blockjs
vietredweb Oct 7, 2024
b5e02f9
Update name
vietredweb Oct 7, 2024
b7fe92e
Merge pull request #318 from vietredweb/block-js-fix
vietredweb Oct 7, 2024
09366aa
Update version
vietredweb Oct 7, 2024
00a5b3d
Merge pull request #319 from vietredweb/release2.3.2
vietredweb Oct 7, 2024
e07b90f
Fix consent
vietredweb Oct 10, 2024
627613b
Update version
vietredweb Oct 10, 2024
db1eda0
Update
vietredweb Oct 10, 2024
56a1ad1
Update version
vietredweb Oct 10, 2024
428aca7
Merge pull request #320 from vietredweb/fix-consent
vietredweb Oct 10, 2024
61496a2
Update export
vietredweb Dec 24, 2024
4156ce9
prepare for release
vietredweb Dec 24, 2024
2449bd5
Merge pull request #331 from vietredweb/update-event
vietredweb Dec 24, 2024
18a566e
Export handle
vietredweb Dec 24, 2024
4f50d58
Merge pull request #333 from vietredweb/update-export
vietredweb Dec 24, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aesirx-analytics",
"version": "2.3.0",
"version": "2.3.5",
"license": "GPL-3.0-only",
"author": "AesirX",
"repository": "https://gitlab.redweb.dk/aesirx/analytics",
Expand All @@ -10,7 +10,7 @@
"type": "module",
"dependencies": {
"@concordium/browser-wallet-api-helpers": "3.0.1",
"@concordium/react-components": "0.4.0-rc.7",
"@concordium/react-components": "0.6.1",
"@concordium/web-sdk": "7.0.4-rc.3",
"@web3modal/ethereum": "^2.7.0",
"@web3modal/react": "^2.7.0",
Expand Down Expand Up @@ -96,9 +96,7 @@
"resolutions": {
"postcss": "^8",
"ws": "8.17.1",
"@walletconnect/core": "2.9.1",
"@walletconnect/types": "2.9.1",
"@walletconnect/sign-client": "2.9.1",
"rollup": "3.26.3"
"cookie": "^0.7.0",
"rollup": "3.29.5"
}
}
5 changes: 4 additions & 1 deletion src/Components/ConsentCustom.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -933,7 +933,10 @@ const ConsentComponentCustomApp = (props: any) => {
onClick={async () => {
if (revokeConsentOption === 'consent') {
await handleRevokeBtn();
if (level > 1) {
const levelRevoke =
sessionStorage.getItem('aesirx-analytics-revoke') &&
parseInt(sessionStorage.getItem('aesirx-analytics-revoke'));
if (levelRevoke > 1 || window['aesirx1stparty']) {
setTimeout(() => {
window.location.reload();
}, 1000);
Expand Down
19 changes: 19 additions & 0 deletions src/Hooks/useConsentStatus.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ const useConsentStatus = (endpoint?: string, layout?: string, props?: WalletConn
sessionStorage.removeItem('aesirx-analytics-allow');
return;
} else {
setShow(false);
sessionStorage.setItem('aesirx-analytics-uuid', analyticsContext.visitor_uuid);
sessionStorage.setItem('aesirx-analytics-allow', '1');
if (consent) {
Expand Down Expand Up @@ -175,6 +176,24 @@ const useConsentStatus = (endpoint?: string, layout?: string, props?: WalletConn
if (level && level !== '0') {
window.funcAfterConsent && window.funcAfterConsent();
window.configBlockJS && unBlockScripts();
if (
window['aesirx_analytics_degistered_scripts'] ||
window['aesirx_analytics_deregistered_scripts_head'] ||
window['aesirx_analytics_deregistered_scripts_footer']
) {
const blockJSList = Object.assign(
window['aesirx_analytics_degistered_scripts'],
window['aesirx_analytics_deregistered_scripts_head'],
window['aesirx_analytics_deregistered_scripts_footer']
);
Object.keys(blockJSList).forEach((key) => {
const scriptNode = document.createElement('script');
scriptNode.src =
blockJSList[key].src + (blockJSList[key].ver ? `?ver=${blockJSList[key].ver}` : '');
scriptNode.type = 'text/javascript';
document.body.appendChild(scriptNode);
});
}
}
};

Expand Down
4 changes: 3 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
export { default as AnalyticsNext } from './AnalyticsNext';
export { default as AnalyticsReact } from './AnalyticsReact';
export { trackEvent } from './utils';
export { default as AnalyticsReactHandle } from './AnalyticsReact/handle';
export { default as AnalyticsNextHandle } from './AnalyticsNext/handle';
export { trackEvent, startTracker, endTrackerVisibilityState } from './utils';
export { AnalyticsContext } from './utils/AnalyticsContextProvider';
export { default as getFingerprint } from './lib/fingerprint';
export { default as OptInConsent } from './Components/OptInConsent';
127 changes: 113 additions & 14 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1029,6 +1029,15 @@
dependencies:
"@concordium/wallet-connectors" "^0.4.0-rc.6"

"@concordium/[email protected]":
version "0.6.1"
resolved "https://registry.yarnpkg.com/@concordium/react-components/-/react-components-0.6.1.tgz#d138eb52ef0bd51bec398a483710b7acbf18c09f"
integrity sha512-zMc+7dsI52tnTPVPP/Tawva06bYuNA35+PoHLjrZiewxzYdTQzk5hLvg2bukaKf0FBFF2mscs+JWAgZOmzJZVQ==
dependencies:
"@concordium/wallet-connectors" "^0.6.1"
"@protobuf-ts/grpcweb-transport" "^2.9.4"
buffer "^6.0.3"

"@concordium/[email protected]":
version "2.0.1"
resolved "https://registry.yarnpkg.com/@concordium/rust-bindings/-/rust-bindings-2.0.1.tgz#267fbd6339e14673debe5c3529dcebcf254e11b0"
Expand All @@ -1043,6 +1052,18 @@
"@walletconnect/qrcode-modal" "^1.8.0"
"@walletconnect/sign-client" "^2.1.4"

"@concordium/wallet-connectors@^0.6.1":
version "0.6.1"
resolved "https://registry.yarnpkg.com/@concordium/wallet-connectors/-/wallet-connectors-0.6.1.tgz#77a72186cfdd7682152b33fe21144fdeb6c08ac9"
integrity sha512-M9EeO5r47xm20UpC0aFldQfbdD5xfmkfcQ1QUrj78qcSboMaksTD1SOIhiiA/+Blp6orUW4lJWMNUv+SJmr6gA==
dependencies:
"@concordium/browser-wallet-api-helpers" "^3.0.0"
"@protobuf-ts/grpcweb-transport" "^2.9.4"
"@walletconnect/modal" "^2.6.2"
"@walletconnect/modal-core" "^2.6.2"
"@walletconnect/sign-client" "^2.1.4"
buffer "^6.0.3"

"@concordium/[email protected]":
version "7.0.4-rc.3"
resolved "https://registry.yarnpkg.com/@concordium/web-sdk/-/web-sdk-7.0.4-rc.3.tgz#f99c5655b646f1a7772eafa423cca5396ab01fcf"
Expand Down Expand Up @@ -2098,7 +2119,7 @@
"@protobuf-ts/runtime" "^2.9.4"
"@protobuf-ts/runtime-rpc" "^2.9.4"

"@protobuf-ts/grpcweb-transport@^2.9.1":
"@protobuf-ts/grpcweb-transport@^2.9.1", "@protobuf-ts/grpcweb-transport@^2.9.4":
version "2.9.4"
resolved "https://registry.yarnpkg.com/@protobuf-ts/grpcweb-transport/-/grpcweb-transport-2.9.4.tgz#e98d543d2838e95d5cec1a22f23a02de88393401"
integrity sha512-6aQgwPTgX6FkqWqmNts3uk8T/C5coJoH7U87zgaZY/Wo2EVa9SId5bXTM8uo4WR+CN8j9W4c9ij1yG13Hc3xUw==
Expand Down Expand Up @@ -2829,6 +2850,29 @@
"@walletconnect/window-metadata" "1.0.0"
detect-browser "5.2.0"

"@walletconnect/[email protected]":
version "2.11.0"
resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.11.0.tgz#3a4e301077b2f858fd916b7a20b5b984d1afce63"
integrity sha512-2Tjp5BCevI7dbmqo/OrCjX4tqgMqwJNQLlQAlphqPfvwlF9+tIu6pGcVbSN3U9zyXzWIZCeleqEaWUeSeET4Ew==
dependencies:
"@walletconnect/heartbeat" "1.2.1"
"@walletconnect/jsonrpc-provider" "1.0.13"
"@walletconnect/jsonrpc-types" "1.0.3"
"@walletconnect/jsonrpc-utils" "1.0.8"
"@walletconnect/jsonrpc-ws-connection" "1.0.14"
"@walletconnect/keyvaluestorage" "^1.1.1"
"@walletconnect/logger" "^2.0.1"
"@walletconnect/relay-api" "^1.0.9"
"@walletconnect/relay-auth" "^1.0.4"
"@walletconnect/safe-json" "^1.0.2"
"@walletconnect/time" "^1.0.2"
"@walletconnect/types" "2.11.0"
"@walletconnect/utils" "2.11.0"
events "^3.3.0"
isomorphic-unfetch "3.1.0"
lodash.isequal "4.5.0"
uint8arrays "^3.1.0"

"@walletconnect/[email protected]":
version "2.9.1"
resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.9.1.tgz#1a333933750f5f933d9b7788a8dae44ce1173063"
Expand Down Expand Up @@ -2985,7 +3029,17 @@
tslib "1.14.1"
ws "^7.5.1"

"@walletconnect/[email protected]", "@walletconnect/keyvaluestorage@^1.0.2":
"@walletconnect/[email protected]":
version "1.0.14"
resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-ws-connection/-/jsonrpc-ws-connection-1.0.14.tgz#eec700e74766c7887de2bd76c91a0206628732aa"
integrity sha512-Jsl6fC55AYcbkNVkwNM6Jo+ufsuCQRqViOQ8ZBPH9pRREHH9welbBiszuTLqEJiQcO/6XfFDl6bzCJIkrEi8XA==
dependencies:
"@walletconnect/jsonrpc-utils" "^1.0.6"
"@walletconnect/safe-json" "^1.0.2"
events "^3.3.0"
ws "^7.5.1"

"@walletconnect/[email protected]", "@walletconnect/keyvaluestorage@^1.0.2", "@walletconnect/keyvaluestorage@^1.1.1":
version "1.1.1"
resolved "https://registry.yarnpkg.com/@walletconnect/keyvaluestorage/-/keyvaluestorage-1.1.1.tgz#dd2caddabfbaf80f6b8993a0704d8b83115a1842"
integrity sha512-V7ZQq2+mSxAq7MrRqDxanTzu2RcElfK1PfNYiaVnJgJ7Q7G7hTVwF8voIBx92qsRyGHZihrwNPHuZd1aKkd0rA==
Expand Down Expand Up @@ -3074,7 +3128,7 @@
dependencies:
valtio "1.11.2"

"@walletconnect/[email protected]":
"@walletconnect/[email protected]", "@walletconnect/modal-core@^2.6.2":
version "2.7.0"
resolved "https://registry.yarnpkg.com/@walletconnect/modal-core/-/modal-core-2.7.0.tgz#73c13c3b7b0abf9ccdbac9b242254a86327ce0a4"
integrity sha512-oyMIfdlNdpyKF2kTJowTixZSo0PGlCJRdssUN/EZdA6H6v03hZnf09JnwpljZNfir2M65Dvjm/15nGrDQnlxSA==
Expand Down Expand Up @@ -3170,7 +3224,22 @@
dependencies:
tslib "1.14.1"

"@walletconnect/[email protected]", "@walletconnect/[email protected]", "@walletconnect/sign-client@^2.1.4":
"@walletconnect/[email protected]":
version "2.11.0"
resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.11.0.tgz#de10f976cc1b8ab04b7f7c27f6a298e4e083ab25"
integrity sha512-H2ukscibBS+6WrzQWh+WyVBqO5z4F5et12JcwobdwgHnJSlqIoZxqnUYYWNCI5rUR5UKsKWaUyto4AE9N5dw4Q==
dependencies:
"@walletconnect/core" "2.11.0"
"@walletconnect/events" "^1.0.1"
"@walletconnect/heartbeat" "1.2.1"
"@walletconnect/jsonrpc-utils" "1.0.8"
"@walletconnect/logger" "^2.0.1"
"@walletconnect/time" "^1.0.2"
"@walletconnect/types" "2.11.0"
"@walletconnect/utils" "2.11.0"
events "^3.3.0"

"@walletconnect/sign-client@^2.1.4":
version "2.9.1"
resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.9.1.tgz#e4aa9c7b15849f450fdd1b03754a7517cb5c8811"
integrity sha512-Z7tFRrJ9btA1vU427vsjUS6cPlHQVcTWdKH90khEc2lv3dB6mU8FNO0VJsw+I2D7CW7WaMWF3nnj6Z1FfotbDg==
Expand All @@ -3192,7 +3261,19 @@
dependencies:
tslib "1.14.1"

"@walletconnect/[email protected]", "@walletconnect/[email protected]", "@walletconnect/types@^1.8.0":
"@walletconnect/[email protected]":
version "2.11.0"
resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.11.0.tgz#474a009c56faa9ef4063b76ed84415c801dc9f1e"
integrity sha512-AB5b1lrEbCGHxqS2vqfCkIoODieH+ZAUp9rA1O2ftrhnqDJiJK983Df87JhYhECsQUBHHfALphA8ydER0q+9sw==
dependencies:
"@walletconnect/events" "^1.0.1"
"@walletconnect/heartbeat" "1.2.1"
"@walletconnect/jsonrpc-types" "1.0.3"
"@walletconnect/keyvaluestorage" "^1.1.1"
"@walletconnect/logger" "^2.0.1"
events "^3.3.0"

"@walletconnect/[email protected]":
version "2.9.1"
resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.9.1.tgz#cb32ff396cc8880a7395f28716d1e82f407e1372"
integrity sha512-xbGgTPuD6xsb7YMvCESBIH55cjB86QAnnVL50a/ED42YkQzDsOdJ0VGTbrm0tG5cxUOF933rpxZQjxGdP+ovww==
Expand All @@ -3204,6 +3285,11 @@
"@walletconnect/logger" "^2.0.1"
events "^3.3.0"

"@walletconnect/types@^1.8.0":
version "1.8.0"
resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-1.8.0.tgz#3f5e85b2d6b149337f727ab8a71b8471d8d9a195"
integrity sha512-Cn+3I0V0vT9ghMuzh1KzZvCkiAxTq+1TR2eSqw5E5AVWfmCtECFkVZBP6uUJZ8YjwLqXheI+rnjqPy7sVM4Fyg==

"@walletconnect/types@^2.10.0":
version "2.17.0"
resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.17.0.tgz#20eda5791e3172f8ab9146caa3f317701d4b3232"
Expand Down Expand Up @@ -4143,10 +4229,10 @@ cookie-es@^1.1.0:
resolved "https://registry.yarnpkg.com/cookie-es/-/cookie-es-1.2.2.tgz#18ceef9eb513cac1cb6c14bcbf8bdb2679b34821"
integrity sha512-+W7VmiVINB+ywl1HGXJXmrqkOhpKrIiVZV6tQuV54ZyQC7MMuBt81Vc336GMLoHBq5hV/F9eXgt5Mnx0Rha5Fg==

cookie@~0.4.1:
version "0.4.2"
resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.2.tgz#0e41f24de5ecf317947c82fc789e06a884824432"
integrity sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA==
cookie@^0.7.0, cookie@~0.4.1:
version "0.7.2"
resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.7.2.tgz#556369c472a2ba910f2979891b526b3436237ed7"
integrity sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==

copy-to-clipboard@^3.3.1, copy-to-clipboard@^3.3.3:
version "3.3.3"
Expand Down Expand Up @@ -5901,6 +5987,14 @@ iso-3166-1@^2.1.1:
resolved "https://registry.yarnpkg.com/iso-3166-1/-/iso-3166-1-2.1.1.tgz#79b80d2aebc3c9528d792bdbb8316c912fe37c68"
integrity sha512-RZxXf8cw5Y8LyHZIwIRvKw8sWTIHh2/txBT+ehO0QroesVfnz3JNFFX4i/OC/Yuv2bDIVYrHna5PMvjtpefq5w==

[email protected]:
version "3.1.0"
resolved "https://registry.yarnpkg.com/isomorphic-unfetch/-/isomorphic-unfetch-3.1.0.tgz#87341d5f4f7b63843d468438128cb087b7c3e98f"
integrity sha512-geDJjpoZ8N0kWexiwkX8F9NkTsXhetLPVbZFQ+JTW239QNOwvB0gniuR1Wc6f0AMTn7/mFGyXvHTifrCp/GH8Q==
dependencies:
node-fetch "^2.6.1"
unfetch "^4.2.0"

[email protected]:
version "1.0.3"
resolved "https://registry.yarnpkg.com/isows/-/isows-1.0.3.tgz#93c1cf0575daf56e7120bab5c8c448b0809d0d74"
Expand Down Expand Up @@ -6925,7 +7019,7 @@ node-fetch-native@^1.6.4:
resolved "https://registry.yarnpkg.com/node-fetch-native/-/node-fetch-native-1.6.4.tgz#679fc8fd8111266d47d7e72c379f1bed9acff06e"
integrity sha512-IhOigYzAKHd244OC0JIMIUrjzctirCmPkaIfhDeGcEETWof5zKYUW7e7MYvChGWh/4CJeXEgsRyGzuF334rOOQ==

node-fetch@^2.6.12:
node-fetch@^2.6.1, node-fetch@^2.6.12:
version "2.7.0"
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d"
integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==
Expand Down Expand Up @@ -7890,10 +7984,10 @@ rimraf@^3.0.2:
dependencies:
glob "^7.1.3"

rollup@3.26.3, rollup@^4.0.2:
version "3.26.3"
resolved "https://registry.yarnpkg.com/rollup/-/rollup-3.26.3.tgz#bbc8818cadd0aebca348dbb3d68d296d220967b8"
integrity sha512-7Tin0C8l86TkpcMtXvQu6saWH93nhG3dGQ1/+l5V2TDMceTxO7kDiK6GzbfLWNNxqJXm591PcEZUozZm51ogwQ==
rollup@3.29.5, rollup@^4.0.2:
version "3.29.5"
resolved "https://registry.yarnpkg.com/rollup/-/rollup-3.29.5.tgz#8a2e477a758b520fb78daf04bca4c522c1da8a54"
integrity sha512-GVsDdsbJzzy4S/v3dqWPJ7EfvZJfCHiDqe80IyrF59LYuP+e6U1LJoUqeuqRbwAWoMNoXivMNeNAOf5E22VA1w==
optionalDependencies:
fsevents "~2.3.2"

Expand Down Expand Up @@ -8714,6 +8808,11 @@ unenv@^1.9.0:
node-fetch-native "^1.6.4"
pathe "^1.1.2"

unfetch@^4.2.0:
version "4.2.0"
resolved "https://registry.yarnpkg.com/unfetch/-/unfetch-4.2.0.tgz#7e21b0ef7d363d8d9af0fb929a5555f6ef97a3be"
integrity sha512-F9p7yYCn6cIW9El1zi0HI6vqpeIvBsr3dSuRO6Xuppb1u5rXpCPmMvLSyECLhybr9isec8Ohl0hPekMVrEinDA==

unicode-canonical-property-names-ecmascript@^2.0.0:
version "2.0.1"
resolved "https://registry.yarnpkg.com/unicode-canonical-property-names-ecmascript/-/unicode-canonical-property-names-ecmascript-2.0.1.tgz#cb3173fe47ca743e228216e4a3ddc4c84d628cc2"
Expand Down
Loading