fix:typescripts built errors

This commit is contained in:
Ida Dittrich 2026-01-05 06:58:54 +01:00
parent 826eead605
commit 48754d6243
2 changed files with 9 additions and 9 deletions

View file

@ -30,7 +30,7 @@ const PageManager: React.FC<PageManagerProps> = ({
const checkPageAccess = async (pageData: GenericPageData): Promise<boolean> => {
console.log('🔍 PageManager: Checking page access:', {
path: pageData.path,
label: pageData.label,
name: pageData.name,
hide: pageData.hide,
moduleEnabled: pageData.moduleEnabled
});
@ -57,7 +57,7 @@ const PageManager: React.FC<PageManagerProps> = ({
hasPageData: !!pageData,
hide: pageData?.hide,
moduleEnabled: pageData?.moduleEnabled,
label: pageData?.label
name: pageData?.name
});
if (!pageData || pageData.hide || !pageData.moduleEnabled) {
@ -83,7 +83,7 @@ const PageManager: React.FC<PageManagerProps> = ({
console.log('✅ PageManager: Rendering page:', {
path: currentPath,
label: pageData.label
name: pageData.name
});
setPageInstances(prev => {
@ -103,7 +103,7 @@ const PageManager: React.FC<PageManagerProps> = ({
if (!newInstances.has(currentPath)) {
console.log('📦 PageManager: Creating new page instance:', {
path: currentPath,
label: pageData.label
name: pageData.name
});
const shouldPreserve = pageData.preserveState || false;

View file

@ -164,7 +164,7 @@ export const SidebarProvider: React.FC<SidebarProviderProps> = ({ children }) =>
for (const pageData of mainPages) {
console.log('🔍 SidebarProvider: Checking access for page:', {
path: pageData.path,
label: pageData.label,
name: pageData.name,
hasSubpages: pageData.hasSubpages
});
@ -206,7 +206,7 @@ export const SidebarProvider: React.FC<SidebarProviderProps> = ({ children }) =>
console.log('🔍 SidebarProvider: Checking subpage access:', {
parentPath: pageData.path,
subpagePath: subpage.path,
subpageLabel: subpage.label
subpageName: subpage.name
});
const hasSubpageRBACAccess = await canView('UI', subpage.path);
@ -236,7 +236,7 @@ export const SidebarProvider: React.FC<SidebarProviderProps> = ({ children }) =>
if (accessibleSubpages.length > 0) {
console.log('✅ SidebarProvider: Adding parent page with subpages:', {
path: pageData.path,
label: pageData.label,
name: pageData.name,
subpagesCount: accessibleSubpages.length
});
// Create expandable item with submenu
@ -258,7 +258,7 @@ export const SidebarProvider: React.FC<SidebarProviderProps> = ({ children }) =>
// No accessible subpages, show as regular item
console.log('✅ SidebarProvider: Adding parent page without accessible subpages:', {
path: pageData.path,
label: pageData.label
name: pageData.name
});
items.push({
id: pageData.id,
@ -273,7 +273,7 @@ export const SidebarProvider: React.FC<SidebarProviderProps> = ({ children }) =>
// Regular items without subpages
console.log('✅ SidebarProvider: Adding regular page:', {
path: pageData.path,
label: pageData.label
name: pageData.name
});
items.push({
id: pageData.id,