0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-12-13 01:08:58 +01:00
Bootstrap/scss/tests/utilities/_api.test.scss
Julien Déramond 60714e32c7
Add theme maps specific to dark mode (#37843)
* Add theme maps specific to dark mode

* Fix CSS building

* Fix other failing test

Co-authored-by: Mark Otto <markdotto@gmail.com>
2023-01-11 21:06:18 -08:00

77 lines
1.4 KiB
SCSS

@import "../../functions";
@import "../../variables";
@import "../../variables-dark";
@import "../../maps";
@import "../../mixins";
$utilities: ();
@include describe("utilities/api") {
@include it("generates utilities for each breakpoints") {
$utilities: (
margin: (
property: margin,
values: auto
),
padding: (
property: padding,
responsive: true,
values: 1rem
),
font-size: (
property: font-size,
values: (large: 1.25rem),
print: true
)
) !global;
$grid-breakpoints: (
xs: 0,
sm: 576px,
md: 768px
);
@include assert() {
@include output() {
@import "../../utilities/api";
}
@include expect() {
// margin is not set to responsive
.margin-auto {
margin: auto !important;
}
// padding is, though
.padding-1rem {
padding: 1rem !important;
}
.font-size-large {
font-size: 1.25rem !important;
}
@media (min-width: 576px) {
.padding-sm-1rem {
padding: 1rem !important;
}
}
@media (min-width: 768px) {
.padding-md-1rem {
padding: 1rem !important;
}
}
@media print {
.font-size-print-large {
font-size: 1.25rem !important;
}
}
}
}
}
}