Shopify / dawn

Shopify's first source available reference theme, with Online Store 2.0 features and performance built-in.
Other
2.53k stars 3.41k forks source link

[RTE] Lists are getting line breaks if heading styles are selected #2418

Open danielvan opened 1 year ago

danielvan commented 1 year ago

Describe the current behavior

When using ordered or unordered lists, if I select a heading style on the RTE it automatically adds a line break between the bullet/number and the text.

Describe the expected behavior

Bullets/numbers and text just remain at the same line regardless of style chosen.

Version information (Dawn, browsers and operating systems)

Possible solution

Seems like we are not providing styles for lists inside of richtext. Potentially building those outs explicitly can fix the issue.

Additional context/screenshots

Screenshot

LexMetcalfe commented 1 year ago

I have another instance of this here (Sense v9), where changing the rte <ul> list-style-position hasn't solved the issue, despite the merchant using <p> elements within list items.

A solution I had was to change the list-position-style to outside, like so:

.rte ul, .rte ol {
    list-style-position: outside;
}