mirror of
https://github.com/SteamDeckHomebrew/decky-frontend-lib.git
synced 2026-06-05 09:06:56 +02:00
fix(components): fix missing children prop
also remove unnessecary use of tsx
This commit is contained in:
28
src/components/SidebarNavigation.ts
Normal file
28
src/components/SidebarNavigation.ts
Normal file
@@ -0,0 +1,28 @@
|
||||
import { ReactNode, FC } from 'react';
|
||||
|
||||
import { Export, findModuleExport } from '../webpack';
|
||||
|
||||
export interface SidebarNavigationPage {
|
||||
title: ReactNode;
|
||||
content: ReactNode;
|
||||
icon?: ReactNode;
|
||||
visible?: boolean;
|
||||
hideTitle?: boolean;
|
||||
identifier?: string;
|
||||
route?: string;
|
||||
link?: string;
|
||||
padding?: 'none' | 'compact';
|
||||
}
|
||||
|
||||
export interface SidebarNavigationProps {
|
||||
title?: string;
|
||||
pages: (SidebarNavigationPage | 'separator')[];
|
||||
showTitle?: boolean;
|
||||
disableRouteReporting?: boolean;
|
||||
page?: string;
|
||||
onPageRequested?: (page: string) => void;
|
||||
}
|
||||
|
||||
export const SidebarNavigation = findModuleExport((e: Export) =>
|
||||
e?.toString()?.includes('"disableRouteReporting"'),
|
||||
) as FC<SidebarNavigationProps>;
|
||||
Reference in New Issue
Block a user