mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-29 05:29:37 +08:00
docs: v3 -> v4 Tree & TreeSelect migration guide (#26214)
* docs: v3 -> v4 tree & treeselect label & title adjustment * docs: update links * chore * chore * fix: misplace docs * chore
This commit is contained in:
parent
dc306a20f9
commit
5537ab66e0
@ -127,6 +127,7 @@ const Demo = () => (
|
||||
- Select remove `dropdownMenuStyle` prop.
|
||||
- Use `listHeight` to config popup height instead of `dropdownStyle`.
|
||||
- `filterOption` return origin data with second params instead. No need to use `option.props.children` for matching.
|
||||
- Tree, TreeSelect will display `label` when `title` and `label` are both set. The adjustment is for aligning behavior with `labelInValue`. [New behavior](https://codesandbox.io/s/keen-curran-d3qnp) (show 'label' on first node). [Old behavior](https://codesandbox.io/s/muddy-darkness-57lb3) (show 'title' on first node).
|
||||
- The Grid component uses flex layout.
|
||||
- Button's `danger` is now treated as a property instead of a button type.
|
||||
- Input, Select set `value` to `undefined` is uncontrolled mode now.
|
||||
|
@ -127,6 +127,7 @@ const Demo = () => (
|
||||
- Select 移除 `dropdownMenuStyle` 属性。
|
||||
- 如果你需要设置弹窗高度请使用 `listHeight` 来代替 `dropdownStyle` 的高度样式。
|
||||
- `filterOption` 第二个参数直接返回原数据,不在需要通过 `option.props.children` 来进行匹配。
|
||||
- Tree、TreeSelect 同时指定 `title` 和 `label` 的时候,会选择显示 `label`。为了 `labelInValue` 行为一致进行了该调整。[新行为](https://codesandbox.io/s/keen-curran-d3qnp)(在第一个节点展示 'label'),[旧行为](https://codesandbox.io/s/muddy-darkness-57lb3)(在第一个节点展示 'title')。
|
||||
- Grid 组件使用 flex 布局。
|
||||
- Button 的 `danger` 现在作为一个属性而不是按钮类型。
|
||||
- Input、Select 的 `value` 为 `undefined` 时改为非受控状态。
|
||||
|
Loading…
Reference in New Issue
Block a user