From 8c51ce6f3b07da963ebafaa1a0c6eacf878d71f7 Mon Sep 17 00:00:00 2001 From: Pete Bacon Darwin Date: Thu, 14 Jun 2018 22:06:59 +0100 Subject: [PATCH] build(docs-infra): move overload short description above syntax (#24526) PR Close #24526 --- aio/src/styles/1-layouts/_api-pages.scss | 4 ++++ .../transforms/templates/api/includes/class-overview.html | 2 +- aio/tools/transforms/templates/api/lib/memberHelpers.html | 4 ++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/aio/src/styles/1-layouts/_api-pages.scss b/aio/src/styles/1-layouts/_api-pages.scss index 9755851cb2..81e2f548a0 100644 --- a/aio/src/styles/1-layouts/_api-pages.scss +++ b/aio/src/styles/1-layouts/_api-pages.scss @@ -37,5 +37,9 @@ padding: 16px 24px; } } + + .short-description { + margin-left: 0; + } } } \ No newline at end of file diff --git a/aio/tools/transforms/templates/api/includes/class-overview.html b/aio/tools/transforms/templates/api/includes/class-overview.html index 906f51e0a5..d9064a17bf 100644 --- a/aio/tools/transforms/templates/api/includes/class-overview.html +++ b/aio/tools/transforms/templates/api/includes/class-overview.html @@ -1,7 +1,7 @@ {% import "lib/memberHelpers.html" as memberHelper -%}
- + {% if doc.isAbstract %}abstract {% endif%}{$ doc.docType $} {$ doc.name $}{$ doc.typeParams | escape $}{$ memberHelper.renderHeritage(doc) $} {{$ memberHelper.renderMembers(doc) $} } diff --git a/aio/tools/transforms/templates/api/lib/memberHelpers.html b/aio/tools/transforms/templates/api/lib/memberHelpers.html index 046d56dfcd..de81f1f5a2 100644 --- a/aio/tools/transforms/templates/api/lib/memberHelpers.html +++ b/aio/tools/transforms/templates/api/lib/memberHelpers.html @@ -40,13 +40,13 @@ {%- macro renderOverloadInfo(overload, cssClass, method) -%} -{$ renderMemberSyntax(overload) $} - {% if overload.shortDescription and (overload.shortDescription != method.shortDescription) %}
{$ overload.shortDescription | marked $}
{% endif %} +{$ renderMemberSyntax(overload) $} +

Parameters

{$ params.renderParameters(overload.parameterDocs, cssClass + '-parameters', cssClass + '-parameter') $}