@fattureincloud/fic-design-system 0.19.16 → 0.19.18

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import { DefaultDropdownProps } from '../types';
3
- declare const DefaultDropdown: ({ closeDropdown, componentId, content, fullWidth, maxWidth, rowHasFocus, setHighlightedItem, emptyState, }: DefaultDropdownProps) => JSX.Element;
3
+ declare const DefaultDropdown: ({ closeDropdown, componentId, content, emptyState, fullWidth, maxWidth, rowHasFocus, setHighlightedItem, }: DefaultDropdownProps) => JSX.Element;
4
4
  export default DefaultDropdown;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { buttonColors } from '../buttons/button/types';
2
+ import { buttonColors } from '../buttons';
3
3
  interface Props {
4
4
  actionText: string;
5
5
  cancelColor?: buttonColors;
@@ -15,6 +15,7 @@ interface Props {
15
15
  setIsOpen: (state: boolean) => void;
16
16
  title?: string;
17
17
  type: 'success' | 'error' | 'warning' | 'info';
18
+ isLoading?: boolean;
18
19
  }
19
20
  export declare const ConfirmationModal: (props: Props) => React.JSX.Element;
20
21
  export {};
@@ -1,11 +1,11 @@
1
1
  /// <reference types="react" />
2
2
  import { Row as RowType } from '@tanstack/react-table';
3
3
  import { TableProps } from '../../types';
4
- interface BodyProps<T> extends Pick<TableProps<T>, 'isLoading' | 'isRowDisabled' | 'isRowHighlighted' | 'onRowClick' | 'rowActions' | 'rowHighlightColor' | 'rowSelection' | 'rowTooltip' | 'renderEmptyState' | 'isRowActionDisabled'> {
4
+ interface BodyProps<T> extends Pick<TableProps<T>, 'isLoading' | 'isRowDisabled' | 'isRowHighlighted' | 'onRowClick' | 'rowActions' | 'rowHighlightColor' | 'rowSelection' | 'rowTooltip' | 'renderEmptyState' | 'isRowActionDisabled' | 'customAction'> {
5
5
  pageIndex: number;
6
6
  rows: RowType<T>[];
7
7
  columnsCount: number;
8
8
  isTableEmpty?: boolean;
9
9
  }
10
- declare const Body: <T>({ columnsCount, isLoading, isRowActionDisabled, isRowDisabled, isRowHighlighted, isTableEmpty, onRowClick, pageIndex, renderEmptyState, rowActions, rowHighlightColor, rowSelection, rowTooltip, rows, }: BodyProps<T>) => JSX.Element;
10
+ declare const Body: <T>({ columnsCount, customAction, isLoading, isRowActionDisabled, isRowDisabled, isRowHighlighted, isTableEmpty, onRowClick, pageIndex, renderEmptyState, rowActions, rowHighlightColor, rowSelection, rowTooltip, rows, }: BodyProps<T>) => JSX.Element;
11
11
  export default Body;
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import { Row } from '@tanstack/react-table';
3
3
  import { TableProps } from '../../../types';
4
- declare type Props<T> = {
4
+ declare type Props<T> = Pick<TableProps<T>, 'customAction'> & {
5
5
  disableRow: boolean;
6
6
  disableRowActions: boolean;
7
7
  mouseHover: boolean;
@@ -11,5 +11,5 @@ declare type Props<T> = {
11
11
  rowHighlightColor?: string;
12
12
  selected: boolean;
13
13
  };
14
- declare const ActionsCell: <T>({ disableRow, disableRowActions, isRowHighlighted, mouseHover, row, rowActions, rowHighlightColor, selected, }: Props<T>) => JSX.Element;
14
+ declare const ActionsCell: <T>({ customAction, disableRow, disableRowActions, isRowHighlighted, mouseHover, row, rowActions, rowHighlightColor, selected, }: Props<T>) => JSX.Element;
15
15
  export default ActionsCell;
@@ -1,8 +1,8 @@
1
1
  /// <reference types="react" />
2
2
  import { Row as RowType } from '@tanstack/react-table';
3
3
  import { TableProps } from '../../types';
4
- declare type TrProps<T> = Pick<TableProps<T>, 'isLoading' | 'isRowDisabled' | 'isRowActionDisabled' | 'isRowHighlighted' | 'onRowClick' | 'rowActions' | 'rowHighlightColor' | 'rowSelection' | 'rowTooltip'> & {
4
+ declare type TrProps<T> = Pick<TableProps<T>, 'isLoading' | 'isRowDisabled' | 'isRowActionDisabled' | 'isRowHighlighted' | 'onRowClick' | 'rowActions' | 'rowHighlightColor' | 'rowSelection' | 'rowTooltip' | 'customAction'> & {
5
5
  row: RowType<T>;
6
6
  };
7
- declare const Row: <T>({ isLoading, isRowActionDisabled, isRowDisabled, isRowHighlighted, onRowClick, row, rowActions, rowHighlightColor, rowSelection, rowTooltip, }: TrProps<T>) => JSX.Element;
7
+ declare const Row: <T>({ customAction, isLoading, isRowActionDisabled, isRowDisabled, isRowHighlighted, onRowClick, row, rowActions, rowHighlightColor, rowSelection, rowTooltip, }: TrProps<T>) => JSX.Element;
8
8
  export default Row;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
2
  import { TableContextProps, TableProviderProps } from './types';
3
3
  export declare const TableContext: React.Context<TableContextProps>;
4
- declare const TableProvider: <T>({ absoluteElementsPortal, actionColumnWidth, children, columns, columnsSettings: initialColumnsSettings, enableSettings, hideableColumns, isLoading, isSelectable, loadingStyle, onSettingsChange, rowActions, rowSize: initialRowSize, settingsLabels, settingsTooltip, sortableColumns, }: TableProviderProps<T>) => JSX.Element;
4
+ declare const TableProvider: <T>({ absoluteElementsPortal, actionColumnWidth, children, columns, columnsSettings: initialColumnsSettings, customAction, enableSettings, hideableColumns, isLoading, isSelectable, loadingStyle, onSettingsChange, rowActions, rowSize: initialRowSize, settingsLabels, settingsTooltip, sortableColumns, }: TableProviderProps<T>) => JSX.Element;
5
5
  export default TableProvider;
@@ -24,6 +24,7 @@ export declare type TableProps<T> = SelectableTable<T> & PaginatedTable & Sortab
24
24
  rowTooltip?: (row: Row<T>) => string;
25
25
  showFooter?: boolean;
26
26
  uniqueId: keyof T;
27
+ customAction?: (row: Row<T>) => JSX.Element | null;
27
28
  };
28
29
  export declare type LoadingStyle = {
29
30
  backgroundColor?: string;