Quick amounts styling reference
On this page
Quick amounts are the suggested cash amounts on the checkout screen, which operators tap to take a payment without typing in the amount. You can change the color, corners, text size, and width of quick amounts, etc. Follow the POS styling API rules when you style quick amounts.
Where the quick amounts appear
Quick amounts appear on the cash screen at checkout when suggested amounts are turned on, in one of two forms:
- Cards: before anything is entered, rows of cards replace the numpad.
- Keys: a column of keys beside the numpad. Each key is a numpad key of the
amountkind, so style it with the numpad parts.
Parts
| Part | What it is | Available from |
|---|---|---|
quick-amounts-root |
The whole list of amounts. | v22.0.15 |
quick-amounts-row |
A row of cards, when the amounts are drawn as cards. | v22.0.15 |
quick-amounts-amount |
One amount’s card, when the amounts are drawn as cards. Drawn as keys, each amount is a numpad key. | v22.0.15 |
quick-amounts-label |
The first line of a card, such as the amount. | v22.0.15 |
quick-amounts-sublabel |
The smaller second line of a card, such as the change it returns, when it has one. | v22.0.15 |
The Available from column shows the first release that carries the name.
Attributes
Narrow quick-amounts-root by this, inside :where(), to style one way of drawing the
amounts.
| Attribute | Values | Default | Available from |
|---|---|---|---|
data-appearance |
keys, buttons |
keys |
v22.0.15 |
keys— a column of keys beside the keypad, each a numpad keybuttons— rows of cards, each with a label and, when it has one, a second line
Component properties
Set this on quick-amounts-root, or on :root.
| Property | What it sets | Default | Available from |
|---|---|---|---|
--sc-quick-amounts-width |
The narrowest an amount drawn as a key is, so short amounts line up in a column. | 140px | v22.0.15 |
Examples
Each example is tested against the POS on every change.
“Give the amount cards our brand color.”
```css
[part~=’quick-amounts-amount’] { background-color: #0b5394; color: #ffffff; } ```
“Make the cards’ corners squarer.”
```css
[part~=’quick-amounts-amount’] { border-radius: 8px; } ```
“Make the amounts on the cards bigger.”
```css
[part~=’quick-amounts-label’] { font-size: 28px; } ```
“Make the second line of a card easier to read.”
```css
[part~=’quick-amounts-sublabel’] { opacity: 1; } ```
“Make the amounts beside the keypad wider.”
```css
–sc-quick-amounts-width: 180px; } ```
What can’t be styled yet
- A card that can’t be pressed, apart from the others: a fill you set on the cards also replaces the gray a card takes while the payment is being sent
- One card on its own, such as the custom amount, since no card has a name yet
- How the cards are laid out: which row a card sits on, and how the cards share a row
- The column beside the keypad that holds the amounts over Reset, which belongs to the cash screen and has no part yet
Retired
None yet.
Was this article helpful?
Thanks for your feedback! It helps us improve our docs.