管理者、user-upload
33,346
回編集
(一部内容を最新の記述方法に合わせて更新) |
細編集の要約なし |
||
(3人の利用者による、間の10版が非表示) | |||
1行目: | 1行目: | ||
// <nowiki> | |||
function customizeToolbar() { | function customizeToolbar() { | ||
$('#wpTextbox1').wikiEditor('addToToolbar', { | $('#wpTextbox1').wikiEditor('addToToolbar', { | ||
7行目: | 9行目: | ||
deferLoad: true, | deferLoad: true, | ||
pages: { | pages: { | ||
' | 'headers': { | ||
'layout': 'characters', | 'layout': 'characters', | ||
'label': ' | 'label': 'ヘッダ要素', | ||
'characters': [ | 'characters': [ | ||
{ | { | ||
label: ' | label: '{{グループ情報}}', | ||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: ' | pre: '{{グループ情報\n| グループ名 = \n| 画像 = \n| 関連ページ = \n| 活動期間 = \n| チーム = \n| レーベル = \n| 総合プロデューサー = \n| 公式サイト = \n}}', | ||
ownline: true | |||
} | } | ||
} | } | ||
}, | }, | ||
{ | { | ||
label: '{{ | label: '{{ユニット情報}}', | ||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{ | pre: '{{ユニット情報\n| 名前 = \n| 画像 = \n| 活動期間 = \n| レーベル = \n| 事務所 = \n| 公式サイト = \n| メンバー = \n| 旧メンバー = \n}}', | ||
ownline: true | |||
} | } | ||
} | } | ||
}, | }, | ||
{ | { | ||
label: '{{ | label: '{{メンバー情報}}', | ||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{ | pre: '{{メンバー情報\n| グループ = \n| チーム = \n| 名前 = \n| 読み = \n| 画像 = \n| 公式ニックネーム = \n| 所属事務所 = \n| 生年月日 = \n| 出身地 = \n| 血液型 = \n| 身長 = \n| 体重 = \n| スリーサイズ = \n| 靴のサイズ = \n| 合格期 = \n| 所属ユニット = \n| 選抜回数 = \n| サイリウム = \n}}', | ||
ownline: true | |||
} | } | ||
} | } | ||
}, | }, | ||
{ | { | ||
label: '{{ | label: '{{関係者情報}}', | ||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{ | pre: '{{関係者情報\n| 名前 = \n| 読み = \n| 役職 = \n| bgcolor = \n| 画像 = \n| ニックネーム = \n| 所属事務所 = \n| 生年月日 = \n| 出身地 = \n| 血液型 = \n| 身長 = \n| 体重 = \n}}', | ||
ownline: true | ownline: true | ||
} | } | ||
67行目: | 54行目: | ||
}, | }, | ||
{ | { | ||
label: '{{ | label: '{{シングル情報}}', | ||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{ | pre: '{{シングル情報\n| タイトル = \n| アーティスト = \n| 通算枚数 = \n| 区分 = シングル\n| 画像 = \n| 発売日 = \n| レーベル = \n| 選抜人数 = \n| 販売形態 = \n| 週間ランキング = \n| 初週売上 = \n| 月間ランキング = \n| 初月売上 = \n| 年間ランキング = \n| 売上枚数 = \n| 前作 = \n| 次作 = \n}}', | ||
ownline: true | ownline: true | ||
} | } | ||
78行目: | 64行目: | ||
}, | }, | ||
{ | { | ||
label: '{{ | label: '{{アルバム情報}}', | ||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{ | pre: '{{アルバム情報\n| タイトル = \n| アーティスト = \n| 通算枚数 = \n| 区分 = シングル\n| 画像 = \n| 発売日 = \n| レーベル = \n| 選抜人数 = \n| 販売形態 = \n| 週間ランキング = \n| 初週売上 = \n| 月間ランキング = \n| 初月売上 = \n| 年間ランキング = \n| 売上枚数 = \n| 前作 = \n| 次作 = \n}}', | ||
ownline: true | ownline: true | ||
} | } | ||
89行目: | 74行目: | ||
}, | }, | ||
{ | { | ||
label: '{{ | label: '{{楽曲情報}}', | ||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{ | pre: '{{楽曲情報\n| タイトル = \n| 名義 = \n| 画像 = \n| 作詞 = \n| 作曲 = \n| 編曲 = \n| YouTube = \n| MV監督 = \n| 振付 = \n| タイアップ = \n}}', | ||
ownline: true | ownline: true | ||
} | } | ||
100行目: | 84行目: | ||
}, | }, | ||
{ | { | ||
label: '{{ | label: '[[ファイル:<ファイル名>|250px]]', | ||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[ファイル:', | |||
post: '|250px]]' | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{書きかけ}}', | |||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{ | pre: '{{書きかけ}}', | ||
ownline: true | ownline: true | ||
} | } | ||
115行目: | 108行目: | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{編集者希望 | pre: '{{編集者希望}}', | ||
ownline: true | ownline: true | ||
} | } | ||
126行目: | 118行目: | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{情報希望| | pre: '{{情報希望|', | ||
post: '}}', | post: '}}', | ||
ownline: true | ownline: true | ||
137行目: | 129行目: | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{更新 | pre: '{{更新}}', | ||
ownline: true | ownline: true | ||
} | } | ||
148行目: | 139行目: | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{雑多| | pre: '{{雑多}}', | ||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{発売前}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{発売前|', | |||
post: '}}', | post: '}}', | ||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{予定}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{予定}}', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{最新の出来事}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{最新の出来事}}', | |||
ownline: true | ownline: true | ||
} | } | ||
159行目: | 180行目: | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{最終更新| | pre: '{{最終更新}}', | ||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{出典明記}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{出典明記}}', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{編集合戦}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{編集合戦}}', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{保護中}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{保護中|reason=', | |||
post: '}}', | post: '}}', | ||
ownline: true | ownline: true | ||
} | |||
} | |||
}, | |||
] | |||
}, | |||
'templates': { | |||
'layout': 'characters', | |||
'label': '編集用テンプレート', | |||
'characters': [ | |||
{ | |||
label: '{{要出典}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{要出典}}' | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{要出典|}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{要出典|', | |||
post: '}}' | |||
} | |||
} | |||
}, | |||
{ | |||
label: '<ref></ref>', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '<ref>', | |||
post: '</ref>' | |||
} | |||
} | |||
}, | |||
{ | |||
label: '<ref name=""></ref>', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '<ref name="">', | |||
post: '</ref>' | |||
} | } | ||
} | } | ||
}, | }, | ||
{ | { | ||
label: '{{ | label: '{{出典 Google+|url= |by= |date= }}', | ||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{出典 Google+|url=', | |||
post: '|by=|date=}}' | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{注釈}}', | |||
action: { | action: { | ||
type: 'encapsulate', | type: 'encapsulate', | ||
options: { | options: { | ||
pre: '{{ | pre: '{{注釈|', | ||
post: ' | post: '}}' | ||
} | } | ||
} | } | ||
178行目: | 283行目: | ||
] | ] | ||
}, | }, | ||
'footers': { | |||
layout: ' | 'layout': 'characters', | ||
label: 'フッタ要素', | 'label': 'フッタ要素', | ||
'characters': [ | |||
{ | { | ||
label: '== 注釈 ==', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '== 注釈 ==\n<references group="注釈" />', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '== 出典 ==', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '== 出典 ==\n<references />', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '{{DEFAULTSORT:}}', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '{{DEFAULTSORT:', | |||
post: '}}', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '[[カテゴリ:]]', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[カテゴリ:', | |||
post: ']]', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '[[jawp:]]', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[jawp:', | |||
post: ']]', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '[[akb49:]]', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[akb49:', | |||
post: ']]', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '[[stage48:]]', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[stage48:', | |||
post: ']]', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | |||
label: '[[akb48wikia:]]', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[akb48wikia:', | |||
post: ']]', | |||
ownline: true | |||
} | |||
} | |||
}, | |||
{ | { | ||
label: '[[nogipedia:]]', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[nogipedia:', | |||
post: ']]', | |||
ownline: true | |||
} | |||
} | |||
}, | }, | ||
{ | { | ||
label: '[[baidu:]]', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[baidu:', | |||
post: ']]', | |||
ownline: true | |||
} | |||
} | |||
}, | }, | ||
{ | { | ||
label: '[[namuwiki:]]', | |||
action: { | |||
type: 'encapsulate', | |||
options: { | |||
pre: '[[namuwiki:', | |||
post: ']]', | |||
ownline: true | |||
} | |||
} | |||
}, | }, | ||
] | ] | ||
226行目: | 420行目: | ||
name: { html: 'グループ<br>グループ<i>n</i>' }, | name: { html: 'グループ<br>グループ<i>n</i>' }, | ||
example: { html: 'AKB48' }, | example: { html: 'AKB48' }, | ||
description: { html: ' | description: { html: '所属グループ' } | ||
}, | }, | ||
{ | { | ||
name: { html: 'チーム<br>チーム<i>n</i>' }, | name: { html: 'チーム<br>チーム<i>n</i>' }, | ||
example: { html: ' | example: { html: 'チームA、研究生' }, | ||
description: { html: '「グループ」に対応する所属チーム | description: { html: '「グループ」に対応する所属チーム' } | ||
}, | }, | ||
{ | { | ||
name: { html: ' | name: { html: '元グループ<br>元グループ<i>n</i>' }, | ||
example: { html: '' }, | example: { html: 'AKB48' }, | ||
description: { html: ' | description: { html: '過去の所属グループ<br>現在48・46グループに所属している場合は入力しない' } | ||
}, | }, | ||
{ | { | ||
384行目: | 573行目: | ||
/* Check if view is in edit mode and that the required modules are available. Then, customize the toolbar . . . */ | /* Check if view is in edit mode and that the required modules are available. Then, customize the toolbar . . . */ | ||
if ( $.inArray( mw.config.get( 'wgAction' ), [ 'edit', 'submit' ] ) !== -1 ) { | if ( $.inArray( mw.config.get( 'wgAction' ), [ 'edit', 'submit' ] ) !== -1 ) { | ||
mw.loader.using( 'user.options' | mw.loader.using( 'user.options').then( function() { | ||
if ( mw.user.options.get( 'usebetatoolbar | if ( mw.user.options.get( 'usebetatoolbar' ) == 1 ) { | ||
$.when( | $.when( | ||
mw.loader.using( 'ext.wikiEditor | mw.loader.using( 'ext.wikiEditor' ), | ||
$.ready | $.ready | ||
).then( customizeToolbar ); | ).then( customizeToolbar ); | ||
393行目: | 582行目: | ||
} ); | } ); | ||
} | } | ||
// </nowiki> |