gpt4 book ai didi

css - 防止特立尼达在生成的 CSS 中添加/覆盖样式属性

转载 作者:行者123 更新时间:2023-11-28 05:13:03 27 4
gpt4 key购买 nike

我正在处理 Apache Trinidad 1.2.14 元素。我需要对组件进行一些基本样式设置(在我的例子中是 tr:breadCrumbs)。我的问题是特立尼达不断添加甚至覆盖一些样式属性。

例如,我皮肤中的这条规则:

af|breadCrumbs { padding-bottom: 4px !important; }

在生成的 CSS 文件中呈现为:

.af_breadCrumbs { padding-bottom: 12px; display: table; }

我的皮肤正在扩展 simple.desktop:

<skin>
<id>mySkin.desktop</id>
<family>mySkin</family>
<render-kit-id>org.apache.myfaces.trinidad.desktop</render-kit-id>
<style-sheet-name>_skin/mySkin.desktop.css</style-sheet-name>
<extends>simple.desktop</extends>
</skin>

这可能是属性的来源。

我什至尝试过 -tr-inhibit: all ,但这似乎不起作用。

-tr-inhibit e.g., af|foo {-tr-inhibit: padding; color: red} This css property is used to inhibit/reset css properties that you are inheriting from a base skin.

如何防止这种行为?

最佳答案

我有强烈的感觉这是一个错误。我能够使用以下规则解决它:

html af|breadCrumbs { padding-bottom: 4px; }

在生成的 CSS 文件中呈现为:

html .af_breadCrumbs { padding-bottom: 4px; }

关于css - 防止特立尼达在生成的 CSS 中添加/覆盖样式属性,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39446913/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com