grunwaldlab / Reproducible-science-in-R

This site provides information on conducting reproducible science using the R language.
http://grunwaldlab.github.io/Reproducible-science-in-R/
14 stars 8 forks source link

Do something about the TOC not working right #28

Closed zachary-foster closed 8 years ago

zachary-foster commented 8 years ago

I tried to fix this in quiltr last night, but it is a complicated problem. Basically, the HTML anchors need to be opened in the iframe they are in. This is different than links to external sites, which need to open in a new window. Even if the two type are automatically differentiated (which should be possible by applying the css target: "_self" to "a" elements in the "TOC" div), it is uncertain wether it is possible to use HTML anchors in iframes in firefox:

This page uses anchors in an iframe; it does not work with firefox, but does work with chrome).

I can think of the following solutions:

Thoughts?

zkamvar commented 8 years ago

I think for the time being the best idea would be to remove the TOC all together since we are so close to the workshop. Later, we can refine this.

We used a prototype of the procedure outlined in your last point for the population genetics in R website. It used to involve hand-coding the dropdown menu, but it looks like that's not necessary anymore with their _site.yml.

zkamvar commented 8 years ago

I've been thinking about this and, given the fact that quiltr is not meant to create proper websites and the fact that linking in iframes is not possible without javascript, the best option for this website in the future is to utilize the procedure outlined in the rmarkdown documents.

zachary-foster commented 8 years ago

I agree.