When click on add to cart button, the Woocommerce shows the message, view cart, I want to edit this message, actually edit all the span, put some icon etc...
@Dante is correct, the solutions provided by @BradleyD won't work for ajax_add_to_cart on shop page.
The solution provided by @Abstract is working as expected. I am also using his solution.
Another jQuery approach is to to listen for the the ajaxSuccess event on the document object and do the desired modifications for the clicked button.
Something like that should work:
$(document).ajaxSuccess(function(event, xhr, settings) {
if (settings.url.indexOf('?wc-ajax=add_to_cart') !== -1) {
// You can find the clicked button element under the event.target.activeElement
// Than you can do whatever you want here. Add new html element and text, etc.
}
});