Move skeletons outside of RadioList

This commit is contained in:
James Lyne 2021-05-28 14:35:03 +01:00
parent 6209a89092
commit fd82b6c527
2 changed files with 4 additions and 4 deletions

View File

@ -18,10 +18,10 @@
<CollapsibleSection name="players"> <CollapsibleSection name="players">
<template v-slot:heading>{{ heading }} [{{ players.size }}/{{ maxPlayers }}]</template> <template v-slot:heading>{{ heading }} [{{ players.size }}/{{ maxPlayers }}]</template>
<template v-slot:default> <template v-slot:default>
<RadioList class="section__content"> <RadioList class="section__content" v-if="players.size">
<PlayerListItem v-for="[account, player] in players" :key="account" :player="player"></PlayerListItem> <PlayerListItem v-for="[account, player] in players" :key="account" :player="player"></PlayerListItem>
<div v-if="!players.size" class="section__skeleton" aria-disabled="true" role="radio">{{ skeletonPlayers }}</div>
</RadioList> </RadioList>
<div v-else class="section__skeleton">{{ skeletonPlayers }}</div>
</template> </template>
</CollapsibleSection> </CollapsibleSection>
</template> </template>

View File

@ -18,10 +18,10 @@
<CollapsibleSection name="maps"> <CollapsibleSection name="maps">
<template v-slot:heading>{{ heading }}</template> <template v-slot:heading>{{ heading }}</template>
<template v-slot:default> <template v-slot:default>
<RadioList class="section__content"> <RadioList v-if="worlds.size" class="section__content">
<WorldListItem :world="world" v-for="[name, world] in worlds" :key="`${prefix}_${currentServer.id}_${name}`"></WorldListItem> <WorldListItem :world="world" v-for="[name, world] in worlds" :key="`${prefix}_${currentServer.id}_${name}`"></WorldListItem>
<div v-if="!worlds.size" class="section__skeleton" aria-disabled="true" role="radio">{{ skeletonWorlds }}</div>
</RadioList> </RadioList>
<div v-else class="section__skeleton">{{ skeletonWorlds }}</div>
</template> </template>
</CollapsibleSection> </CollapsibleSection>
</template> </template>