Expands the active item if possible, otherwise navigates to the first child.
(opts?: SelectOptions)
| 459 | |
| 460 | /** Expands the active item if possible, otherwise navigates to the first child. */ |
| 461 | _expandOrFirstChild(opts?: SelectOptions) { |
| 462 | const item = this.treeBehavior.inputs.activeItem(); |
| 463 | if (item && this.treeBehavior.isExpandable(item) && !item.expanded()) { |
| 464 | this.treeBehavior.expand(item); |
| 465 | } else { |
| 466 | this.treeBehavior.firstChild(opts); |
| 467 | } |
| 468 | } |
| 469 | |
| 470 | /** Collapses the active item if possible, otherwise navigates to the parent. */ |
| 471 | _collapseOrParent(opts?: SelectOptions) { |
no test coverage detected