@rive-app/canvas-advanced-single 2.49.3 → 2.50.0

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,7 +1,7 @@
1
1
  {
2
2
  "name": "@rive-app/canvas-advanced-single",
3
- "version": "2.49.3",
4
- "description": "Rive's lightweight low-level canvas based web api all in one js file.",
3
+ "version": "2.50.0",
4
+ "description": "Rive web runtime, low-level API, canvas renderer, bundled as a single JS file. Rive is an agent-native 2D and 3D engine for games, apps, and interactive UI.",
5
5
  "main": "canvas_advanced_single.mjs",
6
6
  "homepage": "https://rive.app",
7
7
  "repository": {
@@ -10,7 +10,11 @@
10
10
  },
11
11
  "keywords": [
12
12
  "rive",
13
- "animation"
13
+ "animation",
14
+ "interactive",
15
+ "ui",
16
+ "game-engine",
17
+ "graphics"
14
18
  ],
15
19
  "author": "Rive",
16
20
  "contributors": [
@@ -22,6 +22,16 @@ interface RiveOptions {
22
22
  declare function Rive(options?: RiveOptions): Promise<RiveCanvas>;
23
23
  export default Rive;
24
24
 
25
+ /** Resolved script fetch options; see RuntimeLoader.setScriptFetch. */
26
+ export interface ScriptFetchConfig {
27
+ proxyUrl: string | null;
28
+ allowedHosts: string[] | null;
29
+ /** 0 is no limit. */
30
+ maxRequestsPerMinute: number;
31
+ /** 0 keeps the runtime's default. */
32
+ maxResponseBytes: number;
33
+ }
34
+
25
35
  /**
26
36
  * RiveCanvas is the main export object that contains references to different Rive classes to help
27
37
  * build the Rive render loop for low-level API usage. In addition, this contains multiple methods
@@ -93,6 +103,13 @@ export interface RiveCanvas {
93
103
  */
94
104
  awaitReplayCaps?(): Promise<void> | undefined;
95
105
 
106
+ /**
107
+ * @experimental Enables scripts' fetch() for every file, or disables it
108
+ * with null. Only in builds with script networking (the threaded webgl2
109
+ * build), so always feature-detect it. Use RuntimeLoader.setScriptFetch.
110
+ */
111
+ configureScriptFetch?(options: ScriptFetchConfig | null): void;
112
+
96
113
  /**
97
114
  * Loads a Rive file for the runtime and returns a Rive-specific File class
98
115
  *
@@ -1009,6 +1026,8 @@ export interface FocusState {
1009
1026
  hasFocus: boolean;
1010
1027
  /** True if the focused element accepts keyboard input (e.g. a TextInput node). */
1011
1028
  expectsKeyboardInput: boolean;
1029
+ /** True if the focused element or an ancestor takes typed text: show a virtual keyboard. */
1030
+ expectsTextInput: boolean;
1012
1031
  }
1013
1032
 
1014
1033
  export declare class LinearAnimation {