Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Typescript + API Cleanup + Simple Components #30

Open
wants to merge 26 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
3a8c533
bump version
Nov 25, 2020
723ebee
* Converted files to TS.
Nov 30, 2020
ec52265
* Added files missing in last commit
Nov 30, 2020
5ca4d7a
* Fixed remaining TS errors
Nov 30, 2020
fe28492
* Added StickyList and AutoSizedStickyList
Nov 30, 2020
9913158
* [BREAKING CHANGE] - changed API so that it returns the node that yo…
Dec 1, 2020
38c141c
* Prevent key errors.
Dec 1, 2020
16b5530
Point to the code!
Dec 1, 2020
ee0f2df
Externalise the callback props to make it easier to use
Dec 1, 2020
3895940
We need to export everything.
Dec 1, 2020
1e0c799
Revert back to target
Dec 2, 2020
45551e1
Break out props so they can be used individually.
Dec 2, 2020
f7c05f6
Remove need to specify key by using node.id
Dec 2, 2020
dc3c842
Added meta and isLeafNode to info. Added types for react-measure
Dec 3, 2020
18d12c8
Added meta and isLeafNode to info. Added types for react-measure
Dec 23, 2020
23022fc
Use render function which will be more performant.
Dec 31, 2020
11edaa5
Port fix from master
Dec 31, 2020
d382c28
Moved @types/react-measure from dependencies to devDependencies
Feb 27, 2021
91a7dee
Add a prop to allow the inline width/height to not be set on the stic…
Mar 23, 2021
a04d4ed
bump version
Mar 23, 2021
7f99192
Merge pull request #33 from marchaos/prop_for_not_setting_inline_widt…
marchaos Mar 23, 2021
c5b5c92
Fixed issue in StickyList were the root node didn't have a height cau…
Nov 2, 2022
53e8ff9
allow passed in items to have node info on them for a sticky list
Nov 3, 2022
e549b44
Add getting and setting scrollLeft
Jan 20, 2023
57c9f66
Build for both esm and cjs
Mar 11, 2024
616b349
Add extensions so that webpack does not complain when using the mjs v…
Mar 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Port fix from master
Marc McIntyre authored and Marc McIntyre committed Dec 31, 2020

Verified

This commit was created on github.com and signed with GitHub’s verified signature.
commit 11edaa57b6a96264f764feed7423343ab7055aa9
4 changes: 4 additions & 0 deletions src/StickyTree.tsx
Original file line number Diff line number Diff line change
@@ -896,6 +896,10 @@ export default class StickyTree<TNodeType extends TreeNode = TreeNode, TMeta = a
scrollTop = this.elemRef.current.scrollHeight - this.elemRef.current.offsetHeight;
}

if (scrollTop === this.state.scrollTop) {
return;
}

let pos;
if (scrollTop > this.state.scrollTop || currNodePos === 0) {
pos = this.forwardSearch(scrollTop, currNodePos);