-
Notifications
You must be signed in to change notification settings - Fork 2
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
Adding React Mosaic #390
Adding React Mosaic #390
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the refactoring/feature. The windowing works now much smoother and also looks cleaner from the code.
Please see my comments and improvements below.
Additionally, I noticed that the dragging of the COSMIC view is not fixed using the pointer-events: none
. Could you please have a look into this again?
P.S. Ignore the empty ranking which is caused by the lineupengine release v2.4.1.
const path = getPathToCorner(mosaicState, Corner.TOP_RIGHT); | ||
const parent = getNodeAtPath(mosaicState, dropRight(path)) as MosaicParent<string>; | ||
const destination = getNodeAtPath(mosaicState, path) as MosaicNode<string>; | ||
const direction: MosaicDirection = parent ? getOtherDirection(parent.direction) : 'row'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const direction: MosaicDirection = parent ? getOtherDirection(parent.direction) : 'row'; | |
const direction: MosaicDirection = parent ? getOtherDirection(parent.direction) : 'row'; | |
const newViewId: string = views[views.length - 1].uniqueId; // assumes that the new view is appended to the array |
Maybe extract to a variable and add a comment that new views are appended.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, done. Should also mention here the way this works will probably not quite hold when we get provenance in, since it relies on views being added one at a time and in order. But can address that when the need arises?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good question! I think, we don't need a todo here, as we need to test everything again once the provenance is in place. Maybe you give @kirangadhave a heads up.
Also made a new ticket for improving the performance of the resizing with vis https://github.com/datavisyn/reprovisyn/issues/373. Currently it is quite slow, and if the dataset is large its a large hindrance |
@dvzacharycutler Thanks for your changes and for creating the follow-up issue. There are two open points before we are ready to merge this PR. Refactor CSS importsPlease refactor the CSS imports as mentioned above. Add
|
Yes, I addressed the pointer events issue, the problem wasnt scss but me not realizing what the onDragEnd does. Instead set the flag for dragging in the MosaicWindow onChange, and turned it off in onRelease. Will fix the imports now |
Ok, thanks for the explanation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've tested the PR again and it works well. Dragging is working fluently and without problems.
I could reproduce a bug with LineUp when a second view is dragged to the left. I documented the bug in the follow-up issue https://github.com/datavisyn/reprovisyn/issues/375.
Beside this everything else looks good and is ready to be merged. Thanks for your implementation, @dvzacharycutler!
Closes https://github.com/datavisyn/reprovisyn/issues/328
Developer Checklist (Definition of Done)
next-version: minor
) to this PR following semverSummary of changes
Screenshots
react-mosaic.mp4