mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
fix(core): Store ICU state in LView rather than in TView (#39233)
Before this refactoring/fix the ICU would store the current selected index in `TView`. This is incorrect, since if ICU is in `ngFor` it will cause issues in some circumstances. This refactoring properly moves the state to `LView`. closes #37021 closes #38144 closes #38073 PR Close #39233
This commit is contained in:
committed by
Alex Rickabaugh
parent
6790848f68
commit
ca11ef2376
@@ -158,8 +158,13 @@ export abstract class Renderer2 {
|
||||
* @param parent The parent node.
|
||||
* @param newChild The new child nodes.
|
||||
* @param refChild The existing child node before which `newChild` is inserted.
|
||||
* @param isMove Optional argument which signifies if the current `insertBefore` is a result of a
|
||||
* move. Animation uses this information to trigger move animations. In the past the Animation
|
||||
* would always assume that any `insertBefore` is a move. This is not strictly true because
|
||||
* with runtime i18n it is possible to invoke `insertBefore` as a result of i18n and it should
|
||||
* not trigger an animation move.
|
||||
*/
|
||||
abstract insertBefore(parent: any, newChild: any, refChild: any): void;
|
||||
abstract insertBefore(parent: any, newChild: any, refChild: any, isMove?: boolean): void;
|
||||
/**
|
||||
* Implement this callback to remove a child node from the host element's DOM.
|
||||
* @param parent The parent node.
|
||||
|
||||
Reference in New Issue
Block a user