{{!
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements.  See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership.  The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License.  You may obtain a copy of the License at
*
*     http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
}}

<div class="row">
  <div class="col-md-12 messages-header">
    <div class="col-md-1">
      {{#link-to "files" (query-params path=currentBrowserPath) class="btn btn-primary"}}{{fa-icon "arrow-left"}} Browser{{/link-to}}
    </div>
    <div class="col-md-2 col-md-offset-4 text-center">
      <span class="messages-title">{{fa-icon "comment"}} Messages</span>
    </div>
  </div>
</div>
<div class="row">
  <div class={{if isExpanded "col-md-12" "col-md-4"}}>
    <div class="list-group">
      {{#each model as |message|}}
        {{#link-to 'messages.message' message class=(alert-message-context-class message.type "list-group-item list-group-item-")}}
          <h4 class="list-group-item-heading wrap-message">
            {{#fa-stack}}
              {{fa-icon "circle-thin" stack=2}}
              {{fa-icon (alert-message-icon-class message.type) stack=1}}
            {{/fa-stack}}
            {{{message.message}}}</h4>
          <p class="list-group-item-text wrap-message">{{shorten-text message.responseMessage shortenLength}}</p>
        {{/link-to}}
      {{else}}
        No messages present
      {{/each}}
    </div>

  </div>
  {{#unless isExpanded}}
    <div class="col-md-8">
      {{outlet}}
    </div>
  {{/unless}}
</div>

