Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Navigation breaks if iframe is the last line of a md file #818

Closed
MaxGhenis opened this issue Jul 28, 2020 · 7 comments
Closed

Navigation breaks if iframe is the last line of a md file #818

MaxGhenis opened this issue Jul 28, 2020 · 7 comments
Labels
bug Something isn't working

Comments

@MaxGhenis
Copy link
Contributor

Describe the bug
When an iframe is the last line of a md file, without a trailing new line, some page navigation breaks.

To Reproduce
Steps to reproduce the behavior:

  1. jb create jb; cd jb
  2. Add an iframe to the last line of intro.md, e.g.:
<iframe src="https://docs.google.com/spreadsheets/d/e/2PACX-1vQQoN_MKQqvDnUQjQHdCEISGkHYGgsSZVvHOWcv6qia260XbftP3aRh8FsPTXO-mJ8NioM7iSbNouTo/pubhtml?widget=true&amp;headers=false"></iframe>
  1. jb build .
  2. Open _build/html/intro.html, which looks like this:

Screenshot 2020-07-27 at 18 08 36

Expected behavior
This, which is produced when I add a new line to the end of the file.

Screenshot 2020-07-27 at 18 25 42

Environment (please complete the following information):

  • Python 3.7.7
  • Output of jupyter-book --version:
Jupyter Book: 0.7.1
MyST-NB: 0.8.3
Sphinx Book Theme: 0.0.31
MyST-Parser: 0.8.2
Jupyter-Cache: 0.2.2
@MaxGhenis MaxGhenis added the bug Something isn't working label Jul 28, 2020
@choldgraf
Copy link
Member

I think I just fixed this in #817 - wanna try this again on master and see if it fixes your problem?

@MaxGhenis
Copy link
Contributor Author

I'm getting the same result after running pip install git+https://github.com/executablebooks/jupyter-book.git and then jb clean . and jb build ..

@choldgraf
Copy link
Member

hmmm I just tried this on the master branch of jupyter book and it looked fine to me. This is what my intro.md looked like:

Welcome to your Jupyter Book
============================

This is a small sample book to give you a feel for how book content is
structured.

Check out the content pages bundled with this sample book to get started.

<iframe src="https://docs.google.com/spreadsheets/d/e/2PACX-1vQQoN_MKQqvDnUQjQHdCEISGkHYGgsSZVvHOWcv6qia260XbftP3aRh8FsPTXO-mJ8NioM7iSbNouTo/pubhtml?widget=true&amp;headers=false"></iframe>

is that how yours looked?

@choldgraf
Copy link
Member

ahhh nevermind, I just saw your point about "newline". OK I can replicate this if there is no blank line on the page

@choldgraf
Copy link
Member

ok I think that #836 fixes this, wanna upgrade on master and try again?

@MaxGhenis
Copy link
Contributor Author

That did it, thanks!
image

@choldgraf
Copy link
Member

yahoo!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants