|
3 | 3 | {% extends "base_template.html.j2" %} |
4 | 4 | {% block content %} |
5 | 5 |
|
6 | | -<h1 id="summary"><code>{{ body['content']['name'] }}</code><small>{% if body['content']['element'] %}{{ |
7 | | - macros.tooltip_display('Element', 'Element functions can be customized with <code>set</code> and <code>show</code> rules.') }}{% endif %}</small></h1> |
| 6 | +<h1 id="summary"> |
| 7 | + <code>{{ body['content']['name'] }}</code> |
| 8 | + <small> |
| 9 | + {% if body['content']['element'] %} |
| 10 | + {{ macros.tooltip_display('Element', 'Element functions can be customized with <code>set</code> and <code>show</code> rules.') }} |
| 11 | + {% endif %} |
| 12 | + {% if body['content']['contextual'] %} |
| 13 | + {{ macros.tooltip_display('Contextual', 'Contextual functions can only be used when the context is known') }} |
| 14 | + {% endif %} |
| 15 | + </small> |
| 16 | +</h1> |
8 | 17 | {{ body['content']['details'] | safe }} |
9 | 18 | <h2 id="parameters"> |
10 | 19 | {{ macros.tooltip_display('引数', 'Parameters are the inputs to a function. They are specified in parentheses after the function name.', prefix='parameters') }} |
|
22 | 31 | </h2> |
23 | 32 | {% endif %} |
24 | 33 | {% for method in body['content']['scope'] %} |
25 | | - <h3 id="{{ prefix }}-{{ method['name'] }}" class="method-head"><span><code>{{ method['name'] }}</code></span></h3> |
| 34 | + <h3 id="definitions-{{ method['name'] }}" class="method-head"> |
| 35 | + <code{% if method['deprecation'] %} style="text-decoration: line-through;"{% endif %}>{{ method['name'] }}</code> |
| 36 | + |
| 37 | + <small> |
| 38 | + {% if method['element'] %} |
| 39 | + {{ macros.tooltip_display('Element', 'Element functions can be customized with <code>set</code> and <code>show</code> rules.') }} |
| 40 | + {% endif %} |
| 41 | + {% if method['contextual'] %} |
| 42 | + {{ macros.tooltip_display('Contextual', 'Contextual functions can only be used when the context is known') }} |
| 43 | + {% endif %} |
| 44 | + </small> |
| 45 | + {% if method['deprecation'] %} |
| 46 | + <small class="deprecation"> |
| 47 | + <div class="tooltip-context"> |
| 48 | + <svg width="16" height="16" viewBox="0 0 16 16" tabindex="0" role="img" |
| 49 | + aria-labelledby="definitions-{{ method['name'] }}-deprecation-tooltip"> |
| 50 | + <title id="definitions-{{ method['name'] }}-deprecation-tooltip"> |
| 51 | + Warning |
| 52 | + </title> |
| 53 | + <use href="/assets/icons/16-warn.svg#icon"></use> |
| 54 | + </svg> |
| 55 | + </div> |
| 56 | + <span> |
| 57 | + <span>{{ method['deprecation'] }}</span> |
| 58 | + </span> |
| 59 | + </small> |
| 60 | + {% endif %} |
| 61 | + </h3> |
26 | 62 | {{ macros.function_display(method, type2href, type2class, gen_path, prefix='definitions-' + method['name']) }} |
27 | 63 | {% endfor %} |
28 | 64 |
|
|
0 commit comments