Question
Capgemini
SE
Last activity: 27 Nov 2024 12:11 EST
Is there an intended way to change the breakpoint for collapsing Summary Panel on Mobile and tablets in Cosmos?
Hello!
Is there an intended way to collapse Summary Panel on Mobile and tablets in Cosmos?
We noticed in Pega 24.1 that having a viewport of 1000px will decide whether the Summary Panel starts collapsed or expanded.
We noticed that 1000px is hardcoded in a final rule, is there any intended way to overwrite this with custom breakpoints in the skin or in another way?
You find the hardcoded value here: ID: webwb • pz-cosmos-ui-portal • js RS:Theme-Cosmos:05-01-01
var _hideSummaryPanelForMediumScreen = function() {
var isMdScreen = window.matchMedia('(max-width: 1000px)');
var mainPage = document.querySelector(".main-page");
if (!mainPage) return;
var isSummaryPanelCollapsed = mainPage.classList.contains('summary-collapsed');
if (isMdScreen.matches && !isSummaryPanelCollapsed) {
pega.desktop.infinity.toggleSummaryPanel();
}
};
I found this article Summary Panel Collapsed by default | Support Center (pega.com) but this doesn't seem to be the intended way for mobile and tablets as the JS code exists in pz-cosmos-ui-portal? Eventhough 1000px is a strange choice of breakpoint as some tablets in Portrait-mode are affected but not in landscape mode.
***Edited by Moderator Rupashree S. to add Capability tags***