Skip to content

Commit

Permalink
Fix u-sizeFit overriding responsive versions
Browse files Browse the repository at this point in the history
Fixes #39
  • Loading branch information
simonsmith committed Nov 7, 2017
1 parent d501662 commit 5a9b506
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 0 deletions.
1 change: 1 addition & 0 deletions lib/size-lg.css
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@

.u-lg-sizeFit {
flex-basis: auto !important;
width: auto !important;
}

/**
Expand Down
1 change: 1 addition & 0 deletions lib/size-md.css
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,7 @@

.u-md-sizeFit {
flex-basis: auto !important;
width: auto !important;
}

/**
Expand Down
1 change: 1 addition & 0 deletions lib/size-sm.css
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@

.u-sm-sizeFit {
flex-basis: auto !important;
width: auto !important;
}

/**
Expand Down
24 changes: 24 additions & 0 deletions test/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,30 @@ <h3 class="Test-it">shrink-wraps (on left) / fills remaining space</h3>
</div>
</div>

<h2 class="Test-describe">.u-[size]-sizeFit</h2>
<h3 class="Test-it">overrides u-sizeFit correctly</h3>
<div class="Test-run">
<div class="u-flex">
<div class="u-size1of2 u-sm-sizeFit u-highlight">
should sizeFit at sm-viewport
</div>
</div>
</div>
<div class="Test-run">
<div class="u-flex">
<div class="u-size1of2 u-md-sizeFit u-highlight">
should sizeFit at md-viewport
</div>
</div>
</div>
<div class="Test-run">
<div class="u-flex">
<div class="u-size1of2 u-lg-sizeFit u-highlight">
should sizeFit at lg-viewport
</div>
</div>
</div>

<h2 class="Test-describe">.u-sizeFill</h2>
<h3 class="Test-it">distributes space evenly</h3>
<div class="Test-run" style="margin-bottom: 15px">
Expand Down

0 comments on commit 5a9b506

Please sign in to comment.