diff --git a/packages/common/store/InfoPanelStore.js b/packages/common/store/InfoPanelStore.js index ed4a5a121f..233a0d779b 100644 --- a/packages/common/store/InfoPanelStore.js +++ b/packages/common/store/InfoPanelStore.js @@ -75,6 +75,18 @@ class InfoPanelStore { const pathname = window.location.pathname.toLowerCase(); return pathname.indexOf("form-gallery") !== -1; }; + + getCanDisplay = () => { + const pathname = window.location.pathname.toLowerCase(); + + const isRooms = pathname.indexOf("rooms") !== -1; + const isFiles = pathname.indexOf("files") !== -1; + const isGallery = pathname.indexOf("form-gallery") !== -1; + const isAccountsHome = + pathname.indexOf("accounts") !== -1 && !(pathname.indexOf("view") !== -1); + + return isRooms || isFiles || isGallery || isAccountsHome; + }; } export default InfoPanelStore;