mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-11-24 05:29:51 +03:00
Don't show "Filter" button when no branhes (#4093)
This commit is contained in:
parent
81f683777e
commit
c83dec6bca
@ -24,22 +24,24 @@
|
||||
<Badge {count} />
|
||||
{/if}
|
||||
</div>
|
||||
<div class="header__filter-btn" bind:this={filterButton}>
|
||||
<Button
|
||||
style="ghost"
|
||||
outline
|
||||
icon={filtersActive ? 'filter-applied-small' : 'filter-small'}
|
||||
on:mousedown={onFilterClick}
|
||||
>
|
||||
Filter
|
||||
</Button>
|
||||
<div
|
||||
class="filter-popup-menu"
|
||||
use:clickOutside={{ trigger: filterButton, handler: () => (visible = false) }}
|
||||
>
|
||||
<slot name="context-menu" {visible} />
|
||||
{#if count && count > 0}
|
||||
<div class="header__filter-btn" bind:this={filterButton}>
|
||||
<Button
|
||||
style="ghost"
|
||||
outline
|
||||
icon={filtersActive ? 'filter-applied-small' : 'filter-small'}
|
||||
on:mousedown={onFilterClick}
|
||||
>
|
||||
Filter
|
||||
</Button>
|
||||
<div
|
||||
class="filter-popup-menu"
|
||||
use:clickOutside={{ trigger: filterButton, handler: () => (visible = false) }}
|
||||
>
|
||||
<slot name="context-menu" {visible} />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
<style lang="postcss">
|
||||
|
Loading…
Reference in New Issue
Block a user