LLWiki正在建设中,欢迎加入我们

“User:Bhsd/edit.js”的版本间差异

跳转到导航 跳转到搜索
// 修改WikiEditor的替换文本框
if (['edit', 'submit'].includes( action ) && skin == 'vector') {
$(this'body').replaceWith( $on('<textarea>click', {id: "'input#wikieditor-toolbar-replace-replace"', tabindex:10}function() {
mw.loader.using( 'jquery.textSelection' ).then(() => {
$('body'this).onreplaceWith( $('click<textarea>', 'input#{id: "wikieditor-toolbar-replace-replace'", function(tabindex:10}) {
}).keypresson('keydown keypress', e => { if (e.keyCode == '13') { e.stopPropagation(); } }) );
$(this).replaceWith( $('<textarea>', {id: "wikieditor-toolbar-replace-replace", tabindex:10})
.keydown(function(e) {
if (e.keyCode == '13') {
e.stopPropagation();
$(this).textSelection( 'replaceSelection', '\n' );
}
}).keypress(e => { if (e.keyCode == '13') { e.stopPropagation(); } }) );
});
});
}