User:逆襲的天邪鬼/Twinkle-lzh/twinklewarn.js: Difference between revisions
Content added Content deleted
(Created page with "//<nowiki> // vim: set noet sts=0 sw=8: (function($){ /* **************************************** *** twinklewarn.js: Warn module **************************************...") |
No edit summary |
||
Line 18: | Line 18: | ||
Twinkle.warn = function twinklewarn() { |
Twinkle.warn = function twinklewarn() { |
||
if ( Morebits.wiki.flow.relevantUserName() ) { |
if ( Morebits.wiki.flow.relevantUserName() ) { |
||
Twinkle.addPortletLink( Twinkle.warn.callback, "警告", "tw-warn", "警告或提醒用 |
Twinkle.addPortletLink( Twinkle.warn.callback, "警告", "tw-warn", "警告或提醒用戶" ); |
||
} |
} |
||
Line 41: | Line 41: | ||
Twinkle.warn.callback = function twinklewarnCallback() { |
Twinkle.warn.callback = function twinklewarnCallback() { |
||
if( Morebits.wiki.flow.relevantUserName() === mw.config.get( 'wgUserName' ) && |
if( Morebits.wiki.flow.relevantUserName() === mw.config.get( 'wgUserName' ) && |
||
!confirm( '您 |
!confirm( '您將要警告自己!您確定要繼續嗎?' ) ) { |
||
return; |
return; |
||
} |
} |
||
var Window = new Morebits.simpleWindow( 600, 440 ); |
var Window = new Morebits.simpleWindow( 600, 440 ); |
||
Window.setTitle( "警告、通知用 |
Window.setTitle( "警告、通知用戶" ); |
||
Window.setScriptName( "Twinkle" ); |
Window.setScriptName( "Twinkle" ); |
||
Window.addFooterLink( "选择警告级别", "WP:WARN" ); |
|||
Window.addFooterLink( "Twinkle帮助", "WP:TW/DOC#warn" ); |
|||
var form = new Morebits.quickForm( Twinkle.warn.callback.evaluate ); |
var form = new Morebits.quickForm( Twinkle.warn.callback.evaluate ); |
||
var main_select = form.append( { |
var main_select = form.append( { |
||
type: 'field', |
type: 'field', |
||
label: ' |
label: '選擇警告或通知類別', |
||
tooltip: ' |
tooltip: '選擇具體的警告模板。' |
||
} ); |
} ); |
||
main_select.append( { type: 'select', name: 'sub_group' } ); |
|||
Twinkle.warn.callback.create_category(); |
|||
type: 'select', |
|||
name: 'main_group', |
|||
event:Twinkle.warn.callback.change_category |
|||
} ); |
|||
var defaultGroup = parseInt(Twinkle.getPref('defaultWarningGroup'), 10); |
|||
main_group.append( { type: 'option', label: '层级1', value: 'level1', selected: ( defaultGroup === 1 || defaultGroup < 1 || ( Morebits.userIsInGroup( 'sysop' ) ? defaultGroup > 8 : defaultGroup > 7 ) ) } ); |
|||
main_group.append( { type: 'option', label: '层级2', value: 'level2', selected: ( defaultGroup === 2 ) } ); |
|||
main_group.append( { type: 'option', label: '层级3', value: 'level3', selected: ( defaultGroup === 3 ) } ); |
|||
main_group.append( { type: 'option', label: '层级4', value: 'level4', selected: ( defaultGroup === 4 ) } ); |
|||
main_group.append( { type: 'option', label: '层级4im', value: 'level4im', selected: ( defaultGroup === 5 ) } ); |
|||
main_group.append( { type: 'option', label: '单层级通知', value: 'singlenotice', selected: ( defaultGroup === 6 ) } ); |
|||
main_group.append( { type: 'option', label: '单层级警告', value: 'singlewarn', selected: ( defaultGroup === 7 ) } ); |
|||
if( Twinkle.getPref( 'customWarningList' ).length ) { |
|||
main_group.append( { type: 'option', label: '自定义警告', value: 'custom', selected: ( defaultGroup === 9 ) } ); |
|||
} |
|||
main_select.append( { type: 'select', name: 'sub_group', event:Twinkle.warn.callback.change_subcategory } ); //Will be empty to begin with. |
|||
form.append( { |
form.append( { |
||
type: 'input', |
|||
name: 'article', |
|||
label: '條目連結', |
|||
value:( Morebits.queryString.exists( 'vanarticle' ) ? Morebits.queryString.get( 'vanarticle' ) : '' ), |
|||
tooltip: '給模板中加入一個條目連結,可留空。' |
|||
} ); |
|||
var more = form.append( { type: 'field', name: 'reasonGroup', label: '警告信息' } ); |
var more = form.append( { type: 'field', name: 'reasonGroup', label: '警告信息' } ); |
||
more.append( { type: 'textarea', label: '可 |
more.append( { type: 'textarea', label: '可選信息:', name: 'reason', tooltip: '理由或是附加信息' } ); |
||
var previewlink = document.createElement( 'a' ); |
var previewlink = document.createElement( 'a' ); |
||
Line 94: | Line 75: | ||
}); |
}); |
||
previewlink.style.cursor = "pointer"; |
previewlink.style.cursor = "pointer"; |
||
previewlink.textContent = ' |
previewlink.textContent = '預覽'; |
||
more.append( { type: 'div', id: 'warningpreview', label: [ previewlink ] } ); |
more.append( { type: 'div', id: 'warningpreview', label: [ previewlink ] } ); |
||
more.append( { type: 'div', id: 'twinklewarn-previewbox', style: 'display: none' } ); |
more.append( { type: 'div', id: 'twinklewarn-previewbox', style: 'display: none' } ); |
||
Line 118: | Line 99: | ||
// suppressArticleInSummary (optional): Set to true to suppress showing the article name in the edit summary. Useful if the warning relates to attack pages, or some such. |
// suppressArticleInSummary (optional): Set to true to suppress showing the article name in the edit summary. Useful if the warning relates to attack pages, or some such. |
||
Twinkle.warn.messages = { |
Twinkle.warn.messages = { |
||
"非建設編輯": { |
|||
level1: { |
|||
"uw-vandalism1": { |
|||
"不同类型的非建设编辑": { |
|||
label: "毀文觀(提醒)", |
|||
"uw-vandalism1": { |
|||
summary: "毀文觀(提醒)" |
|||
label: "破坏", |
|||
summary: "层级1:破坏" |
|||
}, |
|||
"uw-test1": { |
|||
label: "编辑测试", |
|||
summary: "层级1:编辑测试" |
|||
}, |
|||
"uw-delete1": { |
|||
label: "清空页面、移除内容或模板", |
|||
summary: "层级1:清空页面、移除内容或模板" |
|||
}, |
|||
"uw-redirect1": { |
|||
label: "创建恶意重定向", |
|||
summary: "层级1:创建恶意重定向" |
|||
}, |
|||
"uw-tdel1": { |
|||
label: "移除维护性模板", |
|||
summary: "层级1:移除维护性模板" |
|||
}, |
|||
"uw-joke1": { |
|||
label: "加入不当玩笑", |
|||
summary: "层级1:加入不当玩笑" |
|||
}, |
|||
"uw-create1": { |
|||
label: "创建不当页面", |
|||
summary: "层级1:创建不当页面" |
|||
}, |
|||
"uw-upload1": { |
|||
label: "上传不当图像", |
|||
summary: "层级1:上传不当图像" |
|||
}, |
|||
"uw-image1": { |
|||
label: "与图像相关之破坏", |
|||
summary: "层级1:与图像相关之破坏" |
|||
} |
|||
}, |
}, |
||
" |
"uw-vandalism2": { |
||
label: "毀文觀(警告)", |
|||
"uw-spam1": { |
|||
summary: "毀文觀(警告)" |
|||
label: "增加垃圾连结", |
|||
summary: "层级1:增加垃圾连结" |
|||
}, |
|||
"uw-advert1": { |
|||
label: "利用维基百科来发布广告或推广", |
|||
summary: "层级1:利用维基百科来发布广告或推广" |
|||
}, |
|||
"uw-npov1": { |
|||
label: "不遵守中立的观点方针", |
|||
summary: "层级1:不遵守中立的观点方针" |
|||
} |
|||
}, |
}, |
||
"uw-vandalism3": { |
|||
"加插不实及/或诽谤文字": { |
|||
label: "毀文觀(最後警告)", |
|||
"uw-unsourced1": { |
|||
summary: "毀文觀(最後警告)" |
|||
label: "没有使用适当的引用方法而增加没有来源的资料", |
|||
summary: "层级1:没有使用适当的引用方法而增加没有来源的资料" |
|||
}, |
|||
"uw-error1": { |
|||
label: "故意加入不实内容", |
|||
summary: "层级1:故意加入不实内容" |
|||
}, |
|||
"uw-biog1": { |
|||
label: "加入有关在生人物而又缺乏来源的资料", |
|||
summary: "层级1:加入有关在生人物而又缺乏来源的资料" |
|||
}, |
|||
"uw-defamatory1": { |
|||
label: "没有特定目标的诽谤", |
|||
summary: "层级1:没有特定目标的诽谤" |
|||
} |
|||
}, |
}, |
||
"翻译品质": { |
|||
"uw-roughtranslation1": { |
|||
label: "粗劣翻译", |
|||
summary: "层级1:粗劣翻译" |
|||
} |
|||
}, |
|||
"非能接受且违反方针或指引的单方面行为或操作": { |
|||
"uw-notcensored1": { |
|||
label: "资料的审查", |
|||
summary: "层级1:资料的审查" |
|||
}, |
|||
"uw-mos1": { |
|||
label: "格式、日期、语言等", |
|||
summary: "层级1:格式、日期、语言等" |
|||
}, |
|||
"uw-move1": { |
|||
label: "页面移动", |
|||
summary: "层级1:页面移动" |
|||
}, |
|||
"uw-cd1": { |
|||
label: "把讨论页清空", |
|||
summary: "层级1:把讨论页清空" |
|||
}, |
|||
"uw-chat1": { |
|||
label: "把讨论页当为论坛", |
|||
summary: "层级1:把讨论页当为论坛" |
|||
}, |
|||
"uw-tpv1": { |
|||
label: "改写其他用户在讨论页留下的意见", |
|||
summary: "层级1:改写其他用户在讨论页留下的意见" |
|||
}, |
|||
"uw-afd1": { |
|||
label: "移除{{afd}}模板", |
|||
summary: "层级1:移除{{afd}}模板" |
|||
}, |
|||
"uw-speedy1": { |
|||
label: "移除{{delete}}模板", |
|||
summary: "层级1:移除{{delete}}模板" |
|||
} |
|||
}, |
|||
"对其他用户和条目的态度": { |
|||
"uw-npa1": { |
|||
label: "针对特定用户的人身攻击", |
|||
summary: "层级1:针对特定用户的人身攻击" |
|||
}, |
|||
"uw-agf1": { |
|||
label: "没有善意推定", |
|||
summary: "层级1:没有善意推定" |
|||
}, |
|||
"uw-own1": { |
|||
label: "条目的所有权", |
|||
summary: "层级1:条目的所有权" |
|||
}, |
|||
"uw-tempabuse1": { |
|||
label: "不当使用警告或封锁模板", |
|||
summary: "层级1:不当使用警告或封锁模板" |
|||
} |
|||
} |
|||
}, |
}, |
||
"文法": { |
|||
"uw-lzh1": { |
|||
label: "非文言", |
|||
level2: { |
|||
summary: "非文言" |
|||
"不同类型的非建设编辑": { |
|||
"uw-vandalism2": { |
|||
label: "破坏", |
|||
summary: "层级2:破坏" |
|||
}, |
|||
"uw-test2": { |
|||
label: "编辑测试", |
|||
summary: "层级2:编辑测试" |
|||
}, |
|||
"uw-delete2": { |
|||
label: "清空页面、移除内容或模板", |
|||
summary: "层级2:清空页面、移除内容或模板" |
|||
}, |
|||
"uw-redirect2": { |
|||
label: "创建恶意重定向", |
|||
summary: "层级2:创建恶意重定向" |
|||
}, |
|||
"uw-tdel2": { |
|||
label: "移除维护性模板", |
|||
summary: "层级2:移除维护性模板" |
|||
}, |
|||
"uw-joke2": { |
|||
label: "加入不当玩笑", |
|||
summary: "层级2:加入不当玩笑" |
|||
}, |
|||
"uw-create2": { |
|||
label: "创建不当页面", |
|||
summary: "层级2:创建不当页面" |
|||
}, |
|||
"uw-upload2": { |
|||
label: "上传不当图像", |
|||
summary: "层级2:上传不当图像" |
|||
}, |
|||
"uw-image2": { |
|||
label: "与图像相关之破坏", |
|||
summary: "层级2:与图像相关之破坏" |
|||
} |
|||
}, |
}, |
||
" |
"uw-lzh2": { |
||
label: "非文言(最後警告)", |
|||
"uw-spam2": { |
|||
summary: "非文言(最後警告)" |
|||
label: "增加垃圾连结", |
|||
summary: "层级2:增加垃圾连结" |
|||
}, |
|||
"uw-advert2": { |
|||
label: "利用维基百科来发布广告或推广", |
|||
summary: "层级2:利用维基百科来发布广告或推广" |
|||
}, |
|||
"uw-npov2": { |
|||
label: "不遵守中立的观点方针", |
|||
summary: "层级2:不遵守中立的观点方针" |
|||
} |
|||
}, |
}, |
||
"uw-lzh-en": { |
|||
"加插不实及/或诽谤文字": { |
|||
label: "非文言(英文警告)", |
|||
"uw-unsourced2": { |
|||
summary: "非文言/Not Classical Chinese(Warning)" |
|||
label: "没有使用适当的引用方法而增加没有来源的资料", |
|||
summary: "层级2:没有使用适当的引用方法而增加没有来源的资料" |
|||
}, |
|||
"uw-error2": { |
|||
label: "故意加入不实内容", |
|||
summary: "层级2:故意加入不实内容" |
|||
}, |
|||
"uw-biog2": { |
|||
label: "加入有关在生人物而又缺乏来源的资料", |
|||
summary: "层级2:加入有关在生人物而又缺乏来源的资料" |
|||
}, |
|||
"uw-defamatory2": { |
|||
label: "没有特定目标的诽谤", |
|||
summary: "层级2:没有特定目标的诽谤" |
|||
} |
|||
}, |
}, |
||
" |
"uw-lzh-en-2": { |
||
label: "非文言(英文最後警告)", |
|||
"uw-roughtranslation2": { |
|||
summary: "非文言/Not Classical Chinese(Final Warning)" |
|||
label: "粗劣翻译", |
|||
summary: "层级2:粗劣翻译" |
|||
} |
|||
}, |
}, |
||
"uw-simp": { |
|||
"非能接受且违反方针或指引的单方面行为或操作": { |
|||
label: "簡體字", |
|||
"uw-notcensored2": { |
|||
summary: "簡體字" |
|||
summary: "层级2:资料的审查" |
|||
}, |
|||
"uw-mos2": { |
|||
label: "格式、日期、语言等", |
|||
summary: "层级2:格式、日期、语言等" |
|||
}, |
|||
"uw-move2": { |
|||
label: "页面移动", |
|||
summary: "层级2:页面移动" |
|||
}, |
|||
"uw-cd2": { |
|||
label: "把讨论页清空", |
|||
summary: "层级2:把讨论页清空" |
|||
}, |
|||
"uw-chat2": { |
|||
label: "把讨论页当为论坛", |
|||
summary: "层级2:把讨论页当为论坛" |
|||
}, |
|||
"uw-tpv2": { |
|||
label: "改写其他用户在讨论页留下的意见", |
|||
summary: "层级2:改写其他用户在讨论页留下的意见" |
|||
}, |
|||
"uw-afd2": { |
|||
label: "移除{{afd}}模板", |
|||
summary: "层级2:移除{{afd}}模板" |
|||
}, |
|||
"uw-speedy2": { |
|||
label: "移除{{delete}}模板", |
|||
summary: "层级2:移除{{delete}}模板" |
|||
} |
|||
}, |
}, |
||
"uw-blp": { |
|||
"对其他用户和条目的态度": { |
|||
label: "生不立傳", |
|||
"uw-npa2": { |
|||
summary: "生不立傳" |
|||
label: "针对特定用户的人身攻击", |
|||
summary: "层级2:针对特定用户的人身攻击" |
|||
}, |
|||
"uw-agf2": { |
|||
label: "没有善意推定", |
|||
summary: "层级2:没有善意推定" |
|||
}, |
|||
"uw-own2": { |
|||
label: "条目的所有权", |
|||
summary: "层级2:条目的所有权" |
|||
}, |
|||
"uw-tempabuse2": { |
|||
label: "不当使用警告或封锁模板", |
|||
summary: "层级2:不当使用警告或封锁模板" |
|||
} |
|||
} |
|||
}, |
|||
level3: { |
|||
"不同类型的非建设编辑": { |
|||
"uw-vandalism3": { |
|||
label: "破坏", |
|||
summary: "层级3:破坏" |
|||
}, |
|||
"uw-test3": { |
|||
label: "编辑测试", |
|||
summary: "层级3:编辑测试" |
|||
}, |
|||
"uw-delete3": { |
|||
label: "清空页面、移除内容或模板", |
|||
summary: "层级3:清空页面、移除内容或模板" |
|||
}, |
|||
"uw-redirect3": { |
|||
label: "创建恶意重定向", |
|||
summary: "层级3:创建恶意重定向" |
|||
}, |
|||
"uw-tdel3": { |
|||
label: "移除维护性模板", |
|||
summary: "层级3:移除维护性模板" |
|||
}, |
|||
"uw-joke3": { |
|||
label: "加入不当玩笑", |
|||
summary: "层级3:加入不当玩笑" |
|||
}, |
|||
"uw-create3": { |
|||
label: "创建不当页面", |
|||
summary: "层级3:创建不当页面" |
|||
}, |
|||
"uw-upload3": { |
|||
label: "上传不当图像", |
|||
summary: "层级3:上传不当图像" |
|||
}, |
|||
"uw-image3": { |
|||
label: "与图像相关之破坏", |
|||
summary: "层级3:与图像相关之破坏" |
|||
} |
|||
}, |
}, |
||
"增加商品或政治广告": { |
|||
"uw-spam3": { |
|||
label: "增加垃圾连结", |
|||
summary: "层级3:增加垃圾连结" |
|||
}, |
|||
"uw-advert3": { |
|||
label: "利用维基百科来发布广告或推广", |
|||
summary: "层级3:利用维基百科来发布广告或推广" |
|||
}, |
|||
"uw-npov3": { |
|||
label: "不遵守中立的观点方针", |
|||
summary: "层级3:不遵守中立的观点方针" |
|||
} |
|||
}, |
|||
"加插不实及/或诽谤文字": { |
|||
"uw-unsourced3": { |
|||
label: "没有使用适当的引用方法而增加没有来源的资料", |
|||
summary: "层级3:没有使用适当的引用方法而增加没有来源的资料" |
|||
}, |
|||
"uw-error3": { |
|||
label: "故意加入不实内容", |
|||
summary: "层级3:故意加入不实内容" |
|||
}, |
|||
"uw-biog3": { |
|||
label: "加入有关在生人物而又缺乏来源的资料", |
|||
summary: "层级3:加入有关在生人物而又缺乏来源的资料" |
|||
}, |
|||
"uw-defamatory3": { |
|||
label: "没有特定目标的诽谤", |
|||
summary: "层级3:没有特定目标的诽谤" |
|||
} |
|||
}, |
|||
"翻译品质": { |
|||
"uw-roughtranslation3": { |
|||
label: "粗劣翻译", |
|||
summary: "层级3:粗劣翻译" |
|||
} |
|||
}, |
|||
"非能接受且违反方针或指引的单方面行为或操作": { |
|||
"uw-notcensored3": { |
|||
label: "资料的审查", |
|||
summary: "层级3:资料的审查" |
|||
}, |
|||
"uw-mos3": { |
|||
label: "格式、日期、语言等", |
|||
summary: "层级3:格式、日期、语言等" |
|||
}, |
|||
"uw-move3": { |
|||
label: "页面移动", |
|||
summary: "层级3:页面移动" |
|||
}, |
|||
"uw-cd3": { |
|||
label: "把讨论页清空", |
|||
summary: "层级3:把讨论页清空" |
|||
}, |
|||
"uw-chat3": { |
|||
label: "把讨论页当为论坛", |
|||
summary: "层级3:把讨论页当为论坛" |
|||
}, |
|||
"uw-tpv3": { |
|||
label: "改写其他用户在讨论页留下的意见", |
|||
summary: "层级3:改写其他用户在讨论页留下的意见" |
|||
}, |
|||
"uw-afd3": { |
|||
label: "移除{{afd}}模板", |
|||
summary: "层级3:移除{{afd}}模板" |
|||
}, |
|||
"uw-speedy3": { |
|||
label: "移除{{delete}}模板", |
|||
summary: "层级3:移除{{delete}}模板" |
|||
} |
|||
}, |
|||
"对其他用户和条目的态度": { |
|||
"uw-npa3": { |
|||
label: "针对特定用户的人身攻击", |
|||
summary: "层级3:针对特定用户的人身攻击" |
|||
}, |
|||
"uw-agf3": { |
|||
label: "没有善意推定", |
|||
summary: "层级3:没有善意推定" |
|||
}, |
|||
"uw-own3": { |
|||
label: "条目的所有权", |
|||
summary: "层级3:条目的所有权" |
|||
}, |
|||
"uw-tempabuse3": { |
|||
label: "不当使用警告或封锁模板", |
|||
summary: "层级3:不当使用警告或封锁模板" |
|||
} |
|||
} |
|||
}, |
}, |
||
"態度": { |
|||
"uw-sign": { |
|||
label: "沒有簽名", |
|||
level4: { |
|||
summary: "簽名" |
|||
"不同类型的非建设编辑": { |
|||
"uw-vandalism4": { |
|||
label: "破坏", |
|||
summary: "层级4:破坏" |
|||
}, |
|||
"uw-test4": { |
|||
label: "编辑测试", |
|||
summary: "层级4:编辑测试" |
|||
}, |
|||
"uw-delete4": { |
|||
label: "清空页面、移除内容或模板", |
|||
summary: "层级4:清空页面、移除内容或模板" |
|||
}, |
|||
"uw-redirect4": { |
|||
label: "创建恶意重定向", |
|||
summary: "层级4:创建恶意重定向" |
|||
}, |
|||
"uw-tdel4": { |
|||
label: "移除维护性模板", |
|||
summary: "层级4:移除维护性模板" |
|||
}, |
|||
"uw-joke4": { |
|||
label: "加入不当玩笑", |
|||
summary: "层级4:加入不当玩笑" |
|||
}, |
|||
"uw-create4": { |
|||
label: "创建不当页面", |
|||
summary: "层级4:创建不当页面" |
|||
}, |
|||
"uw-upload4": { |
|||
label: "上传不当图像", |
|||
summary: "层级4:上传不当图像" |
|||
}, |
|||
"uw-image4": { |
|||
label: "与图像相关之破坏", |
|||
summary: "层级4:与图像相关之破坏" |
|||
} |
|||
}, |
}, |
||
" |
"uw-civil1": { |
||
label: "不文明(提醒)", |
|||
"uw-spam4": { |
|||
summary: "不文明(提醒)" |
|||
label: "增加垃圾连结", |
|||
summary: "层级4:增加垃圾连结" |
|||
}, |
|||
"uw-advert4": { |
|||
label: "利用维基百科来发布广告或推广", |
|||
summary: "层级4:利用维基百科来发布广告或推广" |
|||
}, |
|||
"uw-npov4": { |
|||
label: "不遵守中立的观点方针", |
|||
summary: "层级4:不遵守中立的观点方针" |
|||
} |
|||
}, |
}, |
||
"uw-civil2": { |
|||
"加插不实及/或诽谤文字": { |
|||
label: "不文明(警告)", |
|||
"uw-biog4": { |
|||
summary: "不文明(警告)" |
|||
label: "加入有关在生人物而又缺乏来源的资料", |
|||
summary: "层级4:加入有关在生人物而又缺乏来源的资料" |
|||
}, |
|||
"uw-defamatory4": { |
|||
label: "没有特定目标的诽谤", |
|||
summary: "层级4:没有特定目标的诽谤" |
|||
} |
|||
}, |
}, |
||
"uw-editwar": { |
|||
"非能接受且违反方针或指引的单方面行为或操作": { |
|||
label: "編輯戰", |
|||
"uw-mos4": { |
|||
summary: "編輯戰" |
|||
label: "格式、日期、语言等", |
|||
summary: "层级4:格式、日期、语言等" |
|||
}, |
|||
"uw-move4": { |
|||
label: "页面移动", |
|||
summary: "层级4:页面移动" |
|||
}, |
|||
"uw-chat4": { |
|||
label: "把讨论页当为论坛", |
|||
summary: "层级4:把讨论页当为论坛" |
|||
}, |
|||
"uw-afd4": { |
|||
label: "移除{{afd}}模板", |
|||
summary: "层级4:移除{{afd}}模板" |
|||
}, |
|||
"uw-speedy4": { |
|||
label: "移除{{delete}}模板", |
|||
summary: "层级4:移除{{delete}}模板" |
|||
} |
|||
}, |
}, |
||
"uw-baduserpage": { |
|||
"对其他用户和条目的态度": { |
|||
label: "表達政治或宗教的用戶框/用戶頁", |
|||
"uw-npa4": { |
|||
summary: "政治、宗教用戶頁" |
|||
label: "针对特定用户的人身攻击", |
|||
summary: "层级4:针对特定用户的人身攻击" |
|||
}, |
|||
"uw-tempabuse4": { |
|||
label: "不当使用警告或封锁模板", |
|||
summary: "层级4:不当使用警告或封锁模板" |
|||
} |
|||
} |
} |
||
}, |
}, |
||
level4im: { |
|||
"不同类型的非建设编辑": { |
|||
"uw-vandalism4im": { |
|||
label: "破坏", |
|||
summary: "层级4im:破坏" |
|||
}, |
|||
"uw-delete4im": { |
|||
label: "清空页面、移除内容或模板", |
|||
summary: "层级4im:清空页面、移除内容或模板" |
|||
}, |
|||
"uw-redirect4im": { |
|||
label: "创建恶意重定向", |
|||
summary: "层级4im:创建恶意重定向" |
|||
}, |
|||
"uw-joke4im": { |
|||
label: "加入不当玩笑", |
|||
summary: "层级4im:加入不当玩笑" |
|||
}, |
|||
"uw-create4im": { |
|||
label: "创建不当页面", |
|||
summary: "层级4im:创建不当页面" |
|||
}, |
|||
"uw-upload4im": { |
|||
label: "上传不当图像", |
|||
summary: "层级4im:上传不当图像" |
|||
}, |
|||
"uw-image4im": { |
|||
label: "与图像相关之破坏", |
|||
summary: "层级4im:与图像相关之破坏" |
|||
} |
|||
}, |
|||
"增加商品或政治广告": { |
|||
"uw-spam4im": { |
|||
label: "增加垃圾连结", |
|||
summary: "层级4im:增加垃圾连结" |
|||
} |
|||
}, |
|||
"加插不实及/或诽谤文字": { |
|||
"uw-biog4im": { |
|||
label: "加入有关在生人物而又缺乏来源的资料", |
|||
summary: "层级4im:加入有关在生人物而又缺乏来源的资料" |
|||
}, |
|||
"uw-defamatory4im": { |
|||
label: "没有特定目标的诽谤", |
|||
summary: "层级4im:没有特定目标的诽谤" |
|||
} |
|||
}, |
|||
"非能接受且违反方针或指引的单方面行为或操作": { |
|||
"uw-move4im": { |
|||
label: "页面移动", |
|||
summary: "层级4im:页面移动" |
|||
} |
|||
}, |
|||
"对其他用户和条目的态度": { |
|||
"uw-npa4im": { |
|||
label: "针对特定用户的人身攻击", |
|||
summary: "层级4im:针对特定用户的人身攻击" |
|||
}, |
|||
"uw-tempabuse4im": { |
|||
label: "不当使用警告或封锁模板", |
|||
summary: "层级4im:不当使用警告或封锁模板" |
|||
} |
|||
} |
|||
}, |
|||
singlenotice: { |
|||
"uw-2redirect": { |
|||
label: "透过不适当的页面移动建立双重重定向", |
|||
summary: "单层级通知:透过不适当的页面移动建立双重重定向" |
|||
}, |
|||
"uw-aiv": { |
|||
label: "不恰当的破坏回报", |
|||
summary: "单层级通知:不恰当的破坏回报" |
|||
}, |
|||
"uw-articlesig": { |
|||
label: "在条目页中签名", |
|||
summary: "单层级通知:在条目页中签名" |
|||
}, |
|||
"uw-autobiography": { |
|||
label: "建立自传", |
|||
summary: "单层级通知:建立自传" |
|||
}, |
|||
"uw-badcat": { |
|||
label: "加入错误的页面分类", |
|||
summary: "单层级通知:加入错误的页面分类" |
|||
}, |
|||
"uw-bite": { |
|||
label: "伤害新手", |
|||
summary: "单层级通知:伤害新手" |
|||
}, |
|||
"uw-booktitle": { |
|||
label: "没有使用书名号来标示书籍、电影、音乐专辑等", |
|||
summary: "单层级通知:没有使用书名号来标示书籍、电影、音乐专辑等" |
|||
}, |
|||
"uw-c&pmove": { |
|||
label: "剪贴移动", |
|||
summary: "单层级通知:剪贴移动" |
|||
}, |
|||
"uw-chinese": { |
|||
label: "不是以中文进行沟通", |
|||
summary: "单层级通知:不是以中文进行沟通" |
|||
}, |
|||
"uw-coi": { |
|||
label: "利益冲突", |
|||
summary: "单层级通知:利益冲突" |
|||
}, |
|||
"uw-copyright-friendly": { |
|||
label: "初次加入侵犯版权的内容", |
|||
summary: "单层级通知:初次加入侵犯版权的内容" |
|||
}, |
|||
"uw-copyviorewrite": { |
|||
label: "在侵权页面直接重写条目", |
|||
summary: "单层级通知:在侵权页面直接重写条目" |
|||
}, |
|||
"uw-crystal": { |
|||
label: "加入臆测或未确认的讯息", |
|||
summary: "单层级通知:加入臆测或未确认的讯息" |
|||
}, |
|||
"uw-csd": { |
|||
label: "快速删除标记不当", |
|||
summary: "单层级通知:快速删除标记不当" |
|||
}, |
|||
"uw-dab": { |
|||
label: "消歧义页格式错误", |
|||
summary: "单层级通知:消歧义页格式错误" |
|||
}, |
|||
"uw-date": { |
|||
label: "不必要地更换日期格式", |
|||
summary: "单层级通知:不必要地更换日期格式" |
|||
}, |
|||
"uw-editsummary": { |
|||
label: "没有使用编辑摘要", |
|||
summary: "单层级通知:没有使用编辑摘要" |
|||
}, |
|||
"uw-hangon": { |
|||
label: "没有在讨论页说明暂缓快速删除理由", |
|||
summary: "单层级通知:没有在讨论页说明暂缓快速删除理由" |
|||
}, |
|||
"uw-lang": { |
|||
label: "不必要地将条目所有文字换成简体或繁体中文", |
|||
summary: "单层级通知:不必要地将条目所有文字换成简体或繁体中文" |
|||
}, |
|||
"uw-langmove": { |
|||
label: "不必要地将条目标题换成简体或繁体中文", |
|||
summary: "单层级通知:不必要地将条目标题换成简体或繁体中文" |
|||
}, |
|||
"uw-linking": { |
|||
label: "过度加入红字连结或重复蓝字连结", |
|||
summary: "单层级通知:过度加入红字连结或重复蓝字连结" |
|||
}, |
|||
"uw-minor": { |
|||
label: "不适当地使用小修改选项", |
|||
summary: "单层级通知:不适当地使用小修改选项" |
|||
}, |
|||
"uw-notaiv": { |
|||
label: "不要向当前的破坏回报复杂的用户纷争", |
|||
summary: "单层级通知:不要向当前的破坏回报复杂的用户纷争" |
|||
}, |
|||
"uw-notvote": { |
|||
label: "我们是以共识处事,不仅是投票", |
|||
summary: "单层级通知:我们是以共识处事,不仅是投票" |
|||
}, |
|||
"uw-preview": { |
|||
label: "使用预览按钮来避免不必要的错误", |
|||
summary: "单层级通知:使用预览按钮来避免不必要的错误" |
|||
}, |
|||
"uw-sandbox": { |
|||
label: "移除沙盒的置顶模板{{sandbox}}", |
|||
summary: "单层级通知:移除沙盒的置顶模板{{sandbox}}" |
|||
}, |
|||
"uw-selfrevert": { |
|||
label: "回退个人的测试", |
|||
summary: "单层级通知:回退个人的测试" |
|||
}, |
|||
"uw-subst": { |
|||
label: "谨记要替代模板", |
|||
summary: "单层级通知:谨记要替代模板" |
|||
}, |
|||
"uw-talkinarticle": { |
|||
label: "在条目页中留下意见", |
|||
summary: "单层级通知:在条目页中留下意见" |
|||
}, |
|||
"uw-tilde": { |
|||
label: "没有在讨论页上签名", |
|||
summary: "单层级通知:没有在讨论页上签名" |
|||
}, |
|||
"uw-translated": { |
|||
label: "翻译条目未标注原作者", |
|||
summary: "单层级通知:翻译条目未标注原作者" |
|||
}, |
|||
"uw-uaa": { |
|||
label: "向更改用户名回报的用户名称并不违反方针", |
|||
summary: "单层级通知:向更改用户名回报的用户名称并不违反方针" |
|||
}, |
|||
"uw-warn": { |
|||
label: "警告破坏用户", |
|||
summary: "单层级通知:警告破坏用户" |
|||
} |
|||
}, |
|||
singlewarn: { |
|||
"uw-3rr": { |
|||
label: "用户潜在违反回退不过三原则的可能性", |
|||
summary: "单层级警告:用户潜在违反回退不过三原则的可能性" |
|||
}, |
|||
"uw-attack": { |
|||
label: "建立人身攻击页面", |
|||
summary: "单层级警告:建立人身攻击页面", |
|||
suppressArticleInSummary: true |
|||
}, |
|||
"uw-bv": { |
|||
label: "公然的破坏", |
|||
summary: "单层级警告:公然的破坏" |
|||
}, |
|||
"uw-canvass": { |
|||
label: "不恰当的拉票", |
|||
summary: "单层级警告:不恰当的拉票" |
|||
}, |
|||
"uw-copyright": { |
|||
label: "侵犯版权", |
|||
summary: "单层级警告:侵犯版权" |
|||
}, |
|||
"uw-copyright-link": { |
|||
label: "连结到有版权的材料", |
|||
summary: "单层级警告:连结到有版权的材料" |
|||
}, |
|||
"uw-fakesource": { |
|||
label: "虚构资料来源或引文", |
|||
summary: "单层级警告:虚构资料来源或引文" |
|||
}, |
|||
"uw-hoax": { |
|||
label: "建立恶作剧", |
|||
summary: "单层级警告:建立恶作剧" |
|||
}, |
|||
"uw-incompletecite": { |
|||
label: "列出的资料来源欠缺若干详情而不易查找", |
|||
summary: "单层级警告:列出的资料来源欠缺若干详情而不易查找" |
|||
}, |
|||
"uw-legal": { |
|||
label: "诉诸法律威胁", |
|||
summary: "单层级警告:诉诸法律威胁" |
|||
}, |
|||
"uw-longterm": { |
|||
label: "长期的破坏", |
|||
summary: "单层级警告:长期的破坏" |
|||
}, |
|||
"uw-multipleIPs": { |
|||
label: "使用多个IP地址", |
|||
summary: "单层级警告:使用多个IP地址" |
|||
}, |
|||
"uw-npov-tvd": { |
|||
label: "在剧集条目中加入奸角等非中立描述", |
|||
summary: "单层级警告:在剧集条目中加入奸角等非中立描述" |
|||
}, |
|||
"uw-pinfo": { |
|||
label: "个人资料", |
|||
summary: "单层级警告:个人资料" |
|||
}, |
|||
"uw-upv": { |
|||
label: "用户页破坏", |
|||
summary: "单层级警告:用户页破坏" |
|||
}, |
|||
"uw-selfinventedname": { |
|||
label: "不适当的自创新名词、新译名", |
|||
summary: "单层级警告:不适当的自创新名词、新译名" |
|||
}, |
|||
"uw-substub": { |
|||
label: "创建小小作品", |
|||
summary: "单层级警告:创建小小作品" |
|||
}, |
|||
"uw-username": { |
|||
label: "不恰当的用户名", |
|||
summary: "单层级警告:不恰当的用户名" |
|||
}, |
|||
"uw-wrongsummary": { |
|||
label: "在编辑摘要制造不适当的内容", |
|||
summary: "单层级警告:在编辑摘要制造不适当的内容" |
|||
} |
|||
} |
|||
}; |
}; |
||
Line 897: | Line 166: | ||
Twinkle.warn.prev_reason = null; |
Twinkle.warn.prev_reason = null; |
||
Twinkle.warn.callback. |
Twinkle.warn.callback.create_category = function (e) { |
||
var value = e.target.value; |
|||
var sub_group = e.target.root.sub_group; |
|||
sub_group.main_group = value; |
|||
var old_subvalue = sub_group.value; |
|||
var old_subvalue_re; |
|||
if( old_subvalue ) { |
|||
old_subvalue = old_subvalue.replace(/\d*(im)?$/, '' ); |
|||
old_subvalue_re = new RegExp( mw.RegExp.escape( old_subvalue ) + "(\\d*(?:im)?)$" ); |
|||
} |
|||
while( sub_group.hasChildNodes() ){ |
|||
sub_group.removeChild( sub_group.firstChild ); |
|||
} |
|||
// worker function to create the combo box entries |
// worker function to create the combo box entries |
||
var createEntries = function( contents, container, wrapInOptgroup ) { |
var createEntries = function( contents, container, wrapInOptgroup ) { |
||
Line 945: | Line 200: | ||
}; |
}; |
||
// create the option-groups |
|||
if( value === "singlenotice" || value === "singlewarn" ) { |
|||
$.each( Twinkle.warn.messages, function( groupLabel, groupContents ) { |
|||
// no categories, just create the options right away |
|||
var optgroup = new Morebits.quickForm.element( { |
|||
createEntries( Twinkle.warn.messages[ value ], sub_group, true ); |
|||
type: 'optgroup', |
|||
} else if( value === "custom" ) { |
|||
label: groupLabel |
|||
createEntries( Twinkle.getPref("customWarningList"), sub_group, true ); |
|||
} else { |
|||
// create the option-groups |
|||
$.each( Twinkle.warn.messages[ value ], function( groupLabel, groupContents ) { |
|||
var optgroup = new Morebits.quickForm.element( { |
|||
type: 'optgroup', |
|||
label: groupLabel |
|||
} ); |
|||
optgroup = optgroup.render(); |
|||
sub_group.appendChild( optgroup ); |
|||
// create the options |
|||
createEntries( groupContents, optgroup, false ); |
|||
} ); |
} ); |
||
optgroup = optgroup.render(); |
|||
} |
|||
sub_group.appendChild( optgroup ); |
|||
// create the options |
|||
createEntries( groupContents, optgroup, false ); |
|||
} ); |
|||
// 自訂警告 |
|||
// clear overridden label on article textbox |
|||
Morebits.quickForm. |
var optgroup2 = new Morebits.quickForm.element( { |
||
type: 'optgroup', |
|||
Morebits.quickForm.resetElementLabel(e.target.root.article); |
|||
label: '自定義警告' |
|||
} ); |
|||
// hide the big red notice |
|||
optgroup2 = optgroup2.render(); |
|||
$("#tw-warn-red-notice").remove(); |
|||
sub_group.appendChild( optgroup2 ); |
|||
}; |
|||
createEntries( Twinkle.getPref("customWarningList"), sub_group, true ); |
|||
Twinkle.warn.callback.change_subcategory = function twinklewarnCallbackChangeSubcategory(e) { |
|||
var main_group = e.target.form.main_group.value; |
|||
var value = e.target.form.sub_group.value; |
|||
if( main_group === 'singlenotice' || main_group === 'singlewarn' ) { |
|||
if( value === 'uw-bite' || value === 'uw-username' || value === 'uw-socksuspect' ) { |
|||
if(Twinkle.warn.prev_article === null) { |
|||
Twinkle.warn.prev_article = e.target.form.article.value; |
|||
} |
|||
e.target.form.article.notArticle = true; |
|||
e.target.form.article.value = ''; |
|||
} else if( e.target.form.article.notArticle ) { |
|||
if(Twinkle.warn.prev_article !== null) { |
|||
e.target.form.article.value = Twinkle.warn.prev_article; |
|||
Twinkle.warn.prev_article = null; |
|||
} |
|||
e.target.form.article.notArticle = false; |
|||
} |
|||
} |
|||
// change form labels according to the warning selected |
|||
if (value === "uw-socksuspect") { |
|||
Morebits.quickForm.setElementTooltipVisibility(e.target.form.article, false); |
|||
Morebits.quickForm.overrideElementLabel(e.target.form.article, "傀儡操纵者用户名,如知晓(不含User:) "); |
|||
} else if (value === "uw-username") { |
|||
Morebits.quickForm.setElementTooltipVisibility(e.target.form.article, false); |
|||
Morebits.quickForm.overrideElementLabel(e.target.form.article, "用户名违反方针,因为… "); |
|||
} else if (value === "uw-bite") { |
|||
Morebits.quickForm.setElementTooltipVisibility(e.target.form.article, false); |
|||
Morebits.quickForm.overrideElementLabel(e.target.form.article, "被“咬到”的用户(不含User:) "); |
|||
} else { |
|||
Morebits.quickForm.setElementTooltipVisibility(e.target.form.article, true); |
|||
Morebits.quickForm.resetElementLabel(e.target.form.article); |
|||
} |
|||
// add big red notice, warning users about how to use {{uw-[coi-]username}} appropriately |
|||
$("#tw-warn-red-notice").remove(); |
|||
var $redWarning; |
|||
if (value === "uw-username") { |
|||
$redWarning = $("<div style='color: red;' id='tw-warn-red-notice'>{{uw-username}}<b>不应</b>被用于<b>明显</b>违反用户名方针的用户。" + |
|||
"明显的违反方针应被报告给UAA。" + |
|||
"{{uw-username}}应只被用在边界情况下需要与用户讨论时。</div>"); |
|||
$redWarning.insertAfter(Morebits.quickForm.getElementLabelObject(e.target.form.reasonGroup)); |
|||
}; |
|||
}; |
}; |
||
Line 1,050: | Line 253: | ||
var params = pageobj.getCallbackParameters(); |
var params = pageobj.getCallbackParameters(); |
||
var messageData = params.messageData; |
var messageData = params.messageData; |
||
var history_re = /<!-- Template:(uw-.*?) -->.*?(\d{4})年(\d{1,2})月(\d{1,2})日 \([日一二三四五六]\) (\d{1,2}):(\d{1,2}) \(UTC\)/g; |
|||
var history = {}; |
|||
var latest = { date: new Date( 0 ), type: '' }; |
|||
var current; |
|||
while( ( current = history_re.exec( text ) ) ) { |
|||
var current_date = new Date( current[2] + '-' + current[3] + '-' + current[4] + ' ' + current[5] + ':' + current[6] + ' UTC' ); |
|||
if( !( current[1] in history ) || history[ current[1] ] < current_date ) { |
|||
history[ current[1] ] = current_date; |
|||
} |
|||
if( current_date > latest.date ) { |
|||
latest.date = current_date; |
|||
latest.type = current[1]; |
|||
} |
|||
} |
|||
var date = new Date(); |
var date = new Date(); |
||
if( params.sub_group in history ) { |
|||
var temp_time = new Date( history[ params.sub_group ] ); |
|||
temp_time.setUTCHours( temp_time.getUTCHours() + 24 ); |
|||
if( temp_time > date ) { |
|||
if( !confirm( "近24小时内一个同样的 " + params.sub_group + " 模板已被发出。\n是否继续?" ) ) { |
|||
pageobj.statelem.info( '用户取消' ); |
|||
return; |
|||
} |
|||
} |
|||
} |
|||
latest.date.setUTCMinutes( latest.date.getUTCMinutes() + 1 ); // after long debate, one minute is max |
|||
if( latest.date > date ) { |
|||
if( !confirm( "近1分钟内一个同样的 " + latest.type + " 模板已被发出。\n是否继续?" ) ) { |
|||
pageobj.statelem.info( '用户取消' ); |
|||
return; |
|||
} |
|||
} |
|||
var dateHeaderRegex = new RegExp( "^==+\\s*" + date.getUTCFullYear() + "年" + (date.getUTCMonth() + 1) + "月" + |
var dateHeaderRegex = new RegExp( "^==+\\s*" + date.getUTCFullYear() + "年" + (date.getUTCMonth() + 1) + "月" + |
||
Line 1,108: | Line 273: | ||
text += "== " + messageData.heading + " ==\n"; |
text += "== " + messageData.heading + " ==\n"; |
||
} else if( !dateHeaderRegexResult || dateHeaderRegexResult.index !== lastHeaderIndex ) { |
} else if( !dateHeaderRegexResult || dateHeaderRegexResult.index !== lastHeaderIndex ) { |
||
Morebits.status.info( '信息', '未找到 |
Morebits.status.info( '信息', '未找到當月標題,將建立新的' ); |
||
text += "== " + date.getUTCFullYear() + "年" + (date.getUTCMonth() + 1) + "月 " + " ==\n"; |
text += "== " + date.getUTCFullYear() + "年" + (date.getUTCMonth() + 1) + "月 " + " ==\n"; |
||
} |
} |
||
Line 1,115: | Line 280: | ||
if ( Twinkle.getPref('showSharedIPNotice') && Morebits.isIPAddress( mw.config.get('wgTitle') ) ) { |
if ( Twinkle.getPref('showSharedIPNotice') && Morebits.isIPAddress( mw.config.get('wgTitle') ) ) { |
||
Morebits.status.info( '信息', ' |
Morebits.status.info( '信息', '加入共享IP說明' ); |
||
text += "\n{{subst:SharedIPAdvice}}"; |
text += "\n{{subst:SharedIPAdvice}}"; |
||
} |
} |
||
Line 1,133: | Line 298: | ||
break; |
break; |
||
case "4": |
case "4": |
||
summary = "最 |
summary = "最後警告"; |
||
break; |
break; |
||
case "m": |
case "m": |
||
Line 1,150: | Line 315: | ||
summary = messageData.summary; |
summary = messageData.summary; |
||
if ( messageData.suppressArticleInSummary !== true && params.article ) { |
if ( messageData.suppressArticleInSummary !== true && params.article ) { |
||
summary += ",於[[" + params.article + "]]"; |
|||
if ( params.sub_group === "uw-socksuspect" ) { // this template requires a username |
|||
summary += ",[[User:" + params.article + "]]的"; |
|||
} else { |
|||
summary += ",于[[" + params.article + "]]"; |
|||
} |
|||
} |
} |
||
} |
} |
||
Line 1,164: | Line 325: | ||
pageobj.save(); |
pageobj.save(); |
||
}, |
}, |
||
main_flow: function (flowobj) { |
|||
var params = flowobj.getCallbackParameters(); |
|||
var messageData = params.messageData; |
|||
var date = new Date(); |
|||
var topic; |
|||
if (messageData.heading) { |
|||
topic = messageData.heading; |
|||
} else { |
|||
var summary; |
|||
switch( params.sub_group.substr( -1 ) ) { |
|||
case "1": |
|||
summary = "提醒"; |
|||
break; |
|||
case "2": |
|||
summary = "注意"; |
|||
break; |
|||
case "3": |
|||
summary = "警告"; |
|||
break; |
|||
case "4": |
|||
summary = "最后警告"; |
|||
break; |
|||
case "m": |
|||
if( params.sub_group.substr( -3 ) === "4im" ) { |
|||
summary = "唯一警告"; |
|||
break; |
|||
} |
|||
summary = "提示"; |
|||
break; |
|||
default: |
|||
summary = "提示"; |
|||
break; |
|||
} |
|||
// 因为Flow讨论串自带时间,所以不需要再另外标注 |
|||
topic = summary + " (" + Morebits.string.toUpperCaseFirstChar(messageData.label) + ")"; |
|||
} |
|||
var content = Twinkle.warn.callbacks.getWarningWikitext(params.sub_group, params.article, |
|||
params.reason, params.main_group === 'custom'); |
|||
flowobj.setTopic(topic); |
|||
flowobj.setContent(content); |
|||
flowobj.newTopic(); |
|||
} |
|||
}; |
}; |
||
Twinkle.warn.callback.evaluate = function twinklewarnCallbackEvaluate(e) { |
Twinkle.warn.callback.evaluate = function twinklewarnCallbackEvaluate(e) { |
||
var userTalkPage = 'User_talk:' + Morebits.wiki.flow.relevantUserName(); |
var userTalkPage = 'User_talk:' + Morebits.wiki.flow.relevantUserName(); |
||
// First, check to make sure a reason was filled in if uw-username was selected |
|||
if(e.target.sub_group.value === 'uw-username' && e.target.article.value.trim() === '') { |
|||
alert("必须给{{uw-username}}提供理由。"); |
|||
return; |
|||
} |
|||
// Find the selected <option> element so we can fetch the data structure |
// Find the selected <option> element so we can fetch the data structure |
||
Line 1,238: | Line 346: | ||
Morebits.wiki.actionCompleted.redirect = userTalkPage; |
Morebits.wiki.actionCompleted.redirect = userTalkPage; |
||
Morebits.wiki.actionCompleted.notice = "警告完成, |
Morebits.wiki.actionCompleted.notice = "警告完成,將在幾秒後重新載入"; |
||
Morebits.wiki. |
var wikipedia_page = new Morebits.wiki.page( userTalkPage, '用戶對話頁修改' ); |
||
wikipedia_page.setCallbackParameters( params ); |
|||
var flow_page = new Morebits.wiki.flow( userTalkPage, '用户Flow对话页留言' ); |
|||
wikipedia_page.setFollowRedirect( true ); |
|||
flow_page.setCallbackParameters( params ); |
|||
wikipedia_page.load( Twinkle.warn.callbacks.main ); |
|||
}, function () { |
|||
var wikipedia_page = new Morebits.wiki.page( userTalkPage, '用户对话页修改' ); |
|||
wikipedia_page.setCallbackParameters( params ); |
|||
wikipedia_page.setFollowRedirect( true ); |
|||
wikipedia_page.load( Twinkle.warn.callbacks.main ); |
|||
}); |
|||
}; |
}; |