mirror of
https://github.com/rstudio/shiny.git
synced 2026-02-09 22:25:59 -05:00
Remove extraneous indenting
This commit is contained in:
@@ -1,36 +1,36 @@
|
||||
var checkboxInputBinding = new InputBinding();
|
||||
$.extend(checkboxInputBinding, {
|
||||
find: function(scope) {
|
||||
return $(scope).find('input[type="checkbox"]');
|
||||
},
|
||||
getValue: function(el) {
|
||||
return el.checked;
|
||||
},
|
||||
setValue: function(el, value) {
|
||||
el.checked = value;
|
||||
},
|
||||
subscribe: function(el, callback) {
|
||||
$(el).on('change.checkboxInputBinding', function(event) {
|
||||
callback(true);
|
||||
});
|
||||
},
|
||||
unsubscribe: function(el) {
|
||||
$(el).off('.checkboxInputBinding');
|
||||
},
|
||||
getState: function(el) {
|
||||
return {
|
||||
label: $(el).parent().find('span').text(),
|
||||
value: el.checked
|
||||
};
|
||||
},
|
||||
receiveMessage: function(el, data) {
|
||||
if (data.hasOwnProperty('value'))
|
||||
el.checked = data.value;
|
||||
var checkboxInputBinding = new InputBinding();
|
||||
$.extend(checkboxInputBinding, {
|
||||
find: function(scope) {
|
||||
return $(scope).find('input[type="checkbox"]');
|
||||
},
|
||||
getValue: function(el) {
|
||||
return el.checked;
|
||||
},
|
||||
setValue: function(el, value) {
|
||||
el.checked = value;
|
||||
},
|
||||
subscribe: function(el, callback) {
|
||||
$(el).on('change.checkboxInputBinding', function(event) {
|
||||
callback(true);
|
||||
});
|
||||
},
|
||||
unsubscribe: function(el) {
|
||||
$(el).off('.checkboxInputBinding');
|
||||
},
|
||||
getState: function(el) {
|
||||
return {
|
||||
label: $(el).parent().find('span').text(),
|
||||
value: el.checked
|
||||
};
|
||||
},
|
||||
receiveMessage: function(el, data) {
|
||||
if (data.hasOwnProperty('value'))
|
||||
el.checked = data.value;
|
||||
|
||||
if (data.hasOwnProperty('label'))
|
||||
$(el).parent().find('span').text(data.label);
|
||||
if (data.hasOwnProperty('label'))
|
||||
$(el).parent().find('span').text(data.label);
|
||||
|
||||
$(el).trigger('change');
|
||||
}
|
||||
});
|
||||
inputBindings.register(checkboxInputBinding, 'shiny.checkboxInput');
|
||||
$(el).trigger('change');
|
||||
}
|
||||
});
|
||||
inputBindings.register(checkboxInputBinding, 'shiny.checkboxInput');
|
||||
|
||||
Reference in New Issue
Block a user