@indico-data/design-system 2.50.0 → 2.51.1

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.
Files changed (74) hide show
  1. package/lib/components/tanstackTable/TankstackTable.types.d.ts +45 -0
  2. package/lib/components/tanstackTable/TanstackTable.stories.d.ts +16 -0
  3. package/lib/components/tanstackTable/TanstakTable.d.ts +4 -0
  4. package/lib/components/tanstackTable/__tests__/TanstackTable.test.d.ts +1 -0
  5. package/lib/components/tanstackTable/__tests__/__mocks__/test-mock-data.d.ts +8 -0
  6. package/lib/components/tanstackTable/components/ActionBar/ActionBar.d.ts +17 -0
  7. package/lib/components/tanstackTable/components/ActionBar/ActionBar.stories.d.ts +10 -0
  8. package/lib/components/tanstackTable/components/ActionBar/__tests__/ActionBar.test.d.ts +1 -0
  9. package/lib/components/tanstackTable/components/ActionBar/index.d.ts +1 -0
  10. package/lib/components/tanstackTable/components/NoResults/NoResults.d.ts +7 -0
  11. package/lib/components/tanstackTable/components/NoResults/__tests__/NoResult.test.d.ts +1 -0
  12. package/lib/components/tanstackTable/components/NoResults/index.d.ts +1 -0
  13. package/lib/components/tanstackTable/components/TableBody/TableBody.d.ts +11 -0
  14. package/lib/components/tanstackTable/components/TableBody/index.d.ts +1 -0
  15. package/lib/components/tanstackTable/components/TableHeader/TableHeader.d.ts +6 -0
  16. package/lib/components/tanstackTable/components/TableHeader/index.d.ts +1 -0
  17. package/lib/components/tanstackTable/components/TablePagination/TablePagination.d.ts +9 -0
  18. package/lib/components/tanstackTable/components/TablePagination/__tests__/TablePagination.test.d.ts +1 -0
  19. package/lib/components/tanstackTable/components/TablePagination/index.d.ts +1 -0
  20. package/lib/components/tanstackTable/docs/pinnedColumns/PinnedColumn.stories.d.ts +7 -0
  21. package/lib/components/tanstackTable/docs/withRowClick/WithRowClick.stories.d.ts +7 -0
  22. package/lib/components/tanstackTable/helpers.d.ts +830 -0
  23. package/lib/components/tanstackTable/index.d.ts +2 -0
  24. package/lib/components/tanstackTable/mock-data/mock-data.d.ts +14 -0
  25. package/lib/components/tanstackTable/mock-data/table-configuration.d.ts +3 -0
  26. package/lib/components/tanstackTable/useTanstackTable.d.ts +14 -0
  27. package/lib/index.css +262 -0
  28. package/lib/index.d.ts +67 -17
  29. package/lib/index.esm.css +262 -0
  30. package/lib/index.esm.js +20432 -56
  31. package/lib/index.esm.js.map +1 -1
  32. package/lib/index.js +20432 -55
  33. package/lib/index.js.map +1 -1
  34. package/package.json +2 -1
  35. package/src/components/tanstackTable/TankstackTable.types.ts +44 -0
  36. package/src/components/tanstackTable/TanstackTable.mdx +122 -0
  37. package/src/components/tanstackTable/TanstackTable.stories.tsx +284 -0
  38. package/src/components/tanstackTable/TanstakTable.tsx +156 -0
  39. package/src/components/tanstackTable/__tests__/TanstackTable.test.tsx +73 -0
  40. package/src/components/tanstackTable/__tests__/__mocks__/test-mock-data.tsx +83 -0
  41. package/src/components/tanstackTable/components/ActionBar/ActionBar.mdx +10 -0
  42. package/src/components/tanstackTable/components/ActionBar/ActionBar.scss +30 -0
  43. package/src/components/tanstackTable/components/ActionBar/ActionBar.stories.tsx +98 -0
  44. package/src/components/tanstackTable/components/ActionBar/ActionBar.tsx +43 -0
  45. package/src/components/tanstackTable/components/ActionBar/__tests__/ActionBar.test.tsx +65 -0
  46. package/src/components/tanstackTable/components/ActionBar/index.ts +1 -0
  47. package/src/components/tanstackTable/components/NoResults/NoResults.scss +24 -0
  48. package/src/components/tanstackTable/components/NoResults/NoResults.tsx +22 -0
  49. package/src/components/tanstackTable/components/NoResults/__tests__/NoResult.test.tsx +25 -0
  50. package/src/components/tanstackTable/components/NoResults/index.ts +1 -0
  51. package/src/components/tanstackTable/components/TableBody/TableBody.tsx +77 -0
  52. package/src/components/tanstackTable/components/TableBody/index.ts +1 -0
  53. package/src/components/tanstackTable/components/TableHeader/TableHeader.tsx +49 -0
  54. package/src/components/tanstackTable/components/TableHeader/index.ts +1 -0
  55. package/src/components/tanstackTable/components/TablePagination/TablePagination.tsx +45 -0
  56. package/src/components/tanstackTable/components/TablePagination/__tests__/TablePagination.test.tsx +18 -0
  57. package/src/components/tanstackTable/components/TablePagination/index.ts +1 -0
  58. package/src/components/tanstackTable/docs/pinnedColumns/PinnedColumn.mdx +34 -0
  59. package/src/components/tanstackTable/docs/pinnedColumns/PinnedColumn.stories.tsx +40 -0
  60. package/src/components/tanstackTable/docs/withRowClick/WithRowClick.mdx +48 -0
  61. package/src/components/tanstackTable/docs/withRowClick/WithRowClick.stories.tsx +32 -0
  62. package/src/components/tanstackTable/helpers.ts +45 -0
  63. package/src/components/tanstackTable/index.ts +2 -0
  64. package/src/components/tanstackTable/mock-data/mock-data.ts +256 -0
  65. package/src/components/tanstackTable/mock-data/table-configuration.tsx +222 -0
  66. package/src/components/tanstackTable/styles/_variables.scss +35 -0
  67. package/src/components/tanstackTable/styles/table.scss +218 -0
  68. package/src/components/tanstackTable/styles/test.scss +19 -0
  69. package/src/components/tanstackTable/tanstack-table.d.ts +19 -0
  70. package/src/components/tanstackTable/useTanstackTable.tsx +39 -0
  71. package/src/index.ts +1 -0
  72. package/src/legacy/components/loading-indicators/CirclePulse/CirclePulse.tsx +1 -0
  73. package/src/styles/index.scss +1 -0
  74. package/src/stylesAndAnimations/utilityClasses/UtilityClassesTable.tsx +16 -2
@@ -0,0 +1,2 @@
1
+ export type { ColumnDef } from '@tanstack/react-table';
2
+ export { TanstackTable } from './TanstakTable';
@@ -0,0 +1,14 @@
1
+ export type Person = {
2
+ firstName: string;
3
+ lastName: string;
4
+ age: number;
5
+ visits: number;
6
+ progress: number;
7
+ status: 'relationship' | 'complicated' | 'single';
8
+ subRows?: Person[];
9
+ id: string;
10
+ country: string;
11
+ city: string;
12
+ civility: string;
13
+ };
14
+ export declare const people: Person[];
@@ -0,0 +1,3 @@
1
+ import { ColumnDef } from '@tanstack/react-table';
2
+ import { Person } from './mock-data';
3
+ export declare const columns: ColumnDef<Person>[];
@@ -0,0 +1,14 @@
1
+ import { ColumnDef } from '@tanstack/react-table';
2
+ type Props<T> = {
3
+ defaultColumns: ColumnDef<T>[];
4
+ };
5
+ export declare function useTanstackTable<T>({ defaultColumns }: Props<T>): {
6
+ columns: ColumnDef<T>[];
7
+ defaultData: never[];
8
+ rowSelection: {};
9
+ setRowSelection: import("react").Dispatch<import("react").SetStateAction<{}>>;
10
+ windowWidth: number;
11
+ formattedColumns: ColumnDef<T>[];
12
+ setFormattedColumns: import("react").Dispatch<import("react").SetStateAction<ColumnDef<T>[]>>;
13
+ };
14
+ export {};
package/lib/index.css CHANGED
@@ -1962,6 +1962,268 @@ form {
1962
1962
  border-color: var(--pf-error-color);
1963
1963
  }
1964
1964
 
1965
+ :root [data-theme=light] {
1966
+ --pf-tanstack-table-background-color: var(--pf-white-color);
1967
+ --pf-tanstack-table-font-color: var(--pf-gray-color);
1968
+ --pf-tanstack-table-border-color: var(--pf-gray-color-200);
1969
+ --pf-tanstack-table-stripe-color: var(--pf-gray-color-100);
1970
+ --pf-tanstack-table-hover-color: var(--pf-gray-color-200);
1971
+ --pf-tanstack-table-disabled-color: var(--pf-gray-color-300);
1972
+ --pf-tanstack-table-checked-color: var(--pf-secondary-color-950);
1973
+ --pf-tanstack-table-clicked-color: var(--pf-secondary-color-100);
1974
+ --pf-tanstack-table-highlighted-color: var(--pf-gray-color-200);
1975
+ --pf-tanstack-table-highlighted-box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2),
1976
+ 0 8px 16px rgba(0, 0, 0, 0.2);
1977
+ --pf-tanstack-table-font-size: var(--pf-font-size-body2);
1978
+ }
1979
+
1980
+ :root [data-theme=dark],
1981
+ :root {
1982
+ --pf-tanstack-table-background-color: var(--pf-primary-color-800);
1983
+ --pf-tanstack-table-font-color: var(--pf-white-color);
1984
+ --pf-tanstack-table-border-color: var(--pf-tertiary-color-800);
1985
+ --pf-tanstack-table-stripe-color: var(--pf-primary-color-700);
1986
+ --pf-tanstack-table-hover-color: var(--pf-primary-color-600);
1987
+ --pf-tanstack-table-disabled-color: var(--pf-gray-color-900);
1988
+ --pf-tanstack-table-disabled-button-color: var(--pf-primary-color-100);
1989
+ --pf-tanstack-table-checked-color: var(--pf-secondary-color-950);
1990
+ --pf-tanstack-table-clicked-color: var(--pf-primary-color);
1991
+ --pf-tanstack-table-highlighted-color: var(--pf-primary-color);
1992
+ --pf-tanstack-table-highlighted-box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4),
1993
+ 0 8px 16px rgba(0, 0, 0, 0.3);
1994
+ --pf-tanstack-table-font-size: var(--pf-font-size-body2);
1995
+ --pf-tanstack-table-pagination-background-color: var(--pf-primary-color-700);
1996
+ }
1997
+
1998
+ .tanstack-table__action-bar-test {
1999
+ left: 20% !important;
2000
+ }
2001
+
2002
+ .tanstack-table__action-bar-docs {
2003
+ bottom: unset !important;
2004
+ top: 50% !important;
2005
+ transform: translate(-50%, -50%) !important;
2006
+ }
2007
+
2008
+ .tanstack-table__column.is-pinned {
2009
+ opacity: 1;
2010
+ }
2011
+ .tanstack-table__column.is-not-pinned {
2012
+ opacity: 0.3;
2013
+ }
2014
+
2015
+ .tanstack-table__action-bar {
2016
+ position: fixed;
2017
+ bottom: 170px;
2018
+ left: 50%;
2019
+ transform: translateX(-50%);
2020
+ z-index: 90;
2021
+ box-shadow: 3px 1px 15px 0 rgba(0, 0, 0, 0.85);
2022
+ }
2023
+ .tanstack-table__action-bar__container {
2024
+ display: flex;
2025
+ align-items: center;
2026
+ gap: var(--pf-size-2);
2027
+ }
2028
+ .tanstack-table__action-bar__text-container {
2029
+ padding: var(--pf-padding-2);
2030
+ }
2031
+ .tanstack-table__action-bar__text-container span {
2032
+ font-size: var(--pf-font-size-base);
2033
+ font-weight: var(--pf-font-weight-medium);
2034
+ line-height: var(--pf-line-height-lg);
2035
+ color: var(--pf-white-color);
2036
+ }
2037
+ .tanstack-table__action-bar__button-container {
2038
+ display: flex;
2039
+ align-items: center;
2040
+ gap: var(--pf-size-4);
2041
+ }
2042
+
2043
+ .tanstack-table__no-results {
2044
+ display: flex;
2045
+ justify-content: center;
2046
+ flex-direction: column;
2047
+ align-items: center;
2048
+ position: sticky;
2049
+ left: 0;
2050
+ margin: var(--pf-margin-8) auto;
2051
+ }
2052
+ .tanstack-table__no-results__text {
2053
+ font-size: var(--pf-line-height-md);
2054
+ font-weight: var(--pf-font-weight-medium);
2055
+ color: var(--pf-primary-color-50);
2056
+ }
2057
+ .tanstack-table__no-results__text span {
2058
+ color: var(--pf-white-color);
2059
+ cursor: pointer;
2060
+ }
2061
+ .tanstack-table__no-results__text span:hover {
2062
+ text-decoration: underline;
2063
+ }
2064
+
2065
+ .tanstack-table__outer-container .tanstack-table__column--is-pinned {
2066
+ opacity: 1;
2067
+ }
2068
+ .tanstack-table__outer-container .tanstack-table__column--is-not-pinned {
2069
+ opacity: 0.3;
2070
+ }
2071
+ .tanstack-table__outer-container .tanstack-table__container {
2072
+ height: calc(100vh - 70px);
2073
+ grid-template-rows: auto 1fr auto;
2074
+ grid-template-columns: 1fr;
2075
+ display: grid;
2076
+ grid-template-rows: auto 1fr auto;
2077
+ grid-template-columns: 1fr;
2078
+ overflow-x: auto;
2079
+ overflow-y: auto;
2080
+ background-color: var(--pf-tanstack-table-background-color);
2081
+ border-radius: var(--pf-rounded-lg);
2082
+ border-left: var(--pf-border-sm) solid var(--pf-tanstack-table-border-color);
2083
+ border-right: var(--pf-border-sm) solid var(--pf-tanstack-table-border-color);
2084
+ border-bottom: var(--pf-border-sm) solid var(--pf-tanstack-table-border-color);
2085
+ scrollbar-width: thin;
2086
+ scrollbar-color: var(--pf-tanstack-table-border-color) var(--pf-tanstack-table-background-color);
2087
+ }
2088
+ .tanstack-table__outer-container .tanstack-table__container::-webkit-scrollbar {
2089
+ width: var(--pf-size-2);
2090
+ height: var(--pf-size-2);
2091
+ cursor: pointer;
2092
+ }
2093
+ .tanstack-table__outer-container .tanstack-table__container::-webkit-scrollbar-track {
2094
+ background: var(--pf-tanstack-table-background-color);
2095
+ border-radius: var(--pf-rounded);
2096
+ cursor: pointer;
2097
+ }
2098
+ .tanstack-table__outer-container .tanstack-table__container::-webkit-scrollbar-thumb {
2099
+ background: var(--pf-tanstack-table-border-color);
2100
+ border-radius: var(--pf-rounded);
2101
+ cursor: pointer;
2102
+ }
2103
+ .tanstack-table__outer-container .tanstack-table__container::-webkit-scrollbar-thumb:hover {
2104
+ background: var(--pf-primary-color);
2105
+ }
2106
+
2107
+ .tanstack-table {
2108
+ border-collapse: separate;
2109
+ margin: 0;
2110
+ table-layout: auto;
2111
+ border-spacing: 0;
2112
+ border-radius: var(--pf-rounded-lg);
2113
+ width: 100%;
2114
+ }
2115
+ .tanstack-table.is-loading {
2116
+ border: var(--pf-border-thin) solid var(--pf-border-color);
2117
+ height: 100%;
2118
+ width: 100%;
2119
+ }
2120
+ .tanstack-table__thead {
2121
+ position: sticky;
2122
+ top: 0;
2123
+ z-index: 3;
2124
+ box-sizing: border-box;
2125
+ background-color: var(--pf-tanstack-table-background-color);
2126
+ }
2127
+ .tanstack-table__thead tr:first-child th:first-child {
2128
+ border-left: none;
2129
+ }
2130
+ .tanstack-table__thead tr:first-child th:last-child {
2131
+ border-right: none;
2132
+ }
2133
+ .tanstack-table__thead__th {
2134
+ color: var(--pf-tanstack-table-font-color);
2135
+ background: var(--pf-tanstack-table-background-color);
2136
+ font-size: var(--pf-tanstack-table-font-size);
2137
+ font-weight: var(--pf-font-weight-medium);
2138
+ box-sizing: border-box;
2139
+ border-top: var(--pf-border-sm) solid var(--pf-tanstack-table-border-color);
2140
+ border-bottom: var(--pf-border-sm) solid var(--pf-tanstack-table-border-color);
2141
+ border-right: var(--pf-border-sm) solid var(--pf-tanstack-table-border-color);
2142
+ -webkit-user-select: none;
2143
+ -moz-user-select: none;
2144
+ user-select: none;
2145
+ overflow: hidden;
2146
+ text-overflow: ellipsis;
2147
+ white-space: nowrap;
2148
+ max-width: 300px;
2149
+ width: auto;
2150
+ padding: 0 var(--pf-padding-2);
2151
+ text-align: left;
2152
+ }
2153
+ .tanstack-table__thead__th:first-child {
2154
+ border-left: none;
2155
+ }
2156
+ .tanstack-table__thead__th:last-child {
2157
+ border-right: none;
2158
+ }
2159
+ .tanstack-table__tbody tr:last-child {
2160
+ border-bottom: none;
2161
+ }
2162
+ .tanstack-table__tbody__tr {
2163
+ background: transparent;
2164
+ width: 100%;
2165
+ border-left: none;
2166
+ border-right: none;
2167
+ }
2168
+ .tanstack-table__tbody__tr.is-selected td {
2169
+ background: var(--pf-tanstack-table-checked-color);
2170
+ }
2171
+ .tanstack-table__tbody__tr.show-hover:hover td {
2172
+ background-color: var(--pf-tanstack-table-hover-color);
2173
+ cursor: pointer;
2174
+ }
2175
+ .tanstack-table__tbody__tr.is-clicked td {
2176
+ background-color: var(--pf-tanstack-table-clicked-color);
2177
+ }
2178
+ .tanstack-table__tbody__td {
2179
+ font-size: var(--pf-font-size-base);
2180
+ font-weight: var(--pf-font-weight-medium);
2181
+ color: var(--pf-tanstack-table-font-color);
2182
+ background: var(--pf-tanstack-table-background-color);
2183
+ border-right: var(--pf-border-sm) solid var(--pf-tanstack-table-border-color);
2184
+ border-bottom: var(--pf-border-sm) solid var(--pf-tanstack-table-border-color);
2185
+ box-sizing: border-box;
2186
+ overflow: hidden;
2187
+ text-overflow: ellipsis;
2188
+ white-space: nowrap;
2189
+ padding: 0 var(--pf-padding-2);
2190
+ max-width: 300px;
2191
+ width: auto;
2192
+ text-align: left;
2193
+ }
2194
+ .tanstack-table__tbody__td:first-child {
2195
+ border-left: none;
2196
+ }
2197
+ .tanstack-table__tbody__td:last-child {
2198
+ border-right: none;
2199
+ }
2200
+ .tanstack-table__centered-row {
2201
+ padding: var(--pf-padding-1) var(--pf-padding-2);
2202
+ text-align: center;
2203
+ vertical-align: middle;
2204
+ height: 100%;
2205
+ border: var(--pf-border-sm) solid var(--pf-border-color);
2206
+ animation: none;
2207
+ }
2208
+ @keyframes shimmer {
2209
+ 0% {
2210
+ background-color: var(--pf-primary-color-700) 40;
2211
+ }
2212
+ 50% {
2213
+ background-color: var(--pf-primary-color-700);
2214
+ }
2215
+ 100% {
2216
+ background-color: var(--pf-primary-color-700) 40;
2217
+ }
2218
+ }
2219
+ .tanstack-table__centered-row.is-loading {
2220
+ animation: shimmer 3s ease-in-out infinite;
2221
+ }
2222
+ .tanstack-table__centered-row svg {
2223
+ margin: 0 auto;
2224
+ display: block;
2225
+ }
2226
+
1965
2227
  :root [data-theme=light] {
1966
2228
  --pf-pill-primary-background-color: var(--pf-primary-color);
1967
2229
  --pf-pill-primary-font-color: var(--pf-white-color);
package/lib/index.d.ts CHANGED
@@ -6,8 +6,9 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
6
6
  import { ContainerProps, RowProps, ColProps } from 'react-grid-system';
7
7
  import { IDataTableProps, Direction as Direction$1, TableColumn as TableColumn$1 } from 'react-data-table-component';
8
8
  import { CSSObject } from 'styled-components';
9
- import { Props as Props$7 } from 'react-select';
9
+ import { Props as Props$8 } from 'react-select';
10
10
  import { DateRange, OnSelectHandler, Mode, CustomComponents, Matcher, Formatters, MonthChangeEventHandler, DayEventHandler } from 'react-day-picker';
11
+ import { ColumnDef, Row as Row$1 } from '@tanstack/react-table';
11
12
 
12
13
  declare const registerFontAwesomeIcons: (...icons: IconDefinition[]) => void;
13
14
 
@@ -222,28 +223,28 @@ type PermafrostComponent = {
222
223
 
223
224
  type SemanticColor = 'primary' | 'secondary' | 'warning' | 'error' | 'success' | 'info' | 'pending';
224
225
 
225
- type Props$6 = PermafrostComponent & {
226
+ type Props$7 = PermafrostComponent & {
226
227
  ariaLabel?: string;
227
228
  size?: IconSizes;
228
229
  style?: React$1.CSSProperties;
229
230
  fill?: string;
230
231
  };
231
- declare function CircleSpinner(props: Props$6): React$1.ReactElement;
232
+ declare function CircleSpinner(props: Props$7): React$1.ReactElement;
232
233
 
233
- type Props$5 = PermafrostComponent & {
234
+ type Props$6 = PermafrostComponent & {
234
235
  width?: string;
235
236
  };
236
- declare function BarSpinner(props: Props$5): React$1.ReactElement;
237
+ declare function BarSpinner(props: Props$6): React$1.ReactElement;
237
238
 
238
- type Props$4 = PermafrostComponent & {
239
+ type Props$5 = PermafrostComponent & {
239
240
  color?: string;
240
241
  overallSize?: string | number;
241
242
  rippleSize?: string | number;
242
243
  showRandomMessage?: boolean;
243
244
  };
244
- declare function CirclePulse(props: Props$4): React$1.ReactElement;
245
+ declare function CirclePulse(props: Props$5): React$1.ReactElement;
245
246
 
246
- type Props$3 = PermafrostComponent & {
247
+ type Props$4 = PermafrostComponent & {
247
248
  questionMark?: boolean;
248
249
  for?: string | null;
249
250
  place?: string;
@@ -254,7 +255,7 @@ type Props$3 = PermafrostComponent & {
254
255
  children: React$1.ReactNode;
255
256
  block?: boolean;
256
257
  };
257
- declare const Tooltip: (props: Props$3) => react_jsx_runtime.JSX.Element;
258
+ declare const Tooltip: (props: Props$4) => react_jsx_runtime.JSX.Element;
258
259
 
259
260
  declare const Container: ({ ref: _ref, ...rest }: ContainerProps) => react_jsx_runtime.JSX.Element;
260
261
 
@@ -390,7 +391,7 @@ interface PasswordInputProps extends LabelProps {
390
391
  }
391
392
  declare const LabeledPasswordInput: React$1.ForwardRefExoticComponent<Omit<Omit<PasswordInputProps, "ref"> & React$1.RefAttributes<HTMLInputElement> & LabelProps, "ref"> & React$1.RefAttributes<any>>;
392
393
 
393
- interface SelectProps<OptionType extends SelectOption> extends Props$7<OptionType> {
394
+ interface SelectProps<OptionType extends SelectOption> extends Props$8<OptionType> {
394
395
  options: OptionType[];
395
396
  }
396
397
  declare const Select: <OptionType extends SelectOption>({ classNamePrefix, className, components: customComponents, ...props }: SelectProps<OptionType>) => react_jsx_runtime.JSX.Element;
@@ -424,7 +425,7 @@ interface DatePickerProps {
424
425
 
425
426
  declare const DatePicker: (props: DatePickerProps) => react_jsx_runtime.JSX.Element;
426
427
 
427
- interface Props$2 {
428
+ interface Props$3 {
428
429
  mode?: Mode;
429
430
  ariaLabel: string;
430
431
  disableBeforeDate?: Date;
@@ -442,7 +443,7 @@ interface Props$2 {
442
443
  initialMonth?: Date;
443
444
  'data-testid'?: string;
444
445
  }
445
- declare const IconTriggerDatePicker: (props: Props$2) => react_jsx_runtime.JSX.Element;
446
+ declare const IconTriggerDatePicker: (props: Props$3) => react_jsx_runtime.JSX.Element;
446
447
 
447
448
  interface SingleInputDatePickerProps {
448
449
  ariaLabel: string;
@@ -480,23 +481,23 @@ interface FormProps {
480
481
  }
481
482
  declare const Form: ({ children, onSubmit, action, method, target, autocomplete, noValidate, enctype, rel, ...rest }: FormProps) => react_jsx_runtime.JSX.Element;
482
483
 
483
- type Props$1 = {
484
+ type Props$2 = {
484
485
  className?: string;
485
486
  height?: number | string;
486
487
  width?: number | string;
487
488
  isCircle?: boolean;
488
489
  isFullHeight?: boolean;
489
490
  };
490
- declare const Skeleton: ({ className, height, width, isCircle, isFullHeight, ...rest }: Props$1) => react_jsx_runtime.JSX.Element;
491
+ declare const Skeleton: ({ className, height, width, isCircle, isFullHeight, ...rest }: Props$2) => react_jsx_runtime.JSX.Element;
491
492
 
492
- type Props = {
493
+ type Props$1 = {
493
494
  className?: string;
494
495
  children: React$1.ReactNode;
495
496
  title?: string;
496
497
  subtitle?: string;
497
498
  hasBoxShadow?: boolean;
498
499
  };
499
- declare const Card: React$1.FC<Props>;
500
+ declare const Card: React$1.FC<Props$1>;
500
501
 
501
502
  type FloatUIProps = {
502
503
  children: [ReactElement, ReactElement];
@@ -549,4 +550,53 @@ interface ModalProps {
549
550
 
550
551
  declare const Modal: ({ className, children, isOpen, onRequestClose, portalClassName, overlayClassName, appElement, shouldCloseOnOverlayClick, shouldCloseOnEsc, testId, contentElement, overlayElement, position, parentSelector, ...rest }: ModalProps) => react_jsx_runtime.JSX.Element;
551
552
 
552
- export { Badge, BarSpinner, Button, Card, Checkbox, CirclePulse, CircleSpinner, Col, Container, DatePicker, FloatUI, Form, Icon, IconTriggerDatePicker, LabeledInput as Input, Menu, Modal, LabeledPasswordInput as PasswordInput, Pill, Radio as RadioInput, Row, Select as SelectInput, SingleInputDatePicker, Skeleton, Table, LabeledTextarea as Textarea, Toggle as ToggleInput, Tooltip, registerFontAwesomeIcons };
553
+ type WithPaginationProps = {
554
+ rowsPerPage: number;
555
+ rowCount: number;
556
+ onChangePage: (page: number) => void;
557
+ currentPage: number;
558
+ totalEntriesText?: string;
559
+ showPagination: true;
560
+ };
561
+ type WithoutPaginationProps = {
562
+ rowsPerPage?: number;
563
+ rowCount?: number;
564
+ onChangePage?: (page: number) => void;
565
+ currentPage?: number;
566
+ totalEntriesText?: string;
567
+ showPagination?: false;
568
+ };
569
+ type PaginationProps = WithPaginationProps | WithoutPaginationProps;
570
+ type Props<T extends object> = {
571
+ data: T[];
572
+ columns: ColumnDef<T & {
573
+ id: string;
574
+ }>[];
575
+ className?: string;
576
+ actionBarClassName?: string;
577
+ TableActions?: React.ComponentType<{
578
+ selectedItems: Row$1<any>[];
579
+ unselectRows: () => void;
580
+ }>;
581
+ error?: {
582
+ hasError: boolean;
583
+ errorMessage?: string;
584
+ };
585
+ enableRowSelection?: boolean | ((row: Row$1<T>) => boolean);
586
+ clearFilters?: () => void;
587
+ hasFilters?: boolean;
588
+ isLoading?: boolean;
589
+ defaultPinnedColumns?: string[];
590
+ onClickRow?: ((row: Row$1<T>) => void) | null;
591
+ onRowClick?: (row: T) => void;
592
+ activeRows?: string[];
593
+ rowSelection?: Record<string, boolean>;
594
+ onRowSelectionChange?: (updater: Record<string, boolean>) => void;
595
+ onSelectAllChange?: (isSelected: boolean) => void;
596
+ } & PaginationProps;
597
+
598
+ declare function TanstackTable<T extends object>({ columns: defaultColumns, data, className, currentPage, rowCount, rowsPerPage, onChangePage, totalEntriesText, TableActions, error, enableRowSelection, clearFilters, hasFilters, showPagination, isLoading, defaultPinnedColumns, onRowClick, activeRows, actionBarClassName, ...rest }: Props<T & {
599
+ id: string;
600
+ }>): react_jsx_runtime.JSX.Element;
601
+
602
+ export { Badge, BarSpinner, Button, Card, Checkbox, CirclePulse, CircleSpinner, Col, Container, DatePicker, FloatUI, Form, Icon, IconTriggerDatePicker, LabeledInput as Input, Menu, Modal, LabeledPasswordInput as PasswordInput, Pill, Radio as RadioInput, Row, Select as SelectInput, SingleInputDatePicker, Skeleton, Table, TanstackTable, LabeledTextarea as Textarea, Toggle as ToggleInput, Tooltip, registerFontAwesomeIcons };