Skip to content

Commit

Permalink
Basic layout using CSS Grid Layout
Browse files Browse the repository at this point in the history
Closes #7
  • Loading branch information
amiuhle committed Jun 19, 2017
1 parent 340537d commit f6f6854
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 7 deletions.
11 changes: 5 additions & 6 deletions src/components/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@ import React from 'react'

export default (props) => {
return (
<div className='App'>
<header>
<h1>Kasisto</h1>
</header>
<section />
<footer />
<div className='o-app'>
<h1 className='o-app__header u-margin-none'>Kasisto</h1>
<aside className='o-app__nav' />
<section className='o-app__content' />
<footer className='o-app__footer' />
</div>
)
}
32 changes: 32 additions & 0 deletions src/styles/_objects.app.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
// #APP
/*
* App layout using CSS Grid Layout
*/

.o-app {
height: 100vh;
display: grid;
grid-gap: $base-spacing-unit;
grid-template-rows: $double-spacing-unit 1fr $double-spacing-unit;
grid-template-columns: $double-spacing-unit 1fr;
grid-template-areas:
'nav header'
'content content'
'footer footer';
}

.o-app__header {
grid-area: header;
}

.o-app__nav {
grid-area: nav;
}

.o-app__content {
grid-area: content;
}

.o-app__footer {
grid-area: footer;
}
Empty file removed src/styles/_objects.layout.scss
Empty file.
2 changes: 2 additions & 0 deletions src/styles/_tools.aliases.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
$base-spacing-unit: $inuit-global-spacing-unit;
$double-spacing-unit: $inuit-global-spacing-unit-large;
3 changes: 2 additions & 1 deletion src/styles/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@
@import 'elements.headings';

// OBJECTS
@import 'objects.layout';
@import 'objects.app';

// COMPONENTS

// UTILITIES
@import '~inuitcss/utilities/utilities.spacings';

0 comments on commit f6f6854

Please sign in to comment.