sidebars fallback

This commit is contained in:
typescreep
2025-11-18 16:57:42 +03:00
parent 63e3581216
commit 9d5845ca7a
2 changed files with 14 additions and 1 deletions

View File

@@ -6,7 +6,11 @@ import { useSelector } from 'react-redux'
import type { RootState } from 'store/store'
// import { HEAD_FIRST_ROW, SIDEBAR_CLUSTER_HEIGHT } from 'constants/blocksSizes'
import { HEAD_FIRST_ROW } from 'constants/blocksSizes'
import { BASE_API_GROUP, BASE_API_VERSION } from 'constants/customizationApiGroupAndVersion'
import {
BASE_API_GROUP,
BASE_API_VERSION,
CUSTOMIZATION_SIDEBAR_FALLBACK_ID,
} from 'constants/customizationApiGroupAndVersion'
import { Styled } from './styled'
type TManageableSidebarProps = {
@@ -56,6 +60,8 @@ export const ManageableSidebar: FC<TManageableSidebarProps> = ({
return acc
}, {})
console.log(namespace ? `${CUSTOMIZATION_SIDEBAR_FALLBACK_ID}-namespaced` : CUSTOMIZATION_SIDEBAR_FALLBACK_ID)
return (
<Styled.Container
$isDark={theme === 'dark'}
@@ -82,6 +88,9 @@ export const ManageableSidebar: FC<TManageableSidebarProps> = ({
}}
pathname={pathname}
idToCompare={idToCompare}
fallbackIdToCompare={
namespace ? `${CUSTOMIZATION_SIDEBAR_FALLBACK_ID}-namespaced` : CUSTOMIZATION_SIDEBAR_FALLBACK_ID
}
currentTags={currentTags}
noMarginTop
/>

View File

@@ -34,6 +34,10 @@ export const BASE_CUSTOMIZATION_NAVIGATION_RESOURCE = import.meta.env.DEV
? window._env_.CUSTOMIZATION_NAVIGATION_RESOURCE || import.meta.env.VITE_CUSTOMIZATION_NAVIGATION_RESOURCE
: window._env_.CUSTOMIZATION_NAVIGATION_RESOURCE
export const CUSTOMIZATION_SIDEBAR_FALLBACK_ID = import.meta.env.DEV
? window._env_.CUSTOMIZATION_SIDEBAR_FALLBACK_ID || import.meta.env.VITE_CUSTOMIZATION_SIDEBAR_FALLBACK_ID
: window._env_.CUSTOMIZATION_SIDEBAR_FALLBACK_ID
export const BASE_USE_NAMESPACE_NAV = import.meta.env.DEV
? window._env_.USE_NAMESPACE_NAV || import.meta.env.VITE_USE_NAMESPACE_NAV
: window._env_.USE_NAMESPACE_NAV