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

feat: Add Animation for Column, Pie and Scatter charts #940

Merged
merged 34 commits into from
May 15, 2023
Merged
Changes from 1 commit
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
6f713fc
refactor: Time slider -> Animation
bprusinowski Jan 19, 2023
18e7343
feat: Add Animation icon
bprusinowski Jan 19, 2023
cc40a66
feat: Use Animation icon for time slider
bprusinowski Jan 19, 2023
0f2b62b
refactor: Make label optional
bprusinowski Jan 20, 2023
9b5562d
feat: Add animation field to types and migrations
bprusinowski Jan 20, 2023
e7eb303
feat: Handle animation field changes
bprusinowski Jan 20, 2023
c63e799
chore: Remove TimeSlider UI elements
bprusinowski Jan 20, 2023
e6786ec
feat: Hide animation field behind a flag
bprusinowski Jan 20, 2023
4d2d62f
feat: Add label
bprusinowski Jan 20, 2023
2fb1ddb
feat: Consider animation time range filter
bprusinowski Jan 20, 2023
e90d7f3
refactor: Remove interactiveFiltersConfig.timeSlider in favor of Anim…
bprusinowski Jan 20, 2023
a4e56e3
chore: Merge main
bprusinowski Jan 20, 2023
02c7c6b
fix: Lint
bprusinowski Jan 20, 2023
55eee5c
fix: Only migrate timeSlider to charts that support it
bprusinowski Jan 20, 2023
1400d72
feat: Enable Animation field for Pie and Scatterplot
bprusinowski Jan 23, 2023
0b24e50
Merge branch 'main' of github.com:visualize-admin/visualization-tool …
bprusinowski May 8, 2023
76e54d5
fix: Imports
bprusinowski May 8, 2023
c04ceb6
fix: Align optional label with label (field)
bprusinowski May 8, 2023
9121a38
feat: Remove flag from Animation field
bprusinowski May 8, 2023
a753244
feat: Consolidate Add… translations
bprusinowski May 8, 2023
526120e
refactor: Move icons closer to the component that needs them
bprusinowski May 9, 2023
2910e83
refactor: Improve types
bprusinowski May 9, 2023
1f8d086
feat: Add an option to show / hide play button
bprusinowski May 9, 2023
774114b
chore: Remove unused translations
bprusinowski May 9, 2023
68fe8d9
feat: Add an option to control animation duration
bprusinowski May 9, 2023
beb6139
feat: Only show animation duration options when play button is shown
bprusinowski May 9, 2023
48cec8a
feat: Add animation types
bprusinowski May 9, 2023
73ae545
feat: Add animation to ChartConfigAdjusters
bprusinowski May 9, 2023
d0673ea
fix: Type
bprusinowski May 9, 2023
767bf9a
feat: Animate columns in column chart
bprusinowski May 9, 2023
f236df3
docs: Update CHANGELOG
bprusinowski May 9, 2023
6aac288
feat: Add a 10s option to Animation
bprusinowski May 15, 2023
8eb8833
Merge branch 'main' of github.com:visualize-admin/visualization-tool …
bprusinowski May 15, 2023
14df0b1
fix: Lint
bprusinowski May 15, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions app/charts/shared/chart-helpers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,17 +37,13 @@ export const prepareQueryFilters = (
dataFilters: InteractiveFiltersState["dataFilters"]
): Filters => {
let queryFilters = filters;
const { timeSlider } = interactiveFiltersConfig || {};

if (chartType !== "table" && interactiveFiltersConfig?.dataFilters.active) {
queryFilters = { ...queryFilters, ...dataFilters };
}

queryFilters = omitBy(queryFilters, (v, k) => {
return (
(v.type === "single" && v.value === FIELD_VALUE_NONE) ||
k === timeSlider?.componentIri
);
queryFilters = omitBy(queryFilters, (v) => {
return v.type === "single" && v.value === FIELD_VALUE_NONE;
bprusinowski marked this conversation as resolved.
Show resolved Hide resolved
});

return queryFilters;
Expand Down