-1
I’m making a website at work where I needed to make a bootstrap boot, with a "see more" style when clicking to open the card and the button turning "see less", the ways I found bugged the button if you clicked too fast, turning to see more before it even closes. The solution I found was to use before with content and Aria-Expanded, like this:
.Produtos .container_produtos .conteudo .card #botao[aria-expanded="false"]:before{
content:" Ver mais ";
}
.Produtos .container_produtos .conteudo .card #botao[aria-expanded="true"]:before{
content:" Ver menos ";
}
In front of the view more there is an icon of +, and when the card opens, the customer would like it to flip a -, is there a way to turn an icon using before? or that uses Aria Expanded to keep you from bugging
How about
" + Ver mais "
:D, Guy without your code doesn’t help you much, put in the Bootstrap component that you’re using and tell me which version of Bootstrap it is.– hugocsl
I would use javascript to make that happen. And a very good way to use these icons is the awesome font, because the icons are chosen according to the class of that element: https://fontawesome.com To change the class you only need to use the property. jquery toggleClass
– Lucas Módolo