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

fix: typo #4622

Merged
merged 1 commit into from
Sep 29, 2024
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
4 changes: 2 additions & 2 deletions helper/attributes.json
Original file line number Diff line number Diff line change
Expand Up @@ -7201,7 +7201,7 @@
"parentFirst",
"all"
],
"description": "选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaft 表示无论什么情况,选中值仅呈现叶子节点\n\ndefault: onlyLeaf\n\n[docs](https://tdesign.tencent.com/vue-next/components/tree?tab=api#tree-props)"
"description": "选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaf 表示无论什么情况,选中值仅呈现叶子节点\n\ndefault: onlyLeaf\n\n[docs](https://tdesign.tencent.com/vue-next/components/tree?tab=api#tree-props)"
},
"t-tree/active": {
"type": "event",
Expand Down Expand Up @@ -7772,4 +7772,4 @@
"type": "Number",
"description": "水印元素的 `z-index`,默认值写在 CSS 中\n\n[docs](https://tdesign.tencent.com/vue-next/components/watermark?tab=api#watermark-props)"
}
}
}
4 changes: 2 additions & 2 deletions helper/web-types.json
Original file line number Diff line number Diff line change
Expand Up @@ -19045,7 +19045,7 @@
},
{
"name": "value-mode",
"description": "选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaft 表示无论什么情况,选中值仅呈现叶子节点",
"description": "选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaf 表示无论什么情况,选中值仅呈现叶子节点",
"doc-url": "https://tdesign.tencent.com/vue-next/components/tree?tab=api#tree-props",
"type": [
"String"
Expand Down Expand Up @@ -20447,4 +20447,4 @@
]
}
}
}
}
2 changes: 1 addition & 1 deletion src/tree/props.ts
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ export default {
type: Array as PropType<TdTreeProps['defaultValue']>,
default: (): TdTreeProps['defaultValue'] => [],
},
/** 选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaft 表示无论什么情况,选中值仅呈现叶子节点 */
/** 选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaf 表示无论什么情况,选中值仅呈现叶子节点 */
valueMode: {
type: String as PropType<TdTreeProps['valueMode']>,
default: 'onlyLeaf' as TdTreeProps['valueMode'],
Expand Down
2 changes: 1 addition & 1 deletion src/tree/tree.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ scroll | Object | - | 懒加载和虚拟滚动。为保证组件收益最大化
transition | Boolean | true | 节点展开折叠时是否使用过渡动画 | N
value | Array | [] | 选中值,组件为可选状态时有效。支持语法糖 `v-model` 或 `v-model:value`。TS 类型:`Array<TreeNodeValue>` `type TreeNodeValue = string \| number`。[详细类型定义](https://github.com/Tencent/tdesign-vue-next/tree/develop/src/tree/type.ts) | N
defaultValue | Array | [] | 选中值,组件为可选状态时有效。非受控属性。TS 类型:`Array<TreeNodeValue>` `type TreeNodeValue = string \| number`。[详细类型定义](https://github.com/Tencent/tdesign-vue-next/tree/develop/src/tree/type.ts) | N
valueMode | String | onlyLeaf | 选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaft 表示无论什么情况,选中值仅呈现叶子节点。可选项:onlyLeaf/parentFirst/all | N
valueMode | String | onlyLeaf | 选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaf 表示无论什么情况,选中值仅呈现叶子节点。可选项:onlyLeaf/parentFirst/all | N
onActive | Function | | TS 类型:`(value: Array<TreeNodeValue>, context: { node: TreeNodeModel<T>; e?: MouseEvent; trigger: 'node-click' \| 'setItem' }) => void`<br/>节点激活时触发,泛型 `T` 表示树节点 TS 类型 | N
onChange | Function | | TS 类型:`(value: Array<TreeNodeValue>, context: { node: TreeNodeModel<T>; e?: any; trigger: 'node-click' \| 'setItem' }) => void`<br/>节点选中状态变化时触发,context.node 表示当前变化的选项,泛型 `T` 表示树节点 TS 类型 | N
onClick | Function | | TS 类型:`(context: { node: TreeNodeModel<T>; e: MouseEvent }) => void`<br/>节点点击时触发,泛型 `T` 表示树节点 TS 类型 | N
Expand Down
2 changes: 1 addition & 1 deletion src/tree/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ export interface TdTreeProps<T extends TreeOptionData = TreeOptionData> {
*/
modelValue?: Array<TreeNodeValue>;
/**
* 选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaft 表示无论什么情况,选中值仅呈现叶子节点
* 选中值模式。all 表示父节点和子节点全部会出现在选中值里面;parentFirst 表示当子节点全部选中时,仅父节点在选中值里面;onlyLeaf 表示无论什么情况,选中值仅呈现叶子节点
* @default onlyLeaf
*/
valueMode?: 'onlyLeaf' | 'parentFirst' | 'all';
Expand Down
Loading