Improve shortcode parsing