es-grid-template 1.8.66 → 1.8.68
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/es/grid-component/hooks/constant.d.ts +1 -0
- package/es/grid-component/hooks/constant.js +2 -1
- package/es/grid-component/hooks/useLazyKVMap.d.ts +1 -1
- package/es/grid-component/hooks/utils.d.ts +1 -1
- package/es/grid-component/index.d.ts +1 -1
- package/es/grid-component/type.d.ts +567 -0
- package/es/grid-component/type.js +1 -490
- package/es/table-component/ColumnsChoose.d.ts +1 -1
- package/es/table-component/ColumnsChoose.js +0 -2
- package/es/table-component/ContextMenu.d.ts +1 -2
- package/es/table-component/ContextMenu.js +0 -1
- package/es/table-component/InternalTable.d.ts +1 -2
- package/es/table-component/InternalTable.js +1 -32
- package/es/table-component/TableContainer.d.ts +1 -1
- package/es/table-component/TableContainer.js +4 -2
- package/es/table-component/TableContainerEdit.d.ts +1 -1
- package/es/table-component/TableContainerEdit.js +6 -129
- package/es/table-component/body/EditableCell.d.ts +1 -1
- package/es/table-component/body/EditableCell.js +1 -18
- package/es/table-component/body/TableBody.d.ts +1 -1
- package/es/table-component/body/TableBodyCell.d.ts +1 -1
- package/es/table-component/body/TableBodyCellEdit.d.ts +1 -1
- package/es/table-component/body/TableBodyCellEdit.js +2 -9
- package/es/table-component/body/TableBodyRow.d.ts +1 -1
- package/es/table-component/components/ControlCheckbox.d.ts +1 -1
- package/es/table-component/components/EditForm/EditForm.js +0 -1
- package/es/table-component/components/InputControl/InputControl.js +0 -3
- package/es/table-component/components/async-select/index.d.ts +1 -1
- package/es/table-component/components/async-select/index.js +0 -3
- package/es/table-component/components/async-table-select/index.d.ts +1 -1
- package/es/table-component/components/async-table-select/index.js +0 -4
- package/es/table-component/components/checkbox-filter/CheckboxFilter.js +6 -2
- package/es/table-component/components/checkbox-filter/FilterSearch.d.ts +1 -1
- package/es/table-component/components/checkbox-filter/FilterSearch.js +1 -1
- package/es/table-component/components/command/Command.d.ts +1 -1
- package/es/table-component/components/number/index.d.ts +3 -2
- package/es/table-component/components/number/index.js +0 -8
- package/es/table-component/components/number-range/index.d.ts +3 -2
- package/es/table-component/components/number-range/index.js +0 -3
- package/es/table-component/footer/TableFooterRow.js +1 -22
- package/es/table-component/header/TableHead.js +0 -20
- package/es/table-component/header/TableHeadCell.js +1 -15
- package/es/table-component/header/TableHeadCell2.js +5 -3
- package/es/table-component/header/TableHeadGroupCell.js +0 -23
- package/es/table-component/header/renderFilter.d.ts +1 -1
- package/es/table-component/hook/useColumns.d.ts +1 -1
- package/es/table-component/hook/useFilterOperator.d.ts +2 -2
- package/es/table-component/hook/utils.d.ts +1 -1
- package/es/table-component/hook/utils.js +0 -3
- package/es/table-component/index.d.ts +1 -1
- package/es/table-component/index.js +0 -3
- package/es/table-component/table/Grid.d.ts +1 -1
- package/es/table-component/table/Grid.js +0 -5
- package/es/table-component/table/TableWrapper.d.ts +1 -1
- package/es/table-component/useContext.d.ts +2 -1
- package/es/table-virtuoso/InternalTable.d.ts +1 -1
- package/es/table-virtuoso/InternalTable.js +2 -1
- package/es/table-virtuoso/body/TableBodyCell.d.ts +1 -1
- package/es/table-virtuoso/body/TableBodyCell.js +1 -1
- package/es/table-virtuoso/body/TableBodyRow.d.ts +2 -2
- package/es/table-virtuoso/body/TableBodyRow.js +3 -1
- package/es/table-virtuoso/header/TableHeadCell.js +1 -3
- package/es/table-virtuoso/header/renderFilter.d.ts +1 -1
- package/es/table-virtuoso/header/renderFilter.js +0 -4
- package/es/table-virtuoso/hook/utils.d.ts +1 -1
- package/es/table-virtuoso/style.js +1 -1
- package/es/table-virtuoso/table/Grid.d.ts +1 -1
- package/es/table-virtuoso/table/Grid.js +0 -24
- package/es/table-virtuoso/table/TableContainer.d.ts +1 -1
- package/es/table-virtuoso/table/TableContainer.js +0 -2
- package/es/table-virtuoso/table/TableWrapper.d.ts +1 -1
- package/es/table-virtuoso/table/TableWrapper.js +3 -19
- package/es/table-virtuoso/useContext.d.ts +1 -1
- package/lib/grid-component/hooks/constant.d.ts +1 -0
- package/lib/grid-component/hooks/constant.js +3 -2
- package/lib/grid-component/hooks/useLazyKVMap.d.ts +1 -1
- package/lib/grid-component/hooks/utils.d.ts +1 -1
- package/lib/grid-component/index.d.ts +1 -1
- package/lib/grid-component/type.d.ts +567 -0
- package/lib/grid-component/type.js +4 -490
- package/lib/table-component/ColumnsChoose.d.ts +1 -1
- package/lib/table-component/ColumnsChoose.js +0 -2
- package/lib/table-component/ContextMenu.d.ts +1 -2
- package/lib/table-component/ContextMenu.js +0 -2
- package/lib/table-component/InternalTable.d.ts +1 -2
- package/lib/table-component/InternalTable.js +1 -28
- package/lib/table-component/TableContainer.d.ts +1 -1
- package/lib/table-component/TableContainer.js +4 -2
- package/lib/table-component/TableContainerEdit.d.ts +1 -1
- package/lib/table-component/TableContainerEdit.js +5 -128
- package/lib/table-component/body/EditableCell.d.ts +1 -1
- package/lib/table-component/body/EditableCell.js +0 -10
- package/lib/table-component/body/TableBody.d.ts +1 -1
- package/lib/table-component/body/TableBodyCell.d.ts +1 -1
- package/lib/table-component/body/TableBodyCellEdit.d.ts +1 -1
- package/lib/table-component/body/TableBodyCellEdit.js +5 -11
- package/lib/table-component/body/TableBodyRow.d.ts +1 -1
- package/lib/table-component/components/ControlCheckbox.d.ts +1 -1
- package/lib/table-component/components/EditForm/EditForm.js +0 -2
- package/lib/table-component/components/InputControl/InputControl.js +0 -4
- package/lib/table-component/components/async-select/index.d.ts +1 -1
- package/lib/table-component/components/async-select/index.js +0 -2
- package/lib/table-component/components/async-table-select/index.d.ts +1 -1
- package/lib/table-component/components/async-table-select/index.js +0 -4
- package/lib/table-component/components/checkbox-filter/CheckboxFilter.js +6 -2
- package/lib/table-component/components/checkbox-filter/FilterSearch.d.ts +1 -1
- package/lib/table-component/components/checkbox-filter/FilterSearch.js +1 -1
- package/lib/table-component/components/command/Command.d.ts +1 -1
- package/lib/table-component/components/number/index.d.ts +3 -2
- package/lib/table-component/components/number/index.js +0 -8
- package/lib/table-component/components/number-range/index.d.ts +3 -2
- package/lib/table-component/components/number-range/index.js +0 -3
- package/lib/table-component/footer/TableFooterRow.js +1 -23
- package/lib/table-component/header/TableHead.js +0 -21
- package/lib/table-component/header/TableHeadCell.js +4 -18
- package/lib/table-component/header/TableHeadCell2.js +8 -6
- package/lib/table-component/header/TableHeadGroupCell.js +0 -23
- package/lib/table-component/header/renderFilter.d.ts +1 -1
- package/lib/table-component/hook/useColumns.d.ts +1 -1
- package/lib/table-component/hook/useFilterOperator.d.ts +2 -2
- package/lib/table-component/hook/utils.d.ts +1 -1
- package/lib/table-component/hook/utils.js +0 -4
- package/lib/table-component/index.d.ts +1 -1
- package/lib/table-component/index.js +0 -1
- package/lib/table-component/table/Grid.d.ts +1 -1
- package/lib/table-component/table/Grid.js +0 -4
- package/lib/table-component/table/TableWrapper.d.ts +1 -1
- package/lib/table-component/useContext.d.ts +2 -1
- package/lib/table-virtuoso/InternalTable.d.ts +1 -1
- package/lib/table-virtuoso/InternalTable.js +3 -1
- package/lib/table-virtuoso/body/TableBodyCell.d.ts +1 -1
- package/lib/table-virtuoso/body/TableBodyCell.js +1 -1
- package/lib/table-virtuoso/body/TableBodyRow.d.ts +2 -2
- package/lib/table-virtuoso/body/TableBodyRow.js +3 -1
- package/lib/table-virtuoso/header/TableHeadCell.js +4 -6
- package/lib/table-virtuoso/header/renderFilter.d.ts +1 -1
- package/lib/table-virtuoso/header/renderFilter.js +0 -4
- package/lib/table-virtuoso/hook/utils.d.ts +1 -1
- package/lib/table-virtuoso/style.js +1 -1
- package/lib/table-virtuoso/table/Grid.d.ts +1 -1
- package/lib/table-virtuoso/table/Grid.js +0 -24
- package/lib/table-virtuoso/table/TableContainer.d.ts +1 -1
- package/lib/table-virtuoso/table/TableContainer.js +0 -2
- package/lib/table-virtuoso/table/TableWrapper.d.ts +1 -1
- package/lib/table-virtuoso/table/TableWrapper.js +3 -19
- package/lib/table-virtuoso/useContext.d.ts +1 -1
- package/package.json +1 -1
- package/es/table-component/hook/constant.d.ts +0 -73
- package/es/table-component/hook/constant.js +0 -240
- package/es/table-component/type.d.ts +0 -567
- package/es/table-component/type.js +0 -1
- package/es/table-virtuoso/hook/constant.d.ts +0 -73
- package/es/table-virtuoso/hook/constant.js +0 -240
- package/es/table-virtuoso/hook/convert.d.ts +0 -1
- package/es/table-virtuoso/hook/convert.js +0 -28
- package/es/table-virtuoso/hook/useColumns.d.ts +0 -28
- package/es/table-virtuoso/hook/useColumns.js +0 -302
- package/es/table-virtuoso/hook/useFilterOperator.d.ts +0 -7
- package/es/table-virtuoso/hook/useFilterOperator.js +0 -33
- package/es/table-virtuoso/style.scss +0 -1441
- package/es/table-virtuoso/type.d.ts +0 -0
- package/es/table-virtuoso/type.js +0 -785
- package/lib/table-component/hook/constant.d.ts +0 -73
- package/lib/table-component/hook/constant.js +0 -247
- package/lib/table-component/type.d.ts +0 -567
- package/lib/table-component/type.js +0 -5
- package/lib/table-virtuoso/hook/constant.d.ts +0 -73
- package/lib/table-virtuoso/hook/constant.js +0 -247
- package/lib/table-virtuoso/hook/convert.d.ts +0 -1
- package/lib/table-virtuoso/hook/convert.js +0 -34
- package/lib/table-virtuoso/hook/useColumns.d.ts +0 -28
- package/lib/table-virtuoso/hook/useColumns.js +0 -315
- package/lib/table-virtuoso/hook/useFilterOperator.d.ts +0 -7
- package/lib/table-virtuoso/hook/useFilterOperator.js +0 -40
- package/lib/table-virtuoso/style.scss +0 -1441
- package/lib/table-virtuoso/type.d.ts +0 -0
- package/lib/table-virtuoso/type.js +0 -786
|
@@ -1,491 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
// import type React from "react"
|
|
3
|
-
// import type { IOperator } from "./hooks"
|
|
4
|
-
// import type {
|
|
5
|
-
// TypeFilter,
|
|
6
|
-
// TableProps as RcTableProps,
|
|
7
|
-
// TableColumnType as RcColumnType,
|
|
8
|
-
// EditType,
|
|
9
|
-
// TablePaginationConfig
|
|
10
|
-
// } from "rc-master-ui"
|
|
11
|
-
// import type { FilterOperator, TableRowSelection } from "rc-master-ui/es/table/interface"
|
|
12
|
-
// import type { ToolbarItem as RcToolbarItem } from "rc-master-ui/es/toolbar"
|
|
13
|
-
// import type { ItemType } from "rc-master-ui/es/menu/interface"
|
|
14
|
-
// import type { FieldNames, FilterFunc } from "rc-select/es/Select"
|
|
15
|
-
// import type { ColorPickerProps } from "antd"
|
|
16
|
-
// import type { FixedType } from "rc-base-table/lib/interface"
|
|
17
|
-
// import type { TableLocale } from "rc-master-ui/lib/table/interface"
|
|
18
|
-
// import type { Cell, Header, Row } from '@tanstack/react-table'
|
|
1
|
+
"use strict";
|
|
19
2
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
// export type SelectMode = 'checkbox' | 'radio' | undefined
|
|
25
|
-
// export type ITextAlign = 'center' | 'left' | 'right'
|
|
26
|
-
// export type Frozen = 'left' | 'right' | 'Left' | 'Right'
|
|
27
|
-
|
|
28
|
-
// export type ToolbarItem = Omit<RcToolbarItem, 'position' | 'align'> & {
|
|
29
|
-
// position?: 'Top' | 'Bottom',
|
|
30
|
-
// align?: ITextAlign
|
|
31
|
-
// onClick?: (args: any) => void
|
|
32
|
-
// };
|
|
33
|
-
|
|
34
|
-
// // export type ContextMenuItem = MenuProps['items'] & {}
|
|
35
|
-
// export type ContextMenuItem = ItemType
|
|
36
|
-
|
|
37
|
-
// export type ITemplateColumn = {
|
|
38
|
-
// value: any
|
|
39
|
-
// column: any
|
|
40
|
-
// rowData: any
|
|
41
|
-
// field: number | string
|
|
42
|
-
// index: number
|
|
43
|
-
// // [key: string]: any
|
|
44
|
-
// }
|
|
45
|
-
|
|
46
|
-
// export type ColumnSelectTable = {
|
|
47
|
-
// field: string,
|
|
48
|
-
// dataIndex?: string,
|
|
49
|
-
// type?: IColumnType
|
|
50
|
-
// headerText?: string,
|
|
51
|
-
// fixedType?: 'left' | 'right' | undefined,
|
|
52
|
-
// width?: number | undefined,
|
|
53
|
-
// minWidth?: number,
|
|
54
|
-
// maxWidth?: number,
|
|
55
|
-
// visible?: boolean
|
|
56
|
-
// textAlign?: ITextAlign
|
|
57
|
-
// headerTextAlign?: ITextAlign
|
|
58
|
-
// // eslint-disable-next-line no-unused-vars
|
|
59
|
-
// template?: (props: ITemplateColumn) => ReactNode | ReactElement
|
|
60
|
-
// headerTemplate?: any
|
|
61
|
-
// ellipsis?: boolean | undefined
|
|
62
|
-
// format?: IFormat
|
|
63
|
-
// // eslint-disable-next-line no-unused-vars
|
|
64
|
-
// tooltipDescription?: string | ((rowData: any) => string | ReactNode)
|
|
65
|
-
// // tooltipDescription?: string | ((rowData: any) => string | React.FC<any> | ReactNode)
|
|
66
|
-
// showTooltip?: boolean
|
|
67
|
-
// showTooltipHeader?: boolean
|
|
68
|
-
// }
|
|
69
|
-
|
|
70
|
-
// export type IEditSelectSettings = {
|
|
71
|
-
// fieldKey?: string
|
|
72
|
-
// options: any[] | ((rowData: any, field: string) => any[])
|
|
73
|
-
// /** get value form other field **/
|
|
74
|
-
// fieldValue?: string
|
|
75
|
-
// /** get label form other field **/
|
|
76
|
-
// fieldLabel?: string
|
|
77
|
-
// /** cho phép nhập giá trị - onBlur: giá trị search được set thành value **/
|
|
78
|
-
// searchTextAsValue?: boolean
|
|
79
|
-
|
|
80
|
-
// inputKey?: string
|
|
81
|
-
|
|
82
|
-
// filterKey?: string[]
|
|
83
|
-
// selectMode?: SelectMode
|
|
84
|
-
|
|
85
|
-
// // eslint-disable-next-line no-unused-vars
|
|
86
|
-
// getPasteValue?: (value: any) => Record<string, any> | null
|
|
87
|
-
// // eslint-disable-next-line no-unused-vars
|
|
88
|
-
// validateOption?: (rowData: any, field: string) => any[]
|
|
89
|
-
|
|
90
|
-
// defaultOptions?: any[]
|
|
91
|
-
// // eslint-disable-next-line no-unused-vars
|
|
92
|
-
// defaultValue?: (value: any, rowData: any) => {
|
|
93
|
-
// value: any
|
|
94
|
-
// label: string
|
|
95
|
-
// [key: string]: string
|
|
96
|
-
|
|
97
|
-
// } | null
|
|
98
|
-
|
|
99
|
-
// formatOptionLabel?: (option: any) => ReactNode | ReactElement
|
|
100
|
-
// // loadOptions?: (search: string, callback: (newOptions: any[]) => void) => void
|
|
101
|
-
// loadOptions?: (search: string, callback: (newOptions: any[]) => void, args?: LoadOptionsArgs) => void;
|
|
102
|
-
// isMulti?: boolean
|
|
103
|
-
// closeMenuOnSelect?: boolean
|
|
104
|
-
// menuWidth?: number
|
|
105
|
-
// menuHeight?: number
|
|
106
|
-
|
|
107
|
-
// columns?: ColumnSelectTable[]
|
|
108
|
-
// toolbarItems?: ToolbarItem[]
|
|
109
|
-
// // eslint-disable-next-line no-unused-vars
|
|
110
|
-
// toolbarClick?: (props: ToolbarClick) => void
|
|
111
|
-
// toolbarHeight?: number
|
|
112
|
-
// hideSelectedOptions?: boolean
|
|
113
|
-
// showItems?: number
|
|
114
|
-
// isLengthSelected?: boolean
|
|
115
|
-
// fieldNames?: FieldNames
|
|
116
|
-
// filterOption?: boolean | FilterFunc<any>;
|
|
117
|
-
// }
|
|
118
|
-
// export type ToolbarClick = {
|
|
119
|
-
// item: any
|
|
120
|
-
// column: any
|
|
121
|
-
// }
|
|
122
|
-
// export type LoadOptionsArgs = {
|
|
123
|
-
// rowData?: any
|
|
124
|
-
|
|
125
|
-
// }
|
|
126
|
-
|
|
127
|
-
// export type ColumnTable<RecordType = AnyObject> = Omit<RcColumnType<RecordType>, 'headerTemplate' | 'title' | 'format' | 'commandItems'> & {
|
|
128
|
-
// field?: string,
|
|
129
|
-
// key?: any,
|
|
130
|
-
// type?: IColumnType,
|
|
131
|
-
// /** @deprecated This function is deprecated and should use `onChange` instead */
|
|
132
|
-
// haveSum?: boolean
|
|
133
|
-
// isSummary?: boolean
|
|
134
|
-
// summaryTemplate?: (data: number, key: string) => ReactElement | ReactNode
|
|
135
|
-
// maxWidth?: string | number
|
|
136
|
-
// format?: IFormat | ((rowData: any) => IFormat)
|
|
137
|
-
// allowFiltering?: boolean
|
|
138
|
-
// allowSortering?: boolean
|
|
139
|
-
// operator?: FilterOperator
|
|
140
|
-
// hideOperator?: boolean
|
|
141
|
-
// placeholder?: string
|
|
142
|
-
// showInColumnChoose?: boolean
|
|
143
|
-
// typeFilter?: TypeFilter
|
|
144
|
-
// source?: any[]
|
|
145
|
-
// showFilterSearch?: boolean
|
|
146
|
-
// headerText?: string
|
|
147
|
-
// visible?: boolean
|
|
148
|
-
// headerTooltip?: boolean | string | (() => ReactNode | ReactElement)
|
|
149
|
-
// columnGroupText?: string
|
|
150
|
-
// textAlign?: ITextAlign
|
|
151
|
-
// headerTextAlign?: ITextAlign
|
|
152
|
-
// // template?: ReactNode | ReactElement | ((value: any, record: RecordType, index: number) => ReactNode | ReactElement)
|
|
153
|
-
// template?: ReactNode | ReactElement | ((args: ColumnTemplate<RecordType>) => ReactNode | ReactElement)
|
|
154
|
-
// showTooltip?: boolean
|
|
155
|
-
// tooltipDescription?: ReactNode | ReactElement | ((args: { value: any, record: RecordType }) => ReactNode | ReactElement)
|
|
156
|
-
// headerTemplate?: React.ReactNode | React.ReactElement | ((column: ColumnTable<RecordType>) => React.ReactNode | React.ReactElement);
|
|
157
|
-
// commandItems?: CommandItem[]
|
|
158
|
-
|
|
159
|
-
// children?: ColumnTable<RecordType>[]
|
|
160
|
-
|
|
161
|
-
// editType?: EditType | ((rowData?: RecordType) => EditType)
|
|
162
|
-
// disable?: boolean | ((rowData: any) => boolean)
|
|
163
|
-
// editEnable?: boolean | ((rowData: any) => boolean)
|
|
164
|
-
// isClearable?: boolean
|
|
165
|
-
// maxDate?: any
|
|
166
|
-
// minDate?: any
|
|
167
|
-
// maxTime?: any
|
|
168
|
-
// minTime?: any
|
|
169
|
-
// max?: number
|
|
170
|
-
// min?: number
|
|
171
|
-
// editSelectSettings?: IEditSelectSettings
|
|
172
|
-
// editFromSettings?: IEditFromSettings
|
|
173
|
-
// fixedType?: FixedType,
|
|
174
|
-
// headerTextWrap?: boolean
|
|
175
|
-
// // children?: ColumnEditType<RecordType>[]
|
|
176
|
-
|
|
177
|
-
// sumGroup?: boolean
|
|
178
|
-
|
|
179
|
-
// allowSelection?: boolean | ((rowData: RecordType) => boolean)
|
|
180
|
-
|
|
181
|
-
// onCellStyles?: Omit<React.CSSProperties, 'display' | 'width' | 'minWidth' | 'left' | 'right' | 'position'> | ((cellValue: any, cell: Cell<RecordType, unknown>) => Omit<React.CSSProperties, 'display' | 'width' | 'minWidth' | 'left' | 'right' | 'position'>)
|
|
182
|
-
// onCellHeaderStyles?: Omit<React.CSSProperties, 'display' | 'width' | 'minWidth' | 'left' | 'right' | 'position'> | ((cell: Header<RecordType, unknown>) => Omit<React.CSSProperties, 'display' | 'width' | 'minWidth' | 'left' | 'right' | 'position'>)
|
|
183
|
-
// onCellFooterStyles?: Omit<React.CSSProperties, 'display' | 'width' | 'minWidth' | 'left' | 'right' | 'position'> | ((cellValue: any, cell: Header<RecordType, unknown>) => Omit<React.CSSProperties, 'display' | 'width' | 'minWidth' | 'left' | 'right' | 'position'>)
|
|
184
|
-
|
|
185
|
-
// }
|
|
186
|
-
|
|
187
|
-
// export type IFormOpen = {
|
|
188
|
-
// value?: any
|
|
189
|
-
// setValue?: any
|
|
190
|
-
// getValues?: any
|
|
191
|
-
// reset?: any
|
|
192
|
-
// rowData?: any
|
|
193
|
-
// }
|
|
194
|
-
|
|
195
|
-
// export type IEditFromSettings = {
|
|
196
|
-
// fieldKey: string
|
|
197
|
-
// // eslint-disable-next-line no-unused-vars
|
|
198
|
-
// formOpen?: (props: IFormOpen) => void
|
|
199
|
-
// // eslint-disable-next-line no-unused-vars
|
|
200
|
-
// formClose?: (props: IFormOpen) => void
|
|
201
|
-
// // eslint-disable-next-line no-unused-vars
|
|
202
|
-
// formatLabel?: (value: any) => string
|
|
203
|
-
// menuWidth?: number
|
|
204
|
-
// menuHeight?: number
|
|
205
|
-
// labelWith?: number
|
|
206
|
-
// items: any[]
|
|
207
|
-
// layout?: {
|
|
208
|
-
// xl?: IGrid
|
|
209
|
-
// lg?: IGrid
|
|
210
|
-
// md?: IGrid
|
|
211
|
-
// sm?: IGrid
|
|
212
|
-
// xs?: IGrid
|
|
213
|
-
// }
|
|
214
|
-
|
|
215
|
-
// defaultValues?: Record<string, any>
|
|
216
|
-
|
|
217
|
-
// schema?: any
|
|
218
|
-
// }
|
|
219
|
-
|
|
220
|
-
// type IGrid = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24
|
|
221
|
-
|
|
222
|
-
// export type ColumnTemplate<RecordType> = {
|
|
223
|
-
// value: any,
|
|
224
|
-
// rowData: RecordType,
|
|
225
|
-
// index: number,
|
|
226
|
-
// field: string
|
|
227
|
-
// }
|
|
228
|
-
|
|
229
|
-
// export type ColumnsTable<RecordType = AnyObject> = ColumnTable<RecordType>[]
|
|
230
|
-
|
|
231
|
-
// export type Locale = TableLocale & {
|
|
232
|
-
// ok_btn: string
|
|
233
|
-
// cancel_btn: string
|
|
234
|
-
// add_rows: string
|
|
235
|
-
// add_rows_before: string
|
|
236
|
-
// add_rows_after: string
|
|
237
|
-
// add_1: string
|
|
238
|
-
// add_10: string
|
|
239
|
-
// add_50: string
|
|
240
|
-
// add_100: string
|
|
241
|
-
// add_children: string
|
|
242
|
-
// delete_content: string
|
|
243
|
-
// delete_rows: string
|
|
244
|
-
// custom: string
|
|
245
|
-
// }
|
|
246
|
-
|
|
247
|
-
// export type Sort = {
|
|
248
|
-
// columnKey: string,
|
|
249
|
-
// field: string,
|
|
250
|
-
// order: 'ascend' | 'descend' | null
|
|
251
|
-
// }
|
|
252
|
-
|
|
253
|
-
// export interface TableProps<RecordType = AnyObject> extends Omit<RcTableProps<RecordType>, 'columns' | 'rowSelection' | 'loading' | 'dataSource' | 'summary' | 'pagination' | 'locale' | 'virtual'> {
|
|
254
|
-
// editAble?: boolean
|
|
255
|
-
// infiniteScroll?: boolean
|
|
256
|
-
// theme?: {
|
|
257
|
-
// theme?: 'dark' | 'light',
|
|
258
|
-
// backgroundColor?: string
|
|
259
|
-
// color?: string
|
|
260
|
-
// }
|
|
261
|
-
// virtualRow?: boolean
|
|
262
|
-
// virtualColumns?: boolean
|
|
263
|
-
// next?: () => void
|
|
264
|
-
// locale?: Locale
|
|
265
|
-
// groupAble?: boolean
|
|
266
|
-
// groupColumns?: string[]
|
|
267
|
-
// groupSetting?: IGroupSetting
|
|
268
|
-
// onChooseColumns?: (props: IOnChooseColumns) => void
|
|
269
|
-
// pagination?: false | PaginationConfig;
|
|
270
|
-
// showCustomTooltip?: boolean
|
|
271
|
-
|
|
272
|
-
// sortMultiple?: boolean
|
|
273
|
-
// dataSource: RecordType[]
|
|
274
|
-
// columns: ColumnsTable<RecordType>,
|
|
275
|
-
// height?: number
|
|
276
|
-
// minHeight?: number
|
|
277
|
-
// format?: IFormat
|
|
278
|
-
// t?: any
|
|
279
|
-
// lang?: string
|
|
280
|
-
// contextMenuItems?: ContextMenuItem[]
|
|
281
|
-
// showDefaultContext?: boolean
|
|
282
|
-
// contextMenuHidden?: string[] | ((args?: Omit<ContextInfo<RecordType>, 'item' | 'event'>) => string[])
|
|
283
|
-
// contextMenuOpen?: (args: Omit<ContextInfo<RecordType>, 'item'>) => void
|
|
284
|
-
// contextMenuClick?: (args: ContextInfo<RecordType>) => void
|
|
285
|
-
// recordDoubleClick?: (args: RecordDoubleClickEventArgs<RecordType>) => void
|
|
286
|
-
// toolbarItems?: ToolbarItem[]
|
|
287
|
-
// showColumnChoose?: boolean
|
|
288
|
-
// showAdvanceFilter?: boolean
|
|
289
|
-
|
|
290
|
-
// allowFiltering?: boolean
|
|
291
|
-
// onFilter?: (query: { field: string, key: string, operator: IOperator, predicate: 'and' | 'or', value: any }[]) => void
|
|
292
|
-
// allowSortering?: boolean
|
|
293
|
-
// onSorter?: (args: { column: ColumnTable<RecordType>, columnKey: string, field: string, order: 'ascend' | 'descend' | null }) => void
|
|
294
|
-
// defaultSorter?: Sort[]
|
|
295
|
-
// selectionSettings?: SelectionSettings
|
|
296
|
-
// // rowKey?: string
|
|
297
|
-
// rowKey?: string | keyof RecordType | GetRowKey<RecordType>;
|
|
298
|
-
|
|
299
|
-
// rowSelection?: RowSelection<RecordType>
|
|
300
|
-
// rowSelected?: (args: { type: string, rowData: RecordType, selected: RecordType | RecordType[] }) => void
|
|
301
|
-
// dataSourceFilter?: SourceFilter[]
|
|
302
|
-
// onFilterClick?: (column: ColumnTable<RecordType>, callback: (key: string, data: any) => void) => void
|
|
303
|
-
// loading?: boolean
|
|
304
|
-
// allowResizing?: boolean
|
|
305
|
-
// showToolbar?: boolean
|
|
306
|
-
// onDataChange?: (data: RecordType[]) => void
|
|
307
|
-
// defaultValue?: AnyObject | (() => AnyObject)
|
|
308
|
-
|
|
309
|
-
// summary?: boolean | ((data: readonly RecordType[]) => React.ReactNode);
|
|
310
|
-
// showEmptyText?: boolean
|
|
311
|
-
// commandSettings?: CommandSettings
|
|
312
|
-
|
|
313
|
-
// // columns: ColumnsTable<RecordType>
|
|
314
|
-
// onCellPaste?: ICellPasteModel<RecordType>
|
|
315
|
-
// onCellChange?: (args: CellChangeArgs<RecordType>, handleCallback: (rowData: any, index: any, value?: any) => void) => void
|
|
316
|
-
// onCellClick?: (args: ICellClick, callback?: any) => void
|
|
317
|
-
// rowEditable?: (rowData: RecordType) => boolean
|
|
318
|
-
// validate?: any
|
|
319
|
-
// onBlur?: (data: RecordType[]) => void
|
|
320
|
-
|
|
321
|
-
// onExpandClick?: (args: { expandedKeys: string[], key: string, rowData: any }) => void
|
|
322
|
-
|
|
323
|
-
// wrapSettings?: IWrapSettings,
|
|
324
|
-
|
|
325
|
-
// actionTemplate?: ReactNode | ReactElement | (() => ReactNode | ReactElement)
|
|
326
|
-
|
|
327
|
-
// fullScreen?: boolean
|
|
328
|
-
|
|
329
|
-
// onRowStyles?: Omit<React.CSSProperties, 'display' | 'transform' | 'gridTemplateColumns' | 'height' | 'minHeight'> | ((data: RecordType, row: Row<RecordType>) => Omit<React.CSSProperties, 'display' | 'transform' | 'gridTemplateColumns' | 'height' | 'minHeight'>)
|
|
330
|
-
// onRowHeaderStyles?: Omit<React.CSSProperties, 'display' | 'transform' | 'gridTemplateColumns' | 'height' | 'minHeight'> | (() => Omit<React.CSSProperties, 'display' | 'transform' | 'gridTemplateColumns' | 'height' | 'minHeight'>)
|
|
331
|
-
// onRowFooterStyles?: Omit<React.CSSProperties, 'display' | 'transform' | 'gridTemplateColumns' | 'height' | 'minHeight'> | (() => Omit<React.CSSProperties, 'display' | 'transform' | 'gridTemplateColumns' | 'height' | 'minHeight'>)
|
|
332
|
-
|
|
333
|
-
// fullScreenTitle?: ReactNode | (() => ReactNode)
|
|
334
|
-
// }
|
|
335
|
-
|
|
336
|
-
// // export interface TableEditProps<RecordType = AnyObject> extends Omit<TableProps<RecordType>, 'columns' > {
|
|
337
|
-
// // columns: ColumnsTable<RecordType>
|
|
338
|
-
// // onCellPaste?: ICellPasteModel<RecordType>
|
|
339
|
-
// // onCellChange?: (args: CellChangeArgs<RecordType>, handleCallback: (rowData: any, index: any, value?: any) => void) => void
|
|
340
|
-
// // onCellClick?: (args: ICellClick, callback?: any) => void
|
|
341
|
-
// // rowEditable?: (rowData: RecordType) => boolean
|
|
342
|
-
// // }
|
|
343
|
-
|
|
344
|
-
// export type PaginationConfig = TablePaginationConfig & {
|
|
345
|
-
// currentPage?: number
|
|
346
|
-
// }
|
|
347
|
-
// export type ICellClick = {
|
|
348
|
-
// index: number
|
|
349
|
-
// indexCol?: number
|
|
350
|
-
// rowId: string | number
|
|
351
|
-
// type: 'Editing' | 'Default'
|
|
352
|
-
// field: string
|
|
353
|
-
// cellValue: any
|
|
354
|
-
// rowData: any
|
|
355
|
-
// }
|
|
356
|
-
|
|
357
|
-
// export type GridTableProps<RecordType = AnyObject> = TableProps<RecordType>
|
|
358
|
-
|
|
359
|
-
// export interface CommandItem {
|
|
360
|
-
// id: string
|
|
361
|
-
// type?: string
|
|
362
|
-
// visible?: boolean | ((record: any) => boolean)
|
|
363
|
-
// title: string
|
|
364
|
-
// color?: 'blue' | 'purple' | 'cyan' | 'green' | 'magenta' | 'pink' | 'red' | 'orange' | 'yellow' | 'volcano' | 'geekblue' | 'lime' | 'gold';
|
|
365
|
-
// tooltip?: string
|
|
366
|
-
// icon?: ReactNode | ReactElement | (() => ReactNode | ReactElement)
|
|
367
|
-
// template?: ReactNode | ReactElement | ((record: any) => ReactNode | ReactElement)
|
|
368
|
-
// client?: boolean
|
|
369
|
-
// confirmDialog?: boolean
|
|
370
|
-
// }
|
|
371
|
-
|
|
372
|
-
// export type GroupTemplate = {
|
|
373
|
-
// rowData: any
|
|
374
|
-
// value: any
|
|
375
|
-
// column: ColumnTable
|
|
376
|
-
// }
|
|
377
|
-
|
|
378
|
-
// export type IGroupSetting = {
|
|
379
|
-
// client?: boolean
|
|
380
|
-
// onGroup?: (props: IOnGroup) => void
|
|
381
|
-
// groupColumnSpan?: number
|
|
382
|
-
// hiddenColumnGroup?: boolean
|
|
383
|
-
// showHeaderColumn?: boolean
|
|
384
|
-
// showGroupIcon?: boolean
|
|
385
|
-
// unClearableLevel?: 1 | 2 | 3 | undefined
|
|
386
|
-
// sumGroup?: boolean
|
|
387
|
-
// groupTemplate?: React.ReactNode | React.ReactElement | ((args: GroupTemplate) => React.ReactNode | React.ReactElement)
|
|
388
|
-
// }
|
|
389
|
-
|
|
390
|
-
// type IOnGroup = {
|
|
391
|
-
// columnGrouped: string[]
|
|
392
|
-
// columns: ColumnsTable
|
|
393
|
-
// flattenColumns: ColumnsTable
|
|
394
|
-
// }
|
|
395
|
-
|
|
396
|
-
// export type IOnChooseColumns = {
|
|
397
|
-
// columns: ColumnsTable
|
|
398
|
-
// showColumns: ColumnsTable
|
|
399
|
-
// flattenColumns: ColumnsTable
|
|
400
|
-
// }
|
|
401
|
-
|
|
402
|
-
// export type CellChangeArgs<T> = {
|
|
403
|
-
// type: 'onPaste' | 'onChange' | 'onCellPaste'
|
|
404
|
-
// value: any
|
|
405
|
-
// option: AnyObject
|
|
406
|
-
// rowData: T
|
|
407
|
-
// rowsData: T[]
|
|
408
|
-
// indexRow: number
|
|
409
|
-
// rowId?: string
|
|
410
|
-
// field: string | undefined
|
|
411
|
-
// indexCol: any
|
|
412
|
-
// sumValue?: any[]
|
|
413
|
-
// }
|
|
414
|
-
|
|
415
|
-
// export type IOnPastedProps = {
|
|
416
|
-
// data: any[]
|
|
417
|
-
// copyRows: any[]
|
|
418
|
-
// pastedColumns: string[]
|
|
419
|
-
// pasteData: any[]
|
|
420
|
-
// type: 'onPaste' | 'onChange' | 'onCellPaste'
|
|
421
|
-
// }
|
|
422
|
-
|
|
423
|
-
// export interface ICellPasteModel<RecordType = AnyObject> {
|
|
424
|
-
|
|
425
|
-
// onPasted?: (args: IOnPastedProps, handleCallback: (callbackData: any[]) => void) => void
|
|
426
|
-
|
|
427
|
-
// dataChange?: (data: RecordType[]) => void
|
|
428
|
-
// getCallbackData?: (props: any) => void
|
|
429
|
-
// maxRowsPaste?: number
|
|
430
|
-
// }
|
|
431
|
-
|
|
432
|
-
// export type SourceFilter = {
|
|
433
|
-
// key: string
|
|
434
|
-
// data: any[]
|
|
435
|
-
// loadOptions?: (search: string, callback: (newOptions: any[]) => void) => void;
|
|
436
|
-
|
|
437
|
-
// }
|
|
438
|
-
|
|
439
|
-
// export type RowSelection<RecordType> = Omit<TableRowSelection<RecordType>, 'type' | 'columnWidth' | 'hideSelectAll' | 'defaultSelectedRowKeys'>
|
|
440
|
-
|
|
441
|
-
// export type SelectionSettings = Omit<TableRowSelection, 'type' | 'onChange' | 'onSelect' | 'onSelectAll' | 'onSelectNone' | 'onSelectMultiple'> & {
|
|
442
|
-
// mode?: 'checkbox' | 'radio'
|
|
443
|
-
// type?: 'single' | 'multiple'
|
|
444
|
-
// checkboxOnly?: boolean
|
|
445
|
-
// }
|
|
446
|
-
|
|
447
|
-
// export type RecordDoubleClickEventArgs<RecordType> = {
|
|
448
|
-
// rowData: RecordType
|
|
449
|
-
// rowIndex: number | undefined
|
|
450
|
-
// e: React.MouseEvent<HTMLElement> | React.KeyboardEvent<HTMLElement>;
|
|
451
|
-
// }
|
|
452
|
-
|
|
453
|
-
// export type ContextInfo<RecordType> = {
|
|
454
|
-
// rowInfo: {
|
|
455
|
-
// rowData: RecordType | null
|
|
456
|
-
// }
|
|
457
|
-
// event: React.MouseEvent<HTMLElement> | React.KeyboardEvent<HTMLElement>;
|
|
458
|
-
// item: ItemType
|
|
459
|
-
// }
|
|
460
|
-
|
|
461
|
-
// export type IFormat = {
|
|
462
|
-
// thousandSeparator?: string
|
|
463
|
-
// decimalSeparator?: string
|
|
464
|
-
// decimalScale?: number | undefined // bao nhiêu số sau số thập phân
|
|
465
|
-
// allowNegative?: boolean // check nhập số âm
|
|
466
|
-
// prefix?: string | undefined
|
|
467
|
-
// suffix?: string | undefined
|
|
468
|
-
// fixedDecimalScale?: boolean // mặc định thêm số 0 sau số thập phân
|
|
469
|
-
// dateFormat?: string
|
|
470
|
-
// datetimeFormat?: string
|
|
471
|
-
// timeFormat?: string
|
|
472
|
-
// weekFormat?: string
|
|
473
|
-
// monthFormat?: string
|
|
474
|
-
// yearFormat?: string
|
|
475
|
-
// }
|
|
476
|
-
|
|
477
|
-
// export type GetRowKey<RecordType> = (record: RecordType, index?: number) => Key;
|
|
478
|
-
|
|
479
|
-
// export type Presets = Required<ColorPickerProps>['presets'][number];
|
|
480
|
-
|
|
481
|
-
// export type CommandSettings = {
|
|
482
|
-
// client?: boolean
|
|
483
|
-
// confirmDialog?: boolean
|
|
484
|
-
// }
|
|
485
|
-
|
|
486
|
-
// export type IWrapMode = 'Header' | 'Both' | 'Content'
|
|
487
|
-
|
|
488
|
-
// export type IWrapSettings = {
|
|
489
|
-
// wrapMode?: IWrapMode
|
|
490
|
-
// }
|
|
491
|
-
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import type { ColumnsTable, ColumnTable } from "
|
|
2
|
+
import type { ColumnsTable, ColumnTable } from "./../grid-component/type";
|
|
3
3
|
import type { ColumnDef } from "@tanstack/react-table";
|
|
4
4
|
export type IColumnsChoose<RecordType> = {
|
|
5
5
|
columns: ColumnDef<RecordType>[];
|
|
@@ -15,8 +15,6 @@ var _utils = require("./hook/utils");
|
|
|
15
15
|
var _becoxyIcons = require("becoxy-icons");
|
|
16
16
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
17
17
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
18
|
-
// import { SettingOutlined } from "@ant-design/icons"
|
|
19
|
-
|
|
20
18
|
const BoxAction = _styledComponents.default.div.withConfig({
|
|
21
19
|
displayName: "BoxAction",
|
|
22
20
|
componentId: "es-grid-template__sc-jfujqh-0"
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import type { ContextInfo } from "
|
|
3
|
-
import type { ContextMenuItem } from "./type";
|
|
2
|
+
import type { ContextInfo, ContextMenuItem } from "./../grid-component/type";
|
|
4
3
|
export declare const findItemByKey: (array: any[], key: string, value: any) => any;
|
|
5
4
|
type Props<RecordType> = {
|
|
6
5
|
rowData: RecordType | null;
|
|
@@ -8,8 +8,6 @@ var React = _interopRequireWildcard(require("react"));
|
|
|
8
8
|
var _antd = require("antd");
|
|
9
9
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
10
10
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
11
|
-
// import type { MenuProps } from "antd";
|
|
12
|
-
|
|
13
11
|
const findItemByKey = (array, key, value) => {
|
|
14
12
|
for (let i = 0; i < array.length; i++) {
|
|
15
13
|
const item = array[i];
|
|
@@ -3,7 +3,6 @@ import 'react-resizable/css/styles.css';
|
|
|
3
3
|
import 'dayjs/locale/es';
|
|
4
4
|
import 'dayjs/locale/vi';
|
|
5
5
|
import './style.scss';
|
|
6
|
-
import type { TableProps } from '
|
|
7
|
-
export declare const SELECTION_COLUMN: {};
|
|
6
|
+
import type { TableProps } from './../grid-component/type';
|
|
8
7
|
declare const InternalTable: <RecordType extends object>(props: TableProps<RecordType>) => React.JSX.Element;
|
|
9
8
|
export default InternalTable;
|
|
@@ -4,7 +4,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.default =
|
|
7
|
+
exports.default = void 0;
|
|
8
8
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
9
9
|
var _customParseFormat = _interopRequireDefault(require("dayjs/plugin/customParseFormat"));
|
|
10
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
@@ -22,34 +22,7 @@ var _convert = require("./hook/convert");
|
|
|
22
22
|
var _hooks = require("../grid-component/hooks");
|
|
23
23
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
24
24
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
25
|
-
// import en from "rc-master-ui/es/date-picker/locale/en_US"
|
|
26
|
-
// import vi from "rc-master-ui/es/date-picker/locale/vi_VN"
|
|
27
|
-
|
|
28
|
-
// import enDr from "rc-master-ui/es/locales/en_US"
|
|
29
|
-
// import viDr from "rc-master-ui/es/locales/vi_VN"
|
|
30
|
-
|
|
31
|
-
// import type { PickerLocale } from "rc-master-ui/es/date-picker/generatePicker"
|
|
32
|
-
|
|
33
|
-
// import Swal from "sweetalert2"
|
|
34
|
-
// import withReactContent from "sweetalert2-react-content"
|
|
35
|
-
// import { Tooltip } from "react-tooltip"
|
|
36
|
-
|
|
37
|
-
// import InfiniteTable from './table/InfiniteTable'
|
|
38
|
-
// import GridEdit from './table/GridEdit'
|
|
39
|
-
|
|
40
|
-
// import { Group } from 'becoxy-icons'
|
|
41
|
-
|
|
42
|
-
// import { Tooltip } from 'react-tooltip'
|
|
43
|
-
// import ContextMenu from './ContextMenu'
|
|
44
|
-
|
|
45
25
|
_dayjs.default.extend(_customParseFormat.default);
|
|
46
|
-
|
|
47
|
-
// const MySwal = withReactContent(Swal)
|
|
48
|
-
|
|
49
|
-
// const ASCEND = 'ascend'
|
|
50
|
-
// const DESCEND = 'descend'
|
|
51
|
-
|
|
52
|
-
const SELECTION_COLUMN = exports.SELECTION_COLUMN = {};
|
|
53
26
|
const InternalTable = props => {
|
|
54
27
|
const {
|
|
55
28
|
t,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { Dispatch, SetStateAction } from 'react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import type { ColumnDef, ColumnSizingInfoState, ColumnSizingState, Table } from '@tanstack/react-table';
|
|
4
|
-
import type { ColumnsTable, TableProps } from '
|
|
4
|
+
import type { ColumnsTable, TableProps } from './../grid-component/type';
|
|
5
5
|
type TableContainerProps<T> = Omit<TableProps<T>, 'columns'> & {
|
|
6
6
|
table: Table<T>;
|
|
7
7
|
prefix: string;
|
|
@@ -75,7 +75,8 @@ const TableContainer = props => {
|
|
|
75
75
|
onRowStyles,
|
|
76
76
|
onRowFooterStyles,
|
|
77
77
|
onRowHeaderStyles,
|
|
78
|
-
title
|
|
78
|
+
title,
|
|
79
|
+
dataSourceFilter
|
|
79
80
|
} = props;
|
|
80
81
|
const tableContainerRef = _react.default.useRef(null);
|
|
81
82
|
const containerRef = _react.default.useRef(null);
|
|
@@ -277,7 +278,8 @@ const TableContainer = props => {
|
|
|
277
278
|
onRowFooterStyles,
|
|
278
279
|
onRowHeaderStyles,
|
|
279
280
|
table,
|
|
280
|
-
pagination
|
|
281
|
+
pagination,
|
|
282
|
+
dataSourceFilter
|
|
281
283
|
}
|
|
282
284
|
}, /*#__PURE__*/_react.default.createElement(_TableWrapper.default, {
|
|
283
285
|
contextMenuItems: contextMenuItems,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { Dispatch, SetStateAction } from "react";
|
|
2
2
|
import React from "react";
|
|
3
3
|
import type { ColumnDef, ColumnSizingInfoState, ColumnSizingState, Table } from "@tanstack/react-table";
|
|
4
|
-
import type { ColumnsTable, TableProps } from "
|
|
4
|
+
import type { ColumnsTable, TableProps } from "./../grid-component/type";
|
|
5
5
|
type TableContainerProps<T> = Omit<TableProps<T>, 'columns'> & {
|
|
6
6
|
table: Table<T>;
|
|
7
7
|
prefix: string;
|