♻️ refactor(privacy): update privacy policy
temporarily disable cookies
This commit is contained in:
@@ -1,141 +1,23 @@
|
|||||||
import React from 'react'
|
import React from 'react'
|
||||||
import { useState, useEffect, useCallback } from 'react'
|
import { Box, Typography } from '@mui/material'
|
||||||
import { Box, Button, Link, Stack, Switch, Typography, SnackbarCloseReason, Snackbar, Alert } from '@mui/material'
|
|
||||||
import { useAnalytics } from 'use-analytics'
|
|
||||||
|
|
||||||
import { ANALYTICS_PLUGINS, COOKIE_CONSENT_KEY } from 'components/utils/analytics/index.js'
|
|
||||||
import { SectionHeader } from 'components/atoms/index.js'
|
import { SectionHeader } from 'components/atoms/index.js'
|
||||||
|
|
||||||
interface CookieConsentState {
|
|
||||||
necessary: boolean // Always true, but included for completeness
|
|
||||||
analytics: boolean
|
|
||||||
}
|
|
||||||
|
|
||||||
export type CookieConsentProps = {
|
export type CookieConsentProps = {
|
||||||
consentDisplayDefaultOpen?: boolean
|
consentDisplayDefaultOpen?: boolean
|
||||||
}
|
}
|
||||||
|
|
||||||
const CookieConsent: React.FC<CookieConsentProps> = ({ consentDisplayDefaultOpen = true }) => {
|
const CookieConsent: React.FC<CookieConsentProps> = () => {
|
||||||
const analytics = useAnalytics()
|
|
||||||
const [consent, setConsent] = useState<CookieConsentState>({
|
|
||||||
necessary: true,
|
|
||||||
analytics: false,
|
|
||||||
})
|
|
||||||
const [open, setOpen] = React.useState(false)
|
|
||||||
|
|
||||||
const handleClose = (_event: React.SyntheticEvent | Event, reason?: SnackbarCloseReason) => {
|
|
||||||
if (reason === 'clickaway') {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
setOpen(false)
|
|
||||||
}
|
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
// Check if user has already given consent
|
|
||||||
const savedConsent = localStorage.getItem(COOKIE_CONSENT_KEY)
|
|
||||||
|
|
||||||
if (savedConsent) {
|
|
||||||
const parsedConsent = JSON.parse(savedConsent) as CookieConsentState
|
|
||||||
// eslint-disable-next-line react-hooks/set-state-in-effect
|
|
||||||
setConsent(parsedConsent)
|
|
||||||
}
|
|
||||||
}, [analytics.plugins, consentDisplayDefaultOpen])
|
|
||||||
|
|
||||||
const handleSave = useCallback(() => {
|
|
||||||
localStorage.setItem(COOKIE_CONSENT_KEY, JSON.stringify(consent))
|
|
||||||
|
|
||||||
// Initialize GA if analytics consent was given
|
|
||||||
if (consent.analytics) {
|
|
||||||
analytics.plugins.enable(ANALYTICS_PLUGINS)
|
|
||||||
} else {
|
|
||||||
analytics.plugins.disable(ANALYTICS_PLUGINS)
|
|
||||||
}
|
|
||||||
setOpen(true)
|
|
||||||
}, [consent, analytics.plugins])
|
|
||||||
|
|
||||||
const handleChange = useCallback((type: keyof CookieConsentState) => {
|
|
||||||
if (type === 'necessary') {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
setConsent(prev => ({
|
|
||||||
...prev,
|
|
||||||
[type]: !prev[type],
|
|
||||||
}))
|
|
||||||
}, [])
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Box id="cookie-preferences" aria-labelledby="cookie-preferences-title" aria-describedby="cookie-preferences-description">
|
<Box id="cookie-preferences" aria-labelledby="cookie-preferences-title" aria-describedby="cookie-preferences-description">
|
||||||
<SectionHeader color="inherit" id="cookie-preferences-title" aria-label="cookie-preferences">
|
<SectionHeader color="inherit" id="cookie-preferences-title" aria-label="cookie-preferences">
|
||||||
Cookie Preferences
|
Cookie policy
|
||||||
</SectionHeader>
|
</SectionHeader>
|
||||||
<Typography id="cookie-preferences-description" color="textSecondary" flexGrow={1}>
|
|
||||||
Please set your preferences below. You can change these settings at any time in the future.
|
<Typography component="p" color="textSecondary">
|
||||||
<br />
|
La Compagnia d'Arme del Santo Luca, con sede in via Leonello Poletti n. 16, 44122 Ferrara, Titolare del trattamento dei dati, informa gli
|
||||||
For more details, please see our{' '}
|
utenti del sito {window.location.host} di non utilizzare alcun tipo di coockie per il funzionamento di suddetto sito web.
|
||||||
<Link href="/privacy" color="textPrimary">
|
|
||||||
Privacy Policy
|
|
||||||
</Link>
|
|
||||||
.
|
|
||||||
</Typography>
|
</Typography>
|
||||||
|
|
||||||
<Box
|
|
||||||
sx={theme => ({
|
|
||||||
display: 'flex',
|
|
||||||
flexDirection: 'column',
|
|
||||||
gap: theme.spacing(2),
|
|
||||||
my: theme.spacing(2),
|
|
||||||
p: theme.spacing(4),
|
|
||||||
backgroundColor: theme.palette.background.paper,
|
|
||||||
borderRadius: theme.shape.borderRadius,
|
|
||||||
})}>
|
|
||||||
<Stack direction="row" alignSelf="flex-end" mb={-2}>
|
|
||||||
<Button onClick={() => setConsent({ necessary: true, analytics: false })} color="inherit" variant="text" sx={{ textTransform: 'none' }}>
|
|
||||||
Reject All
|
|
||||||
</Button>
|
|
||||||
<Button onClick={() => setConsent({ necessary: true, analytics: true })} color="inherit" variant="text" sx={{ textTransform: 'none' }}>
|
|
||||||
Accept All
|
|
||||||
</Button>
|
|
||||||
</Stack>
|
|
||||||
|
|
||||||
<Box>
|
|
||||||
<Stack direction="row" alignItems="center" justifyContent="space-between" alignContent="center">
|
|
||||||
<Typography variant="h6" fontFamily="Oswald, sans-serif">
|
|
||||||
Necessary Cookies
|
|
||||||
</Typography>
|
|
||||||
<Switch slotProps={{ input: { 'aria-label': 'necessary-cookies-toggle' } }} color="default" disabled checked />
|
|
||||||
</Stack>
|
|
||||||
<Typography variant="body2" color="textSecondary">
|
|
||||||
These cookies are essential for the website to function properly and cannot be disabled.
|
|
||||||
</Typography>
|
|
||||||
</Box>
|
|
||||||
|
|
||||||
<Box>
|
|
||||||
<Stack direction="row" alignItems="center" justifyContent="space-between" alignContent="center">
|
|
||||||
<Typography variant="h6" fontFamily="Oswald, sans-serif">
|
|
||||||
Analytics Cookies
|
|
||||||
</Typography>
|
|
||||||
<Switch
|
|
||||||
checked={consent.analytics}
|
|
||||||
slotProps={{ input: { 'aria-label': 'analytics-cookies-toggle' } }}
|
|
||||||
onChange={() => handleChange('analytics')}
|
|
||||||
color="default"
|
|
||||||
/>
|
|
||||||
</Stack>
|
|
||||||
<Typography variant="body2" color="textSecondary">
|
|
||||||
These cookies help us understand how visitors interact with our website, helping us improve our services.
|
|
||||||
</Typography>
|
|
||||||
</Box>
|
|
||||||
|
|
||||||
<Button onClick={handleSave} variant="outlined" sx={{ alignSelf: 'flex-end' }}>
|
|
||||||
Save Preferences
|
|
||||||
</Button>
|
|
||||||
</Box>
|
|
||||||
<Snackbar open={open} autoHideDuration={3000} onClose={handleClose}>
|
|
||||||
<Alert onClose={handleClose} sx={{ backgroundColor: 'background.paper', width: '100%' }}>
|
|
||||||
Preferences saved!
|
|
||||||
</Alert>
|
|
||||||
</Snackbar>
|
|
||||||
</Box>
|
</Box>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,13 +5,12 @@ import PolicyIcon from '@mui/icons-material/Policy'
|
|||||||
import CookieIcon from '@mui/icons-material/Cookie'
|
import CookieIcon from '@mui/icons-material/Cookie'
|
||||||
|
|
||||||
import { EmailIconLink, InstagramIconLink, FacebookIconLink } from 'components/atoms/IconLinks/index.js'
|
import { EmailIconLink, InstagramIconLink, FacebookIconLink } from 'components/atoms/IconLinks/index.js'
|
||||||
import CookieConsent from 'components/molecules/CookieConsent/index.js'
|
|
||||||
|
|
||||||
type FooterProps = {
|
type FooterProps = {
|
||||||
showCookieConsent?: boolean
|
showCookieConsent?: boolean
|
||||||
}
|
}
|
||||||
|
|
||||||
const Footer: React.FC<FooterProps> = ({ showCookieConsent = true }) => {
|
const Footer: React.FC<FooterProps> = () => {
|
||||||
const year = new Date().getFullYear()
|
const year = new Date().getFullYear()
|
||||||
return (
|
return (
|
||||||
<Box
|
<Box
|
||||||
@@ -60,8 +59,6 @@ const Footer: React.FC<FooterProps> = ({ showCookieConsent = true }) => {
|
|||||||
m-tartari
|
m-tartari
|
||||||
</Link>
|
</Link>
|
||||||
</Typography>
|
</Typography>
|
||||||
|
|
||||||
{showCookieConsent && <CookieConsent />}
|
|
||||||
</Box>
|
</Box>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -19,91 +19,75 @@ const PrivacyPolicy: React.FC = () => {
|
|||||||
Privacy Policy
|
Privacy Policy
|
||||||
</SectionHeader>
|
</SectionHeader>
|
||||||
<Typography variant="subtitle1" color="textSecondary" component="p" pb={4}>
|
<Typography variant="subtitle1" color="textSecondary" component="p" pb={4}>
|
||||||
Last updated: May 27, 2025
|
Data ultimo aggiornamento: Feb. 1, 2026
|
||||||
</Typography>
|
</Typography>
|
||||||
|
|
||||||
<SectionSubheader>Introduction</SectionSubheader>
|
<SectionSubheader>Introduction</SectionSubheader>
|
||||||
<Typography component="p" color="textSecondary">
|
<Typography component="p" color="textSecondary">
|
||||||
Compagnia d'Arme del Santo Luca ("we", "our", or "us") respects your privacy and is committed to protecting your personal data. This privacy
|
L'informativa è resa solo per il sito web ufficiale di la Compagnia d'Arme del Santo Luca all'indirizzo https://{window.location.host} e non
|
||||||
policy will inform you about how we look after your personal data when you visit our website and tell you about your privacy rights and how
|
per altri siti web esterni, eventualmente consultati dall'utente tramite link.
|
||||||
the law protects you.
|
|
||||||
</Typography>
|
</Typography>
|
||||||
|
|
||||||
<SectionSubheader sx={{ mt: 4 }}>The Data We Collect About You</SectionSubheader>
|
<SectionSubheader sx={{ mt: 4 }}>Titolare del trattamento</SectionSubheader>
|
||||||
<Typography component="p" color="textSecondary">
|
<Typography component="p" color="textSecondary">
|
||||||
We collect and process the following information when you visit our website:
|
Il Titolare del trattamento è la Compagnia d'Arme del Santo Luca, con sede legale in via Leonello Poletti n. 16, 44122 Ferrara.
|
||||||
</Typography>
|
</Typography>
|
||||||
<List dense>
|
|
||||||
<ListItemText title="Technical Data">
|
|
||||||
includes internet protocol (IP) address, browser type and version, time zone setting and location, browser plug-in types and versions,
|
|
||||||
operating system and platform, and other technology on the devices you use to access this website.
|
|
||||||
</ListItemText>
|
|
||||||
<ListItemText title="Usage Data"> includes information about how you use our website, products, and services.</ListItemText>
|
|
||||||
</List>
|
|
||||||
|
|
||||||
<SectionSubheader sx={{ mt: 4 }}>Cookies</SectionSubheader>
|
<SectionSubheader sx={{ mt: 4 }}> Responsabile Protezione Dati (DPO)</SectionSubheader>
|
||||||
<Typography component="p" color="textSecondary">
|
<Typography component="p" color="textSecondary">
|
||||||
We use cookies to distinguish you from other users of our website. This helps us to provide you with a good experience when you browse our
|
Il Titolare, la Compagnia d'Arme del Santo Luca, ai sensi dell'art. 37 GDPR, non è tenuto a nominare il Responsabile della protezione dei
|
||||||
website and also allows us to improve our site.
|
dati.
|
||||||
|
</Typography>
|
||||||
|
|
||||||
|
<SectionSubheader sx={{ mt: 4 }}>Tipi di dati trattati (Dati di navigazione)</SectionSubheader>
|
||||||
|
<Typography component="p" color="textSecondary" gutterBottom>
|
||||||
|
I sistemi informatici e le procedure software preposte al funzionamento di questo sito web acquisiscono, nel corso del loro normale esercizio,
|
||||||
|
alcuni dati personali la cui trasmissione è implicita nell'uso dei protocolli di comunicazione di Internet. Si tratta di informazioni che non
|
||||||
|
sono raccolte per essere associate a interessati identificati, ma che per loro stessa natura potrebbero, attraverso elaborazioni ed
|
||||||
|
associazioni con dati detenuti da terzi, permettere di identificare gli utenti. In questa categoria di dati rientrano gli indirizzi IP o i
|
||||||
|
nomi a dominio dei computer utilizzati dagli utenti che si connettono al sito, gli indirizzi in notazione URI (Uniform Resource Identifier)
|
||||||
|
delle risorse richieste, l'orario della richiesta, il metodo utilizzato nel sottoporre la richiesta al server, la dimensione del file ottenuto
|
||||||
|
in risposta, il codice numerico indicante lo stato della risposta data dal server (buon fine, errore, ecc.) ed altri parametri relativi al
|
||||||
|
sistema operativo e all'ambiente informatico dell'utente.
|
||||||
</Typography>
|
</Typography>
|
||||||
<Typography component="p" color="textSecondary">
|
<Typography component="p" color="textSecondary">
|
||||||
We use the following types of cookies:
|
I suddetti dati sono necessari per la fruizione della navigazione del sito. Questi dati vengono conservati dal provider per il tempo
|
||||||
|
strettamente necessario. I dati potrebbero essere utilizzati per l'accertamento di responsabilità in caso di ipotetici reati informatici ai
|
||||||
|
danni del sito.
|
||||||
|
</Typography>
|
||||||
|
|
||||||
|
<SectionSubheader sx={{ mt: 4 }}>Modalità del trattamento</SectionSubheader>
|
||||||
|
<Typography component="p" color="textSecondary">
|
||||||
|
I dati personali di navigazione sono trattati con strumenti automatizzati per il tempo strettamente necessario a conseguire gli scopi per cui
|
||||||
|
sono stati raccolti. I dati personali di contatto sono trattati con strumenti cartacei e informatici e vengono conservati fino a completa
|
||||||
|
esecuzione del rapporto precontrattuale e di quello contrattuale o per quanto necessario secondo termini di legge. Specifiche misure di
|
||||||
|
sicurezza sono osservate per prevenire la perdita dei dati, usi illeciti o non corretti ed accessi non autorizzati.
|
||||||
|
</Typography>
|
||||||
|
|
||||||
|
<SectionSubheader sx={{ mt: 4 }}>Diritti di accesso e reclamo</SectionSubheader>
|
||||||
|
<Typography component="p" color="textSecondary">
|
||||||
|
Scrivendo attraverso il modulo di contatto le è garantito il diritto di:
|
||||||
</Typography>
|
</Typography>
|
||||||
<List dense>
|
<List dense>
|
||||||
<ListItemText title="Necessary Cookies:">
|
<ListItemText>chiedere l'esistenza e l'accesso ai dati che la riguardano;</ListItemText>
|
||||||
These are essential to enable you to use the website and its features. Without these cookies, services you have asked for cannot be
|
<ListItemText>chiedere l'aggiornamento e l'integrazione dei dati forniti;</ListItemText>
|
||||||
provided.
|
<ListItemText>
|
||||||
|
chiedere la cancellazione dei dati personali, salva l'esistenza di un diritto del Titolare alla conservazione degli stessi
|
||||||
</ListItemText>
|
</ListItemText>
|
||||||
<ListItemText title="Analytics Cookies:">
|
<ListItemText>
|
||||||
We use Google Analytics to help us understand how visitors interact with our website. These cookies collect information about your visit to
|
chiedere la comunicazione dei dati personali conservati eventualmente dal Titolare o la consegna di una loro copia;
|
||||||
our website, the content you viewed, the links you followed, and information about your browser, device, and IP address. We do this to
|
</ListItemText>
|
||||||
improve how our website works.
|
<ListItemText>opporsi ad operazioni di trattamento che ritenga non siano legittime o chiedere limitazioni di trattamento</ListItemText>
|
||||||
|
<ListItemText>
|
||||||
|
Per l'esercizio dei suddetti diritti la legittimità della sua richiesta potrà essere valutata previa verifica della sua identità.
|
||||||
</ListItemText>
|
</ListItemText>
|
||||||
</List>
|
</List>
|
||||||
|
|
||||||
<SectionSubheader sx={{ mt: 4 }}>Google Analytics</SectionSubheader>
|
|
||||||
<Typography component="p" color="textSecondary">
|
<Typography component="p" color="textSecondary">
|
||||||
This website uses Google Analytics 4, a web analytics service provided by Google, Inc. ("Google"). Google Analytics uses cookies to help the
|
Qualora ritenga che il trattamento abbia violato un suo diritto potrà presentare obiezioni nei confronti del Titolare utilizzando l'indirizzo
|
||||||
website analyze how users use the site. The information generated by the cookie about your use of the website will be transmitted to and
|
sopra indicato e anche presentando reclamo presso l'Autorità Garante{' '}
|
||||||
stored by Google on servers in the United States.
|
<Link color="textPrimary" href="https://www.garanteprivacy.it" target="_blank" rel="noopener noreferrer">
|
||||||
</Typography>
|
www.garanteprivacy.it
|
||||||
<Typography component="p" color="textSecondary">
|
|
||||||
We have implemented the following measures to be GDPR compliant:
|
|
||||||
</Typography>
|
|
||||||
<List dense>
|
|
||||||
<ListItemText>We have obtained your consent before processing your data through cookies</ListItemText>
|
|
||||||
<ListItemText>We have implemented IP address anonymization</ListItemText>
|
|
||||||
<ListItemText>We have disabled data sharing with Google</ListItemText>
|
|
||||||
<ListItemText>We have set the data retention period to the minimum required for our analysis</ListItemText>
|
|
||||||
</List>
|
|
||||||
<Typography component="p" color="textSecondary">
|
|
||||||
You can prevent the collection of your data by Google Analytics by declining analytics cookies in our cookie consent banner or by using the
|
|
||||||
Google Analytics Opt-out Browser Add-on available at{' '}
|
|
||||||
<Link color="textPrimary" href="https://tools.google.com/dlpage/gaoptout" target="_blank" rel="noopener noreferrer">
|
|
||||||
https://tools.google.com/dlpage/gaoptout
|
|
||||||
</Link>
|
|
||||||
.
|
|
||||||
</Typography>
|
|
||||||
|
|
||||||
<SectionSubheader sx={{ mt: 4 }}>Your Rights</SectionSubheader>
|
|
||||||
<Typography component="p" color="textSecondary">
|
|
||||||
Under the General Data Protection Regulation (GDPR), you have various rights in relation to your personal data, including:
|
|
||||||
</Typography>
|
|
||||||
|
|
||||||
<List dense>
|
|
||||||
<ListItemText>The right to access your personal data</ListItemText>
|
|
||||||
<ListItemText>The right to rectification of your personal data</ListItemText>
|
|
||||||
<ListItemText>The right to erasure of your personal data</ListItemText>
|
|
||||||
<ListItemText>The right to restrict processing of your personal data</ListItemText>
|
|
||||||
<ListItemText>The right to data portability</ListItemText>
|
|
||||||
<ListItemText>The right to object to processing of your personal data</ListItemText>
|
|
||||||
</List>
|
|
||||||
|
|
||||||
<SectionSubheader sx={{ mt: 4 }}>Contact Us</SectionSubheader>
|
|
||||||
<Typography component="p" color="textSecondary">
|
|
||||||
If you have any questions about this privacy policy or our privacy practices, please contact us at{' '}
|
|
||||||
<Link color="textPrimary" href="mailto:compagniasantoluca@gmail.com" target="_blank" rel="noopener noreferrer">
|
|
||||||
compagniasantoluca@gmail.com
|
|
||||||
</Link>
|
</Link>
|
||||||
.
|
.
|
||||||
</Typography>
|
</Typography>
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
import { useEffect } from 'react'
|
import { useEffect } from 'react'
|
||||||
import { useAnalytics } from 'use-analytics'
|
|
||||||
import { Outlet, useLocation } from 'react-router-dom'
|
import { Outlet, useLocation } from 'react-router-dom'
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -7,11 +6,6 @@ import { Outlet, useLocation } from 'react-router-dom'
|
|||||||
*/
|
*/
|
||||||
const RouteTracker = () => {
|
const RouteTracker = () => {
|
||||||
const location = useLocation()
|
const location = useLocation()
|
||||||
const analytics = useAnalytics()
|
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
analytics.page()
|
|
||||||
}, [analytics, location])
|
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
window.scrollTo(0, 0)
|
window.scrollTo(0, 0)
|
||||||
|
|||||||
+4
-8
@@ -5,10 +5,8 @@ import '@fontsource/medievalsharp' // Regular
|
|||||||
|
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import ReactDOM from 'react-dom/client'
|
import ReactDOM from 'react-dom/client'
|
||||||
import { AnalyticsProvider } from 'use-analytics'
|
|
||||||
import { ThemeProvider, CssBaseline } from '@mui/material'
|
import { ThemeProvider, CssBaseline } from '@mui/material'
|
||||||
|
|
||||||
import analytics from 'components/utils/analytics/index.js'
|
|
||||||
import theme from 'style/theme.js'
|
import theme from 'style/theme.js'
|
||||||
import App from './App.js'
|
import App from './App.js'
|
||||||
import './index.css'
|
import './index.css'
|
||||||
@@ -23,11 +21,9 @@ if (themeParam === 'light' || themeParam === 'dark' || themeParam === 'system')
|
|||||||
const root = ReactDOM.createRoot(document.getElementById('root') as HTMLElement)
|
const root = ReactDOM.createRoot(document.getElementById('root') as HTMLElement)
|
||||||
root.render(
|
root.render(
|
||||||
<React.StrictMode>
|
<React.StrictMode>
|
||||||
<AnalyticsProvider instance={analytics}>
|
<ThemeProvider theme={theme} defaultMode={mode}>
|
||||||
<ThemeProvider theme={theme} defaultMode={mode}>
|
<CssBaseline />
|
||||||
<CssBaseline />
|
<App />
|
||||||
<App />
|
</ThemeProvider>
|
||||||
</ThemeProvider>
|
|
||||||
</AnalyticsProvider>
|
|
||||||
</React.StrictMode>
|
</React.StrictMode>
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user