@ledgerhq/react-ui 0.24.0-nightly.2 → 0.24.0-nightly.3

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.
@@ -32,23 +32,63 @@ __export(VirtualList_exports, {
32
32
  });
33
33
  module.exports = __toCommonJS(VirtualList_exports);
34
34
  var import_react = __toESM(require("react"));
35
- var import_react_window = require("react-window");
36
- var import_react_virtualized_auto_sizer = __toESM(require("react-virtualized-auto-sizer"));
35
+ var import_react_virtual = require("@tanstack/react-virtual");
36
+ var import_components = require("../../../components");
37
+ const DefaultLoadingComponent = () => /* @__PURE__ */ import_react.default.createElement(import_components.Flex, { justifyContent: "center", alignItems: "center", height: "76px" }, /* @__PURE__ */ import_react.default.createElement(import_components.InfiniteLoader, null));
37
38
  const VirtualList = ({
38
39
  count,
39
40
  itemHeight,
41
+ overscan = 5,
42
+ LoadingComponent,
43
+ isLoading,
44
+ hasNextPage = false,
45
+ threshold = 5,
46
+ onVisibleItemsScrollEnd,
40
47
  renderItem
41
48
  }) => {
42
- return /* @__PURE__ */ import_react.default.createElement(import_react_virtualized_auto_sizer.default, { style: { height: "100%", width: "100%" } }, ({ height }) => /* @__PURE__ */ import_react.default.createElement(
43
- import_react_window.FixedSizeList,
49
+ const parentRef = (0, import_react.useRef)(null);
50
+ const rowVirtualizer = (0, import_react_virtual.useVirtualizer)({
51
+ count: hasNextPage ? count + 1 : count,
52
+ getScrollElement: () => parentRef.current,
53
+ estimateSize: () => itemHeight,
54
+ overscan
55
+ });
56
+ (0, import_react.useEffect)(() => {
57
+ const items = rowVirtualizer.getVirtualItems();
58
+ if (!items.length)
59
+ return;
60
+ const lastItem = items[items.length - 1];
61
+ if (lastItem.index >= count - 1 - threshold && hasNextPage && !isLoading && onVisibleItemsScrollEnd) {
62
+ onVisibleItemsScrollEnd();
63
+ }
64
+ }, [hasNextPage, onVisibleItemsScrollEnd, count, isLoading, rowVirtualizer.getVirtualItems()]);
65
+ const showCustomLoadingComponent = !!LoadingComponent;
66
+ return /* @__PURE__ */ import_react.default.createElement("div", { ref: parentRef, style: { width: "100%", height: "100%", overflow: "auto" } }, /* @__PURE__ */ import_react.default.createElement(
67
+ "div",
44
68
  {
45
- height,
46
- itemCount: count,
47
- itemSize: itemHeight,
48
- layout: "vertical",
49
- width: "100%"
69
+ style: {
70
+ height: `${rowVirtualizer.getTotalSize()}px`,
71
+ width: "100%",
72
+ position: "relative"
73
+ }
50
74
  },
51
- ({ index, style }) => /* @__PURE__ */ import_react.default.createElement("div", { style }, renderItem(index))
52
- ));
75
+ rowVirtualizer.getVirtualItems().map((virtualRow) => /* @__PURE__ */ import_react.default.createElement(
76
+ "div",
77
+ {
78
+ key: virtualRow.index,
79
+ "data-index": virtualRow.index,
80
+ ref: rowVirtualizer.measureElement,
81
+ style: {
82
+ position: "absolute",
83
+ top: 0,
84
+ left: 0,
85
+ transform: `translateY(${virtualRow.start}px)`,
86
+ height: `${itemHeight}px`,
87
+ width: "100%"
88
+ }
89
+ },
90
+ renderItem(virtualRow.index)
91
+ ))
92
+ ), isLoading && (showCustomLoadingComponent ? LoadingComponent : /* @__PURE__ */ import_react.default.createElement(DefaultLoadingComponent, null)));
53
93
  };
54
94
  //# sourceMappingURL=VirtualList.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/pre-ldls/components/VirtualList/VirtualList.tsx"],
4
- "sourcesContent": ["import React, { ReactNode } from \"react\";\nimport { FixedSizeList as List } from \"react-window\";\nimport AutoSizer from \"react-virtualized-auto-sizer\";\n\nexport const VirtualList = ({\n count,\n itemHeight,\n renderItem,\n}: {\n count: number;\n itemHeight: number;\n renderItem: (index: number) => ReactNode;\n}) => {\n return (\n <AutoSizer style={{ height: \"100%\", width: \"100%\" }}>\n {({ height }: { height: number }) => (\n <List\n height={height}\n itemCount={count}\n itemSize={itemHeight}\n layout=\"vertical\"\n width=\"100%\"\n >\n {({ index, style }) => <div style={style}>{renderItem(index)}</div>}\n </List>\n )}\n </AutoSizer>\n );\n};\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAiC;AACjC,0BAAsC;AACtC,0CAAsB;AAEf,MAAM,cAAc,CAAC;AAAA,EAC1B;AAAA,EACA;AAAA,EACA;AACF,MAIM;AACJ,SACE,6BAAAA,QAAA,cAAC,oCAAAC,SAAA,EAAU,OAAO,EAAE,QAAQ,QAAQ,OAAO,OAAO,KAC/C,CAAC,EAAE,OAAO,MACT,6BAAAD,QAAA;AAAA,IAAC,oBAAAE;AAAA,IAAA;AAAA,MACC;AAAA,MACA,WAAW;AAAA,MACX,UAAU;AAAA,MACV,QAAO;AAAA,MACP,OAAM;AAAA;AAAA,IAEL,CAAC,EAAE,OAAO,MAAM,MAAM,6BAAAF,QAAA,cAAC,SAAI,SAAe,WAAW,KAAK,CAAE;AAAA,EAC/D,CAEJ;AAEJ;",
6
- "names": ["React", "AutoSizer", "List"]
4
+ "sourcesContent": ["import React, { useEffect, useRef } from \"react\";\nimport { useVirtualizer } from \"@tanstack/react-virtual\";\nimport { Flex, InfiniteLoader } from \"../../../components\";\n\ninterface VirtualItem {\n key: string | number | bigint;\n index: number;\n start: number;\n end: number;\n size: number;\n}\n\n/**\n * Props for the VirtualList component, which efficiently renders large lists\n * by virtualizing DOM nodes to improve performance.\n */\ntype VirtualListProps = {\n /**\n * Total number of items in the list.\n * This is used to calculate the total height of the list.\n */\n count: number;\n /**\n * Height of each item in the list.\n * This is used to calculate the total height of the list and the position of each item.\n */\n itemHeight: number;\n /**\n * Number of extra items to render outside the visible viewport for smoother scrolling.\n * Defaults to 5.\n */\n overscan?: number;\n /**\n * React component or node to display when the list is loading additional items.\n * If not provided, a default loading spinner will be used.\n */\n LoadingComponent?: React.ReactNode;\n /**\n * Indicates whether new items are currently being loaded.\n */\n isLoading?: boolean;\n /**\n * Indicates if there are more items to load.\n */\n hasNextPage?: boolean;\n /**\n * Number of items to check before the end of the list to trigger loading more items.\n * Defaults to 5.\n */\n threshold?: number;\n /**\n * Callback function to be called when the user scrolls to the end of the visible items.\n * This can be used to load more items when the user reaches the end of the list.\n */\n onVisibleItemsScrollEnd?: () => void;\n /**\n * Function to render each item in the list.\n * Receives the index of the item as an argument and should return a React node.\n */\n renderItem: (index: number) => React.ReactNode;\n};\n\nconst DefaultLoadingComponent = () => (\n <Flex justifyContent=\"center\" alignItems=\"center\" height=\"76px\">\n <InfiniteLoader />\n </Flex>\n);\n\nexport const VirtualList = ({\n count,\n itemHeight,\n overscan = 5,\n LoadingComponent,\n isLoading,\n hasNextPage = false,\n threshold = 5,\n onVisibleItemsScrollEnd,\n renderItem,\n}: VirtualListProps) => {\n const parentRef = useRef<HTMLDivElement>(null);\n\n const rowVirtualizer = useVirtualizer({\n count: hasNextPage ? count + 1 : count,\n getScrollElement: () => parentRef.current,\n estimateSize: () => itemHeight,\n overscan,\n });\n\n useEffect(() => {\n const items = rowVirtualizer.getVirtualItems();\n if (!items.length) return;\n const lastItem = items[items.length - 1];\n\n if (\n lastItem.index >= count - 1 - threshold &&\n hasNextPage &&\n !isLoading &&\n onVisibleItemsScrollEnd\n ) {\n onVisibleItemsScrollEnd();\n }\n }, [hasNextPage, onVisibleItemsScrollEnd, count, isLoading, rowVirtualizer.getVirtualItems()]);\n\n const showCustomLoadingComponent = !!LoadingComponent;\n\n return (\n <div ref={parentRef} style={{ width: \"100%\", height: \"100%\", overflow: \"auto\" }}>\n <div\n style={{\n height: `${rowVirtualizer.getTotalSize()}px`,\n width: \"100%\",\n position: \"relative\",\n }}\n >\n {rowVirtualizer.getVirtualItems().map((virtualRow: VirtualItem) => (\n <div\n key={virtualRow.index}\n data-index={virtualRow.index}\n ref={rowVirtualizer.measureElement}\n style={{\n position: \"absolute\",\n top: 0,\n left: 0,\n transform: `translateY(${virtualRow.start}px)`,\n height: `${itemHeight}px`,\n width: \"100%\",\n }}\n >\n {renderItem(virtualRow.index)}\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ACP,UAAU;AAAA,MACZ;AAAA;AAAA,IAEC,eAAe,gBAAgB,EAAE,IAAI,CAAC,eACrC,6BAAAA,QAAA;AAAA,MAAC;AAAA;AAAA,QACC,KAAK,WAAW;AAAA,QAChB,cAAY,WAAW;AAAA,QACvB,KAAK,eAAe;AAAA,QACpB,OAAO;AAAA,UACL,UAAU;AAAA,UACV,KAAK;AAAA,UACL,MAAM;AAAA,UACN,WAAW,cAAc,WAAW,KAAK;AAAA,UACzC,QAAQ,GAAG,UAAU;AAAA,UACrB,OAAO;AAAA,QACT;AAAA;AAAA,MAEC,WAAW,WAAW,KAAK;AAAA,IAC9B,CACD;AAAA,EACH,GACC,cAAc,6BAA6B,mBAAmB,6BAAAA,QAAA,cAAC,6BAAwB,EAC1F;AAEJ;",
6
+ "names": ["React"]
7
7
  }
@@ -30,11 +30,13 @@ var VirtualList_stories_exports = {};
30
30
  __export(VirtualList_stories_exports, {
31
31
  Default: () => Default,
32
32
  TestVirtualList: () => TestVirtualList,
33
+ WithPagination: () => WithPagination,
33
34
  default: () => VirtualList_stories_default
34
35
  });
35
36
  module.exports = __toCommonJS(VirtualList_stories_exports);
36
37
  var import_react = __toESM(require("react"));
37
38
  var import_VirtualList = require("./VirtualList");
39
+ var import_addon_actions = require("@storybook/addon-actions");
38
40
  var import_test = require("@storybook/test");
39
41
  const meta = {
40
42
  component: import_VirtualList.VirtualList,
@@ -43,28 +45,123 @@ const meta = {
43
45
  ],
44
46
  title: "PreLdls/Components/VirtualList",
45
47
  tags: ["autodocs"],
48
+ parameters: {
49
+ layout: "fullscreen",
50
+ docs: {
51
+ description: {
52
+ component: "A virtualized list component that renders only the visible items in a scrollable container using the `useVirtualizer` hook from `@tanstack/react-virtual`. It supports pagination and custom item rendering."
53
+ }
54
+ }
55
+ },
56
+ argTypes: {
57
+ count: {
58
+ description: "Total number of items in the list."
59
+ },
60
+ itemHeight: {
61
+ description: "Height of each item in the list."
62
+ },
63
+ overscan: {
64
+ description: "Number of extra items to render outside the visible viewport for smoother scrolling.",
65
+ table: {
66
+ defaultValue: {
67
+ summary: "5"
68
+ }
69
+ }
70
+ },
71
+ LoadingComponent: {
72
+ description: "React component or node to display when the list is loading additional items. If not provided, a default loading spinner will be used."
73
+ },
74
+ isLoading: {
75
+ description: "Indicates whether new items are currently being loaded."
76
+ },
77
+ hasNextPage: {
78
+ description: "Indicates if there are more items to load. If true, the list will trigger loading more items when scrolled to the end.",
79
+ defaultValue: {
80
+ summary: "false"
81
+ }
82
+ },
83
+ threshold: {
84
+ description: "Number of items to check before the end of the list to trigger loading more items.",
85
+ defaultValue: {
86
+ summary: "5"
87
+ }
88
+ },
89
+ onVisibleItemsScrollEnd: {
90
+ description: "Callback function to be called when the user scrolls to the end of the visible items. This can be used to load more items when the user reaches the end of the list."
91
+ },
92
+ renderItem: {
93
+ description: "Function to render each item in the list. Receives the index of the item as an argument and should return a React node."
94
+ }
95
+ },
46
96
  args: {
47
97
  itemHeight: 64,
48
98
  count: 50,
49
- renderItem: (i) => /* @__PURE__ */ import_react.default.createElement("h1", { tabIndex: i }, "Item #", i)
99
+ LoadingComponent: void 0,
100
+ isLoading: false,
101
+ overscan: 5,
102
+ hasNextPage: false,
103
+ threshold: 5,
104
+ onVisibleItemsScrollEnd: () => {
105
+ },
106
+ renderItem: (index) => /* @__PURE__ */ import_react.default.createElement("h1", { tabIndex: index }, "Item #", index)
50
107
  }
51
108
  };
52
109
  var VirtualList_stories_default = meta;
53
- const Default = {};
110
+ const Default = {
111
+ args: {
112
+ count: 20,
113
+ itemHeight: 50,
114
+ overscan: 5,
115
+ renderItem: (index) => /* @__PURE__ */ import_react.default.createElement("div", { style: { height: 50, backgroundColor: "lightblue", border: "1px solid black" } }, "Item ", index)
116
+ }
117
+ };
118
+ const WithPagination = {
119
+ render: (args) => {
120
+ const [items, setItems] = (0, import_react.useState)(Array.from({ length: args.count }, (_, i) => i));
121
+ const [isFetching, setIsFetching] = (0, import_react.useState)(false);
122
+ const handleFetchNextPage = async () => {
123
+ (0, import_addon_actions.action)("fetchNextPage")();
124
+ if (isFetching)
125
+ return;
126
+ setIsFetching(true);
127
+ await new Promise((resolve) => setTimeout(resolve, 1e3));
128
+ setItems((prev) => [...prev, ...Array.from({ length: 50 }, (_, i) => prev.length + i)]);
129
+ setIsFetching(false);
130
+ };
131
+ return /* @__PURE__ */ import_react.default.createElement(
132
+ import_VirtualList.VirtualList,
133
+ {
134
+ ...args,
135
+ count: items.length,
136
+ isLoading: isFetching,
137
+ onVisibleItemsScrollEnd: handleFetchNextPage,
138
+ hasNextPage: true,
139
+ renderItem: (index) => /* @__PURE__ */ import_react.default.createElement("div", { style: { height: 50, backgroundColor: "lightgreen", border: "1px solid black" } }, "Item ", items[index])
140
+ }
141
+ );
142
+ },
143
+ args: {
144
+ count: 50,
145
+ itemHeight: 50,
146
+ overscan: 5,
147
+ hasNextPage: true,
148
+ isLoading: false
149
+ }
150
+ };
54
151
  const TestVirtualList = {
55
152
  play: async ({ canvasElement }) => {
56
153
  const canvas = (0, import_test.within)(canvasElement);
57
- const visible = canvas.getAllByText(/Item #/i);
58
- const firstVisible = visible[0];
59
- const lastVisible = visible[visible.length - 1];
60
- await (0, import_test.expect)(visible.length).toBeLessThanOrEqual(10);
61
- await (0, import_test.expect)(firstVisible).toBeInTheDocument();
154
+ const visibleItems = canvas.getAllByText(/Item #/i);
155
+ const firstVisibleItem = visibleItems[0];
156
+ const lastVisibleItem = visibleItems[visibleItems.length - 1];
157
+ await (0, import_test.expect)(visibleItems.length).toBeLessThanOrEqual(12);
158
+ await (0, import_test.expect)(firstVisibleItem).toBeInTheDocument();
62
159
  await import_test.userEvent.pointer([
63
- { keys: "[TouchA>]", target: lastVisible },
64
- { target: firstVisible },
160
+ { keys: "[TouchA>]", target: lastVisibleItem },
161
+ { target: firstVisibleItem },
65
162
  { keys: "[/TouchA]" }
66
163
  ]);
67
- await (0, import_test.waitFor)(() => (0, import_test.expect)(firstVisible).not.toBeInTheDocument());
164
+ await (0, import_test.waitFor)(() => (0, import_test.expect)(firstVisibleItem).not.toBeInTheDocument());
68
165
  }
69
166
  };
70
167
  //# sourceMappingURL=VirtualList.stories.js.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../../../src/pre-ldls/components/VirtualList/VirtualList.stories.tsx"],
4
- "sourcesContent": ["import React from \"react\";\nimport type { Meta, StoryObj } from \"@storybook/react\";\nimport { VirtualList } from \"./VirtualList\";\nimport { expect, userEvent, waitFor, within } from \"@storybook/test\";\n\nconst meta: Meta<typeof VirtualList> = {\n component: VirtualList,\n decorators: [\n Story => (\n <div style={{ height: \"400px\" }}>\n <Story />\n </div>\n ),\n ],\n title: \"PreLdls/Components/VirtualList\",\n tags: [\"autodocs\"],\n args: {\n itemHeight: 64,\n count: 50,\n renderItem: (i: number) => <h1 tabIndex={i}>Item #{i}</h1>,\n },\n};\nexport default meta;\n\ntype Story = StoryObj<typeof VirtualList>;\n\nexport const Default: Story = {};\n\nexport const TestVirtualList: Story = {\n play: async ({ canvasElement }) => {\n const canvas = within(canvasElement);\n\n const visible = canvas.getAllByText(/Item #/i);\n const firstVisible = visible[0];\n const lastVisible = visible[visible.length - 1];\n\n await expect(visible.length).toBeLessThanOrEqual(10);\n\n await expect(firstVisible).toBeInTheDocument();\n await userEvent.pointer([\n { keys: \"[TouchA>]\", target: lastVisible },\n { target: firstVisible },\n { keys: \"[/TouchA]\" },\n ]);\n await waitFor(() => expect(firstVisible).not.toBeInTheDocument());\n },\n};\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAkB;AAElB,yBAA4B;AAC5B,kBAAmD;AAEnD,MAAM,OAAiC;AAAA,EACrC,WAAW;AAAA,EACX,YAAY;AAAA,IACV,WACE,6BAAAA,QAAA,cAAC,SAAI,OAAO,EAAE,QAAQ,QAAQ,KAC5B,6BAAAA,QAAA,cAAC,WAAM,CACT;AAAA,EAEJ;AAAA,EACA,OAAO;AAAA,EACP,MAAM,CAAC,UAAU;AAAA,EACjB,MAAM;AAAA,IACJ,YAAY;AAAA,IACZ,OAAO;AAAA,IACP,YAAY,CAAC,MAAc,6BAAAA,QAAA,cAAC,QAAG,UAAU,KAAG,UAAO,CAAE;AAAA,EACvD;AACF;AACA,IAAO,8BAAQ;AAIR,MAAM,UAAiB,CAAC;AAExB,MAAM,kBAAyB;AAAA,EACpC,MAAM,OAAO,EAAE,cAAc,MAAM;AACjC,UAAM,aAAS,oBAAO,aAAa;AAEnC,UAAM,UAAU,OAAO,aAAa,SAAS;AAC7C,UAAM,eAAe,QAAQ,CAAC;AAC9B,UAAM,cAAc,QAAQ,QAAQ,SAAS,CAAC;AAE9C,cAAM,oBAAO,QAAQ,MAAM,EAAE,oBAAoB,EAAE;AAEnD,cAAM,oBAAO,YAAY,EAAE,kBAAkB;AAC7C,UAAM,sBAAU,QAAQ;AAAA,MACtB,EAAE,MAAM,aAAa,QAAQ,YAAY;AAAA,MACzC,EAAE,QAAQ,aAAa;AAAA,MACvB,EAAE,MAAM,YAAY;AAAA,IACtB,CAAC;AACD,cAAM,qBAAQ,UAAM,oBAAO,YAAY,EAAE,IAAI,kBAAkB,CAAC;AAAA,EAClE;AACF;",
4
+ "sourcesContent": ["import React, { useState } from \"react\";\nimport type { Meta, StoryObj } from \"@storybook/react\";\nimport { VirtualList } from \"./VirtualList\";\nimport { action } from \"@storybook/addon-actions\";\nimport { expect, userEvent, waitFor, within } from \"@storybook/test\";\n\nconst meta: Meta<typeof VirtualList> = {\n component: VirtualList,\n decorators: [\n Story => (\n <div style={{ height: \"400px\" }}>\n <Story />\n </div>\n ),\n ],\n title: \"PreLdls/Components/VirtualList\",\n tags: [\"autodocs\"],\n parameters: {\n layout: \"fullscreen\",\n docs: {\n description: {\n component:\n \"A virtualized list component that renders only the visible items in a scrollable container using the `useVirtualizer` hook from `@tanstack/react-virtual`. It supports pagination and custom item rendering.\",\n },\n },\n },\n argTypes: {\n count: {\n description: \"Total number of items in the list.\",\n },\n itemHeight: {\n description: \"Height of each item in the list.\",\n },\n overscan: {\n description:\n \"Number of extra items to render outside the visible viewport for smoother scrolling.\",\n table: {\n defaultValue: {\n summary: \"5\",\n },\n },\n },\n LoadingComponent: {\n description:\n \"React component or node to display when the list is loading additional items. If not provided, a default loading spinner will be used.\",\n },\n isLoading: {\n description: \"Indicates whether new items are currently being loaded.\",\n },\n hasNextPage: {\n description:\n \"Indicates if there are more items to load. If true, the list will trigger loading more items when scrolled to the end.\",\n defaultValue: {\n summary: \"false\",\n },\n },\n threshold: {\n description:\n \"Number of items to check before the end of the list to trigger loading more items.\",\n defaultValue: {\n summary: \"5\",\n },\n },\n onVisibleItemsScrollEnd: {\n description:\n \"Callback function to be called when the user scrolls to the end of the visible items. This can be used to load more items when the user reaches the end of the list.\",\n },\n renderItem: {\n description:\n \"Function to render each item in the list. Receives the index of the item as an argument and should return a React node.\",\n },\n },\n args: {\n itemHeight: 64,\n count: 50,\n LoadingComponent: undefined,\n isLoading: false,\n overscan: 5,\n hasNextPage: false,\n threshold: 5,\n onVisibleItemsScrollEnd: () => {},\n renderItem: (index: number) => <h1 tabIndex={index}>Item #{index}</h1>,\n },\n};\nexport default meta;\n\ntype Story = StoryObj<typeof VirtualList>;\n\nexport const Default: Story = {\n args: {\n count: 20,\n itemHeight: 50,\n overscan: 5,\n renderItem: (index: number) => (\n <div style={{ height: 50, backgroundColor: \"lightblue\", border: \"1px solid black\" }}>\n Item {index}\n </div>\n ),\n },\n};\n\nexport const WithPagination: Story = {\n render: args => {\n const [items, setItems] = useState(Array.from({ length: args.count }, (_, i) => i));\n const [isFetching, setIsFetching] = useState(false);\n\n const handleFetchNextPage = async () => {\n action(\"fetchNextPage\")();\n if (isFetching) return;\n setIsFetching(true);\n await new Promise(resolve => setTimeout(resolve, 1000));\n setItems(prev => [...prev, ...Array.from({ length: 50 }, (_, i) => prev.length + i)]);\n setIsFetching(false);\n };\n\n return (\n <VirtualList\n {...args}\n count={items.length}\n isLoading={isFetching}\n onVisibleItemsScrollEnd={handleFetchNextPage}\n hasNextPage={true}\n renderItem={index => (\n <div style={{ height: 50, backgroundColor: \"lightgreen\", border: \"1px solid black\" }}>\n Item {items[index]}\n </div>\n )}\n />\n );\n },\n args: {\n count: 50,\n itemHeight: 50,\n overscan: 5,\n hasNextPage: true,\n isLoading: false,\n },\n};\n\nexport const TestVirtualList: Story = {\n play: async ({ canvasElement }) => {\n const canvas = within(canvasElement);\n\n const visibleItems = canvas.getAllByText(/Item #/i);\n const firstVisibleItem = visibleItems[0];\n const lastVisibleItem = visibleItems[visibleItems.length - 1];\n\n // need to add 5 due to the overscan set to 5 (it renders 5 items before and after the visible items)\n await expect(visibleItems.length).toBeLessThanOrEqual(12);\n\n await expect(firstVisibleItem).toBeInTheDocument();\n\n await userEvent.pointer([\n { keys: \"[TouchA>]\", target: lastVisibleItem },\n { target: firstVisibleItem },\n { keys: \"[/TouchA]\" },\n ]);\n\n await waitFor(() => expect(firstVisibleItem).not.toBeInTheDocument());\n },\n};\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBAAgC;AAEhC,yBAA4B;AAC5B,2BAAuB;AACvB,kBAAmD;AAEnD,MAAM,OAAiC;AAAA,EACrC,WAAW;AAAA,EACX,YAAY;AAAA,IACV,WACE,6BAAAA,QAAA,cAAC,SAAI,OAAO,EAAE,QAAQ,QAAQ,KAC5B,6BAAAA,QAAA,cAAC,WAAM,CACT;AAAA,EAEJ;AAAA,EACA,OAAO;AAAA,EACP,MAAM,CAAC,UAAU;AAAA,EACjB,YAAY;AAAA,IACV,QAAQ;AAAA,IACR,MAAM;AAAA,MACJ,aAAa;AAAA,QACX,WACE;AAAA,MACJ;AAAA,IACF;AAAA,EACF;AAAA,EACA,UAAU;AAAA,IACR,OAAO;AAAA,MACL,aAAa;AAAA,IACf;AAAA,IACA,Y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cAAM,qBAAQ,UAAM,oBAAO,gBAAgB,EAAE,IAAI,kBAAkB,CAAC;AAAA,EACtE;AACF;",
6
6
  "names": ["React"]
7
7
  }
@@ -1,7 +1,53 @@
1
- import React, { ReactNode } from "react";
2
- export declare const VirtualList: ({ count, itemHeight, renderItem, }: {
1
+ import React from "react";
2
+ /**
3
+ * Props for the VirtualList component, which efficiently renders large lists
4
+ * by virtualizing DOM nodes to improve performance.
5
+ */
6
+ type VirtualListProps = {
7
+ /**
8
+ * Total number of items in the list.
9
+ * This is used to calculate the total height of the list.
10
+ */
3
11
  count: number;
12
+ /**
13
+ * Height of each item in the list.
14
+ * This is used to calculate the total height of the list and the position of each item.
15
+ */
4
16
  itemHeight: number;
5
- renderItem: (index: number) => ReactNode;
6
- }) => React.JSX.Element;
17
+ /**
18
+ * Number of extra items to render outside the visible viewport for smoother scrolling.
19
+ * Defaults to 5.
20
+ */
21
+ overscan?: number;
22
+ /**
23
+ * React component or node to display when the list is loading additional items.
24
+ * If not provided, a default loading spinner will be used.
25
+ */
26
+ LoadingComponent?: React.ReactNode;
27
+ /**
28
+ * Indicates whether new items are currently being loaded.
29
+ */
30
+ isLoading?: boolean;
31
+ /**
32
+ * Indicates if there are more items to load.
33
+ */
34
+ hasNextPage?: boolean;
35
+ /**
36
+ * Number of items to check before the end of the list to trigger loading more items.
37
+ * Defaults to 5.
38
+ */
39
+ threshold?: number;
40
+ /**
41
+ * Callback function to be called when the user scrolls to the end of the visible items.
42
+ * This can be used to load more items when the user reaches the end of the list.
43
+ */
44
+ onVisibleItemsScrollEnd?: () => void;
45
+ /**
46
+ * Function to render each item in the list.
47
+ * Receives the index of the item as an argument and should return a React node.
48
+ */
49
+ renderItem: (index: number) => React.ReactNode;
50
+ };
51
+ export declare const VirtualList: ({ count, itemHeight, overscan, LoadingComponent, isLoading, hasNextPage, threshold, onVisibleItemsScrollEnd, renderItem, }: VirtualListProps) => React.JSX.Element;
52
+ export {};
7
53
  //# sourceMappingURL=VirtualList.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"VirtualList.d.ts","sourceRoot":"","sources":["../../../../src/pre-ldls/components/VirtualList/VirtualList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAIzC,eAAO,MAAM,WAAW;WAKf,MAAM;gBACD,MAAM;wBACE,MAAM,KAAK,SAAS;uBAiBzC,CAAC"}
1
+ {"version":3,"file":"VirtualList.d.ts","sourceRoot":"","sources":["../../../../src/pre-ldls/components/VirtualList/VirtualList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAYjD;;;GAGG;AACH,KAAK,gBAAgB,GAAG;IACtB;;;OAGG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,UAAU,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,gBAAgB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACnC;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;OAEG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,uBAAuB,CAAC,EAAE,MAAM,IAAI,CAAC;IACrC;;;OAGG;IACH,UAAU,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,KAAK,CAAC,SAAS,CAAC;CAChD,CAAC;AAQF,eAAO,MAAM,WAAW,+HAUrB,gBAAgB,sBAyDlB,CAAC"}
@@ -1,7 +1,42 @@
1
- import React from "react";
2
- import { FixedSizeList as List } from "react-window";
3
- import AutoSizer from "react-virtualized-auto-sizer";
4
- export const VirtualList = ({ count, itemHeight, renderItem, }) => {
5
- return (React.createElement(AutoSizer, { style: { height: "100%", width: "100%" } }, ({ height }) => (React.createElement(List, { height: height, itemCount: count, itemSize: itemHeight, layout: "vertical", width: "100%" }, ({ index, style }) => React.createElement("div", { style: style }, renderItem(index))))));
1
+ import React, { useEffect, useRef } from "react";
2
+ import { useVirtualizer } from "@tanstack/react-virtual";
3
+ import { Flex, InfiniteLoader } from "../../../components";
4
+ const DefaultLoadingComponent = () => (React.createElement(Flex, { justifyContent: "center", alignItems: "center", height: "76px" },
5
+ React.createElement(InfiniteLoader, null)));
6
+ export const VirtualList = ({ count, itemHeight, overscan = 5, LoadingComponent, isLoading, hasNextPage = false, threshold = 5, onVisibleItemsScrollEnd, renderItem, }) => {
7
+ const parentRef = useRef(null);
8
+ const rowVirtualizer = useVirtualizer({
9
+ count: hasNextPage ? count + 1 : count,
10
+ getScrollElement: () => parentRef.current,
11
+ estimateSize: () => itemHeight,
12
+ overscan,
13
+ });
14
+ useEffect(() => {
15
+ const items = rowVirtualizer.getVirtualItems();
16
+ if (!items.length)
17
+ return;
18
+ const lastItem = items[items.length - 1];
19
+ if (lastItem.index >= count - 1 - threshold &&
20
+ hasNextPage &&
21
+ !isLoading &&
22
+ onVisibleItemsScrollEnd) {
23
+ onVisibleItemsScrollEnd();
24
+ }
25
+ }, [hasNextPage, onVisibleItemsScrollEnd, count, isLoading, rowVirtualizer.getVirtualItems()]);
26
+ const showCustomLoadingComponent = !!LoadingComponent;
27
+ return (React.createElement("div", { ref: parentRef, style: { width: "100%", height: "100%", overflow: "auto" } },
28
+ React.createElement("div", { style: {
29
+ height: `${rowVirtualizer.getTotalSize()}px`,
30
+ width: "100%",
31
+ position: "relative",
32
+ } }, rowVirtualizer.getVirtualItems().map((virtualRow) => (React.createElement("div", { key: virtualRow.index, "data-index": virtualRow.index, ref: rowVirtualizer.measureElement, style: {
33
+ position: "absolute",
34
+ top: 0,
35
+ left: 0,
36
+ transform: `translateY(${virtualRow.start}px)`,
37
+ height: `${itemHeight}px`,
38
+ width: "100%",
39
+ } }, renderItem(virtualRow.index))))),
40
+ isLoading && (showCustomLoadingComponent ? LoadingComponent : React.createElement(DefaultLoadingComponent, null))));
6
41
  };
7
42
  //# sourceMappingURL=VirtualList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"VirtualList.js","sourceRoot":"","sources":["../../../../src/pre-ldls/components/VirtualList/VirtualList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoB,MAAM,OAAO,CAAC;AACzC,OAAO,EAAE,aAAa,IAAI,IAAI,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,SAAS,MAAM,8BAA8B,CAAC;AAErD,MAAM,CAAC,MAAM,WAAW,GAAG,CAAC,EAC1B,KAAK,EACL,UAAU,EACV,UAAU,GAKX,EAAE,EAAE;IACH,OAAO,CACL,oBAAC,SAAS,IAAC,KAAK,EAAE,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,IAChD,CAAC,EAAE,MAAM,EAAsB,EAAE,EAAE,CAAC,CACnC,oBAAC,IAAI,IACH,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,KAAK,EAChB,QAAQ,EAAE,UAAU,EACpB,MAAM,EAAC,UAAU,EACjB,KAAK,EAAC,MAAM,IAEX,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,6BAAK,KAAK,EAAE,KAAK,IAAG,UAAU,CAAC,KAAK,CAAC,CAAO,CAC9D,CACR,CACS,CACb,CAAC;AACJ,CAAC,CAAC"}
1
+ {"version":3,"file":"VirtualList.js","sourceRoot":"","sources":["../../../../src/pre-ldls/components/VirtualList/VirtualList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AACjD,OAAO,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACzD,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AA4D3D,MAAM,uBAAuB,GAAG,GAAG,EAAE,CAAC,CACpC,oBAAC,IAAI,IAAC,cAAc,EAAC,QAAQ,EAAC,UAAU,EAAC,QA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AM,EAAE,QAAQ,EAAE,MAAM,EAAE;QAC7E,6BACE,KAAK,EAAE;gBACL,MAAM,EAAE,GAAG,cAAc,CAAC,YAAY,EAAE,IAAI;gBAC5C,KAAK,EAAE,MAAM;gBACb,QAAQ,EAAE,UAAU;aACrB,IAEA,cAAc,CAAC,eAAe,EAAE,CAAC,GAAG,CAAC,CAAC,UAAuB,EAAE,EAAE,CAAC,CACjE,6BACE,GAAG,EAAE,UAAU,CAAC,KAAK,gBACT,UAAU,CAAC,KAAK,EAC5B,GAAG,EAAE,cAAc,CAAC,cAAc,EAClC,KAAK,EAAE;gBACL,QAAQ,EAAE,UAAU;gBACpB,GAAG,EAAE,CAAC;gBACN,IAAI,EAAE,CAAC;gBACP,SAAS,EAAE,cAAc,UAAU,CAAC,KAAK,KAAK;gBAC9C,MAAM,EAAE,GAAG,UAAU,IAAI;gBACzB,KAAK,EAAE,MAAM;aACd,IAEA,UAAU,CAAC,UAAU,CAAC,KAAK,CAAC,CACzB,CACP,CAAC,CACE;QACL,SAAS,IAAI,CAAC,0BAA0B,CAAC,CAAC,CAAC,gBAAgB,CAAC,CAAC,CAAC,oBAAC,uBAAuB,OAAG,CAAC,CACvF,CACP,CAAC;AACJ,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ledgerhq/react-ui",
3
- "version": "0.24.0-nightly.2",
3
+ "version": "0.24.0-nightly.3",
4
4
  "description": "Ledger Live - Desktop UI",
5
5
  "author": "Ledger Live Team <team-live@ledger.fr>",
6
6
  "repository": {
@@ -61,6 +61,7 @@
61
61
  ],
62
62
  "dependencies": {
63
63
  "@floating-ui/react-dom": "^0.4.0",
64
+ "@tanstack/react-virtual": "3.13.6",
64
65
  "@tippyjs/react": "^4.2.6",
65
66
  "color": "^4.0.0",
66
67
  "embla-carousel-autoplay": "8.4.0",
@@ -71,7 +72,6 @@
71
72
  "react-select": "^5.2.1",
72
73
  "react-spring": "8.0.27",
73
74
  "react-transition-group": "^4.4.2",
74
- "react-virtualized-auto-sizer": "1.0.24",
75
75
  "react-window": "^1.8.6",
76
76
  "styled-system": "^5.1.5",
77
77
  "@ledgerhq/crypto-icons-ui": "^1.13.0-nightly.0",