Skip to content

Commit

Permalink
Improve compatibility of the ButtonGroup with the Modal component (#2349
Browse files Browse the repository at this point in the history
)
  • Loading branch information
connor-baer authored Dec 19, 2023
1 parent 31b7b64 commit dbceca6
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
5 changes: 5 additions & 0 deletions .changeset/tame-camels-argue.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@sumup/circuit-ui': patch
---

Reduced the container width at which the ButtonGroup component switches to a horizontal layout to improve compatibility with the Modal component.
2 changes: 1 addition & 1 deletion packages/circuit-ui/components/Button/base.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@
}
}

@container cui-button-group (width > 480px) {
@container cui-button-group (width > 420px) {
/* Keep in sync with the .secondary class above */
.tertiary {
color: var(--cui-fg-normal);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@
align-items: center;
}

.secondary {
.base .secondary {
margin-top: var(--cui-spacings-kilo);
}

@container cui-button-group (width > 480px) {
@container cui-button-group (width > 420px) {
.base {
flex-direction: row-reverse;
}
Expand All @@ -30,7 +30,7 @@
justify-content: flex-start;
}

.secondary {
.base .secondary {
margin-top: 0;
margin-right: var(--cui-spacings-mega);
}
Expand Down

0 comments on commit dbceca6

Please sign in to comment.