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

“MediaWiki:Gadget-inspect.js”的版本间差异

跳转到导航 跳转到搜索
添加288字节 、​ 2021年1月8日 (五) 04:54
无编辑摘要
mw.request = mw.request || mw.standardQuery(api);
// 标注<p>标签
const css = mw.util.addCSS( '#mw-content-text .mw-parser-output pempty { border:1px dashedsolid rgba(253,220,154,0.5); box-shadow:0 0 0.5em #fddc9a; }' +
// 解决<ul>等元素文字不换行的问题
'#mw-content-text .mw-parser-output { display:flow-root; overflow:hidden; word-wrap:break-word; }' );
if (confirm) { editor.setValue( backupContent ); }
});
},
pEmpty = function($div) {
$div.find( 'p:not(:has(script))' ).filter(function() { return !/\S/.test( this.textContent ); })
.addClass('empty');
},
$placeholder = $('<div>', {class: "mw-parser-output"}).css('display', 'none'), // 用于替换时保留原始数据
if ($.contains( $content[0], $original[0] )) { $original.after( $placeholder ).detach(); }
$content.children( '.mw-parser-output' ).replaceWith( html );
pEmpty( $content.children( '.mw-parser-output' ) );
if (mw.resizeLyrics) { mw.resizeLyrics(); }
mw.hook( 'wikipage.content' ).fire($content);
}).children('a').blur(function() { menu.addClass( 'oo-ui-element-hidden' ); });
}
pEmpty( $original );
$.when(getJSON, mw.request).then(function(config, data) {
console.log('End API request: 已获得页面Wikitext');
16,874

个编辑

导航菜单