You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// - if below/above plot area, give it the maximum potential margin-push value// - otherwise, extend the height of the plot arealegendObj._maxHeight=Math.max((isBelowPlotArea||isAbovePlotArea) ? fullLayout.height/2 : gs.h,30);// _maxHeight is also limited by the container if it is anchored to itif(legendObj.yref==='container'&&legendObj._maxHeight>30){varyanchor=getYanchor(legendObj);varcontainerAllowedHeight;if(yanchor==='top')containerAllowedHeight=legendObj.y*fullLayout.height;elseif(yanchor==='bottom')containerAllowedHeight=(1-legendObj.y)*fullLayout.height;else// if (yanchor === 'middle')containerAllowedHeight=2*Math.min(1-legendObj.y,legendObj.y)*fullLayout.height;legendObj._maxHeight=Math.min(containerAllowedHeight,legendObj._maxHeight);}
If a legend is anchored to the container, the container sizes aren't taken into account when the legend sizes are computed.
In the example codepen legends aren't visible fully and it is not possible to scroll then to the end.
function computeLegendDimensions should take into account the container sizes for calculation of
_maxHeight
and_maxWidth
The text was updated successfully, but these errors were encountered: