Skip to content

Conversation

@martgnz
Copy link
Contributor

@martgnz martgnz commented May 28, 2021

This PR adds the shape-rendering attribute to the list of mark styles.

@Fil Fil self-requested a review May 28, 2021 16:15
@Fil
Copy link
Contributor

Fil commented May 28, 2021

Thanks! Have you by any chance looked at the examples in the test/plots/ directory and seen a plot that would benefit from using the option?

@Fil Fil self-assigned this May 28, 2021
@martgnz
Copy link
Contributor Author

martgnz commented May 30, 2021

I didn't see any test plot that could benefit so I added a new snapshot test (which could be a useful example when #415 lands too).

There's also two new small unit tests.

Copy link
Contributor

@Fil Fil left a comment

Choose a reason for hiding this comment

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

great example, thanks!

Copy link
Contributor

@Fil Fil left a comment

Choose a reason for hiding this comment

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

we'll be waiting on #415 then

@Fil Fil mentioned this pull request Jun 18, 2021
1 task
@Fil
Copy link
Contributor

Fil commented Jul 20, 2021

src/style.js Outdated
mark.strokeMiterlimit = impliedNumber(strokeMiterlimit, 4);
mark.strokeDasharray = string(strokeDasharray);
mark.mixBlendMode = impliedString(mixBlendMode, "normal");
mark.shapeRendering = string(shapeRendering);
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
mark.shapeRendering = string(shapeRendering);
mark.shapeRendering = impliedString(shapeRendering, "auto");

@mbostock mbostock merged commit 7e45462 into observablehq:main Aug 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants