Skip to content

Commit b394418

Browse files
authored
Merge pull request #3630 from aforcada/join-radius
fix: #3611 join border radius when used with a single item
2 parents c0de73d + 88c048a commit b394418

File tree

1 file changed

+48
-0
lines changed

1 file changed

+48
-0
lines changed

packages/daisyui/src/utilities/join.css

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,22 @@
4949
--join-ee: var(--radius-field);
5050
}
5151
}
52+
53+
> .join-item:where(:only-child) {
54+
--join-ss: var(--radius-field);
55+
--join-se: var(--radius-field);
56+
--join-es: var(--radius-field);
57+
--join-ee: var(--radius-field);
58+
}
59+
60+
:only-child {
61+
:where(.join-item) {
62+
--join-ss: var(--radius-field);
63+
--join-se: var(--radius-field);
64+
--join-es: var(--radius-field);
65+
--join-ee: var(--radius-field);
66+
}
67+
}
5268
}
5369

5470
.join-item {
@@ -93,6 +109,22 @@
93109
}
94110
}
95111

112+
> .join-item:only-child {
113+
--join-ss: var(--radius-field);
114+
--join-se: var(--radius-field);
115+
--join-es: var(--radius-field);
116+
--join-ee: var(--radius-field);
117+
}
118+
119+
:only-child {
120+
.join-item {
121+
--join-ss: var(--radius-field);
122+
--join-se: var(--radius-field);
123+
--join-es: var(--radius-field);
124+
--join-ee: var(--radius-field);
125+
}
126+
}
127+
96128
.join-item {
97129
&:where(*:not(:first-child)) {
98130
margin-inline-start: 0;
@@ -136,6 +168,22 @@
136168
}
137169
}
138170

171+
> .join-item:only-child {
172+
--join-ss: var(--radius-field);
173+
--join-se: var(--radius-field);
174+
--join-es: var(--radius-field);
175+
--join-ee: var(--radius-field);
176+
}
177+
178+
:only-child {
179+
.join-item {
180+
--join-ss: var(--radius-field);
181+
--join-se: var(--radius-field);
182+
--join-es: var(--radius-field);
183+
--join-ee: var(--radius-field);
184+
}
185+
}
186+
139187
.join-item {
140188
&:where(*:not(:first-child)) {
141189
margin-inline-start: calc(var(--border, 1px) * -1);

0 commit comments

Comments
 (0)