Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
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

Hotfix: excessive scrollbar on quality page #8729

Merged
merged 7 commits into from
Nov 21, 2024
Merged

Hotfix: excessive scrollbar on quality page #8729

merged 7 commits into from
Nov 21, 2024

Conversation

klakhov
Copy link
Contributor

@klakhov klakhov commented Nov 21, 2024

Motivation and context

Fix for scaling in #8698 produced excessive scrollbar even for 100%
(for quality placeholder and management tab with full table of gt frames)
image
image

This hotfix fixes it. Scrollbar should be visible only on scaling

How has this been tested?

Checklist

  • I submit my changes into the develop branch
  • I have created a changelog fragment
  • I have updated the documentation accordingly
  • I have added tests to cover my changes
  • I have linked related issues (see GitHub docs)
  • I have increased versions of npm packages if it is necessary
    (cvat-canvas,
    cvat-core,
    cvat-data and
    cvat-ui)

License

  • I submit my code changes under the same MIT License that covers the project.
    Feel free to contact the maintainers if that's a concern.

@klakhov klakhov requested a review from bsekachev as a code owner November 21, 2024 08:50
Copy link
Contributor

coderabbitai bot commented Nov 21, 2024

Walkthrough

The changes involve modifications to the styles.scss files of two components: cvat-paid-feature-placeholder and cvat-quality-control. The height of the .ant-card-body class in the paid feature placeholder is reduced from 80% to 75%. In the quality control component, the maximum height of the .ant-table-container is increased slightly, and the height of the .ant-tabs-tabpane is changed from a maximum height to a fixed height. No other structural or significant styling changes were made.

Changes

File Path Change Summary
cvat-ui/src/components/paid-feature-placeholder/styles.scss Adjusted height of .ant-card-body from 80% to 75%.
cvat-ui/src/components/quality-control/styles.scss Increased max height of .cvat-frame-allocation-table .ant-table-container from calc(100vh - $grid-unit-size * 60) to calc(100vh - $grid-unit-size * 61). Changed height of .ant-tabs-tabpane from max-height: calc(100vh - $grid-unit-size * 35) to height: calc(100vh - $grid-unit-size * 33).

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant UI
    participant Component

    User->>UI: Interacts with quality control component
    UI->>Component: Render updated layout
    Component-->>UI: Display adjusted heights
    UI-->>User: Show modified interface
Loading

🐰 "In the land of code where changes bloom,
The card's height shrinks, making more room.
With tables and tabs, we adjust with care,
A little more space, for all to share!
Hopping through styles, we dance with delight,
In our UI garden, everything feels right!" 🌼


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 228b676 and 958acc7.

📒 Files selected for processing (2)
  • cvat-ui/src/components/paid-feature-placeholder/styles.scss (1 hunks)
  • cvat-ui/src/components/quality-control/styles.scss (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • cvat-ui/src/components/paid-feature-placeholder/styles.scss
🔇 Additional comments (2)
cvat-ui/src/components/quality-control/styles.scss (2)

134-136: Verify the visual impact of the increased table height

The max-height increase of 1 grid unit is minimal, but please ensure this fixes the intended UI issue without causing any content overlap with adjacent elements.

Consider documenting the reason for this specific height adjustment in a code comment to help future maintainers understand the precise measurement requirement.


142-142: Consider implications of fixed height

Changing from max-height to height makes the tab pane height fixed rather than flexible. While scrolling is handled by the extended .cvat-quality-scrollbar class, please verify:

  1. Content doesn't get cut off in various viewport sizes
  2. The user experience remains smooth when content exceeds the fixed height
  3. The height reduction (from 35 to 33 grid units) doesn't cause layout issues

Consider using CSS Grid or Flexbox for more flexible layouts that can adapt to different content sizes and viewport dimensions.


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@klakhov klakhov changed the title Hotfix: Hotfix: excessive scrollbar on quality page Nov 21, 2024
Copy link

sonarcloud bot commented Nov 21, 2024

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 74.18%. Comparing base (228b676) to head (958acc7).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #8729   +/-   ##
========================================
  Coverage    74.18%   74.18%           
========================================
  Files          401      401           
  Lines        43513    43513           
  Branches      3953     3953           
========================================
+ Hits         32281    32282    +1     
+ Misses       11232    11231    -1     
Components Coverage Δ
cvat-ui 78.50% <ø> (+<0.01%) ⬆️
cvat-server 70.49% <ø> (ø)
---- 🚨 Try these New Features:

@klakhov klakhov merged commit 3d7e2c7 into develop Nov 21, 2024
34 checks passed
@bsekachev bsekachev deleted the kl/gt-issues branch December 3, 2024 06:25
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.

3 participants