Skip to content

SVG and PNG Downloads for Heatmap#255

Merged
bencap merged 9 commits intorelease-2024.3.0from
feature/bencap/216/png-for-heatmap
Aug 27, 2024
Merged

SVG and PNG Downloads for Heatmap#255
bencap merged 9 commits intorelease-2024.3.0from
feature/bencap/216/png-for-heatmap

Conversation

@bencap
Copy link
Copy Markdown
Collaborator

@bencap bencap commented Aug 26, 2024

#216, plus rolls in changes from #251

@bencap bencap added type: bug Something isn't working type: enhancement Enhancement to an existing feature labels Aug 26, 2024
@bencap bencap requested a review from jstone-dev August 26, 2024 20:43
@bencap bencap changed the base branch from main to release-2024.3.0 August 26, 2024 20:54
bencap added 4 commits August 26, 2024 14:45
Hides Selection Tooltip When No Bin is Selected:

The previous version threw errors when selecting a heatmap square with no score, since this
variant was not present in the histogram.

Treat NaN Scores as Null:

The previous version sent all such score averages to NaN. See #256
for further information.
@bencap bencap force-pushed the feature/bencap/216/png-for-heatmap branch from 7d0d2f8 to ed68fed Compare August 26, 2024 21:53
Adds a chart export lib module in support of this task. SVGs are handled with custom logic
to allow for grouped export (in the heatmap, the chart is composed of two SVGs grouped within
a scroll div). For PNGs, we use an external module as this conversion of composed SVGs was
giving us trouble during PNG Rasterization.
@bencap bencap force-pushed the feature/bencap/216/png-for-heatmap branch from ed68fed to 3fe1683 Compare August 26, 2024 21:57
Comment thread src/components/ScoreSetHeatmap.vue Outdated
Comment thread src/components/ScoreSetHistogram.vue Outdated
@jstone-dev
Copy link
Copy Markdown
Collaborator

The limitation of the export feature from the gastruloid site carries over here: In some browsers, clicking one of the download buttons just saves an SVG file instead of prompting the user for a location and image format (SVG or PNG). I think this is fine, though at some point we might want to look into it. It may be an effect of browser settings that we can't work around.

bencap and others added 4 commits August 27, 2024 14:16
Adds a new `exportChart` emits property to our chart components
that emits the `exportChart` function handler once the component is mounted. The parent
component grab this method object via the `@handler` hook on the child component and use the method without relying on manipulating child refs.
@bencap bencap merged commit a7270e4 into release-2024.3.0 Aug 27, 2024
@bencap bencap deleted the feature/bencap/216/png-for-heatmap branch August 27, 2024 21:46
@bencap bencap mentioned this pull request Aug 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: bug Something isn't working type: enhancement Enhancement to an existing feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Assigning to Variant Heatmap Const SVG/PNG download button for heatmap & score distribution

2 participants