diff --git a/.eslintrc.js b/.eslintrc.js index 846b4d3ce..926164b5f 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -16,8 +16,8 @@ module.exports = { }, plugins: [ "react", - "react-hooks", - "mocha" + "react-hooks", + "mocha" ], rules: { "quotes": [ @@ -39,9 +39,11 @@ module.exports = { "react/no-unescaped-entities": 0, "react/display-name": 1, "react-hooks/rules-of-hooks": "error", - "react-hooks/exhaustive-deps": "warn", - "mocha/no-skipped-tests": "warn", - "mocha/no-exclusive-tests": "error" + "react-hooks/exhaustive-deps": "warn", + "react/jsx-uses-react": "off", + "react/react-in-jsx-scope": "off", + "mocha/no-skipped-tests": "warn", + "mocha/no-exclusive-tests": "error" }, settings: { "react": { @@ -71,21 +73,21 @@ module.exports = { "@typescript-eslint/explicit-function-return-type": 0, '@typescript-eslint/prefer-string-starts-ends-with': 1, '@typescript-eslint/no-unnecessary-type-assertion': 1, // has false positives (Object.values result) v 2.29.0 - '@typescript-eslint/no-inferrable-types': 1, // causes problems with unknown values v 2.29.0 typescript v 3.8.3 - '@typescript-eslint/no-var-requires': 'off', - // TODO - enable these new recommended rules, a first step would be to switch from "off" to "warn" - '@typescript-eslint/explicit-module-boundary-types': 'off', - '@typescript-eslint/no-floating-promises': 'off', - '@typescript-eslint/no-extra-semi': 'off', - '@typescript-eslint/no-unsafe-assignment': 'off', - '@typescript-eslint/no-unsafe-call': 'off', - '@typescript-eslint/no-unsafe-member-access': 'off', - '@typescript-eslint/no-unsafe-return': 'off', - '@typescript-eslint/restrict-plus-operands': 'off', - '@typescript-eslint/restrict-template-expressions': 'off', - '@typescript-eslint/naming-convention': 'off', - '@typescript-eslint/prefer-regexp-exec': 'off', - '@typescript-eslint/no-explicit-any': 'off', + '@typescript-eslint/no-inferrable-types': 1, // causes problems with unknown values v 2.29.0 typescript v 3.8.3 + '@typescript-eslint/no-var-requires': 'off', + // TODO - enable these new recommended rules, a first step would be to switch from "off" to "warn" + '@typescript-eslint/explicit-module-boundary-types': 'off', + '@typescript-eslint/no-floating-promises': 'off', + '@typescript-eslint/no-extra-semi': 'off', + '@typescript-eslint/no-unsafe-assignment': 'off', + '@typescript-eslint/no-unsafe-call': 'off', + '@typescript-eslint/no-unsafe-member-access': 'off', + '@typescript-eslint/no-unsafe-return': 'off', + '@typescript-eslint/restrict-plus-operands': 'off', + '@typescript-eslint/restrict-template-expressions': 'off', + '@typescript-eslint/naming-convention': 'off', + '@typescript-eslint/prefer-regexp-exec': 'off', + '@typescript-eslint/no-explicit-any': 'off', }, extends: [ "plugin:@typescript-eslint/recommended", @@ -93,7 +95,7 @@ module.exports = { ] }, { - files: ["**/*.test.js"], + files: ["**/*.test.js"], env: { mocha: true } diff --git a/babel.config.json b/babel.config.json index 0711618a6..130fee74c 100644 --- a/babel.config.json +++ b/babel.config.json @@ -8,7 +8,12 @@ } } ], - "@babel/preset-react", + [ + "@babel/preset-react", + { + "runtime": "automatic" + } + ], "@babel/preset-typescript" ], "plugins": [ diff --git a/mon-entreprise/package.json b/mon-entreprise/package.json index 1bcbd725d..083215219 100644 --- a/mon-entreprise/package.json +++ b/mon-entreprise/package.json @@ -72,7 +72,7 @@ "nearley": "^2.19.0", "publicodes": "^1.0.0-beta.4", "ramda": "^0.27.0", - "react": "^16.13.1", + "react": "^17.0.0", "react-color": "^2.14.0", "react-dom": "npm:@hot-loader/react-dom", "react-easy-emoji": "^1.2.0", diff --git a/mon-entreprise/source/components/CompanyDetails.tsx b/mon-entreprise/source/components/CompanyDetails.tsx index 0e1c6e152..3c05b23fa 100644 --- a/mon-entreprise/source/components/CompanyDetails.tsx +++ b/mon-entreprise/source/components/CompanyDetails.tsx @@ -1,4 +1,4 @@ -import React, { useEffect, useMemo, useState } from 'react' +import { useEffect, useMemo, useState } from 'react' import { Trans, useTranslation } from 'react-i18next' import Skeleton from 'Components/ui/Skeleton' import { Etablissement, fetchCompanyDetails } from '../api/sirene' diff --git a/mon-entreprise/source/components/CurrencyInput/CurrencyInput.test.js b/mon-entreprise/source/components/CurrencyInput/CurrencyInput.test.js index 12b2f7110..80819c793 100644 --- a/mon-entreprise/source/components/CurrencyInput/CurrencyInput.test.js +++ b/mon-entreprise/source/components/CurrencyInput/CurrencyInput.test.js @@ -1,6 +1,5 @@ import { expect } from 'chai' import { mount, shallow } from 'enzyme' -import React from 'react' import { match, spy, useFakeTimers } from 'sinon' import CurrencyInput from './CurrencyInput' diff --git a/mon-entreprise/source/components/Distribution.tsx b/mon-entreprise/source/components/Distribution.tsx index aefe4356a..0f987e8b0 100644 --- a/mon-entreprise/source/components/Distribution.tsx +++ b/mon-entreprise/source/components/Distribution.tsx @@ -1,6 +1,6 @@ import { EngineContext } from 'Components/utils/EngineContext' import { max } from 'ramda' -import React, { useContext } from 'react' +import { useContext } from 'react' import { useSelector } from 'react-redux' import { DottedName } from 'Rules' import { targetUnitSelector } from 'Selectors/simulationSelectors' diff --git a/mon-entreprise/source/components/Feedback/LinkToForm.tsx b/mon-entreprise/source/components/Feedback/LinkToForm.tsx index 79638cf95..92b3aa667 100644 --- a/mon-entreprise/source/components/Feedback/LinkToForm.tsx +++ b/mon-entreprise/source/components/Feedback/LinkToForm.tsx @@ -1,5 +1,3 @@ -import React from 'react' - // Envie de donner un coup de pouce ? Répondez à notre sondage sur le simulateur. export default function LinkToForm() { const hostname = new URL( diff --git a/mon-entreprise/source/components/FindCompany.tsx b/mon-entreprise/source/components/FindCompany.tsx index d93342940..be2d3e469 100644 --- a/mon-entreprise/source/components/FindCompany.tsx +++ b/mon-entreprise/source/components/FindCompany.tsx @@ -1,6 +1,6 @@ import { setEntreprise } from 'Actions/existingCompanyActions' import CompanyDetails from 'Components/CompanyDetails' -import React, { useCallback, useMemo, useState } from 'react' +import { useCallback, useMemo, useState } from 'react' import { Trans } from 'react-i18next' import { useDispatch } from 'react-redux' import { Etablissement, searchDenominationOrSiren } from '../api/sirene' diff --git a/mon-entreprise/source/components/LangSwitcher.tsx b/mon-entreprise/source/components/LangSwitcher.tsx index 977d790e7..e3aa08d50 100644 --- a/mon-entreprise/source/components/LangSwitcher.tsx +++ b/mon-entreprise/source/components/LangSwitcher.tsx @@ -1,4 +1,3 @@ -import React from 'react' import emoji from 'react-easy-emoji' import { useTranslation } from 'react-i18next' diff --git a/mon-entreprise/source/components/LegalNotice.tsx b/mon-entreprise/source/components/LegalNotice.tsx index a08ee4fbe..51374e07d 100644 --- a/mon-entreprise/source/components/LegalNotice.tsx +++ b/mon-entreprise/source/components/LegalNotice.tsx @@ -1,5 +1,5 @@ import Overlay from 'Components/Overlay' -import React, { useState } from 'react' +import { useState } from 'react' import { Trans } from 'react-i18next' export const LegalNoticeContent = () => ( diff --git a/mon-entreprise/source/components/MoreInfosOnUs.tsx b/mon-entreprise/source/components/MoreInfosOnUs.tsx index 6a08390d5..3eb0ae636 100644 --- a/mon-entreprise/source/components/MoreInfosOnUs.tsx +++ b/mon-entreprise/source/components/MoreInfosOnUs.tsx @@ -1,4 +1,4 @@ -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { useTranslation } from 'react-i18next' import { Link, useLocation } from 'react-router-dom' diff --git a/mon-entreprise/source/components/NewsletterRegister.tsx b/mon-entreprise/source/components/NewsletterRegister.tsx index 8a7af806a..88177f6e1 100644 --- a/mon-entreprise/source/components/NewsletterRegister.tsx +++ b/mon-entreprise/source/components/NewsletterRegister.tsx @@ -1,6 +1,6 @@ import { usePersistingState } from 'Components/utils/persistState' import { TrackerContext } from 'Components/utils/withTracker' -import React, { useContext, useRef, useState } from 'react' +import { useContext, useRef, useState } from 'react' import { Trans, useTranslation } from 'react-i18next' import emoji from 'react-easy-emoji' import * as animate from 'Components/ui/animate' diff --git a/mon-entreprise/source/components/Notifications.tsx b/mon-entreprise/source/components/Notifications.tsx index 45911f0ef..eef88d995 100644 --- a/mon-entreprise/source/components/Notifications.tsx +++ b/mon-entreprise/source/components/Notifications.tsx @@ -1,7 +1,7 @@ import { hideNotification } from 'Actions/actions' import animate from 'Components/ui/animate' import { useInversionFail, EngineContext } from 'Components/utils/EngineContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { useTranslation } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' diff --git a/mon-entreprise/source/components/PaySlip.tsx b/mon-entreprise/source/components/PaySlip.tsx index 9acbf2bc0..68ca9c90c 100644 --- a/mon-entreprise/source/components/PaySlip.tsx +++ b/mon-entreprise/source/components/PaySlip.tsx @@ -2,7 +2,7 @@ import Value from 'Components/EngineValue' import RuleLink from 'Components/RuleLink' import { EngineContext, useEvaluation } from 'Components/utils/EngineContext' import { formatValue, ParsedRule, ParsedRules } from 'publicodes' -import React, { Fragment, useContext } from 'react' +import { Fragment, useContext } from 'react' import { Trans, useTranslation } from 'react-i18next' import { DottedName } from 'Rules' import './PaySlip.css' diff --git a/mon-entreprise/source/components/PaySlipSections.tsx b/mon-entreprise/source/components/PaySlipSections.tsx index fa0faa79b..bf8f9d7dd 100644 --- a/mon-entreprise/source/components/PaySlipSections.tsx +++ b/mon-entreprise/source/components/PaySlipSections.tsx @@ -1,7 +1,5 @@ import Value, { Condition, ValueProps } from 'Components/EngineValue' import RuleLink from 'Components/RuleLink' -import { EngineContext } from 'Components/utils/EngineContext' -import React, { useContext } from 'react' import { Trans } from 'react-i18next' import { DottedName } from 'Rules' diff --git a/mon-entreprise/source/components/PercentageField.tsx b/mon-entreprise/source/components/PercentageField.tsx index d7bf2e97a..5bb76ffca 100644 --- a/mon-entreprise/source/components/PercentageField.tsx +++ b/mon-entreprise/source/components/PercentageField.tsx @@ -1,5 +1,5 @@ import { formatValue } from 'publicodes' -import React, { useCallback, useState } from 'react' +import { useCallback, useState } from 'react' import { useTranslation } from 'react-i18next' import { debounce as debounceFn } from '../utils' import './PercentageField.css' diff --git a/mon-entreprise/source/components/PeriodSwitch.tsx b/mon-entreprise/source/components/PeriodSwitch.tsx index a5c57bf02..f0fc5291b 100644 --- a/mon-entreprise/source/components/PeriodSwitch.tsx +++ b/mon-entreprise/source/components/PeriodSwitch.tsx @@ -1,5 +1,4 @@ import { updateUnit } from 'Actions/actions' -import React from 'react' import { Trans } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' import { targetUnitSelector } from 'Selectors/simulationSelectors' diff --git a/mon-entreprise/source/components/PreviousSimulationBanner.tsx b/mon-entreprise/source/components/PreviousSimulationBanner.tsx index 22e943e95..0a389846e 100644 --- a/mon-entreprise/source/components/PreviousSimulationBanner.tsx +++ b/mon-entreprise/source/components/PreviousSimulationBanner.tsx @@ -1,5 +1,4 @@ import { loadPreviousSimulation } from 'Actions/actions' -import React from 'react' import { Trans } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' import { RootState } from 'Reducers/rootReducer' diff --git a/mon-entreprise/source/components/QuickLinks.tsx b/mon-entreprise/source/components/QuickLinks.tsx index 246863f7a..096a0f5c5 100644 --- a/mon-entreprise/source/components/QuickLinks.tsx +++ b/mon-entreprise/source/components/QuickLinks.tsx @@ -1,6 +1,5 @@ import { goToQuestion } from 'Actions/actions' import { contains, filter, pipe, reject, toPairs } from 'ramda' -import React from 'react' import { Trans } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' import { RootState } from 'Reducers/rootReducer' diff --git a/mon-entreprise/source/components/Route404.tsx b/mon-entreprise/source/components/Route404.tsx index 5cbd289be..9d27dbf63 100644 --- a/mon-entreprise/source/components/Route404.tsx +++ b/mon-entreprise/source/components/Route404.tsx @@ -1,5 +1,4 @@ import image from 'Images/map-directions.png' -import React from 'react' import emoji from 'react-easy-emoji' import { Trans } from 'react-i18next' import { Link } from 'react-router-dom' diff --git a/mon-entreprise/source/components/RulesList.tsx b/mon-entreprise/source/components/RulesList.tsx index 2f8658e3a..7be5822f2 100644 --- a/mon-entreprise/source/components/RulesList.tsx +++ b/mon-entreprise/source/components/RulesList.tsx @@ -1,5 +1,4 @@ import SearchBar from 'Components/SearchBar' -import React from 'react' import { Trans } from 'react-i18next' import './RulesList.css' diff --git a/mon-entreprise/source/components/SearchButton.tsx b/mon-entreprise/source/components/SearchButton.tsx index 2e63022b6..0a55202ae 100644 --- a/mon-entreprise/source/components/SearchButton.tsx +++ b/mon-entreprise/source/components/SearchButton.tsx @@ -1,4 +1,4 @@ -import React, { useEffect, useState } from 'react' +import { useEffect, useState } from 'react' import emoji from 'react-easy-emoji' import { Trans } from 'react-i18next' import Overlay from './Overlay' diff --git a/mon-entreprise/source/components/SimulateurWarning.tsx b/mon-entreprise/source/components/SimulateurWarning.tsx index 779e75124..5f84ddfe6 100644 --- a/mon-entreprise/source/components/SimulateurWarning.tsx +++ b/mon-entreprise/source/components/SimulateurWarning.tsx @@ -1,5 +1,4 @@ import Warning from 'Components/ui/WarningBlock' -import React from 'react' import { Trans } from 'react-i18next' import { SitePaths } from './utils/SitePathsContext' diff --git a/mon-entreprise/source/components/SyntaxHighlighter.tsx b/mon-entreprise/source/components/SyntaxHighlighter.tsx index fb196247a..b2f2316d6 100644 --- a/mon-entreprise/source/components/SyntaxHighlighter.tsx +++ b/mon-entreprise/source/components/SyntaxHighlighter.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { PrismLight } from 'react-syntax-highlighter' import js from 'react-syntax-highlighter/dist/esm/languages/prism/javascript' import jsx from 'react-syntax-highlighter/dist/esm/languages/prism/jsx' diff --git a/mon-entreprise/source/components/TargetSelection.tsx b/mon-entreprise/source/components/TargetSelection.tsx index e8c7cb4f0..a3e8f8829 100644 --- a/mon-entreprise/source/components/TargetSelection.tsx +++ b/mon-entreprise/source/components/TargetSelection.tsx @@ -13,7 +13,7 @@ import { import { SitePathsContext } from 'Components/utils/SitePathsContext' import { EvaluatedRule, formatValue } from 'publicodes' import { isNil } from 'ramda' -import React, { useCallback, useContext } from 'react' +import { Fragment, useCallback, useContext } from 'react' import emoji from 'react-easy-emoji' import { Trans, useTranslation } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' @@ -42,7 +42,7 @@ export default function TargetSelection({ showPeriodSwitch = true }) { nom?: string objectifs: Array }>).map(({ icône, objectifs: targets, nom }, index: number) => ( - +
{nom && ( @@ -72,7 +72,7 @@ export default function TargetSelection({ showPeriodSwitch = true }) { ))} - + ))}
) diff --git a/mon-entreprise/source/components/TypeFormEmbed.js b/mon-entreprise/source/components/TypeFormEmbed.js index e83ed3194..5a083ce59 100644 --- a/mon-entreprise/source/components/TypeFormEmbed.js +++ b/mon-entreprise/source/components/TypeFormEmbed.js @@ -1,4 +1,3 @@ -import React from 'react' import { Helmet } from 'react-helmet' let createQueryParams = params => diff --git a/mon-entreprise/source/components/conversation/Aide.tsx b/mon-entreprise/source/components/conversation/Aide.tsx index cf2ff4103..f48549d7e 100644 --- a/mon-entreprise/source/components/conversation/Aide.tsx +++ b/mon-entreprise/source/components/conversation/Aide.tsx @@ -1,7 +1,7 @@ import { explainVariable } from 'Actions/actions' import Overlay from 'Components/Overlay' import { Markdown } from 'Components/utils/markdown' -import React, { useContext } from 'react' +import { useContext } from 'react' import { useDispatch, useSelector } from 'react-redux' import { RootState } from 'Reducers/rootReducer' import './Aide.css' diff --git a/mon-entreprise/source/components/conversation/AnswerList.tsx b/mon-entreprise/source/components/conversation/AnswerList.tsx index 21b9b99c1..9c3fd7266 100644 --- a/mon-entreprise/source/components/conversation/AnswerList.tsx +++ b/mon-entreprise/source/components/conversation/AnswerList.tsx @@ -3,7 +3,6 @@ import Overlay from 'Components/Overlay' import { useEvaluation } from 'Components/utils/EngineContext' import { useNextQuestions } from 'Components/utils/useNextQuestion' import { formatValue } from 'publicodes' -import React from 'react' import emoji from 'react-easy-emoji' import { Trans, useTranslation } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' diff --git a/mon-entreprise/source/components/conversation/DateInput.tsx b/mon-entreprise/source/components/conversation/DateInput.tsx index 8db6426af..15deeeb7d 100644 --- a/mon-entreprise/source/components/conversation/DateInput.tsx +++ b/mon-entreprise/source/components/conversation/DateInput.tsx @@ -1,6 +1,6 @@ import { RuleInputProps } from 'Components/conversation/RuleInput' import { Rule } from 'publicodes' -import React, { useCallback, useMemo } from 'react' +import { useCallback, useMemo } from 'react' import styled from 'styled-components' import InputSuggestions from './InputSuggestions' diff --git a/mon-entreprise/source/components/conversation/Input.tsx b/mon-entreprise/source/components/conversation/Input.tsx index f1c91bbe9..284fc99f1 100644 --- a/mon-entreprise/source/components/conversation/Input.tsx +++ b/mon-entreprise/source/components/conversation/Input.tsx @@ -1,5 +1,5 @@ import { formatValue } from 'publicodes' -import React, { useCallback, useState } from 'react' +import { useCallback, useState } from 'react' import { useTranslation } from 'react-i18next' import NumberFormat from 'react-number-format' import { currencyFormat, debounce } from '../../utils' diff --git a/mon-entreprise/source/components/conversation/InputSuggestions.tsx b/mon-entreprise/source/components/conversation/InputSuggestions.tsx index fe3562cb6..8316a7458 100644 --- a/mon-entreprise/source/components/conversation/InputSuggestions.tsx +++ b/mon-entreprise/source/components/conversation/InputSuggestions.tsx @@ -1,6 +1,6 @@ import { serializeValue } from 'publicodes' import { toPairs } from 'ramda' -import React, { useState } from 'react' +import { useState } from 'react' import { useTranslation } from 'react-i18next' import { Unit } from 'publicodes' diff --git a/mon-entreprise/source/components/conversation/ParagrapheInput.tsx b/mon-entreprise/source/components/conversation/ParagrapheInput.tsx index 42aafecfc..b339bce0a 100644 --- a/mon-entreprise/source/components/conversation/ParagrapheInput.tsx +++ b/mon-entreprise/source/components/conversation/ParagrapheInput.tsx @@ -1,4 +1,4 @@ -import React, { useCallback } from 'react' +import { useCallback } from 'react' import { debounce } from '../../utils' export default function ParagrapheInput({ diff --git a/mon-entreprise/source/components/conversation/Question.tsx b/mon-entreprise/source/components/conversation/Question.tsx index b668635cb..44837befb 100644 --- a/mon-entreprise/source/components/conversation/Question.tsx +++ b/mon-entreprise/source/components/conversation/Question.tsx @@ -1,7 +1,7 @@ import classnames from 'classnames' import { Markdown } from 'Components/utils/markdown' import { is } from 'ramda' -import React, { useCallback, useEffect, useState } from 'react' +import { useCallback, useEffect, useState } from 'react' import emoji from 'react-easy-emoji' import { Trans } from 'react-i18next' import { Explicable } from './Explicable' diff --git a/mon-entreprise/source/components/conversation/SeeAnswersButton.tsx b/mon-entreprise/source/components/conversation/SeeAnswersButton.tsx index 40b0f92f9..00a678764 100644 --- a/mon-entreprise/source/components/conversation/SeeAnswersButton.tsx +++ b/mon-entreprise/source/components/conversation/SeeAnswersButton.tsx @@ -1,4 +1,4 @@ -import React, { useState } from 'react' +import { useState } from 'react' import { Trans } from 'react-i18next' import Answers from './AnswerList' import './conversation.css' diff --git a/mon-entreprise/source/components/conversation/TextInput.tsx b/mon-entreprise/source/components/conversation/TextInput.tsx index ba7779ab3..c8a3d3d2f 100644 --- a/mon-entreprise/source/components/conversation/TextInput.tsx +++ b/mon-entreprise/source/components/conversation/TextInput.tsx @@ -1,5 +1,5 @@ import { ThemeColorsContext } from 'Components/utils/colors' -import React, { useCallback, useContext } from 'react' +import { useCallback, useContext } from 'react' import { debounce } from '../../utils' export default function TextInput({ diff --git a/mon-entreprise/source/components/conversation/select/SelectEuropeCountry.tsx b/mon-entreprise/source/components/conversation/select/SelectEuropeCountry.tsx index a3eaff003..83673a033 100644 --- a/mon-entreprise/source/components/conversation/select/SelectEuropeCountry.tsx +++ b/mon-entreprise/source/components/conversation/select/SelectEuropeCountry.tsx @@ -1,4 +1,3 @@ -import React from 'react' const STATES = [ 'Allemagne', 'Autriche', diff --git a/mon-entreprise/source/components/conversation/select/SelectTauxRisque.js b/mon-entreprise/source/components/conversation/select/SelectTauxRisque.js index e5b2d4466..16c39d2e4 100644 --- a/mon-entreprise/source/components/conversation/select/SelectTauxRisque.js +++ b/mon-entreprise/source/components/conversation/select/SelectTauxRisque.js @@ -1,4 +1,4 @@ -import React, { useEffect, useState } from 'react' +import { useEffect, useState } from 'react' import { Trans, useTranslation } from 'react-i18next' import Worker from 'worker-loader!./SelectTauxRisque.worker.js' const worker = new Worker() diff --git a/mon-entreprise/source/components/simulationExplanation/IndépendantExplanation.tsx b/mon-entreprise/source/components/simulationExplanation/IndépendantExplanation.tsx index 342e427d6..7540e7b79 100644 --- a/mon-entreprise/source/components/simulationExplanation/IndépendantExplanation.tsx +++ b/mon-entreprise/source/components/simulationExplanation/IndépendantExplanation.tsx @@ -8,7 +8,7 @@ import assuranceMaladieSrc from 'Images/assurance-maladie.svg' import * as logosSrc from 'Images/logos-cnavpl' import urssafSrc from 'Images/urssaf.svg' import { max } from 'ramda' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Trans, useTranslation } from 'react-i18next' import { useSelector } from 'react-redux' import { DottedName } from 'Rules' diff --git a/mon-entreprise/source/components/simulationExplanation/SalaryExplanation.tsx b/mon-entreprise/source/components/simulationExplanation/SalaryExplanation.tsx index dfa1ce72f..0420570e6 100644 --- a/mon-entreprise/source/components/simulationExplanation/SalaryExplanation.tsx +++ b/mon-entreprise/source/components/simulationExplanation/SalaryExplanation.tsx @@ -3,7 +3,7 @@ import PaySlip from 'Components/PaySlip' import StackedBarChart from 'Components/StackedBarChart' import { ThemeColorsContext } from 'Components/utils/colors' import { useEvaluation, useInversionFail } from 'Components/utils/EngineContext' -import React, { useContext, useRef } from 'react' +import { useContext, useRef } from 'react' import emoji from 'react-easy-emoji' import { Trans, useTranslation } from 'react-i18next' import { useSelector } from 'react-redux' diff --git a/mon-entreprise/source/components/ui/Skeleton.tsx b/mon-entreprise/source/components/ui/Skeleton.tsx index e84045d68..7ba85385f 100644 --- a/mon-entreprise/source/components/ui/Skeleton.tsx +++ b/mon-entreprise/source/components/ui/Skeleton.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { keyframes } from 'styled-components' type SkeletonProps = { diff --git a/mon-entreprise/source/components/ui/SocialIcon.tsx b/mon-entreprise/source/components/ui/SocialIcon.tsx index 556900c6e..b0d6079f3 100644 --- a/mon-entreprise/source/components/ui/SocialIcon.tsx +++ b/mon-entreprise/source/components/ui/SocialIcon.tsx @@ -1,5 +1,5 @@ import { ThemeColorsContext } from 'Components/utils/colors' -import React, { useContext } from 'react' +import { useContext } from 'react' export const icons = { facebook: { diff --git a/mon-entreprise/source/components/ui/WarningBlock.tsx b/mon-entreprise/source/components/ui/WarningBlock.tsx index dfec94ec6..36a009773 100644 --- a/mon-entreprise/source/components/ui/WarningBlock.tsx +++ b/mon-entreprise/source/components/ui/WarningBlock.tsx @@ -1,5 +1,5 @@ import { usePersistingState } from 'Components/utils/persistState' -import React, { ReactNode } from 'react' +import { ReactNode } from 'react' import emoji from 'react-easy-emoji' import { Trans } from 'react-i18next' diff --git a/mon-entreprise/source/components/utils/Meta.tsx b/mon-entreprise/source/components/utils/Meta.tsx index 3a1c293db..534acd628 100644 --- a/mon-entreprise/source/components/utils/Meta.tsx +++ b/mon-entreprise/source/components/utils/Meta.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { Helmet } from 'react-helmet' import { useLocation } from 'react-router' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/App.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/App.tsx index 32565648d..fbaeb217a 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/App.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/App.tsx @@ -8,7 +8,7 @@ import { import { SitePathsContext } from 'Components/utils/SitePathsContext' import 'iframe-resizer' import Engine from 'publicodes' -import React, { useContext, useMemo } from 'react' +import { useContext, useMemo } from 'react' import { Helmet } from 'react-helmet' import { useTranslation } from 'react-i18next' import { useSelector } from 'react-redux' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/entry.en.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/entry.en.tsx index 829df3bea..a4bf5b8b1 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/entry.en.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/entry.en.tsx @@ -1,7 +1,6 @@ import 'core-js/stable' import { hot } from 'react-hot-loader/root' import { translateRules } from 'publicodes' -import React from 'react' import { render } from 'react-dom' import 'regenerator-runtime/runtime' import rules from 'Rules' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/entry.fr.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/entry.fr.tsx index 917127843..aafc1f0e7 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/entry.fr.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/entry.fr.tsx @@ -1,7 +1,6 @@ import { hot } from 'react-hot-loader/root' import 'core-js/stable' import 'react-hot-loader' -import React from 'react' import { render } from 'react-dom' import 'regenerator-runtime/runtime' import rules from 'Rules' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Contact.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Contact.tsx index 9a95ba259..1db8c0a74 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Contact.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Contact.tsx @@ -1,5 +1,4 @@ import ContactImage from 'Images/contact.png' -import React from 'react' const Contact = () => (

diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Footer.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Footer.tsx index 7928efc0e..74a1c161c 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Footer.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Footer.tsx @@ -3,7 +3,7 @@ import LegalNotice from 'Components/LegalNotice' import NewsletterRegister from 'Components/NewsletterRegister' import SocialIcon from 'Components/ui/SocialIcon' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { Helmet } from 'react-helmet' import { Trans } from 'react-i18next' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Privacy.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Privacy.tsx index f4c49469b..564ccfc8f 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Privacy.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/layout/Footer/Privacy.tsx @@ -1,5 +1,5 @@ import Overlay from 'Components/Overlay' -import React, { useState } from 'react' +import { useState } from 'react' import { Trans, useTranslation } from 'react-i18next' export default function Privacy({ label }: { label?: string }) { diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/layout/Header.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/layout/Header.tsx index bd0d9e51d..1bf53479d 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/layout/Header.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/layout/Header.tsx @@ -3,7 +3,7 @@ import logoEnSvg from 'Images/logo-mycompany.svg' import logoSvg from 'Images/logo.svg' import marianneSvg from 'Images/marianne.svg' import urssafSvg from 'Images/urssaf.svg' -import React, { useContext } from 'react' +import { useContext } from 'react' import { useTranslation } from 'react-i18next' import { Link } from 'react-router-dom' import NewsBanner from './NewsBanner' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/layout/NewsBanner.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/layout/NewsBanner.tsx index 9e82bf4ec..d8924ab5a 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/layout/NewsBanner.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/layout/NewsBanner.tsx @@ -1,6 +1,6 @@ import { useLocalStorage, writeStorage } from '@rehooks/local-storage' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { useTranslation } from 'react-i18next' import { Link } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Budget/Budget.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Budget/Budget.tsx index 347aa762b..dd74ccaeb 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Budget/Budget.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Budget/Budget.tsx @@ -3,7 +3,7 @@ import { Markdown } from 'Components/utils/markdown' import { ScrollToTop } from 'Components/utils/Scroll' import { formatValue } from 'publicodes' import { sum, uniq } from 'ramda' -import React, { useState } from 'react' +import { useState } from 'react' import emoji from 'react-easy-emoji' import { useTranslation } from 'react-i18next' import styled from 'styled-components' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/AfterRegistration.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/AfterRegistration.tsx index e2ac72a88..3f7d427a3 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/AfterRegistration.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/AfterRegistration.tsx @@ -1,6 +1,6 @@ import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Trans, useTranslation } from 'react-i18next' import { useSelector } from 'react-redux' import { NavLink } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/CreationChecklist.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/CreationChecklist.tsx index b116f4df8..60b94359e 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/CreationChecklist.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/CreationChecklist.tsx @@ -5,7 +5,7 @@ import { import { goToCompanyStatusChoice } from 'Actions/companyStatusActions' import Scroll from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/AutoEntrepreneur.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/AutoEntrepreneur.tsx index ebcafb85f..83585645e 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/AutoEntrepreneur.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/AutoEntrepreneur.tsx @@ -1,5 +1,4 @@ import SchemeComparaison from 'Components/SchemeComparaison' -import React from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/DirectorStatus.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/DirectorStatus.tsx index cab68c7c6..6b0a2cf1f 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/DirectorStatus.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/DirectorStatus.tsx @@ -1,5 +1,4 @@ import SchemeComparaison from 'Components/SchemeComparaison' -import React from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/MinorityDirector.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/MinorityDirector.tsx index cca67a958..82660e040 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/MinorityDirector.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/MinorityDirector.tsx @@ -1,5 +1,4 @@ import { directorIsInAMinority } from 'Actions/companyStatusActions' -import React from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' import { useDispatch } from 'react-redux' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/NumberOfAssociate.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/NumberOfAssociate.tsx index c661c6979..13e623675 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/NumberOfAssociate.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/NumberOfAssociate.tsx @@ -1,5 +1,4 @@ import { companyHasMultipleAssociates } from 'Actions/companyStatusActions' -import React from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' import { useDispatch } from 'react-redux' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/PickLegalStatus.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/PickLegalStatus.tsx index 9b055e452..dfd030c6c 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/PickLegalStatus.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/PickLegalStatus.tsx @@ -1,6 +1,6 @@ import { SitePathsContext } from 'Components/utils/SitePathsContext' import { filter } from 'ramda' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' import { useSelector } from 'react-redux' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/PreviousAnswers.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/PreviousAnswers.tsx index eab706712..0ad409a81 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/PreviousAnswers.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/PreviousAnswers.tsx @@ -1,6 +1,6 @@ import { SitePathsContext } from 'Components/utils/SitePathsContext' import { isNil } from 'ramda' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Trans } from 'react-i18next' import { useSelector } from 'react-redux' import { Link } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/SoleProprietorship.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/SoleProprietorship.tsx index 97b12b4ea..da421fdf9 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/SoleProprietorship.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/SoleProprietorship.tsx @@ -1,5 +1,4 @@ import { isSoleProprietorship } from 'Actions/companyStatusActions' -import React from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' import { useDispatch } from 'react-redux' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/index.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/index.tsx index 8862cd6e6..d9e3ae5d7 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/index.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/GuideStatut/index.tsx @@ -1,7 +1,7 @@ import { resetCompanyStatusChoice } from 'Actions/companyStatusActions' import { SitePathsContext } from 'Components/utils/SitePathsContext' import { toPairs } from 'ramda' -import React, { useContext, useEffect } from 'react' +import { useContext, useEffect } from 'react' import { Trans } from 'react-i18next' import { useDispatch } from 'react-redux' import { NavLink, Route, Switch, useLocation } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/Home.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/Home.tsx index aaa6d3b26..d76cc2699 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/Home.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/Home.tsx @@ -1,5 +1,5 @@ import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' import { useSelector } from 'react-redux' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/StatutDescription.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/StatutDescription.tsx index b23293e17..11712bb05 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/StatutDescription.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/StatutDescription.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { Trans } from 'react-i18next' import { LegalStatus } from 'Selectors/companyStatusSelectors' type Props = { diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/index.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/index.tsx index 99747215e..19873da89 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/index.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Créer/index.tsx @@ -1,6 +1,6 @@ import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Route, Switch } from 'react-router-dom' import { useLocation } from 'react-router-dom' import { LANDING_LEGAL_STATUS_LIST } from '../../sitePaths' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/ColorPicker.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/ColorPicker.tsx index 8d35b0a7b..a3a84aa36 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/ColorPicker.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/ColorPicker.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { ChromePicker, ChromePickerProps } from 'react-color' type ColorPickerProps = { diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/IntegrationTest.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/IntegrationTest.tsx index 0e2a920bc..52978df91 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/IntegrationTest.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/IntegrationTest.tsx @@ -1,6 +1,6 @@ -import React, { Suspense, useMemo } from 'react' +import { lazy, useState, useRef, useEffect, Suspense, useMemo } from 'react' import useSimulatorsData from '../Simulateurs/metadata' -const LazyColorPicker = React.lazy(() => import('./ColorPicker')) +const LazyColorPicker = lazy(() => import('./ColorPicker')) export default function IntegrationTest() { const simulators = useSimulatorsData() @@ -11,13 +11,11 @@ export default function IntegrationTest() { .filter(Boolean), [simulators] ) - const [currentModule, setCurrentModule] = React.useState( - integrableModuleNames[0] - ) - const [color, setColor] = React.useState('#005aa1') - const [version, setVersion] = React.useState(0) - const domNode = React.useRef(null) - React.useEffect(() => { + const [currentModule, setCurrentModule] = useState(integrableModuleNames[0]) + const [color, setColor] = useState('#005aa1') + const [version, setVersion] = useState(0) + const domNode = useRef(null) + useEffect(() => { const script = document.createElement('script') script.id = 'script-monentreprise' script.src = window.location.origin + '/simulateur-iframe-integration.js' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/Personas.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/Personas.tsx index 3328a250d..ebaf90b48 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/Personas.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/Personas.tsx @@ -1,5 +1,3 @@ -import React from 'react' - export default function Personas() { return ( <> diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/Sitemap.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/Sitemap.tsx index e9af958ce..bf7179292 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/Sitemap.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Dev/Sitemap.tsx @@ -1,5 +1,5 @@ import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { generateSiteMap, SitePathsType } from '../../sitePaths' export default function SiteMap() { diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Documentation.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Documentation.tsx index fc0284546..abc7964e4 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Documentation.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Documentation.tsx @@ -5,7 +5,7 @@ import { EngineContext } from 'Components/utils/EngineContext' import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' import { Documentation, getDocumentationSiteMap } from 'publicodes' -import React, { useCallback, useContext, useMemo } from 'react' +import { useCallback, useContext, useMemo } from 'react' import { Trans, useTranslation } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' import { Redirect, useLocation } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/AideDéclarationIndépendant/index.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/AideDéclarationIndépendant/index.tsx index ebfc1919e..c0b7e883e 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/AideDéclarationIndépendant/index.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/AideDéclarationIndépendant/index.tsx @@ -8,7 +8,7 @@ import { ScrollToTop } from 'Components/utils/Scroll' import useDisplayOnIntersecting from 'Components/utils/useDisplayOnIntersecting' import RuleInput from 'Components/conversation/RuleInput' import { ParsedRule } from 'publicodes' -import React, { useCallback, useEffect, useState, useContext } from 'react' +import { Fragment, useCallback, useEffect, useState, useContext } from 'react' import { Trans } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' import { RootState } from 'Reducers/rootReducer' @@ -432,7 +432,7 @@ function Results() { <> {results.map(r => ( - +

{r.title} {r.summary}

@@ -449,7 +449,7 @@ function Results() { )}

- + ))} diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/AideOrganismeLocal.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/AideOrganismeLocal.tsx index 2bd7b8b3f..b3f4dd89b 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/AideOrganismeLocal.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/AideOrganismeLocal.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { useTranslation } from 'react-i18next' import { useSelector } from 'react-redux' import { RootState } from 'Reducers/rootReducer' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/EndBlock.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/EndBlock.tsx index d2755f7c8..eceac7654 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/EndBlock.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/EndBlock.tsx @@ -3,7 +3,7 @@ import Overlay from 'Components/Overlay' import Checkbox from 'Components/ui/Checkbox' import { ThemeColorsContext } from 'Components/utils/colors' import { TrackerContext } from 'Components/utils/withTracker' -import React, { Suspense, useContext, useRef, useState } from 'react' +import { lazy, Suspense, useContext, useRef, useState } from 'react' import emoji from 'react-easy-emoji' import SignaturePad from 'react-signature-pad-wrapper' import PDFDocument from './PDFDocument' @@ -186,7 +186,7 @@ export default function EndBlock({ fields, isMissingValues }) { ) } -const LazyBlobProvider = React.lazy( +const LazyBlobProvider = lazy( () => new Promise(resolve => setTimeout(() => resolve({ default: BlobProvider }), 300) diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/FieldsPDF.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/FieldsPDF.tsx index 0f794a889..1bd8c0c04 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/FieldsPDF.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/FieldsPDF.tsx @@ -1,6 +1,5 @@ import { StyleSheet, Text, View } from '@react-pdf/renderer' import { formatValue } from 'publicodes' -import React from 'react' export default function FieldsPDF({ fields }) { return fields.map(field => ( diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/PDFDocument.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/PDFDocument.tsx index 0c0f2c7d7..2f16a1cde 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/PDFDocument.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/PDFDocument.tsx @@ -9,7 +9,6 @@ import { Link } from '@react-pdf/renderer' import urssafPng from 'Images/destinataires/URSSAF.png' -import React from 'react' import FieldsPDF, { styles as fieldStyles } from './FieldsPDF' import montserratUrl from './Montserrat-SemiBold.ttf' import robotoUrl from './Roboto-Regular.ttf' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/index.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/index.tsx index 590ce5c0f..63c9be7b9 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/index.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/DemandeMobilite/index.tsx @@ -5,12 +5,12 @@ import Emoji from 'Components/utils/Emoji' import { Markdown } from 'Components/utils/markdown' import { usePersistingState } from 'Components/utils/persistState' import Engine from 'publicodes' -import React, { Suspense, useCallback, useState } from 'react' +import { lazy, createElement, Suspense, useCallback, useState } from 'react' import emoji from 'react-easy-emoji' import { hash } from '../../../../../utils' import formulaire from './formulaire-détachement.yaml' -const LazyEndBlock = React.lazy(() => import('./EndBlock')) +const LazyEndBlock = lazy(() => import('./EndBlock')) export default function FormulaireMobilitéIndépendant() { const engine = new Engine(formulaire) @@ -128,7 +128,7 @@ function FormulairePublicodes({ engine }) { {field.type === 'groupe' ? ( <> - {React.createElement( + {createElement( `h${Math.min(field.dottedName.split(' . ').length + 1, 6)}`, {}, field.title diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Embaucher.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Embaucher.tsx index 3612df6d5..54f4e9bb0 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Embaucher.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Embaucher.tsx @@ -2,7 +2,6 @@ import { checkHiringItem, initializeHiringChecklist } from 'Actions/hiringChecklistAction' -import React from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' import { connect, useSelector } from 'react-redux' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Home.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Home.tsx index 6d10e278a..ba338ccf8 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Home.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Home.tsx @@ -8,7 +8,7 @@ import FindCompany from 'Components/FindCompany' import Overlay from 'Components/Overlay' import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext, useEffect, useRef, useState } from 'react' +import { useContext, useEffect, useRef, useState } from 'react' import emoji from 'react-easy-emoji' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/SchemeSelection.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/SchemeSelection.tsx index b5c4ad233..f9db9bf46 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/SchemeSelection.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/SchemeSelection.tsx @@ -1,5 +1,5 @@ import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/SécuritéSociale.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/SécuritéSociale.tsx index 5cce71bf9..cc69901bc 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/SécuritéSociale.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/SécuritéSociale.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' import * as Animate from 'Components/ui/animate' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Video.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Video.tsx index 6b6d2c3ca..cb60d602e 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Video.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/Video.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { useTranslation } from 'react-i18next' export default function Video() { diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/index.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/index.tsx index 25a89902e..23624d628 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/index.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Gérer/index.tsx @@ -1,6 +1,6 @@ import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Trans } from 'react-i18next' import { Route, Switch } from 'react-router-dom' import { NavLink, useLocation } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Iframes/IframeFooter.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Iframes/IframeFooter.tsx index 4793f216e..01bc44c46 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Iframes/IframeFooter.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Iframes/IframeFooter.tsx @@ -1,4 +1,3 @@ -import React from 'react' import Privacy from '../../layout/Footer/Privacy' export default function IframeFooter() { diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Iframes/index.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Iframes/index.tsx index a9e489797..4ffc9cd69 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Iframes/index.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Iframes/index.tsx @@ -1,5 +1,4 @@ import { IsEmbeddedContext } from 'Components/utils/embeddedContext' -import React from 'react' import { Route, Switch } from 'react-router-dom' import { inIframe } from '../../../../utils' import useSimulatorsData from '../Simulateurs/metadata' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Landing/Landing.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Landing/Landing.tsx index 9162c43fc..7e7d06413 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Landing/Landing.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Landing/Landing.tsx @@ -1,6 +1,6 @@ import { SitePathsContext } from 'Components/utils/SitePathsContext' import logoSvg from 'Images/logo.svg' -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { Trans } from 'react-i18next' import { useSelector } from 'react-redux' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Nouveautés/Nouveautés.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Nouveautés/Nouveautés.tsx index 126dfb28e..d1908c38a 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Nouveautés/Nouveautés.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Nouveautés/Nouveautés.tsx @@ -2,7 +2,7 @@ import MoreInfosOnUs from 'Components/MoreInfosOnUs' import { MarkdownWithAnchorLinks } from 'Components/utils/markdown' import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext, useEffect } from 'react' +import { useContext, useEffect } from 'react' import emoji from 'react-easy-emoji' import { Redirect, useHistory, useRouteMatch } from 'react-router-dom' import { Link, NavLink } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ArtisteAuteur.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ArtisteAuteur.tsx index d7dbcd4f4..4ccd97387 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ArtisteAuteur.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ArtisteAuteur.tsx @@ -6,7 +6,7 @@ import SimulateurWarning from 'Components/SimulateurWarning' import 'Components/TargetSelection.css' import Animate from 'Components/ui/animate' import { EngineContext, useEvaluation } from 'Components/utils/EngineContext' -import React, { createContext, useContext, useEffect, useState } from 'react' +import { createContext, useContext, useEffect, useState } from 'react' import { Trans } from 'react-i18next' import { useDispatch, useSelector } from 'react-redux' import { DottedName } from 'Rules' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/Home.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/Home.tsx index 0e1c624fa..55e76ad34 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/Home.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/Home.tsx @@ -1,4 +1,4 @@ -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/IndépendantSimulation.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/IndépendantSimulation.tsx index 91d8916f7..a45d59f88 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/IndépendantSimulation.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/IndépendantSimulation.tsx @@ -1,7 +1,6 @@ import SimulateurWarning from 'Components/SimulateurWarning' import Simulation from 'Components/Simulation' import IndépendantExplanation from 'Components/simulationExplanation/IndépendantExplanation' -import React from 'react' export default function IndépendantSimulation() { return ( <> diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/SchemeComparaison.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/SchemeComparaison.tsx index 212d20fa1..b7e2a9909 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/SchemeComparaison.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/SchemeComparaison.tsx @@ -1,5 +1,4 @@ import SchemeComparaison from 'Components/SchemeComparaison' -import React from 'react' import { Trans, useTranslation } from 'react-i18next' export default function SchemeComparaisonPage() { diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/Activité.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/Activité.tsx index d45deae69..739883f6b 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/Activité.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/Activité.tsx @@ -2,7 +2,7 @@ import { Markdown } from 'Components/utils/markdown' import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' import Value from 'Components/EngineValue' -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { Trans, useTranslation } from 'react-i18next' import { Redirect } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/ExceptionsExonération.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/ExceptionsExonération.tsx index c0e9935eb..0b0dd96f2 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/ExceptionsExonération.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/ExceptionsExonération.tsx @@ -1,4 +1,4 @@ -import React, { useContext } from 'react' +import { useContext } from 'react' import { Trans } from 'react-i18next' import { CheckItem, Checklist } from 'Components/ui/Checklist' import { changeCritèreExonération } from './actions' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/NextButton.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/NextButton.tsx index 8ce395923..40435917e 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/NextButton.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/NextButton.tsx @@ -1,6 +1,6 @@ import classnames from 'classnames' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Trans } from 'react-i18next' import { Link } from 'react-router-dom' import { activitéVue } from './actions' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/StoreContext.js b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/StoreContext.js index 6f0b65fd5..732529336 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/StoreContext.js +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/StoreContext.js @@ -1,5 +1,5 @@ import { getInitialState, persistState } from 'Components/utils/persistState' -import React, { createContext, useCallback, useReducer } from 'react' +import { createContext, useCallback, useReducer } from 'react' const StoreContext = createContext() diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/VotreSituation.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/VotreSituation.tsx index b43f3a7a3..294af90a6 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/VotreSituation.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/VotreSituation.tsx @@ -1,6 +1,6 @@ import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Helmet } from 'react-helmet' import { Trans, useTranslation } from 'react-i18next' import { Link, Redirect } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/index.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/index.tsx index a2ec71715..03d176950 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/index.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Simulateurs/ÉconomieCollaborative/index.tsx @@ -1,5 +1,5 @@ import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Trans } from 'react-i18next' import { Route, Switch } from 'react-router-dom' import { NavLink } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Stats/LazyStats.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Stats/LazyStats.tsx index 153f79dfc..b93a7f90e 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/Stats/LazyStats.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/Stats/LazyStats.tsx @@ -1,5 +1,5 @@ -import React, { Suspense } from 'react' -const Stats = React.lazy(() => import('./Stats')) +import { lazy, Suspense } from 'react' +const Stats = lazy(() => import('./Stats')) export default function LazyStats() { return ( diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/Library.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/Library.tsx index 598f96fa5..69ecb1512 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/Library.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/Library.tsx @@ -1,5 +1,4 @@ import { ScrollToTop } from 'Components/utils/Scroll' -import React from 'react' import emoji from 'react-easy-emoji' import { Trans } from 'react-i18next' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/Options.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/Options.tsx index 686aca2ef..2214dd0f5 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/Options.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/Options.tsx @@ -1,5 +1,5 @@ import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import emoji from 'react-easy-emoji' import { Trans } from 'react-i18next' import { Link } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/index.tsx b/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/index.tsx index 29adff825..dc993bdbd 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/index.tsx +++ b/mon-entreprise/source/sites/mon-entreprise.fr/pages/integration/index.tsx @@ -1,6 +1,6 @@ import { ScrollToTop } from 'Components/utils/Scroll' import { SitePathsContext } from 'Components/utils/SitePathsContext' -import React, { useContext } from 'react' +import { useContext } from 'react' import { Trans } from 'react-i18next' import { Route, Switch, useLocation } from 'react-router-dom' import { Link } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/mon-entreprise.fr/redirects.js b/mon-entreprise/source/sites/mon-entreprise.fr/redirects.js index 3f9a12a07..267dfc282 100644 --- a/mon-entreprise/source/sites/mon-entreprise.fr/redirects.js +++ b/mon-entreprise/source/sites/mon-entreprise.fr/redirects.js @@ -1,4 +1,3 @@ -import React from 'react' import { Redirect } from 'react-router-dom' import netlifyToml from '../../../../netlify.toml' diff --git a/mon-entreprise/source/sites/publi.codes/Api.tsx b/mon-entreprise/source/sites/publi.codes/Api.tsx index ad4f7a11b..05a348f6b 100644 --- a/mon-entreprise/source/sites/publi.codes/Api.tsx +++ b/mon-entreprise/source/sites/publi.codes/Api.tsx @@ -1,4 +1,3 @@ -import React from 'react' import { ScrollToTop } from 'Components/utils/Scroll' import { Header } from './Header' import api from '../../../../publicodes/docs/api.md' diff --git a/mon-entreprise/source/sites/publi.codes/App.tsx b/mon-entreprise/source/sites/publi.codes/App.tsx index bc37752b2..47f324745 100644 --- a/mon-entreprise/source/sites/publi.codes/App.tsx +++ b/mon-entreprise/source/sites/publi.codes/App.tsx @@ -1,7 +1,6 @@ // TODO : load translation only if en import 'Components/ui/index.css' import 'iframe-resizer' -import React from 'react' import { hot } from 'react-hot-loader' import { Route, Switch } from 'react-router-dom' import Provider from '../../Provider' diff --git a/mon-entreprise/source/sites/publi.codes/Landing.tsx b/mon-entreprise/source/sites/publi.codes/Landing.tsx index 777f3c6fc..1a0e4a58d 100644 --- a/mon-entreprise/source/sites/publi.codes/Landing.tsx +++ b/mon-entreprise/source/sites/publi.codes/Landing.tsx @@ -1,7 +1,7 @@ import { MarkdownWithAnchorLinks } from 'Components/utils/markdown' import { ScrollToTop } from 'Components/utils/Scroll' import publicodeReadme from '../../../../publicodes/README.md' -import React, { useEffect } from 'react' +import { useEffect } from 'react' import { Header } from './Header' import { NavLink } from 'react-router-dom' diff --git a/mon-entreprise/source/sites/publi.codes/LazyStudio.tsx b/mon-entreprise/source/sites/publi.codes/LazyStudio.tsx index 2902078c7..c351e08d9 100644 --- a/mon-entreprise/source/sites/publi.codes/LazyStudio.tsx +++ b/mon-entreprise/source/sites/publi.codes/LazyStudio.tsx @@ -1,6 +1,6 @@ -import React, { Suspense } from 'react' +import { lazy, Suspense } from 'react' import { Header } from './Header' -const Studio = React.lazy(() => import('./Studio')) +const Studio = lazy(() => import('./Studio')) export default function LazyStudio() { return ( diff --git a/mon-entreprise/source/sites/publi.codes/Mécanismes.tsx b/mon-entreprise/source/sites/publi.codes/Mécanismes.tsx index 9d6349384..ce1bda816 100644 --- a/mon-entreprise/source/sites/publi.codes/Mécanismes.tsx +++ b/mon-entreprise/source/sites/publi.codes/Mécanismes.tsx @@ -1,6 +1,6 @@ import { Markdown } from 'Components/utils/markdown' import { ScrollToTop } from 'Components/utils/Scroll' -import React, { useEffect } from 'react' +import { Fragment, useEffect } from 'react' import { useLocation } from 'react-router-dom' import { HashLink as Link } from 'react-router-hash-link' import mecanisms from '../../../../publicodes/docs/mecanisms.yaml' @@ -35,10 +35,10 @@ export default function Landing() { ))} {Object.entries(mecanisms).map(([name, data]) => ( - + Retour à la liste - + ))}
) @@ -61,10 +61,10 @@ function Explanation({ name, description, exemples }: ExplanationProp) { {exemples && ( <> {Object.entries(exemples).map(([name, exemple]) => ( - +

{name === 'base' ? 'Exemple' : capitalise0(name)}

-
+ ))}{' '} )} diff --git a/mon-entreprise/source/sites/publi.codes/entry.tsx b/mon-entreprise/source/sites/publi.codes/entry.tsx index 063b0bad1..71d6a3a32 100644 --- a/mon-entreprise/source/sites/publi.codes/entry.tsx +++ b/mon-entreprise/source/sites/publi.codes/entry.tsx @@ -1,5 +1,4 @@ import 'core-js/stable' -import React from 'react' import { render } from 'react-dom' import 'regenerator-runtime/runtime' import App from './App' diff --git a/yarn.lock b/yarn.lock index 1fe7d0a3e..5539089d5 100644 --- a/yarn.lock +++ b/yarn.lock @@ -18,7 +18,7 @@ invariant "^2.2.4" semver "^5.5.0" -"@babel/core@^7.1.0", "@babel/core@^7.9.0": +"@babel/core@^7.1.0": version "7.11.4" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.11.4.tgz#4301dfdfafa01eeb97f1896c5501a3f0655d4229" integrity sha512-5deljj5HlqRXN+5oJTY7Zs37iH3z3b++KjiKtIsJy1NrjOOVSEaJHEetLBhyu0aQOSNNZ/0IuEAan9GzRuDXHg== @@ -40,7 +40,38 @@ semver "^5.4.1" source-map "^0.5.0" -"@babel/generator@^7.11.0", "@babel/generator@^7.11.4", "@babel/generator@^7.4.0": +"@babel/core@^7.9.0": + version "7.12.3" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.12.3.tgz#1b436884e1e3bff6fb1328dc02b208759de92ad8" + integrity sha512-0qXcZYKZp3/6N2jKYVxZv0aNCsxTSVCiK72DTiTYZAu7sjg73W0/aynWjMbiGd87EQL4WyA8reiJVh92AVla9g== + dependencies: + "@babel/code-frame" "^7.10.4" + "@babel/generator" "^7.12.1" + "@babel/helper-module-transforms" "^7.12.1" + "@babel/helpers" "^7.12.1" + "@babel/parser" "^7.12.3" + "@babel/template" "^7.10.4" + "@babel/traverse" "^7.12.1" + "@babel/types" "^7.12.1" + convert-source-map "^1.7.0" + debug "^4.1.0" + gensync "^1.0.0-beta.1" + json5 "^2.1.2" + lodash "^4.17.19" + resolve "^1.3.2" + semver "^5.4.1" + source-map "^0.5.0" + +"@babel/generator@^7.11.0", "@babel/generator@^7.11.4", "@babel/generator@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.12.1.tgz#0d70be32bdaa03d7c51c8597dda76e0df1f15468" + integrity sha512-DB+6rafIdc9o72Yc3/Ph5h+6hUjeOp66pF0naQBgUFFuPqzQwIlPTm3xZR7YNvduIMtkDIj2t21LSQwnbCrXvg== + dependencies: + "@babel/types" "^7.12.1" + jsesc "^2.5.1" + source-map "^0.5.0" + +"@babel/generator@^7.4.0": version "7.11.4" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.11.4.tgz#1ec7eec00defba5d6f83e50e3ee72ae2fee482be" integrity sha512-Rn26vueFx0eOoz7iifCN2UHT6rGtnkSGWSoDRIy8jZN3B91PzeSULbswfLoOWuTuAcNwpG/mxy+uCTDnZ9Mp1g== @@ -64,14 +95,14 @@ "@babel/helper-explode-assignable-expression" "^7.10.4" "@babel/types" "^7.10.4" -"@babel/helper-builder-react-jsx-experimental@^7.10.4": - version "7.10.5" - resolved "https://registry.yarnpkg.com/@babel/helper-builder-react-jsx-experimental/-/helper-builder-react-jsx-experimental-7.10.5.tgz#f35e956a19955ff08c1258e44a515a6d6248646b" - integrity sha512-Buewnx6M4ttG+NLkKyt7baQn7ScC/Td+e99G914fRU8fGIUivDDgVIQeDHFa5e4CRSJQt58WpNHhsAZgtzVhsg== +"@babel/helper-builder-react-jsx-experimental@^7.12.1": + version "7.12.4" + resolved "https://registry.yarnpkg.com/@babel/helper-builder-react-jsx-experimental/-/helper-builder-react-jsx-experimental-7.12.4.tgz#55fc1ead5242caa0ca2875dcb8eed6d311e50f48" + integrity sha512-AjEa0jrQqNk7eDQOo0pTfUOwQBMF+xVqrausQwT9/rTKy0g04ggFNaJpaE09IQMn9yExluigWMJcj0WC7bq+Og== dependencies: "@babel/helper-annotate-as-pure" "^7.10.4" - "@babel/helper-module-imports" "^7.10.4" - "@babel/types" "^7.10.5" + "@babel/helper-module-imports" "^7.12.1" + "@babel/types" "^7.12.1" "@babel/helper-builder-react-jsx@^7.10.4": version "7.10.4" @@ -152,21 +183,35 @@ dependencies: "@babel/types" "^7.10.4" -"@babel/helper-member-expression-to-functions@^7.10.4", "@babel/helper-member-expression-to-functions@^7.10.5": +"@babel/helper-member-expression-to-functions@^7.10.5": version "7.11.0" resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.11.0.tgz#ae69c83d84ee82f4b42f96e2a09410935a8f26df" integrity sha512-JbFlKHFntRV5qKw3YC0CvQnDZ4XMwgzzBbld7Ly4Mj4cbFy3KywcR8NtNctRToMWJOVvLINJv525Gd6wwVEx/Q== dependencies: "@babel/types" "^7.11.0" -"@babel/helper-module-imports@^7.0.0", "@babel/helper-module-imports@^7.10.4": +"@babel/helper-member-expression-to-functions@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.12.1.tgz#fba0f2fcff3fba00e6ecb664bb5e6e26e2d6165c" + integrity sha512-k0CIe3tXUKTRSoEx1LQEPFU9vRQfqHtl+kf8eNnDqb4AUJEy5pz6aIiog+YWtVm2jpggjS1laH68bPsR+KWWPQ== + dependencies: + "@babel/types" "^7.12.1" + +"@babel/helper-module-imports@^7.0.0": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.10.4.tgz#4c5c54be04bd31670a7382797d75b9fa2e5b5620" integrity sha512-nEQJHqYavI217oD9+s5MUBzk6x1IlvoS9WTPfgG43CbMEeStE0v+r+TucWdx8KFGowPGvyOkDT9+7DHedIDnVw== dependencies: "@babel/types" "^7.10.4" -"@babel/helper-module-transforms@^7.10.4", "@babel/helper-module-transforms@^7.10.5", "@babel/helper-module-transforms@^7.11.0": +"@babel/helper-module-imports@^7.10.4", "@babel/helper-module-imports@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.12.1.tgz#1644c01591a15a2f084dd6d092d9430eb1d1216c" + integrity sha512-ZeC1TlMSvikvJNy1v/wPIazCu3NdOwgYZLIkmIyAsGhqkNpiDoQQRmaCK8YP4Pq3GPTLPV9WXaPCJKvx06JxKA== + dependencies: + "@babel/types" "^7.12.1" + +"@babel/helper-module-transforms@^7.10.4", "@babel/helper-module-transforms@^7.10.5": version "7.11.0" resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.11.0.tgz#b16f250229e47211abdd84b34b64737c2ab2d359" integrity sha512-02EVu8COMuTRO1TAzdMtpBPbe6aQ1w/8fePD2YgQmxZU4gpNWaL9gK3Jp7dxlkUlUCJOTaSeA+Hrm1BRQwqIhg== @@ -179,6 +224,21 @@ "@babel/types" "^7.11.0" lodash "^4.17.19" +"@babel/helper-module-transforms@^7.11.0", "@babel/helper-module-transforms@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.12.1.tgz#7954fec71f5b32c48e4b303b437c34453fd7247c" + integrity sha512-QQzehgFAZ2bbISiCpmVGfiGux8YVFXQ0abBic2Envhej22DVXV9nCFaS5hIQbkyo1AdGb+gNME2TSh3hYJVV/w== + dependencies: + "@babel/helper-module-imports" "^7.12.1" + "@babel/helper-replace-supers" "^7.12.1" + "@babel/helper-simple-access" "^7.12.1" + "@babel/helper-split-export-declaration" "^7.11.0" + "@babel/helper-validator-identifier" "^7.10.4" + "@babel/template" "^7.10.4" + "@babel/traverse" "^7.12.1" + "@babel/types" "^7.12.1" + lodash "^4.17.19" + "@babel/helper-optimise-call-expression@^7.10.4": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.10.4.tgz#50dc96413d594f995a77905905b05893cd779673" @@ -208,23 +268,22 @@ "@babel/template" "^7.10.4" "@babel/types" "^7.10.4" -"@babel/helper-replace-supers@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.10.4.tgz#d585cd9388ea06e6031e4cd44b6713cbead9e6cf" - integrity sha512-sPxZfFXocEymYTdVK1UNmFPBN+Hv5mJkLPsYWwGBxZAxaWfFu+xqp7b6qWD0yjNuNL2VKc6L5M18tOXUP7NU0A== +"@babel/helper-replace-supers@^7.10.4", "@babel/helper-replace-supers@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.12.1.tgz#f15c9cc897439281891e11d5ce12562ac0cf3fa9" + integrity sha512-zJjTvtNJnCFsCXVi5rUInstLd/EIVNmIKA1Q9ynESmMBWPWd+7sdR+G4/wdu+Mppfep0XLyG2m7EBPvjCeFyrw== dependencies: - "@babel/helper-member-expression-to-functions" "^7.10.4" + "@babel/helper-member-expression-to-functions" "^7.12.1" "@babel/helper-optimise-call-expression" "^7.10.4" - "@babel/traverse" "^7.10.4" - "@babel/types" "^7.10.4" + "@babel/traverse" "^7.12.1" + "@babel/types" "^7.12.1" -"@babel/helper-simple-access@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.10.4.tgz#0f5ccda2945277a2a7a2d3a821e15395edcf3461" - integrity sha512-0fMy72ej/VEvF8ULmX6yb5MtHG4uH4Dbd6I/aHDb/JVg0bbivwt9Wg+h3uMvX+QSFtwr5MeItvazbrc4jtRAXw== +"@babel/helper-simple-access@^7.10.4", "@babel/helper-simple-access@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.12.1.tgz#32427e5aa61547d38eb1e6eaf5fd1426fdad9136" + integrity sha512-OxBp7pMrjVewSSC8fXDFrHrBcJATOOFssZwv16F3/6Xtc138GHybBfPbm9kfiqQHKhYQrlamWILwlDCeyMFEaA== dependencies: - "@babel/template" "^7.10.4" - "@babel/types" "^7.10.4" + "@babel/types" "^7.12.1" "@babel/helper-skip-transparent-expression-wrappers@^7.11.0": version "7.11.0" @@ -255,14 +314,14 @@ "@babel/traverse" "^7.10.4" "@babel/types" "^7.10.4" -"@babel/helpers@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.10.4.tgz#2abeb0d721aff7c0a97376b9e1f6f65d7a475044" - integrity sha512-L2gX/XeUONeEbI78dXSrJzGdz4GQ+ZTA/aazfUsFaWjSe95kiCuOZ5HsXvkiw3iwF+mFHSRUfJU8t6YavocdXA== +"@babel/helpers@^7.10.4", "@babel/helpers@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.12.1.tgz#8a8261c1d438ec18cb890434df4ec768734c1e79" + integrity sha512-9JoDSBGoWtmbay98efmT2+mySkwjzeFeAL9BuWNoVQpkPFQF8SIIFUfY5os9u8wVzglzoiPRSW7cuJmBDUt43g== dependencies: "@babel/template" "^7.10.4" - "@babel/traverse" "^7.10.4" - "@babel/types" "^7.10.4" + "@babel/traverse" "^7.12.1" + "@babel/types" "^7.12.1" "@babel/highlight@^7.10.4": version "7.10.4" @@ -273,11 +332,16 @@ chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/parser@^7.1.0", "@babel/parser@^7.10.4", "@babel/parser@^7.11.0", "@babel/parser@^7.11.4", "@babel/parser@^7.4.3": +"@babel/parser@^7.1.0", "@babel/parser@^7.4.3": version "7.11.4" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.11.4.tgz#6fa1a118b8b0d80d0267b719213dc947e88cc0ca" integrity sha512-MggwidiH+E9j5Sh8pbrX5sJvMcsqS5o+7iB42M9/k0CD63MjYbdP4nhSh7uB5wnv2/RVzTZFTxzF/kIa5mrCqA== +"@babel/parser@^7.10.4", "@babel/parser@^7.11.0", "@babel/parser@^7.11.4", "@babel/parser@^7.12.1", "@babel/parser@^7.12.3": + version "7.12.3" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.12.3.tgz#a305415ebe7a6c7023b40b5122a0662d928334cd" + integrity sha512-kFsOS0IbsuhO5ojF8Hc8z/8vEIOkylVBrjiZUbLTE3XFe0Qi+uu6HjzQixkFaqr0ZPAMZcBVxEwmsnsLPZ2Xsw== + "@babel/plugin-proposal-async-generator-functions@^7.10.4": version "7.10.5" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.10.5.tgz#3491cabf2f7c179ab820606cec27fed15e0e8558" @@ -420,10 +484,10 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-jsx@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.10.4.tgz#39abaae3cbf710c4373d8429484e6ba21340166c" - integrity sha512-KCg9mio9jwiARCB7WAcQ7Y1q+qicILjoK8LP/VkPkEKaf5dkaZZK1EcTe91a3JJlZ3qy6L5s9X52boEYi8DM9g== +"@babel/plugin-syntax-jsx@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.12.1.tgz#9d9d357cc818aa7ae7935917c1257f67677a0926" + integrity sha512-1yRi7yAtB0ETgxdY9ti/p2TivUxJkTdhu/ZbF9MshVGqOx1TdB3b7xCXs49Fupgg50N45KcAsRP/ZqWjs9SRjg== dependencies: "@babel/helper-plugin-utils" "^7.10.4" @@ -667,52 +731,50 @@ dependencies: "@babel/helper-plugin-utils" "^7.10.4" -"@babel/plugin-transform-react-display-name@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-display-name/-/plugin-transform-react-display-name-7.10.4.tgz#b5795f4e3e3140419c3611b7a2a3832b9aef328d" - integrity sha512-Zd4X54Mu9SBfPGnEcaGcOrVAYOtjT2on8QZkLKEq1S/tHexG39d9XXGZv19VfRrDjPJzFmPfTAqOQS1pfFOujw== +"@babel/plugin-transform-react-display-name@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-display-name/-/plugin-transform-react-display-name-7.12.1.tgz#1cbcd0c3b1d6648c55374a22fc9b6b7e5341c00d" + integrity sha512-cAzB+UzBIrekfYxyLlFqf/OagTvHLcVBb5vpouzkYkBclRPraiygVnafvAoipErZLI8ANv8Ecn6E/m5qPXD26w== dependencies: "@babel/helper-plugin-utils" "^7.10.4" -"@babel/plugin-transform-react-jsx-development@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-development/-/plugin-transform-react-jsx-development-7.10.4.tgz#6ec90f244394604623880e15ebc3c34c356258ba" - integrity sha512-RM3ZAd1sU1iQ7rI2dhrZRZGv0aqzNQMbkIUCS1txYpi9wHQ2ZHNjo5TwX+UD6pvFW4AbWqLVYvKy5qJSAyRGjQ== +"@babel/plugin-transform-react-jsx-development@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-development/-/plugin-transform-react-jsx-development-7.12.1.tgz#0b8f8cd531dcf7991f1e5f2c10a2a4f1cfc78e36" + integrity sha512-IilcGWdN1yNgEGOrB96jbTplRh+V2Pz1EoEwsKsHfX1a/L40cUYuD71Zepa7C+ujv7kJIxnDftWeZbKNEqZjCQ== dependencies: - "@babel/helper-builder-react-jsx-experimental" "^7.10.4" + "@babel/helper-builder-react-jsx-experimental" "^7.12.1" "@babel/helper-plugin-utils" "^7.10.4" - "@babel/plugin-syntax-jsx" "^7.10.4" + "@babel/plugin-syntax-jsx" "^7.12.1" -"@babel/plugin-transform-react-jsx-self@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.10.4.tgz#cd301a5fed8988c182ed0b9d55e9bd6db0bd9369" - integrity sha512-yOvxY2pDiVJi0axdTWHSMi5T0DILN+H+SaeJeACHKjQLezEzhLx9nEF9xgpBLPtkZsks9cnb5P9iBEi21En3gg== +"@babel/plugin-transform-react-jsx-self@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.12.1.tgz#ef43cbca2a14f1bd17807dbe4376ff89d714cf28" + integrity sha512-FbpL0ieNWiiBB5tCldX17EtXgmzeEZjFrix72rQYeq9X6nUK38HCaxexzVQrZWXanxKJPKVVIU37gFjEQYkPkA== dependencies: "@babel/helper-plugin-utils" "^7.10.4" - "@babel/plugin-syntax-jsx" "^7.10.4" -"@babel/plugin-transform-react-jsx-source@^7.10.4": - version "7.10.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.10.5.tgz#34f1779117520a779c054f2cdd9680435b9222b4" - integrity sha512-wTeqHVkN1lfPLubRiZH3o73f4rfon42HpgxUSs86Nc+8QIcm/B9s8NNVXu/gwGcOyd7yDib9ikxoDLxJP0UiDA== +"@babel/plugin-transform-react-jsx-source@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.12.1.tgz#d07de6863f468da0809edcf79a1aa8ce2a82a26b" + integrity sha512-keQ5kBfjJNRc6zZN1/nVHCd6LLIHq4aUKcVnvE/2l+ZZROSbqoiGFRtT5t3Is89XJxBQaP7NLZX2jgGHdZvvFQ== dependencies: "@babel/helper-plugin-utils" "^7.10.4" - "@babel/plugin-syntax-jsx" "^7.10.4" -"@babel/plugin-transform-react-jsx@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.10.4.tgz#673c9f913948764a4421683b2bef2936968fddf2" - integrity sha512-L+MfRhWjX0eI7Js093MM6MacKU4M6dnCRa/QPDwYMxjljzSCzzlzKzj9Pk4P3OtrPcxr2N3znR419nr3Xw+65A== +"@babel/plugin-transform-react-jsx@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.12.1.tgz#c2d96c77c2b0e4362cc4e77a43ce7c2539d478cb" + integrity sha512-RmKejwnT0T0QzQUzcbP5p1VWlpnP8QHtdhEtLG55ZDQnJNalbF3eeDyu3dnGKvGzFIQiBzFhBYTwvv435p9Xpw== dependencies: "@babel/helper-builder-react-jsx" "^7.10.4" - "@babel/helper-builder-react-jsx-experimental" "^7.10.4" + "@babel/helper-builder-react-jsx-experimental" "^7.12.1" "@babel/helper-plugin-utils" "^7.10.4" - "@babel/plugin-syntax-jsx" "^7.10.4" + "@babel/plugin-syntax-jsx" "^7.12.1" -"@babel/plugin-transform-react-pure-annotations@^7.10.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-pure-annotations/-/plugin-transform-react-pure-annotations-7.10.4.tgz#3eefbb73db94afbc075f097523e445354a1c6501" - integrity sha512-+njZkqcOuS8RaPakrnR9KvxjoG1ASJWpoIv/doyWngId88JoFlPlISenGXjrVacZUIALGUr6eodRs1vmPnF23A== +"@babel/plugin-transform-react-pure-annotations@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-pure-annotations/-/plugin-transform-react-pure-annotations-7.12.1.tgz#05d46f0ab4d1339ac59adf20a1462c91b37a1a42" + integrity sha512-RqeaHiwZtphSIUZ5I85PEH19LOSzxfuEazoY7/pWASCAIBuATQzpSVD+eT6MebeeZT2F4eSL0u4vw6n4Nm0Mjg== dependencies: "@babel/helper-annotate-as-pure" "^7.10.4" "@babel/helper-plugin-utils" "^7.10.4" @@ -879,17 +941,17 @@ esutils "^2.0.2" "@babel/preset-react@^7.9.4": - version "7.10.4" - resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.10.4.tgz#92e8a66d816f9911d11d4cc935be67adfc82dbcf" - integrity sha512-BrHp4TgOIy4M19JAfO1LhycVXOPWdDbTRep7eVyatf174Hff+6Uk53sDyajqZPu8W1qXRBiYOfIamek6jA7YVw== + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.12.1.tgz#7f022b13f55b6dd82f00f16d1c599ae62985358c" + integrity sha512-euCExymHCi0qB9u5fKw7rvlw7AZSjw/NaB9h7EkdTt5+yHRrXdiRTh7fkG3uBPpJg82CqLfp1LHLqWGSCrab+g== dependencies: "@babel/helper-plugin-utils" "^7.10.4" - "@babel/plugin-transform-react-display-name" "^7.10.4" - "@babel/plugin-transform-react-jsx" "^7.10.4" - "@babel/plugin-transform-react-jsx-development" "^7.10.4" - "@babel/plugin-transform-react-jsx-self" "^7.10.4" - "@babel/plugin-transform-react-jsx-source" "^7.10.4" - "@babel/plugin-transform-react-pure-annotations" "^7.10.4" + "@babel/plugin-transform-react-display-name" "^7.12.1" + "@babel/plugin-transform-react-jsx" "^7.12.1" + "@babel/plugin-transform-react-jsx-development" "^7.12.1" + "@babel/plugin-transform-react-jsx-self" "^7.12.1" + "@babel/plugin-transform-react-jsx-source" "^7.12.1" + "@babel/plugin-transform-react-pure-annotations" "^7.12.1" "@babel/preset-typescript@^7.9.0": version "7.10.4" @@ -915,7 +977,7 @@ "@babel/parser" "^7.10.4" "@babel/types" "^7.10.4" -"@babel/traverse@^7.1.0", "@babel/traverse@^7.10.4", "@babel/traverse@^7.11.0", "@babel/traverse@^7.4.3", "@babel/traverse@^7.4.5": +"@babel/traverse@^7.1.0", "@babel/traverse@^7.4.3", "@babel/traverse@^7.4.5": version "7.11.0" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.11.0.tgz#9b996ce1b98f53f7c3e4175115605d56ed07dd24" integrity sha512-ZB2V+LskoWKNpMq6E5UUCrjtDUh5IOTAyIl0dTjIEoXum/iKWkoIEKIRDnUucO6f+2FzNkE0oD4RLKoPIufDtg== @@ -930,7 +992,22 @@ globals "^11.1.0" lodash "^4.17.19" -"@babel/types@^7.0.0", "@babel/types@^7.10.4", "@babel/types@^7.10.5", "@babel/types@^7.11.0", "@babel/types@^7.3.0", "@babel/types@^7.4.0", "@babel/types@^7.4.4": +"@babel/traverse@^7.10.4", "@babel/traverse@^7.11.0", "@babel/traverse@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.12.1.tgz#941395e0c5cc86d5d3e75caa095d3924526f0c1e" + integrity sha512-MA3WPoRt1ZHo2ZmoGKNqi20YnPt0B1S0GTZEPhhd+hw2KGUzBlHuVunj6K4sNuK+reEvyiPwtp0cpaqLzJDmAw== + dependencies: + "@babel/code-frame" "^7.10.4" + "@babel/generator" "^7.12.1" + "@babel/helper-function-name" "^7.10.4" + "@babel/helper-split-export-declaration" "^7.11.0" + "@babel/parser" "^7.12.1" + "@babel/types" "^7.12.1" + debug "^4.1.0" + globals "^11.1.0" + lodash "^4.17.19" + +"@babel/types@^7.0.0", "@babel/types@^7.3.0", "@babel/types@^7.4.0", "@babel/types@^7.4.4": version "7.11.0" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.11.0.tgz#2ae6bf1ba9ae8c3c43824e5861269871b206e90d" integrity sha512-O53yME4ZZI0jO1EVGtF1ePGl0LHirG4P1ibcD80XyzZcKhcMFeCXmh4Xb1ifGBIV233Qg12x4rBfQgA+tmOukA== @@ -939,6 +1016,15 @@ lodash "^4.17.19" to-fast-properties "^2.0.0" +"@babel/types@^7.10.4", "@babel/types@^7.10.5", "@babel/types@^7.11.0", "@babel/types@^7.12.1": + version "7.12.1" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.12.1.tgz#e109d9ab99a8de735be287ee3d6a9947a190c4ae" + integrity sha512-BzSY3NJBKM4kyatSOWh3D/JJ2O3CVzBybHWxtgxnggaxEuaSTTDqeiSb/xk9lrkw2Tbqyivw5ZU4rT+EfznQsA== + dependencies: + "@babel/helper-validator-identifier" "^7.10.4" + lodash "^4.17.19" + to-fast-properties "^2.0.0" + "@cnakazawa/watch@^1.0.3": version "1.0.4" resolved "https://registry.yarnpkg.com/@cnakazawa/watch/-/watch-1.0.4.tgz#f864ae85004d0fcab6f50be9141c4da368d1656a" @@ -4138,13 +4224,20 @@ debug@3.2.6, debug@^3.1.0, debug@^3.1.1: dependencies: ms "^2.1.1" -debug@^4.0.1, debug@^4.1.0, debug@^4.1.1: +debug@^4.0.1, debug@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== dependencies: ms "^2.1.1" +debug@^4.1.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.2.0.tgz#7f150f93920e94c58f5574c2fd01a3110effe7f1" + integrity sha512-IX2ncY78vDTjZMFUdmsvIRFY2Cf4FnD0wRs+nQwJU8Lu99/tPFdb0VybiiMTPe3I6rQmwsqQqRBvxU+bZ/I8sg== + dependencies: + ms "2.1.2" + decamelize@^1.1.1, decamelize@^1.1.2, decamelize@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" @@ -6624,6 +6717,13 @@ is-ci@^2.0.0: dependencies: ci-info "^2.0.0" +is-core-module@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.0.0.tgz#58531b70aed1db7c0e8d4eb1a0a2d1ddd64bd12d" + integrity sha512-jq1AH6C8MuteOoBPwkxHafmByhL9j5q4OaPGdbuD+ZtQJVzH+i6E3BJDQcBA09k57i2Hh2yQbEG8yObZ0jdlWw== + dependencies: + has "^1.0.3" + is-data-descriptor@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" @@ -8425,7 +8525,7 @@ ms@2.1.1: resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.1.tgz#30a5864eb3ebb0a66f2ebe6d727af06a09d86e0a" integrity sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg== -ms@^2.1.1: +ms@2.1.2, ms@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== @@ -9966,15 +10066,14 @@ react-color@^2.14.0: reactcss "^1.2.0" tinycolor2 "^1.4.1" -"react-dom@npm:@hot-loader/react-dom": - version "16.13.0" - resolved "https://registry.yarnpkg.com/@hot-loader/react-dom/-/react-dom-16.13.0.tgz#de245b42358110baf80aaf47a0592153d4047997" - integrity sha512-lJZrmkucz2MrQJTQtJobx5MICXcfQvKihszqv655p557HPi0hMOWxrNpiHv3DWD8ugNWjtWcVWqRnFvwsHq1mQ== +react-dom@17.0.0: + version "17.0.0" + resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-17.0.0.tgz#f8266e4d9861584553ccbd186d596a1c7dd8dcb4" + integrity sha512-OGnFbxCjI2TMAZYMVxi4hqheJiN8rCEVVrL7XIGzCB6beNc4Am8M47HtkvxODZw9QgjmAPKpLba9FTu4fC1byA== dependencies: loose-envify "^1.1.0" object-assign "^4.1.1" - prop-types "^15.6.2" - scheduler "^0.19.0" + scheduler "^0.20.0" react-easy-emoji@^1.2.0, react-easy-emoji@^1.4.0: version "1.4.0" @@ -10202,6 +10301,14 @@ react-useportal@^1.0.13: dependencies: use-ssr "^1.0.19" +react@17.0.0: + version "17.0.0" + resolved "https://registry.yarnpkg.com/react/-/react-17.0.0.tgz#ad96d5fa1a33bb9b06d0cc52672f7992d84aa662" + integrity sha512-rG9bqS3LMuetoSUKHN8G3fMNuQOePKDThK6+2yXFWtoeTDLVNh/QCaxT+Jr+rNf4lwNXpx+atdn3Aa0oi8/6eQ== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + react@^16.13.1, react@^16.3.0: version "16.13.1" resolved "https://registry.yarnpkg.com/react/-/react-16.13.1.tgz#2e818822f1a9743122c063d6410d85c1e3afe48e" @@ -10699,13 +10806,21 @@ resolve@1.1.7: resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= -resolve@^1.10.0, resolve@^1.17.0, resolve@^1.3.2: +resolve@^1.10.0, resolve@^1.17.0: version "1.17.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.17.0.tgz#b25941b54968231cc2d1bb76a79cb7f2c0bf8444" integrity sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w== dependencies: path-parse "^1.0.6" +resolve@^1.3.2: + version "1.18.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.18.1.tgz#018fcb2c5b207d2a6424aee361c5a266da8f4130" + integrity sha512-lDfCPaMKfOJXjy0dPayzPdF1phampNWr3qFCjAu+rw/qbQmr5jWH5xN2hwh9QKfw9E5v4hwV7A+jrCmL8yjjqA== + dependencies: + is-core-module "^2.0.0" + path-parse "^1.0.6" + restore-cursor@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-1.0.1.tgz#34661f46886327fed2991479152252df92daa541" @@ -10879,7 +10994,7 @@ scheduler@^0.18.0: loose-envify "^1.1.0" object-assign "^4.1.1" -scheduler@^0.19.0, scheduler@^0.19.1: +scheduler@^0.19.1: version "0.19.1" resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.19.1.tgz#4f3e2ed2c1a7d65681f4c854fa8c5a1ccb40f196" integrity sha512-n/zwRWRYSUj0/3g/otKDRPMh6qv2SYMWNq85IEa8iZyAv8od9zDYpGSnpBEjNgcMNq6Scbu5KfIPxNF72R/2EA== @@ -10887,6 +11002,14 @@ scheduler@^0.19.0, scheduler@^0.19.1: loose-envify "^1.1.0" object-assign "^4.1.1" +scheduler@^0.20.0: + version "0.20.1" + resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.20.1.tgz#da0b907e24026b01181ecbc75efdc7f27b5a000c" + integrity sha512-LKTe+2xNJBNxu/QhHvDR14wUXHRQbVY5ZOYpOGWRzhydZUqrLb2JBvLPY7cAqFmqrWuDED0Mjk7013SZiOz6Bw== + dependencies: + loose-envify "^1.1.0" + object-assign "^4.1.1" + schema-utils@^0.4.0, schema-utils@^0.4.5: version "0.4.7" resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-0.4.7.tgz#ba74f597d2be2ea880131746ee17d0a093c68187"