<form class="dialog-repos">
  <img class="chat-icon" src="{{img}}" data-tooltip="{{name}}" />
  <div class="flexcol">
    <div class="flexrow"><span>
      <h2>{{name}} se repose</h2>
    </span></div>
    <div class="flexrow"><span>
      <input type="radio" name="repos" id="sieste" value="sieste" {{#unless system.sommeil.nouveaujour}}checked{{/unless}}>
      <label for="sieste">Sieste de 
        <input name="sieste.heures" value="1" type="number" data-dtype="Number" />
        heures</label>
    </span></div>
    <div class="flexrow"><span><hr></span></div>
    {{#if system.sommeil.nouveaujour}}
    <div class="flexrow"><span>
      <input name="repos" type="radio" id="chateau-dormant" value="chateau-dormant">
      <label for="chateau-dormant">Juste château Dormant</label>
    </span></div>
    <div class="flexrow"><span>
      <input name="repos" type="radio" id="nuit" value="nuit" checked>
      {{#if system.sommeil.insomnie}}
      <label>Insomnie cette nuit</label>
      {{else}}
      <label for="nuit">Nuit : heure
        <select name="sommeil.heure.debut">
          {{selectOptions hourDefinitions selected=nuitHeureDebut labelAttr='label' valueAttr='heure'}}
        </select>
        → heure
        <select name="sommeil.heure.fin">
          {{selectOptions hourDefinitions selected=nuitHeureFin labelAttr='label' valueAttr='heure'}}
        </select>
        (<span name="sommeil.duree">{{nuitDuree}}</span>h)</label>
      {{/if}}
    </span></div>
    <div class="flexrow">
      <label for="moral">Moral</label>
      <div class="sommeil-actor-moral">
        {{> "systems/foundryvtt-reve-de-dragon/templates/sommeil/sommeil-actor-moral.hbs" system.sommeil}}
      </div>
    </div>
    {{else}}
      <div class="flexrow"><span>
        Le gardien des rêves doit faire passer Chateau Dormant
      </span></div>
    {{/if}}
    <div class="flexrow"><span><hr></span></div>
    <div class="flexrow"><span>
      <input name="repos" type="radio" id="gris-reve" value="gris-reve">
      <label for="gris-reve">Gris rêve</label>
    </span></div>
    <div class="flexrow">
      <label for="nb-jours">Nombre de jours</label>
      <input name="nb-jours" value="2" type="number" data-dtype="Number" />
    </div>
  </div>
</form>