typedoc 0.27.9 → 0.28.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -26
- package/bin/package.json +1 -1
- package/dist/browser-locales/en.d.ts +2 -0
- package/dist/browser-locales/en.js +62 -0
- package/dist/browser-locales/ja.d.ts +2 -0
- package/dist/browser-locales/ja.js +62 -0
- package/dist/browser-locales/ko.d.ts +2 -0
- package/dist/browser-locales/ko.js +62 -0
- package/dist/browser-locales/zh.d.ts +2 -0
- package/dist/browser-locales/zh.js +62 -0
- package/dist/browser-utils.d.ts +3 -0
- package/dist/browser-utils.js +3 -0
- package/dist/index.d.ts +15 -9
- package/dist/index.js +13 -7
- package/dist/lib/application.d.ts +9 -10
- package/dist/lib/application.js +75 -56
- package/dist/lib/cli.js +4 -3
- package/dist/lib/converter/comments/blockLexer.js +2 -2
- package/dist/lib/converter/comments/declarationReferenceResolver.d.ts +1 -1
- package/dist/lib/converter/comments/declarationReferenceResolver.js +8 -10
- package/dist/lib/converter/comments/discovery.d.ts +1 -1
- package/dist/lib/converter/comments/discovery.js +3 -4
- package/dist/lib/converter/comments/index.d.ts +1 -1
- package/dist/lib/converter/comments/index.js +5 -7
- package/dist/lib/converter/comments/linkResolver.d.ts +1 -1
- package/dist/lib/converter/comments/linkResolver.js +10 -16
- package/dist/lib/converter/comments/parser.d.ts +2 -2
- package/dist/lib/converter/comments/parser.js +8 -8
- package/dist/lib/converter/comments/textParser.d.ts +3 -2
- package/dist/lib/converter/comments/textParser.js +1 -2
- package/dist/lib/converter/context.d.ts +13 -14
- package/dist/lib/converter/context.js +49 -13
- package/dist/lib/converter/converter.d.ts +10 -5
- package/dist/lib/converter/converter.js +59 -42
- package/dist/lib/converter/factories/index-signature.js +3 -2
- package/dist/lib/converter/factories/signature.js +5 -6
- package/dist/lib/converter/factories/symbol-id.d.ts +4 -0
- package/dist/lib/converter/factories/symbol-id.js +92 -0
- package/dist/lib/converter/factories/types.d.ts +4 -0
- package/dist/lib/converter/factories/types.js +13 -0
- package/dist/lib/converter/index.d.ts +3 -4
- package/dist/lib/converter/index.js +2 -2
- package/dist/lib/converter/jsdoc.js +5 -4
- package/dist/lib/converter/plugins/CategoryPlugin.js +4 -2
- package/dist/lib/converter/plugins/CommentPlugin.d.ts +0 -1
- package/dist/lib/converter/plugins/CommentPlugin.js +8 -6
- package/dist/lib/converter/plugins/GroupPlugin.d.ts +2 -3
- package/dist/lib/converter/plugins/GroupPlugin.js +8 -7
- package/dist/lib/converter/plugins/ImplementsPlugin.js +6 -8
- package/dist/lib/converter/plugins/IncludePlugin.d.ts +1 -1
- package/dist/lib/converter/plugins/IncludePlugin.js +19 -16
- package/dist/lib/converter/plugins/InheritDocPlugin.js +7 -9
- package/dist/lib/converter/plugins/MergeModuleWithPlugin.js +3 -2
- package/dist/lib/converter/plugins/PackagePlugin.d.ts +3 -2
- package/dist/lib/converter/plugins/PackagePlugin.js +23 -19
- package/dist/lib/converter/plugins/SourcePlugin.d.ts +2 -1
- package/dist/lib/converter/plugins/SourcePlugin.js +10 -9
- package/dist/lib/converter/plugins/TypePlugin.d.ts +1 -1
- package/dist/lib/converter/plugins/TypePlugin.js +1 -1
- package/dist/lib/converter/plugins/index.d.ts +1 -1
- package/dist/lib/converter/plugins/index.js +1 -1
- package/dist/lib/converter/symbols.js +103 -32
- package/dist/lib/converter/types.js +14 -13
- package/dist/lib/converter/utils/repository.d.ts +1 -1
- package/dist/lib/converter/utils/repository.js +2 -2
- package/dist/lib/debug/index.d.ts +2 -2
- package/dist/lib/debug/index.js +2 -2
- package/dist/lib/debug/{debugReflectionLifetimes.d.ts → reflectionLifetimes.d.ts} +2 -1
- package/dist/lib/debug/{debugReflectionLifetimes.js → reflectionLifetimes.js} +12 -4
- package/dist/lib/debug/{debugRendererUrls.d.ts → rendererUrls.d.ts} +1 -0
- package/dist/lib/debug/rendererUrls.js +68 -0
- package/dist/lib/internationalization/index.d.ts +2 -1
- package/dist/lib/internationalization/index.js +2 -1
- package/dist/lib/internationalization/internationalization.d.ts +16 -46
- package/dist/lib/internationalization/internationalization.js +44 -213
- package/dist/lib/internationalization/locales/en.cjs +9 -1
- package/dist/lib/internationalization/locales/en.d.cts +9 -1
- package/dist/lib/internationalization/locales/ja.cjs +1 -0
- package/dist/lib/internationalization/locales/zh.cjs +61 -5
- package/dist/lib/internationalization/locales/zh.d.cts +26 -2
- package/dist/lib/internationalization/translatable.d.ts +2 -1
- package/dist/lib/models/{comments/comment.d.ts → Comment.d.ts} +9 -8
- package/dist/lib/models/{comments/comment.js → Comment.js} +15 -18
- package/dist/lib/models/{reflections/container.d.ts → ContainerReflection.d.ts} +6 -6
- package/dist/lib/models/{reflections/container.js → ContainerReflection.js} +4 -5
- package/dist/lib/models/{reflections/declaration.d.ts → DeclarationReflection.d.ts} +11 -19
- package/dist/lib/models/{reflections/declaration.js → DeclarationReflection.js} +11 -29
- package/dist/lib/models/{reflections/document.d.ts → DocumentReflection.d.ts} +3 -3
- package/dist/lib/models/{reflections/document.js → DocumentReflection.js} +3 -3
- package/dist/lib/models/FileRegistry.d.ts +12 -20
- package/dist/lib/models/FileRegistry.js +8 -44
- package/dist/lib/models/{reflections/parameter.d.ts → ParameterReflection.d.ts} +4 -4
- package/dist/lib/models/{reflections/parameter.js → ParameterReflection.js} +2 -2
- package/dist/lib/models/{reflections/project.d.ts → ProjectReflection.d.ts} +12 -21
- package/dist/lib/models/{reflections/project.js → ProjectReflection.js} +16 -48
- package/dist/lib/models/{reflections/reference.d.ts → ReferenceReflection.d.ts} +3 -3
- package/dist/lib/models/{reflections/reference.js → ReferenceReflection.js} +3 -4
- package/dist/lib/models/{reflections/abstract.d.ts → Reflection.d.ts} +15 -28
- package/dist/lib/models/{reflections/abstract.js → Reflection.js} +38 -21
- package/dist/lib/models/ReflectionCategory.d.ts +2 -6
- package/dist/lib/models/ReflectionCategory.js +3 -9
- package/dist/lib/models/ReflectionGroup.d.ts +1 -5
- package/dist/lib/models/ReflectionGroup.js +2 -8
- package/dist/lib/models/{reflections/ReflectionSymbolId.d.ts → ReflectionSymbolId.d.ts} +23 -10
- package/dist/lib/models/ReflectionSymbolId.js +75 -0
- package/dist/lib/models/{reflections/signature.d.ts → SignatureReflection.d.ts} +8 -7
- package/dist/lib/models/{reflections/signature.js → SignatureReflection.js} +7 -11
- package/dist/lib/models/{sources/file.d.ts → SourceReference.d.ts} +3 -4
- package/dist/lib/models/{reflections/type-parameter.d.ts → TypeParameterReflection.d.ts} +6 -5
- package/dist/lib/models/{reflections/type-parameter.js → TypeParameterReflection.js} +4 -1
- package/dist/lib/models/index.d.ts +18 -6
- package/dist/lib/models/index.js +18 -6
- package/dist/lib/models/{reflections/kind.d.ts → kind.d.ts} +2 -8
- package/dist/lib/models/{reflections/kind.js → kind.js} +99 -30
- package/dist/lib/models/types.d.ts +8 -10
- package/dist/lib/models/types.js +11 -22
- package/dist/lib/models/{reflections/variant.d.ts → variant.d.ts} +7 -7
- package/dist/lib/output/components.d.ts +2 -2
- package/dist/lib/output/components.js +1 -1
- package/dist/lib/output/events.d.ts +10 -18
- package/dist/lib/output/events.js +10 -27
- package/dist/lib/output/formatter.d.ts +8 -5
- package/dist/lib/output/formatter.js +45 -18
- package/dist/lib/output/index.d.ts +4 -5
- package/dist/lib/output/index.js +4 -4
- package/dist/lib/output/output.js +5 -4
- package/dist/lib/output/plugins/AssetsPlugin.js +7 -6
- package/dist/lib/output/plugins/HierarchyPlugin.js +4 -3
- package/dist/lib/output/plugins/IconsPlugin.js +3 -3
- package/dist/lib/output/plugins/JavascriptIndexPlugin.js +12 -17
- package/dist/lib/output/plugins/SitemapPlugin.js +6 -7
- package/dist/lib/output/renderer.d.ts +22 -14
- package/dist/lib/output/renderer.js +76 -36
- package/dist/lib/output/router.d.ts +175 -0
- package/dist/lib/output/router.js +478 -0
- package/dist/lib/output/theme.d.ts +3 -28
- package/dist/lib/output/theme.js +2 -15
- package/dist/lib/output/themes/MarkedPlugin.d.ts +2 -2
- package/dist/lib/output/themes/MarkedPlugin.js +32 -30
- package/dist/lib/output/themes/default/DefaultTheme.d.ts +11 -40
- package/dist/lib/output/themes/default/DefaultTheme.js +207 -406
- package/dist/lib/output/themes/default/DefaultThemeRenderContext.d.ts +49 -47
- package/dist/lib/output/themes/default/DefaultThemeRenderContext.js +17 -14
- package/dist/lib/output/themes/default/Slugger.js +1 -1
- package/dist/lib/output/themes/default/layouts/default.d.ts +1 -1
- package/dist/lib/output/themes/default/layouts/default.js +6 -6
- package/dist/lib/output/themes/default/partials/anchor-icon.d.ts +4 -1
- package/dist/lib/output/themes/default/partials/anchor-icon.js +12 -2
- package/dist/lib/output/themes/default/partials/breadcrumb.d.ts +2 -2
- package/dist/lib/output/themes/default/partials/breadcrumb.js +11 -5
- package/dist/lib/output/themes/default/partials/comment.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/comment.js +9 -9
- package/dist/lib/output/themes/default/partials/footer.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/footer.js +2 -2
- package/dist/lib/output/themes/default/partials/header.d.ts +2 -2
- package/dist/lib/output/themes/default/partials/header.js +4 -3
- package/dist/lib/output/themes/default/partials/hierarchy.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/hierarchy.js +10 -8
- package/dist/lib/output/themes/default/partials/icon.d.ts +2 -3
- package/dist/lib/output/themes/default/partials/icon.js +3 -3
- package/dist/lib/output/themes/default/partials/index.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/index.js +10 -18
- package/dist/lib/output/themes/default/partials/member.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/member.declaration.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/member.declaration.js +2 -2
- package/dist/lib/output/themes/default/partials/member.getterSetter.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/member.getterSetter.js +5 -5
- package/dist/lib/output/themes/default/partials/member.js +10 -9
- package/dist/lib/output/themes/default/partials/member.signature.body.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/member.signature.body.js +4 -4
- package/dist/lib/output/themes/default/partials/member.signature.title.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/member.signature.title.js +1 -1
- package/dist/lib/output/themes/default/partials/member.signatures.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/member.signatures.js +4 -4
- package/dist/lib/output/themes/default/partials/member.sources.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/member.sources.js +7 -7
- package/dist/lib/output/themes/default/partials/members.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/members.js +2 -2
- package/dist/lib/output/themes/default/partials/moduleReflection.d.ts +2 -2
- package/dist/lib/output/themes/default/partials/moduleReflection.js +5 -5
- package/dist/lib/output/themes/default/partials/navigation.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/navigation.js +17 -15
- package/dist/lib/output/themes/default/partials/reflectionPreview.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/reflectionPreview.js +2 -2
- package/dist/lib/output/themes/default/partials/toolbar.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/toolbar.js +10 -13
- package/dist/lib/output/themes/default/partials/type.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/type.js +1 -1
- package/dist/lib/output/themes/default/partials/typeAndParent.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/typeAndParent.js +3 -3
- package/dist/lib/output/themes/default/partials/typeDetails.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/typeDetails.js +23 -19
- package/dist/lib/output/themes/default/partials/typeParameters.d.ts +1 -1
- package/dist/lib/output/themes/default/partials/typeParameters.js +12 -7
- package/dist/lib/output/themes/default/templates/document.d.ts +1 -1
- package/dist/lib/output/themes/default/templates/document.js +2 -2
- package/dist/lib/output/themes/default/templates/hierarchy.d.ts +1 -1
- package/dist/lib/output/themes/default/templates/hierarchy.js +4 -3
- package/dist/lib/output/themes/default/templates/index.d.ts +1 -1
- package/dist/lib/output/themes/default/templates/index.js +2 -2
- package/dist/lib/output/themes/default/templates/reflection.d.ts +1 -1
- package/dist/lib/output/themes/default/templates/reflection.js +9 -12
- package/dist/lib/output/themes/lib.d.ts +1 -1
- package/dist/lib/output/themes/lib.js +3 -3
- package/dist/lib/serialization/components.d.ts +1 -1
- package/dist/lib/serialization/deserializer.d.ts +9 -13
- package/dist/lib/serialization/deserializer.js +22 -24
- package/dist/lib/serialization/events.d.ts +1 -1
- package/dist/lib/serialization/index.d.ts +1 -1
- package/dist/lib/serialization/index.js +1 -1
- package/dist/lib/serialization/schema.d.ts +15 -10
- package/dist/lib/serialization/schema.js +1 -1
- package/dist/lib/serialization/serializer.d.ts +4 -4
- package/dist/lib/serialization/serializer.js +1 -2
- package/dist/lib/utils/ValidatingFileRegistry.d.ts +10 -0
- package/dist/lib/utils/ValidatingFileRegistry.js +34 -0
- package/dist/lib/utils/component.d.ts +1 -1
- package/dist/lib/utils/component.js +1 -1
- package/dist/lib/utils/entry-point.d.ts +3 -3
- package/dist/lib/utils/entry-point.js +29 -26
- package/dist/lib/utils/fs.d.ts +5 -13
- package/dist/lib/utils/fs.js +11 -67
- package/dist/lib/utils/general.d.ts +1 -47
- package/dist/lib/utils/general.js +4 -74
- package/dist/lib/utils/highlighter.js +1 -2
- package/dist/lib/utils/html.d.ts +0 -1
- package/dist/lib/utils/html.js +4 -13
- package/dist/lib/utils/index.d.ts +9 -17
- package/dist/lib/utils/index.js +8 -15
- package/dist/lib/utils/loggers.d.ts +5 -108
- package/dist/lib/utils/loggers.js +24 -168
- package/dist/lib/utils/options/declaration.d.ts +63 -38
- package/dist/lib/utils/options/declaration.js +124 -66
- package/dist/lib/utils/options/defaults.d.ts +1 -1
- package/dist/lib/utils/options/help.d.ts +1 -2
- package/dist/lib/utils/options/help.js +5 -5
- package/dist/lib/utils/options/index.d.ts +4 -4
- package/dist/lib/utils/options/index.js +3 -3
- package/dist/lib/utils/options/options.d.ts +3 -6
- package/dist/lib/utils/options/options.js +10 -12
- package/dist/lib/utils/options/readers/arguments.d.ts +2 -2
- package/dist/lib/utils/options/readers/arguments.js +4 -3
- package/dist/lib/utils/options/readers/package-json.d.ts +1 -1
- package/dist/lib/utils/options/readers/package-json.js +3 -2
- package/dist/lib/utils/options/readers/tsconfig.d.ts +1 -1
- package/dist/lib/utils/options/readers/tsconfig.js +27 -27
- package/dist/lib/utils/options/readers/typedoc.d.ts +1 -1
- package/dist/lib/utils/options/readers/typedoc.js +8 -9
- package/dist/lib/utils/options/sources/typedoc.js +143 -135
- package/dist/lib/utils/options/tsdoc-defaults.d.ts +1 -1
- package/dist/lib/utils/options/tsdoc-defaults.js +3 -1
- package/dist/lib/utils/package-manifest.d.ts +3 -3
- package/dist/lib/utils/package-manifest.js +9 -8
- package/dist/lib/utils/paths.d.ts +17 -6
- package/dist/lib/utils/paths.js +94 -11
- package/dist/lib/utils/perf.d.ts +4 -1
- package/dist/lib/utils/perf.js +32 -13
- package/dist/lib/utils/plugins.js +4 -3
- package/dist/lib/utils/sort.d.ts +1 -1
- package/dist/lib/utils/sort.js +8 -3
- package/dist/lib/utils/tsconfig.d.ts +1 -1
- package/dist/lib/utils/tsconfig.js +4 -3
- package/dist/lib/utils-common/general.d.ts +40 -0
- package/dist/lib/utils-common/general.js +20 -0
- package/dist/lib/utils-common/i18n.d.ts +17 -0
- package/dist/lib/utils-common/i18n.js +39 -0
- package/dist/lib/utils-common/index.d.ts +16 -0
- package/dist/lib/utils-common/index.js +18 -0
- package/dist/lib/{utils → utils-common}/jsx.d.ts +3 -3
- package/dist/lib/{utils → utils-common}/jsx.js +1 -1
- package/dist/lib/utils-common/logger.d.ts +86 -0
- package/dist/lib/utils-common/logger.js +120 -0
- package/dist/lib/{utils → utils-common}/minimalSourceFile.d.ts +7 -2
- package/dist/lib/{utils → utils-common}/minimalSourceFile.js +3 -2
- package/dist/lib/utils-common/path.d.ts +35 -0
- package/dist/lib/utils-common/path.js +123 -0
- package/dist/lib/utils-common/string.d.ts +11 -0
- package/dist/lib/utils-common/string.js +84 -0
- package/dist/lib/validation/documentation.d.ts +2 -2
- package/dist/lib/validation/documentation.js +5 -6
- package/dist/lib/validation/exports.d.ts +1 -1
- package/dist/lib/validation/exports.js +4 -4
- package/dist/lib/validation/links.d.ts +1 -1
- package/dist/lib/validation/links.js +9 -8
- package/dist/lib/validation/unusedMergeModuleWith.d.ts +1 -1
- package/dist/lib/validation/unusedMergeModuleWith.js +3 -2
- package/package.json +57 -36
- package/static/main.js +4 -4
- package/static/style.css +232 -209
- package/tsdoc.json +8 -0
- package/dist/lib/debug/debugRendererUrls.js +0 -59
- package/dist/lib/internationalization/locales/jp.cjs +0 -3
- package/dist/lib/internationalization/locales/jp.d.cts +0 -2
- package/dist/lib/models/comments/index.d.ts +0 -2
- package/dist/lib/models/comments/index.js +0 -1
- package/dist/lib/models/reflections/ReflectionSymbolId.js +0 -133
- package/dist/lib/models/reflections/index.d.ts +0 -15
- package/dist/lib/models/reflections/index.js +0 -12
- package/dist/lib/models/sources/index.d.ts +0 -1
- package/dist/lib/models/sources/index.js +0 -1
- package/dist/lib/output/models/UrlMapping.d.ts +0 -13
- package/dist/lib/output/models/UrlMapping.js +0 -10
- /package/dist/lib/models/{sources/file.js → SourceReference.js} +0 -0
- /package/dist/lib/models/{reflections/utils.d.ts → utils.d.ts} +0 -0
- /package/dist/lib/models/{reflections/utils.js → utils.js} +0 -0
- /package/dist/lib/models/{reflections/variant.js → variant.js} +0 -0
- /package/dist/lib/{utils → utils-common}/array.d.ts +0 -0
- /package/dist/lib/{utils → utils-common}/array.js +0 -0
- /package/dist/lib/{converter/comments → utils-common}/declarationReference.d.ts +0 -0
- /package/dist/lib/{converter/comments → utils-common}/declarationReference.js +0 -0
- /package/dist/lib/{utils → utils-common}/enum.d.ts +0 -0
- /package/dist/lib/{utils → utils-common}/enum.js +0 -0
- /package/dist/lib/{utils → utils-common}/events.d.ts +0 -0
- /package/dist/lib/{utils → utils-common}/events.js +0 -0
- /package/dist/lib/{utils → utils-common}/hooks.d.ts +0 -0
- /package/dist/lib/{utils → utils-common}/hooks.js +0 -0
- /package/dist/lib/{utils → utils-common}/jsx.elements.d.ts +0 -0
- /package/dist/lib/{utils → utils-common}/jsx.elements.js +0 -0
- /package/dist/lib/{utils → utils-common}/map.d.ts +0 -0
- /package/dist/lib/{utils → utils-common}/map.js +0 -0
- /package/dist/lib/{utils → utils-common}/set.d.ts +0 -0
- /package/dist/lib/{utils → utils-common}/set.js +0 -0
- /package/dist/lib/{utils → utils-common}/validation.d.ts +0 -0
- /package/dist/lib/{utils → utils-common}/validation.js +0 -0
package/tsdoc.json
CHANGED
|
@@ -116,6 +116,10 @@
|
|
|
116
116
|
"tagName": "@inline",
|
|
117
117
|
"syntaxKind": "modifier"
|
|
118
118
|
},
|
|
119
|
+
{
|
|
120
|
+
"tagName": "@primaryExport",
|
|
121
|
+
"syntaxKind": "modifier"
|
|
122
|
+
},
|
|
119
123
|
{
|
|
120
124
|
"tagName": "@template",
|
|
121
125
|
"syntaxKind": "block",
|
|
@@ -177,6 +181,10 @@
|
|
|
177
181
|
"tagName": "@interface",
|
|
178
182
|
"syntaxKind": "modifier"
|
|
179
183
|
},
|
|
184
|
+
{
|
|
185
|
+
"tagName": "@function",
|
|
186
|
+
"syntaxKind": "modifier"
|
|
187
|
+
},
|
|
180
188
|
{
|
|
181
189
|
"tagName": "@showCategories",
|
|
182
190
|
"syntaxKind": "modifier"
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
/* eslint-disable no-console */
|
|
2
|
-
import { join } from "node:path";
|
|
3
|
-
import { Reflection, ReflectionKind, } from "../models/index.js";
|
|
4
|
-
const serializer = {
|
|
5
|
-
priority: 0,
|
|
6
|
-
supports(x) {
|
|
7
|
-
return x instanceof Reflection;
|
|
8
|
-
},
|
|
9
|
-
toObject(item, obj) {
|
|
10
|
-
obj.url = item.url;
|
|
11
|
-
obj.hasOwnDocument = item.hasOwnDocument;
|
|
12
|
-
// obj.anchor = item.anchor;
|
|
13
|
-
delete obj.sources;
|
|
14
|
-
delete obj.groups;
|
|
15
|
-
delete obj.categories;
|
|
16
|
-
delete obj.readme;
|
|
17
|
-
delete obj.content;
|
|
18
|
-
obj.kind = ReflectionKind[obj.kind];
|
|
19
|
-
delete obj.flags;
|
|
20
|
-
delete obj.defaultValue;
|
|
21
|
-
delete obj.symbolIdMap;
|
|
22
|
-
delete obj.files;
|
|
23
|
-
delete obj.packageName;
|
|
24
|
-
delete obj.variant;
|
|
25
|
-
delete obj.extendedTypes;
|
|
26
|
-
delete obj.inheritedFrom;
|
|
27
|
-
if (!["reflection", "reference"].includes(obj.type?.type)) {
|
|
28
|
-
delete obj.type;
|
|
29
|
-
}
|
|
30
|
-
if (obj.comment) {
|
|
31
|
-
obj.comment.summary = obj.comment.summary.filter((part) => part.kind === "inline-tag");
|
|
32
|
-
obj.comment.blockTags = obj.comment.blockTags?.filter((tag) => {
|
|
33
|
-
tag.content = tag.content.filter((part) => part.kind === "inline-tag");
|
|
34
|
-
return tag.content.length;
|
|
35
|
-
});
|
|
36
|
-
if (!obj.comment.summary.length &&
|
|
37
|
-
!obj.comment.blockTags?.length &&
|
|
38
|
-
!obj.comment.modifierTags) {
|
|
39
|
-
delete obj.comment;
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
return obj;
|
|
43
|
-
},
|
|
44
|
-
};
|
|
45
|
-
export function debugRendererUrls(app, { json = false, logs = false } = { logs: true }) {
|
|
46
|
-
app.renderer.postRenderAsyncJobs.push(async (evt) => {
|
|
47
|
-
if (json) {
|
|
48
|
-
app.serializer.addSerializer(serializer);
|
|
49
|
-
await app.generateJson(evt.project, join(evt.outputDirectory, "url_debug.json"));
|
|
50
|
-
app.serializer.removeSerializer(serializer);
|
|
51
|
-
}
|
|
52
|
-
if (logs) {
|
|
53
|
-
for (const id in evt.project.reflections) {
|
|
54
|
-
const refl = evt.project.reflections[id];
|
|
55
|
-
console.log(refl.id, refl.getFullName(), refl.url, refl.hasOwnDocument);
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
});
|
|
59
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { Comment, CommentTag } from "./comment.js";
|
|
@@ -1,133 +0,0 @@
|
|
|
1
|
-
import { existsSync } from "fs";
|
|
2
|
-
import { isAbsolute, join, relative, resolve } from "path";
|
|
3
|
-
import ts from "typescript";
|
|
4
|
-
import { findPackageForPath, getCommonDirectory, readFile, } from "../../utils/fs.js";
|
|
5
|
-
import { normalizePath } from "../../utils/paths.js";
|
|
6
|
-
import { getQualifiedName } from "../../utils/tsutils.js";
|
|
7
|
-
import { optional, validate } from "../../utils/validation.js";
|
|
8
|
-
import { splitUnquotedString } from "./utils.js";
|
|
9
|
-
let transientCount = 0;
|
|
10
|
-
const transientIds = new WeakMap();
|
|
11
|
-
/**
|
|
12
|
-
* This exists so that TypeDoc can store a unique identifier for a `ts.Symbol` without
|
|
13
|
-
* keeping a reference to the `ts.Symbol` itself. This identifier should be stable across
|
|
14
|
-
* runs so long as the symbol is exported from the same file.
|
|
15
|
-
*/
|
|
16
|
-
export class ReflectionSymbolId {
|
|
17
|
-
fileName;
|
|
18
|
-
qualifiedName;
|
|
19
|
-
/**
|
|
20
|
-
* Note: This is **not** serialized. It exists for sorting by declaration order, but
|
|
21
|
-
* should not be needed when deserializing from JSON.
|
|
22
|
-
* Will be set to `Infinity` if the ID was deserialized from JSON.
|
|
23
|
-
*/
|
|
24
|
-
pos;
|
|
25
|
-
/**
|
|
26
|
-
* Note: This is **not** serialized. It exists to support detection of the differences between
|
|
27
|
-
* symbols which share declarations, but are instantiated with different type parameters.
|
|
28
|
-
* This will be `NaN` if the symbol reference is not transient.
|
|
29
|
-
* Note: This can only be non-NaN if {@link pos} is finite.
|
|
30
|
-
*/
|
|
31
|
-
transientId;
|
|
32
|
-
constructor(symbol, declaration) {
|
|
33
|
-
if ("name" in symbol) {
|
|
34
|
-
declaration ??= symbol.declarations?.[0];
|
|
35
|
-
this.fileName = normalizePath(declaration?.getSourceFile().fileName ?? "");
|
|
36
|
-
if (symbol.declarations?.some(ts.isSourceFile)) {
|
|
37
|
-
this.qualifiedName = "";
|
|
38
|
-
}
|
|
39
|
-
else {
|
|
40
|
-
this.qualifiedName = getQualifiedName(symbol, symbol.name);
|
|
41
|
-
}
|
|
42
|
-
this.pos = declaration?.getStart() ?? Infinity;
|
|
43
|
-
if (symbol.flags & ts.SymbolFlags.Transient) {
|
|
44
|
-
this.transientId = transientIds.get(symbol) ?? ++transientCount;
|
|
45
|
-
transientIds.set(symbol, this.transientId);
|
|
46
|
-
}
|
|
47
|
-
else {
|
|
48
|
-
this.transientId = NaN;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
else {
|
|
52
|
-
this.fileName = symbol.sourceFileName;
|
|
53
|
-
this.qualifiedName = symbol.qualifiedName;
|
|
54
|
-
this.pos = Infinity;
|
|
55
|
-
this.transientId = NaN;
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
getStableKey() {
|
|
59
|
-
if (Number.isFinite(this.pos)) {
|
|
60
|
-
return `${this.fileName}\0${this.qualifiedName}\0${this.pos}\0${this.transientId}`;
|
|
61
|
-
}
|
|
62
|
-
else {
|
|
63
|
-
return `${this.fileName}\0${this.qualifiedName}`;
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
toDeclarationReference() {
|
|
67
|
-
return {
|
|
68
|
-
resolutionStart: "global",
|
|
69
|
-
moduleSource: findPackageForPath(this.fileName),
|
|
70
|
-
symbolReference: {
|
|
71
|
-
path: splitUnquotedString(this.qualifiedName, ".").map((path) => ({
|
|
72
|
-
navigation: ".",
|
|
73
|
-
path,
|
|
74
|
-
})),
|
|
75
|
-
},
|
|
76
|
-
};
|
|
77
|
-
}
|
|
78
|
-
toObject(serializer) {
|
|
79
|
-
const sourceFileName = isAbsolute(this.fileName)
|
|
80
|
-
? normalizePath(relative(serializer.projectRoot, resolveDeclarationMaps(this.fileName)))
|
|
81
|
-
: this.fileName;
|
|
82
|
-
return {
|
|
83
|
-
sourceFileName,
|
|
84
|
-
qualifiedName: this.qualifiedName,
|
|
85
|
-
};
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
const declarationMapCache = new Map();
|
|
89
|
-
function resolveDeclarationMaps(file) {
|
|
90
|
-
if (!/\.d\.[cm]?ts$/.test(file))
|
|
91
|
-
return file;
|
|
92
|
-
if (declarationMapCache.has(file))
|
|
93
|
-
return declarationMapCache.get(file);
|
|
94
|
-
const mapFile = file + ".map";
|
|
95
|
-
if (!existsSync(mapFile))
|
|
96
|
-
return file;
|
|
97
|
-
let sourceMap;
|
|
98
|
-
try {
|
|
99
|
-
sourceMap = JSON.parse(readFile(mapFile));
|
|
100
|
-
}
|
|
101
|
-
catch {
|
|
102
|
-
return file;
|
|
103
|
-
}
|
|
104
|
-
if (validate({
|
|
105
|
-
file: String,
|
|
106
|
-
sourceRoot: optional(String),
|
|
107
|
-
sources: [Array, String],
|
|
108
|
-
}, sourceMap)) {
|
|
109
|
-
// There's a pretty large assumption in here that we only have
|
|
110
|
-
// 1 source file per js file. This is a pretty standard typescript approach,
|
|
111
|
-
// but people might do interesting things with transpilation that could break this.
|
|
112
|
-
let source = sourceMap.sources[0];
|
|
113
|
-
// If we have a sourceRoot, trim any leading slash from the source, and join them
|
|
114
|
-
// Similar to how it's done at https://github.com/mozilla/source-map/blob/58819f09018d56ef84dc41ba9c93f554e0645169/lib/util.js#L412
|
|
115
|
-
if (sourceMap.sourceRoot !== undefined) {
|
|
116
|
-
source = source.replace(/^\//, "");
|
|
117
|
-
source = join(sourceMap.sourceRoot, source);
|
|
118
|
-
}
|
|
119
|
-
const result = resolve(mapFile, "..", source);
|
|
120
|
-
declarationMapCache.set(file, result);
|
|
121
|
-
return result;
|
|
122
|
-
}
|
|
123
|
-
return file;
|
|
124
|
-
}
|
|
125
|
-
// See also: inferEntryPoints in entry-point.ts
|
|
126
|
-
export function addInferredDeclarationMapPaths(opts, files) {
|
|
127
|
-
const rootDir = opts.rootDir || getCommonDirectory(files);
|
|
128
|
-
const declDir = opts.declarationDir || opts.outDir || rootDir;
|
|
129
|
-
for (const file of files) {
|
|
130
|
-
const mapFile = normalizePath(resolve(declDir, relative(rootDir, file)).replace(/\.([cm]?[tj]s)x?$/, ".d.$1"));
|
|
131
|
-
declarationMapCache.set(mapFile, file);
|
|
132
|
-
}
|
|
133
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export { Reflection, ReflectionFlag, ReflectionFlags, TraverseProperty, } from "./abstract.js";
|
|
2
|
-
export type { ReflectionVisitor, TraverseCallback, ReflectionId, } from "./abstract.js";
|
|
3
|
-
export { ContainerReflection } from "./container.js";
|
|
4
|
-
export { DeclarationReflection } from "./declaration.js";
|
|
5
|
-
export type { DeclarationHierarchy } from "./declaration.js";
|
|
6
|
-
export { DocumentReflection } from "./document.js";
|
|
7
|
-
export { ReflectionKind } from "./kind.js";
|
|
8
|
-
export { ParameterReflection } from "./parameter.js";
|
|
9
|
-
export { ProjectReflection } from "./project.js";
|
|
10
|
-
export { ReferenceReflection } from "./reference.js";
|
|
11
|
-
export { ReflectionSymbolId, type ReflectionSymbolIdString, } from "./ReflectionSymbolId.js";
|
|
12
|
-
export { SignatureReflection } from "./signature.js";
|
|
13
|
-
export { TypeParameterReflection, VarianceModifier } from "./type-parameter.js";
|
|
14
|
-
export { splitUnquotedString } from "./utils.js";
|
|
15
|
-
export type { ReflectionVariant, SomeReflection } from "./variant.js";
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
export { Reflection, ReflectionFlag, ReflectionFlags, TraverseProperty, } from "./abstract.js";
|
|
2
|
-
export { ContainerReflection } from "./container.js";
|
|
3
|
-
export { DeclarationReflection } from "./declaration.js";
|
|
4
|
-
export { DocumentReflection } from "./document.js";
|
|
5
|
-
export { ReflectionKind } from "./kind.js";
|
|
6
|
-
export { ParameterReflection } from "./parameter.js";
|
|
7
|
-
export { ProjectReflection } from "./project.js";
|
|
8
|
-
export { ReferenceReflection } from "./reference.js";
|
|
9
|
-
export { ReflectionSymbolId, } from "./ReflectionSymbolId.js";
|
|
10
|
-
export { SignatureReflection } from "./signature.js";
|
|
11
|
-
export { TypeParameterReflection, VarianceModifier } from "./type-parameter.js";
|
|
12
|
-
export { splitUnquotedString } from "./utils.js";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { SourceReference } from "./file.js";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { SourceReference } from "./file.js";
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { JSX } from "../../utils/index.js";
|
|
2
|
-
import type { PageEvent } from "../events.js";
|
|
3
|
-
export declare class UrlMapping<Model = any> {
|
|
4
|
-
url: string;
|
|
5
|
-
model: Model;
|
|
6
|
-
template: RenderTemplate<PageEvent<Model>>;
|
|
7
|
-
constructor(url: string, model: Model, template: RenderTemplate<PageEvent<Model>>);
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* @param data the reflection to render
|
|
11
|
-
* @returns either a string to be written to the file, or an element to be serialized and then written.
|
|
12
|
-
*/
|
|
13
|
-
export type RenderTemplate<T> = (data: T) => JSX.Element | string;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|