This repository has been archived on 2023-03-18. You can view files and clone it, but cannot push or open issues or pull requests.
osr-discourse-src/app/assets/javascripts/discourse/templates/components/topic-footer-buttons.hbs

100 lines
3.1 KiB
Handlebars

<div class='topic-footer-main-buttons'>
{{#if showAdminButton}}
{{topic-admin-menu-button
topic=topic
openUpwards="true"
toggleMultiSelect=toggleMultiSelect
hideMultiSelect=hideMultiSelect
deleteTopic=deleteTopic
recoverTopic=recoverTopic
toggleClosed=toggleClosed
toggleArchived=toggleArchived
toggleVisibility=toggleVisibility
showTopicStatusUpdate=showTopicStatusUpdate
showFeatureTopic=showFeatureTopic
showChangeTimestamp=showChangeTimestamp
resetBumpDate=resetBumpDate
convertToPublicTopic=convertToPublicTopic
convertToPrivateMessage=convertToPrivateMessage}}
{{/if}}
{{#unless topic.isPrivateMessage}}
{{#if site.mobileView}}
{{topic-footer-mobile-dropdown topic=topic
showInvite=showInvite
showFlagTopic=showFlagTopic}}
{{else}}
{{d-button class=bookmarkClass
title=bookmarkTitle
label=bookmarkLabel
icon="bookmark"
action=toggleBookmark}}
{{share-button url=topic.shareUrl}}
{{#if topic.details.can_flag_topic}}
{{d-button class="flag-topic"
title="topic.flag_topic.help"
label="topic.flag_topic.title"
icon="flag"
action=showFlagTopic}}
{{/if}}
{{/if}}
{{/unless}}
{{#if canInviteTo}}
{{d-button class="invite-topic"
title="topic.invite_reply.help"
label="topic.invite_reply.title"
icon="users"
action=showInvite
disabled=inviteDisabled}}
{{/if}}
{{#if canArchive}}
{{d-button class="standard archive-topic"
title=archiveTitle
label=archiveLabel
icon=archiveIcon
action=toggleArchiveMessage}}
{{/if}}
{{#if showEditOnFooter}}
{{d-button class="edit-message"
title="topic.edit_message.help"
label="topic.edit_message.title"
icon="pencil"
action=editFirstPost}}
{{/if}}
{{plugin-outlet name="topic-footer-main-buttons-before-create"
args=(hash topic=topic)
tagName=""
connectorTagName="span"}}
{{#if topic.details.can_create_post}}
{{d-button class="btn-primary create"
icon="reply"
action=replyToPost
label="topic.reply.title"
title="topic.reply.help"}}
{{/if}}
{{plugin-outlet name="after-topic-footer-main-buttons"
args=(hash topic=topic)
tagName=""
connectorTagName="span"}}
{{pinned-button pinned=topic.pinned topic=topic}}
</div>
{{#if showNotificationsButton}}
{{topic-notifications-button notificationLevel=topic.details.notification_level topic=topic}}
{{/if}}
{{plugin-outlet name="after-topic-footer-buttons"
args=(hash topic=topic)
tagName=""
connectorTagName="span"}}