Skip to content
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

Drop support for deprecated error bar opacity attribute (use alpha channel of error bar color attribute instead) #7216

Merged
merged 8 commits into from
Oct 8, 2024

Conversation

emilykl
Copy link
Contributor

@emilykl emilykl commented Oct 7, 2024

Closes #7197

  • Drop support for deprecated error bar opacity attribute (use alpha channel of error bar color attribute instead)

@@ -72,16 +72,14 @@
"value": 0.1,
"color": "#85144B",
"thickness": 1.5,
"width": 3,
"opacity": 1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just for my own learning, what happened to "opacity"?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

opacity can also be specified by using the alpha channel of the color attribute, which defaults to full-opacity, so the same image result can be achieved without explicitly setting the opacity.

I guess for the purposes of this test it might make sense to include it explicitly though.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

very happy to use color instead (fewer parameters is better) - was just wondering how we were now handling it - thanks

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know why we chose to deprecate opacity here though and not elsewhere, maybe @archmoj has an idea

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In some places - particularly where multiple colors or multiple objects are involved - there are many different effects you can achieve depending on exactly where you set the opacity

Screenshot 2024-10-08 at 10 15 34

Here though I guess there's nothing you can't achieve just with the opacity of the color.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That makes perfect sense -- thanks @alexcjohnson .

@@ -17391,7 +17384,7 @@
"valType": "string"
},
"color": {
"description": "Sets the stoke color of the error bars.",
"description": "Sets the stroke color of the error bars.",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good catch

@gvwilson gvwilson added feature something new P1 needed for current cycle labels Oct 8, 2024
Copy link
Contributor

@archmoj archmoj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💃

@emilykl
Copy link
Contributor Author

emilykl commented Oct 8, 2024

FYI @archmoj I updated the error_bar_style mock and baseline to make use of opacity in the color attribute.

@emilykl emilykl merged commit 2f19d0f into master Oct 8, 2024
1 check passed
@emilykl emilykl deleted the drop-errorbar-opacity branch October 8, 2024 18:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature something new P1 needed for current cycle
Projects
None yet
Development

Successfully merging this pull request may close these issues.

drop deprecated opacity attribute of errorbars in v3
4 participants