Adding icons to add-to-cart-button

Hello everyone!

I’m currently working on a custom theme and I’d like to ask for assistance:
I need to implement a custom icon with a different background in the add-to-cart-button, to resemble the following:
Screenshot from 2022-06-09 13-58-14

Does anyone know how can I achieve this result? (: Thank you very much in advance!

Hey Artur!

I think you can use ::after selector from and ‘backgound-image’ property, both from CSS.

Looks like:

button::after{
    content: " ";
    display: inline-block;
    width: 40px;
    height: 40px;
    background-color: blue;
    background-repeat: no-repeat;
    background-size: contain;
    background-image: url('your icon here');
}

Give me a feedback if it helped you!