From 43f85bbbb0ed1c996b62937d21f82717cb51f9f6 Mon Sep 17 00:00:00 2001 From: Rajiv Anisetti Date: Wed, 6 Nov 2024 18:25:21 -0500 Subject: [PATCH] Add optional selection argument to $getHtmlContent flow type TSIA -- the implementation has an optional selection argument that defaults to `$getSelection()` --- packages/lexical-clipboard/flow/LexicalClipboard.js.flow | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/lexical-clipboard/flow/LexicalClipboard.js.flow b/packages/lexical-clipboard/flow/LexicalClipboard.js.flow index db534fbbe43..6ca0ee622b0 100644 --- a/packages/lexical-clipboard/flow/LexicalClipboard.js.flow +++ b/packages/lexical-clipboard/flow/LexicalClipboard.js.flow @@ -24,7 +24,11 @@ declare export function $insertDataTransferForRichText( editor: LexicalEditor, ): void; -declare export function $getHtmlContent(editor: LexicalEditor): string | null; +declare export function $getHtmlContent( + editor: LexicalEditor, + selection?: BaseSelection, +): string | null; + declare export function $getLexicalContent( editor: LexicalEditor, ): string | null;