fix: Hauteur des images et l'aspect de la page d'accueil

This commit is contained in:
Simon 2022-04-06 12:22:53 +02:00
parent ac319cb39a
commit 5fc23225d0
2 changed files with 19 additions and 13 deletions

View File

@ -59,7 +59,6 @@ function slideMove(splide, newIndex) {
@click="$emit('answerSelected', question, answerWeight)"
>
<img
width="200"
height="200"
:src="`/answers/${answer.image}.png`"
/>

View File

@ -25,7 +25,7 @@ function getTranslation(translations, key) {
<h1>Ceiba Scores App</h1>
</header>
<main>
<template v-if="scores">
<div class="container" v-if="scores">
<ul>
<li v-for="score in scores" :key="score.id" :id="`score_${score.id}`">
<router-link :to="{ name: 'score', params: { id: score.id } }">{{
@ -33,7 +33,7 @@ function getTranslation(translations, key) {
}}</router-link>
</li>
</ul>
</template>
</div>
</main>
</template>
@ -60,30 +60,37 @@ main
overflow: hidden
background-color: var(--color-highlight)
.container
position: relative
width: 100%
max-width: 440px
max-height: 100%
padding-top: calc(100% / (724 / 1136))
@media only screen and (min-width: 472px)
padding-top: 0
width: 440px
height: calc(440px * 1136 / 724)
ul
margin: 0
padding: 0
list-style: none
width: 100%
max-width: 100%
max-height: 100%
position: absolute
top: 0
left: 0
bottom: 0
right: 0
aspect-ratio: 181 / 284
background-image: url(/arbre.png)
background-size: 724px 1136px
background-position: center
background-repeat: no-repeat
background-size: contain
position: relative
// border: 2px solid var(--color-white)
border-radius: 10px
@media only screen and (min-width: 472px)
max-width: 440px
li
display: none