Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

View Markdown source of foreign messages #13516

Closed
martinvonwittich opened this issue May 5, 2020 · 2 comments
Closed

View Markdown source of foreign messages #13516

martinvonwittich opened this issue May 5, 2020 · 2 comments

Comments

@martinvonwittich
Copy link

Is your suggestion related to a problem? Please describe.

It is currently easy to get the Markdown source of your own messages - just hit the up arrow key to open the editing view, and you can easily copy-paste the Markdown source of your own messages, e.g. to post the same message in multiple chats.

Unfortunately, it is not as easy to get the Markdown source of messages posted by other users. Currently the only way is to click on "View source" and to extract it from content.body, but this has two significant disadvantages:

  • It's not obvious how to do this to normal users which have no tech background
  • The text is formatted as JSON, which implies that newlines are expressed as \n

This makes copying the Markdown code from foreign messages practically unusable.

The use case I have in mind for this would be e.g. to collaboratively extend a list. The first user might post:

  • foo
  • bar
  • baz

and someone else might want to extend this list to:

  • foo
  • bar
  • baz
  • barfoo
  • bazfoo

This would currently involve manually recreating the formatting each time.

Describe the solution you'd like

I would like the ability to easily view (or at least copy) the Markdown representation of a foreign message, e.g. by clicking on the three dots next to a message and choosing a suitable option that does this.

Describe alternatives you've considered

  • The "View source" option could be extended so that it has two tabs:

    • View Markdown source

      This will show the message formatted as Markdown.

    • View message source

      This will show the whole message source as JSON, as "View source" currently does.

  • Message editing could be extended so that it allows users to open the edit view for foreign messages, of course only having the ability to save changes for one's own messages.

@turt2live
Copy link
Member

Not all messages are markdown - riot just happens to use markdown. Also, there is an argument to be made that it shouldn't be easy to copy other people's messages and instead possibly use different tooling to accomplish the task.

@MadLittleMods
Copy link
Contributor

Closing in favour of #10649

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants