Closed 1058274 closed 1 year ago
I would suggest implementing an HTML field with TinyMCE as done in https://github.com/svthalia/concrexit
I would suggest implementing an HTML field with TinyMCE as done in https://github.com/svthalia/concrexit
I had a look at TinyMCE's HTMLField
and it looks like a better solution indeed, as it allows the admins to customize the project description in different ways and to preview the project descriptions in realtime instead of having to rely on some conversion from urlize
that only gets applied after saving.
Other than hyperlinks, what other styling features should be allowed in the editor? Also, the output should go through a bleach
tag that has been configured based on the predetermined allowed styling features, similar to how it has been implemented @ Thalia, correct?
Other than hyperlinks, what other styling features should be allowed in the editor? Also, the output should go through a
bleach
tag that has been configured based on the predetermined allowed styling features, similar to how it has been implemented @ Thalia, correct?
Maybe strong or italic text would be nice too, as well as ul
s and ol
s. I think the set Thalia implemented is very well thought-through so I propose to just copy it from them :)
One-sentence description
Obvious plaintext URLs in project descriptions should automatically be detected and converted to HTML hyperlinks.
Desired functionality
Currently, project descriptions can not be set in any way to present URLs as HTML hyperlinks due to HTML character encoding. Superusers should be able to set a plaintext project description containing URLs where the URLs get converted to HTML hyperlinks in the front-end. This way, page visitors can directly visit a page mentioned in the project description using a single click.
Motivation
Nitpicking, perfectionism, and user experience.
Suggested implementation
example.nl
does not get converted butwww.example.nl
andhttps://example.nl
do.Chemrade Plant dashboard
andPUC Mathematics scavenger hunt
. This step is not directly related to this repository, as it is likely a configuration mistake.urlize
, the current production website would have displayed proper hyperlinks. However, I think this step is not necessary if the user setting the project descriptions is aware that HTML can not directly be embedded in project descriptions.