我试过了:
.listItem {
text-overflow: ellipsis;
}
.listItem:focus {
color: red;
text-overflow: none !important;
}
但这对文本溢出没有影响,尽管它确实将颜色变成了红色。有想法吗?
最佳答案
none
属性没有任何text-overflow
值。默认值为clip
。
https://developer.mozilla.org/en/CSS/text-overflow