
A comprehensive product variant selection block that provides flexible display options for product options including colors, sizes, and other variants. The block supports both button-based and dropdown-based selection interfaces, with advanced features like swatches, tooltips, and unavailability indicators. It integrates with Alpine.js for interactive behavior and handles complex variant logic including availability checking and option state management.
| Setting | Description | Options |
|---|---|---|
| Show advanced settings | Reveals 6 advanced options including unavailable indication, show labels, and more | Checkbox (default: false) |
| Setting | Description | Options |
|---|---|---|
| Product | Select the product to display options for | Product picker |
| Variant selection | Controls how non-swatch variants are displayed | • Buttons (default) |
| Unavailable indication | Controls how unavailable variants are indicated | • None Visible when Show advanced settings is on |
| Show labels | Displays labels for each option | Checkbox (default: true) Visible when Show advanced settings is on |
| Show single variant options | Shows options when the product has only one variant | Checkbox (default: true) Visible when Show advanced settings is on |
| Setting | Description | Options |
|---|---|---|
| Swatch selection | Controls how swatch options (colors) are displayed | • Buttons (default) |
| Show swatch | Displays color swatches for color options | Checkbox (default: true) Visible when Show advanced settings is on |
| Show tooltip | Displays tooltips showing option names on swatch hover | Checkbox (default: true) Visible when Swatch selection is buttons and Show advanced settings is on |
| Show labels | Displays text labels with swatches | Checkbox (default: false) |
| Layout | Controls the layout of swatch and label | • Stacked |
| Size | Size of the swatch indicators | 8 - 120 px (default: 16) |
| Radius | Border radius for swatches | • None |
| Setting | Description | Options |
|---|---|---|
| Enable horizontal padding | Adds horizontal padding around the options | Checkbox (default: false) |
| Enable top padding | Adds top padding around the options | Checkbox (default: false) |
| Enable bottom padding | Adds bottom padding around the options | Checkbox (default: false) |
| Gap size | Spacing between option elements | • None |
| Setting | Description | Options |
|---|---|---|
| Text color | Controls the text color | • Default (default) |
| Button color | Color scheme for option buttons | • Primary |
| Button color selected | Color scheme for selected option buttons | • Primary |
| Setting | Description | Options |
|---|---|---|
| Font family | Controls the font family used for option labels | • Standard |
| Font size | Controls the font size of option labels | • Smaller |
| Button size | Controls the size of option buttons | • Extra small |
| Enable selected outline | Draws an outline on the selected option | Checkbox (default: true) Visible when Show advanced settings is on |
| Setting | Description | Options |
|---|---|---|
| Horizontal alignment | Controls horizontal alignment | • Left (default) |
| Enable grid layout | Uses a grid layout instead of flex wrap | Checkbox (default: false) |
| Row desktop | Number of columns in grid on desktop | 1 - 12 (default: 4) |
| Row mobile | Number of columns in grid on mobile | 1 - 3 (default: 2) |
| Setting | Description | Options |
|---|---|---|
| Visibility | Controls when the block is visible | • All (default) Visible when Show advanced settings is on |
Start by connecting your source repository and choosing the pages you want to publish.
You can then browse your documentation and ask questions about the content your team has shared.