Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion assets/css/_editor.scss
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
}

pre:hover:after {
content: "ctrl + enter pour quitter le mode bloc de code";
content: "shift + enter pour quitter le mode bloc de code";
font-style: italic;
font-weight: bold;
display: block;
Expand Down
11 changes: 11 additions & 0 deletions assets/css/_exercise-gestion.scss
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,17 @@ h1 {
}
}

.status {
line-height: 25px;
svg {
vertical-align: middle;
width: 25px;
margin-left: 5px;
}

margin-bottom: 30px;
}

.content {
background-color: white;
border-radius: 4px;
Expand Down
24 changes: 24 additions & 0 deletions components/Gestion/ExerciseForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,30 @@

<h1>{{title}}</h1>

<h2 v-if="exercise" class="title--primary-color__light">Status actuel de la ressource</h2>

<div v-if="exercise" class="status">
<template v-if="exercise.state === 'VALIDATED'">
Valide <Icon type="check" theme="theme--green"/>
</template>

<template v-else-if="exercise.state === 'NOT_VALIDATED'">
Non valide <Icon type="close" theme="theme--red-light"/>
</template>

<template v-else-if="exercise.state === 'PENDING'">
En attente <Icon type="send" theme="theme--yellow"/>
</template>

<template v-else-if="exercise.state === 'DRAFT'">
Brouillon <Icon title="Créé" type="paper" theme="theme--primary-color-light"/>
</template>

<template v-else-if="exercise.state === 'ARCHIVED'">
Archivé <Icon type="archive" theme="theme--red-light"/>
</template>
</div>

<ValidationObserver ref="observer1" tag="form" @submit.prevent="validateBeforeSubmit()">
<ValidationProvider tag="label"
name="titre"
Expand Down
35 changes: 34 additions & 1 deletion pages/exercices/_id.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,28 @@
<section class="exercise">
<h1>{{exercise.title}}</h1>
<span>Créé le {{$moment(exercise.createdAt).format("DD/MM/YY à H:mm")}}</span> | <span>Mis à jour le {{$moment(exercise.updatedAt).format("DD/MM/YY à H:mm")}}</span>

<div class="status">
<b>status</b> -
<template v-if="exercise.state === 'VALIDATED'">
Valide <Icon type="check" theme="theme--green"/>
</template>

<template v-else-if="exercise.state === 'NOT_VALIDATED'">
Non valide <Icon type="close" theme="theme--red-light"/>
</template>

<template v-else-if="exercise.state === 'PENDING'">
En attente <Icon type="send" theme="theme--yellow"/>
</template>

<template v-else-if="exercise.state === 'DRAFT'">
Brouillon <Icon title="Créé" type="paper" theme="theme--primary-color-light"/>
</template>

<template v-else-if="exercise.state === 'ARCHIVED'">
Archivé <Icon type="archive" theme="theme--red-light"/>
</template>
</div>
<div class="score__info">
<div v-if="$auth.loggedIn">
<h4 class="title--primary-color__light">Votre note</h4>
Expand Down Expand Up @@ -221,6 +242,18 @@

#Exercise {

.status {
font-weight: 300;
line-height: 25px;
margin-top: 5px;
svg {
vertical-align: middle;
width: 25px;
margin-left: 5px;
}

}

.exercise {
position: relative;

Expand Down