2.0 Beta

Smootify 2.0 is in public beta. Your 1.x store keeps working. Move when you want.

What changed

addon-swatches

One button per value or variant of the nested product as add-ons.

v2.0 beta
Open .md
On this page
  1. At a glance
  2. Where it can go
  3. What it requires
  4. Attributes on the element
  5. Attributes inside it
  6. Loading

At a glance

addon-checkbox

A Webflow Checkbox

Adds
The add-on's current variant, while checked.
Label
Stays as you write it.
No add-on
The box unchecked.
addon-select

A Select field

Adds
The variant chosen in the select.
Options
Smootify writes one per variant.
No add-on
An option you add without a value, such as "No thanks".
addon-dropdown

A Webflow Dropdown

Adds
The variant chosen in the dropdown.
Template
The first Dropdown link. show-price adds the price after each name.
No add-on
With allow-unselect, a "None" entry comes first. Without it, the first variant is chosen from the start.
addon-popover

An element with a popover

Adds
The variant chosen in the popover.
Template
The first link or button in the popover. show-price as in the dropdown.
No add-on
With allow-unselect, a "None" entry comes first. Without it, the first variant is chosen from the start.
addon-swatches

Custom elements with the tag button

Adds
The value or variant of the chosen button. It gets is-active.
Template
The first button: one per value with one option, one per variant with more.
No add-on
A click on the chosen button. allow-unselect="false" prevents it and chooses the first value.

More in the guide.

Where it can go

  • Inside smootify-add-to-cart smootify-product. A selector with a space is a chain: a b is b inside a.
  • Not inside .w-condition-invisible: a Webflow condition that hides the element takes it out.
  • Must contain button:not([popovertarget]).
  • Out of place, Smootify removes it from the page.

What it requires

Nothing beyond Smootify: it works on every plan.

Attributes on the element

Attributes inside it

GroupAttribute nameValues
Option buttonsoption14
Option metafieldoption-metafield3

Loading

Its code loads only on pages that have addon-swatches.

    ↑ ↓ to moveEnter to openEsc to close