Merge pull request #3113 from daschw/plotly-legend
Switch to plotly-latest
This commit is contained in:
commit
e5d9b8ba48
@ -339,7 +339,11 @@ function plotly_add_legend!(plotattributes_out::KW, sp::Subplot)
|
|||||||
:font => plotly_font(legendfont(sp)),
|
:font => plotly_font(legendfont(sp)),
|
||||||
:tracegroupgap => 0,
|
:tracegroupgap => 0,
|
||||||
:x => legend_position.coords[1],
|
:x => legend_position.coords[1],
|
||||||
:y => legend_position.coords[2]
|
:y => legend_position.coords[2],
|
||||||
|
:title => KW(
|
||||||
|
:text => sp[:legendtitle] === nothing ? "" : string(sp[:legendtitle]),
|
||||||
|
:font => plotly_font(legendtitlefont(sp)),
|
||||||
|
),
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -883,7 +887,7 @@ const ijulia_initialized = Ref(false)
|
|||||||
|
|
||||||
function plotly_html_head(plt::Plot)
|
function plotly_html_head(plt::Plot)
|
||||||
plotly =
|
plotly =
|
||||||
use_local_dependencies[] ? ("file:///" * plotly_local_file_path[]) : "https://cdn.plot.ly/plotly-1.54.2.min.js"
|
use_local_dependencies[] ? ("file:///" * plotly_local_file_path[]) : "https://cdn.plot.ly/plotly-1.57.1.min.js"
|
||||||
|
|
||||||
include_mathjax = get(plt[:extra_plot_kwargs], :include_mathjax, "")
|
include_mathjax = get(plt[:extra_plot_kwargs], :include_mathjax, "")
|
||||||
mathjax_file = include_mathjax != "cdn" ? ("file://" * include_mathjax) : "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.7/MathJax.js?config=TeX-MML-AM_CHTML"
|
mathjax_file = include_mathjax != "cdn" ? ("file://" * include_mathjax) : "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.7/MathJax.js?config=TeX-MML-AM_CHTML"
|
||||||
|
|||||||
@ -81,7 +81,7 @@ function __init__()
|
|||||||
if get(ENV, "PLOTS_HOST_DEPENDENCY_LOCAL", "false") == "true"
|
if get(ENV, "PLOTS_HOST_DEPENDENCY_LOCAL", "false") == "true"
|
||||||
global plotly_local_file_path[] = joinpath(@get_scratch!("plotly"), "plotly-1.54.2.min.js")
|
global plotly_local_file_path[] = joinpath(@get_scratch!("plotly"), "plotly-1.54.2.min.js")
|
||||||
if !isfile(plotly_local_file_path[])
|
if !isfile(plotly_local_file_path[])
|
||||||
download("https://cdn.plot.ly/plotly-1.54.2.min.js", plotly_local_file_path[])
|
download("https://cdn.plot.ly/plotly-1.57.1.min.js", plotly_local_file_path[])
|
||||||
end
|
end
|
||||||
|
|
||||||
use_local_plotlyjs[] = true
|
use_local_plotlyjs[] = true
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user