feat(app): store assistant image previews as assets
This commit is contained in:
@@ -166,6 +166,16 @@ export function createDesktopAttachmentStore(): AttachmentStore {
|
||||
});
|
||||
}
|
||||
|
||||
if (input.source.kind === "base64") {
|
||||
const mimeType = normalizeMimeType(input.mimeType);
|
||||
return await saveDesktopAttachmentFromBase64({
|
||||
id,
|
||||
base64: input.source.base64,
|
||||
mimeType,
|
||||
fileName,
|
||||
});
|
||||
}
|
||||
|
||||
const mimeType = normalizeMimeType(input.mimeType ?? input.source.blob.type);
|
||||
const base64 = await blobToBase64(input.source.blob);
|
||||
return await saveDesktopAttachmentFromBase64({
|
||||
|
||||
Reference in New Issue
Block a user