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

Add toggle to allow Markdown in User Comments in Entry Editor #12407

Closed
ThiloteE opened this issue Jan 20, 2025 · 16 comments
Closed

Add toggle to allow Markdown in User Comments in Entry Editor #12407

ThiloteE opened this issue Jan 20, 2025 · 16 comments

Comments

@ThiloteE
Copy link
Member

ThiloteE commented Jan 20, 2025

JabRef 6.0-alpha.29--2025-01-13--e9da46a
Windows 10 10.0 amd64
Java 23.0.1
JavaFX 23.0.1+4

Is your suggestion for improvement related to a problem? Please describe.
I want to store my AI generated summaries somewhere, because everytime I restart JabRef, they get deleted. Sometimes I want to generate multiple summaries of the same scientific paper. I opted to store the summaries in the comments section of JabRef, but the comments section does not support Markdown and that's annoying, because I want to have responses formated in Markdown.

Describe the solution you'd like
Add toggle that allows users to switch between "Markdown" and "Plaintext" mode.

Additional context
There is currently work being done on adding Markdown to the AI-Chat tab (see #12234), so to add this feature here, some of the code could potentially be re-used. There already is a toggle in the AI-Summary tab.

@github-project-automation github-project-automation bot moved this to Normal priority in Prioritization Jan 20, 2025
@ThiloteE ThiloteE removed the component: ai Related to AI Chat/Summarization label Jan 20, 2025
@priyanshu16095
Copy link
Contributor

priyanshu16095 commented Jan 25, 2025

I am interested in this issue. Please assign me this issue.

@koppor
Copy link
Member

koppor commented Jan 27, 2025

I don't understand what you mean. Comments are plain text.

Do you mean the entry preview? It can be configured to render Markdown.

@ThiloteE
Copy link
Member Author

Yes, Comments are plain texst only right now, but I want them be optionally rendered in Markdown, just like Entry Preview, AI-Summary or AI-Chat.

@koppor
Copy link
Member

koppor commented Jan 27, 2025

I wonder, why this was not touched in #6232

2020 one has the preview in Markdown:

image

@ThiloteE
Copy link
Member Author

ThiloteE commented Jan 27, 2025

Jabref 6.0alpha:
With following preferences:
Image
Comments tab:
Image

@koppor koppor changed the title Add toggle to allow Markdown in "Comments" Tab in Entry Editor Add toggle to allow Markdown in User Comments in Entry Editor Jan 27, 2025
@Siedlerchr
Copy link
Member

This is the wrong place for it. The Markdown Formatter affects only the Entry Preview, and it can be configured for arbitrary fields - if you use JabRef's entry preview (not CSL)
The entry editor itself has no say in this

@ThiloteE
Copy link
Member Author

ThiloteE commented Jan 27, 2025

JabRef 6.0alpha:
With following preferences: Image
Comments tab:
Image

@koppor
Copy link
Member

koppor commented Jan 27, 2025

Task is here to add the functionality to the entry preview. Meaning: Enhancing the #6232. Also add user-speciifc comments fielkds to the rendering.

  • Check/add support for generating markdown rendering in the preview
  • Add preference migration

@koppor
Copy link
Member

koppor commented Jan 27, 2025

/assign @priyanshu16095

@github-actions github-actions bot added the 📍 Assigned Assigned by assign-issue-action (or manually assigned) label Jan 27, 2025
@Siedlerchr Siedlerchr removed the 📍 Assigned Assigned by assign-issue-action (or manually assigned) label Jan 27, 2025
@Siedlerchr
Copy link
Member

@koppor There is nothing to implement here, you would need to adapt the preview:
e-.

"\\begin{comment}<BR><BR><b>Comment: </b> \\format[Markdown,HTMLChars]{\\comment-thilo} \\end{comment}" 

@JabRef JabRef deleted a comment from github-actions bot Jan 27, 2025
@koppor
Copy link
Member

koppor commented Jan 27, 2025

I want it to have WITHOUT configuration!

@koppor
Copy link
Member

koppor commented Jan 27, 2025

I think, currently, it works WITH configuration, but WIHTOUT, it does not --> knob-less JabRef ^^

@koppor koppor added status: devcall 📍 Assigned Assigned by assign-issue-action (or manually assigned) labels Jan 27, 2025
@Siedlerchr
Copy link
Member

Siedlerchr commented Jan 27, 2025

How should this work? It'a user defined/custom field? You would need to explicitly add this to the preview

@koppor
Copy link
Member

koppor commented Jan 27, 2025

It'a user defined/custom field?

No, Added as fix for issue JabRef#543

That field automatically appears. Based on the user name.

@koppor koppor removed the 📍 Assigned Assigned by assign-issue-action (or manually assigned) label Jan 27, 2025
@ThiloteE
Copy link
Member Author

ThiloteE commented Jan 27, 2025

Ok, we found out that it works with the following configuration, but only for the "comment" field.
Image
Here the render:
Image

User specific comment fields do not support Markdown rendering right now.
Currently, selecting a CSL style like "Modern Language Association 9th edition" blocks additional Markdown rendering as well.

@koppor
Copy link
Member

koppor commented Jan 27, 2025

I put it into our internal refinement board, because a real "specification" takes time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants