Skip to content

树形控件中checked与halfChecked应在checkStrictly=false时运用 #1151

@lhcGinv

Description

@lhcGinv

Version

1.3.16

控件

树形控件: https://vue.ant.design/components/tree-cn/#API

What problem does this feature solve?
checkStrictly=true时,checkable状态下节点选择完全受控(父子节点选中状态不再关联),此时不可能出现halfChecked的节点, 而checkStrictly=false时, 非常需要知道checked和halfChecked分别是什么

What does the proposed API look like?

// ...
console.log(checkedKeys)
checkStrictly=ture,这个时候checkedKeys是一个数组,例如{checked: [17], halfChecked: []}, 此时halfChecked永远都是空的,
checkStrictly=false(默认), 因为父子节点选中状态有关联, 此时halfChecked应该有值

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions