UNPKG

analytica-frontend-lib

Version:

Repositório público dos componentes utilizados nas plataformas da Analytica Ensino

63 lines 1.93 kB
import { type ReactNode } from 'react'; export interface EmptyStateProps { /** * Image source for the illustration (optional) */ image?: string; /** * Title text to display * @default "Nenhum dado disponível" */ title?: string; /** * Description text to display below the title * @default "Não há dados para exibir no momento." */ description?: string; /** * Button text (optional - if not provided, button won't be displayed) */ buttonText?: string; /** * Icon to display on the left side of the button */ buttonIcon?: ReactNode; /** * Callback function when button is clicked */ onButtonClick?: () => void; /** * Button variant * @default "solid" */ buttonVariant?: 'solid' | 'outline' | 'link'; /** * Button action color * @default "primary" */ buttonAction?: 'primary' | 'positive' | 'negative'; } /** * Component displayed when there is no data to show (empty state) * Shows an illustration with customizable title, description, and optional button in horizontal layout * * @example * ```tsx * import { EmptyState } from 'analytica-frontend-lib'; * import activityImage from './assets/activity.png'; * import { Plus } from 'phosphor-react'; * * <EmptyState * image={activityImage} * title="Incentive sua turma ao aprendizado" * description="Crie uma nova atividade e ajude seus alunos a colocarem o conteúdo em prática!" * buttonText="Criar atividade" * buttonIcon={<Plus size={18} />} * buttonVariant="outline" * onButtonClick={handleCreateActivity} * /> * ``` */ declare const EmptyState: ({ image, title, description, buttonText, buttonIcon, onButtonClick, buttonVariant, buttonAction, }: EmptyStateProps) => import("react/jsx-runtime").JSX.Element; export default EmptyState; //# sourceMappingURL=EmptyState.d.ts.map