Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
Xiaodong Sun committed Feb 22, 2016
2 parents 552c938 + 69be149 commit 63c4da2
Show file tree
Hide file tree
Showing 38 changed files with 3,112 additions and 1,525 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
.idea/*
temp
node_modules
bower_components
./css/
.grunt/*
_SpecRunner.html
npm-debug.log
.DS_STORE
index.html
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
5.1.1
50 changes: 50 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
6.0.16 / 2016-02-04
==================
* Bug Fix: Attempted Bug fix from 6.0.11 was refined to ensure so side effects.

6.0.15 / 2016-02-04
==================
* Bug Fix: _setText() defaults to `.textContent` vs `.innerHTML`. Thanks to [gio-js](https://github.com/gio-js)

6.0.13 / 2016-01-31
==================
* Reverted Bug fix from prior release

6.0.11 / 2016-01-31
==================
* Bug fix: Slider was not scrolling properly when nested inside of scrollable container. Thanks to [serbiant](https://github.com/serbiant)


6.0.9 / 2016-01-26
==================
* Bug fix: Race condition in `setValue()` where slider value was being set after `change` and `slide` events were being triggered. Thanks to [glaszig](https://github.com/glaszig)

6.0.7 / 2016-01-22
==================
* Bug fix: When `tooltip_position` option is set to `"bottom"` on a slider with multiple split handles, position both tooltips below the slider. Thanks to [Martin Hesslund](https://github.com/kesse)

6.0.5 / 2016-01-20
==================
* bower.json: changing "main" to reference /dist/bootstrap-slider.js

6.0.2 / 2015-12-31
==================
* package.json: changing "main" to point at proper file path

6.0.0 / 2015-12-30
==================
* Moving all source code to `/src` directory
* Transpiling JS with [Babel](https://babeljs.io/)
* Adding `Other Guidelines` section to CONTRIBUTING.MD
* Updating README with Grunt CLI tasks
* Update postpublish script to reference transpiled code
* Freezing dependency versions (this allows us to ensure the module and grunt tasks always have consistent/repeatable behavior)
* Adding an `.nvmrc` file for Node 5.x.x. This version of node comes with NPM 3.x.x, which creates a flat dependency tree for `node_modules`, which basically eliminates the need for bower as our client-side deps management solution

5.3.6 / 2015-12-27
==================
* Restoring bootstrap depedency to bower.json file (Fixes issue with `grunt prod` task)

5.3.4 / 2015-12-27
==================
* Bug fix: Ticks now reposition themselves during window resize - Thanks to [Zachary Siswick](https://github.com/zsiswick)
13 changes: 10 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,18 @@ Pull Requests

Please accompany all pull requests with the following (where appropriate):

* unit tests
* jsfiddle
* unit tests (we use [Jasmine 1.3](http://jasmine.github.io/1.3/introduction.html))
* jsfiddle (or an equivalent such as codepen, plunker, etc)
* documentation updates
* examples (for new options being added)

Additionally, when you are ready to submit your PR, please rebase your commits against the latest master branch so they are easier to examine!
We support both Sass and LESS. If you modify one in your PR, please modify both and make sure they both work.

Additionally, when you are ready to submit your PR, please rebase your commits against the latest master branch so they are easier to examine! Please make sure you're not committing your re-built `dist` files, either. We'll do that!

Also, please note, your code will not be merged if it does not pass our CI test. Thanks for your contribution!

Other Guidelines
=============
* Please do not include anything from the `dist` directory in your pull request. The contents of this directory are automatically generated when the project maintainers merge pull requests/bump the version/publish to NPM
* The application JavaScript source code is transpiled using [Babel](https://babeljs.io/)
120 changes: 91 additions & 29 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,27 +7,37 @@ module.exports = function(grunt) {

// Project configuration.
grunt.initConfig({
// Metadata.
// Metadata
pkg: packageJSON,
// Task configuration.
header: {
dist: {
options: {
text: "/*! =======================================================\n VERSION <%= pkg.version %> \n========================================================= */"
},
files: {
'<%= pkg.gruntConfig.dist.js %>': '<%= pkg.gruntConfig.temp.js %>',
'<%= pkg.gruntConfig.dist.jsMin %>': '<%= pkg.gruntConfig.temp.jsMin %>',
'<%= pkg.gruntConfig.dist.css %>': '<%= pkg.gruntConfig.temp.css %>',
'<%= pkg.gruntConfig.dist.cssMin %>': '<%= pkg.gruntConfig.temp.cssMin %>'
}
}
},
// Task configuration.
uglify: {
options: {
preserveComments: 'some'
},
dist: {
src: '<%= pkg.main %>',
src: '<%= pkg.gruntConfig.temp.js %>',
dest: '<%= pkg.gruntConfig.temp.jsMin %>'
}
},
babel: {
options: {
presets: ['es2015']
},
dist: {
src: '<%= pkg.gruntConfig.js.slider %>',
dest: '<%= pkg.gruntConfig.temp.js %>'
}
},
Expand All @@ -36,9 +46,10 @@ module.exports = function(grunt) {
options: {
'-W099': true
},
src: '<%= pkg.main %>'
src: '<%= pkg.gruntConfig.js.slider %>'
},
options: {
esnext: true,
curly: true,
eqeqeq: true,
immed: true,
Expand All @@ -59,13 +70,13 @@ module.exports = function(grunt) {
module: true,
require: true
},
"-W099": true,
"-W099": true
},
gruntfile: {
src: 'Gruntfile.js'
},
js: {
src: '<%= pkg.main %>'
src: '<%= pkg.gruntConfig.js.slider %>'
},
spec : {
src: '<%= pkg.gruntConfig.spec %>',
Expand Down Expand Up @@ -99,11 +110,11 @@ module.exports = function(grunt) {
}
},
jasmine : {
src : '<%= pkg.main %>',
src : '<%= pkg.gruntConfig.temp.js %>',
options : {
specs : '<%= pkg.gruntConfig.spec %>',
vendor : ['<%= pkg.gruntConfig.js.jquery %>', '<%= pkg.gruntConfig.js.bindPolyfill %>'],
styles : ['<%= pkg.gruntConfig.css.bootstrap %>', '<%= pkg.gruntConfig.css.slider %>'],
styles : ['<%= pkg.gruntConfig.css.bootstrap %>', '<%= pkg.gruntConfig.temp.css %>'],
template : '<%= pkg.gruntConfig.tpl.SpecRunner %>'
}
},
Expand All @@ -114,11 +125,29 @@ module.exports = function(grunt) {
js : {
modernizr : '<%= pkg.gruntConfig.js.modernizr %>',
jquery : '<%= pkg.gruntConfig.js.jquery %>',
slider : '<%= pkg.main %>'
slider : '<%= pkg.gruntConfig.temp.js %>'
},
css : {
bootstrap : '<%= pkg.gruntConfig.css.bootstrap %>',
slider : '<%= pkg.gruntConfig.css.slider %>'
slider : '<%= pkg.gruntConfig.temp.css %>'
}
}
},
files : {
'index.html' : ['<%= pkg.gruntConfig.tpl.index %>']
}
},
'generate-gh-pages' : {
options : {
data : {
js : {
modernizr : '<%= pkg.gruntConfig.js.modernizr %>',
jquery : '<%= pkg.gruntConfig.js.jquery %>',
slider : 'js/bootstrap-slider.js'
},
css : {
bootstrap : '<%= pkg.gruntConfig.css.bootstrap %>',
slider : 'css/bootstrap-slider.css'
}
}
},
Expand All @@ -128,26 +157,30 @@ module.exports = function(grunt) {
}
},
watch: {
options : {
options: {
livereload: true
},
js : {
files: '<%= pkg.main %>',
tasks: ['jshint:js', 'jasmine']
js: {
files: '<%= pkg.gruntConfig.js.slider %>',
tasks: ['jshint:js', 'babel', 'jasmine']
},
gruntfile : {
gruntfile: {
files: '<%= jshint.gruntfile %>',
tasks: ['jshint:gruntfile']
},
spec : {
spec: {
files: '<%= pkg.gruntConfig.spec %>',
tasks: ['jshint:spec', 'jasmine:src']
},
css : {
files: ['<%= pkg.gruntConfig.less.slider %>', '<%= pkg.gruntConfig.less.rules %>', '<%= pkg.gruntConfig.less.variables %>'],
css: {
files: [
'<%= pkg.gruntConfig.less.slider %>',
'<%= pkg.gruntConfig.less.rules %>',
'<%= pkg.gruntConfig.less.variables %>'
],
tasks: ['less:development']
},
index : {
index: {
files: '<%= pkg.gruntConfig.tpl.index %>',
tasks: ['template:generate-index-page']
}
Expand All @@ -170,7 +203,7 @@ module.exports = function(grunt) {
},
development: {
files: {
'<%= pkg.gruntConfig.css.slider %>': '<%= pkg.gruntConfig.less.slider %>'
'<%= pkg.gruntConfig.temp.css %>': '<%= pkg.gruntConfig.less.slider %>'
}
},
production: {
Expand Down Expand Up @@ -207,7 +240,6 @@ module.exports = function(grunt) {
}
});


// These plugins provide necessary tasks.
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-jshint');
Expand All @@ -220,16 +252,46 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-template');
grunt.loadNpmTasks('grunt-header');
grunt.loadNpmTasks('grunt-bump');
grunt.loadNpmTasks('grunt-babel');

// Create custom tasks
grunt.registerTask('test', ['jshint', 'jasmine']);
grunt.registerTask('build', ['less:development', 'test', 'template']);
grunt.registerTask('development', ['template', 'connect', 'open:development', 'watch']);
grunt.registerTask('append-header', ['header', 'clean:temp']);
grunt.registerTask('production', ['less:production', 'less:production-min', 'test', 'uglify', "clean:dist", 'append-header']);
grunt.registerTask('test', [
'jshint',
'babel',
'less:development',
'jasmine',
'clean:temp'
]);
grunt.registerTask('build', [
'less:development',
'test',
'template:generate-index-page'
]);
grunt.registerTask('build-gh-pages', [
'less:development',
'babel',
'template:generate-gh-pages'
]);
grunt.registerTask('dist', [
'clean:dist',
'less:production',
'less:production-min',
'babel',
'uglify',
'append-header'
]);
grunt.registerTask('development', [
'less:development',
'babel',
'template:generate-index-page',
'connect',
'open:development',
'watch'
]);
grunt.registerTask('production', ['test', 'dist']);
grunt.registerTask('dev', 'development');
grunt.registerTask('prod', 'production');
grunt.registerTask('dist', 'production');
grunt.registerTask('dist-no-tests', ['less:production', 'less:production-min', 'uglify', 'append-header']);
grunt.registerTask('default', 'build');
};
grunt.registerTask('default', ['build']);

}; // End of module
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
----------------------------------------------------------------------
bootstrap-slider is released under the MIT License
Copyright (c) 2015 Kyle Kemp, Rohit Kalkur, and contributors
Copyright (c) 2015-2016 Kyle Kemp, Rohit Kalkur, and contributors

Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
Expand Down
Loading

0 comments on commit 63c4da2

Please sign in to comment.