@xpack/doxygen2docusaurus 1.0.2 → 2.0.0
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 +3 -4
- package/dist/cli/main.d.ts +6 -0
- package/dist/cli/main.d.ts.map +1 -1
- package/dist/cli/main.js +29 -2
- package/dist/cli/main.js.map +1 -1
- package/dist/docusaurus/cli-options.d.ts +268 -39
- package/dist/docusaurus/cli-options.d.ts.map +1 -1
- package/dist/docusaurus/cli-options.js +267 -53
- package/dist/docusaurus/cli-options.js.map +1 -1
- package/dist/docusaurus/generator.d.ts +179 -4
- package/dist/docusaurus/generator.d.ts.map +1 -1
- package/dist/docusaurus/generator.js +215 -45
- package/dist/docusaurus/generator.js.map +1 -1
- package/dist/docusaurus/renderers/descriptiontype.d.ts +417 -0
- package/dist/docusaurus/renderers/descriptiontype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/descriptiontype.js +417 -0
- package/dist/docusaurus/renderers/descriptiontype.js.map +1 -1
- package/dist/docusaurus/renderers/docinternalstype.d.ts +132 -0
- package/dist/docusaurus/renderers/docinternalstype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/docinternalstype.js +132 -0
- package/dist/docusaurus/renderers/docinternalstype.js.map +1 -1
- package/dist/docusaurus/renderers/doclisttype.d.ts +22 -0
- package/dist/docusaurus/renderers/doclisttype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/doclisttype.js +22 -2
- package/dist/docusaurus/renderers/doclisttype.js.map +1 -1
- package/dist/docusaurus/renderers/doctabletype.d.ts +88 -0
- package/dist/docusaurus/renderers/doctabletype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/doctabletype.js +88 -0
- package/dist/docusaurus/renderers/doctabletype.js.map +1 -1
- package/dist/docusaurus/renderers/doctitletype.d.ts +22 -0
- package/dist/docusaurus/renderers/doctitletype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/doctitletype.js +22 -0
- package/dist/docusaurus/renderers/doctitletype.js.map +1 -1
- package/dist/docusaurus/renderers/docvariablelisttype.d.ts +44 -0
- package/dist/docusaurus/renderers/docvariablelisttype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/docvariablelisttype.js +44 -0
- package/dist/docusaurus/renderers/docvariablelisttype.js.map +1 -1
- package/dist/docusaurus/renderers/docxrefsecttype.d.ts +22 -0
- package/dist/docusaurus/renderers/docxrefsecttype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/docxrefsecttype.js +22 -0
- package/dist/docusaurus/renderers/docxrefsecttype.js.map +1 -1
- package/dist/docusaurus/renderers/element-renderer-base.d.ts +74 -0
- package/dist/docusaurus/renderers/element-renderer-base.d.ts.map +1 -1
- package/dist/docusaurus/renderers/element-renderer-base.js +52 -0
- package/dist/docusaurus/renderers/element-renderer-base.js.map +1 -1
- package/dist/docusaurus/renderers/inctype.d.ts +23 -0
- package/dist/docusaurus/renderers/inctype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/inctype.js +23 -0
- package/dist/docusaurus/renderers/inctype.js.map +1 -1
- package/dist/docusaurus/renderers/linkedtexttype.d.ts +22 -0
- package/dist/docusaurus/renderers/linkedtexttype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/linkedtexttype.js +22 -0
- package/dist/docusaurus/renderers/linkedtexttype.js.map +1 -1
- package/dist/docusaurus/renderers/listingtype.d.ts +52 -0
- package/dist/docusaurus/renderers/listingtype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/listingtype.js +66 -2
- package/dist/docusaurus/renderers/listingtype.js.map +1 -1
- package/dist/docusaurus/renderers/paramtype.d.ts +22 -0
- package/dist/docusaurus/renderers/paramtype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/paramtype.js +22 -0
- package/dist/docusaurus/renderers/paramtype.js.map +1 -1
- package/dist/docusaurus/renderers/referencetype.d.ts +23 -0
- package/dist/docusaurus/renderers/referencetype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/referencetype.js +23 -2
- package/dist/docusaurus/renderers/referencetype.js.map +1 -1
- package/dist/docusaurus/renderers/reftexttype.d.ts +22 -0
- package/dist/docusaurus/renderers/reftexttype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/reftexttype.js +22 -0
- package/dist/docusaurus/renderers/reftexttype.js.map +1 -1
- package/dist/docusaurus/renderers/reftype.d.ts +22 -0
- package/dist/docusaurus/renderers/reftype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/reftype.js +22 -0
- package/dist/docusaurus/renderers/reftype.js.map +1 -1
- package/dist/docusaurus/renderers/renderers.d.ts +151 -0
- package/dist/docusaurus/renderers/renderers.d.ts.map +1 -1
- package/dist/docusaurus/renderers/renderers.js +151 -0
- package/dist/docusaurus/renderers/renderers.js.map +1 -1
- package/dist/docusaurus/renderers/substringtype.d.ts +22 -0
- package/dist/docusaurus/renderers/substringtype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/substringtype.js +22 -0
- package/dist/docusaurus/renderers/substringtype.js.map +1 -1
- package/dist/docusaurus/renderers/tableofcontentstype.d.ts +22 -0
- package/dist/docusaurus/renderers/tableofcontentstype.d.ts.map +1 -1
- package/dist/docusaurus/renderers/tableofcontentstype.js +22 -0
- package/dist/docusaurus/renderers/tableofcontentstype.js.map +1 -1
- package/dist/docusaurus/types.d.ts +114 -8
- package/dist/docusaurus/types.d.ts.map +1 -1
- package/dist/docusaurus/types.js.map +1 -1
- package/dist/docusaurus/utils.d.ts +214 -0
- package/dist/docusaurus/utils.d.ts.map +1 -1
- package/dist/docusaurus/utils.js +214 -0
- package/dist/docusaurus/utils.js.map +1 -1
- package/dist/docusaurus/view-model/classes-vm.d.ts +139 -2
- package/dist/docusaurus/view-model/classes-vm.d.ts.map +1 -1
- package/dist/docusaurus/view-model/classes-vm.js +147 -6
- package/dist/docusaurus/view-model/classes-vm.js.map +1 -1
- package/dist/docusaurus/view-model/collection-base.d.ts +122 -2
- package/dist/docusaurus/view-model/collection-base.d.ts.map +1 -1
- package/dist/docusaurus/view-model/collection-base.js +78 -0
- package/dist/docusaurus/view-model/collection-base.js.map +1 -1
- package/dist/docusaurus/view-model/compound-base-vm.d.ts +134 -19
- package/dist/docusaurus/view-model/compound-base-vm.d.ts.map +1 -1
- package/dist/docusaurus/view-model/compound-base-vm.js +122 -26
- package/dist/docusaurus/view-model/compound-base-vm.js.map +1 -1
- package/dist/docusaurus/view-model/description-anchors.d.ts +58 -0
- package/dist/docusaurus/view-model/description-anchors.d.ts.map +1 -1
- package/dist/docusaurus/view-model/description-anchors.js +58 -0
- package/dist/docusaurus/view-model/description-anchors.js.map +1 -1
- package/dist/docusaurus/view-model/files-and-folders-vm.d.ts +249 -2
- package/dist/docusaurus/view-model/files-and-folders-vm.d.ts.map +1 -1
- package/dist/docusaurus/view-model/files-and-folders-vm.js +250 -4
- package/dist/docusaurus/view-model/files-and-folders-vm.js.map +1 -1
- package/dist/docusaurus/view-model/groups-vm.d.ts +150 -2
- package/dist/docusaurus/view-model/groups-vm.d.ts.map +1 -1
- package/dist/docusaurus/view-model/groups-vm.js +153 -5
- package/dist/docusaurus/view-model/groups-vm.js.map +1 -1
- package/dist/docusaurus/view-model/members-vm.d.ts +552 -0
- package/dist/docusaurus/view-model/members-vm.d.ts.map +1 -1
- package/dist/docusaurus/view-model/members-vm.js +552 -4
- package/dist/docusaurus/view-model/members-vm.js.map +1 -1
- package/dist/docusaurus/view-model/namespaces-vm.d.ts +201 -2
- package/dist/docusaurus/view-model/namespaces-vm.d.ts.map +1 -1
- package/dist/docusaurus/view-model/namespaces-vm.js +202 -4
- package/dist/docusaurus/view-model/namespaces-vm.js.map +1 -1
- package/dist/docusaurus/view-model/options.d.ts +43 -0
- package/dist/docusaurus/view-model/options.d.ts.map +1 -1
- package/dist/docusaurus/view-model/options.js +43 -0
- package/dist/docusaurus/view-model/options.js.map +1 -1
- package/dist/docusaurus/view-model/pages-vm.d.ts +117 -2
- package/dist/docusaurus/view-model/pages-vm.d.ts.map +1 -1
- package/dist/docusaurus/view-model/pages-vm.js +119 -4
- package/dist/docusaurus/view-model/pages-vm.js.map +1 -1
- package/dist/docusaurus/view-model/tree-entries-vm.d.ts +135 -15
- package/dist/docusaurus/view-model/tree-entries-vm.d.ts.map +1 -1
- package/dist/docusaurus/view-model/tree-entries-vm.js +136 -16
- package/dist/docusaurus/view-model/tree-entries-vm.js.map +1 -1
- package/dist/docusaurus/view-model/view-model.d.ts +119 -0
- package/dist/docusaurus/view-model/view-model.d.ts.map +1 -1
- package/dist/docusaurus/view-model/view-model.js +119 -0
- package/dist/docusaurus/view-model/view-model.js.map +1 -1
- package/dist/docusaurus/workspace.d.ts +106 -0
- package/dist/docusaurus/workspace.d.ts.map +1 -1
- package/dist/docusaurus/workspace.js +107 -1
- package/dist/docusaurus/workspace.js.map +1 -1
- package/dist/doxygen/data-model/compounds/compounddef-dm.d.ts +485 -0
- package/dist/doxygen/data-model/compounds/compounddef-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/compounddef-dm.js +485 -0
- package/dist/doxygen/data-model/compounds/compounddef-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/compoundreftype-dm.d.ts +120 -0
- package/dist/doxygen/data-model/compounds/compoundreftype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/compoundreftype-dm.js +98 -0
- package/dist/doxygen/data-model/compounds/compoundreftype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/descriptiontype-dm.d.ts +2705 -0
- package/dist/doxygen/data-model/compounds/descriptiontype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/descriptiontype-dm.js +2677 -47
- package/dist/doxygen/data-model/compounds/descriptiontype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/docvarlistentrytype-dm.d.ts +165 -0
- package/dist/doxygen/data-model/compounds/docvarlistentrytype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/docvarlistentrytype-dm.js +165 -0
- package/dist/doxygen/data-model/compounds/docvarlistentrytype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/doxygentype-dm.d.ts +70 -0
- package/dist/doxygen/data-model/compounds/doxygentype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/doxygentype-dm.js +70 -0
- package/dist/doxygen/data-model/compounds/doxygentype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/enumvaluetype-dm.d.ts +78 -0
- package/dist/doxygen/data-model/compounds/enumvaluetype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/enumvaluetype-dm.js +78 -0
- package/dist/doxygen/data-model/compounds/enumvaluetype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/inctype-dm.d.ts +107 -0
- package/dist/doxygen/data-model/compounds/inctype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/inctype-dm.js +107 -0
- package/dist/doxygen/data-model/compounds/inctype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/linkedtexttype-dm.d.ts +123 -0
- package/dist/doxygen/data-model/compounds/linkedtexttype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/linkedtexttype-dm.js +123 -0
- package/dist/doxygen/data-model/compounds/linkedtexttype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/listofallmemberstype-dm.d.ts +70 -0
- package/dist/doxygen/data-model/compounds/listofallmemberstype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/listofallmemberstype-dm.js +70 -1
- package/dist/doxygen/data-model/compounds/listofallmemberstype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/locationtype-dm.d.ts +156 -0
- package/dist/doxygen/data-model/compounds/locationtype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/locationtype-dm.js +156 -5
- package/dist/doxygen/data-model/compounds/locationtype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/memberdeftype-dm.d.ts +433 -0
- package/dist/doxygen/data-model/compounds/memberdeftype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/memberdeftype-dm.js +417 -6
- package/dist/doxygen/data-model/compounds/memberdeftype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/memberreftype-dm.d.ts +135 -0
- package/dist/doxygen/data-model/compounds/memberreftype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/memberreftype-dm.js +136 -4
- package/dist/doxygen/data-model/compounds/memberreftype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/membertype-dm.d.ts +95 -0
- package/dist/doxygen/data-model/compounds/membertype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/membertype-dm.js +76 -4
- package/dist/doxygen/data-model/compounds/membertype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/paramtype-dm.d.ts +158 -0
- package/dist/doxygen/data-model/compounds/paramtype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/paramtype-dm.js +158 -1
- package/dist/doxygen/data-model/compounds/paramtype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/referencetype-dm.d.ts +130 -0
- package/dist/doxygen/data-model/compounds/referencetype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/referencetype-dm.js +130 -2
- package/dist/doxygen/data-model/compounds/referencetype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/reftexttype-dm.d.ts +120 -0
- package/dist/doxygen/data-model/compounds/reftexttype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/reftexttype-dm.js +106 -3
- package/dist/doxygen/data-model/compounds/reftexttype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/reftype-dm.d.ts +247 -0
- package/dist/doxygen/data-model/compounds/reftype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/reftype-dm.js +247 -3
- package/dist/doxygen/data-model/compounds/reftype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/reimplementtype-dm.d.ts +99 -0
- package/dist/doxygen/data-model/compounds/reimplementtype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/reimplementtype-dm.js +99 -2
- package/dist/doxygen/data-model/compounds/reimplementtype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/sectiondeftype-dm.d.ts +159 -0
- package/dist/doxygen/data-model/compounds/sectiondeftype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/sectiondeftype-dm.js +159 -3
- package/dist/doxygen/data-model/compounds/sectiondeftype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/tableofcontentstype-dm.d.ts +255 -0
- package/dist/doxygen/data-model/compounds/tableofcontentstype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/tableofcontentstype-dm.js +255 -6
- package/dist/doxygen/data-model/compounds/tableofcontentstype-dm.js.map +1 -1
- package/dist/doxygen/data-model/compounds/templateparamlisttype-dm.d.ts +60 -0
- package/dist/doxygen/data-model/compounds/templateparamlisttype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/compounds/templateparamlisttype-dm.js +60 -1
- package/dist/doxygen/data-model/compounds/templateparamlisttype-dm.js.map +1 -1
- package/dist/doxygen/data-model/data-model.d.ts +86 -2
- package/dist/doxygen/data-model/data-model.d.ts.map +1 -1
- package/dist/doxygen/data-model/data-model.js +86 -4
- package/dist/doxygen/data-model/data-model.js.map +1 -1
- package/dist/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.d.ts +109 -0
- package/dist/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.js +84 -2
- package/dist/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.js.map +1 -1
- package/dist/doxygen/data-model/doxyfile/doxyfiletype-dm.d.ts +81 -0
- package/dist/doxygen/data-model/doxyfile/doxyfiletype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/doxyfile/doxyfiletype-dm.js +81 -3
- package/dist/doxygen/data-model/doxyfile/doxyfiletype-dm.js.map +1 -1
- package/dist/doxygen/data-model/doxygen-xml-parser.d.ts +24 -7
- package/dist/doxygen/data-model/doxygen-xml-parser.d.ts.map +1 -1
- package/dist/doxygen/data-model/doxygen-xml-parser.js +24 -22
- package/dist/doxygen/data-model/doxygen-xml-parser.js.map +1 -1
- package/dist/doxygen/data-model/index/indexcompoundtype-dm.d.ts +92 -0
- package/dist/doxygen/data-model/index/indexcompoundtype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/index/indexcompoundtype-dm.js +79 -2
- package/dist/doxygen/data-model/index/indexcompoundtype-dm.js.map +1 -1
- package/dist/doxygen/data-model/index/indexdoxygentype-dm.d.ts +76 -0
- package/dist/doxygen/data-model/index/indexdoxygentype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/index/indexdoxygentype-dm.js +76 -3
- package/dist/doxygen/data-model/index/indexdoxygentype-dm.js.map +1 -1
- package/dist/doxygen/data-model/index/indexmembertype-dm.d.ts +79 -0
- package/dist/doxygen/data-model/index/indexmembertype-dm.d.ts.map +1 -1
- package/dist/doxygen/data-model/index/indexmembertype-dm.js +66 -2
- package/dist/doxygen/data-model/index/indexmembertype-dm.js.map +1 -1
- package/dist/doxygen/data-model/types.d.ts +96 -1
- package/dist/doxygen/data-model/types.d.ts.map +1 -1
- package/dist/doxygen/data-model/types.js +37 -0
- package/dist/doxygen/data-model/types.js.map +1 -1
- package/dist/doxygen2docusaurus.d.ts +4774 -0
- package/dist/tsdoc-metadata.json +11 -0
- package/package.json +11 -7
- /package/{template → templates}/css/custom.css +0 -0
- /package/{template → templates}/img/README.md +0 -0
- /package/{template → templates}/img/document-svgrepo-com.svg +0 -0
- /package/{template → templates}/img/folder-svgrepo-com.svg +0 -0
|
@@ -12,97 +12,278 @@
|
|
|
12
12
|
import assert from 'node:assert';
|
|
13
13
|
import * as fs from 'node:fs/promises';
|
|
14
14
|
import * as path from 'node:path';
|
|
15
|
-
// import * as util from 'node:util'
|
|
16
|
-
// https://www.npmjs.com/package/commander
|
|
17
|
-
import { Command } from 'commander';
|
|
18
15
|
/**
|
|
19
|
-
*
|
|
16
|
+
* Comprehensive CLI options class for documentation generation configuration.
|
|
17
|
+
*
|
|
18
|
+
* @remarks
|
|
19
|
+
* The CliOptions class contains all configuration parameters that control
|
|
20
|
+
* the behaviour of the doxygen2docusaurus conversion process, including
|
|
21
|
+
* paths, URLs, styling, and feature toggles.
|
|
20
22
|
*
|
|
21
23
|
* @public
|
|
22
24
|
*/
|
|
23
25
|
export class CliOptions {
|
|
24
26
|
/**
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
+
* Path to the Doxygen XML input folder relative to the website folder.
|
|
28
|
+
*
|
|
29
|
+
* @remarks
|
|
30
|
+
* Specifies the location of XML files generated by Doxygen, typically
|
|
31
|
+
* containing the parsed documentation data. Path should not include
|
|
32
|
+
* initial or final slashes.
|
|
33
|
+
*
|
|
34
|
+
* @defaultValue 'doxygen/xml'
|
|
27
35
|
*/
|
|
28
36
|
doxygenXmlInputFolderPath = 'doxygen/xml';
|
|
29
37
|
/**
|
|
30
|
-
*
|
|
31
|
-
*
|
|
38
|
+
* Path to the documentation folder relative to the website folder.
|
|
39
|
+
*
|
|
40
|
+
* @remarks
|
|
41
|
+
* Defines the base folder where generated documentation will be placed
|
|
42
|
+
* within the Docusaurus website structure. Path should not include
|
|
43
|
+
* initial or final slashes.
|
|
44
|
+
*
|
|
45
|
+
* @defaultValue 'docs'
|
|
32
46
|
*/
|
|
33
47
|
docsFolderPath = 'docs';
|
|
34
|
-
/**
|
|
48
|
+
/**
|
|
49
|
+
* Path to the API documentation folder relative to the docs folder.
|
|
50
|
+
*
|
|
51
|
+
* @remarks
|
|
52
|
+
* Specifies the subfolder within the docs folder where API reference
|
|
53
|
+
* documentation will be generated. Path should not include initial
|
|
54
|
+
* or final slashes.
|
|
55
|
+
*
|
|
56
|
+
* @defaultValue 'api'
|
|
57
|
+
*/
|
|
35
58
|
apiFolderPath = 'api';
|
|
36
|
-
/**
|
|
59
|
+
/**
|
|
60
|
+
* Base URL for the entire website.
|
|
61
|
+
*
|
|
62
|
+
* @remarks
|
|
63
|
+
* Defines the root URL path for the website, typically '/' for root
|
|
64
|
+
* deployment or '/project-name/' for GitHub Pages or similar hosting.
|
|
65
|
+
*
|
|
66
|
+
* @defaultValue '/'
|
|
67
|
+
*/
|
|
37
68
|
baseUrl = '/';
|
|
38
|
-
/**
|
|
69
|
+
/**
|
|
70
|
+
* URL path to the documentation section relative to the website root.
|
|
71
|
+
*
|
|
72
|
+
* @remarks
|
|
73
|
+
* Specifies the URL segment that leads to the documentation section,
|
|
74
|
+
* without initial or final slashes. Used for navigation and linking.
|
|
75
|
+
*
|
|
76
|
+
* @defaultValue 'docs'
|
|
77
|
+
*/
|
|
39
78
|
docsBaseUrl = 'docs';
|
|
40
|
-
/**
|
|
79
|
+
/**
|
|
80
|
+
* URL path to the API documentation relative to the docs section.
|
|
81
|
+
*
|
|
82
|
+
* @remarks
|
|
83
|
+
* Defines the URL segment for API documentation within the docs section,
|
|
84
|
+
* without initial or final slashes. Used for generating navigation links.
|
|
85
|
+
*
|
|
86
|
+
* @defaultValue 'api'
|
|
87
|
+
*/
|
|
41
88
|
apiBaseUrl = 'api';
|
|
42
|
-
/**
|
|
43
|
-
|
|
44
|
-
|
|
89
|
+
/**
|
|
90
|
+
* Path for images relative to the `static` folder.
|
|
91
|
+
*
|
|
92
|
+
* @remarks
|
|
93
|
+
* Specifies where Doxygen-generated images will be stored within the
|
|
94
|
+
* Docusaurus static assets folder structure.
|
|
95
|
+
*
|
|
96
|
+
* @defaultValue 'assets/images/doxygen'
|
|
97
|
+
*/
|
|
98
|
+
imagesFolderPath = 'assets/images/doxygen';
|
|
99
|
+
/**
|
|
100
|
+
* Output folder for compatibility redirect files.
|
|
101
|
+
*
|
|
102
|
+
* @remarks
|
|
103
|
+
* Optional path relative to the website/static folder where HTML redirect
|
|
104
|
+
* files will be generated to maintain compatibility with original Doxygen
|
|
105
|
+
* URLs. When undefined, no redirect files are created.
|
|
106
|
+
*/
|
|
45
107
|
compatibilityRedirectsOutputFolderPath;
|
|
46
|
-
/**
|
|
108
|
+
/**
|
|
109
|
+
* Title displayed on the main API documentation page.
|
|
110
|
+
*
|
|
111
|
+
* @remarks
|
|
112
|
+
* When specified, this title overrides the default title generated from
|
|
113
|
+
* the project brief. When empty, the title is automatically constructed
|
|
114
|
+
* from the project configuration.
|
|
115
|
+
*
|
|
116
|
+
* @defaultValue ''
|
|
117
|
+
*/
|
|
47
118
|
mainPageTitle = '';
|
|
48
119
|
/**
|
|
49
|
-
*
|
|
50
|
-
*
|
|
120
|
+
* Path to the sidebar category configuration file.
|
|
121
|
+
*
|
|
122
|
+
* @remarks
|
|
123
|
+
* Specifies the location where the generated sidebar category JSON
|
|
124
|
+
* configuration will be written, relative to the current website folder.
|
|
125
|
+
*
|
|
126
|
+
* @defaultValue 'sidebar-category-doxygen.json'
|
|
51
127
|
*/
|
|
52
128
|
sidebarCategoryFilePath = 'sidebar-category-doxygen.json';
|
|
53
|
-
/**
|
|
129
|
+
/**
|
|
130
|
+
* Label displayed in the Docusaurus sidebar for the API documentation.
|
|
131
|
+
*
|
|
132
|
+
* @remarks
|
|
133
|
+
* Short descriptive text that appears in the sidebar navigation to
|
|
134
|
+
* identify the API reference section.
|
|
135
|
+
*
|
|
136
|
+
* @defaultValue 'API Reference (Doxygen)'
|
|
137
|
+
*/
|
|
54
138
|
sidebarCategoryLabel = 'API Reference (Doxygen)';
|
|
55
139
|
/**
|
|
56
|
-
*
|
|
57
|
-
*
|
|
140
|
+
* Path to the navbar configuration file.
|
|
141
|
+
*
|
|
142
|
+
* @remarks
|
|
143
|
+
* Specifies the location where the generated navbar dropdown JSON
|
|
144
|
+
* configuration will be written, relative to the current website folder.
|
|
145
|
+
*
|
|
146
|
+
* @defaultValue 'docusaurus-config-navbar-doxygen.json'
|
|
147
|
+
*/
|
|
148
|
+
navbarFilePath = 'docusaurus-config-navbar-doxygen.json';
|
|
149
|
+
/**
|
|
150
|
+
* Label displayed in the top navigation bar.
|
|
151
|
+
*
|
|
152
|
+
* @remarks
|
|
153
|
+
* Short text that appears in the Docusaurus top navigation bar to
|
|
154
|
+
* provide access to the API documentation section.
|
|
155
|
+
*
|
|
156
|
+
* @defaultValue 'Reference'
|
|
157
|
+
*/
|
|
158
|
+
navbarLabel = 'Reference';
|
|
159
|
+
/**
|
|
160
|
+
* Position of the navigation menu in the top bar.
|
|
161
|
+
*
|
|
162
|
+
* @remarks
|
|
163
|
+
* Determines whether the API documentation menu appears on the left
|
|
164
|
+
* or right side of the Docusaurus navigation bar.
|
|
165
|
+
*
|
|
166
|
+
* @defaultValue 'left'
|
|
58
167
|
*/
|
|
59
|
-
|
|
60
|
-
/** Short text to be displayed in the menu. */
|
|
61
|
-
menuDropdownLabel = 'Reference';
|
|
168
|
+
navbarPosition = 'left';
|
|
62
169
|
/**
|
|
63
|
-
*
|
|
64
|
-
*
|
|
170
|
+
* Path to the custom CSS file for styling overrides.
|
|
171
|
+
*
|
|
172
|
+
* @remarks
|
|
173
|
+
* Specifies the location where custom CSS styles will be written to
|
|
174
|
+
* provide Doxygen-specific styling within the Docusaurus theme.
|
|
175
|
+
* Path is relative to the current website folder.
|
|
176
|
+
*
|
|
177
|
+
* @defaultValue 'src/css/custom-doxygen2docusaurus.css'
|
|
65
178
|
*/
|
|
66
179
|
customCssFilePath = 'src/css/custom-doxygen2docusaurus.css';
|
|
67
|
-
/**
|
|
180
|
+
/**
|
|
181
|
+
* Controls verbose output during the conversion process.
|
|
182
|
+
*
|
|
183
|
+
* @remarks
|
|
184
|
+
* When enabled, provides detailed logging information about the
|
|
185
|
+
* conversion process, including file processing status and statistics.
|
|
186
|
+
*
|
|
187
|
+
* @defaultValue false
|
|
188
|
+
*/
|
|
68
189
|
verbose = false;
|
|
69
|
-
/**
|
|
190
|
+
/**
|
|
191
|
+
* Controls debug-level output during the conversion process.
|
|
192
|
+
*
|
|
193
|
+
* @remarks
|
|
194
|
+
* When enabled, provides extensive debugging information useful for
|
|
195
|
+
* troubleshooting issues. Automatically enables verbose output as well.
|
|
196
|
+
*
|
|
197
|
+
* @defaultValue false
|
|
198
|
+
*/
|
|
70
199
|
debug = false;
|
|
71
|
-
/**
|
|
200
|
+
/**
|
|
201
|
+
* Controls whether TODO suggestion descriptions are displayed.
|
|
202
|
+
*
|
|
203
|
+
* @remarks
|
|
204
|
+
* When enabled, shows suggestions for improvements or missing content
|
|
205
|
+
* that could enhance the generated documentation quality.
|
|
206
|
+
*
|
|
207
|
+
* @defaultValue false
|
|
208
|
+
*/
|
|
72
209
|
suggestToDoDescriptions = false;
|
|
73
|
-
/**
|
|
74
|
-
|
|
75
|
-
|
|
210
|
+
/**
|
|
211
|
+
* Controls whether pages are listed at the top of the sidebar.
|
|
212
|
+
*
|
|
213
|
+
* @remarks
|
|
214
|
+
* When enabled, places page links prominently at the top of the sidebar
|
|
215
|
+
* navigation structure for easier access to important pages.
|
|
216
|
+
*
|
|
217
|
+
* @defaultValue true
|
|
218
|
+
*/
|
|
219
|
+
listPagesAtTop = true;
|
|
220
|
+
/**
|
|
221
|
+
* Controls program listing rendering in File pages.
|
|
222
|
+
*
|
|
223
|
+
* @remarks
|
|
224
|
+
* When enabled, includes syntax-highlighted source code listings
|
|
225
|
+
* within the generated File documentation pages.
|
|
226
|
+
*
|
|
227
|
+
* @defaultValue true
|
|
228
|
+
*/
|
|
76
229
|
renderProgramListing = true;
|
|
77
230
|
/**
|
|
78
|
-
*
|
|
231
|
+
* Controls program listing rendering in member definition sections.
|
|
232
|
+
*
|
|
233
|
+
* @remarks
|
|
234
|
+
* When enabled, includes inline syntax-highlighted code snippets
|
|
235
|
+
* within member documentation sections for better context.
|
|
236
|
+
*
|
|
237
|
+
* @defaultValue true
|
|
79
238
|
*/
|
|
80
239
|
renderProgramListingInline = true;
|
|
81
240
|
/**
|
|
82
|
-
*
|
|
241
|
+
* Note about the location of original Doxygen pages.
|
|
83
242
|
*
|
|
84
|
-
*
|
|
85
|
-
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
88
|
-
*
|
|
243
|
+
* @remarks
|
|
244
|
+
* Provides information about where to find the original Doxygen HTML
|
|
245
|
+
* pages for comparison purposes. When populated, this note is displayed
|
|
246
|
+
* to inform users about the availability of alternative documentation
|
|
247
|
+
* formats.
|
|
89
248
|
*/
|
|
90
249
|
originalPagesNote = '';
|
|
91
|
-
/**
|
|
250
|
+
/**
|
|
251
|
+
* String identifier for distinguishing multiple configuration instances.
|
|
252
|
+
*
|
|
253
|
+
* @remarks
|
|
254
|
+
* Used when multiple configuration instances exist to provide unique
|
|
255
|
+
* identification. Particularly useful in multi-configuration scenarios
|
|
256
|
+
* where different settings need to be applied to different outputs.
|
|
257
|
+
*
|
|
258
|
+
* @defaultValue 'default'
|
|
259
|
+
*/
|
|
92
260
|
id = 'default';
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
261
|
+
/**
|
|
262
|
+
* Creates a new CliOptions instance with the specified command options.
|
|
263
|
+
*
|
|
264
|
+
* @remarks
|
|
265
|
+
* Initialises the configuration object by setting the ID and optional
|
|
266
|
+
* flags like verbose and debug. When the ID is not 'default', adjusts
|
|
267
|
+
* folder paths and file names to include the ID for multi-configuration
|
|
268
|
+
* scenarios.
|
|
269
|
+
*
|
|
270
|
+
* @param commandOptions - Command-line options object containing ID and flags
|
|
271
|
+
*/
|
|
272
|
+
constructor(commandOptions) {
|
|
273
|
+
this.id = commandOptions.id;
|
|
274
|
+
if (commandOptions.verbose !== undefined) {
|
|
275
|
+
this.verbose = true;
|
|
276
|
+
}
|
|
277
|
+
if (commandOptions.debug !== undefined) {
|
|
278
|
+
this.debug = true;
|
|
279
|
+
}
|
|
99
280
|
if (this.id !== 'default') {
|
|
100
281
|
this.apiFolderPath = this.id;
|
|
101
282
|
this.apiBaseUrl = this.id;
|
|
102
283
|
this.imagesFolderPath = `img/doxygen-${this.id}`;
|
|
103
284
|
this.sidebarCategoryFilePath =
|
|
104
285
|
'sidebar-category-doxygen' + `-${this.id}.json`;
|
|
105
|
-
this.
|
|
286
|
+
this.navbarFilePath =
|
|
106
287
|
'docusaurus-config-navbar-doxygen' + `-${this.id}.json`;
|
|
107
288
|
}
|
|
108
289
|
else {
|
|
@@ -110,9 +291,20 @@ export class CliOptions {
|
|
|
110
291
|
this.apiBaseUrl = 'api';
|
|
111
292
|
this.imagesFolderPath = `img/doxygen`;
|
|
112
293
|
this.sidebarCategoryFilePath = `sidebar-category-doxygen.json`;
|
|
113
|
-
this.
|
|
294
|
+
this.navbarFilePath = `docusaurus-config-navbar-doxygen.json`;
|
|
114
295
|
}
|
|
115
296
|
}
|
|
297
|
+
/**
|
|
298
|
+
* Parses configuration options from various JSON configuration sources.
|
|
299
|
+
*
|
|
300
|
+
* @remarks
|
|
301
|
+
* Attempts to load configuration from multiple locations in order of
|
|
302
|
+
* preference: config/doxygen2docusaurus.json, doxygen2docusaurus.json,
|
|
303
|
+
* and package.json. Validates required properties and enables debug
|
|
304
|
+
* output if requested.
|
|
305
|
+
*
|
|
306
|
+
* @throws Assertion error if required configuration properties are missing
|
|
307
|
+
*/
|
|
116
308
|
async parse() {
|
|
117
309
|
let configurationOptions = undefined;
|
|
118
310
|
try {
|
|
@@ -159,10 +351,10 @@ export class CliOptions {
|
|
|
159
351
|
/* Cannot read/parse JSON */
|
|
160
352
|
}
|
|
161
353
|
}
|
|
162
|
-
if (this.debug) {
|
|
163
|
-
console.log(configurationOptions);
|
|
164
|
-
}
|
|
165
354
|
if (configurationOptions !== undefined) {
|
|
355
|
+
if (this.debug) {
|
|
356
|
+
console.log(configurationOptions);
|
|
357
|
+
}
|
|
166
358
|
// Override only properties that exist in CliOptions
|
|
167
359
|
const thisProperties = Object.getOwnPropertyNames(this);
|
|
168
360
|
for (const key of Object.keys(configurationOptions)) {
|
|
@@ -172,7 +364,10 @@ export class CliOptions {
|
|
|
172
364
|
const thisProperty = this[key];
|
|
173
365
|
const thisType = typeof thisProperty;
|
|
174
366
|
const valueType = typeof value;
|
|
175
|
-
|
|
367
|
+
if (['id', 'verbose', 'debug'].includes(key)) {
|
|
368
|
+
continue;
|
|
369
|
+
}
|
|
370
|
+
// Override only if types match.
|
|
176
371
|
if (thisType === valueType) {
|
|
177
372
|
;
|
|
178
373
|
this[key] = value;
|
|
@@ -180,6 +375,9 @@ export class CliOptions {
|
|
|
180
375
|
}
|
|
181
376
|
}
|
|
182
377
|
}
|
|
378
|
+
if (this.debug) {
|
|
379
|
+
this.verbose = true;
|
|
380
|
+
}
|
|
183
381
|
if (this.verbose) {
|
|
184
382
|
console.log();
|
|
185
383
|
console.log(this);
|
|
@@ -191,6 +389,17 @@ export class CliOptions {
|
|
|
191
389
|
// assert(this.apiBaseUrl.length > 0, 'apiBaseUrl is required')
|
|
192
390
|
assert(this.sidebarCategoryFilePath.length > 0, 'sidebarCategoryFilePath is required');
|
|
193
391
|
}
|
|
392
|
+
/**
|
|
393
|
+
* Selects the appropriate configuration from multi-configuration options.
|
|
394
|
+
*
|
|
395
|
+
* @remarks
|
|
396
|
+
* When using a specific ID, returns the corresponding configuration.
|
|
397
|
+
* For the default ID, returns either the 'default' configuration or
|
|
398
|
+
* treats the entire object as a single configuration.
|
|
399
|
+
*
|
|
400
|
+
* @param multiConfigurations - Configuration object or multi-config map
|
|
401
|
+
* @returns Selected configuration options or undefined if not found
|
|
402
|
+
*/
|
|
194
403
|
selectMultiConfiguration(multiConfigurations) {
|
|
195
404
|
let configurationOptions = undefined;
|
|
196
405
|
if (this.id !== 'default') {
|
|
@@ -200,13 +409,18 @@ export class CliOptions {
|
|
|
200
409
|
}
|
|
201
410
|
}
|
|
202
411
|
else {
|
|
203
|
-
|
|
412
|
+
const multiConfig = multiConfigurations;
|
|
413
|
+
configurationOptions =
|
|
414
|
+
'default' in multiConfig
|
|
415
|
+
? multiConfig.default
|
|
416
|
+
: multiConfigurations;
|
|
204
417
|
}
|
|
205
418
|
return configurationOptions;
|
|
206
419
|
}
|
|
207
420
|
}
|
|
208
421
|
// Was used during development. Now stick to true.
|
|
209
422
|
export const renderParagraphs = true;
|
|
423
|
+
// Does not make noticeable differences.
|
|
210
424
|
export const maxParallelPromises = 42;
|
|
211
425
|
// ----------------------------------------------------------------------------
|
|
212
426
|
//# sourceMappingURL=cli-options.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-options.js","sourceRoot":"","sources":["../../src/docusaurus/cli-options.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,+EAA+E;AAE/E,OAAO,MAAM,MAAM,aAAa,CAAA;AAChC,OAAO,KAAK,EAAE,MAAM,kBAAkB,CAAA;AACtC,OAAO,KAAK,IAAI,MAAM,WAAW,CAAA;
|
|
1
|
+
{"version":3,"file":"cli-options.js","sourceRoot":"","sources":["../../src/docusaurus/cli-options.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,+EAA+E;AAE/E,OAAO,MAAM,MAAM,aAAa,CAAA;AAChC,OAAO,KAAK,EAAE,MAAM,kBAAkB,CAAA;AACtC,OAAO,KAAK,IAAI,MAAM,WAAW,CAAA;AA+DjC;;;;;;;;;GASG;AACH,MAAM,OAAO,UAAU;IACrB;;;;;;;;;OASG;IACH,yBAAyB,GAAG,aAAa,CAAA;IAEzC;;;;;;;;;OASG;IACH,cAAc,GAAG,MAAM,CAAA;IAEvB;;;;;;;;;OASG;IACH,aAAa,GAAG,KAAK,CAAA;IAErB;;;;;;;;OAQG;IACH,OAAO,GAAG,GAAG,CAAA;IAEb;;;;;;;;OAQG;IACH,WAAW,GAAG,MAAM,CAAA;IAEpB;;;;;;;;OAQG;IACH,UAAU,GAAG,KAAK,CAAA;IAElB;;;;;;;;OAQG;IACH,gBAAgB,GAAG,uBAAuB,CAAA;IAE1C;;;;;;;OAOG;IACH,sCAAsC,CAAqB;IAE3D;;;;;;;;;OASG;IACH,aAAa,GAAG,EAAE,CAAA;IAElB;;;;;;;;OAQG;IACH,uBAAuB,GAAG,+BAA+B,CAAA;IAEzD;;;;;;;;OAQG;IACH,oBAAoB,GAAG,yBAAyB,C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C,CAAA;IACH,CAAC;IAED;;;;;;;;;;OAUG;IACH,wBAAwB,CACtB,mBAAkE;QAElE,IAAI,oBAAoB,GAAwC,SAAS,CAAA;QACzE,IAAI,IAAI,CAAC,EAAE,KAAK,SAAS,EAAE,CAAC;YAC1B,oBAAoB,GAClB,mBAID,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;YAEV,IAAI,oBAAoB,KAAK,SAAS,EAAE,CAAC;gBACvC,oBAAoB,CAAC,EAAE,GAAG,IAAI,CAAC,EAAE,CAAA;YACnC,CAAC;QACH,CAAC;aAAM,CAAC;YACN,MAAM,WAAW,GAAG,mBAA0C,CAAA;YAC9D,oBAAoB;gBAClB,SAAS,IAAI,WAAW;oBACtB,CAAC,CAAC,WAAW,CAAC,OAAO;oBACrB,CAAC,CAAE,mBAA+C,CAAA;QACxD,CAAC;QACD,OAAO,oBAAoB,CAAA;IAC7B,CAAC;CACF;AAED,kDAAkD;AAClD,MAAM,CAAC,MAAM,gBAAgB,GAAG,IAAI,CAAA;AAEpC,wCAAwC;AACxC,MAAM,CAAC,MAAM,mBAAmB,GAAG,EAAE,CAAA;AAErC,+EAA+E"}
|
|
@@ -1,22 +1,197 @@
|
|
|
1
1
|
import { Workspace } from './workspace.js';
|
|
2
2
|
import { CliOptions } from './cli-options.js';
|
|
3
|
+
import type { SidebarCategory, NavbarItem } from './types.js';
|
|
3
4
|
import type { CompoundBase } from './view-model/compound-base-vm.js';
|
|
5
|
+
/**
|
|
6
|
+
* Generates Docusaurus-compatible Markdown files and configuration from
|
|
7
|
+
* Doxygen XML output.
|
|
8
|
+
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* This class orchestrates the conversion process, creating documentation pages,
|
|
11
|
+
* navigation structures, and associated assets for integration with Docusaurus
|
|
12
|
+
* websites. It handles parallel processing for performance optimisation and
|
|
13
|
+
* manages the complete workflow from XML parsing to final site generation.
|
|
14
|
+
*
|
|
15
|
+
* @public
|
|
16
|
+
*/
|
|
4
17
|
export declare class DocusaurusGenerator {
|
|
18
|
+
/** The workspace containing the data model and configuration options. */
|
|
5
19
|
workspace: Workspace;
|
|
20
|
+
/** CLI options that control the generation process. */
|
|
6
21
|
options: CliOptions;
|
|
22
|
+
/**
|
|
23
|
+
* Constructs a new Docusaurus generator instance.
|
|
24
|
+
*
|
|
25
|
+
* @remarks
|
|
26
|
+
* Initialises the generator with the provided workspace, which contains
|
|
27
|
+
* the parsed Doxygen data model and configuration options required for
|
|
28
|
+
* the generation process.
|
|
29
|
+
*
|
|
30
|
+
* @param workspace - The workspace containing the data model and
|
|
31
|
+
* configuration.
|
|
32
|
+
*/
|
|
7
33
|
constructor(workspace: Workspace);
|
|
34
|
+
/**
|
|
35
|
+
* Executes the complete generation process.
|
|
36
|
+
*
|
|
37
|
+
* @remarks
|
|
38
|
+
* Orchestrates the creation of all Docusaurus assets including Markdown
|
|
39
|
+
* files, navigation structures, redirect files, and static assets. The
|
|
40
|
+
* process follows a specific sequence to ensure proper dependencies and
|
|
41
|
+
* optimal performance through parallel processing where appropriate.
|
|
42
|
+
*
|
|
43
|
+
* @returns A promise that resolves to the exit code (0 for success).
|
|
44
|
+
*/
|
|
8
45
|
run(): Promise<number>;
|
|
46
|
+
/**
|
|
47
|
+
* Prepares the output folder for generated content.
|
|
48
|
+
*
|
|
49
|
+
* @remarks
|
|
50
|
+
* Removes any existing output folder and creates a new empty directory
|
|
51
|
+
* structure for the generated Docusaurus files. This ensures a clean
|
|
52
|
+
* starting state for each generation run and prevents conflicts with
|
|
53
|
+
* previous builds.
|
|
54
|
+
*/
|
|
9
55
|
prepareOutputFolder(): Promise<void>;
|
|
10
|
-
|
|
11
|
-
|
|
56
|
+
/**
|
|
57
|
+
* Generates the sidebar category structure for Docusaurus navigation.
|
|
58
|
+
*
|
|
59
|
+
* @remarks
|
|
60
|
+
* Creates a hierarchical category structure that organises all generated
|
|
61
|
+
* documentation pages into a logical navigation tree. The structure includes
|
|
62
|
+
* top-level pages and follows the configured collection ordering to maintain
|
|
63
|
+
* consistent navigation patterns.
|
|
64
|
+
*
|
|
65
|
+
* @returns The complete sidebar category configuration object.
|
|
66
|
+
*/
|
|
67
|
+
generateSidebarCategory(): SidebarCategory;
|
|
68
|
+
/**
|
|
69
|
+
* Writes the sidebar configuration to a JSON file.
|
|
70
|
+
*
|
|
71
|
+
* @remarks
|
|
72
|
+
* Serialises the sidebar category structure and writes it to the configured
|
|
73
|
+
* output path for integration with Docusaurus. The resulting JSON file
|
|
74
|
+
* provides the complete navigation structure for the documentation site.
|
|
75
|
+
*
|
|
76
|
+
* @param sidebarCategory - The sidebar configuration to write.
|
|
77
|
+
*/
|
|
78
|
+
writeSidebarFile(sidebarCategory: SidebarCategory): Promise<void>;
|
|
79
|
+
/**
|
|
80
|
+
* Generates the navbar dropdown configuration for the top navigation.
|
|
81
|
+
*
|
|
82
|
+
* @remarks
|
|
83
|
+
* Creates a navigation menu structure that provides quick access to
|
|
84
|
+
* different sections of the generated documentation. When no items are
|
|
85
|
+
* available, falls back to a simple link format for consistency.
|
|
86
|
+
*
|
|
87
|
+
* @returns The navbar item configuration for Docusaurus.
|
|
88
|
+
*/
|
|
89
|
+
generateNavbarItem(): NavbarItem;
|
|
90
|
+
/**
|
|
91
|
+
* Writes the navbar configuration to a JSON file.
|
|
92
|
+
*
|
|
93
|
+
* @remarks
|
|
94
|
+
* Serialises the navbar item structure and writes it to the configured
|
|
95
|
+
* output path for integration with Docusaurus navigation. The resulting
|
|
96
|
+
* JSON file provides the top-level navigation menu configuration.
|
|
97
|
+
*
|
|
98
|
+
* @param navbarItem - The navbar configuration to write.
|
|
99
|
+
*/
|
|
100
|
+
writeNavbarFile(navbarItem: NavbarItem): Promise<void>;
|
|
101
|
+
/**
|
|
102
|
+
* Generates index Markdown files for all collections.
|
|
103
|
+
*
|
|
104
|
+
* @remarks
|
|
105
|
+
* Creates overview pages for each documentation collection (classes, files,
|
|
106
|
+
* namespaces, etc.) that provide organised access to the content. These
|
|
107
|
+
* index files serve as entry points for navigating large documentation
|
|
108
|
+
* collections efficiently.
|
|
109
|
+
*/
|
|
12
110
|
generateCollectionsIndexDotMdFiles(): Promise<void>;
|
|
111
|
+
/**
|
|
112
|
+
* Generates the main index Markdown file for the API documentation.
|
|
113
|
+
*
|
|
114
|
+
* @remarks
|
|
115
|
+
* Creates the landing page that serves as the entry point to the generated
|
|
116
|
+
* documentation, including topics overview and main page content. This
|
|
117
|
+
* combines the Doxygen @mainpage content with a structured topics table
|
|
118
|
+
* for comprehensive navigation.
|
|
119
|
+
*/
|
|
13
120
|
generateTopIndexDotMdFile(): Promise<void>;
|
|
14
|
-
|
|
15
|
-
|
|
121
|
+
/**
|
|
122
|
+
* Generates alphabetical index files organised by initial letters.
|
|
123
|
+
*
|
|
124
|
+
* @remarks
|
|
125
|
+
* Creates index pages that group documentation items by their first letter,
|
|
126
|
+
* facilitating alphabetical navigation through large sets of documentation.
|
|
127
|
+
* This approach improves usability when dealing with extensive API
|
|
128
|
+
* documentation containing numerous items.
|
|
129
|
+
*/
|
|
130
|
+
generatePerInitialsIndexDotMdFiles(): Promise<void>;
|
|
131
|
+
/**
|
|
132
|
+
* Generates all individual Markdown files for documentation compounds.
|
|
133
|
+
*
|
|
134
|
+
* @remarks
|
|
135
|
+
* Processes all compounds (classes, files, namespaces, etc.) from the
|
|
136
|
+
* Doxygen XML and converts them into Docusaurus-compatible Markdown pages.
|
|
137
|
+
* Supports parallel processing for improved performance whilst maintaining
|
|
138
|
+
* proper error handling and resource management.
|
|
139
|
+
*/
|
|
140
|
+
generateMdFiles(): Promise<void>;
|
|
141
|
+
/**
|
|
142
|
+
* Generates a single Markdown page for a documentation compound.
|
|
143
|
+
*
|
|
144
|
+
* @remarks
|
|
145
|
+
* Converts an individual compound (class, file, namespace, etc.) into a
|
|
146
|
+
* properly formatted Docusaurus Markdown file with appropriate front matter
|
|
147
|
+
* and content. The method handles permalink generation, metadata creation,
|
|
148
|
+
* and content rendering for optimal integration with Docusaurus.
|
|
149
|
+
*
|
|
150
|
+
* @param compound - The compound to generate a page for.
|
|
151
|
+
*/
|
|
16
152
|
generatePage(compound: CompoundBase): Promise<void>;
|
|
153
|
+
/**
|
|
154
|
+
* Generates HTML redirect files for backwards compatibility.
|
|
155
|
+
*
|
|
156
|
+
* @remarks
|
|
157
|
+
* Creates redirect files that map original Doxygen URLs to the new
|
|
158
|
+
* Docusaurus URLs, maintaining compatibility with existing bookmarks
|
|
159
|
+
* and external links. This ensures a smooth transition when migrating
|
|
160
|
+
* from Doxygen-generated documentation to Docusaurus.
|
|
161
|
+
*/
|
|
17
162
|
generateCompatibilityRedirectFiles(): Promise<void>;
|
|
163
|
+
/**
|
|
164
|
+
* Generates an HTML redirect file for URL redirection.
|
|
165
|
+
*
|
|
166
|
+
* @remarks
|
|
167
|
+
* Creates a client-side redirect page that automatically forwards visitors
|
|
168
|
+
* from old Doxygen URLs to the corresponding Docusaurus pages. The redirect
|
|
169
|
+
* preserves query parameters and hash fragments to maintain deep linking
|
|
170
|
+
* functionality across the migration.
|
|
171
|
+
*
|
|
172
|
+
* @param filePath - The path where the redirect file should be created.
|
|
173
|
+
* @param permalink - The target URL to redirect to.
|
|
174
|
+
*/
|
|
18
175
|
private generateRedirectFile;
|
|
176
|
+
/**
|
|
177
|
+
* Copies required static files to the output directory.
|
|
178
|
+
*
|
|
179
|
+
* @remarks
|
|
180
|
+
* Transfers essential template files including SVG icons and CSS
|
|
181
|
+
* stylesheets to the appropriate locations in the static directory
|
|
182
|
+
* for use by the generated documentation. These assets provide the
|
|
183
|
+
* visual styling and iconography for the documentation site.
|
|
184
|
+
*/
|
|
19
185
|
copyFiles(): Promise<void>;
|
|
186
|
+
/**
|
|
187
|
+
* Copies image files referenced in the documentation.
|
|
188
|
+
*
|
|
189
|
+
* @remarks
|
|
190
|
+
* Transfers all image files that are referenced within the Doxygen
|
|
191
|
+
* documentation to the appropriate static directory, ensuring they
|
|
192
|
+
* remain accessible in the generated Docusaurus site. Duplicate
|
|
193
|
+
* image names are automatically deduplicated for efficiency.
|
|
194
|
+
*/
|
|
20
195
|
copyImageFiles(): Promise<void>;
|
|
21
196
|
}
|
|
22
197
|
//# sourceMappingURL=generator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generator.d.ts","sourceRoot":"","sources":["../../src/docusaurus/generator.ts"],"names":[],"mappings":"AAkBA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,EAAE,UAAU,EAAuB,MAAM,kBAAkB,CAAA;
|
|
1
|
+
{"version":3,"file":"generator.d.ts","sourceRoot":"","sources":["../../src/docusaurus/generator.ts"],"names":[],"mappings":"AAkBA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,EAAE,UAAU,EAAuB,MAAM,kBAAkB,CAAA;AAClE,OAAO,KAAK,EAAE,eAAe,EAAe,UAAU,EAAE,MAAM,YAAY,CAAA;AAK1E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AAKpE;;;;;;;;;;;GAWG;AACH,qBAAa,mBAAmB;IAC9B,yEAAyE;IACzE,SAAS,EAAE,SAAS,CAAA;IAEpB,uDAAuD;IACvD,OAAO,EAAE,UAAU,CAAA;IAInB;;;;;;;;;;OAUG;gBACS,SAAS,EAAE,SAAS;IAQhC;;;;;;;;;;OAUG;IACG,GAAG,IAAI,OAAO,CAAC,MAAM,CAAC;IA+C5B;;;;;;;;OAQG;IAEG,mBAAmB,IAAI,OAAO,CAAC,IAAI,CAAC;IAiB1C;;;;;;;;;;OAUG;IACH,uBAAuB,IAAI,eAAe;IA8B1C;;;;;;;;;OASG;IACG,gBAAgB,CAAC,eAAe,EAAE,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC;IAYvE;;;;;;;;;OASG;IACH,kBAAkB,IAAI,UAAU;IAoChC;;;;;;;;;OASG;IACG,eAAe,CAAC,UAAU,EAAE,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC;IAa5D;;;;;;;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