Move Gallery Block under Add to Cart

Description

  • move gallery block under add to cart, so you can some icon box with text under add to cart
  • view demo – password: abc
  • buy me a coffee

08.26c21v5 Move Gallery Block under Add to Cart

#1. Install Code

#1.1. First, you can edit Product > Add Section > Add a Gallery Block

08.26c21v5 Move Gallery Block under Add to Cart

Choose a Grid layout

08.26c21v5 Move Gallery Block under Add to Cart

#1.2. Click Gear icon on Store Page

07.26c05v1 Variant Description

Next, click Advanced > Page Header Code Injection

07.26c05v1 Variant Description

#1.3. Add this code to right box

<script>
window.MoveElementConfig = {
  moves: [
    {
      source: 'section.region .gallery-block',
      target: 'button.sqs-add-to-cart-button',
      position: 'after',
      enableDesktop: true,
      enableMobile: true
    }
  ]
};
</script>
<script src="https://code.beaverhero.com/same/0626c28v7moveelementdesktopmobile.js"></script>

08.26c21v5 Move Gallery Block under Add to Cart

#2. Customize

#2.1. To make 4 items/row on Mobile, use this under main code

<style>
@media screen and (max-width:767px) {
    .sqs-add-to-cart-button-wrapper.product-add-to-cart-button-wrapper .slide {
    width: 25% !important;
}}
</style>

 

Buy me a coffee