reusing social presenter in the candidate card

Signed-off-by: Andrey Platov <andrey@hardcoreeng.com>
This commit is contained in:
Andrey Platov 2021-09-01 19:38:31 +02:00
parent 0f6fde311c
commit 8d0c3b9969
No known key found for this signature in database
GPG Key ID: C8787EFEB4B64AF0

View File

@ -19,7 +19,7 @@
import type { Ref, Space, Doc } from '@anticrm/core'
import { generateId } from '@anticrm/core'
import { EditBox, Button, CircleButton, Grid, Label, Link, showPopup } from '@anticrm/ui'
import { EditBox, Button, CircleButton, Grid, Label, Link, showPopup, Component } from '@anticrm/ui'
import type { AnyComponent } from '@anticrm/ui'
import { getClient } from '@anticrm/presentation'
@ -35,6 +35,7 @@
import { Candidate } from '@anticrm/recruit'
import chunter from '@anticrm/chunter'
import contact from '@anticrm/contact'
const dispatch = createEventDispatcher()
@ -141,7 +142,7 @@
</div>
<div class="abs-rt-content">
<Grid column={2} columnGap={.5}>
<CircleButton icon={Twitter} label={'Twitter'} />
<div><Component is='contact:component:ChannelsPresenter' props={ { value: newValue.channels } }/></div>
<CircleButton icon={Edit} label={'Edit'} on:click={(ev) => showPopup(SocialEditor, { values: newValue.channels ?? [] }, ev.target, (result) => { newValue.channels = result; isChanged() })} />
</Grid>
</div>