@fluentui/react-northstar
Version:
A themable React component library.
58 lines (57 loc) • 2.95 kB
TypeScript
import { Accessibility } from '@fluentui/accessibility';
import * as PropTypes from 'prop-types';
import * as React from 'react';
import { UIComponentProps, ChildrenComponentProps } from '../../utils';
import { ShorthandCollection, ComponentEventHandler, FluentComponentStaticProps } from '../../types';
import { CarouselNavigationItemProps } from './CarouselNavigationItem';
export interface CarouselNavigationProps extends UIComponentProps, ChildrenComponentProps {
/**
* Accessibility behavior if overridden by the user.
*/
accessibility?: Accessibility<never>;
/** Index of the currently active item. */
activeIndex?: number | string;
/** A navigation may have just icons. */
iconOnly?: boolean;
/** A navigation may have thumbnails. */
thumbnails?: boolean;
/** Shorthand array of props for Navigation. */
items?: ShorthandCollection<CarouselNavigationItemProps>;
/**
* Called when a panel title is clicked.
*
* @param {SyntheticEvent} event - React's original SyntheticEvent.
* @param {object} data - All item props.
*/
onItemClick?: ComponentEventHandler<CarouselNavigationItemProps>;
/** The carousel navigation can have primary type. */
primary?: boolean;
/** The carousel navigation can have secondary type. */
secondary?: boolean;
/** A vertical carousel navigation displays elements vertically. */
vertical?: boolean;
/** A navigation may be clickable */
disableClickableNav?: boolean;
}
export declare type CarouselNavigationStylesProps = Required<Pick<CarouselNavigationProps, 'activeIndex' | 'iconOnly' | 'primary' | 'vertical' | 'thumbnails'>>;
export declare const carouselNavigationClassName = "ui-carousel__navigation";
/**
* A Carousel navigation helps switching between Carousel items.
*/
export declare const CarouselNavigation: (<TExtendedElementType extends React.ElementType<any> = "ul">(props: React.RefAttributes<HTMLUListElement> & Omit<import("@fluentui/react-bindings").PropsOfElement<TExtendedElementType>, "as" | keyof CarouselNavigationProps> & {
as?: TExtendedElementType;
} & CarouselNavigationProps) => JSX.Element) & {
propTypes?: React.WeakValidationMap<CarouselNavigationProps> & {
as: React.Requireable<string | ((props: any, context?: any) => any) | (new (props: any, context?: any) => any)>;
};
contextTypes?: PropTypes.ValidationMap<any>;
defaultProps?: Partial<CarouselNavigationProps & {
as: "ul";
}>;
displayName?: string;
readonly __PRIVATE_PROPS?: React.RefAttributes<HTMLUListElement> & Omit<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "key" | keyof React.HTMLAttributes<HTMLUListElement>> & {
ref?: React.Ref<HTMLUListElement>;
}, "as" | keyof CarouselNavigationProps> & {
as?: "ul";
} & CarouselNavigationProps;
} & FluentComponentStaticProps<CarouselNavigationProps>;