mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-24 21:05:59 +00:00
close all fix
This commit is contained in:
@@ -176,7 +176,14 @@ export default function TabsPanel() {
|
|||||||
|
|
||||||
const closeTab = closeTabFunc((x, active) => x.tabid == active.tabid);
|
const closeTab = closeTabFunc((x, active) => x.tabid == active.tabid);
|
||||||
const closeAll = () => {
|
const closeAll = () => {
|
||||||
setOpenedTabs([]);
|
const closedTime = new Date().getTime();
|
||||||
|
setOpenedTabs((tabs) =>
|
||||||
|
tabs.map((tab) => ({
|
||||||
|
...tab,
|
||||||
|
closedTime: tab.closedTime || closedTime,
|
||||||
|
selected: false,
|
||||||
|
}))
|
||||||
|
);
|
||||||
};
|
};
|
||||||
const closeWithSameDb = closeTabFunc(
|
const closeWithSameDb = closeTabFunc(
|
||||||
(x, active) =>
|
(x, active) =>
|
||||||
|
|||||||
Reference in New Issue
Block a user