Skip to content

Commit 1ee4ea7

Browse files
Add samples with custom :button_text: values
1 parent 1d4be23 commit 1ee4ea7

File tree

3 files changed

+46
-0
lines changed

3 files changed

+46
-0
lines changed

docs/directives/jupyterlite.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,23 @@ of JupyterLite.
5050
:new_tab: True
5151
```
5252

53+
When using this option, it is also possible to customise the button text, overriding the
54+
global value using an additional `:button_text:` parameter:
55+
56+
```rst
57+
.. jupyterlite:: my_notebook.ipynb
58+
:new_tab: True
59+
:button_text: My custom JupyterLite button text
60+
```
61+
62+
```{eval-rst}
63+
.. jupyterlite:: my_notebook.ipynb
64+
:new_tab: True
65+
:button_text: My custom JupyterLite button text
66+
```
67+
68+
## Search parameters
69+
5370
The directive `search_params` allows to transfer some search parameters from the documentation URL to the Jupyterlite URL.\
5471
Jupyterlite will then be able to fetch these parameters from its own URL.\
5572
For example `:search_params: ["param1", "param2"]` will transfer the parameters *param1* and *param2*.

docs/directives/notebooklite.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,18 @@ Lab interface.
4545
.. notebooklite:: my_notebook.ipynb
4646
:new_tab: True
4747
```
48+
49+
When using this option, it is also possible to customise the button text, overriding the
50+
global value using an additional `:button_text:` parameter:
51+
52+
```rst
53+
.. notebooklite:: my_notebook.ipynb
54+
:new_tab: True
55+
:button_text: My custom NotebookLite button text
56+
```
57+
58+
```{eval-rst}
59+
.. notebooklite:: my_notebook.ipynb
60+
:new_tab: True
61+
:button_text: My custom NotebookLite button text
62+
```

docs/directives/voici.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,3 +41,17 @@ the notebook in a new browser tab, instead of in the current page.
4141
:new_tab: True
4242
```
4343

44+
When using this option, it is also possible to customise the button text, overriding the
45+
global value using an additional `:button_text:` parameter:
46+
47+
```rst
48+
.. voici:: my_notebook.ipynb
49+
:new_tab: True
50+
:button_text: My custom Voici button text
51+
```
52+
53+
```{eval-rst}
54+
.. voici:: my_notebook.ipynb
55+
:new_tab: True
56+
:button_text: My custom Voici button text
57+
```

0 commit comments

Comments
 (0)