mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-07-23 15:19:38 +02:00
Fix tooltip trend color
This commit is contained in:
parent
6105f822b7
commit
743e291d56
1 changed files with 8 additions and 2 deletions
|
@ -399,8 +399,14 @@ export default class extends Controller {
|
||||||
|
|
||||||
_tooltipTrendColor(datum) {
|
_tooltipTrendColor(datum) {
|
||||||
return {
|
return {
|
||||||
up: tailwindColors.success,
|
up:
|
||||||
down: tailwindColors.error,
|
datum.trend.favorable_direction === "up"
|
||||||
|
? tailwindColors.success
|
||||||
|
: tailwindColors.error,
|
||||||
|
down:
|
||||||
|
datum.trend.favorable_direction === "down"
|
||||||
|
? tailwindColors.success
|
||||||
|
: tailwindColors.error,
|
||||||
flat: tailwindColors.gray[500],
|
flat: tailwindColors.gray[500],
|
||||||
}[datum.trend.direction];
|
}[datum.trend.direction];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue