Skip to content

Commit

Permalink
Merge pull request #193 from traPtitech/feat/multipleContestTeam
Browse files Browse the repository at this point in the history
コンテストチームの複数表示に対応
  • Loading branch information
Pugma authored Jul 6, 2024
2 parents b9a149d + b8d0d5b commit 83e1cc8
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions src/components/User/ContestsContainer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,15 @@ defineProps<Props>()
<ul v-if="contests.length > 0" :class="$style.contests">
<li v-for="contest in contests" :key="contest.id" :class="$style.contest">
<router-link :to="`/contests/${contest.id}`" :class="$style.link">
<div>{{ contest.name }}</div>
<div :class="$style.detail">
<div>チーム {{ contest.teams[0]?.name }}</div>
<div>{{ contest.teams[0]?.result }}</div>
<h4>{{ contest.name }}</h4>
<div
v-for="team in contest.teams"
:key="team.id"
:class="$style.detail"
>
チーム {{ team.name }}
<br />
{{ team.result }}
</div>
</router-link>
</li>
Expand Down Expand Up @@ -50,12 +55,14 @@ defineProps<Props>()
.link {
color: $color-text;
text-decoration: none;
margin: 4px 0;
}
.detail {
display: flex;
flex-direction: column;
gap: 0.25rem;
padding-left: 0.75rem;
padding-left: 1.75rem;
font-size: 0.875rem;
text-indent: -1rem;
}
</style>

0 comments on commit 83e1cc8

Please sign in to comment.