refreshLink: function(linkUrl) {
this._container().text('');
- this._container().attr('style', 'background-image: url(\'' + linkUrl + '\');');
+ if (linkUrl && linkUrl !== 'http://') {
+ this._container().text('');
+ this._container().attr('style', 'background-image: url(\'' + linkUrl + '\');');
+ } else {
+ this._container().text(gettext('No image. Click here to add image'));
+ }
},
changeLink: function(e) {
prePasteHandler: function(text) {
return this.wlxmlNode.document.getLinkForUrl(text);
}.bind(this),
- description: '<a href="#-" class="attachment-library">attachment library</a>'
+ description: '<a href="#-" class="attachment-library">' + gettext('attachment library') + '</a>'
}
]
});