#7 Clamours emmm,这个插件的作者代码里边写了 display: block !important;
,你需要进入插件的目录直接修改里边的css。
修改
/vendor/foskym/flarum-custom-levels/less/forum.less
替换为以下内容,然后清理缓存
.CustomLevel-level {
float: left;
position: relative;
margin-left: -85px;
top: 75px;
width: 64px;
text-align: center;
}
.CustomLevel-bar {
height: 8px;
overflow: hidden;
background: @control-bg;
border-radius: 4px;
-webkit-box-shadow: inset 0 1px 2px rgba(0,0,0,.1);
box-shadow: inset 0 1px 2px rgba(0,0,0,.1);
}
.CustomLevel-bar-value {
float: left;
width: 0%;
height: 100%;
font-size: 12px;
color: #fff;
text-align: center;
background: @primary-color;
border-radius: 10px;
-webkit-box-shadow: inset 0 -1px 0 rgba(0,0,0,.15);
box-shadow: inset 0 -1px 0 rgba(0,0,0,.15);
-webkit-transition: width .6s ease;
-o-transition: width .6s ease;
transition: width .6s ease;
}
.CustomLevel-levelNumber {
position: relative;
}
.Post--hidden .CustomLevel-level {
display: none;
}
.Post--hidden.revealContent .CustomLevel-level {
display: block;
}
.Post-header>ul>li.item-custom-levels {
display: none;
}
li.item-custom-levels {
.CustomLevel-level {
float: none;
position: relative;
margin-left: 0;
top: 0;
text-align: left;
width: auto;
}
.CustomLevel-bar {
display: none !important;
}
}
.Post-header>ul>li.item-custom-levels {
.CustomLevel-level {
float: none;
position: relative;
margin-left: 0;
margin-top: 0;
text-align: left;
width: auto;
display: inline-block;
}
.CustomLevel-bar {
display: block;
width: 64px;
}
}
@media @phone {
.CustomLevel-level {
text-align: center !important;
height: 10px;
}
.CustomLevel-bar {
display: none !important;
}
.PostUser .CustomLevel-level {
display: none;
}
.Post-header>ul>li.item-custom-levels {
display: inline;
}
}