Skip to content
Snippets Groups Projects
Commit b0080073 authored by Florian Raab's avatar Florian Raab
Browse files

LinePlot: add ratio of applied and issued to tooltip

parent 1b52e59a
No related branches found
No related tags found
No related merge requests found
Pipeline #24419 passed
......@@ -276,6 +276,21 @@ view global model =
)
]
)
rate = annotation
|> Maybe.map
(Tuple.first
>> .selection
>> .y
)
|> Maybe.withDefault []
|> List.map
(\{ groupLabel, value } ->
value
)
|> List.foldl (\x y -> x / y) 1.0
|> String.fromFloat
|> String.left 5
in
Html.div
[ Html.Attributes.style "margin" "0"
......@@ -293,6 +308,8 @@ view global model =
[ Html.text year
, Html.br [] []
, Html.div [] values
, Html.br [] []
, Html.text ("ratio: " ++ rate)
]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment