Skip to content

Commit

Permalink
feat: add decs
Browse files Browse the repository at this point in the history
  • Loading branch information
jahnli committed Nov 27, 2024
1 parent 18f18b6 commit e625c1a
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 19 deletions.
20 changes: 11 additions & 9 deletions src/split/demos/enUS/index.demo-entry.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,18 @@ snap-offset.vue

| Name | Type | Default | Description | Version |
| --- | --- | --- | --- | --- |
| default-size | `number` | `0.5` | Default split size, when it's `number` it should in 0 ~ 1, when it's `string` it should be formatted in `${number}px`. | 2.36.0, `string` 2.38.2 |
| default-size | `number` | `0.5` | Default split size, when it's `number` it should in 0 ~ 1, when it's `string` it should be formatted in `${number}px`. | 2.36.0, `string` 2.38.2, `(string \| number)[]` NEXT_VERSION |
| direction | `'horizontal' \| 'vertical'` | `'horizontal'` | The direction of the split. | 2.36.0 |
| disabled | `boolean` | `false` | Whether to disable the split. | 2.36.0 |
| max | `string \| number` | `1` | The maximum split threshold, when it's `number` it should in 0 ~ 1, when it's `string` it should be formatted in `${number}px`. | 2.36.0, `string` 2.38.2 |
| min | `string \| number` | `0` | The minimum threshold for splitting, when it's `number` it should in 0 ~ 1, when it's `string` it should be formatted in `${number}px`. | 2.36.0, `string` 2.38.2 |
| max | `string \| number` | `1` | The maximum split threshold, when it's `number` it should in 0 ~ 1, when it's `string` it should be formatted in `${number}px`. | 2.36.0, `string` 2.38.2,`(string \| number)[]` NEXT_VERSION |
| min | `string \| number` | `0` | The minimum threshold for splitting, when it's `number` it should in 0 ~ 1, when it's `string` it should be formatted in `${number}px`. | 2.36.0, `string` 2.38.2,`(string \| number)[]` NEXT_VERSION |
| pane1-class | `string` | `undefined` | The class name of the first pane. | 2.38.2 |
| pane1-style | `Object \| string` | `undefined` | The Style of the first pane | 2.38.2 |
| pane2-class | `string` | `undefined` | The class name of the second pane. | 2.38.2 |
| pane2-style | `Object \| string` | `undefined` | The Style of the second pane | 2.38.2 |
| resize-trigger-size | `number` | `3` | Size of the resize trigger. | 2.36.0 |
| size | `string \| number` | `undefined` | Split is the controlled split size, when it's `number` it should in 0 ~ 1, when it's `string` it should be formatted in `${number}px`. | 2.38.0, `string` 2.38.2 |
| size | `string \| number` | `undefined` | Split is the controlled split size, when it's `number` it should in 0 ~ 1, when it's `string` it should be formatted in `${number}px`. | 2.38.0, `string` 2.38.2,`(string \| number)[]` NEXT_VERSION |
| snap-offset | `number` | `undefined` | The snap offset of the split. | NEXT_VERSION |
| watch-props | `Array<'defaultSize'>` | `undefined` | Default prop names that needed to be watched. Components will be updated after the prop is changed. Note: the `watch-props` itself is not reactive. | 2.38.0 |
| on-drag-start | `(e: Event) => void` | `undefined` | Callback function when drag start. | 2.36.0 |
| on-drag-move | `(e: Event) => void` | `undefined` | Callback function when dragging. | 2.36.0 |
Expand All @@ -42,8 +43,9 @@ snap-offset.vue

### Split Slots

| Name | Parameters | Description | Version |
| -------------- | ---------- | ------------------------ | ------- |
| 1 | `()` | The first pane content. | 2.36.0 |
| 2 | `()` | The Second pane content. | 2.36.0 |
| resize-trigger | `()` | Split bar content. | 2.36.0 |
| Name | Parameters | Description | Version |
| -------------- | ---------- | ------------------------ | ------------ |
| 1 | `()` | The first pane content. | 2.36.0 |
| 2 | `()` | The Second pane content. | 2.36.0 |
| \* | `()` | The \* pane content. | NEXT_VERSION |
| resize-trigger | `()` | Split bar content. | 2.36.0 |
2 changes: 1 addition & 1 deletion src/split/demos/enUS/snap-offset.demo.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<markdown>
# 吸附偏移
# Snap Offset
</markdown>

<template>
Expand Down
19 changes: 10 additions & 9 deletions src/split/demos/zhCN/index.demo-entry.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,17 @@ snap-offset.vue

| 名称 | 类型 | 默认值 | 说明 | 版本 |
| --- | --- | --- | --- | --- |
| default-size | `string \| number` | `0.5` | Split 的默认分割大小,为 `number` 类型时应该为 0 ~ 1 之间的值,为 `string` 类型时应该为 `${number}px` 格式 | 2.36.0, `string` 2.38.2 |
| default-size | `string \| number` | `0.5` | Split 的默认分割大小,为 `number` 类型时应该为 0 ~ 1 之间的值,为 `string` 类型时应该为 `${number}px` 格式 | 2.36.0, `string` 2.38.2,`(string \| number)[]` NEXT_VERSION |
| direction | `'horizontal' \| 'vertical'` | `'horizontal'` | Split 的分割方向 | 2.36.0 |
| disabled | `boolean` | `false` | 是否禁用 | 2.36.0 |
| max | `string \| number` | `1` | Split 的分割最大阈值,为 `number` 类型时应该为 0 ~ 1 之间的值,为 `string` 类型时应该为 `${number}px` 格式 | 2.36.0, `string` 2.38.2 |
| min | `string \| number` | `0` | Split 的分割最小阈值,为 `number` 类型时应该为 0 ~ 1 之间的值,为 `string` 类型时应该为 `${number}px` 格式 | 2.36.0, `string` 2.38.2 |
| max | `string \| number` | `1` | Split 的分割最大阈值,为 `number` 类型时应该为 0 ~ 1 之间的值,为 `string` 类型时应该为 `${number}px` 格式 | 2.36.0, `string` 2.38.2,`(string \| number)[]` NEXT_VERSION |
| min | `string \| number` | `0` | Split 的分割最小阈值,为 `number` 类型时应该为 0 ~ 1 之间的值,为 `string` 类型时应该为 `${number}px` 格式 | 2.36.0, `string` 2.38.2,`(string \| number)[]` NEXT_VERSION |
| pane1-class | `string` | `undefined` | 第一个面板的类名 | 2.38.2 |
| pane1-style | `Object \| string` | `undefined` | 第一个面板的样式 | 2.38.2 |
| pane2-class | `string` | `undefined` | 第二个面板的类名 | 2.38.2 |
| pane2-style | `Object \| string` | `undefined` | 第二个面板的样式 | 2.38.2 |
| resize-trigger-size | `number` | `3` | Split 的分隔条大小 | 2.36.0 |
| size | `string \| number` | `undefined` | Split 的受控分割大小,为 `number` 类型时应该为 0 ~ 1 之间的值,为 `string` 类型时应该为 `${number}px` 格式 | 2.38.0, `string` 2.38.2 |
| size | `string \| number` | `undefined` | Split 的受控分割大小,为 `number` 类型时应该为 0 ~ 1 之间的值,为 `string` 类型时应该为 `${number}px` 格式 | 2.38.0, `string` 2.38.2,`(string \| number)[]` NEXT_VERSION |
| snap-offset | `number` | `undefined` | Split 的吸附偏移量 | NEXT_VERSION |
| watch-props | `Array<'defaultSize'>` | `undefined` | 需要检测变更的默认属性,检测后组件状态会更新。注意:`watch-props` 本身不是响应式的 | 2.38.0 |
| on-drag-start | `(e: Event) => void` | `undefined` | 开始拖拽的回调函数 | 2.36.0 |
Expand All @@ -43,8 +43,9 @@ snap-offset.vue

### Split Slots

| 名称 | 参数 | 说明 | 版本 |
| -------------- | ---- | -------------- | ------ |
| 1 | `()` | 第一个面板内容 | 2.36.0 |
| 2 | `()` | 第二个面板内容 | 2.36.0 |
| resize-trigger | `()` | 分割条内容 | 2.36.0 |
| 名称 | 参数 | 说明 | 版本 |
| -------------- | ---- | ---------------- | ------------ |
| 1 | `()` | 第一个面板内容 | 2.36.0 |
| 2 | `()` | 第二个面板内容 | 2.36.0 |
| \* | `()` |\* 个面板内容 | NEXT_VERSION |
| resize-trigger | `()` | 分割条内容 | 2.36.0 |

0 comments on commit e625c1a

Please sign in to comment.