@foris/avocado-suite 0.11.9 → 0.11.11

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,6 +1,7 @@
1
1
  declare const DataTable: {
2
2
  Action: import("react").FC<import("./components/DataTableAction/DataTableAction").IDataTableAction>;
3
- ActionsGroup: import("react").FC<import("./components/DataTableAction/DataTableActionsGroup").IDataTableActionsGroup>;
3
+ SubActions: import("react").FC<import("./components/DataTableAction/DataTableSubActions").DataTableSubActionsProps>;
4
+ ActionsGroup: import("react").FC<import("./components/DataTableAction/DataTableActionsGroup").DataTableActionsGroupProps>;
4
5
  Content: import("react").FC<import("./components/DataTableContent/DataTableContent").IDataTableContent>;
5
6
  Header: import("react").FC<import("./components/DataTableHeader/DataTableHeader").IDataTableHeader>;
6
7
  Row: import("react").FC<import("./components/DataTableRow/DataTableRow").IDataTableRow>;
@@ -13,6 +13,8 @@ export interface IDataTableAction {
13
13
  };
14
14
  /** disabled state */
15
15
  disabled?: boolean;
16
+ /** hide and set just the action dimensions */
17
+ hide?: boolean;
16
18
  /** icon value */
17
19
  icon?: IconTypes;
18
20
  /** icon size */
@@ -1,10 +1,9 @@
1
- import * as React from 'react';
2
- import DataTableAction from './DataTableAction';
3
- export interface IDataTableActionsGroup {
1
+ import React from 'react';
2
+ export interface DataTableActionsGroupProps {
4
3
  /** actions */
5
- children: React.ReactElement<typeof DataTableAction> | React.ReactElement<typeof DataTableAction>[];
4
+ children: React.ReactNode;
6
5
  /** overwrite className */
7
6
  className?: string;
8
7
  }
9
- declare const DataTableActionsGroup: React.FC<IDataTableActionsGroup>;
8
+ declare const DataTableActionsGroup: React.FC<DataTableActionsGroupProps>;
10
9
  export default DataTableActionsGroup;
@@ -0,0 +1,6 @@
1
+ import { FC, ReactNode } from 'react';
2
+ export interface DataTableSubActionsProps {
3
+ children: ReactNode;
4
+ }
5
+ declare const DataTableSubActions: FC<DataTableSubActionsProps>;
6
+ export default DataTableSubActions;
@@ -42,6 +42,8 @@ export interface IDataTableContentColumn {
42
42
  export interface IDataTableContentActions {
43
43
  /** Column's name */
44
44
  header?: React.ReactNode | string;
45
+ /** Show menu button to group all actions on mobile version */
46
+ groupedOnMobile?: boolean;
45
47
  /** Column's visibility */
46
48
  visibility: boolean;
47
49
  /** This function (or component) is primarily used for formatting the column value */
@@ -50,6 +52,8 @@ export interface IDataTableContentActions {
50
52
  export interface IDataTableContent {
51
53
  /** overwrite className */
52
54
  className?: string;
55
+ /** overwrite classNameHeader */
56
+ classNameHeader?: string;
53
57
  /** The columns configuration for the table. */
54
58
  columns: IDataTableContentColumn[];
55
59
  /** The data that you want to display on the table. */
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { DataTableSubContentStyle } from '../DataTableContent/DataTableContent';
2
+ import { DataTableSubContentStyle, IDataTableContentActions } from '../DataTableContent/DataTableContent';
3
3
  export interface IDataTableRowAccordion {
4
4
  /** The columns parsed for the table. */
5
5
  columns: any[];
@@ -11,6 +11,8 @@ export interface IDataTableRowAccordion {
11
11
  keyBody?: string;
12
12
  /** style of sub content: inheritance | custom */
13
13
  styleBody?: DataTableSubContentStyle;
14
+ /** Right action or actions on the table */
15
+ rightActions?: IDataTableContentActions;
14
16
  /** event to render each sub row */
15
17
  renderBody?: (body: any) => any;
16
18
  }