我在横幅上设置了颜色和背景
横幅在其他页面(如主题)上不显示
但背景会出现在所有页面上
如何才能让横幅只显示在 discourse 主页上?
1 个赞
1 个赞
我试过了,但没用。
我安装了 Versatil 横幅并进行了以下更改
.banner-box {
width: 1070px;
height: 265px;
background-color: black;
border-radius: 30px;
}
黑色背景确实改变了,但它出现在所有页面上,当我输入
.custom-homepage {
.banner-box {
width: 1070px;
height: 265px;
background-color: black;
border-radius: 30px;
}
}
或者像这样
.custom-homepage .banner-box {
width: 1070px;
height: 265px;
background-color: black;
border-radius: 30px;
}
它不起作用
1 个赞
编辑:我现在看到您没有使用多功能横幅。这看起来像是欢迎链接横幅。
1 个赞
抱歉,我正在使用谷歌翻译
我借助 CSS 在 Banner Versátil 中添加了背景,它工作得很完美,但背景出现在所有页面上,如何让它只保留在主页上?
这是我做的 CSS 修改,在主页上效果很好
但在其他页面上背景出现了(我希望这个背景不要出现在其他页面上)
编辑:现在看看你的屏幕截图,我可以告诉你你把组件弄混了,或者翻译器把它弄乱了。那看起来像是 Welcome Link Banner 而不是 https://meta.discourse.org/t/versatile-banner/109133/1。

