mirror of
https://github.com/hcengineering/platform.git
synced 2025-04-23 08:48:01 +00: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
|
export let primary: boolean = false
|
||||||
</script>
|
</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">
|
<div class="content">
|
||||||
<Icon {icon} size={'full'} />
|
<Icon {icon} size={'full'} />
|
||||||
</div>
|
</div>
|
||||||
|
@ -42,7 +42,7 @@
|
|||||||
><slot /></div>
|
><slot /></div>
|
||||||
|
|
||||||
{#if !ignore && bigger && !fixed}
|
{#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} />
|
<Label label={(cHeight > limit) ? ui.string.ShowLess : ui.string.ShowMore} />
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
@ -76,10 +76,5 @@
|
|||||||
border-radius: 2.5rem;
|
border-radius: 2.5rem;
|
||||||
user-select: none;
|
user-select: none;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
||||||
&.outter {
|
|
||||||
bottom: -2.75rem;
|
|
||||||
transform: translateX(-50%);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -19,25 +19,25 @@
|
|||||||
|
|
||||||
{#each filterTx([tx, ...tx.txes], core.class.TxCreateDoc) as ctx, i}
|
{#each filterTx([tx, ...tx.txes], core.class.TxCreateDoc) as ctx, i}
|
||||||
{#if i === 0}
|
{#if i === 0}
|
||||||
<div class='mr-2'>
|
<div class="mr-1"><IconAdd size={'small'} /></div>
|
||||||
<IconAdd size={'small'} />
|
|
||||||
</div>
|
|
||||||
{/if}
|
{/if}
|
||||||
|
<div class="mr-1">
|
||||||
{#if typeof viewlet?.component === 'string'}
|
{#if typeof viewlet?.component === 'string'}
|
||||||
<Component is={viewlet?.component} props={getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
<Component is={viewlet?.component} props={getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||||
{:else}
|
{:else}
|
||||||
<svelte:component this={viewlet?.component} {...getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
<svelte:component this={viewlet?.component} {...getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||||
{/if}
|
{/if}
|
||||||
|
</div>
|
||||||
{/each}
|
{/each}
|
||||||
{#each filterTx([tx, ...tx.txes], core.class.TxRemoveDoc) as ctx, i}
|
{#each filterTx([tx, ...tx.txes], core.class.TxRemoveDoc) as ctx, i}
|
||||||
{#if i === 0}
|
{#if i === 0}
|
||||||
<div class='mr-2'>
|
<div class="mr-1"><IconDelete size={'small'} /></div>
|
||||||
<IconDelete size={'small'} />
|
|
||||||
</div>
|
|
||||||
{/if}
|
{/if}
|
||||||
|
<div class="mr-1">
|
||||||
{#if typeof viewlet?.component === 'string'}
|
{#if typeof viewlet?.component === 'string'}
|
||||||
<Component is={viewlet?.component} props={getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
<Component is={viewlet?.component} props={getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||||
{:else}
|
{:else}
|
||||||
<svelte:component this={viewlet?.component} {...getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
<svelte:component this={viewlet?.component} {...getProps(getDTxProps(ctx), edit)} on:close={onCancelEdit} />
|
||||||
{/if}
|
{/if}
|
||||||
|
</div>
|
||||||
{/each}
|
{/each}
|
||||||
|
@ -41,7 +41,7 @@
|
|||||||
}
|
}
|
||||||
})}
|
})}
|
||||||
/>
|
/>
|
||||||
<span><Label label={presentation.string.AddSocialLinks} /></span>
|
<span class="ml-2"><Label label={presentation.string.AddSocialLinks} /></span>
|
||||||
{:else}
|
{:else}
|
||||||
<ChannelsView value={channels} size={'small'} {integrations} on:click />
|
<ChannelsView value={channels} size={'small'} {integrations} on:click />
|
||||||
<div class="ml-1">
|
<div class="ml-1">
|
||||||
@ -58,9 +58,3 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
<style lang="scss">
|
|
||||||
span {
|
|
||||||
margin-left: 0.5rem;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
@ -37,4 +37,4 @@
|
|||||||
}
|
}
|
||||||
</script>
|
</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 value: AttachedData<Channel>[] | Channel | null
|
||||||
export let size: 'small' | 'medium' | 'large' | 'x-large' = 'large'
|
export let size: 'small' | 'medium' | 'large' | 'x-large' = 'large'
|
||||||
|
export let length: 'short' | 'full' = 'full'
|
||||||
export let reverse: boolean = false
|
export let reverse: boolean = false
|
||||||
export let integrations: Set<Ref<Doc>> = new Set<Ref<Doc>>()
|
export let integrations: Set<Ref<Doc>> = new Set<Ref<Doc>>()
|
||||||
const notificationClient = NotificationClientImpl.getClient()
|
const notificationClient = NotificationClientImpl.getClient()
|
||||||
@ -99,20 +100,36 @@
|
|||||||
|
|
||||||
<div
|
<div
|
||||||
bind:this={divHTML}
|
bind:this={divHTML}
|
||||||
class="flex-row-center flex-wrap"
|
class="channels {length}"
|
||||||
class:gap-1={size === 'small'}
|
class:one={displayItems?.length === 1}
|
||||||
class:gap-2={size !== 'small'}
|
|
||||||
class:reverse
|
class:reverse
|
||||||
|
class:small-gap={size === 'small'}
|
||||||
|
class:normal-gap={size !== 'small'}
|
||||||
>
|
>
|
||||||
{#each displayItems as item}
|
{#each displayItems as item,i}
|
||||||
<div
|
<Tooltip component={ChannelsPopup} props={{ value: item }} label={undefined} anchor={divHTML}>
|
||||||
on:click|stopPropagation={() => {
|
<CircleButton
|
||||||
|
icon={item.icon}
|
||||||
|
{size}
|
||||||
|
primary={item.integration || item.notification}
|
||||||
|
on:click={() => {
|
||||||
dispatch('click', item)
|
dispatch('click', item)
|
||||||
}}
|
}}
|
||||||
>
|
/>
|
||||||
<Tooltip component={ChannelsPopup} props={{ value: item }} label={undefined} anchor={divHTML}>
|
|
||||||
<CircleButton icon={item.icon} {size} primary={item.integration || item.notification} />
|
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
</div>
|
|
||||||
{/each}
|
{/each}
|
||||||
</div>
|
</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="separator" />
|
||||||
|
|
||||||
<div class="flex-between channels">
|
<div class="flex-between">
|
||||||
<div class="flex-row-center">
|
<div class="flex-row-center">
|
||||||
<ChannelsEditor attachedTo={object._id} attachedClass={object._class} {editable} {integrations} on:click />
|
<ChannelsEditor attachedTo={object._id} attachedClass={object._class} {editable} {integrations} on:click />
|
||||||
</div>
|
</div>
|
||||||
@ -135,9 +135,6 @@
|
|||||||
font-size: 1.25rem;
|
font-size: 1.25rem;
|
||||||
color: var(--theme-caption-color);
|
color: var(--theme-caption-color);
|
||||||
}
|
}
|
||||||
.channels {
|
|
||||||
margin-top: 0.75rem;
|
|
||||||
}
|
|
||||||
.location {
|
.location {
|
||||||
margin-top: 0.25rem;
|
margin-top: 0.25rem;
|
||||||
font-size: 0.75rem;
|
font-size: 0.75rem;
|
||||||
|
@ -53,7 +53,7 @@
|
|||||||
<Component is={attachment.component.AttachmentsPresenter} props={{ value: candidate, size: 'medium', showCounter: true }}/>
|
<Component is={attachment.component.AttachmentsPresenter} props={{ value: candidate, size: 'medium', showCounter: true }}/>
|
||||||
</div>
|
</div>
|
||||||
<div class='flex flex-grow'>
|
<div class='flex flex-grow'>
|
||||||
<ChannelsView value={channels} size={'small'} on:click />
|
<ChannelsView value={channels} size={'small'} length={'short'} on:click />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
Loading…
Reference in New Issue
Block a user