From cf595146a83a3a631c895b1661afb52c0dcef1ea Mon Sep 17 00:00:00 2001 From: Dani Palou Date: Wed, 3 May 2023 12:50:32 +0200 Subject: [PATCH] MOBILE-4270 collapsible-header: Fix changes not detected Before this change, listenEvents was called after initializeFloatingTitle, so the mutationObserver didn't exist when initializeFloatingTitle was executed. --- src/core/directives/collapsible-header.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/directives/collapsible-header.ts b/src/core/directives/collapsible-header.ts index 28d1c7f09..bdc9dc474 100644 --- a/src/core/directives/collapsible-header.ts +++ b/src/core/directives/collapsible-header.ts @@ -125,6 +125,8 @@ export class CoreCollapsibleHeaderDirective implements OnInit, OnChanges, OnDest await this.enteredPromise, ]); + this.listenEvents(); + await this.initializeFloatingTitle(); this.initializeContent(); } @@ -291,8 +293,6 @@ export class CoreCollapsibleHeaderDirective implements OnInit, OnChanges, OnDest return; } - this.listenEvents(); - // Initialize from tabs. const tabs = CoreDirectivesRegistry.resolve(this.page.querySelector('core-tabs-outlet'), CoreTabsOutletComponent);