Skip to content

Ensure visibility of match stats and info#15198

Merged
jamesmockett merged 4 commits intomainfrom
jm/football-stat-colour-updates
Jan 26, 2026
Merged

Ensure visibility of match stats and info#15198
jamesmockett merged 4 commits intomainfrom
jm/football-stat-colour-updates

Conversation

@jamesmockett
Copy link
Contributor

@jamesmockett jamesmockett commented Jan 23, 2026

What does this change?

Updates match stat components and match info page to use fixed colours for figures and applies borders to elements to add contrast and aid visibility

Why?

We have no control over the team colours used as we get these directly from the PA feed, but these are applied to elements of the match stat components and need to be visible in light and dark mode

Screenshots

Screenshot 2026-01-23 at 15 26 29 Screenshot 2026-01-23 at 15 26 03 Screenshot 2026-01-23 at 15 26 47

@github-actions
Copy link

Hello 👋! When you're ready to run Chromatic, please apply the run_chromatic label to this PR.

You will need to reapply the label each time you want to run Chromatic.

Click here to see the Chromatic project.

@jamesmockett jamesmockett self-assigned this Jan 23, 2026
@jamesmockett jamesmockett added the feature Departmental tracking: work on a new feature label Jan 23, 2026
@jamesmockett jamesmockett added the run_chromatic Runs chromatic when label is applied label Jan 23, 2026
@github-actions github-actions bot removed the run_chromatic Runs chromatic when label is applied label Jan 23, 2026
@jamesmockett jamesmockett linked an issue Jan 23, 2026 that may be closed by this pull request
@jamesmockett jamesmockett requested a review from a team January 23, 2026 16:01
Copy link
Contributor

@alexduf alexduf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To me this looks good. I got worried when I saw hard coded teams and colour code but as far as I understand it this is only for testing purposes, correct?

Comment on lines +215 to +217
color: ${isLight(colour)
? sourcePalette.neutral[7]
: sourcePalette.neutral[100]};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oooh, that's the trick! Cool so we preserve contrast by looking at the colour code.

@jamesmockett
Copy link
Contributor Author

To me this looks good. I got worried when I saw hard coded teams and colour code but as far as I understand it this is only for testing purposes, correct?

Yes, those are fixtures for the Storybook stories so we can show how the design looks with different team colours

@jamesmockett jamesmockett merged commit a3aa4eb into main Jan 26, 2026
30 of 31 checks passed
@jamesmockett jamesmockett deleted the jm/football-stat-colour-updates branch January 26, 2026 11:45
@gu-prout
Copy link

gu-prout bot commented Jan 26, 2026

Seen on PROD (merged by @jamesmockett 7 minutes and 29 seconds ago) Please check your changes!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature Departmental tracking: work on a new feature Seen-on-PROD

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Handle dynamic team colours

2 participants