如果您查看源代码,您会发现问题是编译后的版本在 css-select-moz 跨度之间有一个空行。
在你的静态版本中比较这个:
<div class="margFt">
<span class='css-select-moz margFt wshare '>
<select id="test" class="tst" name="test">
<option value="SelectBoxIt is:" selected>Width:</option>
<option value="a jQuery Plugin">a jQuery Plugin</option>
<option value="a Select Box Replacement">a Select Box Replacement</option>
<option value="a Stateful UI Widget">a Stateful UI Widget</option>
</select>
</span>
<span class='css-select-moz margFt wshare'>
<select id="test" class="tst" name="test">
<option value="SelectBoxIt is:" selected>Profile:</option>
<option value="a jQuery Plugin">a jQuery Plugin</option>
<option value="a Select Box Replacement">a Select Box Replacement</option>
<option value="a Stateful UI Widget">a Stateful UI Widget</option>
</select>
</span>
</div>
到您生成的版本:
<div class="margFt">
<span class='css-select-moz margFt wshare '>
<select id="tyre-width"
data-val="true"
data-val-required="The WidthUID field is required."
class="tst"
name="tyre-width"></select>
</span>
<span class='css-select-moz margFt wshare'>
<select id="tyre-profile"
data-val="true"
data-val-required="The ProfileUID field is required."
class="tst"
name="tyre-profile"></select>
</span>
</div>
这是display:inline-block 元素之间的空白的已知问题。 this article and associated comment 中描述了一些解决方法。我很快尝试了font-size:0 技巧,并且确实解决了它,所以这一定是问题所在。
更新
只是再次播放,而不是将.css-display-moz 设置为display:inline:block;,将其设置为float:left; 会使它们变得更好——它们只是稍微向左移动,但垂直间距不是问题。这可能需要考虑。