<div style={{profileBannerBackgroundColorStyle}} class='moderation-card__header theme--dark'>
  {{#if cardInfo.user.isLoading}}
    {{loading-spinner}}
  {{/if}}

  <button type="button" {{action closeAction}} class='button button--icon-only moderation-card__close-button'>
    {{svg-icon path='svg/chat/close'}}
  </button>

  <div class='moderation-card__drag-handle js-drag-handle'></div>

  <div class="flex">
    <img src="{{profilePicture}}" class='square-5 moderation-card__channel-logo flex__item'>
    <h4 class='moderation-card__name ellipsis mg-l-1 mg-r-2 flex__item cl-white'>
      {{#unless cardInfo.user.isLoading}}
        <a class="cl-white" href="/{{cardInfo.user.id}}" target='_blank' rel='noopener noreferrer'>
          {{format-display-name cardInfo.user.id cardInfo.user.display_name}}
        </a>
      {{/unless}}
    </h4>
  </div>

  <div class='moderation-card__channel-background' style={{profileBannerBackgroundImageStyle}}></div>
</div>

<div class='moderation-card__actions theme--light clearfix'>
  <div class='clearfix'>
    {{#unless cardInfo.isChannelOwner}}
      {{follow-button name="chat" channel=cardInfo.user track=trackFollowButtonAction class="float-left mg-r-1"}}

      {{twitch-friends-list/twitch-friend-button userId=cardInfo.user._id userLogin=cardInfo.user.name uiContext='chat_card' class='float-left mg-r-1'}}
    {{/unless}}

    <button {{action 'message'}} class='message-button button button--hollow float-left'>{{i18n 'Whisper'}}</button>
    {{#if isIgnored}}
      <button {{action unignoreAction (hash user=moderationTarget)}} class='ignore button button--icon-only light tooltip float-left mg-l-1' title={{i18n 'Unignore User'}}>
        {{svg-icon path='svg/unignore'}}
      </button>
    {{else}}
      <button {{action ignoreAction (hash user=moderationTarget)}} class='ignore button button--icon-only tooltip float-left mg-l-1' title={{i18n 'Ignore User'}}>
        {{svg-icon path='svg/ignore'}}
      </button>
    {{/if}}
  </div>

  {{#if cardInfo.isModeratorOrHigher}}
    <div class='moderation-card__controls mg-t-1'>
      <button {{action timeoutAction (hash user=moderationTarget tracking_source='moderation_card')}} class='timeout button button--icon-only light tooltip' title={{i18n 'Timeout User'}}>
        {{svg-icon path='svg/timeout'}}
      </button>

      <button {{action banAction (hash user=moderationTarget tracking_source='moderation_card')}} class='ban button button--icon-only light tooltip' title={{i18n 'Ban User'}}>
        {{svg-icon path='svg/ban'}}
      </button>

      <button {{action modAction (hash user=moderationTarget tracking_source='moderation_card')}} class='mod button button--icon-only light tooltip' title={{i18n 'Mod User'}}>
        {{svg-icon path='svg/op'}}
      </button>
    </div>
  {{/if}}

</div>
