[UBER-782] Added disabled parameter to DM presenter (#3620)

Signed-off-by: Oleg Solodkov <oleg.solodkov@xored.com>
This commit is contained in:
Oleg Solodkov 2023-08-23 15:33:22 +07:00 committed by GitHub
parent 411c194e22
commit 77f6b3dfd6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 6 additions and 4 deletions

View File

@ -21,6 +21,8 @@
import { getDmName } from '../utils'
export let value: DirectMessage
export let disabled = false
const client = getClient()
$: icon = client.getHierarchy().getClass(value._class).icon
@ -28,7 +30,7 @@
{#if value}
{#await getDmName(client, value) then name}
<NavLink app={chunterId} space={value._id}>
<NavLink app={chunterId} space={value._id} {disabled}>
<div class="flex-presenter">
<div class="icon">
{#if icon}

View File

@ -50,6 +50,6 @@
{#if presenter}
<span class="labels-row">
<span style:text-transform={'lowercase'}><Label label={chunter.string.In} /></span>
<svelte:component this={presenter.presenter} value={doc} inline />
<svelte:component this={presenter.presenter} value={doc} inline disabled />
</span>
{/if}

View File

@ -96,7 +96,7 @@
>
<div class="flex-row-center flex-no-shrink mr-8">
{#if presenter}
<svelte:component this={presenter} value={doc} inline accent />
<svelte:component this={presenter} value={doc} inline accent disabled />
{/if}
{#if newTxes > 0 && !selected}
<div class="counter float">{newTxes}</div>

View File

@ -111,7 +111,7 @@
</div>
<div class="clear-mins flex-no-shrink mt-4">
{#if presenter}
<svelte:component this={presenter} value={doc} inline />
<svelte:component this={presenter} value={doc} inline disabled />
{/if}
</div>
<div class="flex-between flex-baseline mt-3">