From fd17aeadeecf525a2c85fc3de1ba8e2d1ff6339b Mon Sep 17 00:00:00 2001 From: Benjamin Chiong Date: Mon, 29 Mar 2021 15:16:29 +1100 Subject: [PATCH] fix: create column logic for offset --- src/global/scss/tools/_grid.scss | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/global/scss/tools/_grid.scss b/src/global/scss/tools/_grid.scss index 0f429903..e18a75fc 100644 --- a/src/global/scss/tools/_grid.scss +++ b/src/global/scss/tools/_grid.scss @@ -99,14 +99,19 @@ @include breakpoint($breakpoint) { flex: 0 0 percentage($size / $grid-columns); max-width: percentage($size / $grid-columns); - } + + @if ($offset) { + margin-left: percentage($offset / $grid-columns); + } + } + } @else { flex: 0 0 percentage($size / $grid-columns); max-width: percentage($size / $grid-columns); - } - @if ($offset) { - margin-left: percentage($offset / $grid-columns); + @if ($offset) { + margin-left: percentage($offset / $grid-columns); + } } }