allow counter update for inline elements

this makes magnific popup update the "x of y" conter in inline items that contain an element of class mfp-counter