Commit a2767b54 authored by Dan Allen's avatar Dan Allen

upgrade dependencies

- upgrade dependencies
- add preview mode to build
- adding missing displayVersion properties in preview model
- exclude no-descending-specificity rule in stylelint
- fixes compatibility with Node 10
parent ee85fb5b
{
"extends": "stylelint-config-standard",
"rules": {
"comment-empty-line-before": null
"comment-empty-line-before": null,
"no-descending-specificity": null,
}
}
......@@ -27,7 +27,9 @@ gulp.task('lint', ['lint:css', 'lint:js'])
gulp.task('format', () => format(jsFiles))
gulp.task('build', () => build(srcDir, destDir))
gulp.task('build', function () {
return build(srcDir, destDir, this.seq.slice(0).some((name) => ~name.indexOf('preview')))
})
gulp.task('build:preview', ['build'], () =>
buildPreview(srcDir, destDir, previewSiteSrcDir, previewSiteDestDir, connect.reload)
......
......@@ -11,23 +11,23 @@
"node": ">= 8.0.0"
},
"devDependencies": {
"autoprefixer": "^7.1.6",
"browserify": "^14.5.0",
"autoprefixer": "^9.4.3",
"browserify": "^16.2.3",
"chokidar": "^2.0.1",
"cssnano": "^3.10.0",
"eslint": "^4.11.0",
"eslint-config-standard": "^10.2.1",
"cssnano": "^4.1.8",
"eslint": "^5.11.0",
"eslint-config-standard": "^12.0.0",
"eslint-plugin-import": "^2.8.0",
"eslint-plugin-node": "^5.2.1",
"eslint-plugin-promise": "^3.6.0",
"eslint-plugin-standard": "^3.0.1",
"eslint-plugin-node": "^8.0.0",
"eslint-plugin-promise": "^4.0.1",
"eslint-plugin-standard": "^4.0.0",
"gulp": "^3.9.1",
"gulp-concat": "^2.6.1",
"gulp-connect": "^5.2.0",
"gulp-eslint": "^4.0.0",
"gulp-imagemin": "^4.0.0",
"gulp-postcss": "^7.0.0",
"gulp-stylelint": "^5.0.0",
"gulp-eslint": "^5.0.0",
"gulp-imagemin": "^4.1.0",
"gulp-postcss": "^8.0.0",
"gulp-stylelint": "^8.0.0",
"gulp-uglify": "^3.0.0",
"gulp-vinyl-zip": "^2.1.0",
"handlebars": "^4.0.10",
......@@ -35,17 +35,17 @@
"js-yaml": "^3.10.0",
"map-stream": "^0.0.7",
"merge-stream": "^1.0.1",
"postcss-calc": "^6.0.1",
"postcss-custom-properties": "^6.1.0",
"postcss-import": "^11.0.0",
"postcss-url": "^7.1.2",
"postcss-calc": "^7.0.1",
"postcss-custom-properties": "^8.0.9",
"postcss-import": "^12.0.1",
"postcss-url": "^8.0.0",
"prettier-eslint": "^8.2.0",
"require-from-string": "^2.0.1",
"stylelint": "^8.2.0",
"stylelint-config-standard": "^17.0.0",
"typeface-roboto": "^0.0.45",
"typeface-roboto-mono": "^0.0.44",
"stylelint": "^9.9.0",
"stylelint-config-standard": "^18.2.0",
"typeface-roboto": "^0.0.54",
"typeface-roboto-mono": "^0.0.54",
"vinyl-buffer": "^1.0.0",
"vinyl-fs": "^2.4.4"
"vinyl-fs": "^3.0.3"
}
}
......@@ -10,8 +10,10 @@ site:
- &latest_version_abc
url: '#'
version: '1.1'
displayVersion: '1.1'
- url: '#'
version: '1.0'
displayVersion: '1.0'
latestVersion: *latest_version_abc
- &component
name: xyz
......@@ -21,13 +23,17 @@ site:
- &latest_version_xyz
url: /xyz/6.0/index.html
version: '6.0'
displayVersion: '6.0'
- &component_version
url: '#'
version: '5.2'
displayVersion: '5.2'
- url: '#'
version: '5.1'
displayVersion: '5.1'
- url: '#'
version: '5.0'
displayVersion: '5.0'
latestVersion: *latest_version_xyz
- name: 123
title: Project 123
......@@ -36,10 +42,13 @@ site:
- &latest_version_123
url: '#'
version: '2.2'
displayVersion: '2.2'
- url: '#'
version: '2.1'
displayVersion: '2.1'
- url: '#'
version: '2.0'
displayVersion: '2.0'
latestVersion: *latest_version_123
page:
title: Brand’s Hardware & Software Requirements
......@@ -47,6 +56,7 @@ page:
component: *component
componentVersion: *component_version
version: '5.2'
displayVersion: '5.2'
module: ROOT
home: false
editUrl: http://example.com/project-xyz/blob/master/index.adoc
......@@ -59,12 +69,16 @@ page:
urlType: internal
versions:
- version: '6.0'
displayVersion: '6.0'
url: '#'
- version: '5.2'
displayVersion: '5.2'
url: '#'
- version: '5.1'
displayVersion: '5.1'
url: '#'
- version: '5.0'
displayVersion: '5.0'
missing: true
url: '#'
navigation:
......
......@@ -7,10 +7,7 @@ html.is-clipped--nav {
overflow-y: auto;
display: flex;
flex-direction: column;
}
/* help Chrome calculate the height correctly; must match .navigation value minus height of drawer */
.navigation-menu {
/* help Chrome calculate the height correctly; must match .navigation value minus height of drawer */
height: calc(100vh - var(--navbar-height) - var(--toolbar-height) - var(--drawer-height));
}
......
......@@ -19,7 +19,7 @@ const postcssVar = require('postcss-custom-properties')
const uglify = require('gulp-uglify')
const vfs = require('vinyl-fs')
module.exports = (src, dest) => {
module.exports = (src, dest, preview) => {
const opts = { base: src, cwd: src }
const postcssPlugins = [
postcssImport(),
......@@ -42,10 +42,10 @@ module.exports = (src, dest) => {
},
},
]),
postcssVar(),
postcssVar({ preserve: preview ? 'preserve-computed' : false }),
postcssCalc(),
autoprefixer({ browsers: ['last 2 versions'] }),
cssnano({ preset: 'default' }),
preview ? () => {} : cssnano({ preset: 'default' }),
]
return merge([
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment