Created
February 10, 2017 15:38
-
-
Save jberndsen/7c0aa0c490cb067275028c1872d45146 to your computer and use it in GitHub Desktop.
Quick ITCSS startup structure for Angular 2 / Material Design
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import '../settings/_colours.scss'; | |
@import '../settings/_typography.scss'; | |
body { | |
width: 100%; | |
height: 100%; | |
min-height: 100vh; | |
background-color: md-color($vir-app-ui, 50); | |
font-family: $font-stack; | |
font-weight: 400; | |
font-style: normal; | |
font-variant: normal; | |
color: black; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import '~@angular/material/core/theming/theming'; | |
@import './theme'; | |
// For styling your custom components using the general theme colours, | |
// look at https://github.com/angular/material2/blob/master/guides/theming-your-components.md | |
$primary-color: md-color(map-get($app-theme, primary)); | |
$accent-color: md-color(map-get($app-theme, accent)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* { | |
-webkit-box-sizing: border-box; | |
-moz-box-sizing: border-box; | |
box-sizing: border-box; | |
min-width: 0; | |
min-height: 0; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import '~@angular/material/core/theming/theming'; | |
@import '~@angular/material/core/theming/palette'; | |
// define our theme colours | |
$app-primary: md-palette($md-grey); | |
$app-accent: md-palette($md-blue); | |
$app-ui: md-palette($md-grey); | |
// Create the theme object (a Sass map containing all of the palettes). | |
$app-theme: md-light-theme($app-primary, $app-accent); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import '~@angular/material/core/theming/all-theme'; | |
@import '../settings/theme'; | |
// Include the base styles for Angular Material core. We include this here so that you only | |
// have to load a single css file for Angular Material in your app. | |
@include md-core(); | |
// Include theme styles for core and each component used in your app. | |
// Alternatively, you can import and @include the theme mixins for each component | |
// that you are using. | |
@include angular-material-theme($app-theme); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$font-stack: 'Roboto', 'Helvetica Neue', Verdana, Helvetiva, sans-serif; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Provides styling helpers and methods for more specific layers, e.g. Components likely want to import this */ | |
// Settings | |
@import "settings/colours"; | |
@import "settings/typography"; | |
@import "settings/theme"; | |
// Tools | |
@import "tools/flexbox"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Styles that should be applied globally go here. Remember to add to styles in agular-cli.json */ | |
// Generic | |
@import "~normalize.css/normalize.css"; | |
@import "generic/theming"; | |
// Elements | |
@import "elements/star"; | |
@import "elements/body"; | |
// Objects |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment