How can I get the text on my cards in the centre but also aligned?

Hi!

I have a card that has a list on it and the text is in the centre. However, the bullet points are not aligned and it’s really annoying me!

Is there any way to keep the text in the centre but also have the bullet points aligned?

Thank you! :smile:

Those don’t look like bullet points – they look like lines that start with a -. You can tell for sure by checking the HTML view (click < > above the field).

If you use HTML bullet point formatting, they should default to left aligned. Adding/Editing - Anki Manual

1 Like

Use something like the following if you are using HTML lists (see previous reply):

:is(ul, ol) {
  margin-block-start: 15px;
}

It doesn’t exactly center anything but moves the list items more to the right side.

I’ll have a look, thank you.

Thank you!

Pretty sure it should be

:is(ul, ol) {
  margin-left: 15px;
}

to move it to the right.

margin-block-start

moves it down for me.

1 Like

This code should allow lists to be centered (matching the card’s text alignment) while keeping their contents left-justified:

ul, ol { 
   display: inline-block; 
}

li ul, li ol {
   display: block; /* Ensures proper indentation for nested lists in some edge-cases */
}
1 Like