mirror of
https://github.com/hcengineering/platform.git
synced 2025-01-03 08:57:14 +03:00
UBER-340,-341,-346, TSK-1545: ui fixes (#3328)
Signed-off-by: Alexander Platov <sas_lord@mail.ru>
This commit is contained in:
parent
da2f5f3ee4
commit
876d52c08d
@ -680,7 +680,7 @@ export function createModel (builder: Builder): void {
|
|||||||
key: '',
|
key: '',
|
||||||
label: tracker.string.DueDate,
|
label: tracker.string.DueDate,
|
||||||
presenter: tracker.component.DueDatePresenter,
|
presenter: tracker.component.DueDatePresenter,
|
||||||
props: { kind: 'list' }
|
props: { kind: 'list', size: 'small' }
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: '',
|
key: '',
|
||||||
|
@ -60,6 +60,7 @@
|
|||||||
--primary-button-pressed: #284B86;
|
--primary-button-pressed: #284B86;
|
||||||
--primary-button-focused: #144CA8;
|
--primary-button-focused: #144CA8;
|
||||||
--primary-button-disabled: #484662;
|
--primary-button-disabled: #484662;
|
||||||
|
--primary-button-disabled-color: rgba(255, 255, 255, .5);
|
||||||
--primary-button-focused-border: #6E9FED;
|
--primary-button-focused-border: #6E9FED;
|
||||||
--primary-button-border: rgba(255, 255, 255, .09);
|
--primary-button-border: rgba(255, 255, 255, .09);
|
||||||
--primary-button-outline: rgba(87, 132, 255, .3); // OLD
|
--primary-button-outline: rgba(87, 132, 255, .3); // OLD
|
||||||
@ -69,6 +70,7 @@
|
|||||||
--theme-button-pressed: rgba(255, 255, 255, .08);
|
--theme-button-pressed: rgba(255, 255, 255, .08);
|
||||||
--theme-button-focused: rgba(255, 255, 255, .04);
|
--theme-button-focused: rgba(255, 255, 255, .04);
|
||||||
--theme-button-disabled: rgba(255, 255, 255, .02);
|
--theme-button-disabled: rgba(255, 255, 255, .02);
|
||||||
|
--theme-button-disabled-color: rgba(255, 255, 255, .5);
|
||||||
--theme-button-border: rgba(255, 255, 255, .09);
|
--theme-button-border: rgba(255, 255, 255, .09);
|
||||||
|
|
||||||
--theme-refinput-color: rgba(255, 255, 255, .03);
|
--theme-refinput-color: rgba(255, 255, 255, .03);
|
||||||
@ -241,6 +243,7 @@
|
|||||||
--primary-button-pressed: #284B86;
|
--primary-button-pressed: #284B86;
|
||||||
--primary-button-focused: #144CA8;
|
--primary-button-focused: #144CA8;
|
||||||
--primary-button-disabled: #EBEBEB;
|
--primary-button-disabled: #EBEBEB;
|
||||||
|
--primary-button-disabled-color: rgba(0, 0, 0, .5);
|
||||||
--primary-button-focused-border: #6E9FED; // DARK
|
--primary-button-focused-border: #6E9FED; // DARK
|
||||||
--primary-button-border: rgba(255, 255, 255, .09);
|
--primary-button-border: rgba(255, 255, 255, .09);
|
||||||
--primary-button-outline: rgba(87, 132, 255, .3); // OLD
|
--primary-button-outline: rgba(87, 132, 255, .3); // OLD
|
||||||
@ -250,6 +253,7 @@
|
|||||||
--theme-button-pressed: rgba(0, 0, 0, .08);
|
--theme-button-pressed: rgba(0, 0, 0, .08);
|
||||||
--theme-button-focused: rgba(0, 0, 0, .04);
|
--theme-button-focused: rgba(0, 0, 0, .04);
|
||||||
--theme-button-disabled: rgba(0, 0, 0, .02);
|
--theme-button-disabled: rgba(0, 0, 0, .02);
|
||||||
|
--theme-button-disabled-color: rgba(0, 0, 0, .5);
|
||||||
--theme-button-border: rgba(0, 0, 0, .09);
|
--theme-button-border: rgba(0, 0, 0, .09);
|
||||||
|
|
||||||
--theme-refinput-color: rgba(0, 0, 0, .03);
|
--theme-refinput-color: rgba(0, 0, 0, .03);
|
||||||
|
@ -174,6 +174,7 @@
|
|||||||
background-color: var(--theme-button-focused);
|
background-color: var(--theme-button-focused);
|
||||||
}
|
}
|
||||||
&:disabled {
|
&:disabled {
|
||||||
|
color: var(--theme-button-disabled-color);
|
||||||
background-color: var(--theme-button-disabled);
|
background-color: var(--theme-button-disabled);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -267,7 +268,6 @@
|
|||||||
}
|
}
|
||||||
&.list {
|
&.list {
|
||||||
padding: 0 0.625em;
|
padding: 0 0.625em;
|
||||||
min-height: 1.75rem;
|
|
||||||
color: var(--theme-content-color);
|
color: var(--theme-content-color);
|
||||||
background-color: var(--theme-button-enabled);
|
background-color: var(--theme-button-enabled);
|
||||||
border: 1px solid var(--theme-button-border);
|
border: 1px solid var(--theme-button-border);
|
||||||
@ -275,17 +275,14 @@
|
|||||||
// transition-property: border, color, background-color;
|
// transition-property: border, color, background-color;
|
||||||
// transition-duration: 0.15s;
|
// transition-duration: 0.15s;
|
||||||
|
|
||||||
.btn-icon {
|
&:not(.inline, .x-small) { min-height: 1.75rem; }
|
||||||
color: var(--theme-dark-color);
|
.btn-icon { color: var(--theme-dark-color); }
|
||||||
}
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: var(--theme-caption-color);
|
color: var(--theme-caption-color);
|
||||||
background-color: var(--theme-button-hovered);
|
background-color: var(--theme-button-hovered);
|
||||||
border-color: var(--theme-button-border);
|
border-color: var(--theme-button-border);
|
||||||
}
|
}
|
||||||
&:not(.no-focus):focus {
|
&:not(.no-focus):focus { box-shadow: none; }
|
||||||
box-shadow: none;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
&.primary {
|
&.primary {
|
||||||
padding: 0 0.75rem;
|
padding: 0 0.75rem;
|
||||||
@ -307,6 +304,7 @@
|
|||||||
background-color: var(--primary-button-focused);
|
background-color: var(--primary-button-focused);
|
||||||
}
|
}
|
||||||
&:disabled {
|
&:disabled {
|
||||||
|
color: var(--primary-button-disabled-color);
|
||||||
background-color: var(--primary-button-disabled);
|
background-color: var(--primary-button-disabled);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -310,12 +310,6 @@
|
|||||||
font-size: 0.6875rem;
|
font-size: 0.6875rem;
|
||||||
color: var(--theme-halfcontent-color);
|
color: var(--theme-halfcontent-color);
|
||||||
}
|
}
|
||||||
.check {
|
|
||||||
flex-shrink: 0;
|
|
||||||
margin-left: .5rem;
|
|
||||||
width: 1rem;
|
|
||||||
color: var(--theme-dark-color);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// &:hover { background-color: var(--popup-bg-hover); }
|
// &:hover { background-color: var(--popup-bg-hover); }
|
||||||
@ -340,9 +334,11 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
.ap-check {
|
.ap-check {
|
||||||
|
flex-shrink: 0;
|
||||||
margin-left: 1rem;
|
margin-left: 1rem;
|
||||||
width: 1rem;
|
width: 1rem;
|
||||||
height: 1rem;
|
height: 1rem;
|
||||||
|
color: var(--theme-dark-color);
|
||||||
}
|
}
|
||||||
.ap-menuHeader {
|
.ap-menuHeader {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
@ -244,14 +244,14 @@
|
|||||||
padding: 0 0.25rem;
|
padding: 0 0.25rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.btn-icon {
|
.btn-icon:not(.warning, .critical, .overdue) {
|
||||||
color: var(--theme-darker-color);
|
color: var(--theme-darker-color);
|
||||||
}
|
}
|
||||||
&:hover {
|
&:hover {
|
||||||
color: var(--theme-content-color);
|
color: var(--theme-content-color);
|
||||||
background-color: var(--theme-bg-color);
|
background-color: var(--theme-bg-color);
|
||||||
border-color: var(--theme-divider-color);
|
border-color: var(--theme-divider-color);
|
||||||
.btn-icon {
|
.btn-icon:not(.warning, .critical, .overdue) {
|
||||||
color: var(--theme-content-color);
|
color: var(--theme-content-color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -271,8 +271,8 @@
|
|||||||
background-color: var(--theme-list-button-hover);
|
background-color: var(--theme-list-button-hover);
|
||||||
border-color: var(--theme-divider-color);
|
border-color: var(--theme-divider-color);
|
||||||
}
|
}
|
||||||
.btn-icon,
|
.btn-icon:not(.warning, .critical, .overdue),
|
||||||
&:hover .btn-icon {
|
&:hover .btn-icon:not(.warning, .critical, .overdue) {
|
||||||
color: var(--theme-halfcontent-color) !important;
|
color: var(--theme-halfcontent-color) !important;
|
||||||
}
|
}
|
||||||
&.medium {
|
&.medium {
|
||||||
@ -289,7 +289,7 @@
|
|||||||
color: var(--theme-caption-color);
|
color: var(--theme-caption-color);
|
||||||
background-color: var(--theme-link-button-hover);
|
background-color: var(--theme-link-button-hover);
|
||||||
border-color: var(--theme-list-divider-color);
|
border-color: var(--theme-list-divider-color);
|
||||||
.btn-icon {
|
.btn-icon:not(.warning, .critical, .overdue) {
|
||||||
color: var(--theme-caption-color);
|
color: var(--theme-caption-color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -309,13 +309,13 @@
|
|||||||
&:not(.withIcon) {
|
&:not(.withIcon) {
|
||||||
padding: 0 0.75rem;
|
padding: 0 0.75rem;
|
||||||
}
|
}
|
||||||
.btn-icon {
|
.btn-icon:not(.warning, .critical, .overdue) {
|
||||||
color: var(--theme-content-color);
|
color: var(--theme-content-color);
|
||||||
}
|
}
|
||||||
&:hover {
|
&:hover {
|
||||||
background-color: var(--theme-button-hovered);
|
background-color: var(--theme-button-hovered);
|
||||||
border-color: var(--theme-divider-color);
|
border-color: var(--theme-divider-color);
|
||||||
.btn-icon {
|
.btn-icon:not(.warning, .critical, .overdue) {
|
||||||
color: var(--theme-content-color);
|
color: var(--theme-content-color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -339,10 +339,10 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&.noDate .btn-icon {
|
&.noDate .btn-icon:not(.warning, .critical, .overdue) {
|
||||||
color: var(--theme-dark-color);
|
color: var(--theme-dark-color);
|
||||||
}
|
}
|
||||||
&.noDate:hover .btn-icon {
|
&.noDate:hover .btn-icon:not(.warning, .critical, .overdue) {
|
||||||
color: var(--theme-content-color);
|
color: var(--theme-content-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -35,7 +35,7 @@
|
|||||||
export let currentProject: Project | undefined = undefined
|
export let currentProject: Project | undefined = undefined
|
||||||
|
|
||||||
export let kind: ButtonKind = 'link-bordered'
|
export let kind: ButtonKind = 'link-bordered'
|
||||||
export let size: ButtonSize = 'inline'
|
export let size: ButtonSize = 'small'
|
||||||
export let justify: 'left' | 'center' = 'left'
|
export let justify: 'left' | 'center' = 'left'
|
||||||
export let width: string | undefined = 'min-contet'
|
export let width: string | undefined = 'min-contet'
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
-->
|
-->
|
||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import login, { loginId, Workspace } from '@hcengineering/login'
|
import login, { Workspace } from '@hcengineering/login'
|
||||||
import { getResource } from '@hcengineering/platform'
|
import { getResource } from '@hcengineering/platform'
|
||||||
import {
|
import {
|
||||||
closePopup,
|
closePopup,
|
||||||
@ -30,7 +30,7 @@
|
|||||||
import { workbenchId } from '@hcengineering/workbench'
|
import { workbenchId } from '@hcengineering/workbench'
|
||||||
import { onMount } from 'svelte'
|
import { onMount } from 'svelte'
|
||||||
import { workspacesStore } from '../utils'
|
import { workspacesStore } from '../utils'
|
||||||
import Drag from './icons/Drag.svelte'
|
// import Drag from './icons/Drag.svelte'
|
||||||
|
|
||||||
onMount(() => {
|
onMount(() => {
|
||||||
getResource(login.function.GetWorkspaces).then(async (f) => {
|
getResource(login.function.GetWorkspaces).then(async (f) => {
|
||||||
@ -59,10 +59,6 @@
|
|||||||
setMetadataLocalStorage(login.metadata.LoginTokens, tokens)
|
setMetadataLocalStorage(login.metadata.LoginTokens, tokens)
|
||||||
}
|
}
|
||||||
|
|
||||||
const loginPath: Location = {
|
|
||||||
path: [loginId, 'selectWorkspace']
|
|
||||||
}
|
|
||||||
|
|
||||||
function getWorkspaceLink (ws: Workspace): string {
|
function getWorkspaceLink (ws: Workspace): string {
|
||||||
const loc: Location = {
|
const loc: Location = {
|
||||||
path: [workbenchId, ws.workspace]
|
path: [workbenchId, ws.workspace]
|
||||||
@ -113,13 +109,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function handleOther (e: MouseEvent) {
|
|
||||||
if (e.metaKey || e.ctrlKey) return
|
|
||||||
e.preventDefault()
|
|
||||||
closePopup()
|
|
||||||
navigate({ path: [loginId, 'selectWorkspace'] })
|
|
||||||
}
|
|
||||||
|
|
||||||
$: last = $workspacesStore.length
|
$: last = $workspacesStore.length
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
@ -132,19 +121,19 @@
|
|||||||
<a class="stealth" href={getWorkspaceLink(ws)} on:click={(e) => clickHandler(e, ws.workspace)}>
|
<a class="stealth" href={getWorkspaceLink(ws)} on:click={(e) => clickHandler(e, ws.workspace)}>
|
||||||
<button
|
<button
|
||||||
bind:this={btns[i]}
|
bind:this={btns[i]}
|
||||||
class="ap-menuItem flex-row-center withDrag"
|
class="ap-menuItem flex-row-center flex-grow"
|
||||||
class:hover={btns[i] === activeElement}
|
class:hover={btns[i] === activeElement}
|
||||||
on:mousemove={() => {
|
on:mousemove={() => {
|
||||||
focusTarget(btns[i])
|
focusTarget(btns[i])
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<div class="drag"><Drag size={'small'} /></div>
|
<!-- <div class="drag"><Drag size={'small'} /></div> -->
|
||||||
<!-- <div class="logo empty" /> -->
|
<!-- <div class="logo empty" /> -->
|
||||||
<!-- <div class="flex-col flex-grow"> -->
|
<!-- <div class="flex-col flex-grow"> -->
|
||||||
<span class="label overflow-label flex-grow">{ws.workspace}</span>
|
<span class="label overflow-label flex-grow">{ws.workspace}</span>
|
||||||
<!-- <span class="description overflow-label">Description</span> -->
|
<!-- <span class="description overflow-label">Description</span> -->
|
||||||
<!-- </div> -->
|
<!-- </div> -->
|
||||||
<div class="check">
|
<div class="ap-check">
|
||||||
{#if $resolvedLocationStore.path[1] === ws.workspace}
|
{#if $resolvedLocationStore.path[1] === ws.workspace}
|
||||||
<IconCheck size={'small'} />
|
<IconCheck size={'small'} />
|
||||||
{/if}
|
{/if}
|
||||||
@ -152,18 +141,6 @@
|
|||||||
</button>
|
</button>
|
||||||
</a>
|
</a>
|
||||||
{/each}
|
{/each}
|
||||||
<a class="stealth" href={locationToUrl(loginPath)} on:click={handleOther}>
|
|
||||||
<button
|
|
||||||
bind:this={btns[last]}
|
|
||||||
class="ap-menuItem flex-grow"
|
|
||||||
class:hover={btns[last] === activeElement}
|
|
||||||
on:mousemove={() => {
|
|
||||||
focusTarget(btns[last])
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
...
|
|
||||||
</button>
|
|
||||||
</a>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="ap-space x2" />
|
<div class="ap-space x2" />
|
||||||
|
Loading…
Reference in New Issue
Block a user