🚚 Déplace le site publicodes dans le bon répertoire

Déplace:
mon-entreprise/source/sites/publi.codes → publicodes/site
mon-entreprise/source/sites/mon-entreprise.fr → mon-entreprise/source/site

La config Webpack du site publicodes reste encore liée à celle de
mon-entreprise.fr, il faudra la dissocier quand nous déplacerons le
projet publicodes dans son propre dépôt.
pull/1317/head
Maxime Quandalle 2020-12-16 16:41:53 +01:00
parent 037e37599e
commit 803e49f787
159 changed files with 681 additions and 90 deletions

View File

@ -7,7 +7,7 @@ import classnames from 'classnames'
import Conversation from 'Components/conversation/Conversation'
import SeeAnswersButton from 'Components/conversation/SeeAnswersButton'
import Value from 'Components/EngineValue'
import dirigeantComparaison from '../sites/mon-entreprise.fr/pages/Simulateurs/configs/rémunération-dirigeant.yaml'
import dirigeantComparaison from '../site/pages/Simulateurs/configs/rémunération-dirigeant.yaml'
import Engine from 'publicodes'
import revenusSVG from 'Images/revenus.svg'
import { useCallback, useMemo, useState, useEffect } from 'react'

View File

@ -1,5 +1,5 @@
import { createContext } from 'react'
import { SitePathsType } from 'sites/mon-entreprise.fr/sitePaths'
import { SitePathsType } from 'site/sitePaths'
export const SitePathsContext = createContext<SitePathsType>(
{} as SitePathsType

View File

@ -65,7 +65,6 @@ type MarkdownProps = ReactMarkdownProps & {
className?: string
}
const LazySyntaxHighlighter = React.lazy(() => import('../SyntaxHighlighter'))
const CodeBlock = ({
value,
language,
@ -78,15 +77,9 @@ const CodeBlock = ({
position: relative;
`}
>
<Suspense
fallback={
<pre className="ui__ code">
<code>{value}</code>
</pre>
}
>
<LazySyntaxHighlighter language={language} source={value} />
</Suspense>
<pre className="ui__ code">
<code>{value}</code>
</pre>
{language === 'yaml' && (
<a
href={`https://publi.codes/studio?code=${encodeURIComponent(value)}`}

View File

@ -18,7 +18,8 @@ const rewrite = (basename) => ({
app.get('/', function (req, res) {
res.send(`<ul><li><a href="/mon-entreprise">mon-entreprise [fr]</a></li>
<li><a href="/infrance">infrance [en]</a></li>
<li><a href="/mon-entreprise/dev/integration-test">intégration du simulateur sur site tiers [iframe fr]</a></li><li><a href="/publicodes">publicodes</a></li></ul>`)
<li><a href="/mon-entreprise/dev/integration-test">intégration du simulateur sur site tiers [iframe fr]</a></li>
<li><a href="/publicodes">publicodes</a></li></ul>`)
})
app.use(

View File

@ -19,16 +19,16 @@ import {
configSituationSelector,
situationSelector,
} from 'Selectors/simulationSelectors'
import Provider, { ProviderProps } from '../../Provider'
import Provider, { ProviderProps } from '../Provider'
import {
persistEverything,
retrievePersistedState,
} from '../../storage/persistEverything'
} from '../storage/persistEverything'
import {
persistSimulation,
retrievePersistedSimulation,
} from '../../storage/persistSimulation'
import Tracker, { devTracker } from '../../Tracker'
} from '../storage/persistSimulation'
import Tracker, { devTracker } from '../Tracker'
import './App.css'
import Footer from './layout/Footer/Footer'
import Header from './layout/Header'

View File

@ -4,9 +4,9 @@ import { translateRules } from 'publicodes'
import { render } from 'react-dom'
import 'regenerator-runtime/runtime'
import rules from 'modele-social'
import i18next from '../../i18n'
import translations from '../../locales/ui-en.yaml'
import ruleTranslations from '../../locales/rules-en.yaml'
import i18next from '../i18n'
import translations from '../locales/ui-en.yaml'
import ruleTranslations from '../locales/rules-en.yaml'
import App from './App'
i18next.addResourceBundle('en', 'translation', translations)

View File

@ -5,7 +5,7 @@ import { render } from 'react-dom'
import 'regenerator-runtime/runtime'
import rules from 'modele-social'
import App from './App'
import i18next from '../../i18n'
import i18next from '../i18n'
i18next.changeLanguage('fr')

View File

Before

Width:  |  Height:  |  Size: 5.0 KiB

After

Width:  |  Height:  |  Size: 5.0 KiB

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

View File

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

View File

Before

Width:  |  Height:  |  Size: 4.6 KiB

After

Width:  |  Height:  |  Size: 4.6 KiB

View File

Before

Width:  |  Height:  |  Size: 5.0 KiB

After

Width:  |  Height:  |  Size: 5.0 KiB

View File

@ -9,7 +9,7 @@ import { Helmet } from 'react-helmet'
import { Trans } from 'react-i18next'
import { Link, useLocation } from 'react-router-dom'
import useSimulatorsData from '../../pages/Simulateurs/metadata'
import i18n, { AvailableLangs } from '../../../../i18n'
import i18n, { AvailableLangs } from '../../../i18n'
import { hrefLangLink } from '../../sitePaths'
import './Footer.css'
import Privacy from './Privacy'

View File

@ -4,7 +4,7 @@ import { useContext } from 'react'
import emoji from 'react-easy-emoji'
import { useTranslation } from 'react-i18next'
import { Link } from 'react-router-dom'
import lastRelease from '../../../data/last-release.json'
import lastRelease from '../../data/last-release.json'
const localStorageKey = 'last-viewed-release'

View File

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

View File

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

View File

@ -16,7 +16,7 @@ import {
useContext,
} from 'react'
import emoji from 'react-easy-emoji'
import { hash } from '../../../../../utils'
import { hash } from '../../../../utils'
import formulaire from './formulaire-détachement.yaml'
const LazyEndBlock = lazy(() => import('./EndBlock'))

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 18 KiB

View File

@ -1,6 +1,6 @@
import { IsEmbeddedContext } from 'Components/utils/embeddedContext'
import { Route, Switch } from 'react-router-dom'
import { inIframe } from '../../../../utils'
import { inIframe } from '../../../utils'
import useSimulatorsData from '../Simulateurs/metadata'
import SimulateurPage from '../Simulateurs/Page'
import IframeFooter from './IframeFooter'

View File

Before

Width:  |  Height:  |  Size: 5.0 KiB

After

Width:  |  Height:  |  Size: 5.0 KiB

Some files were not shown because too many files have changed in this diff Show More