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 figure previews and fix Zotero-related issues with bib parsing #12

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

cochaviz
Copy link

@cochaviz cochaviz commented Dec 23, 2023

Now also shows table, figure, listing and equation previews in the documentation tab in cmp. Also fix some Zotero-related issues with bib parsing (in Zotero {{}} are added around certain words to add emphasis, but I've decided to just ignore these).

Screencast.from.2023-12-23.14-43-48.webm

The I thought about creating my own regex strings to fix the bib matching, but the ones from the related project https://github.com/aspeddro/cmp-pandoc.nvim/tree/main work very well. Since this is licensed under the MIT license, I've added the appropriate credits there.

I'm also working on a latex preview for the equations, but I'm still working on that. (Just wanted to mention why the latex_preview function is empty).

EDIT: Latex previews now work (using nabla like cmp-pandoc, but implemented slightly differently).

@cochaviz cochaviz marked this pull request as draft December 23, 2023 21:40
@cochaviz
Copy link
Author

Turned it into a draft since my naive implementation is a bit too naive. Will try using the found references as indexes and pattern matching on the reversed string from a match.

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.

1 participant