feat: Modification du design
	
		
			
	
		
	
	
		
	
		
			All checks were successful
		
		
	
	
		
			
				
	
				continuous-integration/drone/push Build is passing
				
			
		
		
	
	
				
					
				
			
		
			All checks were successful
		
		
	
	continuous-integration/drone/push Build is passing
				
			This commit is contained in:
		@@ -51,6 +51,10 @@ html, body, #app {
 | 
				
			|||||||
  padding: 0;
 | 
					  padding: 0;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#app {
 | 
				
			||||||
 | 
					  min-width: 320px;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
body {
 | 
					body {
 | 
				
			||||||
  color: var(--color-text);
 | 
					  color: var(--color-text);
 | 
				
			||||||
  background: var(--color-background);
 | 
					  background: var(--color-background);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -30,26 +30,10 @@ function slideMove(splide, newIndex) {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
<template>
 | 
					<template>
 | 
				
			||||||
  <div class="main">
 | 
					  <div class="main">
 | 
				
			||||||
    <div class="top">
 | 
					    <div class="center">
 | 
				
			||||||
      <legend>{{ question.title }}</legend>
 | 
					      <legend>{{ question.title }}</legend>
 | 
				
			||||||
      <template v-if="question.answers">
 | 
					
 | 
				
			||||||
        <div class="choice" v-for="answer in question.answers" :key="answer.id">
 | 
					      <div class="images">
 | 
				
			||||||
          <label>
 | 
					 | 
				
			||||||
            <input
 | 
					 | 
				
			||||||
              type="radio"
 | 
					 | 
				
			||||||
              :data-answerId="answer.id"
 | 
					 | 
				
			||||||
              :name="`question_${question.id}`"
 | 
					 | 
				
			||||||
              :value="answer.weight"
 | 
					 | 
				
			||||||
              v-model="answerWeight"
 | 
					 | 
				
			||||||
              @change="selectAnswer(answer)"
 | 
					 | 
				
			||||||
              @click="nextQuestion"
 | 
					 | 
				
			||||||
            />
 | 
					 | 
				
			||||||
            {{ answer.title }}
 | 
					 | 
				
			||||||
          </label>
 | 
					 | 
				
			||||||
        </div>
 | 
					 | 
				
			||||||
      </template>
 | 
					 | 
				
			||||||
    </div>
 | 
					 | 
				
			||||||
    <div class="bottom">
 | 
					 | 
				
			||||||
        <template v-if="question.answers">
 | 
					        <template v-if="question.answers">
 | 
				
			||||||
          <Splide
 | 
					          <Splide
 | 
				
			||||||
            @splide:move="slideMove"
 | 
					            @splide:move="slideMove"
 | 
				
			||||||
@@ -67,17 +51,95 @@ function slideMove(splide, newIndex) {
 | 
				
			|||||||
          </Splide>
 | 
					          </Splide>
 | 
				
			||||||
        </template>
 | 
					        </template>
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      <template v-if="question.answers">
 | 
				
			||||||
 | 
					        <ul class="choices">          
 | 
				
			||||||
 | 
					          <li class="choice" v-for="answer in question.answers" :key="answer.id">
 | 
				
			||||||
 | 
					            <input
 | 
				
			||||||
 | 
					              type="radio"
 | 
				
			||||||
 | 
					              :data-answerId="answer.id"
 | 
				
			||||||
 | 
					              :name="`question_${question.id}`"
 | 
				
			||||||
 | 
					              :id="`question_${question.id}_answer_${answer.id}`"
 | 
				
			||||||
 | 
					              :value="answer.weight"
 | 
				
			||||||
 | 
					              v-model="answerWeight"
 | 
				
			||||||
 | 
					              @change="selectAnswer(answer)"
 | 
				
			||||||
 | 
					              @click="nextQuestion"
 | 
				
			||||||
 | 
					            />
 | 
				
			||||||
 | 
					            <label :for="`question_${question.id}_answer_${answer.id}`">
 | 
				
			||||||
 | 
					              {{ answer.title }}
 | 
				
			||||||
 | 
					            </label>
 | 
				
			||||||
 | 
					          </li>
 | 
				
			||||||
 | 
					        </ul>
 | 
				
			||||||
 | 
					      </template>
 | 
				
			||||||
 | 
					    </div>
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
</template>
 | 
					</template>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<style lang="sass">
 | 
					<style lang="sass">
 | 
				
			||||||
 | 
					.splide__arrow
 | 
				
			||||||
 | 
					  background: transparent
 | 
				
			||||||
 | 
					  border: 3px solid var(--color-green)
 | 
				
			||||||
 | 
					  width: 3rem
 | 
				
			||||||
 | 
					  height: 3rem
 | 
				
			||||||
 | 
					  opacity: 1
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  svg
 | 
				
			||||||
 | 
					    fill: var(--color-green)
 | 
				
			||||||
 | 
					    height: 1.6rem
 | 
				
			||||||
 | 
					    width: 1.6rem
 | 
				
			||||||
.splide__pagination
 | 
					.splide__pagination
 | 
				
			||||||
  bottom: -1.5em
 | 
					  bottom: -1.5em
 | 
				
			||||||
 | 
					.splide__pagination__page
 | 
				
			||||||
 | 
					  width: .7rem
 | 
				
			||||||
 | 
					  height: .7rem
 | 
				
			||||||
 | 
					  background: var(--color-green)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  &.is-active
 | 
				
			||||||
 | 
					    background: var(--color-green)
 | 
				
			||||||
</style>
 | 
					</style>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<style lang="sass" scoped>
 | 
					<style lang="sass" scoped>
 | 
				
			||||||
input[type=radio]
 | 
					
 | 
				
			||||||
  margin-right: .5rem
 | 
					legend
 | 
				
			||||||
 | 
					  text-align: center
 | 
				
			||||||
 | 
					  font-size: 1.4rem
 | 
				
			||||||
 | 
					  line-height: 2rem
 | 
				
			||||||
 | 
					  margin: 1rem
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					.choices
 | 
				
			||||||
 | 
					  list-style-type: none
 | 
				
			||||||
 | 
					  text-align: left
 | 
				
			||||||
 | 
					  display: inline-block
 | 
				
			||||||
 | 
					  padding-left: 0
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  input[type=radio]
 | 
				
			||||||
 | 
					    display: none
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    & + label
 | 
				
			||||||
 | 
					      position: relative
 | 
				
			||||||
 | 
					      padding-left: 2rem
 | 
				
			||||||
 | 
					    & + label::before,
 | 
				
			||||||
 | 
					    & + label::after
 | 
				
			||||||
 | 
					      display: block
 | 
				
			||||||
 | 
					      position: absolute
 | 
				
			||||||
 | 
					      box-sizing: border-box
 | 
				
			||||||
 | 
					      content:''
 | 
				
			||||||
 | 
					      border-radius: 1rem
 | 
				
			||||||
 | 
					    & + label::before
 | 
				
			||||||
 | 
					      bottom: 0
 | 
				
			||||||
 | 
					      left: 0
 | 
				
			||||||
 | 
					      background-color: var(--color-green)
 | 
				
			||||||
 | 
					      width: 1rem
 | 
				
			||||||
 | 
					      height: 1rem
 | 
				
			||||||
 | 
					    & + label::after
 | 
				
			||||||
 | 
					      bottom: 3px
 | 
				
			||||||
 | 
					      left: 3px
 | 
				
			||||||
 | 
					      width: calc(1rem - 6px)
 | 
				
			||||||
 | 
					      height: calc(1rem - 6px)
 | 
				
			||||||
 | 
					    &:checked + label::before
 | 
				
			||||||
 | 
					      background-color: white
 | 
				
			||||||
 | 
					    &:checked + label::after
 | 
				
			||||||
 | 
					      background-color: var(--color-green)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.main
 | 
					.main
 | 
				
			||||||
  height: 100%
 | 
					  height: 100%
 | 
				
			||||||
@@ -87,11 +149,19 @@ input[type=radio]
 | 
				
			|||||||
  justify-content: space-around
 | 
					  justify-content: space-around
 | 
				
			||||||
  align-items: center
 | 
					  align-items: center
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  .bottom
 | 
					  .center
 | 
				
			||||||
 | 
					    width: 100%
 | 
				
			||||||
 | 
					    text-align: center
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  .images
 | 
				
			||||||
 | 
					    margin: 3rem auto
 | 
				
			||||||
    width: 400px
 | 
					    width: 400px
 | 
				
			||||||
    max-width: 100%
 | 
					    max-width: 100%
 | 
				
			||||||
    min-width: 280px
 | 
					    min-width: 280px
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  h2
 | 
				
			||||||
 | 
					    font-size: 2rem
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.answers
 | 
					.answers
 | 
				
			||||||
  text-align: center
 | 
					  text-align: center
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -99,6 +169,6 @@ input[type=radio]
 | 
				
			|||||||
  .main
 | 
					  .main
 | 
				
			||||||
    flex-direction: row
 | 
					    flex-direction: row
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    .bottom
 | 
					    .images
 | 
				
			||||||
      max-width: 50%
 | 
					      max-width: 50%
 | 
				
			||||||
</style>
 | 
					</style>
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -105,7 +105,10 @@ function answerSelected(question, answerWeight) {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
function nextQuestion() {
 | 
					function nextQuestion() {
 | 
				
			||||||
  setTimeout(() => slides.value.go(">"), 100);
 | 
					  setTimeout(() => {
 | 
				
			||||||
 | 
					    slides.value.go(">");
 | 
				
			||||||
 | 
					    console.log(slides)
 | 
				
			||||||
 | 
					  }, 100);
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
</script>
 | 
					</script>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -134,13 +137,8 @@ function nextQuestion() {
 | 
				
			|||||||
    </SplideSlide>
 | 
					    </SplideSlide>
 | 
				
			||||||
    <SplideSlide class="latest">
 | 
					    <SplideSlide class="latest">
 | 
				
			||||||
      <template v-if="displayScoreResult && result">
 | 
					      <template v-if="displayScoreResult && result">
 | 
				
			||||||
        <ul>
 | 
					        <h2 class="center">Probabilité d'échec</h2>
 | 
				
			||||||
          <li>score : {{ scoreSum }}</li>
 | 
					        <h2 class="center">{{ result.pde_qtra }}</h2>
 | 
				
			||||||
          <li>pde : {{ result.pde }}</li>
 | 
					 | 
				
			||||||
          <li>pde_qtra : {{ result.pde_qtra }}</li>
 | 
					 | 
				
			||||||
          <li>effets : {{ result.effets }}</li>
 | 
					 | 
				
			||||||
          <li>facteur : {{ result.facteur }}</li>
 | 
					 | 
				
			||||||
        </ul>
 | 
					 | 
				
			||||||
        <div class="gradient">
 | 
					        <div class="gradient">
 | 
				
			||||||
          <div
 | 
					          <div
 | 
				
			||||||
            v-for="(item, index) in [...Array(7).keys()]"
 | 
					            v-for="(item, index) in [...Array(7).keys()]"
 | 
				
			||||||
@@ -150,6 +148,14 @@ function nextQuestion() {
 | 
				
			|||||||
            {{ index + 1 }}
 | 
					            {{ index + 1 }}
 | 
				
			||||||
          </div>
 | 
					          </div>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
 | 
					        <div class="details">
 | 
				
			||||||
 | 
					          <p>Rappel des paramètres choisis :</p>
 | 
				
			||||||
 | 
					          <ul>
 | 
				
			||||||
 | 
					            <li v-for="question in questions" :key="question.id">
 | 
				
			||||||
 | 
					              {{ question.title }} : {{ question.answers.find((answer) => answer.weight === question.weight).title }}
 | 
				
			||||||
 | 
					            </li>
 | 
				
			||||||
 | 
					          </ul>
 | 
				
			||||||
 | 
					        </div>
 | 
				
			||||||
      </template>
 | 
					      </template>
 | 
				
			||||||
      <template v-else>
 | 
					      <template v-else>
 | 
				
			||||||
        <div class="noscore">
 | 
					        <div class="noscore">
 | 
				
			||||||
@@ -181,6 +187,8 @@ function nextQuestion() {
 | 
				
			|||||||
</template>
 | 
					</template>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<style lang="sass" scoped>
 | 
					<style lang="sass" scoped>
 | 
				
			||||||
 | 
					.center
 | 
				
			||||||
 | 
					  text-align: center
 | 
				
			||||||
.noscore
 | 
					.noscore
 | 
				
			||||||
  display: flex
 | 
					  display: flex
 | 
				
			||||||
  justify-content: center
 | 
					  justify-content: center
 | 
				
			||||||
@@ -205,7 +213,8 @@ function nextQuestion() {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.splide__slide
 | 
					.splide__slide
 | 
				
			||||||
  background: transparent
 | 
					  background: white
 | 
				
			||||||
 | 
					  color: black
 | 
				
			||||||
  position: relative
 | 
					  position: relative
 | 
				
			||||||
  padding: 1rem
 | 
					  padding: 1rem
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -223,40 +232,64 @@ label
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
.latest
 | 
					.latest
 | 
				
			||||||
  background-color: var(--color-green)
 | 
					  background-color: var(--color-green)
 | 
				
			||||||
  color: var(--color-black)
 | 
					  color: var(--color-white)
 | 
				
			||||||
 | 
					  text-align: center
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  h2
 | 
				
			||||||
 | 
					    font-size: 2rem
 | 
				
			||||||
 | 
					    & + h2
 | 
				
			||||||
 | 
					      line-height: 2rem
 | 
				
			||||||
 | 
					      font-size: 2.6rem
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  ul
 | 
				
			||||||
 | 
					    text-align: left
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  .details
 | 
				
			||||||
 | 
					    text-align: left
 | 
				
			||||||
 | 
					    display: inline-block
 | 
				
			||||||
 | 
					    font-size: 1.1rem
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.gradient
 | 
					.gradient
 | 
				
			||||||
  width: calc(100% - 2rem)
 | 
					 | 
				
			||||||
  padding: 0 1rem
 | 
					  padding: 0 1rem
 | 
				
			||||||
  height: 3rem
 | 
					  height: 3rem
 | 
				
			||||||
  background-image: linear-gradient(to right, red, red, rgb(255, 255, 0), rgb(255, 255, 0), green, green)
 | 
					  background-image: linear-gradient(to right, red, red, rgb(255, 255, 0), rgb(255, 255, 0), green, green)
 | 
				
			||||||
  display: flex
 | 
					  display: flex
 | 
				
			||||||
  margin: 2.5rem 0
 | 
					  margin: 2.5rem auto
 | 
				
			||||||
  align-items: center
 | 
					  align-items: center
 | 
				
			||||||
  border-radius: 3px
 | 
					  border-radius: 3px
 | 
				
			||||||
  position: absolute
 | 
					  max-width: 30rem
 | 
				
			||||||
  bottom: 0
 | 
					  color: var(--color-black)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  div
 | 
					  div
 | 
				
			||||||
    width: calc(100%/7)
 | 
					    width: calc(100%/7)
 | 
				
			||||||
    text-align: center
 | 
					    text-align: center
 | 
				
			||||||
    align-self: center
 | 
					    align-self: center
 | 
				
			||||||
 | 
					    font-weight: bold
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  .active
 | 
					  .active
 | 
				
			||||||
 | 
					    position: relative
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    &:before
 | 
				
			||||||
 | 
					      content: ""
 | 
				
			||||||
      border: 1px solid black
 | 
					      border: 1px solid black
 | 
				
			||||||
      border-radius: 3px
 | 
					      border-radius: 3px
 | 
				
			||||||
    height: 200%
 | 
					      top: -2.8rem
 | 
				
			||||||
 | 
					      bottom: -1.5rem
 | 
				
			||||||
 | 
					      position: absolute
 | 
				
			||||||
 | 
					      width: 100%
 | 
				
			||||||
      font-weight: bold
 | 
					      font-weight: bold
 | 
				
			||||||
      display: flex
 | 
					      display: flex
 | 
				
			||||||
      align-items: center
 | 
					      align-items: center
 | 
				
			||||||
      justify-content: center
 | 
					      justify-content: center
 | 
				
			||||||
    position: relative
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    &::before
 | 
					    &::after
 | 
				
			||||||
      content: "PdE\AQTRA"
 | 
					      content: "PdE"
 | 
				
			||||||
      position: absolute
 | 
					      position: absolute
 | 
				
			||||||
      font-size: .5rem
 | 
					      font-size: 1rem
 | 
				
			||||||
      top: 0
 | 
					      top: -2rem
 | 
				
			||||||
 | 
					      bottom: -1.5rem
 | 
				
			||||||
 | 
					      left: 0
 | 
				
			||||||
 | 
					      right: 0
 | 
				
			||||||
      line-height: .7rem
 | 
					      line-height: .7rem
 | 
				
			||||||
 | 
					
 | 
				
			||||||
.splide__arrows
 | 
					.splide__arrows
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user