如何取消最大高度? [英] How to unset max-height?
本文介绍了如何取消最大高度?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如果先前已经在某些CSS规则中设置了max-height
属性,如何将其重置为默认值?这不起作用:
How to I reset the max-height
property to its default, if it has been previously set in some CSS rule? This doesn't work:
pre {
max-height: 250px;
}
pre.doNotLimitHeight {
max-height: auto; // Doesn't work at least in Chrome
}
推荐答案
将其重置为none
:
pre {
max-height: 250px;
}
pre.doNotLimitHeight {
max-height: none;
}
Reference
这篇关于如何取消最大高度?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文