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

[GSoC2024] Resolved Issue #7620 (Changed the alignment of the empty component in job page) #7621

Merged
merged 6 commits into from
Mar 20, 2024

Conversation

thekavikumar
Copy link
Contributor

ref issue: #7620

I've created a class called cvat-empty-jobs-list and added it to a div to make the empty component in the job page aligned in the middle as all other pages having empty component aligned to its center.

after

@syedbarimanjan
Copy link
Contributor

syedbarimanjan commented Mar 17, 2024

ref issue: #7620

I've created a class called cvat-empty-jobs-list and added it to a div to make the empty component in the job page aligned in the middle as all other pages having empty component aligned to its center.

after

On line number 23 of styles.scss you have

> div:nth-child(2) {
        &.ant-empty {
            position: absolute;
            top: 40%;
            left: 50%;
        }

and by changing it to

> div:nth-child(2) {
        &.ant-empty {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
        }

shall solve the alignment thus you wont need to write so much code.

@thekavikumar
Copy link
Contributor Author

@syedbarimanjan let me try it out

@thekavikumar
Copy link
Contributor Author

@syedbarimanjan yeah i tried that, but it was not aligned as other empty components rendered in pages like projects

@syedbarimanjan
Copy link
Contributor

syedbarimanjan commented Mar 17, 2024

@syedbarimanjan yeah i tried that, but it was not aligned as other empty components rendered in pages like projects

Screenshot from 2024-03-17 11-03-51
It is properly alligned in the middle. Maybe you applied the styles to the wrong selector.

Copy link
Contributor

@klakhov klakhov left a comment

Choose a reason for hiding this comment

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

Some more comments:

  • Please, add a changelog entry
  • In each file that you update, update license header with actual change year (-2024)
  • Look at the begging at the cvat-ui/src/components/jobs-page/styles.scss file. Class selector .cvat-jobs-page has a couple div:nth-child usages. It was added for faster development of the page but considered as bad practice. Could you fix that and add actual classnames instead of nth selectors? I belive first one is for top-bar and second for empty list. Also you can move your changes with ant-empty alignment here.

cvat-ui/src/components/jobs-page/jobs-page.tsx Outdated Show resolved Hide resolved
cvat-ui/src/components/jobs-page/styles.scss Outdated Show resolved Hide resolved
@klakhov klakhov requested review from klakhov and removed request for bsekachev March 18, 2024 10:03
@klakhov klakhov added the ui/ux label Mar 18, 2024
@thekavikumar
Copy link
Contributor Author

@klakhov how do we create a changelog? do we have any script or should we do it manually in changelog folder?

@syedbarimanjan
Copy link
Contributor

@klakhov how do we create a changelog? do we have any script or should we do it manually in changelog folder?

Developers: this project uses scriv (https://scriv.readthedocs.io/en/stable/index.html)
to maintain the changelog. To add an entry, create a fragment:

$ scriv create --edit

Fragments will be merged into this file whenever a release is made.

@thekavikumar
Copy link
Contributor Author

@klakhov how do we create a changelog? do we have any script or should we do it manually in changelog folder?

Developers: this project uses scriv (https://scriv.readthedocs.io/en/stable/index.html) to maintain the changelog. To add an entry, create a fragment:

$ scriv create --edit

Fragments will be merged into this file whenever a release is made.

thanks

@thekavikumar
Copy link
Contributor Author

@klakhov can you review it now?

@thekavikumar
Copy link
Contributor Author

@klakhov @nmanovic can you please review and let me know the status? I've another pr to make!

Copy link
Contributor

@klakhov klakhov left a comment

Choose a reason for hiding this comment

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

@thekavikumar
It looks we lost paddings for non-empty job list after the style changes. Could you fix that?
image
Should be as on other pages:
image

changelog.d/20240318_203856_kavikumarceo.md Outdated Show resolved Hide resolved
@thekavikumar
Copy link
Contributor Author

@klakhov sure i will fix it

@thekavikumar
Copy link
Contributor Author

@klakhov check it now

@thekavikumar
Copy link
Contributor Author

@klakhov I've changed it to $grid-unit-size

@thekavikumar
Copy link
Contributor Author

@klakhov @nmanovic please review it

Copy link

codecov bot commented Mar 20, 2024

Codecov Report

Merging #7621 (4952d3d) into develop (f513aa1) will decrease coverage by 0.03%.
Report is 2 commits behind head on develop.
The diff coverage is n/a.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #7621      +/-   ##
===========================================
- Coverage    83.47%   83.44%   -0.03%     
===========================================
  Files          373      373              
  Lines        39739    39736       -3     
  Branches      3741     3741              
===========================================
- Hits         33171    33157      -14     
- Misses        6568     6579      +11     
Components Coverage Δ
cvat-ui 79.23% <ø> (-0.06%) ⬇️
cvat-server 87.32% <100.00%> (-0.01%) ⬇️

@klakhov klakhov merged commit d1a300f into cvat-ai:develop Mar 20, 2024
34 checks passed
@nmanovic nmanovic changed the title [GSoC24] Resolved Issue #7620 (Changed the alignment of the empty component in job page) [GSoC2024] Resolved Issue #7620 (Changed the alignment of the empty component in job page) Mar 21, 2024
@cvat-bot cvat-bot bot mentioned this pull request Apr 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants