{{!
  Copyright IBM Corp. 2016, 2025
  SPDX-License-Identifier: BUSL-1.1
}}

<PageHeader as |p|>
  <p.top>
    <Page::Breadcrumbs @breadcrumbs={{@breadcrumbs}} />
  </p.top>
  <p.levelLeft>
    <h1 class="title is-3" data-test-header-title>
      {{@model.name}}
    </h1>
  </p.levelLeft>
</PageHeader>

<div class="tabs-container box is-bottomless is-marginless is-paddingless">
  <nav class="tabs" aria-label="ldap tabs">
    <ul>
      <li><LinkTo @route="libraries.library.details.accounts" data-test-tab="accounts">Accounts</LinkTo></li>
      <li><LinkTo @route="libraries.library.details.configuration" data-test-tab="config">Configuration</LinkTo></li>
    </ul>
  </nav>
</div>

<Toolbar>
  <ToolbarActions aria-label="actions for library {{@model.id}}">
    {{#if @model.canDelete}}
      <ConfirmAction
        @buttonText="Delete library"
        class="toolbar-button"
        @buttonColor="secondary"
        @onConfirmAction={{this.delete}}
        data-test-delete
      />
      {{#if @model.canEdit}}
        <div class="toolbar-separator"></div>
      {{/if}}
    {{/if}}
    {{#if @model.canEdit}}
      <ToolbarLink @route="libraries.library.edit" data-test-edit>
        Edit library
      </ToolbarLink>
    {{/if}}
  </ToolbarActions>
</Toolbar>