wolfe-pack / moro

Interactive documentation and programming with Scala, iPython notebook style.
http://wolfe-pack.github.io/moro
BSD 2-Clause "Simplified" License
19 stars 3 forks source link

Rendering math on reveal breaks #69

Closed riedelcastro closed 9 years ago

riedelcastro commented 9 years ago

We have problems rendering math on reveal slides. Rendering on the editor and static works fine. For example, we have the following markdown

the **inner product** is \\(\langle u,v \rangle := \sum_{l=1}^L u_{l} v_l\\)

which doesn't render properly on the present view (unfortunately sometimes it does) but fine on other views.

sameersingh commented 9 years ago

This probably has to do with the way reveal does the rendering, and it's interaction with the Markdown stuff.

Just to make sure, it breaks on present as well, and not only on the wolfe version of present?

On Thu, Jun 25, 2015 at 6:49 AM, Sebastian Riedel notifications@github.com wrote:

We have problems rendering math on reveal slides. Rendering on the editor and static works fine. For example, we have the following markdown

the inner product is (\langle u,v \rangle := \sum{l=1}^L u{l} v_l)

which doesn't render properly on the present view (unfortunately sometimes it does) but fine on other views.

— Reply to this email directly or view it on GitHub https://github.com/wolfe-pack/moro/issues/69.

riedelcastro commented 9 years ago

Yes, normal present.

sameersingh commented 9 years ago

Seems to be working for me. Can you give me an example of a notebook where this happens?

Preferably check in a simple notebook as public/docs/test.json.

andreasvlachos commented 9 years ago

Hi Sameer, thanks for your help. I just pushed a test.son file with the example: acl2015tutorial/src/main/moro/test.json

At least on my setup, it renders fine in editor mode, but not in present.

Thanks again, Andreas

sameersingh commented 9 years ago

Where's the repo? On Jul 1, 2015 18:34, "Andreas Vlachos" notifications@github.com wrote:

Hi Sameer, thanks for your help. I just pushed a test.son file with the example: acl2015tutorial/src/main/moro/test.json

At least on my setup, it renders fine in editor mode, but not in present.

Thanks again, Andreas

— Reply to this email directly or view it on GitHub https://github.com/wolfe-pack/moro/issues/69#issuecomment-117656496.

riedelcastro commented 9 years ago

https://github.com/uclmr/acl2015tutorial (you should have access now)

sameersingh commented 9 years ago

b3a9e27d909e53f31bf3451b3a79f438971c3735 should fix it (it works on the test that @andreasvlachos provided).

Basically I had to revert the reveal Markdown renderer, and instead use the Moro one, since the reveal one replaces some of the nested braces with italics, which then MathJax cannot access. If the reason to pick the reveal markdown was just to offload server effort, then everything should just work, but if external Markdown makes slides look weird (strutters, sudden pop-in, zooming weirdities), let me know.

riedelcastro commented 9 years ago

Hmm, seems like some of the fragment animations stopped to work after the latest pull. Things still worked at commit f00ffe5c09fd13d893fb27c4af0d5f7726fc1223. The slide that doesn't work is on http://localhost:9000/template/present/04_binarymf (the Logistic Loss Slide).

riedelcastro commented 9 years ago

Recent changes also stopped rendering of the results graph on the last slide of http://localhost:9000/template/present/04_binarymf. Again this still worked at f00ffe5c09fd13d893fb27c4af0d5f7726fc1223.

riedelcastro commented 9 years ago

Also, it seems that using mathjax in HTML cells avoids the problem. What's more, if I put the html cell with the math on the same slide as the markdown version, the markdown version also works!

andreasvlachos commented 9 years ago

Also, not sure if it is related, but the last slide of the notebook appears empty. This is the case at least with 01_motiv and 04_binarymf. It would be good if someone could verify this, just in case I am doing something wrong. The angle brackets in maths though work fine.

Thanks, Andreas

On 6 Jul 2015, at 11:28, Sebastian Riedel notifications@github.com wrote:

Hmm, seems like some of the fragment animations stopped to work after the latest pull. Things still worked at commit f00ffe5. The slide that doesn't work is on http://localhost:9000/template/present/04_binarymf (the Logistic Loss Slide).

— Reply to this email directly or view it on GitHub.