View Single Post
Old 06-17-2019, 02:13 AM   #1
char101
Junior Member
char101 began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Jun 2019
Device: Samsung Tab S2
Alternating lines color in paragraph

Alternate lines color in paragraphs. To customize first decide the first color (color1), the 2nd color (color2), and the height (try different values until it fits). Then modify the values such as

Code:
repeating-linear-gradient(0deg, color1, color1 height/2, color2 height/2, height);
Code:
p { 
    line-height: 1.5 !important;
    background: repeating-linear-gradient(0deg, #1c5071, #1c5071 22px, #8e3b49 22px, #8e3b49 44px);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
Example screenshot: https://imgur.com/a/wycQSmC

Last edited by char101; 06-17-2019 at 02:16 AM. Reason: Add screenshot
char101 is offline   Reply With Quote