@fluentui/react-northstar
Version:
A themable React component library.
47 lines (46 loc) • 2.28 kB
TypeScript
import { Accessibility } from '@fluentui/accessibility';
import * as React from 'react';
import * as PropTypes from 'prop-types';
import { UIComponentProps, ChildrenComponentProps, ColorComponentProps, ContentComponentProps } from '../../utils';
import { FluentComponentStaticProps } from '../../types';
import { DividerContent } from './DividerContent';
export interface DividerProps extends UIComponentProps, ChildrenComponentProps, ColorComponentProps, ContentComponentProps {
/**
* Accessibility behavior if overridden by the user.
*/
accessibility?: Accessibility<never>;
/** A divider can be fitted, without any space above or below it. */
fitted?: boolean;
/** A divider can be resized using this multiplier. (default: 0) */
size?: number;
/** A divider can be emphasized to draw a user's attention. */
important?: boolean;
/** A divider can be positioned vertically. */
vertical?: boolean;
}
export declare type DividerStylesProps = Required<Pick<DividerProps, 'color' | 'fitted' | 'size' | 'important' | 'vertical'> & {
hasContent: boolean;
}>;
export declare const dividerClassName = "ui-divider";
/**
* A Divider visually segments content.
*/
export declare const Divider: (<TExtendedElementType extends React.ElementType<any> = "div">(props: React.RefAttributes<HTMLDivElement> & Omit<import("@fluentui/react-bindings").PropsOfElement<TExtendedElementType>, "as" | keyof DividerProps> & {
as?: TExtendedElementType;
} & DividerProps) => JSX.Element) & {
propTypes?: React.WeakValidationMap<DividerProps> & {
as: React.Requireable<string | ((props: any, context?: any) => any) | (new (props: any, context?: any) => any)>;
};
contextTypes?: PropTypes.ValidationMap<any>;
defaultProps?: Partial<DividerProps & {
as: "div";
}>;
displayName?: string;
readonly __PRIVATE_PROPS?: React.RefAttributes<HTMLDivElement> & Omit<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
ref?: React.Ref<HTMLDivElement>;
}, "as" | keyof DividerProps> & {
as?: "div";
} & DividerProps;
} & FluentComponentStaticProps<DividerProps> & {
Content: typeof DividerContent;
};