Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(components): [tree-select] use new display tag #12663

Merged
merged 2 commits into from
May 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 22 additions & 5 deletions docs/en-US/component/tree-select.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,9 @@ tree-select/lazy

:::

## Attributes
## API

### Attributes

Since this component combines the functions of components `el-tree` and `el-select`,
the original properties have not been changed, so no repetition here,
Expand All @@ -106,8 +108,23 @@ and please go to the original component to view the documentation.
| [tree](./tree.md#attributes) | [tree](./tree.md#method) | [tree](./tree.md#events) | [tree](./tree.md#slots) |
| [select](./select.md#select-attributes) | [select](./select.md#methods) | [select](./select.md#select-events) | [select](./select.md#select-slots) |

### Own Attributes
#### Own Attributes

| Name | Description | Type | Default |
| ------------------- | ------------------------------------------------------------------------------------------------------------------- | ------------------------ | ------- |
| cacheData ^(2.2.26) | The cached data of the lazy node, the structure is the same as the data, used to get the label of the unloaded data | ^[object]`CacheOption[]` | [] |
wzc520pyfm marked this conversation as resolved.
Show resolved Hide resolved

## Type Declarations

<details>
<summary>Show declarations</summary>

```ts
type CacheOption = {
value: string | number | boolean | object
currentLabel: string | number
isDisabled: boolean
}
```

| Name | Description | Type | Accepted Values | Default |
| ------------------------- | ------------------------------------------------------------------------------------------------------------------- | ----- | --------------- | ------- |
| cacheData **(\> 2.2.26)** | The cached data of the lazy node, the structure is the same as the data, used to get the label of the unloaded data | array | — | — |
</details>
3 changes: 3 additions & 0 deletions packages/components/tree-select/src/tree-select.vue
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ export default defineComponent({
props: {
...ElSelect.props,
...ElTree.props,
/**
* @description The cached data of the lazy node, the structure is the same as the data, used to get the label of the unloaded data
*/
cacheData: {
type: Array,
default: () => [],
Expand Down