@@ -14,7 +14,6 @@ import {
1414import { RibbonPickerComponent } from "@/features/common/components/bars/ribbon/ribbon-picker/ribbon-picker.component" ;
1515import { LightIconComponent } from "@/features/common/components/bars/ribbon/assets/light-icon.component" ;
1616import { DarkIconComponent } from "@/features/common/components/bars/ribbon/assets/dark-icon.component" ;
17- import { GlobeIconComponent } from "@/features/common/components/bars/ribbon/assets/globe-icon.component" ;
1817import { ThemeModel } from "@/features/common/models/theme.model" ;
1918import { useAppStore } from "@/features/common/services/app.store" ;
2019import { SystemIconComponent } from "@/features/common/components/bars/ribbon/assets/system-icon.component" ;
@@ -37,10 +36,6 @@ export const RibbonComponent: React.FC<RibbonComponentProps> = ({
3736} ) => {
3837 const theme$ = useAppStore ( ( state ) => state . theme$ ) ;
3938
40- const currentLanguage = dictionary . languagePicker . options . filter (
41- ( element ) => element . code === languageCode ,
42- ) [ 0 ] ;
43-
4439 const sanitizedThemePickerCodeValue = useMemo ( ( ) => {
4540 return getSanitizedThemePickerCodeValue ( themeCode ) ;
4641 } , [ themeCode ] ) ;
@@ -85,25 +80,6 @@ export const RibbonComponent: React.FC<RibbonComponentProps> = ({
8580 [ dictionary . themePicker . options ] ,
8681 ) ;
8782
88- const languageOptions = useMemo (
89- ( ) =>
90- dictionary . languagePicker . options . map ( ( option ) => {
91- return {
92- code : option . code ,
93- full : {
94- ...option ,
95- icon : null ,
96- } ,
97- compact : {
98- ...option ,
99- label : option . code . toUpperCase ( ) ,
100- icon : null ,
101- } ,
102- } ;
103- } ) ,
104- [ dictionary . languagePicker . options ] ,
105- ) ;
106-
10783 const handleThemeSelection = useCallback (
10884 async ( value : ThemePickerCodeValues ) => {
10985 const themePreference = await savePreferredThemeInCookie (
@@ -202,21 +178,6 @@ export const RibbonComponent: React.FC<RibbonComponentProps> = ({
202178 listLabel : dictionary . themePicker . list . ariaLabel ,
203179 } }
204180 />
205- { dictionary . languagePicker . options . length > 1 && (
206- < RibbonPickerComponent
207- icon = { < GlobeIconComponent /> }
208- label = { currentLanguage . label }
209- compactLabel = { currentLanguage . code . toUpperCase ( ) }
210- languageCode = { languageCode }
211- selectedOptionCode = { languageCode }
212- handleSelection = { handleLanguageSelection }
213- options = { languageOptions }
214- aria = { {
215- buttonLabel : dictionary . languagePicker . button . ariaLabel ,
216- listLabel : dictionary . languagePicker . list . ariaLabel ,
217- } }
218- />
219- ) }
220181 </ div >
221182 </ BoxComponent >
222183 </ >
0 commit comments