This repository contains the Chaste website. It is automatically built from markdown files by Hugo using GitHub Actions.
This site is available here: https://chaste.github.io/
main. main the site will be automatically built and deployed and will be live roughly 1 minute later.
This site uses the doks theme which requires you to have installed npm.
Navigate to the site directory, run the following command, which only needs to be run once:
cd Chaste.github.io/site
npm installTo preview changes, stay in this folder and run:
npm run devand click through to the localhost link you're given.
- The top-level banner menu is in
site/config/_default/menus/menus.en.toml - All pages are in
site/content/ - Static content such as photos is in
site/static, following the directory structure of the page it is required in
Top level navigation pages, e.g. team, correspond to subdirectories.
Homepages are _index.md in each top level content directory.
All subpages are name.md, where name corresponds to the part of the URL after the top level.
ℹ️ ℹ️ ℹ️
For almost all changes, you should only need to edit markdown in markdown files. Some examples are:
- To edit https://chaste.github.io/team/, modiy site/content/team/_index.md (top level page)
- To edit https://chaste.github.io/components/cell-based/, modiy site/content/en/components/cell-based.md (sub-page of "components")
ℹ️ ℹ️ ℹ️
Links can either be relative or absolute.
- Links to other pages within the
docsdirectory should be relative, so that when release bundles are created, navigation works properly within each bundle. - Any link to a page outside
docsshould be absolute, so that they still work (and take you to the latest verison) from within a release bundle.
Example relative link:
[link name](../../user-guides/cmake-first-run/)Example absolute link:
[link name](/components/cardiac/)When using an absolute link, the link must start with a / (or it's considered relative to the current location), and must specify everything after the root (in this case, everything after https://chaste.github.io).
To create a new page, copy a directory such as site/content/team/.
Edit the new _index.md to add page content as required.
To make the page visible in the site navigation, add a relevant section to the data file site/config/_default/menus/menus.en.toml.
-
To disable previous/next navigation within a single directory, set
disable_adjacent_navigation: truein that directory's_index.mdfrontmatter. This only affects pages in the same directory, not subdirectories. -
To render fenced code blocks using the terminal styling (e.g. for a complete code file), add a title attribute, for example:
```cpp {title="MyPaperTutorial.hpp"} std::vector<double> my_vec; ... ```