stratosphere-ui 0.1.15 → 0.1.17

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.
@@ -3,5 +3,8 @@ export declare const CheckIcon: (props: SVGProps<SVGSVGElement>) => JSX.Element;
3
3
  export declare const CloseIcon: (props: SVGProps<SVGSVGElement>) => JSX.Element;
4
4
  export declare const ErrorIcon: (props: SVGProps<SVGSVGElement>) => JSX.Element;
5
5
  export declare const InfoIcon: (props: SVGProps<SVGSVGElement>) => JSX.Element;
6
+ export declare const SortAscendingIcon: () => JSX.Element;
7
+ export declare const SortDescendingIcon: () => JSX.Element;
8
+ export declare const SortIcon: () => JSX.Element;
6
9
  export declare const SuccessIcon: (props: SVGProps<SVGSVGElement>) => JSX.Element;
7
10
  export declare const WarningIcon: (props: SVGProps<SVGSVGElement>) => JSX.Element;
@@ -0,0 +1,9 @@
1
+ /// <reference types="react" />
2
+ import { ButtonProps, PaginationProps as DaisyUIPaginationProps } from 'react-daisyui';
3
+ import { PaginationMetadata } from './types';
4
+ export interface PaginationProps extends Omit<DaisyUIPaginationProps, 'children'> {
5
+ metadata?: PaginationMetadata;
6
+ onPaginationChange: (page: number) => void;
7
+ size?: ButtonProps['size'];
8
+ }
9
+ export declare const Pagination: ({ className, metadata, onPaginationChange, size, ...props }: PaginationProps) => JSX.Element | null;
@@ -0,0 +1,2 @@
1
+ export * from './Pagination';
2
+ export * from './types';
@@ -0,0 +1,11 @@
1
+ export interface PaginationMetadata {
2
+ page: number;
3
+ pageCount: number;
4
+ limit: number;
5
+ itemCount: number;
6
+ pages: Array<number | null>;
7
+ }
8
+ export interface PaginatedResults<Data> {
9
+ metadata: PaginationMetadata;
10
+ results: Data[];
11
+ }
@@ -0,0 +1,8 @@
1
+ /// <reference types="react" />
2
+ import { Column } from '@tanstack/react-table';
3
+ import { GenericDataType } from '../../common';
4
+ export interface HeaderSortIconProps<DataType extends GenericDataType> {
5
+ column: Column<DataType, unknown>;
6
+ }
7
+ export declare const HeaderSortIcon: <DataType extends GenericDataType>({ column, }: HeaderSortIconProps<DataType>) => JSX.Element | null;
8
+ export default HeaderSortIcon;
@@ -0,0 +1,15 @@
1
+ /// <reference types="react" />
2
+ import { TableOptions } from '@tanstack/react-table';
3
+ import { PaginationMetadata } from '../Pagination/types';
4
+ import { GenericDataType } from '../../common';
5
+ export interface TableProps<DataType extends GenericDataType> extends TableOptions<DataType> {
6
+ cellClassNames?: Record<string, string>;
7
+ className?: string;
8
+ compact?: boolean;
9
+ enableFixedWidth?: boolean;
10
+ enableRowHover?: boolean;
11
+ enableZebra?: boolean;
12
+ isLoading?: boolean;
13
+ metadata?: PaginationMetadata;
14
+ }
15
+ export declare const Table: <DataType extends GenericDataType>({ cellClassNames, className, compact, enableFixedWidth, enableGlobalFilter, enableRowHover, enableZebra, initialState, isLoading, metadata, ...props }: TableProps<DataType>) => JSX.Element;
@@ -0,0 +1 @@
1
+ export * from './Table';
@@ -6,4 +6,6 @@ export * from './FullScreenLoader';
6
6
  export * from './Icons';
7
7
  export * from './LoadingCard';
8
8
  export * from './Modal';
9
+ export * from './Pagination';
10
+ export * from './Table';
9
11
  export * from './TypeaheadSelect';