File tree Expand file tree Collapse file tree 3 files changed +18
-4
lines changed
backend/impress/configuration/theme
frontend/apps/impress/src
features/left-panel/components Expand file tree Collapse file tree 3 files changed +18
-4
lines changed Original file line number Diff line number Diff line change 11{
2+ "onboarding" : {
3+ "learn_more_url" : " "
4+ },
25 "footer" : {
36 "default" : {
47 "logo" : {
Original file line number Diff line number Diff line change @@ -16,6 +16,9 @@ interface ThemeCustomization {
1616 light : LinkHTMLAttributes < HTMLLinkElement > ;
1717 dark : LinkHTMLAttributes < HTMLLinkElement > ;
1818 } ;
19+ onboarding ?: {
20+ learn_more_url ?: string ;
21+ } ;
1922 footer ?: FooterType ;
2023 home : {
2124 'with-proconnect' ?: boolean ;
Original file line number Diff line number Diff line change @@ -5,13 +5,15 @@ import { useTranslation } from 'react-i18next';
55import { css } from 'styled-components' ;
66
77import { Box } from '@/components' ;
8+ import { useConfig } from '@/core/config/api' ;
89import { OnBoarding } from '@/features/on-boarding/components/OnBoarding' ;
910
1011import HelpOutlineIcon from '../assets/help-outline.svg' ;
1112import WandAndStarsIcon from '../assets/wand-and-stars.svg' ;
1213
1314export const LeftPanelHelpMenu = ( ) => {
1415 const { t } = useTranslation ( ) ;
16+ const { data : config } = useConfig ( ) ;
1517 const [ isMenuOpen , setIsMenuOpen ] = useState ( false ) ;
1618 const [ isModalOpen , setIsModalOpen ] = useState ( false ) ;
1719
@@ -37,6 +39,8 @@ export const LeftPanelHelpMenu = () => {
3739 ] ,
3840 [ openModal , t ] ,
3941 ) ;
42+ const learnMoreUrl =
43+ config ?. theme_customization ?. onboarding ?. learn_more_url ?. trim ( ) ;
4044
4145 return (
4246 < >
@@ -70,10 +74,14 @@ export const LeftPanelHelpMenu = () => {
7074 isOpen = { isModalOpen }
7175 onClose = { closeModal }
7276 onSkip = { closeModal }
73- footerLink = { {
74- label : t ( 'Learn more docs features' ) ,
75- href : 'https://docs.numerique.gouv.fr/docs/335e43b5-9e16-4798-a0b4-912e44c7135e/' ,
76- } }
77+ footerLink = {
78+ learnMoreUrl
79+ ? {
80+ label : t ( 'Learn more docs features' ) ,
81+ href : learnMoreUrl ,
82+ }
83+ : undefined
84+ }
7785 />
7886 </ >
7987 ) ;
You can’t perform that action at this time.
0 commit comments