mirror of
https://github.com/block/buzz.git
synced 2026-11-02 07:22:55 +00:00
refactor(desktop): extract link preview helpers
Co-authored-by: Taylor Ho <taylorkmho@gmail.com> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
This commit is contained in:
parent
2f988aae17
commit
2ac9528955
21
desktop/src/shared/api/editMessage.ts
Normal file
21
desktop/src/shared/api/editMessage.ts
Normal file
@@ -0,0 +1,21 @@
|
||||
import { invokeTauri } from "@/shared/api/tauri";
|
||||
|
||||
export async function editMessage(
|
||||
channelId: string,
|
||||
eventId: string,
|
||||
content: string,
|
||||
mediaTags?: string[][],
|
||||
emojiTags?: string[][],
|
||||
mentionPubkeys?: string[],
|
||||
suppressLinkPreviews?: boolean,
|
||||
): Promise<void> {
|
||||
await invokeTauri("edit_message", {
|
||||
channelId,
|
||||
eventId,
|
||||
content,
|
||||
mediaTags: mediaTags ?? [],
|
||||
emojiTags: emojiTags ?? [],
|
||||
mentionPubkeys: mentionPubkeys ?? null,
|
||||
suppressLinkPreviews: suppressLinkPreviews ?? false,
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user