Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,6 @@ $ poetry install
You can choose a language for build from `ja` or `en`.

```sh
$ poetry run python misc/split_notebook.py
$ poetry run make html -e LANG="ja"
```
99 changes: 0 additions & 99 deletions docs/_static/css/cookie-consent.css

This file was deleted.

20 changes: 20 additions & 0 deletions docs/_static/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,23 @@
.md-icon.md-icon--menu.md-header-nav__button {
margin-top: 17px;
}

.nboutput .output_area .highlight pre {
word-break: break-all;
word-wrap: break-word;
white-space: pre-wrap;
}

.md-typeset__table .head code.docutils{
background: #616161;
padding: 2px;
white-space: nowrap;
font-weight: bold;
color: #FFF;
}

.md-typeset h1,
.md-typeset h2 {
color: rgba(0,0,0,.87);
font-weight: bold;
}
1 change: 0 additions & 1 deletion docs/_static/js/cookie-consent-init.umd.js

This file was deleted.

3 changes: 0 additions & 3 deletions docs/_static/js/cookie-consent.umd.js

This file was deleted.

7 changes: 7 additions & 0 deletions docs/_static/js/external-link.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
$(document).ready(function () {
$('a[href^="http://"], a[href^="https://"]').not('a[class*=internal]').attr({
target: '_blank',
referrerpolicy: "no-referrer",
rel: "noopener noreferrer"
});
});
7 changes: 7 additions & 0 deletions docs/_templates/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,13 @@
<span class="md-header-nav__topic"> {{ title|striptags|e }} </span>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<div style="width: 85px; height: 57px; font-size: 16px; line-height: 57px;">
<a href="https://docs.matlantis.com/atomistic-simulation-tutorial/ja/" hreflang="ja">JA</a>
|
<a href="https://docs.matlantis.com/atomistic-simulation-tutorial/en/" hreflang="en">EN</a>
</div>
</div>
<div class="md-flex__cell md-flex__cell--shrink">
<label class="md-icon md-icon--search md-header-nav__button" for="__search"></label>
{% include "searchbox.html" %}
Expand Down
4 changes: 2 additions & 2 deletions docs/_templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
{% block htmltitle %}
{{ super() }}
<!-- Workaround: need to import cookie-consent library before importing require.js -->
<script src="_static/js/cookie-consent.umd.js"></script>
<script src="_static/js/cookie-consent-init.umd.js"></script>
<script src="https://docs.matlantis.com/assets/js/cookie-consent.umd.js"></script>
<script src="https://docs.matlantis.com/assets/js/cookie-consent-init.umd.js"></script>
{% endblock %}

{% block relbar1 %}
Expand Down
4 changes: 3 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,11 @@

html_css_files = [
'css/custom.css',
'css/cookie-consent.css',
'https://docs.matlantis.com/assets/css/cookie-consent.css',
]

html_js_files = ['js/external-link.js']

# Avoid to plotly error
# See https://github.com/spatialaudio/nbsphinx/issues/572#issuecomment-853389268
mathjax_path = 'https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js?config=TeX-AMS-MML_HTMLorMML'
Expand Down
4 changes: 2 additions & 2 deletions docs/misc/split_notebook.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,8 @@ def split_notebook(
)

# Copy `output` directory
shutil.copytree(tutorials_bilingual / "output", tutorials_jp / "output")
shutil.copytree(tutorials_bilingual / "output", tutorials_en / "output")
shutil.copytree(tutorials_bilingual / "output", tutorials_jp / "output", dirs_exist_ok=True)
shutil.copytree(tutorials_bilingual / "output", tutorials_en / "output", dirs_exist_ok=True)

if args.remove_bilingual_dir:
shutil.rmtree(tutorials_bilingual)
12 changes: 6 additions & 6 deletions tutorials/en/1_1_welcome.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -78,15 +78,15 @@
"\n",
"<div style=\"clear:both;display:table\">\n",
"<figure style=\"width:30%;float:left;margin:10px\">\n",
" <img src=\"https://matlantis.com/wp-content/themes/matlantis_theme/img/product/image_universal1.png\"/>\n",
" <img src=\"https://matlantis.com/wp-content/themes/matlantis_theme/img/product/en_image_universal1.png\"/>\n",
" <figcaption style=\"text-align: center\">Versatility</figcaption>\n",
"</figure>\n",
"<figure style=\"width:30%;float:left;margin:10px\">\n",
" <img src=\"https://matlantis.com/wp-content/themes/matlantis_theme/img/product/image_universal2.png\"/>\n",
" <img src=\"https://matlantis.com/wp-content/themes/matlantis_theme/img/product/en_image_universal2.png\"/>\n",
" <figcaption style=\"text-align: center\">Speed</figcaption>\n",
"</figure>\n",
"<figure style=\"width:30%;float:left;margin:10px\">\n",
" <img src=\"https://matlantis.com/wp-content/themes/matlantis_theme/img/product/image_universal3.png\"/>\n",
" <img src=\"https://matlantis.com/wp-content/themes/matlantis_theme/img/product/en_image_universal3.png\"/>\n",
" <figcaption style=\"text-align: center\">User-friendliness</figcaption>\n",
"</figure>\n",
"</div>\n",
Expand Down Expand Up @@ -220,9 +220,9 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3.7",
"display_name": "Python 3.8",
"language": "python",
"name": "python37"
"name": "python38"
},
"language_info": {
"codemirror_mode": {
Expand All @@ -234,7 +234,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.13"
"version": "3.8.13"
},
"widgets": {
"application/vnd.jupyter.widget-state+json": {
Expand Down
12 changes: 8 additions & 4 deletions tutorials/en/1_2_atomistic_simulation_intro.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -252,11 +252,15 @@
"Therefore, in atomistic simulations, it is necessary to perform appropriate **modeling** according to the phenomenon to create a simplified system that can be analyzed on a computer by extracting only the necessary elements to reproduce the desired phenomenon, rather than creating something exactly the same as the natural world.<br/>\n",
"There are various methods for modeling, and you will be able to do them by learning through this tutorial.\n",
"\n",
"---\n",
"\n",
"[Column] Modeling\n",
"\n",
"For example, if you want to simulate the Earth, if you are interested in weather, you would need to focus your modeling on the Earth's surface atmosphere. \n",
"On the other hand, if you are interested in earthquakes, you would need to concentrate your modeling on the Earth's internal structure rather than the atmosphere. \n",
"If you want to simulate the environment on the surface of the earth, you might consider cutting out only a portion of a continent rather than the entire planet."
"If you want to simulate the environment on the surface of the earth, you might consider cutting out only a portion of a continent rather than the entire planet.\n",
"\n",
"---"
]
},
{
Expand Down Expand Up @@ -294,9 +298,9 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3.7",
"display_name": "Python 3.8",
"language": "python",
"name": "python37"
"name": "python38"
},
"language_info": {
"codemirror_mode": {
Expand All @@ -308,7 +312,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.13"
"version": "3.8.13"
},
"widgets": {
"application/vnd.jupyter.widget-state+json": {
Expand Down
12 changes: 6 additions & 6 deletions tutorials/en/1_3_ase_basic.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@
{
"data": {
"text/html": [
"<img src=\"output/H2O.png\" width=\"150\"/>"
"<img src=\"output/H2.png\" width=\"150\"/>"
],
"text/plain": [
"<IPython.core.display.Image object>"
Expand All @@ -146,8 +146,8 @@
"from ase.io import write\n",
"from IPython.display import Image\n",
"\n",
"write(\"output/H2O.png\", atoms, rotation=\"0x,0y,0z\", scale=100)\n",
"Image(url='output/H2O.png', width=150)"
"write(\"output/H2.png\", atoms, rotation=\"0x,0y,0z\", scale=100)\n",
"Image(url='output/H2.png', width=150)"
]
},
{
Expand Down Expand Up @@ -543,9 +543,9 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3.7",
"display_name": "Python 3.8",
"language": "python",
"name": "python37"
"name": "python38"
},
"language_info": {
"codemirror_mode": {
Expand All @@ -557,7 +557,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.13"
"version": "3.8.13"
},
"toc-autonumbering": false,
"toc-showcode": false,
Expand Down
6 changes: 3 additions & 3 deletions tutorials/en/1_4_ase_structure.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -824,9 +824,9 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3.7",
"display_name": "Python 3.8",
"language": "python",
"name": "python37"
"name": "python38"
},
"language_info": {
"codemirror_mode": {
Expand All @@ -838,7 +838,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.13"
"version": "3.8.13"
},
"toc-autonumbering": false,
"toc-showcode": false,
Expand Down
6 changes: 3 additions & 3 deletions tutorials/en/1_5_ase_calculator.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -677,9 +677,9 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3.7",
"display_name": "Python 3.8",
"language": "python",
"name": "python37"
"name": "python38"
},
"language_info": {
"codemirror_mode": {
Expand All @@ -691,7 +691,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.13"
"version": "3.8.13"
},
"widgets": {
"application/vnd.jupyter.widget-state+json": {
Expand Down
6 changes: 3 additions & 3 deletions tutorials/en/1_6_ase_playground.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -611,9 +611,9 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3.7",
"display_name": "Python 3.8",
"language": "python",
"name": "python37"
"name": "python38"
},
"language_info": {
"codemirror_mode": {
Expand All @@ -625,7 +625,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.13"
"version": "3.8.13"
},
"widgets": {
"application/vnd.jupyter.widget-state+json": {
Expand Down
Loading