Owen Leonard
4b82ed3549
This patch replaces the fixFloat jQuery plugin with a new one: HC-sticky (https://github.com/somewebmedia/hc-sticky). This plugin provides the same functionality without the page-reflow problems fixFloat suffers from. To test, apply the patch and regenerate the staff client CSS. Test the behavior of the floating toolbar on these pages: - Acquisitions -> Vendor -> Vendor details - Acquisitions -> Vendor -> View basket - On both these pages, test toolbar behavior before and after expanding the "Orders search" options at the top of the page. - Administration -> System preferences - Authorities -> Create or edit an authority - Catalog -> Advanced search - Search results - Catalog -> Item search - Cataloging -> Add or edit a record - Open the plugin window for the 008 field - Tools -> Label creator -> New label batch -> Add items -> Search -> Results - Patrons -> New patron - Test before and after expanding the patron search options at the top of the page - Test editing a patron too - Tools -> Automatic item modifications by age -> Edit - Tools -> Notices & slips -> Edit - Lists -> View list Check that the About page has been updated with information about the plugin. Signed-off-by: David Cook <dcook@prosentient.com.au> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
61 lines
No EOL
1.6 KiB
JavaScript
61 lines
No EOL
1.6 KiB
JavaScript
/* eslint-env node */
|
|
/* eslint no-console:"off" */
|
|
|
|
let gulp;
|
|
|
|
try {
|
|
gulp = require( "gulp" );
|
|
} catch(e) {
|
|
console.error("You are missing required Node modules; run `npm install`.");
|
|
process.exit(1);
|
|
}
|
|
|
|
const gutil = require( "gulp-util" );
|
|
const sass = require("gulp-sass");
|
|
const cssnano = require("gulp-cssnano");
|
|
const sourcemaps = require('gulp-sourcemaps');
|
|
const autoprefixer = require('gulp-autoprefixer');
|
|
|
|
const STAFF_JS_BASE = "koha-tmpl/intranet-tmpl/prog/js";
|
|
const STAFF_CSS_BASE = "koha-tmpl/intranet-tmpl/prog/css";
|
|
const OPAC_JS_BASE = "koha-tmpl/opac-tmpl/bootstrap/js";
|
|
const OPAC_CSS_BASE = "koha-tmpl/opac-tmpl/bootstrap/css";
|
|
|
|
var sassOptions = {
|
|
errLogToConsole: true,
|
|
precision: 3
|
|
}
|
|
|
|
if( gutil.env.view == "opac" ){
|
|
var css_base = OPAC_CSS_BASE;
|
|
var js_base = OPAC_JS_BASE;
|
|
} else {
|
|
var css_base = STAFF_CSS_BASE;
|
|
var js_base = STAFF_JS_BASE;
|
|
}
|
|
|
|
gulp.task( "default", ['watch'] );
|
|
|
|
// CSS processing for development
|
|
gulp.task('css', function() {
|
|
return gulp.src( css_base + "/src/**/*.scss" )
|
|
.pipe(sourcemaps.init())
|
|
.pipe(sass( sassOptions ).on('error', sass.logError))
|
|
.pipe(autoprefixer())
|
|
.pipe(sourcemaps.write('./maps'))
|
|
.pipe(gulp.dest( css_base ));
|
|
});
|
|
|
|
// CSS processing for production
|
|
|
|
gulp.task('build', function() {
|
|
return gulp.src( css_base + "/src/**/*.scss" )
|
|
.pipe(sass( sassOptions ).on('error', sass.logError))
|
|
.pipe(autoprefixer())
|
|
.pipe(cssnano({ zindex: false }))
|
|
.pipe(gulp.dest( css_base ));
|
|
});
|
|
|
|
gulp.task('watch', function(){
|
|
gulp.watch( css_base + "/src/**/*.scss", ['css'] );
|
|
}); |