mirror of
https://github.com/anomalyco/opencode.git
synced 2026-08-10 04:33:25 +00:00
fix(app): disable legacy file tree in new layout
This commit is contained in:
parent
bbb1a19ed6
commit
a16dd3d4ed
2 changed files with 6 additions and 13 deletions
|
|
@ -420,18 +420,6 @@ export const SettingsGeneralV2: Component<{
|
|||
<h3 class="settings-v2-section-title">{language.t("settings.general.section.advanced")}</h3>
|
||||
|
||||
<SettingsListV2>
|
||||
<SettingsRowV2
|
||||
title={language.t("settings.general.row.showFileTree.title")}
|
||||
description={language.t("settings.general.row.showFileTree.description")}
|
||||
>
|
||||
<div data-action="settings-show-file-tree">
|
||||
<Switch
|
||||
checked={settings.general.showFileTree()}
|
||||
onChange={(checked) => settings.general.setShowFileTree(checked)}
|
||||
/>
|
||||
</div>
|
||||
</SettingsRowV2>
|
||||
|
||||
<SettingsRowV2
|
||||
title={language.t("settings.general.row.showSearch.title")}
|
||||
description={language.t("settings.general.row.showSearch.description")}
|
||||
|
|
|
|||
|
|
@ -367,6 +367,11 @@ export const { use: useSettings, provider: SettingsProvider } = createSimpleCont
|
|||
setStore("general", "followup", "steer")
|
||||
})
|
||||
|
||||
createEffect(() => {
|
||||
if (!ready() || !newLayoutDesigns() || store.general?.showFileTree !== true) return
|
||||
setStore("general", "showFileTree", false)
|
||||
})
|
||||
|
||||
return {
|
||||
ready,
|
||||
get current() {
|
||||
|
|
@ -465,7 +470,7 @@ export const { use: useSettings, provider: SettingsProvider } = createSimpleCont
|
|||
},
|
||||
},
|
||||
visibility: {
|
||||
fileTree: visible(showFileTree),
|
||||
fileTree: createMemo(() => !newLayoutDesigns()),
|
||||
search: visible(showSearch),
|
||||
status: visible(showStatus),
|
||||
customAgents: visible(showCustomAgents),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue