@arey-dev
Posted
Hello! your work is great!!
I think the button's text and the p
tag has the same color. But if you want to reduce the opacity
of the button's text. You can use hsla()
function, it takes four value. The fourth value is the alpha value, it determines the opacity of the color.
Example:
button:hover {
color: hsla(0, 100%, 100%, 0.5);
}
@ZLikas
Posted
@arey-dev Hi, I've tried this method, the text inside becomes white instead of transparent.
@arey-dev
Posted
@ZLikas Take a look at this hsla() for more info.
Or an alternative solution is to wrap the text of the button in a
tag and set the opacity of a
like this, for exmaple:
html
<button>
<a>Some text</a>
</button>
css
a {
opacity: 0.6;
}