{"version":3,"file":"dataTypes.cjs","names":[],"sources":["../../../../src/labs/DataView/dataTypes.ts"],"sourcesContent":["/*!\n * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport {\n  MRT_Cell,\n  MRT_Column,\n  MRT_ColumnDef,\n  MRT_Row,\n  MRT_RowData,\n  MRT_RowSelectionState,\n  MRT_SortingState,\n  MRT_VisibilityState,\n} from \"material-react-table\";\n\nimport { DataFilter } from \"../DataFilters.js\";\n\nexport type DataQueryParamsType = {\n  filters?: DataFilter[];\n  page?: number;\n  resultsPerPage?: number;\n  search?: string;\n  sort?: MRT_SortingState;\n};\n\nexport type DataTableColumn<\n  TData extends MRT_RowData,\n  TValue = unknown,\n> = MRT_ColumnDef<TData, TValue> & {\n  /**\n   * @deprecated use hasTextWrapping instead of enableWrapping\n   */\n  enableWrapping?: boolean;\n  hasTextWrapping?: boolean;\n};\n\nexport type DataTableColumnInstance<TData extends MRT_RowData, TValue> = Omit<\n  MRT_Column<TData, TValue>,\n  \"columnDef\"\n> & {\n  columnDef: DataTableColumn<TData, TValue>;\n};\n\nexport type DataTableCell<TData extends MRT_RowData, TValue> = Omit<\n  MRT_Cell<TData>,\n  \"column\"\n> & {\n  column: DataTableColumnInstance<TData, TValue>;\n};\n\nexport type DataColumns<\n  TData extends MRT_RowData,\n  TValue = unknown,\n> = DataTableColumn<TData, TValue>[];\n\nexport type DataRow = MRT_RowData;\n\nexport type GetRowId<TData extends MRT_RowData> = (\n  originalRow: TData,\n  index: number,\n  parentRow?: MRT_Row<TData>,\n) => string;\n\nexport type DataGetDataType = {\n  filters?: DataFilter[];\n  page?: number;\n  resultsPerPage?: number;\n  search?: string;\n  sort?: MRT_SortingState;\n};\n\nexport type DataOnReorderRowsType = {\n  newRowIndex: number;\n  rowId: string;\n};\n\nexport type DataColumnVisibilityState = MRT_VisibilityState;\nexport type DataRowSelectionState = MRT_RowSelectionState;\n\n// Provided for backwards compatibility with old DataTable types\nexport type DataTableGetDataType = DataGetDataType;\nexport type DataTableOnReorderRowsType = DataOnReorderRowsType;\nexport type DataTableRowSelectionState = DataRowSelectionState;\nexport type DataTableRow = DataRow;\n"],"mappings":"","ignoreList":[]}