@rive-app/webgl-single 1.0.17 → 1.0.20

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rive-app/webgl-single",
3
- "version": "1.0.17",
3
+ "version": "1.0.20",
4
4
  "description": "Rive's webgl based web api with bundled wasm.",
5
5
  "main": "rive.js",
6
6
  "homepage": "https://rive.app",
package/rive.d.ts CHANGED
@@ -315,6 +315,13 @@ export declare class Rive {
315
315
  * when the canvas is resized
316
316
  */
317
317
  resizeToCanvas(): void;
318
+ /**
319
+ * Accounts for devicePixelRatio as a multiplier to render the size of the canvas drawing surface.
320
+ * Uses the size of the backing canvas to set new width/height attributes. Need to re-render
321
+ * and resize the layout to match the new drawing surface afterwards. Useful function for consumers
322
+ * to include in a window resize listener
323
+ */
324
+ resizeDrawingSurfaceToCanvas(): void;
318
325
  get source(): string;
319
326
  /**
320
327
  * Returns the name of the active artboard