@docusaurus/theme-classic 0.0.0-5030 → 0.0.0-5033

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 (327) hide show
  1. package/lib/getSwizzleConfig.d.ts +8 -0
  2. package/lib/getSwizzleConfig.js +226 -234
  3. package/lib/index.d.ts +12 -0
  4. package/lib/index.js +103 -155
  5. package/lib/nprogress.d.ts +10 -0
  6. package/lib/nprogress.js +16 -37
  7. package/lib/prism-include-languages.d.ts +7 -0
  8. package/lib/prism-include-languages.js +3 -9
  9. package/lib/theme/Admonition/index.d.ts +9 -0
  10. package/{lib-next → lib}/theme/Admonition/index.js +0 -0
  11. package/lib/theme/AnnouncementBar/index.d.ts +8 -0
  12. package/{lib-next → lib}/theme/AnnouncementBar/index.js +4 -10
  13. package/{lib-next → lib}/theme/AnnouncementBar/styles.module.css +0 -0
  14. package/lib/theme/BackToTopButton/index.d.ts +8 -0
  15. package/{lib-next → lib}/theme/BackToTopButton/index.js +1 -3
  16. package/{lib-next → lib}/theme/BackToTopButton/styles.module.css +0 -0
  17. package/lib/theme/BlogArchivePage/index.d.ts +10 -0
  18. package/{lib-next → lib}/theme/BlogArchivePage/index.js +0 -4
  19. package/lib/theme/BlogLayout/index.d.ts +9 -0
  20. package/{lib-next → lib}/theme/BlogLayout/index.js +0 -0
  21. package/lib/theme/BlogListPage/index.d.ts +10 -0
  22. package/{lib-next → lib}/theme/BlogListPage/index.js +0 -3
  23. package/lib/theme/BlogListPaginator/index.d.ts +9 -0
  24. package/{lib-next → lib}/theme/BlogListPaginator/index.js +0 -0
  25. package/lib/theme/BlogPostAuthor/index.d.ts +9 -0
  26. package/{lib-next → lib}/theme/BlogPostAuthor/index.js +0 -3
  27. package/lib/theme/BlogPostAuthors/index.d.ts +9 -0
  28. package/{lib-next → lib}/theme/BlogPostAuthors/index.js +2 -4
  29. package/{lib-next → lib}/theme/BlogPostAuthors/styles.module.css +0 -0
  30. package/lib/theme/BlogPostItem/index.d.ts +9 -0
  31. package/{lib-next → lib}/theme/BlogPostItem/index.js +8 -20
  32. package/{lib-next → lib}/theme/BlogPostItem/styles.module.css +0 -0
  33. package/lib/theme/BlogPostPage/index.d.ts +10 -0
  34. package/{lib-next → lib}/theme/BlogPostPage/index.js +0 -3
  35. package/lib/theme/BlogPostPaginator/index.d.ts +9 -0
  36. package/{lib-next → lib}/theme/BlogPostPaginator/index.js +0 -0
  37. package/lib/theme/BlogSidebar/Desktop/index.d.ts +9 -0
  38. package/{lib-next → lib}/theme/BlogSidebar/Desktop/index.js +0 -0
  39. package/{lib-next → lib}/theme/BlogSidebar/Desktop/styles.module.css +0 -0
  40. package/lib/theme/BlogSidebar/Mobile/index.d.ts +9 -0
  41. package/{lib-next → lib}/theme/BlogSidebar/Mobile/index.js +0 -2
  42. package/lib/theme/BlogSidebar/index.d.ts +9 -0
  43. package/{lib-next → lib}/theme/BlogSidebar/index.js +2 -4
  44. package/lib/theme/BlogTagsListPage/index.d.ts +10 -0
  45. package/{lib-next → lib}/theme/BlogTagsListPage/index.js +0 -0
  46. package/lib/theme/BlogTagsPostsPage/index.d.ts +10 -0
  47. package/{lib-next → lib}/theme/BlogTagsPostsPage/index.js +2 -9
  48. package/lib/theme/CodeBlock/Container/index.d.ts +10 -0
  49. package/{lib-next → lib}/theme/CodeBlock/Container/index.js +2 -1
  50. package/{lib-next → lib}/theme/CodeBlock/Container/styles.module.css +0 -0
  51. package/lib/theme/CodeBlock/Content/Element.d.ts +9 -0
  52. package/{lib-next → lib}/theme/CodeBlock/Content/Element.js +2 -2
  53. package/lib/theme/CodeBlock/Content/String.d.ts +9 -0
  54. package/{lib-next → lib}/theme/CodeBlock/Content/String.js +2 -2
  55. package/{lib-next → lib}/theme/CodeBlock/Content/styles.module.css +0 -0
  56. package/lib/theme/CodeBlock/CopyButton/index.d.ts +9 -0
  57. package/{lib-next → lib}/theme/CodeBlock/CopyButton/index.js +0 -0
  58. package/{lib-next → lib}/theme/CodeBlock/CopyButton/styles.module.css +0 -0
  59. package/lib/theme/CodeBlock/Line/index.d.ts +9 -0
  60. package/{lib-next → lib}/theme/CodeBlock/Line/index.js +1 -8
  61. package/{lib-next → lib}/theme/CodeBlock/Line/styles.module.css +0 -0
  62. package/lib/theme/CodeBlock/WordWrapButton/index.d.ts +9 -0
  63. package/{lib-next → lib}/theme/CodeBlock/WordWrapButton/index.js +0 -0
  64. package/{lib-next → lib}/theme/CodeBlock/WordWrapButton/styles.module.css +0 -0
  65. package/lib/theme/CodeBlock/index.d.ts +9 -0
  66. package/{lib-next → lib}/theme/CodeBlock/index.js +2 -4
  67. package/lib/theme/ColorModeToggle/index.d.ts +11 -0
  68. package/{lib-next → lib}/theme/ColorModeToggle/index.js +0 -2
  69. package/{lib-next → lib}/theme/ColorModeToggle/styles.module.css +0 -0
  70. package/lib/theme/Details/index.d.ts +9 -0
  71. package/{lib-next → lib}/theme/Details/index.js +2 -2
  72. package/{lib-next → lib}/theme/Details/styles.module.css +0 -0
  73. package/lib/theme/DocBreadcrumbs/index.d.ts +8 -0
  74. package/{lib-next → lib}/theme/DocBreadcrumbs/index.js +6 -11
  75. package/{lib-next → lib}/theme/DocBreadcrumbs/styles.module.css +0 -0
  76. package/lib/theme/DocCard/index.d.ts +9 -0
  77. package/{lib-next → lib}/theme/DocCard/index.js +3 -13
  78. package/{lib-next → lib}/theme/DocCard/styles.module.css +0 -0
  79. package/lib/theme/DocCardList/index.d.ts +9 -0
  80. package/{lib-next → lib}/theme/DocCardList/index.js +0 -3
  81. package/lib/theme/DocCategoryGeneratedIndexPage/index.d.ts +10 -0
  82. package/{lib-next → lib}/theme/DocCategoryGeneratedIndexPage/index.js +4 -5
  83. package/{lib-next → lib}/theme/DocCategoryGeneratedIndexPage/styles.module.css +0 -0
  84. package/lib/theme/DocItem/index.d.ts +10 -0
  85. package/{lib-next → lib}/theme/DocItem/index.js +8 -20
  86. package/{lib-next → lib}/theme/DocItem/styles.module.css +0 -0
  87. package/lib/theme/DocItemFooter/index.d.ts +10 -0
  88. package/{lib-next → lib}/theme/DocItemFooter/index.js +0 -5
  89. package/{lib-next → lib}/theme/DocItemFooter/styles.module.css +0 -0
  90. package/lib/theme/DocPage/Layout/Main/index.d.ts +9 -0
  91. package/{lib-next → lib}/theme/DocPage/Layout/Main/index.js +0 -0
  92. package/{lib-next → lib}/theme/DocPage/Layout/Main/styles.module.css +0 -0
  93. package/lib/theme/DocPage/Layout/Sidebar/ExpandButton/index.d.ts +9 -0
  94. package/{lib-next → lib}/theme/DocPage/Layout/Sidebar/ExpandButton/index.js +0 -0
  95. package/{lib-next → lib}/theme/DocPage/Layout/Sidebar/ExpandButton/styles.module.css +0 -0
  96. package/lib/theme/DocPage/Layout/Sidebar/index.d.ts +9 -0
  97. package/{lib-next → lib}/theme/DocPage/Layout/Sidebar/index.js +2 -5
  98. package/{lib-next → lib}/theme/DocPage/Layout/Sidebar/styles.module.css +0 -0
  99. package/lib/theme/DocPage/Layout/index.d.ts +9 -0
  100. package/{lib-next → lib}/theme/DocPage/Layout/index.js +0 -0
  101. package/{lib-next → lib}/theme/DocPage/Layout/styles.module.css +0 -0
  102. package/lib/theme/DocPage/index.d.ts +10 -0
  103. package/{lib-next → lib}/theme/DocPage/index.js +0 -2
  104. package/lib/theme/DocPaginator/index.d.ts +9 -0
  105. package/{lib-next → lib}/theme/DocPaginator/index.js +0 -0
  106. package/lib/theme/DocSidebar/Desktop/CollapseButton/index.d.ts +9 -0
  107. package/{lib-next → lib}/theme/DocSidebar/Desktop/CollapseButton/index.js +0 -0
  108. package/{lib-next → lib}/theme/DocSidebar/Desktop/CollapseButton/styles.module.css +0 -0
  109. package/lib/theme/DocSidebar/Desktop/Content/index.d.ts +9 -0
  110. package/{lib-next → lib}/theme/DocSidebar/Desktop/Content/index.js +0 -2
  111. package/{lib-next → lib}/theme/DocSidebar/Desktop/Content/styles.module.css +0 -0
  112. package/lib/theme/DocSidebar/Desktop/index.d.ts +11 -0
  113. package/{lib-next → lib}/theme/DocSidebar/Desktop/index.js +0 -2
  114. package/{lib-next → lib}/theme/DocSidebar/Desktop/styles.module.css +0 -0
  115. package/lib/theme/DocSidebar/Mobile/index.d.ts +11 -0
  116. package/{lib-next → lib}/theme/DocSidebar/Mobile/index.js +0 -4
  117. package/lib/theme/DocSidebar/index.d.ts +9 -0
  118. package/{lib-next → lib}/theme/DocSidebar/index.js +4 -4
  119. package/lib/theme/DocSidebarItem/Category/index.d.ts +9 -0
  120. package/{lib-next → lib}/theme/DocSidebarItem/Category/index.js +6 -21
  121. package/lib/theme/DocSidebarItem/Html/index.d.ts +9 -0
  122. package/{lib-next → lib}/theme/DocSidebarItem/Html/index.js +3 -4
  123. package/{lib-next → lib}/theme/DocSidebarItem/Html/styles.module.css +0 -0
  124. package/lib/theme/DocSidebarItem/Link/index.d.ts +9 -0
  125. package/{lib-next → lib}/theme/DocSidebarItem/Link/index.js +0 -0
  126. package/{lib-next → lib}/theme/DocSidebarItem/Link/styles.module.css +0 -0
  127. package/lib/theme/DocSidebarItem/index.d.ts +9 -0
  128. package/{lib-next → lib}/theme/DocSidebarItem/index.js +0 -2
  129. package/lib/theme/DocSidebarItems/index.d.ts +11 -0
  130. package/{lib-next → lib}/theme/DocSidebarItems/index.js +2 -3
  131. package/lib/theme/DocTagDocListPage/index.d.ts +10 -0
  132. package/{lib-next → lib}/theme/DocTagDocListPage/index.js +2 -10
  133. package/lib/theme/DocTagsListPage/index.d.ts +10 -0
  134. package/{lib-next → lib}/theme/DocTagsListPage/index.js +0 -0
  135. package/lib/theme/DocVersionBadge/index.d.ts +9 -0
  136. package/{lib-next → lib}/theme/DocVersionBadge/index.js +1 -5
  137. package/lib/theme/DocVersionBanner/index.d.ts +9 -0
  138. package/{lib-next → lib}/theme/DocVersionBanner/index.js +3 -16
  139. package/lib/theme/EditThisPage/index.d.ts +9 -0
  140. package/{lib-next → lib}/theme/EditThisPage/index.js +0 -0
  141. package/lib/theme/ErrorPageContent.d.ts +10 -0
  142. package/{lib-next → lib}/theme/ErrorPageContent.js +0 -0
  143. package/lib/theme/Footer/Copyright/index.d.ts +9 -0
  144. package/{lib-next → lib}/theme/Footer/Copyright/index.js +3 -4
  145. package/lib/theme/Footer/Layout/index.d.ts +9 -0
  146. package/{lib-next → lib}/theme/Footer/Layout/index.js +0 -0
  147. package/lib/theme/Footer/LinkItem/index.d.ts +9 -0
  148. package/{lib-next → lib}/theme/Footer/LinkItem/index.js +1 -3
  149. package/lib/theme/Footer/Links/MultiColumn/index.d.ts +9 -0
  150. package/{lib-next → lib}/theme/Footer/Links/MultiColumn/index.js +3 -7
  151. package/lib/theme/Footer/Links/Simple/index.d.ts +9 -0
  152. package/{lib-next → lib}/theme/Footer/Links/Simple/index.js +3 -7
  153. package/lib/theme/Footer/Links/index.d.ts +9 -0
  154. package/{lib-next → lib}/theme/Footer/Links/index.js +0 -0
  155. package/lib/theme/Footer/Logo/index.d.ts +9 -0
  156. package/{lib-next → lib}/theme/Footer/Logo/index.js +0 -2
  157. package/{lib-next → lib}/theme/Footer/Logo/styles.module.css +0 -0
  158. package/lib/theme/Footer/index.d.ts +10 -0
  159. package/{lib-next → lib}/theme/Footer/index.js +0 -4
  160. package/lib/theme/Heading/index.d.ts +9 -0
  161. package/{lib-next → lib}/theme/Heading/index.js +2 -3
  162. package/{lib-next → lib}/theme/Heading/styles.module.css +0 -0
  163. package/lib/theme/IconArrow/index.d.ts +9 -0
  164. package/{lib-next → lib}/theme/IconArrow/index.js +0 -0
  165. package/lib/theme/IconClose/index.d.ts +9 -0
  166. package/{lib-next → lib}/theme/IconClose/index.js +0 -0
  167. package/lib/theme/IconDarkMode/index.d.ts +9 -0
  168. package/{lib-next → lib}/theme/IconDarkMode/index.js +0 -0
  169. package/lib/theme/IconEdit/index.d.ts +9 -0
  170. package/{lib-next → lib}/theme/IconEdit/index.js +0 -0
  171. package/{lib-next → lib}/theme/IconEdit/styles.module.css +0 -0
  172. package/lib/theme/IconExternalLink/index.d.ts +9 -0
  173. package/{lib-next → lib}/theme/IconExternalLink/index.js +0 -0
  174. package/{lib-next → lib}/theme/IconExternalLink/styles.module.css +0 -0
  175. package/lib/theme/IconHome/index.d.ts +9 -0
  176. package/{lib-next → lib}/theme/IconHome/index.js +0 -0
  177. package/lib/theme/IconLanguage/index.d.ts +9 -0
  178. package/{lib-next → lib}/theme/IconLanguage/index.js +0 -0
  179. package/lib/theme/IconLightMode/index.d.ts +9 -0
  180. package/{lib-next → lib}/theme/IconLightMode/index.js +0 -0
  181. package/lib/theme/IconMenu/index.d.ts +9 -0
  182. package/{lib-next → lib}/theme/IconMenu/index.js +0 -0
  183. package/lib/theme/LastUpdated/index.d.ts +9 -0
  184. package/{lib-next → lib}/theme/LastUpdated/index.js +0 -3
  185. package/lib/theme/Layout/index.d.ts +10 -0
  186. package/{lib-next → lib}/theme/Layout/index.js +0 -0
  187. package/{lib-next → lib}/theme/Layout/styles.css +0 -0
  188. package/lib/theme/LayoutProviders/index.d.ts +9 -0
  189. package/{lib-next → lib}/theme/LayoutProviders/index.js +0 -0
  190. package/lib/theme/Logo/index.d.ts +9 -0
  191. package/{lib-next → lib}/theme/Logo/index.js +2 -9
  192. package/lib/theme/MDXComponents/A.d.ts +9 -0
  193. package/{lib-next → lib}/theme/MDXComponents/A.js +0 -0
  194. package/lib/theme/MDXComponents/Code.d.ts +9 -0
  195. package/{lib-next → lib}/theme/MDXComponents/Code.js +0 -0
  196. package/lib/theme/MDXComponents/Details.d.ts +9 -0
  197. package/{lib-next → lib}/theme/MDXComponents/Details.js +2 -2
  198. package/lib/theme/MDXComponents/Head.d.ts +9 -0
  199. package/{lib-next → lib}/theme/MDXComponents/Head.js +0 -3
  200. package/lib/theme/MDXComponents/Heading.d.ts +9 -0
  201. package/{lib-next → lib}/theme/MDXComponents/Heading.js +0 -0
  202. package/lib/theme/MDXComponents/Img/index.d.ts +9 -0
  203. package/{lib-next → lib}/theme/MDXComponents/Img/index.js +0 -2
  204. package/{lib-next → lib}/theme/MDXComponents/Img/styles.module.css +0 -0
  205. package/lib/theme/MDXComponents/Pre.d.ts +9 -0
  206. package/{lib-next → lib}/theme/MDXComponents/Pre.js +2 -1
  207. package/lib/theme/MDXComponents/Ul.d.ts +9 -0
  208. package/{lib-next → lib}/theme/MDXComponents/Ul.js +2 -3
  209. package/lib/theme/MDXComponents/index.d.ts +9 -0
  210. package/{lib-next → lib}/theme/MDXComponents/index.js +0 -0
  211. package/lib/theme/MDXContent/index.d.ts +9 -0
  212. package/{lib-next → lib}/theme/MDXContent/index.js +0 -0
  213. package/lib/theme/MDXPage/index.d.ts +10 -0
  214. package/{lib-next → lib}/theme/MDXPage/index.js +0 -0
  215. package/{lib-next → lib}/theme/MDXPage/styles.module.css +0 -0
  216. package/lib/theme/Navbar/ColorModeToggle/index.d.ts +9 -0
  217. package/{lib-next → lib}/theme/Navbar/ColorModeToggle/index.js +0 -2
  218. package/lib/theme/Navbar/Content/index.d.ts +8 -0
  219. package/{lib-next → lib}/theme/Navbar/Content/index.js +0 -4
  220. package/{lib-next → lib}/theme/Navbar/Content/styles.module.css +0 -0
  221. package/lib/theme/Navbar/Layout/index.d.ts +9 -0
  222. package/{lib-next → lib}/theme/Navbar/Layout/index.js +0 -2
  223. package/{lib-next → lib}/theme/Navbar/Layout/styles.module.css +0 -0
  224. package/lib/theme/Navbar/Logo/index.d.ts +8 -0
  225. package/{lib-next → lib}/theme/Navbar/Logo/index.js +0 -0
  226. package/lib/theme/Navbar/MobileSidebar/Header/index.d.ts +8 -0
  227. package/{lib-next → lib}/theme/Navbar/MobileSidebar/Header/index.js +0 -2
  228. package/lib/theme/Navbar/MobileSidebar/Layout/index.d.ts +9 -0
  229. package/{lib-next → lib}/theme/Navbar/MobileSidebar/Layout/index.js +0 -0
  230. package/lib/theme/Navbar/MobileSidebar/PrimaryMenu/index.d.ts +8 -0
  231. package/{lib-next → lib}/theme/Navbar/MobileSidebar/PrimaryMenu/index.js +4 -5
  232. package/lib/theme/Navbar/MobileSidebar/SecondaryMenu/index.d.ts +8 -0
  233. package/{lib-next → lib}/theme/Navbar/MobileSidebar/SecondaryMenu/index.js +2 -3
  234. package/lib/theme/Navbar/MobileSidebar/Toggle/index.d.ts +8 -0
  235. package/{lib-next → lib}/theme/Navbar/MobileSidebar/Toggle/index.js +0 -0
  236. package/lib/theme/Navbar/MobileSidebar/index.d.ts +8 -0
  237. package/{lib-next → lib}/theme/Navbar/MobileSidebar/index.js +0 -2
  238. package/lib/theme/Navbar/Search/index.d.ts +9 -0
  239. package/{lib-next → lib}/theme/Navbar/Search/index.js +0 -0
  240. package/{lib-next → lib}/theme/Navbar/Search/styles.module.css +0 -0
  241. package/lib/theme/Navbar/index.d.ts +8 -0
  242. package/{lib-next → lib}/theme/Navbar/index.js +0 -0
  243. package/lib/theme/NavbarItem/ComponentTypes.d.ts +9 -0
  244. package/{lib-next → lib}/theme/NavbarItem/ComponentTypes.js +0 -0
  245. package/lib/theme/NavbarItem/DefaultNavbarItem.d.ts +10 -0
  246. package/{lib-next → lib}/theme/NavbarItem/DefaultNavbarItem.js +1 -7
  247. package/lib/theme/NavbarItem/DocNavbarItem.d.ts +9 -0
  248. package/{lib-next → lib}/theme/NavbarItem/DocNavbarItem.js +3 -4
  249. package/lib/theme/NavbarItem/DocSidebarNavbarItem.d.ts +9 -0
  250. package/{lib-next → lib}/theme/NavbarItem/DocSidebarNavbarItem.js +0 -2
  251. package/lib/theme/NavbarItem/DocsVersionDropdownNavbarItem.d.ts +9 -0
  252. package/{lib-next → lib}/theme/NavbarItem/DocsVersionDropdownNavbarItem.js +4 -7
  253. package/lib/theme/NavbarItem/DocsVersionNavbarItem.d.ts +9 -0
  254. package/{lib-next → lib}/theme/NavbarItem/DocsVersionNavbarItem.js +0 -2
  255. package/lib/theme/NavbarItem/DropdownNavbarItem.d.ts +9 -0
  256. package/{lib-next → lib}/theme/NavbarItem/DropdownNavbarItem.js +6 -17
  257. package/lib/theme/NavbarItem/HtmlNavbarItem.d.ts +9 -0
  258. package/{lib-next → lib}/theme/NavbarItem/HtmlNavbarItem.js +1 -3
  259. package/lib/theme/NavbarItem/LocaleDropdownNavbarItem/index.d.ts +9 -0
  260. package/{lib-next → lib}/theme/NavbarItem/LocaleDropdownNavbarItem/index.js +2 -2
  261. package/{lib-next → lib}/theme/NavbarItem/LocaleDropdownNavbarItem/styles.module.css +0 -0
  262. package/lib/theme/NavbarItem/NavbarNavLink.d.ts +9 -0
  263. package/{lib-next → lib}/theme/NavbarItem/NavbarNavLink.js +5 -16
  264. package/lib/theme/NavbarItem/SearchNavbarItem.d.ts +9 -0
  265. package/{lib-next → lib}/theme/NavbarItem/SearchNavbarItem.js +0 -1
  266. package/lib/theme/NavbarItem/index.d.ts +9 -0
  267. package/{lib-next → lib}/theme/NavbarItem/index.js +0 -6
  268. package/lib/theme/NavbarItem/utils.d.ts +7 -0
  269. package/{lib-next → lib}/theme/NavbarItem/utils.js +0 -1
  270. package/lib/theme/NotFound.d.ts +8 -0
  271. package/{lib-next → lib}/theme/NotFound.js +0 -0
  272. package/lib/theme/PaginatorNavLink/index.d.ts +9 -0
  273. package/{lib-next → lib}/theme/PaginatorNavLink/index.js +0 -0
  274. package/lib/theme/SearchBar.d.ts +7 -0
  275. package/{lib-next → lib}/theme/SearchBar.js +0 -0
  276. package/lib/theme/SearchMetadata/index.d.ts +9 -0
  277. package/{lib-next → lib}/theme/SearchMetadata/index.js +3 -3
  278. package/lib/theme/SiteMetadata/index.d.ts +8 -0
  279. package/{lib-next → lib}/theme/SiteMetadata/index.js +15 -16
  280. package/lib/theme/SkipToContent/index.d.ts +8 -0
  281. package/{lib-next → lib}/theme/SkipToContent/index.js +0 -0
  282. package/{lib-next → lib}/theme/SkipToContent/styles.module.css +0 -0
  283. package/lib/theme/TOC/index.d.ts +9 -0
  284. package/{lib-next → lib}/theme/TOC/index.js +2 -2
  285. package/{lib-next → lib}/theme/TOC/styles.module.css +0 -0
  286. package/lib/theme/TOCCollapsible/CollapseButton/index.d.ts +9 -0
  287. package/{lib-next → lib}/theme/TOCCollapsible/CollapseButton/index.js +0 -0
  288. package/{lib-next → lib}/theme/TOCCollapsible/CollapseButton/styles.module.css +0 -0
  289. package/lib/theme/TOCCollapsible/index.d.ts +9 -0
  290. package/{lib-next → lib}/theme/TOCCollapsible/index.js +0 -0
  291. package/{lib-next → lib}/theme/TOCCollapsible/styles.module.css +0 -0
  292. package/lib/theme/TOCInline/index.d.ts +9 -0
  293. package/{lib-next → lib}/theme/TOCInline/index.js +0 -0
  294. package/{lib-next → lib}/theme/TOCInline/styles.module.css +0 -0
  295. package/lib/theme/TOCItems/Tree.d.ts +11 -0
  296. package/{lib-next → lib}/theme/TOCItems/Tree.js +5 -8
  297. package/lib/theme/TOCItems/index.d.ts +9 -0
  298. package/{lib-next → lib}/theme/TOCItems/index.js +0 -1
  299. package/lib/theme/TabItem/index.d.ts +9 -0
  300. package/{lib-next → lib}/theme/TabItem/index.js +1 -3
  301. package/{lib-next → lib}/theme/TabItem/styles.module.css +0 -0
  302. package/lib/theme/Tabs/index.d.ts +9 -0
  303. package/{lib-next → lib}/theme/Tabs/index.js +11 -27
  304. package/{lib-next → lib}/theme/Tabs/styles.module.css +0 -0
  305. package/lib/theme/Tag/index.d.ts +9 -0
  306. package/{lib-next → lib}/theme/Tag/index.js +0 -0
  307. package/{lib-next → lib}/theme/Tag/styles.module.css +0 -0
  308. package/lib/theme/TagsListByLetter/index.d.ts +9 -0
  309. package/{lib-next → lib}/theme/TagsListByLetter/index.js +0 -2
  310. package/{lib-next → lib}/theme/TagsListByLetter/styles.module.css +0 -0
  311. package/lib/theme/TagsListInline/index.d.ts +9 -0
  312. package/{lib-next → lib}/theme/TagsListInline/index.js +0 -0
  313. package/{lib-next → lib}/theme/TagsListInline/styles.module.css +0 -0
  314. package/lib/theme/ThemedImage/index.d.ts +9 -0
  315. package/{lib-next → lib}/theme/ThemedImage/index.js +3 -2
  316. package/{lib-next → lib}/theme/ThemedImage/styles.module.css +0 -0
  317. package/lib/theme/prism-include-languages.d.ts +8 -0
  318. package/{lib-next → lib}/theme/prism-include-languages.js +2 -2
  319. package/lib/translations.d.ts +15 -0
  320. package/lib/translations.js +120 -136
  321. package/lib/validateThemeConfig.d.ts +68 -0
  322. package/lib/validateThemeConfig.js +353 -322
  323. package/package.json +19 -25
  324. package/src/index.ts +1 -1
  325. package/lib/deps.d.ts +0 -13
  326. package/lib/theme-classic.d.ts +0 -1279
  327. package/lib-next/theme/Tabs/__tests__/index.test.js +0 -146
@@ -8,7 +8,6 @@ import React from 'react';
8
8
  import clsx from 'clsx';
9
9
  import NavbarNavLink from '@theme/NavbarItem/NavbarNavLink';
10
10
  import {getInfimaActiveClassName} from '@theme/NavbarItem/utils';
11
-
12
11
  function DefaultNavbarItemDesktop({
13
12
  className,
14
13
  isDropdownItem = false,
@@ -23,14 +22,11 @@ function DefaultNavbarItemDesktop({
23
22
  {...props}
24
23
  />
25
24
  );
26
-
27
25
  if (isDropdownItem) {
28
26
  return <li>{element}</li>;
29
27
  }
30
-
31
28
  return element;
32
29
  }
33
-
34
30
  function DefaultNavbarItemMobile({className, isDropdownItem, ...props}) {
35
31
  return (
36
32
  <li className="menu__list-item">
@@ -38,11 +34,9 @@ function DefaultNavbarItemMobile({className, isDropdownItem, ...props}) {
38
34
  </li>
39
35
  );
40
36
  }
41
-
42
37
  export default function DefaultNavbarItem({
43
38
  mobile = false,
44
- position,
45
- // Need to destructure position from props so that it doesn't get passed on.
39
+ position, // Need to destructure position from props so that it doesn't get passed on.
46
40
  ...props
47
41
  }) {
48
42
  const Comp = mobile ? DefaultNavbarItemMobile : DefaultNavbarItemDesktop;
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/DocNavbarItem';
9
+ export default function DocNavbarItem({ docId, label: staticLabel, docsPluginId, ...props }: Props): JSX.Element | null;
@@ -17,20 +17,19 @@ export default function DocNavbarItem({
17
17
  ...props
18
18
  }) {
19
19
  const {activeDoc} = useActiveDocContext(docsPluginId);
20
- const doc = useLayoutDoc(docId, docsPluginId); // Draft items are not displayed in the navbar.
21
-
20
+ const doc = useLayoutDoc(docId, docsPluginId);
21
+ // Draft items are not displayed in the navbar.
22
22
  if (doc === null) {
23
23
  return null;
24
24
  }
25
-
26
25
  const activeDocInfimaClassName = getInfimaActiveClassName(props.mobile);
27
26
  return (
28
27
  <DefaultNavbarItem
29
28
  exact
30
29
  {...props}
31
30
  className={clsx(props.className, {
32
- // Do not make the item active if the active doc doesn't have sidebar.
33
31
  [activeDocInfimaClassName]:
32
+ // Do not make the item active if the active doc doesn't have sidebar.
34
33
  // If `activeDoc === doc` react-router will make it active anyways,
35
34
  // regardless of the existence of a sidebar
36
35
  activeDoc?.sidebar && activeDoc.sidebar === doc.sidebar,
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/DocSidebarNavbarItem';
9
+ export default function DocSidebarNavbarItem({ sidebarId, label, docsPluginId, ...props }: Props): JSX.Element;
@@ -18,13 +18,11 @@ export default function DocSidebarNavbarItem({
18
18
  }) {
19
19
  const {activeDoc} = useActiveDocContext(docsPluginId);
20
20
  const sidebarLink = useLayoutDocsSidebar(sidebarId, docsPluginId).link;
21
-
22
21
  if (!sidebarLink) {
23
22
  throw new Error(
24
23
  `DocSidebarNavbarItem: Sidebar with ID "${sidebarId}" doesn't have anything to be linked to.`,
25
24
  );
26
25
  }
27
-
28
26
  const activeDocInfimaClassName = getInfimaActiveClassName(props.mobile);
29
27
  return (
30
28
  <DefaultNavbarItem
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/DocsVersionDropdownNavbarItem';
9
+ export default function DocsVersionDropdownNavbarItem({ mobile, docsPluginId, dropdownActiveClassDisabled, dropdownItemsBefore, dropdownItemsAfter, ...props }: Props): JSX.Element;
@@ -16,10 +16,8 @@ import {
16
16
  import {translate} from '@docusaurus/Translate';
17
17
  import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem';
18
18
  import DropdownNavbarItem from '@theme/NavbarItem/DropdownNavbarItem';
19
-
20
19
  const getVersionMainDoc = (version) =>
21
20
  version.docs.find((doc) => doc.id === version.mainDocId);
22
-
23
21
  export default function DocsVersionDropdownNavbarItem({
24
22
  mobile,
25
23
  docsPluginId,
@@ -50,8 +48,8 @@ export default function DocsVersionDropdownNavbarItem({
50
48
  ...versionLinks,
51
49
  ...dropdownItemsAfter,
52
50
  ];
53
- const dropdownVersion = useDocsVersionCandidates(docsPluginId)[0]; // Mobile dropdown is handled a bit differently
54
-
51
+ const dropdownVersion = useDocsVersionCandidates(docsPluginId)[0];
52
+ // Mobile dropdown is handled a bit differently
55
53
  const dropdownLabel =
56
54
  mobile && items.length > 1
57
55
  ? translate({
@@ -64,10 +62,10 @@ export default function DocsVersionDropdownNavbarItem({
64
62
  const dropdownTo =
65
63
  mobile && items.length > 1
66
64
  ? undefined
67
- : getVersionMainDoc(dropdownVersion).path; // We don't want to render a version dropdown with 0 or 1 item. If we build
65
+ : getVersionMainDoc(dropdownVersion).path;
66
+ // We don't want to render a version dropdown with 0 or 1 item. If we build
68
67
  // the site with a single docs version (onlyIncludeVersions: ['1.0.0']),
69
68
  // We'd rather render a button instead of a dropdown
70
-
71
69
  if (items.length <= 1) {
72
70
  return (
73
71
  <DefaultNavbarItem
@@ -79,7 +77,6 @@ export default function DocsVersionDropdownNavbarItem({
79
77
  />
80
78
  );
81
79
  }
82
-
83
80
  return (
84
81
  <DropdownNavbarItem
85
82
  {...props}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/DocsVersionNavbarItem';
9
+ export default function DocsVersionNavbarItem({ label: staticLabel, to: staticTo, docsPluginId, ...props }: Props): JSX.Element;
@@ -7,10 +7,8 @@
7
7
  import React from 'react';
8
8
  import {useDocsVersionCandidates} from '@docusaurus/theme-common';
9
9
  import DefaultNavbarItem from '@theme/NavbarItem/DefaultNavbarItem';
10
-
11
10
  const getVersionMainDoc = (version) =>
12
11
  version.docs.find((doc) => doc.id === version.mainDocId);
13
-
14
12
  export default function DocsVersionNavbarItem({
15
13
  label: staticLabel,
16
14
  to: staticTo,
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/DropdownNavbarItem';
9
+ export default function DropdownNavbarItem({ mobile, ...props }: Props): JSX.Element;
@@ -16,27 +16,21 @@ import {
16
16
  import NavbarNavLink from '@theme/NavbarItem/NavbarNavLink';
17
17
  import NavbarItem from '@theme/NavbarItem';
18
18
  const dropdownLinkActiveClass = 'dropdown__link--active';
19
-
20
19
  function isItemActive(item, localPathname) {
21
20
  if (isSamePath(item.to, localPathname)) {
22
21
  return true;
23
22
  }
24
-
25
23
  if (isRegexpStringMatch(item.activeBaseRegex, localPathname)) {
26
24
  return true;
27
25
  }
28
-
29
26
  if (item.activeBasePath && localPathname.startsWith(item.activeBasePath)) {
30
27
  return true;
31
28
  }
32
-
33
29
  return false;
34
30
  }
35
-
36
31
  function containsActiveItems(items, localPathname) {
37
32
  return items.some((item) => isItemActive(item, localPathname));
38
33
  }
39
-
40
34
  function DropdownNavbarItemDesktop({items, position, className, ...props}) {
41
35
  const dropdownRef = useRef(null);
42
36
  const [showDropdown, setShowDropdown] = useState(false);
@@ -45,10 +39,8 @@ function DropdownNavbarItemDesktop({items, position, className, ...props}) {
45
39
  if (!dropdownRef.current || dropdownRef.current.contains(event.target)) {
46
40
  return;
47
41
  }
48
-
49
42
  setShowDropdown(false);
50
43
  };
51
-
52
44
  document.addEventListener('mousedown', handleClickOutside);
53
45
  document.addEventListener('touchstart', handleClickOutside);
54
46
  return () => {
@@ -88,12 +80,12 @@ function DropdownNavbarItemDesktop({items, position, className, ...props}) {
88
80
  e.preventDefault();
89
81
  setShowDropdown(false);
90
82
  const nextNavbarItem = dropdownRef.current.nextElementSibling;
91
-
92
83
  if (nextNavbarItem) {
93
84
  const targetItem =
94
85
  nextNavbarItem instanceof HTMLAnchorElement
95
- ? nextNavbarItem // Next item is another dropdown; focus on the inner
96
- : // anchor element instead so there's outline
86
+ ? nextNavbarItem
87
+ : // Next item is another dropdown; focus on the inner
88
+ // anchor element instead so there's outline
97
89
  nextNavbarItem.querySelector('a');
98
90
  targetItem.focus();
99
91
  }
@@ -108,20 +100,18 @@ function DropdownNavbarItemDesktop({items, position, className, ...props}) {
108
100
  </div>
109
101
  );
110
102
  }
111
-
112
103
  function DropdownNavbarItemMobile({
113
104
  items,
114
105
  className,
115
- position,
116
- // Need to destructure position from props so that it doesn't get passed on.
106
+ position, // Need to destructure position from props so that it doesn't get passed on.
117
107
  ...props
118
108
  }) {
119
109
  const localPathname = useLocalPathname();
120
110
  const containsActive = containsActiveItems(items, localPathname);
121
111
  const {collapsed, toggleCollapsed, setCollapsed} = useCollapsible({
122
112
  initialState: () => !containsActive,
123
- }); // Expand/collapse if any item active after a navigation
124
-
113
+ });
114
+ // Expand/collapse if any item active after a navigation
125
115
  useEffect(() => {
126
116
  if (containsActive) {
127
117
  setCollapsed(!containsActive);
@@ -160,7 +150,6 @@ function DropdownNavbarItemMobile({
160
150
  </li>
161
151
  );
162
152
  }
163
-
164
153
  export default function DropdownNavbarItem({mobile = false, ...props}) {
165
154
  const Comp = mobile ? DropdownNavbarItemMobile : DropdownNavbarItemDesktop;
166
155
  return <Comp {...props} />;
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/HtmlNavbarItem';
9
+ export default function HtmlNavbarItem({ value, className, mobile, isDropdownItem, }: Props): JSX.Element;
@@ -22,9 +22,7 @@ export default function HtmlNavbarItem({
22
22
  },
23
23
  className,
24
24
  )}
25
- dangerouslySetInnerHTML={{
26
- __html: value,
27
- }}
25
+ dangerouslySetInnerHTML={{__html: value}}
28
26
  />
29
27
  );
30
28
  }
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/LocaleDropdownNavbarItem';
9
+ export default function LocaleDropdownNavbarItem({ mobile, dropdownItemsBefore, dropdownItemsAfter, ...props }: Props): JSX.Element;
@@ -35,8 +35,8 @@ export default function LocaleDropdownNavbarItem({
35
35
  className: locale === currentLocale ? 'dropdown__link--active' : '',
36
36
  };
37
37
  });
38
- const items = [...dropdownItemsBefore, ...localeItems, ...dropdownItemsAfter]; // Mobile is handled a bit differently
39
-
38
+ const items = [...dropdownItemsBefore, ...localeItems, ...dropdownItemsAfter];
39
+ // Mobile is handled a bit differently
40
40
  const dropdownLabel = mobile
41
41
  ? translate({
42
42
  message: 'Languages',
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/NavbarNavLink';
9
+ export default function NavbarNavLink({ activeBasePath, activeBaseRegex, to, href, label, html, activeClassName, prependBaseUrlToHref, ...props }: Props): JSX.Element;
@@ -26,34 +26,24 @@ export default function NavbarNavLink({
26
26
  // {to: 'version'} should probably be forbidden, in favor of {to: '/version'}
27
27
  const toUrl = useBaseUrl(to);
28
28
  const activeBaseUrl = useBaseUrl(activeBasePath);
29
- const normalizedHref = useBaseUrl(href, {
30
- forcePrependBaseUrl: true,
31
- });
29
+ const normalizedHref = useBaseUrl(href, {forcePrependBaseUrl: true});
32
30
  const isExternalLink = label && href && !isInternalUrl(href);
33
- const isDropdownLink = activeClassName === dropdownLinkActiveClass; // Link content is set through html XOR label
34
-
31
+ const isDropdownLink = activeClassName === dropdownLinkActiveClass;
32
+ // Link content is set through html XOR label
35
33
  const linkContentProps = html
36
- ? {
37
- dangerouslySetInnerHTML: {
38
- __html: html,
39
- },
40
- }
34
+ ? {dangerouslySetInnerHTML: {__html: html}}
41
35
  : {
42
36
  children: (
43
37
  <>
44
38
  {label}
45
39
  {isExternalLink && (
46
40
  <IconExternalLink
47
- {...(isDropdownLink && {
48
- width: 12,
49
- height: 12,
50
- })}
41
+ {...(isDropdownLink && {width: 12, height: 12})}
51
42
  />
52
43
  )}
53
44
  </>
54
45
  ),
55
46
  };
56
-
57
47
  if (href) {
58
48
  return (
59
49
  <Link
@@ -63,7 +53,6 @@ export default function NavbarNavLink({
63
53
  />
64
54
  );
65
55
  }
66
-
67
56
  return (
68
57
  <Link
69
58
  to={toUrl}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem/SearchNavbarItem';
9
+ export default function SearchNavbarItem({ mobile }: Props): JSX.Element | null;
@@ -11,7 +11,6 @@ export default function SearchNavbarItem({mobile}) {
11
11
  if (mobile) {
12
12
  return null;
13
13
  }
14
-
15
14
  return (
16
15
  <NavbarSearch>
17
16
  <SearchBar />
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/NavbarItem';
9
+ export default function NavbarItem({ type, ...props }: Props): JSX.Element;
@@ -6,27 +6,21 @@
6
6
  */
7
7
  import React from 'react';
8
8
  import ComponentTypes from '@theme/NavbarItem/ComponentTypes';
9
-
10
9
  const getNavbarItemComponent = (type) => {
11
10
  const component = ComponentTypes[type];
12
-
13
11
  if (!component) {
14
12
  throw new Error(`No NavbarItem component found for type "${type}".`);
15
13
  }
16
-
17
14
  return component;
18
15
  };
19
-
20
16
  function getComponentType(type, isDropdown) {
21
17
  // Backward compatibility: navbar item with no type set
22
18
  // but containing dropdown items should use the type "dropdown"
23
19
  if (!type || type === 'default') {
24
20
  return isDropdown ? 'dropdown' : 'default';
25
21
  }
26
-
27
22
  return type;
28
23
  }
29
-
30
24
  export default function NavbarItem({type, ...props}) {
31
25
  const componentType = getComponentType(type, props.items !== undefined);
32
26
  const NavbarItemComponent = getNavbarItemComponent(componentType);
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export declare const getInfimaActiveClassName: (mobile?: boolean | undefined) => `${'menu' | 'navbar'}__link--active`;
@@ -4,7 +4,6 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  */
7
-
8
7
  /* eslint-disable import/no-named-export */
9
8
  export const getInfimaActiveClassName = (mobile) =>
10
9
  mobile ? 'menu__link--active' : 'navbar__link--active';
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ export default function NotFound(): JSX.Element;
File without changes
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/PaginatorNavLink';
9
+ export default function PaginatorNavLink(props: Props): JSX.Element;
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export { default } from '@docusaurus/Noop';
File without changes
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/SearchMetadata';
9
+ export default function SearchMetadata({ locale, version, tag, }: Props): JSX.Element;
@@ -18,9 +18,9 @@ export default function SearchMetadata({locale, version, tag}) {
18
18
  return (
19
19
  <Head>
20
20
  {/*
21
- Docusaurus metadata, used by third-party search plugin
22
- See https://github.com/cmfcmf/docusaurus-search-local/issues/99
23
- */}
21
+ Docusaurus metadata, used by third-party search plugin
22
+ See https://github.com/cmfcmf/docusaurus-search-local/issues/99
23
+ */}
24
24
  {locale && <meta name="docusaurus_locale" content={locale} />}
25
25
  {version && <meta name="docusaurus_version" content={version} />}
26
26
  {tag && <meta name="docusaurus_tag" content={tag} />}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ export default function SiteMetadata(): JSX.Element;
@@ -16,18 +16,18 @@ import {
16
16
  keyboardFocusedClassName,
17
17
  } from '@docusaurus/theme-common';
18
18
  import {useLocation} from '@docusaurus/router';
19
- import SearchMetadata from '@theme/SearchMetadata'; // TODO move to SiteMetadataDefaults or theme-common ?
19
+ import SearchMetadata from '@theme/SearchMetadata';
20
+ // TODO move to SiteMetadataDefaults or theme-common ?
20
21
  // Useful for i18n/SEO
21
22
  // See https://developers.google.com/search/docs/advanced/crawling/localized-versions
22
23
  // See https://github.com/facebook/docusaurus/issues/3317
23
-
24
24
  function AlternateLangHeaders() {
25
25
  const {
26
26
  i18n: {defaultLocale, localeConfigs},
27
27
  } = useDocusaurusContext();
28
- const alternatePageUtils = useAlternatePageUtils(); // Note: it is fine to use both "x-default" and "en" to target the same url
28
+ const alternatePageUtils = useAlternatePageUtils();
29
+ // Note: it is fine to use both "x-default" and "en" to target the same url
29
30
  // See https://www.searchviu.com/en/multiple-hreflang-tags-one-url/
30
-
31
31
  return (
32
32
  <Head>
33
33
  {Object.entries(localeConfigs).map(([locale, {htmlLang}]) => (
@@ -51,16 +51,16 @@ function AlternateLangHeaders() {
51
51
  />
52
52
  </Head>
53
53
  );
54
- } // Default canonical url inferred from current page location pathname
55
-
54
+ }
55
+ // Default canonical url inferred from current page location pathname
56
56
  function useDefaultCanonicalUrl() {
57
57
  const {
58
58
  siteConfig: {url: siteUrl},
59
59
  } = useDocusaurusContext();
60
60
  const {pathname} = useLocation();
61
61
  return siteUrl + useBaseUrl(pathname);
62
- } // TODO move to SiteMetadataDefaults or theme-common ?
63
-
62
+ }
63
+ // TODO move to SiteMetadataDefaults or theme-common ?
64
64
  function CanonicalUrlHeaders({permalink}) {
65
65
  const {
66
66
  siteConfig: {url: siteUrl},
@@ -76,13 +76,12 @@ function CanonicalUrlHeaders({permalink}) {
76
76
  </Head>
77
77
  );
78
78
  }
79
-
80
79
  export default function SiteMetadata() {
81
80
  const {
82
81
  i18n: {currentLocale},
83
- } = useDocusaurusContext(); // TODO maybe move these 2 themeConfig to siteConfig?
82
+ } = useDocusaurusContext();
83
+ // TODO maybe move these 2 themeConfig to siteConfig?
84
84
  // These seems useful for other themes as well
85
-
86
85
  const {metadata, image: defaultImage} = useThemeConfig();
87
86
  return (
88
87
  <>
@@ -102,11 +101,11 @@ export default function SiteMetadata() {
102
101
  <SearchMetadata tag={DEFAULT_SEARCH_TAG} locale={currentLocale} />
103
102
 
104
103
  {/*
105
- It's important to have an additional <Head> element here, as it allows
106
- react-helmet to override default metadata values set in previous <Head>
107
- like "twitter:card". In same Head, the same meta would appear twice
108
- instead of overriding.
109
- */}
104
+ It's important to have an additional <Head> element here, as it allows
105
+ react-helmet to override default metadata values set in previous <Head>
106
+ like "twitter:card". In same Head, the same meta would appear twice
107
+ instead of overriding.
108
+ */}
110
109
  <Head>
111
110
  {/* Yes, "metadatum" is the grammatically correct term */}
112
111
  {metadata.map((metadatum, i) => (
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ export default function SkipToContent(): JSX.Element;
File without changes
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Copyright (c) Facebook, Inc. and its affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ /// <reference types="react" />
8
+ import type { Props } from '@theme/TOC';
9
+ export default function TOC({ className, ...props }: Props): JSX.Element;
@@ -7,9 +7,9 @@
7
7
  import React from 'react';
8
8
  import clsx from 'clsx';
9
9
  import TOCItems from '@theme/TOCItems';
10
- import styles from './styles.module.css'; // Using a custom className
10
+ import styles from './styles.module.css';
11
+ // Using a custom className
11
12
  // This prevents TOCInline/TOCCollapsible getting highlighted by mistake
12
-
13
13
  const LINK_CLASS_NAME = 'table-of-contents__link toc-highlight';
14
14
  const LINK_ACTIVE_CLASS_NAME = 'table-of-contents__link--active';
15
15
  export default function TOC({className, ...props}) {
File without changes