First of all: Thanks for the awesome looking library! I recently wanted to do some charts for a private project but ended up not being sure what to use in Elm for that. Because it wasn’t that important i just went with some table display instead. Seeing this announcement made me go back and try it with some fancy charts!
My problem: I might be missing something real obvious, but i can’t seem to get the charts to respect the given amount of space? I have the elm app embeded:
<div id="elm-history-graph"></div>
and
main : Program String Model Msg
main =
Browser.element
and stuff and i am just trying for starters to render it inside:
view _ =
let
data =
[ ...
]
content =
C.chart
[ CA.width 300
]
[ C.xLabels []
, C.yLabels [ CA.withGrid ]
, C.series .x
[ C.interpolated .y [ CA.monotone ] []
, C.interpolated .z [ CA.monotone ] []
]
data
]
in
Html.div
[ Html.Attributes.style "width" "300px" ]
[ content ]
With most of the the charts stuff taking from a github example. But the chart’s labels are rendering outside of their container. Is that normal?