Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign up`sidenotes` don't appear to work #40
Comments
|
That is a left-over of the original Tufte style we started from. In the beginning I wanted to keep the text unchanged. Of course I changed some style preference along the way. But maybe it is time to review that. Would you be able to take a second look and maybe make a short list of things that need cleanup. I may have tunnel vision :) |
|
The sidenotes issue could be related to a |
|
I mostly use pdf mode; the regexp fix is in the html helper function which could explain why I haven't come across this. |
|
apparently the fix for this is to line 201 in the The issue has to do with the change to pandoc 2.7.3 being the standard pandoc version now distributed with Rstudio. This is also have the side effect (no pun intended) of the references no longer being transformed into a margin note either when knitting to html. I assume line 221 I almost exclusively use the html version so I don't know if this is an issue with the conversion to pdf as well, now that the pandoc version has changed. |
|
Nice find! Your comment was really hard to read, though. GitHub supports triple-backtick 'diff' notation though and the link helped. I just commited that to tint now and rolled the minor version. Can you try that version and report back? |
|
I updated tint using |
|
That would be 0.1.2.1, but yes. Sorry, but that was all I time for. Maybe you can fetch the html.R pages of both tufte and tint and look a little more closer. There was more delta than just that one regexp line... |
|
Ok, I gave it another spin which seems to work for me here on a sample document processed as |
|
Now also in master. |
|
I gave it a whirl last night - the footnotes now convert to sidenotes, thanks! The references still don't convert to sidenotes though when converting to html. Using
in my YAML header I get a similar effect as previously with the footnotes where you still get the inline citation as a "link" (i.e. it's underlined) but when you click on it it doesn't take you to the references. I have found a work around where adding -
At the end of my document adds the references I've used throughout the document and then the citations are hyperlinks that take you to the reference. |
|
Is there are a particular reason you didn't report that back? Anyway -- fixed in a new branch. |
|
yeah - "last night" would probably be more accurately described as "wee hours of the morning" ... so reporting back in the comment above was one of the first things I did this morning. |
|
I understand how it goes. But thanks for continuing to probe. It seems that subtle changes in pandoc required subtle changes in the R code preparing it -- and package |
|
Yes, the footnotes in the developmental version convert as they should; though references do not. Using the
the references do convert into sidenotes as expected. I dug through the issues/change log to track down the updates that were made; there seems to be two relevant changes, first here and then here; both update the I forked a copy of the repository and replaced the |
|
Did you look at the most recent version that I was refering to? based on eg this updated input (partial source snippet)
Also, I think you continue to underestimate how a collection of code refers to more than commit. Your original #40 (comment) already made that sin, it may make sense for you to realise that there is more involved. I would recommend you stop looking at isolated commits, and, if you can, actually compare (and run code). |
Turns out you couldn't as I hadn't pushed that. Ah well. My bad. I gotta concentrate on some other, so if you want to help help beyond the useful nudges you have given consider writing a pull request. |
|
@sjoleary Thanks for all the nudges. The version in the main branch should now be ready. If you have time to give it another go, great -- if not just let me know. It is probably ready for a quick new release. |
|
I installed the developmental version (1.2.2) and used it to knit a more complicated document that has references from a |
|
Excellent, thanks again for testing, and of course the confirmation! Will roll this up for CRAN tomorrow or Saturday (as maybe a new RcppArmadillo comes first). I am still tied to pdf as the final product as ~30 years of latex are hard to undo :) Even if the last five or so were driven from RMarkdown. So I use html less, and this mode fell behind. Because of LaTeX I use As for the mechanics, part of the fun of doing what became the quarted of There are only two or three key gotchas:
It's doable, and if you have a fun project to try, not too bad. Then again, we all have actual real work to do so ... ;-) |
|
Thanks for the pointers ... I'll definitely file this away for when I'm ready to go down that rabbit hole! |

Love the theme. But it looks like sidenotes:
Any use of a footnote will automatically be converted to a sidenote. ^[This is a sidenote that was entered using a footnote.]don't seem to work. The sidenote number is printed -- but the note itself isn't.
In your demo, none of the sidenotes are printed: https://eddelbuettel.github.io/tint/tintHTML.html#fn1