jabref icon indicating copy to clipboard operation
jabref copied to clipboard

Area of preview on hover should be shrink to the size of the text displayed

Open samol123456 opened this issue 3 months ago • 4 comments

Closes #12351

This PR improves the sizing behavior of the entry-table tooltip when the preview feature is enabled. Previously, the tooltip became significantly larger than the actual preview content due to missing layout constraints. The fix adjusts the tooltip container and the PreviewViewer sizing logic so the tooltip now adapts to its preferred size and remains compact.

Steps to test

Open Preferences → Entry preview.

Enable: “Show preview in entry table tooltip”.

Hover over any entry in the main table.

Observe that the tooltip now:

matches the size of the preview content,

no longer grows excessively,

remains readable and compact.

image

Mandatory checks

  • [x] I own the copyright of the code submitted and I license it under the MIT license
  • [x] I manually tested my changes in running JabRef (always required)
  • [x] I added JUnit tests for changes (if applicable)
  • [x] I added screenshots in the PR description (if change is visible to the user)
  • [x] I described the change in CHANGELOG.md in a way that is understandable for the average user (if change is visible to the user)
  • [x] I checked the user documentation: Is the information available and up to date? If not, I created an issue at https://github.com/JabRef/user-documentation/issues or, even better, I submitted a pull request updating file(s) in https://github.com/JabRef/user-documentation/tree/main/en.

samol123456 avatar Nov 30 '25 21:11 samol123456

Hey @samol123456!

Thank you for contributing to JabRef! Your help is truly appreciated :heart:

We have automated checks in place, based on which you will soon get feedback if any of them are failing. In a while, maintainers will also review your contribution. Once that happens, you can go through their comments in the "Files changed" tab and act on them, or reply to the conversation if you have further inputs.

Please re-check our contribution guide in case of any other doubts related to our contribution workflow.

github-actions[bot] avatar Nov 30 '25 21:11 github-actions[bot]

Okay we are going to fix it

samol123456 avatar Nov 30 '25 23:11 samol123456

Your pull request conflicts with the target branch.

Please merge with your code. For a step-by-step guide to resolve merge conflicts, see https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/addressing-merge-conflicts/resolving-a-merge-conflict-using-the-command-line.

github-actions[bot] avatar Dec 02 '25 08:12 github-actions[bot]

@samol123456 Please use English words for commit messages (in future)

koppor avatar Dec 03 '25 21:12 koppor