Client - display ascent total depending on user preferences

This commit is contained in:
Sam 2022-07-23 18:06:20 +02:00
parent 7d9f4d0600
commit eb641c4481

View File

@ -11,6 +11,7 @@
:text="distanceUnitTo === 'mi' ? 'miles' : distanceUnitTo" :text="distanceUnitTo === 'mi' ? 'miles' : distanceUnitTo"
/> />
<StatCard <StatCard
v-if="user.display_ascent"
icon="location-arrow" icon="location-arrow"
:value="totalAscent" :value="totalAscent"
:text="ascentUnitTo === 'ft' ? 'feet' : ascentUnitTo" :text="ascentUnitTo === 'ft' ? 'feet' : ascentUnitTo"
@ -20,6 +21,12 @@
:value="totalDuration.days" :value="totalDuration.days"
:text="totalDuration.duration" :text="totalDuration.duration"
/> />
<StatCard
v-if="!user.display_ascent"
icon="tags"
:value="user.nb_sports"
:text="$t('workouts.SPORT', user.nb_sports)"
/>
</div> </div>
</template> </template>