@rive-app/react-canvas 3.0.6 → 3.0.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rive-app/react-canvas",
3
- "version": "3.0.6",
3
+ "version": "3.0.10",
4
4
  "description": "React wrapper around the @rive-app/canvas library",
5
5
  "main": "dist/index.js",
6
6
  "typings": "dist/types/index.d.ts",
@@ -18,7 +18,7 @@
18
18
  },
19
19
  "homepage": "https://github.com/rive-app/rive-react#readme",
20
20
  "dependencies": {
21
- "@rive-app/canvas": "1.0.65"
21
+ "@rive-app/canvas": "1.0.66"
22
22
  },
23
23
  "peerDependencies": {
24
24
  "react": "^16.8.0 || ^17.0.0 || ^18.0.0"
@@ -1,12 +1,31 @@
1
1
  import { Layout } from '@rive-app/canvas';
2
2
  import { ComponentProps } from 'react';
3
- export declare type RiveProps = {
3
+ export interface RiveProps {
4
+ /**
5
+ * URL of the Rive asset, or path to where the public asset is stored.
6
+ */
4
7
  src: string;
8
+ /**
9
+ * Artboard to render from the Rive asset.
10
+ * Defaults to the first artboard created.
11
+ */
5
12
  artboard?: string;
13
+ /**
14
+ * Specify a starting animation to play.
15
+ */
6
16
  animations?: string | string[];
17
+ /**
18
+ * Specify a starting state machine to play.
19
+ */
7
20
  stateMachines?: string | string[];
21
+ /**
22
+ * Specify a starting Layout object to set Fill and Alignment for the drawing surface. See docs at https://help.rive.app/runtimes/layout for more on layout configuration.
23
+ */
8
24
  layout?: Layout;
25
+ /**
26
+ * For `@rive-app/react-webgl`, sets this property to maintain a single WebGL context for multiple canvases. **We recommend to keep the default value** when rendering multiple Rive instances on a page.
27
+ */
9
28
  useOffscreenRenderer?: boolean;
10
- };
29
+ }
11
30
  declare const Rive: ({ src, artboard, animations, stateMachines, layout, useOffscreenRenderer, ...rest }: RiveProps & ComponentProps<'canvas'>) => JSX.Element;
12
31
  export default Rive;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rive-app/react-canvas",
3
- "version": "3.0.6",
3
+ "version": "3.0.10",
4
4
  "description": "React wrapper around the @rive-app/canvas library",
5
5
  "main": "dist/index.js",
6
6
  "typings": "dist/types/index.d.ts",
@@ -18,7 +18,7 @@
18
18
  },
19
19
  "homepage": "https://github.com/rive-app/rive-react#readme",
20
20
  "dependencies": {
21
- "@rive-app/canvas": "1.0.65"
21
+ "@rive-app/canvas": "1.0.66"
22
22
  },
23
23
  "peerDependencies": {
24
24
  "react": "^16.8.0 || ^17.0.0 || ^18.0.0"