-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Property zerolinelayer
for cartesian axes
#7269
base: master
Are you sure you want to change the base?
Conversation
zerolinelayer
with values "below traces" (default) and "above traces"zerolinelayer
for cartesian axes
@gvwilson Do you have a means to trigger the CI again? It seems that this run had a connection error on launch. |
@my-tien I just re-ran CI - hope that helps. |
Hi @gvwilson - Could this PR be reviewed and possibly merged soon? It seems like a reasonably sized change, that should be easy to integrate? Thank you for considering! |
var zeroLineColor = coerce2('zerolinecolor', dfltColor); | ||
var zeroLineWidth = coerce2('zerolinewidth'); | ||
var showZeroLine = coerce('zeroline', opts.showGrid || !!zeroLineColor || !!zeroLineWidth); | ||
|
||
if(!showZeroLine) { | ||
delete containerOut.zerolineLayer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
delete containerOut.zerolineLayer; | |
delete containerOut.zerolinelayer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thx for spotting! Fixed. Btw. did you just see this or is there another trick to catch this mistake?
@my-tien Thank you for the contribution! This is looking good to me -- however I've noticed that How big of a problem is that on your side? We are open to simply documenting the limitation but want to verify whether it will cause issues for you. Mock:
Image: |
Hi Emily, thanks for the heads up. I didn't dig into the zorder logic much, but I assume to make it work with it, the zeroline drawing would have to be moved to another location? So it sounds like it could become a major change (correct me if I'm wrong). In any case, from our side it's okay to document the limitation. – I've added a note to the description of the property. |
Adds a new property
zerolinelayer
to cartesian axes to allow drawing the zeroline above traces.This addresses the issue that sometimes the zeroline can be barely visible:

When setting the new property

yaxis.zerolinelayer = "above traces"
:Disclaimer
I am required to add that…the software is provided "as is", without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose and noninfringement. in no event shall the authors or copyright holders be liable for any claim, damages or other liability, whether in an action of contract, tort or otherwise, arising from, out of or in connection with the software or the use or other dealings in the software.