Skip to content

Commit e5d3e0b

Browse files
committed
Optimized file structure
1 parent eaa1023 commit e5d3e0b

35 files changed

Lines changed: 781 additions & 204 deletions

scss/_accordion.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@import "bootstrap/scss/accordion";

scss/_alert.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@import "bootstrap/scss/alert";

scss/_breadcrumb.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@import "bootstrap/scss/breadcrumb";

scss/_button-group.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@import "bootstrap/scss/button-group";

scss/_card.scss

Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
@import "bootstrap/scss/card";
2+
3+
// Variants
4+
// Plain card (removes borders from header and footer)
5+
.card-plain {
6+
.card-header {
7+
border-bottom: 0;
8+
padding-bottom: 0;
9+
}
10+
11+
.card-footer {
12+
border-top: 0;
13+
padding-top: 0;
14+
}
15+
}
16+
17+
// Contained card
18+
.card-contained {
19+
--#{$prefix}card-bg: #{$card-contained-bg};
20+
--#{$prefix}card-spacer-y: #{$card-contained-spacer-y};
21+
--#{$prefix}card-spacer-x: #{$card-contained-spacer-x};
22+
--#{$prefix}card-cap-padding-y: #{$card-contained-cap-padding-y};
23+
--#{$prefix}card-cap-padding-x: #{$card-contained-cap-padding-x};
24+
25+
--#{$prefix}card-padding: #{$card-contained-padding};
26+
--#{$prefix}card-body-bg: #{$card-contained-body-bg};
27+
--#{$prefix}card-body-border-color: #{$card-contained-body-border-color};
28+
29+
padding: var(--#{$prefix}card-padding);
30+
31+
> .card-img {
32+
margin-bottom: var(--#{$prefix}card-padding);
33+
}
34+
35+
> .card-header {
36+
border-bottom: 0;
37+
}
38+
39+
> .card-footer {
40+
border-top: 0;
41+
}
42+
43+
> .card-body {
44+
border-radius: calc(var(--#{$prefix}card-border-radius) - var(--#{$prefix}card-padding));
45+
border: 1px solid var(--#{$prefix}card-body-border-color);
46+
background-color: var(--#{$prefix}card-body-bg);
47+
48+
> .table-responsive {
49+
border-radius: var(--#{$prefix}card-border-radius);
50+
}
51+
52+
> .table-responsive .table,
53+
> .table {
54+
// because we want to add this on table head first child also
55+
tr:first-child {
56+
> *:first-child {
57+
border-top-left-radius: calc(var(--#{$prefix}card-border-radius) - var(--#{$prefix}card-padding));
58+
}
59+
> *:last-child {
60+
border-top-right-radius: calc(var(--#{$prefix}card-border-radius) - var(--#{$prefix}card-padding));
61+
}
62+
}
63+
64+
tbody {
65+
tr:last-child {
66+
> *:first-child {
67+
border-bottom-left-radius: calc(var(--#{$prefix}card-border-radius) - var(--#{$prefix}card-padding));
68+
}
69+
> *:last-child {
70+
border-bottom-right-radius: calc(var(--#{$prefix}card-border-radius) - var(--#{$prefix}card-padding));
71+
}
72+
td {
73+
border-bottom: 0;
74+
}
75+
}
76+
}
77+
78+
}
79+
}
80+
}
81+
82+
// Elevated card
83+
.card-elevated {
84+
--#{$prefix}card-border-width: 0;
85+
--#{$prefix}card-box-shadow: #{$card-elevated-box-shadow};
86+
}
87+
88+
// Sizes
89+
.card-sm {
90+
--#{$prefix}card-spacer-y: #{$card-sm-spacer-y};
91+
--#{$prefix}card-spacer-x: #{$card-sm-spacer-x};
92+
--#{$prefix}card-cap-padding-y: #{$card-sm-cap-padding-y};
93+
--#{$prefix}card-cap-padding-x: #{$card-sm-cap-padding-x};
94+
}

scss/_carousel.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@import "bootstrap/scss/carousel";

scss/_close.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@import "bootstrap/scss/close";

scss/_core.scss

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
@import "variables";
2+
@import "variables-dark";
3+
4+
// 3. Include remainder of required Bootstrap stylesheets (including any separate color mode stylesheets)
5+
@import "bootstrap/scss/variables";
6+
@import "bootstrap/scss/variables-dark";
7+
8+
// 4. Include any default map overrides here
9+
@import "maps";
10+
@import "mixins";
11+
12+
// 5. Include remainder of required parts
13+
@import "bootstrap/scss/maps";
14+
@import "bootstrap/scss/mixins";
15+
@import "bootstrap/scss/root";
16+
@import "root";
17+
18+
// 6. Include reboot styles for formatting the default browser behaviour
19+
@import "bootstrap/scss/reboot";
20+
@import "reboot";
21+
22+
// 7. Include any other optional stylesheet partials as desired; list below is not inclusive of all available stylesheets
23+
@import "bootstrap/scss/containers";
24+
@import "bootstrap/scss/grid";
25+
@import "bootstrap/scss/transitions";

scss/_extras.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
@import "extras/article";
2+
@import "extras/section-step";

scss/_images.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@import "bootstrap/scss/images";

0 commit comments

Comments
 (0)