<div class="card clipped-bot" {{#if item_uuid}} data-uuid="{{item_uuid}}" {{/if}} style="margin: 0px;">
  <div class="lancer-header lancer-weapon medium">
    <i class="cci cci-weapon i--m i--light"> </i>
    <span>{{ title }}</span>
    {{!-- TODO: refactor reroll button --}}
    <!-- <a class="flow-button roll-attack lancer-button lancer-macro" data-macro="{{rerollMacroData}}" title="Reroll this attack">
      <i class="fas fa-dice-d20 i--m i--light"></i>
    </a> -->
  </div>
  {{#if profile}}
    {{{mini-profile profile}}}
  {{/if}}
  {{#if (not hit_results.length)}}
    <div class="card clipped">
      <div class="lancer-mini-header collapse-trigger" data-collapse-id="{{_uuid}}-attacks">
        {{localize "lancer.chat-card.title.attack"}}
      </div>
      <div class="collapse" data-collapse-id="{{_uuid}}-attacks">
        {{#each attack_results as |attack key|}}
          {{{lancer-dice-roll attack.roll attack.tt "cci cci-reticule i--m"}}}
        {{/each}}
      </div>
    </div>
  {{/if}}
  {{#if hit_results.length}}
    <div class="lancer-mini-header collapse-trigger" data-collapse-id="{{_uuid}}-hits">
      {{localize "lancer.chat-card.title.defense-hit" defense=defense}}
    </div>
    <div class="collapse" data-collapse-id="{{_uuid}}-hits">
      {{#each hit_results as |hit key|}}
        {{{attack-target hit}}}
      {{/each}}
    </div>
  {{/if}}
  {{#if self_heat_result}}
    <div class="card clipped">
      <div class="lancer-mini-header collapse-trigger" data-collapse-id="{{_uuid}}-self-heat">
        {{localize "lancer.chat-card.title.self-heat"}}
      </div>
      <div class="collapse" data-collapse-id="{{_uuid}}-self-heat">
        {{{lancer-dice-roll self_heat_result.roll self_heat_result.tt "cci cci-heat i--m damage--heat"}}}
      </div>
    </div>
  {{/if}}
  {{#if effect}}
    <div class="card clipped">
      <div class="lancer-mini-header">{{localize "lancer.chat-card.title.effect"}}</div>
      {{#if effect.effect_type}} {{{eff-preview effect}}} {{/if}} {{#unless effect.effect_type}}<span class="effect-text"
    >{{{effect}}}</span
    >{{/unless}}
    </div>
  {{/if}}
  {{#if on_attack}}
    <div class="card clipped">
      <div class="lancer-mini-header collapse-trigger" data-collapse-id="{{_uuid}}-effect">{{localize "lancer.chat-card.title.on-attack"}}</div>
      <span class="effect-text collapse" data-collapse-id="{{_uuid}}-effect">{{{on_attack}}}</span>
    </div>
  {{/if}}
  {{#if on_hit}}
    <div class="card clipped">
      <div class="lancer-mini-header collapse-trigger" data-collapse-id="{{_uuid}}-effect">{{localize "lancer.chat-card.title.on-hit"}}</div>
      <span class="effect-text collapse" data-collapse-id="{{_uuid}}-effect">{{{on_hit}}}</span>
    </div>
  {{/if}}
  {{#if on_crit}}
    <div class="card clipped">
      <div class="lancer-mini-header collapse-trigger" data-collapse-id="{{_uuid}}-effect">{{localize "lancer.chat-card.title.on-crit"}}</div>
      <span class="effect-text collapse" data-collapse-id="{{_uuid}}-effect">{{{on_crit}}}</span>
    </div>
  {{/if}}
  {{{tag-list "tags"}}}
  <button
    class="lancer-button lancer-damage-flow lancer-secondary"
    label="lancer.chat-card.attack.roll-all-damage"
  ><i class="mdi mdi-dice-multiple i--sm i--light"></i>&nbsp;{{localize "lancer.chat-card.attack.roll-all-damage"}}</button>
</div>
