mirror of
https://github.com/Floriansylvain/RenewCMS.git
synced 2026-08-19 19:53:21 +02:00
very basic improvements over article home page
This commit is contained in:
@@ -66,7 +66,9 @@ input,
|
|||||||
label,
|
label,
|
||||||
button,
|
button,
|
||||||
span,
|
span,
|
||||||
li {
|
li,
|
||||||
|
td,
|
||||||
|
th {
|
||||||
font-family: 'Hind', sans-serif;
|
font-family: 'Hind', sans-serif;
|
||||||
color: var(--neutral-dark);
|
color: var(--neutral-dark);
|
||||||
}
|
}
|
||||||
@@ -100,7 +102,7 @@ li {
|
|||||||
border-radius: var(--radius);
|
border-radius: var(--radius);
|
||||||
}
|
}
|
||||||
|
|
||||||
.label-input .tags {
|
.tags {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
@@ -109,14 +111,14 @@ li {
|
|||||||
padding: 8px;
|
padding: 8px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.label-input .tags li {
|
.tags li {
|
||||||
background-color: var(--neutral-verylight);
|
background-color: var(--neutral-verylight);
|
||||||
border-radius: var(--radius);
|
border-radius: var(--radius);
|
||||||
|
|
||||||
padding: 4px 16px;
|
padding: 4px 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.label-input .tags li::marker {
|
.tags li::marker {
|
||||||
content: '';
|
content: '';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -19,17 +19,25 @@ onMounted(async () => {
|
|||||||
<th>Date création</th>
|
<th>Date création</th>
|
||||||
<th>Tags</th>
|
<th>Tags</th>
|
||||||
<th>Statut</th>
|
<th>Statut</th>
|
||||||
|
<th>Actions</th>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr v-for="article in articles">
|
<tr v-for="article in articles">
|
||||||
<td>{{ article.title }}</td>
|
<td>{{ article.title }}</td>
|
||||||
<td>{{ new Date(article.date).toLocaleDateString('fr-FR') }}</td>
|
<td>{{ new Date(article.date).toLocaleDateString('fr-FR') }}</td>
|
||||||
<td>{{ article.tags }}</td>
|
<td>
|
||||||
<td>{{`${article.online ? 'En ligne' : 'Hors ligne'}`}}</td>
|
<ul class="tags">
|
||||||
<RouterLink :to="`articles/edit/${article.titleID}`">
|
<li v-for="tag in article.tags">{{ tag }}</li>
|
||||||
Éditer
|
</ul>
|
||||||
</RouterLink>
|
</td>
|
||||||
<button>Supprimer</button>
|
<td class="status">{{`${article.online ? '🟢' : '🔴'}`}}</td>
|
||||||
|
<td>
|
||||||
|
<div class="action-buttons">
|
||||||
|
<RouterLink class="button-secondary" :to="`articles/edit/${article.titleID}`">✏️
|
||||||
|
</RouterLink>
|
||||||
|
<button class="button-secondary">❌</button>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
@@ -44,4 +52,27 @@ main {
|
|||||||
main>a {
|
main>a {
|
||||||
width: fit-content;
|
width: fit-content;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
main table {
|
||||||
|
width: 100%;
|
||||||
|
|
||||||
|
border-collapse: collapse;
|
||||||
|
}
|
||||||
|
|
||||||
|
main table td {
|
||||||
|
padding: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.action-buttons {
|
||||||
|
margin: auto;
|
||||||
|
width: fit-content;
|
||||||
|
}
|
||||||
|
|
||||||
|
.action-buttons>* {
|
||||||
|
margin: 0 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.status {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
Reference in New Issue
Block a user