api-templates: only show directive inputs/outputs if there are some
This commit is contained in:
parent
b5744c813a
commit
26320160f9
|
@ -61,5 +61,7 @@ function getDecoratorValues(classDecoratorValues, memberDecoratorName, members)
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (Object.keys(decoratorValues).length) {
|
||||||
return decoratorValues;
|
return decoratorValues;
|
||||||
}
|
}
|
||||||
|
}
|
|
@ -11,11 +11,11 @@
|
||||||
code {$ selector $}
|
code {$ selector $}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
||||||
{% if doc.inputs.length %}
|
{% if doc.inputs %}
|
||||||
.l-main-section
|
.l-main-section
|
||||||
h2 Inputs
|
h2 Inputs
|
||||||
.l-sub-section
|
.l-sub-section{% for binding, property in doc.inputs %}
|
||||||
h3.input {% for binding, property in doc.inputs %}
|
h3.input
|
||||||
code {$ property.bindingName | dashCase $}
|
code {$ property.bindingName | dashCase $}
|
||||||
| bound to
|
| bound to
|
||||||
code {$ property.memberDoc.classDoc.name $}.{$ property.propertyName $}
|
code {$ property.memberDoc.classDoc.name $}.{$ property.propertyName $}
|
||||||
|
@ -24,11 +24,11 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if doc.ouputs.length %}
|
{% if doc.outputs %}
|
||||||
.l-main-section
|
.l-main-section
|
||||||
h2 Outputs
|
h2 Outputs
|
||||||
.l-sub-section
|
.l-sub-section{% for binding, property in doc.outputs %}
|
||||||
h3.input {% for binding, property in doc.outputs %}
|
h3.output
|
||||||
code {$ property.bindingName | dashCase $}
|
code {$ property.bindingName | dashCase $}
|
||||||
| bound to
|
| bound to
|
||||||
code {$ property.memberDoc.classDoc.name $}.{$ property.propertyName $}
|
code {$ property.memberDoc.classDoc.name $}.{$ property.propertyName $}
|
||||||
|
|
Loading…
Reference in New Issue