forked from airbnb/visx
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
new(react-spring): add package, move AnimatedAxis + AnimatedTicksRend…
…erer
- Loading branch information
1 parent
3127ea5
commit 88239bb
Showing
7 changed files
with
81 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# @vx/react-spring | ||
|
||
<a title="@vx/react-spring npm downloads" href="https://www.npmjs.com/package/@vx/react-spring"> | ||
<img src="https://img.shields.io/npm/dm/@vx/react-spring.svg?style=flat-square" /> | ||
</a> | ||
|
||
Although `vx` is largely unopinioned on animation, there is value in abstracting the complexity + | ||
boilerplate of building **animated** `vx` visualization components. | ||
[`react-spring`](https://www.react-spring.io/) provides performant primitives for animating react | ||
components and is our recommended library for making animated charts. | ||
|
||
In order to minimize `react-spring` as a dependency across other `vx` packages, this package | ||
requires `react-spring` as a `peerDependency` (to be compatible with any usage within your app) and | ||
exports all `vx` components that depend on `react-spring`. | ||
|
||
## Installation | ||
|
||
``` | ||
npm install --save react-spring @vx/react-spring | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
{ | ||
"name": "@vx/react-spring", | ||
"version": "0.0.0", | ||
"description": "Vx primitives that rely on react-spring for animation", | ||
"sideEffects": false, | ||
"main": "lib/index.js", | ||
"module": "esm/index.js", | ||
"types": "lib/index.d.ts", | ||
"files": [ | ||
"lib", | ||
"esm" | ||
], | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/hshoff/vx.git" | ||
}, | ||
"keywords": [ | ||
"vx", | ||
"react", | ||
"d3", | ||
"visualizations", | ||
"charts", | ||
"animation", | ||
"react-spring" | ||
], | ||
"contributors": [ | ||
{ | ||
"name": "Chris Williams", | ||
"url": "https://github.com/williaster" | ||
} | ||
], | ||
"license": "MIT", | ||
"bugs": { | ||
"url": "https://github.com/hshoff/vx/issues" | ||
}, | ||
"homepage": "https://github.com/hshoff/vx#readme", | ||
"publishConfig": { | ||
"access": "public" | ||
}, | ||
"peerDependencies": { | ||
"react": "^16.3.0-0", | ||
"react-spring": "^8.0.27" | ||
}, | ||
"dependencies": { | ||
"@types/classnames": "^2.2.9", | ||
"@types/react": "*", | ||
"@vx/axis": "0.0.198", | ||
"@vx/scale": "0.0.198", | ||
"@vx/text": "0.0.198", | ||
"classnames": "^2.2.5", | ||
"prop-types": "^15.6.2" | ||
} | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...dTicksRenderer/useTickTransitionConfig.ts → ...dTicksRenderer/useTickTransitionConfig.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export { default as AnimatedTicksRender } from './axis/AnimatedTicksRenderer'; | ||
export { default as AnimatedAxis } from './axis/AnimatedAxis'; |