<div class="topic-footer-main-buttons">
  <TopicAdminMenuButton
    @topic={{this.topic}}
    @openUpwards="true"
    @toggleMultiSelect={{this.toggleMultiSelect}}
    @showTopicSlowModeUpdate={{this.showTopicSlowModeUpdate}}
    @deleteTopic={{this.deleteTopic}}
    @recoverTopic={{this.recoverTopic}}
    @toggleFeaturedOnProfile={{this.toggleFeaturedOnProfile}}
    @toggleClosed={{this.toggleClosed}}
    @toggleArchived={{this.toggleArchived}}
    @toggleVisibility={{this.toggleVisibility}}
    @showTopicTimerModal={{this.showTopicTimerModal}}
    @showFeatureTopic={{this.showFeatureTopic}}
    @showChangeTimestamp={{this.showChangeTimestamp}}
    @resetBumpDate={{this.resetBumpDate}}
    @convertToPublicTopic={{this.convertToPublicTopic}}
    @convertToPrivateMessage={{this.convertToPrivateMessage}}
  />

  {{#if this.site.mobileView}}
    <TopicFooterMobileDropdown
      @topic={{this.topic}}
      @content={{this.dropdownButtons}}
    />
  {{/if}}

  {{#each this.inlineActionables as |actionable|}}
    {{#if (eq actionable.type "inline-button")}}
      <DButton
        @id={{concat "topic-footer-button-" actionable.id}}
        @class={{concat
          "btn-default topic-footer-button "
          actionable.classNames
        }}
        @action={{actionable.action}}
        @icon={{actionable.icon}}
        @translatedLabel={{actionable.label}}
        @translatedTitle={{actionable.title}}
        @translatedAriaLabel={{actionable.ariaLabel}}
        @disabled={{actionable.disabled}}
      />
    {{else}}
      <DropdownSelectBox
        @id={{concat "topic-footer-dropdown-" actionable.id}}
        @value={{actionable.value}}
        @class={{concat "topic-footer-dropdown " actionable.classNames}}
        @content={{actionable.content}}
        @onChange={{action actionable.action}}
        @options={{hash
          icon=actionable.icon
          none=actionable.noneItem
          disabled=actionable.disabled
        }}
      />
    {{/if}}
  {{/each}}

  <PluginOutlet
    @name="topic-footer-main-buttons-before-create"
    @outletArgs={{hash topic=this.topic}}
    @connectorTagName="span"
  />

  {{#if this.topic.details.can_create_post}}
    <DButton
      @class="btn-primary create"
      @icon="reply"
      @action={{this.replyToPost}}
      @label="topic.reply.title"
      @title="topic.reply.help"
    />
  {{/if}}

  <PluginOutlet
    @name="after-topic-footer-main-buttons"
    @outletArgs={{hash topic=this.topic}}
    @connectorTagName="span"
  />
</div>

<PinnedButton @pinned={{this.topic.pinned}} @topic={{this.topic}} />

{{#if this.showNotificationsButton}}
  {{#if this.showNotificationUserTip}}
    <UserTip
      @id="topic_notification_levels"
      @selector=".notifications-button"
    />
  {{/if}}

  <TopicNotificationsButton
    @notificationLevel={{this.topic.details.notification_level}}
    @topic={{this.topic}}
  />
{{/if}}

<PluginOutlet
  @name="after-topic-footer-buttons"
  @outletArgs={{hash topic=this.topic}}
  @connectorTagName="span"
/>