From 7a383957a72366b57af66b1679ecb609097acea5 Mon Sep 17 00:00:00 2001 From: Anthony LC Date: Tue, 25 Mar 2025 13:12:02 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A5(frontend)=20remove=20legal=20pages?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Legal pages are not needed anymore in the application. In the dsfr instances, the legal pages will be displayed on a Docs pages. We let the users of Docs managing the legal pages on their own instances. --- .../features/service-worker/service-worker.ts | 5 +- .../impress/src/pages/accessibility/index.tsx | 133 ------------------ .../impress/src/pages/legal-notice/index.tsx | 72 ---------- .../src/pages/personal-data-cookies/index.tsx | 66 --------- 4 files changed, 2 insertions(+), 274 deletions(-) delete mode 100644 src/frontend/apps/impress/src/pages/accessibility/index.tsx delete mode 100644 src/frontend/apps/impress/src/pages/legal-notice/index.tsx delete mode 100644 src/frontend/apps/impress/src/pages/personal-data-cookies/index.tsx diff --git a/src/frontend/apps/impress/src/features/service-worker/service-worker.ts b/src/frontend/apps/impress/src/features/service-worker/service-worker.ts index b4db83f6..957de160 100644 --- a/src/frontend/apps/impress/src/features/service-worker/service-worker.ts +++ b/src/frontend/apps/impress/src/features/service-worker/service-worker.ts @@ -108,10 +108,9 @@ const FALLBACK = { const precacheResources = [ '/', '/index.html', + '/401/', '/404/', - '/accessibility/', - '/legal-notice/', - '/personal-data-cookies/', + '/403/', FALLBACK.offline, FALLBACK.images, FALLBACK.docs, diff --git a/src/frontend/apps/impress/src/pages/accessibility/index.tsx b/src/frontend/apps/impress/src/pages/accessibility/index.tsx deleted file mode 100644 index cec42d66..00000000 --- a/src/frontend/apps/impress/src/pages/accessibility/index.tsx +++ /dev/null @@ -1,133 +0,0 @@ -import { ReactElement } from 'react'; -import { Trans, useTranslation } from 'react-i18next'; - -import { Box, Text, TextStyled } from '@/components'; -import { useCunninghamTheme } from '@/cunningham'; -import { PageLayout } from '@/layouts'; -import { NextPageWithLayout } from '@/types/next'; - -const Page: NextPageWithLayout = () => { - const { t } = useTranslation(); - const { colorsTokens } = useCunninghamTheme(); - - return ( - - - {t('Accessibility')} - - - - - DINUM is committed to making its digital services - accessible, in accordance with article 47 of French law n° 2005-102 - dated February 11, 2005. - - - - {t('Accessibility statement')} - - {t('Established on December 20, 2023.')} - - {t('This accessibility statement applies to the site hosted on')}{' '} - https://docs.numerique.gouv.fr. - - - {t('Compliance status')} - - - - https://docs.numerique.gouv.fr is not compliant - with RGAA 4.1. The site has not yet been audited. - - - - {t('Improvement and contact')} - - - {t( - 'If you are unable to access a content or a service, you can contact the person responsible for https://lasuite.numerique.gouv.fr to be directed to an accessible alternative or to obtain the content in another form.', - )} - - -
  • - {t('E-mail:')}{' '} - - lasuite@modernisation.gouv.fr - -
  • -
  • - {t('Address:')} DINUM, 20 avenue de Ségur 75007 - Paris -
  • -
    - - {t('We try to respond within 2 working days.')} - - - - {t('Remedies')} - - - {t('This procedure should be used in the following case:')}{' '} - {t( - 'you have reported to the website manager a lack of accessibility that prevents you from accessing content or one of the services of the portal and you have not received a satisfactory response.', - )} - - - {t('You can:')} - - -
  • - - Write a message to the - - Defender of Rights - - -
  • -
  • - - Contact the delegate of the - - Defender of Rights in your region - - -
  • -
  • - {t('Send a letter by post (free of charge, no stamp needed):')}{' '} - - {t( - 'Defender of Rights - Free response - 71120 75342 Paris CEDEX 07', - )} - -
  • -
    -
    -
    - ); -}; - -Page.getLayout = function getLayout(page: ReactElement) { - return {page}; -}; - -export default Page; diff --git a/src/frontend/apps/impress/src/pages/legal-notice/index.tsx b/src/frontend/apps/impress/src/pages/legal-notice/index.tsx deleted file mode 100644 index ed762ccf..00000000 --- a/src/frontend/apps/impress/src/pages/legal-notice/index.tsx +++ /dev/null @@ -1,72 +0,0 @@ -import { ReactElement } from 'react'; -import { useTranslation } from 'react-i18next'; - -import { Box, Text, TextStyled } from '@/components'; -import { useCunninghamTheme } from '@/cunningham'; -import { PageLayout } from '@/layouts'; -import { NextPageWithLayout } from '@/types/next'; - -const Page: NextPageWithLayout = () => { - const { t } = useTranslation(); - const { colorsTokens } = useCunninghamTheme(); - - return ( - - - {t('Legal notice')} - - - - {t('Publisher')} - - - {t( - 'French Interministerial Directorate for Digital Affairs (DINUM), 20 avenue de Ségur 75007 Paris.', - )} - - - {t('Publication Director')} - - - {t('Stéphanie Schaer: Interministerial Digital Director (DINUM).')} - - - {t('Copyright')} - - - {t('Illustration:')}{' '} - - DINUM - - - - {t('More info?')} - - - {t( - 'The team in charge of the digital workspace "La Suite numérique" can be contacted directly at', - )}{' '} - - lasuite@modernisation.gouv.fr - - . - - - - ); -}; - -Page.getLayout = function getLayout(page: ReactElement) { - return {page}; -}; - -export default Page; diff --git a/src/frontend/apps/impress/src/pages/personal-data-cookies/index.tsx b/src/frontend/apps/impress/src/pages/personal-data-cookies/index.tsx deleted file mode 100644 index 6e4800c6..00000000 --- a/src/frontend/apps/impress/src/pages/personal-data-cookies/index.tsx +++ /dev/null @@ -1,66 +0,0 @@ -import { ReactElement } from 'react'; -import { useTranslation } from 'react-i18next'; - -import { Box, Text } from '@/components'; -import { useCunninghamTheme } from '@/cunningham'; -import { PageLayout } from '@/layouts'; -import { NextPageWithLayout } from '@/types/next'; - -const Page: NextPageWithLayout = () => { - const { t } = useTranslation(); - const { colorsTokens } = useCunninghamTheme(); - - return ( - - - {t('Personal data and cookies')} - - - - {t('Cookies placed')} - - - {t( - 'This site places a small text file (a "cookie") on your computer when you visit it.', - )} - {t( - 'This allows us to measure the number of visits and understand which pages are the most viewed.', - )} - - - {t('You can oppose the tracking of your browsing on this website.')} - {t( - 'This will protect your privacy, but will also prevent the owner from learning from your actions and creating a better experience for you and other users.', - )} - - - {t('This site does not display a cookie consent banner, why?')} - - - {t( - "It's true, you didn't have to click on a block that covers half the page to say you agree to the placement of cookies — even if you don't know what it means!", - )} - - - {t( - 'Nothing exceptional, no special privileges related to a .gouv.fr.', - )} - {t( - 'We simply comply with the law, which states that certain audience measurement tools, properly configured to respect privacy, are exempt from prior authorization.', - )} - - - - ); -}; - -Page.getLayout = function getLayout(page: ReactElement) { - return {page}; -}; - -export default Page;