From d26db43e38e35df97f27f9054454f7f1dac13086 Mon Sep 17 00:00:00 2001 From: Caroline <4971715+carolineBda@users.noreply.github.com> Date: Tue, 4 Feb 2025 14:53:10 +0100 Subject: [PATCH 1/4] =?UTF-8?q?fix(contributions):=20modification=20des=20?= =?UTF-8?q?events=20sur=20les=20contribs=20generiques=20pour=20=C3=AAtre?= =?UTF-8?q?=20ISO=20avec=20ce=20qu'on=20avait=20avant=20le=20passage=20au?= =?UTF-8?q?=20DSFR=20(#6443)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../convention-collective/convention/page.tsx | 2 - .../src/modules/common/BlueCard.tsx | 24 ++ .../src/modules/common/useLocalStorage.ts | 10 - .../ContributionAgreemeentSelect.tsx | 54 ---- .../contributions/ContributionAgreement.tsx | 60 ++++ .../contributions/ContributionGeneric.tsx | 105 ++++++ .../ContributionGenericAgreementSearch.tsx | 25 +- .../ContributionGenericContent.tsx | 30 +- .../contributions/ContributionLayout.tsx | 125 +------- .../contribution-generic.tracking.test.tsx | 303 ++++++++++++++++++ .../__tests__/contributions.test.tsx | 14 +- .../src/modules/contributions/__tests__/ui.ts | 16 + .../AgreementSearch/AgreementSearch.tsx | 6 +- .../AgreementSearch/AgreementSearchForm.tsx | 20 +- .../AgreementSearch/AgreementSearchInput.tsx | 9 +- .../AgreementSearch/index.ts | 1 - .../Agreements/AgreementsIntro.tsx | 19 +- .../__tests__/AgreementSearchForm.test.tsx | 30 +- .../modules/convention-collective/index.ts | 1 - .../modules/convention-collective/tracking.ts | 8 +- .../EnterpriseAgreementSearch.tsx | 2 + .../EnterpriseAgreementSearchInput.tsx | 22 +- .../EnterpriseAgreementSelectionForm.tsx | 7 +- .../EnterpriseAgreementSelectionLink.tsx | 51 ++- .../__tests__/AgreementSelection.test.tsx | 13 +- .../EnterpriseAgreementSearchInput.test.tsx | 6 +- .../EnterpriseAgreementSearch/tracking.ts | 24 +- 27 files changed, 674 insertions(+), 313 deletions(-) create mode 100644 packages/code-du-travail-frontend/src/modules/common/BlueCard.tsx delete mode 100644 packages/code-du-travail-frontend/src/modules/contributions/ContributionAgreemeentSelect.tsx create mode 100644 packages/code-du-travail-frontend/src/modules/contributions/ContributionAgreement.tsx create mode 100644 packages/code-du-travail-frontend/src/modules/contributions/ContributionGeneric.tsx create mode 100644 packages/code-du-travail-frontend/src/modules/contributions/__tests__/contribution-generic.tracking.test.tsx diff --git a/packages/code-du-travail-frontend/app/outils/convention-collective/convention/page.tsx b/packages/code-du-travail-frontend/app/outils/convention-collective/convention/page.tsx index 3968d5086f..652172cbb1 100644 --- a/packages/code-du-travail-frontend/app/outils/convention-collective/convention/page.tsx +++ b/packages/code-du-travail-frontend/app/outils/convention-collective/convention/page.tsx @@ -1,9 +1,7 @@ import { DsfrLayout } from "../../../../src/modules/layout"; -import { DocumentElasticResult } from "../../../../src/modules/documents"; import { fetchTool, FindAgreementLayout } from "../../../../src/modules/outils"; import { notFound } from "next/navigation"; import { generateDefaultMetadata } from "../../../../src/modules/common/metas"; -import { ElasticTool } from "../../../../src/modules/outils/type"; import { AgreementSearch } from "../../../../src/modules/convention-collective"; import { agreementRelatedItems } from "../../../../src/modules/convention-collective/agreementRelatedItems"; import { SITE_URL } from "../../../../src/config"; diff --git a/packages/code-du-travail-frontend/src/modules/common/BlueCard.tsx b/packages/code-du-travail-frontend/src/modules/common/BlueCard.tsx new file mode 100644 index 0000000000..ba85e0d4d4 --- /dev/null +++ b/packages/code-du-travail-frontend/src/modules/common/BlueCard.tsx @@ -0,0 +1,24 @@ +import React from "react"; +import { css } from "@styled-system/css"; +import { fr } from "@codegouvfr/react-dsfr"; + +type Props = { + children: React.ReactNode; +}; + +const BlueCard = ({ children, ...props }: Props): JSX.Element => { + return ( +
+ {children} +
+ ); +}; + +export default BlueCard; + +const block = css({ + background: "var(--background-alt-blue-cumulus)", +}); diff --git a/packages/code-du-travail-frontend/src/modules/common/useLocalStorage.ts b/packages/code-du-travail-frontend/src/modules/common/useLocalStorage.ts index 52c97f405b..f3efbbfc82 100644 --- a/packages/code-du-travail-frontend/src/modules/common/useLocalStorage.ts +++ b/packages/code-du-travail-frontend/src/modules/common/useLocalStorage.ts @@ -73,13 +73,3 @@ export const getAgreementFromLocalStorage = (): console.error(e); } }; - -export const removeAgreementFromLocalStorage = () => { - try { - if (window?.localStorage) { - window.localStorage.removeItem(STORAGE_KEY_AGREEMENT); - } - } catch (e) { - console.error(e); - } -}; diff --git a/packages/code-du-travail-frontend/src/modules/contributions/ContributionAgreemeentSelect.tsx b/packages/code-du-travail-frontend/src/modules/contributions/ContributionAgreemeentSelect.tsx deleted file mode 100644 index 93db2df3c2..0000000000 --- a/packages/code-du-travail-frontend/src/modules/contributions/ContributionAgreemeentSelect.tsx +++ /dev/null @@ -1,54 +0,0 @@ -"use client"; -import React from "react"; -import { Button } from "@codegouvfr/react-dsfr/Button"; -import { Card } from "@codegouvfr/react-dsfr/Card"; -import { css } from "@styled-system/css"; -import { fr } from "@codegouvfr/react-dsfr"; -import { removeCCNumberFromSlug } from "../common/utils"; - -import { Contribution } from "./type"; - -type Props = { - contribution: Contribution; -}; - -export function ContributionAgreementSelect({ contribution }: Props) { - const { slug } = contribution; - - return ( -
-

Votre convention collective

- - -
- ); -} - -const cardTitle = css({ - fontWeight: "normal!", -}); - -const block = css({ - background: "var(--background-alt-blue-cumulus)!", -}); diff --git a/packages/code-du-travail-frontend/src/modules/contributions/ContributionAgreement.tsx b/packages/code-du-travail-frontend/src/modules/contributions/ContributionAgreement.tsx new file mode 100644 index 0000000000..196386957d --- /dev/null +++ b/packages/code-du-travail-frontend/src/modules/contributions/ContributionAgreement.tsx @@ -0,0 +1,60 @@ +"use client"; +import React from "react"; +import { css } from "@styled-system/css"; +import { fr } from "@codegouvfr/react-dsfr"; +import { ContributionAgreementContent } from "./ContributionAgreementContent"; +import { Contribution } from "./type"; +import { removeCCNumberFromSlug } from "../common/utils"; +import BlueCard from "../common/BlueCard"; +import Card from "@codegouvfr/react-dsfr/Card"; +import Button from "@codegouvfr/react-dsfr/Button"; + +type Props = { + contribution: Contribution; +}; + +export function ContributionAgreement({ contribution }: Props) { + const { slug, relatedItems } = contribution; + + return ( + <> + +

+ Votre convention collective +

+ + +
+ + + + ); +} + +const cardTitle = css({ + fontWeight: "normal!", +}); diff --git a/packages/code-du-travail-frontend/src/modules/contributions/ContributionGeneric.tsx b/packages/code-du-travail-frontend/src/modules/contributions/ContributionGeneric.tsx new file mode 100644 index 0000000000..4ba5a26b4a --- /dev/null +++ b/packages/code-du-travail-frontend/src/modules/contributions/ContributionGeneric.tsx @@ -0,0 +1,105 @@ +"use client"; +import React, { useState } from "react"; +import { useContributionTracking } from "./tracking"; +import { isAgreementSupported, isAgreementValid } from "./contributionUtils"; +import { ContributionGenericContent } from "./ContributionGenericContent"; +import { Contribution } from "./type"; +import { useLocalStorageForAgreement } from "../common/useLocalStorage"; +import { ContributionGenericAgreementSearch } from "./ContributionGenericAgreementSearch"; +import { Button } from "@codegouvfr/react-dsfr/Button"; +import { fr } from "@codegouvfr/react-dsfr"; + +type Props = { + contribution: Contribution; +}; + +export function ContributionGeneric({ contribution }: Props) { + const getTitle = () => `/contribution/${slug}`; + const { slug, isNoCDT, relatedItems } = contribution; + + const [displayGeneric, setDisplayGeneric] = useState(false); + + const [selectedAgreement, setSelectedAgreement] = + useLocalStorageForAgreement(); + const { + emitAgreementTreatedEvent, + emitAgreementUntreatedEvent, + emitDisplayAgreementContent, + emitDisplayGeneralContent, + emitDisplayGenericContent, + emitClickP3, + } = useContributionTracking(); + + return ( + <> + { + setSelectedAgreement(agreement); + setDisplayGeneric(false); + if (!agreement) return; + + if (isAgreementSupported(contribution, agreement)) { + emitAgreementTreatedEvent(agreement.num); + } else { + emitAgreementUntreatedEvent(agreement.num); + } + }} + onDisplayClick={(ev) => { + setDisplayGeneric(!displayGeneric); + if ( + !isAgreementValid(contribution, selectedAgreement) || + !selectedAgreement + ) { + ev.preventDefault(); + setDisplayGeneric(true); + if (selectedAgreement) { + emitDisplayGeneralContent(getTitle()); + } else { + emitDisplayGenericContent(getTitle()); + } + } else { + emitDisplayAgreementContent(getTitle()); + } + }} + defaultAgreement={selectedAgreement} + trackingActionName={getTitle()} + /> + + {!isNoCDT && !isAgreementValid(contribution, selectedAgreement) && ( + <> + {!displayGeneric && ( + + )} + + + Cette réponse correspond à ce que prévoit le code du + travail, elle ne tient pas compte des spécificités de la{" "} + {selectedAgreement.shortTitle} + +

+ ) + } + /> + + )} + + ); +} diff --git a/packages/code-du-travail-frontend/src/modules/contributions/ContributionGenericAgreementSearch.tsx b/packages/code-du-travail-frontend/src/modules/contributions/ContributionGenericAgreementSearch.tsx index 6fab7657fd..38a3f9de23 100644 --- a/packages/code-du-travail-frontend/src/modules/contributions/ContributionGenericAgreementSearch.tsx +++ b/packages/code-du-travail-frontend/src/modules/contributions/ContributionGenericAgreementSearch.tsx @@ -1,12 +1,10 @@ "use client"; import React, { useEffect, useState } from "react"; import { Button } from "@codegouvfr/react-dsfr/Button"; -import { css } from "@styled-system/css"; import { fr } from "@codegouvfr/react-dsfr"; import Image from "next/image"; import AgreementSearch from "../convention-collective/AgreementSearch.svg"; -import { AgreementSearchForm } from "../convention-collective/AgreementSearch/AgreementSearchForm"; import { EnterpriseAgreement } from "../enterprise"; import { isAgreementSupported, @@ -15,12 +13,15 @@ import { } from "./contributionUtils"; import { Contribution } from "./type"; import Link from "../common/Link"; +import BlueCard from "../common/BlueCard"; +import { AgreementSearchForm } from "../convention-collective/AgreementSearch/AgreementSearchForm"; type Props = { - onAgreementSelect: (agreement?: EnterpriseAgreement, mode?: string) => void; + onAgreementSelect: (agreement?: EnterpriseAgreement) => void; onDisplayClick: (ev: React.MouseEvent) => void; contribution: Contribution; defaultAgreement?: EnterpriseAgreement; + trackingActionName: string; }; export function ContributionGenericAgreementSearch({ @@ -28,8 +29,9 @@ export function ContributionGenericAgreementSearch({ onAgreementSelect, onDisplayClick, defaultAgreement, + trackingActionName, }: Props) { - const { slug, isNoCDT } = contribution; + const { slug } = contribution; const [selectedAgreement, setSelectedAgreement] = useState(); @@ -80,12 +82,12 @@ export function ContributionGenericAgreementSearch({ return <>Vous pouvez consulter les informations générales ci-dessous.; }; return ( -
+
Personnalisez la réponse avec votre convention collective

@@ -94,14 +96,15 @@ export function ContributionGenericAgreementSearch({

{ - onAgreementSelect(agreement, mode); + onAgreementSelect={(agreement) => { + onAgreementSelect(agreement); setSelectedAgreement( isAgreementValid(contribution, agreement) ? agreement : undefined ); }} selectedAgreementAlert={selectedAgreementAlert} defaultAgreement={defaultAgreement} + trackingActionName={trackingActionName} /> {((contribution.isNoCDT && isValid) || !contribution.isNoCDT) && (
-
+ ); } - -const block = css({ - background: "var(--background-alt-blue-cumulus)!", -}); diff --git a/packages/code-du-travail-frontend/src/modules/contributions/ContributionGenericContent.tsx b/packages/code-du-travail-frontend/src/modules/contributions/ContributionGenericContent.tsx index 0e583e0e4d..80a1e2016e 100644 --- a/packages/code-du-travail-frontend/src/modules/contributions/ContributionGenericContent.tsx +++ b/packages/code-du-travail-frontend/src/modules/contributions/ContributionGenericContent.tsx @@ -1,6 +1,5 @@ "use client"; -import React, { ReactNode, useEffect, useRef, useState } from "react"; -import { Button } from "@codegouvfr/react-dsfr/Button"; +import React, { ReactNode, useEffect, useRef } from "react"; import { fr } from "@codegouvfr/react-dsfr"; import { Share } from "../common/Share"; import { ContributionContent } from "./ContributionContent"; @@ -13,7 +12,6 @@ import { RelatedItem } from "../documents"; import { Contribution } from "./type"; type Props = { - onDisplayClick: () => void; contribution: Contribution; alertText?: ReactNode; relatedItems: { @@ -25,41 +23,25 @@ type Props = { export function ContributionGenericContent({ contribution, - onDisplayClick, alertText, relatedItems, displayGeneric, }: Props) { const { title, metas } = contribution; - const [displayContent, setDisplayContent] = useState(false); const titleRef = useRef(null); const scrollToTitle = () => { setTimeout(() => { titleRef?.current?.scrollIntoView({ behavior: "smooth" }); }, 100); }; + useEffect(() => { - setDisplayContent(displayGeneric); - }, [displayGeneric]); - useEffect(() => { - if (displayContent) { + if (displayGeneric) { scrollToTitle(); } - }, [displayContent]); + }, [displayGeneric]); return ( <> - {!displayContent && ( - - )}
@@ -102,7 +84,7 @@ export function ContributionGenericContent({ "fr-col-12", "fr-col-md-4", "fr-mt-6w", - !displayContent && "fr-hidden" + !displayGeneric && "fr-hidden" )} > diff --git a/packages/code-du-travail-frontend/src/modules/contributions/ContributionLayout.tsx b/packages/code-du-travail-frontend/src/modules/contributions/ContributionLayout.tsx index 01cd45e931..a94b325455 100644 --- a/packages/code-du-travail-frontend/src/modules/contributions/ContributionLayout.tsx +++ b/packages/code-du-travail-frontend/src/modules/contributions/ContributionLayout.tsx @@ -1,54 +1,23 @@ "use client"; -import React, { useState } from "react"; +import React from "react"; import { css } from "@styled-system/css"; import { fr } from "@codegouvfr/react-dsfr"; -import { sources } from "../documents"; import { Feedback } from "../layout/feedback"; import Breadcrumb from "@codegouvfr/react-dsfr/Breadcrumb"; -import { useContributionTracking } from "./tracking"; -import { ContributionGenericAgreementSearch } from "./ContributionGenericAgreementSearch"; -import { isAgreementSupported, isAgreementValid } from "./contributionUtils"; -import { ContributionGenericContent } from "./ContributionGenericContent"; -import { ContributionAgreementSelect } from "./ContributionAgreemeentSelect"; -import { ContributionAgreementContent } from "./ContributionAgreementContent"; import { Contribution } from "./type"; -import { useLocalStorageForAgreement } from "../common/useLocalStorage"; import { SourceData } from "../layout/SourceData"; +import { ContributionGeneric } from "./ContributionGeneric"; +import { ContributionAgreement } from "./ContributionAgreement"; type Props = { contribution: Contribution; }; -export type RelatedItem = { - title: string; - items: { - title: string; - url: string; - source: (typeof sources)[number]; - }[]; -}; - export function ContributionLayout({ contribution }: Props) { - const getTitle = () => `/contribution/${slug}`; - const { date, title, slug, isGeneric, isNoCDT, isFicheSP, relatedItems } = - contribution; - - const [displayGeneric, setDisplayGeneric] = useState(false); - const [selectedAgreement, setSelectedAgreement] = - useLocalStorageForAgreement(); - const { - emitAgreementTreatedEvent, - emitAgreementUntreatedEvent, - emitDisplayAgreementContent, - emitDisplayGeneralContent, - emitDisplayGenericContent, - emitClickP1, - emitClickP2, - emitClickP3, - } = useContributionTracking(); + const { date, title, isGeneric, isFicheSP } = contribution; return ( -
+ <> {title} {!isGeneric && ( - <> + {" "} - - {contribution.ccnShortTitle} - - + {contribution.ccnShortTitle} + )}

@@ -81,83 +48,15 @@ export function ContributionLayout({ contribution }: Props) { )}

{isGeneric ? ( - { - setSelectedAgreement(agreement); - setDisplayGeneric(false); - if (!agreement) return; - switch (mode) { - case "p1": - emitClickP1(getTitle()); - break; - case "p2": - emitClickP2(getTitle()); - break; - } - if (isAgreementSupported(contribution, agreement)) { - emitAgreementTreatedEvent(agreement?.id); - } else { - emitAgreementUntreatedEvent(agreement?.id); - } - }} - onDisplayClick={(ev) => { - setDisplayGeneric(!displayGeneric); - if ( - !isAgreementValid(contribution, selectedAgreement) || - !selectedAgreement - ) { - ev.preventDefault(); - setDisplayGeneric(true); - if (selectedAgreement) { - emitDisplayGenericContent(getTitle()); - } else { - emitDisplayGeneralContent(getTitle()); - } - } else { - emitDisplayAgreementContent(getTitle()); - } - }} - defaultAgreement={selectedAgreement} - /> + ) : ( - - )} - {isGeneric && - !isNoCDT && - (!selectedAgreement || - !isAgreementValid(contribution, selectedAgreement)) && ( - { - emitClickP3(getTitle()); - }} - relatedItems={relatedItems} - displayGeneric={displayGeneric} - alertText={ - selectedAgreement && - !isAgreementSupported(contribution, selectedAgreement) && ( -

- - Cette réponse correspond à ce que prévoit le code du - travail, elle ne tient pas compte des spécificités de la{" "} - {selectedAgreement.shortTitle} - -

- ) - } - /> - )} - {!isGeneric && ( - + )} +
-
+ ); } diff --git a/packages/code-du-travail-frontend/src/modules/contributions/__tests__/contribution-generic.tracking.test.tsx b/packages/code-du-travail-frontend/src/modules/contributions/__tests__/contribution-generic.tracking.test.tsx new file mode 100644 index 0000000000..5fda8f2d07 --- /dev/null +++ b/packages/code-du-travail-frontend/src/modules/contributions/__tests__/contribution-generic.tracking.test.tsx @@ -0,0 +1,303 @@ +import { fireEvent, render, waitFor } from "@testing-library/react"; +import React from "react"; +import { sendEvent } from "../../utils"; +import { mockAgreementSearch, ui } from "./ui"; +import { ui as ccUi } from "../../convention-collective/__tests__/ui"; +import { byText } from "testing-library-selector"; +import { ContributionGeneric } from "../ContributionGeneric"; +import { Contribution } from "../type"; +import { searchEnterprises } from "../../enterprise/queries"; + +beforeEach(() => { + localStorage.clear(); +}); + +jest.mock("../../utils", () => ({ + sendEvent: jest.fn(), +})); + +jest.mock("uuid", () => ({ + v4: jest.fn(() => ""), +})); + +jest.mock("next/navigation", () => ({ + redirect: jest.fn(), + usePathname: jest.fn(), +})); + +jest.mock("../../convention-collective/search", () => ({ + searchAgreement: jest.fn(), +})); +jest.mock("../../enterprise/queries", () => ({ + searchEnterprises: jest.fn(), +})); + +describe("", () => { + beforeEach(() => { + const ma = sendEvent as jest.MockedFunction; + ma.mockReset(); + }); + const contribution = { + date: "05/12/2023", + isGeneric: true, + isNoCdt: false, + messageBlockGenericNoCDT: "message No CDT", + ccSupported: ["1388"], + ccUnextended: [], + type: "content", + content: "

hello generic

", + source: "contributions", + linkedContent: [], + references: [], + idcc: "0000", + title: "Ma contrib", + slug: "my-contrib", + breadcrumbs: [], + metas: { + title: "SEO Title", + description: "SEO Description", + }, + } as Partial as any; + + (searchEnterprises as jest.Mock).mockImplementation(() => + Promise.resolve([ + { + label: "CARREFOUR PROXIMITE FRANCE (SHOPI-8 A HUIT)", + siren: "345130488", + address: "ZI ROUTE DE PARIS 14120 MONDEVILLE", + conventions: [ + { + id: "2216", + contributions: true, + num: 2216, + shortTitle: + "Commerce de détail et de gros à prédominance alimentaire", + }, + ], + }, + ]) + ); + it("je connais ma CC - cc traité", async () => { + mockAgreementSearch({ + num: 1388, + shortTitle: "Industrie du pétrole", + id: "1388", + }); + expect(sendEvent).toHaveBeenCalledTimes(0); + + render(); + fireEvent.click(ccUi.radio.agreementSearchOption.get()); + fireEvent.change(ccUi.searchByName.input.get(), { + target: { value: "1388" }, + }); + await waitFor(() => + expect( + ccUi.searchByName.autocompleteLines.IDCC1388.name.get() + ).toBeInTheDocument() + ); + fireEvent.click(ccUi.searchByName.autocompleteLines.IDCC1388.name.get()); + expect(ui.generic.buttonDisplayInfo.get()).toBeInTheDocument(); + expect(sendEvent).toHaveBeenCalledTimes(4); + // @ts-ignore + expect(sendEvent.mock.calls).toEqual([ + [ + { + action: "/contribution/my-contrib", + category: "cc_search", + name: '{"query":"1388"}', + value: "", + }, + ], + [ + { + action: "click_p1", + category: "cc_search_type_of_users", + name: "/contribution/my-contrib", + }, + ], + [ + { + action: "cc_select_traitée", + category: "outil", + name: 1388, + }, + ], + [ + { + action: "/contribution/my-contrib", + category: "cc_select_p1", + name: "idcc1388", + value: "", + }, + ], + ]); + expect(ui.generic.buttonDisplayInfo.get()).toHaveAttribute( + "href", + "/contribution/1388-my-contrib" + ); + fireEvent.click(ui.generic.buttonDisplayInfo.get()); + expect(sendEvent).toHaveBeenCalledTimes(5); + expect(sendEvent).toHaveBeenLastCalledWith({ + action: "click_afficher_les_informations_CC", + category: "contribution", + name: "/contribution/my-contrib", + }); + }); + + it("je connais ma CC - cc non traité", async () => { + mockAgreementSearch({ + num: 16, + shortTitle: "Transports routiers et activités auxiliaires du transport", + id: "0016", + }); + expect(sendEvent).toHaveBeenCalledTimes(0); + + render(); + fireEvent.click(ccUi.radio.agreementSearchOption.get()); + fireEvent.change(ccUi.searchByName.input.get(), { + target: { value: "16" }, + }); + await waitFor(() => + expect( + byText( + /Transports routiers et activités auxiliaires du transport/ + ).query() + ).toBeInTheDocument() + ); + fireEvent.click( + byText(/Transports routiers et activités auxiliaires du transport/).get() + ); + expect(ccUi.buttonDisplayInfo.query()).toBeInTheDocument(); + expect(sendEvent).toHaveBeenCalledTimes(4); + // @ts-ignore + expect(sendEvent.mock.calls).toEqual([ + [ + { + action: "/contribution/my-contrib", + category: "cc_search", + name: '{"query":"16"}', + value: "", + }, + ], + [ + { + action: "click_p1", + category: "cc_search_type_of_users", + name: "/contribution/my-contrib", + }, + ], + [ + { + action: "cc_select_non_traitée", + category: "outil", + name: 16, + }, + ], + [ + { + action: "/contribution/my-contrib", + category: "cc_select_p1", + name: "idcc0016", + value: "", + }, + ], + ]); + fireEvent.click(ccUi.buttonDisplayInfo.get()); + expect(sendEvent).toHaveBeenCalledTimes(5); + expect(sendEvent).toHaveBeenLastCalledWith({ + action: "click_afficher_les_informations_générales", + category: "contribution", + name: "/contribution/my-contrib", + }); + }); + + it("je ne connais pas ma CC", async () => { + expect(sendEvent).toHaveBeenCalledTimes(0); + + render(); + fireEvent.click(ccUi.radio.enterpriseSearchOption.get()); + fireEvent.change(ccUi.searchByEnterprise.input.get(), { + target: { value: "carrefour" }, + }); + fireEvent.click(ccUi.searchByEnterprise.submitButton.get()); + await waitFor(() => { + fireEvent.click( + ccUi.searchByEnterprise.resultLines.carrefour.title.get() + ); + }); + expect( + byText(/Vous avez sélectionné la convention collective/).query() + ).toBeInTheDocument(); + + expect(sendEvent).toHaveBeenCalledTimes(5); + // @ts-ignore + expect(sendEvent.mock.calls).toEqual([ + [ + { + action: "/contribution/my-contrib", + category: "enterprise_search", + name: '{"query":"carrefour"}', + value: "", + }, + ], + [ + { + action: "/contribution/my-contrib", + category: "cc_select_p2", + name: "idcc2216", + value: "", + }, + ], + [ + { + action: "/contribution/my-contrib", + category: "enterprise_select", + name: '{"label":"CARREFOUR PROXIMITE FRANCE (SHOPI-8 A HUIT)","siren":"345130488"}', + value: "", + }, + ], + [ + { + action: "click_p2", + category: "cc_search_type_of_users", + name: "/contribution/my-contrib", + }, + ], + [ + { + action: "cc_select_non_traitée", + category: "outil", + name: 2216, + }, + ], + ]); + }); + it("afficher les infos - sans CC", async () => { + expect(sendEvent).toHaveBeenCalledTimes(0); + + render(); + expect(ui.generic.buttonDisplayInfo.get()).toBeInTheDocument(); + fireEvent.click(ui.generic.buttonDisplayInfo.get()); + expect(sendEvent).toHaveBeenCalledTimes(1); + expect(sendEvent).toHaveBeenLastCalledWith({ + action: "click_afficher_les_informations_sans_CC", + category: "contribution", + name: "/contribution/my-contrib", + }); + }); + + it("voir les infos générales", () => { + expect(sendEvent).toHaveBeenCalledTimes(0); + + render(); + + fireEvent.click(ui.generic.linkDisplayInfo.get()); + + expect(sendEvent).toHaveBeenCalledTimes(1); + expect(sendEvent).toHaveBeenCalledWith({ + action: "click_p3", + category: "cc_search_type_of_users", + name: "/contribution/my-contrib", + }); + }); +}); diff --git a/packages/code-du-travail-frontend/src/modules/contributions/__tests__/contributions.test.tsx b/packages/code-du-travail-frontend/src/modules/contributions/__tests__/contributions.test.tsx index fc5dd0a134..9a934a31a0 100644 --- a/packages/code-du-travail-frontend/src/modules/contributions/__tests__/contributions.test.tsx +++ b/packages/code-du-travail-frontend/src/modules/contributions/__tests__/contributions.test.tsx @@ -50,6 +50,10 @@ jest.mock("next/navigation", () => ({ describe("", () => { let rendering: RenderResult; + beforeEach(() => { + const ma = sendEvent as jest.MockedFunction; + ma.mockReset(); + }); it("should render title only if generic", () => { rendering = render(); const titreH1 = rendering.getByRole("heading", { level: 1 }); @@ -133,7 +137,7 @@ describe("", () => { expect(sendEvent).toHaveBeenCalledWith({ action: "cc_select_traitée", category: "outil", - name: "0016", + name: 16, }); }); @@ -147,7 +151,7 @@ describe("", () => { expect(sendEvent).toHaveBeenCalledWith({ action: "cc_select_traitée", category: "outil", - name: "3239", + name: 3239, }); }); @@ -181,7 +185,7 @@ describe("", () => { expect(sendEvent).toHaveBeenCalledWith({ action: "cc_select_non_traitée", category: "outil", - name: "1388", + name: 1388, }); expect(ccUi.warning.title.query()).toBeInTheDocument(); fireEvent.click(ui.generic.linkDisplayInfo.get()); @@ -233,7 +237,7 @@ describe("", () => { expect(sendEvent).toHaveBeenCalledWith({ action: "cc_select_traitée", category: "outil", - name: "0016", + name: 16, }); }); @@ -270,7 +274,7 @@ describe("", () => { expect(sendEvent).toHaveBeenCalledWith({ action: "cc_select_non_traitée", category: "outil", - name: "1388", + name: 1388, }); }); diff --git a/packages/code-du-travail-frontend/src/modules/contributions/__tests__/ui.ts b/packages/code-du-travail-frontend/src/modules/contributions/__tests__/ui.ts index 40b560df93..03940d9109 100644 --- a/packages/code-du-travail-frontend/src/modules/contributions/__tests__/ui.ts +++ b/packages/code-du-travail-frontend/src/modules/contributions/__tests__/ui.ts @@ -1,7 +1,9 @@ import { byText } from "testing-library-selector"; +import { searchAgreement } from "../../convention-collective"; export const ui = { generic: { + buttonDisplayInfo: byText(/Afficher les informations$/), linkDisplayInfo: byText( "Afficher les informations sans sélectionner une convention collective" ), @@ -11,3 +13,17 @@ export const ui = { ), }, }; +export const mockAgreementSearch = (idcc) => + (searchAgreement as jest.Mock).mockImplementation(() => + Promise.resolve([ + { + ...idcc, + url: "https://www.legifrance.gouv.fr/affichIDCC.do?idConvention=KALICONT000005635267", + effectif: 31273, + cdtnId: "8c50f32b7d", + title: + "Convention collective nationale deo l'industrie du pétrole du 3 septembre 1985. Etendue par arrêté du 31 juillet 1986 JORF 9 août 1986.", + contributions: false, + }, + ]) + ); diff --git a/packages/code-du-travail-frontend/src/modules/convention-collective/AgreementSearch/AgreementSearch.tsx b/packages/code-du-travail-frontend/src/modules/convention-collective/AgreementSearch/AgreementSearch.tsx index 66093ec339..4ef849e54a 100644 --- a/packages/code-du-travail-frontend/src/modules/convention-collective/AgreementSearch/AgreementSearch.tsx +++ b/packages/code-du-travail-frontend/src/modules/convention-collective/AgreementSearch/AgreementSearch.tsx @@ -4,7 +4,10 @@ import { useState } from "react"; import Button from "@codegouvfr/react-dsfr/Button"; import { AgreementSearchInput } from "./AgreementSearchInput"; -import { useAgreementSearchTracking } from "../tracking"; +import { + TrackingAgreementSearchAction, + useAgreementSearchTracking, +} from "../tracking"; export const AgreementSearch = () => { const [noResult, setNoResult] = useState(false); @@ -15,6 +18,7 @@ export const AgreementSearch = () => { onSearch={(query, result) => { setNoResult(query.length > 2 && !result?.length); }} + trackingActionName={TrackingAgreementSearchAction.AGREEMENT_SEARCH} />
- ) : ( - <> - {showButtonToDisplayCDTContent() && ( - - )} - - )} - - - - {showGeneralInformationButton() && ( - { - pushAgreementEvents( - getTitle(), - { route: "not-selected" }, - false, - false - ); - setShowAnswer(true); - scrollToTitle(); - }} - > - Accéder aux informations générales sans renseigner ma convention - collective - - )} - - - - Que dit le code du travail ? - - {convention && !isSupported(convention) && ( - - Cette réponse correspond à ce que prévoit le code du travail, elle - ne tient pas compte des spécificités de la convention collective{" "} - {convention.shortTitle} - - )} - - - - - - - - ); -}; - -const { spacings } = theme; - -const SectionHidden = styled(Section)` - display: ${({ show }) => (show ? "block" : "none")}; -`; -const DivCentered = styled.div` - text-align: center; - margin-top: ${spacings.large}; -`; - -const Div = styled.div` - margin-top: ${spacings.base}; -`; - -const StyledButton = styled(Button)` - margin-top: ${spacings.base}; - - :not(:hover) { - color: ${theme.colors.paragraph}; - } -`; - -const StyledDirectionRightIcon = styled(DirectionRight)` - width: 1.5em; - margin-left: ${spacings.base}; -`; -const SectionNoPadding = styled(Section)` - padding: 0 !important; -`; - -export default ContributionGeneric; diff --git a/packages/code-du-travail-frontend/src/contributions/ContributionMessageBlock.tsx b/packages/code-du-travail-frontend/src/contributions/ContributionMessageBlock.tsx deleted file mode 100644 index f06d1af808..0000000000 --- a/packages/code-du-travail-frontend/src/contributions/ContributionMessageBlock.tsx +++ /dev/null @@ -1,42 +0,0 @@ -import { - Alert, - Heading, - icons, - IconStripe, - Section, - theme, -} from "@socialgouv/cdtn-ui"; -import { ElasticSearchContribution } from "@socialgouv/cdtn-types"; -import styled from "styled-components"; -import Html from "../common/Html"; - -type Props = { - message: ElasticSearchContribution["messageBlock"]; -}; - -export const ContributionMessageBlock = ({ message }: Props) => { - if (!message) { - return <>; - } - return ( - - - - Attention - - {message} - - - ); -}; - -const { spacings } = theme; - -const StyledSection = styled(Section)` - margin-top: ${spacings.base}; - padding-bottom: 0; - - > div { - margin-bottom: 0; - } -`; diff --git a/packages/code-du-travail-frontend/src/contributions/DisplayContentContribution.tsx b/packages/code-du-travail-frontend/src/contributions/DisplayContentContribution.tsx index 0f8d0c2e8c..0401d792a2 100644 --- a/packages/code-du-travail-frontend/src/contributions/DisplayContentContribution.tsx +++ b/packages/code-du-travail-frontend/src/contributions/DisplayContentContribution.tsx @@ -2,7 +2,6 @@ import { Alert, Heading, Table as UITable, theme } from "@socialgouv/cdtn-ui"; import { AccordionWithAnchor as Accordion } from "../../src/common/AccordionWithAnchor"; import styled from "styled-components"; -import { FicheServicePublic } from "../fiche-service-public"; import parse, { DOMNode, domToReact, @@ -11,21 +10,6 @@ import parse, { } from "html-react-parser"; import { xssWrapper } from "../lib"; -export const ContentSP = ({ raw, titleLevel }) => { - return ( - <> - {raw && ( - - - - )} - - ); -}; - const mapItem = (titleLevel: number, domNode: Element, summary: Element) => ({ body: domToReact(domNode.children as DOMNode[], options(titleLevel + 1)), title: domToReact(summary.children as DOMNode[], { diff --git a/packages/code-du-travail-frontend/src/contributions/LinkedContent.tsx b/packages/code-du-travail-frontend/src/contributions/LinkedContent.tsx deleted file mode 100644 index 2aa0404bd0..0000000000 --- a/packages/code-du-travail-frontend/src/contributions/LinkedContent.tsx +++ /dev/null @@ -1,35 +0,0 @@ -import { Grid, theme, Section, Title } from "@socialgouv/cdtn-ui"; -import { ListLink } from "../search/SearchResults/Results"; -import { ElasticSearchContribution } from "@socialgouv/cdtn-types"; - -type Props = { - linkedContent: ElasticSearchContribution["linkedContent"]; -}; - -export const LinkedContent = ({ linkedContent }: Props) => { - return ( - <> - {linkedContent.length > 0 && ( -
- - Pour aller plus loin - - - {linkedContent.map((item) => { - return ( - - ); - })} - -
- )} - - ); -}; - -const { spacings } = theme; diff --git a/packages/code-du-travail-frontend/src/contributions/References.tsx b/packages/code-du-travail-frontend/src/contributions/References.tsx deleted file mode 100644 index e43b5034ba..0000000000 --- a/packages/code-du-travail-frontend/src/contributions/References.tsx +++ /dev/null @@ -1,21 +0,0 @@ -import { SOURCES } from "@socialgouv/cdtn-utils"; -import { ElasticSearchContribution } from "@socialgouv/cdtn-types"; -import React from "react"; -import References from "../common/References"; - -type Props = { - references: ElasticSearchContribution["references"]; -}; - -export const ReferencesJuridiques = (props: Props) => { - if (!props.references || props.references.length === 0) { - return null; - } - const refs = props.references - .map(({ title, url }) => { - return { title, type: SOURCES.EXTERNALS, url }; - }) - .sort((a, b) => (a.url && !b.url ? -1 : !a.url && b.url ? 1 : 0)); - - return ; -}; diff --git a/packages/code-du-travail-frontend/src/contributions/__tests__/ContributionGeneric.test.tsx b/packages/code-du-travail-frontend/src/contributions/__tests__/ContributionGeneric.test.tsx deleted file mode 100644 index bbde119b25..0000000000 --- a/packages/code-du-travail-frontend/src/contributions/__tests__/ContributionGeneric.test.tsx +++ /dev/null @@ -1,229 +0,0 @@ -import { fireEvent, render, waitFor, screen } from "@testing-library/react"; -import React from "react"; -import ContributionGeneric from "../ContributionGeneric"; -import { push as matopush } from "@socialgouv/matomo-next"; -import { ui } from "../../outils/DureePreavisDemission/__tests__/ui"; -import { byTestId, byText } from "testing-library-selector"; -import router from "next/router"; - -beforeEach(() => { - localStorage.clear(); -}); -jest.mock("@socialgouv/matomo-next", () => ({ - push: jest.fn(), -})); -jest.mock("../../conventions/Search/api/agreements.service"); -jest.mock("../../conventions/Search/api/enterprises.service"); -jest.mock("next/router", () => ({ - push: jest.fn(), - asPath: "/contribution/my-contrib", -})); -describe("", () => { - beforeEach(() => { - const ma = matopush as jest.MockedFunction; - ma.mockReset(); - const push = router.push as jest.MockedFunction; - push.mockReset(); - }); - const contribution = { - ccSupported: ["1351"], - ccUnextended: [], - type: "content", - content: "

hello generic

", - source: "contributions", - linkedContent: [], - references: [], - idcc: "0000", - title: "Ma contrib", - slug: "my-contrib", - description: "ma meta description", - messageBlock: "mon message block", - breadcrumbs: [], - } as any; - it("je connais ma CC - cc traité", async () => { - expect(matopush).toHaveBeenCalledTimes(0); - - render(); - fireEvent.click(ui.agreement.agreement.get()); - fireEvent.focus(ui.agreement.agreementInput.get()); - fireEvent.change(ui.agreement.agreementInput.get(), { - target: { value: "1351" }, - }); - await waitFor(() => - expect(ui.agreement1351.searchResult.query()).toBeInTheDocument() - ); - fireEvent.click(ui.agreement1351.searchResult.get()); - expect(byText(/Afficher les informations/).get()).toBeInTheDocument(); - expect(matopush).toHaveBeenCalledTimes(4); - // @ts-ignore - expect(matopush.mock.calls).toEqual([ - [ - [ - "trackEvent", - "cc_search", - "/contribution/my-contrib", - '{"query":"1351"}', - ], - ], - [ - [ - "trackEvent", - "cc_search_type_of_users", - "click_p1", - "/contribution/my-contrib", - ], - ], - [["trackEvent", "cc_select_p1", "/contribution/my-contrib", "idcc1351"]], - [["trackEvent", "outil", "cc_select_traitée", 1351]], - ]); - fireEvent.click(byText("Afficher les informations").get()); - expect(matopush).toHaveBeenCalledTimes(5); - expect(matopush).toHaveBeenLastCalledWith([ - "trackEvent", - "contribution", - "click_afficher_les_informations_CC", - "/contribution/my-contrib", - ]); - expect(router.push).toHaveBeenCalledWith("/contribution/1351-my-contrib"); - }); - - it("je connais ma CC - cc non traité", async () => { - expect(matopush).toHaveBeenCalledTimes(0); - - render(); - fireEvent.click(ui.agreement.agreement.get()); - fireEvent.focus(ui.agreement.agreementInput.get()); - fireEvent.change(ui.agreement.agreementInput.get(), { - target: { value: "3239" }, - }); - await waitFor(() => - expect( - byText(/Particuliers employeurs et emploi à domicile/).query() - ).toBeInTheDocument() - ); - fireEvent.click( - byText(/Particuliers employeurs et emploi à domicile/).get() - ); - expect(byText(/Afficher les informations/).get()).toBeInTheDocument(); - expect(matopush).toHaveBeenCalledTimes(4); - // @ts-ignore - expect(matopush.mock.calls).toEqual([ - [ - [ - "trackEvent", - "cc_search", - "/contribution/my-contrib", - '{"query":"3239"}', - ], - ], - [ - [ - "trackEvent", - "cc_search_type_of_users", - "click_p1", - "/contribution/my-contrib", - ], - ], - [["trackEvent", "cc_select_p1", "/contribution/my-contrib", "idcc3239"]], - [["trackEvent", "outil", "cc_select_non_traitée", 3239]], - ]); - fireEvent.click(byText("Afficher les informations générales").get()); - expect(matopush).toHaveBeenCalledTimes(5); - expect(matopush).toHaveBeenLastCalledWith([ - "trackEvent", - "contribution", - "click_afficher_les_informations_générales", - "/contribution/my-contrib", - ]); - expect(router.push).toHaveBeenCalledTimes(0); - }); - - it("je ne connais pas ma CC", async () => { - expect(matopush).toHaveBeenCalledTimes(0); - - render(); - fireEvent.click(ui.agreement.unknownAgreement.get()); - fireEvent.focus(ui.agreement.agreementCompanyInput.get()); - fireEvent.change(ui.agreement.agreementCompanyInput.get(), { - target: { value: "carrefour" }, - }); - fireEvent.click(byTestId("agreement-company-search-button").get()); - await waitFor(() => { - fireEvent.click(byText("CARREFOUR HYPERMARCHES").get()); - }); - expect( - ui.agreement.agreementCompanyInputConfirm.query() - ).toBeInTheDocument(); - fireEvent.click( - byText( - "Commerce de détail et de gros à prédominance alimentaire (IDCC 2216)" - ).get() - ); - expect(matopush).toHaveBeenCalledTimes(5); - // @ts-ignore - expect(matopush.mock.calls).toEqual([ - [ - [ - "trackEvent", - "enterprise_search", - "/contribution/my-contrib", - '{"query":"carrefour"}', - ], - ], - [ - [ - "trackEvent", - "cc_search_type_of_users", - "click_p2", - "/contribution/my-contrib", - ], - ], - [ - [ - "trackEvent", - "enterprise_select", - "/contribution/my-contrib", - '{"label":"CARREFOUR HYPERMARCHES","siren":"451321335"}', - ], - ], - [["trackEvent", "cc_select_p2", "/contribution/my-contrib", "idcc2216"]], - [["trackEvent", "outil", "cc_select_non_traitée", 2216]], - ]); - }); - it("afficher les infos - sans CC", async () => { - expect(matopush).toHaveBeenCalledTimes(0); - - render(); - expect(byText(/Afficher les informations/).get()).toBeInTheDocument(); - fireEvent.click(byText("Afficher les informations").get()); - expect(matopush).toHaveBeenCalledTimes(1); - expect(matopush).toHaveBeenLastCalledWith([ - "trackEvent", - "contribution", - "click_afficher_les_informations_sans_CC", - "/contribution/my-contrib", - ]); - expect(router.push).toHaveBeenCalledTimes(0); - }); - - it("voir les infos générales", () => { - expect(matopush).toHaveBeenCalledTimes(0); - - render(); - - fireEvent.click( - byText( - "Accéder aux informations générales sans renseigner ma convention collective" - ).get() - ); - - expect(matopush).toHaveBeenCalledTimes(1); - expect(matopush).toHaveBeenCalledWith([ - "trackEvent", - "cc_search_type_of_users", - "click_p3", - "/contribution/my-contrib", - ]); - expect(router.push).toHaveBeenCalledTimes(0); - }); -}); diff --git a/packages/code-du-travail-frontend/src/contributions/__tests__/ReferencesJuridique.test.tsx b/packages/code-du-travail-frontend/src/contributions/__tests__/ReferencesJuridique.test.tsx deleted file mode 100644 index 768c824f2a..0000000000 --- a/packages/code-du-travail-frontend/src/contributions/__tests__/ReferencesJuridique.test.tsx +++ /dev/null @@ -1,43 +0,0 @@ -import { render } from "@testing-library/react"; -import { ReferencesJuridiques } from "../References"; - -describe("ReferencesJuridiques", () => { - it(`doit retourner null si pas de références`, () => { - const { asFragment } = render( - - ); - - expect(asFragment().firstChild).toBeNull(); - }); - it(`doit mettre les références sans lien à la fin`, () => { - const { asFragment } = render( - - ); - - expect(asFragment().firstChild).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/ReferencesJuridique.test.tsx.snap b/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/ReferencesJuridique.test.tsx.snap deleted file mode 100644 index 4d586e4e75..0000000000 --- a/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/ReferencesJuridique.test.tsx.snap +++ /dev/null @@ -1,113 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`ReferencesJuridiques doit mettre les références sans lien à la fin 1`] = ` -
-
- -
- -
-
-
-`; diff --git a/packages/code-du-travail-frontend/src/contributions/utils.ts b/packages/code-du-travail-frontend/src/contributions/utils.ts deleted file mode 100644 index 0b6e70a5fb..0000000000 --- a/packages/code-du-travail-frontend/src/contributions/utils.ts +++ /dev/null @@ -1,2 +0,0 @@ -export const removeCCNumberFromSlug = (slug: string): string => - slug.split("-").slice(1).join("-"); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/__mocks__/@testing-library/react.js b/packages/code-du-travail-frontend/src/fiche-service-public/__mocks__/@testing-library/react.js deleted file mode 100644 index c55abd91f3..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/__mocks__/@testing-library/react.js +++ /dev/null @@ -1,26 +0,0 @@ -import React from "react"; -import PropTypes from "prop-types"; -import { render } from "@testing-library/react"; -import { ThemeProvider } from "styled-components"; -import { theme } from "@socialgouv/cdtn-ui"; - -const AllTheProviders = ({ children }) => { - return ( - - <>{children} - - ); -}; - -AllTheProviders.propTypes = { - children: PropTypes.node.isRequired, -}; - -const customRender = (ui, options) => - render(ui, { wrapper: AllTheProviders, ...options }); - -// re-export everything -export * from "@testing-library/react"; - -// override render method -export { customRender as render }; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/FicheServicePublic.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/FicheServicePublic.test.js deleted file mode 100644 index e3d580d552..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/FicheServicePublic.test.js +++ /dev/null @@ -1,14 +0,0 @@ -import { render } from "@testing-library/react"; -import React from "react"; - -import { FicheServicePublic } from ".."; -import ficheDataMock from "./ficheData.mock.json"; - -describe("", () => { - it("should render", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/__snapshots__/FicheServicePublic.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/__snapshots__/FicheServicePublic.test.js.snap deleted file mode 100644 index 837cb75c6e..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/__snapshots__/FicheServicePublic.test.js.snap +++ /dev/null @@ -1,1521 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[` should render 1`] = ` -
-
-

- - La démission vous permet de rompre votre contrat de travail de votre propre initiative. Cependant, pour être valable, elle doit respecter certaines conditions. Vous devez prévenir votre employeur de votre volonté de démissionner. Sauf en cas de dispense, vous poursuivez votre activité jusqu'au terme du préavis de démission. Des dispositions spécifiques de rupture anticipée du contrat de travail sont prévues selon votre situation au moment de votre démission ( - - CDI - - , - - CDD - - ou intérim). - -

-
-
-
    - - - -
-
-
-
-

- CDI -

-
-
-
-
-
-
- -
- -
-
-
-
-
- -
- -
-
-
-
-
- -
- -
-
-
-
-
- -
- -
-
-
-
-
- -
- -
-
-
-
-
-
-
-
-

- Modèle de document -

-

- - Lettre de démission du salarié - -

-
-
-
- Source: - Direction de l'information légale et administrative (Premier ministre) -
-
-
-
-`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/ficheData.mock.json b/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/ficheData.mock.json deleted file mode 100644 index 7082057061..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/__tests__/ficheData.mock.json +++ /dev/null @@ -1,6796 +0,0 @@ -{ - "type": "element", - "name": "Publication", - "attributes": { - "xmlns:dc": "http://purl.org/dc/elements/1.1/", - "xmlns:xsi": "http://www.w3.org/2001/XMLSchema-instance", - "ID": "F2883", - "type": "Fiche d'information", - "xsi:noNamespaceSchemaLocation": "../Schemas/3.0/Publication.xsd" - }, - "children": [ - { - "type": "element", - "name": "dc:title", - "children": [ - { - "type": "text", - "text": "Démission d'un salarié" - } - ] - }, - { - "type": "element", - "name": "dc:creator", - "children": [ - { - "type": "text", - "text": "Direction de l'information légale et administrative" - } - ] - }, - { - "type": "element", - "name": "dc:subject", - "children": [ - { - "type": "text", - "text": "Travail" - } - ] - }, - { - "type": "element", - "name": "dc:description", - "children": [ - { - "type": "text", - "text": "La démission permet au salarié, à son initiative, de rompre son contrat de travail, sous conditions." - } - ] - }, - { - "type": "element", - "name": "dc:publisher", - "children": [ - { - "type": "text", - "text": "Direction de l'information légale et administrative" - } - ] - }, - { - "type": "element", - "name": "dc:contributor", - "children": [ - { - "type": "text", - "text": "Direction de l'information légale et administrative (Premier ministre)" - } - ] - }, - { - "type": "element", - "name": "dc:date", - "children": [ - { - "type": "text", - "text": "modified 2019-01-24" - } - ] - }, - { - "type": "element", - "name": "dc:type", - "children": [ - { - "type": "text", - "text": "Fiche pratique" - } - ] - }, - { - "type": "element", - "name": "dc:format", - "children": [ - { - "type": "text", - "text": "text/xml" - } - ] - }, - { - "type": "element", - "name": "dc:identifier", - "children": [ - { - "type": "text", - "text": "F2883" - } - ] - }, - { - "type": "element", - "name": "dc:source", - "children": [ - { - "type": "text", - "text": "http://www.legifrance.gouv.fr/affichCodeArticle.do?idArticle=LEGIARTI000019071194&cidTexte=LEGITEXT000006072050, http://www.legifrance.gouv.fr/affichCodeArticle.do?idArticle=LEGIARTI000006901174&cidTexte=LEGITEXT000006072050, http://legifrance.gouv.fr/affichCodeArticle.do?idArticle=LEGIARTI000018764983&cidTexte=LEGITEXT000006072050, http://legifrance.gouv.fr/affichCodeArticle.do?idArticle=LEGIARTI000006904729&cidTexte=LEGITEXT000006072050, http://www.legifrance.gouv.fr/affichCode.do?idSectionTA=LEGISCTA000006195635&cidTexte=LEGITEXT000006072050" - } - ] - }, - { - "type": "element", - "name": "dc:language", - "children": [ - { - "type": "text", - "text": "Fr" - } - ] - }, - { - "type": "element", - "name": "dc:relation", - "children": [ - { - "type": "text", - "text": "isPartOf N19611" - } - ] - }, - { - "type": "element", - "name": "dc:coverage", - "children": [ - { - "type": "text", - "text": "France entière" - } - ] - }, - { - "type": "element", - "name": "dc:rights", - "children": [ - { - "type": "text", - "text": "https://www.service-public.fr/a-propos/mentions-legales" - } - ] - }, - { - "type": "element", - "name": "SurTitre", - "children": [ - { - "type": "text", - "text": "Fiche pratique" - } - ] - }, - { - "type": "element", - "name": "Audience", - "children": [ - { - "type": "text", - "text": "Particuliers" - } - ] - }, - { - "type": "element", - "name": "Canal", - "children": [ - { - "type": "text", - "text": "www.service-public.fr" - } - ] - }, - { - "type": "element", - "name": "FilDAriane", - "children": [ - { - "type": "element", - "name": "Niveau", - "attributes": { - "ID": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Accueil particuliers" - } - ] - }, - { - "type": "element", - "name": "Niveau", - "attributes": { - "ID": "N19806" - }, - "children": [ - { - "type": "text", - "text": "Travail" - } - ] - }, - { - "type": "element", - "name": "Niveau", - "attributes": { - "ID": "N19611" - }, - "children": [ - { - "type": "text", - "text": "Rupture du contrat dans le secteur privé (démission, rupture conventionnelle...)" - } - ] - }, - { - "type": "element", - "name": "Niveau", - "attributes": { - "ID": "F2883", - "type": "Fiche d'information" - }, - "children": [ - { - "type": "text", - "text": "Démission d'un salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Theme", - "attributes": { - "ID": "N19806" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Travail" - } - ] - } - ] - }, - { - "type": "element", - "name": "SousThemePere", - "attributes": { - "ID": "N19967" - }, - "children": [ - { - "type": "text", - "text": "Quitter son emploi" - } - ] - }, - { - "type": "element", - "name": "DossierPere", - "attributes": { - "ID": "N19611" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Rupture du contrat dans le secteur privé (démission, rupture conventionnelle...)" - } - ] - }, - { - "type": "element", - "name": "SousDossier", - "attributes": { - "ID": "N19611-1" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Formes de rupture" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F2883" - }, - "children": [ - { - "type": "text", - "text": "Démission" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F19030" - }, - "children": [ - { - "type": "text", - "text": "Rupture conventionnelle" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F24409" - }, - "children": [ - { - "type": "text", - "text": "Prise d'acte" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F24410" - }, - "children": [ - { - "type": "text", - "text": "Résiliation judiciaire" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F24411" - }, - "children": [ - { - "type": "text", - "text": "Départ négocié (difficultés économiques)" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F24412" - }, - "children": [ - { - "type": "text", - "text": "Rupture pour cas de force majeure" - } - ] - } - ] - }, - { - "type": "element", - "name": "SousDossier", - "attributes": { - "ID": "N19611-2" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Documents à remettre au salarié" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F87" - }, - "children": [ - { - "type": "text", - "text": "Certificat de travail" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F2867" - }, - "children": [ - { - "type": "text", - "text": "Attestation destinée à Pôle emploi" - } - ] - }, - { - "type": "element", - "name": "Fiche", - "attributes": { - "ID": "F86" - }, - "children": [ - { - "type": "text", - "text": "Solde de tout compte" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousDossierPere", - "children": [ - { - "type": "text", - "text": "Formes de rupture" - } - ] - }, - { - "type": "element", - "name": "Introduction", - "children": [ - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n La démission vous permet de rompre votre contrat de travail de votre propre initiative. Cependant, pour être valable, elle doit respecter certaines conditions. Vous devez prévenir votre employeur de votre volonté de démissionner. Sauf en cas de dispense, vous poursuivez votre activité jusqu'au terme du préavis de démission. Des dispositions spécifiques de rupture anticipée du contrat de travail sont prévues selon votre situation au moment de votre démission (\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "R24389", - "type": "Sigle" - }, - "children": [ - { - "type": "text", - "text": "CDI" - } - ] - }, - { - "type": "text", - "text": "\n ,\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "R2454", - "type": "Sigle" - }, - "children": [ - { - "type": "text", - "text": "CDD" - } - ] - }, - { - "type": "text", - "text": "\n ou intérim).\n " - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "ListeSituations", - "attributes": { - "affichage": "onglet" - }, - "children": [ - { - "type": "element", - "name": "Situation", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "CDI" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "De quoi s'agit-il ?" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "La démission est un mode de rupture du contrat de travail qui vous permet de quitter votre entreprise sans avoir à justifier cette décision." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Ce droit peut être exercé à tout moment, même si le contrat de travail est\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R43526", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "suspendu" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Conditions" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Le salarié peut mettre fin à son contrat de travail dans les cas suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Dans le cadre d'une rupture volontaire du contrat de travail par le salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Pendant la\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1643", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "période d'essai" - } - ] - }, - { - "type": "text", - "text": "\n sans motif particulier\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n En cas de\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F13941", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "départ volontaire à la retraite" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Dans le cadre d'une\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24410", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "résiliation judiciaire" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Dans le cadre d'une\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24409", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "prise d'acte" - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Volonté de démissionner" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Pour qu'une démission soit valable, vous devez manifester de façon claire et non équivoque votre volonté de mettre fin au contrat de travail." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Une absence injustifiée ou un\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F31209", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "abandon de poste" - } - ] - }, - { - "type": "text", - "text": "\n ne peuvent pas être considérés comme une démission.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n En cas d'ambiguïté sur votre volonté claire et non équivoque, le conseil de prud'hommes peut requalifier la démission en\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1848", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "licenciement injustifié (ou sans cause réelle et sérieuse)" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Dans certains cas, vous pouvez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F131", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "revenir sur votre démission" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n La démission ne doit pas être abusive, c'est-à-dire prise avec l'intention de nuire à l'employeur. Sinon, vous pouvez être condamné(e) au versement de\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R12532", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "dommages et intérêts" - } - ] - }, - { - "type": "text", - "text": "\n à l'employeur.\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Procédure" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Pour manifester votre volonté claire et non équivoque de démissionner, vous devez nécessairement prévenir votre employeur." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Il n'y a pas de procédure légale imposée pour signifier une démission. Vous pouvez prévenir votre employeur par oral ou par écrit, en lui adressant une lettre de démission." - } - ] - }, - { - "type": "element", - "name": "ServiceEnLigne", - "attributes": { - "ID": "R32161", - "URL": "https://www.service-public.fr/simulateur/calcul/Demission", - "type": "Modèle de document" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Lettre de démission du salarié" - } - ] - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30608" - }, - "children": [ - { - "type": "text", - "text": "Direction de l'information légale et administrative (Premier ministre)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Des\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R51533", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "dispositions conventionnelles" - } - ] - }, - { - "type": "text", - "text": "\n peuvent imposer l'envoi de la lettre de démission par lettre recommandée avec\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "R46090", - "type": "Acronyme" - }, - "children": [ - { - "type": "text", - "text": "RAR" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous ne pouvez pas quitter votre travail dès que vous avez signifié votre démission à votre employeur. Vous continuez de travailler jusqu'à la fin de votre contrat de travail, dans le respect du délai de préavis prévu (sauf en cas de dispense du préavis)." - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée" - } - ] - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "onglet" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Cas général" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "La durée du préavis de démission est fixée :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Soit par convention collective ou accord collectif" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Soit par les\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R12729", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "usages" - } - ] - }, - { - "type": "text", - "text": "\n pratiqués dans la localité et dans la profession\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Soit par le droit local (en Alsace-Moselle)" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Votre contrat de travail peut prévoir un préavis de démission, qui s'applique si sa durée est plus courte que celle prévue par la convention collective, l'accord collectif ou les usages." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si vous travaillez à temps partiel, la durée calendaire du préavis de démission est la même que celle d'un salarié à temps plein." - } - ] - }, - { - "type": "element", - "name": "ASavoir", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "À savoir" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "le préavis commence à courir à compter de la notification à l'employeur de votre démission." - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Journaliste" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si vous êtes journaliste, vous devez respecter un délai de préavis fixé en fonction de votre ancienneté, dans les conditions suivantes :" - } - ] - }, - { - "type": "element", - "name": "Tableau", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Durée minimale du préavis en fonction de l'ancienneté du salarié" - } - ] - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "50", - "type": "normal" - } - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "50", - "type": "normal" - } - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "header" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Ancienneté du salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée minimale du préavis" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "3 ans maximum" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1 mois" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Plus de 3 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "2 mois" - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "VRP" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si vous êtes\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "R34931", - "type": "Sigle" - }, - "children": [ - { - "type": "text", - "text": "VRP" - } - ] - }, - { - "type": "text", - "text": "\n , vous devez respecter un délai de préavis fixé en fonction de votre ancienneté, dans les conditions suivantes :\n " - } - ] - }, - { - "type": "element", - "name": "Tableau", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Durée minimale du préavis en fonction de l'ancienneté du salarié" - } - ] - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "50", - "type": "normal" - } - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "50", - "type": "normal" - } - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "header" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Ancienneté du salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée minimale du préavis" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Moins de 1 an" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1 mois" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Entre 1 an et 2 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "2 mois" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Plus de 2 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "3 mois" - } - ] - } - ] - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Dispense de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous n'êtes pas tenu(e) d'effectuer de préavis dans les cas suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Démission\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1730", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "pendant la grossesse ou pour élever un enfant" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Démission à l'issue d'un\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2382", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "congé pour création d'entreprise" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "En dehors de ces deux cas, vous pouvez être dispensé d'effectuer votre préavis, de votre propre initiative ou à la demande de votre employeur, dans les conditions suivantes :" - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "onglet" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous demandez une dispense de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous pouvez demander à votre employeur de vous dispenser d'effectuer votre préavis (par écrit ou par oral) :" - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "radio" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Accord de l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si votre employeur accepte, votre contrat de travail prend fin à la date convenue entre vous. Dans ce cas, l'employeur n'est pas tenu de verser\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "l'indemnité compensatrice" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Refus de l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si votre employeur refuse, vous devez effectuer votre préavis, sous peine de devoir lui verser une indemnité d'un montant égal à la rémunération brute que vous auriez perçue si vous aviez travaillé." - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Votre employeur vous dispense de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n L'employeur peut vous imposer de ne pas effectuer votre préavis. Dans ce cas, vous conservez les avantages que vous auriez perçus si vous aviez travaillé jusqu'à l'expiration du préavis et percevez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "l'indemnité compensatrice de préavis" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Report ou suspension du préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Le préavis peut être reporté ou suspendu dans les cas suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Accord entre le salarié et l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Prise de\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2930", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "congés payés" - } - ] - }, - { - "type": "text", - "text": "\n dont la date a été fixée avant la notification de la rupture\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2614", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Arrêt de travail" - } - ] - }, - { - "type": "text", - "text": "\n survenant en cours de préavis et lié à un accident du travail ou une maladie professionnelle\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R51533", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "Dispositions conventionnelles" - } - ] - }, - { - "type": "text", - "text": "\n le prévoyant\n " - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Absence pour recherche d'emploi" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Il n'existe aucune disposition légale vous permettant de vous\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1054", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "absenter" - } - ] - }, - { - "type": "text", - "text": "\n pour rechercher un emploi.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Toutefois, des dispositions conventionnelles ou, à défaut, un usage dans la localité ou la profession peuvent prévoir des temps d'absence pour rechercher un emploi pendant la durée du préavis." - } - ] - } - ] - }, - { - "type": "element", - "name": "OuSAdresser", - "attributes": { - "ID": "R17689", - "sve": "non", - "type": "Centre de contact" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Agessa et Maison des artistes - Sécurité sociale" - } - ] - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R62649" - }, - "children": [ - { - "type": "text", - "text": "Agessa - Sécurité sociale des artistes auteurs" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Par téléphone" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Du lundi au vendredi : de 9h à 17h" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "0 806 804 208 (prix d'un appel local)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Par messagerie" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "http://www.secu-artistes-auteurs.fr/contact" - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Par courrier" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "60 rue du Faubourg Poissonnière" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "75010 Paris" - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Indemnisation" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Indemnité compensatrice de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si vous êtes dispensé(e) d'effectuer votre préavis par votre employeur, vous avez droit au versement d'une\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "indemnité compensatrice de préavis" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Indemnité compensatrice de congés payés" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Vous avez droit à une\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24661", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "indemnité compensatrice de congés payés" - } - ] - }, - { - "type": "text", - "text": "\n si vous n'avez pas pu prendre la totalité des congés acquis avant la date de rupture de votre contrat.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Complémentaire santé" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Certains motifs de démission ouvrent droit au versement des\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F89", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "allocations chômage" - } - ] - }, - { - "type": "text", - "text": "\n . Si c'est votre cas, vous continuez à bénéficier de la couverture santé que vous avez souscrite dans le cadre de votre ancien travail, sous\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F20744", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "certaines conditions" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Épargne salariale" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si vous bénéficiez d'un dispositif d'épargne salariale, vous pouvez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F31622", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "demander le déblocage anticipé" - } - ] - }, - { - "type": "text", - "text": "\n des sommes.\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Documents remis au salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "L'employeur doit remettre au salarié les documents suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F87", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Certificat de travail" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2867", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Attestation Pôle emploi" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F86", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Solde de tout compte" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "En cas de dispositifs de participation, d'intéressement et des plans d'épargne salariale au sein de l'entreprise, état récapitulatif de l'ensemble des sommes et valeurs mobilières épargnées" - } - ] - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Situation", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "CDD" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "De quoi s'agit-il ?" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "La démission est un mode de rupture du contrat de travail qui vous permet de quitter votre entreprise sans avoir à justifier cette décision." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Ce droit peut être exercé sous conditions." - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Conditions" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Le salarié peut mettre fin à son contrat de travail pendant la\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1643", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "période d'essai" - } - ] - }, - { - "type": "text", - "text": "\n sans motif particulier.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n En dehors de la période d'essai, le CDD peut être rompu avant le terme prévu\n " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "uniquement dans les cas suivants" - } - ] - }, - { - "type": "text", - "text": "\n :\n " - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Accord entre l'employeur et le salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Demande du salarié qui justifie d'une embauche en contrat à durée indéterminée (CDI). Pour éviter toute difficulté, le salarié peut notifier par écrit la rupture du contrat et fournir le justificatif de l'embauche prévue (promesse d'embauche ou contrat de travail, par exemple)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24412", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Force majeure" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1729", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Inaptitude" - } - ] - }, - { - "type": "text", - "text": "\n constatée par le médecin du travail\n " - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Attention", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Attention" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n s'il s'agit d'un\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2406", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "salarié protégé" - } - ] - }, - { - "type": "text", - "text": "\n , la rupture du contrat ne peut intervenir qu'après autorisation de l'inspecteur du travail.\n " - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Volonté de démissionner" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Pour qu'une démission soit valable, vous devez manifester de façon claire et non équivoque votre volonté de mettre fin au contrat de travail." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Une absence injustifiée ou un\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F31209", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "abandon de poste" - } - ] - }, - { - "type": "text", - "text": "\n ne peuvent pas être considérés comme une démission.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n En cas d'ambiguïté sur votre volonté claire et non équivoque, le conseil de prud'hommes peut requalifier la démission en\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1848", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "licenciement injustifié (ou sans cause réelle et sérieuse)" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Dans certains cas, vous pouvez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F131", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "revenir sur votre démission" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n La démission ne doit pas être abusive, c'est-à-dire prise avec l'intention de nuire à l'employeur. Sinon, vous pouvez être condamné(e) au versement de\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R12532", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "dommages et intérêts" - } - ] - }, - { - "type": "text", - "text": "\n à l'employeur.\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Procédure" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Pour manifester votre volonté claire et non équivoque de démissionner, vous devez nécessairement prévenir votre employeur." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Il n'y a pas de procédure légale imposée pour signifier une démission. Vous pouvez prévenir votre employeur par oral ou par écrit, en lui adressant une lettre de démission." - } - ] - }, - { - "type": "element", - "name": "ServiceEnLigne", - "attributes": { - "ID": "R32161", - "URL": "https://www.service-public.fr/simulateur/calcul/Demission", - "type": "Modèle de document" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Lettre de démission du salarié" - } - ] - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30608" - }, - "children": [ - { - "type": "text", - "text": "Direction de l'information légale et administrative (Premier ministre)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Des\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R51533", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "dispositions conventionnelles" - } - ] - }, - { - "type": "text", - "text": "\n peuvent imposer l'envoi de la lettre de démission par lettre recommandée avec\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "R46090", - "type": "Acronyme" - }, - "children": [ - { - "type": "text", - "text": "RAR" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous ne pouvez pas quitter votre travail dès que vous avez signifié votre démission à votre employeur. Vous continuez de travailler jusqu'à la fin de votre contrat de travail, dans le respect du délai de préavis prévu (sauf en cas de dispense du préavis)." - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée" - } - ] - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "onglet" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Cas général" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "La durée du préavis de démission est fixée :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Soit par convention collective ou accord collectif" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Soit par les\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R12729", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "usages" - } - ] - }, - { - "type": "text", - "text": "\n pratiqués dans la localité et dans la profession\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Soit par le droit local (en Alsace-Moselle)" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Votre contrat de travail peut prévoir un préavis de démission, qui s'applique si sa durée est plus courte que celle prévue par la convention collective, l'accord collectif ou les usages." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si vous travaillez à temps partiel, la durée calendaire du préavis de démission est la même que celle d'un salarié à temps plein." - } - ] - }, - { - "type": "element", - "name": "ASavoir", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "À savoir" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "le préavis commence à courir à compter de la notification à l'employeur de votre démission." - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Journaliste" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si vous êtes journaliste, vous devez respecter un délai de préavis fixé en fonction de votre ancienneté, dans les conditions suivantes :" - } - ] - }, - { - "type": "element", - "name": "Tableau", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Durée minimale du préavis en fonction de l'ancienneté du salarié" - } - ] - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "50", - "type": "normal" - } - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "50", - "type": "normal" - } - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "header" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Ancienneté du salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée minimale du préavis" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "3 ans maximum" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1 mois" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Plus de 3 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "2 mois" - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "VRP" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si vous êtes\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "R34931", - "type": "Sigle" - }, - "children": [ - { - "type": "text", - "text": "VRP" - } - ] - }, - { - "type": "text", - "text": "\n , vous devez respecter un délai de préavis fixé en fonction de votre ancienneté, dans les conditions suivantes :\n " - } - ] - }, - { - "type": "element", - "name": "Tableau", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Durée minimale du préavis en fonction de l'ancienneté du salarié" - } - ] - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "50", - "type": "normal" - } - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "50", - "type": "normal" - } - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "header" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Ancienneté du salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée minimale du préavis" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Moins de 1 an" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1 mois" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Entre 1 an et 2 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "2 mois" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Plus de 2 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "3 mois" - } - ] - } - ] - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Dispense de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous n'êtes pas tenu(e) d'effectuer de préavis dans les cas suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Démission\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1730", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "pendant la grossesse ou pour élever un enfant" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Démission à l'issue d'un\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2382", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "congé pour création d'entreprise" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "En dehors de ces deux cas, vous pouvez être dispensé d'effectuer votre préavis, de votre propre initiative ou à la demande de votre employeur, dans les conditions suivantes :" - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "onglet" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous demandez une dispense de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous pouvez demander à votre employeur de vous dispenser d'effectuer votre préavis (par écrit ou par oral) :" - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "radio" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Accord de l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si votre employeur accepte, votre contrat de travail prend fin à la date convenue entre vous. Dans ce cas, l'employeur n'est pas tenu de verser\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "l'indemnité compensatrice" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Refus de l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si votre employeur refuse, vous devez effectuer votre préavis, sous peine de devoir lui verser une indemnité d'un montant égal à la rémunération brute que vous auriez perçue si vous aviez travaillé." - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Votre employeur vous dispense de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n L'employeur peut vous imposer de ne pas effectuer votre préavis. Dans ce cas, vous conservez les avantages que vous auriez perçus si vous aviez travaillé jusqu'à l'expiration du préavis et percevez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "l'indemnité compensatrice de préavis" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Report ou suspension du préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Le préavis peut être reporté ou suspendu dans les cas suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Accord entre le salarié et l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Prise de\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2930", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "congés payés" - } - ] - }, - { - "type": "text", - "text": "\n dont la date a été fixée avant la notification de la rupture\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2614", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Arrêt de travail" - } - ] - }, - { - "type": "text", - "text": "\n survenant en cours de préavis et lié à un accident du travail ou une maladie professionnelle\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R51533", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "Dispositions conventionnelles" - } - ] - }, - { - "type": "text", - "text": "\n le prévoyant\n " - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Absence pour recherche d'emploi" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Il n'existe aucune disposition légale vous permettant de vous\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1054", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "absenter" - } - ] - }, - { - "type": "text", - "text": "\n pour rechercher un emploi.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Toutefois, des dispositions conventionnelles ou, à défaut, un usage dans la localité ou la profession peuvent prévoir des temps d'absence pour rechercher un emploi pendant la durée du préavis." - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Indemnisation" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Indemnité compensatrice de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si vous êtes dispensé(e) d'effectuer votre préavis par votre employeur, vous avez droit au versement d'une\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "indemnité compensatrice de préavis" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Indemnité compensatrice de congés payés" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Vous avez droit à une\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24661", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "indemnité compensatrice de congés payés" - } - ] - }, - { - "type": "text", - "text": "\n si vous n'avez pas pu prendre la totalité des congés acquis avant la date de rupture de votre contrat.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Complémentaire santé" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Certains motifs de démission ouvrent droit au versement des\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F89", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "allocations chômage" - } - ] - }, - { - "type": "text", - "text": "\n . Si c'est votre cas, vous continuez à bénéficier de la couverture santé que vous avez souscrite dans le cadre de votre ancien travail, sous\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F20744", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "certaines conditions" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Épargne salariale" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si vous bénéficiez d'un dispositif d'épargne salariale, vous pouvez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F31622", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "demander le déblocage anticipé" - } - ] - }, - { - "type": "text", - "text": "\n des sommes.\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Documents remis au salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "L'employeur doit remettre au salarié les documents suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F87", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Certificat de travail" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2867", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Attestation Pôle emploi" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F86", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Solde de tout compte" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "En cas de dispositifs de participation, d'intéressement et des plans d'épargne salariale au sein de l'entreprise, état récapitulatif de l'ensemble des sommes et valeurs mobilières épargnées" - } - ] - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Situation", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Contrat de travail temporaire (intérim)" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "De quoi s'agit-il ?" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "La démission est un mode de rupture du contrat de travail qui vous permet de quitter votre entreprise sans avoir à justifier cette décision." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Ce droit peut être exercé sous conditions." - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Conditions" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Le contrat de mission peut être rompu de manière anticipée par le salarié dans les cas suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Pendant la\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1643", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "période d'essai" - } - ] - }, - { - "type": "text", - "text": "\n sans motif particulier\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Embauche du salarié mis à disposition pour un contrat à durée indéterminée" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24412", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Force majeure" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "ANoter", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "À noter" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "si le salarié rompt le contrat après la période d'essai et en dehors des cas autorisés, il peut être condamné par le juge à verser à son employeur des dommages et intérêts." - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Volonté de démissionner" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Pour qu'une démission soit valable, vous devez manifester de façon claire et non équivoque votre volonté de mettre fin au contrat de travail." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Une absence injustifiée ou un\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F31209", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "abandon de poste" - } - ] - }, - { - "type": "text", - "text": "\n ne peuvent pas être considérés comme une démission.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n En cas d'ambiguïté sur votre volonté claire et non équivoque, le conseil de prud'hommes peut requalifier la démission en\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1848", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "licenciement injustifié (ou sans cause réelle et sérieuse)" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Dans certains cas, vous pouvez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F131", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "revenir sur votre démission" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n La démission ne doit pas être abusive, c'est-à-dire prise avec l'intention de nuire à l'employeur. Sinon, vous pouvez être condamné(e) au versement de\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R12532", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "dommages et intérêts" - } - ] - }, - { - "type": "text", - "text": "\n à l'employeur.\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Procédure" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Pour manifester votre volonté claire et non équivoque de démissionner, vous devez nécessairement prévenir votre employeur." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Il n'y a pas de procédure légale imposée pour signifier une démission. Vous pouvez prévenir votre employeur par oral ou par écrit, en lui adressant une lettre de démission." - } - ] - }, - { - "type": "element", - "name": "ServiceEnLigne", - "attributes": { - "ID": "R32161", - "URL": "https://www.service-public.fr/simulateur/calcul/Demission", - "type": "Modèle de document" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Lettre de démission du salarié" - } - ] - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30608" - }, - "children": [ - { - "type": "text", - "text": "Direction de l'information légale et administrative (Premier ministre)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Des\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R51533", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "dispositions conventionnelles" - } - ] - }, - { - "type": "text", - "text": "\n peuvent imposer l'envoi de la lettre de démission par lettre recommandée avec\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "R46090", - "type": "Acronyme" - }, - "children": [ - { - "type": "text", - "text": "RAR" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous ne pouvez pas quitter votre travail dès que vous avez signifié votre démission à votre employeur. Vous continuez de travailler jusqu'à la fin de votre contrat de travail, dans le respect du délai de préavis prévu (sauf en cas de dispense du préavis)." - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Un préavis s'applique si le salarié rompt son contrat pour un contrat à durée indéterminée (CDI) après la\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F32279", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "période d'essai" - } - ] - }, - { - "type": "text", - "text": "\n (sauf s'il en est dispensé par l'employeur).\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Ce préavis est calculé à raison d'un jour par semaine, compte tenu de :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "La durée du contrat, renouvellement inclus, si celui-ci comporte un terme précis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "La durée effectuée, si le contrat ne comporte pas de terme précis" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "La durée totale du préavis ne peut pas être inférieure à 1 jour, ni supérieure à 2 semaines." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Le décompte s'effectue en\n " - }, - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R17509", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "jours ouvrés" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Dispense du préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "onglet" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous demandez une dispense de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Vous pouvez demander à votre employeur de vous dispenser d'effectuer votre préavis (par écrit ou par oral) :" - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "radio" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Accord de l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si votre employeur accepte, votre contrat de travail prend fin à la date convenue entre vous. Dans ce cas, l'employeur n'est pas tenu de verser\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "l'indemnité compensatrice" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Refus de l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si votre employeur refuse, vous devez effectuer votre préavis, sous peine de devoir lui verser une indemnité d'un montant égal à la rémunération brute que vous auriez perçue si vous aviez travaillé." - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Votre employeur vous dispense de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n L'employeur peut vous imposer de ne pas effectuer votre préavis. Dans ce cas, vous conservez les avantages que vous auriez perçus si vous aviez travaillé jusqu'à l'expiration du préavis et percevez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "l'indemnité compensatrice de préavis" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Report ou suspension du préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Le préavis peut être reporté ou suspendu dans les cas suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Accord entre le salarié et l'employeur" - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Prise de\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2930", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "congés payés" - } - ] - }, - { - "type": "text", - "text": "\n dont la date a été fixée avant la notification de la rupture\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2614", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Arrêt de travail" - } - ] - }, - { - "type": "text", - "text": "\n survenant en cours de préavis et lié à un accident du travail ou une maladie professionnelle\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienIntra", - "attributes": { - "LienID": "R51533", - "type": "Définition de glossaire" - }, - "children": [ - { - "type": "text", - "text": "Dispositions conventionnelles" - } - ] - }, - { - "type": "text", - "text": "\n le prévoyant\n " - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "SousChapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Absence pour recherche d'emploi" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Il n'existe aucune disposition légale vous permettant de vous\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F1054", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "absenter" - } - ] - }, - { - "type": "text", - "text": "\n pour rechercher un emploi.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Toutefois, des dispositions conventionnelles ou, à défaut, un usage dans la localité ou la profession peuvent prévoir des temps d'absence pour rechercher un emploi pendant la durée du préavis." - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Indemnisation" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Indemnité compensatrice de préavis" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si vous êtes dispensé(e) d'effectuer votre préavis par votre employeur, vous avez droit au versement d'une\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24660", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "indemnité compensatrice de préavis" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Indemnité compensatrice de congés payés" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Vous avez droit à une\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F24661", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "indemnité compensatrice de congés payés" - } - ] - }, - { - "type": "text", - "text": "\n si vous n'avez pas pu prendre la totalité des congés acquis avant la date de rupture de votre contrat.\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Complémentaire santé" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Certains motifs de démission ouvrent droit au versement des\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F89", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "allocations chômage" - } - ] - }, - { - "type": "text", - "text": "\n . Si c'est votre cas, vous continuez à bénéficier de la couverture santé que vous avez souscrite dans le cadre de votre ancien travail, sous\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F20744", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "certaines conditions" - } - ] - }, - { - "type": "text", - "text": "\n .\n " - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "Épargne salariale" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "\n Si vous bénéficiez d'un dispositif d'épargne salariale, vous pouvez\n " - }, - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F31622", - "type": "Fiche Question-réponse", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "demander le déblocage anticipé" - } - ] - }, - { - "type": "text", - "text": "\n des sommes.\n " - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Documents remis au salarié" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "L'employeur doit remettre au salarié les documents suivants :" - } - ] - }, - { - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F87", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Certificat de travail" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F2867", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Attestation Pôle emploi" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "LienInterne", - "attributes": { - "LienPublication": "F86", - "type": "Fiche d'information", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Solde de tout compte" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "En cas de dispositifs de participation, d'intéressement et des plans d'épargne salariale au sein de l'entreprise, état récapitulatif de l'ensemble des sommes et valeurs mobilières épargnées" - } - ] - } - ] - } - ] - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Reference", - "attributes": { - "type": "Texte de référence", - "URL": "http://www.legifrance.gouv.fr/affichCodeArticle.do?idArticle=LEGIARTI000019071194&cidTexte=LEGITEXT000006072050", - "ID": "R33873" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Code du travail : article L1231-1" - } - ] - }, - { - "type": "element", - "name": "Complement", - "children": [ - { - "type": "text", - "text": "Salariés concernés" - } - ] - } - ] - }, - { - "type": "element", - "name": "Reference", - "attributes": { - "type": "Texte de référence", - "URL": "http://www.legifrance.gouv.fr/affichCodeArticle.do?idArticle=LEGIARTI000006901174&cidTexte=LEGITEXT000006072050", - "ID": "R33874" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Code du travail : article L1237-1" - } - ] - }, - { - "type": "element", - "name": "Complement", - "children": [ - { - "type": "text", - "text": "Préavis (cas général)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Reference", - "attributes": { - "type": "Texte de référence", - "URL": "http://legifrance.gouv.fr/affichCodeArticle.do?idArticle=LEGIARTI000018764983&cidTexte=LEGITEXT000006072050", - "ID": "R34928" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Code du travail : article L7112-2" - } - ] - }, - { - "type": "element", - "name": "Complement", - "children": [ - { - "type": "text", - "text": "Préavis (journalistes)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Reference", - "attributes": { - "type": "Texte de référence", - "URL": "http://legifrance.gouv.fr/affichCodeArticle.do?idArticle=LEGIARTI000006904729&cidTexte=LEGITEXT000006072050", - "ID": "R34929" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Code du travail : article L7313-9" - } - ] - }, - { - "type": "element", - "name": "Complement", - "children": [ - { - "type": "text", - "text": "Préavis (VRP)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Reference", - "attributes": { - "type": "Texte de référence", - "URL": "http://www.legifrance.gouv.fr/affichCode.do?idSectionTA=LEGISCTA000006195635&cidTexte=LEGITEXT000006072050", - "ID": "R33875" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Code du travail : articles L1237-2 et L1237-3" - } - ] - }, - { - "type": "element", - "name": "Complement", - "children": [ - { - "type": "text", - "text": "Démission abusive" - } - ] - } - ] - }, - { - "type": "element", - "name": "ServiceEnLigne", - "attributes": { - "ID": "R32161", - "URL": "https://www.service-public.fr/simulateur/calcul/Demission", - "type": "Modèle de document" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Lettre de démission du salarié" - } - ] - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30608" - }, - "children": [ - { - "type": "text", - "text": "Direction de l'information légale et administrative (Premier ministre)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Definition", - "attributes": { - "ID": "R51533" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Dispositions conventionnelles" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Convention collective, accord collectif, accord de branche, d'entreprise ou d'établissement applicables en droit du travail. Elles fixent les obligations et les droits de l'employeur et du salarié." - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Definition", - "attributes": { - "ID": "R17509" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Jour ouvré" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Jour effectivement travaillé dans une entreprise ou une administration.\n\t\tOn en compte 5 par semaine." - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Definition", - "attributes": { - "ID": "R43526" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Suspension d'un contrat de travail" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Le contrat de travail est suspendu dans les cas suivants : exercice du droit de grève, fonction de juré d'assise, maladie ou accident du travail, congé de maternité, de paternité, d'adoption ou parental, congé pour création ou reprise d'entreprise, congé pour exercer un mandat, congé sabbatique, fermeture temporaire de l'entreprise (chômage technique), mise à pied, mobilité volontaire sécurisée." - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Definition", - "attributes": { - "ID": "R12729" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Usage professionnel ou usage local (droit du travail)" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Pratique d'application générale, constante et fixe au sein d'une profession ou d'une localité et à l'origine d'une règle non écrite s'imposant à l'employeur vis-à-vis du salarié" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Definition", - "attributes": { - "ID": "R12532" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Dommages et intérêts" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Somme d'argent destinée à réparer le préjudice subi" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Abreviation", - "attributes": { - "ID": "R2454", - "type": "Sigle" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "CDD" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Contrat à durée déterminée" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Abreviation", - "attributes": { - "ID": "R24389", - "type": "Sigle" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "CDI" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Contrat de travail à durée indéterminée" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Abreviation", - "attributes": { - "ID": "R46090", - "type": "Acronyme" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "RAR" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Recommandé avec accusé de réception" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Abreviation", - "attributes": { - "ID": "R34931", - "type": "Sigle" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "VRP" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Voyageur représentant placier" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "QuestionReponse", - "attributes": { - "ID": "F12598", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Peut-on démissionner pendant ses congés payés ?" - } - ] - }, - { - "type": "element", - "name": "QuestionReponse", - "attributes": { - "ID": "F540", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Peut-on démissionner pendant un congé parental ?" - } - ] - }, - { - "type": "element", - "name": "QuestionReponse", - "attributes": { - "ID": "F31679", - "audience": "Particuliers" - }, - "children": [ - { - "type": "text", - "text": "Peut-on démissionner pendant un arrêt maladie ?" - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/Accordion.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/Accordion.js deleted file mode 100644 index f66e722c17..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/Accordion.js +++ /dev/null @@ -1,85 +0,0 @@ -import { theme } from "@socialgouv/cdtn-ui"; -import PropTypes from "prop-types"; -import React from "react"; -import styled from "styled-components"; -import { AccordionWithAnchor as Accordion } from "../../../src/common/AccordionWithAnchor"; - -import { getText } from "../utils.js"; -import { ElementBuilder } from "./ElementBuilder.js"; - -const { spacings } = theme; - -const isItemOfAccordion = (element) => - (element.name === "Chapitre" || element.name === "Cas") && - element.children && - element.children.find((child) => child.name === "Titre"); - -class AccordionWrapper extends React.PureComponent { - render() { - const { data, headingLevel } = this.props; - const firstIndexOfAccordionItem = - data.children.findIndex(isItemOfAccordion); - const accordionItems = data.children - .filter(isItemOfAccordion) - .map((accordionItem) => { - const title = getText( - accordionItem.children.find((child) => child.name === "Titre") - ); - const body = ( - child.name !== "Titre" - )} - headingLevel={headingLevel + 1} - /> - ); - return { - body, - title, - }; - }); - - const beforeAccordionElements = data.children - .slice(0, firstIndexOfAccordionItem) - .map((element, index) => ( - - )); - - const afterAccordionElements = data.children - .slice(firstIndexOfAccordionItem + accordionItems.length) - .map((element, index) => ( - - )); - return ( - <> - {beforeAccordionElements} - {accordionItems.length > 0 && ( - - )} - {afterAccordionElements} - - ); - } -} - -AccordionWrapper.propTypes = { - data: PropTypes.object.isRequired, - headingLevel: PropTypes.number.isRequired, -}; - -export default AccordionWrapper; - -const StyledAccordion = styled(Accordion)` - margin-bottom: ${spacings.large}; -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/ElementBuilder.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/ElementBuilder.js deleted file mode 100644 index 9936f570ab..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/ElementBuilder.js +++ /dev/null @@ -1,169 +0,0 @@ -import { theme, Wrapper } from "@socialgouv/cdtn-ui"; -import PropTypes from "prop-types"; -import React from "react"; -import { useUIDSeed } from "react-uid"; -import styled from "styled-components"; - -import { getText, ignoreParagraph } from "../utils.js"; -import Accordion from "./Accordion.js"; -import { LienExterne, LienExterneCommente } from "./LienExterne.js"; -import List from "./List.js"; -import OuSAdresser from "./OuSAdresser.js"; -import ServiceEnLigne from "./ServiceEnLigne.js"; -import Table from "./Table.js"; -import Tabulator from "./Tabulator.js"; -import Title from "./Title.js"; -import { Image as ImageElement } from "./Image"; - -const { spacings } = theme; - -// Beware, this one is recursive -// parentAttributes only purpose for now is to pass a date to the title element -// from the parent level (Avertissement element), we might remove it later -export function ElementBuilder({ data, headingLevel, parentAttributes }) { - const seedId = useUIDSeed(); - // in cases where the parent's "$"/children is undefined while it should not - // e.g. in a "Texte" element. It occurs sometimes. - if (!data) return null; - // In case we get children - if (Array.isArray(data)) { - return data.map((child) => ( - - )); - } - if (data.type === "text") { - return data.text; - } - - switch (data.name) { - // Complex elements, we don't immediately parse their children - case "BlocCas": - if (data.attributes.affichage === "onglet") { - return ; - } else { - return ; - } - case "Image": - return ; - case "Introduction": - if (ignoreParagraph(data)) { - return ( - - - - ); - } - break; - case "LienExterne": - return ; - case "LienExterneCommente": - return ; - case "Liste": - return ; - case "ListeSituations": - return ; - case "OuSAdresser": - return ; - case "ServiceEnLigne": - case "PourEnSavoirPlus": - return ; - case "Tableau": - return ; - case "Texte": - if (data.children.find((child) => child.name === "Chapitre")) { - return ; - } - return ( - - ); - case "Titre": - case "TitreFlottant": - return ( - - {getText(data)} - - ); - // "Simple" elements, we can immediately parse their children - case "ANoter": - case "Exemple": - case "ASavoir": - case "Attention": - case "Avertissement": - case "Rappel": - return ( - - - - ); - case "Chapitre": - case "Description": - case "FragmentConditionne": - case "SousChapitre": - case "Complement": - return ( - - ); - case "Expression": - return ( - - - - ); - case "MiseEnEvidence": - case "Valeur": - return ( - - - - ); - case "Paragraphe": - return ( -

- -

- ); - case "Exposant": - return ( - - - - ); - // These ones are still to be defined - case "LienIntra": - case "LienInterne": - return ( - - ); - // Otherwise we simply ignore the element - default: - return null; - } -} - -ElementBuilder.propTypes = { - data: PropTypes.oneOfType([PropTypes.object, PropTypes.array]), - headingLevel: PropTypes.number, - parentAttributes: PropTypes.object, -}; - -ElementBuilder.defaultProps = { - headingLevel: 0, - parentAttributes: {}, -}; - -const ANoter = styled(Wrapper)` - margin-bottom: ${spacings.base}; -`; - -const Introduction = styled.p` - margin-bottom: ${spacings.large}; -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/Fiche.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/Fiche.js deleted file mode 100644 index 455c244db6..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/Fiche.js +++ /dev/null @@ -1,23 +0,0 @@ -import React from "react"; -import styled from "styled-components"; - -import { ElementBuilder } from "./ElementBuilder.js"; - -export class FicheServicePublic extends React.PureComponent { - render() { - return ( -
- -
- ); - } -} - -const Div = styled.div` - & > *:first-child { - margin-top: 0; - } - & > *:last-child { - margin-bottom: 0; - } -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/Image.tsx b/packages/code-du-travail-frontend/src/fiche-service-public/components/Image.tsx deleted file mode 100644 index ab64d0660f..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/Image.tsx +++ /dev/null @@ -1,69 +0,0 @@ -import React, { memo } from "react"; - -import { getText, ignoreParagraph } from "../utils.js"; -import { ElementBuilder } from "./ElementBuilder"; -import { MoreContent, Wrapper } from "@socialgouv/cdtn-ui"; -import styled from "styled-components"; - -type ImageProps = { - data: any; -}; - -const getCredit = (children: any[]) => { - if (children.length < 2) return; - - const credit = children[1]; - if (credit.name !== "Credits") return; - - return ; -}; -const getTexteDeRemplacement = (children: any[]) => { - if (children.length < 4) return; - - const texteDeRemplacement = children[2]; - if (texteDeRemplacement.name !== "TexteDeRemplacement") return; - - return ; -}; - -function ImageComponent({ data }: ImageProps) { - const name = data.attributes.LienPublication; - const legend = data.children[0]; - if (legend.name !== "Legende") return null; - const legendText = getText(legend.children); - - const creditText = getCredit(data.children); - const texteDeRemplacement = getTexteDeRemplacement(data.children); - - return ( - <> -
- {legendText} -
- {creditText && Crédits : {creditText}} -
-
- {texteDeRemplacement && ( - - {texteDeRemplacement} - - )} - - ); -} - -export const Image = memo(ImageComponent) as typeof ImageComponent; - -const Figure = styled.figure` - img { - max-width: 100%; - } -`; - -const Figcaption = styled.figcaption` - display: flex; - justify-content: flex-end; -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/LienExterne.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/LienExterne.js deleted file mode 100644 index 75bb8631ca..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/LienExterne.js +++ /dev/null @@ -1,46 +0,0 @@ -import PropTypes from "prop-types"; -import React from "react"; - -import { getText } from "../utils.js"; - -export class LienExterneCommente extends React.PureComponent { - render() { - const { data } = this.props; - const commentaire = data.children.find( - (child) => child.name === "Commentaire" - ); - const lienExterne = data.children.find( - (child) => child.name === "LienExterne" - ); - return ( - <> - {getText(commentaire)} -

- -

- - ); - } -} - -export class LienExterne extends React.PureComponent { - render() { - const { data } = this.props; - const url = data.attributes.URL; - const label = getText(data); - return ( - - {label} - - ); - } -} - -LienExterne.propTypes = { - data: PropTypes.object.isRequired, -}; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/List.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/List.js deleted file mode 100644 index 7049d99667..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/List.js +++ /dev/null @@ -1,35 +0,0 @@ -import { theme } from "@socialgouv/cdtn-ui"; -import PropTypes from "prop-types"; -import React from "react"; -import styled from "styled-components"; - -import { ElementBuilder } from "./ElementBuilder.js"; - -const { spacings } = theme; - -class List extends React.PureComponent { - render() { - const { data, headingLevel } = this.props; - const items = data.children.map((item, index) => ( - - - - )); - - if (data.attributes.type === "puce") { - return
    {items}
; - } - return
    {items}
; - } -} - -List.propTypes = { - data: PropTypes.object.isRequired, - headingLevel: PropTypes.number.isRequired, -}; - -export default List; - -const StyledLi = styled.li` - margin-bottom: ${spacings.tiny}; -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/OuSAdresser.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/OuSAdresser.js deleted file mode 100644 index ce73dce5fe..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/OuSAdresser.js +++ /dev/null @@ -1,70 +0,0 @@ -import { Heading, theme } from "@socialgouv/cdtn-ui"; -import PropTypes from "prop-types"; -import React from "react"; -import styled from "styled-components"; - -import { getText } from "../utils.js"; -import { ElementBuilder } from "./ElementBuilder.js"; - -class OuSAdresser extends React.PureComponent { - render() { - const { data, headingLevel } = this.props; - const label = getText( - data.children.find((child) => child.name === "Titre") - ); - let content; - if (data.children.find((child) => child.name === "RessourceWeb")) { - const url = data.children.find((child) => child.name === "RessourceWeb") - .attributes.URL; - content = ( - - {label} - - ); - } else { - content = ( - <> - {label} - child.name === "Texte")} - headingLevel={headingLevel} - /> - - ); - } - return ( - - {"Ou s'adresser ?"} - {content} - - ); - } -} - -OuSAdresser.propTypes = { - data: PropTypes.object.isRequired, - headingLevel: PropTypes.number.isRequired, -}; - -export default OuSAdresser; - -const { breakpoints, colors, spacings, box } = theme; - -const Wrapper = styled.div` - margin-bottom: ${spacings.base}; - padding: ${spacings.large}; - background-color: ${colors.bgTertiary}; - border-radius: ${box.borderRadius}; - @media (max-width: ${breakpoints.mobile}) { - padding: ${spacings.small} ${spacings.medium}; - } -`; -const Title = styled.strong` - display: block; - margin-bottom: ${spacings.tiny}; -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/ServiceEnLigne.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/ServiceEnLigne.js deleted file mode 100644 index 57bfdc200a..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/ServiceEnLigne.js +++ /dev/null @@ -1,42 +0,0 @@ -import { theme } from "@socialgouv/cdtn-ui"; -import PropTypes from "prop-types"; -import React from "react"; -import styled from "styled-components"; - -import { getText } from "../utils.js"; -import { LinkedTile } from "../../common/tiles/LinkedTile"; - -class ServiceEnLigne extends React.PureComponent { - render() { - const { data } = this.props; - const type = data.attributes.type; - const url = data.attributes.URL; - const title = getText(data.children[0]); - const source = getText(data.children[1]); - return ( - - Source: {source} - - ); - } -} - -ServiceEnLigne.propTypes = { - data: PropTypes.object.isRequired, -}; - -export default ServiceEnLigne; -const { spacings } = theme; - -const StyledTile = styled(LinkedTile)` - margin-bottom: ${spacings.base}; -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/Table.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/Table.js deleted file mode 100644 index 9a2912e3d1..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/Table.js +++ /dev/null @@ -1,91 +0,0 @@ -import { Table as UITable } from "@socialgouv/cdtn-ui"; -import PropTypes from "prop-types"; -import React from "react"; - -import { getText, ignoreParagraph } from "../utils.js"; -import { ElementBuilder } from "./ElementBuilder.js"; - -const ROW_HEADER = "header"; - -class Table extends React.PureComponent { - render() { - const { data, headingLevel } = this.props; - - const title = data.children.find((child) => child.name === "Titre"); - const headingRows = data.children.filter( - (child) => child.name === "Rangée" && child.attributes.type === "header" - ); - const rows = data.children.filter( - (child) => child.name === "Rangée" && child.attributes.type === "normal" - ); - - const columns = data.children.filter((child) => child.name === "Colonne"); - const isHeaderCell = (columnIndex) => { - return columns[columnIndex].attributes.type === ROW_HEADER; - }; - - const handleSpan = (el) => { - let colSpan = 1; - let rowSpan = 1; - if (el.attributes) { - colSpan = el.attributes.fusionHorizontale || 1; - rowSpan = el.attributes.fusionVerticale || 1; - } - return { - colSpan, - rowSpan, - }; - }; - - return ( - - {title &&
} - {headingRows.length > 0 && ( - - {headingRows.map((tr, rowIndex) => ( - - {tr.children.map((th, columnIndex) => ( - - ))} - - ))} - - )} - - {rows.map((tr, rowIndex) => ( - - {tr.children.map((td, columnIndex) => { - const Cell = isHeaderCell(columnIndex) ? "th" : "td"; - if (!td.children) { - return ; - } - return ( - - - - ); - })} - - ))} - - - ); - } -} - -Table.propTypes = { - data: PropTypes.object.isRequired, - headingLevel: PropTypes.number.isRequired, -}; - -export default Table; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/Tabulator.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/Tabulator.js deleted file mode 100644 index ce828e57b6..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/Tabulator.js +++ /dev/null @@ -1,38 +0,0 @@ -import { Heading, Tabs } from "@socialgouv/cdtn-ui"; -import PropTypes from "prop-types"; -import React from "react"; - -import { getText } from "../utils.js"; -import { ElementBuilder } from "./ElementBuilder.js"; - -class Tabulator extends React.PureComponent { - render() { - const { data, headingLevel: previousHeadingLevel } = this.props; - const headingLevel = - previousHeadingLevel > 0 ? previousHeadingLevel + 1 : 1; - - const tabsData = data.children.map((tab) => { - return { - panel: ( - el.name !== "Titre")} - headingLevel={headingLevel} - /> - ), - tab: ( - - {getText(tab.children.find((child) => child.name === "Titre"))} - - ), - }; - }); - return ; - } -} - -Tabulator.propTypes = { - data: PropTypes.object.isRequired, - headingLevel: PropTypes.number.isRequired, -}; - -export default Tabulator; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/Title.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/Title.js deleted file mode 100644 index ecb827e92f..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/Title.js +++ /dev/null @@ -1,60 +0,0 @@ -import { Heading, Subtitle, Title as UITitle } from "@socialgouv/cdtn-ui"; -import { format, parseISO } from "date-fns"; -import frLocale from "date-fns/locale/fr"; -import PropTypes from "prop-types"; -import React from "react"; - -class Title extends React.PureComponent { - render() { - const { level, children, date } = this.props; - // the whole date thing here is related to the "Avertissement" element and only it. - const formatedDate = - (date && - format(parseISO(date), "dd MMMM yyyy", { - locale: frLocale, - })) || - undefined; - - switch (level) { - case 0: - return {children}; - case 1: - return ( - - {children} - {formatedDate && {formatedDate}} - - ); - - case 2: - return ( - - {children} - {formatedDate && {formatedDate}} - - ); - case 3: - return ( - - {children} - {formatedDate && {formatedDate}} - - ); - default: - return ( - - {children} - {formatedDate && {formatedDate}} - - ); - } - } -} - -Title.propTypes = { - children: PropTypes.node, - date: PropTypes.string, - level: PropTypes.number, -}; - -export default Title; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Accordion.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Accordion.test.js deleted file mode 100644 index 52ef6cc9fe..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Accordion.test.js +++ /dev/null @@ -1,19 +0,0 @@ -import React from "react"; -import { render } from "@testing-library/react"; -import Accordion from "../Accordion"; -import accordionDataMock from "./mocks/accordionData.json"; - -describe("", () => { - it("should have two different levels of headings", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - }); - it("should render all, siblings included", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/ElementBuilder.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/ElementBuilder.test.js deleted file mode 100644 index 166e0755eb..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/ElementBuilder.test.js +++ /dev/null @@ -1,125 +0,0 @@ -import React from "react"; -import { render } from "@testing-library/react"; -import { ElementBuilder } from "../ElementBuilder"; - -const tests = [ - { - title: "renders when type is text", - data: { type: "text", text: "moonshot" }, - test: (container) => expect(container).toMatchSnapshot(), - }, - { - title: "renders when data is an array", - - data: [ - { type: "text", text: "moonshot 0" }, - { type: "text", text: "moonshot 1" }, - ], - test: (container) => expect(container).toMatchSnapshot(), - }, - { - title: "does not render anything when data is undefined", - data: undefined, - test: (container) => expect(container).toMatchSnapshot(), - }, - { - title: "does not render anything when element name is not recognized", - data: { - type: "element", - name: "TrucMuche", - attributes: { - bidule: "ok ?", - }, - children: [ - { type: "text", text: "you shall not see this text in snapshot !" }, - ], - }, - test: (container) => expect(container).toMatchSnapshot(), - }, - { - title: "does render stuff inside a styled block", - data: [ - { - type: "element", - name: "ANoter", - children: [{ type: "text", text: "stuff 0" }], - }, - { - type: "element", - name: "ASavoir", - children: [{ type: "text", text: "stuff 1" }], - }, - { - type: "element", - name: "Attention", - children: [{ type: "text", text: "stuff 2" }], - }, - { - type: "element", - name: "Rappel", - children: [{ type: "text", text: "stuff 3" }], - }, - ], - test: (container) => expect(container).toMatchSnapshot(), - }, - { - title: "does render several elements", - data: [ - { - type: "element", - name: "Chapitre", - children: [{ type: "text", text: "Chapitre" }], - }, - { - type: "element", - name: "SousChapitre", - children: [{ type: "text", text: "SousChapitre" }], - }, - { - type: "element", - name: "Expression", - children: [{ type: "text", text: "Expression (inside i)" }], - }, - { - type: "element", - name: "MiseEnEvidence", - children: [{ type: "text", text: "MiseEnEvidence (inside strong)" }], - }, - { - type: "element", - name: "Valeur", - children: [{ type: "text", text: "Valeur (inside strong)" }], - }, - { - type: "element", - name: "Paragraphe", - children: [{ type: "text", text: "Paragraphe (inside p)" }], - }, - { - type: "element", - name: "Exposant", - children: [{ type: "text", text: "Exposant (inside sup)" }], - }, - { - type: "element", - name: "LienIntra", - children: [{ type: "text", text: "LienIntra" }], - }, - { - type: "element", - name: "LienInterne", - children: [{ type: "text", text: "LienInterne" }], - }, - ], - test: (container) => expect(container).toMatchSnapshot(), - }, -]; - -describe("", () => { - tests.forEach(({ title, data, test }) => { - it(title, () => { - const { container } = render(); - test(container); - }); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/FragmentConditionne.test.tsx b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/FragmentConditionne.test.tsx deleted file mode 100644 index 7a016aaf1f..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/FragmentConditionne.test.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import React from "react"; -import { render } from "@testing-library/react"; -import dataMock from "./mocks/fragmentConditionne.json"; -import { ElementBuilder } from "../ElementBuilder"; - -describe("FragmentConditionne", () => { - it("Should display element within", () => { - const { container } = render(); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Image.test.tsx b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Image.test.tsx deleted file mode 100644 index 8659d2a862..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Image.test.tsx +++ /dev/null @@ -1,11 +0,0 @@ -import React from "react"; -import { render } from "@testing-library/react"; -import dataMock from "./mocks/image.json"; -import { ElementBuilder } from "../ElementBuilder"; - -describe("Image", () => { - it("should display image and caption", () => { - const { container } = render(); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/LienExterne.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/LienExterne.test.js deleted file mode 100644 index ca65deb0db..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/LienExterne.test.js +++ /dev/null @@ -1,20 +0,0 @@ -import React from "react"; -import { render } from "@testing-library/react"; -import { LienExterne, LienExterneCommente } from "../LienExterne"; -import lienExterneCommenteDataMock from "./mocks/lienExterneCommenteData.json"; -import lienExterneDataMock from "./mocks/lienExterneData.json"; - -describe("", () => { - it("should render", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - }); -}); -describe("", () => { - it("should render", () => { - const { container } = render(); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/List.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/List.test.js deleted file mode 100644 index 7dbeb2d950..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/List.test.js +++ /dev/null @@ -1,11 +0,0 @@ -import React from "react"; -import { render } from "@testing-library/react"; -import List from "../List"; -import listDataMock from "./mocks/listData.json"; - -describe("", () => { - it("should render and increment heading level of children by one", () => { - const { container } = render(); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/OuSAdresser.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/OuSAdresser.test.js deleted file mode 100644 index 0340af4939..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/OuSAdresser.test.js +++ /dev/null @@ -1,24 +0,0 @@ -import { render, screen } from "@testing-library/react"; -import React from "react"; - -import OuSAdresser from "../OuSAdresser"; -import classicData from "./mocks/ouSAdresserClassicData.json"; -import ressourceWebData from "./mocks/ouSAdresserWebData.json"; - -describe("", () => { - it("should render a simple case", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - const h2 = screen.getByRole("heading", { level: 2 }); - expect(h2.textContent).toEqual("Nom du centre"); - }); - - it("should render a ressource web component", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/ServiceEnLigne.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/ServiceEnLigne.test.js deleted file mode 100644 index 092ccfaa63..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/ServiceEnLigne.test.js +++ /dev/null @@ -1,17 +0,0 @@ -import { render, screen } from "@testing-library/react"; -import React from "react"; - -import ServiceEnLigne from "../ServiceEnLigne"; -import serviceEnLigneDataMock from "./mocks/serviceEnLigneData.json"; - -describe("", () => { - it("should render", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - - const title = screen.getByText("Se retrouve dans en entête"); - expect(title.tagName).toEqual("P"); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Table.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Table.test.js deleted file mode 100644 index 217c6c4d66..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Table.test.js +++ /dev/null @@ -1,13 +0,0 @@ -import React from "react"; -import { render } from "@testing-library/react"; -import Table from "../Table"; -import tableDataMock from "./mocks/tableData.json"; - -describe("
{getText(title)}
- {th.children && ( - - )} -
", () => { - it("should render with th, td, colspan etc.", () => { - const { container } = render( -
- ); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Tabulator.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Tabulator.test.js deleted file mode 100644 index 5fe0396e9f..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Tabulator.test.js +++ /dev/null @@ -1,33 +0,0 @@ -import { render, screen } from "@testing-library/react"; -import React from "react"; - -import Tabulator from "../Tabulator"; -import tabulatorDataMock from "./mocks/tabulatorData.json"; - -describe("", () => { - it("should have two different levels of headings", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - const h2 = screen.getByRole("heading", { level: 2 }); - expect(h2.textContent).toEqual("CDI"); - - const h3 = screen.getByRole("heading", { level: 3 }); - expect(h3.textContent).toEqual("titre 1"); - }); - it("should incease heading levels if not 0", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - const title = screen.getByRole("heading", { level: 3 }); - expect(title.textContent).toEqual("CDI"); - }); - it("should render", () => { - const { container } = render( - - ); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Title.test.js b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Title.test.js deleted file mode 100644 index a54f18a7e8..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/Title.test.js +++ /dev/null @@ -1,14 +0,0 @@ -import React from "react"; -import { render } from "@testing-library/react"; -import Title from "../Title"; - -describe("", () => { - it("should render a H{x} whose {x} is headingLevel + 2", () => { - const { container } = render(<Title level={2} />); - expect(container).toMatchSnapshot(); - }); - it("heading should default to H6", () => { - const { container } = render(<Title level={10} />); - expect(container).toMatchSnapshot(); - }); -}); diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Accordion.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Accordion.test.js.snap deleted file mode 100644 index c0d280e94a..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Accordion.test.js.snap +++ /dev/null @@ -1,474 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<Accordion /> should have two different levels of headings 1`] = ` -<div> - <div - class="sc-e32628d4-0 eFvDQP" - > - <h2 - class="sc-d6e72754-0 egzXkL" - > - <span - class="sc-a4d7a179-0 gGBEJx" - /> - titre 0 - </h2> - </div> - <p> - paragraphe 0 - </p> - <div - class="sc-74e63776-0 gELTXP" - data-accordion-component="Accordion" - > - <div - id="titre-1" - > - <div - class="sc-1571bed7-0" - data-accordion-component="AccordionItem" - > - <div - class="accordion__heading" - data-accordion-component="AccordionItemHeading" - > - <div - aria-controls="accordion__panel-titre-1" - aria-disabled="false" - aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" - data-accordion-component="AccordionItemButton" - id="accordion__heading-titre-1" - role="button" - tabindex="0" - > - <svg - aria-hidden="true" - class="sc-93c68677-0 fWneNg" - fill="none" - height="24" - stroke="currentColor" - stroke-linecap="round" - stroke-linejoin="round" - stroke-width="2" - viewBox="0 0 24 24" - width="24" - xmlns="http://www.w3.org/2000/svg" - > - <polyline - points="9 18 15 12 9 6" - /> - </svg> - <div - class="sc-1571bed7-3 figaQV" - > - <h2 - class="sc-b879fc2d-0 hyiHle" - style="margin: 0px;" - > - titre 1 - </h2> - </div> - </div> - </div> - <div - aria-hidden="true" - class="sc-1571bed7-1 hamHiw" - data-accordion-component="AccordionItemPanel" - hidden="" - id="accordion__panel-titre-1" - > - <div - class="sc-32c7807-0 iMDCLs" - > - <p> - paragraphe 1-1 - </p> - <p> - paragraphe 1-2 - </p> - </div> - </div> - </div> - </div> - <div - id="titre-2" - > - <div - class="sc-1571bed7-0 dpEeGj" - data-accordion-component="AccordionItem" - > - <div - class="accordion__heading" - data-accordion-component="AccordionItemHeading" - > - <div - aria-controls="accordion__panel-titre-2" - aria-disabled="false" - aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" - data-accordion-component="AccordionItemButton" - id="accordion__heading-titre-2" - role="button" - tabindex="0" - > - <svg - aria-hidden="true" - class="sc-93c68677-0 fWneNg" - fill="none" - height="24" - stroke="currentColor" - stroke-linecap="round" - stroke-linejoin="round" - stroke-width="2" - viewBox="0 0 24 24" - width="24" - xmlns="http://www.w3.org/2000/svg" - > - <polyline - points="9 18 15 12 9 6" - /> - </svg> - <div - class="sc-1571bed7-3 figaQV" - > - <h2 - class="sc-b879fc2d-0 hyiHle" - style="margin: 0px;" - > - titre 2 - </h2> - </div> - </div> - </div> - <div - aria-hidden="true" - class="sc-1571bed7-1 hamHiw" - data-accordion-component="AccordionItemPanel" - hidden="" - id="accordion__panel-titre-2" - > - <div - class="sc-32c7807-0 iMDCLs" - > - <p> - paragraphe 2-1 - </p> - <p> - paragraphe 2-2 - </p> - <h3 - class="sc-b879fc2d-0 hyiHle" - > - titre 2-1 - </h3> - </div> - </div> - </div> - </div> - <div - id="titre-3" - > - <div - class="sc-1571bed7-0 dpEeGj" - data-accordion-component="AccordionItem" - > - <div - class="accordion__heading" - data-accordion-component="AccordionItemHeading" - > - <div - aria-controls="accordion__panel-titre-3" - aria-disabled="false" - aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" - data-accordion-component="AccordionItemButton" - id="accordion__heading-titre-3" - role="button" - tabindex="0" - > - <svg - aria-hidden="true" - class="sc-93c68677-0 fWneNg" - fill="none" - height="24" - stroke="currentColor" - stroke-linecap="round" - stroke-linejoin="round" - stroke-width="2" - viewBox="0 0 24 24" - width="24" - xmlns="http://www.w3.org/2000/svg" - > - <polyline - points="9 18 15 12 9 6" - /> - </svg> - <div - class="sc-1571bed7-3 figaQV" - > - <h2 - class="sc-b879fc2d-0 hyiHle" - style="margin: 0px;" - > - titre 3 - </h2> - </div> - </div> - </div> - <div - aria-hidden="true" - class="sc-1571bed7-1 hamHiw" - data-accordion-component="AccordionItemPanel" - hidden="" - id="accordion__panel-titre-3" - > - <div - class="sc-32c7807-0 iMDCLs" - > - <p> - paragraphe 3-1 - </p> - </div> - </div> - </div> - </div> - </div> - <p> - paragraphe 4 - </p> -</div> -`; - -exports[`<Accordion /> should render all, siblings included 1`] = ` -<div> - <h5 - class="sc-b879fc2d-0 hyiHle" - > - titre 0 - </h5> - <p> - paragraphe 0 - </p> - <div - class="sc-74e63776-0 gELTXP" - data-accordion-component="Accordion" - > - <div - id="titre-1" - > - <div - class="sc-1571bed7-0" - data-accordion-component="AccordionItem" - > - <div - class="accordion__heading" - data-accordion-component="AccordionItemHeading" - > - <div - aria-controls="accordion__panel-titre-1" - aria-disabled="false" - aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" - data-accordion-component="AccordionItemButton" - id="accordion__heading-titre-1" - role="button" - tabindex="0" - > - <svg - aria-hidden="true" - class="sc-93c68677-0 fWneNg" - fill="none" - height="24" - stroke="currentColor" - stroke-linecap="round" - stroke-linejoin="round" - stroke-width="2" - viewBox="0 0 24 24" - width="24" - xmlns="http://www.w3.org/2000/svg" - > - <polyline - points="9 18 15 12 9 6" - /> - </svg> - <div - class="sc-1571bed7-3 figaQV" - > - <h5 - class="sc-b879fc2d-0 hyiHle" - style="margin: 0px;" - > - titre 1 - </h5> - </div> - </div> - </div> - <div - aria-hidden="true" - class="sc-1571bed7-1 hamHiw" - data-accordion-component="AccordionItemPanel" - hidden="" - id="accordion__panel-titre-1" - > - <div - class="sc-32c7807-0 iMDCLs" - > - <p> - paragraphe 1-1 - </p> - <p> - paragraphe 1-2 - </p> - </div> - </div> - </div> - </div> - <div - id="titre-2" - > - <div - class="sc-1571bed7-0 dpEeGj" - data-accordion-component="AccordionItem" - > - <div - class="accordion__heading" - data-accordion-component="AccordionItemHeading" - > - <div - aria-controls="accordion__panel-titre-2" - aria-disabled="false" - aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" - data-accordion-component="AccordionItemButton" - id="accordion__heading-titre-2" - role="button" - tabindex="0" - > - <svg - aria-hidden="true" - class="sc-93c68677-0 fWneNg" - fill="none" - height="24" - stroke="currentColor" - stroke-linecap="round" - stroke-linejoin="round" - stroke-width="2" - viewBox="0 0 24 24" - width="24" - xmlns="http://www.w3.org/2000/svg" - > - <polyline - points="9 18 15 12 9 6" - /> - </svg> - <div - class="sc-1571bed7-3 figaQV" - > - <h5 - class="sc-b879fc2d-0 hyiHle" - style="margin: 0px;" - > - titre 2 - </h5> - </div> - </div> - </div> - <div - aria-hidden="true" - class="sc-1571bed7-1 hamHiw" - data-accordion-component="AccordionItemPanel" - hidden="" - id="accordion__panel-titre-2" - > - <div - class="sc-32c7807-0 iMDCLs" - > - <p> - paragraphe 2-1 - </p> - <p> - paragraphe 2-2 - </p> - <h6 - class="sc-b879fc2d-0 hyiHle" - > - titre 2-1 - </h6> - </div> - </div> - </div> - </div> - <div - id="titre-3" - > - <div - class="sc-1571bed7-0 dpEeGj" - data-accordion-component="AccordionItem" - > - <div - class="accordion__heading" - data-accordion-component="AccordionItemHeading" - > - <div - aria-controls="accordion__panel-titre-3" - aria-disabled="false" - aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" - data-accordion-component="AccordionItemButton" - id="accordion__heading-titre-3" - role="button" - tabindex="0" - > - <svg - aria-hidden="true" - class="sc-93c68677-0 fWneNg" - fill="none" - height="24" - stroke="currentColor" - stroke-linecap="round" - stroke-linejoin="round" - stroke-width="2" - viewBox="0 0 24 24" - width="24" - xmlns="http://www.w3.org/2000/svg" - > - <polyline - points="9 18 15 12 9 6" - /> - </svg> - <div - class="sc-1571bed7-3 figaQV" - > - <h5 - class="sc-b879fc2d-0 hyiHle" - style="margin: 0px;" - > - titre 3 - </h5> - </div> - </div> - </div> - <div - aria-hidden="true" - class="sc-1571bed7-1 hamHiw" - data-accordion-component="AccordionItemPanel" - hidden="" - id="accordion__panel-titre-3" - > - <div - class="sc-32c7807-0 iMDCLs" - > - <p> - paragraphe 3-1 - </p> - </div> - </div> - </div> - </div> - </div> - <p> - paragraphe 4 - </p> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/ElementBuilder.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/ElementBuilder.test.js.snap deleted file mode 100644 index 03fc2d33ab..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/ElementBuilder.test.js.snap +++ /dev/null @@ -1,67 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<ElementBuilder /> does not render anything when data is undefined 1`] = `<div />`; - -exports[`<ElementBuilder /> does not render anything when element name is not recognized 1`] = `<div />`; - -exports[`<ElementBuilder /> does render several elements 1`] = ` -<div> - Chapitre - SousChapitre - <i> - Expression (inside i) - </i> - <strong> - MiseEnEvidence (inside strong) - </strong> - <strong> - Valeur (inside strong) - </strong> - <p> - Paragraphe (inside p) - </p> - <sup> - Exposant (inside sup) - </sup> - LienIntra - LienInterne -</div> -`; - -exports[`<ElementBuilder /> does render stuff inside a styled block 1`] = ` -<div> - <div - class="sc-2a0a4b0a-0 sc-fb4ce9da-0 dLOZmV bDyXMm" - > - stuff 0 - </div> - <div - class="sc-2a0a4b0a-0 sc-fb4ce9da-0 dLOZmV bDyXMm" - > - stuff 1 - </div> - <div - class="sc-2a0a4b0a-0 sc-fb4ce9da-0 dLOZmV bDyXMm" - > - stuff 2 - </div> - <div - class="sc-2a0a4b0a-0 sc-fb4ce9da-0 dLOZmV bDyXMm" - > - stuff 3 - </div> -</div> -`; - -exports[`<ElementBuilder /> renders when data is an array 1`] = ` -<div> - moonshot 0 - moonshot 1 -</div> -`; - -exports[`<ElementBuilder /> renders when type is text 1`] = ` -<div> - moonshot -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/FragmentConditionne.test.tsx.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/FragmentConditionne.test.tsx.snap deleted file mode 100644 index 471bde75f2..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/FragmentConditionne.test.tsx.snap +++ /dev/null @@ -1,138 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`FragmentConditionne Should display element within 1`] = ` -<div> - <div - class="sc-e32628d4-0 eFvDQP" - > - <h2 - class="sc-d6e72754-0 egzXkL" - > - <span - class="sc-a4d7a179-0 gGBEJx" - /> - Comment le saisir le médiateur de l'apprentissage ? - </h2> - </div> - <p> - Le médiateur de l'apprentissage à saisir dépend de l'activité de l'entreprise. Il est désigné par la chambre consulaire. - </p> - <div - class="sc-ac4a133f-0 fvNPWb" - data-rttabs="true" - > - <div - class="sc-ac4a133f-1 fxZtdi" - > - <ul - class="sc-ac4a133f-2 fHCeXh" - role="tablist" - > - <li - aria-controls="react-tabs-1" - aria-disabled="false" - aria-selected="true" - class="sc-ac4a133f-3 faZqNG react-tabs__tab--selected" - data-rttab="true" - id="react-tabs-0" - role="tab" - tabindex="0" - > - Commerce - industrie - </li> - <li - aria-controls="react-tabs-3" - aria-disabled="false" - aria-selected="false" - class="sc-ac4a133f-3 faZqNG" - data-rttab="true" - id="react-tabs-2" - role="tab" - > - Artisanat - </li> - <li - aria-controls="react-tabs-5" - aria-disabled="false" - aria-selected="false" - class="sc-ac4a133f-3 faZqNG" - data-rttab="true" - id="react-tabs-4" - role="tab" - > - Agriculture - </li> - <li - aria-controls="react-tabs-7" - aria-disabled="false" - aria-selected="false" - class="sc-ac4a133f-3 faZqNG" - data-rttab="true" - id="react-tabs-6" - role="tab" - > - Secteur public - </li> - </ul> - </div> - <div - aria-labelledby="react-tabs-0" - class="sc-ac4a133f-4 haGXHZ react-tabs__tab-panel--selected" - id="react-tabs-1" - role="tabpanel" - > - <div - class="sc-8dcb2faa-0 gxfPDw" - > - <h2 - class="sc-b879fc2d-0 hyiHle" - > - Commerce - industrie - </h2> - </div> - <div - class="sc-ac4a133f-5 yflIk" - > - <p> - Il faut saisir la chambre de commerce et d'industrie. - </p> - <div - class="sc-b28d9feb-0 jhRKAI" - > - <strong - class="sc-b28d9feb-1 FSydE" - > - Ou s'adresser ? - </strong> - <a - aria-label="Chambre de commerce et d'industrie (CCI) (nouvelle fenêtre)" - href="http://www.cci.fr/web/organisation-du-reseau/annuaire" - rel="noopener noreferrer" - target="_blank" - > - Chambre de commerce et d'industrie (CCI) - </a> - </div> - </div> - </div> - <div - aria-labelledby="react-tabs-2" - class="sc-ac4a133f-4 haGXHZ" - id="react-tabs-3" - role="tabpanel" - /> - <div - aria-labelledby="react-tabs-4" - class="sc-ac4a133f-4 haGXHZ" - id="react-tabs-5" - role="tabpanel" - /> - <div - aria-labelledby="react-tabs-6" - class="sc-ac4a133f-4 haGXHZ" - id="react-tabs-7" - role="tabpanel" - /> - </div> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Image.test.tsx.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Image.test.tsx.snap deleted file mode 100644 index 55049314bd..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Image.test.tsx.snap +++ /dev/null @@ -1,114 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`Image should display image and caption 1`] = ` -<div> - <figure - aria-label="Comment calculer un délai quand il y a un jour férié ?" - class="sc-6c336c92-0 fZSumh" - role="group" - > - <img - alt="Comment calculer un délai quand il y a un jour férié ?" - src="https://www.service-public.fr/webapp/images/vdd/extralarge/I4596.jpg" - /> - <figcaption - class="sc-6c336c92-1 gbntbh" - > - <span> - Crédits : - Service Public (DILA) - </span> - </figcaption> - </figure> - <div - class="sc-9845d97e-0 jdstGa" - data-accordion-component="Accordion" - > - <div - class="accordion__item" - data-accordion-component="AccordionItem" - > - <div - class="accordion__heading" - data-accordion-component="AccordionItemHeading" - > - <div - aria-controls="accordion__panel-raa-0" - aria-disabled="false" - aria-expanded="false" - class="sc-9845d97e-1 jffOUe" - data-accordion-component="AccordionItemButton" - id="accordion__heading-raa-0" - role="button" - tabindex="0" - > - <svg - aria-hidden="true" - class="sc-9845d97e-2 kPPRyj" - fill="none" - viewBox="0 0 16 16" - xmlns="http://www.w3.org/2000/svg" - > - <path - clip-rule="evenodd" - d="M8 2a1 1 0 0 0-1 1v4H3a1 1 0 0 0 0 2h4v4a1 1 0 1 0 2 0V9h4a1 1 0 1 0 0-2H9V3a1 1 0 0 0-1-1z" - fill="currentColor" - fill-rule="evenodd" - /> - </svg> - <div - class="sc-9845d97e-3 biBldq" - > - Voir en détail - </div> - </div> - </div> - <div - class="sc-9845d97e-5 mALye" - data-accordion-component="AccordionItemPanel" - hidden="" - id="accordion__panel-raa-0" - > - <div - class="sc-9845d97e-4 dcRMRW" - > - <div - class="sc-2a0a4b0a-0 dLOZmV" - > - <p> - Comment calculer un délai quand il y a un jour férié ? - </p> - <p> - Voici comment calculer un délai de 7 jours, selon que l'on parle de jours calendaires, francs, ouvrables ou ouvrés. Dans notre exemple, le délai commence un lundi et il y a un jour férié (le mercredi). - </p> - <p> - - Délai compté en jour calendaire : lundi + mardi + mercredi + jeudi + vendredi + samedi + dimanche - </p> - <p> - Chaque jour compte. - </p> - <p> - - Délai compté en jour franc : lundi + mardi + mercredi même si c'est un jour férié + jeudi + vendredi + samedi + lundi de la semaine suivante. - </p> - <p> - Report au jour suivant si le 7e jour tombe un samedi, un dimanche (comme c'est le cas dans notre exemple) ou un jour férié. - </p> - <p> - - Délai compté en jour ouvrable : lundi + mardi + jeudi + vendredi + samedi + lundi de la semaine suivante + mardi de la semaine suivante. - </p> - <p> - On ne compte pas le dimanche ni le jour férié. - </p> - <p> - - Délai compté en jour ouvré : lundi + mardi + jeudi + vendredi + lundi de la semaine suivante + mardi de la semaine suivante + mercredi de la semaine suivante. - </p> - <p> - On ne compte pas le jour férié (ici mercredi), le samedi ni le dimanche. - </p> - </div> - </div> - </div> - </div> - </div> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/LienExterne.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/LienExterne.test.js.snap deleted file mode 100644 index c3c059f36d..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/LienExterne.test.js.snap +++ /dev/null @@ -1,30 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<LienExterne /> should render 1`] = ` -<div> - <a - aria-label="formulaire de contact (nouvelle fenêtre)" - href="https://formulaire.defenseurdesdroits.fr/code/afficher.php?ETAPE=accueil_2016" - rel="noopener noreferrer" - target="_blank" - > - formulaire de contact - </a> -</div> -`; - -exports[`<LienExterneCommente /> should render 1`] = ` -<div> - Un contrat à durée déterminée (CDD) ne peut être conclu que pour l'exécution d'une tâche précise et temporaire et seulement dans les cas énumérés par la loi, et doit obligatoirement faire l'objet d'un écrit. Il ne doit pas pourvoir durablement un emploi lié à l'activité normale et permanente de l'entreprise. - <p> - <a - aria-label="Fiche pratique sur le CDD (nouvelle fenêtre)" - href="http://travail-emploi.gouv.fr/droit-du-travail/contrats-et-carriere/contrats-de-travail/types-de-contrats/article/le-contrat-a-duree-determinee-cdd" - rel="noopener noreferrer" - target="_blank" - > - Fiche pratique sur le CDD - </a> - </p> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/List.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/List.test.js.snap deleted file mode 100644 index da5cc77421..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/List.test.js.snap +++ /dev/null @@ -1,24 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<List /> should render and increment heading level of children by one 1`] = ` -<div> - <ul> - <li - class="sc-5f052859-0 cWQbML" - > - <h3 - class="sc-b879fc2d-0 hyiHle" - > - title - </h3> - </li> - <li - class="sc-5f052859-0 cWQbML" - > - <p> - ok - </p> - </li> - </ul> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/OuSAdresser.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/OuSAdresser.test.js.snap deleted file mode 100644 index e21ec386fc..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/OuSAdresser.test.js.snap +++ /dev/null @@ -1,45 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<OuSAdresser /> should render a ressource web component 1`] = ` -<div> - <div - class="sc-b28d9feb-0 jhRKAI" - > - <strong - class="sc-b28d9feb-1 FSydE" - > - Ou s'adresser ? - </strong> - <a - aria-label="Label du lien ! (nouvelle fenêtre)" - href="url du lien" - rel="noopener noreferrer" - target="_blank" - > - Label du lien ! - </a> - </div> -</div> -`; - -exports[`<OuSAdresser /> should render a simple case 1`] = ` -<div> - <div - class="sc-b28d9feb-0 jhRKAI" - > - <strong - class="sc-b28d9feb-1 FSydE" - > - Ou s'adresser ? - </strong> - <h2 - class="sc-b879fc2d-0 hyiHle" - > - Nom du centre - </h2> - <p> - Un paragraphe tout bête - </p> - </div> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/ServiceEnLigne.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/ServiceEnLigne.test.js.snap deleted file mode 100644 index d5b86e0c3b..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/ServiceEnLigne.test.js.snap +++ /dev/null @@ -1,41 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<ServiceEnLigne /> should render 1`] = ` -<div> - <div - aria-label="Se retrouve dans en entête Texte qui se retrouve dans le lien (nouvelle fenêtre)" - class="sc-d47d8018-0 cDsGtD sc-54b316ce-0 kCUWSF no-after" - > - <div - class="sc-d47d8018-2 eBZhiP" - > - <div - class="sc-d47d8018-3 cAXyng" - > - <p - class="sc-9261d202-0 sc-d47d8018-4 iTbcuX llhzYx" - > - Se retrouve dans en entête - </p> - <p - class="sc-d47d8018-5 jNRMjT" - > - <a - href="url à retoruver dans le lien" - rel="noopener noreferrer" - target="_blank" - > - Texte qui se retrouve dans le lien - </a> - </p> - </div> - </div> - <div - class="sc-d47d8018-6 ipSAXR" - > - Source: - Source qui se retrouve sous le lien - </div> - </div> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Table.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Table.test.js.snap deleted file mode 100644 index e2fdca596e..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Table.test.js.snap +++ /dev/null @@ -1,631 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<Table /> should render with th, td, colspan etc. 1`] = ` -<div> - <table - class="sc-4e3ba411-0 kKVapO" - > - <caption> - Conditions ouvrant droit à la retraite anticipée pour carrière longue - </caption> - <thead> - <tr> - <th - colspan="1" - rowspan="2" - > - Année de naissance - </th> - <th - colspan="1" - rowspan="2" - > - Âge de départ à la retraite envisagé (à partir de) - </th> - <th - colspan="1" - rowspan="2" - > - Durée d'assurance minimale cotisée (en trimestres) - </th> - <th - colspan="2" - rowspan="1" - > - Durée d'assurance minimale en début de carrière - </th> - </tr> - <tr> - <th - colspan="1" - rowspan="1" - > - Si vous êtes né entre janvier et septembre - </th> - <th - colspan="1" - rowspan="1" - > - Si vous êtes né entre octobre et décembre - </th> - </tr> - </thead> - <tbody> - <tr> - <th - colspan="1" - rowspan="2" - > - 1959 - </th> - <td - colspan="1" - rowspan="1" - > - 57 ans et 8 mois - </td> - <td - colspan="1" - rowspan="1" - > - 175 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="1" - > - 60 ans - </th> - <td - colspan="1" - rowspan="1" - > - 167 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="2" - > - 1960 - </th> - <td - colspan="1" - rowspan="1" - > - 58 ans - </td> - <td - colspan="1" - rowspan="1" - > - 175 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="1" - > - 60 ans - </th> - <td - colspan="1" - rowspan="1" - > - 167 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="2" - > - 1961, 1962 ou 1963 - </th> - <td - colspan="1" - rowspan="1" - > - 58 ans - </td> - <td - colspan="1" - rowspan="1" - > - 176 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="1" - > - 60 ans - </th> - <td - colspan="1" - rowspan="1" - > - 168 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="2" - > - 1964, 1965 ou 1966 - </th> - <td - colspan="1" - rowspan="1" - > - 58 ans - </td> - <td - colspan="1" - rowspan="1" - > - 177 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="1" - > - 60 ans - </th> - <td - colspan="1" - rowspan="1" - > - 169 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="2" - > - 1967, 1968 ou 1969 - </th> - <td - colspan="1" - rowspan="1" - > - 58 ans - </td> - <td - colspan="1" - rowspan="1" - > - 178 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="1" - > - 60 ans - </th> - <td - colspan="1" - rowspan="1" - > - 170 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="2" - > - 1970, 1971 ou 1972 - </th> - <td - colspan="1" - rowspan="1" - > - 58 ans - </td> - <td - colspan="1" - rowspan="1" - > - 179 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="1" - > - 60 ans - </th> - <td - colspan="1" - rowspan="1" - > - 171 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="2" - > - À partir de 1973 - </th> - <td - colspan="1" - rowspan="1" - > - 58 ans - </td> - <td - colspan="1" - rowspan="1" - > - 180 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 16 ans - </strong> - </td> - </tr> - <tr> - <th - colspan="1" - rowspan="1" - > - 60 ans - </th> - <td - colspan="1" - rowspan="1" - > - 172 - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 5 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - <td - colspan="1" - rowspan="1" - > - <strong> - 4 - </strong> - trimestres à la fin de l'année des - <strong> - 20 ans - </strong> - </td> - </tr> - </tbody> - </table> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Tabulator.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Tabulator.test.js.snap deleted file mode 100644 index 35d642d4d1..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Tabulator.test.js.snap +++ /dev/null @@ -1,229 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<Tabulator /> should have two different levels of headings 1`] = ` -<div> - <div - class="sc-ac4a133f-0 fvNPWb" - data-rttabs="true" - > - <div - class="sc-ac4a133f-1 fxZtdi" - > - <ul - class="sc-ac4a133f-2 fHCeXh" - role="tablist" - > - <li - aria-controls="react-tabs-1" - aria-disabled="false" - aria-selected="true" - class="sc-ac4a133f-3 faZqNG react-tabs__tab--selected" - data-rttab="true" - id="react-tabs-0" - role="tab" - tabindex="0" - > - CDI - </li> - <li - aria-controls="react-tabs-3" - aria-disabled="false" - aria-selected="false" - class="sc-ac4a133f-3 faZqNG" - data-rttab="true" - id="react-tabs-2" - role="tab" - > - CDD - </li> - </ul> - </div> - <div - aria-labelledby="react-tabs-0" - class="sc-ac4a133f-4 haGXHZ react-tabs__tab-panel--selected" - id="react-tabs-1" - role="tabpanel" - > - <div - class="sc-8dcb2faa-0 gxfPDw" - > - <h2 - class="sc-b879fc2d-0 hyiHle" - > - CDI - </h2> - </div> - <div - class="sc-ac4a133f-5 yflIk" - > - <h3 - class="sc-b879fc2d-0 hyiHle" - > - titre 1 - </h3> - <p> - paragraphe 1 - </p> - </div> - </div> - <div - aria-labelledby="react-tabs-2" - class="sc-ac4a133f-4 haGXHZ" - id="react-tabs-3" - role="tabpanel" - /> - </div> -</div> -`; - -exports[`<Tabulator /> should incease heading levels if not 0 1`] = ` -<div> - <div - class="sc-ac4a133f-0 fvNPWb" - data-rttabs="true" - > - <div - class="sc-ac4a133f-1 fxZtdi" - > - <ul - class="sc-ac4a133f-2 fHCeXh" - role="tablist" - > - <li - aria-controls="react-tabs-5" - aria-disabled="false" - aria-selected="true" - class="sc-ac4a133f-3 faZqNG react-tabs__tab--selected" - data-rttab="true" - id="react-tabs-4" - role="tab" - tabindex="0" - > - CDI - </li> - <li - aria-controls="react-tabs-7" - aria-disabled="false" - aria-selected="false" - class="sc-ac4a133f-3 faZqNG" - data-rttab="true" - id="react-tabs-6" - role="tab" - > - CDD - </li> - </ul> - </div> - <div - aria-labelledby="react-tabs-4" - class="sc-ac4a133f-4 haGXHZ react-tabs__tab-panel--selected" - id="react-tabs-5" - role="tabpanel" - > - <div - class="sc-8dcb2faa-0 gxfPDw" - > - <h3 - class="sc-b879fc2d-0 hyiHle" - > - CDI - </h3> - </div> - <div - class="sc-ac4a133f-5 yflIk" - > - <h4 - class="sc-b879fc2d-0 hyiHle" - > - titre 1 - </h4> - <p> - paragraphe 1 - </p> - </div> - </div> - <div - aria-labelledby="react-tabs-6" - class="sc-ac4a133f-4 haGXHZ" - id="react-tabs-7" - role="tabpanel" - /> - </div> -</div> -`; - -exports[`<Tabulator /> should render 1`] = ` -<div> - <div - class="sc-ac4a133f-0 fvNPWb" - data-rttabs="true" - > - <div - class="sc-ac4a133f-1 fxZtdi" - > - <ul - class="sc-ac4a133f-2 fHCeXh" - role="tablist" - > - <li - aria-controls="react-tabs-9" - aria-disabled="false" - aria-selected="true" - class="sc-ac4a133f-3 faZqNG react-tabs__tab--selected" - data-rttab="true" - id="react-tabs-8" - role="tab" - tabindex="0" - > - CDI - </li> - <li - aria-controls="react-tabs-11" - aria-disabled="false" - aria-selected="false" - class="sc-ac4a133f-3 faZqNG" - data-rttab="true" - id="react-tabs-10" - role="tab" - > - CDD - </li> - </ul> - </div> - <div - aria-labelledby="react-tabs-8" - class="sc-ac4a133f-4 haGXHZ react-tabs__tab-panel--selected" - id="react-tabs-9" - role="tabpanel" - > - <div - class="sc-8dcb2faa-0 gxfPDw" - > - <h4 - class="sc-b879fc2d-0 hyiHle" - > - CDI - </h4> - </div> - <div - class="sc-ac4a133f-5 yflIk" - > - <h5 - class="sc-b879fc2d-0 hyiHle" - > - titre 1 - </h5> - <p> - paragraphe 1 - </p> - </div> - </div> - <div - aria-labelledby="react-tabs-10" - class="sc-ac4a133f-4 haGXHZ" - id="react-tabs-11" - role="tabpanel" - /> - </div> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Title.test.js.snap b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Title.test.js.snap deleted file mode 100644 index fa0c689d9b..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/__snapshots__/Title.test.js.snap +++ /dev/null @@ -1,17 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`<Title /> heading should default to H6 1`] = ` -<div> - <h6 - class="sc-b879fc2d-0 hyiHle" - /> -</div> -`; - -exports[`<Title /> should render a H{x} whose {x} is headingLevel + 2 1`] = ` -<div> - <h4 - class="sc-b879fc2d-0 hyiHle" - /> -</div> -`; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/accordionData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/accordionData.json deleted file mode 100644 index 5839bee8a6..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/accordionData.json +++ /dev/null @@ -1,178 +0,0 @@ -{ - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "titre 0" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 0" - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "titre 1" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 1-1" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 1-2" - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "titre 2" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 2-1" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 2-2" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "titre 2-1" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "titre 3" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 3-1" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 4" - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/fragmentConditionne.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/fragmentConditionne.json deleted file mode 100644 index d26a1476e9..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/fragmentConditionne.json +++ /dev/null @@ -1,445 +0,0 @@ -{ - "type": "element", - "name": "Chapitre", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Comment le saisir le médiateur de l'apprentissage ?" - } - ] - } - ] - }, - { - "type": "element", - "name": "FragmentConditionne", - "children": [ - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T10010" - } - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Le médiateur de l'apprentissage à saisir dépend de l'activité de l'entreprise. Il est désigné par la chambre consulaire." - } - ] - } - ] - }, - { - "type": "element", - "name": "BlocCas", - "attributes": { - "affichage": "onglet" - }, - "children": [ - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Commerce - industrie" - } - ] - }, - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T12518" - } - } - ] - }, - { - "type": "element", - "name": "FragmentConditionne", - "children": [ - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T12518" - } - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Il faut saisir la chambre de commerce et d'industrie." - } - ] - }, - { - "type": "element", - "name": "OuSAdresser", - "attributes": { - "ID": "R36", - "sve": "non", - "type": "Local personnalisé sur SP" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Chambre de commerce et d'industrie (CCI)" - } - ] - }, - { - "type": "element", - "name": "PivotLocal", - "children": [ - { - "type": "text", - "text": "cci" - } - ] - }, - { - "type": "element", - "name": "RessourceWeb", - "attributes": { - "URL": "http://www.cci.fr/web/organisation-du-reseau/annuaire" - } - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30752" - }, - "children": [ - { - "type": "text", - "text": "CCI France" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Artisanat" - } - ] - }, - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T12519" - } - } - ] - }, - { - "type": "element", - "name": "FragmentConditionne", - "children": [ - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T12519" - } - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Il faut saisir la chambre des métiers et de l'artisanat." - } - ] - }, - { - "type": "element", - "name": "OuSAdresser", - "attributes": { - "ID": "R37", - "sve": "non", - "type": "Local" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Chambre de métiers et de l'artisanat (CMA)" - } - ] - }, - { - "type": "element", - "name": "RessourceWeb", - "attributes": { - "URL": "https://www.artisanat.fr/reseau-des-cma/un-reseau-de-proximite/annuaire-des-cma" - } - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R57044" - }, - "children": [ - { - "type": "text", - "text": "Chambre des métiers et de l'artisanat (CMA)" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Agriculture" - } - ] - }, - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T12520" - } - } - ] - }, - { - "type": "element", - "name": "FragmentConditionne", - "children": [ - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T12520" - } - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Il faut saisir la chambre d'agriculture." - } - ] - }, - { - "type": "element", - "name": "OuSAdresser", - "attributes": { - "ID": "R35", - "sve": "non", - "type": "Local personnalisé sur SP" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Chambre d'agriculture" - } - ] - }, - { - "type": "element", - "name": "PivotLocal", - "children": [ - { - "type": "text", - "text": "chambre_agriculture" - } - ] - }, - { - "type": "element", - "name": "RessourceWeb", - "attributes": { - "URL": "https://chambres-agriculture.fr/chambres-dagriculture/nous-connaitre/lannuaire-des-chambres-dagriculture/" - } - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30771" - }, - "children": [ - { - "type": "text", - "text": "Assemblée permanente des chambres d'agriculture (APCA)" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cas", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Secteur public" - } - ] - }, - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T14730" - } - } - ] - }, - { - "type": "element", - "name": "FragmentConditionne", - "children": [ - { - "type": "element", - "name": "Condition", - "children": [ - { - "type": "element", - "name": "estVrai", - "attributes": { - "var": "T14730" - } - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Un service est chargé de la médiation pour les apprentis du secteur public non industriel et non commercial." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Dans certains ministères des médiateurs ont été nommés. Sinon, la médiation est assurée par le service des ressources humaines de proximité dont relève l'apprenti." - } - ] - } - ] - } - ] - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/image.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/image.json deleted file mode 100644 index 1d47c91fa0..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/image.json +++ /dev/null @@ -1,162 +0,0 @@ -{ - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Image", - "attributes": { - "LienPublication": "I4596.jpg", - "langue": "fr", - "poids": "594.96", - "format": "image/jpeg", - "type": "Image", - "redimensionnable": "oui" - }, - "children": [ - { - "type": "element", - "name": "Legende", - "children": [ - { - "type": "text", - "text": "Comment calculer un délai quand il y a un jour férié ?" - } - ] - }, - { - "type": "element", - "name": "Credits", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Service Public (DILA)" - } - ] - } - ] - }, - { - "type": "element", - "name": "TexteDeRemplacement", - "children": [ - { - "type": "text", - "text": "Comment calculer un délai quand il y a un jour férié ?" - } - ] - }, - { - "type": "element", - "name": "Description", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Comment calculer un délai quand il y a un jour férié ?" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Voici comment calculer un délai de 7 jours, selon que l'on parle de jours calendaires, francs, ouvrables ou ouvrés. Dans notre exemple, le délai commence un lundi et il y a un jour férié (le mercredi)." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "- Délai compté en jour calendaire : lundi + mardi + mercredi + jeudi + vendredi + samedi + dimanche" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Chaque jour compte." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "- Délai compté en jour franc : lundi + mardi + mercredi même si c'est un jour férié + jeudi + vendredi + samedi + lundi de la semaine suivante." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Report au jour suivant si le 7e jour tombe un samedi, un dimanche (comme c'est le cas dans notre exemple) ou un jour férié." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "- Délai compté en jour ouvrable : lundi + mardi + jeudi + vendredi + samedi + lundi de la semaine suivante + mardi de la semaine suivante." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "On ne compte pas le dimanche ni le jour férié." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "- Délai compté en jour ouvré : lundi + mardi + jeudi + vendredi + lundi de la semaine suivante + mardi de la semaine suivante + mercredi de la semaine suivante." - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "On ne compte pas le jour férié (ici mercredi), le samedi ni le dimanche." - } - ] - } - ] - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/lienExterneCommenteData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/lienExterneCommenteData.json deleted file mode 100644 index c81980539e..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/lienExterneCommenteData.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "type": "element", - "name": "LienExterneCommente", - "children": [ - { - "type": "element", - "name": "Commentaire", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Un contrat à durée déterminée (CDD) ne peut être conclu que pour l'exécution d'une tâche précise et temporaire et seulement dans les cas énumérés par la loi, et doit obligatoirement faire l'objet d'un écrit. Il ne doit pas pourvoir durablement un emploi lié à l'activité normale et permanente de l'entreprise. " - } - ] - } - ] - }, - { - "type": "element", - "name": "LienExterne", - "attributes": { - "URL": "http://travail-emploi.gouv.fr/droit-du-travail/contrats-et-carriere/contrats-de-travail/types-de-contrats/article/le-contrat-a-duree-determinee-cdd" - }, - "children": [ - { - "type": "text", - "text": "Fiche pratique sur le CDD" - } - ] - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30661" - }, - "children": [ - { - "type": "text", - "text": "Ministère chargé du travail" - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/lienExterneData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/lienExterneData.json deleted file mode 100644 index 015cb40896..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/lienExterneData.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "type": "element", - "name": "LienExterne", - "attributes": { - "URL": "https://formulaire.defenseurdesdroits.fr/code/afficher.php?ETAPE=accueil_2016" - }, - "children": [ - { - "type": "text", - "text": "formulaire de contact" - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/listData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/listData.json deleted file mode 100644 index 29f212e3c8..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/listData.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "type": "element", - "name": "Liste", - "attributes": { - "type": "puce" - }, - "children": [ - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "title" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Item", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "ok" - } - ] - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/ouSAdresserClassicData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/ouSAdresserClassicData.json deleted file mode 100644 index f9d0bd3079..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/ouSAdresserClassicData.json +++ /dev/null @@ -1,36 +0,0 @@ -{ - "type": "element", - "name": "OuSAdresser", - "attributes": { - "ID": "R14971", - "type": "pas pris en compte" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Nom du centre" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Un paragraphe tout bête" - } - ] - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/ouSAdresserWebData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/ouSAdresserWebData.json deleted file mode 100644 index daf9fb3f56..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/ouSAdresserWebData.json +++ /dev/null @@ -1,60 +0,0 @@ -{ - "type": "element", - "name": "OuSAdresser", - "attributes": { - "ID": "R11621", - "type": "pas pris en compte" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Label du lien !" - } - ] - }, - { - "type": "element", - "name": "Complement", - "children": [ - { - "type": "text", - "text": "pas pris en compte" - } - ] - }, - { - "type": "element", - "name": "PivotLocal", - "children": [ - { - "type": "text", - "text": "par pris en compte" - } - ] - }, - { - "type": "element", - "name": "RessourceWeb", - "attributes": { - "URL": "url du lien" - } - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30663" - }, - "children": [ - { - "type": "text", - "text": "pas pris en compte" - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/serviceEnLigneData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/serviceEnLigneData.json deleted file mode 100644 index b948f3dd4e..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/serviceEnLigneData.json +++ /dev/null @@ -1,34 +0,0 @@ -{ - "type": "element", - "name": "ServiceEnLigne", - "attributes": { - "ID": "un id", - "URL": "url à retoruver dans le lien", - "type": "Se retrouve dans en entête" - }, - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Texte qui se retrouve dans le lien" - } - ] - }, - { - "type": "element", - "name": "Source", - "attributes": { - "ID": "R30608" - }, - "children": [ - { - "type": "text", - "text": "Source qui se retrouve sous le lien" - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/tableData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/tableData.json deleted file mode 100644 index 1bce5b99ae..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/tableData.json +++ /dev/null @@ -1,1897 +0,0 @@ -{ - "type": "element", - "name": "Tableau", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "Conditions ouvrant droit à la retraite anticipée pour carrière longue" - } - ] - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "13", - "type": "header" - } - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "19", - "type": "normal" - } - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "19", - "type": "normal" - } - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "28", - "type": "normal" - } - }, - { - "type": "element", - "name": "Colonne", - "attributes": { - "largeur": "28", - "type": "normal" - } - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "header" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Année de naissance" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Âge de départ à la retraite envisagé (à partir de)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée d'assurance minimale cotisée (en trimestres)" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionHorizontale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Durée d'assurance minimale en début de carrière" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "header" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si vous êtes né entre janvier et septembre" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "Si vous êtes né entre octobre et décembre" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1959" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "57 ans et 8 mois" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "175" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "60 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "167" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1960" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "58 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "175" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "60 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "167" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1961, 1962 ou 1963" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "58 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "176" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "60 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "168" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1964, 1965 ou 1966" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "58 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "177" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "60 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "169" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1967, 1968 ou 1969" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "58 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "178" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "60 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "170" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "1970, 1971 ou 1972" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "58 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "179" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "60 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "171" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "attributes": { - "fusionVerticale": "2" - }, - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "À partir de 1973" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "58 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "180" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "16 ans" - } - ] - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Rangée", - "attributes": { - "type": "normal" - }, - "children": [ - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "60 ans" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "172" - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "5" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Cellule", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "4" - } - ] - }, - { - "type": "text", - "text": " trimestres à la fin de l'année des " - }, - { - "type": "element", - "name": "MiseEnEvidence", - "children": [ - { - "type": "text", - "text": "20 ans" - } - ] - } - ] - } - ] - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/tabulatorData.json b/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/tabulatorData.json deleted file mode 100644 index f7b54887c6..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/components/__tests__/mocks/tabulatorData.json +++ /dev/null @@ -1,115 +0,0 @@ -{ - "type": "element", - "name": "ListeSituations", - "attributes": { - "affichage": "onglet" - }, - "children": [ - { - "type": "element", - "name": "Situation", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "CDI" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "titre 1" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 1" - } - ] - } - ] - } - ] - }, - { - "type": "element", - "name": "Situation", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "text", - "text": "CDD" - } - ] - }, - { - "type": "element", - "name": "Texte", - "children": [ - { - "type": "element", - "name": "Titre", - "children": [ - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "titre 2" - } - ] - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 2-1" - } - ] - }, - { - "type": "element", - "name": "Paragraphe", - "children": [ - { - "type": "text", - "text": "paragraphe 2-2" - } - ] - } - ] - } - ] - } - ] -} diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/index.ts b/packages/code-du-travail-frontend/src/fiche-service-public/index.ts deleted file mode 100644 index 359422b17f..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { FicheServicePublic } from "./components/Fiche.js"; diff --git a/packages/code-du-travail-frontend/src/fiche-service-public/utils.js b/packages/code-du-travail-frontend/src/fiche-service-public/utils.js deleted file mode 100644 index d782b8b165..0000000000 --- a/packages/code-du-travail-frontend/src/fiche-service-public/utils.js +++ /dev/null @@ -1,26 +0,0 @@ -// beware, this one is recursive -export function getText(element = { text: "" }, separator = " ") { - if (element.type === "text") { - return element.text.trim(); - } - if (element.children) { - return element.children - .map((child) => getText(child, separator)) - .join(separator); - } - if (Array.isArray(element)) { - return element.map((child) => getText(child, separator)).join(separator); - } - return ""; -} - -export const ignoreParagraph = (element) => - element.children.map((child) => { - if (child.name === "Texte") { - return ignoreParagraph(child); - } - if (child.name === "Paragraphe") { - return child.children; - } - return child; - }); From 9a81eafc2e5ef8ff3bbb64749462f9c00170c31a Mon Sep 17 00:00:00 2001 From: carolineBda <caroline.bourdeu@gmail.com> Date: Tue, 4 Feb 2025 17:01:37 +0100 Subject: [PATCH 3/4] fix test --- .../DisplayContentContribution.test.tsx.snap | 198 +++++++++--------- 1 file changed, 99 insertions(+), 99 deletions(-) diff --git a/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/DisplayContentContribution.test.tsx.snap b/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/DisplayContentContribution.test.tsx.snap index 9cd3a073a8..f47ce83d9e 100644 --- a/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/DisplayContentContribution.test.tsx.snap +++ b/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/DisplayContentContribution.test.tsx.snap @@ -3,10 +3,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag 1`] = ` <div> <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <div - class="sc-10167302-1 hzFSzJ" + class="sc-ba8fc922-1 eSDyqW" data-accordion-component="Accordion" data-testid="contrib-accordion" > @@ -14,7 +14,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="report-ou-suspension-du-preavis" > <div - class="sc-1571bed7-0" + class="sc-6ba2e448-0 wqwqk" data-accordion-component="AccordionItem" > <div @@ -25,7 +25,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-report-ou-suspension-du-preavis" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-report-ou-suspension-du-preavis" role="button" @@ -33,7 +33,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -49,10 +49,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h3 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -63,13 +63,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-report-ou-suspension-du-preavis" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <p> @@ -80,7 +80,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </p> <div - class="sc-10167302-1 hzFSzJ" + class="sc-ba8fc922-1 eSDyqW" data-accordion-component="Accordion" data-testid="contrib-accordion" > @@ -88,7 +88,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="conges-payes" > <div - class="sc-1571bed7-0" + class="sc-6ba2e448-0 wqwqk" data-accordion-component="AccordionItem" > <div @@ -99,7 +99,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-conges-payes" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-conges-payes" role="button" @@ -107,7 +107,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -123,10 +123,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h4 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -137,17 +137,17 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-conges-payes" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <div - class="sc-10167302-1 hzFSzJ" + class="sc-ba8fc922-1 eSDyqW" data-accordion-component="Accordion" data-testid="contrib-accordion" > @@ -155,7 +155,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="dates-des-conges-fixees-avant-la-notification-du-licenciement" > <div - class="sc-1571bed7-0" + class="sc-6ba2e448-0 wqwqk" data-accordion-component="AccordionItem" > <div @@ -166,7 +166,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-dates-des-conges-fixees-avant-la-notification-du-licenciement" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-dates-des-conges-fixees-avant-la-notification-du-licenciement" role="button" @@ -174,7 +174,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -190,10 +190,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h5 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -206,13 +206,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-dates-des-conges-fixees-avant-la-notification-du-licenciement" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <p> @@ -232,7 +232,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="dates-des-conges-fixees-apres-la-notification-du-licenciement" > <div - class="sc-1571bed7-0 dpEeGj" + class="sc-6ba2e448-0 gAQMVA" data-accordion-component="AccordionItem" > <div @@ -243,7 +243,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-dates-des-conges-fixees-apres-la-notification-du-licenciement" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-dates-des-conges-fixees-apres-la-notification-du-licenciement" role="button" @@ -251,7 +251,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -267,10 +267,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h5 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-1" style="margin: 0px;" > @@ -283,13 +283,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-dates-des-conges-fixees-apres-la-notification-du-licenciement" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <p> @@ -310,7 +310,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="licenciement-notifie-pendant-les-conges-payes" > <div - class="sc-1571bed7-0 dpEeGj" + class="sc-6ba2e448-0 gAQMVA" data-accordion-component="AccordionItem" > <div @@ -321,7 +321,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-licenciement-notifie-pendant-les-conges-payes" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-licenciement-notifie-pendant-les-conges-payes" role="button" @@ -329,7 +329,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -345,10 +345,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h5 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-2" style="margin: 0px;" > @@ -359,13 +359,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-licenciement-notifie-pendant-les-conges-payes" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <p> @@ -397,10 +397,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag exports[`DisplayContentContribution Accordions should replace details element by one accordion 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <div - class="sc-10167302-1 hzFSzJ" + class="sc-ba8fc922-1 eSDyqW" data-accordion-component="Accordion" data-testid="contrib-accordion" > @@ -408,7 +408,7 @@ exports[`DisplayContentContribution Accordions should replace details element by id="ceci-est-un-titre" > <div - class="sc-1571bed7-0" + class="sc-6ba2e448-0 wqwqk" data-accordion-component="AccordionItem" > <div @@ -419,7 +419,7 @@ exports[`DisplayContentContribution Accordions should replace details element by aria-controls="accordion__panel-ceci-est-un-titre" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-un-titre" role="button" @@ -427,7 +427,7 @@ exports[`DisplayContentContribution Accordions should replace details element by > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -443,10 +443,10 @@ exports[`DisplayContentContribution Accordions should replace details element by /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h3 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -457,13 +457,13 @@ exports[`DisplayContentContribution Accordions should replace details element by </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-un-titre" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <p> @@ -481,10 +481,10 @@ exports[`DisplayContentContribution Accordions should replace details element by exports[`DisplayContentContribution Accordions should replace details element within details element 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <div - class="sc-10167302-1 hzFSzJ" + class="sc-ba8fc922-1 eSDyqW" data-accordion-component="Accordion" data-testid="contrib-accordion" > @@ -492,7 +492,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi id="ceci-est-un-titre" > <div - class="sc-1571bed7-0" + class="sc-6ba2e448-0 wqwqk" data-accordion-component="AccordionItem" > <div @@ -503,7 +503,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi aria-controls="accordion__panel-ceci-est-un-titre" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-un-titre" role="button" @@ -511,7 +511,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -527,10 +527,10 @@ exports[`DisplayContentContribution Accordions should replace details element wi /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h3 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -541,17 +541,17 @@ exports[`DisplayContentContribution Accordions should replace details element wi </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-un-titre" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <div - class="sc-10167302-1 hzFSzJ" + class="sc-ba8fc922-1 eSDyqW" data-accordion-component="Accordion" data-testid="contrib-accordion" > @@ -559,7 +559,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi id="ceci-est-un-sous-titre" > <div - class="sc-1571bed7-0" + class="sc-6ba2e448-0 wqwqk" data-accordion-component="AccordionItem" > <div @@ -570,7 +570,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi aria-controls="accordion__panel-ceci-est-un-sous-titre" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-un-sous-titre" role="button" @@ -578,7 +578,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -594,10 +594,10 @@ exports[`DisplayContentContribution Accordions should replace details element wi /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h4 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -608,13 +608,13 @@ exports[`DisplayContentContribution Accordions should replace details element wi </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-un-sous-titre" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <p> @@ -640,10 +640,10 @@ exports[`DisplayContentContribution Accordions should replace multiple details e <body> <div> <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <div - class="sc-10167302-1 hzFSzJ" + class="sc-ba8fc922-1 eSDyqW" data-accordion-component="Accordion" data-testid="contrib-accordion" > @@ -651,7 +651,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e id="ceci-est-le-titre-1" > <div - class="sc-1571bed7-0" + class="sc-6ba2e448-0 wqwqk" data-accordion-component="AccordionItem" > <div @@ -662,7 +662,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e aria-controls="accordion__panel-ceci-est-le-titre-1" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-le-titre-1" role="button" @@ -670,7 +670,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -686,10 +686,10 @@ exports[`DisplayContentContribution Accordions should replace multiple details e /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h3 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -700,13 +700,13 @@ exports[`DisplayContentContribution Accordions should replace multiple details e </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-le-titre-1" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <p> @@ -722,7 +722,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e id="ceci-est-le-titre-2" > <div - class="sc-1571bed7-0 dpEeGj" + class="sc-6ba2e448-0 gAQMVA" data-accordion-component="AccordionItem" > <div @@ -733,7 +733,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e aria-controls="accordion__panel-ceci-est-le-titre-2" aria-disabled="false" aria-expanded="false" - class="sc-1571bed7-2 gNtlHI" + class="sc-6ba2e448-2 dhbWmA" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-le-titre-2" role="button" @@ -741,7 +741,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e > <svg aria-hidden="true" - class="sc-93c68677-0 fWneNg" + class="sc-efc7f1fd-0 cFvIxv" fill="none" height="24" stroke="currentColor" @@ -757,10 +757,10 @@ exports[`DisplayContentContribution Accordions should replace multiple details e /> </svg> <div - class="sc-1571bed7-3 figaQV" + class="sc-6ba2e448-3 dhjOwJ" > <h3 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" data-testid="contrib-accordion-1" style="margin: 0px;" > @@ -771,13 +771,13 @@ exports[`DisplayContentContribution Accordions should replace multiple details e </div> <div aria-hidden="true" - class="sc-1571bed7-1 hamHiw" + class="sc-6ba2e448-1 cDSlef" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-le-titre-2" > <div - class="sc-32c7807-0 iMDCLs" + class="sc-8fc9f174-0 glbEDc" > <div> <p> @@ -797,7 +797,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e exports[`DisplayContentContribution Alerts should have space in table item for a strong and an other content 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <table class="sc-4e3ba411-0 kGLBMt" @@ -877,7 +877,7 @@ exports[`DisplayContentContribution Alerts should have space in table item for a exports[`DisplayContentContribution Alerts should replace div with alert class in li component to Alert component 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <div> <p> @@ -926,7 +926,7 @@ exports[`DisplayContentContribution Alerts should replace div with alert class i </p> <br /> <div - class="sc-6c78813f-0 fnbVWG" + class="sc-35146c68-0 eYIxsm" > <p> <strong> @@ -943,10 +943,10 @@ exports[`DisplayContentContribution Alerts should replace div with alert class i exports[`DisplayContentContribution Alerts should replace div with alert class to Alert component 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <div - class="sc-6c78813f-0 fnbVWG" + class="sc-35146c68-0 eYIxsm" > <p> <strong> @@ -961,15 +961,15 @@ exports[`DisplayContentContribution Alerts should replace div with alert class t exports[`DisplayContentContribution Headings should replace span with class "title" and "sub-titles" with heading 1`] = ` <div> <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <h2 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" > Mon titre </h2> <h3 - class="sc-b879fc2d-0 hyiHle" + class="sc-a53a0f9a-0 bIsTsN" > Mon sous titre </h3> @@ -979,10 +979,10 @@ exports[`DisplayContentContribution Headings should replace span with class "tit exports[`DisplayContentContribution Tables should add thead to table if not present and move table into a Table element 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <table - class="sc-4e3ba411-0 kKVapO" + class="sc-6d9f376d-0 iugiNe" > <thead> <tr> @@ -1034,7 +1034,7 @@ exports[`DisplayContentContribution Tables should add thead to table if not pres exports[`DisplayContentContribution Tables should keep whitespace in specific tag 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <p> Ceci est un @@ -1064,7 +1064,7 @@ exports[`DisplayContentContribution Tables should keep whitespace in specific ta exports[`DisplayContentContribution Tables should not change if thead is already present 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <table> <tbody> @@ -1102,10 +1102,10 @@ exports[`DisplayContentContribution Tables should not change if thead is already exports[`DisplayContentContribution Tables should render correctly a table with multiple head lines 1`] = ` <div> <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <table - class="sc-4e3ba411-0 kKVapO" + class="sc-6d9f376d-0 iugiNe" > <thead> <tr> @@ -1232,7 +1232,7 @@ exports[`DisplayContentContribution Tables should render correctly a table with exports[`DisplayContentContribution Tables should replace td by th in thead 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <table> <tbody> @@ -1269,7 +1269,7 @@ exports[`DisplayContentContribution Tables should replace td by th in thead 1`] exports[`DisplayContentContribution should keep whitespace in specific tag 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <p> Ceci est un @@ -1299,7 +1299,7 @@ exports[`DisplayContentContribution should keep whitespace in specific tag 1`] = exports[`DisplayContentContribution should not remove space between strong and em tag in p tag 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <p> <strong> @@ -1315,7 +1315,7 @@ exports[`DisplayContentContribution should not remove space between strong and e exports[`DisplayContentContribution should return html 1`] = ` <div - class="sc-10167302-0 dCJsPi" + class="sc-ba8fc922-0 jVfsbN" > <p> hello From 661b621603234eee66fb4bc51eb1a0f291397723 Mon Sep 17 00:00:00 2001 From: carolineBda <caroline.bourdeu@gmail.com> Date: Tue, 4 Feb 2025 17:15:35 +0100 Subject: [PATCH 4/4] fix test --- .../DisplayContentContribution.test.tsx.snap | 152 +++++++++--------- 1 file changed, 76 insertions(+), 76 deletions(-) diff --git a/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/DisplayContentContribution.test.tsx.snap b/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/DisplayContentContribution.test.tsx.snap index f47ce83d9e..3397148a7c 100644 --- a/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/DisplayContentContribution.test.tsx.snap +++ b/packages/code-du-travail-frontend/src/contributions/__tests__/__snapshots__/DisplayContentContribution.test.tsx.snap @@ -14,7 +14,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="report-ou-suspension-du-preavis" > <div - class="sc-6ba2e448-0 wqwqk" + class="sc-1571bed7-0" data-accordion-component="AccordionItem" > <div @@ -25,7 +25,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-report-ou-suspension-du-preavis" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-report-ou-suspension-du-preavis" role="button" @@ -33,7 +33,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -49,10 +49,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h3 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -63,13 +63,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-report-ou-suspension-du-preavis" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <p> @@ -88,7 +88,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="conges-payes" > <div - class="sc-6ba2e448-0 wqwqk" + class="sc-1571bed7-0" data-accordion-component="AccordionItem" > <div @@ -99,7 +99,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-conges-payes" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-conges-payes" role="button" @@ -107,7 +107,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -123,10 +123,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h4 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -137,13 +137,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-conges-payes" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <div @@ -155,7 +155,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="dates-des-conges-fixees-avant-la-notification-du-licenciement" > <div - class="sc-6ba2e448-0 wqwqk" + class="sc-1571bed7-0" data-accordion-component="AccordionItem" > <div @@ -166,7 +166,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-dates-des-conges-fixees-avant-la-notification-du-licenciement" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-dates-des-conges-fixees-avant-la-notification-du-licenciement" role="button" @@ -174,7 +174,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -190,10 +190,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h5 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -206,13 +206,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-dates-des-conges-fixees-avant-la-notification-du-licenciement" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <p> @@ -232,7 +232,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="dates-des-conges-fixees-apres-la-notification-du-licenciement" > <div - class="sc-6ba2e448-0 gAQMVA" + class="sc-1571bed7-0 dpEeGj" data-accordion-component="AccordionItem" > <div @@ -243,7 +243,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-dates-des-conges-fixees-apres-la-notification-du-licenciement" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-dates-des-conges-fixees-apres-la-notification-du-licenciement" role="button" @@ -251,7 +251,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -267,10 +267,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h5 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-1" style="margin: 0px;" > @@ -283,13 +283,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-dates-des-conges-fixees-apres-la-notification-du-licenciement" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <p> @@ -310,7 +310,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag id="licenciement-notifie-pendant-les-conges-payes" > <div - class="sc-6ba2e448-0 gAQMVA" + class="sc-1571bed7-0 dpEeGj" data-accordion-component="AccordionItem" > <div @@ -321,7 +321,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag aria-controls="accordion__panel-licenciement-notifie-pendant-les-conges-payes" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-licenciement-notifie-pendant-les-conges-payes" role="button" @@ -329,7 +329,7 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -345,10 +345,10 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h5 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-2" style="margin: 0px;" > @@ -359,13 +359,13 @@ exports[`DisplayContentContribution Accordions should not fail if no summary tag </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-licenciement-notifie-pendant-les-conges-payes" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <p> @@ -408,7 +408,7 @@ exports[`DisplayContentContribution Accordions should replace details element by id="ceci-est-un-titre" > <div - class="sc-6ba2e448-0 wqwqk" + class="sc-1571bed7-0" data-accordion-component="AccordionItem" > <div @@ -419,7 +419,7 @@ exports[`DisplayContentContribution Accordions should replace details element by aria-controls="accordion__panel-ceci-est-un-titre" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-un-titre" role="button" @@ -427,7 +427,7 @@ exports[`DisplayContentContribution Accordions should replace details element by > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -443,10 +443,10 @@ exports[`DisplayContentContribution Accordions should replace details element by /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h3 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -457,13 +457,13 @@ exports[`DisplayContentContribution Accordions should replace details element by </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-un-titre" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <p> @@ -492,7 +492,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi id="ceci-est-un-titre" > <div - class="sc-6ba2e448-0 wqwqk" + class="sc-1571bed7-0" data-accordion-component="AccordionItem" > <div @@ -503,7 +503,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi aria-controls="accordion__panel-ceci-est-un-titre" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-un-titre" role="button" @@ -511,7 +511,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -527,10 +527,10 @@ exports[`DisplayContentContribution Accordions should replace details element wi /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h3 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -541,13 +541,13 @@ exports[`DisplayContentContribution Accordions should replace details element wi </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-un-titre" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <div @@ -559,7 +559,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi id="ceci-est-un-sous-titre" > <div - class="sc-6ba2e448-0 wqwqk" + class="sc-1571bed7-0" data-accordion-component="AccordionItem" > <div @@ -570,7 +570,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi aria-controls="accordion__panel-ceci-est-un-sous-titre" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-un-sous-titre" role="button" @@ -578,7 +578,7 @@ exports[`DisplayContentContribution Accordions should replace details element wi > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -594,10 +594,10 @@ exports[`DisplayContentContribution Accordions should replace details element wi /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h4 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -608,13 +608,13 @@ exports[`DisplayContentContribution Accordions should replace details element wi </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-un-sous-titre" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <p> @@ -651,7 +651,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e id="ceci-est-le-titre-1" > <div - class="sc-6ba2e448-0 wqwqk" + class="sc-1571bed7-0" data-accordion-component="AccordionItem" > <div @@ -662,7 +662,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e aria-controls="accordion__panel-ceci-est-le-titre-1" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-le-titre-1" role="button" @@ -670,7 +670,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -686,10 +686,10 @@ exports[`DisplayContentContribution Accordions should replace multiple details e /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h3 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-0" style="margin: 0px;" > @@ -700,13 +700,13 @@ exports[`DisplayContentContribution Accordions should replace multiple details e </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-le-titre-1" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <p> @@ -722,7 +722,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e id="ceci-est-le-titre-2" > <div - class="sc-6ba2e448-0 gAQMVA" + class="sc-1571bed7-0 dpEeGj" data-accordion-component="AccordionItem" > <div @@ -733,7 +733,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e aria-controls="accordion__panel-ceci-est-le-titre-2" aria-disabled="false" aria-expanded="false" - class="sc-6ba2e448-2 dhbWmA" + class="sc-1571bed7-2 gNtlHI" data-accordion-component="AccordionItemButton" id="accordion__heading-ceci-est-le-titre-2" role="button" @@ -741,7 +741,7 @@ exports[`DisplayContentContribution Accordions should replace multiple details e > <svg aria-hidden="true" - class="sc-efc7f1fd-0 cFvIxv" + class="sc-93c68677-0 fWneNg" fill="none" height="24" stroke="currentColor" @@ -757,10 +757,10 @@ exports[`DisplayContentContribution Accordions should replace multiple details e /> </svg> <div - class="sc-6ba2e448-3 dhjOwJ" + class="sc-1571bed7-3 figaQV" > <h3 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" data-testid="contrib-accordion-1" style="margin: 0px;" > @@ -771,13 +771,13 @@ exports[`DisplayContentContribution Accordions should replace multiple details e </div> <div aria-hidden="true" - class="sc-6ba2e448-1 cDSlef" + class="sc-1571bed7-1 hamHiw" data-accordion-component="AccordionItemPanel" hidden="" id="accordion__panel-ceci-est-le-titre-2" > <div - class="sc-8fc9f174-0 glbEDc" + class="sc-32c7807-0 iMDCLs" > <div> <p> @@ -926,7 +926,7 @@ exports[`DisplayContentContribution Alerts should replace div with alert class i </p> <br /> <div - class="sc-35146c68-0 eYIxsm" + class="sc-6c78813f-0 fnbVWG" > <p> <strong> @@ -946,7 +946,7 @@ exports[`DisplayContentContribution Alerts should replace div with alert class t class="sc-ba8fc922-0 jVfsbN" > <div - class="sc-35146c68-0 eYIxsm" + class="sc-6c78813f-0 fnbVWG" > <p> <strong> @@ -964,12 +964,12 @@ exports[`DisplayContentContribution Headings should replace span with class "tit class="sc-ba8fc922-0 jVfsbN" > <h2 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" > Mon titre </h2> <h3 - class="sc-a53a0f9a-0 bIsTsN" + class="sc-b879fc2d-0 hyiHle" > Mon sous titre </h3> @@ -982,7 +982,7 @@ exports[`DisplayContentContribution Tables should add thead to table if not pres class="sc-ba8fc922-0 jVfsbN" > <table - class="sc-6d9f376d-0 iugiNe" + class="sc-4e3ba411-0 kKVapO" > <thead> <tr> @@ -1105,7 +1105,7 @@ exports[`DisplayContentContribution Tables should render correctly a table with class="sc-ba8fc922-0 jVfsbN" > <table - class="sc-6d9f376d-0 iugiNe" + class="sc-4e3ba411-0 kKVapO" > <thead> <tr>