-1

1

The CSS is below:

#RR .rewards-banner-lego .bubble ul {
    align-items: center;
    bottom: 100px;
    column-count: 4;
    display: flex;
    justify-content: center;
    list-style: none;
    position: relative;
}

If I add something like width: 500px; it adjusts to the side and does not center, how come?

2

  • You're centering everything inside a smaller width. Get the centering done with its parent if you want the whole container centered instead. Happy to show you a modern flexbox solution if you create a code snippet with markup etc. to reproduce the problem. – Zach Jensz Oct 18 '22 at 02:20
  • please include all your codes – arsyaadi Oct 18 '22 at 02:46

1 Answers1

0

it could be that 500px is too small so another way to add the width is by putting width: 100%; making your ul the same width as the website (if that's what you're wanting). If it's still not centered then you might try justify-content: center; which makes all the items in the element go to the center of it horizontally.

Lenonade
  • 28
  • 5