0

Does anyone know how to add two values to the "background-repeat" attribute, so that I can for example repeat an image in x-direction (background-repeat: repeat-x) and space the image in x-direction at the same time (background-repeat: space)?

Unfortunately, if I leave it just to the value "space" it will repeat in both directions and if I just leave the value to "repeat-x" it wont space in x-direction, it will cut off as soon as the width of the window has been reached. So how can I do both?

cyra
  • 9
  • 2
  • you cannot have two values for the same direction. Either you repeat, you round or you space. By the way, space and round will repeat the image so I don't understand what you exactly want, maybe `background-repeat: space no-repeat` ? – Temani Afif Aug 01 '22 at 08:47
  • @Temani Afif To make it more specific: what if I want to repeat the background in only y-direction and round it at the same time so that the last image does not cut of when it reach the bottom. I know space and round will repeat by them self, but the are focussing on the horizontal repetitions not on the vertical ones – cyra Aug 01 '22 at 09:07
  • use `background-repeat: no-repeat round` – Temani Afif Aug 01 '22 at 09:08
  • @Temani Afif It does not work!!! – cyra Aug 01 '22 at 09:12
  • *It does not work!!!* --> show us that *it doesn't work*. Until then, it does work for me. – Temani Afif Aug 01 '22 at 09:15

0 Answers0