Revert "Make Tabs closable by mouseclick. Closes #778"

This commit is contained in:
Anoop M D 2023-10-26 09:54:32 +05:30 committed by GitHub
parent 7f7b3f479a
commit e274aedb9a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,7 +4,7 @@ import filter from 'lodash/filter';
import classnames from 'classnames'; import classnames from 'classnames';
import { IconChevronRight, IconChevronLeft } from '@tabler/icons'; import { IconChevronRight, IconChevronLeft } from '@tabler/icons';
import { useSelector, useDispatch } from 'react-redux'; import { useSelector, useDispatch } from 'react-redux';
import { closeTabs, focusTab } from 'providers/ReduxStore/slices/tabs'; import { focusTab } from 'providers/ReduxStore/slices/tabs';
import NewRequest from 'components/Sidebar/NewRequest'; import NewRequest from 'components/Sidebar/NewRequest';
import CollectionToolBar from './CollectionToolBar'; import CollectionToolBar from './CollectionToolBar';
import RequestTab from './RequestTab'; import RequestTab from './RequestTab';
@ -35,14 +35,6 @@ const RequestTabs = () => {
); );
}; };
const handleCloseClick = (tab) => {
dispatch(
closeTabs({
tabUids: [tab.uid]
})
);
};
const createNewTab = () => setNewRequestModalOpen(true); const createNewTab = () => setNewRequestModalOpen(true);
if (!activeTabUid) { if (!activeTabUid) {
@ -118,7 +110,6 @@ const RequestTabs = () => {
className={getTabClassname(tab, index)} className={getTabClassname(tab, index)}
role="tab" role="tab"
onClick={() => handleClick(tab)} onClick={() => handleClick(tab)}
onAuxClick={() => handleCloseClick(tab)}
> >
<RequestTab key={tab.uid} tab={tab} collection={activeCollection} /> <RequestTab key={tab.uid} tab={tab} collection={activeCollection} />
</li> </li>