1
0
mirror of https://github.com/ascribe/wp-theme synced 2024-12-22 09:13:38 +01:00

split up assets in _src & dist folders

This commit is contained in:
Matthias Kretschmann 2016-01-16 21:26:38 +01:00
parent 3fc1aea957
commit a54a54a3db
29 changed files with 63 additions and 72 deletions

View File

@ -4,7 +4,7 @@
// Main collection file
//
@node_modules: '../../node_modules';
@node_modules: '../../../node_modules';
// Normalize all the things
@import (inline) '@{node_modules}/normalize-css/normalize.css';
@ -105,7 +105,7 @@
position:relative;
top:15px;
margin:0 auto;
background-image: url(../../images/leftright.png);
background-image: url(../../../images/leftright.png);
width: 25px;
height: 50px;
}
@ -200,7 +200,7 @@
display: block;
width: 60px;
height: 60px;
background-image: url(../../images/icon-arrow.png);
background-image: url(../../../images/icon-arrow.png);
background-size:60px;
background-repeat: no-repeat;
}

View File

@ -92,7 +92,7 @@
}
.chevron-divider {
background-image: url(../../images/svg/ascribe-chevron.svg);
background-image: url(../../../images/svg/ascribe-chevron.svg);
background-position: bottom;
width: 100%;
background-size: 100%;

View File

@ -70,7 +70,7 @@
}
&:after {
content: '';
background-image: url(../img/arrow.png);
background-image: url(../../img/arrow.png);
background-repeat: no-repeat;
width: 10px;
height: 8px;

View File

@ -43,9 +43,10 @@
@text-color: @greyText;
@font-family-base: "canada-type-gibson", sans-serif;
@font-weight-base: @font-weight-light;
@font-weight-light: 300;
@font-weight-normal: 400;
@font-weight-base: @font-weight-light;
@font-weight-bold: @font-weight-normal;
@body-bg: @white;
@ -60,6 +61,7 @@
@headings-line-height: 1.2;
@headings-color: @pink;
//
// Spacing
//

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

11
assets/dist/css/ascribe.css vendored Normal file

File diff suppressed because one or more lines are too long

11
assets/dist/css/ascribe.min.css vendored Normal file

File diff suppressed because one or more lines are too long

11
assets/dist/js/ascribe.js vendored Normal file
View File

@ -0,0 +1,11 @@
/**
** ascribe v0.0.1
** The best WordPress theme ever made!
** http://ascribe.io
**
** Territorial <us@territorial.ca>
**
**
** https://github.com/ascribe/wp-theme.git
**/
function stickyNav(){var e=$(".sticky");$(window).on("load resize scroll",function(){$(window).width()>768&&($(window).scrollTop()>100?e.addClass("stuck"):e.removeClass("stuck"))})}function mobileNav(){$(".hamburger").click(function(){$(".mobile-nav").toggleClass("active")})}$(document).ready(function(){function e(){$("body").hasClass("page-template-template-tour")&&$(".tour-switcher .menu").prepend($(".tour-switcher .current-menu-item")),$(".current-menu-item a").click(function(e){e.preventDefault(),$("#menu-landing-page-menu").toggleClass("active")})}function t(){$(".case-study:gt(0)").addClass("hidden"),$(".slider-action").click(function(){var e=$(this).attr("id");"back"===e?($(".case-study").addClass("hidden"),$(".case-study").last().prependTo(".slide-container").removeClass("hidden")):(displayed=$(".case-study").first(),displayed.addClass("hidden"),$(".case-study").eq(1).removeClass("hidden"),displayed.appendTo(".slide-container"))})}function a(){$(".featured-faqs dt").click(function(){$(this).next("dd").toggleClass("open")})}function s(){$(".top-tab").click(function(){$(".top-tab").removeClass("active"),$(this).addClass("active");var e=$(this).data("tab");$(".marketplace-info").removeClass("active"),$("#"+e).addClass("active")})}t(),a(),s(),e(),mobileNav(),stickyNav()});

11
assets/dist/js/ascribe.min.js vendored Normal file
View File

@ -0,0 +1,11 @@
/**
** ascribe v0.0.1
** The best WordPress theme ever made!
** http://ascribe.io
**
** Territorial <us@territorial.ca>
**
**
** https://github.com/ascribe/wp-theme.git
**/
function stickyNav(){var e=$(".sticky");$(window).on("load resize scroll",function(){$(window).width()>768&&($(window).scrollTop()>100?e.addClass("stuck"):e.removeClass("stuck"))})}function mobileNav(){$(".hamburger").click(function(){$(".mobile-nav").toggleClass("active")})}$(document).ready(function(){function e(){$("body").hasClass("page-template-template-tour")&&$(".tour-switcher .menu").prepend($(".tour-switcher .current-menu-item")),$(".current-menu-item a").click(function(e){e.preventDefault(),$("#menu-landing-page-menu").toggleClass("active")})}function t(){$(".case-study:gt(0)").addClass("hidden"),$(".slider-action").click(function(){var e=$(this).attr("id");"back"===e?($(".case-study").addClass("hidden"),$(".case-study").last().prependTo(".slide-container").removeClass("hidden")):(displayed=$(".case-study").first(),displayed.addClass("hidden"),$(".case-study").eq(1).removeClass("hidden"),displayed.appendTo(".slide-container"))})}function a(){$(".featured-faqs dt").click(function(){$(this).next("dd").toggleClass("open")})}function s(){$(".top-tab").click(function(){$(".top-tab").removeClass("active"),$(this).addClass("active");var e=$(this).data("tab");$(".marketplace-info").removeClass("active"),$("#"+e).addClass("active")})}t(),a(),s(),e(),mobileNav(),stickyNav()});

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -67,16 +67,14 @@ var PROXY = 'http://localhost:8888'
// Styles
//
gulp.task('css', function() {
return gulp.src(SRC + 'assets/less/ascribe.less')
.pipe($.sourcemaps.init())
return gulp.src(SRC + 'assets/_src/less/ascribe.less')
.pipe($.less()).on('error', onError)
.pipe($.autoprefixer({ browsers: COMPATIBILITY }))
.pipe($.cssmin())
.pipe($.sourcemaps.write())
.pipe($.header(BANNER, { pkg: pkg }))
.pipe(gulp.dest(DIST + 'assets/css/'))
.pipe(gulp.dest(DIST + 'assets/dist/css/'))
.pipe($.rename({ suffix: '.min' }))
.pipe(gulp.dest(DIST + 'assets/css/'))
.pipe(gulp.dest(DIST + 'assets/dist/css/'))
.pipe(browser.stream());
});
@ -85,15 +83,13 @@ gulp.task('css', function() {
// JavaScript
//
gulp.task('js', function() {
return gulp.src(SRC + 'assets/js/src/ascribe.js')
.pipe($.sourcemaps.init())
return gulp.src(SRC + 'assets/_src/js/ascribe.js')
.pipe($.include())
.pipe($.uglify()).on('error', onError)
.pipe($.sourcemaps.write())
.pipe($.header(BANNER, { pkg: pkg }))
.pipe(gulp.dest(DIST + 'assets/js/'))
.pipe(gulp.dest(DIST + 'assets/dist/js/'))
.pipe($.rename({suffix: '.min'}))
.pipe(gulp.dest(DIST + 'assets/js/'));
.pipe(gulp.dest(DIST + 'assets/dist/js/'));
});
@ -104,9 +100,9 @@ gulp.task('serve', function() {
browser.init({
proxy: PROXY
});
gulp.watch([SRC + 'assets/less/**/*'], ['css']).on('change', browser.reload);
gulp.watch([SRC + 'assets/js/src/**/*'], ['js']);
//gulp.watch(SRC + '**/*').on('change', browser.reload);
gulp.watch([SRC + 'assets/_src/less/**/*'], ['css']);
gulp.watch([SRC + 'assets/_src/js/**/*'], ['js']);
gulp.watch(SRC + '**/*.{php,svg,png,jpg,gif}').on('change', browser.reload);
});

View File

@ -39,7 +39,7 @@ function scripts( $debug = false ) {
wp_enqueue_script(
'wptheme',
WPTHEME_TEMPLATE_URL . "/assets/js/ascribe.min.js",
WPTHEME_TEMPLATE_URL . "/assets/dist/js/ascribe.min.js",
array('jquery'),
WPTHEME_VERSION,
true
@ -60,7 +60,7 @@ function styles( $debug = false ) {
wp_enqueue_style(
'wptheme',
WPTHEME_URL . "/assets/css/ascribe{$min}.css",
WPTHEME_URL . "/assets/dist/css/ascribe{$min}.css",
array(),
WPTHEME_VERSION
);

View File

@ -15,8 +15,6 @@
"url": "http://territorial.ca"
},
"dependencies": {
"bootstrap": "^3.3.6",
"jquery": ">=2.1.4",
"normalize-css": ">=2.3.1",
"normalize-opentype.css": ">=0.2.4"
},
@ -33,7 +31,6 @@
"gulp-less": "^3.0.5",
"gulp-load-plugins": ">=0.10.0",
"gulp-rename": ">=1.2.2",
"gulp-sourcemaps": ">=1.6.0",
"gulp-uglify": ">=1.2.0",
"gulp-util": ">=3.0.6",
"qunitjs": "~1.18.0"