16,874
个编辑
LLWiki正在建设中,欢迎加入我们!
小 |
小 |
||
lineWrapping: true, lineNumbers: true});
wrapper = $( editor.getWrapperElement() ).toggle();
$('<div>', {id: 'inspector-btns', html: btns.map(function(ele) { return ele.$element; })}).appendTo( outer );
$('.diff').click(function(e) {
isLineno = row.children( '.diff-lineno' ).length ? 1 : 0,
rowLineno = isLineno ? row : row.prevAll( ':has(.diff-lineno)' ).first(),
n = parseInt( rowLineno.children().last().text().match(/\d+/) )
if (nLine >=
editor.scrollIntoView(nLine);
editor.scrollIntoView(n);
}
else { mw.notify( wgULS('当前不存在该行!', '當前不存在該行!'), {type: 'warn'} ); }
});
}, function(reason) { mw.apiFailure(reason, 'CodeMirror' + wgULS('设置或页面', '設置或頁面') + 'Wikitext'); });
|