Table of Contents text formatting

Posted in: Newspaper
Post count: 201

Hi team,

Firstly, the Table of Contents was a great addition to the theme – thank you!

My question relates to styling. By default, the content headings are indented, and this is accentuated if the list style is changed to circle or numeric.

Is there an easy way to remove this indent? As the table of contents is typically small, I would like the headings left-aligned in line with the header, to best make use of available space.

Thanks!

Post count: 35449

Hi,
Unfortunately, di do not understand exactly. Can you please provide an example how you’ll like to be? Also a link to the page were you are using the Table of Contents will help a lot.
Thank you!

Post count: 201

Hi Calin,

Apologies my description wasn’t clear. By default, the table of content headers are shifted right, here’s an image that helps show what I mean: https://imgur.com/a/tbVC8y9

What I want is the Headings to be left aligned in line with the Table of Contents title, like this: https://imgur.com/a/863fJVQ

Post count: 35449

Hi,
I understand.
Please try this custom css:
#panel li {
margin-left: 0;
}

Set the css in the theme panel > custom code> custom css.
Thank you!

Post count: 201

Hi Calin,

Thanks for the suggestion. Unfortunately, wish a css fix like that, everything will be forced to have no left margin, meaning nested headers will no longer nest correctly.

Post count: 35449

Hi,
In this situation try this css:
#panel {
margin-left: -21px;
}

The nested headers will display nest correctly

Post count: 201

Hi Calin,

That’s done the trick, thank you for the recommendation.

Hopefully this is another one the devs can add to the roadmap. While the extra css words, it’s always nice to have a built-in toggle for the margin.

Thanks again!

Viewing 7 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic.