TSK-1452: Revert sprint statistics display (#3142)

Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
Andrey Sobolev
2023-05-11 00:16:26 +07:00
committed by GitHub
parent 84b7df4923
commit 739fca0132
5 changed files with 51 additions and 25 deletions
@@ -18,7 +18,7 @@
import { getClient } from '@hcengineering/presentation'
import { Issue, IssueDraft } from '@hcengineering/tracker'
import { Button, ButtonKind, ButtonSize, eventToHTMLElement, showPopup } from '@hcengineering/ui'
import { EditBoxPopup } from '@hcengineering/view-resources'
import { EditBoxPopup, FixedColumn } from '@hcengineering/view-resources'
import { createEventDispatcher } from 'svelte'
import tracker from '../../../plugin'
import EstimationPopup from './EstimationPopup.svelte'
@@ -74,7 +74,9 @@
{#if value}
{#if kind === 'list' && '_class' in value}
<EstimationStatsPresenter {value} {kind} on:click={handleestimationEditorOpened} />
<FixedColumn key="estimation-editor-total">
<EstimationStatsPresenter {value} {kind} on:click={handleestimationEditorOpened} />
</FixedColumn>
{:else}
<Button
{focusIndex}
@@ -29,13 +29,15 @@
on:click
use:tooltip={{
component: Label,
props: { label: tracker.string.TimeSpendHours, params: { value: floorFractionDigits(value * 8, 2) } }
props: { label: tracker.string.TimeSpendHours, params: { value: floorFractionDigits(value * 8, 3) } }
}}
>
{#if noSymbol}
{floorFractionDigits(value, 3)}
{floorFractionDigits(value, 1)}
{:else if value > 0 && value < 1}
<Label label={tracker.string.TimeSpendHours} params={{ value: floorFractionDigits(value * 8, 1) }} />
{:else}
<Label label={tracker.string.TimeSpendValue} params={{ value: floorFractionDigits(value, 3) }} />
<Label label={tracker.string.TimeSpendValue} params={{ value: floorFractionDigits(value, 1) }} />
{/if}
</span>