some fixes, also search bar and add spell button

This commit is contained in:
BlackMageMathos
2020-06-05 16:20:20 +02:00
parent ddc9122929
commit b80ce291ad
3 changed files with 35 additions and 5 deletions

View File

@@ -4,7 +4,7 @@
class="col-12 col-sm-6 col-lg-4 col-xl-3 mb-4 grid-item grid-sizer">
<div class="spellcard bg-white p-4 rounded text-dark shadow" style="border-left-width:4px;border-left-style:solid;">
<div class="h3 font-display font-weight-bold text-wrap word-break" :title="name" style="line-height:100%;">
<a class="text-decoration-none" :href="'/spell/'+id">{{name}}</a>
<a class="text-decoration-none" href="#">{{name}}</a>
</div>
<div>
<div class="font-weight-700 text-muted d-inline-block">Niveau {{level}}</div><span> · </span>
@@ -22,10 +22,10 @@
<span v-for="(variable,index) in variables" :key="index"><span class="font-weight-bold"><span v-if="index!=0"><br></span>{{String.fromCharCode(120+index)}}</span> = {{variable.description}}</span>
</div>
</div>
<div class="text-right">
<!--<div class="text-right">
<a class="h5 text-secondary mr-1" :href="'/spell/'+id+'/edit'"><i class="mad">edit</i></a>
<a class="h5 text-danger" :href="'/spell/'+id+'/delete'"><i class="mad">delete</i></a>
</div>
</div>-->
</div>
</div>
</template>

View File

@@ -1,6 +1,36 @@
<template>
<div class="container-fluid p-4" id="spell-container">
<h1 class="display-3 font-display mb-4">Sortilèges</h1>
<h1 class="display-3 font-display mb-3">Sortilèges</h1>
<div class="mb-4">
<form>
<div class="form-group mb-2">
<input type="text" class="form-control" name="search_terms" id="search_terms" placeholder="Rechercher un sort">
</div>
<div class="mb-3">
<div class="form-check form-check-inline">
<input checked class="form-check-input" type="checkbox" id="search_fields_name" value="search_fields_name">
<label class="form-check-label" for="search_fields_name">Nom</label>
</div>
<div class="form-check form-check-inline">
<input checked class="form-check-input" type="checkbox" id="search_fields_schools" value="search_fields_schools">
<label class="form-check-label" for="search_fields_schools">École(s)</label>
</div>
<div class="form-check form-check-inline">
<input checked class="form-check-input" type="checkbox" id="search_fields_ingredients" value="search_fields_ingredients">
<label class="form-check-label" for="search_fields_ingredients">Ingrédients</label>
</div>
<div class="form-check form-check-inline">
<input checked class="form-check-input" type="checkbox" id="search_fields_description" value="search_fields_description">
<label class="form-check-label" for="search_fields_description">Description</label>
</div>
<div class="form-check form-check-inline">
<input checked class="form-check-input" type="checkbox" id="search_fields_variables" value="search_fields_variables">
<label class="form-check-label" for="search_fields_variables">Variables</label>
</div>
</div>
</form>
<button type="button" class="btn font-display font-weight-bold btn-lg btn-outline-dark btn-block shadow-sm"><i class="mad">add</i> Ajouter un sort</button>
</div>
<spell-list/>
</div>
</template>

View File

@@ -35,7 +35,7 @@
</div>
<div class="form-group">
<label for="spell_ingredients" class="font-weight-bold col-form-label">Ingrédients&nbsp;:</label>
<textarea class="form-control" name="spell_ingredients" id="spell_ingredients" placeholder="(1024 caractères max.)"></textarea>
<textarea class="form-control" name="spell_ingredients" id="spell_ingredients" placeholder="(1024 caractères max., 1 ingrédient par ligne)"></textarea>
</div>
<div class="form-group">
<label for="spell_description" class="font-weight-bold col-form-label">Description&nbsp;:</label>