User:Star0/timeless.js

From Project Archive by Lakejason0
< User:Star0
Revision as of 09:16, 6 March 2021 by Star0 (talk | contribs) (建立内容为“$(function() { var wgULS = window.wgULS || function (hans, hant, cn, tw, hk, sg, zh, mo, my){ return function (wg, hans, hant, cn, tw, hk, sg, zh, mo, my) {…”的新页面)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Note: After publishing, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Press Ctrl-F5.
$(function() {
	var wgULS = window.wgULS || function (hans, hant, cn, tw, hk, sg, zh, mo, my){
		return function (wg, hans, hant, cn, tw, hk, sg, zh, mo, my) {
			var ret = {
				'zh': zh || hans || hant || cn || tw || hk || sg || mo || my,
				'zh-hans': hans || cn || sg || my,
				'zh-hant': hant || tw || hk || mo,
				'zh-cn': cn || hans || sg || my,
				'zh-sg': sg || hans || cn || my,
				'zh-tw': tw || hant || hk || mo,
				'zh-hk': hk || hant || mo || tw,
				'zh-mo': mo || hant || hk || tw
			};
			return ret[wg] || zh || hans || hant || cn || tw || hk || sg || mo || my;
		} (mw.config.get('wgUserLanguage'), hans, hant, cn, tw, hk, sg, zh, mo, my);
	};
	if (mw.config.get('wgIsMainPage') && mw.config.get('wgAction') == 'view') {
		$('div#mw-content-text').text(wgULS('正在加载自订首页','正在加载自订首页')).show().load(mw.config.get('wgScript'), {
        	action: 'render',
        	title: '存档计划:计划'
    	});
	} 
});