Skip to content

Conversation

@camiloHimura
Copy link

📝 Description

Fix inference rendering on large screens

Before After
Screenshot 2025-12-12 at 13 10 49 Screenshot 2025-12-12 at 13 11 04
  • Provide a clear summary of the changes and the issue that has been addressed.
  • 🛠️ Fixes # (issue number)

✨ Changes

Select what type of change your PR is:

  • 🚀 New feature (non-breaking change which adds functionality)
  • 🐞 Bug fix (non-breaking change which fixes an issue)
  • 🔄 Refactor (non-breaking change which refactors the code base)
  • ⚡ Performance improvements
  • 🎨 Style changes (code style/formatting)
  • 🧪 Tests (adding/modifying tests)
  • 📚 Documentation update
  • 📦 Build system changes
  • 🚧 CI/CD configuration
  • 🔧 Chore (general maintenance)
  • 🔒 Security update
  • 💥 Breaking change (fix or feature that would cause existing functionality to not work as expected)

✅ Checklist

Before you submit your pull request, please make sure you have completed the following steps:

  • 📚 I have made the necessary updates to the documentation (if applicable).
  • 🧪 I have written tests that support my changes and prove that my fix is effective or my feature works (if applicable).
  • 🏷️ My PR title follows conventional commit format.

For more information about code review checklists, see the Code Review Checklist.

Signed-off-by: Colorado, Camilo <[email protected]>
Copilot AI review requested due to automatic review settings December 12, 2025 12:36
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes the rendering of inference results on large screens by adjusting the layout and positioning of inference overlays to properly align with the displayed images.

Key Changes:

  • Refactored inference result rendering to calculate and use actual image dimensions when displaying overlay
  • Updated CSS positioning and layout structure to use absolute positioning with calculated dimensions
  • Modified selection handler to validate media item IDs before callback

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
fps.component.tsx Reordered properties and added z-index for proper layering
sidebar-items.component.tsx Added validation for media item ID before selection callback
media-preview.component.tsx Added relative positioning to canvas container
util.ts New utility function to calculate rendered image dimensions with object-fit contain
inference-result.module.scss Updated CSS to use absolute positioning and removed duplicate styles
inference-result.component.tsx Refactored to track image dimensions and position inference overlay accordingly
virtualizer-grid-layout.module.scss Changed thumbnail object-fit from contain to cover

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Signed-off-by: Colorado, Camilo <[email protected]>
@camiloHimura camiloHimura force-pushed the ccolora11/preview-inference branch from 3fb4354 to 3121977 Compare December 12, 2025 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant