Skip to content

Commit c4370dd

Browse files
committed
Refactor(web): Leverage custom properties for Container padding to make it easily accessible
1 parent 05547e9 commit c4370dd

File tree

4 files changed

+3
-15
lines changed

4 files changed

+3
-15
lines changed

packages/web/src/scss/components/Container/_Container.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
width: 100%;
66
max-width: theme.$container-max-width;
77
margin-inline: auto;
8+
padding-inline: var(--container-padding-inline);
89

910
@include tools.paddings(theme.$container-paddings, theme.$container-breakpoints);
1011
}

packages/web/src/scss/components/Container/_tools.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
@mixin paddings($paddings, $breakpoints) {
66
@each $name, $breakpoint in $breakpoints {
77
@include breakpoint.up($breakpoint) {
8-
padding-inline: map.get($paddings, $name);
8+
--container-padding-inline: #{map.get($paddings, $name)};
99
}
1010
}
1111
}
Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
@use '../tools/breakout';
2-
31
.breakout-container {
4-
@include breakout.container();
2+
margin-inline: calc(-1 * var(--container-padding-inline));
53
}

packages/web/src/scss/tools/_breakout.scss

Lines changed: 0 additions & 11 deletions
This file was deleted.

0 commit comments

Comments
 (0)