From cde26a523402bd0ae7c7996805dc5e6597823359 Mon Sep 17 00:00:00 2001 From: Mark Otto Date: Tue, 16 Feb 2016 20:21:27 -0800 Subject: [PATCH 1/2] Fixes #19221: Add .w-100 as width: 100% utility class --- scss/utilities/_spacing.scss | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scss/utilities/_spacing.scss b/scss/utilities/_spacing.scss index cd543c8c90..b7ff044b6d 100644 --- a/scss/utilities/_spacing.scss +++ b/scss/utilities/_spacing.scss @@ -1,3 +1,7 @@ +// Width + +.w-100 { width: 100% !important; } + // Margin and Padding .m-x-auto { From 3165835a1bcfcc3b2046d883bf90e21ab3784c76 Mon Sep 17 00:00:00 2001 From: Chris Rebert Date: Wed, 6 Apr 2016 15:06:23 -0700 Subject: [PATCH 2/2] Add docs for .w-100 utility class [skip sauce] --- docs/components/utilities.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/components/utilities.md b/docs/components/utilities.md index 76bf5f9bed..829ee49078 100644 --- a/docs/components/utilities.md +++ b/docs/components/utilities.md @@ -165,6 +165,14 @@ Sometimes contextual classes cannot be applied due to the specificity of another {% capture callout-include %}{% include callout-warning-color-assistive-technologies.md %}{% endcapture %} {{ callout-include | markdownify }} +## Widths + +Easily make an element as wide as its parent using the `.w-100` utility class, which sets `width: 100%`. + +{% example html %} +Width = 100% +{% endexample %} + ## Close icon Use a generic close icon for dismissing content like modals and alerts. **Be sure to include text for screen readers**, as we've done with `aria-label`.