<div class="exception">
  <div class="exc-title">
    {% for name in causeName %}
      {% if loop.index == causeName.size - 1 %}
        <span class="exc-title-primary">{{name}}</span>
      {% else %}
        {{name}}.
      {% endif %}
    {% endfor %}
    {%if code != null %}
      <span title="Exception Code">: {{code}}</span>
    {% endif %}
  </div>
  <div class="exc-message">
    {% if cause.message != null %}
      <span><span>{{cause.message}}</span></span>
      {% if previousMessages is not empty %}
        <div class="exc-title prev-exc-title">
          <span class="exc-title-secondary">Previous exceptions</span>
        </div>
        <ul>
          {% for previousMessage in previousMessages %}
            <li>
              {{previousMessage}}
              <span class="prev-exc-code">()</span>
            </li>
          {% endfor %}
        </ul>
      {% endif %}
    {% else %}
      <span class="exc-message-empty-notice">No message</span>
    {% endif %}
    
    <span id="plain-exception">{{stacktrace}}</span>
    <button id="copy-button" class="rightButton clipboard" data-clipboard-text="{{stacktrace}}" title="Copy exception details to clipboard">
      COPY
    </button>
    
  </div>
</div>
