Module: @lexical/clipboard
Functions
$generateJSONFromSelectedNodes
▸ $generateJSONFromSelectedNodes<SerializedNode
>(editor
, selection
): Object
Type parameters
Name | Type |
---|---|
SerializedNode | extends BaseSerializedNode |
Parameters
Name | Type |
---|---|
editor | LexicalEditor |
selection | null | RangeSelection | GridSelection | NodeSelection |
Returns
Object
Name | Type |
---|---|
namespace | string |
nodes | SerializedNode [] |
Defined in
lexical-clipboard/src/clipboard.ts:460
$generateNodesFromSerializedNodes
▸ $generateNodesFromSerializedNodes(serializedNodes
): LexicalNode
[]
Parameters
Name | Type |
---|---|
serializedNodes | BaseSerializedNode [] |
Returns
Defined in
lexical-clipboard/src/clipboard.ts:482
$getHtmlContent
▸ $getHtmlContent(editor
): string
Parameters
Name | Type |
---|---|
editor | LexicalEditor |
Returns
string
Defined in
lexical-clipboard/src/clipboard.ts:47
$getLexicalContent
▸ $getLexicalContent(editor
): null
| string
Parameters
Name | Type |
---|---|
editor | LexicalEditor |
Returns
null
| string
Defined in
lexical-clipboard/src/clipboard.ts:67
$insertDataTransferForPlainText
▸ $insertDataTransferForPlainText(dataTransfer
, selection
): void
Parameters
Name | Type |
---|---|
dataTransfer | DataTransfer |
selection | RangeSelection | GridSelection |
Returns
void
Defined in
lexical-clipboard/src/clipboard.ts:85
$insertDataTransferForRichText
▸ $insertDataTransferForRichText(dataTransfer
, selection
, editor
): void
Parameters
Name | Type |
---|---|
dataTransfer | DataTransfer |
selection | RangeSelection | GridSelection |
editor | LexicalEditor |
Returns
void
Defined in
lexical-clipboard/src/clipboard.ts:96
$insertGeneratedNodes
▸ $insertGeneratedNodes(editor
, nodes
, selection
): void
Parameters
Name | Type |
---|---|
editor | LexicalEditor |
nodes | LexicalNode [] |
selection | RangeSelection | GridSelection |
Returns
void
Defined in
lexical-clipboard/src/clipboard.ts:155
copyToClipboard
▸ copyToClipboard(editor
, event
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
editor | LexicalEditor |
event | null | ClipboardEvent |
Returns
Promise
<boolean
>
Defined in
lexical-clipboard/src/clipboard.ts:502