Skip to content

Fix for issue 13234 #13283

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

Closed
wants to merge 4 commits into from
Closed

Conversation

YaxPrajapti
Copy link

Closes #13234

This PR enhances the "Citation relations" feature by making the "Look up a DOI and try again." text a clickable hyperlink. On clicking, the text changes to "Looking up DOI...". Based on the lookup result:

If a DOI is found, it is used for citation relations.

If no DOI is found, a notification "No DOI found" is shown and the link resets to its original state.

Steps to test

  • Add a paper in jabRef entry editor.
  • Go to citation relations. You will see hyperlink. Click on that hyperlink.
Screenshot 2025-06-09 at 5 05 12 PM

Mandatory checks

  • I own the copyright of the code submitted and I license it under the MIT license
  • Change in CHANGELOG.md described in a way that is understandable for the average user (if change is visible to the user)
  • [/] Tests created for changes (if applicable)
  • [/] Manually tested changed features in running JabRef (always required)
  • Screenshots added in PR description (if change is visible to the user)
  • Checked developer's documentation: Is the information available and up to date? If not, I outlined it in this pull request.
  • Checked 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 to the documentation repository.

@jabref-machine
Copy link
Collaborator

Your pull request conflicts with the target branch.

Please merge upstream/main 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.

new Label(Localization.lang("The selected entry doesn't have a DOI linked to it. Lookup a DOI and try again.")));

Text doiLookUpText = new Text(Localization.lang("The selected entry doesn't have a DOI linked to it. "));
Hyperlink doiLookUpHyperLink = new Hyperlink(Localization.lang("Lookup a DOI and try again."));
Copy link

Choose a reason for hiding this comment

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

The hyperlink text 'Lookup a DOI and try again.' should be sentence case, starting with a lowercase letter, to maintain consistency with other UI elements.

entry.setField(StandardField.DOI, doiIdentifier.get().asString());
searchForRelations(entry, listView, abortButton, refreshButton, searchType, importButton, progress, shouldRefresh);
} else {
dialogService.notify("No DOI found");
Copy link

Choose a reason for hiding this comment

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

The notification message 'No DOI found' should be sentence case, starting with a lowercase letter, to maintain consistency with other UI elements.

@YaxPrajapti YaxPrajapti closed this Jun 9, 2025
@YaxPrajapti YaxPrajapti deleted the fix-for-issue-13234 branch June 9, 2025 11:45
@YaxPrajapti YaxPrajapti restored the fix-for-issue-13234 branch June 9, 2025 12:10
@koppor
Copy link
Member

koppor commented Jun 10, 2025

Follow-up #13285

@YaxPrajapti No need to delete branches and close PRs. Please just add new commits. In the concrete case, continue to work on fix-for-issue-13234 and keep it open!

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.

Automatic lookup of DOI at citation relations
3 participants