Releases: inokawa/virtua
Releases · inokawa/virtua
0.48.2
0.48.1
0.48.0
BREAKING CHANGES
Removed reverse prop from VList for React (#774)
// before
<VList reverse>{children}</VList>;
// after
// Recommended markup to align items to the bottom
<div
style={{
overflowY: "auto",
height: "100%",
display: "flex",
flexDirection: "column",
}}
>
<div style={{ flexGrow: 1 }} />
<Virtualizer>{children}</Virtualizer>
</div>;
// or if you want the exactly same markup as reverse prop, use this
const scrollRef = useRef(null);
<div
ref={scrollRef}
style={{
display: "block",
overflowY: "auto",
contain: "strict",
width: "100%",
height: "100%",
}}
>
<div
style={{
display: "flex",
flexDirection: "column",
justifyContent: "flex-end",
minHeight: "100%",
overflow: "clip",
}}
>
<Virtualizer scrollRef={scrollRef}>{children}</Virtualizer>
</div>
</div>;
// ...or we can use "column-reverse" to invert scroll direction in 0.48.0. May fit depending on your usecase
<div
style={{
height: "100%",
overflowY: "auto",
display: "flex",
flexDirection: "column-reverse",
}}
>
<Virtualizer>{children}</Virtualizer>
</div>;What's Changed
- Add Svelte Chat Story by @sf1tzp in #820
- Remove reverse prop by @inokawa in #774
- Support flex-direction: column-reverse and writing-mode by @inokawa in #824
New Contributors
Full Changelog: 0.47.2...0.48.0
0.47.2
0.47.1
0.47.0
BREAKING CHANGES
- Merged
findStartIndex/findEndIndexintofindItemIndexfor more control
// before
handle.findStartIndex();
// after
handle.findItemIndex(handle.scrollOffset);
// before
handle.findEndIndex();
// after
handle.findItemIndex(handle.scrollOffset + handle.viewportSize);- Refactored some methods and props of experimental_VGrid #777
What's Changed
- Refactor handle by @inokawa in #808
- Refactor handle by @inokawa in #814
- Add getItemOffset/getItemSize to WindowVirtualizerHandle by @inokawa in #815
- Replace findStartIndex/findEndIndex with findItemIndex by @inokawa in #816
- Refine VGrid methods and props by @inokawa in #777
Full Changelog: 0.46.7...0.47.0