Skip to content
This repository has been archived by the owner on Jul 14, 2023. It is now read-only.

Commit

Permalink
Update grid-media documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
whmii committed Feb 17, 2017
1 parent 48e0456 commit 6b35881
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 8 deletions.
20 changes: 15 additions & 5 deletions core/neat/mixins/_grid-media.scss
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
@charset "UTF-8";
/// Creates a media query in which custom grid properties can be defined.
/// Add the `media` property to your custom grid settings map and add the media
/// you would like to scope to. If only a number is defined, it is assumed this
/// is a `min-with` value. Your custom grid can then be passed to the mixin.
/// `grid-media` allows you to change your layout based on a media query.
/// For example, an object can span 3 columns on small screens and 6 columns
/// on large screens.
///
/// You can take this a step further and set different grid attributes like
/// gutter size and total column count for each media query. So, for example,
/// you can have a `1rem` gutter on small screens, and a `2rem` gutter on large
/// screens.
///
/// @group features
///
Expand All @@ -12,7 +16,13 @@
/// The grid to be used within the scope of the block.
/// This grid should include the `media` property to determine the expression
/// for the media query.
/// By default, the global `$neat-grid` will be used.
///
/// @content
/// Grid media will temporarily the override the default grid with the
/// attributes of the custom grid. This change is scoped to within the mixin
/// block, and once the mixin has ended the default grid will revert to its
/// original state as defined by `$neat-grid`. This allows for different
/// gutter width and column count based on screen size or other properties.
///
/// @example scss
/// $custom-neat-grid: (
Expand Down
6 changes: 3 additions & 3 deletions core/neat/settings/_settings.scss
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@
$neat-grid: () !default;
/// If you would like to have multiple grids in a single project, you can do
/// If you need multiple grids in a single project, you can do
/// this by defining a new map stored within a variable of your choosing. This
/// variable can then be passed directly in to any of Neat's mixins like
/// [`grid-column(12, $my-custom-grid)`](#grid-column).
///
/// Custom grids are especially useful with [`grid-media`](#grid-media). By
/// defining a `media` attribute within your custom grid, you are able to easily
/// define both the attributes of a grid as well the breakpoint at which this
/// grid should activate.
/// define gutter width and total column count as well the breakpoint at which
/// they should activate.
///
/// @type map
///
Expand Down

0 comments on commit 6b35881

Please sign in to comment.