Note: This is for advanced users who can work with Shopify liquid code and CSS styling language.


Badges can be placed at virtually any location on pages having products, including product details page, collection page, search page, etc. The badge position can be manipulated by:


1. Changing the integration code location

2. Passing appropriate parameters in the integration code    


There are two helpful integration parameters to manage the badge placement:


1. primebOuterClass: CSS classes passed using this parameter will be applied to the DIV containing the badges. 


We have the following in-built classes that can be used to manage the badge placement:


Class NameResultant CSS
prime-d-blockdisplay:block;
prime-d-inline-blockdisplay:inline-block;
prime-mr-1margin-right: .25rem;
prime-ml-1margin-left: .25rem;
prime-mt-1margin-top: .25rem;
prime-mb-1margin-bottom: .25rem;


Example integration code:

{% render 'primeb', product: product, primebOuterClass:'prime-mt-1 prime-mb-1', primebInnerClass: 'prime-d-inline-block prime-mr-1 prime-mb-1' %}

This will apply a margin of .25rem to the top and bottom of the badge container.


2. primebOuterStyle: Pass any custom CSS elements using this parameter and they will be applied to the badge container.


Example integration code:

{% render 'primeb', product: product, primebOuterClass:'prime-d-inline-block', primebOuterStyle:'position:absolute; right:0px; top:0px; z-index:1;', primebInnerStyle:'', primebInnerClass: 'prime-d-block prime-mr-1 prime-mb-1' %}

This code can be used to place the badges on the top right corner of the product images on collection pages.