File tree Expand file tree Collapse file tree 3 files changed +8
-11
lines changed
Expand file tree Collapse file tree 3 files changed +8
-11
lines changed Original file line number Diff line number Diff line change @@ -3,15 +3,15 @@ import type {
33 FootballMatchStats ,
44 FootballMatchTeamWithStats ,
55} from '../footballMatchStats' ;
6- import type { FootballTable as FootballTableData } from '../footballTables' ;
6+ import type { FootballTableSummary } from '../footballTables' ;
77import { grid } from '../grid' ;
88import { FootballMatchStat } from './FootballMatchStat' ;
99import { LeagueTable } from './LeagueTable' ;
1010import { Lineups } from './Lineups' ;
1111
1212type Props = {
1313 match : FootballMatchStats ;
14- table ?: FootballTableData ;
14+ table ?: FootballTableSummary ;
1515} ;
1616
1717function teamHasStats ( {
Original file line number Diff line number Diff line change @@ -7,14 +7,11 @@ import {
77 textSansBold14 ,
88 textSansBold15 ,
99} from '@guardian/source/foundations' ;
10- import type {
11- Entry ,
12- FootballTable as FootballTableData ,
13- } from '../footballTables' ;
10+ import type { EntrySummary , FootballTableSummary } from '../footballTables' ;
1411import { palette } from '../palette' ;
1512
1613type Props = {
17- table : FootballTableData ;
14+ table : FootballTableSummary ;
1815} ;
1916
2017export const LeagueTable = ( { table } : Props ) => {
@@ -43,7 +40,7 @@ const Title = ({ text }: { text: string }) => (
4340 </ h3 >
4441) ;
4542
46- const Table = ( { table } : { table : FootballTableData } ) => {
43+ const Table = ( { table } : { table : FootballTableSummary } ) => {
4744 return (
4845 < table
4946 css = { css `
@@ -78,7 +75,7 @@ const Table = ({ table }: { table: FootballTableData }) => {
7875 ) ;
7976} ;
8077
81- const TableRow = ( { entry } : { entry : Entry } ) => {
78+ const TableRow = ( { entry } : { entry : EntrySummary } ) => {
8279 return (
8380 < tr css = { [ gridContainer , tableRowStyles ] } >
8481 < th scope = "row" css = { [ between ( 'pos' , 'team' ) , position ] } >
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ type Team = {
2828 url ?: string ;
2929} ;
3030
31- type EntrySummary = {
31+ export type EntrySummary = {
3232 position : number ;
3333 team : Team ;
3434 gamesPlayed : number ;
@@ -41,7 +41,7 @@ type EntrySummary = {
4141 points : number ;
4242} ;
4343
44- export type Entry = EntrySummary & {
44+ type Entry = EntrySummary & {
4545 results : TeamResult [ ] ;
4646} ;
4747
You can’t perform that action at this time.
0 commit comments