Product page image gallery reverse images/ thumbnails order

Do someone have experience setting up images order from the last to first on the Product page, could it work with adjusting cms-element-image-gallery twig template?