.row
  .col-md-6
    .gl-card.gl-mb-5
      .gl-card-header
        = _('Licensed to')
      .gl-card-body
        %ul.content-list
          - @license.licensee.each do |label, value|
            %li
              %span.light= succeed(':') { label }
              %strong= value

    .gl-card.js-license-info-panel.gl-mb-5
      .gl-card-header
        = _('Details')
      .gl-card-body
        %ul.content-list
          %li
            %span.light= _('Plan:')
            %strong= @license.plan.capitalize
            - unless @license.ultimate?
              = ' - '
              = link_to _('Contact Sales to upgrade'),
                'https://about.gitlab.com/sales/?inapplink=contactsalessm',
                class: 'inline-link',
                target: :_blank,
                rel: :noreferrer
          %li
            %span.light= _('Uploaded:')
            %strong= time_ago_with_tooltip @license.created_at
          %li
            %span.light= _('Started:')
            %strong= time_ago_with_tooltip @license.starts_at
          %li
            %span.light
              = render 'license_status'

            - if @license.expired?
              %span.badge.badge-danger.float-right
                %strong= _('Expired')
          %li
            %span.light= _('License ID:')
            %strong= @license.license_id
            = clipboard_button(text: @license.license_id, title: _("Copy ID"), class: "btn-transparent btn-clipboard")


  .col-md-6
    .gl-card.border-info.gl-mb-5
      .gl-card-header.bg-info.text-white
        = _('Download license')
      .gl-card-body
        %p= html_escape(_('Your license will be included in your GitLab backup and will survive upgrades, so in normal usage you should never need to re-upload your %{code_open}.gitlab-license%{code_close} file.')) % { code_open: '<code>'.html_safe, code_close: '</code>'.html_safe }
        %p= _('Still, we recommend keeping a backup saved somewhere. Otherwise, if you ever need it and have lost it, you will need to request GitLab Inc. to send it to you again.')
        %br
        = link_to _('Download license'), download_admin_license_path, class: 'gl-button btn btn-info'
        = link_to _('Customer Portal'), 'https://customers.gitlab.com', class: 'gl-button btn btn-info btn-inverted', data: { track_event: 'click_text', track_label: 'license_dashboard', track_property: 'customer_portal' }, target: '_blank', rel: 'noopener noreferrer'

    .gl-card.border-danger.gl-mb-5
      .gl-card-header.bg-danger.text-white
        = _('Remove license')
      .gl-card-body
        %p= _('If you remove this license, GitLab will fall back on the previous license, if any.')
        %p= _('If there is no previous license or if the previous license has expired, some GitLab functionality will be blocked until a new, valid license is uploaded.')
        %br
        = link_to _('Remove license'), admin_license_path, data: { confirm: _('Are you sure you want to remove the license?'), qa_selector: 'remove_license_link' }, method: :delete, class: 'gl-button btn btn-danger'
