Skip to content

Commit

Permalink
Added information on how to syle markdown using CSS in README
Browse files Browse the repository at this point in the history
  • Loading branch information
atteggiani committed Apr 22, 2024
1 parent f05e416 commit 6b8947d
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 27 deletions.
15 changes: 14 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,21 @@ Please follow the guidelines below so as to make the Hive consistent among the p
- Code lines/blocks need to be used for lines/blocks of code and terminal commands;
- Italic needs to be used when referring to specific proper nouns (for example *Gadi* or *payu*);
- Bold can be used to highlight some words (please do not overuse it);
- All types of admonitions (info, warning, etc.), collapsible and not, can be used as described in the [documentation](https://squidfunk.github.io/mkdocs-material/reference/admonitions/), but they are rendered slightly differently. If you need to use the HTML version of them, please refer to the [HTML/Markdown cheatsheet](#HTML/markdown-cheatsheet).
- All types of admonitions (info, warning, etc.), collapsible and not, can be used as described in the [documentation](https://squidfunk.github.io/mkdocs-material/reference/admonitions/), but they are rendered slightly differently. For the HTML version of them, please refer to the [HTML/Markdown cheatsheet](#HTML/markdown-cheatsheet).
- Instructions for different versions (for example different operative systems or different model versions) can be rendered using tabs (see [HTML/Markdown cheatsheet](#HTML/markdown-cheatsheet));

### Styling Markdown using CSS
To style Markdown using custom CSS, you can add the markdown content inside a \<div> tag having the `markdown` attribute.<br>You can then style the \<div> tag using CSS (in-line or adding selectors to the `access-nri.css` file).

For example, to render a markdown section with half font-size, you can write the following:
```
<div markdown style="font-size: 0.5em;">
### Section with half font-size (This will appear in the table of content)
- First _bullet_ point
- Second bullet **point**
</div>
```

### HTML/Markdown Cheatsheet for the Hive
|Style|Markdown Syntax|HTML Syntax|Rendered example|
Expand All @@ -34,6 +46,7 @@ Please follow the guidelines below so as to make the Hive consistent among the p
|**Collapsible [Admonition](https://squidfunk.github.io/mkdocs-material/reference/admonitions/#usage)**|??? warning title<br>&emsp;this is a collapsible<br>&emsp;warning admonition|\<details class="warning"><br>&emsp;\<summary><br>&emsp;&emsp;\<p><br>&emsp;&emsp;&emsp;this is a collapsible<br>&emsp;&emsp;&emsp;warning admonition<br>&emsp;&emsp;\</p><br>&emsp;\</summary><br>\</details>|![collapsible warning admonition](docs/assets/assets_for_readme/collapsible_warning_admonition.gif)|
|**Tabs**|N/A|\<div class="tabLabels" label="your-tab-label"><br>&emsp;\<button>Tab1\</button><br>&emsp;\<button>Tab2\</button><br>\</div><br>\<div class="tabContents" label="your-tab-label"><br>&emsp;\<div><br>&emsp;&emsp;Content for tab1<br>&emsp;\</div><br>&emsp;\<div><br>&emsp;&emsp;Content for tab2<br>&emsp;\</div><br>\</div>|![tabs](docs/assets/assets_for_readme/tabs.gif)|


# License
The ACCESS-Hive site is covered by the [CC-BY 4.0 license](https://creativecommons.org/licenses/by/4.0/legalcode).

Expand Down
43 changes: 17 additions & 26 deletions docs/models/run-a-model/run-access-om.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% set model = "ACCESS-OM2" %}
{% set access_om2_configs = "https://github.com/ACCESS-NRI/access-om2-configs" %}
[cosima]: "https://cosima.org.au"
[cosima]: https://cosima.org.au
[PBS job]: https://opus.nci.org.au/display/Help/4.+PBS+Jobs
[payu]: https://github.com/payu-org/payu
[model components]: https://access-hive.org.au/models/configurations/access-om/#model-components
Expand Down Expand Up @@ -537,13 +537,13 @@ For more information about specific `userscripts` fields, check the relevant sec

The following configuration settings should never require changing:

```yaml
stacksize: unlimited
mpirun: --mca io ompio --mca io_ompio_num_aggregators 1
qsub_flags: -W umask=027
env:
UCX_LOG_LEVEL: 'error'
```
```yaml
stacksize: unlimited
mpirun: --mca io ompio --mca io_ompio_num_aggregators 1
qsub_flags: -W umask=027
env:
UCX_LOG_LEVEL: 'error'
```

To find out more about configuration settings for the `config.yaml` file, refer to [how to configure your experiment with payu](https://payu.readthedocs.io/en/latest/config.html).

Expand All @@ -557,22 +557,13 @@ To modify these options please refer to the User Guide of the respective model c

----------------------------------------------------------------------------------------

<!-- References -->
<!-- References
Need HTML heading to avoid showing refeerences in the table of content-->
<h6>References</h6>
<ul class="references">
<li>
<a href="https://cosima.org.au" target="_blank">https://cosima.org.au</a>
</li>
<li>
<a href = "http://doi.org/10.5194/gmd-13-401-2020" target="_blank">Kiss et al. (2020)</a>
</li>
<li>
<a href = "https://payu.readthedocs.io/en/latest/usage.html" target="_blank">https://payu.readthedocs.io/en/latest/usage.html</a>
</li>
<li>
<a href = "https://github.com/access-nri/access-om2/" target="_blank">https://github.com/access-nri/access-om2/</a>
</li>
<li>
<a href = "https://opus.nci.org.au/" target="_blank">https://opus.nci.org.au/</a>
</li>
</ul>
<div class="references" markdown>
- [https://cosima.org.au](https://cosima.org.au)
- [Kiss et al. (2020)](http://doi.org/10.5194/gmd-13-401-2020)
- [https://payu.readthedocs.io/en/latest/usage.html](https://payu.readthedocs.io/en/latest/usage.html)
- [https://github.com/access-nri/access-om2](https://github.com/access-nri/access-om2)
- [https://opus.nci.org.au/](https://opus.nci.org.au/)
</div>

0 comments on commit 6b8947d

Please sign in to comment.