Skip to content

Commit

Permalink
feat: add europa league and conference league
Browse files Browse the repository at this point in the history
  • Loading branch information
KimJoonSeo committed Nov 20, 2023
1 parent e9a946e commit f660540
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 21 deletions.
2 changes: 1 addition & 1 deletion public/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "European Football Leagues Score",
"description": "Simple football box score",
"version": "1.2.0",
"version": "1.3.0",
"manifest_version": 3,
"action": {
"default_popup": "index.html",
Expand Down
56 changes: 36 additions & 20 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ import laliga from './resources/images/laliga.png'
import epl from './resources/images/epl.png'
import seriea from './resources/images/seriea.png'
import ligue1 from './resources/images/ligue1.png'
import europa from './resources/images/europa.png'
import conference from './resources/images/conference.png'

const LeagueOption: React.FC<{ image: string; name: string }> = ({
image,
Expand All @@ -36,27 +38,41 @@ const App: React.FC = () => {
const [date, setDate] = useState<dayjs.Dayjs>(dayjs())
const [league, setLeague] = useState<string>('eng.1')
const leagueOptions = [
{
value: 'eng.1',
label: <LeagueOption image={epl} name={'Premier League'} />,
},
{ value: 'esp.1', label: <LeagueOption image={laliga} name={'LaLiga'} /> },
{
value: 'ger.1',
label: <LeagueOption image={bundesliga} name={'Bundesliga'} />,
},
{
value: 'ita.1',
label: <LeagueOption image={seriea} name={'Serie A'} />,
},
{
value: 'fra.1',
label: <LeagueOption image={ligue1} name={'Ligue 1'} />,
},
{
value: 'uefa.champions',
label: <LeagueOption image={ucl} name={'UEFA Champions League'} />,
{label: 'Nation', options: [
{
value: 'eng.1',
label: <LeagueOption image={epl} name={'Premier League'} />,
},
{ value: 'esp.1', label: <LeagueOption image={laliga} name={'LaLiga'} /> },
{
value: 'ger.1',
label: <LeagueOption image={bundesliga} name={'Bundesliga'} />,
},
{
value: 'ita.1',
label: <LeagueOption image={seriea} name={'Serie A'} />,
},
{
value: 'fra.1',
label: <LeagueOption image={ligue1} name={'Ligue 1'} />,
},
]
},
{label: 'UEFA', options: [
{
value: 'uefa.champions',
label: <LeagueOption image={ucl} name={'UEFA Champions League'} />,
},
{
value: 'uefa.europa',
label: <LeagueOption image={europa} name={'UEFA Europa League'} />,
},
{
value: 'uefa.europa.conf',
label: <LeagueOption image={conference} name={'UEFA Europa Conference League'} />,
},
]
}
]

const onChangeDate: DatePickerProps['onChange'] = (date, _dateString) => {
Expand Down
Binary file added src/resources/images/conference.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/resources/images/europa.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit f660540

Please sign in to comment.