()
| 119 | _pattern!: TreeItemPattern<V>; |
| 120 | |
| 121 | constructor() { |
| 122 | super(); |
| 123 | effect(onCleanup => { |
| 124 | const parent = this.parent(); |
| 125 | const tree = this.tree(); |
| 126 | untracked(() => { |
| 127 | if (parent instanceof TreeItemGroup) { |
| 128 | parent._register(this); |
| 129 | } |
| 130 | tree._collection.register(this); |
| 131 | }); |
| 132 | onCleanup(() => { |
| 133 | if (parent instanceof TreeItemGroup) { |
| 134 | parent._unregister(this); |
| 135 | } |
| 136 | tree._collection.unregister(this); |
| 137 | }); |
| 138 | }); |
| 139 | afterRenderEffect({ |
| 140 | write: () => { |
| 141 | this.contentVisible.set(this._pattern.expanded()); |
| 142 | }, |
| 143 | }); |
| 144 | } |
| 145 | |
| 146 | ngOnInit() { |
| 147 | const treePattern = computed(() => this.tree()._pattern); |
nothing calls this directly
no test coverage detected