Time tooltip

Signed-off-by: Denis Bykhov <80476319+BykhovDenis@users.noreply.github.com>
This commit is contained in:
Denis Bykhov 2022-02-14 11:00:50 +06:00
parent d13f4690b6
commit 4ed5101c15

View File

@ -19,6 +19,7 @@
import { translate } from '@anticrm/platform' import { translate } from '@anticrm/platform'
import { ticker } from '..' import { ticker } from '..'
import ui from '../plugin' import ui from '../plugin'
import Tooltip from './Tooltip.svelte'
export let value: number export let value: number
@ -43,6 +44,10 @@
$: formatTime($ticker) $: formatTime($ticker)
$: tooltip = new Date(value).toLocaleString('default', { minute:'2-digit', hour:'numeric', day:'2-digit', month: 'short', year: 'numeric'})
</script> </script>
<Tooltip label={tooltip}>
<span style="white-space: nowrap;" >{time}</span> <span style="white-space: nowrap;" >{time}</span>
</Tooltip>