simple-table-core 1.2.6 → 1.2.8

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.
@@ -1,10 +1,11 @@
1
1
  import CellValue from "../../../types/CellValue";
2
2
  import EnumOption from "../../../types/EnumOption";
3
+ import { ColumnType } from "../../../types/HeaderObject";
3
4
  interface EditableCellProps {
4
5
  enumOptions?: EnumOption[];
5
6
  onChange: (newValue: CellValue) => void;
6
7
  setIsEditing: (isEditing: boolean) => void;
7
- type?: "string" | "number" | "boolean" | "date" | "enum";
8
+ type?: ColumnType;
8
9
  value: CellValue;
9
10
  }
10
11
  declare const EditableCell: ({ enumOptions, onChange, setIsEditing, type, value, }: EditableCellProps) => import("react/jsx-runtime").JSX.Element;
package/dist/index.d.ts CHANGED
@@ -1,23 +1,23 @@
1
1
  import SimpleTable from "./components/simple-table/SimpleTable";
2
- import type BoundingBox from "./types/BoundingBox";
3
- import type Cell from "./types/Cell";
4
- import type CellChangeProps from "./types/CellChangeProps";
5
- import type CellValue from "./types/CellValue";
6
- import type ColumnEditorPosition from "./types/ColumnEditorPosition";
7
- import type DragHandlerProps from "./types/DragHandlerProps";
2
+ import BoundingBox from "./types/BoundingBox";
3
+ import Cell from "./types/Cell";
4
+ import CellChangeProps from "./types/CellChangeProps";
5
+ import CellValue from "./types/CellValue";
6
+ import ColumnEditorPosition from "./types/ColumnEditorPosition";
7
+ import DragHandlerProps from "./types/DragHandlerProps";
8
8
  import EnumOption from "./types/EnumOption";
9
- import type HeaderObject from "./types/HeaderObject";
10
- import type { AggregationConfig, AggregationType } from "./types/AggregationTypes";
11
- import type OnSortProps from "./types/OnSortProps";
12
- import type Row from "./types/Row";
13
- import type SharedTableProps from "./types/SharedTableProps";
14
- import type SortColumn from "./types/SortColumn";
15
- import type TableCellProps from "./types/TableCellProps";
16
- import type TableHeaderProps from "./types/TableHeaderProps";
9
+ import HeaderObject, { Accessor, ColumnType } from "./types/HeaderObject";
10
+ import { AggregationConfig, AggregationType } from "./types/AggregationTypes";
11
+ import OnSortProps from "./types/OnSortProps";
12
+ import Row from "./types/Row";
13
+ import SharedTableProps from "./types/SharedTableProps";
14
+ import SortColumn from "./types/SortColumn";
15
+ import TableCellProps from "./types/TableCellProps";
16
+ import TableHeaderProps from "./types/TableHeaderProps";
17
17
  import TableRefType from "./types/TableRefType";
18
- import type TableRowProps from "./types/TableRowProps";
19
- import type Theme from "./types/Theme";
20
- import type UpdateDataProps from "./types/UpdateCellProps";
18
+ import TableRowProps from "./types/TableRowProps";
19
+ import Theme from "./types/Theme";
20
+ import UpdateDataProps from "./types/UpdateCellProps";
21
21
  import { FilterCondition, TableFilterState } from "./types/FilterTypes";
22
22
  export { SimpleTable };
23
- export type { AggregationConfig, AggregationType, BoundingBox, Cell, CellChangeProps, CellValue, ColumnEditorPosition, DragHandlerProps, EnumOption, FilterCondition, HeaderObject, OnSortProps, Row, SharedTableProps, SortColumn, TableCellProps, TableFilterState, TableHeaderProps, TableRefType, TableRowProps, Theme, UpdateDataProps, };
23
+ export type { Accessor, AggregationConfig, AggregationType, BoundingBox, Cell, CellChangeProps, CellValue, ColumnEditorPosition, ColumnType, DragHandlerProps, EnumOption, FilterCondition, HeaderObject, OnSortProps, Row, SharedTableProps, SortColumn, TableCellProps, TableFilterState, TableHeaderProps, TableRefType, TableRowProps, Theme, UpdateDataProps, };
@@ -5,6 +5,7 @@ import Theme from "./Theme";
5
5
  import EnumOption from "./EnumOption";
6
6
  import { AggregationConfig } from "./AggregationTypes";
7
7
  export type Accessor = keyof Row;
8
+ export type ColumnType = "string" | "number" | "boolean" | "date" | "enum" | "other";
8
9
  type HeaderObject = {
9
10
  accessor: Accessor;
10
11
  aggregation?: AggregationConfig;
@@ -31,7 +32,7 @@ type HeaderObject = {
31
32
  label: string;
32
33
  minWidth?: number | string;
33
34
  pinned?: Pinned;
34
- type?: "string" | "number" | "boolean" | "date" | "enum";
35
+ type?: ColumnType;
35
36
  width: number | string;
36
37
  };
37
38
  export default HeaderObject;
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.2.6",
2
+ "version": "1.2.8",
3
3
  "main": "dist/index.js",
4
4
  "module": "dist/index.es.js",
5
5
  "types": "dist/index.d.ts",