fix(aio): fix code highlight in API docs templates (#21630)
Fixes #21108 PR Close #21630
This commit is contained in:
parent
97b18b2a5c
commit
b2e902deb4
|
@ -2,7 +2,7 @@
|
|||
<section class="annotations">
|
||||
<h2>Annotations</h2>
|
||||
{%- for decorator in doc.decorators %}
|
||||
<code-example hideCopy="true" class="no-box api-heading">@{$ decorator.name $}({$ decorator.arguments $})</code-example>
|
||||
<code-example language="ts" hideCopy="true" class="no-box api-heading">@{$ decorator.name $}({$ decorator.arguments $})</code-example>
|
||||
{% if not decorator.notYetDocumented %}{$ decorator.description | marked $}{% endif %}
|
||||
{% endfor %}
|
||||
</section>
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
{% for metadata in doc.members %}{% if not metadata.internal %}
|
||||
<div class="metadata-member">
|
||||
<a name="{$ metadata.name $}" class="anchor-offset"></a>
|
||||
<code-example hideCopy="true">{$ metadata.name $}{$ params.paramList(metadata.parameters) | trim $}{$ params.returnType(metadata.type) $}</code-example>
|
||||
<code-example language="ts" hideCopy="true">{$ metadata.name $}{$ params.paramList(metadata.parameters) | trim $}{$ params.returnType(metadata.type) $}</code-example>
|
||||
{%- if not metadata.notYetDocumented %}{$ metadata.description | marked $}{% endif -%}
|
||||
</div>
|
||||
{% if not loop.last %}<hr class="hr-margin">{% endif %}
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
{%- macro renderMemberDetail(member, cssClass) -%}
|
||||
<div class="{$ cssClass $}">
|
||||
<a id="{$ member.anchor $}"></a>
|
||||
<code-example hideCopy="true" class="no-box api-heading">{$ renderMember(member) $}</code-example>
|
||||
<code-example language="ts" hideCopy="true" class="no-box api-heading">{$ renderMember(member) $}</code-example>
|
||||
{%- if not member.notYetDocumented %}
|
||||
{$ member.description | marked $}
|
||||
{% endif -%}
|
||||
|
@ -57,4 +57,4 @@
|
|||
{% endif %}{% endfor %}
|
||||
</section>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
{% endmacro %}
|
||||
|
|
Loading…
Reference in New Issue