import React, { PropsWithChildren, ReactNode } from 'react';
import { CarbonIconType } from '@carbon/icons-react/lib/CarbonIcon';
import { ActionIcon } from '../Card/Card';
type overflowAction = {
id?: string;
itemText?: string;
onClick?: (event: MouseEvent) => void;
onKeyDown?: (event: KeyboardEvent) => void;
};
type PlacementType = 'top' | 'bottom';
type ClickZoneType = 'one' | 'two' | 'three';
export interface ProductiveCardProps extends PropsWithChildren {
/**
* Icons that are displayed on the card. Refer to design documentation for implementation guidelines. Note: href is deprecated. Set link.href for href functionality. If you are setting link object, href is a required property. link object supports all anchor element properties. Precedence: link.href > href. If link.href or href is set => anchor element, else button.
*/
actionIcons?: ActionIcon[];
/**
* Optional prop that allows you to pass any component.
*/
decorator?: ReactNode | boolean;
/**
* Determines if the action icons are on the top or bottom of the card
*/
actionsPlacement?: PlacementType;
/**
* Optional user provided class
*/
className?: string;
/**
* Designates which zones of the card are clickable. Refer to design documentation for implementation guidelines
*/
clickZone?: ClickZoneType;
/**
* Optional header description
*/
description?: string | object | ReactNode;
/**
* Optional label for the top of the card
*/
label?: string | object | ReactNode;
/**
* Provides the callback for a clickable card
*/
onClick?: (event: MouseEvent) => void;
/**
* Provides the callback for keydown events on the card
*/
onKeyDown?: (event: KeyboardEvent) => void;
/**
* Function that's called from the primary button or action icon
*/
onPrimaryButtonClick?: () => void;
/**
* Function that's called from the secondary button
*/
onSecondaryButtonClick?: () => void;
/**
* Use an overflow menu instead of action icons. Refer to design documentation for implementation guidelines
*/
overflowActions?: overflowAction[];
/**
* Sets the text for the OverflowMenu aria label and the OverflowMenu trigger button tooltip.
* Overrides `iconDescription` prop.
*/
overflowAriaLabel?: string;
/**
* Determines if the primary button is enabled or not
*/
primaryButtonDisabled?: boolean;
/**
* Optionally specify an href for your Button to become an element
*/
primaryButtonHref?: string;
/**
* Optional prop to allow overriding the icon rendering. Can be a React component class
*/
primaryButtonIcon?: CarbonIconType;
/**
* Determines if the primary button is on the top or bottom of the card
*/
primaryButtonPlacement?: PlacementType;
/**
* The text that's displayed in the primary button
*/
primaryButtonText?: string;
/**
* Optionally specify an href for your Button to become an element
*/
secondaryButtonHref?: string;
/**
* Optional prop to allow overriding the icon rendering. Can be a React component class
*/
secondaryButtonIcon?: CarbonIconType;
/**
* Determines if the secondary button is on the top or bottom of the card
*/
secondaryButtonPlacement?: PlacementType;
/**
* The text that's displayed in the secondary button
*/
secondaryButtonText?: string;
/**
* **Experimental:** For all cases a `Slug` component can be provided.
* Clickable tiles only accept a boolean value of true and display a hollow slug.
* @deprecated please use the `decorator` prop
*/
slug?: ReactNode | boolean;
/**
* Title that's displayed at the top of the card
*/
title?: string | object | ReactNode;
/**
* Determines title size
*/
titleSize?: 'default' | 'large';
/**
* Sets the text for the OverflowMenu trigger button tooltip and OverflowMenu aria label,
* gets overridden by the `overflowAriaLabel` prop.
*
* @deprecated Please use the `overflowAriaLabel` prop instead.
*/
iconDescription?: string;
}
export declare const ProductiveCard: React.ForwardRefExoticComponent>;
export {};
//# sourceMappingURL=ProductiveCard.d.ts.map