jabref icon indicating copy to clipboard operation
jabref copied to clipboard

Copy entry preview should copy real HTML

Open koppor opened this issue 11 months ago • 12 comments

This is a follow up to https://github.com/JabRef/jabref/pull/12576 and a real fix for https://github.com/JabRef/jabref/issues/12551.

Example entry preview - based on Chocolate.bib; Richard_2017:

Image

I press "copy citation (html)":

Image

Then following HTML is in the clipboard:

<!DOCTYPE html>
<html>
   <head>
      <meta charset="utf-8">
   </head>
   <body>

 Article (Richard_2017)
Richard, Anna / Meule, Adrian / Friese, Malte / Blechert, Jens

Effects of Chocolate Deprivation on Implicit and Explicit Evaluation of Chocolate in High and Low Trait Chocolate Cravers 
2017-09


Frontiers in Psychology  , Vol. 8


Frontiers Media SA





 
   </body>
</html>

All highlithing lost.

Reason: org.jabref.gui.preview.PreviewViewer#copyPreviewHtmlToClipBoard calls getTextContent. -- This implementation should be changed to use the same functionality as "Copy Preview" of the main table.

Image


The main table copy works correct

Paste result in word:

Image


Hint: org.jabref.gui.preview.CopyCitationAction should be used. - see org.jabref.gui.maintable.RightClickMenu how to initialize; maybe they can be stored globally. Check how it is done in other places of JabRef.

The code uses org.jabref.gui.preview.ClipboardContentGenerator#generateCitations to generate the HTML.

koppor avatar May 01 '25 20:05 koppor

/assign-me

antPinot avatar May 02 '25 08:05 antPinot

👋 Hey @antPinot, thank you for your interest in this issue! 🎉

We're excited to have you on board. Start by exploring our Contributing guidelines, and don't forget to check out our workspace setup guidelines to get started smoothly.

In case you encounter failing tests during development, please check our developer FAQs!

Having any questions or issues? Feel free to ask here on GitHub. Need help setting up your local workspace? Join the conversation on JabRef's Gitter chat. And don't hesitate to open a (draft) pull request early on to show the direction it is heading towards. This way, you will receive valuable feedback.

Happy coding! 🚀

github-actions[bot] avatar May 02 '25 08:05 github-actions[bot]

⏰ Assignment Reminder

Hi @antPinot, this is a friendly reminder about your assignment to this issue.

[!WARNING] This issue will be automatically unassigned in 11 days if there's no activity.

How to keep your assignment


If you are working on it, you can prevent automatic unassignment by:

  • Submitting a draft PR with your progress
  • Asking for the 📌 Pinned label if you need more time

We appreciate your contribution and are here to help if needed!

github-actions[bot] avatar May 20 '25 12:05 github-actions[bot]

/assign-me

prathamxx avatar Jun 02 '25 14:06 prathamxx

⚠️ Issue Already Assigned

Hi @prathamxx, this issue is currently assigned to @antPinot.

[!NOTE] If no progress is made within 14 days, the issue will be automatically unassigned.

Options for contributors
  • Wait for availability: The issue may become available if auto-unassigned
  • Collaborate: You can ask the assignee if they want help
  • Maintainer assistance: A maintainer can add you as co-assignee if appropriate

github-actions[bot] avatar Jun 02 '25 14:06 github-actions[bot]

I think our assignment action cannot count days correctly ^^

koppor avatar Jun 02 '25 14:06 koppor

/assign @prathamxx

koppor avatar Jun 02 '25 14:06 koppor

👋 Hey @prathamxx, thank you for your interest in this issue! 🎉

We're excited to have you on board. Start by exploring our Contributing guidelines, and don't forget to check out our workspace setup guidelines to get started smoothly.

For questions on JabRef functionality and the code base, you can consult the JabRef Guru or ask on our Gitter chat.

In case you encounter failing tests during development, please check our developer FAQs!

Having any questions or issues? Feel free to ask here on GitHub. Need help setting up your local workspace? Join the conversation on JabRef's Gitter chat. And don't hesitate to open a (draft) pull request early on to show the direction it is heading towards. This way, you will receive valuable feedback.

Happy coding! 🚀

github-actions[bot] avatar Jun 02 '25 14:06 github-actions[bot]

⏰ Assignment Reminder

Hi @prathamxx, this is a friendly reminder about your assignment to this issue.

[!WARNING] This issue will be automatically unassigned in 11 days if there's no activity.

Remember that you can ask the JabRef Guru about anything regarding JabRef. Additionally, our contributing guide has hints on creating a pull request and a link to our Gitter chat.

How to keep your assignment


If you are working on it, you can prevent automatic unassignment by:

  • Submitting a draft PR with your progress
  • Asking for the 📌 Pinned label if you need more time

We appreciate your contribution and are here to help if needed!

github-actions[bot] avatar Jun 12 '25 12:06 github-actions[bot]

I have already investigated on the key issue and I am working on resolving it.

prathamxx avatar Jun 12 '25 14:06 prathamxx

I have already investigated on the key issue and I am working on resolving it.

Will you be able to file a pull request within the next 10 days? If not, when is your planned date?

koppor avatar Jun 13 '25 06:06 koppor

Hey koppor, i should by done within the next 5-7 days

On Fri, 13 Jun 2025 at 3:33 pm, Oliver Kopp @.***> wrote:

koppor left a comment (JabRef/jabref#13041) https://github.com/JabRef/jabref/issues/13041#issuecomment-2969164581

I have already investigated on the key issue and I am working on resolving it.

Will you be able to file a pull request within the next 10 days? If not, when is your planned date?

— Reply to this email directly, view it on GitHub https://github.com/JabRef/jabref/issues/13041#issuecomment-2969164581, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU4SKDDQIGPQOYSPIJ2QNWD3DJSUBAVCNFSM6AAAAAB4IR52X6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDSNRZGE3DINJYGE . You are receiving this because you were mentioned.Message ID: @.***>

prathamxx avatar Jun 13 '25 06:06 prathamxx

We think that this issue was fixed. Please head to https://builds.jabref.org/main to download a development build and try it out.

For any feedback, add a comment to the pull request at https://github.com/JabRef/jabref/pull/13339.

github-actions[bot] avatar Jun 18 '25 18:06 github-actions[bot]