mirror of
https://github.com/jupyter/notebook.git
synced 2025-03-13 13:17:50 +08:00
Added support for disabled flag to button widget.
This commit is contained in:
parent
1536c45955
commit
d69e957b9a
@ -42,6 +42,12 @@ define(["notebook/js/widget"], function(widget_manager){
|
||||
this.$el.html(description);
|
||||
}
|
||||
|
||||
if (this.model.get('disabled')) {
|
||||
this.$el.attr('disabled','disabled');
|
||||
} else {
|
||||
this.$el.removeAttr('disabled');
|
||||
}
|
||||
|
||||
return IPython.WidgetView.prototype.update.call(this);
|
||||
},
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user