Skip to content

Commit

Permalink
update matomo config
Browse files Browse the repository at this point in the history
  • Loading branch information
yann300 committed Dec 6, 2023
1 parent 075475d commit 111f5e3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 10 deletions.
4 changes: 0 additions & 4 deletions apps/remix-ide/src/app/tabs/settings-tab.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -95,14 +95,10 @@ module.exports = class SettingsTab extends ViewPlugin {
_paq.push(['optUserOut'])
// revoke tracking consent
_paq.push(['forgetConsentGiven']);
// OR revoke cookie consent
_paq.push(['forgetCookieConsentGiven']);
} else {
_paq.push(['forgetUserOptOut'])
// user has given consent to process their data
_paq.push(['setConsentGiven']);
// OR user has given consent to store and use cookies
_paq.push(['setCookieConsentGiven']);
}
this.dispatch({
...this
Expand Down
7 changes: 5 additions & 2 deletions apps/remix-ide/src/assets/js/loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,17 @@ if (domains[window.location.hostname]) {
_paq.push(['enableJSErrorTracking']);
// require user tracking consent before processing data
_paq.push(['requireConsent']);
// OR require user cookie consent before storing any cookies
_paq.push(['requireCookieConsent']);
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
_paq.push(['enableHeartBeatTimer']);
if (!window.localStorage.getItem('config-v0.8:.remix.config') ||
(window.localStorage.getItem('config-v0.8:.remix.config') && !window.localStorage.getItem('config-v0.8:.remix.config').includes('settings/matomo-analytics'))) {
_paq.push(['optUserOut'])

} else {
_paq.push(['forgetUserOptOut'])
// user has given consent to process their data
_paq.push(['setConsentGiven'])
}
(function () {
var u = "https://ethereumfoundation.matomo.cloud/";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,17 +59,13 @@ const MatomoDialog = (props) => {
_paq.push(['optUserOut'])
// revoke tracking consent
_paq.push(['forgetConsentGiven']);
// OR revoke cookie consent
_paq.push(['forgetCookieConsentGiven']);
setVisible(false)
}

const handleModalOkClick = async () => {
_paq.push(['forgetUserOptOut'])
// user has given consent to process their data
_paq.push(['setConsentGiven']);
// OR user has given consent to store and use cookies
_paq.push(['setCookieConsentGiven']);
settings.updateMatomoAnalyticsChoice(true)
setVisible(false)
}
Expand Down

0 comments on commit 111f5e3

Please sign in to comment.