diff --git a/src/addons/messages/pages/contacts-35/contacts.html b/src/addons/messages/pages/contacts-35/contacts.html
index 285f07231..1e52521df 100644
--- a/src/addons/messages/pages/contacts-35/contacts.html
+++ b/src/addons/messages/pages/contacts-35/contacts.html
@@ -7,6 +7,8 @@
{{ 'addon.messages.contacts' | translate }}
+
+
diff --git a/src/addons/messages/pages/contacts-35/contacts.page.ts b/src/addons/messages/pages/contacts-35/contacts.page.ts
index b552e49c0..a5dd98e8a 100644
--- a/src/addons/messages/pages/contacts-35/contacts.page.ts
+++ b/src/addons/messages/pages/contacts-35/contacts.page.ts
@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-import { Component, OnDestroy, OnInit } from '@angular/core';
+import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core';
import { IonRefresher } from '@ionic/angular';
import { CoreSites } from '@services/sites';
import {
@@ -29,6 +29,7 @@ import { ActivatedRoute } from '@angular/router';
import { Translate } from '@singletons';
import { CoreScreen } from '@services/screen';
import { CoreNavigator } from '@services/navigator';
+import { CoreSplitViewComponent } from '@components/split-view/split-view';
/**
* Page that displays the list of contacts.
@@ -40,6 +41,8 @@ import { CoreNavigator } from '@services/navigator';
})
export class AddonMessagesContacts35Page implements OnInit, OnDestroy {
+ @ViewChild(CoreSplitViewComponent) splitView!: CoreSplitViewComponent;
+
protected searchingMessages: string;
protected loadingMessages: string;
protected siteId: string;
@@ -244,7 +247,9 @@ export class AddonMessagesContacts35Page implements OnInit, OnDestroy {
const path = CoreNavigator.getRelativePathToParent('/messages/contacts-35') + `discussion/user/${discussionUserId}`;
// @todo Check why this is failing on ngInit.
- CoreNavigator.navigate(path);
+ CoreNavigator.navigate(path, {
+ reset: CoreScreen.isTablet && !!this.splitView && !this.splitView.isNested,
+ });
}
/**
diff --git a/src/addons/messages/pages/contacts/contacts.html b/src/addons/messages/pages/contacts/contacts.html
index 0715dea69..00e28e4d0 100644
--- a/src/addons/messages/pages/contacts/contacts.html
+++ b/src/addons/messages/pages/contacts/contacts.html
@@ -10,6 +10,8 @@
+
+
diff --git a/src/addons/messages/pages/contacts/contacts.page.ts b/src/addons/messages/pages/contacts/contacts.page.ts
index 97535862e..187a39293 100644
--- a/src/addons/messages/pages/contacts/contacts.page.ts
+++ b/src/addons/messages/pages/contacts/contacts.page.ts
@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-import { Component, OnDestroy, OnInit } from '@angular/core';
+import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core';
import { CoreEventObserver, CoreEvents } from '@singletons/events';
import { CoreSites } from '@services/sites';
import {
@@ -24,6 +24,7 @@ import { CoreNavigator } from '@services/navigator';
import { CoreScreen } from '@services/screen';
import { CoreDomUtils } from '@services/utils/dom';
import { IonRefresher } from '@ionic/angular';
+import { CoreSplitViewComponent } from '@components/split-view/split-view';
/**
* Page that displays contacts and contact requests.
@@ -37,6 +38,8 @@ import { IonRefresher } from '@ionic/angular';
})
export class AddonMessagesContactsPage implements OnInit, OnDestroy {
+ @ViewChild(CoreSplitViewComponent) splitView!: CoreSplitViewComponent;
+
selected: 'confirmed' | 'requests' = 'confirmed';
requestsBadge = '';
selectedUserId?: number; // User id of the conversation opened in the split view.
@@ -292,7 +295,9 @@ export class AddonMessagesContactsPage implements OnInit, OnDestroy {
this.selectedUserId = userId;
const path = CoreNavigator.getRelativePathToParent('/messages/contacts') + `discussion/user/${userId}`;
- CoreNavigator.navigate(path);
+ CoreNavigator.navigate(path, {
+ reset: CoreScreen.isTablet && !!this.splitView && !this.splitView.isNested,
+ });
}
/**
diff --git a/src/addons/messages/pages/discussions-35/discussions.html b/src/addons/messages/pages/discussions-35/discussions.html
index 9d80742f2..83053d987 100644
--- a/src/addons/messages/pages/discussions-35/discussions.html
+++ b/src/addons/messages/pages/discussions-35/discussions.html
@@ -7,6 +7,8 @@
{{ 'addon.messages.messages' | translate }}
+
+
diff --git a/src/addons/messages/pages/discussions-35/discussions.page.ts b/src/addons/messages/pages/discussions-35/discussions.page.ts
index ef4df1701..0706b9b9d 100644
--- a/src/addons/messages/pages/discussions-35/discussions.page.ts
+++ b/src/addons/messages/pages/discussions-35/discussions.page.ts
@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-import { Component, OnDestroy, OnInit } from '@angular/core';
+import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core';
import { CoreEventObserver, CoreEvents } from '@singletons/events';
import { CoreSites } from '@services/sites';
import {
@@ -34,6 +34,7 @@ import { CoreNavigator } from '@services/navigator';
import { CoreScreen } from '@services/screen';
import { CoreMainMenuDeepLinkManager } from '@features/mainmenu/classes/deep-link-manager';
import { CorePlatform } from '@services/platform';
+import { CoreSplitViewComponent } from '@components/split-view/split-view';
/**
* Page that displays the list of discussions.
@@ -45,6 +46,8 @@ import { CorePlatform } from '@services/platform';
})
export class AddonMessagesDiscussions35Page implements OnInit, OnDestroy {
+ @ViewChild(CoreSplitViewComponent) splitView!: CoreSplitViewComponent;
+
protected newMessagesObserver: CoreEventObserver;
protected readChangedObserver: CoreEventObserver;
protected appResumeSubscription: Subscription;
@@ -264,7 +267,10 @@ export class AddonMessagesDiscussions35Page implements OnInit, OnDestroy {
const path = CoreNavigator.getRelativePathToParent('/messages/index') + `discussion/user/${discussionUserId}`;
- await CoreNavigator.navigate(path, { params });
+ await CoreNavigator.navigate(path, {
+ params,
+ reset: CoreScreen.isTablet && !!this.splitView && !this.splitView.isNested,
+ });
}
/**
diff --git a/src/addons/messages/pages/group-conversations/group-conversations.html b/src/addons/messages/pages/group-conversations/group-conversations.html
index 71f57c29d..223cc96d7 100644
--- a/src/addons/messages/pages/group-conversations/group-conversations.html
+++ b/src/addons/messages/pages/group-conversations/group-conversations.html
@@ -13,6 +13,8 @@
+
+
diff --git a/src/addons/messages/pages/group-conversations/group-conversations.page.ts b/src/addons/messages/pages/group-conversations/group-conversations.page.ts
index d54e0b793..d250f26ad 100644
--- a/src/addons/messages/pages/group-conversations/group-conversations.page.ts
+++ b/src/addons/messages/pages/group-conversations/group-conversations.page.ts
@@ -38,6 +38,7 @@ import { CoreNavigator } from '@services/navigator';
import { CoreScreen } from '@services/screen';
import { CoreMainMenuDeepLinkManager } from '@features/mainmenu/classes/deep-link-manager';
import { CorePlatform } from '@services/platform';
+import { CoreSplitViewComponent } from '@components/split-view/split-view';
/**
* Page that displays the list of conversations, including group conversations.
@@ -49,6 +50,8 @@ import { CorePlatform } from '@services/platform';
})
export class AddonMessagesGroupConversationsPage implements OnInit, OnDestroy {
+ @ViewChild(CoreSplitViewComponent) splitView!: CoreSplitViewComponent;
+
@ViewChild(IonContent) content?: IonContent;
@ViewChild('favlist') favListEl?: ElementRef;
@ViewChild('grouplist') groupListEl?: ElementRef;
@@ -526,7 +529,10 @@ export class AddonMessagesGroupConversationsPage implements OnInit, OnDestroy {
const path = CoreNavigator.getRelativePathToParent('/messages/group-conversations') + 'discussion/' +
(conversationId ? conversationId : `user/${userId}`);
- await CoreNavigator.navigate(path, { params });
+ await CoreNavigator.navigate(path, {
+ params,
+ reset: CoreScreen.isTablet && !!this.splitView && !this.splitView.isNested,
+ });
}
/**
diff --git a/src/addons/messages/pages/search/search.html b/src/addons/messages/pages/search/search.html
index 133b5c5ae..9830db473 100644
--- a/src/addons/messages/pages/search/search.html
+++ b/src/addons/messages/pages/search/search.html
@@ -7,6 +7,8 @@
{{ 'addon.messages.searchcombined' | translate }}
+
+
diff --git a/src/addons/messages/pages/search/search.page.ts b/src/addons/messages/pages/search/search.page.ts
index 160b34f7e..8d309a17a 100644
--- a/src/addons/messages/pages/search/search.page.ts
+++ b/src/addons/messages/pages/search/search.page.ts
@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-import { Component, OnDestroy } from '@angular/core';
+import { Component, OnDestroy, ViewChild } from '@angular/core';
import { CoreEventObserver, CoreEvents } from '@singletons/events';
import { CoreSites } from '@services/sites';
import {
@@ -25,6 +25,7 @@ import { CoreDomUtils } from '@services/utils/dom';
import { CoreApp } from '@services/app';
import { CoreNavigator } from '@services/navigator';
import { CoreScreen } from '@services/screen';
+import { CoreSplitViewComponent } from '@components/split-view/split-view';
/**
* Page for searching users.
@@ -35,6 +36,8 @@ import { CoreScreen } from '@services/screen';
})
export class AddonMessagesSearchPage implements OnDestroy {
+ @ViewChild(CoreSplitViewComponent) splitView!: CoreSplitViewComponent;
+
disableSearch = false;
displaySearching = false;
displayResults = false;
@@ -260,7 +263,9 @@ export class AddonMessagesSearchPage implements OnDestroy {
const path = CoreNavigator.getRelativePathToParent('/messages/search') + 'discussion/' +
(conversationId ? conversationId : `user/${userId}`);
- CoreNavigator.navigate(path);
+ CoreNavigator.navigate(path, {
+ reset: CoreScreen.isTablet && !!this.splitView && !this.splitView.isNested,
+ });
}
}
diff --git a/src/addons/mod/forum/components/index/index.html b/src/addons/mod/forum/components/index/index.html
index b53392089..90e871645 100644
--- a/src/addons/mod/forum/components/index/index.html
+++ b/src/addons/mod/forum/components/index/index.html
@@ -3,6 +3,8 @@
+
+
diff --git a/src/core/components/navbar-buttons/navbar-buttons.ts b/src/core/components/navbar-buttons/navbar-buttons.ts
index 3cceba4bb..662ce0cf8 100644
--- a/src/core/components/navbar-buttons/navbar-buttons.ts
+++ b/src/core/components/navbar-buttons/navbar-buttons.ts
@@ -164,6 +164,8 @@ export class CoreNavBarButtonsComponent implements OnInit, OnDestroy {
} else {
// There is a context-menu in these buttons, but there is no main context menu in the header.
// Create one main context menu dynamically.
+ // @todo: Find a better way to handle header buttons. This isn't working as expected in some cases because the menu
+ // is destroyed when the page is destroyed, so click listeners stop working.
mainContextMenuInstance = this.createMainContextMenu();
}
diff --git a/src/core/features/course/pages/index/index.html b/src/core/features/course/pages/index/index.html
index 350992231..6edf868b4 100644
--- a/src/core/features/course/pages/index/index.html
+++ b/src/core/features/course/pages/index/index.html
@@ -13,6 +13,8 @@
+
+