Added support for multiple spaces in a row

also added button height fix for standard buttons without a caption
Jonathan Frederic 12 years ago
parent ce53644d54
commit 59e7a04723

@ -38,10 +38,11 @@ define(["notebook/js/widget"], function(){
// Frontent -> Frontend Sync
update : function(){
var description = this.model.get('description');
if (description.length==0) {
this.$el.html(' '); // Preserve button height
description.replace(' ', ' ')
if (description.length == 0) {
this.$el.html(' '); // Preserve button height
} else {
this.$el.html(description);
this.$el.html(this.model.get('description'));
}
return IPython.WidgetView.prototype.update.call(this);

@ -60,8 +60,8 @@ define(["notebook/js/widget"], function(){
update : function(){
var selected_item_text = this.model.get('value');
selected_item_text.replace(' ', '');
if (selected_item_text == '') {
selected_item_text.replace(' ', ' ');
if (selected_item_text.length == 0) {
this.$droplabel.html(' ');
} else {
this.$droplabel.html(this.model.get('value'));

Loading…
Cancel
Save