@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.
- package/lib/components/tanstackTable/TankstackTable.types.d.ts +45 -0
- package/lib/components/tanstackTable/TanstackTable.stories.d.ts +16 -0
- package/lib/components/tanstackTable/TanstakTable.d.ts +4 -0
- package/lib/components/tanstackTable/__tests__/TanstackTable.test.d.ts +1 -0
- package/lib/components/tanstackTable/__tests__/__mocks__/test-mock-data.d.ts +8 -0
- package/lib/components/tanstackTable/components/ActionBar/ActionBar.d.ts +17 -0
- package/lib/components/tanstackTable/components/ActionBar/ActionBar.stories.d.ts +10 -0
- package/lib/components/tanstackTable/components/ActionBar/__tests__/ActionBar.test.d.ts +1 -0
- package/lib/components/tanstackTable/components/ActionBar/index.d.ts +1 -0
- package/lib/components/tanstackTable/components/NoResults/NoResults.d.ts +7 -0
- package/lib/components/tanstackTable/components/NoResults/__tests__/NoResult.test.d.ts +1 -0
- package/lib/components/tanstackTable/components/NoResults/index.d.ts +1 -0
- package/lib/components/tanstackTable/components/TableBody/TableBody.d.ts +11 -0
- package/lib/components/tanstackTable/components/TableBody/index.d.ts +1 -0
- package/lib/components/tanstackTable/components/TableHeader/TableHeader.d.ts +6 -0
- package/lib/components/tanstackTable/components/TableHeader/index.d.ts +1 -0
- package/lib/components/tanstackTable/components/TablePagination/TablePagination.d.ts +9 -0
- package/lib/components/tanstackTable/components/TablePagination/__tests__/TablePagination.test.d.ts +1 -0
- package/lib/components/tanstackTable/components/TablePagination/index.d.ts +1 -0
- package/lib/components/tanstackTable/docs/pinnedColumns/PinnedColumn.stories.d.ts +7 -0
- package/lib/components/tanstackTable/docs/withRowClick/WithRowClick.stories.d.ts +7 -0
- package/lib/components/tanstackTable/helpers.d.ts +830 -0
- package/lib/components/tanstackTable/index.d.ts +2 -0
- package/lib/components/tanstackTable/mock-data/mock-data.d.ts +14 -0
- package/lib/components/tanstackTable/mock-data/table-configuration.d.ts +3 -0
- package/lib/components/tanstackTable/useTanstackTable.d.ts +14 -0
- package/lib/index.css +262 -0
- package/lib/index.d.ts +67 -17
- package/lib/index.esm.css +262 -0
- package/lib/index.esm.js +20432 -56
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +20432 -55
- package/lib/index.js.map +1 -1
- package/package.json +2 -1
- package/src/components/tanstackTable/TankstackTable.types.ts +44 -0
- package/src/components/tanstackTable/TanstackTable.mdx +122 -0
- package/src/components/tanstackTable/TanstackTable.stories.tsx +284 -0
- package/src/components/tanstackTable/TanstakTable.tsx +156 -0
- package/src/components/tanstackTable/__tests__/TanstackTable.test.tsx +73 -0
- package/src/components/tanstackTable/__tests__/__mocks__/test-mock-data.tsx +83 -0
- package/src/components/tanstackTable/components/ActionBar/ActionBar.mdx +10 -0
- package/src/components/tanstackTable/components/ActionBar/ActionBar.scss +30 -0
- package/src/components/tanstackTable/components/ActionBar/ActionBar.stories.tsx +98 -0
- package/src/components/tanstackTable/components/ActionBar/ActionBar.tsx +43 -0
- package/src/components/tanstackTable/components/ActionBar/__tests__/ActionBar.test.tsx +65 -0
- package/src/components/tanstackTable/components/ActionBar/index.ts +1 -0
- package/src/components/tanstackTable/components/NoResults/NoResults.scss +24 -0
- package/src/components/tanstackTable/components/NoResults/NoResults.tsx +22 -0
- package/src/components/tanstackTable/components/NoResults/__tests__/NoResult.test.tsx +25 -0
- package/src/components/tanstackTable/components/NoResults/index.ts +1 -0
- package/src/components/tanstackTable/components/TableBody/TableBody.tsx +77 -0
- package/src/components/tanstackTable/components/TableBody/index.ts +1 -0
- package/src/components/tanstackTable/components/TableHeader/TableHeader.tsx +49 -0
- package/src/components/tanstackTable/components/TableHeader/index.ts +1 -0
- package/src/components/tanstackTable/components/TablePagination/TablePagination.tsx +45 -0
- package/src/components/tanstackTable/components/TablePagination/__tests__/TablePagination.test.tsx +18 -0
- package/src/components/tanstackTable/components/TablePagination/index.ts +1 -0
- package/src/components/tanstackTable/docs/pinnedColumns/PinnedColumn.mdx +34 -0
- package/src/components/tanstackTable/docs/pinnedColumns/PinnedColumn.stories.tsx +40 -0
- package/src/components/tanstackTable/docs/withRowClick/WithRowClick.mdx +48 -0
- package/src/components/tanstackTable/docs/withRowClick/WithRowClick.stories.tsx +32 -0
- package/src/components/tanstackTable/helpers.ts +45 -0
- package/src/components/tanstackTable/index.ts +2 -0
- package/src/components/tanstackTable/mock-data/mock-data.ts +256 -0
- package/src/components/tanstackTable/mock-data/table-configuration.tsx +222 -0
- package/src/components/tanstackTable/styles/_variables.scss +35 -0
- package/src/components/tanstackTable/styles/table.scss +218 -0
- package/src/components/tanstackTable/styles/test.scss +19 -0
- package/src/components/tanstackTable/tanstack-table.d.ts +19 -0
- package/src/components/tanstackTable/useTanstackTable.tsx +39 -0
- package/src/index.ts +1 -0
- package/src/legacy/components/loading-indicators/CirclePulse/CirclePulse.tsx +1 -0
- package/src/styles/index.scss +1 -0
- package/src/stylesAndAnimations/utilityClasses/UtilityClassesTable.tsx +16 -2
package/lib/index.esm.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);
|