diff --git a/.yarn/offline-mirror/@storybook-addon-actions-5.3.0.tgz b/.yarn/offline-mirror/@storybook-addon-actions-5.3.0.tgz
new file mode 100644
index 000000000000..87fa01627573
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-addon-actions-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-addons-5.3.0.tgz b/.yarn/offline-mirror/@storybook-addons-5.3.0.tgz
new file mode 100644
index 000000000000..271f16c29906
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-addons-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-api-5.3.0.tgz b/.yarn/offline-mirror/@storybook-api-5.3.0.tgz
new file mode 100644
index 000000000000..00afe7181d4a
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-api-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-channel-postmessage-5.3.0.tgz b/.yarn/offline-mirror/@storybook-channel-postmessage-5.3.0.tgz
new file mode 100644
index 000000000000..a399744f9bdc
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-channel-postmessage-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-channels-5.3.0.tgz b/.yarn/offline-mirror/@storybook-channels-5.3.0.tgz
new file mode 100644
index 000000000000..724a9b44bb65
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-channels-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-client-api-5.3.0.tgz b/.yarn/offline-mirror/@storybook-client-api-5.3.0.tgz
new file mode 100644
index 000000000000..dafdcd296d81
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-client-api-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-client-logger-5.3.0.tgz b/.yarn/offline-mirror/@storybook-client-logger-5.3.0.tgz
new file mode 100644
index 000000000000..1cddf0536ea6
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-client-logger-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-components-5.3.0.tgz b/.yarn/offline-mirror/@storybook-components-5.3.0.tgz
new file mode 100644
index 000000000000..c2118594eb03
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-components-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-core-events-5.3.0.tgz b/.yarn/offline-mirror/@storybook-core-events-5.3.0.tgz
new file mode 100644
index 000000000000..3c544a4d981c
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-core-events-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-router-5.3.0.tgz b/.yarn/offline-mirror/@storybook-router-5.3.0.tgz
new file mode 100644
index 000000000000..383d3de266ad
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-router-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/@storybook-theming-5.3.0.tgz b/.yarn/offline-mirror/@storybook-theming-5.3.0.tgz
new file mode 100644
index 000000000000..7f4c5f095784
Binary files /dev/null and b/.yarn/offline-mirror/@storybook-theming-5.3.0.tgz differ
diff --git a/.yarn/offline-mirror/schema-utils-2.6.1.tgz b/.yarn/offline-mirror/schema-utils-2.6.1.tgz
new file mode 100644
index 000000000000..734fc4252eae
Binary files /dev/null and b/.yarn/offline-mirror/schema-utils-2.6.1.tgz differ
diff --git a/packages/components/src/globals/scss/vendor/@carbon/elements/scss/grid/_inlined/_mixins.scss b/packages/components/src/globals/scss/vendor/@carbon/elements/scss/grid/_inlined/_mixins.scss
new file mode 100644
index 000000000000..044afd79301e
--- /dev/null
+++ b/packages/components/src/globals/scss/vendor/@carbon/elements/scss/grid/_inlined/_mixins.scss
@@ -0,0 +1,339 @@
+//
+// Copyright IBM Corp. 2018, 2018
+//
+// This source code is licensed under the Apache-2.0 license found in the
+// LICENSE file in the root directory of this source tree.
+//
+
+// Helpers for defining columns, rows, and containers are heavily inspired by,
+// and often derived from, bootstrap:
+// https://github.com/twbs/bootstrap/blob/v4-dev/scss/mixins/_grid.scss
+
+@import '../vendor/@carbon/layout/breakpoint';
+@import 'prefix';
+
+// -----------------------------------------------------------------------------
+// Columns
+// -----------------------------------------------------------------------------
+
+/// Used to initialize the default properties for a column class, most notably
+/// for setting width and default gutters when a column's breakpoint has not been
+/// hit yet.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter for the grid system
+/// @param {Number} $collapsed-gutter [$carbon--grid-gutter--condensed] - The condensed mode gutter
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col-ready(
+ $gutter: $carbon--grid-gutter,
+ $condensed-gutter: $carbon--grid-gutter--condensed
+) {
+ // Prevent columns from becoming too narrow when at smaller grid tiers by
+ // always setting `width: 100%;`. This works because we use `flex` values
+ // later on to override this initial width.
+ width: 100%;
+ padding-right: ($gutter / 2);
+ padding-left: ($gutter / 2);
+
+ // For our condensed use-case, our gutters collapse to 2px solid, 1px on each
+ // side.
+ .#{$prefix}--row--condensed &,
+ .#{$prefix}--grid--condensed & {
+ padding-right: ($condensed-gutter / 2);
+ padding-left: ($condensed-gutter / 2);
+ }
+}
+
+/// Define the width of the column for a given span and column count.
+/// A width of 0 will hide the column entirely.
+/// @param {Number} $span - The number of columns covered
+/// @param {Number} $columns - The total number of columns available
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col($span, $columns) {
+ @if $span == 0 {
+ display: none;
+ } @else {
+ // Explicitly include `display: block` to override
+ display: block;
+ flex: 0 0 percentage($span / $columns);
+ // Add a `max-width` to ensure content within each column does not blow out
+ // the width of the column. Applies to IE10+ and Firefox. Chrome and Safari
+ // do not appear to require this.
+ max-width: percentage($span / $columns);
+ }
+}
+
+/// Create a column offset for a given span and column count.
+/// @param {Number} $span - The number of columns the offset should cover
+/// @param {Number} $columns - The total number of columns available
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col-offset($span, $columns) {
+ $offset: $span / $columns;
+ @if $offset == 0 {
+ margin-left: 0;
+ } @else {
+ margin-left: percentage($offset);
+ }
+}
+
+/// Output the CSS required for all the columns in a given grid system.
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - The breakpoints in the grid system
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter for the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-grid-columns(
+ $breakpoints: $carbon--grid-breakpoints,
+ $gutter: $carbon--grid-gutter
+) {
+ .#{$prefix}--col {
+ @include carbon--make-col-ready();
+ }
+
+ @each $breakpoint in map-keys($breakpoints) {
+ $infix: carbon--breakpoint-infix($breakpoint);
+ $columns: map-get(map-get($breakpoints, $breakpoint), columns);
+
+ // Allow columns to stretch full width below their breakpoints
+ @for $i from 0 through $columns {
+ .#{$prefix}--col#{$infix}-#{$i} {
+ @include carbon--make-col-ready();
+ }
+ }
+
+ .#{$prefix}--col#{$infix},
+ .#{$prefix}--col#{$infix}--auto {
+ @include carbon--make-col-ready();
+ }
+
+ @include carbon--breakpoint($breakpoint, $breakpoints) {
+ // Provide basic `.col-{bp}` classes for equal-width flexbox columns
+ .#{$prefix}--col,
+ .#{$prefix}--col#{$infix} {
+ flex-basis: 0;
+ flex-grow: 1;
+ max-width: 100%;
+ }
+
+ .#{$prefix}--col--auto,
+ .#{$prefix}--col#{$infix}--auto {
+ flex: 1 0 0%;
+ width: auto;
+ // Reset earlier grid tiers
+ max-width: 100%;
+ }
+
+ @for $i from 0 through $columns {
+ .#{$prefix}--col#{$infix}-#{$i} {
+ @include carbon--make-col($i, $columns);
+ }
+ }
+
+ @for $i from 0 through ($columns - 1) {
+ @if not($infix == '') {
+ .#{$prefix}--offset#{$infix}-#{$i} {
+ @include carbon--make-col-offset($i, $columns);
+ }
+ }
+ }
+ }
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Rows
+// -----------------------------------------------------------------------------
+
+/// Define the properties for a selector assigned to a row in the grid system.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter in the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-row($gutter: $carbon--grid-gutter) {
+ display: flex;
+ flex-wrap: wrap;
+ margin-right: -1 * $gutter / 2;
+ margin-left: -1 * $gutter / 2;
+}
+
+// -----------------------------------------------------------------------------
+// No gutter
+// -----------------------------------------------------------------------------
+
+/// Add `no-gutter` and `no-gutter--{left,right}` classes to the output CSS. These
+/// classes are useful for dropping the gutter in fluid situations.
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--no-gutter {
+ .#{$prefix}--no-gutter,
+ .#{$prefix}--row.#{$prefix}--no-gutter [class*='#{$prefix}--col'] {
+ padding-left: 0;
+ padding-right: 0;
+ }
+
+ .#{$prefix}--no-gutter--left,
+ .#{$prefix}--row.#{$prefix}--no-gutter--left [class*='#{$prefix}--col'] {
+ padding-left: 0;
+ }
+
+ .#{$prefix}--no-gutter--right,
+ .#{$prefix}--row.#{$prefix}--no-gutter--right [class*='#{$prefix}--col'] {
+ padding-right: 0;
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Hang
+// -----------------------------------------------------------------------------
+
+/// Add `hang--left` and `hang--right` classes for a given gutter. These classes are
+/// used alongside `no-gutter--left` and `no-gutter--right` to "hang" type.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter in the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--hang($gutter: $carbon--grid-gutter) {
+ .#{$prefix}--hang--left {
+ padding-left: ($gutter / 2);
+ }
+
+ .#{$prefix}--hang--right {
+ padding-right: ($gutter / 2);
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Aspect ratio
+// -----------------------------------------------------------------------------
+
+/// The aspect ratios that are used to generate corresponding aspect ratio
+/// classes in code
+/// @type List
+/// @access public
+/// @group @carbon/grid
+$carbon--aspect-ratios: ((16, 9), (2, 1), (4, 3), (1, 1), (1, 2));
+
+/// Output the CSS classes for generating aspect ratio classes
+/// @param {List} $aspect-ratios [$carbon--aspect-ratios] - A list of aspect ratios to generate
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--aspect-ratio($aspect-ratios: $carbon--aspect-ratios) {
+ .#{$prefix}--aspect-ratio {
+ height: 0;
+ position: relative;
+ }
+
+ .#{$prefix}--aspect-ratio--object {
+ position: absolute;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ z-index: 100;
+ }
+
+ @each $ratio in $aspect-ratios {
+ $width: nth($ratio, 1);
+ $height: nth($ratio, 2);
+
+ .#{$prefix}--aspect-ratio--#{$width}x#{$height} {
+ padding-bottom: percentage($height / $width);
+ }
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Grid
+// -----------------------------------------------------------------------------
+
+/// Create the container for a grid. Will cause full-bleed for the grid unless
+/// max-width properties are added with `make-container-max-widths`
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-container($breakpoints: $carbon--grid-breakpoints) {
+ margin-right: auto;
+ margin-left: auto;
+
+ @include carbon--set-largest-breakpoint();
+
+ @each $name, $value in $breakpoints {
+ $prev-breakpoint: map-get($breakpoints, carbon--breakpoint-prev($name));
+ $margin: map-get($value, margin);
+
+ @if $prev-breakpoint {
+ $prev-margin: map-get($prev-breakpoint, margin);
+ @if $prev-margin != $margin {
+ @include carbon--breakpoint($name) {
+ padding-left: #{($carbon--grid-gutter / 2) + $margin};
+ padding-right: #{($carbon--grid-gutter / 2) + $margin};
+ }
+ }
+ } @else {
+ @include carbon--breakpoint($name) {
+ padding-left: #{($carbon--grid-gutter / 2) + $margin};
+ padding-right: #{($carbon--grid-gutter / 2) + $margin};
+ }
+ }
+ }
+}
+
+/// Get the last breakpoint width and set max-width to its value
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--set-largest-breakpoint($breakpoints: $carbon--grid-breakpoints) {
+ $largest-breakpoint: last-map-item($breakpoints);
+
+ max-width: map-get($largest-breakpoint, 'width');
+}
+
+/// Add in the max-widths for each breakpoint to the container
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-container-max-widths(
+ $breakpoints: $carbon--grid-breakpoints
+) {
+ @each $name, $value in $breakpoints {
+ @include carbon--breakpoint($name) {
+ max-width: map-get($value, width);
+ }
+ }
+}
+
+/// Generate the CSS for a grid for the given breakpoints and gutters
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - The default breakpoints
+/// @param {Number} $grid-gutter [$carbon--grid-gutter] - The default gutters
+/// @param {Number} $condensed-gutter [$carbon--grid-gutter--condensed] - The condensed mode gutter
+/// @access public
+/// @group @carbon/grid
+@mixin carbon--grid(
+ $breakpoints: $carbon--grid-breakpoints,
+ $grid-gutter: $carbon--grid-gutter,
+ $condensed-gutter: $carbon--grid-gutter--condensed
+) {
+ .#{$prefix}--grid {
+ @include carbon--make-container($breakpoints);
+ }
+
+ @include carbon--largest-breakpoint($breakpoints) {
+ .#{$prefix}--grid--full-width {
+ max-width: 100%;
+ }
+ }
+
+ .#{$prefix}--row {
+ @include carbon--make-row();
+ }
+
+ .#{$prefix}--grid--condensed [class*='#{$prefix}--col'] {
+ padding-top: $condensed-gutter / 2;
+ padding-bottom: $condensed-gutter / 2;
+ }
+
+ @include carbon--make-grid-columns($breakpoints, $grid-gutter);
+ @include carbon--no-gutter();
+ @include carbon--hang($grid-gutter);
+ @include carbon--aspect-ratio();
+}
diff --git a/packages/components/src/globals/scss/vendor/@carbon/elements/scss/grid/_mixins.scss b/packages/components/src/globals/scss/vendor/@carbon/elements/scss/grid/_mixins.scss
new file mode 100644
index 000000000000..b9d31e773bd6
--- /dev/null
+++ b/packages/components/src/globals/scss/vendor/@carbon/elements/scss/grid/_mixins.scss
@@ -0,0 +1,339 @@
+//
+// Copyright IBM Corp. 2018, 2018
+//
+// This source code is licensed under the Apache-2.0 license found in the
+// LICENSE file in the root directory of this source tree.
+//
+
+// Helpers for defining columns, rows, and containers are heavily inspired by,
+// and often derived from, bootstrap:
+// https://github.com/twbs/bootstrap/blob/v4-dev/scss/mixins/_grid.scss
+
+@import '../layout/breakpoint';
+@import 'prefix';
+
+// -----------------------------------------------------------------------------
+// Columns
+// -----------------------------------------------------------------------------
+
+/// Used to initialize the default properties for a column class, most notably
+/// for setting width and default gutters when a column's breakpoint has not been
+/// hit yet.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter for the grid system
+/// @param {Number} $collapsed-gutter [$carbon--grid-gutter--condensed] - The condensed mode gutter
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col-ready(
+ $gutter: $carbon--grid-gutter,
+ $condensed-gutter: $carbon--grid-gutter--condensed
+) {
+ // Prevent columns from becoming too narrow when at smaller grid tiers by
+ // always setting `width: 100%;`. This works because we use `flex` values
+ // later on to override this initial width.
+ width: 100%;
+ padding-right: ($gutter / 2);
+ padding-left: ($gutter / 2);
+
+ // For our condensed use-case, our gutters collapse to 2px solid, 1px on each
+ // side.
+ .#{$prefix}--row--condensed &,
+ .#{$prefix}--grid--condensed & {
+ padding-right: ($condensed-gutter / 2);
+ padding-left: ($condensed-gutter / 2);
+ }
+}
+
+/// Define the width of the column for a given span and column count.
+/// A width of 0 will hide the column entirely.
+/// @param {Number} $span - The number of columns covered
+/// @param {Number} $columns - The total number of columns available
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col($span, $columns) {
+ @if $span == 0 {
+ display: none;
+ } @else {
+ // Explicitly include `display: block` to override
+ display: block;
+ flex: 0 0 percentage($span / $columns);
+ // Add a `max-width` to ensure content within each column does not blow out
+ // the width of the column. Applies to IE10+ and Firefox. Chrome and Safari
+ // do not appear to require this.
+ max-width: percentage($span / $columns);
+ }
+}
+
+/// Create a column offset for a given span and column count.
+/// @param {Number} $span - The number of columns the offset should cover
+/// @param {Number} $columns - The total number of columns available
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col-offset($span, $columns) {
+ $offset: $span / $columns;
+ @if $offset == 0 {
+ margin-left: 0;
+ } @else {
+ margin-left: percentage($offset);
+ }
+}
+
+/// Output the CSS required for all the columns in a given grid system.
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - The breakpoints in the grid system
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter for the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-grid-columns(
+ $breakpoints: $carbon--grid-breakpoints,
+ $gutter: $carbon--grid-gutter
+) {
+ .#{$prefix}--col {
+ @include carbon--make-col-ready();
+ }
+
+ @each $breakpoint in map-keys($breakpoints) {
+ $infix: carbon--breakpoint-infix($breakpoint);
+ $columns: map-get(map-get($breakpoints, $breakpoint), columns);
+
+ // Allow columns to stretch full width below their breakpoints
+ @for $i from 0 through $columns {
+ .#{$prefix}--col#{$infix}-#{$i} {
+ @include carbon--make-col-ready();
+ }
+ }
+
+ .#{$prefix}--col#{$infix},
+ .#{$prefix}--col#{$infix}--auto {
+ @include carbon--make-col-ready();
+ }
+
+ @include carbon--breakpoint($breakpoint, $breakpoints) {
+ // Provide basic `.col-{bp}` classes for equal-width flexbox columns
+ .#{$prefix}--col,
+ .#{$prefix}--col#{$infix} {
+ flex-basis: 0;
+ flex-grow: 1;
+ max-width: 100%;
+ }
+
+ .#{$prefix}--col--auto,
+ .#{$prefix}--col#{$infix}--auto {
+ flex: 1 0 0%;
+ width: auto;
+ // Reset earlier grid tiers
+ max-width: 100%;
+ }
+
+ @for $i from 0 through $columns {
+ .#{$prefix}--col#{$infix}-#{$i} {
+ @include carbon--make-col($i, $columns);
+ }
+ }
+
+ @for $i from 0 through ($columns - 1) {
+ @if not($infix == '') {
+ .#{$prefix}--offset#{$infix}-#{$i} {
+ @include carbon--make-col-offset($i, $columns);
+ }
+ }
+ }
+ }
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Rows
+// -----------------------------------------------------------------------------
+
+/// Define the properties for a selector assigned to a row in the grid system.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter in the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-row($gutter: $carbon--grid-gutter) {
+ display: flex;
+ flex-wrap: wrap;
+ margin-right: -1 * $gutter / 2;
+ margin-left: -1 * $gutter / 2;
+}
+
+// -----------------------------------------------------------------------------
+// No gutter
+// -----------------------------------------------------------------------------
+
+/// Add `no-gutter` and `no-gutter--{left,right}` classes to the output CSS. These
+/// classes are useful for dropping the gutter in fluid situations.
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--no-gutter {
+ .#{$prefix}--no-gutter,
+ .#{$prefix}--row.#{$prefix}--no-gutter [class*='#{$prefix}--col'] {
+ padding-left: 0;
+ padding-right: 0;
+ }
+
+ .#{$prefix}--no-gutter--left,
+ .#{$prefix}--row.#{$prefix}--no-gutter--left [class*='#{$prefix}--col'] {
+ padding-left: 0;
+ }
+
+ .#{$prefix}--no-gutter--right,
+ .#{$prefix}--row.#{$prefix}--no-gutter--right [class*='#{$prefix}--col'] {
+ padding-right: 0;
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Hang
+// -----------------------------------------------------------------------------
+
+/// Add `hang--left` and `hang--right` classes for a given gutter. These classes are
+/// used alongside `no-gutter--left` and `no-gutter--right` to "hang" type.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter in the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--hang($gutter: $carbon--grid-gutter) {
+ .#{$prefix}--hang--left {
+ padding-left: ($gutter / 2);
+ }
+
+ .#{$prefix}--hang--right {
+ padding-right: ($gutter / 2);
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Aspect ratio
+// -----------------------------------------------------------------------------
+
+/// The aspect ratios that are used to generate corresponding aspect ratio
+/// classes in code
+/// @type List
+/// @access public
+/// @group @carbon/grid
+$carbon--aspect-ratios: ((16, 9), (2, 1), (4, 3), (1, 1), (1, 2));
+
+/// Output the CSS classes for generating aspect ratio classes
+/// @param {List} $aspect-ratios [$carbon--aspect-ratios] - A list of aspect ratios to generate
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--aspect-ratio($aspect-ratios: $carbon--aspect-ratios) {
+ .#{$prefix}--aspect-ratio {
+ height: 0;
+ position: relative;
+ }
+
+ .#{$prefix}--aspect-ratio--object {
+ position: absolute;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ z-index: 100;
+ }
+
+ @each $ratio in $aspect-ratios {
+ $width: nth($ratio, 1);
+ $height: nth($ratio, 2);
+
+ .#{$prefix}--aspect-ratio--#{$width}x#{$height} {
+ padding-bottom: percentage($height / $width);
+ }
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Grid
+// -----------------------------------------------------------------------------
+
+/// Create the container for a grid. Will cause full-bleed for the grid unless
+/// max-width properties are added with `make-container-max-widths`
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-container($breakpoints: $carbon--grid-breakpoints) {
+ margin-right: auto;
+ margin-left: auto;
+
+ @include carbon--set-largest-breakpoint();
+
+ @each $name, $value in $breakpoints {
+ $prev-breakpoint: map-get($breakpoints, carbon--breakpoint-prev($name));
+ $margin: map-get($value, margin);
+
+ @if $prev-breakpoint {
+ $prev-margin: map-get($prev-breakpoint, margin);
+ @if $prev-margin != $margin {
+ @include carbon--breakpoint($name) {
+ padding-left: #{($carbon--grid-gutter / 2) + $margin};
+ padding-right: #{($carbon--grid-gutter / 2) + $margin};
+ }
+ }
+ } @else {
+ @include carbon--breakpoint($name) {
+ padding-left: #{($carbon--grid-gutter / 2) + $margin};
+ padding-right: #{($carbon--grid-gutter / 2) + $margin};
+ }
+ }
+ }
+}
+
+/// Get the last breakpoint width and set max-width to its value
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--set-largest-breakpoint($breakpoints: $carbon--grid-breakpoints) {
+ $largest-breakpoint: last-map-item($breakpoints);
+
+ max-width: map-get($largest-breakpoint, 'width');
+}
+
+/// Add in the max-widths for each breakpoint to the container
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-container-max-widths(
+ $breakpoints: $carbon--grid-breakpoints
+) {
+ @each $name, $value in $breakpoints {
+ @include carbon--breakpoint($name) {
+ max-width: map-get($value, width);
+ }
+ }
+}
+
+/// Generate the CSS for a grid for the given breakpoints and gutters
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - The default breakpoints
+/// @param {Number} $grid-gutter [$carbon--grid-gutter] - The default gutters
+/// @param {Number} $condensed-gutter [$carbon--grid-gutter--condensed] - The condensed mode gutter
+/// @access public
+/// @group @carbon/grid
+@mixin carbon--grid(
+ $breakpoints: $carbon--grid-breakpoints,
+ $grid-gutter: $carbon--grid-gutter,
+ $condensed-gutter: $carbon--grid-gutter--condensed
+) {
+ .#{$prefix}--grid {
+ @include carbon--make-container($breakpoints);
+ }
+
+ @include carbon--largest-breakpoint($breakpoints) {
+ .#{$prefix}--grid--full-width {
+ max-width: 100%;
+ }
+ }
+
+ .#{$prefix}--row {
+ @include carbon--make-row();
+ }
+
+ .#{$prefix}--grid--condensed [class*='#{$prefix}--col'] {
+ padding-top: $condensed-gutter / 2;
+ padding-bottom: $condensed-gutter / 2;
+ }
+
+ @include carbon--make-grid-columns($breakpoints, $grid-gutter);
+ @include carbon--no-gutter();
+ @include carbon--hang($grid-gutter);
+ @include carbon--aspect-ratio();
+}
diff --git a/packages/components/src/globals/scss/vendor/@carbon/grid/scss/_inlined/_mixins.scss b/packages/components/src/globals/scss/vendor/@carbon/grid/scss/_inlined/_mixins.scss
new file mode 100644
index 000000000000..044afd79301e
--- /dev/null
+++ b/packages/components/src/globals/scss/vendor/@carbon/grid/scss/_inlined/_mixins.scss
@@ -0,0 +1,339 @@
+//
+// Copyright IBM Corp. 2018, 2018
+//
+// This source code is licensed under the Apache-2.0 license found in the
+// LICENSE file in the root directory of this source tree.
+//
+
+// Helpers for defining columns, rows, and containers are heavily inspired by,
+// and often derived from, bootstrap:
+// https://github.com/twbs/bootstrap/blob/v4-dev/scss/mixins/_grid.scss
+
+@import '../vendor/@carbon/layout/breakpoint';
+@import 'prefix';
+
+// -----------------------------------------------------------------------------
+// Columns
+// -----------------------------------------------------------------------------
+
+/// Used to initialize the default properties for a column class, most notably
+/// for setting width and default gutters when a column's breakpoint has not been
+/// hit yet.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter for the grid system
+/// @param {Number} $collapsed-gutter [$carbon--grid-gutter--condensed] - The condensed mode gutter
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col-ready(
+ $gutter: $carbon--grid-gutter,
+ $condensed-gutter: $carbon--grid-gutter--condensed
+) {
+ // Prevent columns from becoming too narrow when at smaller grid tiers by
+ // always setting `width: 100%;`. This works because we use `flex` values
+ // later on to override this initial width.
+ width: 100%;
+ padding-right: ($gutter / 2);
+ padding-left: ($gutter / 2);
+
+ // For our condensed use-case, our gutters collapse to 2px solid, 1px on each
+ // side.
+ .#{$prefix}--row--condensed &,
+ .#{$prefix}--grid--condensed & {
+ padding-right: ($condensed-gutter / 2);
+ padding-left: ($condensed-gutter / 2);
+ }
+}
+
+/// Define the width of the column for a given span and column count.
+/// A width of 0 will hide the column entirely.
+/// @param {Number} $span - The number of columns covered
+/// @param {Number} $columns - The total number of columns available
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col($span, $columns) {
+ @if $span == 0 {
+ display: none;
+ } @else {
+ // Explicitly include `display: block` to override
+ display: block;
+ flex: 0 0 percentage($span / $columns);
+ // Add a `max-width` to ensure content within each column does not blow out
+ // the width of the column. Applies to IE10+ and Firefox. Chrome and Safari
+ // do not appear to require this.
+ max-width: percentage($span / $columns);
+ }
+}
+
+/// Create a column offset for a given span and column count.
+/// @param {Number} $span - The number of columns the offset should cover
+/// @param {Number} $columns - The total number of columns available
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-col-offset($span, $columns) {
+ $offset: $span / $columns;
+ @if $offset == 0 {
+ margin-left: 0;
+ } @else {
+ margin-left: percentage($offset);
+ }
+}
+
+/// Output the CSS required for all the columns in a given grid system.
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - The breakpoints in the grid system
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter for the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-grid-columns(
+ $breakpoints: $carbon--grid-breakpoints,
+ $gutter: $carbon--grid-gutter
+) {
+ .#{$prefix}--col {
+ @include carbon--make-col-ready();
+ }
+
+ @each $breakpoint in map-keys($breakpoints) {
+ $infix: carbon--breakpoint-infix($breakpoint);
+ $columns: map-get(map-get($breakpoints, $breakpoint), columns);
+
+ // Allow columns to stretch full width below their breakpoints
+ @for $i from 0 through $columns {
+ .#{$prefix}--col#{$infix}-#{$i} {
+ @include carbon--make-col-ready();
+ }
+ }
+
+ .#{$prefix}--col#{$infix},
+ .#{$prefix}--col#{$infix}--auto {
+ @include carbon--make-col-ready();
+ }
+
+ @include carbon--breakpoint($breakpoint, $breakpoints) {
+ // Provide basic `.col-{bp}` classes for equal-width flexbox columns
+ .#{$prefix}--col,
+ .#{$prefix}--col#{$infix} {
+ flex-basis: 0;
+ flex-grow: 1;
+ max-width: 100%;
+ }
+
+ .#{$prefix}--col--auto,
+ .#{$prefix}--col#{$infix}--auto {
+ flex: 1 0 0%;
+ width: auto;
+ // Reset earlier grid tiers
+ max-width: 100%;
+ }
+
+ @for $i from 0 through $columns {
+ .#{$prefix}--col#{$infix}-#{$i} {
+ @include carbon--make-col($i, $columns);
+ }
+ }
+
+ @for $i from 0 through ($columns - 1) {
+ @if not($infix == '') {
+ .#{$prefix}--offset#{$infix}-#{$i} {
+ @include carbon--make-col-offset($i, $columns);
+ }
+ }
+ }
+ }
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Rows
+// -----------------------------------------------------------------------------
+
+/// Define the properties for a selector assigned to a row in the grid system.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter in the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-row($gutter: $carbon--grid-gutter) {
+ display: flex;
+ flex-wrap: wrap;
+ margin-right: -1 * $gutter / 2;
+ margin-left: -1 * $gutter / 2;
+}
+
+// -----------------------------------------------------------------------------
+// No gutter
+// -----------------------------------------------------------------------------
+
+/// Add `no-gutter` and `no-gutter--{left,right}` classes to the output CSS. These
+/// classes are useful for dropping the gutter in fluid situations.
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--no-gutter {
+ .#{$prefix}--no-gutter,
+ .#{$prefix}--row.#{$prefix}--no-gutter [class*='#{$prefix}--col'] {
+ padding-left: 0;
+ padding-right: 0;
+ }
+
+ .#{$prefix}--no-gutter--left,
+ .#{$prefix}--row.#{$prefix}--no-gutter--left [class*='#{$prefix}--col'] {
+ padding-left: 0;
+ }
+
+ .#{$prefix}--no-gutter--right,
+ .#{$prefix}--row.#{$prefix}--no-gutter--right [class*='#{$prefix}--col'] {
+ padding-right: 0;
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Hang
+// -----------------------------------------------------------------------------
+
+/// Add `hang--left` and `hang--right` classes for a given gutter. These classes are
+/// used alongside `no-gutter--left` and `no-gutter--right` to "hang" type.
+/// @param {Number} $gutter [$carbon--grid-gutter] - The gutter in the grid system
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--hang($gutter: $carbon--grid-gutter) {
+ .#{$prefix}--hang--left {
+ padding-left: ($gutter / 2);
+ }
+
+ .#{$prefix}--hang--right {
+ padding-right: ($gutter / 2);
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Aspect ratio
+// -----------------------------------------------------------------------------
+
+/// The aspect ratios that are used to generate corresponding aspect ratio
+/// classes in code
+/// @type List
+/// @access public
+/// @group @carbon/grid
+$carbon--aspect-ratios: ((16, 9), (2, 1), (4, 3), (1, 1), (1, 2));
+
+/// Output the CSS classes for generating aspect ratio classes
+/// @param {List} $aspect-ratios [$carbon--aspect-ratios] - A list of aspect ratios to generate
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--aspect-ratio($aspect-ratios: $carbon--aspect-ratios) {
+ .#{$prefix}--aspect-ratio {
+ height: 0;
+ position: relative;
+ }
+
+ .#{$prefix}--aspect-ratio--object {
+ position: absolute;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ z-index: 100;
+ }
+
+ @each $ratio in $aspect-ratios {
+ $width: nth($ratio, 1);
+ $height: nth($ratio, 2);
+
+ .#{$prefix}--aspect-ratio--#{$width}x#{$height} {
+ padding-bottom: percentage($height / $width);
+ }
+ }
+}
+
+// -----------------------------------------------------------------------------
+// Grid
+// -----------------------------------------------------------------------------
+
+/// Create the container for a grid. Will cause full-bleed for the grid unless
+/// max-width properties are added with `make-container-max-widths`
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-container($breakpoints: $carbon--grid-breakpoints) {
+ margin-right: auto;
+ margin-left: auto;
+
+ @include carbon--set-largest-breakpoint();
+
+ @each $name, $value in $breakpoints {
+ $prev-breakpoint: map-get($breakpoints, carbon--breakpoint-prev($name));
+ $margin: map-get($value, margin);
+
+ @if $prev-breakpoint {
+ $prev-margin: map-get($prev-breakpoint, margin);
+ @if $prev-margin != $margin {
+ @include carbon--breakpoint($name) {
+ padding-left: #{($carbon--grid-gutter / 2) + $margin};
+ padding-right: #{($carbon--grid-gutter / 2) + $margin};
+ }
+ }
+ } @else {
+ @include carbon--breakpoint($name) {
+ padding-left: #{($carbon--grid-gutter / 2) + $margin};
+ padding-right: #{($carbon--grid-gutter / 2) + $margin};
+ }
+ }
+ }
+}
+
+/// Get the last breakpoint width and set max-width to its value
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--set-largest-breakpoint($breakpoints: $carbon--grid-breakpoints) {
+ $largest-breakpoint: last-map-item($breakpoints);
+
+ max-width: map-get($largest-breakpoint, 'width');
+}
+
+/// Add in the max-widths for each breakpoint to the container
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - A map of breakpoints where the key is the name
+/// @access private
+/// @group @carbon/grid
+@mixin carbon--make-container-max-widths(
+ $breakpoints: $carbon--grid-breakpoints
+) {
+ @each $name, $value in $breakpoints {
+ @include carbon--breakpoint($name) {
+ max-width: map-get($value, width);
+ }
+ }
+}
+
+/// Generate the CSS for a grid for the given breakpoints and gutters
+/// @param {Map} $breakpoints [$carbon--grid-breakpoints] - The default breakpoints
+/// @param {Number} $grid-gutter [$carbon--grid-gutter] - The default gutters
+/// @param {Number} $condensed-gutter [$carbon--grid-gutter--condensed] - The condensed mode gutter
+/// @access public
+/// @group @carbon/grid
+@mixin carbon--grid(
+ $breakpoints: $carbon--grid-breakpoints,
+ $grid-gutter: $carbon--grid-gutter,
+ $condensed-gutter: $carbon--grid-gutter--condensed
+) {
+ .#{$prefix}--grid {
+ @include carbon--make-container($breakpoints);
+ }
+
+ @include carbon--largest-breakpoint($breakpoints) {
+ .#{$prefix}--grid--full-width {
+ max-width: 100%;
+ }
+ }
+
+ .#{$prefix}--row {
+ @include carbon--make-row();
+ }
+
+ .#{$prefix}--grid--condensed [class*='#{$prefix}--col'] {
+ padding-top: $condensed-gutter / 2;
+ padding-bottom: $condensed-gutter / 2;
+ }
+
+ @include carbon--make-grid-columns($breakpoints, $grid-gutter);
+ @include carbon--no-gutter();
+ @include carbon--hang($grid-gutter);
+ @include carbon--aspect-ratio();
+}
diff --git a/packages/grid/README.md b/packages/grid/README.md
index b6a422424d54..6d6643afd5be 100644
--- a/packages/grid/README.md
+++ b/packages/grid/README.md
@@ -20,6 +20,9 @@ yarn add @carbon/grid
## Usage
+_More examples and documentation can be found on this
+[live demo website](https://carbon-elements.netlify.com/grid/examples/preview/)._
+
`@carbon/grid` has three primitive class types to use in order to structure your
application. They include:
diff --git a/packages/react/.storybook/config.js b/packages/react/.storybook/config.js
index 25ef617dbd9b..497f5a52db04 100644
--- a/packages/react/.storybook/config.js
+++ b/packages/react/.storybook/config.js
@@ -32,6 +32,8 @@ addDecorator(
addParameters({
options: {
+ // display in alphabetic order
+ storySort: (a, b) => a[1].id.localeCompare(b[1].id),
theme: {
brandTitle: 'carbon components react',
brandUrl:
@@ -68,9 +70,4 @@ addons.getChannel().on(CARBON_TYPE_TOKEN, ({ tokenName, tokenValue }) => {
);
});
-function loadStories() {
- const req = require.context('../src/components', true, /\-story\.js$/);
- req.keys().forEach(filename => req(filename));
-}
-
-configure(loadStories, module);
+configure(require.context('../src/components', true, /\-story\.js$/), module);
diff --git a/packages/react/src/__tests__/index-test.js b/packages/react/src/__tests__/index-test.js
index d2f1062ce83a..8d0cfc639b3c 100644
--- a/packages/react/src/__tests__/index-test.js
+++ b/packages/react/src/__tests__/index-test.js
@@ -28,6 +28,7 @@ describe('Carbon Components React', () => {
"ClickableTile",
"CodeSnippet",
"CodeSnippetSkeleton",
+ "Column",
"ComboBox",
"ComposedModal",
"Content",
@@ -55,6 +56,7 @@ describe('Carbon Components React', () => {
"FormGroup",
"FormItem",
"FormLabel",
+ "Grid",
"Header",
"HeaderContainer",
"HeaderGlobalAction",
@@ -96,6 +98,7 @@ describe('Carbon Components React', () => {
"RadioButtonGroup",
"RadioButtonSkeleton",
"RadioTile",
+ "Row",
"Search",
"SearchFilterButton",
"SearchLayoutButton",
diff --git a/packages/react/src/components/Grid/Column.js b/packages/react/src/components/Grid/Column.js
new file mode 100644
index 000000000000..e9ef5d9f6104
--- /dev/null
+++ b/packages/react/src/components/Grid/Column.js
@@ -0,0 +1,159 @@
+/**
+ * Copyright IBM Corp. 2016, 2018
+ *
+ * This source code is licensed under the Apache-2.0 license found in the
+ * LICENSE file in the root directory of this source tree.
+ */
+
+import { settings } from 'carbon-components';
+import cx from 'classnames';
+import PropTypes from 'prop-types';
+import React from 'react';
+
+const { prefix } = settings;
+
+function Column({
+ as: BaseComponent = 'div',
+ children,
+ className: containerClassName,
+ sm,
+ md,
+ lg,
+ xlg,
+ max,
+ ...rest
+}) {
+ const columnClassName = getClassNameForBreakpoints([sm, md, lg, xlg, max]);
+ const className = cx(containerClassName, columnClassName, {
+ [`${prefix}--col`]: columnClassName.length === 0,
+ });
+
+ return (
+