Like the editor of this forum, in addition to recognizing Markdown, it can also identify image data in the clipboard. If it’s an image, it would automatically upload it and insert it at the cursor’s position.
Currently, in Mattermost’s text input box, when using Ctrl+V to paste, if the data in the clipboard is not text, it uniformly goes through the attachment upload process. In fact, if it’s an image, it could be uploaded in the background, automatically retrieve the path, and then be inserted at the cursor position through inline code. I think this would be more intuitive, don’t you agree?
https://simditor.tower.im/
is an open-source text editor. After proper configuration, it can achieve quite a perfect blend of text and images, and it might be worth looking into for reference.