Skip to content

fix facet channel sort with transform #1316

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

Merged
merged 3 commits into from
Mar 7, 2023

Conversation

mbostock
Copy link
Member

@mbostock mbostock commented Mar 4, 2023

Fixes #840.

@mbostock mbostock requested a review from Fil March 4, 2023 06:53
@mbostock mbostock force-pushed the mbostock/fix-transform-facet-channel-domain branch from 4ef3f7c to 92fee30 Compare March 4, 2023 06:54
Fil added a commit that referenced this pull request Mar 6, 2023
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.

I've checked that it works well in conjunction with #1315.
Build: https://observablehq.com/@observablehq/plot-sort-1315-1316

@mbostock mbostock force-pushed the mbostock/fix-transform-facet-channel-domain branch from 43aaeb0 to 35922e6 Compare March 7, 2023 16:50
@mbostock mbostock merged commit e52a782 into main Mar 7, 2023
@mbostock mbostock deleted the mbostock/fix-transform-facet-channel-domain branch March 7, 2023 16:50
if (this.transform != null) ({facets, data} = this.transform(data, facets)), (data = arrayify(data));
if (facets !== undefined) facets.original = originalFacets; // needed up read facetChannels
Copy link
Member Author

Choose a reason for hiding this comment

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

“needed up read facetChannels” 🤔

Copy link
Contributor

Choose a reason for hiding this comment

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

"needed to reindex the facet channel" (?)
or remove

Copy link
Member Author

Choose a reason for hiding this comment

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

Ah ha. I think I meant “needed to read facetChannels”.

chaichontat pushed a commit to chaichontat/plot that referenced this pull request Jan 14, 2024
* fix facet channel sort with transform

* marginLeft—less minimalist, but more readable

* rule y = 0

---------

Co-authored-by: Philippe Rivière <fil@rezo.net>
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.

2 participants