diff --git a/site/source/App.tsx b/site/source/components/App.tsx similarity index 84% rename from site/source/App.tsx rename to site/source/components/App.tsx index 8cfc0fc36..38abc7640 100644 --- a/site/source/App.tsx +++ b/site/source/components/App.tsx @@ -19,26 +19,26 @@ import { import { useIsEmbedded } from '@/components/utils/useIsEmbedded' import { Container, Spacing } from '@/design-system/layout' +import { useAxeCoreAnalysis } from '../hooks/useAxeCoreAnalysis' +import { useGetFullURL } from '../hooks/useGetFullURL' +import { useSaveAndRestoreScrollPosition } from '../hooks/useSaveAndRestoreScrollPosition' +import Accessibilité from '../pages/Accessibilité' +import Budget from '../pages/Budget/Budget' +import Créer from '../pages/Creer' +import IntegrationTest from '../pages/Dev/IntegrationTest' +import Documentation from '../pages/Documentation' +import Iframes from '../pages/Iframes' +import Landing from '../pages/Landing/Landing' +import Nouveautés from '../pages/Nouveautes/Nouveautes' +import Offline from '../pages/Offline' +import Plan from '../pages/Plan' +import Simulateurs from '../pages/Simulateurs' +import Stats from '../pages/Stats/LazyStats' +import Assistants from '../pages/assistants' +import Gérer from '../pages/gerer' +import Integration from '../pages/integration/index' +import { useSitePaths } from '../sitePaths' import Provider, { ProviderProps } from './Provider' -import { useAxeCoreAnalysis } from './hooks/useAxeCoreAnalysis' -import { useGetFullURL } from './hooks/useGetFullURL' -import { useSaveAndRestoreScrollPosition } from './hooks/useSaveAndRestoreScrollPosition' -import Accessibilité from './pages/Accessibilité' -import Budget from './pages/Budget/Budget' -import Créer from './pages/Creer' -import IntegrationTest from './pages/Dev/IntegrationTest' -import Documentation from './pages/Documentation' -import Iframes from './pages/Iframes' -import Landing from './pages/Landing/Landing' -import Nouveautés from './pages/Nouveautes/Nouveautes' -import Offline from './pages/Offline' -import Plan from './pages/Plan' -import Simulateurs from './pages/Simulateurs' -import Stats from './pages/Stats/LazyStats' -import Assistants from './pages/assistants' -import Gérer from './pages/gerer' -import Integration from './pages/integration/index' -import { useSitePaths } from './sitePaths' type RootProps = { basename: ProviderProps['basename'] diff --git a/site/source/Provider.tsx b/site/source/components/Provider.tsx similarity index 90% rename from site/source/Provider.tsx rename to site/source/components/Provider.tsx index adcd240af..e5399eccf 100644 --- a/site/source/Provider.tsx +++ b/site/source/components/Provider.tsx @@ -18,14 +18,14 @@ import { Link } from '@/design-system/typography/link' import { Body, Intro } from '@/design-system/typography/paragraphs' import { useIframeResizer } from '@/hooks/useIframeResizer' -import { TrackingContext } from './components/ATInternetTracking' -import { createTracker } from './components/ATInternetTracking/Tracker' -import { ServiceWorker } from './components/ServiceWorker' -import { DarkModeProvider } from './contexts/DarkModeContext' -import { Message } from './design-system' -import * as safeLocalStorage from './storage/safeLocalStorage' -import { store } from './store/store' -import { inIframe } from './utils' +import { DarkModeProvider } from '../contexts/DarkModeContext' +import { Message } from '../design-system' +import * as safeLocalStorage from '../storage/safeLocalStorage' +import { store } from '../store/store' +import { inIframe } from '../utils' +import { TrackingContext } from './ATInternetTracking' +import { createTracker } from './ATInternetTracking/Tracker' +import { ServiceWorker } from './ServiceWorker' type SiteName = 'mon-entreprise' | 'infrance' | 'publicodes' diff --git a/site/source/components/utils/markdown.tsx b/site/source/components/utils/markdown.tsx index aa0a28a0f..f2652c032 100644 --- a/site/source/components/utils/markdown.tsx +++ b/site/source/components/utils/markdown.tsx @@ -10,9 +10,9 @@ import { H1, H2, H3, H4, H5, H6 } from '@/design-system/typography/heading' import { Link } from '@/design-system/typography/link' import { Li, Ol, Ul } from '@/design-system/typography/list' import { Body } from '@/design-system/typography/paragraphs' +import { isIterable } from '@/utils' -import { SiteNameContext } from '../../Provider' -import { isIterable } from '../../utils' +import { SiteNameContext } from '../Provider' const internalURLs = { 'mon-entreprise.urssaf.fr': 'mon-entreprise', diff --git a/site/source/entries/entry-en.tsx b/site/source/entries/entry-en.tsx index a2e097920..a51b1238d 100644 --- a/site/source/entries/entry-en.tsx +++ b/site/source/entries/entry-en.tsx @@ -2,7 +2,7 @@ import { I18nProvider } from '@react-aria/i18n' import { withProfiler } from '@sentry/react' import { createRoot } from 'react-dom/client' -import App from '../App' +import App from '../components/App' import i18next from '../locales/i18n' import ruleTranslations from '../locales/rules-en.yaml' import translateRules from '../locales/translateRules' diff --git a/site/source/entries/entry-fr.tsx b/site/source/entries/entry-fr.tsx index e0975401f..5ecd5346f 100644 --- a/site/source/entries/entry-fr.tsx +++ b/site/source/entries/entry-fr.tsx @@ -2,7 +2,7 @@ import { I18nProvider } from '@react-aria/i18n' import { withProfiler } from '@sentry/react' import { createRoot } from 'react-dom/client' -import App from '../App' +import App from '../components/App' import i18next from '../locales/i18n' import '../api/sentry'