mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 10:21:05 +00:00
fix(tree-view)!: remove expanded
property from TreeNode
interface (#1631)
* fix(tree-view)!: remove `expanded` property from `TreeNode` * fix(tree-view-node-list)!: remove unused `expanded` prop * docs(tree-view): remove `expanded` as a property #1630
This commit is contained in:
parent
7701c012a5
commit
ec867c46ba
7 changed files with 4 additions and 9 deletions
|
@ -14522,9 +14522,9 @@
|
|||
"ts": "type TreeNodeId = string | number"
|
||||
},
|
||||
{
|
||||
"type": "{ id: TreeNodeId; text: any; icon?: typeof import(\"svelte\").SvelteComponent; disabled?: boolean; expanded?: boolean; children?: TreeNode[]; }",
|
||||
"type": "{ id: TreeNodeId; text: any; icon?: typeof import(\"svelte\").SvelteComponent; disabled?: boolean; children?: TreeNode[]; }",
|
||||
"name": "TreeNode",
|
||||
"ts": "interface TreeNode { id: TreeNodeId; text: any; icon?: typeof import(\"svelte\").SvelteComponent; disabled?: boolean; expanded?: boolean; children?: TreeNode[]; }"
|
||||
"ts": "interface TreeNode { id: TreeNodeId; text: any; icon?: typeof import(\"svelte\").SvelteComponent; disabled?: boolean; children?: TreeNode[]; }"
|
||||
}
|
||||
],
|
||||
"rest_props": { "type": "Element", "name": "ul" }
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
|
||||
The `children` prop accepts an array of child nodes. Each node should contain `id` and `text` properties.
|
||||
|
||||
Optional properties include `disabled`, `expanded`, `icon`, and `children`.
|
||||
Optional properties include `disabled`, `icon`, and `children`.
|
||||
|
||||
A parent node contains `children` while a leaf node does not.
|
||||
|
||||
|
|
|
@ -14,13 +14,11 @@
|
|||
id: 1,
|
||||
text: "Analytics",
|
||||
icon: Analytics,
|
||||
expanded: true,
|
||||
children: [
|
||||
{
|
||||
id: 2,
|
||||
text: "IBM Analytics Engine",
|
||||
icon: Analytics,
|
||||
expanded: true,
|
||||
children: [
|
||||
{ id: 3, text: "Apache Spark", icon: Analytics },
|
||||
{ id: 4, text: "Hadoop", icon: Analytics },
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue