@xpack/doxygen2docusaurus 2.0.0 → 2.2.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.
Files changed (365) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +3 -1
  3. package/bin/doxygen2docusaurus.js +5 -5
  4. package/dist/cli/main.d.ts +0 -14
  5. package/dist/cli/main.d.ts.map +1 -1
  6. package/dist/cli/main.js +0 -34
  7. package/dist/cli/main.js.map +1 -1
  8. package/dist/docusaurus/cli-options.d.ts +3 -292
  9. package/dist/docusaurus/cli-options.d.ts.map +1 -1
  10. package/dist/docusaurus/cli-options.js +6 -290
  11. package/dist/docusaurus/cli-options.js.map +1 -1
  12. package/dist/docusaurus/generator.d.ts +0 -172
  13. package/dist/docusaurus/generator.d.ts.map +1 -1
  14. package/dist/docusaurus/generator.js +20 -280
  15. package/dist/docusaurus/generator.js.map +1 -1
  16. package/dist/docusaurus/renderers/conceptparts.d.ts +9 -0
  17. package/dist/docusaurus/renderers/conceptparts.d.ts.map +1 -0
  18. package/dist/docusaurus/renderers/conceptparts.js +21 -0
  19. package/dist/docusaurus/renderers/conceptparts.js.map +1 -0
  20. package/dist/docusaurus/renderers/descriptiontype.d.ts +0 -417
  21. package/dist/docusaurus/renderers/descriptiontype.d.ts.map +1 -1
  22. package/dist/docusaurus/renderers/descriptiontype.js +11 -555
  23. package/dist/docusaurus/renderers/descriptiontype.js.map +1 -1
  24. package/dist/docusaurus/renderers/docinternalstype.d.ts +0 -132
  25. package/dist/docusaurus/renderers/docinternalstype.d.ts.map +1 -1
  26. package/dist/docusaurus/renderers/docinternalstype.js +0 -156
  27. package/dist/docusaurus/renderers/docinternalstype.js.map +1 -1
  28. package/dist/docusaurus/renderers/doclisttype.d.ts +0 -22
  29. package/dist/docusaurus/renderers/doclisttype.d.ts.map +1 -1
  30. package/dist/docusaurus/renderers/doclisttype.js +0 -42
  31. package/dist/docusaurus/renderers/doclisttype.js.map +1 -1
  32. package/dist/docusaurus/renderers/doctabletype.d.ts +0 -88
  33. package/dist/docusaurus/renderers/doctabletype.d.ts.map +1 -1
  34. package/dist/docusaurus/renderers/doctabletype.js +1 -113
  35. package/dist/docusaurus/renderers/doctabletype.js.map +1 -1
  36. package/dist/docusaurus/renderers/doctitletype.d.ts +0 -22
  37. package/dist/docusaurus/renderers/doctitletype.d.ts.map +1 -1
  38. package/dist/docusaurus/renderers/doctitletype.js +0 -42
  39. package/dist/docusaurus/renderers/doctitletype.js.map +1 -1
  40. package/dist/docusaurus/renderers/docvariablelisttype.d.ts +0 -44
  41. package/dist/docusaurus/renderers/docvariablelisttype.d.ts.map +1 -1
  42. package/dist/docusaurus/renderers/docvariablelisttype.js +1 -69
  43. package/dist/docusaurus/renderers/docvariablelisttype.js.map +1 -1
  44. package/dist/docusaurus/renderers/docxrefsecttype.d.ts +0 -22
  45. package/dist/docusaurus/renderers/docxrefsecttype.d.ts.map +1 -1
  46. package/dist/docusaurus/renderers/docxrefsecttype.js +0 -38
  47. package/dist/docusaurus/renderers/docxrefsecttype.js.map +1 -1
  48. package/dist/docusaurus/renderers/element-renderer-base.d.ts +0 -74
  49. package/dist/docusaurus/renderers/element-renderer-base.d.ts.map +1 -1
  50. package/dist/docusaurus/renderers/element-renderer-base.js +0 -64
  51. package/dist/docusaurus/renderers/element-renderer-base.js.map +1 -1
  52. package/dist/docusaurus/renderers/inctype.d.ts +0 -23
  53. package/dist/docusaurus/renderers/inctype.d.ts.map +1 -1
  54. package/dist/docusaurus/renderers/inctype.js +0 -41
  55. package/dist/docusaurus/renderers/inctype.js.map +1 -1
  56. package/dist/docusaurus/renderers/linkedtexttype.d.ts +0 -22
  57. package/dist/docusaurus/renderers/linkedtexttype.d.ts.map +1 -1
  58. package/dist/docusaurus/renderers/linkedtexttype.js +0 -45
  59. package/dist/docusaurus/renderers/linkedtexttype.js.map +1 -1
  60. package/dist/docusaurus/renderers/listingtype.d.ts +0 -52
  61. package/dist/docusaurus/renderers/listingtype.d.ts.map +1 -1
  62. package/dist/docusaurus/renderers/listingtype.js +1 -88
  63. package/dist/docusaurus/renderers/listingtype.js.map +1 -1
  64. package/dist/docusaurus/renderers/paramtype.d.ts +0 -22
  65. package/dist/docusaurus/renderers/paramtype.d.ts.map +1 -1
  66. package/dist/docusaurus/renderers/paramtype.js +2 -51
  67. package/dist/docusaurus/renderers/paramtype.js.map +1 -1
  68. package/dist/docusaurus/renderers/referencetype.d.ts +0 -23
  69. package/dist/docusaurus/renderers/referencetype.d.ts.map +1 -1
  70. package/dist/docusaurus/renderers/referencetype.js +0 -38
  71. package/dist/docusaurus/renderers/referencetype.js.map +1 -1
  72. package/dist/docusaurus/renderers/reftexttype.d.ts +0 -22
  73. package/dist/docusaurus/renderers/reftexttype.d.ts.map +1 -1
  74. package/dist/docusaurus/renderers/reftexttype.js +0 -38
  75. package/dist/docusaurus/renderers/reftexttype.js.map +1 -1
  76. package/dist/docusaurus/renderers/reftype.d.ts +0 -22
  77. package/dist/docusaurus/renderers/reftype.d.ts.map +1 -1
  78. package/dist/docusaurus/renderers/reftype.js +0 -38
  79. package/dist/docusaurus/renderers/reftype.js.map +1 -1
  80. package/dist/docusaurus/renderers/renderers.d.ts +0 -151
  81. package/dist/docusaurus/renderers/renderers.d.ts.map +1 -1
  82. package/dist/docusaurus/renderers/renderers.js +15 -186
  83. package/dist/docusaurus/renderers/renderers.js.map +1 -1
  84. package/dist/docusaurus/renderers/substringtype.d.ts +0 -22
  85. package/dist/docusaurus/renderers/substringtype.d.ts.map +1 -1
  86. package/dist/docusaurus/renderers/substringtype.js +0 -39
  87. package/dist/docusaurus/renderers/substringtype.js.map +1 -1
  88. package/dist/docusaurus/renderers/tableofcontentstype.d.ts +0 -22
  89. package/dist/docusaurus/renderers/tableofcontentstype.d.ts.map +1 -1
  90. package/dist/docusaurus/renderers/tableofcontentstype.js +0 -39
  91. package/dist/docusaurus/renderers/tableofcontentstype.js.map +1 -1
  92. package/dist/docusaurus/types.d.ts +0 -110
  93. package/dist/docusaurus/types.d.ts.map +1 -1
  94. package/dist/docusaurus/types.js +0 -11
  95. package/dist/docusaurus/types.js.map +1 -1
  96. package/dist/docusaurus/utils.d.ts +0 -214
  97. package/dist/docusaurus/utils.d.ts.map +1 -1
  98. package/dist/docusaurus/utils.js +0 -296
  99. package/dist/docusaurus/utils.js.map +1 -1
  100. package/dist/docusaurus/view-model/classes-vm.d.ts +0 -137
  101. package/dist/docusaurus/view-model/classes-vm.d.ts.map +1 -1
  102. package/dist/docusaurus/view-model/classes-vm.js +9 -225
  103. package/dist/docusaurus/view-model/classes-vm.js.map +1 -1
  104. package/dist/docusaurus/view-model/collection-base.d.ts +0 -120
  105. package/dist/docusaurus/view-model/collection-base.d.ts.map +1 -1
  106. package/dist/docusaurus/view-model/collection-base.js +11 -101
  107. package/dist/docusaurus/view-model/collection-base.js.map +1 -1
  108. package/dist/docusaurus/view-model/compound-base-vm.d.ts +2 -147
  109. package/dist/docusaurus/view-model/compound-base-vm.d.ts.map +1 -1
  110. package/dist/docusaurus/view-model/compound-base-vm.js +47 -225
  111. package/dist/docusaurus/view-model/compound-base-vm.js.map +1 -1
  112. package/dist/docusaurus/view-model/concepts-vm.d.ts +27 -0
  113. package/dist/docusaurus/view-model/concepts-vm.d.ts.map +1 -0
  114. package/dist/docusaurus/view-model/concepts-vm.js +337 -0
  115. package/dist/docusaurus/view-model/concepts-vm.js.map +1 -0
  116. package/dist/docusaurus/view-model/description-anchors.d.ts +0 -58
  117. package/dist/docusaurus/view-model/description-anchors.d.ts.map +1 -1
  118. package/dist/docusaurus/view-model/description-anchors.js +0 -71
  119. package/dist/docusaurus/view-model/description-anchors.js.map +1 -1
  120. package/dist/docusaurus/view-model/files-and-folders-vm.d.ts +0 -247
  121. package/dist/docusaurus/view-model/files-and-folders-vm.d.ts.map +1 -1
  122. package/dist/docusaurus/view-model/files-and-folders-vm.js +61 -353
  123. package/dist/docusaurus/view-model/files-and-folders-vm.js.map +1 -1
  124. package/dist/docusaurus/view-model/groups-vm.d.ts +0 -148
  125. package/dist/docusaurus/view-model/groups-vm.d.ts.map +1 -1
  126. package/dist/docusaurus/view-model/groups-vm.js +2 -223
  127. package/dist/docusaurus/view-model/groups-vm.js.map +1 -1
  128. package/dist/docusaurus/view-model/members-vm.d.ts +0 -552
  129. package/dist/docusaurus/view-model/members-vm.d.ts.map +1 -1
  130. package/dist/docusaurus/view-model/members-vm.js +17 -702
  131. package/dist/docusaurus/view-model/members-vm.js.map +1 -1
  132. package/dist/docusaurus/view-model/namespaces-vm.d.ts +5 -199
  133. package/dist/docusaurus/view-model/namespaces-vm.d.ts.map +1 -1
  134. package/dist/docusaurus/view-model/namespaces-vm.js +85 -284
  135. package/dist/docusaurus/view-model/namespaces-vm.js.map +1 -1
  136. package/dist/docusaurus/view-model/options.d.ts +0 -43
  137. package/dist/docusaurus/view-model/options.d.ts.map +1 -1
  138. package/dist/docusaurus/view-model/options.js +0 -57
  139. package/dist/docusaurus/view-model/options.js.map +1 -1
  140. package/dist/docusaurus/view-model/pages-vm.d.ts +0 -115
  141. package/dist/docusaurus/view-model/pages-vm.d.ts.map +1 -1
  142. package/dist/docusaurus/view-model/pages-vm.js +39 -162
  143. package/dist/docusaurus/view-model/pages-vm.js.map +1 -1
  144. package/dist/docusaurus/view-model/tree-entries-vm.d.ts +8 -142
  145. package/dist/docusaurus/view-model/tree-entries-vm.d.ts.map +1 -1
  146. package/dist/docusaurus/view-model/tree-entries-vm.js +54 -174
  147. package/dist/docusaurus/view-model/tree-entries-vm.js.map +1 -1
  148. package/dist/docusaurus/view-model/view-model.d.ts +0 -125
  149. package/dist/docusaurus/view-model/view-model.d.ts.map +1 -1
  150. package/dist/docusaurus/view-model/view-model.js +20 -182
  151. package/dist/docusaurus/view-model/view-model.js.map +1 -1
  152. package/dist/docusaurus/workspace.d.ts +1 -126
  153. package/dist/docusaurus/workspace.d.ts.map +1 -1
  154. package/dist/docusaurus/workspace.js +8 -221
  155. package/dist/docusaurus/workspace.js.map +1 -1
  156. package/dist/doxygen/data-model/compounds/compounddef-dm.d.ts +7 -492
  157. package/dist/doxygen/data-model/compounds/compounddef-dm.d.ts.map +1 -1
  158. package/dist/doxygen/data-model/compounds/compounddef-dm.js +28 -672
  159. package/dist/doxygen/data-model/compounds/compounddef-dm.js.map +1 -1
  160. package/dist/doxygen/data-model/compounds/compoundreftype-dm.d.ts +0 -129
  161. package/dist/doxygen/data-model/compounds/compoundreftype-dm.d.ts.map +1 -1
  162. package/dist/doxygen/data-model/compounds/compoundreftype-dm.js +1 -145
  163. package/dist/doxygen/data-model/compounds/compoundreftype-dm.js.map +1 -1
  164. package/dist/doxygen/data-model/compounds/concepts-dm.d.ts +23 -0
  165. package/dist/doxygen/data-model/compounds/concepts-dm.d.ts.map +1 -0
  166. package/dist/doxygen/data-model/compounds/concepts-dm.js +94 -0
  167. package/dist/doxygen/data-model/compounds/concepts-dm.js.map +1 -0
  168. package/dist/doxygen/data-model/compounds/descriptiontype-dm.d.ts +104 -2848
  169. package/dist/doxygen/data-model/compounds/descriptiontype-dm.d.ts.map +1 -1
  170. package/dist/doxygen/data-model/compounds/descriptiontype-dm.js +73 -3975
  171. package/dist/doxygen/data-model/compounds/descriptiontype-dm.js.map +1 -1
  172. package/dist/doxygen/data-model/compounds/docvarlistentrytype-dm.d.ts +0 -165
  173. package/dist/doxygen/data-model/compounds/docvarlistentrytype-dm.d.ts.map +1 -1
  174. package/dist/doxygen/data-model/compounds/docvarlistentrytype-dm.js +0 -229
  175. package/dist/doxygen/data-model/compounds/docvarlistentrytype-dm.js.map +1 -1
  176. package/dist/doxygen/data-model/compounds/doxygentype-dm.d.ts +0 -70
  177. package/dist/doxygen/data-model/compounds/doxygentype-dm.d.ts.map +1 -1
  178. package/dist/doxygen/data-model/compounds/doxygentype-dm.js +0 -105
  179. package/dist/doxygen/data-model/compounds/doxygentype-dm.js.map +1 -1
  180. package/dist/doxygen/data-model/compounds/enumvaluetype-dm.d.ts +0 -84
  181. package/dist/doxygen/data-model/compounds/enumvaluetype-dm.d.ts.map +1 -1
  182. package/dist/doxygen/data-model/compounds/enumvaluetype-dm.js +1 -122
  183. package/dist/doxygen/data-model/compounds/enumvaluetype-dm.js.map +1 -1
  184. package/dist/doxygen/data-model/compounds/inctype-dm.d.ts +0 -116
  185. package/dist/doxygen/data-model/compounds/inctype-dm.d.ts.map +1 -1
  186. package/dist/doxygen/data-model/compounds/inctype-dm.js +3 -155
  187. package/dist/doxygen/data-model/compounds/inctype-dm.js.map +1 -1
  188. package/dist/doxygen/data-model/compounds/linkedtexttype-dm.d.ts +3 -138
  189. package/dist/doxygen/data-model/compounds/linkedtexttype-dm.d.ts.map +1 -1
  190. package/dist/doxygen/data-model/compounds/linkedtexttype-dm.js +5 -180
  191. package/dist/doxygen/data-model/compounds/linkedtexttype-dm.js.map +1 -1
  192. package/dist/doxygen/data-model/compounds/listofallmemberstype-dm.d.ts +0 -76
  193. package/dist/doxygen/data-model/compounds/listofallmemberstype-dm.d.ts.map +1 -1
  194. package/dist/doxygen/data-model/compounds/listofallmemberstype-dm.js +0 -107
  195. package/dist/doxygen/data-model/compounds/listofallmemberstype-dm.js.map +1 -1
  196. package/dist/doxygen/data-model/compounds/locationtype-dm.d.ts +0 -162
  197. package/dist/doxygen/data-model/compounds/locationtype-dm.d.ts.map +1 -1
  198. package/dist/doxygen/data-model/compounds/locationtype-dm.js +4 -203
  199. package/dist/doxygen/data-model/compounds/locationtype-dm.js.map +1 -1
  200. package/dist/doxygen/data-model/compounds/memberdeftype-dm.d.ts +2 -443
  201. package/dist/doxygen/data-model/compounds/memberdeftype-dm.d.ts.map +1 -1
  202. package/dist/doxygen/data-model/compounds/memberdeftype-dm.js +19 -475
  203. package/dist/doxygen/data-model/compounds/memberdeftype-dm.js.map +1 -1
  204. package/dist/doxygen/data-model/compounds/memberreftype-dm.d.ts +0 -141
  205. package/dist/doxygen/data-model/compounds/memberreftype-dm.d.ts.map +1 -1
  206. package/dist/doxygen/data-model/compounds/memberreftype-dm.js +0 -176
  207. package/dist/doxygen/data-model/compounds/memberreftype-dm.js.map +1 -1
  208. package/dist/doxygen/data-model/compounds/membertype-dm.d.ts +0 -101
  209. package/dist/doxygen/data-model/compounds/membertype-dm.d.ts.map +1 -1
  210. package/dist/doxygen/data-model/compounds/membertype-dm.js +0 -115
  211. package/dist/doxygen/data-model/compounds/membertype-dm.js.map +1 -1
  212. package/dist/doxygen/data-model/compounds/paramtype-dm.d.ts +0 -164
  213. package/dist/doxygen/data-model/compounds/paramtype-dm.d.ts.map +1 -1
  214. package/dist/doxygen/data-model/compounds/paramtype-dm.js +0 -208
  215. package/dist/doxygen/data-model/compounds/paramtype-dm.js.map +1 -1
  216. package/dist/doxygen/data-model/compounds/referencetype-dm.d.ts +0 -139
  217. package/dist/doxygen/data-model/compounds/referencetype-dm.d.ts.map +1 -1
  218. package/dist/doxygen/data-model/compounds/referencetype-dm.js +2 -175
  219. package/dist/doxygen/data-model/compounds/referencetype-dm.js.map +1 -1
  220. package/dist/doxygen/data-model/compounds/reftexttype-dm.d.ts +0 -120
  221. package/dist/doxygen/data-model/compounds/reftexttype-dm.d.ts.map +1 -1
  222. package/dist/doxygen/data-model/compounds/reftexttype-dm.js +2 -141
  223. package/dist/doxygen/data-model/compounds/reftexttype-dm.js.map +1 -1
  224. package/dist/doxygen/data-model/compounds/reftype-dm.d.ts +0 -268
  225. package/dist/doxygen/data-model/compounds/reftype-dm.d.ts.map +1 -1
  226. package/dist/doxygen/data-model/compounds/reftype-dm.js +4 -326
  227. package/dist/doxygen/data-model/compounds/reftype-dm.js.map +1 -1
  228. package/dist/doxygen/data-model/compounds/reimplementtype-dm.d.ts +0 -105
  229. package/dist/doxygen/data-model/compounds/reimplementtype-dm.d.ts.map +1 -1
  230. package/dist/doxygen/data-model/compounds/reimplementtype-dm.js +1 -139
  231. package/dist/doxygen/data-model/compounds/reimplementtype-dm.js.map +1 -1
  232. package/dist/doxygen/data-model/compounds/requirements-dm.d.ts +2 -0
  233. package/dist/doxygen/data-model/compounds/requirements-dm.d.ts.map +1 -0
  234. package/dist/doxygen/data-model/compounds/requirements-dm.js +2 -0
  235. package/dist/doxygen/data-model/compounds/requirements-dm.js.map +1 -0
  236. package/dist/doxygen/data-model/compounds/sectiondeftype-dm.d.ts +0 -168
  237. package/dist/doxygen/data-model/compounds/sectiondeftype-dm.d.ts.map +1 -1
  238. package/dist/doxygen/data-model/compounds/sectiondeftype-dm.js +0 -209
  239. package/dist/doxygen/data-model/compounds/sectiondeftype-dm.js.map +1 -1
  240. package/dist/doxygen/data-model/compounds/tableofcontentstype-dm.d.ts +0 -267
  241. package/dist/doxygen/data-model/compounds/tableofcontentstype-dm.d.ts.map +1 -1
  242. package/dist/doxygen/data-model/compounds/tableofcontentstype-dm.js +0 -354
  243. package/dist/doxygen/data-model/compounds/tableofcontentstype-dm.js.map +1 -1
  244. package/dist/doxygen/data-model/compounds/templateparamlisttype-dm.d.ts +0 -66
  245. package/dist/doxygen/data-model/compounds/templateparamlisttype-dm.d.ts.map +1 -1
  246. package/dist/doxygen/data-model/compounds/templateparamlisttype-dm.js +0 -97
  247. package/dist/doxygen/data-model/compounds/templateparamlisttype-dm.js.map +1 -1
  248. package/dist/doxygen/data-model/data-model.d.ts +0 -149
  249. package/dist/doxygen/data-model/data-model.d.ts.map +1 -1
  250. package/dist/doxygen/data-model/data-model.js +8 -200
  251. package/dist/doxygen/data-model/data-model.js.map +1 -1
  252. package/dist/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.d.ts +0 -115
  253. package/dist/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.d.ts.map +1 -1
  254. package/dist/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.js +4 -129
  255. package/dist/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.js.map +1 -1
  256. package/dist/doxygen/data-model/doxyfile/doxyfiletype-dm.d.ts +0 -87
  257. package/dist/doxygen/data-model/doxyfile/doxyfiletype-dm.d.ts.map +1 -1
  258. package/dist/doxygen/data-model/doxyfile/doxyfiletype-dm.js +0 -118
  259. package/dist/doxygen/data-model/doxyfile/doxyfiletype-dm.js.map +1 -1
  260. package/dist/doxygen/data-model/doxygen-xml-parser.d.ts +0 -253
  261. package/dist/doxygen/data-model/doxygen-xml-parser.d.ts.map +1 -1
  262. package/dist/doxygen/data-model/doxygen-xml-parser.js +0 -291
  263. package/dist/doxygen/data-model/doxygen-xml-parser.js.map +1 -1
  264. package/dist/doxygen/data-model/index/indexcompoundtype-dm.d.ts +0 -98
  265. package/dist/doxygen/data-model/index/indexcompoundtype-dm.d.ts.map +1 -1
  266. package/dist/doxygen/data-model/index/indexcompoundtype-dm.js +2 -122
  267. package/dist/doxygen/data-model/index/indexcompoundtype-dm.js.map +1 -1
  268. package/dist/doxygen/data-model/index/indexdoxygentype-dm.d.ts +0 -82
  269. package/dist/doxygen/data-model/index/indexdoxygentype-dm.d.ts.map +1 -1
  270. package/dist/doxygen/data-model/index/indexdoxygentype-dm.js +0 -114
  271. package/dist/doxygen/data-model/index/indexdoxygentype-dm.js.map +1 -1
  272. package/dist/doxygen/data-model/index/indexmembertype-dm.d.ts +0 -85
  273. package/dist/doxygen/data-model/index/indexmembertype-dm.d.ts.map +1 -1
  274. package/dist/doxygen/data-model/index/indexmembertype-dm.js +1 -107
  275. package/dist/doxygen/data-model/index/indexmembertype-dm.js.map +1 -1
  276. package/dist/doxygen/data-model/types.d.ts +0 -104
  277. package/dist/doxygen/data-model/types.d.ts.map +1 -1
  278. package/dist/doxygen/data-model/types.js +0 -52
  279. package/dist/doxygen/data-model/types.js.map +1 -1
  280. package/dist/index.d.ts +5 -16
  281. package/dist/index.d.ts.map +1 -1
  282. package/dist/index.js +5 -42
  283. package/dist/index.js.map +1 -1
  284. package/package.json +49 -52
  285. package/src/cli/main.ts +122 -0
  286. package/src/docusaurus/cli-options.ts +560 -0
  287. package/src/docusaurus/generator.ts +788 -0
  288. package/src/docusaurus/renderers/conceptparts.ts +119 -0
  289. package/src/docusaurus/renderers/descriptiontype.ts +1299 -0
  290. package/src/docusaurus/renderers/docinternalstype.ts +354 -0
  291. package/src/docusaurus/renderers/doclisttype.ts +134 -0
  292. package/src/docusaurus/renderers/doctabletype.ts +220 -0
  293. package/src/docusaurus/renderers/doctitletype.ts +77 -0
  294. package/src/docusaurus/renderers/docvariablelisttype.ts +123 -0
  295. package/src/docusaurus/renderers/docxrefsecttype.ts +84 -0
  296. package/src/docusaurus/renderers/element-renderer-base.ts +112 -0
  297. package/src/docusaurus/renderers/inctype.ts +75 -0
  298. package/src/docusaurus/renderers/linkedtexttype.ts +64 -0
  299. package/src/docusaurus/renderers/listingtype.ts +235 -0
  300. package/src/docusaurus/renderers/paramtype.ts +116 -0
  301. package/src/docusaurus/renderers/referencetype.ts +83 -0
  302. package/src/docusaurus/renderers/reftexttype.ts +81 -0
  303. package/src/docusaurus/renderers/reftype.ts +77 -0
  304. package/src/docusaurus/renderers/renderers.ts +812 -0
  305. package/src/docusaurus/renderers/substringtype.ts +53 -0
  306. package/src/docusaurus/renderers/tableofcontentstype.ts +74 -0
  307. package/src/docusaurus/types.ts +187 -0
  308. package/src/docusaurus/utils.ts +409 -0
  309. package/src/docusaurus/view-model/README.md +12 -0
  310. package/src/docusaurus/view-model/classes-vm.ts +1088 -0
  311. package/src/docusaurus/view-model/collection-base.ts +352 -0
  312. package/src/docusaurus/view-model/compound-base-vm.ts +1340 -0
  313. package/src/docusaurus/view-model/concepts-vm.ts +749 -0
  314. package/src/docusaurus/view-model/description-anchors.ts +107 -0
  315. package/src/docusaurus/view-model/files-and-folders-vm.ts +1293 -0
  316. package/src/docusaurus/view-model/groups-vm.ts +548 -0
  317. package/src/docusaurus/view-model/members-vm.ts +1943 -0
  318. package/src/docusaurus/view-model/namespaces-vm.ts +1037 -0
  319. package/src/docusaurus/view-model/options.ts +95 -0
  320. package/src/docusaurus/view-model/pages-vm.ts +389 -0
  321. package/src/docusaurus/view-model/tree-entries-vm.ts +376 -0
  322. package/src/docusaurus/view-model/view-model.ts +513 -0
  323. package/src/docusaurus/workspace.ts +588 -0
  324. package/src/doxygen/data-model/README.md +13 -0
  325. package/src/doxygen/data-model/compounds/compounddef-dm.ts +1230 -0
  326. package/src/doxygen/data-model/compounds/compoundreftype-dm.ts +266 -0
  327. package/src/doxygen/data-model/compounds/concepts-dm.ts +362 -0
  328. package/src/doxygen/data-model/compounds/descriptiontype-dm.ts +10114 -0
  329. package/src/doxygen/data-model/compounds/docvarlistentrytype-dm.ts +354 -0
  330. package/src/doxygen/data-model/compounds/doxygentype-dm.ts +187 -0
  331. package/src/doxygen/data-model/compounds/enumvaluetype-dm.ts +218 -0
  332. package/src/doxygen/data-model/compounds/inctype-dm.ts +217 -0
  333. package/src/doxygen/data-model/compounds/linkedtexttype-dm.ts +288 -0
  334. package/src/doxygen/data-model/compounds/listofallmemberstype-dm.ts +160 -0
  335. package/src/doxygen/data-model/compounds/locationtype-dm.ts +284 -0
  336. package/src/doxygen/data-model/compounds/memberdeftype-dm.ts +881 -0
  337. package/src/doxygen/data-model/compounds/memberreftype-dm.ts +270 -0
  338. package/src/doxygen/data-model/compounds/membertype-dm.ts +239 -0
  339. package/src/doxygen/data-model/compounds/paramtype-dm.ts +302 -0
  340. package/src/doxygen/data-model/compounds/referencetype-dm.ts +248 -0
  341. package/src/doxygen/data-model/compounds/reftexttype-dm.ts +234 -0
  342. package/src/doxygen/data-model/compounds/reftype-dm.ts +430 -0
  343. package/src/doxygen/data-model/compounds/reimplementtype-dm.ts +201 -0
  344. package/src/doxygen/data-model/compounds/requirements-dm.ts +50 -0
  345. package/src/doxygen/data-model/compounds/sectiondeftype-dm.ts +330 -0
  346. package/src/doxygen/data-model/compounds/tableofcontentstype-dm.ts +564 -0
  347. package/src/doxygen/data-model/compounds/templateparamlisttype-dm.ts +150 -0
  348. package/src/doxygen/data-model/data-model.ts +378 -0
  349. package/src/doxygen/data-model/doxyfile/doxyfileoptiontype-dm.ts +271 -0
  350. package/src/doxygen/data-model/doxyfile/doxyfiletype-dm.ts +200 -0
  351. package/src/doxygen/data-model/doxygen-xml-parser.ts +522 -0
  352. package/src/doxygen/data-model/index/indexcompoundtype-dm.ts +256 -0
  353. package/src/doxygen/data-model/index/indexdoxygentype-dm.ts +196 -0
  354. package/src/doxygen/data-model/index/indexmembertype-dm.ts +230 -0
  355. package/src/doxygen/data-model/types.ts +175 -0
  356. package/src/doxygen/data-model/xsds/README.md +6 -0
  357. package/src/doxygen/data-model/xsds/compound.xsd +1788 -0
  358. package/src/doxygen/data-model/xsds/doxyfile.xsd +365 -0
  359. package/src/doxygen/data-model/xsds/index.xsd +74 -0
  360. package/src/doxygen/data-model/xsds/xml.xsd +23 -0
  361. package/src/index.ts +267 -0
  362. package/src/tsconfig.json +12 -0
  363. package/dist/doxygen2docusaurus.d.ts +0 -4774
  364. package/dist/tsconfig.tsbuildinfo +0 -1
  365. package/dist/tsdoc-metadata.json +0 -11
@@ -0,0 +1,749 @@
1
+ /*
2
+ * This file is part of the xPack project (http://xpack.github.io).
3
+ * Copyright (c) 2025-2026 Liviu Ionescu. All rights reserved.
4
+ *
5
+ * Permission to use, copy, modify, and/or distribute this software for any
6
+ * purpose is hereby granted, under the terms of the MIT license.
7
+ *
8
+ * If a copy of the license was not distributed with this file, it can be
9
+ * obtained from https://opensource.org/licenses/mit.
10
+ */
11
+
12
+ // ----------------------------------------------------------------------------
13
+
14
+ // import * as util from 'node:util'
15
+ import assert from 'node:assert'
16
+
17
+ import { CompoundDefDataModel } from '../../doxygen/data-model/compounds/compounddef-dm.js'
18
+ import {
19
+ FrontMatter,
20
+ NavbarItem,
21
+ SidebarCategory,
22
+ SidebarCategoryItem,
23
+ SidebarItem,
24
+ } from '../types.js'
25
+ import { CollectionBase } from './collection-base.js'
26
+ import { CompoundBase } from './compound-base-vm.js'
27
+ import {
28
+ flattenPath,
29
+ sanitizeAnonymousNamespace,
30
+ sanitizeHierarchicalPath,
31
+ } from '../utils.js'
32
+ import { Namespace, Namespaces } from './namespaces-vm.js'
33
+ import { ConceptEntry, TreeEntryBase } from './tree-entries-vm.js'
34
+
35
+ // ----------------------------------------------------------------------------
36
+
37
+ /**
38
+ * Manages the collection of C++20 concept documentation compounds.
39
+ *
40
+ * @remarks
41
+ * Handles the organisation and generation of concept-based documentation,
42
+ * including namespace hierarchy association, sidebar generation, and
43
+ * comprehensive index file creation. Concepts provide formal constraints
44
+ * on template parameters, and their documentation is arranged within
45
+ * the namespace hierarchy in which they are defined.
46
+ *
47
+ * @public
48
+ */
49
+ export class Concepts extends CollectionBase {
50
+ /**
51
+ * Array of top-level concepts not nested in any namespace.
52
+ *
53
+ * @remarks
54
+ * Contains concepts whose fully qualified name contains no `::` separator,
55
+ * used for organising top-level concept entries in index pages and
56
+ * the sidebar hierarchy.
57
+ */
58
+ topLevelConcepts: Concept[] = []
59
+
60
+ // constructor(workspace: Workspace) {
61
+ // super(workspace)
62
+ // }
63
+
64
+ /**
65
+ * Adds a concept compound to the collection.
66
+ *
67
+ * @remarks
68
+ * Creates a new {@link Concept} instance from the compound definition
69
+ * and registers it in the collection map for later processing.
70
+ *
71
+ * @param compoundDef - The compound definition data for the concept
72
+ * @returns The created {@link Concept} instance
73
+ */
74
+ addChild(compoundDef: CompoundDefDataModel): CompoundBase {
75
+ const concept = new Concept(this, compoundDef)
76
+ this.collectionCompoundsById.set(concept.id, concept)
77
+
78
+ return concept
79
+ }
80
+
81
+ /**
82
+ * Creates hierarchical relationships between concepts and namespaces.
83
+ *
84
+ * @remarks
85
+ * Iterates over all concept compounds and resolves their parent namespace
86
+ * by stripping the last `::` component of the fully qualified name.
87
+ * Concepts without a namespace qualifier are added to
88
+ * {@link topLevelConcepts}. Concepts with a qualifying namespace that
89
+ * cannot be found in the namespace collection are reported to the console.
90
+ */
91
+ createCompoundsHierarchies(): void {
92
+ // throw new Error('Method not implemented.')
93
+ for (const concept of this.collectionCompoundsById.values()) {
94
+ assert(concept instanceof Concept)
95
+
96
+ if (concept.compoundName.includes('::')) {
97
+ const namespaceCompoundName = concept.compoundName.replace(
98
+ /::[a-zA-Z0-9_]+$/,
99
+ ''
100
+ )
101
+ const namespaces =
102
+ this.workspace.viewModel.collections.get('namespaces')
103
+ assert(namespaces !== undefined)
104
+ const namespace = (
105
+ namespaces as Namespaces
106
+ ).findNamespaceByCompoundName(namespaceCompoundName)
107
+ if (namespace !== undefined) {
108
+ concept.parent = namespace
109
+ namespace.concepts.push(concept)
110
+ if (this.workspace.options.debug) {
111
+ console.log(
112
+ 'concept',
113
+ concept.compoundName,
114
+ 'has parent namespace',
115
+ namespace.compoundName
116
+ )
117
+ }
118
+ } else {
119
+ console.log(
120
+ 'concept',
121
+ concept.compoundName,
122
+ 'has no parent namespace'
123
+ )
124
+ }
125
+ } else {
126
+ if (this.workspace.options.debug) {
127
+ this.topLevelConcepts.push(concept)
128
+ console.log('topLevelConceptId:', concept.id, concept.compoundName)
129
+ }
130
+ }
131
+ }
132
+ }
133
+
134
+ /**
135
+ * Adds concept sidebar items to the provided sidebar category.
136
+ *
137
+ * @remarks
138
+ * Creates a 'Concepts' category containing a hierarchical 'Hierarchy'
139
+ * sub-category that mirrors the namespace tree, plus a flat 'All'
140
+ * index entry. Only namespaces and concepts with sidebar metadata
141
+ * are included.
142
+ *
143
+ * @param sidebarCategory - The sidebar category to populate with concept
144
+ * items
145
+ */
146
+ addSidebarItems(sidebarCategory: SidebarCategory): void {
147
+ const indicesSet = this.workspace.indicesMaps.get('concepts')
148
+ if (indicesSet === undefined) {
149
+ return
150
+ }
151
+
152
+ const conceptsCategory: SidebarCategoryItem = {
153
+ type: 'category',
154
+ label: 'Concepts',
155
+ link: {
156
+ type: 'doc',
157
+ id: `${this.workspace.sidebarBaseId}indices/concepts/index`,
158
+ },
159
+ collapsed: true,
160
+ items: [
161
+ {
162
+ type: 'category',
163
+ label: 'Hierarchy',
164
+ link: {
165
+ type: 'doc',
166
+ id: `${this.workspace.sidebarBaseId}indices/concepts/index`,
167
+ },
168
+ collapsed: true,
169
+ items: [],
170
+ },
171
+ ],
172
+ }
173
+
174
+ const namespaces = this.workspace.viewModel.collections.get('namespaces')
175
+ if (namespaces !== undefined) {
176
+ for (const namespace of (namespaces as Namespaces).topLevelNamespaces) {
177
+ const item = this.createNamespaceItemRecursively(namespace)
178
+ if (item !== undefined) {
179
+ ;(conceptsCategory.items[0] as SidebarCategoryItem).items.push(item)
180
+ }
181
+ }
182
+ }
183
+
184
+ for (const concept of this.topLevelConcepts) {
185
+ const item = this.createConceptItem(concept)
186
+ if (item !== undefined) {
187
+ ;(conceptsCategory.items[0] as SidebarCategoryItem).items.push(item)
188
+ }
189
+ }
190
+
191
+ if (indicesSet.has('all')) {
192
+ conceptsCategory.items.push({
193
+ type: 'doc',
194
+ label: 'All',
195
+ id: `${this.workspace.sidebarBaseId}indices/concepts/all`,
196
+ })
197
+ }
198
+
199
+ sidebarCategory.items.push(conceptsCategory)
200
+ }
201
+
202
+ /**
203
+ * Recursively builds a sidebar item tree for a namespace and its concepts.
204
+ *
205
+ * @remarks
206
+ * Returns `undefined` when the namespace lacks sidebar metadata or
207
+ * contains no concepts anywhere in its subtree. Child namespaces are
208
+ * processed recursively before individual concept items are appended.
209
+ *
210
+ * @param namespace - The namespace to create a sidebar item for
211
+ * @returns A sidebar category item, or `undefined` if the namespace
212
+ * should be omitted
213
+ */
214
+ private createNamespaceItemRecursively(
215
+ namespace: Namespace
216
+ ): SidebarItem | undefined {
217
+ if (
218
+ namespace.sidebarLabel === undefined ||
219
+ namespace.sidebarId === undefined
220
+ ) {
221
+ return undefined
222
+ }
223
+
224
+ if (!namespace.hasConceptsRecursively()) {
225
+ return undefined
226
+ }
227
+
228
+ const categoryItem: SidebarCategoryItem = {
229
+ type: 'category',
230
+ label: namespace.sidebarLabel,
231
+ link: {
232
+ type: 'doc',
233
+ id: `${this.workspace.sidebarBaseId}${namespace.sidebarId}`,
234
+ },
235
+ className: 'doxyEllipsis',
236
+ collapsed: true,
237
+ items: [],
238
+ }
239
+
240
+ for (const childNamespace of namespace.children) {
241
+ if (childNamespace instanceof Namespace) {
242
+ const item = this.createNamespaceItemRecursively(childNamespace)
243
+ if (item !== undefined) {
244
+ categoryItem.items.push(item)
245
+ }
246
+ }
247
+ }
248
+
249
+ for (const concept of namespace.concepts) {
250
+ const item = this.createConceptItem(concept)
251
+ if (item !== undefined) {
252
+ categoryItem.items.push(item)
253
+ }
254
+ }
255
+
256
+ return categoryItem
257
+ }
258
+
259
+ /**
260
+ * Creates a sidebar category item for a single concept.
261
+ *
262
+ * @remarks
263
+ * Returns `undefined` when the concept lacks the sidebar identifier
264
+ * or label required to construct a valid navigation entry.
265
+ *
266
+ * @param concept - The concept to create a sidebar item for
267
+ * @returns A sidebar category item, or `undefined` if the concept
268
+ * should be omitted
269
+ */
270
+ private createConceptItem(concept: Concept): SidebarCategoryItem | undefined {
271
+ if (concept.sidebarId === undefined || concept.sidebarLabel === undefined) {
272
+ return undefined
273
+ }
274
+
275
+ const item: SidebarCategoryItem = {
276
+ type: 'category',
277
+ label: concept.sidebarLabel,
278
+ link: {
279
+ type: 'doc',
280
+ id: `${this.workspace.sidebarBaseId}${concept.sidebarId}`,
281
+ },
282
+ collapsed: true,
283
+ items: [],
284
+ }
285
+
286
+ return item
287
+ }
288
+
289
+ /**
290
+ * Creates navbar items for the concepts section.
291
+ *
292
+ * @remarks
293
+ * Returns a single navbar item linking to the top-level concepts index
294
+ * page.
295
+ *
296
+ * @returns An array containing the concepts navbar item
297
+ */
298
+ createNavbarItems(): NavbarItem[] {
299
+ const navbarItem: NavbarItem = {
300
+ label: 'Concepts',
301
+ to: `${this.workspace.menuBaseUrl}concepts/`,
302
+ }
303
+ return [navbarItem]
304
+ }
305
+
306
+ /**
307
+ * Generates the main concepts index Markdown file.
308
+ *
309
+ * @remarks
310
+ * Writes `indices/concepts/index.md` containing a hierarchical tree table
311
+ * of all namespaces and their concepts. The file is skipped when the
312
+ * collection contains no renderable content.
313
+ */
314
+ override async generateIndexDotMdFile(): Promise<void> {
315
+ const filePath =
316
+ this.workspace.outputFolderPath + 'indices/concepts/index.md'
317
+ const permalink = 'concepts'
318
+
319
+ const frontMatter: FrontMatter = {
320
+ title: 'Concepts',
321
+ slug: `${this.workspace.slugBaseUrl}${permalink}`,
322
+ description: 'The C++20 concepts defined in the project',
323
+ custom_edit_url: null,
324
+ keywords: ['doxygen', 'concepts', 'reference'],
325
+ }
326
+
327
+ const contentLines: string[] = []
328
+
329
+ const namespaces = this.workspace.viewModel.collections.get('namespaces')
330
+ if (namespaces !== undefined) {
331
+ for (const namespace of (namespaces as Namespaces).topLevelNamespaces) {
332
+ contentLines.push(
333
+ ...this.generateNamespacesIndexMdLinesRecursively(namespace, 1)
334
+ )
335
+ }
336
+ }
337
+
338
+ contentLines.push(
339
+ ...this.generateConceptsIndexMdFile(this.topLevelConcepts, 1)
340
+ )
341
+
342
+ if (contentLines.length === 0) {
343
+ return
344
+ }
345
+
346
+ const lines: string[] = []
347
+
348
+ lines.push('The C++20 concepts used by this project are:')
349
+
350
+ lines.push(...this.workspace.renderTreeTableToHtmlLines({ contentLines }))
351
+
352
+ if (this.workspace.options.verbose) {
353
+ console.log(`Writing concepts index file '${filePath}'...`)
354
+ }
355
+
356
+ await this.workspace.writeOutputMdFile({
357
+ filePath,
358
+ frontMatter,
359
+ bodyLines: lines,
360
+ })
361
+
362
+ return
363
+ }
364
+
365
+ /**
366
+ * Recursively generates index Markdown lines for a namespace subtree.
367
+ *
368
+ * @remarks
369
+ * Produces an indented tree-table row for the namespace followed by rows
370
+ * for its direct concepts and then recurses into child namespaces.
371
+ * Returns an empty array when the namespace has no permalink or no
372
+ * concepts anywhere in its subtree.
373
+ *
374
+ * @param namespace - The namespace to render
375
+ * @param depth - The current indentation depth in the tree table
376
+ * @returns An array of HTML lines for the namespace and its concepts
377
+ */
378
+ private generateNamespacesIndexMdLinesRecursively(
379
+ namespace: Namespace,
380
+ depth: number
381
+ ): string[] {
382
+ // console.log(util.inspect(namespace, { compact: false, depth: 999 }))
383
+
384
+ const lines: string[] = []
385
+
386
+ const label = this.workspace.renderString(namespace.treeEntryName, 'html')
387
+
388
+ const permalink = this.workspace.getPagePermalink(namespace.id)
389
+ if (permalink === undefined || permalink.length === 0) {
390
+ // console.log(namespace)
391
+ return []
392
+ }
393
+
394
+ if (!namespace.hasConceptsRecursively()) {
395
+ return []
396
+ }
397
+
398
+ // assert(permalink !== undefined && permalink.length > 1)
399
+
400
+ let description = ''
401
+ if (
402
+ namespace.briefDescriptionHtmlString !== undefined &&
403
+ namespace.briefDescriptionHtmlString.length > 0
404
+ ) {
405
+ description = namespace.briefDescriptionHtmlString.replace(/[.]$/, '')
406
+ }
407
+
408
+ lines.push('')
409
+ lines.push(
410
+ ...this.workspace.renderTreeTableRowToHtmlLines({
411
+ itemIconLetter: 'N',
412
+ itemLabel: label,
413
+ itemLink: permalink,
414
+ depth,
415
+ description,
416
+ })
417
+ )
418
+
419
+ lines.push('')
420
+ lines.push(
421
+ ...this.generateConceptsIndexMdFile(namespace.concepts, depth + 1)
422
+ )
423
+
424
+ if (namespace.children.length > 0) {
425
+ for (const childNamespace of namespace.children) {
426
+ if (childNamespace instanceof Namespace) {
427
+ lines.push(
428
+ ...this.generateNamespacesIndexMdLinesRecursively(
429
+ childNamespace,
430
+ depth + 1
431
+ )
432
+ )
433
+ }
434
+ }
435
+ }
436
+
437
+ return lines
438
+ }
439
+
440
+ /**
441
+ * Generates index Markdown lines for a list of concepts.
442
+ *
443
+ * @remarks
444
+ * Produces one tree-table row per concept that has a valid permalink.
445
+ * Concepts without a permalink (i.e., those with no content and
446
+ * `suggestToDoDescriptions` disabled) are silently skipped.
447
+ *
448
+ * @param concepts - The concepts to render
449
+ * @param depth - The current indentation depth in the tree table
450
+ * @returns An array of HTML lines, one tree-table row per concept
451
+ */
452
+ private generateConceptsIndexMdFile(
453
+ concepts: Concept[],
454
+ depth: number
455
+ ): string[] {
456
+ // console.log(util.inspect(namespace, { compact: false, depth: 999 }))
457
+
458
+ const lines: string[] = []
459
+
460
+ for (const concept of concepts) {
461
+ const label = this.workspace.renderString(concept.treeEntryName, 'html')
462
+
463
+ const permalink = this.workspace.getPagePermalink(concept.id)
464
+ if (permalink === undefined || permalink.length === 0) {
465
+ // console.log(concept)
466
+ continue
467
+ }
468
+
469
+ let description = ''
470
+ if (
471
+ concept.briefDescriptionHtmlString !== undefined &&
472
+ concept.briefDescriptionHtmlString.length > 0
473
+ ) {
474
+ description = concept.briefDescriptionHtmlString.replace(/[.]$/, '')
475
+ }
476
+
477
+ lines.push(
478
+ ...this.workspace.renderTreeTableRowToHtmlLines({
479
+ itemIconLetter: 'R',
480
+ itemLabel: label,
481
+ itemLink: permalink,
482
+ depth,
483
+ description,
484
+ })
485
+ )
486
+ }
487
+
488
+ return lines
489
+ }
490
+
491
+ /**
492
+ * Generates the flat 'all concepts' index Markdown file.
493
+ *
494
+ * @remarks
495
+ * Writes a single alphabetical index file (`indices/concepts/all`) that
496
+ * lists every concept in the collection regardless of namespace nesting.
497
+ * The method returns immediately when the collection is empty.
498
+ */
499
+ override async generatePerInitialsIndexMdFiles(): Promise<void> {
500
+ if (this.collectionCompoundsById.size === 0) {
501
+ return
502
+ }
503
+
504
+ const allUnorderedEntriesMap = new Map<string, TreeEntryBase>()
505
+
506
+ for (const [conceptId, concept] of this.collectionCompoundsById) {
507
+ const entry = new ConceptEntry(concept as Concept)
508
+ allUnorderedEntriesMap.set(conceptId, entry)
509
+ }
510
+
511
+ // ------------------------------------------------------------------------
512
+
513
+ await this.generateIndexFile({
514
+ group: 'concepts',
515
+ fileKind: 'all',
516
+ title: 'Concepts Definitions Index',
517
+ description: 'The C++20 concepts defined in the project are:',
518
+ map: allUnorderedEntriesMap,
519
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
520
+ filter: (kind) => true,
521
+ })
522
+ }
523
+ }
524
+
525
+ // ============================================================================
526
+
527
+ /**
528
+ * Represents a single C++20 concept documentation compound.
529
+ *
530
+ * @remarks
531
+ * Encapsulates all information derived from a Doxygen compound definition
532
+ * of kind `concept`, including template parameter specification, the
533
+ * concept constraint expression, and the rendered documentation page.
534
+ *
535
+ * @public
536
+ */
537
+ export class Concept extends CompoundBase {
538
+ /**
539
+ * The unqualified concept name, without any namespace prefix.
540
+ *
541
+ * @remarks
542
+ * Derived from the fully qualified `compoundName` by stripping everything
543
+ * up to and including the last `::`. Anonymous namespace markers are
544
+ * also removed.
545
+ */
546
+ unqualifiedName = '???'
547
+
548
+ /**
549
+ * Rendered template parameter specification string.
550
+ *
551
+ * @remarks
552
+ * Contains the comma-separated list of template parameter names as they
553
+ * appear in the `template<...>` preamble of the concept definition.
554
+ * Empty when the concept has no template parameters.
555
+ */
556
+ templateParameters = ''
557
+
558
+ /**
559
+ * The rendered HTML string representing the concept constraint expression.
560
+ *
561
+ * @remarks
562
+ * Populated during {@link initializeLate} by rendering the Doxygen
563
+ * `initializer` element. Defaults to `'???'` until initialised.
564
+ */
565
+ initializerString = '???'
566
+
567
+ /**
568
+ * Rendered HTML lines for the concept parts content.
569
+ *
570
+ * @remarks
571
+ * Stores the rendered output of the Doxygen `conceptParts` element, which
572
+ * may contain an ordered mixture of documentation fragments and code
573
+ * fragments associated with the concept. Populated during
574
+ * {@link initializeLate}, and appended to the generated page body by
575
+ * {@link renderToLines}. The array remains empty when the compound does not
576
+ * include any concept parts.
577
+ */
578
+ conceptPartsHtmlLines: string[] = []
579
+
580
+ /**
581
+ * Creates a new Concept instance.
582
+ *
583
+ * @remarks
584
+ * Derives display names, permalink, and sidebar identifiers from the
585
+ * compound definition. The constraint expression
586
+ * ({@link initializerString}) is not rendered here; it is deferred to
587
+ * {@link initializeLate} because it may reference other compounds that
588
+ * have not yet been created.
589
+ *
590
+ * @param collection - The owning {@link Concepts} collection
591
+ * @param compoundDef - The Doxygen compound definition data
592
+ */
593
+ constructor(collection: Concepts, compoundDef: CompoundDefDataModel) {
594
+ super(collection, compoundDef)
595
+
596
+ // console.log('Class.constructor', util.inspect(compoundDef))
597
+
598
+ // The compoundName is the fully qualified namespace name.
599
+ // Keep only the last name.
600
+ this.unqualifiedName = sanitizeAnonymousNamespace(
601
+ compoundDef.compoundName.replace(/.*::/, '')
602
+ )
603
+ this.indexName = sanitizeAnonymousNamespace(
604
+ this.compoundName.replace(/.*::/, '')
605
+ )
606
+
607
+ this.pageTitle = `\`${this.unqualifiedName}\` Concept`
608
+
609
+ this.templateParameters = this.renderTemplateParameterNamesToString(
610
+ compoundDef.templateParamList
611
+ )
612
+
613
+ const sanitizedPath: string = sanitizeHierarchicalPath(
614
+ sanitizeAnonymousNamespace(this.compoundName.replaceAll('::', '/'))
615
+ )
616
+
617
+ this.relativePermalink = `concepts/${sanitizedPath}`
618
+ this.sidebarId = `concepts/${flattenPath(sanitizedPath)}`
619
+ const { unqualifiedName } = this
620
+ this.sidebarLabel = unqualifiedName
621
+
622
+ this.treeEntryName = this.indexName
623
+ }
624
+
625
+ /**
626
+ * Performs late initialisation that depends on the full compound graph.
627
+ *
628
+ * @remarks
629
+ * Renders the concept constraint expression after all compounds have
630
+ * been created, since the initializer may contain cross-references.
631
+ * Concepts with no content are hidden (permalink cleared) unless
632
+ * `suggestToDoDescriptions` is enabled.
633
+ */
634
+ override initializeLate(): void {
635
+ super.initializeLate()
636
+
637
+ const { workspace } = this.collection
638
+
639
+ // console.log(this)
640
+ if (!this.hasAnyContent()) {
641
+ if (!workspace.options.suggestToDoDescriptions) {
642
+ console.log(this.kind, this.compoundName, 'has no content, not shown')
643
+
644
+ this.sidebarId = undefined
645
+ this.sidebarLabel = undefined
646
+ this.relativePermalink = undefined
647
+
648
+ return
649
+ } else {
650
+ if (workspace.options.verbose) {
651
+ console.log(
652
+ this.kind,
653
+ this.compoundName,
654
+ 'has no content, see the TODO description'
655
+ )
656
+ }
657
+ }
658
+ }
659
+
660
+ // There might be references to other compounds in the initializer,
661
+ // so render it after all compounds are created.
662
+ if (this._private._compoundDef?.initializer !== undefined) {
663
+ this.initializerString = workspace
664
+ .renderElementToLines(this._private._compoundDef.initializer, 'html')
665
+ .join('<br/>\n')
666
+ .replace(/template/, 'template ')
667
+ }
668
+
669
+ const conceptParts = this._private._compoundDef?.conceptParts
670
+ if (conceptParts !== undefined) {
671
+ this.conceptPartsHtmlLines = workspace.renderElementToLines(
672
+ conceptParts,
673
+ 'html'
674
+ )
675
+ // console.log('conceptParts', this.conceptPartsHtmlLines)
676
+ }
677
+ }
678
+
679
+ /**
680
+ * Renders the concept documentation page body to an array of HTML lines.
681
+ *
682
+ * @remarks
683
+ * Produces the brief description header, the `## Definition` section
684
+ * containing the rendered constraint expression, and the detailed
685
+ * description block. The `frontMatter` parameter is currently unused
686
+ * but is required by the base class interface.
687
+ *
688
+ * @param frontMatter - The front matter object for the output page
689
+ * @returns An array of Markdown/HTML lines forming the page body
690
+ */
691
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
692
+ renderToLines(frontMatter: FrontMatter): string[] {
693
+ const lines: string[] = []
694
+
695
+ // const { workspace } = this.collection
696
+
697
+ const name = this.collection.workspace.renderString(
698
+ this.compoundName,
699
+ 'html'
700
+ )
701
+ const descriptionTodo = `@concept ${name}`
702
+
703
+ // The Description header is always shown.
704
+ const morePermalink = '#details'
705
+
706
+ lines.push(
707
+ this.renderBriefDescriptionToHtmlString({
708
+ briefDescriptionHtmlString: this.briefDescriptionHtmlString,
709
+ todo: descriptionTodo,
710
+ morePermalink,
711
+ })
712
+ )
713
+
714
+ lines.push('')
715
+ lines.push('## Definition')
716
+
717
+ lines.push('')
718
+ lines.push('<div class="doxyDefinition">')
719
+
720
+ lines.push(this.initializerString)
721
+ lines.push('</div>')
722
+
723
+ lines.push(
724
+ ...this.renderDetailedDescriptionToHtmlLines({
725
+ briefDescriptionHtmlString: this.briefDescriptionHtmlString,
726
+ detailedDescriptionHtmlLines: this.detailedDescriptionHtmlLines,
727
+ todo: descriptionTodo,
728
+ showHeader: true,
729
+ showBrief: !this.hasSect1InDescription,
730
+ })
731
+ )
732
+
733
+ if (this.locationLines !== undefined) {
734
+ lines.push(...this.locationLines)
735
+ }
736
+
737
+ lines.push(...this.conceptPartsHtmlLines)
738
+
739
+ // Currently here are no sections.
740
+ // lines.push(...this.renderSectionsToLines())
741
+
742
+ // Currently there are none.
743
+ // lines.push(...this.renderGeneratedFromToLines())
744
+
745
+ return lines
746
+ }
747
+ }
748
+
749
+ // ----------------------------------------------------------------------------