I'm using this piece of code to create a somewhat dotted border:
CSS
.strip {
height: 5px;
width: 80px;
background: repeating-linear-gradient(90deg, transparent, transparent 10px, #ffaacd 5px, #ffaacd 30px);
}
I'm trying to reverse the colors by switching transparent
and #ffaacd
and their corresponding lengths but it doesn't work. I would get a straight pink line.
Note
Please note that I cannot use border
because it affects some layout so I'd rather just use the background.
Edit
I've created a Fiddle to illustrate what I'm trying to achieve.
Basically I'm doing some form of legend and right now the strip is starting with a transparent color but I want it to start with the pink color so that it is aligned with the strip above it.