You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/components/pg/inputPixelEditor/README.md
+6-5Lines changed: 6 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -46,6 +46,7 @@ See usage for each method below.
46
46
| Method | Tested | Description |
47
47
| ---------- | -------- | ----------- |
48
48
|`getJson(options)`| - | Get JSON file. |
49
+
|`getData()`| - | Get layer data. |
49
50
|`setJson(json)`| - | Set JSON file. |
50
51
|`reset()`| - | Reset canvas and data. |
51
52
|`getExportCanvas()`| - | Get new canvas of export. |
@@ -98,7 +99,7 @@ See usage for each method below.
98
99
99
100
### `getJson(options)` Method
100
101
101
-
The `getJson` method allows getting the JSON representation of the current editor. Optionally this can snapshot the entire undo history.
102
+
The `getJson` method allows getting the JSON representation of the current editor. Optionally this can snapshot the entire undo history. To get only data by layer call `getData()`.
102
103
103
104
```typescript
104
105
@Part() $editor: PgInputPixelEditor;
@@ -173,8 +174,8 @@ A complete JSON storage for a 10x10 image.
0 commit comments