From 0adbc91afa8d41eae2385f82d5a3d260908e5e7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20PAILHAREY?= <rpailharey@grandlyon.com> Date: Tue, 31 Oct 2023 14:54:27 +0000 Subject: [PATCH] feat: updated case of ecolyo links --- src/components/Newsletter/CustomLink.tsx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/components/Newsletter/CustomLink.tsx b/src/components/Newsletter/CustomLink.tsx index ec22c523..0a349213 100644 --- a/src/components/Newsletter/CustomLink.tsx +++ b/src/components/Newsletter/CustomLink.tsx @@ -23,7 +23,7 @@ const CustomLink: React.FC<EcolyoLinkProps> = ({ onChange, editorState }) => { link: 'ecogestures', }, { - displayTitle: 'Sélection des astuces', + displayTitle: 'Sélection des Astuces', link: 'ecogesture-selection', }, { @@ -36,9 +36,7 @@ const CustomLink: React.FC<EcolyoLinkProps> = ({ onChange, editorState }) => { }, ] const appendLink = (link: LinkState) => { - const data = `<a href="{cozyUrl}${ - link.link - }">${link.displayTitle.toLowerCase()}</a>` + const data = `<a href="{cozyUrl}${link.link}">${link.displayTitle}</a>` const { contentBlocks, entityMap } = htmlToDraft(data) const contentState = Modifier.replaceWithFragment( -- GitLab