Skip to content
Closed
Show file tree
Hide file tree
Changes from 46 commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
05ea790
refactor: Remove helper and improve typing of another
Josmithr Sep 16, 2025
30cbc79
feat(api-markdown-documenter): Class and interface items now inherit …
Josmithr Sep 16, 2025
a6fb1c0
refactor: Add utilities dir
Josmithr Sep 16, 2025
8342b3d
refactor: Move API item utils into directory
Josmithr Sep 16, 2025
c330692
refactor: Move test module
Josmithr Sep 16, 2025
1f4253b
Merge branch 'api-markdown-documenter/reorganize-utilities' into api-…
Josmithr Sep 16, 2025
29e77e8
refactor: Extract type inheritance utilities into their own module
Josmithr Sep 16, 2025
987894d
docs: Add module comment
Josmithr Sep 16, 2025
9b56a70
docs: TODOs
Josmithr Sep 16, 2025
4b3062e
refactor: Simplify section creation
Josmithr Sep 16, 2025
14e5840
refactor: Don't export helpers
Josmithr Sep 16, 2025
3c14079
refactor: Add new table creation utils
Josmithr Sep 16, 2025
8315d09
refactor: Use new table creation utils
Josmithr Sep 16, 2025
ca8f5e5
refactor: Use new table creation utils
Josmithr Sep 16, 2025
b9ec5f1
fix: `align` handling
Josmithr Sep 16, 2025
17b7641
refactor: More consistent table handling
Josmithr Sep 16, 2025
5569cc9
refactor: Make table creation utilities more general
Josmithr Sep 16, 2025
c788295
refactor: Use new table creation utils
Josmithr Sep 16, 2025
29d2fbf
refactor: Use new table creation utils
Josmithr Sep 16, 2025
5026b75
refactor: Use new table creation utils
Josmithr Sep 16, 2025
ba389c5
refactor: Rename utility function
Josmithr Sep 16, 2025
69e5b9e
refactor: Don't export functions
Josmithr Sep 16, 2025
f56c2cd
refactor: Use new table creation utility
Josmithr Sep 16, 2025
a55eb7e
refactor: Rename utility function
Josmithr Sep 16, 2025
b732f78
refactor: Cleanup
Josmithr Sep 16, 2025
262071f
Merge branch 'main' into api-markdown-documenter/improve-table-helpers
Josmithr Sep 16, 2025
bf26110
Merge branch 'main' into api-markdown-documenter/inherit-members
Josmithr Sep 16, 2025
88b2168
Merge branch 'api-markdown-documenter/improve-table-helpers' into api…
Josmithr Sep 16, 2025
7ead26b
bump: Version for publishing
Josmithr Sep 16, 2025
b76f140
refactor: Fix typo
Josmithr Sep 16, 2025
1dfda98
fix: Don't generate empty cells
Josmithr Sep 16, 2025
9ea079f
Merge branch 'api-markdown-documenter/improve-table-helpers' into api…
Josmithr Sep 16, 2025
a936ea8
docs: Add comments
Josmithr Sep 16, 2025
8939d41
docs: Add property docs
Josmithr Sep 16, 2025
4a2f6cd
fix: Inheritance resolution
Josmithr Sep 17, 2025
94ead60
docs: TODO
Josmithr Sep 17, 2025
99f8928
fix: Don't inherit static members
Josmithr Sep 17, 2025
8796129
refactor: Add new utility type
Josmithr Sep 17, 2025
c4bcfe9
refactor: Extract function
Josmithr Sep 17, 2025
22835c6
Merge branch 'main' into api-markdown-documenter/inherit-members
Josmithr Sep 17, 2025
a8896cc
docs: TODOs
Josmithr Sep 17, 2025
9d2ac4b
refactor: Use explicit table helpers
Josmithr Sep 17, 2025
4b11b21
Merge branch 'main' into api-markdown-documenter/inherit-members
Josmithr Sep 17, 2025
e697a54
WIP: Display more information
Josmithr Sep 17, 2025
1e3c2f1
refactor: Rename property
Josmithr Sep 17, 2025
448ef69
refactor: Cleanup
Josmithr Sep 17, 2025
8a14cd2
refactor: Extract function
Josmithr Sep 17, 2025
4134f1e
Merge branch 'main' into api-markdown-documenter/inherit-members
Josmithr Sep 17, 2025
68fcc03
Merge branch 'main' into api-markdown-documenter/inherit-members
Josmithr Sep 18, 2025
fb120a5
fix: Table column labeling
Josmithr Sep 18, 2025
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
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ import { TypeParameter } from '@microsoft/api-extractor-model';
// @public
function ancestryHasModifierTag(apiItem: ApiItem, tagName: string): boolean;

// @public
export type ApiConstructorLike = ApiConstructor | ApiConstructSignature;

// @public @sealed
export interface ApiDocument {
readonly apiItem: ApiItem;
Expand All @@ -49,7 +52,7 @@ export interface ApiDocument {
}

// @public
export type ApiFunctionLike = ApiConstructSignature | ApiConstructor | ApiFunction | ApiMethod | ApiMethodSignature;
export type ApiFunctionLike = ApiConstructorLike | ApiFunction | ApiMethod | ApiMethodSignature;

export { ApiItem }

Expand Down Expand Up @@ -268,7 +271,7 @@ export namespace DocumentWriter {
}

// @public
function filterItems(apiItems: readonly ApiItem[], config: ApiItemTransformationConfiguration): ApiItem[];
function filterItems<TApiItem extends ApiItem>(apiItems: readonly TApiItem[], config: ApiItemTransformationConfiguration): TApiItem[];

// @public
export enum FolderDocumentPlacement {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import type { Section, SectionContent } from "../../mdast/index.js";
import { getApiItemKind, getScopedMemberNameForDiagnostics } from "../../utilities/index.js";
import type { ApiItemTransformationConfiguration } from "../configuration/index.js";
import { createMemberTables } from "../helpers/index.js";
import { getFilteredMembers } from "../utilities/index.js";
import { filterItems } from "../utilities/index.js";

/**
* Default documentation transform for `Enum` items.
Expand All @@ -26,15 +26,15 @@ export function transformApiEnum(
): Section[] {
const sections: Section[] = [];

const filteredChildren = getFilteredMembers(apiEnum, config);
const filteredChildren = filterItems(apiEnum.members, config);
if (filteredChildren.length > 0) {
// Accumulate child items
const flags: ApiEnumMember[] = [];
for (const child of filteredChildren) {
const childKind = getApiItemKind(child);
switch (childKind) {
case ApiItemKind.EnumMember: {
flags.push(child as ApiEnumMember);
flags.push(child);
break;
}
default: {
Expand Down
Loading
Loading