mirror of
https://github.com/hcengineering/platform.git
synced 2024-12-28 05:56:02 +03:00
Fix contact info (#1087)
Signed-off-by: Andrey Sobolev <haiodo@gmail.com> Co-authored-by: Alexander Platov <sas_lord@mail.ru>
This commit is contained in:
parent
09c9b22938
commit
53ce98c2b3
@ -25,7 +25,7 @@
|
||||
export let primary: boolean = false
|
||||
</script>
|
||||
|
||||
<div class="flex-center icon-button icon-{size}" class:selected class:transparent class:primary on:click on:mousemove>
|
||||
<div class="flex-center icon-button icon-{size}" class:selected class:transparent class:primary on:click|stopPropagation on:mousemove>
|
||||
<div class="content">
|
||||
<Icon {icon} size={'full'} />
|
||||
</div>
|
||||
|
@ -42,7 +42,7 @@
|
||||
><slot /></div>
|
||||
|
||||
{#if !ignore && bigger && !fixed}
|
||||
<div class="showMore" class:outter={cHeight > limit} on:click={toggle}>
|
||||
<div class="showMore" on:click={toggle}>
|
||||
<Label label={(cHeight > limit) ? ui.string.ShowLess : ui.string.ShowMore} />
|
||||
</div>
|
||||
{/if}
|
||||
@ -76,10 +76,5 @@
|
||||
border-radius: 2.5rem;
|
||||
user-select: none;
|
||||
cursor: pointer;
|
||||
|
||||
&.outter {
|
||||
bottom: -2.75rem;
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
@ -19,25 +19,25 @@
|
||||
|
||||
{#each filterTx([tx, ...tx.txes], core.class.TxCreateDoc) as ctx, i}
|
||||
{#if i === 0}
|
||||
<div class='mr-2'>
|
||||
<IconAdd size={'small'} />
|
||||
</div>
|
||||
{/if}
|
||||
{#if typeof viewlet?.component === 'string'}
|
||||
<Component is={viewlet?.component} props={getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||
{:else}
|
||||
<svelte:component this={viewlet?.component} {...getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||
<div class="mr-1"><IconAdd size={'small'} /></div>
|
||||
{/if}
|
||||
<div class="mr-1">
|
||||
{#if typeof viewlet?.component === 'string'}
|
||||
<Component is={viewlet?.component} props={getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||
{:else}
|
||||
<svelte:component this={viewlet?.component} {...getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||
{/if}
|
||||
</div>
|
||||
{/each}
|
||||
{#each filterTx([tx, ...tx.txes], core.class.TxRemoveDoc) as ctx, i}
|
||||
{#if i === 0}
|
||||
<div class='mr-2'>
|
||||
<IconDelete size={'small'} />
|
||||
</div>
|
||||
{/if}
|
||||
{#if typeof viewlet?.component === 'string'}
|
||||
<Component is={viewlet?.component} props={getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||
{:else}
|
||||
<svelte:component this={viewlet?.component} {...getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||
<div class="mr-1"><IconDelete size={'small'} /></div>
|
||||
{/if}
|
||||
<div class="mr-1">
|
||||
{#if typeof viewlet?.component === 'string'}
|
||||
<Component is={viewlet?.component} props={getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||
{:else}
|
||||
<svelte:component this={viewlet?.component} {...getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||
{/if}
|
||||
</div>
|
||||
{/each}
|
||||
|
@ -41,7 +41,7 @@
|
||||
}
|
||||
})}
|
||||
/>
|
||||
<span><Label label={presentation.string.AddSocialLinks} /></span>
|
||||
<span class="ml-2"><Label label={presentation.string.AddSocialLinks} /></span>
|
||||
{:else}
|
||||
<ChannelsView value={channels} size={'small'} {integrations} on:click />
|
||||
<div class="ml-1">
|
||||
@ -58,9 +58,3 @@
|
||||
/>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
<style lang="scss">
|
||||
span {
|
||||
margin-left: 0.5rem;
|
||||
}
|
||||
</style>
|
||||
|
@ -37,4 +37,4 @@
|
||||
}
|
||||
</script>
|
||||
|
||||
<ChannelsView {value} size={'small'} reverse on:click={click} />
|
||||
<ChannelsView {value} size={'small'} length={'short'} on:click={click} />
|
||||
|
@ -26,6 +26,7 @@
|
||||
|
||||
export let value: AttachedData<Channel>[] | Channel | null
|
||||
export let size: 'small' | 'medium' | 'large' | 'x-large' = 'large'
|
||||
export let length: 'short' | 'full' = 'full'
|
||||
export let reverse: boolean = false
|
||||
export let integrations: Set<Ref<Doc>> = new Set<Ref<Doc>>()
|
||||
const notificationClient = NotificationClientImpl.getClient()
|
||||
@ -99,20 +100,36 @@
|
||||
|
||||
<div
|
||||
bind:this={divHTML}
|
||||
class="flex-row-center flex-wrap"
|
||||
class:gap-1={size === 'small'}
|
||||
class:gap-2={size !== 'small'}
|
||||
class="channels {length}"
|
||||
class:one={displayItems?.length === 1}
|
||||
class:reverse
|
||||
class:small-gap={size === 'small'}
|
||||
class:normal-gap={size !== 'small'}
|
||||
>
|
||||
{#each displayItems as item}
|
||||
<div
|
||||
on:click|stopPropagation={() => {
|
||||
dispatch('click', item)
|
||||
}}
|
||||
>
|
||||
<Tooltip component={ChannelsPopup} props={{ value: item }} label={undefined} anchor={divHTML}>
|
||||
<CircleButton icon={item.icon} {size} primary={item.integration || item.notification} />
|
||||
</Tooltip>
|
||||
</div>
|
||||
{#each displayItems as item,i}
|
||||
<Tooltip component={ChannelsPopup} props={{ value: item }} label={undefined} anchor={divHTML}>
|
||||
<CircleButton
|
||||
icon={item.icon}
|
||||
{size}
|
||||
primary={item.integration || item.notification}
|
||||
on:click={() => {
|
||||
dispatch('click', item)
|
||||
}}
|
||||
/>
|
||||
</Tooltip>
|
||||
{/each}
|
||||
</div>
|
||||
<style lang="scss">
|
||||
.channels {
|
||||
display: grid;
|
||||
&.one { display: block; }
|
||||
&.short {
|
||||
grid-template-columns: repeat(4, min-content);
|
||||
grid-auto-rows: auto;
|
||||
}
|
||||
&.full { grid-auto-flow: column; }
|
||||
&.reverse { grid-auto-flow: dense; }
|
||||
&.small-gap { gap: .25rem; }
|
||||
&.normal-gap { gap: .5rem; }
|
||||
}
|
||||
</style>
|
@ -113,7 +113,7 @@
|
||||
|
||||
<div class="separator" />
|
||||
|
||||
<div class="flex-between channels">
|
||||
<div class="flex-between">
|
||||
<div class="flex-row-center">
|
||||
<ChannelsEditor attachedTo={object._id} attachedClass={object._class} {editable} {integrations} on:click />
|
||||
</div>
|
||||
@ -135,9 +135,6 @@
|
||||
font-size: 1.25rem;
|
||||
color: var(--theme-caption-color);
|
||||
}
|
||||
.channels {
|
||||
margin-top: 0.75rem;
|
||||
}
|
||||
.location {
|
||||
margin-top: 0.25rem;
|
||||
font-size: 0.75rem;
|
||||
|
@ -53,7 +53,7 @@
|
||||
<Component is={attachment.component.AttachmentsPresenter} props={{ value: candidate, size: 'medium', showCounter: true }}/>
|
||||
</div>
|
||||
<div class='flex flex-grow'>
|
||||
<ChannelsView value={channels} size={'small'} on:click />
|
||||
<ChannelsView value={channels} size={'small'} length={'short'} on:click />
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
|
Loading…
Reference in New Issue
Block a user