-
-
Notifications
You must be signed in to change notification settings - Fork 393
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
[FIX] Promote URLs in plain text to HTML anchors after strip_tags. #5341
Conversation
@decidim/lot-core this PR is ready for review |
decidim-core/spec/content_renderers/decidim/hashtag_renderer_spec.rb
Outdated
Show resolved
Hide resolved
Co-Authored-By: Oriol Gual <oriolgual@users.noreply.github.com>
[REFACTOR] Also added target blank and rel noopener.
@oriolgual @decidim/lot-core I've simplified this PR to simply converting plain text URLs to anchors. Ready |
… Proposal and CollaborativeDrafts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good enough for me, if in the future we need to add it to more places we can review the approach
@tramuntanal I've deployed this to staging and it doesn't seem to work OK:
http://staging.decidim.codegram.com/processes/itaque-voluptatem/f/3/proposals/43 |
Yes, I'll check! |
* Fix order to escape proposal content. Related to #5341 * Revert spec changes
🎩 What? Why?
Links in Proposal's body disappear.
I'm doing one thing in this PR:
Discarded:
📌 Related Issues
📋 Subtasks
CHANGELOG
entry📷 Screenshots (optional)
When entering "Content with <a href="http://urls.net" onmouseover="alert(document.cookies)">URLs</a> of anchor type and text urls like https://decidim.org." in the body of a Proposal, it gets rendered as follows: