2023年政策修订增补工作正在进行中,欢迎参与!
  • Moegirl.ICU:萌娘百科流亡社群 581077156(QQ),欢迎对萌娘百科运营感到失望的编辑者加入
  • Moegirl.ICU:账号认领正在试运行,有意者请参照账号认领流程

MediaWiki talk:Gadget-site-styles.css

萌娘百科,万物皆可萌的百科全书!转载请标注来源页面的网页链接,并声明引自萌娘百科。内容不可商用。
跳转到导航 跳转到搜索

编辑请求 - Func

由Func提出的编辑请求:

状态:   完成

将以下内容:

padding: 20px 30px;

修改为:

margin: 0px -1px;

默认的padding现在已经写在element.style里面,并且为更合理的1em,故去除。

加margin可以在{{人物信息}}等模板里的显示更美观。

—— Func讨论·贡献) 2020年6月20日 (六) 22:14 (CST)

并没有写入在模板内。——From AnnAngela the Temporary Bureaucrat (Talk) 2020年6月24日 (三) 09:04 (CST)
啊这,padding样式是通过MediaWiki:Gadget-Tabs.js写入的吧。(另外MediaWiki:Gadget-Tabs.js第88行初始化的时候有个textPadding没有和前面的几种预设统一)--Func讨论·贡献) 2020年6月24日 (三) 22:46 (CST)
{{Tabs/core}}默认不使用预设样式,不能依赖预设样式解决问题(可以先思考一下用户指定值、用户指定主题样式值、js默认值、css默认值之间的优先级关系)。——From AnnAngela the Temporary Bureaucrat (Talk) 2020年6月25日 (四) 09:07 (CST)
啊,目前{{Tabs/core}}不加预设的默认padding确实是20px 30px,不是说依赖预设样式,而是希望默认的表现能在padding上与预设一致……目前padding会被css和js分别写两次,所以我图方便这样申请,如果不合适,还请考虑只加上margin……还是说应该限制在td里面……--Func讨论·贡献) 2020年6月25日 (四) 11:46 (CST)
margin也没那么美观_(:зゝ∠)_——From AnnAngela the Temporary Bureaucrat (Talk) 2020年6月25日 (四) 22:22 (CST)
来了来了,因为要作用于TabContent啊……Special:固定链接/4096610Special:固定链接/4096632,不同图片大小下的效果。--Func讨论·贡献) 2020年6月25日 (四) 23:32 (CST)
Help:沙盒/styles.css(TabLabel也一同选上效果更佳),不过我愣是没看懂在Gadget-Tabs.css里.tab怎么选择到.Tabs的……--Func讨论·贡献) 2020年6月25日 (四) 23:40 (CST)
Done. 因为.tab是放在body上的。——From AnnAngela the Temporary Bureaucrat (Talk) 2020年6月26日 (五) 21:08 (CST)

编辑请求 - Bhsd - 2020.10.03

由Bhsd提出的编辑请求:

状态:   完成

将以下内容:

body:not(.heimu_toggle_on) .heimu.off .new,
body:not(.heimu_toggle_on) .heimu.off .new:hover,
body:not(.heimu_toggle_on) .new:hover .heimu.off,
body:not(.heimu_toggle_on) .heimu.off .new,
body:not(.heimu_toggle_on) .heimu.off .new:hover,
body:not(.heimu_toggle_on) .new:hover .heimu.off {
    transition: color .13s linear;
    color: #BA0000;
}

修改为:

body:not(.heimu_toggle_on) .heimu.off .new,
body:not(.heimu_toggle_on) .heimu.off .new:hover,
body:not(.heimu_toggle_on) .new:hover .heimu.off,
body:not(.heimu_toggle_on) .heimu.off .new,
body:not(.heimu_toggle_on) .heimu.off .new:hover,
body:not(.heimu_toggle_on) .new:hover .heimu.off,
body:not(.heimu_toggle_on) .heimu:hover .new {
    transition: color .13s linear;
    color: #BA0000;
}

添加一行选择器,以解决提问求助区反馈的bug。这个编辑申请我有点犹豫,因为黑幕里的红链不太看得清……是否要考虑对body:not(.heimu_toggle_on) .heimu:hover .new单独换一个浅一点的红色?——移动版用户 Bhsd讨论) 2020年10月3日 (六) 20:01 (CST)

Done.——From AnnAngela the Temporary Bureaucrat (Talk) 2020年10月3日 (六) 20:54 (CST)

编辑请求 - Leranjun - 2020.10.13

撤回的编辑请求

由Leranjun提出的编辑请求:

状态:   撤回

将以下内容:

body:not(.heimu_toggle_on) .heimu:hover a,
body:not(.heimu_toggle_on) a:hover .heimu,
body:not(.heimu_toggle_on) .heimu.off a,
body:not(.heimu_toggle_on) a:hover .heimu.off {
    transition: color .13s linear;
    color: lightblue;
}
body:not(.heimu_toggle_on) .heimu.off .new,
body:not(.heimu_toggle_on) .heimu.off .new:hover,
body:not(.heimu_toggle_on) .new:hover .heimu.off,
body:not(.heimu_toggle_on) .heimu.off .new,
body:not(.heimu_toggle_on) .heimu.off .new:hover,
body:not(.heimu_toggle_on) .new:hover .heimu.off,
body:not(.heimu_toggle_on) .heimu:hover .new {
    transition: color .13s linear;
    color: #BA0000;
}
修改为:
body:not(.heimu_toggle_on) .heimu:hover > a,
body:not(.heimu_toggle_on) a:hover > .heimu,
body:not(.heimu_toggle_on) .heimu.off > a,
body:not(.heimu_toggle_on) a:hover > .heimu.off {
    transition: color .13s linear;
    color: lightblue;
}
body:not(.heimu_toggle_on) .heimu.off > .new,
body:not(.heimu_toggle_on) .heimu.off > .new:hover,
body:not(.heimu_toggle_on) .new:hover > .heimu.off,
body:not(.heimu_toggle_on) .heimu.off > .new,
body:not(.heimu_toggle_on) .heimu.off > .new:hover,
body:not(.heimu_toggle_on) .new:hover > .heimu.off {
    transition: color .13s linear;
    color: #BA0000;
}
body:not(.heimu_toggle_on) .heimu:hover > .new {
    transition: color .13s linear;
    color: #FC494E;
}

添加>限制黑幕链接仅显示一层。尝试解决公版上提到的双层黑幕的问题。顺便改一下黑幕红链的颜色。--ZhMGP:~ Leranjun$用户页讨论页贡献乙方|33 2020年10月13日 (二) 20:17 (CST)

这个处理有点问题。即使黑幕里不额外定制内容,ruby里面也可能会由于语言设置再套一层span。——移动版用户 Bhsd讨论) 2020年10月13日 (二) 21:03 (CST)
@Bhsd 啊,会吗?公版上的那几个黑幕好像都是没问题的诶(包括ruby)。您方便给个沙盒链接吗XD--ZhMGP:~ Leranjun$用户页讨论页贡献工具人|11 2020年10月13日 (二) 21:14 (CST)
那是因为那几个例子的ruby没加语言参数。——移动版用户 Bhsd讨论) 2020年10月13日 (二) 21:36 (CST)
Symbol Circle OK.svg 了解 看来比我想象的麻烦啊(半恼)
那我先暂时撤回请求,在沙盒测试完毕后再回来申请。--ZhMGP:~ Leranjun$用户页讨论页贡献优编|20 2020年10月13日 (二) 21:41 (CST)

由Leranjun提出的编辑请求:

状态:   拒绝

将以下内容:

.heimu,
.heimu a,
a .heimu,
.heimu a.new {
    background-color: #252525;
    color: #252525;
    text-shadow: none;
}
body:not(.heimu_toggle_on) .heimu:hover,
body:not(.heimu_toggle_on) .heimu:active,
body:not(.heimu_toggle_on) .heimu.off {
    transition: color .13s linear;
    color: white;
}
body:not(.heimu_toggle_on) .heimu:hover a,
body:not(.heimu_toggle_on) a:hover .heimu,
body:not(.heimu_toggle_on) .heimu.off a,
body:not(.heimu_toggle_on) a:hover .heimu.off {
    transition: color .13s linear;
    color: lightblue;
}
body:not(.heimu_toggle_on) .heimu.off .new,
body:not(.heimu_toggle_on) .heimu.off .new:hover,
body:not(.heimu_toggle_on) .new:hover .heimu.off,
body:not(.heimu_toggle_on) .heimu:hover .new {
    transition: color .13s linear;
    color: #BA0000;
}

修改为:

.heimu,
.heimu a,
a .heimu,
.heimu a.new,
.heimu rt {
    background-color: #252525;
    color: #252525;
    text-shadow: none;
}

body:not(.heimu_toggle_on) .heimu:hover,
body:not(.heimu_toggle_on) .heimu:active,
body:not(.heimu_toggle_on) .heimu.off,
body:not(.heimu_toggle_on) .heimu rt:hover,
body:not(.heimu_toggle_on) .heimu.off rt {
    transition: color .13s linear;
    color: white;
}

body:not(.heimu_toggle_on) .heimu:hover>a,
body:not(.heimu_toggle_on) a:hover>.heimu,
body:not(.heimu_toggle_on) .heimu.off>a,
body:not(.heimu_toggle_on) a:hover>.heimu.off,
body:not(.heimu_toggle_on) .heimu:hover>span[lang]>a,
body:not(.heimu_toggle_on) .heimu rt:hover>a,
body:not(.heimu_toggle_on) .heimu rt:hover>span[lang]>a,
body:not(.heimu_toggle_on) .heimu rb:hover>a,
body:not(.heimu_toggle_on) .heimu:hover rb>a {
    transition: color .13s linear;
    color: lightblue;
}

body:not(.heimu_toggle_on) .heimu.off>.new,
body:not(.heimu_toggle_on) .heimu.off>.new:hover,
body:not(.heimu_toggle_on) .new:hover>.heimu.off,
body:not(.heimu_toggle_on) .heimu.off>.new,
body:not(.heimu_toggle_on) .heimu.off>.new:hover,
body:not(.heimu_toggle_on) .new:hover>.heimu.off {
    transition: color .13s linear;
    color: #BA0000;
}

body:not(.heimu_toggle_on) .heimu:hover>.new,
body:not(.heimu_toggle_on) .heimu:hover>span[lang]>.new,
body:not(.heimu_toggle_on) .heimu rt:hover>.new,
body:not(.heimu_toggle_on) .heimu rt:hover>span[lang]>.new,
body:not(.heimu_toggle_on) .heimu rb:hover>.new,
body:not(.heimu_toggle_on) .heimu:hover rb>.new {
    transition: color .13s linear;
    color: #FC494E;
}

再次尝试修复黑幕的万年坑。改动的地方包括对ruby及语言模板的处理、对嵌套黑幕的处理、以及黑幕中红链的颜色等。

这段代码通过了部分{{黑幕}}、{{lj}}和{{ruby}}的排列组合测试,见User:Leranjun/sandbox/heimu

如果采用的话,同时需要修改MediaWiki:Gadget-heimu-toggle.css以适应。

啊不行了我眼花了(滑稽哭)--ZhMGP:~ Leranjun$用户页讨论页贡献优编|1 2020年10月13日 (二) 22:47 (CST)

(-)反对 萌百{{黑幕}}用量太大,不可能逐一检查参数有无定制更多HTML结构,没道理为了嵌套黑幕这一本就不提倡的用法冒风险修改CSS。——移动版用户 Bhsd讨论) 2020年10月13日 (二) 23:01 (CST)
如果一定要改的话,可以使用下面的思路(以下的代码仅用作示例:
.heimu:hover {
  color:inherit;
  background:inherit;
}
.heimu:not(:hover) {
  color:transparent;
  background:black;
}
.heimu:hover a {
  color:#0645ad;
}
.heimu:not(:hover) a {
  color:transparent;
}
.heimu:hover .new {
  color:#ba0000;
}
.heimu:not(:hover) .new {
  color:transparent;
}

重点是保证:not(:hover)的优先级更高,比如这里通过放在:hover之后实现。——移动版用户 Bhsd讨论) 2020年10月14日 (三) 04:59 (CST)

我不认为我们需要耗费精力在错误的模板使用上,尤其是这么做还会引入后续的持续维护需求。如果发现有错误的黑幕模板用法,建议直接修改页面。——From AnnAngela the Temporary Bureaucrat (Talk) 2020年10月14日 (三) 12:52 (CST)
@BhsdAnnAngela Symbol Circle OK.svg 了解 Face-smile.svg感谢 那至少可以把红链颜色改一下吗QAQ--ZhMGP:~ Leranjun$用户页讨论页贡献EnMGP|28 2020年10月14日 (三) 13:07 (CST)
我已经在全站js里添加了对应代码。——From AnnAngela the Temporary Bureaucrat (Talk) 2020年10月14日 (三) 13:17 (CST)

编辑请求 - MJH - 2021.08.03

由MJH提出的对MediaWiki:Gadget-site-styles.css的编辑请求:

状态:   完成

增加以下内容:

.noconvins > .mw-charinsert-item::before{
	content: '-{';
}
.noconvins > .mw-charinsert-item::after{
	content: '}-';
}

MediaWiki:Edittools的编辑请求联动,预期将能够正确显示插入“-{}-”的按钮。在User:MJH/Sandbox#char有测试例子。

也算是完成红梦子的一个夙愿了。——拒绝互膜的M.Maya. J.Judge my soul. H.Heritage.【乾】{{#forargs:}} is evil! 2021年8月3日 (二) 14:55 (CST)

Done.——From AnnAngela the Bureaucrat (Talk) 2021年8月3日 (二) 19:19 (CST)

有一个属性没有用上

第252行(讨论发出时的版本)关于locl的注释,想法是很好的,最开始也是起到了作用的。可惜2019年4月13日的修改导致所有带有lang属性的span的字体都只能用initial(默认值),也就是说永远用不了思源黑体以及其他可能的字体了,font-feature-settings: "locl" on;加了个寂寞。 あめろ 讨论 2021年9月26日 (日) 03:22 (CST)

編輯請求-Ericliu1912-2021-12-09

由Ericliu1912提出的对MediaWiki:Gadget-site-styles.css的编辑请求:

状态:   拒绝

增加以下内容:

cite {
    font-style: normal;
}

解決cite定位內文字顯示為斜體的問題。—— Eric Liu 創造は生命(留言 2021年12月9日 (四) 02:03 (CST)

(-)不支持 cite标签斜体是浏览器默认行为,未见添加到全站CSS的必要性。——移动版用户 Bhsd 2021年12月9日 (四) 02:12 (CST)
若确有令cite系列模板内文字非斜体需要,请尝试改进模块:Citation/CS1。—— ほしみ 2021年12月9日 (四) 02:32 (CST)
這套標準大概並不是為非拉丁文字設計的,看看該模組第五百五十行左右就明白了。斜體應用在本站常用的某些語言上真的很醜,考慮到語言常用程度,優先程度應當倒轉;但是讓中文斜體跟讓外文正體比起來,本站竟然打算選擇讓中文斜體?算了不多說了,裸ref了事,反正也沒多少人真的用Cite模板。—— Eric Liu 創造は生命(留言 2021年12月9日 (四) 23:29 (CST)
(+)支持 意大利体是西文排版的概念,Bhsd所谓的默认行为也是因为是标准按照西方的习惯制定的。但这里是中文站点,中文排版里面并没有意大利体这个概念,强行把字倾斜只会增加阅读难度。 あめろ 讨论 2021年12月9日 (四) 23:35 (CST)

编辑请求 - あめろ - 2022.03.17

由あめろ提出的对MediaWiki:Gadget-site-styles.css的编辑请求:

状态:   拒绝

增加以下内容:

.mw-parser-output span:target, span:target+.mw-headline {
	background: rgba(66,31,255,.2);
	border-radius: .2em;
	animation: bg-fade 1.3s ease-in .7s forwards;
}
@keyframes bg-fade {
	to {
		background: rgba(66,31,255,0);
	}
}

添加章节锚点、手动锚点跳转时的提示效果。效果见Special:固定链接/5746213

.mw-parser-output限制效果仅在文章中,避免误伤。rgba(66,31,255,0)不能改成transparent,因为不同浏览器行为不一致。—— あめろ 讨论 2022年3月17日 (四) 22:24 (CST)

Done.—— 屠麟傲血讨论) 2022年3月17日 (四) 22:30 (CST)
有需要可以修改自己的CSS。 —— ほしみ 2022年3月17日 (四) 22:35 (CST)

编辑请求 - BITSALLEE - 2022.04.14

由BITSALLEE提出的对MediaWiki:Gadget-site-styles.css的编辑请求:

状态:   拒绝

将以下内容:

font-feature-settings: "locl"on; -webkit-font-feature-settings: "locl"on;

修改为:

font-feature-settings: "locl"=on; -webkit-font-feature-settings: "locl"=on;

在251行和252行可能存在错误——小狸卡讨论) 2022年4月14日 (四) 19:43 (CST)

你认真的吗? —— ほしみ 2022年4月14日 (四) 19:49 (CST)