@indico-data/design-system 2.60.12 → 2.60.14
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/lib/components/tanstackTable/TankstackTable.types.d.ts +2 -1
- package/lib/components/tanstackTable/TanstackTable.d.ts +1 -1
- package/lib/index.css +3 -0
- package/lib/index.d.ts +3 -2
- package/lib/index.esm.css +3 -0
- package/lib/index.esm.js +2 -2
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +2 -2
- package/lib/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/tanstackTable/TankstackTable.types.ts +2 -1
- package/src/components/tanstackTable/TanstackTable.stories.tsx +9 -0
- package/src/components/tanstackTable/TanstackTable.tsx +2 -1
- package/src/components/truncate/styles/Truncate.scss +4 -0
package/lib/index.js
CHANGED
|
@@ -41487,13 +41487,13 @@ const TableBody = ({ table, onRowClick, isLoading, columnsLength, activeRows, })
|
|
|
41487
41487
|
};
|
|
41488
41488
|
|
|
41489
41489
|
function TanstackTable(_a) {
|
|
41490
|
-
var { columns: defaultColumns, data, className, currentPage, rowCount, rowsPerPage = 1000, onChangePage, totalEntriesText, TableActions, error, enableRowSelection = true, clearFilters, hasFilters, showPagination = true, isLoading = false, defaultPinnedColumns, onRowClick, activeRows = [], isStriped = true, actionBarClassName } = _a, rest = __rest(_a, ["columns", "data", "className", "currentPage", "rowCount", "rowsPerPage", "onChangePage", "totalEntriesText", "TableActions", "error", "enableRowSelection", "clearFilters", "hasFilters", "showPagination", "isLoading", "defaultPinnedColumns", "onRowClick", "activeRows", "isStriped", "actionBarClassName"]);
|
|
41490
|
+
var { columns: defaultColumns, data, className, currentPage, rowCount, rowsPerPage = 1000, onChangePage, totalEntriesText, TableActions, error, enableRowSelection = true, clearFilters, hasFilters, showPagination = true, isLoading = false, defaultPinnedColumns, onRowClick, activeRows = [], isStriped = true, actionBarClassName, defaultSorting } = _a, rest = __rest(_a, ["columns", "data", "className", "currentPage", "rowCount", "rowsPerPage", "onChangePage", "totalEntriesText", "TableActions", "error", "enableRowSelection", "clearFilters", "hasFilters", "showPagination", "isLoading", "defaultPinnedColumns", "onRowClick", "activeRows", "isStriped", "actionBarClassName", "defaultSorting"]);
|
|
41491
41491
|
const { columns, defaultData, windowWidth, rowSelection, // This refers to the checkboxes.
|
|
41492
41492
|
setRowSelection, formattedColumns, setFormattedColumns, } = useTanstackTable({
|
|
41493
41493
|
defaultColumns,
|
|
41494
41494
|
});
|
|
41495
41495
|
// handles internal sorting state.
|
|
41496
|
-
const [sorting, setSorting] = React.useState([]);
|
|
41496
|
+
const [sorting, setSorting] = React.useState(defaultSorting !== null && defaultSorting !== void 0 ? defaultSorting : []);
|
|
41497
41497
|
const thRefs = React.useRef({});
|
|
41498
41498
|
// Auto-compute column widths based on current table header cell widths for columns without a defined size.
|
|
41499
41499
|
React.useEffect(() => {
|