UNPKG

@carbon/ibm-products

Version:

Carbon for IBM Products

293 lines (292 loc) 9.91 kB
/** * Copyright IBM Corp. 2025, 2025 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. */ import React, { type ComponentType, type FunctionComponent } from 'react'; import { IconButtonProps, BreadcrumbItemProps, BreadcrumbProps } from '@carbon/react'; import { TYPES } from '@carbon/react/es/components/Tag/Tag'; /** * ---------- * PageHeader * ---------- */ interface PageHeaderProps { children?: React.ReactNode; className?: string; } declare const PageHeader: React.ForwardRefExoticComponent<PageHeaderProps & React.RefAttributes<HTMLDivElement>>; /** * ----------------------- * PageHeaderBreadcrumbBar * ----------------------- */ interface PageHeaderBreadcrumbBarProps { /** * `true` by default to render BreadcrumbBar bottom border. */ border?: boolean; children?: React.ReactNode; className?: string; /** * Provide an optional icon to render in front of the PageHeaderContent's title. */ renderIcon?: ComponentType | FunctionComponent; /** * The PageHeaderBreadcrumbBar's content actions */ contentActions?: React.ReactNode; /** * `true` to set content actions flush against page actions */ contentActionsFlush?: boolean; /** * The PageHeaderContent's page actions */ pageActions?: React.ReactNode; /** * `true` to set page actions flush with page */ pageActionsFlush?: boolean; } declare const PageHeaderBreadcrumbBar: React.ForwardRefExoticComponent<PageHeaderBreadcrumbBarProps & React.RefAttributes<HTMLDivElement>>; /** * ----------------- * PageHeaderContent * ----------------- */ interface PageHeaderContentProps { /** * Provide child elements to be rendered inside PageHeaderContent. */ children?: React.ReactNode; /** * Specify an optional className to be added to your PageHeaderContent */ className?: string; /** * Provide an optional icon to render in front of the PageHeaderContent's title. */ renderIcon?: ComponentType | FunctionComponent; /** * The PageHeaderContent's title */ title: string; /** * The PageHeaderContent's contextual actions */ contextualActions?: React.ReactNode; /** * The PageHeaderContent's page actions */ pageActions?: React.ReactNode; } declare const PageHeaderContent: React.ForwardRefExoticComponent<PageHeaderContentProps & React.RefAttributes<HTMLDivElement>>; /** * ---------------- * PageHeaderContentPageActions * ---------------- */ interface PageHeaderContentPageActionsProps { /** * Provide child elements to be rendered inside PageHeaderContentPageActions. */ children?: React.ReactNode; /** * Specify an optional className to be added to your PageHeaderContentPageActions */ className?: string; /** * The PageHeaderContent's page actions collapsible Menu button label */ menuButtonLabel?: string; /** * The PageHeaderContent's page actions */ actions?: React.ReactNode; } declare const PageHeaderContentPageActions: { ({ className, children, menuButtonLabel, actions, ...other }: PageHeaderContentPageActionsProps): React.JSX.Element; displayName: string; propTypes: { /** * The PageHeaderContent's page actions */ actions: any; /** * Provide child elements to be rendered inside PageHeaderContentPageActions. */ children: any; /** * Specify an optional className to be added to your PageHeaderContentPageActions */ className: any; /** * The PageHeaderContent's collapsible Menu button label */ menuButtonLabel: any; }; }; /** * ---------------- * PageHeaderContentText * ---------------- */ interface PageHeaderContentTextProps { /** * Provide child elements to be rendered inside PageHeaderContentText. */ children?: React.ReactNode; /** * Specify an optional className to be added to your PageHeaderContentText */ className?: string; /** * The PageHeaderContent's subtitle */ subtitle?: string; } declare const PageHeaderContentText: { ({ className, children, subtitle, ...other }: PageHeaderContentTextProps): React.JSX.Element; displayName: string; propTypes: { /** * Provide child elements to be rendered inside PageHeaderContentText. */ children: any; /** * Specify an optional className to be added to your PageHeaderContentText */ className: any; /** * The PageHeaderContent's subtitle */ subtitle: any; }; }; /** * ---------------- * PageHeaderHeroImage * ---------------- */ interface PageHeaderHeroImageProps { /** * Provide child elements to be rendered inside PageHeaderHeroImage. */ children?: React.ReactNode; /** * Specify an optional className to be added to your PageHeaderHeroImage */ className?: string; } declare const PageHeaderHeroImage: { ({ className, children, ...other }: PageHeaderHeroImageProps): React.JSX.Element; displayName: string; propTypes: { /** * Provide child elements to be rendered inside PageHeaderHeroImage. */ children: any; /** * Specify an optional className to be added to your PageHeaderHeroImage */ className: any; }; }; /** * ---------------- * PageHeaderTabBar * ---------------- */ interface TagItem { type: keyof typeof TYPES; text: string; size?: 'sm' | 'md' | 'lg'; id: string; } interface PageHeaderTabBarProps { children?: React.ReactNode; className?: string; tags?: TagItem[]; scroller?: React.ReactNode; } declare const PageHeaderTabBar: React.ForwardRefExoticComponent<PageHeaderTabBarProps & React.RefAttributes<HTMLDivElement>>; interface PageHeaderScrollButtonProps extends IconButtonProps { collapseText?: string; expandText?: string; } declare const PageHeaderScrollButton: React.ForwardRefExoticComponent<PageHeaderScrollButtonProps & React.RefAttributes<HTMLDivElement>>; declare const PageHeaderTitleBreadcrumb: React.ForwardRefExoticComponent<BreadcrumbItemProps & React.RefAttributes<HTMLLIElement>>; interface PageHeaderBreadcrumbOverflowProps extends BreadcrumbProps { renderOverflowBreadcrumb?: (hiddenBreadcrumbs: HTMLElement[]) => React.ReactElement<BreadcrumbItemProps>; } declare const PageHeaderBreadcrumbOverflow: React.ForwardRefExoticComponent<PageHeaderBreadcrumbOverflowProps & React.RefAttributes<HTMLElement>>; /** * ------- * Exports * ------- */ declare const Root: React.ForwardRefExoticComponent<PageHeaderProps & React.RefAttributes<HTMLDivElement>>; declare const BreadcrumbBar: React.ForwardRefExoticComponent<PageHeaderBreadcrumbBarProps & React.RefAttributes<HTMLDivElement>>; declare const Content: React.ForwardRefExoticComponent<PageHeaderContentProps & React.RefAttributes<HTMLDivElement>>; declare const ContentPageActions: { ({ className, children, menuButtonLabel, actions, ...other }: PageHeaderContentPageActionsProps): React.JSX.Element; displayName: string; propTypes: { /** * The PageHeaderContent's page actions */ actions: any; /** * Provide child elements to be rendered inside PageHeaderContentPageActions. */ children: any; /** * Specify an optional className to be added to your PageHeaderContentPageActions */ className: any; /** * The PageHeaderContent's collapsible Menu button label */ menuButtonLabel: any; }; }; declare const ContentText: { ({ className, children, subtitle, ...other }: PageHeaderContentTextProps): React.JSX.Element; displayName: string; propTypes: { /** * Provide child elements to be rendered inside PageHeaderContentText. */ children: any; /** * Specify an optional className to be added to your PageHeaderContentText */ className: any; /** * The PageHeaderContent's subtitle */ subtitle: any; }; }; declare const HeroImage: { ({ className, children, ...other }: PageHeaderHeroImageProps): React.JSX.Element; displayName: string; propTypes: { /** * Provide child elements to be rendered inside PageHeaderHeroImage. */ children: any; /** * Specify an optional className to be added to your PageHeaderHeroImage */ className: any; }; }; declare const TabBar: React.ForwardRefExoticComponent<PageHeaderTabBarProps & React.RefAttributes<HTMLDivElement>>; declare const ScrollButton: React.ForwardRefExoticComponent<PageHeaderScrollButtonProps & React.RefAttributes<HTMLDivElement>>; declare const TitleBreadcrumb: React.ForwardRefExoticComponent<BreadcrumbItemProps & React.RefAttributes<HTMLLIElement>>; declare const BreadcrumbOverflow: React.ForwardRefExoticComponent<PageHeaderBreadcrumbOverflowProps & React.RefAttributes<HTMLElement>>; export { PageHeader, PageHeaderBreadcrumbBar, PageHeaderContent, PageHeaderContentPageActions, PageHeaderContentText, PageHeaderHeroImage, PageHeaderTabBar, PageHeaderScrollButton, PageHeaderTitleBreadcrumb, PageHeaderBreadcrumbOverflow, Root, BreadcrumbBar, Content, ContentPageActions, ContentText, HeroImage, TabBar, ScrollButton, TitleBreadcrumb, BreadcrumbOverflow, }; export type { PageHeaderProps, PageHeaderBreadcrumbBarProps, PageHeaderContentProps, PageHeaderContentPageActionsProps, PageHeaderContentTextProps, PageHeaderHeroImageProps, PageHeaderTabBarProps, PageHeaderScrollButtonProps, };