UNPKG

1.3 kBTypeScriptView Raw
1import * as React from "react";
2import { AbstractPureComponent2, Elevation } from "../../common";
3import { HTMLDivProps, Props } from "../../common/props";
4export declare type CardProps = ICardProps;
5/** @deprecated use CardProps */
6export interface ICardProps extends Props, HTMLDivProps {
7 /**
8 * Controls the intensity of the drop shadow beneath the card: the higher
9 * the elevation, the higher the drop shadow. At elevation `0`, no drop
10 * shadow is applied.
11 *
12 * @default 0
13 */
14 elevation?: Elevation;
15 /**
16 * Whether the card should respond to user interactions. If set to `true`,
17 * hovering over the card will increase the card's elevation
18 * and change the mouse cursor to a pointer.
19 *
20 * Recommended when `onClick` is also defined.
21 *
22 * @default false
23 */
24 interactive?: boolean;
25 /**
26 * Callback invoked when the card is clicked.
27 * Recommended when `interactive` is `true`.
28 */
29 onClick?: (e: React.MouseEvent<HTMLDivElement>) => void;
30}
31/**
32 * Card component.
33 *
34 * @see https://blueprintjs.com/docs/#core/components/card
35 */
36export declare class Card extends AbstractPureComponent2<CardProps> {
37 static displayName: string;
38 static defaultProps: CardProps;
39 render(): JSX.Element;
40}