Simulate indentation of the project tree using some divs#12047
Simulate indentation of the project tree using some divs#12047marcelgerber merged 5 commits intoadobe:masterfrom
Conversation
| * @param {int} depth - The depthness of the current node. | ||
| * @return {ReactComponent} - The resulting div. | ||
| */ | ||
| function _createThickness(depth) { |
There was a problem hiding this comment.
Does this div have defined display as inline-block?
There was a problem hiding this comment.
I just saw it is defined in the thickness class, may be we can define it inside the style prop?
|
@dibosh Thank you to have looked at it. |
|
@marcelgerber if you have a bit of time could you take a look? |
| * @private | ||
| * | ||
| * Create an appropriate div based thickness to indent the tree correctly. | ||
| * |
There was a problem hiding this comment.
Nit, but depthness is no word ;)
|
LGTM, but I'd like to have someone else have a look at the React code (even though it looks straighforward) since I don't know nothing about React. |
|
@marcelgerber Thank you. |
| className: "jstree-icon" | ||
| }, " "), | ||
| ]; | ||
| var thickness = _createThickness(this.props.depth); |
There was a problem hiding this comment.
Nit: Consecutive vars are usually either separated with a dot or new line
|
Reviewed this, made a few comments 👍 |
|
I've updated the PR. |
| @@ -114,35 +114,36 @@ define(function (require, exports, module) { | |||
| /** | |||
| * @private | |||
| * | |||
There was a problem hiding this comment.
Unitless value here, does React automatically convert it to px?
|
@marcelgerber LGTM, but has merge conflicts after some recent changes. |
d865862 to
39416d3
Compare
|
I made some changes so to fix the rename case too. So it needs another look. |
|
@marcelgerber I fixed that issue, but now when you rename a folder the element with the children ( There is a |
|
You probably didn't see this comment: |
|
If you can somehow manage to not apply |
instead of using combinations of padding/margin. Fixes adobe#10574
5969de2 to
dc8cb32
Compare
|
I noticed another small issue were selecting a folder would result in a blue border. |
|
LGTM. Going for it. |
|
Thank you @marcelgerber @petetnt @dibosh for review |
Update tests after #12047

instead of using combinations of padding/margin.
Fixes #10574