Browse Source

edited gulpfile

master
rdrew 2 years ago
parent
commit
e5cb555492
  1. 8
      config.yml
  2. 21
      css/sass/_base.scss
  3. 6
      css/sass/_header.scss
  4. 33
      css/sass/style.scss
  5. 64
      css/style.css
  6. 2
      css/style.css.map
  7. 40
      gulpfile.js

8
config.yml

@ -1,5 +1,5 @@
SITE: SITE:
Local: 'https://rdm_upei.lndo.site/' Local: 'https://rdm.lndo.site/'
Remote: Remote:
Url: 'https://rdm2.researchspaces.ca/' Url: 'https://rdm2.researchspaces.ca/'
Path: user Path: user
@ -7,8 +7,8 @@ PORT: 8000
BSREWRITE: BSREWRITE:
Css: Css:
Match: "/themes/contrib/RDM/css/" Match: '/themes/contrib/rdm/css/style.css'
Replace: "/css/" Replace: '/css/style.css'
Js: Js:
Match: "/themes/contrib/RDM/js/" Match: "/themes/contrib/RDM/js/"
Replace: "/js/" Replace: "/js/"
@ -23,7 +23,7 @@ PATHS:
#- libraries/guff #- libraries/guff
#- bower_components/foundation-sites/scss #- bower_components/foundation-sites/scss
#- bower_components/motion-ui/src #- bower_components/motion-ui/src
#- node_modules/modularscale-sass/stylesheets - node_modules/modularscale-sass/stylesheets
#- libraries/fontawesome-free/scss #- libraries/fontawesome-free/scss
Css: Css:
Dir: css Dir: css

21
css/sass/_base.scss

@ -49,6 +49,27 @@ h6 {
font-family: var(--heading-font); font-family: var(--heading-font);
color: var(--bold-color); color: var(--bold-color);
} }
h1 {
font-size: 2.2rem;
font-size: ms(3);
}
h2 {
font-size: 1.9rem;
font-size: ms(2);
}
h3 {
font-size: 1.6rem;
font-size: ms(1);
}
h4 {
font-size: 1.3rem;
}
h5 {
font-size: 1.1rem;
}
h6 {
font-size: 1.1rem;
}
strong { strong {
color: var(--bold-color); color: var(--bold-color);
} }

6
css/sass/_header.scss

@ -39,7 +39,8 @@
font-family: var(--heading-font); font-family: var(--heading-font);
color: var(--primary); color: var(--primary);
font-weight: 700; font-weight: 700;
font-size: 2rem !important; //font-size: 2rem !important;
font-size: ms(2);
} }
.site-name a:hover { .site-name a:hover {
color: var(--primary); color: var(--primary);
@ -65,6 +66,9 @@
.menu-wrap ul.menu li > a { .menu-wrap ul.menu li > a {
padding: 10px; padding: 10px;
} }
.menu-wrap ul.menu {
font-size:ms(0);
}
/* Header -> search block region */ /* Header -> search block region */
.search-icon { .search-icon {
width: 36px; width: 36px;

33
css/sass/style.scss

@ -1,5 +1,10 @@
.test-class { .test-class {
} }
@import 'modularscale';
$modularscale: (
base: 1em,
ratio: 1.5
); //@import './node_modules/modularscale-sass/stylesheets/_modularscale.scss';
//@format //@format
@import 'fonts'; @import 'fonts';
@import 'base'; @import 'base';
@ -26,6 +31,9 @@
.slider-text h4 { .slider-text h4 {
color: var(--dark-grey); color: var(--dark-grey);
} }
.slider-text p {
font-size: ms(0);
}
.slider { .slider {
background: var(--content-bg); background: var(--content-bg);
} }
@ -40,3 +48,28 @@ div#block-homepagewelcome {
color: #fff !important; color: #fff !important;
background: #789d4a; background: #789d4a;
} }
.toolbar-horizontal .search-box.open {
margin-top: 38px;
}
.toolbar-horizontal.toolbar-tray-open .search-box.open {
margin-top: 84px;
}
div#block-homepagewelcome-2 {
color: #fff !important;
background: #789d4a;
}
div#block-homepagewelcome-2 a {
color: var(--upei-red);
}
div#block-homepagewelcome-2 p {
color: #fff !important;
font-size: ms(1);
}
div#block-homepagewelcome-2 h2 {
color: #fff !important;
font-size: ms(2);
}

64
css/style.css

@ -48,6 +48,33 @@ h6 {
color: var(--bold-color); color: var(--bold-color);
} }
h1 {
font-size: 2.2rem;
font-size: 3.375em;
}
h2 {
font-size: 1.9rem;
font-size: 2.25em;
}
h3 {
font-size: 1.6rem;
font-size: 1.5em;
}
h4 {
font-size: 1.3rem;
}
h5 {
font-size: 1.1rem;
}
h6 {
font-size: 1.1rem;
}
strong { strong {
color: var(--bold-color); color: var(--bold-color);
} }
@ -434,7 +461,7 @@ div#block-menudetailsforhomepage li {
font-family: var(--heading-font); font-family: var(--heading-font);
color: var(--primary); color: var(--primary);
font-weight: 700; font-weight: 700;
font-size: 2rem !important; font-size: 2.25em;
} }
.site-name a:hover { .site-name a:hover {
@ -467,6 +494,10 @@ div#block-menudetailsforhomepage li {
padding: 10px; padding: 10px;
} }
.menu-wrap ul.menu {
font-size: 1em;
}
/* Header -> search block region */ /* Header -> search block region */
.search-icon { .search-icon {
width: 36px; width: 36px;
@ -1193,6 +1224,10 @@ button,
color: var(--dark-grey); color: var(--dark-grey);
} }
.slider-text p {
font-size: 1em;
}
.slider { .slider {
background: var(--content-bg); background: var(--content-bg);
} }
@ -1208,4 +1243,31 @@ div#block-homepagewelcome h2,
div#block-homepagewelcome p { div#block-homepagewelcome p {
color: #fff !important; color: #fff !important;
} }
.toolbar-horizontal .search-box.open {
margin-top: 38px;
}
.toolbar-horizontal.toolbar-tray-open .search-box.open {
margin-top: 84px;
}
div#block-homepagewelcome-2 {
color: #fff !important;
background: #789d4a;
}
div#block-homepagewelcome-2 a {
color: var(--upei-red);
}
div#block-homepagewelcome-2 p {
color: #fff !important;
font-size: 1.5em;
}
div#block-homepagewelcome-2 h2 {
color: #fff !important;
font-size: 2.25em;
}
/*# sourceMappingURL=style.css.map */ /*# sourceMappingURL=style.css.map */

2
css/style.css.map

File diff suppressed because one or more lines are too long

40
gulpfile.js

@ -1,7 +1,7 @@
//@format //@format
const yaml = require('js-yaml'); const yaml = require('js-yaml');
const fs = require('fs'); const fs = require('fs');
const {SITE, PORT, BSREWRITE, PATHS} = loadConfig(); const { SITE, PORT, BSREWRITE, PATHS } = loadConfig();
//var server = require('browser-sync').create(); //var server = require('browser-sync').create();
//global.server = server; //global.server = server;
const gulp = require('gulp'); const gulp = require('gulp');
@ -17,33 +17,32 @@ function loadConfig() {
} }
// BrowserSync // BrowserSync
function bsInit(done) { function bsInit__local(done) {
browsersync.init({ browsersync.init({
logLevel: 'debug', logLevel: 'debug',
//proxy: 'https://roblib_2022.lndo.site' //proxy: SITE.Local.Url,
proxy: 'https://rdm2.researchspaces.ca', proxy: 'https://rdm.lndo.site/',
}); });
done(); done();
} }
function bsInit__remote(done) { function bsInit__remote(done) {
browsersync.init({ browsersync.init({
logLevel: 'debug',
proxy: SITE.Remote.Url, proxy: SITE.Remote.Url,
serveStatic: ['.'], serveStatic: ['.'],
files: PATHS.Watch, files: PATHS.Watch,
plugins: ['bs-rewrite-rules'], plugins: ['bs-rewrite-rules'],
rewriteRules: [ rewriteRules: [
{ {
//match: BSREWRITE.Css.Match, match: BSREWRITE.Css.Match,
match: '/themes/contrib/rdm/css/style.css', replace: BSREWRITE.Css.Replace
replace: '/css/style.css',
//replace: BSREWRITE.Css.Replace,
}, },
{ {
match: BSREWRITE.Js.Match, match: BSREWRITE.Js.Match,
replace: BSREWRITE.Js.Replace, replace: BSREWRITE.Js.Replace
}, }
], ]
}); });
done(); done();
} }
@ -69,9 +68,9 @@ function styles() {
.pipe( .pipe(
sass sass
.sync({ .sync({
includePaths: PATHS.Scss.Libraries, includePaths: PATHS.Scss.Libraries
}) })
.on('error', sass.logError), .on('error', sass.logError)
) )
.pipe(sourcemaps.write('.')) .pipe(sourcemaps.write('.'))
.pipe(gulp.dest(PATHS.Css.Dir)) .pipe(gulp.dest(PATHS.Css.Dir))
@ -88,11 +87,20 @@ function watchFiles() {
// Group complex tasks // Group complex tasks
const build = gulp.parallel(styles); const build = gulp.parallel(styles);
const watch = gulp.series(styles, gulp.parallel(watchFiles, bsInit__remote)); const watch_remote = gulp.series(
styles,
gulp.parallel(watchFiles, bsInit__remote)
);
const watch_local = gulp.series(
styles,
gulp.parallel(watchFiles, bsInit__local)
);
// Export tasks // Export tasks
exports.build = build; exports.build = build;
exports.styles = styles; exports.styles = styles;
exports.drush = drush; exports.drush = drush;
exports.watch = watch; exports.watch = watch_remote;
exports.default = watch; exports.remote = watch_remote;
exports.local = watch_local;
exports.default = watch_remote;

Loading…
Cancel
Save