Refactoring front-gallery-shortcode