Skip to content
This repository has been archived by the owner on Sep 10, 2019. It is now read-only.

Feature/css condense #460

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,10 @@ gulp.task('css', ['sass'], function() {
];
return gulp.src(dirs)
.pipe($.concat('app.css'))
.pipe($.cssCondense({
compress: false,
lineBreaks: true
}))
.pipe(gulp.dest('build/assets/css'))
;
});
Expand Down Expand Up @@ -311,6 +315,7 @@ gulp.task('deploy:dist', function(cb) {
.pipe($.rename('foundation-apps.css'))
.pipe(gulp.dest('./dist/css'))
.pipe($.minifyCss())
.pipe($.cssCondense())
.pipe($.rename('foundation-apps.min.css'))
.pipe(gulp.dest('./dist/css'));

Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
"front-matter": "^0.2.0",
"gulp": "^3.8.8",
"gulp-autoprefixer": "^1.0.1",
"gulp-css-condense": "~1.1.1",
"gulp-concat": "^2.4.1",
"gulp-connect": "^2.0.6",
"gulp-filter": "^2.0.0",
Expand Down
6 changes: 5 additions & 1 deletion scss/helpers/_breakpoints.scss
Original file line number Diff line number Diff line change
Expand Up @@ -150,5 +150,9 @@ meta.foundation-version {
font-family: "#{$foundation-version}";
}
meta.foundation-mq {
font-family: "#{map-serialize($breakpoints)}";
// Uses two sets of quotations in order to keep the double quotes for
// that would otherwise get stripped out by css-condense.
// Without double quotes, the foundation.mediaqueries.js functionality
// would break.
font-family: '"#{map-serialize($breakpoints)}"';
}