Skip to content

Support Material-UI tree #143

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

Merged
merged 6 commits into from
Jan 7, 2021
Merged

Support Material-UI tree #143

merged 6 commits into from
Jan 7, 2021

Conversation

liatgo
Copy link
Contributor

@liatgo liatgo commented Jan 5, 2021

No description provided.

@liatgo liatgo requested a review from liorheber January 5, 2021 17:42
"author": "ui@kenshoo.com",
"license": "MIT",
"peerDependencies": {
"@kenshooui/react-tree": "^1.0.0",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would add this to dev as well.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@liorheber please publish react-tree

@liorheber
Copy link
Contributor

liorheber commented Jan 6, 2021

Something with the left arrow doesn't seem aligned properly:
image

@liorheber
Copy link
Contributor

Something in the search isn't working properly, after each character it blurs out of the input and I need to click on the input again to continue typing.

@liatgo
Copy link
Contributor Author

liatgo commented Jan 6, 2021

Something in the search isn't working properly, after each character it blurs out of the input and I need to click on the input again to continue typing.

It's a regression caused by "React.forwardRef..."

@liatgo
Copy link
Contributor Author

liatgo commented Jan 6, 2021

Something with the left arrow doesn't seem aligned properly:
image

It's seems like this because of the "hover circle":
image

@liorheber I can remove this behavior and add some custom behavior on hover (or just live it without hover behavior)
What do you think?

Comment on lines 9 to 11
containerRef?.current?.clientHeight -
headerRef?.current?.clientHeight -
inputRef?.current?.clientHeight;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will this work properly for stuff that is missing? say 300 - undefined - 10?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@liorheber I don't think so.
What is the desirable behavior n this case? give itemsHeight a default value?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it doesn't exist I'd expect it to have a clientHeight value of 0 -
Why? If the ref doesn't exist it means that it was not inserted. if it was not inserted it should take 0px of the height.

Does that make sense?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same about containerRef? because in this case we will get negative result

@liorheber liorheber merged commit 1700429 into master Jan 7, 2021
@liorheber liorheber deleted the support-material-ui-tree branch January 7, 2021 15:08

const Tree = props => {
const {
structure = [],
title,
onSelect,
className,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@liorheber Here is the removal of className.
Is it ok? Or should I change it back?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants