mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Reorder should start after 300ms. In addition, pointer events should be blocked to not open link after reorder is finished.
53 lines
1.6 KiB
Handlebars
53 lines
1.6 KiB
Handlebars
{{#if this.displaySection}}
|
|
<div
|
|
class={{concat-class "sidebar-section-wrapper sidebar-section" @class}}
|
|
data-section-name={{@sectionName}}
|
|
>
|
|
<div class="sidebar-section-header-wrapper sidebar-row">
|
|
<Sidebar::SectionHeader
|
|
@collapsable={{@collapsable}}
|
|
@sidebarSectionContentID={{this.sidebarSectionContentID}}
|
|
@toggleSectionDisplay={{this.toggleSectionDisplay}}
|
|
@isExpanded={{this.displaySectionContent}}
|
|
>
|
|
{{#if @collapsable}}
|
|
<span class="sidebar-section-header-caret">
|
|
{{d-icon this.headerCaretIcon}}
|
|
</span>
|
|
{{/if}}
|
|
|
|
<span class="sidebar-section-header-text">
|
|
{{@headerLinkText}}
|
|
</span>
|
|
</Sidebar::SectionHeader>
|
|
|
|
{{#if this.isSingleHeaderAction}}
|
|
{{#each @headerActions as |headerAction|}}
|
|
<button
|
|
type="button"
|
|
class="sidebar-section-header-button"
|
|
{{on "click" headerAction.action}}
|
|
title={{headerAction.title}}
|
|
>
|
|
{{d-icon @headerActionsIcon}}
|
|
</button>
|
|
{{/each}}
|
|
{{/if}}
|
|
|
|
{{#if this.isMultipleHeaderActions}}
|
|
<DropdownSelectBox
|
|
@options={{hash icon=@headerActionsIcon placementStrategy="absolute"}}
|
|
@content={{@headerActions}}
|
|
@onChange={{action "handleMultipleHeaderActions"}}
|
|
@class="sidebar-section-header-dropdown"
|
|
/>
|
|
{{/if}}
|
|
</div>
|
|
|
|
{{#if this.displaySectionContent}}
|
|
<ul class="sidebar-section-content" id={{this.sidebarSectionContentID}}>
|
|
{{yield}}
|
|
</ul>
|
|
{{/if}}
|
|
</div>
|
|
{{/if}} |