跳到主要内容

分割线 Divider

用于将内容分隔为多个区域

安装使用​

import { TiDivider } from '@titian-design/mobile-vue'

用法示例​

单独使用
codesanbox
copy
code
对齐方式
居左居中居右
codesanbox
copy
code
分割线方向
codesanbox
copy
code
分割线风格
codesanbox
copy
code
分割线颜色
文字文字文字
codesanbox
copy
code
分割线厚度
codesanbox
copy
code

TiDivider API​

属性 Properties​

名称类型必填默认值说明备注
dashedboolean否false虚线-
hairlineboolean否false发丝线-
text-alignstring否center文本位置,可选值 left center right -
colorstring否-颜色,包括分割线和文字-
border-colorstring否-分割线颜色-
border-widthnumber否2分割线厚度-
orientationstring否horizontal分割线方向,可选值horizontal vertical-
ext-stylestring | Record<string, string>否-根节点样式-

插槽 Slots​

名称说明备注
default默认插槽orientation 为 horizontal 可用

外部样式类 External Classes​

名称说明备注
ext-class根节点样式类-

CSS 变量 CSS Variable​

变量默认值说明备注
--divider-gaptheme.spacing.gap.g6分割线和文字间距(orientation="horizontal")-
theme.spacing.gap.g0分割线和文字间距(orientation="vertical")-
--divider-width2px分割线厚度-
--divider-colortheme.color.gray.texticon.50分割线颜色-
--divider-stylesolid分割线类型-
--divider-font-sizetheme.fontSize.t4分割线文字字号-
--divider-text-colortheme.color.gray.texticon.550分割线文字颜色-