欢迎来到奇葩栖息地!欢迎加入Discord服务器:XfrfHCzfbW欢迎加入QQ频道:r01m9y3iz6请先至特殊:参数设置验证邮箱后再进行编辑。特殊:参数设置挑选自己想要使用的小工具!不会编辑?请至这里学习Wikitext语法。

MediaWiki:Mobile.js:修订间差异

来自奇葩栖息地
添加的内容 删除的内容
无编辑摘要
标签移动版编辑 移动版网页编辑
无编辑摘要
标签移动版编辑 移动版网页编辑
第24行: 第24行:
}
}
siteNoticeScroll('.siteNoticeScroll',5000);
siteNoticeScroll('.siteNoticeScroll',5000);
mw.loader.load("ext.SimpleMathJax");
mw.loader.load(mw.config.get('wgExtensionAssetsPath')+"/SimpleMathJax/resources/ext.SimpleMathJax.js");

2021年6月13日 (日) 10:12的版本

/* 这里的任何JavaScript将为使用移动版网站的用户加载 */
/** 顶部公告 **/
/* From wjghj.cn under CC BY-NC-SA 4.0*/
function siteNoticeScroll(obj,interval) {
  $(obj).animate({
    height: 'show',
    paddingTop: 'show',
    marginTop: 'show',
    paddingBottom: 'show',
    marginBottom: 'show',
  });
  setInterval(function() {
    $(obj).find('ul:first').animate({
      marginTop: '-25px'
    },
    300,
    function() {
      $(this).css({
        marginTop: '0px',
      }).find('li:first').appendTo(this);
    });
  },
  interval);
}
siteNoticeScroll('.siteNoticeScroll',5000);
mw.loader.load(mw.config.get('wgExtensionAssetsPath')+"/SimpleMathJax/resources/ext.SimpleMathJax.js");