Fix scrollbar and icons. Contact: Add Open integration. (#1956)

Signed-off-by: Alexander Platov <sas_lord@mail.ru>
This commit is contained in:
Alexander Platov 2022-05-31 07:22:47 +03:00 committed by GitHub
parent 5faa41a206
commit 7479ec6ca7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 98 additions and 84 deletions

View File

@ -66,9 +66,9 @@
--highlight-select-border: #2f3544;
--highlight-select-hover: #323a4e;
--scrollbar-bar-color: #ffffff10;
--scrollbar-bar-hover: #ffffff15;
--scrollbar-track-color: #ffffff0a;
--scrollbar-bar-color: #28292b; // #ffffff10;
--scrollbar-bar-hover: #2d2f36; // #ffffff15;
--scrollbar-track-color: #27282b; // #ffffff0a;
--dark-color: #62666d;
--content-color: #8a8f98;
@ -216,9 +216,9 @@
--highlight-select-border: #e6eaff;
--highlight-select-hover: #e4ebff;
--scrollbar-bar-color: #00000010;
--scrollbar-bar-hover: #00000015;
--scrollbar-track-color: #0000000a;
--scrollbar-bar-color: #eee; // #00000010;
--scrollbar-bar-hover: #f0f3f9; // #00000015;
--scrollbar-track-color: #f8f9fb; // #0000000a;
--dark-color: #90959d;
--content-color: #3c4149;

View File

@ -34,8 +34,10 @@
grid-template-columns: auto;
grid-auto-flow: column;
grid-auto-columns: min-content;
gap: 0.75rem;
gap: .75rem;
align-items: center;
&.withSettings { padding-right: .75rem; }
}
&.mirror {
justify-content: space-between;

View File

@ -55,8 +55,8 @@
<path d="M12.8,16.5c0-0.4-0.3-0.8-0.8-0.8c-1.2,0-2.3-0.1-3.5-0.2c-0.3-2.3-0.3-4.6,0-6.9c2.3-0.3,4.6-0.3,6.9,0 c0.1,1.1,0.2,2.3,0.2,3.5c0,0.4,0.3,0.8,0.8,0.8c0.4,0,0.8-0.3,0.8-0.8c0-1.1-0.1-2.2-0.2-3.2c1.3,0.2,2.5,0.5,3.8,0.9 c0.1,0,0.1,0,0.2,0c0.2,0.7,0.3,1.5,0.3,2.3c0,0.4,0.3,0.8,0.8,0.8s0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.6-0.2-1.2-0.8-1.8 S20.8,14.4,20.1,14.4z M20.3,15.9C20.3,15.9,20.3,15.9,20.3,15.9c0.2,0,0.5,0.2,0.6,0.4c0.2,0.2,0.4,0.4,0.3,0.6 c0,0.1-0.1,0.3-0.3,0.5l-0.2,0.2c-0.5-0.2-0.9-0.7-1.1-1.2l0.2-0.2C19.9,16,20.1,15.9,20.3,15.9z M17.4,21c0,0-0.1,0.1-0.2,0.1 l-1.2,0.2l0.2-1.2c0,0,0-0.1,0.1-0.2l2.3-2.3c0.3,0.5,0.7,0.9,1.2,1.2L17.4,21z" />
</symbol>
<symbol id='homepage' fill='none' viewBox="0 0 28 28">
<path d="M4.66602 22.9167V12.7127C4.66602 12.4192 4.79497 12.1405 5.01869 11.9505L13.6149 4.65008C13.9969 4.32565 14.5601 4.33411 14.9321 4.66986L23.0026 11.9522C23.2127 12.1418 23.3327 12.4116 23.3327 12.6946V22.9167C23.3327 23.469 22.885 23.9167 22.3327 23.9167H5.66602C5.11373 23.9167 4.66602 23.469 4.66602 22.9167Z" stroke="white" stroke-width="1.2"/>
<symbol id="homepage" viewBox="0 0 24 24">
<path d="M12,1.2C6.1,1.2,1.2,6.1,1.2,12S6.1,22.8,12,22.8S22.8,17.9,22.8,12S17.9,1.2,12,1.2z M20.8,14.3 c-1.2,0.4-2.5,0.7-3.8,0.9c0.2-2.1,0.2-4.3,0-6.5c1.3,0.2,2.5,0.5,3.8,0.9c0.1,0,0.1,0,0.2,0c0.2,0.7,0.3,1.5,0.3,2.3 c0,0.8-0.1,1.5-0.3,2.3C20.9,14.3,20.8,14.3,20.8,14.3z M3,14.3c-0.2-0.7-0.3-1.5-0.3-2.3c0-0.8,0.1-1.5,0.3-2.3c0.1,0,0.1,0,0.2,0 C4.5,9.3,5.7,9,7,8.8c-0.2,2.1-0.2,4.3,0,6.5c-1.3-0.2-2.5-0.5-3.8-0.9C3.2,14.3,3.1,14.3,3,14.3z M8.5,8.5c2.3-0.3,4.6-0.3,6.9,0 c0.3,2.3,0.3,4.6,0,6.9c-2.3,0.3-4.6,0.3-6.9,0C8.3,13.2,8.3,10.8,8.5,8.5z M20.3,8c-1.2-0.3-2.3-0.6-3.5-0.8 C16.6,6,16.3,4.8,16,3.7C17.9,4.6,19.4,6.1,20.3,8z M14.3,3c0,0.1,0,0.1,0,0.2C14.7,4.5,15,5.7,15.2,7c-2.1-0.2-4.3-0.2-6.5,0 C9,5.7,9.3,4.5,9.7,3.2c0-0.1,0-0.1,0-0.2c0.7-0.2,1.5-0.3,2.3-0.3C12.8,2.8,13.5,2.9,14.3,3z M7.9,3.7C7.9,3.7,7.9,3.7,7.9,3.7 C7.6,4.9,7.4,6,7.2,7.2C6,7.4,4.8,7.7,3.7,8C4.5,6.2,6,4.7,7.9,3.7z M3.7,16.1C3.7,16.1,3.7,16.1,3.7,16.1c1.2,0.2,2.3,0.5,3.5,0.7 C7.4,18,7.6,19.1,8,20.2c0,0-0.1,0-0.1,0C6.1,19.4,4.6,17.9,3.7,16.1z M9.7,21c0-0.1,0-0.1,0-0.2C9.3,19.5,9,18.3,8.8,17 c1.1,0.1,2.2,0.2,3.2,0.2c1.1,0,2.2-0.1,3.2-0.2c-0.2,1.3-0.5,2.5-0.9,3.8c0,0.1,0,0.1,0,0.2c-0.7,0.2-1.5,0.3-2.3,0.3 C11.2,21.2,10.5,21.1,9.7,21z M16,20.3c0.3-1.2,0.6-2.4,0.8-3.6c1.2-0.2,2.3-0.4,3.5-0.8c0,0,0,0.1,0,0.1C19.4,18,17.8,19.5,16,20.3 z"/>
</symbol>
</svg>

Before

Width:  |  Height:  |  Size: 9.9 KiB

After

Width:  |  Height:  |  Size: 11 KiB

View File

@ -130,6 +130,18 @@
dispatch('close', value)
}}
/>
{#if openable}
<Button
focusIndex={4}
kind={'transparent'}
size={'small'}
icon={IconArrowRight}
on:click={() => {
dispatch('update', value)
dispatch('close', 'open')
}}
/>
{/if}
</div>
{:else}
<div class="buttons-group xsmall-gap">

View File

@ -183,7 +183,8 @@
{
value: item.value,
placeholder: item.placeholder,
editable
editable,
openable: item.presenter ?? false
},
el,
(result) => {
@ -191,13 +192,14 @@
if (result === '') {
displayItems = dropItem(n)
} else {
displayItems[n].value = result
if (result !== 'open') displayItems[n].value = result
}
saveItems()
focusManager?.setFocusPos(focusIndex + 1 + n)
}
if (result === undefined && item.value === '') displayItems = dropItem(n)
opened = undefined
if (result === 'open') dispatch('open', item)
},
(result) => {
if (result != null) {

View File

@ -16,7 +16,7 @@
<script lang="ts">
import { Doc, DocumentQuery } from '@anticrm/core'
import { createQuery, getClient } from '@anticrm/presentation'
import { ActionIcon, Button, Icon, IconAdd, Label, Loading, SearchEdit, showPopup } from '@anticrm/ui'
import { Tooltip, Button, Icon, IconAdd, Label, Loading, SearchEdit, showPopup } from '@anticrm/ui'
import view, { Viewlet, ViewletPreference } from '@anticrm/view'
import type { Filter } from '@anticrm/view'
import { ActionContext, TableBrowser, ViewletSetting, FilterButton } from '@anticrm/view-resources'
@ -71,7 +71,7 @@
}}
/>
<div class="antiPanel-component">
<div class="ac-header full">
<div class="ac-header full withSettings">
<div class="ac-header__wrap-title">
<div class="ac-header__icon"><Icon icon={contact.icon.Person} size={'small'} /></div>
<span class="ac-header__title"><Label label={contact.string.Contacts} /></span>
@ -91,14 +91,15 @@
on:click={(ev) => showCreateDialog(ev)}
/>
{#if viewlet}
<ActionIcon
icon={view.icon.Setting}
size={'small'}
label={view.string.CustomizeView}
action={() => {
showPopup(ViewletSetting, { viewlet })
}}
/>
<Tooltip label={view.string.CustomizeView}>
<Button
icon={view.icon.Setting}
kind={'transparent'}
on:click={() => {
showPopup(ViewletSetting, { viewlet })
}}
/>
</Tooltip>
{/if}
</div>

View File

@ -24,7 +24,7 @@
IconAdd,
eventToHTMLElement,
Loading,
ActionIcon
Tooltip
} from '@anticrm/ui'
import CreateProduct from './CreateProduct.svelte'
import inventory from '../plugin'
@ -69,7 +69,7 @@
}
</script>
<div class="ac-header full">
<div class="ac-header full withSettings">
<div class="ac-header__wrap-title">
<span class="ac-header__icon"><Icon icon={inventory.icon.Products} size={'small'} /></span>
<span class="ac-header__title"><Label label={inventory.string.Products} /></span>
@ -90,14 +90,15 @@
on:click={(ev) => showCreateDialog(ev)}
/>
{#if descr}
<ActionIcon
icon={view.icon.Setting}
size={'small'}
label={view.string.CustomizeView}
action={() => {
showPopup(ViewletSetting, { viewlet: descr })
}}
/>
<Tooltip label={view.string.CustomizeView}>
<Button
icon={view.icon.Setting}
kind={'transparent'}
on:click={() => {
showPopup(ViewletSetting, { viewlet: descr })
}}
/>
</Tooltip>
{/if}
</div>

View File

@ -16,7 +16,7 @@
<script lang="ts">
import { Doc, DocumentQuery } from '@anticrm/core'
import { createQuery, getClient } from '@anticrm/presentation'
import { ActionIcon, Icon, Label, Loading, showPopup, SearchEdit } from '@anticrm/ui'
import { Tooltip, Button, Icon, Label, Loading, showPopup, SearchEdit } from '@anticrm/ui'
import view, { Viewlet, ViewletPreference } from '@anticrm/view'
import { ViewletSetting, TableBrowser } from '@anticrm/view-resources'
import lead from '../plugin'
@ -58,7 +58,7 @@
}
</script>
<div class="ac-header full">
<div class="ac-header full withSettings">
<div class="ac-header__wrap-title">
<div class="ac-header__icon"><Icon icon={lead.icon.Lead} size={'small'} /></div>
<span class="ac-header__title"><Label label={lead.string.Customers} /></span>
@ -71,14 +71,15 @@
}}
/>
{#if descr}
<ActionIcon
icon={view.icon.Setting}
size={'small'}
label={view.string.CustomizeView}
action={() => {
showPopup(ViewletSetting, { viewlet: descr })
}}
/>
<Tooltip label={view.string.CustomizeView}>
<Button
icon={view.icon.Setting}
kind={'transparent'}
on:click={() => {
showPopup(ViewletSetting, { viewlet: descr })
}}
/>
</Tooltip>
{/if}
</div>

View File

@ -17,7 +17,7 @@
import { createQuery, getClient } from '@anticrm/presentation'
import { Applicant } from '@anticrm/recruit'
import task from '@anticrm/task'
import { ActionIcon, Button, Icon, IconAdd, Label, Loading, SearchEdit, showPopup } from '@anticrm/ui'
import { Tooltip, Button, Icon, IconAdd, Label, Loading, SearchEdit, showPopup } from '@anticrm/ui'
import view, { Viewlet, ViewletPreference } from '@anticrm/view'
import type { Filter } from '@anticrm/view'
import { TableBrowser, ViewletSetting, FilterButton } from '@anticrm/view-resources'
@ -69,7 +69,7 @@
}
</script>
<div class="ac-header full">
<div class="ac-header full withSettings">
<div class="ac-header__wrap-title">
<div class="ac-header__icon"><Icon icon={recruit.icon.Application} size={'small'} /></div>
<span class="ac-header__title"><Label label={recruit.string.Applications} /></span>
@ -84,14 +84,15 @@
/>
<Button icon={IconAdd} label={recruit.string.ApplicationCreateLabel} kind={'primary'} on:click={showCreateDialog} />
{#if descr}
<ActionIcon
icon={view.icon.Setting}
size={'small'}
label={view.string.CustomizeView}
action={() => {
showPopup(ViewletSetting, { viewlet: descr })
}}
/>
<Tooltip label={view.string.CustomizeView}>
<Button
icon={view.icon.Setting}
kind={'transparent'}
on:click={() => {
showPopup(ViewletSetting, { viewlet: descr })
}}
/>
</Tooltip>
{/if}
</div>

View File

@ -17,7 +17,7 @@
import contact from '@anticrm/contact'
import { Doc, DocumentQuery } from '@anticrm/core'
import { createQuery, getClient } from '@anticrm/presentation'
import { ActionIcon, showPopup, Icon, Label, Loading, SearchEdit, Button, IconAdd } from '@anticrm/ui'
import { Tooltip, showPopup, Icon, Label, Loading, SearchEdit, Button, IconAdd } from '@anticrm/ui'
import view, { Viewlet, ViewletPreference } from '@anticrm/view'
import type { Filter } from '@anticrm/view'
import { ActionContext, TableBrowser, ViewletSetting, FilterButton } from '@anticrm/view-resources'
@ -69,7 +69,7 @@
}
</script>
<div class="ac-header full">
<div class="ac-header full withSettings">
<div class="ac-header__wrap-title">
<div class="ac-header__icon"><Icon icon={contact.icon.Person} size={'small'} /></div>
<span class="ac-header__title"><Label label={recruit.string.Candidates} /></span>
@ -84,14 +84,15 @@
/>
<Button icon={IconAdd} label={recruit.string.CandidateCreateLabel} kind={'primary'} on:click={showCreateDialog} />
{#if descr}
<ActionIcon
icon={view.icon.Setting}
size={'small'}
label={view.string.CustomizeView}
action={() => {
showPopup(ViewletSetting, { viewlet: descr })
}}
/>
<Tooltip label={view.string.CustomizeView}>
<Button
icon={view.icon.Setting}
kind={'transparent'}
on:click={() => {
showPopup(ViewletSetting, { viewlet: descr })
}}
/>
</Tooltip>
{/if}
</div>

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 8.0 KiB

After

Width:  |  Height:  |  Size: 13 KiB

View File

@ -17,17 +17,7 @@
import core, { WithLookup } from '@anticrm/core'
import { IntlString } from '@anticrm/platform'
import presentation, { createQuery, getClient } from '@anticrm/presentation'
import {
ActionIcon,
AnyComponent,
showPanel,
Button,
Icon,
SearchEdit,
showPopup,
Tooltip,
IconAdd
} from '@anticrm/ui'
import { AnyComponent, showPanel, Button, Icon, SearchEdit, showPopup, Tooltip, IconAdd } from '@anticrm/ui'
import view, { Viewlet } from '@anticrm/view'
import { ViewletSetting } from '@anticrm/view-resources'
import { createEventDispatcher } from 'svelte'
@ -87,7 +77,7 @@
}
</script>
<div class="ac-header full">
<div class="ac-header full withSettings">
{#if space}
<Header
icon={classIcon(client, space._class)}
@ -126,14 +116,15 @@
<Button icon={IconAdd} label={createItemLabel} kind={'primary'} on:click={(ev) => showCreateDialog(ev)} />
{/if}
{#if viewlet}
<ActionIcon
icon={view.icon.Setting}
size={'small'}
label={view.string.CustomizeView}
action={() => {
showPopup(ViewletSetting, { viewlet })
}}
/>
<Tooltip label={view.string.CustomizeView}>
<Button
icon={view.icon.Setting}
kind={'transparent'}
on:click={() => {
showPopup(ViewletSetting, { viewlet })
}}
/>
</Tooltip>
{/if}
{/if}
</div>