Remove auto linkify image since it might print out unwanted url and it can be achieved by reference syntax, issue #214
This commit is contained in:
parent
fe912f73ec
commit
70a52e2eae
1 changed files with 1 additions and 11 deletions
|
@ -352,19 +352,9 @@ function finishView(view) {
|
|||
images.each(function (key, value) {
|
||||
// if it's already wrapped by link, then ignore
|
||||
var $value = $(value);
|
||||
if ($value.parent()[0].nodeName === 'A') return;
|
||||
var src = $(value).attr('src');
|
||||
var a = $('<a>');
|
||||
if (src) {
|
||||
a.attr('href', src);
|
||||
a.attr('target', "_blank");
|
||||
}
|
||||
var clone = $value.clone();
|
||||
clone[0].onload = function (e) {
|
||||
$value[0].onload = function (e) {
|
||||
if(viewAjaxCallback) viewAjaxCallback();
|
||||
};
|
||||
a.html(clone);
|
||||
$value.replaceWith(a);
|
||||
});
|
||||
//blockquote
|
||||
var blockquote = view.find("blockquote.raw").removeClass("raw");
|
||||
|
|
Loading…
Reference in a new issue