# Highlight-based quoting ruby text messes up formatting

**URL:** <https://meta.discourse.org/t/highlight-based-quoting-ruby-text-messes-up-formatting/125282>\
**Category:** Feature\
**Created:** [August 8, 2019, 9:02pm UTC](https://meta.discourse.org/t/highlight-based-quoting-ruby-text-messes-up-formatting/125282 "2019-08-08T21:02:57Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![seanblue](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@seanblue](https://meta.discourse.org/u/seanblue)\
**Post date:** [December 5, 2019, 5:59pm UTC](https://meta.discourse.org/t/highlight-based-quoting-ruby-text-messes-up-formatting/125282/9 "2019-12-05T17:59:47Z")

</div>

It might be good to keep all the ruby-related tags that have been [whitelisted](https://github.com/discourse/discourse/blob/9845963105c03ab50b7443667e0e1a21855e125a/app/assets/javascripts/pretty-text/white-lister.js.es6#L196-L202), even though `rb` and `rp` aren’t used as much anymore. `rp` is used for legacy support for old browser though, so maybe not particularly relevant for Discourse. No big deal one way or the other, just thought I should mention.

EDIT:  
More importantly, when I test this on the word in my OP (and _only_ that word) it misses the surrounding `ruby` tags, so it doesn’t format the text as expected. When I highlight text on either side it before quoting, includes the `ruby` tag, but that workaround wouldn’t work if the word was the first or last part of the post. Is there anything that can be done to make sure it includes the `ruby` tags?

---

_[View the full topic](https://meta.discourse.org/t/highlight-based-quoting-ruby-text-messes-up-formatting/125282)._
