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