内容分割组件
<z-line />
通过指定属性direction
为col
,即可将线条设置为纵向
<z-line :custom-style="{height:'30rpx'}" direction="col"></z-line>
通过指定属性content-position
,即在线条中空置文字的位置。可选值center
,left
,right
<z-line content-position="center">zebraUI</z-line>
通过指定属性dashed
,即可将线条设置为虚线
<z-line dashed />
通过指定属性custom-style
,即可自定义线条样式
<z-line content-position="center" :custom-style="{color: '#1989fa',borderColor: '#1989fa',fontSize: '24rpx'}">文本</z-line>
参数 | 说明 | 类型 | 可选值 | 默认值 |
---|---|---|---|---|
dashed | 是否显示为虚线 | boolean | false |
|
hairline | 是否使用细线条 | boolean | false |
|
content-position | 内容的位置 | string | center left right |
- |
font-size | 文字大小 | string | - | |
border-color | 线条的颜色 | string | - | |
text-color | 文字的颜色 | string | - | |
custom-style | 自定义样式 | object | - | |
direction | 线条方向 | string | row col |
row |
名称 | 说明 | Bindings |
---|---|---|
default | 默认插槽 |