Skip to content

Commit f395cc4

Browse files
MichaelAllenWarnerMichael Warner
and
Michael Warner
authored
add caption-side utilities (#10470)
Co-authored-by: Michael Warner <[email protected]>
1 parent 8bd2846 commit f395cc4

7 files changed

+35
-0
lines changed

src/corePlugins.js

+7
Original file line numberDiff line numberDiff line change
@@ -772,6 +772,13 @@ export let corePlugins = {
772772
})
773773
},
774774

775+
captionSide: ({ addUtilities }) => {
776+
addUtilities({
777+
'.caption-top': { 'caption-side': 'top' },
778+
'.caption-bottom': { 'caption-side': 'bottom' },
779+
})
780+
},
781+
775782
borderCollapse: ({ addUtilities }) => {
776783
addUtilities({
777784
'.border-collapse': { 'border-collapse': 'collapse' },

tests/basic-usage.oxide.test.css

+6
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,12 @@
252252
.table-fixed {
253253
table-layout: fixed;
254254
}
255+
.caption-top {
256+
caption-side: top;
257+
}
258+
.caption-bottom {
259+
caption-side: bottom;
260+
}
255261
.border-collapse {
256262
border-collapse: collapse;
257263
}

tests/basic-usage.test.css

+6
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,12 @@
252252
.table-fixed {
253253
table-layout: fixed;
254254
}
255+
.caption-top {
256+
caption-side: top;
257+
}
258+
.caption-bottom {
259+
caption-side: bottom;
260+
}
255261
.border-collapse {
256262
border-collapse: collapse;
257263
}

tests/basic-usage.test.js

+2
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,8 @@ crosscheck(({ stable, oxide }) => {
161161
<div class="stroke-current"></div>
162162
<div class="stroke-2"></div>
163163
<div class="table-fixed"></div>
164+
<div class="caption-top"></div>
165+
<div class="caption-bottom"></div>
164166
<div class="text-center"></div>
165167
<div class="indent-6 -indent-12"></div>
166168
<div class="text-indigo-500"></div>

tests/raw-content.oxide.test.css

+6
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,12 @@
179179
.table-fixed {
180180
table-layout: fixed;
181181
}
182+
.caption-top {
183+
caption-side: top;
184+
}
185+
.caption-bottom {
186+
caption-side: bottom;
187+
}
182188
.border-collapse {
183189
border-collapse: collapse;
184190
}

tests/raw-content.test.css

+6
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,12 @@
179179
.table-fixed {
180180
table-layout: fixed;
181181
}
182+
.caption-top {
183+
caption-side: top;
184+
}
185+
.caption-bottom {
186+
caption-side: bottom;
187+
}
182188
.border-collapse {
183189
border-collapse: collapse;
184190
}

tests/raw-content.test.js

+2
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,8 @@ crosscheck(({ stable, oxide }) => {
123123
<div class="stroke-current"></div>
124124
<div class="stroke-2"></div>
125125
<div class="table-fixed"></div>
126+
<div class="caption-top"></div>
127+
<div class="caption-bottom"></div>
126128
<div class="text-center"></div>
127129
<div class="text-indigo-500"></div>
128130
<div class="underline"></div>

0 commit comments

Comments
 (0)