@indico-data/design-system 2.3.2 → 2.4.0

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.
package/lib/index.d.ts CHANGED
@@ -6,7 +6,7 @@ import { AriaButtonProps } from '@react-types/button';
6
6
  import { AriaRadioProps, RadioGroupProps as RadioGroupProps$1, AriaRadioGroupProps } from '@react-types/radio';
7
7
  import { DateRange } from 'react-day-picker';
8
8
  import { ContainerProps, RowProps, ColProps } from 'react-grid-system';
9
- import { TableColumn } from 'react-data-table-component';
9
+ import { TableProps as TableProps$1, Direction as Direction$1, Alignment as Alignment$1 } from 'react-data-table-component';
10
10
 
11
11
  declare const GlobalStyles: () => react_jsx_runtime.JSX.Element;
12
12
 
@@ -912,80 +912,14 @@ type IconProps = PermafrostComponent & {
912
912
 
913
913
  declare const Icon: ({ name, size, className, ariaLabel, ...props }: IconProps) => react_jsx_runtime.JSX.Element | null;
914
914
 
915
- type LocalDirection = 'auto' | 'ltr' | 'rtl';
916
- type LocalAlignment = 'left' | 'right' | 'center';
917
- interface TableProps {
918
- columns: TableColumn<any>[];
919
- data: Record<string, any>[];
920
- responsive?: boolean;
921
- direction?: LocalDirection;
922
- subHeaderAlign?: LocalAlignment;
923
- subHeaderWrap?: boolean;
924
- pagination?: boolean;
925
- selectableRows?: boolean;
926
- keyField?: string;
927
- title?: string | React$1.ReactNode;
928
- striped?: boolean;
929
- highlightOnHover?: boolean;
930
- pointerOnHover?: boolean;
931
- dense?: boolean;
932
- persistTableHead?: boolean;
933
- noDataComponent?: string | React$1.ReactNode;
915
+ type Direction = `${Direction$1}`;
916
+ type Alignment = `${Alignment$1}`;
917
+ type TableProps<T> = Omit<TableProps$1<T>, 'disabled' | 'progressPending' | 'direction' | 'subHeaderAlign'> & {
934
918
  isDisabled?: boolean;
935
- onRowClicked?: (row: Record<string, any>, event: React$1.MouseEvent) => void;
936
- onRowDoubleClicked?: (row: Record<string, any>, event: React$1.MouseEvent) => void;
937
- onRowMouseEnter?: (row: Record<string, any>, event: React$1.MouseEvent) => void;
938
- onRowMouseLeave?: (row: Record<string, any>, event: React$1.MouseEvent) => void;
939
- defaultSortFieldId?: string | number;
940
- defaultSortAsc?: boolean;
941
- sortIcon?: React$1.ReactNode;
942
- sortServer?: boolean;
943
- sortFunction?: any;
944
- onSort?: any;
945
- selectableRowsVisibleOnly?: boolean;
946
- selectableRowsHighlight?: boolean;
947
- selectableRowsSingle?: boolean;
948
- selectableRowsNoSelectAll?: boolean;
949
- selectableRowsComponent?: any;
950
- selectableRowsComponentProps?: Record<string, any>;
951
- clearSelectedRows?: boolean;
952
- selectableRowSelected?: (row: Record<string, any>) => boolean;
953
- selectableRowDisabled?: (row: Record<string, any>) => boolean;
954
- onSelectedRowsChange?: any;
955
- expandableRows?: boolean;
956
- expandableIcon?: any;
957
- expandableRowsComponent?: any;
958
- expandableRowDisabled?: any;
959
- expandableRowExpanded?: any;
960
- expandableRowsComponentProps?: Record<string, any>;
961
- expandOnRowClicked?: boolean;
962
- expandOnRowDoubleClicked?: boolean;
963
- expandableRowsHideExpander?: boolean;
964
- expandableInheritConditionalStyles?: boolean;
965
- onRowExpandToggled?: any;
966
- paginationServer?: boolean;
967
- paginationServerOptions?: Record<string, any>;
968
- paginationDefaultPage?: number;
969
- paginationResetDefaultPage?: boolean;
970
- paginationTotalRows?: number;
971
- paginationPerPage?: number;
972
- paginationRowsPerPageOptions?: number[];
973
- paginationComponent?: any;
974
- paginationComponentOptions?: Record<string, any>;
975
- paginationIconFirstPage?: any;
976
- paginationIconLastPage?: any;
977
- paginationIconNext?: any;
978
- paginationIconPrevious?: any;
979
- onChangePage?: any;
980
- onChangeRowsPerPage?: any;
981
- actions?: any;
982
- noHeader?: boolean;
983
- fixedHeader?: boolean;
984
- fixedHeaderScrollHeight?: string;
985
- subHeader?: boolean;
986
- subHeaderComponent?: any;
987
919
  isLoading?: boolean;
988
- }
989
- declare const Table: (props: TableProps) => react_jsx_runtime.JSX.Element;
920
+ direction: Direction;
921
+ subHeaderAlign: Alignment;
922
+ };
923
+ declare const Table: <T>(props: TableProps<T>) => react_jsx_runtime.JSX.Element;
990
924
 
991
925
  export { animation as ANIMATION, Radio as AbstractRadio, RadioGroup as AbstractRadioGroup, Accordion, breakpoints as BREAKPOINT, BarSpinner, BorderSelect, Button, allColors as COLORS, CirclePulse, CircleSpinner, Col, ConfirmModal, Container, DatePicker, EditableInput, GlobalStyles, Icon, IconButton, Button$1 as LegacyButton, ListTable, LoadingAwareContainer, LoadingList, margin as MARGINS, MATH, mediaQueries as MEDIA_QUERIES, ModalBase, MultiCombobox, NoInputDatePicker, NumberInput, padding as PADDINGS, Pagination, PercentageRing, Radio$1 as Radio, RadioGroup$1 as RadioGroup, RandomLoadingMessage, Row, spacings as SPACING, SearchInput, Section, SectionBlock, SectionBody, SectionHeader, SectionTable, Select, Shrug, SingleCombobox, typography as TYPOGRAPHY, Table, TextInput, TextTruncate, Toggle, Tooltip, color as colorUtils, number as numberUtils, string as stringUtils };