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

Pave way for table revamping, binding the table to single container #2422

Closed
wants to merge 10 commits into from
Closed

Conversation

kushthedude
Copy link
Member

Refers: #1312

Copy link
Sponsor Member

@wetneb wetneb left a comment

Choose a reason for hiding this comment

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

This is definitely a good move since it should help us solve a lot of issues. However in its current form, it breaks the design. We should aim to preserve the same design when doing such a change.

Before:

image

After:
image

@kushthedude
Copy link
Member Author

I didn't test the design with less number of rows, indeed it was my lack of testing for the PR. I will make the changes required.

@kushthedude
Copy link
Member Author

@wetneb Fixed the design, Combining them to one container made some other function useless which were just there to adjust there orientation.

@kushthedude kushthedude requested a review from wetneb April 2, 2020 13:49
Copy link
Sponsor Member

@wetneb wetneb left a comment

Choose a reason for hiding this comment

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

We should be able to revamp this architecture without making any significant changes to the appearance. Can you notice the changes?

  • missing grey background on odd rows
  • missing cell borders in table header
  • incorrect color for cell borders in table body

I might have missed others! This needs to be thoroughly tested.

Before

image

After

image

@kushthedude
Copy link
Member Author

@wetneb I will fix all the design issues. With this commit I have just fixed the orientationa and alignment issues which were more observing.

@thadguidry
Copy link
Member

@kushthedude you are doing great! I see the simplification coming through now, and understand your strategy here. Your right that styling and alignment can be fixed. Essentially this is really a Draft Pull Request in the making :) I think a few more hours or day and you'll conquer it!

Copy link
Member

@tfmorris tfmorris left a comment

Choose a reason for hiding this comment

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

Thanks for tackling this! I'd like to see the variable/class naming updated to reflect the current structure to make it less confusing for future developers. I also think more of the previous machinery can be removed.

A couple of small stylistics things which will make it easier for reviewers:

  • try to resist the temptation to make non-essential changes like adding/removing blank lines. They just add noise to the diff.
  • a meaningful branch name like 1312-table-refactor, or something similar, will make it easier for developers with lots of branches to find yours

@kushthedude
Copy link
Member Author

  • a meaningful branch name like 1312-table-refactor, or something similar, will make it easier for developers with lots of branches to find yours

I actually preferred UI as the main aim for this branch was to completely refactor the table section but then I came to know that current table is too loosely bounded and we have an explicit function for simple tasks like aligning header with the body etc. Hence had to refactor the method of the rendering of the table before introducing more feature in data-grid.

@kushthedude
Copy link
Member Author

@wetneb @thadguidry @tfmorris Sorry for the delay, I was having hard luck finding a nice internet but it's solved now.

@wetneb Restored the styling, I can't find any change now b/w old & new table.
Please take a look!
Screenshot 2020-04-06 at 6 50 47 AM

After this, I think the next step would be to design the re-sizer which I will do in the meantime and make a PR. I will add the resizer to the table and make draggable columns later as I have mentioned it in my GSoC Timeline.

Copy link
Sponsor Member

@wetneb wetneb left a comment

Choose a reason for hiding this comment

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

I can notice the following changes:

  • The font size of all text in the table has increased;
  • Borders in column headers are missing (as I already mentioned in the previous review). With Chromium, there is still a vertical border between column headers, but with Firefox even those have disappeared.

If you find it hard to compare both versions, you can do this:

  • run OpenRefine from the master branch and load a sample project in your browser
  • stop OpenRefine and keep your project open in your browser
  • start OpenRefine from your branch and load the same project in a new tab

You can now switch back and forth between the two tabs.

With this technique, differences such as the font size of table elements should be really obvious.

Before

image

After (Chromium)

image

After (Firefox)

image

main/webapp/modules/core/styles/views/data-table-view.less Outdated Show resolved Hide resolved
@kushthedude
Copy link
Member Author

@wetneb Done the changes :

Before this (On chromium & safari)

Screenshot 2020-04-07 at 6 31 45 AM

After this (On chromium & safari)

Screenshot 2020-04-07 at 6 32 43 AM

I mimic firefox using safari user-agent and it was working well. Please let me know if it is still broke on firefox because I dont cant see any particular reason why the styling won't apply on firefox.

@kushthedude kushthedude requested a review from wetneb April 7, 2020 01:05
@lisa761
Copy link
Member

lisa761 commented Apr 7, 2020

Hi @kushthedude, I tested it out and it still does not seem to work on firefox.

Before:

2020-04-07 (2)

After:

2020-04-07 (3)

Plus on chrome, its a minute detail, but the top border of the table header is not present anymore.

Before:

2020-04-07 (7)

After:

2020-04-07 (8)

@kushthedude
Copy link
Member Author

Top border is present in chrome, I think you missed seeing it.
About firefox, I will look into it.

@lisa761
Copy link
Member

lisa761 commented Apr 7, 2020

I am talking about this:
Before:
2020-04-07 (7)_LI
After:
2020-04-07 (8)_LI

I meant the top border of the header column. If you look carefully, it is not as thick anymore.

@lisa761
Copy link
Member

lisa761 commented Apr 7, 2020

@kushthedude, Looking at your screenshots, this does not seem to appear in your chrome for some reason? Although, when I checked @wetneb's screenshots, it seems to persist.

@kushthedude
Copy link
Member Author

@kushthedude, Looking at your screenshots, this does not seem to appear in your chrome for some reason? Although, when I checked @wetneb's screenshots, it seems to persist.

Did you mind to try out in your local ?

@kushthedude
Copy link
Member Author

I am talking about this:
Before:
2020-04-07 (7)_LI
After:
2020-04-07 (8)_LI

I meant the top border of the header column. If you look, carefully it is not as thick anymore.

I checked it again both are of 1 px, there must be viewport difference in your both tabs.

@kushthedude
Copy link
Member Author

BTW Screenshot in firefox:-
Screenshot 2020-04-08 at 5 14 16 AM

@thadguidry
Copy link
Member

@kushthedude this was unnecessary for such a very minor visual difference, but glad to see that you went the extra mile to make it exact as before.

@wetneb
Copy link
Sponsor Member

wetneb commented Apr 8, 2020

We don't use that top border or delineate with it...

I am not sure what you mean by that… By this token, we don't "use" most borders.
I think it is important to keep the UI clean and consistent.

@kushthedude
Copy link
Member Author

@wetneb UI is consistent and borders are intact in chromium and firefox too.

@kushthedude
Copy link
Member Author

kushthedude commented Apr 8, 2020

There are number of commits after the @wetneb 's screenshots. There will be change, all I told you to check the PR locally and show me the css details from the console if you think there is difference of border size after this PR and before.

@antoine2711
Copy link
Member

@kushthedude : wow, what you are doing is impressive.
Keep up the good work, it is very promising.

Regards, Antoine.

@kushthedude kushthedude requested review from wetneb and removed request for wetneb April 9, 2020 00:14
@kushthedude
Copy link
Member Author

Thanks, @antoine2711, Once this gets merged. I will be making a PR for migration of a dialogue or a dropdown service to Vue.js to see how it actually goes.

@kushthedude
Copy link
Member Author

@wetneb Is there anything more remaining in this PR?

@wetneb
Copy link
Sponsor Member

wetneb commented Apr 14, 2020

Thanks for your patience and for fixing all the rendering issues encountered so far!

I noticed differences in the way column groups are rendered:

Before:
image

After:
image

(to test this, create a project with column groups, with the XML or JSON importers)

@kushthedude
Copy link
Member Author

@wetneb Fixed the issue with XML/JSON importers.
One thing before the complete page was occupied by TableHeader column which will not be the case after as now TableHeader & Body is bonded by a single table

@kushthedude kushthedude requested a review from wetneb April 18, 2020 17:48
@kushthedude kushthedude requested review from wetneb and removed request for wetneb April 19, 2020 10:32
Copy link
Sponsor Member

@wetneb wetneb left a comment

Choose a reason for hiding this comment

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

The column groups are still not correctly rendered. See my latest screenshots again: you have fixed the background, but that was not the only difference! Have a good look at the orange bars. Can you notice a difference?

If you could have the initiative to test things more thoroughly on your side it would be great - it is quite time consuming to review changes like this. Thanks!

@lisa761
Copy link
Member

lisa761 commented May 19, 2020

Hi Kush!
Are you still working on this PR?

@kushthedude
Copy link
Member Author

kushthedude commented May 19, 2020 via email

@lisa761
Copy link
Member

lisa761 commented May 23, 2020

Hey Kush, this PR is important in order to start with the infinite scrolling project. If you don't mind, can you wrap this up faster? If you're busy, I can help as well.

@kushthedude
Copy link
Member Author

@wetneb I am currently occupied with my academic activities which may take another week to wrap up, hence closing this PR.

@wetneb
Copy link
Sponsor Member

wetneb commented May 23, 2020

That is alright, thanks a lot for all the work done so far! This PR was almost in a mergeable state so it will already help Lisa a lot :)

@thadguidry
Copy link
Member

@kushthedude Thank you Kush!

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.

None yet

6 participants