{{!
  Copyright (c) HashiCorp, Inc.
  SPDX-License-Identifier: BUSL-1.1
~}}

{{#if (or (and @items.meta @items.meta.total) @items.length)}}
  <div class="box is-fullwidth is-bottomless is-sideless is-paddingless" data-test-list-view-list>
    {{#each @items as |item|}}
      {{yield (hash item=item)}}
    {{else}}
      {{yield}}
    {{/each}}
    {{#if this.showPagination}}
      <ListPagination
        @page={{@items.meta.currentPage}}
        @lastPage={{@items.meta.lastPage}}
        @link={{@paginationRouteName}}
        data-test-list-view-pagination
      />
    {{/if}}
  </div>
{{else}}
  {{yield (hash empty=(component "empty-state" title=this.emptyTitle message=this.emptyMessage))}}
{{/if}}