{{! Weapons }}
{{#if weapons.length}}
<p class="cde-item-group-label">{{ localize "CDE.Weapons" }}</p>
{{/if}}
<ol class="item-list">
  {{#each weapons as |item id|}}
  <li class="item flexrow" data-item-id="{{item._id}}">
    <img src="{{item.img}}" title="{{item.name}}" width="24" height="24" />
    <h4 class="item-name">{{item.name}}</h4>
    <span class="cde-badge weapon">{{ localize "CDE.WeaponType" }}</span>
    <span class="cde-item-stat cde-item-damage">{{item.system.damageBase}}</span>
    <div class="item-controls">
      <a class="item-control cde-roll-trigger cde-weapon-roll-btn" title="{{ localize 'CDE.WeaponRoll' }}" data-libel-id="{{item._id}}-itemweapon"><i class="fas fa-dice-d10"></i></a>
      <a class="item-control" title="{{ localize 'CDE.ItemEdit' }}" data-action="edit"><i class="fas fa-edit"></i></a>
      <a class="item-control" title="{{ localize 'CDE.ItemDelete' }}" data-action="delete"><i class="fas fa-trash"></i></a>
    </div>
  </li>
  {{/each}}
</ol>
<p>
  <a class="item-control" title="{{ localize 'CDE.WeaponCreate' }}" data-action="create" data-type="weapon"><i class="fas fa-plus"></i> {{ localize "CDE.WeaponCreate" }}</a>
</p>

{{! Armors }}
{{#if armors.length}}
<p class="cde-item-group-label">{{ localize "CDE.Armors" }}</p>
{{/if}}
<ol class="item-list">
  {{#each armors as |item id|}}
  <li class="item flexrow" data-item-id="{{item._id}}">
    <img src="{{item.img}}" title="{{item.name}}" width="24" height="24" />
    <h4 class="item-name">{{item.name}}</h4>
    <span class="cde-badge armor">{{ localize "CDE.ArmorType" }}</span>
    {{#if item.system.protection}}<span class="cde-item-stat">{{item.system.protection}}</span>{{/if}}
    <div class="item-controls">
      <a class="item-control" title="{{ localize 'CDE.ItemEdit' }}" data-action="edit"><i class="fas fa-edit"></i></a>
      <a class="item-control" title="{{ localize 'CDE.ItemDelete' }}" data-action="delete"><i class="fas fa-trash"></i></a>
    </div>
  </li>
  {{/each}}
</ol>
<p>
  <a class="item-control" title="{{ localize 'CDE.ArmorCreate' }}" data-action="create" data-type="armor"><i class="fas fa-plus"></i> {{ localize "CDE.ArmorCreate" }}</a>
</p>

{{! Sanhei }}
{{#if sanheis.length}}
<p class="cde-item-group-label">{{ localize "CDE.Sanheis" }}</p>
{{/if}}
<ol class="item-list">
  {{#each sanheis as |item id|}}
  <li class="item flexrow" data-item-id="{{item._id}}">
    <img src="{{item.img}}" title="{{item.name}}" width="24" height="24" />
    <h4 class="item-name">{{item.name}}</h4>
    <span class="cde-badge sanhei">{{ localize "CDE.SanheiType" }}</span>
    <div class="item-controls">
      <a class="item-control" title="{{ localize 'CDE.ItemEdit' }}" data-action="edit"><i class="fas fa-edit"></i></a>
      <a class="item-control" title="{{ localize 'CDE.ItemDelete' }}" data-action="delete"><i class="fas fa-trash"></i></a>
    </div>
  </li>
  {{/each}}
</ol>
<p>
  <a class="item-control" title="{{ localize 'CDE.SanheiCreate' }}" data-action="create" data-type="sanhei"><i class="fas fa-plus"></i> {{ localize "CDE.SanheiCreate" }}</a>
</p>

{{! Ingredients }}
{{#if ingredients.length}}
<p class="cde-item-group-label">{{ localize "CDE.Ingredients" }}</p>
{{/if}}
<ol class="item-list">
  {{#each ingredients as |item id|}}
  <li class="item flexrow" data-item-id="{{item._id}}">
    <img src="{{item.img}}" title="{{item.name}}" width="24" height="24" />
    <h4 class="item-name">{{item.name}}</h4>
    <span class="cde-badge ingredient">{{ localize "CDE.IngredientType" }}</span>
    <div class="item-controls">
      <a class="item-control" title="{{ localize 'CDE.ItemEdit' }}" data-action="edit"><i class="fas fa-edit"></i></a>
      <a class="item-control" title="{{ localize 'CDE.ItemDelete' }}" data-action="delete"><i class="fas fa-trash"></i></a>
    </div>
  </li>
  {{/each}}
</ol>
<p>
  <a class="item-control" title="{{ localize 'CDE.IngredientCreate' }}" data-action="create" data-type="ingredient"><i class="fas fa-plus"></i> {{ localize "CDE.IngredientCreate" }}</a>
</p>

{{! Generic items }}
{{#if equipments.length}}
<p class="cde-item-group-label">{{ localize "CDE.Items" }}</p>
{{/if}}
<ol class="item-list">
  {{#each equipments as |item id|}}
  <li class="item flexrow" data-item-id="{{item._id}}">
    <img src="{{item.img}}" title="{{item.name}}" width="24" height="24" />
    <h4 class="item-name">{{item.name}}</h4>
    <span class="cde-badge item">{{ localize "CDE.ItemType" }}</span>
    <div class="item-controls">
      <a class="item-control" title="{{ localize 'CDE.ItemEdit' }}" data-action="edit"><i class="fas fa-edit"></i></a>
      <a class="item-control" title="{{ localize 'CDE.ItemDelete' }}" data-action="delete"><i class="fas fa-trash"></i></a>
    </div>
  </li>
  {{/each}}
</ol>
<p>
  <a class="item-control" title="{{ localize 'CDE.ItemCreate' }}" data-action="create" data-type="item"><i class="fas fa-plus"></i> {{ localize "CDE.ItemCreate" }}</a>
</p>
