MediaWiki:Gadget-widgetPreload.js:修订间差异
外观
AnnAngela-dbot(留言 | 贡献) 代码变动:103d1a56 - feat: rename (#594) by U:AnnAngela, co-authored-by: GH:github-actions[bot] 标签:由机器人或全自动脚本执行的操作 |
AnnAngela-dbot(留言 | 贡献) 标签:由机器人或全自动脚本执行的操作 |
||
| 第4行: | 第4行: | ||
* ------------------------------------------------------------------------- | * ------------------------------------------------------------------------- | ||
*/ | */ | ||
var _addText = '{{GHIACode|page=GHIA:MoegirlPediaInterfaceCodes/blob/master/src/gadgets/widgetPreload/Gadget-widgetPreload.js|user=[[U: | var _addText = '{{GHIACode|page=GHIA:MoegirlPediaInterfaceCodes/blob/master/src/gadgets/widgetPreload/Gadget-widgetPreload.js|user=[[U:屠麟傲血]]|co-authors=|longId=6943529111ca996bf65b72925d9ce1c09b98992c|shortId=69435291|summary=fix: :bug: 依赖与小工具加载条件|body=<nowiki>1.移除失效依赖:mw.notify↩2.将部分小工具名字空间、操作判断条件移动到配置文件中</nowiki>}}'; | ||
/* <pre> */ | /* <pre> */ | ||
"use strict";$(()=>{if( | "use strict";$(()=>{if(!mw.config.get("wgCurRevisionId")){const e=/[-_,./\\]/;if(e.test(mw.config.get("wgPageName")))return window.onbeforeunload=void 0,$(window).off("beforeunload"),void location.replace(`${mw.config.get("wgServer")}${mw.config.get("wgScriptPath")}/index.php?action=edit&title=${mw.config.get("wgPageName").replace(/ |_/g,"").replace(/^([^/]*)[/\\].*$/i,"$1").split(e).map(e=>{return`${`${(n=e)[0]}`.substring(0,1).toUpperCase()}${`${n}`.substring(1)}`;var n}).join("")}`);const n=`wg${mw.config.get("wgTitle")}`.replace(/ /g,"");$("#wpTextbox1").val(`<noinclude> </noinclude><includeonly>\x3c!--{if !isset($${n}) || !$${n}}--\x3e\x3c!--{assign var="${n}" value=true scope="global"}--\x3e<script>\n"use strict";\nwindow.RLQ = window.RLQ || [];\nwindow.RLQ.push(["jquery", () => {\n\n}]);\n<\/script>\x3c!--{/if}--\x3e</includeonly>`),$("#mw-content-text > .mw-parser-output > .noarticletext")[0]&&$(document.body).addClass("noWidget")}}); | ||
/* </pre> */ | /* </pre> */ | ||
2025年7月27日 (日) 21:27的最新版本
/**
* -------------------------------------------------------------------------
* !!! DON'T MODIFY THIS PAGE MANUALLY, YOUR CHANGES WILL BE OVERWRITTEN !!!
* -------------------------------------------------------------------------
*/
var _addText = '{{GHIACode|page=GHIA:MoegirlPediaInterfaceCodes/blob/master/src/gadgets/widgetPreload/Gadget-widgetPreload.js|user=[[U:屠麟傲血]]|co-authors=|longId=6943529111ca996bf65b72925d9ce1c09b98992c|shortId=69435291|summary=fix: :bug: 依赖与小工具加载条件|body=<nowiki>1.移除失效依赖:mw.notify↩2.将部分小工具名字空间、操作判断条件移动到配置文件中</nowiki>}}';
/* <pre> */
"use strict";$(()=>{if(!mw.config.get("wgCurRevisionId")){const e=/[-_,./\\]/;if(e.test(mw.config.get("wgPageName")))return window.onbeforeunload=void 0,$(window).off("beforeunload"),void location.replace(`${mw.config.get("wgServer")}${mw.config.get("wgScriptPath")}/index.php?action=edit&title=${mw.config.get("wgPageName").replace(/ |_/g,"").replace(/^([^/]*)[/\\].*$/i,"$1").split(e).map(e=>{return`${`${(n=e)[0]}`.substring(0,1).toUpperCase()}${`${n}`.substring(1)}`;var n}).join("")}`);const n=`wg${mw.config.get("wgTitle")}`.replace(/ /g,"");$("#wpTextbox1").val(`<noinclude> </noinclude><includeonly>\x3c!--{if !isset($${n}) || !$${n}}--\x3e\x3c!--{assign var="${n}" value=true scope="global"}--\x3e<script>\n"use strict";\nwindow.RLQ = window.RLQ || [];\nwindow.RLQ.push(["jquery", () => {\n\n}]);\n<\/script>\x3c!--{/if}--\x3e</includeonly>`),$("#mw-content-text > .mw-parser-output > .noarticletext")[0]&&$(document.body).addClass("noWidget")}});
/* </pre> */