This commit is contained in:
Timothy Jaeryang Baek
2026-04-09 11:36:06 -07:00
parent 4b8e331333
commit 1dcbfd47fb
2 changed files with 15 additions and 3 deletions
+13 -1
View File
@@ -1231,7 +1231,19 @@
const { query, files: eventFiles } = $desktopEvent;
desktopEvent.set(null);
// TODO: handle eventFiles (attach to chat)
// Attach screenshot images from desktop (e.g. Spotlight region capture)
if (eventFiles?.length) {
for (const ef of eventFiles) {
files = [
...files,
{
type: 'image',
url: ef.dataUrl,
name: ef.name
}
];
}
}
if (query) {
messageInput?.setText(query);
+2 -2
View File
@@ -711,8 +711,8 @@
await goto(event.data.path);
return;
}
if (event.type === 'query' && event.data?.query) {
desktopEvent.set({ query: event.data.query });
if (event.type === 'query' && (event.data?.query || event.data?.files?.length)) {
desktopEvent.set({ query: event.data.query, files: event.data.files });
await goto('/');
return;
}