line-height.uvue 655 字节
Newer Older
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
1
<template>
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
2
  <view style="flex-grow: 1;">
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
3 4
    <view style="height: 500px;background-color: gray;justify-content: center;align-items: center;">
      <text class="common" style="line-height: 75px;">line-height: 75px</text>
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
5 6
      <text class="common" style="line-height: 3;">line-height: 3</text>
      <text class="common" style="line-height: 3em;">line-height: 3em</text>
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
7
      <text class="common" style="line-height: 3;">line-height: 3\nline-height: 3\nline-height: 3</text>
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
8 9
    </view>
  </view>
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
10 11 12 13 14 15 16
</template>

<script>

</script>

<style>
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
17 18
  .common {
    font-size: 20px;
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
19 20 21
    border: 1px red solid;
    margin: 10px 0;
    padding: 0 10px;
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
22
  }
DCloud-yinjiacheng's avatar
DCloud-yinjiacheng 已提交
23
</style>