(gifUrl: string, altText: string)
| 568 | }; |
| 569 | |
| 570 | const onGifCommand = async (gifUrl: string, altText: string) => { |
| 571 | const textareaCommand = getCommand(); |
| 572 | const replace: GetReplacementFn = (type, { trailingChar }) => { |
| 573 | const replacement = `${ |
| 574 | !trailingChar ? '' : '\n\n' |
| 575 | }\n\n`; |
| 576 | return { replacement }; |
| 577 | }; |
| 578 | await textareaCommand.replaceWord(replace, onUpdate); |
| 579 | }; |
| 580 | |
| 581 | const onPaste: ClipboardEventHandler<HTMLTextAreaElement> = async (e) => { |
| 582 | const pastedText = e.clipboardData.getData('text'); |
nothing calls this directly
no test coverage detected