diff --git a/packages/bruno-app/src/components/Sidebar/Collections/Collection/CollectionItem/index.js b/packages/bruno-app/src/components/Sidebar/Collections/Collection/CollectionItem/index.js index d6ecc57a9..e46b0ba8c 100644 --- a/packages/bruno-app/src/components/Sidebar/Collections/Collection/CollectionItem/index.js +++ b/packages/bruno-app/src/components/Sidebar/Collections/Collection/CollectionItem/index.js @@ -15,6 +15,7 @@ import CloneCollectionItem from './CloneCollectionItem'; import DeleteCollectionItem from './DeleteCollectionItem'; import { isItemARequest, isItemAFolder, itemIsOpenedInTabs } from 'utils/tabs'; import { doesRequestMatchSearchText, doesFolderHaveItemsMatchSearchText } from 'utils/collections/search'; +import { hideHomePage } from 'providers/ReduxStore/slices/app'; import StyledWrapper from './StyledWrapper'; @@ -68,6 +69,7 @@ const CollectionItem = ({item, collection, searchText}) => { collectionUid: collection.uid })); } + dispatch(hideHomePage()); } else { dispatch(collectionFolderClicked({ itemUid: item.uid, diff --git a/packages/bruno-app/src/components/Sidebar/TitleBar/index.js b/packages/bruno-app/src/components/Sidebar/TitleBar/index.js index e33b2ab9f..baa636175 100644 --- a/packages/bruno-app/src/components/Sidebar/TitleBar/index.js +++ b/packages/bruno-app/src/components/Sidebar/TitleBar/index.js @@ -1,8 +1,10 @@ import React, { useState, forwardRef, useRef } from 'react'; import Toast from 'components/Toast'; import Dropdown from 'components/Dropdown'; +import Bruno from 'components/Bruno'; import { useDispatch } from 'react-redux'; import { createCollection } from 'providers/ReduxStore/slices/collections'; +import { showHomePage } from 'providers/ReduxStore/slices/app'; import { IconDots } from '@tabler/icons'; import CreateCollection from '../CreateCollection'; import StyledWrapper from './StyledWrapper'; @@ -24,6 +26,7 @@ const TitleBar = () => { const handleCancel = () => setModalOpen(false); const handleCloseToast = () => setShowToast({show: false}); + const handleTitleClick = () => dispatch(showHomePage()); const handleConfirm = (values) => { setModalOpen(false); @@ -41,31 +44,16 @@ const TitleBar = () => { ) : null}