6,514
回編集
(タブを非表示にする選択肢を追加) |
(withCSSをMediwWiki:Common.jsから移植) |
||
2行目: | 2行目: | ||
mw.hook('wikipage.content').add(function() { | mw.hook('wikipage.content').add(function() { | ||
/* URLのwithCSSパラメータで、追加のスタイルシートを読み込む */ | |||
var extraCSS = mw.util.getParamValue('withCSS'); | |||
if (extraCSS && extraCSS.match(/\.css$/)) { | |||
mw.loader.load(mw.config.get('wgServer') + mw.config.get('wgScript') + | |||
'?action=raw&ctype=text/css&title=' + | |||
mw.util.wikiUrlencode(extraCSS), 'text/css'); | |||
} | |||
/* [[テンプレート:折り畳みボックス]] */ | /* [[テンプレート:折り畳みボックス]] */ |