Skip to content

Commit

Permalink
Add cursor style on disabled #2.
Browse files Browse the repository at this point in the history
  • Loading branch information
vsn4ik committed Jun 9, 2014
1 parent d36f932 commit 8ee3e04
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 14 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# [Bootstrap-checkbox](http://vsn4ik.github.io/bootstrap-checkbox)

[![Bower version](https://badge.fury.io/bo/bootstrap-checkbox.svg)](http://badge.fury.io/bo/bootstrap-checkbox)

## Getting Started
Expand Down
5 changes: 4 additions & 1 deletion dist/bootstrap-checkbox.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ if (typeof jQuery === 'undefined') {
(function($) {
var Checkboxpicker = function(element, options) {
this.element = element;
this.$element = $(element).hide();

// Change .prop('hidden', true) -> .hide() in future
this.$element = $(element).prop('hidden', true);

this.options = $.extend({}, $.fn.checkboxpicker.defaults, options, this.$element.data());

Expand Down Expand Up @@ -63,6 +65,7 @@ if (typeof jQuery === 'undefined') {

if (this.element.disabled) {
this.$buttons.addClass('disabled');
this.$group.css('cursor', 'not-allowed');
}
else {
this.$element.change(this.toggle.bind(this));
Expand Down
18 changes: 5 additions & 13 deletions dist/bootstrap-checkbox.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 8ee3e04

Please sign in to comment.