Merge pull request 'fix: CollapseHistory: show "—" instead of "0" profit when data unavailable (#207)' (#231) from fix/issue-207 into master

This commit is contained in:
johba 2026-02-24 21:26:18 +01:00
commit e3d45bb8ef
2 changed files with 3 additions and 3 deletions

2
package-lock.json generated
View file

@ -1,5 +1,5 @@
{
"name": "harb-worktree-209",
"name": "harb-worktree-207",
"lockfileVersion": 3,
"requires": true,
"packages": {

View file

@ -25,7 +25,7 @@
</div>
<div>
<span class="subheader2">Profit</span><span class="number-small">{{ profit }}</span
><span class="caption"> $KRK</span>
><span v-if="profit !== '—'" class="caption"> $KRK</span>
</div>
<template v-if="isSnatched">
<div v-if="payoutKrk !== null">
@ -62,7 +62,7 @@ const isSnatched = computed(() => props.position.snatched > 0);
const profit = computed(() => {
if (!props.position.totalSupplyEnd) {
return 0;
return '—';
}
return calculateClosedPositionProfit(props.position.totalSupplyInit, props.position.totalSupplyEnd, props.position.share);
});