@forge/react
11.12.011.13.0-next.0
out/components/global/index.d.ts~
out/components/global/index.d.tsModified+6−27
Index: package/out/components/global/index.d.ts
===================================================================
--- package/out/components/global/index.d.ts
+++ package/out/components/global/index.d.ts
@@ -1,31 +1,10 @@
-import type { ReactElement, ReactNode } from 'react';
-declare type GlobalElements = ReactElement<GlobalExpandableMenuItemProps> | ReactElement<GlobalLinkMenuItemProps> | ReactElement<GlobalSidebarProps> | ReactElement<GlobalMainProps> | ReactElement<GlobalProps>;
-declare type NotGlobalComponents<T> = T extends GlobalElements ? never : T;
-interface GlobalLinkMenuItemProps {
- href: string;
- label: string;
- children?: never;
-}
-interface GlobalExpandableMenuItemProps {
- children: ReactElement<GlobalLinkMenuItemProps> | ReactElement<GlobalLinkMenuItemProps>[];
- label: string;
-}
-interface GlobalSidebarProps {
- forYouUrl?: string;
- children: ReactElement<GlobalLinkMenuItemProps> | ReactElement<GlobalExpandableMenuItemProps> | Array<ReactElement<GlobalLinkMenuItemProps> | ReactElement<GlobalExpandableMenuItemProps>>;
-}
-interface GlobalMainProps {
- children: NotGlobalComponents<ReactNode>;
-}
-interface GlobalProps {
- children: [ReactElement<GlobalSidebarProps, typeof Global.Sidebar>, ReactElement<GlobalMainProps, typeof Global.Main>] | [ReactElement<GlobalMainProps, typeof Global.Main>, ReactElement<GlobalSidebarProps, typeof Global.Sidebar>];
-}
+import { TGlobalExpandableMenuItem, TGlobalLinkMenuItem, TGlobalSidebar, TGlobalMain, GlobalProps } from '@atlaskit/forge-react-types';
+import { ForgeElement } from '../../types';
export declare const Global: {
(props: GlobalProps): import("react/jsx-runtime").JSX.Element;
- Main(props: GlobalMainProps): import("react/jsx-runtime").JSX.Element;
- Sidebar({ children, forYouUrl }: GlobalSidebarProps): import("react/jsx-runtime").JSX.Element;
- ExpandMenuItem({ label, children }: GlobalExpandableMenuItemProps): import("react/jsx-runtime").JSX.Element;
- LinkMenuItem(props: GlobalLinkMenuItemProps): import("react/jsx-runtime").JSX.Element;
+ Main: TGlobalMain<ForgeElement<Record<string, any>>>;
+ Sidebar: TGlobalSidebar<ForgeElement<Record<string, any>>>;
+ LinkMenuItem: TGlobalLinkMenuItem<ForgeElement<Record<string, any>>>;
+ ExpandMenuItem: TGlobalExpandableMenuItem<ForgeElement<Record<string, any>>>;
};
-export {};
//# sourceMappingURL=index.d.ts.map
\ No newline at end of file