mirror of
https://github.com/hcengineering/platform.git
synced 2026-09-10 03:37:43 +02:00
Refactor Button. Add icons. Fix EditDoc. (#2326)
Signed-off-by: Alexander Platov <sas_lord@mail.ru>
This commit is contained in:
@@ -252,7 +252,7 @@
|
||||
{icon}
|
||||
{title}
|
||||
{object}
|
||||
isHeader={true}
|
||||
isHeader={false}
|
||||
isAside={true}
|
||||
bind:panelWidth
|
||||
bind:innerWidth
|
||||
@@ -265,24 +265,6 @@
|
||||
<UpDownNavigator element={object} />
|
||||
</svelte:fragment>
|
||||
|
||||
<svelte:fragment slot="header">
|
||||
<span class="fs-title flex-grow">
|
||||
{#if mainEditor}
|
||||
<Component
|
||||
is={mainEditor}
|
||||
props={{ object }}
|
||||
on:open={(ev) => {
|
||||
ignoreKeys = ev.detail.ignoreKeys
|
||||
ignoreMixins = new Set(ev.detail.ignoreMixins)
|
||||
allowedCollections = ev.detail.allowedCollections ?? []
|
||||
collectionArrays = ev.detail.collectionArrays ?? []
|
||||
getMixins(parentClass, object, showAllMixins)
|
||||
updateKeys(showAllMixins)
|
||||
}}
|
||||
/>
|
||||
{/if}
|
||||
</span>
|
||||
</svelte:fragment>
|
||||
<svelte:fragment slot="tools">
|
||||
<div class="p-1">
|
||||
<Button icon={IconMoreH} kind={'transparent'} size={'medium'} on:click={showMenu} />
|
||||
@@ -335,6 +317,20 @@
|
||||
{/if}
|
||||
</svelte:fragment>
|
||||
|
||||
{#if mainEditor}
|
||||
<Component
|
||||
is={mainEditor}
|
||||
props={{ object }}
|
||||
on:open={(ev) => {
|
||||
ignoreKeys = ev.detail.ignoreKeys
|
||||
ignoreMixins = new Set(ev.detail.ignoreMixins)
|
||||
allowedCollections = ev.detail.allowedCollections ?? []
|
||||
collectionArrays = ev.detail.collectionArrays ?? []
|
||||
getMixins(parentClass, object, showAllMixins)
|
||||
updateKeys(showAllMixins)
|
||||
}}
|
||||
/>
|
||||
{/if}
|
||||
{#each fieldEditors as collection}
|
||||
{#if collection.editor}
|
||||
<div class="mt-6 clear-mins">
|
||||
|
||||
@@ -156,7 +156,7 @@
|
||||
{:else}
|
||||
{#each values as value, i}
|
||||
<button
|
||||
class="menu-item"
|
||||
class="menu-item no-focus"
|
||||
on:click={() => {
|
||||
toggle(value)
|
||||
}}
|
||||
@@ -167,7 +167,7 @@
|
||||
<CheckBox checked={isSelected(value, filter.value)} primary />
|
||||
</div>
|
||||
{#if value}
|
||||
<svelte:component this={attribute.presenter} {value} {...attribute.props} />
|
||||
<svelte:component this={attribute.presenter} {value} {...attribute.props} isInteractive={false} />
|
||||
{:else}
|
||||
<Label label={ui.string.NotSelected} />
|
||||
{/if}
|
||||
|
||||
Reference in New Issue
Block a user