Fix board menu button (#1693)

Signed-off-by: Dvinyanin Alexandr <dvinyanin.alexandr@gmail.com>
This commit is contained in:
Alex 2022-05-07 00:46:54 +07:00 committed by GitHub
parent 64a8a27265
commit 9951132b3c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,6 +1,6 @@
<script lang="ts">
import core, { Ref, Space } from '@anticrm/core'
import { Button, getCurrentLocation, navigate } from '@anticrm/ui'
import { Button, getCurrentLocation, navigate, location } from '@anticrm/ui'
import { createQuery, getClient } from '@anticrm/presentation'
import { Header, classIcon } from '@anticrm/chunter-resources'
import border from '../plugin'
@ -20,11 +20,14 @@
loc.path[3] = space._id
navigate(loc)
}
$: showMenuButton = $location.path[3] !== spaceId
</script>
<div class="ac-header divide full">
{#if space}
<Header icon={classIcon(client, space._class)} label={space.name} description={space.description} />
<Button label={border.string.ShowMenu} on:click={showMenu} />
{#if showMenuButton}
<Button label={border.string.ShowMenu} on:click={showMenu} />
{/if}
{/if}
</div>