Browse Source

Re-organizing the poi editor form

poi-dev
Léo Serre 2 years ago
parent
commit
1589a33aaf
  1. 11
      views/css/d.poi.css
  2. 21
      views/d.poi.edit.html

11
views/css/d.poi.css

@ -50,13 +50,16 @@ form.form input, form.form textarea, form.form input[type=radio]:checked+label,
}
form.form h1 input {
width: 58%;
margin: 10px 0 10px 0px;
flex: 2 !important;
font-size: 18px;
}
form.form h1 {
padding: 10px 0;
margin: 0 0 10px 0;
}
#locale {
width: 38%;
float: right;
flex: 1;
margin: 10px 5px 0 5px;
font-size: 17px;
}

21
views/d.poi.edit.html

@ -13,30 +13,29 @@
<section>
<i id="slide-icon" class="fas fa-chevron-up"></i>
<form class="form" action="<?=$config['rel_root_folder']?>wiki/<?=$poi->permalink?>/edit" method="post">
<br>
<div class="flex_line" id="type_selector">
<? foreach($poi_types as $type) { ?>
<input type="radio" name="poi_type" value="<?=$type[3]?>" id="<?=$type[3]?>">
<label for="<?=$type[3]?>"><img src="<?=$config['views_url']?>img/<?=$type[3]?>.svg"><br><?=$type[0]?></label>
<? } ?>
</div>
<h1>
<h1 class="flex_line">
<input type="text" value="<?=$poi->name?>" name="name" id="name" placeholder="Nom de l'hébergement">
<select name="locale" id="locale">
<? foreach($locales->objs as $locale) { ?>
<option <?=$poi->locale==$locale->name?'selected':''?> value="<?=$locale->name?>"><?=$locale->display_name?></option>
<? } ?>
</select>
<input type="text" value="<?=$poi->name?>" name="name" id="name" placeholder="Nom de l'hébergement">
</h1>
<div class="flex_line" id="type_selector">
<? foreach($poi_types as $type) { ?>
<input type="radio" name="poi_type" value="<?=$type[3]?>" id="<?=$type[3]?>">
<label for="<?=$type[3]?>"><img src="<?=$config['views_url']?>img/<?=$type[3]?>.svg"><br><?=$type[0]?></label>
<? } ?>
</div>
<div class="flex_line">
<input type="text" value="<?=$poi->lat?>" name="lat" id="lat" placeholder="Latitude">
<input type="text" value="<?=$poi->lon?>" name="lon" id="lon" placeholder="Longitude">
<input type="text" value="<?=$poi->alt?>" name="alt" id="alt" placeholder="Altitude">
</div>
<input name="submit" id="submit" type="submit" value="Envoyer">
<input name="submit" id="submit" type="submit" value="Ajouter l'hébergement">
</form>
</section>

Loading…
Cancel
Save