Bundle group styling reference
On this page
A bundle group is one group of products in the bundle dialog, where operators choose what goes in a bundle, such as the side for a meal or the lenses for a pair of glasses. Each bundle group shows the group’s name and what to choose from it, a row of product cards, and a list of what’s been chosen. You can change the fill, corners, and inner space of bundle groups, and how many products fit across a row. Follow the POS styling API rules when you style bundle groups.
Where a bundle group appears
Bundle groups appear in the bundle dialog, which opens when an operator adds a bundle to the cart:
- Each group of the bundle’s products is a bundle group.
- The products the bundle includes are one more bundle group, headed Included.
- When a product in the bundle is a bundle too, operators build that product in a panel. The groups in that panel are bundle groups with
data-nested='true'.
Each product in a bundle group is a card, also named product-card. The bundle group price is a product price, also named bundle-group-price.
Parts
| Part | What it is | Available from |
|---|---|---|
bundle-group-root |
The whole group, with the fill and corners. | v22.0.19 |
bundle-group-header |
The group’s name and what to choose from it, or Included, with the group’s price at the end once what’s chosen adds to the price or saves something. | v22.0.19 |
bundle-group-price |
The price of what’s chosen from the group, with the full price and whether the group is complete under it. It shows once what’s chosen adds to the price or saves something, on a bundle priced by its products, and never on a group of a bundle inside another. It is a product price, so the product price properties apply to it. | v22.0.19 |
bundle-group-list |
The row of the group’s products, which scrolls sideways when the products don’t all fit. | v22.0.19 |
bundle-group-item |
One product in the row: the cell around the product’s card. The card is also named product-card, so the card properties apply to it. |
v22.0.19 |
bundle-group-selected |
The list of what’s chosen from the group, under the group’s products, shown once something is chosen. | v22.0.19 |
bundle-group-selected-heading |
How many are chosen, over that list. | v22.0.19 |
The Available from column shows the first release that carries the name.
Attributes
Narrow bundle-group-root by this, inside :where(), to style one kind of group.
| Attribute | Values | Default | Available from |
|---|---|---|---|
data-nested |
true, false |
false |
v22.0.19 |
true— a group in the panel that builds a bundle inside another bundlefalse— a group in the bundle dialog, including the Included group
Component properties
Set these on bundle-group-root. The bundle dialog sets --sc-bundle-group-padding around the groups, so a value for it on :root doesn’t reach them.
| Property | What it sets | Default | Available from |
|---|---|---|---|
--sc-bundle-group-bg-color |
The group’s fill. A group inside another bundle has none. | var(–sc-color-surface-raised) | v22.0.19 |
--sc-bundle-group-border-radius |
How round the group’s corners are. A group inside another bundle has square corners. | var(–sc-spacing-4) | v22.0.19 |
--sc-bundle-group-padding |
The space inside the group’s edges, around the header, the products, and the list of what’s chosen. The bundle dialog sets it around the groups, so set it on the group, not on :root. |
var(–sc-spacing-4) | v22.0.19 |
--sc-bundle-group-cards-sm |
How many cards fit across the row of products while the row is under 600px wide inside the group’s padding, counting the part of the last one that shows. | 2.5 | v22.0.19 |
--sc-bundle-group-cards-md |
How many cards fit across the row of products while the row is 600px to 1000px wide inside the group’s padding. | 3.5 | v22.0.19 |
--sc-bundle-group-cards-lg |
How many cards fit across the row of products while the row is 1000px wide or wider inside the group’s padding. | 4.3 | v22.0.19 |
Examples
Each example is tested against the POS on every change.
“Give each group a fill of our own.”
```css
part~=’bundle-group-root’ { –sc-bundle-group-bg-color: #f5f7fa; –sc-bundle-group-border-radius: 8px; } ```
“Give the groups more room inside.” Set it on the group, since the dialog sets it around the groups:
```css
part~=’bundle-group-root’ { –sc-bundle-group-padding: 24px; } ```
“Show more products across a wide group.”
```css
part~=’bundle-group-root’ { –sc-bundle-group-cards-lg: 5.5; } ```
“Set off a group inside another bundle.” Narrow by the attribute:
```css
border: 1px solid #d0d5dd; } ```
“Show the group prices in our brand color.”
```css
[part~=’bundle-group-price’] { color: #0b5394; } ```
“Make the count of what’s chosen stand out.”
```css
[part~=’bundle-group-selected-heading’] { color: #0b5394; } ```
What can’t be styled yet
- The Included group apart from a group to choose from
- A group while something is being chosen from it, apart from one that’s complete
- The haze over the rest of a group while a product’s panel is open, and the panel itself
- Each row in the list of what’s chosen, apart from styling the list
- The space between the products in the row, and between the rows of what’s chosen
Retired
None yet.
Was this article helpful?
Thanks for your feedback! It helps us improve our docs.