route-graphics 0.0.34 → 0.0.35

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/README.md CHANGED
@@ -99,7 +99,7 @@ Parse elements from state object using registered parser plugins (without render
99
99
  Update the canvas background color.
100
100
 
101
101
  **Parameters:**
102
- - `color` (string) - New background color as hex (e.g., `"0xffffff"`)
102
+ - `color` (number) - New background color as hex (e.g., `0xffffff`)
103
103
 
104
104
  **Returns:** `void`
105
105
 
@@ -116,12 +116,12 @@ Find an element in the stage by its label.
116
116
 
117
117
  ---
118
118
 
119
- #### `extractBase64(element)`
119
+ #### `extractBase64(label)`
120
120
 
121
121
  Extract a base64 representation of an element.
122
122
 
123
123
  **Parameters:**
124
- - `element` (DisplayObject) - Element to extract
124
+ - `label` (string, optional) - Label of the element to extract. Omit to extract the full stage.
125
125
 
126
126
  **Returns:** `Promise<string>` - Base64 string
127
127
 
@@ -263,11 +263,13 @@ app.render({
263
263
  width: 64,
264
264
  height: 64,
265
265
  hover: {
266
- imageSrc: "file:circle-blue",
266
+ src: "file:circle-blue",
267
267
  soundSrc: "file:hover-sound"
268
268
  },
269
269
  click: {
270
- action: "handleClick",
270
+ actionPayload: {
271
+ action: "handleClick"
272
+ },
271
273
  soundSrc: "file:click-sound"
272
274
  }
273
275
  }