Fix: hide Git Bridge, GitHub Sync and Zotero UI elements when the corresponding feature is disabled

This commit is contained in:
yu-i-i
2026-09-22 02:41:43 +02:00
parent 07a77cafd9
commit 08bc4c65dc
8 changed files with 40 additions and 12 deletions
@@ -71,7 +71,7 @@ export const RailLayout = () => {
const { features } = useProjectContext()
const { isRestrictedTokenMember } = useEditorContext()
const gitBridgeEnabled = getMeta('ol-gitBridgeEnabled')
const { isOverleaf } = getMeta('ol-ExposedSettings')
const { isOverleaf, githubSyncEnabled, zoteroEnabled } = getMeta('ol-ExposedSettings')
const { view, setSettingsShown, focusMode } = useLayoutContext()
@@ -119,7 +119,7 @@ export const RailLayout = () => {
icon: 'integration_instructions',
title: t('integrations'),
component: <IntegrationsPanel />,
hide: !isOverleaf && !gitBridgeEnabled,
hide: !isOverleaf && !gitBridgeEnabled && !githubSyncEnabled && !zoteroEnabled,
},
{
key: 'review-panel',
@@ -148,6 +148,8 @@ export const RailLayout = () => {
isRestrictedTokenMember,
isOverleaf,
gitBridgeEnabled,
githubSyncEnabled,
zoteroEnabled,
]
)