Skip to content

Commit be3d76b

Browse files
authored
Minor doc updates to avoid common confusion in issues (#2869)
1 parent 359a99e commit be3d76b

File tree

4 files changed

+34
-2
lines changed

4 files changed

+34
-2
lines changed

docs/src/content/docs/victory-animation.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ type: docs
88

99
# VictoryAnimation
1010

11+
> [See this guide to animations with Victory Charts](/guides/animations). The `VictoryAnimation` component is used for animating arbitrary React components and is not commonly used.
12+
1113
`VictoryAnimation` animates prop changes for any React component. To animate prop changes, define a child function that accepts an object of tweened values and other animation information and returns a component to render.
1214

1315
```jsx

docs/src/content/docs/victory-clip-container.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
id: 10
33
title: VictoryClipContainer
4-
category: more
4+
category: containers
55
type: docs
66
scope: null
77
---
@@ -10,6 +10,16 @@ scope: null
1010

1111
`VictoryClipContainer` is a specialized group container that enables curtain-style transitions for continuous data types like `VictoryLine` and `VictoryArea`. `VictoryClipContainer` will render its children either in a regular `<g>` element, or in a `<g>` element clipped by a rectangular clip path when a `clipWidth` is supplied.
1212

13+
```playground
14+
<VictoryChart>
15+
<VictoryLine
16+
groupComponent={
17+
<VictoryClipContainer clipPadding={{ top: -100 }} />
18+
}
19+
/>
20+
</VictoryChart>
21+
```
22+
1323
## children
1424

1525
`type: element || array[element]`

docs/src/content/docs/victory-tooltip.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,26 @@ scope:
1313

1414
*note:* When providing tooltips for `VictoryLine` or `VictoryArea`, it is necessary to use [`VictoryVoronoiContainer`](/docs/victory-voronoi-container), as these components only render a single element for the entire dataset.
1515

16+
See the [tooltips guide](/guides/tooltips) for more expanded examples of usage.
17+
18+
```playground
19+
<VictoryChart domain={{ x: [0, 11], y: [-10, 10] }}>
20+
<VictoryBar
21+
labelComponent={<VictoryTooltip/>}
22+
data={[
23+
{x: 2, y: 5, label: "right-side-up"},
24+
{x: 4, y: -6, label: "upside-down"},
25+
{x: 6, y: 4, label: "tiny"},
26+
{x: 8, y: -5, label: "or a little \n BIGGER"},
27+
{x: 10, y: 7, label: "automatically"}
28+
]}
29+
style={{
30+
data: {fill: "tomato", width: 20}
31+
}}
32+
/>
33+
</VictoryChart>
34+
```
35+
1636
## active
1737

1838
`type: boolean`

docs/src/content/guides/animations.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ scope:
88
---
99
# Animations
1010

11-
VictoryAnimation is able to animate changes in props using [d3-interpolate][]. Victory components define their animations via the `animate` prop. `duration`, `delay`, `easing` and `onEnd` functions may all be specified via the `animate` prop.
11+
Victory is able to animate changes in props using [d3-interpolate][]. Victory components define their animations via the `animate` prop. `duration`, `delay`, `easing` and `onEnd` functions may all be specified via the `animate` prop.
1212

1313
```playground_norender
1414
function App() {

0 commit comments

Comments
 (0)