CameronCogs Posted June 20 Posted June 20 Hi everyone, I used custom CSS to create a gradient effect for my H2 text, however, now in my testimonial carousel all of the text is also gradient even though it is paragraph 2 size, which I have in many other places in the site which are black. Only in the carousel is this gradient applied to paragraph sized font. Hoping someone has an idea of how to correct this issue. The website link is below and the carousel is at the very bottom of the page. The code I used for the gradient is as follows: h2 {background: -webkit-linear-gradient(45deg, blue, aqua);-webkit-background-clip: text;-webkit-text-fill-color: transparent;}h1:hover {background: -webkit-linear-gradient(45deg, aqua, blue);-webkit-background-clip: text;-webkit-text-fill-color: transparent;} www.myvitaminscore.com/homeold
Solution Lesum Posted June 20 Solution Posted June 20 @CameronCogs Hi! Update your code to the following to address the issue: h2:not(.list-item-content__title) { background: -webkit-linear-gradient(45deg, blue, aqua); -webkit-background-clip: text; -webkit-text-fill-color: transparent; } h1:hover { background: -webkit-linear-gradient(45deg, aqua, blue); -webkit-background-clip: text; -webkit-text-fill-color: transparent; } If my comments were useful, please like or mark my solution as answer so others can scroll to it quickly. Sam Web Developer & Digital Designer ☕ Did you find my contribution helpful? Buy me a coffee?
CameronCogs Posted June 21 Author Posted June 21 9 hours ago, Lesum said: @CameronCogs Hi! Update your code to the following to address the issue: h2:not(.list-item-content__title) { background: -webkit-linear-gradient(45deg, blue, aqua); -webkit-background-clip: text; -webkit-text-fill-color: transparent; } h1:hover { background: -webkit-linear-gradient(45deg, aqua, blue); -webkit-background-clip: text; -webkit-text-fill-color: transparent; } Thank you very much my friend. Worked like a charm!
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment