From 8579ac63a21c2c8a08130576ba6688b05aa4ed6d Mon Sep 17 00:00:00 2001 From: JimmFly <447268514@qq.com> Date: Thu, 11 Apr 2024 10:04:39 +0000 Subject: [PATCH] feat(core): set the right sidebar to display TOC by default (#6503) https://github.com/toeverything/AFFiNE/assets/102217452/e37ee798-0b22-4ad4-8bf7-ed32eafc89d0 --- .../core/src/modules/multi-tab-sidebar/view/header-switcher.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/frontend/core/src/modules/multi-tab-sidebar/view/header-switcher.tsx b/packages/frontend/core/src/modules/multi-tab-sidebar/view/header-switcher.tsx index 13eecb6f50..07e086bf41 100644 --- a/packages/frontend/core/src/modules/multi-tab-sidebar/view/header-switcher.tsx +++ b/packages/frontend/core/src/modules/multi-tab-sidebar/view/header-switcher.tsx @@ -45,6 +45,7 @@ export const MultiTabSidebarHeaderSwitcher = ({ useEffect(() => { const journalExtension = tabs.find(ext => ext.name === 'journal'); isJournal && journalExtension && setActiveTabName('journal'); + !isJournal && setActiveTabName('outline'); }, [tabs, isJournal, setActiveTabName]); const vars = assignInlineVars({