Skip to content

Commit

Permalink
[ci skip] Autodoc commit for 0515f59.
Browse files Browse the repository at this point in the history
  • Loading branch information
oscwiag committed Sep 9, 2024
1 parent b595b54 commit f1435b9
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ for the ``ruby`` cluster. It will then hide it every time the cluster ``ruby``
widget: select
options:
- 'standard'
- [
- [
'gpu', 'gpu',
data-option-for-cluster-ruby: false
]
Expand All @@ -78,7 +78,7 @@ But using Nvidia's `CUDA`_ libraries only makes sense when the user is requestin
So, we want to hide the ``cuda_version`` element when a users chooses standard ``node_type``.

Here's the example YAML for this app with two select widgets. This
instructs the webpage to hide the ``cuda_version`` when the ``standard``
instructs the webpage to hide the ``cuda_version`` when the ``standard``
``node_type`` is selected.

.. code-block:: yaml
Expand All @@ -88,7 +88,7 @@ instructs the webpage to hide the ``cuda_version`` when the ``standard``
node_type:
widget: select
options:
- [
- [
'standard', 'standard',
data-hide-cuda-version: true
]
Expand All @@ -100,7 +100,7 @@ Here we have a checkbox ``enable_cuda_version`` that will show
``cuda_version`` when checked and hide it when it's not checked.

.. tip::
Checkboxes respond to ``when-checked: true`` and ``when-unchecked: true``
Checkboxes respond to ``when-checked: true`` and ``when-un-checked: true``
for hiding elements when checked or unchecked.

.. code-block:: yaml
Expand All @@ -111,7 +111,7 @@ Here we have a checkbox ``enable_cuda_version`` that will show
widget: 'check_box'
html_options:
data:
hide-cuda-version-when-unchecked: true
hide-cuda-version-when-un-checked: true
Dynamic Min and Maxes
*********************
Expand All @@ -130,7 +130,7 @@ different sizes. In the ``oakley`` cluster nodes have a total 28 cores and in th
``ruby`` cluster they have 40.

In this example ``data-max-num-cores-for-cluster-oakley`` is attached to the standard
node type. This config is saying, when the ``node_type`` is ``standard``
node type. This config is saying, when the ``node_type`` is ``standard``
and the ``cluster`` is ``oakley`` set maximum ``num_cores`` to 28.

.. code-block:: yaml
Expand All @@ -139,7 +139,7 @@ and the ``cluster`` is ``oakley`` set maximum ``num_cores`` to 28.
node_type:
widget: select
options:
- [
- [
'standard', 'standard',
data-max-num-cores-for-cluster-oakley: 28,
data-max-num-cores-for-cluster-ruby: 40,
Expand All @@ -150,7 +150,7 @@ and the ``cluster`` is ``oakley`` set maximum ``num_cores`` to 28.
data-min-num-cores: 1,
]
This example also illustrates a simpler variant of this directive attached to ``gpu``.
This example also illustrates a simpler variant of this directive attached to ``gpu``.
This configuration doesn't have a for clause, so it will set the minimum and maximum
values for ``num_cores`` when ``gpu`` is selected, regardless of which cluster is selected.

Expand Down Expand Up @@ -183,7 +183,7 @@ the ``enable_gpu`` check box will either be checked or unchecked.
node_type:
widget: select
options:
- [
- [
'standard', 'standard',
data-set-charge-account: 'standard-charge-code',
data-set-enable-gpu: 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,15 +304,15 @@ <h2>Hiding entire elements<a class="headerlink" href="#hiding-entire-elements" t
<code class="docutils literal notranslate"><span class="pre">cuda_version</span></code> when checked and hide it when it’s not checked.</p>
<div class="admonition tip">
<p class="admonition-title">Tip</p>
<p>Checkboxes respond to <code class="docutils literal notranslate"><span class="pre">when-checked:</span> <span class="pre">true</span></code> and <code class="docutils literal notranslate"><span class="pre">when-unchecked:</span> <span class="pre">true</span></code>
<p>Checkboxes respond to <code class="docutils literal notranslate"><span class="pre">when-checked:</span> <span class="pre">true</span></code> and <code class="docutils literal notranslate"><span class="pre">when-un-checked:</span> <span class="pre">true</span></code>
for hiding elements when checked or unchecked.</p>
</div>
<div class="highlight-yaml notranslate"><div class="highlight"><pre><span></span><span class="nt">attributes</span><span class="p">:</span><span class="w"></span>
<span class="w"> </span><span class="nt">enable_cuda_version</span><span class="p">:</span><span class="w"></span>
<span class="w"> </span><span class="nt">widget</span><span class="p">:</span><span class="w"> </span><span class="s">&#39;check_box&#39;</span><span class="w"></span>
<span class="w"> </span><span class="nt">html_options</span><span class="p">:</span><span class="w"></span>
<span class="w"> </span><span class="nt">data</span><span class="p">:</span><span class="w"></span>
<span class="hll"><span class="w"> </span><span class="nt">hide-cuda-version-when-unchecked</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span><span class="w"></span>
<span class="hll"><span class="w"> </span><span class="nt">hide-cuda-version-when-un-checked</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">true</span><span class="w"></span>
</span></pre></div>
</div>
</div>
Expand Down

0 comments on commit f1435b9

Please sign in to comment.