@devtron-labs/devtron-fe-common-lib 1.13.0-pre-1 → 1.13.0-pre-1-beta-1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ import { GenericInfoCardListingProps } from './types';
2
+ export declare const GenericInfoCardListing: ({ isLoading, error, list, searchKey, reloadList, borderVariant, handleClearFilters, emptyStateConfig, }: GenericInfoCardListingProps) => JSX.Element;
@@ -1,2 +1,3 @@
1
1
  export { default as GenericInfoCard } from './GenericInfoCard.component';
2
- export { GenericInfoCardBorderVariant, type GenericInfoCardProps } from './types';
2
+ export * from './GenericInfoCardListing';
3
+ export { GenericInfoCardBorderVariant, type GenericInfoCardListingProps, type GenericInfoCardProps } from './types';
@@ -1,5 +1,7 @@
1
1
  import { MouseEventHandler, ReactElement } from 'react';
2
2
  import { LinkProps } from 'react-router-dom';
3
+ import { GenericFilterEmptyStateProps } from '@Common/EmptyState/types';
4
+ import { GenericEmptyStateType } from '../../../Common/Types';
3
5
  type BaseGenericInfoCardProps = {
4
6
  title: string;
5
7
  description: string;
@@ -23,4 +25,12 @@ export type GenericInfoCardProps = {
23
25
  } & Partial<Record<keyof BaseGenericInfoCardProps, never>>) | ({
24
26
  isLoading?: boolean;
25
27
  } & BaseGenericInfoCardProps));
28
+ export interface GenericInfoCardListingProps extends Pick<GenericInfoCardProps, 'borderVariant'>, Pick<GenericFilterEmptyStateProps, 'handleClearFilters'> {
29
+ list: (Pick<GenericInfoCardProps, 'Icon' | 'author' | 'description' | 'linkProps' | 'onClick' | 'title'> & Record<'id', string>)[];
30
+ emptyStateConfig: Pick<GenericEmptyStateType, 'title' | 'subTitle' | 'image'>;
31
+ searchKey?: string;
32
+ reloadList?: () => void;
33
+ error?: Record<string, unknown>;
34
+ isLoading?: boolean;
35
+ }
26
36
  export {};