fix empty segment case

This commit is contained in:
Simon Christ 2022-04-08 15:05:07 +02:00
parent 4b73b8b5d5
commit 2c2bf5a396

View File

@ -753,13 +753,12 @@ function plotly_series(plt::Plot, series::Series)
plotly_polar!(plotattributes_out, series) plotly_polar!(plotattributes_out, series)
plotly_adjust_hover_label!(plotattributes_out, series[:hover]) plotly_adjust_hover_label!(plotattributes_out, series[:hover])
return [plotattributes_out] return [plotattributes_out]
end end
function plotly_series_shapes(plt::Plot, series::Series, clims) function plotly_series_shapes(plt::Plot, series::Series, clims)
segments = series_segments(series; check = true) segments = series_segments(series; check = true)
plotattributes_outs = Vector{KW}(undef, length(segments)) plotattributes_outs = [KW() for _ in eachindex(segments)]
# TODO: create a plotattributes_out for each polygon # TODO: create a plotattributes_out for each polygon
# x, y = series[:x], series[:y] # x, y = series[:x], series[:y]