flw0 / equation-editor-react

Equation editor based on Mathquill for React web apps
https://flw0.github.io/equation-editor-react/
MIT License
62 stars 14 forks source link

How to use ChemArrow accents #32

Closed Kaliyani closed 1 year ago

Kaliyani commented 3 years ago

I want to use below extension symbols,

Screenshot 2021-10-02 at 8 04 01 AM Screenshot 2021-10-02 at 8 04 22 AM Screenshot 2021-10-02 at 8 04 40 AM Screenshot 2021-10-02 at 8 05 02 AM

I am planning to use this equation editor to one my academic related project which is based React. Can you help me to solve this issue.

V0XNIHILI commented 3 years ago

Hey! The equation editor is built on top of Mathquill. I just tried some of the symbols that you need (\xrightarrow, \overleftrightarrow) on their website (http://mathquill.com/) but they do not seem to work there. Basically this means that the underlying editor lacks support for it... Maybe for you it would be an alternative to use KaTeX (https://katex.org/), since they do have support for the arrows you need. Lemme know if that is a solution for you!

Kaliyani commented 3 years ago

@V0XNIHILI Thank you so much for your quick response. Actually I am looking for math editor like your's. We are planning to feed more science related content to database for our future purpose. Your solution is exactly matching my requirement except few scenarios as I mentioned above. I have gone through react-katex. If I want to display integral with superscript limit and subscript limit, I need to enter \int^2_3 in react-katex. But in your library, in edit box if i enter int the subscript and subscript limit I can enter in edit box itself. Latex code will be generated automatically. I am looking for this kind of solutions. Can you help to achieve this.

V0XNIHILI commented 3 years ago

I understand. If you want, you can make a pull request in src/commands/math/commands.js or src/commands/math/advancedSymbols.js in the MathQuill repo, as the editing functionality stems from that project.