Skip to main content
The collections placement adds a save/unsave toggle to each product card in your collection grids. When a customer taps the button, Swish handles variant selection, list assignment, and feedback automatically based on your intent settings. By default, Swish places save buttons on product cards through the app embed. You can customize their position and appearance using the placement API.

Setup

Target your product card selector and use an overlay layout to float the button on top of the card image.
The target.selector matches every element on the page, including cards added dynamically by infinite scroll or quick view modals.

Styling

Pass design tokens under design to match the button to your card style.
Design tokens support responsive breakpoints. The default breakpoints are sm at 500px and lg at 700px.

Show on hover

A common pattern is to hide the save button until the customer hovers over the card. Use the css property to achieve this:

Container wrapper

Wrap the button in a custom container for easier styling or layout control:

Advanced mounting

If the save button needs to sit inside a specific child element of the card, use mount.at to resolve a different element:
See the placements overview for the full list of mount.at options.

Further reading