Skip to content

Commit

Permalink
hero-unit styles
Browse files Browse the repository at this point in the history
  • Loading branch information
Adrian Miranda committed Apr 7, 2014
1 parent 9400d20 commit fb6fe23
Show file tree
Hide file tree
Showing 17 changed files with 64 additions and 10 deletions.
1 change: 1 addition & 0 deletions app/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@
this.log(chalk.green('\n ✓', chalk.white('H5BP')));
// app/
this.copy('app/404.html', 'app/404.html');
this.copy('app/images/cover.png', 'app/images/cover.png');
this.copy('app/favicon.ico', 'app/favicon.ico');
this.copy('app/ht.access', 'app/.htaccess');
this.copy('app/humans.txt', 'app/humans.txt');
Expand Down
30 changes: 20 additions & 10 deletions app/templates/_gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
'.jshintrc',
'.jscs.json'
])
.pipe($.plumber())
.pipe($.jsonlint()).pipe($.jsonlint.reporter())
.pipe($.notify({
message: '<%= options.date %> ✓ lint: <%= file.relative %>',
Expand All @@ -61,6 +62,7 @@
'!' + _.app + '/scripts/vendor/**/*.js',
'test/spec/{,*/}*.js'
])
.pipe($.plumber())
.pipe($.jshint('.jshintrc')).pipe($.jshint.reporter('default'))
.pipe($.jscs())
.pipe($.notify({
Expand All @@ -75,7 +77,8 @@
//| ✓ mocha
//'~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
gulp.task('mocha', function() {
return gulp.src('test/*.js').pipe($.mocha({ reporter: 'list' }));
return gulp.src('test/*.js').pipe($.plumber())
.pipe($.mocha({ reporter: 'list' }));
});

//|**~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand All @@ -91,7 +94,9 @@
preserveLicenseComments: true,
useStrict: true,
wrap: true
}).pipe(gulp.dest(_.dist + '/scripts')).pipe($.size()).pipe($.notify({
})
.pipe($.plumber()).pipe(gulp.dest(_.dist + '/scripts')).pipe($.size())
.pipe($.notify({
message: '<%= options.date %> ✓ require: <%= file.relative %>',
templateOptions: {
date: new Date()
Expand All @@ -106,7 +111,7 @@
return gulp.src([
_.app + '/scripts/**/*.js',
'!' + _.app + '/scripts/vendor/**/*.js'
]).pipe($.size()).pipe($.notify({
]).pipe($.plumber()).pipe($.size()).pipe($.notify({
message: '<%= options.date %> ✓ script: <%= file.relative %>',
templateOptions: {
date: new Date()
Expand All @@ -120,10 +125,11 @@
gulp.task('styles', function() {
return gulp.src(_.app + '/styles/theme.scss').pipe($.rubySass({
loadPath: [_.app + '/scripts/vendor'],
require: ['sass-css-importer'],
require: ['sass-css-importer'], // @require https://github.com/chriseppstein/sass-css-importer
style: 'expanded',
compass: false, // only work's with sass (3.2.18) or earlier
}).on('error', $.util.log))
compass: false, // @deprecated only work's with sass (3.2.18) or earlier
noCache: false
}).on('error', $.util.log)).pipe($.plumber())
.pipe($.autoprefixer('last 1 version', '> 1%', 'ie 8'))
.pipe(gulp.dest(_.app + '/styles'))
.pipe($.size())
Expand All @@ -142,7 +148,9 @@
return gulp.src([
_.app + '/images/**/*.svg',
_.app + '/styles/**/*.svg'
]).pipe($.svgmin([{ removeDoctype: false }, { removeComments: false }]))
])
.pipe($.plumber())
.pipe($.svgmin([{ removeDoctype: false }, { removeComments: false }]))
.pipe(gulp.dest(_.dist + '/images')).pipe($.size()).pipe($.notify({
message: '<%= options.date %> ✓ svg: <%= file.relative %>',
templateOptions: {
Expand All @@ -155,9 +163,10 @@
//| ✓ images
//'~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
gulp.task('images', function() {
gulp.src(_.app + '/*.{png,jpg,jpeg,gif,ico}').pipe(gulp.dest(_.dist));
return gulp.src([
_.app + '/images/**/*.{png,jpg,jpeg,gif,ico}'
]).pipe($.cache($.imagemin({
]).pipe($.plumber()).pipe($.cache($.imagemin({
optimizationLevel: 3,
progressive: true,
interlaced: true
Expand All @@ -174,7 +183,8 @@
//'~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
gulp.task('html', ['styles', 'scripts'], function() {
var js = $.filter('**/*.js'), css = $.filter('**/*.css');
return gulp.src([_.app + '/*.html'])
gulp.src(_.app + '/*.txt').pipe(gulp.dest(_.dist));
return gulp.src([_.app + '/*.html']).pipe($.plumber())
.pipe($.useref.assets())
.pipe(js)
.pipe($.uglify())
Expand Down Expand Up @@ -230,7 +240,7 @@
gulp.task('watch', ['server'], function() {
// Watch for changes in `app` dir
$.watch({ glob: [
_.app + '/*.html',
_.app + '/*.{html,txt}',
_.app + '/styles/**/*.{sass,scss}',
_.app + '/scripts/**/*.js',
_.app + '/images/**/*.{png,jpg,jpeg,gif,ico}',
Expand Down
Binary file added app/templates/app/images/cover.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
43 changes: 43 additions & 0 deletions app/templates/app/styles/theme.scss
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,46 @@
@import "states";
@import "layout";
@import "modules";

//
// hero unit
//

$titleColor:rgb(255,210,0);
$featColor:rgb(212,0,0);
@mixin centralize($top:0, $right:0, $bottom:0, $left:0, $margin:auto) {
position: absolute;
margin: #{$margin};
top: $top;
right: $right;
bottom: $bottom;
left: $left;
}
body {
width: 100%;
height: 100%;
font-family: Verdana, Helvetica, sans-serif;
background: url(../images/cover.png) 0 0 #fcfcfc;
color: #888;
}
.hero-unit {
@include centralize();
width: 350px;
height: 200px;
background-color: #fcfcfc;
border: 1px solid #eee;
text-align: center;

h1 {
color: $titleColor;
}
ul {
list-style: none;
padding: 0;
margin: 0;
}
li {
color: $featColor;
margin: 0 0 4px 0;
}
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed app/templates/app/styles/typography/ubuntu.woff
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 comments on commit fb6fe23

Please sign in to comment.