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

-- markdown option? -- #1604

Open
scubamuc opened this issue May 27, 2024 · 7 comments
Open

-- markdown option? -- #1604

scubamuc opened this issue May 27, 2024 · 7 comments
Labels
enhancement New feature or request

Comments

@scubamuc
Copy link

my mail communication is generally unformatted plain text and html is avoided rigorously....

Sometimes basic formatting is required though. I've become quite accustomed to markdown.

grafik

Would it be possible to add markdown as an option to the fantastic editor in Snappymail?

Best regards and thanks for great software!

@the-djmaze
Copy link
Owner

There are many different ways how text/markdown is handled/viewed.

So how should SnappyMail handle Markdown?
What rules to use when writing in HTML and go to text/plain?
What rules to use when converting to HTML?
Etc.

@scubamuc
Copy link
Author

@the-djmaze, wow, thanks for the quick reply.

admittedly, hadn't considered any "rules". not being a dev makes this difficult to specify.

So how should SnappyMail handle Markdown?

in the same way it handles text / html, add a toggle for md.

What rules to use when writing in HTML and go to text/plain?

select either html, text or md.

What rules to use when converting to HTML?

no need for conversion, html is avoided. this is an option like "use plain text only" or "use plain text and md only"

do you have suggestions?

@scubamuc
Copy link
Author

scubamuc commented May 28, 2024

@the-djmaze since Snappymail is perfectly integrated in Nextcloud and the 1st choice mail client for Nextcloud, I was thinking somewhere along the lines of using the markdown functionality offered by Nextcloud. Almost all Nextcloud docs can be edited with Nextcloud editor as text or md and can be viewed/previewed in Nextcloud.

But I do understand the necessity to specify when Snappymail is standalone.

@the-djmaze
Copy link
Owner

Since many mail viewers don't handle markdown, the code needs to be transformed in HTML.
So # becomes H1, etc.
But when you look here on github, many other things are possible.

And when you view markdown in different applications, the styling is not consistent.

So which is "best" for our viewing purposes?

@scubamuc
Copy link
Author

asking for my preferences, I'd say GitHub markdown is the reference but Snappymail being 1st choice mail for Nextcloud, this would be my personal favourite.

the-djmaze pushed a commit that referenced this issue Aug 20, 2024
the-djmaze pushed a commit that referenced this issue Aug 25, 2024
@the-djmaze
Copy link
Owner

I've added:

Why? Because these have the lowest footprint regarding JavaScript code.
Both should be CommonMark compatible and extensible.

They are not used yet, but it gives a base to start working with.

@the-djmaze
Copy link
Owner

For now i've integrated Turndown to convert HTML into Markdown into the plain text editor and message viewer.

Let's see if it will improve the experience.

@the-djmaze the-djmaze added the enhancement New feature or request label Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants