我正在尝试理解为什么我需要增加像素的值来减少边距。让我添加一些代码。
首先是基础知识:
$base-font-size: 16px;
$base-line-height: 24px;
@include establish-baseline; I要减少标记中的一些边距,为此,我以像素为单位增加了值:
h3 {
font-weight:500;
@include adjust-font-size-to(26px);
margin: rhythm(1, 56px) 0 0 0; /* 2 line above, 1 line below */
} 为什么我需要增加px值?
发布于 2014-05-23 16:56:22
好的,我认为你的问题有点不清楚。
首先,“以像素为单位增加值”是什么意思,哪个值?
而且,它非常不完整,你是否使用了一些重置或蓝图?
$base-font-size: 16px;
$base-line-height: 24px;
@include establish-baseline; 因此,您可以设置您的基线,这是可以的。
h3 {
font-weight:500;
@include adjust-font-size-to(26px);
margin: rhythm(1, 56px) 0 0 0; /* 2 line above, 1 line below */}
但这一部分还不清楚。如果您只使用您编写的代码,则没有应用边距或填充,因此您的问题是无效的。
您必须指定此值的来源。另外,我认为你应该参考一下:
http://compass-style.org/reference/compass/typography/vertical_rhythm/
此外,这也会有所帮助:
https://medium.com/typography/34fe2f1d2c02
请更新答案并添加额外信息。
https://stackoverflow.com/questions/23068424
复制相似问题