Skip to content

Comments

Math Formula Support: Integrated remark-math and rehype-katex to render LaTeX formulas#199

Open
arnab9957 wants to merge 5 commits intoHarshYadav152:mainfrom
arnab9957:arnab9957-math
Open

Math Formula Support: Integrated remark-math and rehype-katex to render LaTeX formulas#199
arnab9957 wants to merge 5 commits intoHarshYadav152:mainfrom
arnab9957:arnab9957-math

Conversation

@arnab9957
Copy link

Key Changes #158
Frontend Enhancements
Math Formula Support: Integrated remark-math and rehype-katex to render LaTeX formulas. Supported syntaxes include $inline$ and $$block$$.
Markdown Tables: Enabled GFM-style comparison tables.
Editor Helpers:
Added "∑ Math" and "⊞ Table" helper buttons to insert template syntaxes.
Added a Preview Mode to verify rendering before saving.
New Study Template for quick note structure setup.
Enhanced Media Rendering:
Updated
NoteItem.js
to render images, voice notes, and PDF attachments in the full-view (zoom) modal.
Improved PDF attachment UI with file size and type indicators.
Backend & API Fixes
Notes API Updates: Modified POST /api/notes and PUT /api/notes/[id] to extract and persist the attachments array.
Upload Logic Fix: Corrected a naming inconsistency in the attachment upload form data (changed files to attachment) to match the backend expectations.
Data Persistence: Ensured attachments are correctly stored in the MongoDB
Notes
collection.
Bug Fixes
Resolved a 401/Unauthorized issue in the local dev environment caused by a MongoDB port conflict. Reconfigured the local setup to use a dedicated port (27019) for the project database.
Verification Results
Math Rendering: Verified that complex formulas (e.g., integrals, Einstein's field equations) render correctly via KaTeX.
Table Support: Confirmed that structured markdown tables render into valid HTML tables with proper alignment.
Attachment Flow: Successfully tested the upload, storage, and retrieval of PDF files.
Rendering Preview
Verified Math and Table Rendering

Deployment Notes
Ensure Cloudinary environment variables are set for handling raw resource types (required for PDFs).
MongoDB instance should be running and accessible as per the updated
.env.local
.

@vercel
Copy link

vercel bot commented Feb 23, 2026

@arnab9957 is attempting to deploy a commit to the Harsh Yadav's projects Team on Vercel.

A member of the Team first needs to authorize it.

Copy link
Owner

@HarshYadav152 HarshYadav152 left a comment

Choose a reason for hiding this comment

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

@arnab9957 Your issue for adding Math formulas and Table comparison support.
But your changes to unnecessary files.
Will you explain your work ?

  1. Login/Register page
  2. Similar api route
    • savebook/app/api/auth/register/route.js
    • savebook/app/api/auth/update-profile/route.js
    • savebook/app/api/auth/user/route.js
    • savebook/app/profile/page.js
  3. Why you add .backup files remove them.
  4. Made any changes to AddNote only no need to make AddNoteEnhanced
  5. There are some problem in NoteItem.js
  6. And why you remove toggleShare from NoteState also isPublic from Note model.
  7. Do not remove or change any previous feature.
  8. Also unnecesary modification in User model.
  9. Remove savebook/activate_features.sh file no need of this.
  10. Also remove add_study_features.sh
  11. Also remove NoteItem_updates.txt from root.

Do these changes and let me know and remember modifies only files related to your issue.

@VinayKumar42 VinayKumar42 added the jwoc-2026 For JWoC evaluation label Feb 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

jwoc-2026 For JWoC evaluation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants