UNPKG

@primer/react

Version:

An implementation of GitHub's Primer Design System using React

56 lines 2.27 kB
import React from 'react'; type ActionListSubItemProps = { children?: React.ReactNode; }; export declare const SubItem: React.FC<ActionListSubItemProps>; declare const Item: (<As extends React.ElementType = "li">(props: (import("../utils/modern-polymorphic").PolymorphicProps<As, "li"> extends infer T ? T extends import("../utils/modern-polymorphic").PolymorphicProps<As, "li"> ? T extends any ? Omit<T, "onSelect"> : never : never : never) & { children?: React.ReactNode; onSelect?: (event: React.MouseEvent<HTMLElement> | React.KeyboardEvent<HTMLElement>) => void; selected?: boolean; active?: boolean; variant?: "default" | "danger"; size?: "medium" | "large"; disabled?: boolean; role?: import("../utils/types").AriaRole; id?: string; inactiveText?: string; loading?: boolean; _PrivateItemWrapper?: React.FC<React.PropsWithChildren<{ onClick?: (event: React.MouseEvent<HTMLElement>) => void; onKeyPress?: (event: React.KeyboardEvent<HTMLElement>) => void; 'aria-disabled'?: boolean; tabIndex?: number; 'aria-labelledby'?: string; 'aria-describedby'?: string; role?: string; className?: string; }>>; className?: string; groupId?: string; renderItem?: (item: React.FC<React.PropsWithChildren<{ onClick?: (event: React.MouseEvent<HTMLElement>) => void; onKeyPress?: (event: React.KeyboardEvent<HTMLElement>) => void; 'aria-disabled'?: boolean; tabIndex?: number; 'aria-labelledby'?: string; 'aria-describedby'?: string; role?: string; className?: string; }>>) => React.ReactNode; handleAddItem?: (item: React.FC<React.PropsWithChildren<{ onClick?: (event: React.MouseEvent<HTMLElement>) => void; onKeyPress?: (event: React.KeyboardEvent<HTMLElement>) => void; 'aria-disabled'?: boolean; tabIndex?: number; 'aria-labelledby'?: string; 'aria-describedby'?: string; role?: string; className?: string; }>>) => void; as?: As | undefined; } & React.RefAttributes<any>) => React.ReactNode) & { displayName: string; __SLOT__: symbol; }; export { Item }; //# sourceMappingURL=Item.d.ts.map