@@ -160,7 +160,7 @@ const OnboardingChecklist = () => {
160160 return ( ) => window . removeEventListener ( "scroll" , handleScroll ) ;
161161 } , [ checklist ] ) ;
162162
163- const toggleStep = ( stepId , subStepId ) => {
163+ const toggleStep = ( stepId : string , subStepId : string ) => {
164164 setChecklist ( ( prevChecklist ) =>
165165 prevChecklist . map ( ( step ) =>
166166 step . id === stepId
@@ -199,9 +199,9 @@ const OnboardingChecklist = () => {
199199 }
200200 } ;
201201
202- const scrollToSection = ( sectionId ) => {
202+ const scrollToSection = ( sectionId : string ) => {
203203 // Try to find the element by either sectionId or by h2/h3 text content
204- let element = document . getElementById ( sectionId ) ;
204+ let element : HTMLElement | null = document . getElementById ( sectionId ) ;
205205
206206 if ( ! element ) {
207207 // Try to find via heading text if ID isn't found
@@ -215,7 +215,8 @@ const OnboardingChecklist = () => {
215215
216216 for ( const heading of headingsArray ) {
217217 if ( heading . textContent && heading . textContent . includes ( step . title ) ) {
218- element = heading ;
218+ // Cast to HTMLElement to fix TypeScript error
219+ element = heading as HTMLElement ;
219220 break ;
220221 }
221222 }
@@ -366,7 +367,9 @@ const OnboardingChecklist = () => {
366367 boxShadow : "0 4px 8px rgba(0, 0, 0, 0.1)" ,
367368 transition : "transform 0.3s ease" ,
368369 zIndex : 999 ,
369- backgroundColor : colors . primary ,
370+ backgroundColor : isDarkMode
371+ ? colors . primaryDarker
372+ : colors . primaryLightest ,
370373 } }
371374 >
372375 < div
@@ -822,7 +825,9 @@ const OnboardingChecklist = () => {
822825 justifyContent : "space-between" ,
823826 alignItems : "center" ,
824827 padding : "0.75rem 1rem" ,
825- backgroundColor : colors . primary ,
828+ backgroundColor : isDarkMode
829+ ? colors . primaryDarker
830+ : colors . primaryLightest ,
826831 color : "white" ,
827832 } }
828833 >
@@ -885,7 +890,7 @@ const OnboardingChecklist = () => {
885890 cursor : "pointer" ,
886891 backgroundColor :
887892 status . docSection === activeSection
888- ? `rgba(${ isDarkMode ? "109, 168, 254" : "13, 110, 253" } , 0.08)`
893+ ? `rgba(var(--ifm-color-primary-rgb) , 0.08)`
889894 : "transparent" ,
890895 borderLeft :
891896 status . docSection === activeSection
0 commit comments