MediaWiki:Gadget-CollapsibleSidebar.js:修订间差异

imported>=海豚=
无编辑摘要
top:​bad link repair, replaced: hmoegirl.com → hmoegirl.info
 
(未显示1个用户的4个中间版本)
第2行: 第2行:
  * 侧边栏隐藏工具
  * 侧边栏隐藏工具
  * 本工具参考自维百的同功能小工具——https://zh.wikipedia.org/wiki/MediaWiki:Gadget-CollapsibleSidebar.js
  * 本工具参考自维百的同功能小工具——https://zh.wikipedia.org/wiki/MediaWiki:Gadget-CollapsibleSidebar.js
  * [[User:AnnAngela]]做了一点改进
  * [[User:AnnAngela]]/[[User:850710247liu]]做了一点改进
  * 此处代码已转化为可通过mw检测的格式,源码可在 https://zh.moegirl.org.cn/User:AnnAngela/js/sidebarHidden.js 找到
  * 此处代码已转化为可通过mw检测的格式,源码可在 https://zh.moegirl.org.cn/User:AnnAngela/js/sidebarHidden.js 找到
  */
  */
第53行: 第53行:
                 }));
                 }));
             };
             };
             var logoPic = "https://www.hmoegirl.com/images/b/bc/Hmoegirl_logo.png";
             var logoPic = "https://www.hmoegirl.info/images/b/bc/Hmoegirl_logo.png";
             var arrowRightSvg = generateImageObject('<svg version="1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" enable-background="new 0 0 48 48"><polygon fill="#2196F3" points="17.1,5 14,8.1 29.9,24 14,39.9 17.1,43 36,24"/></svg>');
             var arrowRightSvg = generateImageObject('<svg version="1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" enable-background="new 0 0 48 48"><polygon fill="#2196F3" points="17.1,5 14,8.1 29.9,24 14,39.9 17.1,43 36,24"/></svg>');
             var arrowLeftSvg = generateImageObject('<svg version="1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" enable-background="new 0 0 48 48"><polygon fill="#2196F3" points="30.9,43 34,39.9 18.1,24 34,8.1 30.9,5 12,24"/></svg>');
             var arrowLeftSvg = generateImageObject('<svg version="1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" enable-background="new 0 0 48 48"><polygon fill="#2196F3" points="30.9,43 34,39.9 18.1,24 34,8.1 30.9,5 12,24"/></svg>');
第70行: 第70行:
             $logoLink.empty().removeAttr("class").attr("id", "sidebarHidden-logo-link").append($logo);
             $logoLink.empty().removeAttr("class").attr("id", "sidebarHidden-logo-link").append($logo);
             var hide = function () {
             var hide = function () {
            if ($(".toc-custom").length > 0){
            document.querySelector(".toc-custom").style.transform="translate(-100%, 0)";
            }
                 if (saving) {
                 if (saving) {
                     return;
                     return;
第82行: 第85行:
             };
             };
             var show = function () {
             var show = function () {
                        if ($(".toc-custom").length > 0){
            document.querySelector(".toc-custom").style.transform="translate(0, 0)";
                        }
                 if (saving) {
                 if (saving) {
                     return;
                     return;