@civitai/app-sdk 0.60.0 → 0.62.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/dist/blocks/messages.d.ts +18 -3
- package/dist/blocks/types.d.ts +5 -1
- package/package.json +1 -1
|
@@ -521,6 +521,8 @@ export type ParentToBlockMessage = {
|
|
|
521
521
|
payload: {
|
|
522
522
|
requestId: string;
|
|
523
523
|
selected?: BlockUploadedImageInfo | BlockGenerationSourceImageInfo | BlockPendingImageInfo;
|
|
524
|
+
/** A `bytes` upload's refusal or failure: a host string or a forwarded server message. */
|
|
525
|
+
error?: string;
|
|
524
526
|
};
|
|
525
527
|
} | {
|
|
526
528
|
type: 'IMAGE_SCAN_RESOLVED';
|
|
@@ -836,6 +838,10 @@ export type BlockToParentMessage = {
|
|
|
836
838
|
requestId: string;
|
|
837
839
|
purpose?: BlockUploadPurpose;
|
|
838
840
|
asyncScan?: boolean;
|
|
841
|
+
/** In-tab image bytes; no picker. Page apps only. See the comment above. */
|
|
842
|
+
bytes?: ArrayBuffer;
|
|
843
|
+
/** Optional name for a `bytes` upload (host-sanitised). */
|
|
844
|
+
filename?: string;
|
|
839
845
|
};
|
|
840
846
|
} | {
|
|
841
847
|
type: 'SET_USER_CHECKPOINT';
|
|
@@ -966,11 +972,20 @@ export type BlockToParentMessage = {
|
|
|
966
972
|
type: 'SAVE_IMAGE';
|
|
967
973
|
payload: {
|
|
968
974
|
requestId: string;
|
|
969
|
-
/** Own-output URL — origin-allowlisted host-side. Mutually exclusive with `imageId`. */
|
|
975
|
+
/** Own-output URL — origin-allowlisted host-side. Mutually exclusive with `imageId` / `bytes`. */
|
|
970
976
|
url?: string;
|
|
971
|
-
/** Cross-user image id — routed through the gated per-viewer read. Mutually exclusive with `url`. */
|
|
977
|
+
/** Cross-user image id — routed through the gated per-viewer read. Mutually exclusive with `url` / `bytes`. */
|
|
972
978
|
imageId?: number;
|
|
973
|
-
/**
|
|
979
|
+
/**
|
|
980
|
+
* In-tab file bytes — classified by CONTENT host-side, size-capped host-side.
|
|
981
|
+
* Page apps only. Mutually exclusive with `url` / `imageId`.
|
|
982
|
+
*/
|
|
983
|
+
bytes?: ArrayBuffer;
|
|
984
|
+
/**
|
|
985
|
+
* Optional download filename (host-sanitized). For `bytes`, a `.json`
|
|
986
|
+
* name selects JSON for text that parses as JSON, and the extension is
|
|
987
|
+
* forced from the classified type.
|
|
988
|
+
*/
|
|
974
989
|
filename?: string;
|
|
975
990
|
};
|
|
976
991
|
} | {
|
package/dist/blocks/types.d.ts
CHANGED
|
@@ -2429,7 +2429,11 @@ export type BlockPostSource = {
|
|
|
2429
2429
|
imageIndexes?: number[];
|
|
2430
2430
|
} | {
|
|
2431
2431
|
kind: 'published';
|
|
2432
|
-
/**
|
|
2432
|
+
/**
|
|
2433
|
+
* Ids returned by a previous `usePublishGenerationOutputs()` publish, or
|
|
2434
|
+
* by an in-tab `bytes` upload (`useUploadImageBytes()` in
|
|
2435
|
+
* `@civitai/blocks-react`; page apps only).
|
|
2436
|
+
*/
|
|
2433
2437
|
imageIds: number[];
|
|
2434
2438
|
};
|
|
2435
2439
|
/**
|
package/package.json
CHANGED