There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.
TypeScript appcrdteditorelectronknowledge-basemarkdownmironotesnotionnotion-alternativerustrust-langrust-languagetabletableviewwhiteboardwikiworkspace
fix(electron): duplicate tab views issue (#7703)
pengx17cbdcfdc2d8ad
diff --git a/packages/frontend/electron/src/main/windows-manager/tab-views.ts b/packages/frontend/electron/src/main/windows-manager/tab-views.tsindex e937f801ce..c0bea63e2f 100644--- a/packages/frontend/electron/src/main/windows-manager/tab-views.ts+++ b/packages/frontend/electron/src/main/windows-manager/tab-views.ts@@ -387,7 +387,7 @@ export class WebContentViewsManager {addTab = async (option?: AddTabOption) => {if (!option) {const activeWorkbench = this.activeWorkbenchMeta;- const basename = (activeWorkbench?.basename ?? '') + '/';+ const basename = activeWorkbench?.basename ?? '/';option = {basename,@@ -395,7 +395,7 @@ export class WebContentViewsManager {title: 'New Tab',path: basename.startsWith('/workspace')? {- pathname: 'all',+ pathname: '/all',}: undefined,},@@ -1025,7 +1025,11 @@ export const showTabContextMenu = async (tabId: string, viewIndex: number) => {{label: 'Duplicate tab',click: () => {- addTab(tabMeta).catch(logger.error);+ addTab({+ basename: tabMeta.basename,+ view: tabMeta.views,+ show: false,+ }).catch(logger.error);},},