mirror of
https://github.com/rustdesk/doc.rustdesk.com.git
synced 2024-12-28 01:49:26 +01:00
fix cookie consent status
This commit is contained in:
parent
fdc0973f15
commit
afdc36f199
@ -12,8 +12,6 @@ import '../assets/styles/ccElegantBlack.css';
|
||||
document.body.classList.add('cc--elegant-black');
|
||||
|
||||
function checkCookieConsent() {
|
||||
// this cookie consent use cookie to store the consent status, but our webiste v2 use localStorage
|
||||
// this is used to compliant with v2
|
||||
const consentStatus = localStorage.getItem('cookie-accepted');
|
||||
return consentStatus === 'true';
|
||||
}
|
||||
|
@ -25,6 +25,7 @@ export const config: CookieConsentConfig = {
|
||||
'<a href="https://marketingplatform.google.com/about/analytics/terms/us/" target="_blank">Google Analytics 4 (dummy)</a>',
|
||||
onAccept: () => {
|
||||
// TODO: load ga4
|
||||
localStorage.setItem('cookie-accepted', 'true');
|
||||
},
|
||||
onReject: () => {
|
||||
console.log('ga4 rejected');
|
||||
|
Loading…
Reference in New Issue
Block a user