Skip to content

build: fix formatting for static properties and filter out coercion members #22823

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 27, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion tools/dgeni/common/private-docs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ export function isPublicDoc(doc: ApiDoc) {
if (_isEnforcedPublicDoc(doc)) {
return true;
}
if (_hasDocsPrivateTag(doc) || doc.name.startsWith('_')) {
if (_hasDocsPrivateTag(doc) || doc.name.startsWith('_') ||
doc.name.startsWith('ngAcceptInputType_')) {
return false;
} else if (doc instanceof MemberDoc) {
return !_isInternalMember(doc);
Expand Down
3 changes: 2 additions & 1 deletion tools/dgeni/processors/docs-private-filter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ export class DocsPrivateFilter implements Processor {
// Filter out private class members which could be annotated
// with the "@docs-private" tag.
if (isPublic && doc instanceof ClassExportDoc) {
doc.members = doc.members.filter(memberDoc => isPublicDoc(memberDoc));
doc.members = doc.members.filter(isPublicDoc);
doc.statics = doc.statics.filter(isPublicDoc);
}

return isPublic;
Expand Down
2 changes: 1 addition & 1 deletion tools/dgeni/templates/property.template.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
{%- endif -%}

<p class="docs-api-property-name">
<code>{%- if property.isStatic -%}static {%- endif -%}{$ property.name $}: {$ property.type $}</code>
<code>{%- if property.isStatic -%}static&nbsp;{%- endif -%}{$ property.name $}: {$ property.type $}</code>
</p>
</td>
<td class="docs-api-property-description">{$ property.description | marked | safe $}</td>
Expand Down