virtua 0.50.6 → 0.51.0
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/README.md +6 -1
- package/lib/angular/Virtualizer.d.ts +2 -2
- package/lib/angular/WindowVirtualizer.d.ts +2 -2
- package/lib/angular/index.js +152 -156
- package/lib/angular/index.js.map +1 -1
- package/lib/core/index.cjs +234 -232
- package/lib/core/index.cjs.map +1 -1
- package/lib/core/index.js +242 -240
- package/lib/core/index.js.map +1 -1
- package/lib/index.cjs +442 -440
- package/lib/index.cjs.map +1 -1
- package/lib/index.js +435 -433
- package/lib/index.js.map +1 -1
- package/lib/react/VGrid.d.ts +3 -3
- package/lib/react/Virtualizer.d.ts +2 -2
- package/lib/react/WindowVirtualizer.d.ts +2 -2
- package/lib/solid/Virtualizer.d.ts +2 -2
- package/lib/solid/WindowVirtualizer.d.ts +2 -2
- package/lib/solid/index.cjs +228 -234
- package/lib/solid/index.cjs.map +1 -1
- package/lib/solid/index.js +239 -243
- package/lib/solid/index.js.map +1 -1
- package/lib/solid/index.jsx +97 -88
- package/lib/solid/index.jsx.map +1 -1
- package/lib/svelte/ListItem.svelte +1 -1
- package/lib/svelte/Virtualizer.svelte +1 -2
- package/lib/svelte/Virtualizer.type.d.ts +2 -2
- package/lib/svelte/WindowVirtualizer.svelte +1 -2
- package/lib/svelte/WindowVirtualizer.type.d.ts +2 -2
- package/lib/vue/Virtualizer.d.ts +2 -2
- package/lib/vue/WindowVirtualizer.d.ts +2 -2
- package/lib/vue/index.cjs +276 -285
- package/lib/vue/index.cjs.map +1 -1
- package/lib/vue/index.js +257 -266
- package/lib/vue/index.js.map +1 -1
- package/package.json +2 -3
package/README.md
CHANGED
|
@@ -28,7 +28,12 @@ https://inokawa.github.io/virtua/
|
|
|
28
28
|
npm install virtua
|
|
29
29
|
```
|
|
30
30
|
|
|
31
|
-
If you
|
|
31
|
+
If you want to support legacy browsers, you need polyfills.
|
|
32
|
+
|
|
33
|
+
- [ResizeObserver](https://caniuse.com/?search=resizeobserver) is always required (e.g. [@juggle/resize-observer](https://github.com/juggle/resize-observer#switching-between-native-and-polyfilled-versions)).
|
|
34
|
+
- [Scroll methods on elements](https://caniuse.com/element-scroll-methods) are always required (e.g. [element-scroll-polyfill](https://github.com/idmadj/element-scroll-polyfill)).
|
|
35
|
+
- [CSS scroll-behavior](https://caniuse.com/?search=scroll-behavior) is required only if you call `scrollToIndex` with `smooth: true` (e.g. [scroll-behavior-polyfill](https://github.com/wessberg/scroll-behavior-polyfill)).
|
|
36
|
+
- [CSS inset-inline-start](https://caniuse.com/mdn-css_properties_inset-inline-start) is required only if you set `horizontal: true`. It cannot be polyfilled so use `virtua@<=0.50` instead.
|
|
32
37
|
|
|
33
38
|
## Getting started
|
|
34
39
|
|
|
@@ -11,7 +11,7 @@ export interface VirtualizerHandle {
|
|
|
11
11
|
*/
|
|
12
12
|
readonly cache: CacheSnapshot;
|
|
13
13
|
/**
|
|
14
|
-
* Get current scrollTop, or scrollLeft if horizontal: true.
|
|
14
|
+
* Get current scrollTop, or scrollLeft if horizontal: true. Always positive even in RTL.
|
|
15
15
|
*/
|
|
16
16
|
readonly scrollOffset: number;
|
|
17
17
|
/**
|
|
@@ -19,7 +19,7 @@ export interface VirtualizerHandle {
|
|
|
19
19
|
*/
|
|
20
20
|
readonly scrollSize: number;
|
|
21
21
|
/**
|
|
22
|
-
* Get current
|
|
22
|
+
* Get current clientHeight, or clientWidth if horizontal: true.
|
|
23
23
|
*/
|
|
24
24
|
readonly viewportSize: number;
|
|
25
25
|
/**
|
|
@@ -10,11 +10,11 @@ export interface WindowVirtualizerHandle {
|
|
|
10
10
|
*/
|
|
11
11
|
readonly cache: CacheSnapshot;
|
|
12
12
|
/**
|
|
13
|
-
* Get current scrollTop, or scrollLeft if horizontal: true.
|
|
13
|
+
* Get current scrollTop, or scrollLeft if horizontal: true. Always positive even in RTL.
|
|
14
14
|
*/
|
|
15
15
|
readonly scrollOffset: number;
|
|
16
16
|
/**
|
|
17
|
-
* Get current
|
|
17
|
+
* Get current clientHeight of the document, or clientWidth if horizontal: true.
|
|
18
18
|
*/
|
|
19
19
|
readonly viewportSize: number;
|
|
20
20
|
/**
|