11import { type OnboardingStep } from '@gouvfr-lasuite/ui-kit' ;
2+ import Image from 'next/image' ;
23import { useMemo } from 'react' ;
34import { useTranslation } from 'react-i18next' ;
45
@@ -9,7 +10,6 @@ import FileShareIcon from '../assets/file-share.svg';
910import FormatTextIcon from '../assets/format-text.svg' ;
1011import StackTemplateIcon from '../assets/stack-template.svg' ;
1112import { OnboardingStepIcon } from '../components/OnboardingStepIcon' ;
12- import { OnboardingStepImage } from '../components/OnboardingStepImage' ;
1313
1414export interface OnboardingStepsData {
1515 steps : OnboardingStep [ ] ;
@@ -41,12 +41,16 @@ export const useOnboardingSteps = () => {
4141 'Move, duplicate, and transform your texts, headings, lists, images without breaking your layout.' ,
4242 ) ,
4343 content : (
44- < OnboardingStepImage
44+ < Image
4545 src = { t ( 'src_img_onboarding_step_1' , {
4646 desc : 'URL of onboarding step 1 preview image' ,
4747 defaultValue : '/assets/on-boarding/step_1_EN.gif' ,
4848 } ) }
4949 alt = { t ( 'Compose your doc easily' ) }
50+ width = { 350 }
51+ height = { 350 }
52+ priority
53+ unoptimized
5054 />
5155 ) ,
5256 } ,
@@ -66,12 +70,16 @@ export const useOnboardingSteps = () => {
6670 'Apply styles, structure, and emphasis in one click—keep documents clean, consistent, and easy to scan.' ,
6771 ) ,
6872 content : (
69- < OnboardingStepImage
73+ < Image
7074 src = { t ( 'src_img_onboarding_step_2' , {
7175 desc : 'URL of onboarding step 2 preview image' ,
7276 defaultValue : '/assets/on-boarding/step_2_EN.gif' ,
7377 } ) }
7478 alt = { t ( 'Format your content with the toolbar' ) }
79+ width = { 350 }
80+ height = { 350 }
81+ priority
82+ unoptimized
7583 />
7684 ) ,
7785 } ,
@@ -91,12 +99,16 @@ export const useOnboardingSteps = () => {
9199 'Decide exactly who can view, comment, edit—or simply use shareable links.' ,
92100 ) ,
93101 content : (
94- < OnboardingStepImage
102+ < Image
95103 src = { t ( 'src_img_onboarding_step_3' , {
96104 desc : 'URL of onboarding step 3 preview image' ,
97105 defaultValue : '/assets/on-boarding/step_3_EN.png' ,
98106 } ) }
99107 alt = { t ( 'Share and collaborate with ease' ) }
108+ width = { 350 }
109+ height = { 350 }
110+ priority
111+ unoptimized
100112 />
101113 ) ,
102114 } ,
@@ -116,12 +128,16 @@ export const useOnboardingSteps = () => {
116128 'Start from ready-made templates for common use cases, then customize them to match your workflow in minutes.' ,
117129 ) ,
118130 content : (
119- < OnboardingStepImage
131+ < Image
120132 src = { t ( 'src_img_onboarding_step_4' , {
121133 desc : 'URL of onboarding step 4 preview image' ,
122134 defaultValue : '/assets/on-boarding/step_4_EN.png' ,
123135 } ) }
124136 alt = { t ( 'Draw inspiration from the content library' ) }
137+ width = { 350 }
138+ height = { 350 }
139+ priority
140+ unoptimized
125141 />
126142 ) ,
127143 } ,
0 commit comments