diff --git a/Gulpfile.js b/Gulpfile.js index c5cc36c6d..278199504 100644 --- a/Gulpfile.js +++ b/Gulpfile.js @@ -1,5 +1,6 @@ // Require our dependencies const autoprefixer = require( 'autoprefixer' ); +const babel = require( 'gulp-babel' ); const bourbon = require( 'bourbon' ).includePaths; const browserSync = require( 'browser-sync' ); const cheerio = require( 'gulp-cheerio' ); @@ -43,7 +44,7 @@ const paths = { * Handle errors and alert the user. */ function handleErrors () { - var args = Array.prototype.slice.call( arguments ); + const args = Array.prototype.slice.call( arguments ); notify.onError( { 'title': 'Task Failed [<%= error.message %>', @@ -51,18 +52,18 @@ function handleErrors () { 'sound': 'Sosumi' // See: https://github.com/mikaelbr/node-notifier#all-notification-options-with-their-defaults } ).apply( this, args ); - gutil.beep(); // Beep 'sosumi' again + gutil.beep(); // Beep 'sosumi' again. - // Prevent the 'watch' task from stopping + // Prevent the 'watch' task from stopping. this.emit( 'end' ); } /** * Delete style.css and style.min.css before we minify and optimize */ -gulp.task( 'clean:styles', function () { - return del( [ 'style.css', 'style.min.css' ] ); -} ); +gulp.task( 'clean:styles', () => + del( [ 'style.css', 'style.min.css' ] ) +); /** * Compile Sass and run stylesheet through PostCSS. @@ -72,62 +73,62 @@ gulp.task( 'clean:styles', function () { * https://www.npmjs.com/package/gulp-autoprefixer * https://www.npmjs.com/package/css-mqpacker */ -gulp.task( 'postcss', [ 'clean:styles' ], function () { - return gulp.src( 'assets/sass/*.scss', paths.css ) +gulp.task( 'postcss', [ 'clean:styles' ], () => + gulp.src( 'assets/sass/*.scss', paths.css ) - // Deal with errors. - .pipe( plumber( {'errorHandler': handleErrors} ) ) + // Deal with errors. + .pipe( plumber( {'errorHandler': handleErrors} ) ) - // Wrap tasks in a sourcemap. - .pipe( sourcemaps.init() ) + // Wrap tasks in a sourcemap. + .pipe( sourcemaps.init() ) - // Compile Sass using LibSass. - .pipe( sass( { - 'includePaths': [].concat( bourbon, neat ), - 'errLogToConsole': true, - 'outputStyle': 'expanded' // Options: nested, expanded, compact, compressed - } ) ) + // Compile Sass using LibSass. + .pipe( sass( { + 'includePaths': [].concat( bourbon, neat ), + 'errLogToConsole': true, + 'outputStyle': 'expanded' // Options: nested, expanded, compact, compressed + } ) ) - // Parse with PostCSS plugins. - .pipe( postcss( [ - autoprefixer( { - 'browsers': [ 'last 2 version' ] - } ), - mqpacker( { - 'sort': true - } ) - ] ) ) - - // Create sourcemap. - .pipe( sourcemaps.write() ) - - // Create style.css. - .pipe( gulp.dest( './' ) ) - .pipe( browserSync.stream() ); -} ); + // Parse with PostCSS plugins. + .pipe( postcss( [ + autoprefixer( { + 'browsers': [ 'last 2 version' ] + } ), + mqpacker( { + 'sort': true + } ) + ] ) ) + + // Create sourcemap. + .pipe( sourcemaps.write() ) + + // Create style.css. + .pipe( gulp.dest( './' ) ) + .pipe( browserSync.stream() ) +); /** * Minify and optimize style.css. * * https://www.npmjs.com/package/gulp-cssnano */ -gulp.task( 'cssnano', [ 'postcss' ], function () { - return gulp.src( 'style.css' ) - .pipe( plumber( {'errorHandler': handleErrors} ) ) - .pipe( cssnano( { - 'safe': true // Use safe optimizations - } ) ) - .pipe( rename( 'style.min.css' ) ) - .pipe( gulp.dest( './' ) ) - .pipe( browserSync.stream() ); -} ); +gulp.task( 'cssnano', [ 'postcss' ], () => + gulp.src( 'style.css' ) + .pipe( plumber( {'errorHandler': handleErrors} ) ) + .pipe( cssnano( { + 'safe': true // Use safe optimizations. + } ) ) + .pipe( rename( 'style.min.css' ) ) + .pipe( gulp.dest( './' ) ) + .pipe( browserSync.stream() ) +); /** * Delete the svg-icons.svg before we minify, concat. */ -gulp.task( 'clean:icons', function () { - return del( [ 'assets/images/svg-icons.svg' ] ); -} ); +gulp.task( 'clean:icons', () => + del( [ 'assets/images/svg-icons.svg' ] ) +); /** * Minify, concatenate, and clean SVG icons. @@ -136,45 +137,57 @@ gulp.task( 'clean:icons', function () { * https://www.npmjs.com/package/gulp-svgstore * https://www.npmjs.com/package/gulp-cheerio */ -gulp.task( 'svg', [ 'clean:icons' ], function () { - return gulp.src( paths.icons ) - .pipe( plumber( {'errorHandler': handleErrors} ) ) - .pipe( svgmin() ) - .pipe( rename( {'prefix': 'icon-'} ) ) - .pipe( svgstore( {'inlineSvg': true} ) ) - .pipe( cheerio( { - 'run': function ( $, file ) { - $( 'svg' ).attr( 'style', 'display:none' ); - $( '[fill]' ).removeAttr( 'fill' ); - $( 'path' ).removeAttr( 'class' ); - }, - 'parserOptions': {'xmlMode': true} - } ) ) - .pipe( gulp.dest( 'assets/images/' ) ) - .pipe( browserSync.stream() ); -} ); +gulp.task( 'svg', [ 'clean:icons' ], () => + gulp.src( paths.icons ) + + // Deal with errors. + .pipe( plumber( {'errorHandler': handleErrors} ) ) + + // Minify SVGs. + .pipe( svgmin() ) + + // Add a prefix to SVG IDs. + .pipe( rename( {'prefix': 'icon-'} ) ) + + // Combine all SVGs into a single + .pipe( svgstore( {'inlineSvg': true} ) ) + + // Clean up the by removing the following cruft... + .pipe( cheerio( { + 'run': function ( $, file ) { + $( 'svg' ).attr( 'style', 'display:none' ); + $( '[fill]' ).removeAttr( 'fill' ); + $( 'path' ).removeAttr( 'class' ); + }, + 'parserOptions': {'xmlMode': true} + } ) ) + + // Save svg-icons.svg. + .pipe( gulp.dest( 'assets/images/' ) ) + .pipe( browserSync.stream() ) +); /** * Optimize images. * * https://www.npmjs.com/package/gulp-imagemin */ -gulp.task( 'imagemin', function () { - return gulp.src( paths.images ) - .pipe( plumber( {'errorHandler': handleErrors} ) ) - .pipe( imagemin( { - 'optimizationLevel': 5, - 'progressive': true, - 'interlaced': true - } ) ) - .pipe( gulp.dest( 'assets/images' ) ); -} ); +gulp.task( 'imagemin', () => + gulp.src( paths.images ) + .pipe( plumber( {'errorHandler': handleErrors} ) ) + .pipe( imagemin( { + 'optimizationLevel': 5, + 'progressive': true, + 'interlaced': true + } ) ) + .pipe( gulp.dest( 'assets/images' ) ) +); /** * Delete the sprites.png before rebuilding sprite. */ -gulp.task( 'clean:sprites', function () { - return del( [ 'assets/images/sprites.png' ] ); +gulp.task( 'clean:sprites', () => { + del( [ 'assets/images/sprites.png' ] ) } ); /** @@ -182,97 +195,118 @@ gulp.task( 'clean:sprites', function () { * * https://www.npmjs.com/package/gulp.spritesmith */ -gulp.task( 'spritesmith', [ 'clean:sprites' ], function () { - return gulp.src( paths.sprites ) - .pipe( plumber( {'errorHandler': handleErrors} ) ) - .pipe( spritesmith( { - 'imgName': 'sprites.png', - 'cssName': '../../assets/sass/base/_sprites.scss', - 'imgPath': 'assets/images/sprites.png', - 'algorithm': 'binary-tree' - } ) ) - .pipe( gulp.dest( 'assets/images/' ) ) - .pipe( browserSync.stream() ); -} ); +gulp.task( 'spritesmith', [ 'clean:sprites' ], () => + gulp.src( paths.sprites ) + .pipe( plumber( {'errorHandler': handleErrors} ) ) + .pipe( spritesmith( { + 'imgName': 'sprites.png', + 'cssName': '../../assets/sass/base/_sprites.scss', + 'imgPath': 'assets/images/sprites.png', + 'algorithm': 'binary-tree' + } ) ) + .pipe( gulp.dest( 'assets/images/' ) ) + .pipe( browserSync.stream() ) +); /** - * Concatenate javascript files into one. + * Concatenate and transform JavaScript. + * * https://www.npmjs.com/package/gulp-concat + * https://github.com/babel/gulp-babel + * https://www.npmjs.com/package/gulp-sourcemaps */ -gulp.task( 'concat', function () { - return gulp.src( paths.concat_scripts ) - .pipe( plumber( {'errorHandler': handleErrors} ) ) - .pipe( sourcemaps.init() ) - .pipe( concat( 'project.js' ) ) - .pipe( sourcemaps.write() ) - .pipe( gulp.dest( 'assets/scripts' ) ) - .pipe( browserSync.stream() ); -} ); +gulp.task( 'concat', () => + gulp.src( paths.concat_scripts ) + + // Deal with errors. + .pipe( plumber( + {'errorHandler': handleErrors} + ) ) + + // Start a sourcemap. + .pipe( sourcemaps.init() ) + + // Convert ES6+ to ES2015. + .pipe( babel( { + presets: [ 'es2015' ] + } ) ) + + // Concatenate partials into a single script. + .pipe( concat( 'project.js' ) ) + + // Append the sourcemap to project.js. + .pipe( sourcemaps.write() ) - /** - * Minify compiled javascript after concatenated. + // Save project.js + .pipe( gulp.dest( 'assets/scripts' ) ) + .pipe( browserSync.stream() ) +); + +/** + * Minify compiled JavaScript. + * * https://www.npmjs.com/package/gulp-uglify */ -gulp.task( 'uglify', [ 'concat' ], function () { - return gulp.src( paths.scripts ) - .pipe( rename( {'suffix': '.min'} ) ) - .pipe( uglify( { - 'mangle': false - } ) ) - .pipe( gulp.dest( 'assets/scripts' ) ); -} ); +gulp.task( 'uglify', [ 'concat' ], () => + gulp.src( paths.scripts ) + .pipe( rename( {'suffix': '.min'} ) ) + .pipe( uglify( { + 'mangle': false + } ) ) + .pipe( gulp.dest( 'assets/scripts' ) ) +); /** * Delete the theme's .pot before we create a new one. */ -gulp.task( 'clean:pot', function () { - return del( [ 'languages/_s.pot' ] ); -} ); +gulp.task( 'clean:pot', () => + del( [ 'languages/_s.pot' ] ) +); /** * Scan the theme and create a POT file. * * https://www.npmjs.com/package/gulp-wp-pot */ -gulp.task( 'wp-pot', [ 'clean:pot' ], function () { - return gulp.src( paths.php ) - .pipe( plumber( {'errorHandler': handleErrors} ) ) - .pipe( sort() ) - .pipe( wpPot( { - 'domain': '_s', - 'destFile': '_s.pot', - 'package': '_s', - 'bugReport': 'http://_s.com', - 'lastTranslator': 'John Doe ', - 'team': 'Team ' - } ) ) - .pipe( gulp.dest( 'languages/' ) ); -} ); +gulp.task( 'wp-pot', [ 'clean:pot' ], () => + gulp.src( paths.php ) + .pipe( plumber( {'errorHandler': handleErrors} ) ) + .pipe( sort() ) + .pipe( wpPot( { + 'domain': '_s', + 'destFile': '_s.pot', + 'package': '_s', + 'bugReport': 'http://_s.com', + 'lastTranslator': 'John Doe ', + 'team': 'Team ' + } ) ) + .pipe( gulp.dest( 'languages/' ) ) +); /** * Sass linting. * * https://www.npmjs.com/package/sass-lint */ -gulp.task( 'sass:lint', function () { +gulp.task( 'sass:lint', () => gulp.src( [ 'assets/sass/**/*.scss', '!assets/sass/base/_normalize.scss', '!assets/sass/base/_sprites.scss', '!node_modules/**' ] ) - .pipe( sassLint() ) - .pipe( sassLint.format() ) - .pipe( sassLint.failOnError() ); -} ); + .pipe( sassLint() ) + .pipe( sassLint.format() ) + .pipe( sassLint.failOnError() ) +); /** - * Javascript linting. + * JavaScript linting. * * https://www.npmjs.com/package/gulp-eslint */ -gulp.task( 'js:lint', function () { - return gulp.src( [ +gulp.task( 'js:lint', () => + gulp.src( [ 'assets/scripts/concat/*.js', 'assets/scripts/*.js', '!assets/scripts/project.js', @@ -281,10 +315,10 @@ gulp.task( 'js:lint', function () { '!Gulpfile.js', '!node_modules/**' ] ) - .pipe( eslint() ) - .pipe( eslint.format() ) - .pipe( eslint.failAfterError() ); -} ); + .pipe( eslint() ) + .pipe( eslint.format() ) + .pipe( eslint.failAfterError() ) +); /** * Process tasks and reload browsers on file changes. @@ -292,13 +326,14 @@ gulp.task( 'js:lint', function () { * https://www.npmjs.com/package/browser-sync */ gulp.task( 'watch', function () { + // Kick off BrowserSync. browserSync( { 'open': false, // Open project in a new tab? - 'injectChanges': true, // Auto inject changes instead of full reload - 'proxy': 'testing.dev', // Use http://_s.com:3000 to use BrowserSync + 'injectChanges': true, // Auto inject changes instead of full reload. + 'proxy': 'testing.dev', // Use http://_s.com:3000 to use BrowserSync. 'watchOptions': { - 'debounceDelay': 1000 // Wait 1 second before injecting + 'debounceDelay': 1000 // Wait 1 second before injecting. } } ); @@ -321,4 +356,4 @@ gulp.task( 'scripts', [ 'uglify' ] ); gulp.task( 'styles', [ 'cssnano' ] ); gulp.task( 'sprites', [ 'spritesmith' ] ); gulp.task( 'lint', [ 'sass:lint', 'js:lint' ] ); -gulp.task( 'default', [ 'sprites', 'i18n', 'icons', 'styles', 'scripts', 'imagemin', 'lint' ] ); +gulp.task( 'default', [ 'sprites', 'i18n', 'icons', 'styles', 'scripts', 'imagemin'] ); \ No newline at end of file diff --git a/assets/scripts/project.js b/assets/scripts/project.js index d38439e76..160f04358 100644 --- a/assets/scripts/project.js +++ b/assets/scripts/project.js @@ -1,9 +1,12 @@ +'use strict'; + /** * File js-enabled.js * * If Javascript is enabled, replace the class "no-js". */ -document.body.className = document.body.className.replace( 'no-js', 'js' ); +document.body.className = document.body.className.replace('no-js', 'js'); +'use strict'; /** * File modal.js @@ -12,12 +15,12 @@ document.body.className = document.body.className.replace( 'no-js', 'js' ); */ window.wdsModal = {}; -( function ( window, $, app ) { +(function (window, $, app) { // Constructor. app.init = function () { app.cache(); - if ( app.meetsRequirements() ) { + if (app.meetsRequirements()) { app.bindEvents(); } }; @@ -25,81 +28,82 @@ window.wdsModal = {}; // Cache all the things. app.cache = function () { app.$c = { - 'body': $( 'body' ) + 'body': $('body') }; }; // Do we meet the requirements? app.meetsRequirements = function () { - return $( '.modal-trigger' ).length; + return $('.modal-trigger').length; }; // Combine all events. app.bindEvents = function () { // Trigger a modal to open. - app.$c.body.on( 'click touchstart', '.modal-trigger', app.openModal ); + app.$c.body.on('click touchstart', '.modal-trigger', app.openModal); // Trigger the close button to close the modal. - app.$c.body.on( 'click touchstart', '.close', app.closeModal ); + app.$c.body.on('click touchstart', '.close', app.closeModal); // Allow the user to close the modal by hitting the esc key. - app.$c.body.on( 'keydown', app.escKeyClose ); + app.$c.body.on('keydown', app.escKeyClose); // Allow the user to close the modal by clicking outside of the modal. - app.$c.body.on( 'click touchstart', 'div.modal-open', app.closeModalByClick ); + app.$c.body.on('click touchstart', 'div.modal-open', app.closeModalByClick); }; // Open the modal. app.openModal = function () { // Figure out which modal we're opening and store the object. - var $modal = $( $( this ).data( 'target' ) ); + var $modal = $($(this).data('target')); // Display the modal. - $modal.addClass( 'modal-open' ); + $modal.addClass('modal-open'); // Add body class. - app.$c.body.addClass( 'modal-open' ); + app.$c.body.addClass('modal-open'); }; // Close the modal. app.closeModal = function () { // Figure the opened modal we're closing and store the object. - var $modal = $( $( 'div.modal-open .close' ).data( 'target' ) ); + var $modal = $($('div.modal-open .close').data('target')); // Find the iframe in the $modal object. - var $iframe = $modal.find( 'iframe' ); + var $iframe = $modal.find('iframe'); // Get the iframe src URL. - var url = $iframe.attr( 'src' ); + var url = $iframe.attr('src'); // Remove the source URL, then add it back, so the video can be played again later. - $iframe.attr( 'src', '' ).attr( 'src', url ); + $iframe.attr('src', '').attr('src', url); // Finally, hide the modal. - $modal.removeClass( 'modal-open' ); + $modal.removeClass('modal-open'); // Remove the body class. - app.$c.body.removeClass( 'modal-open' ); + app.$c.body.removeClass('modal-open'); }; // Close if "esc" key is pressed. - app.escKeyClose = function ( event ) { - if ( 27 === event.keyCode ) { + app.escKeyClose = function (event) { + if (27 === event.keyCode) { app.closeModal(); } }; // Close if the user clicks outside of the modal - app.closeModalByClick = function ( event ) { + app.closeModalByClick = function (event) { // If the parent container is NOT the modal dialog container, close the modal - if ( !$( event.target ).parents( 'div' ).hasClass( 'modal-dialog' ) ) { + if (!$(event.target).parents('div').hasClass('modal-dialog')) { app.closeModal(); } }; // Engage! - $( app.init ); -} )( window, jQuery, window.wdsModal ); + $(app.init); +})(window, jQuery, window.wdsModal); +'use strict'; /** * File search.js @@ -108,12 +112,12 @@ window.wdsModal = {}; */ window.wdsSearch = {}; -( function ( window, $, app ) { +(function (window, $, app) { // Constructor. app.init = function () { app.cache(); - if ( app.meetsRequirements() ) { + if (app.meetsRequirements()) { app.bindEvents(); } }; @@ -121,41 +125,42 @@ window.wdsSearch = {}; // Cache all the things. app.cache = function () { app.$c = { - 'body': $( 'body' ) + 'body': $('body') }; }; // Do we meet the requirements? app.meetsRequirements = function () { - return $( '.search-field' ).length; + return $('.search-field').length; }; // Combine all events. app.bindEvents = function () { // Remove placeholder text from search field on focus. - app.$c.body.on( 'focus', '.search-field', app.removePlaceholderText ); + app.$c.body.on('focus', '.search-field', app.removePlaceholderText); // Add placeholder text back to search field on blur. - app.$c.body.on( 'blur', '.search-field', app.addPlaceholderText ); + app.$c.body.on('blur', '.search-field', app.addPlaceholderText); }; // Remove placeholder text from search field. app.removePlaceholderText = function () { - var $search_field = $( this ); + var $search_field = $(this); - $search_field.data( 'placeholder', $search_field.attr( 'placeholder' ) ).attr( 'placeholder', '' ); + $search_field.data('placeholder', $search_field.attr('placeholder')).attr('placeholder', ''); }; // Replace placeholder text from search field. app.addPlaceholderText = function () { - var $search_field = $( this ); + var $search_field = $(this); - $search_field.attr( 'placeholder', $search_field.data( 'placeholder' ) ).data( 'placeholder', '' ); + $search_field.attr('placeholder', $search_field.data('placeholder')).data('placeholder', ''); }; // Engage! - $( app.init ); -} )( window, jQuery, window.wdsSearch ); + $(app.init); +})(window, jQuery, window.wdsSearch); +'use strict'; /** * File skip-link-focus-fix.js. @@ -164,32 +169,33 @@ window.wdsSearch = {}; * * Learn more: https://git.io/vWdr2 */ -( function () { - var isWebkit = navigator.userAgent.toLowerCase().indexOf( 'webkit' ) > -1, - isOpera = navigator.userAgent.toLowerCase().indexOf( 'opera' ) > -1, - isIe = navigator.userAgent.toLowerCase().indexOf( 'msie' ) > -1; +(function () { + var isWebkit = navigator.userAgent.toLowerCase().indexOf('webkit') > -1, + isOpera = navigator.userAgent.toLowerCase().indexOf('opera') > -1, + isIe = navigator.userAgent.toLowerCase().indexOf('msie') > -1; - if ( ( isWebkit || isOpera || isIe ) && document.getElementById && window.addEventListener ) { - window.addEventListener( 'hashchange', function () { - var id = location.hash.substring( 1 ), - element; + if ((isWebkit || isOpera || isIe) && document.getElementById && window.addEventListener) { + window.addEventListener('hashchange', function () { + var id = location.hash.substring(1), + element; - if ( !( /^[A-z0-9_-]+$/ ).test( id ) ) { + if (!/^[A-z0-9_-]+$/.test(id)) { return; } - element = document.getElementById( id ); + element = document.getElementById(id); - if ( element ) { - if ( !( /^(?:a|select|input|button|textarea)$/i ).test( element.tagName ) ) { + if (element) { + if (!/^(?:a|select|input|button|textarea)$/i.test(element.tagName)) { element.tabIndex = -1; } element.focus(); } - }, false ); + }, false); } -} )(); +})(); +'use strict'; /** * File window-ready.js @@ -197,7 +203,7 @@ window.wdsSearch = {}; * Add a "ready" class to when window is ready. */ window.wdsWindowReady = {}; -( function ( window, $, app ) { +(function (window, $, app) { // Constructor. app.init = function () { app.cache(); @@ -207,23 +213,22 @@ window.wdsWindowReady = {}; // Cache document elements. app.cache = function () { app.$c = { - 'window': $( window ), - 'body': $( document.body ) + 'window': $(window), + 'body': $(document.body) }; }; // Combine all events. app.bindEvents = function () { - app.$c.window.load( app.addBodyClass ); + app.$c.window.load(app.addBodyClass); }; // Add a class to . app.addBodyClass = function () { - app.$c.body.addClass( 'ready' ); + app.$c.body.addClass('ready'); }; // Engage! - $( app.init ); -} )( window, jQuery, window.wdsWindowReady ); - -//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImpzLWVuYWJsZWQuanMiLCJtb2RhbC5qcyIsInNlYXJjaC5qcyIsInNraXAtbGluay1mb2N1cy1maXguanMiLCJ3aW5kb3ctcmVhZHkuanMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUNOQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFD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G5cdFx0fTtcblx0fTtcblxuXHQvLyBDb21iaW5lIGFsbCBldmVudHMuXG5cdGFwcC5iaW5kRXZlbnRzID0gZnVuY3Rpb24gKCkge1xuXHRcdGFwcC4kYy53aW5kb3cubG9hZCggYXBwLmFkZEJvZHlDbGFzcyApO1xuXHR9O1xuXG5cdC8vIEFkZCBhIGNsYXNzIHRvIDxib2R5Pi5cblx0YXBwLmFkZEJvZHlDbGFzcyA9IGZ1bmN0aW9uICgpIHtcblx0XHRhcHAuJGMuYm9keS5hZGRDbGFzcyggJ3JlYWR5JyApO1xuXHR9O1xuXG5cdC8vIEVuZ2FnZSFcblx0JCggYXBwLmluaXQgKTtcbn0gKSggd2luZG93LCBqUXVlcnksIHdpbmRvdy53ZHNXaW5kb3dSZWFkeSApO1xuIl0sInNvdXJjZVJvb3QiOiIvc291cmNlLyJ9 + $(app.init); +})(window, jQuery, window.wdsWindowReady); +//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImpzLWVuYWJsZWQuanMiLCJtb2RhbC5qcyIsInNlYXJjaC5qcyIsInNraXAtbGluay1mb2N1cy1maXguanMiLCJ3aW5kb3ctcmVhZHkuanMiXSwibmFtZXMiOlsiZG9jdW1lbnQiLCJib2R5IiwiY2xhc3NOYW1lIiwicmVwbGFjZSIsIndpbmRvdyIsIndkc01vZGFsIiwiJCIsImFwcCIsImluaXQiLCJjYWNoZSIsIm1lZXRzUmVxdWlyZW1lbnRzIiwiYmluZEV2ZW50cyIsIiRjIiwibGVuZ3RoIiwib24iLCJvcGVuTW9kYWwiLCJjbG9zZU1vZGFsIiwiZXNjS2V5Q2xvc2UiLCJjbG9zZU1vZGFsQnlDbGljayIsIiRtb2RhbCIsImRhdGEiLCJhZGRDbGFzcyIsIiRpZnJhbWUiLCJmaW5kIiwidXJsIiwiYXR0ciIsInJlbW92ZUNsYXNzIiwiZXZlbnQiLCJrZXlDb2RlIiwidGFyZ2V0IiwicGFyZW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YXBwLmJpbmRFdmVudHMgPSBmdW5jdGlvbiAoKSB7XG5cdFx0YXBwLiRjLndpbmRvdy5sb2FkKCBhcHAuYWRkQm9keUNsYXNzICk7XG5cdH07XG5cblx0Ly8gQWRkIGEgY2xhc3MgdG8gPGJvZHk+LlxuXHRhcHAuYWRkQm9keUNsYXNzID0gZnVuY3Rpb24gKCkge1xuXHRcdGFwcC4kYy5ib2R5LmFkZENsYXNzKCAncmVhZHknICk7XG5cdH07XG5cblx0Ly8gRW5nYWdlIVxuXHQkKCBhcHAuaW5pdCApO1xufSApKCB3aW5kb3csIGpRdWVyeSwgd2luZG93Lndkc1dpbmRvd1JlYWR5ICk7XG4iXX0= diff --git a/assets/scripts/project.min.js b/assets/scripts/project.min.js index d43d0ac96..40f880c21 100644 --- a/assets/scripts/project.min.js +++ b/assets/scripts/project.min.js @@ -1 +1 @@ -document.body.className=document.body.className.replace("no-js","js"),window.wdsModal={},function(window,$,app){app.init=function(){app.cache(),app.meetsRequirements()&&app.bindEvents()},app.cache=function(){app.$c={body:$("body")}},app.meetsRequirements=function(){return $(".modal-trigger").length},app.bindEvents=function(){app.$c.body.on("click touchstart",".modal-trigger",app.openModal),app.$c.body.on("click touchstart",".close",app.closeModal),app.$c.body.on("keydown",app.escKeyClose),app.$c.body.on("click touchstart","div.modal-open",app.closeModalByClick)},app.openModal=function(){var $modal=$($(this).data("target"));$modal.addClass("modal-open"),app.$c.body.addClass("modal-open")},app.closeModal=function(){var $modal=$($("div.modal-open .close").data("target")),$iframe=$modal.find("iframe"),url=$iframe.attr("src");$iframe.attr("src","").attr("src",url),$modal.removeClass("modal-open"),app.$c.body.removeClass("modal-open")},app.escKeyClose=function(event){27===event.keyCode&&app.closeModal()},app.closeModalByClick=function(event){$(event.target).parents("div").hasClass("modal-dialog")||app.closeModal()},$(app.init)}(window,jQuery,window.wdsModal),window.wdsSearch={},function(window,$,app){app.init=function(){app.cache(),app.meetsRequirements()&&app.bindEvents()},app.cache=function(){app.$c={body:$("body")}},app.meetsRequirements=function(){return $(".search-field").length},app.bindEvents=function(){app.$c.body.on("focus",".search-field",app.removePlaceholderText),app.$c.body.on("blur",".search-field",app.addPlaceholderText)},app.removePlaceholderText=function(){var $search_field=$(this);$search_field.data("placeholder",$search_field.attr("placeholder")).attr("placeholder","")},app.addPlaceholderText=function(){var $search_field=$(this);$search_field.attr("placeholder",$search_field.data("placeholder")).data("placeholder","")},$(app.init)}(window,jQuery,window.wdsSearch),function(){var isWebkit=navigator.userAgent.toLowerCase().indexOf("webkit")>-1,isOpera=navigator.userAgent.toLowerCase().indexOf("opera")>-1,isIe=navigator.userAgent.toLowerCase().indexOf("msie")>-1;(isWebkit||isOpera||isIe)&&document.getElementById&&window.addEventListener&&window.addEventListener("hashchange",function(){var element,id=location.hash.substring(1);/^[A-z0-9_-]+$/.test(id)&&(element=document.getElementById(id),element&&(/^(?:a|select|input|button|textarea)$/i.test(element.tagName)||(element.tabIndex=-1),element.focus()))},!1)}(),window.wdsWindowReady={},function(window,$,app){app.init=function(){app.cache(),app.bindEvents()},app.cache=function(){app.$c={window:$(window),body:$(document.body)}},app.bindEvents=function(){app.$c.window.load(app.addBodyClass)},app.addBodyClass=function(){app.$c.body.addClass("ready")},$(app.init)}(window,jQuery,window.wdsWindowReady); \ No newline at end of file +"use strict";document.body.className=document.body.className.replace("no-js","js"),window.wdsModal={},function(window,$,app){app.init=function(){app.cache(),app.meetsRequirements()&&app.bindEvents()},app.cache=function(){app.$c={body:$("body")}},app.meetsRequirements=function(){return $(".modal-trigger").length},app.bindEvents=function(){app.$c.body.on("click touchstart",".modal-trigger",app.openModal),app.$c.body.on("click touchstart",".close",app.closeModal),app.$c.body.on("keydown",app.escKeyClose),app.$c.body.on("click touchstart","div.modal-open",app.closeModalByClick)},app.openModal=function(){var $modal=$($(this).data("target"));$modal.addClass("modal-open"),app.$c.body.addClass("modal-open")},app.closeModal=function(){var $modal=$($("div.modal-open .close").data("target")),$iframe=$modal.find("iframe"),url=$iframe.attr("src");$iframe.attr("src","").attr("src",url),$modal.removeClass("modal-open"),app.$c.body.removeClass("modal-open")},app.escKeyClose=function(event){27===event.keyCode&&app.closeModal()},app.closeModalByClick=function(event){$(event.target).parents("div").hasClass("modal-dialog")||app.closeModal()},$(app.init)}(window,jQuery,window.wdsModal),window.wdsSearch={},function(window,$,app){app.init=function(){app.cache(),app.meetsRequirements()&&app.bindEvents()},app.cache=function(){app.$c={body:$("body")}},app.meetsRequirements=function(){return $(".search-field").length},app.bindEvents=function(){app.$c.body.on("focus",".search-field",app.removePlaceholderText),app.$c.body.on("blur",".search-field",app.addPlaceholderText)},app.removePlaceholderText=function(){var $search_field=$(this);$search_field.data("placeholder",$search_field.attr("placeholder")).attr("placeholder","")},app.addPlaceholderText=function(){var $search_field=$(this);$search_field.attr("placeholder",$search_field.data("placeholder")).data("placeholder","")},$(app.init)}(window,jQuery,window.wdsSearch),function(){var isWebkit=navigator.userAgent.toLowerCase().indexOf("webkit")>-1,isOpera=navigator.userAgent.toLowerCase().indexOf("opera")>-1,isIe=navigator.userAgent.toLowerCase().indexOf("msie")>-1;(isWebkit||isOpera||isIe)&&document.getElementById&&window.addEventListener&&window.addEventListener("hashchange",function(){var element,id=location.hash.substring(1);/^[A-z0-9_-]+$/.test(id)&&(element=document.getElementById(id),element&&(/^(?:a|select|input|button|textarea)$/i.test(element.tagName)||(element.tabIndex=-1),element.focus()))},!1)}(),window.wdsWindowReady={},function(window,$,app){app.init=function(){app.cache(),app.bindEvents()},app.cache=function(){app.$c={window:$(window),body:$(document.body)}},app.bindEvents=function(){app.$c.window.load(app.addBodyClass)},app.addBodyClass=function(){app.$c.body.addClass("ready")},$(app.init)}(window,jQuery,window.wdsWindowReady); \ No newline at end of file diff --git a/package.json b/package.json index 070d4fb65..162155ba4 100644 --- a/package.json +++ b/package.json @@ -5,6 +5,7 @@ "main": "Gulpfile.js", "dependencies": { "autoprefixer": "^6.3.1", + "babel-preset-es2015": "^6.16.0", "bourbon": "^4.2.6", "bourbon-neat": "^1.7.2", "browser-sync": "^2.11.1", @@ -13,6 +14,7 @@ "eslint-config-wordpress": "^0.1.0", "glob": "^6.0.4", "gulp": "^3.9.1", + "gulp-babel": "^6.1.2", "gulp-cheerio": "^0.6.2", "gulp-concat": "^2.6.0", "gulp-cssnano": "^2.1.0",