From f88cac7733a54e1170b31e0b5676e55ea7ffd81c Mon Sep 17 00:00:00 2001 From: Julie Kirsch Date: Mon, 24 Feb 2025 14:59:54 +0100 Subject: [PATCH] fix toc --- book/_toc.yml | 2 -- book/exercises/008.md | 29 +++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+), 2 deletions(-) diff --git a/book/_toc.yml b/book/_toc.yml index c3d339d..70ae5bb 100644 --- a/book/_toc.yml +++ b/book/_toc.yml @@ -8,7 +8,6 @@ parts: sections: - file: some_content/text_and_code.ipynb - file: exercises - caption: Beginner exercises sections: - file: exercises/001.md - file: exercises/002.md @@ -18,7 +17,6 @@ parts: - file: exercises/006.md - file: exercises/summary - file: advances_exercises.md - caption: Advanced exercises sections: - file: user_type_3.md sections: diff --git a/book/exercises/008.md b/book/exercises/008.md index e69de29..3a7e816 100644 --- a/book/exercises/008.md +++ b/book/exercises/008.md @@ -0,0 +1,29 @@ +# Exercise 8: Add a figure/gif/video + +Now let's add a figure. If you want to add a figure/gif/video to you book, you can refer to another website. This is quite handy for video's but it does carry the risk that this figure/gif/video will no longer be visible if the location is changed. + + + + + +So it is better to add the source directly to the book. So you first need to upload a figure to GitHub and then reference that figure in our file. (Note: later this becomes much easier). + + +```{figure} figures/HubUser3_EditFile2.PNG +--- +width: 80% +align: center +--- +Commit changes +``` + +6. In case you added a new file, you also need to include it table of contents of your book! The table of contents is specified in a file called `toc.yml` and it is already included in your repository if you used the teachbooks template. You can edit it and commit the changes in the same manner as with markdown `(file.md)` files. + +```{figure} figures/HubUser3_toc.PNG +--- +width: 80% +align: center +--- +Table of contents +``` +```` \ No newline at end of file