0
Fork 0
mirror of https://github.com/verdaccio/verdaccio.git synced 2024-12-16 21:56:25 -05:00

chore: fix type for country flags and hover titles (#4709)

* chore: fix type for country flags

* add text for Canada, fix Australia flag

* add flag texts

* fix text keys

* update changeset

* Add lock file

* Add Austria
This commit is contained in:
Marc Bernard 2024-07-12 03:20:22 -04:00 committed by GitHub
parent da6d8e5f38
commit 5a77414eb6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 1390 additions and 479 deletions

View file

@ -0,0 +1,6 @@
---
'@verdaccio/ui-components': patch
'@verdaccio/ui-theme': patch
---
chore: fix type for country flags

View file

@ -32,7 +32,7 @@
"@verdaccio/ui-components": "workspace:3.0.0-next-7.8", "@verdaccio/ui-components": "workspace:3.0.0-next-7.8",
"babel-loader": "8.3.0", "babel-loader": "8.3.0",
"babel-plugin-dynamic-import-node": "2.3.3", "babel-plugin-dynamic-import-node": "2.3.3",
"country-flag-icons": "1.5.9", "country-flag-icons": "1.5.13",
"css-loader": "6.9.1", "css-loader": "6.9.1",
"dayjs": "1.11.10", "dayjs": "1.11.10",
"dompurify": "3.0.8", "dompurify": "3.0.8",

View file

@ -181,7 +181,9 @@
}, },
"flag": { "flag": {
"austria": "Austria", "austria": "Austria",
"australia": "Australia",
"brazil": "Brazil", "brazil": "Brazil",
"canada": "Canada",
"spain": "Spain", "spain": "Spain",
"nicaragua": "Nicaragua", "nicaragua": "Nicaragua",
"india": "India", "india": "India",

View file

@ -1,12 +1,11 @@
import Flags from 'country-flag-icons/react/3x2'; import Flags from 'country-flag-icons/react/3x2';
import React from 'react';
export const DEFAULT_LANGUAGE = 'en-US'; export const DEFAULT_LANGUAGE = 'en-US';
export type LanguageConfiguration = { export type LanguageConfiguration = {
lng: string; lng: string;
menuKey: string; menuKey: string;
icon: React.ReactElement; icon: Flags.FlagComponent;
}; };
export const listLanguages: LanguageConfiguration[] = [ export const listLanguages: LanguageConfiguration[] = [

View file

@ -27,31 +27,34 @@ const Footer = () => {
<StyledEarth /> <StyledEarth />
<Flags> <Flags>
<Icon> <Icon>
<FlagsIcon.ES /> <FlagsIcon.ES title={t('flag.spain')} />
</Icon> </Icon>
<Icon> <Icon>
<FlagsIcon.NI /> <FlagsIcon.NI title={t('flag.nicaragua')} />
</Icon> </Icon>
<Icon> <Icon>
<FlagsIcon.IN /> <FlagsIcon.IN title={t('flag.india')} />
</Icon> </Icon>
<Icon> <Icon>
<FlagsIcon.BR /> <FlagsIcon.BR title={t('flag.brazil')} />
</Icon> </Icon>
<Icon> <Icon>
<FlagsIcon.CN /> <FlagsIcon.CN title={t('flag.china')} />
</Icon> </Icon>
<Icon> <Icon>
<FlagsIcon.AU /> <FlagsIcon.AU title={t('flag.australia')} />
</Icon> </Icon>
<Icon> <Icon>
<FlagsIcon.DE /> <FlagsIcon.DE title={t('flag.germany')} />
</Icon> </Icon>
<Icon> <Icon>
<FlagsIcon.TW /> <FlagsIcon.TW title={t('flag.taiwan')} />
</Icon> </Icon>
<Icon> <Icon>
<FlagsIcon.CA /> <FlagsIcon.AT title={t('flag.austria')} />
</Icon>
<Icon>
<FlagsIcon.CA title={t('flag.canada')} />
</Icon> </Icon>
</Flags> </Flags>
</ToolTip> </ToolTip>

File diff suppressed because it is too large Load diff