Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/feature/typedoc' into feature/ty…
Browse files Browse the repository at this point in the history
…pedoc-signature
  • Loading branch information
ZEROM22 committed Dec 9, 2024
2 parents 3740da0 + b55a411 commit 77b1f63
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 23 deletions.
2 changes: 0 additions & 2 deletions packages/library-declaration/lib/next.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ export class Declaration {
signature = new DeclarationSignature()
summary = ""
description = ""
properties: Fragment[] = []
parameters: Fragment[] = []
returns = new DeclarationReturns()
examples = ""
Expand All @@ -63,7 +62,6 @@ export class Fragment {
default = ""
example = ""
description = ""
properties: Fragment[] = []
}

export class FragmentSignature {
Expand Down
29 changes: 8 additions & 21 deletions packages/typedoc-declaration/lib/internal.ts
Original file line number Diff line number Diff line change
Expand Up @@ -567,7 +567,6 @@ export function shakeItems(o: J.Reflection, c: Item[]): Entity[] {
p.children.push(...t.children)

if (p instanceof Declaration) {
p.properties.push(...t.properties)
p.parameters.push(...t.parameters)
}

Expand Down Expand Up @@ -755,7 +754,6 @@ export class Declaration {
name = ""
trail = new TrailDuplex()
narrative = new Narrative()
properties: Fragment[] = []
parameters: Fragment[] = []
parentId = -1
children: number[] = []
Expand Down Expand Up @@ -819,11 +817,6 @@ export class Declaration {
d.summary = this.narrative.summary
d.description = this.narrative.description

for (const f of this.properties) {
const t = f.to()
d.properties.push(t)
}

for (const f of this.parameters) {
const t = f.to()
d.parameters.push(t)
Expand Down Expand Up @@ -1214,12 +1207,6 @@ export class Repository {
const f = flatTrail(t.trail.real)
r.#trailIndex.set(d, f)

for (const [i, p] of t.properties.entries()) {
const e = d.properties[i]
const f = flatTrail(p.trail.real)
r.#trailIndex.set(e, f)
}

for (const [i, p] of t.parameters.entries()) {
const e = d.parameters[i]
const f = flatTrail(p.trail.real)
Expand Down Expand Up @@ -1299,20 +1286,20 @@ export function resolveTrail(o: J.Reflection, t: NestedTrail): J.Reflection | un

let t: J.Reflection[] = []

if (isSignatureReflection(o) && o.parameters) {
t = o.parameters
if (isSignatureReflection(c) && c.parameters) {
t = c.parameters
}

if (isDeclarationReflection(o) && isReflectionType(o.type)) {
t = [o.type.declaration]
if (isDeclarationReflection(c) && isReflectionType(c.type)) {
t = [c.type.declaration]
}

if (isDeclarationReflection(o) && o.signatures) {
t = o.signatures
if (isDeclarationReflection(c) && c.signatures) {
t = c.signatures
}

if (isContainerReflection(o) && o.children) {
t = o.children
if (isContainerReflection(c) && c.children) {
t = c.children
}

if (t.length !== 0) {
Expand Down

0 comments on commit 77b1f63

Please sign in to comment.