Skip to content

Commit

Permalink
Use team color on scoreboard.
Browse files Browse the repository at this point in the history
  • Loading branch information
krazkidd committed Sep 28, 2023
1 parent 4958f9e commit 2390d2c
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
11 changes: 9 additions & 2 deletions components/scoreboard/ScoreboardTeamTile.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,18 @@ const emit = defineEmits<{
(e: "removeRun"): void;
}>();
const cardPassThroughOptions = {
const cardPassThroughOptions = computed(() => ({
root: {
class: 'accent m-1 w-64',
},
title: {
class: 'rounded',
style: {
color: props.team ? `#${props.team!.jerseyTextColor}` : '',
backgroundColor: props.team ? `#${props.team!.jerseyColor}` : '',
}
}
} as CardPassThroughOptions;
} as CardPassThroughOptions));
const buttonPassThroughOptions = {
label: {
Expand Down
4 changes: 2 additions & 2 deletions pages/scoreboard/[[id]].vue
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ const { data: scoreboard } = useDocument(await getScoreboard(db, teamId.value));
const fakeTeam = {
name: "Opposing Team",
jerseyColor: "f5f5f5",
jerseyTextColor: "cdcdcd",
//jerseyColor: "",
//jerseyTextColor: "",
} as Team;
</script>

Expand Down

0 comments on commit 2390d2c

Please sign in to comment.