build(aio): remove formatting and styles from dgeni templates
Much of the formatting was hardcoded and copied from the old anguar.io jade files. This gives us a clean start. Also, more use has been made of include files to make the templates easier to understand and manage.
This commit is contained in:
parent
ec8e68ed56
commit
ef48ee0a0a
|
@ -0,0 +1,144 @@
|
|||
This folder contains the dgeni templates that are used to generate the API docs
|
||||
|
||||
Generally there is a template for each docType. Templates can extend and/or include
|
||||
other templates. Templates can also import macros from other template files.
|
||||
|
||||
# Template inheritance
|
||||
|
||||
When extending a template, parent must declare blocks that can be overridden by the
|
||||
child. The template extension hierarchy looks like this (with declared blocks in parentheses):
|
||||
|
||||
- layout/base.template.html (base)
|
||||
- module.template.html
|
||||
- layout/api-base.template.html (jumpNav, jumpNavLinks, whatItDoes, infoBar, securityConsiderations, deprecationNotes, howToUse, details)
|
||||
- class.template.html
|
||||
- directive.template.html
|
||||
- enum.template.html
|
||||
- var.template.html
|
||||
- const.template.html
|
||||
- let.template.html
|
||||
- decorator.template.html
|
||||
- function.template.html
|
||||
- interface.template.html
|
||||
- type-alias.template.html
|
||||
- pipe.template.html
|
||||
|
||||
# Doc Properties
|
||||
|
||||
It is useful to know what properties are available on each doc type when working with the templates.
|
||||
Here is an overview:
|
||||
|
||||
## class
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
- members
|
||||
|
||||
## directive
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
- members
|
||||
|
||||
## enum
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
|
||||
## var
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
|
||||
## const
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
|
||||
## let
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
|
||||
## decorator
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
- members
|
||||
|
||||
## function
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
|
||||
## interface
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
- members
|
||||
|
||||
## type-alias
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
|
||||
## pipe
|
||||
|
||||
- docType
|
||||
- name
|
||||
- id
|
||||
- moduleDoc
|
||||
- path
|
||||
- description
|
||||
- notYetDocumented
|
||||
|
|
@ -1,161 +1,12 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
{% import "lib/paramList.html" as params -%}
|
||||
{% extends 'layout/base.template.html' -%}
|
||||
{% extends 'layout/api-base.template.html' -%}
|
||||
|
||||
{% block body %}
|
||||
|
||||
|
||||
{% include "layout/_what-it-does.html" %}
|
||||
|
||||
{% include "layout/_security-notes.html" %}
|
||||
|
||||
{% include "layout/_deprecated-notes.html" %}
|
||||
|
||||
{% include "layout/_how-to-use.html" %}
|
||||
|
||||
<div layout="row" layout-xs="column" class="ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Class Overview</h2>
|
||||
</div>
|
||||
<div flex="80" flex-xs="100">
|
||||
<code class="no-bg api-doc-code openParens">class {$ doc.name $} {</code>
|
||||
{% if doc.statics.length %}
|
||||
<div layout="column">
|
||||
{% for member in doc.statics %}{% if not member.internal %}
|
||||
<pre class="prettyprint no-bg-with-indent">static
|
||||
<a class="code-anchor" href="#{$ member.name $}-anchor">
|
||||
<code(class="code-background api-doc-code">{$ member.name | indent(6, false) | trim $}</code>
|
||||
</a>
|
||||
<code class="api-doc-code">
|
||||
{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}
|
||||
</code>
|
||||
{% endif %}{% endfor %}
|
||||
{% endif %}
|
||||
{% if doc.constructorDoc.name %}
|
||||
<div layout="column">
|
||||
<pre class="prettyprint no-bg-with-indent">
|
||||
<a class="code-anchor" href="#constructor">
|
||||
<code class="code-background api-doc-code">{$ doc.constructorDoc.name $}</code>
|
||||
</a>
|
||||
<code class="api-doc-code">
|
||||
{$ params.paramList(doc.constructorDoc.parameters) | indent(8, false) | trim $}
|
||||
</code>
|
||||
{% endif %}
|
||||
{% if doc.members.length %}
|
||||
<div layout="column">
|
||||
{% for member in doc.members %}{% if not member.internal %}
|
||||
<pre class="prettyprint no-bg-with-indent">
|
||||
<a class="code-anchor" href="#{$ member.name $}-anchor">
|
||||
<code class="code-background api-doc-code">{$ member.name | indent(6, false) | trim $}</code>
|
||||
</a>
|
||||
<code class="api-doc-code">{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}</code>
|
||||
</pre>
|
||||
{% endif %}{% endfor %}
|
||||
{% endif %}
|
||||
<p class="selector endParens">
|
||||
<code class="api-doc-code no-bg">}</code>
|
||||
</p>
|
||||
|
||||
{% block additional %}
|
||||
{% endblock %}
|
||||
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Class Description</h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
{%- if doc.description.length > 2 %}
|
||||
{$ doc.description | trimBlankLines | marked $}
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{%- if doc.decorators.length %}
|
||||
{% block annotations %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Annotations</h2>
|
||||
</div>
|
||||
<div flex="80" flex-xs="100">
|
||||
{%- for decorator in doc.decorators %}
|
||||
<pre class="prettyprint no-bg">
|
||||
<code class="api-doc-code">
|
||||
@{$ decorator.name $}{$ params.paramList(decorator.arguments) | indent(10, false) $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not decorator.notYetDocumented %}
|
||||
{$ decorator.description | indentForMarkdown(8) | trimBlankLines | marked $}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endblock %}
|
||||
{% endif %}
|
||||
|
||||
{%- if doc.constructorDoc and not doc.constructorDoc.internal %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Constructor</h2>
|
||||
</div>
|
||||
<div flex="80" flex-xs="100">
|
||||
<a name="constructor" class="anchor-offset"></a>
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ doc.constructorDoc.name $}') }">
|
||||
<code class="api-doc-code">
|
||||
{$ doc.constructorDoc.name $}{$ params.paramList(doc.constructorDoc.parameters) | indent(8, false) | trim $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not doc.constructorDoc.notYetDocumented %}
|
||||
{$ doc.constructorDoc.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if doc.statics.length %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Static Members</h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
{% for member in doc.statics %}{% if not member.internal %}
|
||||
<a name="{$ member.name $}-anchor" class="anchor-offset"></a>
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ member.name $}') }">
|
||||
<code class="api-doc-code">
|
||||
{$ member.name $}{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not member.notYetDocumented %}
|
||||
{$ member.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}
|
||||
{% endif %}
|
||||
|
||||
{% if not loop.last %}
|
||||
<hr class="hr-margin">
|
||||
{% endif %}
|
||||
|
||||
{% endif %}{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
{% if doc.members.length %}
|
||||
<div layout="row" layout-xs="column" class="instance-members" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Class Details</h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
{% for member in doc.members %}{% if not member.internal %}
|
||||
<a name="{$ member.name $}-anchor" class="anchor-offset">
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ member.name $}') }">
|
||||
<code class="api-doc-code">
|
||||
{$ member.name $}{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not member.notYetDocumented %}
|
||||
{$ member.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}
|
||||
{% endif -%}
|
||||
|
||||
{% if not loop.last %}
|
||||
<hr class="hr-margin">
|
||||
{% endif %}
|
||||
{% endif %}{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
<p class="location-badge">
|
||||
exported from {@link {$ doc.moduleDoc.id $} {$doc.moduleDoc.id $} },
|
||||
defined in {$ github.githubViewLink(doc, versionInfo) $}
|
||||
</p>
|
||||
{% block details %}
|
||||
{% include "includes/_class-overview.html" %}
|
||||
{% block additional %}{% endblock %}
|
||||
{% include "includes/_description.html" %}
|
||||
{% include "includes/_annotations.html" %}
|
||||
{% include "includes/_constructor.html" %}
|
||||
{% include "includes/_statics.html" %}
|
||||
{% include "includes/_members.html" %}
|
||||
{% endblock %}
|
||||
|
|
|
@ -1,44 +1,7 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
{% import "lib/paramList.html" as params -%}
|
||||
{% extends 'layout/base.template.html' %}
|
||||
{% extends 'layout/api-base.template.html' %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
|
||||
{% include "layout/_what-it-does.html" %}
|
||||
|
||||
{% include "layout/_security-notes.html" %}
|
||||
|
||||
{% include "layout/_deprecated-notes.html" %}
|
||||
|
||||
{% include "layout/_how-to-use.html" %}
|
||||
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Description</h2>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
{%- if not doc.notYetDocumented %}{$ doc.description | trimBlankLines | marked $}{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
{% if doc.metadataDoc and doc.metadataDoc.members.length %}
|
||||
<div layout="row" layout-xs="column" class="metadata" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Metadata Properties</h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
{% for metadata in doc.metadataDoc.members %}{% if not metadata.internal %}
|
||||
<a name="{$ metadata.name $}-anchor" class="anchor-offset"></a>
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ metadata.name $}') }">
|
||||
<code class="api-doc-code">
|
||||
{$ metadata.name $}{$ params.paramList(metadata.parameters) | indent(8, false) | trim $}{$ params.returnType(metadata.returnType) $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not metadata.notYetDocumented %}{$ metadata.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}{% endif -%}
|
||||
{% if not loop.last %}<hr class="hr-margin">{% endif %}
|
||||
{% endif %}{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
<p class="location-badge">
|
||||
exported from {@link {$ doc.moduleDoc.id $} {$doc.moduleDoc.id $} } defined in {$ github.githubViewLink(doc, versionInfo) $}
|
||||
</p>
|
||||
{% block main %}
|
||||
{% include "includes/_description.html" %}
|
||||
{% include "includes/_metadata.html" %}
|
||||
{% endblock %}
|
||||
|
|
|
@ -1,62 +1,9 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
{% import "lib/paramList.html" as params -%}
|
||||
{% extends 'class.template.html' -%}
|
||||
|
||||
{% block annotations %}
|
||||
{% endblock %}
|
||||
|
||||
{% block additional -%}
|
||||
|
||||
{%- if doc.directiveOptions.selector.split(',').length %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Selectors</h2>
|
||||
<div flex="80" flex-xs="100">
|
||||
{% for selector in doc.directiveOptions.selector.split(',') %}
|
||||
<p class="selector">
|
||||
<code>{$ selector $}</code>
|
||||
</p>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
{% if doc.outputs %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Outputs</h2>
|
||||
</div>
|
||||
<div flex="80" flex-xs="100">
|
||||
{% for binding, property in doc.outputs %}
|
||||
<div class="code-margin">
|
||||
<code>{$ property.bindingName $} bound to </code>
|
||||
<code>{$ property.memberDoc.classDoc.name $}.{$ property.propertyName $}</code
|
||||
</div>
|
||||
{$ property.memberDoc.description | trimBlankLines | marked $}
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if doc.inputs %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Inputs</h2>
|
||||
<div flex="80" flex-xs="100">
|
||||
{% for binding, property in doc.inputs %}
|
||||
<div class="code-margin">
|
||||
<code>{$ property.bindingName $} bound to </code>
|
||||
<code>{$ property.memberDoc.classDoc.name $}.{$ property.propertyName $}</code>
|
||||
{$ property.memberDoc.description | trimBlankLines | marked $}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
{%- if doc.directiveOptions.exportAs %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Exported as</h2>
|
||||
</div>
|
||||
<div flex="80" flex-xs="100">
|
||||
<p class="input">
|
||||
<code>{$ doc.directiveOptions.exportAs $}</code>
|
||||
</p>
|
||||
{% endif %}
|
||||
{% include "includes/_selectors.html" %}
|
||||
{% include "includes/_outputs.html" %}
|
||||
{% include "includes/_inputs.html" %}
|
||||
{% include "includes/_export-as.html" %}
|
||||
{% endblock %}
|
||||
|
|
|
@ -1,31 +1,6 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
{% import "lib/paramList.html" as params -%}
|
||||
{% extends 'layout/base.template.html' -%}
|
||||
{% extends 'layout/api-base.template.html' -%}
|
||||
|
||||
{% block body %}
|
||||
|
||||
|
||||
{% include "layout/_what-it-does.html" %}
|
||||
|
||||
{% include "layout/_security-notes.html" %}
|
||||
|
||||
{% include "layout/_deprecated-notes.html" %}
|
||||
|
||||
{% include "layout/_how-to-use.html" %}
|
||||
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Class Export</h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
<pre class="prettyprint no-bg">
|
||||
<code>
|
||||
export {$ doc.name $}{$ params.paramList(doc.parameters) | indent(8, true) | trim $}{$ params.returnType(doc.returnType) $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not doc.notYetDocumented %}{$ doc.description | trimBlankLines | marked $}{% endif %}
|
||||
|
||||
<p class="location-badge">
|
||||
exported from {@link {$ doc.moduleDoc.id $} {$doc.moduleDoc.id $} } defined in {$ github.githubViewLink(doc, versionInfo) $}
|
||||
</p>
|
||||
{% block main %}
|
||||
{% include "includes/_description.html" %}
|
||||
{% endblock %}
|
|
@ -0,0 +1,13 @@
|
|||
{%- if doc.decorators.length %}
|
||||
<section class="annotations">
|
||||
<h2>Annotations</h2>
|
||||
<div class="annotation">
|
||||
{%- for decorator in doc.decorators %}
|
||||
<pre class="prettyprint no-bg">
|
||||
<code>@{$ decorator.name $}{$ params.paramList(decorator.arguments) | indent(10, false) $}</code>
|
||||
</pre>
|
||||
{%- if not decorator.notYetDocumented %}{$ decorator.description | marked $}{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,40 @@
|
|||
<section class="class-overview">
|
||||
<h2>Class Overview</h2>
|
||||
<div class="api-doc-code">
|
||||
|
||||
<code class="no-bg openParens">class {$ doc.name $} {</code>
|
||||
|
||||
{% if doc.statics.length %}
|
||||
<div class="statics">
|
||||
{% for member in doc.statics %}{% if not member.internal %}
|
||||
<pre class="prettyprint no-bg-with-indent"><code>static
|
||||
<a class="code-anchor" href="#{$ member.name $}-anchor">{$ member.name | indent(6, false) | trim $}</a>
|
||||
{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}
|
||||
</code></pre>
|
||||
{% endif %}{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if doc.constructorDoc.name %}
|
||||
<div class="constructor">
|
||||
<pre class="prettyprint no-bg-with-indent"><code>
|
||||
<a class="code-anchor" href="#constructor">{$ doc.constructorDoc.name $}</a>
|
||||
{$ params.paramList(doc.constructorDoc.parameters) | indent(8, false) | trim $}
|
||||
</code></pre>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if doc.members.length %}
|
||||
<div class="members">
|
||||
{% for member in doc.members %}{% if not member.internal %}
|
||||
<pre class="prettyprint no-bg-with-indent"><code>
|
||||
<a class="code-anchor" href="#{$ member.name $}-anchor">{$ member.name | indent(6, false) | trim $}</a>
|
||||
{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}
|
||||
</code></pre>
|
||||
{% endif %}{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
<code class="endParens api-doc-code no-bg">}</code>
|
||||
</div>
|
||||
</section>
|
|
@ -0,0 +1,16 @@
|
|||
{%- if doc.constructorDoc and not doc.constructorDoc.internal %}
|
||||
<section class="constructor">
|
||||
<h2>Constructor</h2>
|
||||
<div class="description">
|
||||
<a name="constructor" class="anchor-offset"></a>
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ doc.constructorDoc.name $}') }">
|
||||
<code>
|
||||
{$ doc.constructorDoc.name $}{$ params.paramList(doc.constructorDoc.parameters) | indent(8, false) | trim $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not doc.constructorDoc.notYetDocumented %}
|
||||
{$ doc.constructorDoc.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}
|
||||
{% endif %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,9 @@
|
|||
<section class="l-content-block">
|
||||
<h3 class="text-display-1" id="api-description">
|
||||
Description
|
||||
<a href="#api-description" class="header-link"><i class="material-icons">link</i></a>
|
||||
</h3>
|
||||
{%- if doc.description.length > 2 %}
|
||||
{$ doc.description | trimBlankLines | marked $}
|
||||
{% endif %}
|
||||
</section>
|
|
@ -0,0 +1,10 @@
|
|||
{%- if doc.directiveOptions.exportAs %}
|
||||
<section class="export-as">
|
||||
<h2>Exported as</h2>
|
||||
<div class="description">
|
||||
<p>
|
||||
<code>{$ doc.directiveOptions.exportAs $}</code>
|
||||
</p>
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,9 @@
|
|||
{%- if doc.howToUse %}
|
||||
<!-- QUICK REFERENCE CODE EXAMPLE -->
|
||||
<section class="how-to-use">
|
||||
<h2>How To Use</h2>
|
||||
<div class="description">
|
||||
{$ doc.howToUse | marked $}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,18 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
|
||||
<!-- INFO BAR -->
|
||||
<div class="info-bar">
|
||||
<span class="info-bar-item is-left">
|
||||
npm package: <a href="#">{$ doc.package $}</a>
|
||||
</span>
|
||||
|
||||
<span class="info-bar-item is-left">
|
||||
NgModule: <a href="#">{$ doc.moduleDoc.name $}</a>
|
||||
</span>
|
||||
|
||||
<span class="info-bar-item is-right">
|
||||
{$ github.githubViewLink(doc, versionInfo) $}
|
||||
</span>
|
||||
|
||||
<i class="material-icons l-right">create</i>
|
||||
</div>
|
|
@ -0,0 +1,13 @@
|
|||
{% if doc.inputs %}
|
||||
<section class="inputs">
|
||||
<h2>Inputs</h2>
|
||||
<div class="description">
|
||||
{% for binding, property in doc.inputs %}
|
||||
<div class="input">
|
||||
<code>{$ property.bindingName $}</code> bound to <code>{$ property.memberDoc.classDoc.name $}.{$ property.propertyName $}</code>
|
||||
{$ property.memberDoc.description | trimBlankLines | marked $}
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,19 @@
|
|||
<section class="class-overview">
|
||||
<h2>Interface Overview</h2>
|
||||
<div class="api-doc-code">
|
||||
|
||||
<code class="no-bg openParens">interface {$ doc.name $} {</code>
|
||||
|
||||
{% if doc.members.length %}
|
||||
<div class="members">
|
||||
{% for member in doc.members %}{% if not member.internal %}
|
||||
<pre class="prettyprint no-bg-with-indent"><code>
|
||||
<a class="code-anchor" href="#{$ member.name $}-anchor">{$ member.name | indent(6, false) | trim $}</a>
|
||||
{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}
|
||||
</code></pre>
|
||||
{% endif %}{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
<code class="endParens api-doc-code no-bg">}</code>
|
||||
</div>
|
||||
</section>
|
|
@ -0,0 +1,19 @@
|
|||
{% if doc.members.length %}
|
||||
<section class="instance-members">
|
||||
<h2>Class Details</h2>
|
||||
<div class="description">
|
||||
{% for member in doc.members %}{% if not member.internal %}
|
||||
<div class="instance-member">
|
||||
<a name="{$ member.name $}-anchor" class="anchor-offset"></a>
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ member.name $}') }">
|
||||
<code>{$ member.name $}{$ params.paramList(member.parameters) | trim $}{$ params.returnType(member.returnType) $}</code>
|
||||
</pre>
|
||||
{%- if not member.notYetDocumented %}
|
||||
{$ member.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}
|
||||
{% endif -%}
|
||||
</div>
|
||||
{% if not loop.last %}<hr class="hr-margin">{% endif %}
|
||||
{% endif %}{% endfor %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,17 @@
|
|||
{% if doc.metadataDoc and doc.metadataDoc.members.length %}
|
||||
<section class="meta-data">
|
||||
<h2>Metadata Properties</h2>
|
||||
<div class="description">
|
||||
{% for metadata in doc.metadataDoc.members %}{% if not metadata.internal %}
|
||||
<div class="metadata-member">
|
||||
<a name="{$ metadata.name $}-anchor" class="anchor-offset"></a>
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ metadata.name $}') }">
|
||||
<code>{$ metadata.name $}{$ params.paramList(metadata.parameters) | trim $}{$ params.returnType(metadata.returnType) $}</code>
|
||||
</pre>
|
||||
{%- if not metadata.notYetDocumented %}{$ metadata.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}{% endif -%}
|
||||
</div>
|
||||
{% if not loop.last %}<hr class="hr-margin">{% endif %}
|
||||
{% endif %}{% endfor %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,13 @@
|
|||
{% if doc.outputs %}
|
||||
<section class="outputs">
|
||||
<h2>Outputs</h2>
|
||||
<div class="description">
|
||||
{% for binding, property in doc.outputs %}
|
||||
<div class="output">
|
||||
<code>{$ property.bindingName $}</code> bound to <code>{$ property.memberDoc.classDoc.name $}.{$ property.propertyName $}</code>
|
||||
{$ property.memberDoc.description | trimBlankLines | marked $}
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,12 @@
|
|||
{%- if doc.directiveOptions.selector.split(',').length %}
|
||||
<section class="selectors">
|
||||
<h2>Selectors</h2>
|
||||
<div class="description">
|
||||
{% for selector in doc.directiveOptions.selector.split(',') %}
|
||||
<p class="selector">
|
||||
<code>{$ selector $}</code>
|
||||
</p>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,23 @@
|
|||
{% if doc.statics.length %}
|
||||
<section class="static-members">
|
||||
<h2>Static Members</h2>
|
||||
<div class="description">
|
||||
{% for member in doc.statics %}{% if not member.internal %}
|
||||
<div class="static-member">
|
||||
<a name="{$ member.name $}-anchor" class="anchor-offset"></a>
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ member.name $}') }">
|
||||
<code>{$ member.name $}{$ params.paramList(member.parameters) | trim $}{$ params.returnType(member.returnType) $}</code>
|
||||
</pre>
|
||||
{%- if not member.notYetDocumented %}
|
||||
{$ member.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{% if not loop.last %}
|
||||
<hr class="hr-margin">
|
||||
{% endif %}
|
||||
|
||||
{% endif %}{% endfor %}
|
||||
</div>
|
||||
</section>
|
||||
{% endif %}
|
|
@ -0,0 +1,6 @@
|
|||
<!-- PAGE HERO -->
|
||||
<header>
|
||||
<h1>{$ doc.name $}</h1>
|
||||
<h2>{$ doc.docType $}</h2>
|
||||
<span class="version">{$ angular.version $}</span>
|
||||
</header>
|
|
@ -0,0 +1,3 @@
|
|||
{%- if doc.whatItDoes %}
|
||||
<div class="what-it-does">{$ doc.whatItDoes | marked $}</div>
|
||||
{% endif %}
|
|
@ -1,72 +1,8 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
{% import "lib/paramList.html" as params -%}
|
||||
{% extends 'layout/base.template.html' -%}
|
||||
{% extends 'layout/api-base.template.html' -%}
|
||||
|
||||
{% block body %}
|
||||
|
||||
|
||||
{% include "layout/_what-it-does.html" %}
|
||||
|
||||
{% include "layout/_security-notes.html" %}
|
||||
|
||||
{% include "layout/_deprecated-notes.html" %}
|
||||
|
||||
{% include "layout/_how-to-use.html" %}
|
||||
|
||||
<div layout="row" layout-xs="column" class="ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Interface Overview</h2>
|
||||
</div>
|
||||
<div flex="80" flex-xs="100">
|
||||
<code class="no-bg api-doc-code openParens">interface {$ doc.name $} {</code>
|
||||
|
||||
{% if doc.members.length %}
|
||||
<div layout="column">
|
||||
{% for member in doc.members %}{% if not member.internal %}
|
||||
<pre class="prettyprint no-bg-with-indent">
|
||||
<a class="code-anchor" href="#{$ member.name $}-anchor">
|
||||
<code class="code-background api-doc-code">{$ member.name | indent(6, false) | trim $}</code>
|
||||
<code class="api-doc-code">{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}</code>
|
||||
</a>
|
||||
</pre>
|
||||
{% endif %}{% endfor %}
|
||||
{% endif %}
|
||||
<p class="selector endParens">
|
||||
<code class="api-doc-code no-bg">}</code>
|
||||
</p>
|
||||
|
||||
{% block additional %}
|
||||
{% endblock %}
|
||||
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Interface Description</h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
{%- if doc.description.length > 2 %}{$ doc.description | trimBlankLines | marked $}{% endif %}
|
||||
</div>
|
||||
{% if doc.members.length %}
|
||||
<div layout="row" layout-xs="column" class="instance-members" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Interface Details</h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
{% for member in doc.members %}{% if not member.internal %}
|
||||
<a name="{$ member.name $}-anchor" class="anchor-offset"></a>
|
||||
<pre class="prettyprint no-bg" ng-class="{ 'anchor-focused': appCtrl.isApiDocMemberFocused('{$ member.name $}') }">
|
||||
<code class="api-doc-code">
|
||||
{$ member.name $}{$ params.paramList(member.parameters) | indent(8, false) | trim $}{$ params.returnType(member.returnType) $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not member.notYetDocumented %}{$ member.description | replace('### Example', '') | replace('## Example', '') | replace('# Example', '') | trimBlankLines | marked $}{% endif -%}
|
||||
{% if not loop.last %}<hr class="hr-margin">{% endif %}
|
||||
</div>
|
||||
{% endif %}{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<p class="location-badge">
|
||||
exported from {@link {$ doc.moduleDoc.id $} {$doc.moduleDoc.id $} },
|
||||
defined in {$ github.githubViewLink(doc, versionInfo) $}
|
||||
</p>
|
||||
{% block main %}
|
||||
{% include "includes/_interface-overview.html" %}
|
||||
{% include "includes/_description.html" %}
|
||||
{% include "includes/_members.html" %}
|
||||
{% endblock %}
|
||||
|
|
|
@ -1,10 +0,0 @@
|
|||
{%- if doc.howToUse %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">How to use</h2>
|
||||
</div>
|
||||
<div flex="80" flex-xs="100">
|
||||
{$ doc.howToUse | marked $}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
|
@ -1,10 +0,0 @@
|
|||
{%- if doc.whatItDoes %}
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">What it does</h2>
|
||||
</div>
|
||||
<div flex="80" flex-xs="100">
|
||||
{$ doc.whatItDoes | marked $}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
|
@ -0,0 +1,11 @@
|
|||
{% extends 'layout/base.template.html' -%}
|
||||
|
||||
{% block body %}
|
||||
<aio-jump-nav></aio-jump-nav>
|
||||
{% include "includes/_what-it-does.html" %}
|
||||
{% include "includes/_info-bar.html" %}
|
||||
{% include "includes/_security-notes.html" %}
|
||||
{% include "includes/_deprecated-notes.html" %}
|
||||
{% include "includes/_how-to-use.html" %}
|
||||
{% block details %}{% endblock %}
|
||||
{% endblock %}
|
|
@ -1 +1,4 @@
|
|||
{% block body %}{% endblock %}
|
||||
<article>
|
||||
{% include "includes/_title.html" %}
|
||||
{% block body %}{% endblock %}
|
||||
</article>
|
|
@ -1,8 +1,6 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
{% extends 'layout/base.template.html' -%}
|
||||
|
||||
{% block body -%}
|
||||
<p class="location-badge">defined in {$ github.githubViewLink(doc, versionInfo) $}</p>
|
||||
<ul>
|
||||
{% for page in doc.childPages -%}
|
||||
<li>
|
||||
|
|
|
@ -1,30 +1,5 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
{% import "lib/paramList.html" as params -%}
|
||||
{% extends 'layout/base.template.html' -%}
|
||||
{% extends 'layout/api-base.template.html' -%}
|
||||
|
||||
{% block body %}
|
||||
|
||||
|
||||
{% include "layout/_what-it-does.html" %}
|
||||
|
||||
{% include "layout/_security-notes.html" %}
|
||||
|
||||
{% include "layout/_deprecated-notes.html" %}
|
||||
|
||||
{% include "layout/_how-to-use.html" %}
|
||||
|
||||
{% include "layout/_ng-module.html" %}
|
||||
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Description</h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
{%- if doc.description.length > 2 %}{$ doc.description | trimBlankLines | marked $}{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<p class="location-badge">
|
||||
exported from {@link {$ doc.moduleDoc.id $} {$doc.moduleDoc.id $} }
|
||||
defined in {$ github.githubViewLink(doc, versionInfo) $}
|
||||
</p>
|
||||
{% block details %}
|
||||
{% include "includes/_description.html" %}
|
||||
{% endblock %}
|
||||
|
|
|
@ -1,33 +1,5 @@
|
|||
{% import "lib/githubLinks.html" as github -%}
|
||||
{% import "lib/paramList.html" as params -%}
|
||||
{% extends 'layout/base.template.html' %}
|
||||
{% extends 'layout/api-base.template.html' %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
|
||||
{% include "layout/_what-it-does.html" %}
|
||||
|
||||
{% include "layout/_security-notes.html" %}
|
||||
|
||||
{% include "layout/_deprecated-notes.html" %}
|
||||
|
||||
{% include "layout/_how-to-use.html" %}
|
||||
|
||||
<div layout="row" layout-xs="column" class="row-margin ng-cloak">
|
||||
<div flex="20" flex-xs="100">
|
||||
<h2 class="h2-api-docs">Variable Export<h2>
|
||||
</div>
|
||||
<div class="code-links" flex="80" flex-xs="100">
|
||||
<pre class="prettyprint no-bg">
|
||||
<code>
|
||||
export {$ doc.name $}
|
||||
</code>
|
||||
</pre>
|
||||
{%- if not doc.notYetDocumented %}{$ doc.description | trimBlankLines | marked $}{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<p class="location-badge">
|
||||
exported from {@link {$ doc.moduleDoc.id $} {$doc.moduleDoc.id $} }
|
||||
defined in {$ github.githubViewLink(doc, versionInfo) $}
|
||||
</p>
|
||||
{% block details %}
|
||||
{% include "includes/_description.html" %}
|
||||
{% endblock %}
|
||||
|
|
Loading…
Reference in New Issue