Releases: FormidableLabs/victory
v36.4.0
What's Changed
- Added the ability to add victory charts title and desc props for better accessibility by @shankstee in #2199
- Bump axios from 0.19.2 to 0.21.2 in /docs by @dependabot in #2188
- Bump cross-fetch from 3.1.4 to 3.1.5 by @dependabot in #2206
- add style interface to SliceProps type by @heythisispaul in #2212
- Add jest and react testing library tests for victory-line and victory-area by @becca-bailey in #2196
- fix typos in scale prop documentation by @heythisispaul in #2218
- Bump cross-fetch from 3.1.4 to 3.1.5 by @dependabot in #2213
- Bump cross-fetch from 3.1.4 to 3.1.5 in /demo/rn by @dependabot in #2207
- add box plot jest/rtl tests by @heythisispaul in #2225
- jest and rtl unit tests for bar components by @heythisispaul in #2216
- Add victory-vendor package for d3 dependencies by @becca-bailey in #2204
Introducing the victory-vendor
package
In order to safely upgrade d3-packages while still allowing Node.js users to use ESM imports, we introduced a new package called victory-vendor
for babelifying our d3 packages to make them more compatible with Victory. For more info, check out the description here.
This should not make much of a difference for the end user, but there are a couple changes to be aware of. Upgrading d3-scale
introduced some minor scaling changes. If you (like us) are using Chromatic or another visual regression testing tool, it may pick up some very small differences in the placement of axes and data points. d3-scale
also introduced some changes to the scale.tickFormat
function that changes the default formatting for log scales.
Before | After |
---|---|
If you are using a log scale and don't wish to use d3's default label formatting, You can use the tickFormat
prop on a VictoryAxis
component to override this default formatting. https://formidable.com/open-source/victory/docs/victory-axis#tickformat
New Contributors
- @shankstee made their first contribution in #2199
- @heythisispaul made their first contribution in #2212
Full Changelog: v36.3.2...v36.4.0
v36.3.2
What's Changed
- Added functionality to be able to pass user props to components. Safe… by @dlcartright in #2151
- Bump moment from 2.29.1 to 2.29.2 by @dependabot in #2186
- Add user props tests and remove arbitrary demo props by @becca-bailey in #2172
- Bump minimist from 1.2.5 to 1.2.6 in /demo/rn by @dependabot in #2177
- Add safe user props to all top-level components by @becca-bailey in #2191
- Bump ansi-regex from 3.0.0 to 3.0.1 in /demo/rn by @dependabot in #2190
- Bump plist from 3.0.4 to 3.0.5 in /demo/rn by @dependabot in #2189
- Bump async from 2.6.3 to 2.6.4 in /demo/rn by @dependabot in #2193
- Allow additional props from user, such as
aria-label
anddata-testid
by @becca-bailey in #2192 - Fix Horizontal charts panning at the incorrect rate by @TabithaMaudMM in #2179
New Contributors
- @dlcartright made their first contribution in #2151
- @TabithaMaudMM made their first contribution in #2179
Full Changelog: v36.3.1...v36.3.2
v36.3.1
What's Changed
- add FAQ for Expo Web apps by @jpdriver in #2121
- Add RegExp array to voronoiBlacklist type by @brendanmorrell in #2127
- Bump url-parse from 1.5.3 to 1.5.10 by @dependabot in #2143
- Bump url-parse from 1.5.3 to 1.5.10 in /demo/rn by @dependabot in #2144
- Bump node-fetch from 2.6.0 to 2.6.7 in /docs by @dependabot in #2075
- Fix TS build 2094 by @matt-hernandez in #2107
- Bump karma from 6.3.14 to 6.3.16 by @dependabot in #2148
- Bump url-parse from 1.4.7 to 1.5.10 in /docs by @dependabot in #2147
- Bump postcss from 7.0.32 to 7.0.39 in /docs by @dependabot in #2146
- Bump prismjs from 1.20.0 to 1.27.0 in /docs by @dependabot in #2145
- Bump lodash from 4.17.19 to 4.17.21 in /docs by @dependabot in #2159
New Contributors
- @jpdriver made their first contribution in #2121
- @brendanmorrell made their first contribution in #2127
- @matt-hernandez made their first contribution in #2107
Full Changelog: v36.3.0...v36.3.1
v36.3.0
What's Changed
- Bump follow-redirects from 1.14.7 to 1.14.8 by @dependabot in #2095
- Bump karma from 6.3.4 to 6.3.14 by @dependabot in #2092
- Fix font stack and correct margins in docs by @melvin-chen in #2070
- Patch missing text component type by @youPickItUp in #2089
- Bump nanoid from 3.1.28 to 3.2.0 in /demo/rn by @dependabot in #2074
- Patch missing text component type by @becca-bailey in #2097
- fix: android touch events by @zibs in #2071
- feat: Add VictoryNativeBrushLine component by @zibs in #2077
New Contributors
- @melvin-chen made their first contribution in #2070
- @youPickItUp made their first contribution in #2089
- @zibs made their first contribution in #2071
Full Changelog: v36.2.2...v36.3.0
v35.9.0
(2021-06-24)
Adds a new disableInlineStyles
prop to components and primitives to support users who want to style their components by class, or use a CSS in JS solution like styled-components
When the new disableInlineStyles
prop is supplied to a component like VictoryBar
no styles will be supplied to either data or label components that it renders:
const StyledBar = styled(Bar)`
fill: purple;
`
const StyledLabel = styled(VictoryLabel)`
tspan {
fill: magenta;
font-family: Papyrus, fantasy;
}
`
function CustomStyledBarChart() {
return (
<VictoryChart>
<VictoryBar
disableInlineStyles
labels={[1, 2, 3, 4]}
dataComponent={<StyledBar />}
labelComponent={<StyledLabel />}
/>
</VictoryChart>
)
}
The disableInlineStyles
prop may also be supplied to primitive components for more granular control:
const StyledBar = styled(Bar)`
fill: purple;
`
function CustomStyledBarChart() {
return (
<VictoryChart>
<VictoryBar
labels={[1, 2, 3, 4]}
dataComponent={<StyledBar disableInlineStyles />}
/>
</VictoryChart>
)
}
Related PRs