mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
chore(Divider): use tsx
This commit is contained in:
parent
861a77ce44
commit
aaec78d54d
@ -61,11 +61,11 @@ app.use(Divider);
|
||||
|
||||
### Props
|
||||
|
||||
| 参数 | 说明 | 类型 | 默认值 |
|
||||
| ---------------- | -------------------------------- | --------- | -------- |
|
||||
| dashed | 是否使用虚线 | _boolean_ | `false` |
|
||||
| hairline | 是否使用 0.5px 线 | _boolean_ | `true` |
|
||||
| content-position | 内容位置,可选值为`left` `right` | _string_ | `center` |
|
||||
| 参数 | 说明 | 类型 | 默认值 |
|
||||
| ---------------- | --------------------------------- | --------- | -------- |
|
||||
| dashed | 是否使用虚线 | _boolean_ | `false` |
|
||||
| hairline | 是否使用 0.5px 线 | _boolean_ | `true` |
|
||||
| content-position | 内容位置,可选值为 `left` `right` | _string_ | `center` |
|
||||
|
||||
### Slots
|
||||
|
||||
|
@ -1,7 +1,10 @@
|
||||
import { PropType } from 'vue';
|
||||
import { createNamespace } from '../utils';
|
||||
|
||||
const [createComponent, bem] = createNamespace('divider');
|
||||
|
||||
export type DividerContentPosition = 'left' | 'center' | 'right';
|
||||
|
||||
export default createComponent({
|
||||
props: {
|
||||
dashed: Boolean,
|
||||
@ -10,7 +13,7 @@ export default createComponent({
|
||||
default: true,
|
||||
},
|
||||
contentPosition: {
|
||||
type: String,
|
||||
type: String as PropType<DividerContentPosition>,
|
||||
default: 'center',
|
||||
},
|
||||
},
|
Loading…
x
Reference in New Issue
Block a user