* Called when a change had occurred that may invalidate the statically matching selectors (class, id, ancestor selectors). * As a result, at some point in time, the selectors matched have to be requerried from the style scope and applied to the view.
()
| 546 | * As a result, at some point in time, the selectors matched have to be requerried from the style scope and applied to the view. |
| 547 | */ |
| 548 | public onChange(): void { |
| 549 | const view = this.viewRef.get(); |
| 550 | if (view && view.isLoaded) { |
| 551 | this.unsubscribeFromDynamicUpdates(); |
| 552 | this.updateMatch(); |
| 553 | this.subscribeForDynamicUpdates(); |
| 554 | this.updateDynamicState(); |
| 555 | } else { |
| 556 | this._matchInvalid = true; |
| 557 | } |
| 558 | } |
| 559 | |
| 560 | /** |
| 561 | * Checks whether style scope and CSS state selectors are in sync. |
no test coverage detected