Permalink
Browse files

Added data reference. Sorted most of the documentation out.

1 parent 2f351b8 commit 43a3c0ff0a2eb77e36de099442e61ac17e8a0ea4 @ewafford ewafford committed Jun 2, 2015
View
@@ -0,0 +1,118 @@
+# Contributing to Roots Projects
+
+Please take a moment to review this document in order to make the contribution
+process easy and effective for everyone involved.
+
+Following these guidelines helps to communicate that you respect the time of
+the developers managing and developing this open source project. In return,
+they should reciprocate that respect in addressing your issue or assessing
+patches and features.
+
+
+## Using the issue tracker
+
+The issue tracker is the preferred channel for [bug reports](#bugs),
+[features requests](#features) and [submitting pull
+requests](#pull-requests), but please respect the following restrictions:
+
+* Please **do not** use the issue tracker for personal support requests.
+
+* Please **do not** derail or troll issues. Keep the discussion on topic and
+ respect the opinions of others.
+
+
+<a name="bugs"></a>
+## Bug reports
+
+A bug is a _demonstrable problem_ that is caused by the code in the repository.
+Good bug reports are extremely helpful - thank you!
+
+Guidelines for bug reports:
+
+1. **Use the GitHub issue search** &mdash; check if the issue has already been
+ reported.
+
+2. **Check if the issue has been fixed** &mdash; try to reproduce it using the
+ latest `master` or development branch in the repository.
+
+3. **Isolate the problem** &mdash; make sure that the code in the repository is
+_definitely_ responsible for the issue.
+
+A good bug report shouldn't leave others needing to chase you up for more
+information. Please try to be as detailed as possible in your report. Examples are
+important, please try to provide them.
+
+
+<a name="features"></a>
+## Feature requests
+
+Feature requests are welcome. But take a moment to find out whether your idea
+fits with the scope and aims of the project. It's up to *you* to make a strong
+case to convince the developers of the merits of this feature. Please
+provide as much detail and context as possible.
+
+
+<a name="pull-requests"></a>
+## Pull requests
+
+Good pull requests - patches, improvements, new features - are a fantastic
+help. They should remain focused in scope and avoid containing unrelated
+commits.
+
+**Please ask first** before embarking on any significant pull request (e.g.
+implementing features, refactoring code), otherwise you risk spending a lot of
+time working on something that the developers might not want to merge into the
+project.
+
+Please adhere to the coding conventions used throughout the project (indentation,
+comments, etc.).
+
+Adhering to the following this process is the best way to get your work
+merged:
+
+1. [Fork](http://help.github.com/fork-a-repo/) the repo, clone your fork,
+ and configure the remotes:
+
+ ```bash
+ # Clone your fork of the repo into the current directory
+ git clone https://github.com/<your-username>/<repo-name>
+ # Navigate to the newly cloned directory
+ cd <repo-name>
+ # Assign the original repo to a remote called "upstream"
+ git remote add upstream https://github.com/<upsteam-owner>/<repo-name>
+ ```
+
+2. If you cloned a while ago, get the latest changes from upstream:
+
+ ```bash
+ git checkout <dev-branch>
+ git pull upstream <dev-branch>
+ ```
+
+3. Create a new topic branch (off the main project development branch) to
+ contain your feature, change, or fix:
+
+ ```bash
+ git checkout -b <topic-branch-name>
+ ```
+
+4. Commit your changes in logical chunks. Please adhere to these [git commit
+ message guidelines](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html)
+ or your code is unlikely be merged into the main project. Use Git's
+ [interactive rebase](https://help.github.com/articles/interactive-rebase)
+ feature to tidy up your commits before making them public.
+
+5. Locally merge (or rebase) the upstream development branch into your topic branch:
+
+ ```bash
+ git pull [--rebase] upstream <dev-branch>
+ ```
+
+6. Push your topic branch up to your fork:
+
+ ```bash
+ git push origin <topic-branch-name>
+ ```
+
+10. [Open a Pull Request](https://help.github.com/articles/using-pull-requests/)
+ with a clear title and description.
View
@@ -20,6 +20,7 @@ module.exports = function(grunt) {
pkg: grunt.file.readJSON('package.json'),
app: grunt.file.readJSON('_config.json'),
vendor: 'bower_components',
+
// assemble
assemble: {
options: {
@@ -108,6 +109,7 @@ module.exports = function(grunt) {
}
},
+ // concat
concat: {
docs: {
src: [
@@ -155,6 +157,7 @@ module.exports = function(grunt) {
}
},
+ // jshint
jshint: {
options: {
jshintrc: 'src/js/.jshintrc'
@@ -164,6 +167,7 @@ module.exports = function(grunt) {
}
},
+ //jscs
jscs: {
options: {
config: 'src/js/.jscsrc',
@@ -175,6 +179,7 @@ module.exports = function(grunt) {
}
},
+ // uglify
uglify: {
options: {
banner: '/**\n' + ' * bxSlider v<%= pkg.version %>\n' +
@@ -308,13 +313,13 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('assemble');
// tasks
- grunt.registerTask('dist', ['clean:dist', 'less:dist', 'concat:dist', 'cssmin:dist', 'copy:distImages', 'copy:distVendor', 'jscs:dist', 'uglify:dist', 'copy:readme']);
+ grunt.registerTask('dist', ['clean:dist', 'less:dist', 'jshint:dist', 'concat:dist', 'cssmin:dist', 'copy:distImages', 'copy:distVendor', 'jscs:dist', 'uglify:dist', 'copy:readme']);
grunt.registerTask('docs', ['clean:docs', 'assemble', 'less:docs', 'concat:docs', 'copy:docsAssets', 'copy:docsHighlightAssets', 'copy:distToDocs']);
grunt.registerTask('test', ['jshint:dist']);
- grunt.registerTask('default', ['dist', 'docs', 'test']);
+ grunt.registerTask('default', ['dist', 'docs']);
grunt.registerTask('serve', ['connect:docs', 'watch']);
View
@@ -1,6 +1,6 @@
{
"name": "bxslider-4",
- "version": "4.2.3",
+ "version": "4.2.4",
"homepage": "http://bxslider.com",
"license": "MIT",
"main": [
View
@@ -1,4 +1,4 @@
-#bxSlider 4.2.3
+#bxSlider 4.2.4
##The fully-loaded, responsive jQuery content slider
###Why should I use this slider?
@@ -29,7 +29,7 @@ First and most important, the jQuery library needs to be included (no need to do
```html
<!-- jQuery library (served from Google) -->
-<script src="//ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script>
+<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
<!-- bxSlider Javascript file -->
<script src="/js/jquery.bxslider.min.js"></script>
<!-- bxSlider CSS file -->
@@ -51,7 +51,7 @@ Create a `<ul class="bxslider">` element, with a `<li>` for each slide. Slides c
###Step 3: Call the bxSlider
-Call .bxslider() on `<ul class="bxslider">`. Note that the call must be made inside of a $(document).ready() call, or the plugin will not work!
+Call .bxSlider() on `<ul class="bxslider">`. Note that the call must be made inside of a $(document).ready() call, or the plugin will not work!
```javascript
$(document).ready(function(){
@@ -362,6 +362,12 @@ Slides will automatically transition
default: false
options: boolean (true / false)
```
+**stopAutoOnClick**
+Auto will stop on interaction with controls
+```
+default: false
+options: boolean (true / false)
+```
**pause**
The amount of time (in ms) between each auto transition
@@ -428,6 +434,30 @@ default: 0
options: integer
```
+###Keyboard
+
+**keyboardEnabled**
+Allows for keyboard control of visible slider. Keypress ignored if slider not visible.
+```
+default: false
+options: boolean (true / false)
+```
+
+###Accessibility
+**ariaLive**
+Adds Aria Live attribute to slider.
+```
+default: true
+options: boolean (true / false)
+```
+
+**ariaHidden**
+Adds Aria Hidden attribute to any nonvisible slides.
+```
+default: true
+options: boolean (true / false)
+```
+
###Callbacks
**onSliderLoad**
@@ -1,5 +1,5 @@
/**
- * bxSlider v4.2.3
+ * bxSlider v4.2.4
* Copyright 2013-2015 Steven Wanderski
* Written while drinking Belgian ales and listening to jazz
@@ -1,5 +1,5 @@
/**
- * bxSlider v4.2.3
+ * bxSlider v4.2.4
* Copyright 2013-2015 Steven Wanderski
* Written while drinking Belgian ales and listening to jazz
@@ -114,6 +114,9 @@
windowWidth = $(window).width(),
windowHeight = $(window).height();
+ // Return if slider is already initialized
+ if ($(el).data('bxslider')) { return; }
+
/**
* ===================================================================================
* = PRIVATE FUNCTIONS
@@ -125,7 +128,7 @@
*/
var init = function() {
// Return if slider is already initialized
- if (slider.initialized) { return; }
+ if ($(el).data('bxslider')) { return; }
// merge user-supplied options with the defaults
slider.settings = $.extend({}, defaults, options);
// parse slideWidth setting
@@ -178,6 +181,9 @@
el.children(slider.settings.slideSelector).each(function() {
$(this).data('origStyle', $(this).attr('style'));
});
+
+ //store reference to self in order to access public functions later
+ $(el).data('bxslider', this);
// perform all DOM / CSS modifications
setup();
};
@@ -342,7 +348,7 @@
* Returns the calculated height of the viewport, used to determine either adaptiveHeight or the maxHeight value
*/
var getViewportHeight = function() {
- var height = 0,
+ var height = el.outerHeight(),
currentIndex = null,
// first determine which children (slides) should be used in our height calculation
children = $();
@@ -1559,6 +1565,8 @@
clearInterval(slider.interval);
if (slider.settings.responsive) { $(window).unbind('resize', resizeWindow); }
if (slider.settings.keyboardEnabled) { $(document).unbind('keydown', keyPress); }
+ //remove self reference in data
+ $(this).removeData('bxslider');
};
/**
@@ -1568,6 +1576,8 @@
if (settings !== undefined) { options = settings; }
el.destroySlider();
init();
+ //store reference to self in order to access public functions later
+ $(el).data('bxslider', this);
};
init();
@@ -1,5 +1,5 @@
/**
- * bxSlider v4.2.3
+ * bxSlider v4.2.4
* Copyright 2013-2015 Steven Wanderski
* Written while drinking Belgian ales and listening to jazz
Oops, something went wrong.
@@ -2,7 +2,7 @@
title: Adaptive Height
subTitle: AdaptiveHeight
description: Adaptive Height demo
-sort: 7
+sort: 8
tags:
- demo
@@ -3,7 +3,7 @@ title: Auto Demo
subTitle: Auto
nav: demos
description: Autoplay usage demo
-sort: 6
+sort: 7
tags:
- demo
@@ -3,7 +3,7 @@ title: Callbacks Demo
subTitle: Callbacks
nav: demos
description: Callback usage demo
-sort: 8
+sort: 9
tags:
- demo
@@ -3,7 +3,7 @@ title: Caption Demo
subTitle: Captions
nav: demos
description: Slider with Captions
-sort: 5
+sort: 6
tags:
- demo
@@ -2,15 +2,15 @@
title: Custom Pager Demo
subTitle: Pager
description: Custom Pager usage demo
-sort: 9
+sort: 10
tags:
- demo
---
<h1>Custom Pager</h1>
-<p>Note that the parent element (#bx-pager in this example), must contain an <code><a></code> tag for each slide. Each <code><a></code> tag must have a data-slide-index attribute that references the respecitve slide index (zero-based). See the HTML in this example. Also note that this method should not be used for dynamic carousels.</p>
+<p>Note that the parent element (#bx-pager in this example), must contain an href tag for each slide. Each href tag must have a data-slide-index attribute that references the respecitve slide index (zero-based). See the HTML in this example. Also note that this method should not be used for dynamic carousels.</p>
<div id="demoSlider1" class="bxslider">
<div class="item"><img src="{{assets}}/img/photo1.jpeg"></div>
@@ -3,7 +3,7 @@ title: Destroy Demo
subTitle: Destroy
nav: demos
description: Basic usage demo
-sort: 1
+sort: 13
tags:
- demo
Oops, something went wrong.

0 comments on commit 43a3c0f

Please sign in to comment.