Skip to content

Commit 6611277

Browse files
authored
bug(TS): Update deps to latest versions: (#1524)
1 parent aa90a27 commit 6611277

File tree

10 files changed

+162
-251
lines changed

10 files changed

+162
-251
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
4747

4848
* Fixed #1440: When a Shiny Express app with a `www/` subdirectory was deployed to shinyapps.io or a Connect server, it would not start correctly. (#1442)
4949

50+
* Fixed #1498: Update table related TypeScript dependencies to their latest versions. This fixed an issue where the Row Virtualizer would scroll to the end when hidden. This would cause the DOM to update numerous times, locking up the browser tab for multiple seconds. #1524
51+
5052
* The return type for the data frame patch function now returns a list of `render.CellPatch` objects (which support `htmltools.TagNode` for the `value` attribute). These values will be set inside the data frame's `.data_view()` result. This also means that `.cell_patches()` will be a list of `render.CellPatch` objects. (#1526)
5153

5254
### Other changes

js/data-frame/filter.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import {
2+
ColumnFiltersOptions,
23
ColumnFiltersState,
34
FilterMeta,
4-
FiltersOptions,
55
Header,
66
Row,
77
getFacetedMinMaxValues,
@@ -25,7 +25,7 @@ export function useFilters<TData>(enabled: boolean | undefined): {
2525
columnFilters: ColumnFiltersState;
2626
setColumnFilters: React.Dispatch<React.SetStateAction<ColumnFiltersState>>;
2727
columnFiltersState: { columnFilters: ColumnFiltersState };
28-
filtersTableOptions: FiltersOptions<TData>;
28+
filtersTableOptions: ColumnFiltersOptions<TData>;
2929
} {
3030
const [columnFilters, setColumnFilters] = useState<ColumnFiltersState>([]); // can set initial column filter state here
3131

js/data-frame/index.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,10 +278,11 @@ const ShinyDataGrid: FC<ShinyDataGridProps<unknown>> = ({
278278
count: table.getFilteredRowModel().rows.length,
279279
getScrollElement: () => containerRef.current,
280280
estimateSize: () => 31,
281+
overscan: 15,
281282
paddingStart: theadRef.current?.clientHeight ?? 0,
282283
// In response to https://github.com/posit-dev/py-shiny/pull/538/files#r1228352446
283284
// (the default scrollingDelay is 150)
284-
scrollingDelay: 10,
285+
isScrollingResetDelay: 10,
285286
});
286287

287288
// Reset scroll when dataset changes

js/data-frame/table-summary.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import React, { useMemo } from "react";
1313
export function useSummary(
1414
summaryTemplate: string | boolean | undefined,
1515
scrollContainer: HTMLElement | null,
16-
virtualRows: VirtualItem[],
16+
virtualRows: VirtualItem<Element>[],
1717
thead: HTMLTableSectionElement | null,
1818
nrows: number
1919
): JSX.Element | null {

0 commit comments

Comments
 (0)