具有多行标签的窗体中的垂直对齐(水平放置标签-输入)

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了具有多行标签的窗体中的垂直对齐(水平放置标签-输入)相关的知识,希望对你有一定的参考价值。

this snippet is for this html structure

%form
%ol
%li
%label Label:
%input
  1. li {
  2. display: inline-block;
  3. line-height: 0;
  4. }
  5.  
  6. label {
  7. display: inline-block;
  8. line-height: 1.5em;
  9. vertical-align: middle;
  10. }
  11.  
  12. input {
  13. display: inline-block;
  14. vertical-align: middle;
  15. }

以上是关于具有多行标签的窗体中的垂直对齐(水平放置标签-输入)的主要内容,如果未能解决你的问题,请参考以下文章