@redocly/reference-docs 3.0.0-alpha.1 → 3.0.0-alpha.4

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 (751) hide show
  1. package/bin/cli/commands/redocly-docs-cli.min.js +546 -437
  2. package/bin/cli/commands/redocly-docs-cli.min.js.LICENSE.txt +14 -36
  3. package/dist/console.redocly-reference-docs.min.js +319 -296
  4. package/dist/oauth2-redirect.js +5 -5
  5. package/dist/redocly-reference-docs.min.js +2991 -2104
  6. package/lib/components/Endpoint/Endpoint.d.ts +1 -6
  7. package/lib/components/Endpoint/Endpoint.js +1 -1
  8. package/lib/components/Endpoint/ServerList.d.ts +2 -7
  9. package/lib/components/Endpoint/ServerList.js +1 -1
  10. package/lib/components/Endpoint/Summary.d.ts +1 -12
  11. package/lib/components/Endpoint/Summary.js +1 -1
  12. package/lib/components/Endpoint/index.d.ts +2 -1
  13. package/lib/components/Endpoint/index.js +1 -1
  14. package/lib/components/Endpoint/styled.d.ts +13 -0
  15. package/lib/components/Endpoint/styled.js +2 -0
  16. package/lib/components/Endpoint/types.d.ts +21 -0
  17. package/lib/{redoc-lib/src/services/MenuStore.js → components/Endpoint/types.js} +1 -1
  18. package/lib/components/NextSectionButton.d.ts +6 -5
  19. package/lib/components/NextSectionButton.js +1 -1
  20. package/lib/components/OperationParameters/OperationParameters.d.ts +3 -0
  21. package/lib/components/OperationParameters/OperationParameters.js +2 -0
  22. package/lib/components/OperationParameters/index.d.ts +1 -0
  23. package/lib/components/OperationParameters/index.js +2 -0
  24. package/lib/components/{console/OperationParameters.d.ts → OperationParameters/types.d.ts} +5 -3
  25. package/lib/components/OperationParameters/types.js +2 -0
  26. package/lib/components/OperationParameters/utils.d.ts +7 -0
  27. package/lib/components/OperationParameters/utils.js +2 -0
  28. package/lib/components/Panel/Accordion.js +1 -1
  29. package/lib/components/Panel/ContentPanel.js +1 -1
  30. package/lib/components/Panel/Description.d.ts +1 -0
  31. package/lib/components/Panel/Description.js +2 -0
  32. package/lib/components/Panel/PanelComponent.d.ts +4 -2
  33. package/lib/components/Panel/PanelComponent.js +1 -1
  34. package/lib/components/Panel/ResponsePanel.js +1 -1
  35. package/lib/components/Panel/Trigger.js +1 -1
  36. package/lib/components/Panel/index.d.ts +1 -0
  37. package/lib/components/Panel/index.js +1 -1
  38. package/lib/components/ProProviders.d.ts +8 -2
  39. package/lib/components/RedoclyReferenceDocs.d.ts +2 -7
  40. package/lib/components/RedoclyReferenceDocs.js +1 -1
  41. package/lib/components/RedoclyReferenceDocsMultiStandalone.d.ts +8 -0
  42. package/lib/components/RedoclyReferenceDocsMultiStandalone.js +2 -0
  43. package/lib/components/Samples/ExampleSwitch.d.ts +1 -2
  44. package/lib/components/Samples/ExampleSwitch.js +1 -1
  45. package/lib/components/Samples/SamplesTabs.d.ts +3 -1
  46. package/lib/components/Samples/SamplesTabs.js +1 -1
  47. package/lib/components/Samples/use-example-key.js +1 -1
  48. package/lib/components/Search/ProSearchBox.js +1 -1
  49. package/lib/components/StoreProvider.d.ts +1 -1
  50. package/lib/components/StoreProvider.js +1 -1
  51. package/lib/components/Tabs/CollapsingTabs/CollapsingTabs.js +1 -1
  52. package/lib/components/Tabs/CollapsingTabs/CollapsingTabsBase.d.ts +1 -1
  53. package/lib/components/Tabs/CollapsingTabs/CollapsingTabsBase.js +1 -1
  54. package/lib/components/VersionSwitcher.d.ts +1 -1
  55. package/lib/components/common/CheckboxList.d.ts +1 -1
  56. package/lib/components/common/ClearButton/ClearButton.d.ts +3 -0
  57. package/lib/components/common/ClearButton/ClearButton.js +2 -0
  58. package/lib/components/common/ClearButton/index.d.ts +2 -0
  59. package/lib/components/common/ClearButton/index.js +2 -0
  60. package/lib/components/common/ClearButton/styled.d.ts +2 -0
  61. package/lib/components/common/ClearButton/styled.js +2 -0
  62. package/lib/components/common/ClearButton/types.d.ts +6 -0
  63. package/lib/components/common/ClearButton/types.js +2 -0
  64. package/lib/components/common/Dropdown/Dropdown.js +1 -1
  65. package/lib/components/common/Dropdown/styled.js +1 -1
  66. package/lib/components/common/Dropdown/types.d.ts +2 -0
  67. package/lib/components/common/FileUpload/FileUpload.d.ts +3 -2
  68. package/lib/components/common/FileUpload/FileUpload.js +1 -1
  69. package/lib/components/common/TextField.js +1 -1
  70. package/lib/components/console/ActionPanel.js +1 -1
  71. package/lib/components/console/AuthPanel/AuthPanel.d.ts +1 -1
  72. package/lib/components/console/AuthPanel/AuthPanel.js +1 -1
  73. package/lib/components/console/AuthPanel/types.d.ts +1 -1
  74. package/lib/components/console/CodemirrorInput.d.ts +16 -12
  75. package/lib/components/console/CodemirrorInput.js +1 -1
  76. package/lib/components/console/Console.d.ts +4 -10
  77. package/lib/components/console/Console.js +1 -1
  78. package/lib/components/console/ConsoleLazy.js +1 -1
  79. package/lib/components/console/OAuth2Flow.d.ts +2 -1
  80. package/lib/components/console/OAuth2Flow.js +1 -1
  81. package/lib/components/console/OAuth2TokenInput.d.ts +2 -1
  82. package/lib/components/console/OAuth2TokenInput.js +1 -1
  83. package/lib/components/console/OpenIDConnect.d.ts +4 -1
  84. package/lib/components/console/OpenIDConnect.js +1 -1
  85. package/lib/components/console/ParameterArray.d.ts +10 -0
  86. package/lib/components/console/ParameterArray.js +2 -0
  87. package/lib/components/console/ParameterDropdown.js +1 -1
  88. package/lib/components/console/RequestBody/RequestBody.d.ts +3 -0
  89. package/lib/components/console/RequestBody/RequestBody.js +2 -0
  90. package/lib/components/console/RequestBody/index.d.ts +2 -0
  91. package/lib/components/console/RequestBody/index.js +2 -0
  92. package/lib/components/console/RequestBody/types.d.ts +10 -0
  93. package/lib/components/console/RequestBody/types.js +2 -0
  94. package/lib/components/console/RequestBodyForm.d.ts +3 -2
  95. package/lib/components/console/RequestBodyForm.js +1 -1
  96. package/lib/components/console/ServersDropdown/ServersDropdown.d.ts +3 -0
  97. package/lib/components/console/ServersDropdown/ServersDropdown.js +2 -0
  98. package/lib/components/console/ServersDropdown/index.d.ts +1 -0
  99. package/lib/components/console/ServersDropdown/index.js +2 -0
  100. package/lib/components/console/ServersDropdown/types.d.ts +5 -0
  101. package/lib/components/console/ServersDropdown/types.js +2 -0
  102. package/lib/components/console/TryItPanel.d.ts +7 -0
  103. package/lib/components/console/TryItPanel.js +2 -0
  104. package/lib/components/console/codemirror-helpers.js +1 -1
  105. package/lib/components/console/styled.d.ts +7 -4
  106. package/lib/components/console/styled.js +1 -1
  107. package/lib/components/console/utils.d.ts +11 -1
  108. package/lib/components/console/utils.js +1 -1
  109. package/lib/components/index.d.ts +1 -0
  110. package/lib/components/index.js +1 -1
  111. package/lib/components/pluggable/PullRight.js +1 -1
  112. package/lib/components/pluggable/RedocResponse.js +1 -1
  113. package/lib/components/shared/index.d.ts +0 -1
  114. package/lib/components/shared/index.js +1 -1
  115. package/lib/components/types.d.ts +1 -1
  116. package/lib/hooks/index.d.ts +1 -0
  117. package/lib/hooks/index.js +1 -1
  118. package/lib/hooks/useDimensions.d.ts +1 -0
  119. package/lib/hooks/useDimensions.js +2 -0
  120. package/lib/index.d.ts +1 -1
  121. package/lib/models/file-upload.d.ts +0 -5
  122. package/lib/models/file-upload.js +1 -1
  123. package/lib/oauth2-redirect-page/handler/helpers.d.ts +1 -0
  124. package/lib/oauth2-redirect-page/handler/helpers.js +1 -1
  125. package/lib/redoc-lib/src/common-elements/LinkToField.js +1 -1
  126. package/lib/redoc-lib/src/common-elements/fields-layout.js +1 -1
  127. package/lib/redoc-lib/src/common-elements/fields.d.ts +1 -0
  128. package/lib/redoc-lib/src/common-elements/fields.js +1 -1
  129. package/lib/redoc-lib/src/common-elements/headers.d.ts +4 -1
  130. package/lib/redoc-lib/src/common-elements/headers.js +1 -1
  131. package/lib/redoc-lib/src/common-elements/icons.d.ts +1 -0
  132. package/lib/redoc-lib/src/common-elements/linkify.d.ts +2 -1
  133. package/lib/redoc-lib/src/common-elements/linkify.js +1 -1
  134. package/lib/redoc-lib/src/common-elements/panels.js +1 -1
  135. package/lib/redoc-lib/src/common-elements/perfect-scrollbar.d.ts +1 -1
  136. package/lib/redoc-lib/src/components/ApiInfo/ApiInfo.d.ts +1 -1
  137. package/lib/redoc-lib/src/components/ApiInfo/ApiInfo.js +1 -1
  138. package/lib/redoc-lib/src/components/CallbackSamples/CallbackReqSamples.js +1 -1
  139. package/lib/redoc-lib/src/components/CallbackSamples/CallbackSamples.js +1 -1
  140. package/lib/redoc-lib/src/components/Callbacks/CallbackDetails.js +1 -1
  141. package/lib/redoc-lib/src/components/Callbacks/CallbackOperation.js +1 -1
  142. package/lib/redoc-lib/src/components/Callbacks/CallbacksList.js +1 -1
  143. package/lib/redoc-lib/src/components/ContentItem/ContentItem.d.ts +10 -0
  144. package/lib/redoc-lib/src/components/ContentItem/ContentItem.js +2 -0
  145. package/lib/redoc-lib/src/components/ContentItem/index.d.ts +1 -0
  146. package/lib/redoc-lib/src/components/ContentItem/index.js +2 -0
  147. package/lib/redoc-lib/src/components/ContentItems/ContentItems.d.ts +3 -22
  148. package/lib/redoc-lib/src/components/ContentItems/ContentItems.js +1 -1
  149. package/lib/redoc-lib/src/components/ContentItems/Skeleton.d.ts +2 -0
  150. package/lib/redoc-lib/src/components/ContentItems/Skeleton.js +2 -0
  151. package/lib/redoc-lib/src/components/ContentItems/index.d.ts +1 -0
  152. package/lib/redoc-lib/src/components/ContentItems/index.js +2 -0
  153. package/lib/redoc-lib/src/components/ErrorBoundary.d.ts +1 -1
  154. package/lib/redoc-lib/src/components/ExternalDocumentation/ExternalDocumentation.js +1 -1
  155. package/lib/redoc-lib/src/components/Fields/EnumValues.js +1 -1
  156. package/lib/redoc-lib/src/components/Fields/Extensions.d.ts +1 -1
  157. package/lib/redoc-lib/src/components/Fields/Extensions.js +1 -1
  158. package/lib/redoc-lib/src/components/Fields/Field.d.ts +1 -1
  159. package/lib/redoc-lib/src/components/Fields/Field.js +1 -1
  160. package/lib/redoc-lib/src/components/Fields/FieldDetails.js +1 -1
  161. package/lib/redoc-lib/src/components/GenericChildrenSwitcher/GenericChildrenSwitcher.js +1 -1
  162. package/lib/redoc-lib/src/components/Loading/Loading.js +1 -1
  163. package/lib/redoc-lib/src/components/Loading/{Spinner.svg.d.ts → Spinner.d.ts} +0 -0
  164. package/lib/redoc-lib/src/components/Loading/{Spinner.svg.js → Spinner.js} +1 -1
  165. package/lib/redoc-lib/src/components/Markdown/AdvancedMarkdown.d.ts +3 -13
  166. package/lib/redoc-lib/src/components/Markdown/AdvancedMarkdown.js +1 -1
  167. package/lib/redoc-lib/src/components/Markdown/Markdown.d.ts +1 -13
  168. package/lib/redoc-lib/src/components/Markdown/Markdown.js +1 -1
  169. package/{lib-esm/redoc-lib/src/components/Markdown/SanitizedMdBlock.d.ts → lib/redoc-lib/src/components/Markdown/SanitizedMarkdownHTML.d.ts} +1 -1
  170. package/lib/redoc-lib/src/components/Markdown/SanitizedMarkdownHTML.js +2 -0
  171. package/lib/redoc-lib/src/components/Markdown/index.d.ts +4 -0
  172. package/lib/redoc-lib/src/components/Markdown/index.js +2 -0
  173. package/lib/redoc-lib/src/components/Markdown/{styled.elements.d.ts → styled.d.ts} +8 -2
  174. package/lib/redoc-lib/src/components/Markdown/{styled.elements.js → styled.js} +2 -2
  175. package/lib/redoc-lib/src/components/Markdown/types.d.ts +17 -0
  176. package/lib/redoc-lib/src/components/Markdown/types.js +2 -0
  177. package/lib/redoc-lib/src/components/MediaTypeSwitch/MediaTypesSwitch.js +1 -1
  178. package/lib/redoc-lib/src/components/Operation/Operation.js +1 -1
  179. package/lib/redoc-lib/src/components/Operation/index.d.ts +1 -0
  180. package/lib/redoc-lib/src/components/Operation/index.js +2 -0
  181. package/lib/redoc-lib/src/components/OperationItem/OperationItem.d.ts +7 -0
  182. package/lib/redoc-lib/src/components/OperationItem/OperationItem.js +2 -0
  183. package/lib/redoc-lib/src/components/OperationItem/index.d.ts +1 -0
  184. package/lib/redoc-lib/src/components/OperationItem/index.js +2 -0
  185. package/lib/redoc-lib/src/components/OptionsProvider.d.ts +1 -0
  186. package/lib/redoc-lib/src/components/OptionsProvider.js +1 -1
  187. package/lib/redoc-lib/src/components/Parameters/Parameters.js +1 -1
  188. package/lib/redoc-lib/src/components/PayloadSamples/Example.d.ts +1 -5
  189. package/lib/redoc-lib/src/components/PayloadSamples/Example.js +1 -1
  190. package/lib/redoc-lib/src/components/PayloadSamples/ExampleValue.d.ts +2 -5
  191. package/lib/redoc-lib/src/components/PayloadSamples/ExampleValue.js +1 -1
  192. package/lib/redoc-lib/src/components/PayloadSamples/MediaTypeSamples.d.ts +2 -7
  193. package/lib/redoc-lib/src/components/PayloadSamples/MediaTypeSamples.js +1 -1
  194. package/lib/redoc-lib/src/components/PayloadSamples/PayloadSamples.d.ts +1 -7
  195. package/lib/redoc-lib/src/components/PayloadSamples/PayloadSamples.js +1 -1
  196. package/lib/redoc-lib/src/components/PayloadSamples/index.d.ts +5 -0
  197. package/lib/redoc-lib/src/components/PayloadSamples/index.js +2 -0
  198. package/lib/redoc-lib/src/components/PayloadSamples/types.d.ts +23 -0
  199. package/lib/redoc-lib/src/components/PayloadSamples/types.js +2 -0
  200. package/lib/redoc-lib/src/components/PayloadSamples/{exernalExampleHook.d.ts → useExternalExample.d.ts} +0 -0
  201. package/lib/redoc-lib/src/components/PayloadSamples/{exernalExampleHook.js → useExternalExample.js} +1 -1
  202. package/lib/redoc-lib/src/components/RenderHook.d.ts +7 -0
  203. package/lib/redoc-lib/src/components/RenderHook.js +2 -0
  204. package/lib/redoc-lib/src/components/RequestSamples/CodeSample.js +1 -1
  205. package/lib/redoc-lib/src/components/RequestSamples/RequestSamples.d.ts +1 -1
  206. package/lib/redoc-lib/src/components/RequestSamples/RequestSamples.js +1 -1
  207. package/lib/redoc-lib/src/components/RequestSamples/languageSwitchEvent.d.ts +1 -1
  208. package/lib/redoc-lib/src/components/ResponseSamples/ResponseSamples.js +1 -1
  209. package/lib/redoc-lib/src/components/Responses/Response.d.ts +2 -5
  210. package/lib/redoc-lib/src/components/Responses/Response.js +1 -1
  211. package/lib/redoc-lib/src/components/Responses/ResponseDetails.d.ts +3 -8
  212. package/lib/redoc-lib/src/components/Responses/ResponseDetails.js +1 -1
  213. package/lib/redoc-lib/src/components/Responses/ResponseHeaders.d.ts +3 -9
  214. package/lib/redoc-lib/src/components/Responses/ResponseHeaders.js +1 -1
  215. package/lib/redoc-lib/src/components/Responses/ResponseSummary.d.ts +1 -5
  216. package/lib/redoc-lib/src/components/Responses/ResponseSummary.js +1 -1
  217. package/lib/redoc-lib/src/components/Responses/ResponsesList.d.ts +3 -8
  218. package/lib/redoc-lib/src/components/Responses/ResponsesList.js +1 -1
  219. package/lib/redoc-lib/src/components/Responses/index.d.ts +1 -0
  220. package/lib/redoc-lib/src/components/Responses/index.js +2 -0
  221. package/lib/redoc-lib/src/components/Responses/styled.d.ts +3 -0
  222. package/lib/redoc-lib/src/components/Responses/styled.js +2 -0
  223. package/lib/redoc-lib/src/components/Responses/types.d.ts +12 -0
  224. package/lib/redoc-lib/src/components/Responses/types.js +2 -0
  225. package/lib/redoc-lib/src/components/Schema/ArraySchema.js +1 -1
  226. package/lib/redoc-lib/src/components/Schema/DiscriminatorDropdown.js +1 -1
  227. package/lib/redoc-lib/src/components/Schema/ObjectSchema.d.ts +2 -7
  228. package/lib/redoc-lib/src/components/Schema/ObjectSchema.js +1 -1
  229. package/lib/redoc-lib/src/components/Schema/OneOfSchema.js +1 -1
  230. package/lib/redoc-lib/src/components/Schema/RecursiveSchema.d.ts +3 -0
  231. package/lib/redoc-lib/src/components/Schema/RecursiveSchema.js +2 -0
  232. package/lib/redoc-lib/src/components/Schema/Schema.js +1 -1
  233. package/lib/redoc-lib/src/components/SchemaDefinition/SchemaDefinition.js +1 -1
  234. package/lib/redoc-lib/src/components/SearchBox/SearchBox.d.ts +2 -3
  235. package/lib/redoc-lib/src/components/SearchBox/SearchBox.js +1 -1
  236. package/lib/redoc-lib/src/components/SectionItem/SectionItem.d.ts +7 -0
  237. package/lib/redoc-lib/src/components/SectionItem/SectionItem.js +2 -0
  238. package/lib/redoc-lib/src/components/SectionItem/index.d.ts +1 -0
  239. package/lib/redoc-lib/src/components/SectionItem/index.js +2 -0
  240. package/lib/redoc-lib/src/components/SecurityRequirement/RequiredScopesRow.d.ts +4 -0
  241. package/lib/redoc-lib/src/components/SecurityRequirement/RequiredScopesRow.js +2 -0
  242. package/lib/redoc-lib/src/components/SecurityRequirement/SecurityDefs.d.ts +8 -0
  243. package/lib/redoc-lib/src/components/SecurityRequirement/SecurityDefs.js +2 -0
  244. package/lib/redoc-lib/src/components/SecurityRequirement/SecurityRequirement.d.ts +9 -10
  245. package/lib/redoc-lib/src/components/SecurityRequirement/SecurityRequirement.js +1 -1
  246. package/lib/redoc-lib/src/components/SecurityRequirement/SecurityRequirementElement.d.ts +8 -0
  247. package/lib/redoc-lib/src/components/SecurityRequirement/SecurityRequirementElement.js +2 -0
  248. package/lib/redoc-lib/src/components/SecurityRequirement/SecurityRequirementPanelDescription.d.ts +8 -0
  249. package/lib/redoc-lib/src/components/SecurityRequirement/SecurityRequirementPanelDescription.js +2 -0
  250. package/lib/redoc-lib/src/components/SecuritySchemes/SecuritySchemes.d.ts +3 -16
  251. package/lib/redoc-lib/src/components/SecuritySchemes/SecuritySchemes.js +1 -1
  252. package/lib/redoc-lib/src/components/SecuritySchemes/helpers.d.ts +34 -0
  253. package/lib/redoc-lib/src/components/SecuritySchemes/helpers.js +2 -0
  254. package/lib/redoc-lib/src/components/SecuritySchemes/types.d.ts +7 -0
  255. package/lib/redoc-lib/src/components/SecuritySchemes/types.js +2 -0
  256. package/lib/redoc-lib/src/components/SeeMore/SeeMore.d.ts +7 -0
  257. package/lib/redoc-lib/src/components/SeeMore/SeeMore.js +2 -0
  258. package/lib/redoc-lib/src/components/SideMenu/MenuItem.js +1 -1
  259. package/lib/redoc-lib/src/components/SideMenu/MenuItems.js +1 -1
  260. package/lib/redoc-lib/src/components/SideMenu/SideMenu.d.ts +1 -1
  261. package/lib/redoc-lib/src/components/SideMenu/SideMenu.js +1 -1
  262. package/lib/redoc-lib/src/components/SideMenu/styled.elements.d.ts +2 -2
  263. package/lib/redoc-lib/src/components/SideMenu/styled.elements.js +1 -1
  264. package/lib/redoc-lib/src/components/StickySidebar/StickyResponsiveSidebar.d.ts +2 -2
  265. package/lib/redoc-lib/src/components/StoreBuilder.d.ts +3 -3
  266. package/lib/redoc-lib/src/components/StoreBuilder.js +1 -1
  267. package/lib/redoc-lib/src/components/index.d.ts +3 -7
  268. package/lib/redoc-lib/src/components/index.js +1 -1
  269. package/lib/redoc-lib/src/index.d.ts +0 -1
  270. package/lib/redoc-lib/src/services/Labels.d.ts +1 -28
  271. package/lib/redoc-lib/src/services/MarkdownRenderer.d.ts +2 -17
  272. package/lib/redoc-lib/src/services/MarkdownRenderer.js +1 -1
  273. package/lib/redoc-lib/src/services/MenuBuilder.d.ts +17 -25
  274. package/lib/redoc-lib/src/services/MenuBuilder.js +1 -1
  275. package/lib/redoc-lib/src/services/OpenAPIParser.d.ts +10 -17
  276. package/lib/redoc-lib/src/services/OpenAPIParser.js +1 -1
  277. package/lib/redoc-lib/src/services/RedocNormalizedOptions.d.ts +10 -113
  278. package/lib/redoc-lib/src/services/RedocNormalizedOptions.js +1 -1
  279. package/lib/redoc-lib/src/services/SearchStore.d.ts +1 -2
  280. package/lib/redoc-lib/src/services/SearchStore.js +1 -1
  281. package/lib/redoc-lib/src/services/SearchWorker.worker.d.ts +1 -9
  282. package/lib/redoc-lib/src/services/SpecStore.d.ts +2 -2
  283. package/lib/redoc-lib/src/services/constants.d.ts +4 -0
  284. package/lib/redoc-lib/src/services/constants.js +1 -1
  285. package/lib/redoc-lib/src/services/index.d.ts +11 -11
  286. package/lib/redoc-lib/src/services/index.js +1 -1
  287. package/lib/redoc-lib/src/services/models/ApiInfo.js +1 -1
  288. package/lib/redoc-lib/src/services/models/Callback.d.ts +1 -1
  289. package/lib/redoc-lib/src/services/models/Callback.js +1 -1
  290. package/lib/redoc-lib/src/services/models/Example.d.ts +4 -1
  291. package/lib/redoc-lib/src/services/models/Example.js +1 -1
  292. package/lib/redoc-lib/src/services/models/Field.d.ts +1 -1
  293. package/lib/redoc-lib/src/services/models/Field.js +1 -1
  294. package/lib/redoc-lib/src/services/models/Group.model.d.ts +2 -3
  295. package/lib/redoc-lib/src/services/models/Group.model.js +1 -1
  296. package/lib/redoc-lib/src/services/models/MediaContent.d.ts +1 -1
  297. package/lib/redoc-lib/src/services/models/MediaContent.js +1 -1
  298. package/lib/redoc-lib/src/services/models/MediaType.d.ts +2 -2
  299. package/lib/redoc-lib/src/services/models/MediaType.js +1 -1
  300. package/lib/redoc-lib/src/services/models/Operation.d.ts +12 -7
  301. package/lib/redoc-lib/src/services/models/Operation.js +1 -1
  302. package/lib/redoc-lib/src/services/models/RequestBody.d.ts +1 -1
  303. package/lib/redoc-lib/src/services/models/RequestBody.js +1 -1
  304. package/lib/redoc-lib/src/services/models/Response.d.ts +1 -1
  305. package/lib/redoc-lib/src/services/models/Response.js +1 -1
  306. package/lib/redoc-lib/src/services/models/Schema.d.ts +5 -5
  307. package/lib/redoc-lib/src/services/models/Schema.js +1 -1
  308. package/lib/redoc-lib/src/services/models/SecurityRequirement.js +1 -1
  309. package/lib/redoc-lib/src/services/models/SecuritySchemes.js +1 -1
  310. package/lib/redoc-lib/src/services/models/Webhook.d.ts +1 -1
  311. package/lib/redoc-lib/src/services/models/Webhook.js +1 -1
  312. package/lib/redoc-lib/src/services/models/index.d.ts +0 -1
  313. package/lib/redoc-lib/src/services/models/index.js +1 -1
  314. package/lib/redoc-lib/src/services/types.d.ts +218 -0
  315. package/lib/redoc-lib/src/services/types.js +2 -0
  316. package/lib/redoc-lib/src/types/open-api.d.ts +22 -2
  317. package/lib/redoc-lib/src/utils/argValuesHelpers.d.ts +1 -1
  318. package/lib/redoc-lib/src/utils/argValuesHelpers.js +1 -1
  319. package/lib/redoc-lib/src/utils/helpers.d.ts +3 -1
  320. package/lib/redoc-lib/src/utils/helpers.js +1 -1
  321. package/lib/redoc-lib/src/utils/openapi.d.ts +3 -4
  322. package/lib/redoc-lib/src/utils/openapi.js +1 -1
  323. package/lib/redoc-lib/src/utils/string.d.ts +1 -0
  324. package/lib/redoc-lib/src/utils/string.js +2 -0
  325. package/lib/services/OAuth2.d.ts +4 -2
  326. package/lib/services/OAuth2.js +1 -1
  327. package/lib/services/OpenIDConnect.d.ts +1 -1
  328. package/lib/services/ProMenu.js +1 -1
  329. package/lib/services/ProStore.d.ts +9 -7
  330. package/lib/services/ProStore.js +1 -1
  331. package/lib/services/SearchStore.d.ts +1 -1
  332. package/lib/services/VersionedSpecStore.d.ts +1 -1
  333. package/lib/services/VersionedSpecStore.js +1 -1
  334. package/lib/services/code-samples/generator.d.ts +1 -0
  335. package/lib/services/code-samples/generator.js +1 -1
  336. package/lib/services/code-samples/httpsnippet/index.js +1 -1
  337. package/lib/services/code-samples/httpsnippet/targets/csharp/httpclient.js +1 -1
  338. package/lib/services/code-samples/httpsnippet/targets/go/native.js +1 -1
  339. package/lib/services/code-samples/httpsnippet/targets/java/httpclient.js +1 -1
  340. package/lib/services/code-samples/httpsnippet/targets/java8/apachehttp.js +1 -1
  341. package/lib/services/code-samples/httpsnippet/targets/javascript/fetch.js +1 -1
  342. package/lib/services/code-samples/httpsnippet/targets/node/fetch.js +1 -1
  343. package/lib/services/code-samples/httpsnippet/targets/php/curl.js +1 -1
  344. package/lib/services/code-samples/httpsnippet/targets/python/requests.js +1 -1
  345. package/lib/services/code-samples/httpsnippet/targets/r/httr.js +1 -1
  346. package/lib/services/code-samples/httpsnippet/targets/ruby/native.js +1 -1
  347. package/lib/services/code-samples/httpsnippet/targets/shell/curl.js +1 -1
  348. package/lib/services/history/ProHashHistoryService.js +1 -1
  349. package/lib/services/utils.d.ts +2 -0
  350. package/lib/services/utils.js +1 -1
  351. package/lib/standalone.d.ts +1 -1
  352. package/lib/standalone.js +1 -1
  353. package/lib/types.d.ts +25 -0
  354. package/lib/types.js +2 -0
  355. package/lib/utils.d.ts +4 -13
  356. package/lib/utils.js +1 -1
  357. package/lib-esm/components/Endpoint/Endpoint.d.ts +1 -6
  358. package/lib-esm/components/Endpoint/Endpoint.js +1 -1
  359. package/lib-esm/components/Endpoint/ServerList.d.ts +2 -7
  360. package/lib-esm/components/Endpoint/ServerList.js +1 -1
  361. package/lib-esm/components/Endpoint/Summary.d.ts +1 -12
  362. package/lib-esm/components/Endpoint/Summary.js +1 -1
  363. package/lib-esm/components/Endpoint/index.d.ts +2 -1
  364. package/lib-esm/components/Endpoint/index.js +1 -1
  365. package/lib-esm/components/Endpoint/styled.d.ts +13 -0
  366. package/lib-esm/components/Endpoint/styled.js +2 -0
  367. package/lib-esm/components/Endpoint/types.d.ts +21 -0
  368. package/lib-esm/components/Endpoint/types.js +2 -0
  369. package/lib-esm/components/NextSectionButton.d.ts +6 -5
  370. package/lib-esm/components/NextSectionButton.js +1 -1
  371. package/lib-esm/components/OperationParameters/OperationParameters.d.ts +3 -0
  372. package/lib-esm/components/OperationParameters/OperationParameters.js +2 -0
  373. package/lib-esm/components/OperationParameters/index.d.ts +1 -0
  374. package/lib-esm/components/OperationParameters/index.js +2 -0
  375. package/lib-esm/components/{console/OperationParameters.d.ts → OperationParameters/types.d.ts} +5 -3
  376. package/lib-esm/components/OperationParameters/types.js +2 -0
  377. package/lib-esm/components/OperationParameters/utils.d.ts +7 -0
  378. package/lib-esm/components/OperationParameters/utils.js +2 -0
  379. package/lib-esm/components/Panel/Accordion.js +1 -1
  380. package/lib-esm/components/Panel/ContentPanel.js +1 -1
  381. package/lib-esm/components/Panel/Description.d.ts +1 -0
  382. package/lib-esm/components/Panel/Description.js +2 -0
  383. package/lib-esm/components/Panel/PanelComponent.d.ts +4 -2
  384. package/lib-esm/components/Panel/PanelComponent.js +1 -1
  385. package/lib-esm/components/Panel/ResponsePanel.js +1 -1
  386. package/lib-esm/components/Panel/Trigger.js +1 -1
  387. package/lib-esm/components/Panel/index.d.ts +1 -0
  388. package/lib-esm/components/Panel/index.js +1 -1
  389. package/lib-esm/components/ProProviders.d.ts +8 -2
  390. package/lib-esm/components/RedoclyReferenceDocs.d.ts +2 -7
  391. package/lib-esm/components/RedoclyReferenceDocs.js +1 -1
  392. package/lib-esm/components/RedoclyReferenceDocsMultiStandalone.d.ts +8 -0
  393. package/lib-esm/components/RedoclyReferenceDocsMultiStandalone.js +2 -0
  394. package/lib-esm/components/Samples/ExampleSwitch.d.ts +1 -2
  395. package/lib-esm/components/Samples/ExampleSwitch.js +1 -1
  396. package/lib-esm/components/Samples/SamplesTabs.d.ts +3 -1
  397. package/lib-esm/components/Samples/SamplesTabs.js +1 -1
  398. package/lib-esm/components/Samples/use-example-key.js +1 -1
  399. package/lib-esm/components/Search/ProSearchBox.js +1 -1
  400. package/lib-esm/components/StoreProvider.d.ts +1 -1
  401. package/lib-esm/components/StoreProvider.js +1 -1
  402. package/lib-esm/components/Tabs/CollapsingTabs/CollapsingTabs.js +1 -1
  403. package/lib-esm/components/Tabs/CollapsingTabs/CollapsingTabsBase.d.ts +1 -1
  404. package/lib-esm/components/Tabs/CollapsingTabs/CollapsingTabsBase.js +1 -1
  405. package/lib-esm/components/VersionSwitcher.d.ts +1 -1
  406. package/lib-esm/components/common/CheckboxList.d.ts +1 -1
  407. package/lib-esm/components/common/ClearButton/ClearButton.d.ts +3 -0
  408. package/lib-esm/components/common/ClearButton/ClearButton.js +2 -0
  409. package/lib-esm/components/common/ClearButton/index.d.ts +2 -0
  410. package/lib-esm/components/common/ClearButton/index.js +2 -0
  411. package/lib-esm/components/common/ClearButton/styled.d.ts +2 -0
  412. package/lib-esm/components/common/ClearButton/styled.js +2 -0
  413. package/lib-esm/components/common/ClearButton/types.d.ts +6 -0
  414. package/lib-esm/components/common/ClearButton/types.js +2 -0
  415. package/lib-esm/components/common/Dropdown/Dropdown.js +1 -1
  416. package/lib-esm/components/common/Dropdown/styled.js +1 -1
  417. package/lib-esm/components/common/Dropdown/types.d.ts +2 -0
  418. package/lib-esm/components/common/FileUpload/FileUpload.d.ts +3 -2
  419. package/lib-esm/components/common/FileUpload/FileUpload.js +1 -1
  420. package/lib-esm/components/common/TextField.js +1 -1
  421. package/lib-esm/components/console/ActionPanel.js +1 -1
  422. package/lib-esm/components/console/AuthPanel/AuthPanel.d.ts +1 -1
  423. package/lib-esm/components/console/AuthPanel/AuthPanel.js +1 -1
  424. package/lib-esm/components/console/AuthPanel/types.d.ts +1 -1
  425. package/lib-esm/components/console/CodemirrorInput.d.ts +16 -12
  426. package/lib-esm/components/console/CodemirrorInput.js +1 -1
  427. package/lib-esm/components/console/Console.d.ts +4 -10
  428. package/lib-esm/components/console/Console.js +1 -1
  429. package/lib-esm/components/console/ConsoleLazy.js +1 -1
  430. package/lib-esm/components/console/OAuth2Flow.d.ts +2 -1
  431. package/lib-esm/components/console/OAuth2Flow.js +1 -1
  432. package/lib-esm/components/console/OAuth2TokenInput.d.ts +2 -1
  433. package/lib-esm/components/console/OAuth2TokenInput.js +1 -1
  434. package/lib-esm/components/console/OpenIDConnect.d.ts +4 -1
  435. package/lib-esm/components/console/OpenIDConnect.js +1 -1
  436. package/lib-esm/components/console/ParameterArray.d.ts +10 -0
  437. package/lib-esm/components/console/ParameterArray.js +2 -0
  438. package/lib-esm/components/console/ParameterDropdown.js +1 -1
  439. package/lib-esm/components/console/RequestBody/RequestBody.d.ts +3 -0
  440. package/lib-esm/components/console/RequestBody/RequestBody.js +2 -0
  441. package/lib-esm/components/console/RequestBody/index.d.ts +2 -0
  442. package/lib-esm/components/console/RequestBody/index.js +2 -0
  443. package/lib-esm/components/console/RequestBody/types.d.ts +10 -0
  444. package/lib-esm/components/console/RequestBody/types.js +2 -0
  445. package/lib-esm/components/console/RequestBodyForm.d.ts +3 -2
  446. package/lib-esm/components/console/RequestBodyForm.js +1 -1
  447. package/lib-esm/components/console/ServersDropdown/ServersDropdown.d.ts +3 -0
  448. package/lib-esm/components/console/ServersDropdown/ServersDropdown.js +2 -0
  449. package/lib-esm/components/console/ServersDropdown/index.d.ts +1 -0
  450. package/lib-esm/components/console/ServersDropdown/index.js +2 -0
  451. package/lib-esm/components/console/ServersDropdown/types.d.ts +5 -0
  452. package/lib-esm/components/console/ServersDropdown/types.js +2 -0
  453. package/lib-esm/components/console/TryItPanel.d.ts +7 -0
  454. package/lib-esm/components/console/TryItPanel.js +2 -0
  455. package/lib-esm/components/console/codemirror-helpers.js +1 -1
  456. package/lib-esm/components/console/styled.d.ts +7 -4
  457. package/lib-esm/components/console/styled.js +1 -1
  458. package/lib-esm/components/console/utils.d.ts +11 -1
  459. package/lib-esm/components/console/utils.js +1 -1
  460. package/lib-esm/components/index.d.ts +1 -0
  461. package/lib-esm/components/index.js +1 -1
  462. package/lib-esm/components/pluggable/PullRight.js +1 -1
  463. package/lib-esm/components/pluggable/RedocResponse.js +1 -1
  464. package/lib-esm/components/shared/index.d.ts +0 -1
  465. package/lib-esm/components/shared/index.js +1 -1
  466. package/lib-esm/components/types.d.ts +1 -1
  467. package/lib-esm/hooks/index.d.ts +1 -0
  468. package/lib-esm/hooks/index.js +1 -1
  469. package/lib-esm/hooks/useDimensions.d.ts +1 -0
  470. package/lib-esm/hooks/useDimensions.js +2 -0
  471. package/lib-esm/index.d.ts +1 -1
  472. package/lib-esm/models/file-upload.d.ts +0 -5
  473. package/lib-esm/models/file-upload.js +1 -1
  474. package/lib-esm/oauth2-redirect-page/handler/helpers.d.ts +1 -0
  475. package/lib-esm/oauth2-redirect-page/handler/helpers.js +1 -1
  476. package/lib-esm/redoc-lib/src/common-elements/LinkToField.js +1 -1
  477. package/lib-esm/redoc-lib/src/common-elements/fields-layout.js +1 -1
  478. package/lib-esm/redoc-lib/src/common-elements/fields.d.ts +1 -0
  479. package/lib-esm/redoc-lib/src/common-elements/fields.js +1 -1
  480. package/lib-esm/redoc-lib/src/common-elements/headers.d.ts +4 -1
  481. package/lib-esm/redoc-lib/src/common-elements/headers.js +1 -1
  482. package/lib-esm/redoc-lib/src/common-elements/icons.d.ts +1 -0
  483. package/lib-esm/redoc-lib/src/common-elements/linkify.d.ts +2 -1
  484. package/lib-esm/redoc-lib/src/common-elements/linkify.js +1 -1
  485. package/lib-esm/redoc-lib/src/common-elements/panels.js +1 -1
  486. package/lib-esm/redoc-lib/src/common-elements/perfect-scrollbar.d.ts +1 -1
  487. package/lib-esm/redoc-lib/src/components/ApiInfo/ApiInfo.d.ts +1 -1
  488. package/lib-esm/redoc-lib/src/components/ApiInfo/ApiInfo.js +1 -1
  489. package/lib-esm/redoc-lib/src/components/CallbackSamples/CallbackReqSamples.js +1 -1
  490. package/lib-esm/redoc-lib/src/components/CallbackSamples/CallbackSamples.js +1 -1
  491. package/lib-esm/redoc-lib/src/components/Callbacks/CallbackDetails.js +1 -1
  492. package/lib-esm/redoc-lib/src/components/Callbacks/CallbackOperation.js +1 -1
  493. package/lib-esm/redoc-lib/src/components/Callbacks/CallbacksList.js +1 -1
  494. package/lib-esm/redoc-lib/src/components/ContentItem/ContentItem.d.ts +10 -0
  495. package/lib-esm/redoc-lib/src/components/ContentItem/ContentItem.js +2 -0
  496. package/lib-esm/redoc-lib/src/components/ContentItem/index.d.ts +1 -0
  497. package/lib-esm/redoc-lib/src/components/ContentItem/index.js +2 -0
  498. package/lib-esm/redoc-lib/src/components/ContentItems/ContentItems.d.ts +3 -22
  499. package/lib-esm/redoc-lib/src/components/ContentItems/ContentItems.js +1 -1
  500. package/lib-esm/redoc-lib/src/components/ContentItems/Skeleton.d.ts +2 -0
  501. package/lib-esm/redoc-lib/src/components/ContentItems/Skeleton.js +2 -0
  502. package/lib-esm/redoc-lib/src/components/ContentItems/index.d.ts +1 -0
  503. package/lib-esm/redoc-lib/src/components/ContentItems/index.js +2 -0
  504. package/lib-esm/redoc-lib/src/components/ErrorBoundary.d.ts +1 -1
  505. package/lib-esm/redoc-lib/src/components/ExternalDocumentation/ExternalDocumentation.js +1 -1
  506. package/lib-esm/redoc-lib/src/components/Fields/EnumValues.js +1 -1
  507. package/lib-esm/redoc-lib/src/components/Fields/Extensions.d.ts +1 -1
  508. package/lib-esm/redoc-lib/src/components/Fields/Extensions.js +1 -1
  509. package/lib-esm/redoc-lib/src/components/Fields/Field.d.ts +1 -1
  510. package/lib-esm/redoc-lib/src/components/Fields/Field.js +1 -1
  511. package/lib-esm/redoc-lib/src/components/Fields/FieldDetails.js +1 -1
  512. package/lib-esm/redoc-lib/src/components/GenericChildrenSwitcher/GenericChildrenSwitcher.js +1 -1
  513. package/lib-esm/redoc-lib/src/components/Loading/Loading.js +1 -1
  514. package/lib-esm/redoc-lib/src/components/Loading/{Spinner.svg.d.ts → Spinner.d.ts} +0 -0
  515. package/lib-esm/redoc-lib/src/components/Loading/{Spinner.svg.js → Spinner.js} +1 -1
  516. package/lib-esm/redoc-lib/src/components/Markdown/AdvancedMarkdown.d.ts +3 -13
  517. package/lib-esm/redoc-lib/src/components/Markdown/AdvancedMarkdown.js +1 -1
  518. package/lib-esm/redoc-lib/src/components/Markdown/Markdown.d.ts +1 -13
  519. package/lib-esm/redoc-lib/src/components/Markdown/Markdown.js +1 -1
  520. package/{lib/redoc-lib/src/components/Markdown/SanitizedMdBlock.d.ts → lib-esm/redoc-lib/src/components/Markdown/SanitizedMarkdownHTML.d.ts} +1 -1
  521. package/lib-esm/redoc-lib/src/components/Markdown/SanitizedMarkdownHTML.js +2 -0
  522. package/lib-esm/redoc-lib/src/components/Markdown/index.d.ts +4 -0
  523. package/lib-esm/redoc-lib/src/components/Markdown/index.js +2 -0
  524. package/lib-esm/redoc-lib/src/components/Markdown/{styled.elements.d.ts → styled.d.ts} +8 -2
  525. package/lib-esm/redoc-lib/src/components/Markdown/{styled.elements.js → styled.js} +2 -2
  526. package/lib-esm/redoc-lib/src/components/Markdown/types.d.ts +17 -0
  527. package/lib-esm/redoc-lib/src/components/Markdown/types.js +2 -0
  528. package/lib-esm/redoc-lib/src/components/MediaTypeSwitch/MediaTypesSwitch.js +1 -1
  529. package/lib-esm/redoc-lib/src/components/Operation/Operation.js +1 -1
  530. package/lib-esm/redoc-lib/src/components/Operation/index.d.ts +1 -0
  531. package/lib-esm/redoc-lib/src/components/Operation/index.js +2 -0
  532. package/lib-esm/redoc-lib/src/components/OperationItem/OperationItem.d.ts +7 -0
  533. package/lib-esm/redoc-lib/src/components/OperationItem/OperationItem.js +2 -0
  534. package/lib-esm/redoc-lib/src/components/OperationItem/index.d.ts +1 -0
  535. package/lib-esm/redoc-lib/src/components/OperationItem/index.js +2 -0
  536. package/lib-esm/redoc-lib/src/components/OptionsProvider.d.ts +1 -0
  537. package/lib-esm/redoc-lib/src/components/OptionsProvider.js +1 -1
  538. package/lib-esm/redoc-lib/src/components/Parameters/Parameters.js +1 -1
  539. package/lib-esm/redoc-lib/src/components/PayloadSamples/Example.d.ts +1 -5
  540. package/lib-esm/redoc-lib/src/components/PayloadSamples/Example.js +1 -1
  541. package/lib-esm/redoc-lib/src/components/PayloadSamples/ExampleValue.d.ts +2 -5
  542. package/lib-esm/redoc-lib/src/components/PayloadSamples/ExampleValue.js +1 -1
  543. package/lib-esm/redoc-lib/src/components/PayloadSamples/MediaTypeSamples.d.ts +2 -7
  544. package/lib-esm/redoc-lib/src/components/PayloadSamples/MediaTypeSamples.js +1 -1
  545. package/lib-esm/redoc-lib/src/components/PayloadSamples/PayloadSamples.d.ts +1 -7
  546. package/lib-esm/redoc-lib/src/components/PayloadSamples/PayloadSamples.js +1 -1
  547. package/lib-esm/redoc-lib/src/components/PayloadSamples/index.d.ts +5 -0
  548. package/lib-esm/redoc-lib/src/components/PayloadSamples/index.js +2 -0
  549. package/lib-esm/redoc-lib/src/components/PayloadSamples/types.d.ts +23 -0
  550. package/lib-esm/redoc-lib/src/components/PayloadSamples/types.js +2 -0
  551. package/lib-esm/redoc-lib/src/components/PayloadSamples/{exernalExampleHook.d.ts → useExternalExample.d.ts} +0 -0
  552. package/lib-esm/redoc-lib/src/components/PayloadSamples/{exernalExampleHook.js → useExternalExample.js} +1 -1
  553. package/lib-esm/redoc-lib/src/components/RenderHook.d.ts +7 -0
  554. package/lib-esm/redoc-lib/src/components/RenderHook.js +2 -0
  555. package/lib-esm/redoc-lib/src/components/RequestSamples/CodeSample.js +1 -1
  556. package/lib-esm/redoc-lib/src/components/RequestSamples/RequestSamples.d.ts +1 -1
  557. package/lib-esm/redoc-lib/src/components/RequestSamples/RequestSamples.js +1 -1
  558. package/lib-esm/redoc-lib/src/components/RequestSamples/languageSwitchEvent.d.ts +1 -1
  559. package/lib-esm/redoc-lib/src/components/ResponseSamples/ResponseSamples.js +1 -1
  560. package/lib-esm/redoc-lib/src/components/Responses/Response.d.ts +2 -5
  561. package/lib-esm/redoc-lib/src/components/Responses/Response.js +1 -1
  562. package/lib-esm/redoc-lib/src/components/Responses/ResponseDetails.d.ts +3 -8
  563. package/lib-esm/redoc-lib/src/components/Responses/ResponseDetails.js +1 -1
  564. package/lib-esm/redoc-lib/src/components/Responses/ResponseHeaders.d.ts +3 -9
  565. package/lib-esm/redoc-lib/src/components/Responses/ResponseHeaders.js +1 -1
  566. package/lib-esm/redoc-lib/src/components/Responses/ResponseSummary.d.ts +1 -5
  567. package/lib-esm/redoc-lib/src/components/Responses/ResponseSummary.js +1 -1
  568. package/lib-esm/redoc-lib/src/components/Responses/ResponsesList.d.ts +3 -8
  569. package/lib-esm/redoc-lib/src/components/Responses/ResponsesList.js +1 -1
  570. package/lib-esm/redoc-lib/src/components/Responses/index.d.ts +1 -0
  571. package/lib-esm/redoc-lib/src/components/Responses/index.js +2 -0
  572. package/lib-esm/redoc-lib/src/components/Responses/styled.d.ts +3 -0
  573. package/lib-esm/redoc-lib/src/components/Responses/styled.js +2 -0
  574. package/lib-esm/redoc-lib/src/components/Responses/types.d.ts +12 -0
  575. package/lib-esm/redoc-lib/src/components/Responses/types.js +2 -0
  576. package/lib-esm/redoc-lib/src/components/Schema/ArraySchema.js +1 -1
  577. package/lib-esm/redoc-lib/src/components/Schema/DiscriminatorDropdown.js +1 -1
  578. package/lib-esm/redoc-lib/src/components/Schema/ObjectSchema.d.ts +2 -7
  579. package/lib-esm/redoc-lib/src/components/Schema/ObjectSchema.js +1 -1
  580. package/lib-esm/redoc-lib/src/components/Schema/OneOfSchema.js +1 -1
  581. package/lib-esm/redoc-lib/src/components/Schema/RecursiveSchema.d.ts +3 -0
  582. package/lib-esm/redoc-lib/src/components/Schema/RecursiveSchema.js +2 -0
  583. package/lib-esm/redoc-lib/src/components/Schema/Schema.js +1 -1
  584. package/lib-esm/redoc-lib/src/components/SchemaDefinition/SchemaDefinition.js +1 -1
  585. package/lib-esm/redoc-lib/src/components/SearchBox/SearchBox.d.ts +2 -3
  586. package/lib-esm/redoc-lib/src/components/SearchBox/SearchBox.js +1 -1
  587. package/lib-esm/redoc-lib/src/components/SectionItem/SectionItem.d.ts +7 -0
  588. package/lib-esm/redoc-lib/src/components/SectionItem/SectionItem.js +2 -0
  589. package/lib-esm/redoc-lib/src/components/SectionItem/index.d.ts +1 -0
  590. package/lib-esm/redoc-lib/src/components/SectionItem/index.js +2 -0
  591. package/lib-esm/redoc-lib/src/components/SecurityRequirement/RequiredScopesRow.d.ts +4 -0
  592. package/lib-esm/redoc-lib/src/components/SecurityRequirement/RequiredScopesRow.js +2 -0
  593. package/lib-esm/redoc-lib/src/components/SecurityRequirement/SecurityDefs.d.ts +8 -0
  594. package/lib-esm/redoc-lib/src/components/SecurityRequirement/SecurityDefs.js +2 -0
  595. package/lib-esm/redoc-lib/src/components/SecurityRequirement/SecurityRequirement.d.ts +9 -10
  596. package/lib-esm/redoc-lib/src/components/SecurityRequirement/SecurityRequirement.js +1 -1
  597. package/lib-esm/redoc-lib/src/components/SecurityRequirement/SecurityRequirementElement.d.ts +8 -0
  598. package/lib-esm/redoc-lib/src/components/SecurityRequirement/SecurityRequirementElement.js +2 -0
  599. package/lib-esm/redoc-lib/src/components/SecurityRequirement/SecurityRequirementPanelDescription.d.ts +8 -0
  600. package/lib-esm/redoc-lib/src/components/SecurityRequirement/SecurityRequirementPanelDescription.js +2 -0
  601. package/lib-esm/redoc-lib/src/components/SecuritySchemes/SecuritySchemes.d.ts +3 -16
  602. package/lib-esm/redoc-lib/src/components/SecuritySchemes/SecuritySchemes.js +1 -1
  603. package/lib-esm/redoc-lib/src/components/SecuritySchemes/helpers.d.ts +34 -0
  604. package/lib-esm/redoc-lib/src/components/SecuritySchemes/helpers.js +2 -0
  605. package/lib-esm/redoc-lib/src/components/SecuritySchemes/types.d.ts +7 -0
  606. package/lib-esm/redoc-lib/src/components/SecuritySchemes/types.js +2 -0
  607. package/lib-esm/redoc-lib/src/components/SeeMore/SeeMore.d.ts +7 -0
  608. package/lib-esm/redoc-lib/src/components/SeeMore/SeeMore.js +2 -0
  609. package/lib-esm/redoc-lib/src/components/SideMenu/MenuItem.js +1 -1
  610. package/lib-esm/redoc-lib/src/components/SideMenu/MenuItems.js +1 -1
  611. package/lib-esm/redoc-lib/src/components/SideMenu/SideMenu.d.ts +1 -1
  612. package/lib-esm/redoc-lib/src/components/SideMenu/SideMenu.js +1 -1
  613. package/lib-esm/redoc-lib/src/components/SideMenu/styled.elements.d.ts +2 -2
  614. package/lib-esm/redoc-lib/src/components/SideMenu/styled.elements.js +1 -1
  615. package/lib-esm/redoc-lib/src/components/StickySidebar/StickyResponsiveSidebar.d.ts +2 -2
  616. package/lib-esm/redoc-lib/src/components/StoreBuilder.d.ts +3 -3
  617. package/lib-esm/redoc-lib/src/components/StoreBuilder.js +1 -1
  618. package/lib-esm/redoc-lib/src/components/index.d.ts +3 -7
  619. package/lib-esm/redoc-lib/src/components/index.js +1 -1
  620. package/lib-esm/redoc-lib/src/index.d.ts +0 -1
  621. package/lib-esm/redoc-lib/src/services/Labels.d.ts +1 -28
  622. package/lib-esm/redoc-lib/src/services/MarkdownRenderer.d.ts +2 -17
  623. package/lib-esm/redoc-lib/src/services/MarkdownRenderer.js +1 -1
  624. package/lib-esm/redoc-lib/src/services/MenuBuilder.d.ts +17 -25
  625. package/lib-esm/redoc-lib/src/services/MenuBuilder.js +1 -1
  626. package/lib-esm/redoc-lib/src/services/OpenAPIParser.d.ts +10 -17
  627. package/lib-esm/redoc-lib/src/services/OpenAPIParser.js +1 -1
  628. package/lib-esm/redoc-lib/src/services/RedocNormalizedOptions.d.ts +10 -113
  629. package/lib-esm/redoc-lib/src/services/RedocNormalizedOptions.js +1 -1
  630. package/lib-esm/redoc-lib/src/services/SearchStore.d.ts +1 -2
  631. package/lib-esm/redoc-lib/src/services/SearchStore.js +1 -1
  632. package/lib-esm/redoc-lib/src/services/SearchWorker.worker.d.ts +1 -9
  633. package/lib-esm/redoc-lib/src/services/SpecStore.d.ts +2 -2
  634. package/lib-esm/redoc-lib/src/services/constants.d.ts +4 -0
  635. package/lib-esm/redoc-lib/src/services/constants.js +1 -1
  636. package/lib-esm/redoc-lib/src/services/index.d.ts +11 -11
  637. package/lib-esm/redoc-lib/src/services/index.js +1 -1
  638. package/lib-esm/redoc-lib/src/services/models/ApiInfo.js +1 -1
  639. package/lib-esm/redoc-lib/src/services/models/Callback.d.ts +1 -1
  640. package/lib-esm/redoc-lib/src/services/models/Callback.js +1 -1
  641. package/lib-esm/redoc-lib/src/services/models/Example.d.ts +4 -1
  642. package/lib-esm/redoc-lib/src/services/models/Example.js +1 -1
  643. package/lib-esm/redoc-lib/src/services/models/Field.d.ts +1 -1
  644. package/lib-esm/redoc-lib/src/services/models/Field.js +1 -1
  645. package/lib-esm/redoc-lib/src/services/models/Group.model.d.ts +2 -3
  646. package/lib-esm/redoc-lib/src/services/models/Group.model.js +1 -1
  647. package/lib-esm/redoc-lib/src/services/models/MediaContent.d.ts +1 -1
  648. package/lib-esm/redoc-lib/src/services/models/MediaContent.js +1 -1
  649. package/lib-esm/redoc-lib/src/services/models/MediaType.d.ts +2 -2
  650. package/lib-esm/redoc-lib/src/services/models/MediaType.js +1 -1
  651. package/lib-esm/redoc-lib/src/services/models/Operation.d.ts +12 -7
  652. package/lib-esm/redoc-lib/src/services/models/Operation.js +1 -1
  653. package/lib-esm/redoc-lib/src/services/models/RequestBody.d.ts +1 -1
  654. package/lib-esm/redoc-lib/src/services/models/RequestBody.js +1 -1
  655. package/lib-esm/redoc-lib/src/services/models/Response.d.ts +1 -1
  656. package/lib-esm/redoc-lib/src/services/models/Response.js +1 -1
  657. package/lib-esm/redoc-lib/src/services/models/Schema.d.ts +5 -5
  658. package/lib-esm/redoc-lib/src/services/models/Schema.js +1 -1
  659. package/lib-esm/redoc-lib/src/services/models/SecurityRequirement.js +1 -1
  660. package/lib-esm/redoc-lib/src/services/models/SecuritySchemes.js +1 -1
  661. package/lib-esm/redoc-lib/src/services/models/Webhook.d.ts +1 -1
  662. package/lib-esm/redoc-lib/src/services/models/Webhook.js +1 -1
  663. package/lib-esm/redoc-lib/src/services/models/index.d.ts +0 -1
  664. package/lib-esm/redoc-lib/src/services/models/index.js +1 -1
  665. package/lib-esm/redoc-lib/src/services/types.d.ts +218 -0
  666. package/lib-esm/redoc-lib/src/services/types.js +2 -0
  667. package/lib-esm/redoc-lib/src/types/open-api.d.ts +22 -2
  668. package/lib-esm/redoc-lib/src/utils/argValuesHelpers.d.ts +1 -1
  669. package/lib-esm/redoc-lib/src/utils/argValuesHelpers.js +1 -1
  670. package/lib-esm/redoc-lib/src/utils/helpers.d.ts +3 -1
  671. package/lib-esm/redoc-lib/src/utils/helpers.js +1 -1
  672. package/lib-esm/redoc-lib/src/utils/openapi.d.ts +3 -4
  673. package/lib-esm/redoc-lib/src/utils/openapi.js +1 -1
  674. package/lib-esm/redoc-lib/src/utils/string.d.ts +1 -0
  675. package/lib-esm/redoc-lib/src/utils/string.js +2 -0
  676. package/lib-esm/services/OAuth2.d.ts +4 -2
  677. package/lib-esm/services/OAuth2.js +1 -1
  678. package/lib-esm/services/OpenIDConnect.d.ts +1 -1
  679. package/lib-esm/services/ProMenu.js +1 -1
  680. package/lib-esm/services/ProStore.d.ts +9 -7
  681. package/lib-esm/services/ProStore.js +1 -1
  682. package/lib-esm/services/SearchStore.d.ts +1 -1
  683. package/lib-esm/services/VersionedSpecStore.d.ts +1 -1
  684. package/lib-esm/services/VersionedSpecStore.js +1 -1
  685. package/lib-esm/services/code-samples/generator.d.ts +1 -0
  686. package/lib-esm/services/code-samples/generator.js +1 -1
  687. package/lib-esm/services/code-samples/httpsnippet/index.js +1 -1
  688. package/lib-esm/services/code-samples/httpsnippet/targets/csharp/httpclient.js +1 -1
  689. package/lib-esm/services/code-samples/httpsnippet/targets/go/native.js +1 -1
  690. package/lib-esm/services/code-samples/httpsnippet/targets/java/httpclient.js +1 -1
  691. package/lib-esm/services/code-samples/httpsnippet/targets/java8/apachehttp.js +1 -1
  692. package/lib-esm/services/code-samples/httpsnippet/targets/javascript/fetch.js +1 -1
  693. package/lib-esm/services/code-samples/httpsnippet/targets/node/fetch.js +1 -1
  694. package/lib-esm/services/code-samples/httpsnippet/targets/php/curl.js +1 -1
  695. package/lib-esm/services/code-samples/httpsnippet/targets/python/requests.js +1 -1
  696. package/lib-esm/services/code-samples/httpsnippet/targets/r/httr.js +1 -1
  697. package/lib-esm/services/code-samples/httpsnippet/targets/ruby/native.js +1 -1
  698. package/lib-esm/services/code-samples/httpsnippet/targets/shell/curl.js +1 -1
  699. package/lib-esm/services/history/ProHashHistoryService.js +1 -1
  700. package/lib-esm/services/utils.d.ts +2 -0
  701. package/lib-esm/services/utils.js +1 -1
  702. package/lib-esm/standalone.d.ts +1 -1
  703. package/lib-esm/standalone.js +1 -1
  704. package/lib-esm/types.d.ts +25 -0
  705. package/lib-esm/types.js +2 -0
  706. package/lib-esm/utils.d.ts +4 -13
  707. package/lib-esm/utils.js +1 -1
  708. package/package.json +26 -60
  709. package/lib/components/Endpoint/CopyLink.d.ts +0 -1
  710. package/lib/components/Endpoint/CopyLink.js +0 -2
  711. package/lib/components/Endpoint/Path.d.ts +0 -4
  712. package/lib/components/Endpoint/Path.js +0 -2
  713. package/lib/components/Endpoint/ServerItem.d.ts +0 -1
  714. package/lib/components/Endpoint/ServerItem.js +0 -2
  715. package/lib/components/Endpoint/ServerUrl.d.ts +0 -1
  716. package/lib/components/Endpoint/ServerUrl.js +0 -2
  717. package/lib/components/console/OperationParameters.js +0 -2
  718. package/lib/components/console/RequestBody.d.ts +0 -12
  719. package/lib/components/console/RequestBody.js +0 -2
  720. package/lib/components/console/ServerDropdown.d.ts +0 -24
  721. package/lib/components/console/ServerDropdown.js +0 -2
  722. package/lib/components/shared/SelectOnClick.d.ts +0 -6
  723. package/lib/components/shared/SelectOnClick.js +0 -2
  724. package/lib/redoc-lib/src/components/Markdown/SanitizedMdBlock.js +0 -2
  725. package/lib/redoc-lib/src/components/Responses/styled.elements.d.ts +0 -1
  726. package/lib/redoc-lib/src/components/Responses/styled.elements.js +0 -2
  727. package/lib/redoc-lib/src/components/helper.d.ts +0 -6
  728. package/lib/redoc-lib/src/components/helper.js +0 -2
  729. package/lib/redoc-lib/src/services/MenuStore.d.ts +0 -21
  730. package/lib-esm/components/Endpoint/CopyLink.d.ts +0 -1
  731. package/lib-esm/components/Endpoint/CopyLink.js +0 -2
  732. package/lib-esm/components/Endpoint/Path.d.ts +0 -4
  733. package/lib-esm/components/Endpoint/Path.js +0 -2
  734. package/lib-esm/components/Endpoint/ServerItem.d.ts +0 -1
  735. package/lib-esm/components/Endpoint/ServerItem.js +0 -2
  736. package/lib-esm/components/Endpoint/ServerUrl.d.ts +0 -1
  737. package/lib-esm/components/Endpoint/ServerUrl.js +0 -2
  738. package/lib-esm/components/console/OperationParameters.js +0 -2
  739. package/lib-esm/components/console/RequestBody.d.ts +0 -12
  740. package/lib-esm/components/console/RequestBody.js +0 -2
  741. package/lib-esm/components/console/ServerDropdown.d.ts +0 -24
  742. package/lib-esm/components/console/ServerDropdown.js +0 -2
  743. package/lib-esm/components/shared/SelectOnClick.d.ts +0 -6
  744. package/lib-esm/components/shared/SelectOnClick.js +0 -2
  745. package/lib-esm/redoc-lib/src/components/Markdown/SanitizedMdBlock.js +0 -2
  746. package/lib-esm/redoc-lib/src/components/Responses/styled.elements.d.ts +0 -1
  747. package/lib-esm/redoc-lib/src/components/Responses/styled.elements.js +0 -2
  748. package/lib-esm/redoc-lib/src/components/helper.d.ts +0 -6
  749. package/lib-esm/redoc-lib/src/components/helper.js +0 -2
  750. package/lib-esm/redoc-lib/src/services/MenuStore.d.ts +0 -21
  751. package/lib-esm/redoc-lib/src/services/MenuStore.js +0 -2
@@ -1,115 +1,5 @@
1
- /// <reference types="react" />
2
- import type { OperationModel, Sample } from '.';
3
1
  import type { MediaQueries } from '../utils';
4
- import type { LabelsConfigRaw } from './Labels';
5
- import type { MDXComponentMeta } from './MarkdownRenderer';
6
- import type { Server } from '../types';
7
- import type { OAuth2 } from '../../../services/OAuth2';
8
- import type { ProStore } from '../../../services';
9
- export declare type Unstable_ExternalCodeSample = Sample & {
10
- get: (source: ExternalSource) => string;
11
- };
12
- export interface ExternalSource {
13
- sample: Unstable_ExternalCodeSample;
14
- operation: OperationModel;
15
- exampleName?: string;
16
- pathParams?: GenericObject;
17
- properties?: GenericObject;
18
- }
19
- export interface SecurityPanelHookProps {
20
- operation: OperationModel;
21
- server: Server;
22
- onChange: (securityDetails: unknown) => void;
23
- OAuth2: OAuth2;
24
- }
25
- export interface HookRawHtml {
26
- html: string;
27
- }
28
- declare type HookResult = JSX.Element | HookRawHtml | null;
29
- export declare type HookConfig<T> = (props: T) => HookResult;
30
- interface HooksConfig {
31
- BeforeOperation?: HookConfig<{
32
- operation: OperationModel;
33
- }>;
34
- BeforeOperationSummary?: HookConfig<{
35
- operation: OperationModel;
36
- }>;
37
- AfterOperationSummary?: HookConfig<{
38
- operation: OperationModel;
39
- }>;
40
- AfterOperation?: HookConfig<{
41
- operation: OperationModel;
42
- }>;
43
- ReplaceTryItSecurityPanel?: HookConfig<SecurityPanelHookProps>;
44
- onInit?: (args: {
45
- store: ProStore;
46
- }) => void;
47
- replaceSecurityLink?: (args: {
48
- securityRequirementId: string;
49
- }) => string;
50
- sanitize?: (raw: string) => string;
51
- /** @deprecated Use ReplaceTryItSecurityPanel instead */
52
- ReplaceTryItAuthPanel?: HookConfig<SecurityPanelHookProps>;
53
- }
54
- export interface RedocRawOptions {
55
- breakpoints?: Omit<MediaQueries, 'print'>;
56
- showAtBreakpoint?: {
57
- sidebar?: keyof Omit<MediaQueries, 'print'>;
58
- samplesPanel?: keyof Omit<MediaQueries, 'print'>;
59
- };
60
- scrollYOffset?: number | string | (() => number);
61
- hideHostname?: boolean | string;
62
- hideInfoDescription?: boolean | string;
63
- expandResponses?: string | 'all';
64
- requiredPropsFirst?: boolean | string;
65
- sortPropsAlphabetically?: boolean | string;
66
- sortEnumValuesAlphabetically?: boolean | string;
67
- sortOperationsAlphabetically?: boolean | string;
68
- sortTagsAlphabetically?: boolean | string;
69
- noAutoAuth?: boolean | string;
70
- nativeScrollbars?: boolean | string;
71
- pathInMiddlePanel?: boolean | string;
72
- untrustedDefinition?: boolean | string;
73
- hideLoading?: boolean | string;
74
- hideDownloadButton?: boolean | string;
75
- downloadDefinitionUrl?: string;
76
- disableSearch?: boolean | string;
77
- showChangeLayoutButton?: boolean | string;
78
- onlyRequiredInSamples?: boolean | string;
79
- generatedPayloadSamplesMaxDepth?: number | string;
80
- sendXUserAgentInTryIt?: boolean | string;
81
- showExtensions?: boolean | string | string[];
82
- hideSingleRequestSampleTab?: boolean | string;
83
- hideRequestPayloadSample?: boolean;
84
- menuToggle?: boolean | string;
85
- jsonSampleExpandLevel?: number | string | 'all';
86
- hideSchemaTitles?: boolean | string;
87
- simpleOneOfTypeLabel?: boolean | string;
88
- payloadSampleIdx?: number;
89
- expandSingleSchemaField?: boolean | string;
90
- schemaExpansionLevel?: number | string | 'all';
91
- samplesTabsMaxCount?: number;
92
- unstable_tryItButtonOverride?: {
93
- label: string;
94
- link: string;
95
- };
96
- allowedMdComponents?: Record<string, MDXComponentMeta>;
97
- labels?: LabelsConfigRaw;
98
- enumSkipQuotes?: boolean | string;
99
- expandDefaultServerVariables?: boolean;
100
- expandDefaultRequest?: boolean;
101
- expandDefaultResponse?: boolean;
102
- maxDisplayedEnumValues?: number;
103
- ignoreNamedSchemas?: string[] | string;
104
- unstable_externalCodeSamples?: Unstable_ExternalCodeSample[];
105
- unstable_ignoreMimeParameters?: boolean;
106
- hooks?: HooksConfig;
107
- hideSchemaPattern?: boolean;
108
- hideOneOfDescription?: boolean;
109
- hideFab?: boolean;
110
- minCharacterLengthToInitSearch?: number;
111
- maxResponseHeadersToShowInTryIt?: number;
112
- }
2
+ import type { HooksConfig, MDXComponentMeta, RedocRawOptions, Unstable_ExternalCodeSample } from './types';
113
3
  export declare class RedocNormalizedOptions {
114
4
  static normalizeExpandResponses(value: RedocRawOptions['expandResponses']): 'all' | {
115
5
  [code: string]: boolean;
@@ -134,7 +24,6 @@ export declare class RedocNormalizedOptions {
134
24
  sortEnumValuesAlphabetically: boolean;
135
25
  sortOperationsAlphabetically: boolean;
136
26
  sortTagsAlphabetically: boolean;
137
- noAutoAuth: boolean;
138
27
  nativeScrollbars: boolean;
139
28
  pathInMiddlePanel: boolean;
140
29
  untrustedDefinition: boolean;
@@ -147,12 +36,15 @@ export declare class RedocNormalizedOptions {
147
36
  sendXUserAgentInTryIt: boolean;
148
37
  generatedPayloadSamplesMaxDepth: number;
149
38
  showExtensions: boolean | string[];
39
+ preserveOriginalExtensionsName: boolean;
150
40
  hideSingleRequestSampleTab: boolean;
151
41
  hideRequestPayloadSample: boolean;
152
42
  menuToggle: boolean;
153
43
  jsonSampleExpandLevel: number;
154
44
  enumSkipQuotes: boolean;
155
45
  hideSchemaTitles: boolean;
46
+ hideSecuritySection: boolean;
47
+ showSecuritySchemeType: boolean;
156
48
  simpleOneOfTypeLabel: boolean;
157
49
  payloadSampleIdx: number;
158
50
  expandSingleSchemaField: boolean;
@@ -175,8 +67,13 @@ export declare class RedocNormalizedOptions {
175
67
  hideSchemaPattern: boolean;
176
68
  hideOneOfDescription: boolean;
177
69
  hideFab: boolean;
70
+ markdownHeadingsAnchorLevel: number;
71
+ schemaDefinitionsTagName?: string;
178
72
  minCharacterLengthToInitSearch: number;
179
73
  maxResponseHeadersToShowInTryIt: number;
74
+ showWebhookVerb: boolean;
75
+ showObjectSchemaExamples: boolean;
76
+ showAccessMode: boolean;
77
+ disableTryItRequestUrlEncoding: boolean;
180
78
  constructor(raw: RedocRawOptions, defaults?: RedocRawOptions);
181
79
  }
182
- export {};
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.RedocNormalizedOptions=void 0;var tslib_1=require("tslib"),mobx_1=require("mobx"),utils_1=require("../utils"),Labels_1=require("./Labels"),RedocNormalizedOptions=function(){function e(a,t){var i;void 0===t&&(t={}),Object.defineProperty(this,"mediaQueries",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showAtBreakpoint",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"scrollYOffset",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideHostname",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideInfoDescription",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandResponses",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"requiredPropsFirst",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sortPropsAlphabetically",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sortEnumValuesAlphabetically",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sortOperationsAlphabetically",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sortTagsAlphabetically",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"noAutoAuth",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"nativeScrollbars",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"pathInMiddlePanel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"untrustedDefinition",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideDownloadButton",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"downloadDefinitionUrl",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"disableSearch",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showChangeLayoutButton",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"onlyRequiredInSamples",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showConsole",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sendXUserAgentInTryIt",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"generatedPayloadSamplesMaxDepth",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showExtensions",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideSingleRequestSampleTab",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideRequestPayloadSample",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"menuToggle",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"jsonSampleExpandLevel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"enumSkipQuotes",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideSchemaTitles",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"simpleOneOfTypeLabel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"payloadSampleIdx",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandSingleSchemaField",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"schemaExpansionLevel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"samplesTabsMaxCount",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"unstable_tryItButtonOverride",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"allowedMdComponents",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandDefaultServerVariables",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandDefaultRequest",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandDefaultResponse",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"maxDisplayedEnumValues",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"ignoreNamedSchemas",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"unstable_ignoreMimeParameters",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"unstable_externalCodeSamples",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hooks",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideSchemaPattern",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideOneOfDescription",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideFab",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"minCharacterLengthToInitSearch",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"maxResponseHeadersToShowInTryIt",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),(0,mobx_1.makeObservable)(this),a=(0,tslib_1.__assign)((0,tslib_1.__assign)({},t),a),(0,Labels_1.setRedocLabels)(a.labels),this.mediaQueries=(0,utils_1.generateMediaQueries)(a.breakpoints||{}),this.showAtBreakpoint=a.showAtBreakpoint,this.scrollYOffset=e.normalizeScrollYOffset(a.scrollYOffset),this.hideHostname=e.normalizeHideHostname(a.hideHostname),this.expandResponses=e.normalizeExpandResponses(a.expandResponses),this.requiredPropsFirst=(0,utils_1.argValueToBoolean)(a.requiredPropsFirst),this.sortPropsAlphabetically=(0,utils_1.argValueToBoolean)(a.sortPropsAlphabetically),this.sortEnumValuesAlphabetically=(0,utils_1.argValueToBoolean)(a.sortEnumValuesAlphabetically),this.sortOperationsAlphabetically=(0,utils_1.argValueToBoolean)(a.sortOperationsAlphabetically),this.sortTagsAlphabetically=(0,utils_1.argValueToBoolean)(a.sortTagsAlphabetically),this.noAutoAuth=(0,utils_1.argValueToBoolean)(a.noAutoAuth),this.nativeScrollbars=(0,utils_1.argValueToBoolean)(a.nativeScrollbars),this.pathInMiddlePanel=(0,utils_1.argValueToBoolean)(a.pathInMiddlePanel),this.untrustedDefinition=(0,utils_1.argValueToBoolean)(a.untrustedDefinition),this.hideDownloadButton=void 0===a.hideDownloadButton?null:(0,utils_1.argValueToBoolean)(a.hideDownloadButton),this.downloadDefinitionUrl=a.downloadDefinitionUrl,this.hideInfoDescription=(0,utils_1.argValueToBoolean)(a.hideInfoDescription),this.disableSearch=(0,utils_1.argValueToBoolean)(a.disableSearch),this.onlyRequiredInSamples=(0,utils_1.argValueToBoolean)(a.onlyRequiredInSamples),this.generatedPayloadSamplesMaxDepth=(0,utils_1.argValueToInt)(a.generatedPayloadSamplesMaxDepth)||8,this.sendXUserAgentInTryIt=(0,utils_1.argValueToBoolean)(a.sendXUserAgentInTryIt),this.showExtensions=e.normalizeShowExtensions(a.showExtensions),this.hideSingleRequestSampleTab=(0,utils_1.argValueToBoolean)(a.hideSingleRequestSampleTab),this.hideRequestPayloadSample=(0,utils_1.argValueToBoolean)(a.hideRequestPayloadSample),this.menuToggle=(0,utils_1.argValueToBoolean)(a.menuToggle,!0),this.jsonSampleExpandLevel=(0,utils_1.argValueToExpandLevel)(a.jsonSampleExpandLevel,2),this.enumSkipQuotes=(0,utils_1.argValueToBoolean)(a.enumSkipQuotes),this.hideSchemaTitles=(0,utils_1.argValueToBoolean)(a.hideSchemaTitles),this.simpleOneOfTypeLabel=(0,utils_1.argValueToBoolean)(a.simpleOneOfTypeLabel),this.payloadSampleIdx=e.normalizePayloadSampleIdx(a.payloadSampleIdx),this.expandSingleSchemaField=(0,utils_1.argValueToBoolean)(a.expandSingleSchemaField),this.schemaExpansionLevel=(0,utils_1.argValueToExpandLevel)(a.schemaExpansionLevel),this.samplesTabsMaxCount=(0,utils_1.argValueToInt)(a.samplesTabsMaxCount)||5,this.unstable_tryItButtonOverride=a.unstable_tryItButtonOverride||null,this.unstable_ignoreMimeParameters=(0,utils_1.argValueToBoolean)(a.unstable_ignoreMimeParameters),this.allowedMdComponents=a.allowedMdComponents||{},this.expandDefaultServerVariables=(0,utils_1.argValueToBoolean)(a.expandDefaultServerVariables),this.expandDefaultRequest=(0,utils_1.argValueToBoolean)(a.expandDefaultRequest,!0),this.expandDefaultResponse=(0,utils_1.argValueToBoolean)(a.expandDefaultResponse,!0),this.maxDisplayedEnumValues=(0,utils_1.argValueToNumber)(a.maxDisplayedEnumValues);var l=Array.isArray(a.ignoreNamedSchemas)?a.ignoreNamedSchemas:null===(i=a.ignoreNamedSchemas)||void 0===i?void 0:i.split(",").map((function(e){return e.trim()}));this.ignoreNamedSchemas=new Set(l),this.unstable_externalCodeSamples=a.unstable_externalCodeSamples||[],this.hooks=a.hooks||{},this.hooks.ReplaceTryItAuthPanel&&!this.hooks.ReplaceTryItSecurityPanel&&(console.warn("[warn] ReplaceTryItAuthPanel is deprecated, use ReplaceTryItSecurityPanel instead"),this.hooks.ReplaceTryItSecurityPanel=this.hooks.ReplaceTryItAuthPanel),this.hideSchemaPattern=(0,utils_1.argValueToBoolean)(a.hideSchemaPattern),this.hideOneOfDescription=(0,utils_1.argValueToBoolean)(a.hideOneOfDescription),this.hideFab=(0,utils_1.argValueToBoolean)(a.hideFab),this.minCharacterLengthToInitSearch=(0,utils_1.argValueToNumber)(a.minCharacterLengthToInitSearch)||3,this.maxResponseHeadersToShowInTryIt=(0,utils_1.argValueToNumber)(a.maxResponseHeadersToShowInTryIt)||0}return Object.defineProperty(e,"normalizeExpandResponses",{enumerable:!1,configurable:!0,writable:!0,value:function(e){if("all"===e)return"all";if("string"==typeof e){var a={};return e.split(",").forEach((function(e){a[e.trim()]=!0})),a}return void 0!==e&&console.warn('expandResponses must be a string but received value "'+e+'" of type '+typeof e),{}}}),Object.defineProperty(e,"normalizeHideHostname",{enumerable:!1,configurable:!0,writable:!0,value:function(e){return!!e}}),Object.defineProperty(e,"normalizeScrollYOffset",{enumerable:!1,configurable:!0,writable:!0,value:function(e){if("string"==typeof e&&!(0,utils_1.isNumeric)(e)){var a=(0,utils_1.querySelector)(e);a||console.warn("scrollYOffset value is a selector to non-existing element. Using offset 0 by default");var t=a&&a.getBoundingClientRect().bottom||0;return function(){return t}}return"number"==typeof e||(0,utils_1.isNumeric)(e)?function(){return"number"==typeof e?e:parseFloat(e)}:"function"==typeof e?function(){var a=e();return"number"!=typeof a&&console.warn('scrollYOffset should return number but returned value "'+a+'" of type '+typeof a),a}:(void 0!==e&&console.warn("Wrong value for scrollYOffset ReDoc option: should be string, number or function"),function(){return 0})}}),Object.defineProperty(e,"normalizeShowExtensions",{enumerable:!1,configurable:!0,writable:!0,value:function(e){if(void 0===e)return!1;if(""===e)return!0;if("string"!=typeof e)return e;switch(e){case"true":return!0;case"false":return!1;default:return e.split(",").map((function(e){return e.trim()}))}}}),Object.defineProperty(e,"normalizePayloadSampleIdx",{enumerable:!1,configurable:!0,writable:!0,value:function(e){return"number"==typeof e?Math.max(0,e):"string"==typeof e&&isFinite(e)?parseInt(e,10):0}}),(0,tslib_1.__decorate)([mobx_1.observable],e.prototype,"showConsole",void 0),e}();exports.RedocNormalizedOptions=RedocNormalizedOptions;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.RedocNormalizedOptions=void 0;var tslib_1=require("tslib"),mobx_1=require("mobx"),utils_1=require("../utils"),utils_2=require("../../../utils"),types_1=require("../../../types"),Labels_1=require("./Labels"),RedocNormalizedOptions=function(){function e(a,i){var t;void 0===i&&(i={}),Object.defineProperty(this,"mediaQueries",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showAtBreakpoint",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"scrollYOffset",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideHostname",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideInfoDescription",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandResponses",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"requiredPropsFirst",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sortPropsAlphabetically",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sortEnumValuesAlphabetically",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sortOperationsAlphabetically",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sortTagsAlphabetically",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"nativeScrollbars",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"pathInMiddlePanel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"untrustedDefinition",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideDownloadButton",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"downloadDefinitionUrl",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"disableSearch",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showChangeLayoutButton",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"onlyRequiredInSamples",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showConsole",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sendXUserAgentInTryIt",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"generatedPayloadSamplesMaxDepth",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showExtensions",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"preserveOriginalExtensionsName",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideSingleRequestSampleTab",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideRequestPayloadSample",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"menuToggle",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"jsonSampleExpandLevel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"enumSkipQuotes",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideSchemaTitles",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideSecuritySection",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showSecuritySchemeType",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"simpleOneOfTypeLabel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"payloadSampleIdx",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandSingleSchemaField",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"schemaExpansionLevel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"samplesTabsMaxCount",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"unstable_tryItButtonOverride",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"allowedMdComponents",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandDefaultServerVariables",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandDefaultRequest",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"expandDefaultResponse",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"maxDisplayedEnumValues",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"ignoreNamedSchemas",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"unstable_ignoreMimeParameters",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"unstable_externalCodeSamples",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hooks",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideSchemaPattern",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideOneOfDescription",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"hideFab",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"markdownHeadingsAnchorLevel",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"schemaDefinitionsTagName",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"minCharacterLengthToInitSearch",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"maxResponseHeadersToShowInTryIt",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showWebhookVerb",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showObjectSchemaExamples",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"showAccessMode",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"disableTryItRequestUrlEncoding",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),(0,mobx_1.makeObservable)(this),a=(0,tslib_1.__assign)((0,tslib_1.__assign)({},i),a),(0,Labels_1.setRedocLabels)(a.labels),this.mediaQueries=(0,utils_1.generateMediaQueries)(a.breakpoints||{}),this.showAtBreakpoint=a.showAtBreakpoint,this.scrollYOffset=e.normalizeScrollYOffset(a.scrollYOffset),this.hideHostname=e.normalizeHideHostname(a.hideHostname),this.expandResponses=e.normalizeExpandResponses(a.expandResponses),this.requiredPropsFirst=(0,utils_1.argValueToBoolean)(a.requiredPropsFirst),this.sortPropsAlphabetically=(0,utils_1.argValueToBoolean)(a.sortPropsAlphabetically),this.sortEnumValuesAlphabetically=(0,utils_1.argValueToBoolean)(a.sortEnumValuesAlphabetically),this.sortOperationsAlphabetically=(0,utils_1.argValueToBoolean)(a.sortOperationsAlphabetically),this.sortTagsAlphabetically=(0,utils_1.argValueToBoolean)(a.sortTagsAlphabetically),this.nativeScrollbars=(0,utils_1.argValueToBoolean)(a.nativeScrollbars),this.pathInMiddlePanel=(0,utils_1.argValueToBoolean)(a.pathInMiddlePanel),this.untrustedDefinition=(0,utils_1.argValueToBoolean)(a.untrustedDefinition),this.hideDownloadButton=void 0===a.hideDownloadButton?null:(0,utils_1.argValueToBoolean)(a.hideDownloadButton),this.downloadDefinitionUrl=a.downloadDefinitionUrl,this.hideInfoDescription=(0,utils_1.argValueToBoolean)(a.hideInfoDescription),this.disableSearch=(0,utils_1.argValueToBoolean)(a.disableSearch),this.onlyRequiredInSamples=(0,utils_1.argValueToBoolean)(a.onlyRequiredInSamples),this.generatedPayloadSamplesMaxDepth=(0,utils_1.argValueToInt)(a.generatedPayloadSamplesMaxDepth)||8,this.sendXUserAgentInTryIt=(0,utils_1.argValueToBoolean)(a.sendXUserAgentInTryIt),this.showExtensions=e.normalizeShowExtensions(a.showExtensions),this.preserveOriginalExtensionsName=(0,utils_1.argValueToBoolean)(a.preserveOriginalExtensionsName,!1),this.hideSingleRequestSampleTab=(0,utils_1.argValueToBoolean)(a.hideSingleRequestSampleTab),this.hideRequestPayloadSample=(0,utils_1.argValueToBoolean)(a.hideRequestPayloadSample),this.menuToggle=(0,utils_1.argValueToBoolean)(a.menuToggle,!0),this.jsonSampleExpandLevel=(0,utils_1.argValueToExpandLevel)(a.jsonSampleExpandLevel,2),this.enumSkipQuotes=(0,utils_1.argValueToBoolean)(a.enumSkipQuotes),this.hideSchemaTitles=(0,utils_1.argValueToBoolean)(a.hideSchemaTitles),this.hideSecuritySection=(0,utils_1.argValueToBoolean)(a.hideSecuritySection),this.showSecuritySchemeType=(0,utils_1.argValueToBoolean)(a.showSecuritySchemeType),this.simpleOneOfTypeLabel=(0,utils_1.argValueToBoolean)(a.simpleOneOfTypeLabel),this.payloadSampleIdx=e.normalizePayloadSampleIdx(a.payloadSampleIdx),this.expandSingleSchemaField=(0,utils_1.argValueToBoolean)(a.expandSingleSchemaField),this.schemaExpansionLevel=(0,utils_1.argValueToExpandLevel)(a.schemaExpansionLevel),this.samplesTabsMaxCount=(0,utils_1.argValueToInt)(a.samplesTabsMaxCount)||5,this.unstable_tryItButtonOverride=a.unstable_tryItButtonOverride||null,this.unstable_ignoreMimeParameters=(0,utils_1.argValueToBoolean)(a.unstable_ignoreMimeParameters),this.allowedMdComponents=a.allowedMdComponents||{},this.expandDefaultServerVariables=(0,utils_1.argValueToBoolean)(a.expandDefaultServerVariables),this.expandDefaultRequest=(0,utils_1.argValueToBoolean)(a.expandDefaultRequest,!0),this.expandDefaultResponse=(0,utils_1.argValueToBoolean)(a.expandDefaultResponse,!0),this.maxDisplayedEnumValues=(0,utils_1.argValueToNumber)(a.maxDisplayedEnumValues);var r=Array.isArray(a.ignoreNamedSchemas)?a.ignoreNamedSchemas:null===(t=a.ignoreNamedSchemas)||void 0===t?void 0:t.split(",").map((function(e){return e.trim()}));this.ignoreNamedSchemas=new Set(r),this.unstable_externalCodeSamples=a.unstable_externalCodeSamples||[],this.hooks=a.hooks||(0,utils_2.getWindowReferenceOptions)(types_1.WindowReferenceOptions.HOOKS)||{},this.hooks.ReplaceTryItAuthPanel&&!this.hooks.ReplaceTryItSecurityPanel&&(console.warn("[warn] ReplaceTryItAuthPanel is deprecated, use ReplaceTryItSecurityPanel instead"),this.hooks.ReplaceTryItSecurityPanel=this.hooks.ReplaceTryItAuthPanel),this.hideSchemaPattern=(0,utils_1.argValueToBoolean)(a.hideSchemaPattern),this.hideOneOfDescription=(0,utils_1.argValueToBoolean)(a.hideOneOfDescription),this.hideFab=(0,utils_1.argValueToBoolean)(a.hideFab),this.markdownHeadingsAnchorLevel=(0,utils_1.argValueToNumber)(a.markdownHeadingsAnchorLevel,2),this.schemaDefinitionsTagName=a.schemaDefinitionsTagName,this.minCharacterLengthToInitSearch=(0,utils_1.argValueToNumber)(a.minCharacterLengthToInitSearch,3),this.maxResponseHeadersToShowInTryIt=(0,utils_1.argValueToNumber)(a.maxResponseHeadersToShowInTryIt),this.showWebhookVerb=(0,utils_1.argValueToBoolean)(a.showWebhookVerb),this.showObjectSchemaExamples=(0,utils_1.argValueToBoolean)(a.showObjectSchemaExamples),this.showAccessMode=(0,utils_1.argValueToBoolean)(a.showAccessMode),this.disableTryItRequestUrlEncoding=(0,utils_1.argValueToBoolean)(a.disableTryItRequestUrlEncoding,!1)}return Object.defineProperty(e,"normalizeExpandResponses",{enumerable:!1,configurable:!0,writable:!0,value:function(e){if("all"===e)return"all";if("string"==typeof e){var a={};return e.split(",").forEach((function(e){a[e.trim()]=!0})),a}return void 0!==e&&console.warn('expandResponses must be a string but received value "'+e+'" of type '+typeof e),{}}}),Object.defineProperty(e,"normalizeHideHostname",{enumerable:!1,configurable:!0,writable:!0,value:function(e){return!!e}}),Object.defineProperty(e,"normalizeScrollYOffset",{enumerable:!1,configurable:!0,writable:!0,value:function(e){if("string"==typeof e&&!(0,utils_1.isNumeric)(e)){var a=(0,utils_1.querySelector)(e);a||console.warn("scrollYOffset value is a selector to non-existing element. Using offset 0 by default");var i=a&&a.getBoundingClientRect().bottom||0;return function(){return i}}return"number"==typeof e||(0,utils_1.isNumeric)(e)?function(){return"number"==typeof e?e:parseFloat(e)}:"function"==typeof e?function(){var a=e();return"number"!=typeof a&&console.warn('scrollYOffset should return number but returned value "'+a+'" of type '+typeof a),a}:(void 0!==e&&console.warn("Wrong value for scrollYOffset ReDoc option: should be string, number or function"),function(){return 0})}}),Object.defineProperty(e,"normalizeShowExtensions",{enumerable:!1,configurable:!0,writable:!0,value:function(e){if(void 0===e)return!1;if(""===e)return!0;if("string"!=typeof e)return e;switch(e){case"true":return!0;case"false":return!1;default:return e.split(",").map((function(e){return e.trim()}))}}}),Object.defineProperty(e,"normalizePayloadSampleIdx",{enumerable:!1,configurable:!0,writable:!0,value:function(e){return"number"==typeof e?Math.max(0,e):"string"==typeof e&&isFinite(e)?parseInt(e,10):0}}),(0,tslib_1.__decorate)([mobx_1.observable],e.prototype,"showConsole",void 0),e}();exports.RedocNormalizedOptions=RedocNormalizedOptions;
2
2
  //# sourceMappingURL=RedocNormalizedOptions.js.map
@@ -1,7 +1,6 @@
1
- import type { IMenuItem } from './MenuStore';
1
+ import type { IMenuItem, SearchResult } from './types';
2
2
  import type { OperationModel } from './models/Operation';
3
3
  import type Worker from './SearchWorker.worker';
4
- import type { SearchResult } from './SearchWorker.worker';
5
4
  export declare class SearchStore<T> {
6
5
  searchWorker: Worker;
7
6
  indexItems(groups: Array<IMenuItem | OperationModel>): void;
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see SearchStore.js.LICENSE.txt */
2
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.SearchStore=t():e.SearchStore=t()}(this,(function(){return(()=>{var e={27:(e,t,r)=>{"use strict";r.d(t,{ZP:()=>a});var i=r(336),n=Object.defineProperty,s=(e,t,r)=>(((e,t,r)=>{t in e?n(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r})(e,"symbol"!=typeof t?t+"":t,r),r),o=(e,t,r)=>new Promise(((i,n)=>{var s=e=>{try{a(r.next(e))}catch(e){n(e)}},o=e=>{try{a(r.throw(e))}catch(e){n(e)}},a=e=>e.done?i(e.value):Promise.resolve(e.value).then(s,o);a((r=r.apply(e,t)).next())}));class a{constructor(){s(this,"add",f),s(this,"done",p),s(this,"search",R),s(this,"toJS",y),s(this,"load",g),s(this,"dispose",x),s(this,"fromExternalJS",m)}}let u,l,c,h=[];function d(){u=new i.Builder,u.field("title"),u.field("description"),u.ref("ref"),u.pipeline.add(i.trimmer,i.stopWordFilter,i.stemmer),c=new Promise((e=>{l=e}))}function f(e,t,r){const i=h.push(r)-1,n={title:e.toLowerCase(),description:t.toLowerCase(),ref:i};u.add(n)}function p(){return o(this,null,(function*(){l(u.build())}))}function y(){return o(this,null,(function*(){return{store:h,index:(yield c).toJSON()}}))}function m(e,t){return o(this,null,(function*(){try{if(importScripts(e),!self[t])throw new Error("Broken index file format");yield g(self[t])}catch(e){console.error("Failed to load search index: "+e.message)}}))}function g(e){return o(this,null,(function*(){h=e.store,l(i.Index.load(e.index))}))}function x(){return o(this,null,(function*(){h=[],d()}))}function R(e,t=0){return o(this,null,(function*(){if(0===e.trim().length)return[];let r=(yield c).query((t=>{e.trim().toLowerCase().split(/\s+/).forEach((e=>{if(1===e.length)return;const r=(e=>"*"+i.stemmer(new i.Token(e,{}))+"*")(e);t.term(r,{})}))}));return t>0&&(r=r.slice(0,t)),r.map((e=>({meta:h[e.ref],score:e.score})))}))}i.tokenizer.separator=/\s+/,d()},336:(e,t,r)=>{var i,n;!function(){var s,o,a,u,l,c,h,d,f,p,y,m,g,x,R,v,w,Q,k,S,E,b,L,P,T,O,I=function(e){var t=new I.Builder;return t.pipeline.add(I.trimmer,I.stopWordFilter,I.stemmer),t.searchPipeline.add(I.stemmer),e.call(t,t),t.build()};I.version="2.3.9",I.utils={},I.utils.warn=(s=this,function(e){s.console&&console.warn&&console.warn(e)}),I.utils.asString=function(e){return null==e?"":e.toString()},I.utils.clone=function(e){if(null==e)return e;for(var t=Object.create(null),r=Object.keys(e),i=0;i<r.length;i++){var n=r[i],s=e[n];if(Array.isArray(s))t[n]=s.slice();else{if("string"!=typeof s&&"number"!=typeof s&&"boolean"!=typeof s)throw new TypeError("clone is not deep and does not support nested objects");t[n]=s}}return t},I.FieldRef=function(e,t,r){this.docRef=e,this.fieldName=t,this._stringValue=r},I.FieldRef.joiner="/",I.FieldRef.fromString=function(e){var t=e.indexOf(I.FieldRef.joiner);if(-1===t)throw"malformed field ref string";var r=e.slice(0,t),i=e.slice(t+1);return new I.FieldRef(i,r,e)},I.FieldRef.prototype.toString=function(){return null==this._stringValue&&(this._stringValue=this.fieldName+I.FieldRef.joiner+this.docRef),this._stringValue},I.Set=function(e){if(this.elements=Object.create(null),e){this.length=e.length;for(var t=0;t<this.length;t++)this.elements[e[t]]=!0}else this.length=0},I.Set.complete={intersect:function(e){return e},union:function(){return this},contains:function(){return!0}},I.Set.empty={intersect:function(){return this},union:function(e){return e},contains:function(){return!1}},I.Set.prototype.contains=function(e){return!!this.elements[e]},I.Set.prototype.intersect=function(e){var t,r,i,n=[];if(e===I.Set.complete)return this;if(e===I.Set.empty)return e;this.length<e.length?(t=this,r=e):(t=e,r=this),i=Object.keys(t.elements);for(var s=0;s<i.length;s++){var o=i[s];o in r.elements&&n.push(o)}return new I.Set(n)},I.Set.prototype.union=function(e){return e===I.Set.complete?I.Set.complete:e===I.Set.empty?this:new I.Set(Object.keys(this.elements).concat(Object.keys(e.elements)))},I.idf=function(e,t){var r=0;for(var i in e)"_index"!=i&&(r+=Object.keys(e[i]).length);var n=(t-r+.5)/(r+.5);return Math.log(1+Math.abs(n))},I.Token=function(e,t){this.str=e||"",this.metadata=t||{}},I.Token.prototype.toString=function(){return this.str},I.Token.prototype.update=function(e){return this.str=e(this.str,this.metadata),this},I.Token.prototype.clone=function(e){return e=e||function(e){return e},new I.Token(e(this.str,this.metadata),this.metadata)},I.tokenizer=function(e,t){if(null==e||null==e)return[];if(Array.isArray(e))return e.map((function(e){return new I.Token(I.utils.asString(e).toLowerCase(),I.utils.clone(t))}));for(var r=e.toString().toLowerCase(),i=r.length,n=[],s=0,o=0;s<=i;s++){var a=s-o;if(r.charAt(s).match(I.tokenizer.separator)||s==i){if(a>0){var u=I.utils.clone(t)||{};u.position=[o,a],u.index=n.length,n.push(new I.Token(r.slice(o,s),u))}o=s+1}}return n},I.tokenizer.separator=/[\s\-]+/,I.Pipeline=function(){this._stack=[]},I.Pipeline.registeredFunctions=Object.create(null),I.Pipeline.registerFunction=function(e,t){t in this.registeredFunctions&&I.utils.warn("Overwriting existing registered function: "+t),e.label=t,I.Pipeline.registeredFunctions[e.label]=e},I.Pipeline.warnIfFunctionNotRegistered=function(e){e.label&&e.label in this.registeredFunctions||I.utils.warn("Function is not registered with pipeline. This may cause problems when serialising the index.\n",e)},I.Pipeline.load=function(e){var t=new I.Pipeline;return e.forEach((function(e){var r=I.Pipeline.registeredFunctions[e];if(!r)throw new Error("Cannot load unregistered function: "+e);t.add(r)})),t},I.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach((function(e){I.Pipeline.warnIfFunctionNotRegistered(e),this._stack.push(e)}),this)},I.Pipeline.prototype.after=function(e,t){I.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");r+=1,this._stack.splice(r,0,t)},I.Pipeline.prototype.before=function(e,t){I.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");this._stack.splice(r,0,t)},I.Pipeline.prototype.remove=function(e){var t=this._stack.indexOf(e);-1!=t&&this._stack.splice(t,1)},I.Pipeline.prototype.run=function(e){for(var t=this._stack.length,r=0;r<t;r++){for(var i=this._stack[r],n=[],s=0;s<e.length;s++){var o=i(e[s],s,e);if(null!=o&&""!==o)if(Array.isArray(o))for(var a=0;a<o.length;a++)n.push(o[a]);else n.push(o)}e=n}return e},I.Pipeline.prototype.runString=function(e,t){var r=new I.Token(e,t);return this.run([r]).map((function(e){return e.toString()}))},I.Pipeline.prototype.reset=function(){this._stack=[]},I.Pipeline.prototype.toJSON=function(){return this._stack.map((function(e){return I.Pipeline.warnIfFunctionNotRegistered(e),e.label}))},I.Vector=function(e){this._magnitude=0,this.elements=e||[]},I.Vector.prototype.positionForIndex=function(e){if(0==this.elements.length)return 0;for(var t=0,r=this.elements.length/2,i=r-t,n=Math.floor(i/2),s=this.elements[2*n];i>1&&(s<e&&(t=n),s>e&&(r=n),s!=e);)i=r-t,n=t+Math.floor(i/2),s=this.elements[2*n];return s==e||s>e?2*n:s<e?2*(n+1):void 0},I.Vector.prototype.insert=function(e,t){this.upsert(e,t,(function(){throw"duplicate index"}))},I.Vector.prototype.upsert=function(e,t,r){this._magnitude=0;var i=this.positionForIndex(e);this.elements[i]==e?this.elements[i+1]=r(this.elements[i+1],t):this.elements.splice(i,0,e,t)},I.Vector.prototype.magnitude=function(){if(this._magnitude)return this._magnitude;for(var e=0,t=this.elements.length,r=1;r<t;r+=2){var i=this.elements[r];e+=i*i}return this._magnitude=Math.sqrt(e)},I.Vector.prototype.dot=function(e){for(var t=0,r=this.elements,i=e.elements,n=r.length,s=i.length,o=0,a=0,u=0,l=0;u<n&&l<s;)(o=r[u])<(a=i[l])?u+=2:o>a?l+=2:o==a&&(t+=r[u+1]*i[l+1],u+=2,l+=2);return t},I.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},I.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),t=1,r=0;t<this.elements.length;t+=2,r++)e[r]=this.elements[t];return e},I.Vector.prototype.toJSON=function(){return this.elements},I.stemmer=(o={ational:"ate",tional:"tion",enci:"ence",anci:"ance",izer:"ize",bli:"ble",alli:"al",entli:"ent",eli:"e",ousli:"ous",ization:"ize",ation:"ate",ator:"ate",alism:"al",iveness:"ive",fulness:"ful",ousness:"ous",aliti:"al",iviti:"ive",biliti:"ble",logi:"log"},a={icate:"ic",ative:"",alize:"al",iciti:"ic",ical:"ic",ful:"",ness:""},u="[aeiouy]",l="[^aeiou][^aeiouy]*",c=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),h=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),d=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*([aeiouy][aeiou]*)?$"),f=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy]"),p=/^(.+?)(ss|i)es$/,y=/^(.+?)([^s])s$/,m=/^(.+?)eed$/,g=/^(.+?)(ed|ing)$/,x=/.$/,R=/(at|bl|iz)$/,v=new RegExp("([^aeiouylsz])\\1$"),w=new RegExp("^"+l+u+"[^aeiouwxy]$"),Q=/^(.+?[^aeiou])y$/,k=/^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/,S=/^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/,E=/^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/,b=/^(.+?)(s|t)(ion)$/,L=/^(.+?)e$/,P=/ll$/,T=new RegExp("^"+l+u+"[^aeiouwxy]$"),O=function(e){var t,r,i,n,s,u,l;if(e.length<3)return e;if("y"==(i=e.substr(0,1))&&(e=i.toUpperCase()+e.substr(1)),s=y,(n=p).test(e)?e=e.replace(n,"$1$2"):s.test(e)&&(e=e.replace(s,"$1$2")),s=g,(n=m).test(e)){var O=n.exec(e);(n=c).test(O[1])&&(n=x,e=e.replace(n,""))}else s.test(e)&&(t=(O=s.exec(e))[1],(s=f).test(t)&&(u=v,l=w,(s=R).test(e=t)?e+="e":u.test(e)?(n=x,e=e.replace(n,"")):l.test(e)&&(e+="e")));return(n=Q).test(e)&&(e=(t=(O=n.exec(e))[1])+"i"),(n=k).test(e)&&(t=(O=n.exec(e))[1],r=O[2],(n=c).test(t)&&(e=t+o[r])),(n=S).test(e)&&(t=(O=n.exec(e))[1],r=O[2],(n=c).test(t)&&(e=t+a[r])),s=b,(n=E).test(e)?(t=(O=n.exec(e))[1],(n=h).test(t)&&(e=t)):s.test(e)&&(t=(O=s.exec(e))[1]+O[2],(s=h).test(t)&&(e=t)),(n=L).test(e)&&(t=(O=n.exec(e))[1],s=d,u=T,((n=h).test(t)||s.test(t)&&!u.test(t))&&(e=t)),s=h,(n=P).test(e)&&s.test(e)&&(n=x,e=e.replace(n,"")),"y"==i&&(e=i.toLowerCase()+e.substr(1)),e},function(e){return e.update(O)}),I.Pipeline.registerFunction(I.stemmer,"stemmer"),I.generateStopWordFilter=function(e){var t=e.reduce((function(e,t){return e[t]=t,e}),{});return function(e){if(e&&t[e.toString()]!==e.toString())return e}},I.stopWordFilter=I.generateStopWordFilter(["a","able","about","across","after","all","almost","also","am","among","an","and","any","are","as","at","be","because","been","but","by","can","cannot","could","dear","did","do","does","either","else","ever","every","for","from","get","got","had","has","have","he","her","hers","him","his","how","however","i","if","in","into","is","it","its","just","least","let","like","likely","may","me","might","most","must","my","neither","no","nor","not","of","off","often","on","only","or","other","our","own","rather","said","say","says","she","should","since","so","some","than","that","the","their","them","then","there","these","they","this","tis","to","too","twas","us","wants","was","we","were","what","when","where","which","while","who","whom","why","will","with","would","yet","you","your"]),I.Pipeline.registerFunction(I.stopWordFilter,"stopWordFilter"),I.trimmer=function(e){return e.update((function(e){return e.replace(/^\W+/,"").replace(/\W+$/,"")}))},I.Pipeline.registerFunction(I.trimmer,"trimmer"),I.TokenSet=function(){this.final=!1,this.edges={},this.id=I.TokenSet._nextId,I.TokenSet._nextId+=1},I.TokenSet._nextId=1,I.TokenSet.fromArray=function(e){for(var t=new I.TokenSet.Builder,r=0,i=e.length;r<i;r++)t.insert(e[r]);return t.finish(),t.root},I.TokenSet.fromClause=function(e){return"editDistance"in e?I.TokenSet.fromFuzzyString(e.term,e.editDistance):I.TokenSet.fromString(e.term)},I.TokenSet.fromFuzzyString=function(e,t){for(var r=new I.TokenSet,i=[{node:r,editsRemaining:t,str:e}];i.length;){var n=i.pop();if(n.str.length>0){var s,o=n.str.charAt(0);o in n.node.edges?s=n.node.edges[o]:(s=new I.TokenSet,n.node.edges[o]=s),1==n.str.length&&(s.final=!0),i.push({node:s,editsRemaining:n.editsRemaining,str:n.str.slice(1)})}if(0!=n.editsRemaining){if("*"in n.node.edges)var a=n.node.edges["*"];else a=new I.TokenSet,n.node.edges["*"]=a;if(0==n.str.length&&(a.final=!0),i.push({node:a,editsRemaining:n.editsRemaining-1,str:n.str}),n.str.length>1&&i.push({node:n.node,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)}),1==n.str.length&&(n.node.final=!0),n.str.length>=1){if("*"in n.node.edges)var u=n.node.edges["*"];else u=new I.TokenSet,n.node.edges["*"]=u;1==n.str.length&&(u.final=!0),i.push({node:u,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)})}if(n.str.length>1){var l,c=n.str.charAt(0),h=n.str.charAt(1);h in n.node.edges?l=n.node.edges[h]:(l=new I.TokenSet,n.node.edges[h]=l),1==n.str.length&&(l.final=!0),i.push({node:l,editsRemaining:n.editsRemaining-1,str:c+n.str.slice(2)})}}}return r},I.TokenSet.fromString=function(e){for(var t=new I.TokenSet,r=t,i=0,n=e.length;i<n;i++){var s=e[i],o=i==n-1;if("*"==s)t.edges[s]=t,t.final=o;else{var a=new I.TokenSet;a.final=o,t.edges[s]=a,t=a}}return r},I.TokenSet.prototype.toArray=function(){for(var e=[],t=[{prefix:"",node:this}];t.length;){var r=t.pop(),i=Object.keys(r.node.edges),n=i.length;r.node.final&&(r.prefix.charAt(0),e.push(r.prefix));for(var s=0;s<n;s++){var o=i[s];t.push({prefix:r.prefix.concat(o),node:r.node.edges[o]})}}return e},I.TokenSet.prototype.toString=function(){if(this._str)return this._str;for(var e=this.final?"1":"0",t=Object.keys(this.edges).sort(),r=t.length,i=0;i<r;i++){var n=t[i];e=e+n+this.edges[n].id}return e},I.TokenSet.prototype.intersect=function(e){for(var t=new I.TokenSet,r=void 0,i=[{qNode:e,output:t,node:this}];i.length;){r=i.pop();for(var n=Object.keys(r.qNode.edges),s=n.length,o=Object.keys(r.node.edges),a=o.length,u=0;u<s;u++)for(var l=n[u],c=0;c<a;c++){var h=o[c];if(h==l||"*"==l){var d=r.node.edges[h],f=r.qNode.edges[l],p=d.final&&f.final,y=void 0;h in r.output.edges?(y=r.output.edges[h]).final=y.final||p:((y=new I.TokenSet).final=p,r.output.edges[h]=y),i.push({qNode:f,output:y,node:d})}}}return t},I.TokenSet.Builder=function(){this.previousWord="",this.root=new I.TokenSet,this.uncheckedNodes=[],this.minimizedNodes={}},I.TokenSet.Builder.prototype.insert=function(e){var t,r=0;if(e<this.previousWord)throw new Error("Out of order word insertion");for(var i=0;i<e.length&&i<this.previousWord.length&&e[i]==this.previousWord[i];i++)r++;for(this.minimize(r),t=0==this.uncheckedNodes.length?this.root:this.uncheckedNodes[this.uncheckedNodes.length-1].child,i=r;i<e.length;i++){var n=new I.TokenSet,s=e[i];t.edges[s]=n,this.uncheckedNodes.push({parent:t,char:s,child:n}),t=n}t.final=!0,this.previousWord=e},I.TokenSet.Builder.prototype.finish=function(){this.minimize(0)},I.TokenSet.Builder.prototype.minimize=function(e){for(var t=this.uncheckedNodes.length-1;t>=e;t--){var r=this.uncheckedNodes[t],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}},I.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},I.Index.prototype.search=function(e){return this.query((function(t){new I.QueryParser(e,t).parse()}))},I.Index.prototype.query=function(e){for(var t=new I.Query(this.fields),r=Object.create(null),i=Object.create(null),n=Object.create(null),s=Object.create(null),o=Object.create(null),a=0;a<this.fields.length;a++)i[this.fields[a]]=new I.Vector;for(e.call(t,t),a=0;a<t.clauses.length;a++){var u,l=t.clauses[a],c=I.Set.empty;u=l.usePipeline?this.pipeline.runString(l.term,{fields:l.fields}):[l.term];for(var h=0;h<u.length;h++){var d=u[h];l.term=d;var f=I.TokenSet.fromClause(l),p=this.tokenSet.intersect(f).toArray();if(0===p.length&&l.presence===I.Query.presence.REQUIRED){for(var y=0;y<l.fields.length;y++)s[F=l.fields[y]]=I.Set.empty;break}for(var m=0;m<p.length;m++){var g=p[m],x=this.invertedIndex[g],R=x._index;for(y=0;y<l.fields.length;y++){var v=x[F=l.fields[y]],w=Object.keys(v),Q=g+"/"+F,k=new I.Set(w);if(l.presence==I.Query.presence.REQUIRED&&(c=c.union(k),void 0===s[F]&&(s[F]=I.Set.complete)),l.presence!=I.Query.presence.PROHIBITED){if(i[F].upsert(R,l.boost,(function(e,t){return e+t})),!n[Q]){for(var S=0;S<w.length;S++){var E,b=w[S],L=new I.FieldRef(b,F),P=v[b];void 0===(E=r[L])?r[L]=new I.MatchData(g,F,P):E.add(g,F,P)}n[Q]=!0}}else void 0===o[F]&&(o[F]=I.Set.empty),o[F]=o[F].union(k)}}}if(l.presence===I.Query.presence.REQUIRED)for(y=0;y<l.fields.length;y++)s[F=l.fields[y]]=s[F].intersect(c)}var T=I.Set.complete,O=I.Set.empty;for(a=0;a<this.fields.length;a++){var F;s[F=this.fields[a]]&&(T=T.intersect(s[F])),o[F]&&(O=O.union(o[F]))}var C=Object.keys(r),j=[],N=Object.create(null);if(t.isNegated())for(C=Object.keys(this.fieldVectors),a=0;a<C.length;a++){L=C[a];var _=I.FieldRef.fromString(L);r[L]=new I.MatchData}for(a=0;a<C.length;a++){var D=(_=I.FieldRef.fromString(C[a])).docRef;if(T.contains(D)&&!O.contains(D)){var A,B=this.fieldVectors[_],V=i[_.fieldName].similarity(B);if(void 0!==(A=N[D]))A.score+=V,A.matchData.combine(r[_]);else{var z={ref:D,score:V,matchData:r[_]};N[D]=z,j.push(z)}}}return j.sort((function(e,t){return t.score-e.score}))},I.Index.prototype.toJSON=function(){var e=Object.keys(this.invertedIndex).sort().map((function(e){return[e,this.invertedIndex[e]]}),this),t=Object.keys(this.fieldVectors).map((function(e){return[e,this.fieldVectors[e].toJSON()]}),this);return{version:I.version,fields:this.fields,fieldVectors:t,invertedIndex:e,pipeline:this.pipeline.toJSON()}},I.Index.load=function(e){var t={},r={},i=e.fieldVectors,n=Object.create(null),s=e.invertedIndex,o=new I.TokenSet.Builder,a=I.Pipeline.load(e.pipeline);e.version!=I.version&&I.utils.warn("Version mismatch when loading serialised index. Current version of lunr '"+I.version+"' does not match serialized index '"+e.version+"'");for(var u=0;u<i.length;u++){var l=(h=i[u])[0],c=h[1];r[l]=new I.Vector(c)}for(u=0;u<s.length;u++){var h,d=(h=s[u])[0],f=h[1];o.insert(d),n[d]=f}return o.finish(),t.fields=e.fields,t.fieldVectors=r,t.invertedIndex=n,t.tokenSet=o.root,t.pipeline=a,new I.Index(t)},I.Builder=function(){this._ref="id",this._fields=Object.create(null),this._documents=Object.create(null),this.invertedIndex=Object.create(null),this.fieldTermFrequencies={},this.fieldLengths={},this.tokenizer=I.tokenizer,this.pipeline=new I.Pipeline,this.searchPipeline=new I.Pipeline,this.documentCount=0,this._b=.75,this._k1=1.2,this.termIndex=0,this.metadataWhitelist=[]},I.Builder.prototype.ref=function(e){this._ref=e},I.Builder.prototype.field=function(e,t){if(/\//.test(e))throw new RangeError("Field '"+e+"' contains illegal character '/'");this._fields[e]=t||{}},I.Builder.prototype.b=function(e){this._b=e<0?0:e>1?1:e},I.Builder.prototype.k1=function(e){this._k1=e},I.Builder.prototype.add=function(e,t){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=t||{},this.documentCount+=1;for(var n=0;n<i.length;n++){var s=i[n],o=this._fields[s].extractor,a=o?o(e):e[s],u=this.tokenizer(a,{fields:[s]}),l=this.pipeline.run(u),c=new I.FieldRef(r,s),h=Object.create(null);this.fieldTermFrequencies[c]=h,this.fieldLengths[c]=0,this.fieldLengths[c]+=l.length;for(var d=0;d<l.length;d++){var f=l[d];if(null==h[f]&&(h[f]=0),h[f]+=1,null==this.invertedIndex[f]){var p=Object.create(null);p._index=this.termIndex,this.termIndex+=1;for(var y=0;y<i.length;y++)p[i[y]]=Object.create(null);this.invertedIndex[f]=p}null==this.invertedIndex[f][s][r]&&(this.invertedIndex[f][s][r]=Object.create(null));for(var m=0;m<this.metadataWhitelist.length;m++){var g=this.metadataWhitelist[m],x=f.metadata[g];null==this.invertedIndex[f][s][r][g]&&(this.invertedIndex[f][s][r][g]=[]),this.invertedIndex[f][s][r][g].push(x)}}}},I.Builder.prototype.calculateAverageFieldLengths=function(){for(var e=Object.keys(this.fieldLengths),t=e.length,r={},i={},n=0;n<t;n++){var s=I.FieldRef.fromString(e[n]),o=s.fieldName;i[o]||(i[o]=0),i[o]+=1,r[o]||(r[o]=0),r[o]+=this.fieldLengths[s]}var a=Object.keys(this._fields);for(n=0;n<a.length;n++){var u=a[n];r[u]=r[u]/i[u]}this.averageFieldLength=r},I.Builder.prototype.createFieldVectors=function(){for(var e={},t=Object.keys(this.fieldTermFrequencies),r=t.length,i=Object.create(null),n=0;n<r;n++){for(var s=I.FieldRef.fromString(t[n]),o=s.fieldName,a=this.fieldLengths[s],u=new I.Vector,l=this.fieldTermFrequencies[s],c=Object.keys(l),h=c.length,d=this._fields[o].boost||1,f=this._documents[s.docRef].boost||1,p=0;p<h;p++){var y,m,g,x=c[p],R=l[x],v=this.invertedIndex[x]._index;void 0===i[x]?(y=I.idf(this.invertedIndex[x],this.documentCount),i[x]=y):y=i[x],m=y*((this._k1+1)*R)/(this._k1*(1-this._b+this._b*(a/this.averageFieldLength[o]))+R),m*=d,m*=f,g=Math.round(1e3*m)/1e3,u.insert(v,g)}e[s]=u}this.fieldVectors=e},I.Builder.prototype.createTokenSet=function(){this.tokenSet=I.TokenSet.fromArray(Object.keys(this.invertedIndex).sort())},I.Builder.prototype.build=function(){return this.calculateAverageFieldLengths(),this.createFieldVectors(),this.createTokenSet(),new I.Index({invertedIndex:this.invertedIndex,fieldVectors:this.fieldVectors,tokenSet:this.tokenSet,fields:Object.keys(this._fields),pipeline:this.searchPipeline})},I.Builder.prototype.use=function(e){var t=Array.prototype.slice.call(arguments,1);t.unshift(this),e.apply(this,t)},I.MatchData=function(e,t,r){for(var i=Object.create(null),n=Object.keys(r||{}),s=0;s<n.length;s++){var o=n[s];i[o]=r[o].slice()}this.metadata=Object.create(null),void 0!==e&&(this.metadata[e]=Object.create(null),this.metadata[e][t]=i)},I.MatchData.prototype.combine=function(e){for(var t=Object.keys(e.metadata),r=0;r<t.length;r++){var i=t[r],n=Object.keys(e.metadata[i]);null==this.metadata[i]&&(this.metadata[i]=Object.create(null));for(var s=0;s<n.length;s++){var o=n[s],a=Object.keys(e.metadata[i][o]);null==this.metadata[i][o]&&(this.metadata[i][o]=Object.create(null));for(var u=0;u<a.length;u++){var l=a[u];null==this.metadata[i][o][l]?this.metadata[i][o][l]=e.metadata[i][o][l]:this.metadata[i][o][l]=this.metadata[i][o][l].concat(e.metadata[i][o][l])}}}},I.MatchData.prototype.add=function(e,t,r){if(!(e in this.metadata))return this.metadata[e]=Object.create(null),void(this.metadata[e][t]=r);if(t in this.metadata[e])for(var i=Object.keys(r),n=0;n<i.length;n++){var s=i[n];s in this.metadata[e][t]?this.metadata[e][t][s]=this.metadata[e][t][s].concat(r[s]):this.metadata[e][t][s]=r[s]}else this.metadata[e][t]=r},I.Query=function(e){this.clauses=[],this.allFields=e},I.Query.wildcard=new String("*"),I.Query.wildcard.NONE=0,I.Query.wildcard.LEADING=1,I.Query.wildcard.TRAILING=2,I.Query.presence={OPTIONAL:1,REQUIRED:2,PROHIBITED:3},I.Query.prototype.clause=function(e){return"fields"in e||(e.fields=this.allFields),"boost"in e||(e.boost=1),"usePipeline"in e||(e.usePipeline=!0),"wildcard"in e||(e.wildcard=I.Query.wildcard.NONE),e.wildcard&I.Query.wildcard.LEADING&&e.term.charAt(0)!=I.Query.wildcard&&(e.term="*"+e.term),e.wildcard&I.Query.wildcard.TRAILING&&e.term.slice(-1)!=I.Query.wildcard&&(e.term=e.term+"*"),"presence"in e||(e.presence=I.Query.presence.OPTIONAL),this.clauses.push(e),this},I.Query.prototype.isNegated=function(){for(var e=0;e<this.clauses.length;e++)if(this.clauses[e].presence!=I.Query.presence.PROHIBITED)return!1;return!0},I.Query.prototype.term=function(e,t){if(Array.isArray(e))return e.forEach((function(e){this.term(e,I.utils.clone(t))}),this),this;var r=t||{};return r.term=e.toString(),this.clause(r),this},I.QueryParseError=function(e,t,r){this.name="QueryParseError",this.message=e,this.start=t,this.end=r},I.QueryParseError.prototype=new Error,I.QueryLexer=function(e){this.lexemes=[],this.str=e,this.length=e.length,this.pos=0,this.start=0,this.escapeCharPositions=[]},I.QueryLexer.prototype.run=function(){for(var e=I.QueryLexer.lexText;e;)e=e(this)},I.QueryLexer.prototype.sliceString=function(){for(var e=[],t=this.start,r=this.pos,i=0;i<this.escapeCharPositions.length;i++)r=this.escapeCharPositions[i],e.push(this.str.slice(t,r)),t=r+1;return e.push(this.str.slice(t,this.pos)),this.escapeCharPositions.length=0,e.join("")},I.QueryLexer.prototype.emit=function(e){this.lexemes.push({type:e,str:this.sliceString(),start:this.start,end:this.pos}),this.start=this.pos},I.QueryLexer.prototype.escapeCharacter=function(){this.escapeCharPositions.push(this.pos-1),this.pos+=1},I.QueryLexer.prototype.next=function(){if(this.pos>=this.length)return I.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},I.QueryLexer.prototype.width=function(){return this.pos-this.start},I.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},I.QueryLexer.prototype.backup=function(){this.pos-=1},I.QueryLexer.prototype.acceptDigitRun=function(){var e,t;do{t=(e=this.next()).charCodeAt(0)}while(t>47&&t<58);e!=I.QueryLexer.EOS&&this.backup()},I.QueryLexer.prototype.more=function(){return this.pos<this.length},I.QueryLexer.EOS="EOS",I.QueryLexer.FIELD="FIELD",I.QueryLexer.TERM="TERM",I.QueryLexer.EDIT_DISTANCE="EDIT_DISTANCE",I.QueryLexer.BOOST="BOOST",I.QueryLexer.PRESENCE="PRESENCE",I.QueryLexer.lexField=function(e){return e.backup(),e.emit(I.QueryLexer.FIELD),e.ignore(),I.QueryLexer.lexText},I.QueryLexer.lexTerm=function(e){if(e.width()>1&&(e.backup(),e.emit(I.QueryLexer.TERM)),e.ignore(),e.more())return I.QueryLexer.lexText},I.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(I.QueryLexer.EDIT_DISTANCE),I.QueryLexer.lexText},I.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(I.QueryLexer.BOOST),I.QueryLexer.lexText},I.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(I.QueryLexer.TERM)},I.QueryLexer.termSeparator=I.tokenizer.separator,I.QueryLexer.lexText=function(e){for(;;){var t=e.next();if(t==I.QueryLexer.EOS)return I.QueryLexer.lexEOS;if(92!=t.charCodeAt(0)){if(":"==t)return I.QueryLexer.lexField;if("~"==t)return e.backup(),e.width()>0&&e.emit(I.QueryLexer.TERM),I.QueryLexer.lexEditDistance;if("^"==t)return e.backup(),e.width()>0&&e.emit(I.QueryLexer.TERM),I.QueryLexer.lexBoost;if("+"==t&&1===e.width())return e.emit(I.QueryLexer.PRESENCE),I.QueryLexer.lexText;if("-"==t&&1===e.width())return e.emit(I.QueryLexer.PRESENCE),I.QueryLexer.lexText;if(t.match(I.QueryLexer.termSeparator))return I.QueryLexer.lexTerm}else e.escapeCharacter()}},I.QueryParser=function(e,t){this.lexer=new I.QueryLexer(e),this.query=t,this.currentClause={},this.lexemeIdx=0},I.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=I.QueryParser.parseClause;e;)e=e(this);return this.query},I.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},I.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},I.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},I.QueryParser.parseClause=function(e){var t=e.peekLexeme();if(null!=t)switch(t.type){case I.QueryLexer.PRESENCE:return I.QueryParser.parsePresence;case I.QueryLexer.FIELD:return I.QueryParser.parseField;case I.QueryLexer.TERM:return I.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+t.type;throw t.str.length>=1&&(r+=" with value '"+t.str+"'"),new I.QueryParseError(r,t.start,t.end)}},I.QueryParser.parsePresence=function(e){var t=e.consumeLexeme();if(null!=t){switch(t.str){case"-":e.currentClause.presence=I.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=I.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+t.str+"'";throw new I.QueryParseError(r,t.start,t.end)}var i=e.peekLexeme();if(null==i)throw r="expecting term or field, found nothing",new I.QueryParseError(r,t.start,t.end);switch(i.type){case I.QueryLexer.FIELD:return I.QueryParser.parseField;case I.QueryLexer.TERM:return I.QueryParser.parseTerm;default:throw r="expecting term or field, found '"+i.type+"'",new I.QueryParseError(r,i.start,i.end)}}},I.QueryParser.parseField=function(e){var t=e.consumeLexeme();if(null!=t){if(-1==e.query.allFields.indexOf(t.str)){var r=e.query.allFields.map((function(e){return"'"+e+"'"})).join(", "),i="unrecognised field '"+t.str+"', possible fields: "+r;throw new I.QueryParseError(i,t.start,t.end)}e.currentClause.fields=[t.str];var n=e.peekLexeme();if(null==n)throw i="expecting term, found nothing",new I.QueryParseError(i,t.start,t.end);if(n.type===I.QueryLexer.TERM)return I.QueryParser.parseTerm;throw i="expecting term, found '"+n.type+"'",new I.QueryParseError(i,n.start,n.end)}},I.QueryParser.parseTerm=function(e){var t=e.consumeLexeme();if(null!=t){e.currentClause.term=t.str.toLowerCase(),-1!=t.str.indexOf("*")&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(null!=r)switch(r.type){case I.QueryLexer.TERM:return e.nextClause(),I.QueryParser.parseTerm;case I.QueryLexer.FIELD:return e.nextClause(),I.QueryParser.parseField;case I.QueryLexer.EDIT_DISTANCE:return I.QueryParser.parseEditDistance;case I.QueryLexer.BOOST:return I.QueryParser.parseBoost;case I.QueryLexer.PRESENCE:return e.nextClause(),I.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+r.type+"'";throw new I.QueryParseError(i,r.start,r.end)}else e.nextClause()}},I.QueryParser.parseEditDistance=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new I.QueryParseError(i,t.start,t.end)}e.currentClause.editDistance=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case I.QueryLexer.TERM:return e.nextClause(),I.QueryParser.parseTerm;case I.QueryLexer.FIELD:return e.nextClause(),I.QueryParser.parseField;case I.QueryLexer.EDIT_DISTANCE:return I.QueryParser.parseEditDistance;case I.QueryLexer.BOOST:return I.QueryParser.parseBoost;case I.QueryLexer.PRESENCE:return e.nextClause(),I.QueryParser.parsePresence;default:throw i="Unexpected lexeme type '"+n.type+"'",new I.QueryParseError(i,n.start,n.end)}else e.nextClause()}},I.QueryParser.parseBoost=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="boost must be numeric";throw new I.QueryParseError(i,t.start,t.end)}e.currentClause.boost=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case I.QueryLexer.TERM:return e.nextClause(),I.QueryParser.parseTerm;case I.QueryLexer.FIELD:return e.nextClause(),I.QueryParser.parseField;case I.QueryLexer.EDIT_DISTANCE:return I.QueryParser.parseEditDistance;case I.QueryLexer.BOOST:return I.QueryParser.parseBoost;case I.QueryLexer.PRESENCE:return e.nextClause(),I.QueryParser.parsePresence;default:throw i="Unexpected lexeme type '"+n.type+"'",new I.QueryParseError(i,n.start,n.end)}else e.nextClause()}},void 0===(n="function"==typeof(i=function(){return I})?i.call(t,r,t,e):i)||(e.exports=n)}()},567:(e,t,r)=>{var i=r(314),n=["add","done","toJS","fromExternalJS","load","dispose","search","Worker"];e.exports=function(){var e=new Worker(URL.createObjectURL(new Blob(['/*! For license information please see c583fb27fbae15fc4e3d.worker.js.LICENSE.txt */\n(()=>{var e={336:(e,t,r)=>{var i,n;!function(){var s,o,a,u,l,c,h,d,f,p,y,m,g,x,v,w,Q,k,S,E,P,L,b,T,O,I,R=function(e){var t=new R.Builder;return t.pipeline.add(R.trimmer,R.stopWordFilter,R.stemmer),t.searchPipeline.add(R.stemmer),e.call(t,t),t.build()};R.version="2.3.9",R.utils={},R.utils.warn=(s=this,function(e){s.console&&console.warn&&console.warn(e)}),R.utils.asString=function(e){return null==e?"":e.toString()},R.utils.clone=function(e){if(null==e)return e;for(var t=Object.create(null),r=Object.keys(e),i=0;i<r.length;i++){var n=r[i],s=e[n];if(Array.isArray(s))t[n]=s.slice();else{if("string"!=typeof s&&"number"!=typeof s&&"boolean"!=typeof s)throw new TypeError("clone is not deep and does not support nested objects");t[n]=s}}return t},R.FieldRef=function(e,t,r){this.docRef=e,this.fieldName=t,this._stringValue=r},R.FieldRef.joiner="/",R.FieldRef.fromString=function(e){var t=e.indexOf(R.FieldRef.joiner);if(-1===t)throw"malformed field ref string";var r=e.slice(0,t),i=e.slice(t+1);return new R.FieldRef(i,r,e)},R.FieldRef.prototype.toString=function(){return null==this._stringValue&&(this._stringValue=this.fieldName+R.FieldRef.joiner+this.docRef),this._stringValue},R.Set=function(e){if(this.elements=Object.create(null),e){this.length=e.length;for(var t=0;t<this.length;t++)this.elements[e[t]]=!0}else this.length=0},R.Set.complete={intersect:function(e){return e},union:function(){return this},contains:function(){return!0}},R.Set.empty={intersect:function(){return this},union:function(e){return e},contains:function(){return!1}},R.Set.prototype.contains=function(e){return!!this.elements[e]},R.Set.prototype.intersect=function(e){var t,r,i,n=[];if(e===R.Set.complete)return this;if(e===R.Set.empty)return e;this.length<e.length?(t=this,r=e):(t=e,r=this),i=Object.keys(t.elements);for(var s=0;s<i.length;s++){var o=i[s];o in r.elements&&n.push(o)}return new R.Set(n)},R.Set.prototype.union=function(e){return e===R.Set.complete?R.Set.complete:e===R.Set.empty?this:new R.Set(Object.keys(this.elements).concat(Object.keys(e.elements)))},R.idf=function(e,t){var r=0;for(var i in e)"_index"!=i&&(r+=Object.keys(e[i]).length);var n=(t-r+.5)/(r+.5);return Math.log(1+Math.abs(n))},R.Token=function(e,t){this.str=e||"",this.metadata=t||{}},R.Token.prototype.toString=function(){return this.str},R.Token.prototype.update=function(e){return this.str=e(this.str,this.metadata),this},R.Token.prototype.clone=function(e){return e=e||function(e){return e},new R.Token(e(this.str,this.metadata),this.metadata)},R.tokenizer=function(e,t){if(null==e||null==e)return[];if(Array.isArray(e))return e.map((function(e){return new R.Token(R.utils.asString(e).toLowerCase(),R.utils.clone(t))}));for(var r=e.toString().toLowerCase(),i=r.length,n=[],s=0,o=0;s<=i;s++){var a=s-o;if(r.charAt(s).match(R.tokenizer.separator)||s==i){if(a>0){var u=R.utils.clone(t)||{};u.position=[o,a],u.index=n.length,n.push(new R.Token(r.slice(o,s),u))}o=s+1}}return n},R.tokenizer.separator=/[\\s\\-]+/,R.Pipeline=function(){this._stack=[]},R.Pipeline.registeredFunctions=Object.create(null),R.Pipeline.registerFunction=function(e,t){t in this.registeredFunctions&&R.utils.warn("Overwriting existing registered function: "+t),e.label=t,R.Pipeline.registeredFunctions[e.label]=e},R.Pipeline.warnIfFunctionNotRegistered=function(e){e.label&&e.label in this.registeredFunctions||R.utils.warn("Function is not registered with pipeline. This may cause problems when serialising the index.\\n",e)},R.Pipeline.load=function(e){var t=new R.Pipeline;return e.forEach((function(e){var r=R.Pipeline.registeredFunctions[e];if(!r)throw new Error("Cannot load unregistered function: "+e);t.add(r)})),t},R.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach((function(e){R.Pipeline.warnIfFunctionNotRegistered(e),this._stack.push(e)}),this)},R.Pipeline.prototype.after=function(e,t){R.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");r+=1,this._stack.splice(r,0,t)},R.Pipeline.prototype.before=function(e,t){R.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");this._stack.splice(r,0,t)},R.Pipeline.prototype.remove=function(e){var t=this._stack.indexOf(e);-1!=t&&this._stack.splice(t,1)},R.Pipeline.prototype.run=function(e){for(var t=this._stack.length,r=0;r<t;r++){for(var i=this._stack[r],n=[],s=0;s<e.length;s++){var o=i(e[s],s,e);if(null!=o&&""!==o)if(Array.isArray(o))for(var a=0;a<o.length;a++)n.push(o[a]);else n.push(o)}e=n}return e},R.Pipeline.prototype.runString=function(e,t){var r=new R.Token(e,t);return this.run([r]).map((function(e){return e.toString()}))},R.Pipeline.prototype.reset=function(){this._stack=[]},R.Pipeline.prototype.toJSON=function(){return this._stack.map((function(e){return R.Pipeline.warnIfFunctionNotRegistered(e),e.label}))},R.Vector=function(e){this._magnitude=0,this.elements=e||[]},R.Vector.prototype.positionForIndex=function(e){if(0==this.elements.length)return 0;for(var t=0,r=this.elements.length/2,i=r-t,n=Math.floor(i/2),s=this.elements[2*n];i>1&&(s<e&&(t=n),s>e&&(r=n),s!=e);)i=r-t,n=t+Math.floor(i/2),s=this.elements[2*n];return s==e||s>e?2*n:s<e?2*(n+1):void 0},R.Vector.prototype.insert=function(e,t){this.upsert(e,t,(function(){throw"duplicate index"}))},R.Vector.prototype.upsert=function(e,t,r){this._magnitude=0;var i=this.positionForIndex(e);this.elements[i]==e?this.elements[i+1]=r(this.elements[i+1],t):this.elements.splice(i,0,e,t)},R.Vector.prototype.magnitude=function(){if(this._magnitude)return this._magnitude;for(var e=0,t=this.elements.length,r=1;r<t;r+=2){var i=this.elements[r];e+=i*i}return this._magnitude=Math.sqrt(e)},R.Vector.prototype.dot=function(e){for(var t=0,r=this.elements,i=e.elements,n=r.length,s=i.length,o=0,a=0,u=0,l=0;u<n&&l<s;)(o=r[u])<(a=i[l])?u+=2:o>a?l+=2:o==a&&(t+=r[u+1]*i[l+1],u+=2,l+=2);return t},R.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},R.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),t=1,r=0;t<this.elements.length;t+=2,r++)e[r]=this.elements[t];return e},R.Vector.prototype.toJSON=function(){return this.elements},R.stemmer=(o={ational:"ate",tional:"tion",enci:"ence",anci:"ance",izer:"ize",bli:"ble",alli:"al",entli:"ent",eli:"e",ousli:"ous",ization:"ize",ation:"ate",ator:"ate",alism:"al",iveness:"ive",fulness:"ful",ousness:"ous",aliti:"al",iviti:"ive",biliti:"ble",logi:"log"},a={icate:"ic",ative:"",alize:"al",iciti:"ic",ical:"ic",ful:"",ness:""},u="[aeiouy]",l="[^aeiou][^aeiouy]*",c=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),h=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),d=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*([aeiouy][aeiou]*)?$"),f=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy]"),p=/^(.+?)(ss|i)es$/,y=/^(.+?)([^s])s$/,m=/^(.+?)eed$/,g=/^(.+?)(ed|ing)$/,x=/.$/,v=/(at|bl|iz)$/,w=new RegExp("([^aeiouylsz])\\\\1$"),Q=new RegExp("^"+l+u+"[^aeiouwxy]$"),k=/^(.+?[^aeiou])y$/,S=/^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/,E=/^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/,P=/^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/,L=/^(.+?)(s|t)(ion)$/,b=/^(.+?)e$/,T=/ll$/,O=new RegExp("^"+l+u+"[^aeiouwxy]$"),I=function(e){var t,r,i,n,s,u,l;if(e.length<3)return e;if("y"==(i=e.substr(0,1))&&(e=i.toUpperCase()+e.substr(1)),s=y,(n=p).test(e)?e=e.replace(n,"$1$2"):s.test(e)&&(e=e.replace(s,"$1$2")),s=g,(n=m).test(e)){var I=n.exec(e);(n=c).test(I[1])&&(n=x,e=e.replace(n,""))}else s.test(e)&&(t=(I=s.exec(e))[1],(s=f).test(t)&&(u=w,l=Q,(s=v).test(e=t)?e+="e":u.test(e)?(n=x,e=e.replace(n,"")):l.test(e)&&(e+="e")));return(n=k).test(e)&&(e=(t=(I=n.exec(e))[1])+"i"),(n=S).test(e)&&(t=(I=n.exec(e))[1],r=I[2],(n=c).test(t)&&(e=t+o[r])),(n=E).test(e)&&(t=(I=n.exec(e))[1],r=I[2],(n=c).test(t)&&(e=t+a[r])),s=L,(n=P).test(e)?(t=(I=n.exec(e))[1],(n=h).test(t)&&(e=t)):s.test(e)&&(t=(I=s.exec(e))[1]+I[2],(s=h).test(t)&&(e=t)),(n=b).test(e)&&(t=(I=n.exec(e))[1],s=d,u=O,((n=h).test(t)||s.test(t)&&!u.test(t))&&(e=t)),s=h,(n=T).test(e)&&s.test(e)&&(n=x,e=e.replace(n,"")),"y"==i&&(e=i.toLowerCase()+e.substr(1)),e},function(e){return e.update(I)}),R.Pipeline.registerFunction(R.stemmer,"stemmer"),R.generateStopWordFilter=function(e){var t=e.reduce((function(e,t){return e[t]=t,e}),{});return function(e){if(e&&t[e.toString()]!==e.toString())return e}},R.stopWordFilter=R.generateStopWordFilter(["a","able","about","across","after","all","almost","also","am","among","an","and","any","are","as","at","be","because","been","but","by","can","cannot","could","dear","did","do","does","either","else","ever","every","for","from","get","got","had","has","have","he","her","hers","him","his","how","however","i","if","in","into","is","it","its","just","least","let","like","likely","may","me","might","most","must","my","neither","no","nor","not","of","off","often","on","only","or","other","our","own","rather","said","say","says","she","should","since","so","some","than","that","the","their","them","then","there","these","they","this","tis","to","too","twas","us","wants","was","we","were","what","when","where","which","while","who","whom","why","will","with","would","yet","you","your"]),R.Pipeline.registerFunction(R.stopWordFilter,"stopWordFilter"),R.trimmer=function(e){return e.update((function(e){return e.replace(/^\\W+/,"").replace(/\\W+$/,"")}))},R.Pipeline.registerFunction(R.trimmer,"trimmer"),R.TokenSet=function(){this.final=!1,this.edges={},this.id=R.TokenSet._nextId,R.TokenSet._nextId+=1},R.TokenSet._nextId=1,R.TokenSet.fromArray=function(e){for(var t=new R.TokenSet.Builder,r=0,i=e.length;r<i;r++)t.insert(e[r]);return t.finish(),t.root},R.TokenSet.fromClause=function(e){return"editDistance"in e?R.TokenSet.fromFuzzyString(e.term,e.editDistance):R.TokenSet.fromString(e.term)},R.TokenSet.fromFuzzyString=function(e,t){for(var r=new R.TokenSet,i=[{node:r,editsRemaining:t,str:e}];i.length;){var n=i.pop();if(n.str.length>0){var s,o=n.str.charAt(0);o in n.node.edges?s=n.node.edges[o]:(s=new R.TokenSet,n.node.edges[o]=s),1==n.str.length&&(s.final=!0),i.push({node:s,editsRemaining:n.editsRemaining,str:n.str.slice(1)})}if(0!=n.editsRemaining){if("*"in n.node.edges)var a=n.node.edges["*"];else a=new R.TokenSet,n.node.edges["*"]=a;if(0==n.str.length&&(a.final=!0),i.push({node:a,editsRemaining:n.editsRemaining-1,str:n.str}),n.str.length>1&&i.push({node:n.node,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)}),1==n.str.length&&(n.node.final=!0),n.str.length>=1){if("*"in n.node.edges)var u=n.node.edges["*"];else u=new R.TokenSet,n.node.edges["*"]=u;1==n.str.length&&(u.final=!0),i.push({node:u,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)})}if(n.str.length>1){var l,c=n.str.charAt(0),h=n.str.charAt(1);h in n.node.edges?l=n.node.edges[h]:(l=new R.TokenSet,n.node.edges[h]=l),1==n.str.length&&(l.final=!0),i.push({node:l,editsRemaining:n.editsRemaining-1,str:c+n.str.slice(2)})}}}return r},R.TokenSet.fromString=function(e){for(var t=new R.TokenSet,r=t,i=0,n=e.length;i<n;i++){var s=e[i],o=i==n-1;if("*"==s)t.edges[s]=t,t.final=o;else{var a=new R.TokenSet;a.final=o,t.edges[s]=a,t=a}}return r},R.TokenSet.prototype.toArray=function(){for(var e=[],t=[{prefix:"",node:this}];t.length;){var r=t.pop(),i=Object.keys(r.node.edges),n=i.length;r.node.final&&(r.prefix.charAt(0),e.push(r.prefix));for(var s=0;s<n;s++){var o=i[s];t.push({prefix:r.prefix.concat(o),node:r.node.edges[o]})}}return e},R.TokenSet.prototype.toString=function(){if(this._str)return this._str;for(var e=this.final?"1":"0",t=Object.keys(this.edges).sort(),r=t.length,i=0;i<r;i++){var n=t[i];e=e+n+this.edges[n].id}return e},R.TokenSet.prototype.intersect=function(e){for(var t=new R.TokenSet,r=void 0,i=[{qNode:e,output:t,node:this}];i.length;){r=i.pop();for(var n=Object.keys(r.qNode.edges),s=n.length,o=Object.keys(r.node.edges),a=o.length,u=0;u<s;u++)for(var l=n[u],c=0;c<a;c++){var h=o[c];if(h==l||"*"==l){var d=r.node.edges[h],f=r.qNode.edges[l],p=d.final&&f.final,y=void 0;h in r.output.edges?(y=r.output.edges[h]).final=y.final||p:((y=new R.TokenSet).final=p,r.output.edges[h]=y),i.push({qNode:f,output:y,node:d})}}}return t},R.TokenSet.Builder=function(){this.previousWord="",this.root=new R.TokenSet,this.uncheckedNodes=[],this.minimizedNodes={}},R.TokenSet.Builder.prototype.insert=function(e){var t,r=0;if(e<this.previousWord)throw new Error("Out of order word insertion");for(var i=0;i<e.length&&i<this.previousWord.length&&e[i]==this.previousWord[i];i++)r++;for(this.minimize(r),t=0==this.uncheckedNodes.length?this.root:this.uncheckedNodes[this.uncheckedNodes.length-1].child,i=r;i<e.length;i++){var n=new R.TokenSet,s=e[i];t.edges[s]=n,this.uncheckedNodes.push({parent:t,char:s,child:n}),t=n}t.final=!0,this.previousWord=e},R.TokenSet.Builder.prototype.finish=function(){this.minimize(0)},R.TokenSet.Builder.prototype.minimize=function(e){for(var t=this.uncheckedNodes.length-1;t>=e;t--){var r=this.uncheckedNodes[t],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}},R.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},R.Index.prototype.search=function(e){return this.query((function(t){new R.QueryParser(e,t).parse()}))},R.Index.prototype.query=function(e){for(var t=new R.Query(this.fields),r=Object.create(null),i=Object.create(null),n=Object.create(null),s=Object.create(null),o=Object.create(null),a=0;a<this.fields.length;a++)i[this.fields[a]]=new R.Vector;for(e.call(t,t),a=0;a<t.clauses.length;a++){var u,l=t.clauses[a],c=R.Set.empty;u=l.usePipeline?this.pipeline.runString(l.term,{fields:l.fields}):[l.term];for(var h=0;h<u.length;h++){var d=u[h];l.term=d;var f=R.TokenSet.fromClause(l),p=this.tokenSet.intersect(f).toArray();if(0===p.length&&l.presence===R.Query.presence.REQUIRED){for(var y=0;y<l.fields.length;y++)s[F=l.fields[y]]=R.Set.empty;break}for(var m=0;m<p.length;m++){var g=p[m],x=this.invertedIndex[g],v=x._index;for(y=0;y<l.fields.length;y++){var w=x[F=l.fields[y]],Q=Object.keys(w),k=g+"/"+F,S=new R.Set(Q);if(l.presence==R.Query.presence.REQUIRED&&(c=c.union(S),void 0===s[F]&&(s[F]=R.Set.complete)),l.presence!=R.Query.presence.PROHIBITED){if(i[F].upsert(v,l.boost,(function(e,t){return e+t})),!n[k]){for(var E=0;E<Q.length;E++){var P,L=Q[E],b=new R.FieldRef(L,F),T=w[L];void 0===(P=r[b])?r[b]=new R.MatchData(g,F,T):P.add(g,F,T)}n[k]=!0}}else void 0===o[F]&&(o[F]=R.Set.empty),o[F]=o[F].union(S)}}}if(l.presence===R.Query.presence.REQUIRED)for(y=0;y<l.fields.length;y++)s[F=l.fields[y]]=s[F].intersect(c)}var O=R.Set.complete,I=R.Set.empty;for(a=0;a<this.fields.length;a++){var F;s[F=this.fields[a]]&&(O=O.intersect(s[F])),o[F]&&(I=I.union(o[F]))}var C=Object.keys(r),N=[],j=Object.create(null);if(t.isNegated())for(C=Object.keys(this.fieldVectors),a=0;a<C.length;a++){b=C[a];var _=R.FieldRef.fromString(b);r[b]=new R.MatchData}for(a=0;a<C.length;a++){var D=(_=R.FieldRef.fromString(C[a])).docRef;if(O.contains(D)&&!I.contains(D)){var A,B=this.fieldVectors[_],z=i[_.fieldName].similarity(B);if(void 0!==(A=j[D]))A.score+=z,A.matchData.combine(r[_]);else{var V={ref:D,score:z,matchData:r[_]};j[D]=V,N.push(V)}}}return N.sort((function(e,t){return t.score-e.score}))},R.Index.prototype.toJSON=function(){var e=Object.keys(this.invertedIndex).sort().map((function(e){return[e,this.invertedIndex[e]]}),this),t=Object.keys(this.fieldVectors).map((function(e){return[e,this.fieldVectors[e].toJSON()]}),this);return{version:R.version,fields:this.fields,fieldVectors:t,invertedIndex:e,pipeline:this.pipeline.toJSON()}},R.Index.load=function(e){var t={},r={},i=e.fieldVectors,n=Object.create(null),s=e.invertedIndex,o=new R.TokenSet.Builder,a=R.Pipeline.load(e.pipeline);e.version!=R.version&&R.utils.warn("Version mismatch when loading serialised index. Current version of lunr \'"+R.version+"\' does not match serialized index \'"+e.version+"\'");for(var u=0;u<i.length;u++){var l=(h=i[u])[0],c=h[1];r[l]=new R.Vector(c)}for(u=0;u<s.length;u++){var h,d=(h=s[u])[0],f=h[1];o.insert(d),n[d]=f}return o.finish(),t.fields=e.fields,t.fieldVectors=r,t.invertedIndex=n,t.tokenSet=o.root,t.pipeline=a,new R.Index(t)},R.Builder=function(){this._ref="id",this._fields=Object.create(null),this._documents=Object.create(null),this.invertedIndex=Object.create(null),this.fieldTermFrequencies={},this.fieldLengths={},this.tokenizer=R.tokenizer,this.pipeline=new R.Pipeline,this.searchPipeline=new R.Pipeline,this.documentCount=0,this._b=.75,this._k1=1.2,this.termIndex=0,this.metadataWhitelist=[]},R.Builder.prototype.ref=function(e){this._ref=e},R.Builder.prototype.field=function(e,t){if(/\\//.test(e))throw new RangeError("Field \'"+e+"\' contains illegal character \'/\'");this._fields[e]=t||{}},R.Builder.prototype.b=function(e){this._b=e<0?0:e>1?1:e},R.Builder.prototype.k1=function(e){this._k1=e},R.Builder.prototype.add=function(e,t){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=t||{},this.documentCount+=1;for(var n=0;n<i.length;n++){var s=i[n],o=this._fields[s].extractor,a=o?o(e):e[s],u=this.tokenizer(a,{fields:[s]}),l=this.pipeline.run(u),c=new R.FieldRef(r,s),h=Object.create(null);this.fieldTermFrequencies[c]=h,this.fieldLengths[c]=0,this.fieldLengths[c]+=l.length;for(var d=0;d<l.length;d++){var f=l[d];if(null==h[f]&&(h[f]=0),h[f]+=1,null==this.invertedIndex[f]){var p=Object.create(null);p._index=this.termIndex,this.termIndex+=1;for(var y=0;y<i.length;y++)p[i[y]]=Object.create(null);this.invertedIndex[f]=p}null==this.invertedIndex[f][s][r]&&(this.invertedIndex[f][s][r]=Object.create(null));for(var m=0;m<this.metadataWhitelist.length;m++){var g=this.metadataWhitelist[m],x=f.metadata[g];null==this.invertedIndex[f][s][r][g]&&(this.invertedIndex[f][s][r][g]=[]),this.invertedIndex[f][s][r][g].push(x)}}}},R.Builder.prototype.calculateAverageFieldLengths=function(){for(var e=Object.keys(this.fieldLengths),t=e.length,r={},i={},n=0;n<t;n++){var s=R.FieldRef.fromString(e[n]),o=s.fieldName;i[o]||(i[o]=0),i[o]+=1,r[o]||(r[o]=0),r[o]+=this.fieldLengths[s]}var a=Object.keys(this._fields);for(n=0;n<a.length;n++){var u=a[n];r[u]=r[u]/i[u]}this.averageFieldLength=r},R.Builder.prototype.createFieldVectors=function(){for(var e={},t=Object.keys(this.fieldTermFrequencies),r=t.length,i=Object.create(null),n=0;n<r;n++){for(var s=R.FieldRef.fromString(t[n]),o=s.fieldName,a=this.fieldLengths[s],u=new R.Vector,l=this.fieldTermFrequencies[s],c=Object.keys(l),h=c.length,d=this._fields[o].boost||1,f=this._documents[s.docRef].boost||1,p=0;p<h;p++){var y,m,g,x=c[p],v=l[x],w=this.invertedIndex[x]._index;void 0===i[x]?(y=R.idf(this.invertedIndex[x],this.documentCount),i[x]=y):y=i[x],m=y*((this._k1+1)*v)/(this._k1*(1-this._b+this._b*(a/this.averageFieldLength[o]))+v),m*=d,m*=f,g=Math.round(1e3*m)/1e3,u.insert(w,g)}e[s]=u}this.fieldVectors=e},R.Builder.prototype.createTokenSet=function(){this.tokenSet=R.TokenSet.fromArray(Object.keys(this.invertedIndex).sort())},R.Builder.prototype.build=function(){return this.calculateAverageFieldLengths(),this.createFieldVectors(),this.createTokenSet(),new R.Index({invertedIndex:this.invertedIndex,fieldVectors:this.fieldVectors,tokenSet:this.tokenSet,fields:Object.keys(this._fields),pipeline:this.searchPipeline})},R.Builder.prototype.use=function(e){var t=Array.prototype.slice.call(arguments,1);t.unshift(this),e.apply(this,t)},R.MatchData=function(e,t,r){for(var i=Object.create(null),n=Object.keys(r||{}),s=0;s<n.length;s++){var o=n[s];i[o]=r[o].slice()}this.metadata=Object.create(null),void 0!==e&&(this.metadata[e]=Object.create(null),this.metadata[e][t]=i)},R.MatchData.prototype.combine=function(e){for(var t=Object.keys(e.metadata),r=0;r<t.length;r++){var i=t[r],n=Object.keys(e.metadata[i]);null==this.metadata[i]&&(this.metadata[i]=Object.create(null));for(var s=0;s<n.length;s++){var o=n[s],a=Object.keys(e.metadata[i][o]);null==this.metadata[i][o]&&(this.metadata[i][o]=Object.create(null));for(var u=0;u<a.length;u++){var l=a[u];null==this.metadata[i][o][l]?this.metadata[i][o][l]=e.metadata[i][o][l]:this.metadata[i][o][l]=this.metadata[i][o][l].concat(e.metadata[i][o][l])}}}},R.MatchData.prototype.add=function(e,t,r){if(!(e in this.metadata))return this.metadata[e]=Object.create(null),void(this.metadata[e][t]=r);if(t in this.metadata[e])for(var i=Object.keys(r),n=0;n<i.length;n++){var s=i[n];s in this.metadata[e][t]?this.metadata[e][t][s]=this.metadata[e][t][s].concat(r[s]):this.metadata[e][t][s]=r[s]}else this.metadata[e][t]=r},R.Query=function(e){this.clauses=[],this.allFields=e},R.Query.wildcard=new String("*"),R.Query.wildcard.NONE=0,R.Query.wildcard.LEADING=1,R.Query.wildcard.TRAILING=2,R.Query.presence={OPTIONAL:1,REQUIRED:2,PROHIBITED:3},R.Query.prototype.clause=function(e){return"fields"in e||(e.fields=this.allFields),"boost"in e||(e.boost=1),"usePipeline"in e||(e.usePipeline=!0),"wildcard"in e||(e.wildcard=R.Query.wildcard.NONE),e.wildcard&R.Query.wildcard.LEADING&&e.term.charAt(0)!=R.Query.wildcard&&(e.term="*"+e.term),e.wildcard&R.Query.wildcard.TRAILING&&e.term.slice(-1)!=R.Query.wildcard&&(e.term=e.term+"*"),"presence"in e||(e.presence=R.Query.presence.OPTIONAL),this.clauses.push(e),this},R.Query.prototype.isNegated=function(){for(var e=0;e<this.clauses.length;e++)if(this.clauses[e].presence!=R.Query.presence.PROHIBITED)return!1;return!0},R.Query.prototype.term=function(e,t){if(Array.isArray(e))return e.forEach((function(e){this.term(e,R.utils.clone(t))}),this),this;var r=t||{};return r.term=e.toString(),this.clause(r),this},R.QueryParseError=function(e,t,r){this.name="QueryParseError",this.message=e,this.start=t,this.end=r},R.QueryParseError.prototype=new Error,R.QueryLexer=function(e){this.lexemes=[],this.str=e,this.length=e.length,this.pos=0,this.start=0,this.escapeCharPositions=[]},R.QueryLexer.prototype.run=function(){for(var e=R.QueryLexer.lexText;e;)e=e(this)},R.QueryLexer.prototype.sliceString=function(){for(var e=[],t=this.start,r=this.pos,i=0;i<this.escapeCharPositions.length;i++)r=this.escapeCharPositions[i],e.push(this.str.slice(t,r)),t=r+1;return e.push(this.str.slice(t,this.pos)),this.escapeCharPositions.length=0,e.join("")},R.QueryLexer.prototype.emit=function(e){this.lexemes.push({type:e,str:this.sliceString(),start:this.start,end:this.pos}),this.start=this.pos},R.QueryLexer.prototype.escapeCharacter=function(){this.escapeCharPositions.push(this.pos-1),this.pos+=1},R.QueryLexer.prototype.next=function(){if(this.pos>=this.length)return R.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},R.QueryLexer.prototype.width=function(){return this.pos-this.start},R.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},R.QueryLexer.prototype.backup=function(){this.pos-=1},R.QueryLexer.prototype.acceptDigitRun=function(){var e,t;do{t=(e=this.next()).charCodeAt(0)}while(t>47&&t<58);e!=R.QueryLexer.EOS&&this.backup()},R.QueryLexer.prototype.more=function(){return this.pos<this.length},R.QueryLexer.EOS="EOS",R.QueryLexer.FIELD="FIELD",R.QueryLexer.TERM="TERM",R.QueryLexer.EDIT_DISTANCE="EDIT_DISTANCE",R.QueryLexer.BOOST="BOOST",R.QueryLexer.PRESENCE="PRESENCE",R.QueryLexer.lexField=function(e){return e.backup(),e.emit(R.QueryLexer.FIELD),e.ignore(),R.QueryLexer.lexText},R.QueryLexer.lexTerm=function(e){if(e.width()>1&&(e.backup(),e.emit(R.QueryLexer.TERM)),e.ignore(),e.more())return R.QueryLexer.lexText},R.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(R.QueryLexer.EDIT_DISTANCE),R.QueryLexer.lexText},R.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(R.QueryLexer.BOOST),R.QueryLexer.lexText},R.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(R.QueryLexer.TERM)},R.QueryLexer.termSeparator=R.tokenizer.separator,R.QueryLexer.lexText=function(e){for(;;){var t=e.next();if(t==R.QueryLexer.EOS)return R.QueryLexer.lexEOS;if(92!=t.charCodeAt(0)){if(":"==t)return R.QueryLexer.lexField;if("~"==t)return e.backup(),e.width()>0&&e.emit(R.QueryLexer.TERM),R.QueryLexer.lexEditDistance;if("^"==t)return e.backup(),e.width()>0&&e.emit(R.QueryLexer.TERM),R.QueryLexer.lexBoost;if("+"==t&&1===e.width())return e.emit(R.QueryLexer.PRESENCE),R.QueryLexer.lexText;if("-"==t&&1===e.width())return e.emit(R.QueryLexer.PRESENCE),R.QueryLexer.lexText;if(t.match(R.QueryLexer.termSeparator))return R.QueryLexer.lexTerm}else e.escapeCharacter()}},R.QueryParser=function(e,t){this.lexer=new R.QueryLexer(e),this.query=t,this.currentClause={},this.lexemeIdx=0},R.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=R.QueryParser.parseClause;e;)e=e(this);return this.query},R.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},R.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},R.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},R.QueryParser.parseClause=function(e){var t=e.peekLexeme();if(null!=t)switch(t.type){case R.QueryLexer.PRESENCE:return R.QueryParser.parsePresence;case R.QueryLexer.FIELD:return R.QueryParser.parseField;case R.QueryLexer.TERM:return R.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+t.type;throw t.str.length>=1&&(r+=" with value \'"+t.str+"\'"),new R.QueryParseError(r,t.start,t.end)}},R.QueryParser.parsePresence=function(e){var t=e.consumeLexeme();if(null!=t){switch(t.str){case"-":e.currentClause.presence=R.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=R.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator\'"+t.str+"\'";throw new R.QueryParseError(r,t.start,t.end)}var i=e.peekLexeme();if(null==i)throw r="expecting term or field, found nothing",new R.QueryParseError(r,t.start,t.end);switch(i.type){case R.QueryLexer.FIELD:return R.QueryParser.parseField;case R.QueryLexer.TERM:return R.QueryParser.parseTerm;default:throw r="expecting term or field, found \'"+i.type+"\'",new R.QueryParseError(r,i.start,i.end)}}},R.QueryParser.parseField=function(e){var t=e.consumeLexeme();if(null!=t){if(-1==e.query.allFields.indexOf(t.str)){var r=e.query.allFields.map((function(e){return"\'"+e+"\'"})).join(", "),i="unrecognised field \'"+t.str+"\', possible fields: "+r;throw new R.QueryParseError(i,t.start,t.end)}e.currentClause.fields=[t.str];var n=e.peekLexeme();if(null==n)throw i="expecting term, found nothing",new R.QueryParseError(i,t.start,t.end);if(n.type===R.QueryLexer.TERM)return R.QueryParser.parseTerm;throw i="expecting term, found \'"+n.type+"\'",new R.QueryParseError(i,n.start,n.end)}},R.QueryParser.parseTerm=function(e){var t=e.consumeLexeme();if(null!=t){e.currentClause.term=t.str.toLowerCase(),-1!=t.str.indexOf("*")&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(null!=r)switch(r.type){case R.QueryLexer.TERM:return e.nextClause(),R.QueryParser.parseTerm;case R.QueryLexer.FIELD:return e.nextClause(),R.QueryParser.parseField;case R.QueryLexer.EDIT_DISTANCE:return R.QueryParser.parseEditDistance;case R.QueryLexer.BOOST:return R.QueryParser.parseBoost;case R.QueryLexer.PRESENCE:return e.nextClause(),R.QueryParser.parsePresence;default:var i="Unexpected lexeme type \'"+r.type+"\'";throw new R.QueryParseError(i,r.start,r.end)}else e.nextClause()}},R.QueryParser.parseEditDistance=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new R.QueryParseError(i,t.start,t.end)}e.currentClause.editDistance=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case R.QueryLexer.TERM:return e.nextClause(),R.QueryParser.parseTerm;case R.QueryLexer.FIELD:return e.nextClause(),R.QueryParser.parseField;case R.QueryLexer.EDIT_DISTANCE:return R.QueryParser.parseEditDistance;case R.QueryLexer.BOOST:return R.QueryParser.parseBoost;case R.QueryLexer.PRESENCE:return e.nextClause(),R.QueryParser.parsePresence;default:throw i="Unexpected lexeme type \'"+n.type+"\'",new R.QueryParseError(i,n.start,n.end)}else e.nextClause()}},R.QueryParser.parseBoost=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="boost must be numeric";throw new R.QueryParseError(i,t.start,t.end)}e.currentClause.boost=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case R.QueryLexer.TERM:return e.nextClause(),R.QueryParser.parseTerm;case R.QueryLexer.FIELD:return e.nextClause(),R.QueryParser.parseField;case R.QueryLexer.EDIT_DISTANCE:return R.QueryParser.parseEditDistance;case R.QueryLexer.BOOST:return R.QueryParser.parseBoost;case R.QueryLexer.PRESENCE:return e.nextClause(),R.QueryParser.parsePresence;default:throw i="Unexpected lexeme type \'"+n.type+"\'",new R.QueryParseError(i,n.start,n.end)}else e.nextClause()}},void 0===(n="function"==typeof(i=function(){return R})?i.call(t,r,t,e):i)||(e.exports=n)}()}},t={};function r(i){var n=t[i];if(void 0!==n)return n.exports;var s=t[i]={exports:{}};return e[i](s,s.exports,r),s.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var i in t)r.o(t,i)&&!r.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var i={};(()=>{"use strict";r.d(i,{add:()=>l,done:()=>c,toJS:()=>h,fromExternalJS:()=>d,load:()=>f,dispose:()=>p,search:()=>y});var e=r(336),t=(Object.defineProperty,(e,t,r)=>new Promise(((i,n)=>{var s=e=>{try{a(r.next(e))}catch(e){n(e)}},o=e=>{try{a(r.throw(e))}catch(e){n(e)}},a=e=>e.done?i(e.value):Promise.resolve(e.value).then(s,o);a((r=r.apply(e,t)).next())})));let n,s,o,a=[];function u(){n=new e.Builder,n.field("title"),n.field("description"),n.ref("ref"),n.pipeline.add(e.trimmer,e.stopWordFilter,e.stemmer),o=new Promise((e=>{s=e}))}function l(e,t,r){const i=a.push(r)-1,s={title:e.toLowerCase(),description:t.toLowerCase(),ref:i};n.add(s)}function c(){return t(this,null,(function*(){s(n.build())}))}function h(){return t(this,null,(function*(){return{store:a,index:(yield o).toJSON()}}))}function d(e,r){return t(this,null,(function*(){try{if(importScripts(e),!self[r])throw new Error("Broken index file format");yield f(self[r])}catch(e){console.error("Failed to load search index: "+e.message)}}))}function f(r){return t(this,null,(function*(){a=r.store,s(e.Index.load(r.index))}))}function p(){return t(this,null,(function*(){a=[],u()}))}function y(r,i=0){return t(this,null,(function*(){if(0===r.trim().length)return[];let t=(yield o).query((t=>{r.trim().toLowerCase().split(/\\s+/).forEach((r=>{if(1===r.length)return;const i=(t=>"*"+e.stemmer(new e.Token(t,{}))+"*")(r);t.term(i,{})}))}));return i>0&&(t=t.slice(0,i)),t.map((e=>({meta:a[e.ref],score:e.score})))}))}e.tokenizer.separator=/\\s+/,u(),addEventListener("message",(function(e){var t,r=e.data,n=r.type,s=r.method,o=r.id,a=r.params;"RPC"===n&&s&&((t=i[s])?Promise.resolve().then((function(){return t.apply(i,a)})):Promise.reject("No such method")).then((function(e){postMessage({type:"RPC",id:o,result:e})})).catch((function(e){var t={message:e};e.stack&&(t.message=e.message,t.stack=e.stack,t.name=e.name),postMessage({type:"RPC",id:o,error:t})}))})),postMessage({type:"RPC",method:"ready"})})()})();'])),{name:"[fullhash].worker.js"});return i(e,n),e}},314:e=>{e.exports=function(e,t){var r=0,i={};e.addEventListener("message",(function(t){var r=t.data;if("RPC"===r.type)if(r.id){var n=i[r.id];n&&(delete i[r.id],r.error?n[1](Object.assign(Error(r.error.message),r.error)):n[0](r.result))}else{var s=document.createEvent("Event");s.initEvent(r.method,!1,!1),s.data=r.params,e.dispatchEvent(s)}})),t.forEach((function(t){e[t]=function(){var n=arguments;return new Promise((function(s,o){var a=++r;i[a]=[s,o],e.postMessage({type:"RPC",id:a,method:t,params:[].slice.call(n)})}))}}))}}},t={};function r(i){var n=t[i];if(void 0!==n)return n.exports;var s=t[i]={exports:{}};return e[i](s,s.exports,r),s.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var i in t)r.o(t,i)&&!r.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{"use strict";r.r(i),r.d(i,{SearchStore:()=>n});const e="undefined"!=typeof window&&"HTMLElement"in window;"undefined"==typeof Element||Element.prototype.scrollIntoViewIfNeeded||(Element.prototype.scrollIntoViewIfNeeded=function(e){e=0===arguments.length||!!e;const t=this.parentNode,r=window.getComputedStyle(t,void 0),i=parseInt(r.getPropertyValue("border-top-width"),10),n=parseInt(r.getPropertyValue("border-left-width"),10),s=this.offsetTop-t.offsetTop<t.scrollTop,o=this.offsetTop-t.offsetTop+this.clientHeight-i>t.scrollTop+t.clientHeight,a=this.offsetLeft-t.offsetLeft<t.scrollLeft,u=this.offsetLeft-t.offsetLeft+this.clientWidth-n>t.scrollLeft+t.clientWidth,l=s&&!o;(s||o)&&e&&(t.scrollTop=this.offsetTop-t.offsetTop-t.clientHeight/2-i+this.clientHeight/2),(a||u)&&e&&(t.scrollLeft=this.offsetLeft-t.offsetLeft-t.clientWidth/2-n+this.clientWidth/2),(s||o||a||u)&&!e&&this.scrollIntoView(l)});var t=Object.defineProperty;class n{constructor(){var i,n,s;i=this,n="searchWorker",s=function(){let t;if(e)try{t=r(567)}catch(e){t=r(27).ZP}else t=r(27).ZP;return new t}(),((e,r,i)=>{r in e?t(e,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[r]=i})(i,"symbol"!=typeof n?n+"":n,s)}indexItems(e){const t=e=>{e.forEach((e=>{"group"!==e.type&&this.add(e.name,e.description||"",e.id),t(e.items)}))};t(e),this.searchWorker.done()}add(e,t,r){this.searchWorker.add(e,t,r)}dispose(){this.searchWorker.terminate(),this.searchWorker.dispose()}search(e){return this.searchWorker.search(e)}toJS(){return e=this,null,t=function*(){return this.searchWorker.toJS()},new Promise(((r,i)=>{var n=e=>{try{o(t.next(e))}catch(e){i(e)}},s=e=>{try{o(t.throw(e))}catch(e){i(e)}},o=e=>e.done?r(e.value):Promise.resolve(e.value).then(n,s);o((t=t.apply(e,null)).next())}));var e,t}load(e){this.searchWorker.load(e)}fromExternalJS(e,t){e&&t&&this.searchWorker.fromExternalJS(e,t)}}})(),i})()}));
2
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.SearchStore=t():e.SearchStore=t()}(this,(function(){return(()=>{var e={27:(e,t,r)=>{"use strict";r.d(t,{ZP:()=>a});var i=r(336),n=Object.defineProperty,s=(e,t,r)=>(((e,t,r)=>{t in e?n(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r})(e,"symbol"!=typeof t?t+"":t,r),r),o=(e,t,r)=>new Promise(((i,n)=>{var s=e=>{try{a(r.next(e))}catch(e){n(e)}},o=e=>{try{a(r.throw(e))}catch(e){n(e)}},a=e=>e.done?i(e.value):Promise.resolve(e.value).then(s,o);a((r=r.apply(e,t)).next())}));class a{constructor(){s(this,"add",f),s(this,"done",p),s(this,"search",R),s(this,"toJS",y),s(this,"load",g),s(this,"dispose",x),s(this,"fromExternalJS",m)}}let u,l,c,h=[];function d(){u=new i.Builder,u.field("title"),u.field("description"),u.ref("ref"),u.pipeline.add(i.trimmer,i.stopWordFilter,i.stemmer),c=new Promise((e=>{l=e}))}function f(e,t,r){const i=h.push(r)-1,n={title:e.toLowerCase(),description:t.toLowerCase(),ref:i};u.add(n)}function p(){return o(this,null,(function*(){l(u.build())}))}function y(){return o(this,null,(function*(){return{store:h,index:(yield c).toJSON()}}))}function m(e,t){return o(this,null,(function*(){try{if(importScripts(e),!self[t])throw new Error("Broken index file format");yield g(self[t])}catch(e){console.error("Failed to load search index: "+e.message)}}))}function g(e){return o(this,null,(function*(){h=e.store,l(i.Index.load(e.index))}))}function x(){return o(this,null,(function*(){h=[],d()}))}function R(e,t=0){return o(this,null,(function*(){if(0===e.trim().length)return[];let r=(yield c).query((t=>{e.trim().toLowerCase().split(/\s+/).forEach((e=>{if(1===e.length)return;const r=(e=>"*"+i.stemmer(new i.Token(e,{}))+"*")(e);t.term(r,{})}))}));return t>0&&(r=r.slice(0,t)),r.map((e=>({meta:h[e.ref],score:e.score})))}))}i.tokenizer.separator=/\s+/,d()},336:(e,t,r)=>{var i,n;!function(){var s,o,a,u,l,c,h,d,f,p,y,m,g,x,R,v,w,Q,k,S,E,b,L,P,T,O,I=function(e){var t=new I.Builder;return t.pipeline.add(I.trimmer,I.stopWordFilter,I.stemmer),t.searchPipeline.add(I.stemmer),e.call(t,t),t.build()};I.version="2.3.9",I.utils={},I.utils.warn=(s=this,function(e){s.console&&console.warn&&console.warn(e)}),I.utils.asString=function(e){return null==e?"":e.toString()},I.utils.clone=function(e){if(null==e)return e;for(var t=Object.create(null),r=Object.keys(e),i=0;i<r.length;i++){var n=r[i],s=e[n];if(Array.isArray(s))t[n]=s.slice();else{if("string"!=typeof s&&"number"!=typeof s&&"boolean"!=typeof s)throw new TypeError("clone is not deep and does not support nested objects");t[n]=s}}return t},I.FieldRef=function(e,t,r){this.docRef=e,this.fieldName=t,this._stringValue=r},I.FieldRef.joiner="/",I.FieldRef.fromString=function(e){var t=e.indexOf(I.FieldRef.joiner);if(-1===t)throw"malformed field ref string";var r=e.slice(0,t),i=e.slice(t+1);return new I.FieldRef(i,r,e)},I.FieldRef.prototype.toString=function(){return null==this._stringValue&&(this._stringValue=this.fieldName+I.FieldRef.joiner+this.docRef),this._stringValue},I.Set=function(e){if(this.elements=Object.create(null),e){this.length=e.length;for(var t=0;t<this.length;t++)this.elements[e[t]]=!0}else this.length=0},I.Set.complete={intersect:function(e){return e},union:function(){return this},contains:function(){return!0}},I.Set.empty={intersect:function(){return this},union:function(e){return e},contains:function(){return!1}},I.Set.prototype.contains=function(e){return!!this.elements[e]},I.Set.prototype.intersect=function(e){var t,r,i,n=[];if(e===I.Set.complete)return this;if(e===I.Set.empty)return e;this.length<e.length?(t=this,r=e):(t=e,r=this),i=Object.keys(t.elements);for(var s=0;s<i.length;s++){var o=i[s];o in r.elements&&n.push(o)}return new I.Set(n)},I.Set.prototype.union=function(e){return e===I.Set.complete?I.Set.complete:e===I.Set.empty?this:new I.Set(Object.keys(this.elements).concat(Object.keys(e.elements)))},I.idf=function(e,t){var r=0;for(var i in e)"_index"!=i&&(r+=Object.keys(e[i]).length);var n=(t-r+.5)/(r+.5);return Math.log(1+Math.abs(n))},I.Token=function(e,t){this.str=e||"",this.metadata=t||{}},I.Token.prototype.toString=function(){return this.str},I.Token.prototype.update=function(e){return this.str=e(this.str,this.metadata),this},I.Token.prototype.clone=function(e){return e=e||function(e){return e},new I.Token(e(this.str,this.metadata),this.metadata)},I.tokenizer=function(e,t){if(null==e||null==e)return[];if(Array.isArray(e))return e.map((function(e){return new I.Token(I.utils.asString(e).toLowerCase(),I.utils.clone(t))}));for(var r=e.toString().toLowerCase(),i=r.length,n=[],s=0,o=0;s<=i;s++){var a=s-o;if(r.charAt(s).match(I.tokenizer.separator)||s==i){if(a>0){var u=I.utils.clone(t)||{};u.position=[o,a],u.index=n.length,n.push(new I.Token(r.slice(o,s),u))}o=s+1}}return n},I.tokenizer.separator=/[\s\-]+/,I.Pipeline=function(){this._stack=[]},I.Pipeline.registeredFunctions=Object.create(null),I.Pipeline.registerFunction=function(e,t){t in this.registeredFunctions&&I.utils.warn("Overwriting existing registered function: "+t),e.label=t,I.Pipeline.registeredFunctions[e.label]=e},I.Pipeline.warnIfFunctionNotRegistered=function(e){e.label&&e.label in this.registeredFunctions||I.utils.warn("Function is not registered with pipeline. This may cause problems when serialising the index.\n",e)},I.Pipeline.load=function(e){var t=new I.Pipeline;return e.forEach((function(e){var r=I.Pipeline.registeredFunctions[e];if(!r)throw new Error("Cannot load unregistered function: "+e);t.add(r)})),t},I.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach((function(e){I.Pipeline.warnIfFunctionNotRegistered(e),this._stack.push(e)}),this)},I.Pipeline.prototype.after=function(e,t){I.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");r+=1,this._stack.splice(r,0,t)},I.Pipeline.prototype.before=function(e,t){I.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");this._stack.splice(r,0,t)},I.Pipeline.prototype.remove=function(e){var t=this._stack.indexOf(e);-1!=t&&this._stack.splice(t,1)},I.Pipeline.prototype.run=function(e){for(var t=this._stack.length,r=0;r<t;r++){for(var i=this._stack[r],n=[],s=0;s<e.length;s++){var o=i(e[s],s,e);if(null!=o&&""!==o)if(Array.isArray(o))for(var a=0;a<o.length;a++)n.push(o[a]);else n.push(o)}e=n}return e},I.Pipeline.prototype.runString=function(e,t){var r=new I.Token(e,t);return this.run([r]).map((function(e){return e.toString()}))},I.Pipeline.prototype.reset=function(){this._stack=[]},I.Pipeline.prototype.toJSON=function(){return this._stack.map((function(e){return I.Pipeline.warnIfFunctionNotRegistered(e),e.label}))},I.Vector=function(e){this._magnitude=0,this.elements=e||[]},I.Vector.prototype.positionForIndex=function(e){if(0==this.elements.length)return 0;for(var t=0,r=this.elements.length/2,i=r-t,n=Math.floor(i/2),s=this.elements[2*n];i>1&&(s<e&&(t=n),s>e&&(r=n),s!=e);)i=r-t,n=t+Math.floor(i/2),s=this.elements[2*n];return s==e||s>e?2*n:s<e?2*(n+1):void 0},I.Vector.prototype.insert=function(e,t){this.upsert(e,t,(function(){throw"duplicate index"}))},I.Vector.prototype.upsert=function(e,t,r){this._magnitude=0;var i=this.positionForIndex(e);this.elements[i]==e?this.elements[i+1]=r(this.elements[i+1],t):this.elements.splice(i,0,e,t)},I.Vector.prototype.magnitude=function(){if(this._magnitude)return this._magnitude;for(var e=0,t=this.elements.length,r=1;r<t;r+=2){var i=this.elements[r];e+=i*i}return this._magnitude=Math.sqrt(e)},I.Vector.prototype.dot=function(e){for(var t=0,r=this.elements,i=e.elements,n=r.length,s=i.length,o=0,a=0,u=0,l=0;u<n&&l<s;)(o=r[u])<(a=i[l])?u+=2:o>a?l+=2:o==a&&(t+=r[u+1]*i[l+1],u+=2,l+=2);return t},I.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},I.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),t=1,r=0;t<this.elements.length;t+=2,r++)e[r]=this.elements[t];return e},I.Vector.prototype.toJSON=function(){return this.elements},I.stemmer=(o={ational:"ate",tional:"tion",enci:"ence",anci:"ance",izer:"ize",bli:"ble",alli:"al",entli:"ent",eli:"e",ousli:"ous",ization:"ize",ation:"ate",ator:"ate",alism:"al",iveness:"ive",fulness:"ful",ousness:"ous",aliti:"al",iviti:"ive",biliti:"ble",logi:"log"},a={icate:"ic",ative:"",alize:"al",iciti:"ic",ical:"ic",ful:"",ness:""},u="[aeiouy]",l="[^aeiou][^aeiouy]*",c=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),h=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),d=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*([aeiouy][aeiou]*)?$"),f=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy]"),p=/^(.+?)(ss|i)es$/,y=/^(.+?)([^s])s$/,m=/^(.+?)eed$/,g=/^(.+?)(ed|ing)$/,x=/.$/,R=/(at|bl|iz)$/,v=new RegExp("([^aeiouylsz])\\1$"),w=new RegExp("^"+l+u+"[^aeiouwxy]$"),Q=/^(.+?[^aeiou])y$/,k=/^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/,S=/^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/,E=/^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/,b=/^(.+?)(s|t)(ion)$/,L=/^(.+?)e$/,P=/ll$/,T=new RegExp("^"+l+u+"[^aeiouwxy]$"),O=function(e){var t,r,i,n,s,u,l;if(e.length<3)return e;if("y"==(i=e.substr(0,1))&&(e=i.toUpperCase()+e.substr(1)),s=y,(n=p).test(e)?e=e.replace(n,"$1$2"):s.test(e)&&(e=e.replace(s,"$1$2")),s=g,(n=m).test(e)){var O=n.exec(e);(n=c).test(O[1])&&(n=x,e=e.replace(n,""))}else s.test(e)&&(t=(O=s.exec(e))[1],(s=f).test(t)&&(u=v,l=w,(s=R).test(e=t)?e+="e":u.test(e)?(n=x,e=e.replace(n,"")):l.test(e)&&(e+="e")));return(n=Q).test(e)&&(e=(t=(O=n.exec(e))[1])+"i"),(n=k).test(e)&&(t=(O=n.exec(e))[1],r=O[2],(n=c).test(t)&&(e=t+o[r])),(n=S).test(e)&&(t=(O=n.exec(e))[1],r=O[2],(n=c).test(t)&&(e=t+a[r])),s=b,(n=E).test(e)?(t=(O=n.exec(e))[1],(n=h).test(t)&&(e=t)):s.test(e)&&(t=(O=s.exec(e))[1]+O[2],(s=h).test(t)&&(e=t)),(n=L).test(e)&&(t=(O=n.exec(e))[1],s=d,u=T,((n=h).test(t)||s.test(t)&&!u.test(t))&&(e=t)),s=h,(n=P).test(e)&&s.test(e)&&(n=x,e=e.replace(n,"")),"y"==i&&(e=i.toLowerCase()+e.substr(1)),e},function(e){return e.update(O)}),I.Pipeline.registerFunction(I.stemmer,"stemmer"),I.generateStopWordFilter=function(e){var t=e.reduce((function(e,t){return e[t]=t,e}),{});return function(e){if(e&&t[e.toString()]!==e.toString())return e}},I.stopWordFilter=I.generateStopWordFilter(["a","able","about","across","after","all","almost","also","am","among","an","and","any","are","as","at","be","because","been","but","by","can","cannot","could","dear","did","do","does","either","else","ever","every","for","from","get","got","had","has","have","he","her","hers","him","his","how","however","i","if","in","into","is","it","its","just","least","let","like","likely","may","me","might","most","must","my","neither","no","nor","not","of","off","often","on","only","or","other","our","own","rather","said","say","says","she","should","since","so","some","than","that","the","their","them","then","there","these","they","this","tis","to","too","twas","us","wants","was","we","were","what","when","where","which","while","who","whom","why","will","with","would","yet","you","your"]),I.Pipeline.registerFunction(I.stopWordFilter,"stopWordFilter"),I.trimmer=function(e){return e.update((function(e){return e.replace(/^\W+/,"").replace(/\W+$/,"")}))},I.Pipeline.registerFunction(I.trimmer,"trimmer"),I.TokenSet=function(){this.final=!1,this.edges={},this.id=I.TokenSet._nextId,I.TokenSet._nextId+=1},I.TokenSet._nextId=1,I.TokenSet.fromArray=function(e){for(var t=new I.TokenSet.Builder,r=0,i=e.length;r<i;r++)t.insert(e[r]);return t.finish(),t.root},I.TokenSet.fromClause=function(e){return"editDistance"in e?I.TokenSet.fromFuzzyString(e.term,e.editDistance):I.TokenSet.fromString(e.term)},I.TokenSet.fromFuzzyString=function(e,t){for(var r=new I.TokenSet,i=[{node:r,editsRemaining:t,str:e}];i.length;){var n=i.pop();if(n.str.length>0){var s,o=n.str.charAt(0);o in n.node.edges?s=n.node.edges[o]:(s=new I.TokenSet,n.node.edges[o]=s),1==n.str.length&&(s.final=!0),i.push({node:s,editsRemaining:n.editsRemaining,str:n.str.slice(1)})}if(0!=n.editsRemaining){if("*"in n.node.edges)var a=n.node.edges["*"];else a=new I.TokenSet,n.node.edges["*"]=a;if(0==n.str.length&&(a.final=!0),i.push({node:a,editsRemaining:n.editsRemaining-1,str:n.str}),n.str.length>1&&i.push({node:n.node,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)}),1==n.str.length&&(n.node.final=!0),n.str.length>=1){if("*"in n.node.edges)var u=n.node.edges["*"];else u=new I.TokenSet,n.node.edges["*"]=u;1==n.str.length&&(u.final=!0),i.push({node:u,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)})}if(n.str.length>1){var l,c=n.str.charAt(0),h=n.str.charAt(1);h in n.node.edges?l=n.node.edges[h]:(l=new I.TokenSet,n.node.edges[h]=l),1==n.str.length&&(l.final=!0),i.push({node:l,editsRemaining:n.editsRemaining-1,str:c+n.str.slice(2)})}}}return r},I.TokenSet.fromString=function(e){for(var t=new I.TokenSet,r=t,i=0,n=e.length;i<n;i++){var s=e[i],o=i==n-1;if("*"==s)t.edges[s]=t,t.final=o;else{var a=new I.TokenSet;a.final=o,t.edges[s]=a,t=a}}return r},I.TokenSet.prototype.toArray=function(){for(var e=[],t=[{prefix:"",node:this}];t.length;){var r=t.pop(),i=Object.keys(r.node.edges),n=i.length;r.node.final&&(r.prefix.charAt(0),e.push(r.prefix));for(var s=0;s<n;s++){var o=i[s];t.push({prefix:r.prefix.concat(o),node:r.node.edges[o]})}}return e},I.TokenSet.prototype.toString=function(){if(this._str)return this._str;for(var e=this.final?"1":"0",t=Object.keys(this.edges).sort(),r=t.length,i=0;i<r;i++){var n=t[i];e=e+n+this.edges[n].id}return e},I.TokenSet.prototype.intersect=function(e){for(var t=new I.TokenSet,r=void 0,i=[{qNode:e,output:t,node:this}];i.length;){r=i.pop();for(var n=Object.keys(r.qNode.edges),s=n.length,o=Object.keys(r.node.edges),a=o.length,u=0;u<s;u++)for(var l=n[u],c=0;c<a;c++){var h=o[c];if(h==l||"*"==l){var d=r.node.edges[h],f=r.qNode.edges[l],p=d.final&&f.final,y=void 0;h in r.output.edges?(y=r.output.edges[h]).final=y.final||p:((y=new I.TokenSet).final=p,r.output.edges[h]=y),i.push({qNode:f,output:y,node:d})}}}return t},I.TokenSet.Builder=function(){this.previousWord="",this.root=new I.TokenSet,this.uncheckedNodes=[],this.minimizedNodes={}},I.TokenSet.Builder.prototype.insert=function(e){var t,r=0;if(e<this.previousWord)throw new Error("Out of order word insertion");for(var i=0;i<e.length&&i<this.previousWord.length&&e[i]==this.previousWord[i];i++)r++;for(this.minimize(r),t=0==this.uncheckedNodes.length?this.root:this.uncheckedNodes[this.uncheckedNodes.length-1].child,i=r;i<e.length;i++){var n=new I.TokenSet,s=e[i];t.edges[s]=n,this.uncheckedNodes.push({parent:t,char:s,child:n}),t=n}t.final=!0,this.previousWord=e},I.TokenSet.Builder.prototype.finish=function(){this.minimize(0)},I.TokenSet.Builder.prototype.minimize=function(e){for(var t=this.uncheckedNodes.length-1;t>=e;t--){var r=this.uncheckedNodes[t],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}},I.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},I.Index.prototype.search=function(e){return this.query((function(t){new I.QueryParser(e,t).parse()}))},I.Index.prototype.query=function(e){for(var t=new I.Query(this.fields),r=Object.create(null),i=Object.create(null),n=Object.create(null),s=Object.create(null),o=Object.create(null),a=0;a<this.fields.length;a++)i[this.fields[a]]=new I.Vector;for(e.call(t,t),a=0;a<t.clauses.length;a++){var u,l=t.clauses[a],c=I.Set.empty;u=l.usePipeline?this.pipeline.runString(l.term,{fields:l.fields}):[l.term];for(var h=0;h<u.length;h++){var d=u[h];l.term=d;var f=I.TokenSet.fromClause(l),p=this.tokenSet.intersect(f).toArray();if(0===p.length&&l.presence===I.Query.presence.REQUIRED){for(var y=0;y<l.fields.length;y++)s[F=l.fields[y]]=I.Set.empty;break}for(var m=0;m<p.length;m++){var g=p[m],x=this.invertedIndex[g],R=x._index;for(y=0;y<l.fields.length;y++){var v=x[F=l.fields[y]],w=Object.keys(v),Q=g+"/"+F,k=new I.Set(w);if(l.presence==I.Query.presence.REQUIRED&&(c=c.union(k),void 0===s[F]&&(s[F]=I.Set.complete)),l.presence!=I.Query.presence.PROHIBITED){if(i[F].upsert(R,l.boost,(function(e,t){return e+t})),!n[Q]){for(var S=0;S<w.length;S++){var E,b=w[S],L=new I.FieldRef(b,F),P=v[b];void 0===(E=r[L])?r[L]=new I.MatchData(g,F,P):E.add(g,F,P)}n[Q]=!0}}else void 0===o[F]&&(o[F]=I.Set.empty),o[F]=o[F].union(k)}}}if(l.presence===I.Query.presence.REQUIRED)for(y=0;y<l.fields.length;y++)s[F=l.fields[y]]=s[F].intersect(c)}var T=I.Set.complete,O=I.Set.empty;for(a=0;a<this.fields.length;a++){var F;s[F=this.fields[a]]&&(T=T.intersect(s[F])),o[F]&&(O=O.union(o[F]))}var C=Object.keys(r),j=[],N=Object.create(null);if(t.isNegated())for(C=Object.keys(this.fieldVectors),a=0;a<C.length;a++){L=C[a];var _=I.FieldRef.fromString(L);r[L]=new I.MatchData}for(a=0;a<C.length;a++){var D=(_=I.FieldRef.fromString(C[a])).docRef;if(T.contains(D)&&!O.contains(D)){var A,B=this.fieldVectors[_],V=i[_.fieldName].similarity(B);if(void 0!==(A=N[D]))A.score+=V,A.matchData.combine(r[_]);else{var z={ref:D,score:V,matchData:r[_]};N[D]=z,j.push(z)}}}return j.sort((function(e,t){return t.score-e.score}))},I.Index.prototype.toJSON=function(){var e=Object.keys(this.invertedIndex).sort().map((function(e){return[e,this.invertedIndex[e]]}),this),t=Object.keys(this.fieldVectors).map((function(e){return[e,this.fieldVectors[e].toJSON()]}),this);return{version:I.version,fields:this.fields,fieldVectors:t,invertedIndex:e,pipeline:this.pipeline.toJSON()}},I.Index.load=function(e){var t={},r={},i=e.fieldVectors,n=Object.create(null),s=e.invertedIndex,o=new I.TokenSet.Builder,a=I.Pipeline.load(e.pipeline);e.version!=I.version&&I.utils.warn("Version mismatch when loading serialised index. Current version of lunr '"+I.version+"' does not match serialized index '"+e.version+"'");for(var u=0;u<i.length;u++){var l=(h=i[u])[0],c=h[1];r[l]=new I.Vector(c)}for(u=0;u<s.length;u++){var h,d=(h=s[u])[0],f=h[1];o.insert(d),n[d]=f}return o.finish(),t.fields=e.fields,t.fieldVectors=r,t.invertedIndex=n,t.tokenSet=o.root,t.pipeline=a,new I.Index(t)},I.Builder=function(){this._ref="id",this._fields=Object.create(null),this._documents=Object.create(null),this.invertedIndex=Object.create(null),this.fieldTermFrequencies={},this.fieldLengths={},this.tokenizer=I.tokenizer,this.pipeline=new I.Pipeline,this.searchPipeline=new I.Pipeline,this.documentCount=0,this._b=.75,this._k1=1.2,this.termIndex=0,this.metadataWhitelist=[]},I.Builder.prototype.ref=function(e){this._ref=e},I.Builder.prototype.field=function(e,t){if(/\//.test(e))throw new RangeError("Field '"+e+"' contains illegal character '/'");this._fields[e]=t||{}},I.Builder.prototype.b=function(e){this._b=e<0?0:e>1?1:e},I.Builder.prototype.k1=function(e){this._k1=e},I.Builder.prototype.add=function(e,t){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=t||{},this.documentCount+=1;for(var n=0;n<i.length;n++){var s=i[n],o=this._fields[s].extractor,a=o?o(e):e[s],u=this.tokenizer(a,{fields:[s]}),l=this.pipeline.run(u),c=new I.FieldRef(r,s),h=Object.create(null);this.fieldTermFrequencies[c]=h,this.fieldLengths[c]=0,this.fieldLengths[c]+=l.length;for(var d=0;d<l.length;d++){var f=l[d];if(null==h[f]&&(h[f]=0),h[f]+=1,null==this.invertedIndex[f]){var p=Object.create(null);p._index=this.termIndex,this.termIndex+=1;for(var y=0;y<i.length;y++)p[i[y]]=Object.create(null);this.invertedIndex[f]=p}null==this.invertedIndex[f][s][r]&&(this.invertedIndex[f][s][r]=Object.create(null));for(var m=0;m<this.metadataWhitelist.length;m++){var g=this.metadataWhitelist[m],x=f.metadata[g];null==this.invertedIndex[f][s][r][g]&&(this.invertedIndex[f][s][r][g]=[]),this.invertedIndex[f][s][r][g].push(x)}}}},I.Builder.prototype.calculateAverageFieldLengths=function(){for(var e=Object.keys(this.fieldLengths),t=e.length,r={},i={},n=0;n<t;n++){var s=I.FieldRef.fromString(e[n]),o=s.fieldName;i[o]||(i[o]=0),i[o]+=1,r[o]||(r[o]=0),r[o]+=this.fieldLengths[s]}var a=Object.keys(this._fields);for(n=0;n<a.length;n++){var u=a[n];r[u]=r[u]/i[u]}this.averageFieldLength=r},I.Builder.prototype.createFieldVectors=function(){for(var e={},t=Object.keys(this.fieldTermFrequencies),r=t.length,i=Object.create(null),n=0;n<r;n++){for(var s=I.FieldRef.fromString(t[n]),o=s.fieldName,a=this.fieldLengths[s],u=new I.Vector,l=this.fieldTermFrequencies[s],c=Object.keys(l),h=c.length,d=this._fields[o].boost||1,f=this._documents[s.docRef].boost||1,p=0;p<h;p++){var y,m,g,x=c[p],R=l[x],v=this.invertedIndex[x]._index;void 0===i[x]?(y=I.idf(this.invertedIndex[x],this.documentCount),i[x]=y):y=i[x],m=y*((this._k1+1)*R)/(this._k1*(1-this._b+this._b*(a/this.averageFieldLength[o]))+R),m*=d,m*=f,g=Math.round(1e3*m)/1e3,u.insert(v,g)}e[s]=u}this.fieldVectors=e},I.Builder.prototype.createTokenSet=function(){this.tokenSet=I.TokenSet.fromArray(Object.keys(this.invertedIndex).sort())},I.Builder.prototype.build=function(){return this.calculateAverageFieldLengths(),this.createFieldVectors(),this.createTokenSet(),new I.Index({invertedIndex:this.invertedIndex,fieldVectors:this.fieldVectors,tokenSet:this.tokenSet,fields:Object.keys(this._fields),pipeline:this.searchPipeline})},I.Builder.prototype.use=function(e){var t=Array.prototype.slice.call(arguments,1);t.unshift(this),e.apply(this,t)},I.MatchData=function(e,t,r){for(var i=Object.create(null),n=Object.keys(r||{}),s=0;s<n.length;s++){var o=n[s];i[o]=r[o].slice()}this.metadata=Object.create(null),void 0!==e&&(this.metadata[e]=Object.create(null),this.metadata[e][t]=i)},I.MatchData.prototype.combine=function(e){for(var t=Object.keys(e.metadata),r=0;r<t.length;r++){var i=t[r],n=Object.keys(e.metadata[i]);null==this.metadata[i]&&(this.metadata[i]=Object.create(null));for(var s=0;s<n.length;s++){var o=n[s],a=Object.keys(e.metadata[i][o]);null==this.metadata[i][o]&&(this.metadata[i][o]=Object.create(null));for(var u=0;u<a.length;u++){var l=a[u];null==this.metadata[i][o][l]?this.metadata[i][o][l]=e.metadata[i][o][l]:this.metadata[i][o][l]=this.metadata[i][o][l].concat(e.metadata[i][o][l])}}}},I.MatchData.prototype.add=function(e,t,r){if(!(e in this.metadata))return this.metadata[e]=Object.create(null),void(this.metadata[e][t]=r);if(t in this.metadata[e])for(var i=Object.keys(r),n=0;n<i.length;n++){var s=i[n];s in this.metadata[e][t]?this.metadata[e][t][s]=this.metadata[e][t][s].concat(r[s]):this.metadata[e][t][s]=r[s]}else this.metadata[e][t]=r},I.Query=function(e){this.clauses=[],this.allFields=e},I.Query.wildcard=new String("*"),I.Query.wildcard.NONE=0,I.Query.wildcard.LEADING=1,I.Query.wildcard.TRAILING=2,I.Query.presence={OPTIONAL:1,REQUIRED:2,PROHIBITED:3},I.Query.prototype.clause=function(e){return"fields"in e||(e.fields=this.allFields),"boost"in e||(e.boost=1),"usePipeline"in e||(e.usePipeline=!0),"wildcard"in e||(e.wildcard=I.Query.wildcard.NONE),e.wildcard&I.Query.wildcard.LEADING&&e.term.charAt(0)!=I.Query.wildcard&&(e.term="*"+e.term),e.wildcard&I.Query.wildcard.TRAILING&&e.term.slice(-1)!=I.Query.wildcard&&(e.term=e.term+"*"),"presence"in e||(e.presence=I.Query.presence.OPTIONAL),this.clauses.push(e),this},I.Query.prototype.isNegated=function(){for(var e=0;e<this.clauses.length;e++)if(this.clauses[e].presence!=I.Query.presence.PROHIBITED)return!1;return!0},I.Query.prototype.term=function(e,t){if(Array.isArray(e))return e.forEach((function(e){this.term(e,I.utils.clone(t))}),this),this;var r=t||{};return r.term=e.toString(),this.clause(r),this},I.QueryParseError=function(e,t,r){this.name="QueryParseError",this.message=e,this.start=t,this.end=r},I.QueryParseError.prototype=new Error,I.QueryLexer=function(e){this.lexemes=[],this.str=e,this.length=e.length,this.pos=0,this.start=0,this.escapeCharPositions=[]},I.QueryLexer.prototype.run=function(){for(var e=I.QueryLexer.lexText;e;)e=e(this)},I.QueryLexer.prototype.sliceString=function(){for(var e=[],t=this.start,r=this.pos,i=0;i<this.escapeCharPositions.length;i++)r=this.escapeCharPositions[i],e.push(this.str.slice(t,r)),t=r+1;return e.push(this.str.slice(t,this.pos)),this.escapeCharPositions.length=0,e.join("")},I.QueryLexer.prototype.emit=function(e){this.lexemes.push({type:e,str:this.sliceString(),start:this.start,end:this.pos}),this.start=this.pos},I.QueryLexer.prototype.escapeCharacter=function(){this.escapeCharPositions.push(this.pos-1),this.pos+=1},I.QueryLexer.prototype.next=function(){if(this.pos>=this.length)return I.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},I.QueryLexer.prototype.width=function(){return this.pos-this.start},I.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},I.QueryLexer.prototype.backup=function(){this.pos-=1},I.QueryLexer.prototype.acceptDigitRun=function(){var e,t;do{t=(e=this.next()).charCodeAt(0)}while(t>47&&t<58);e!=I.QueryLexer.EOS&&this.backup()},I.QueryLexer.prototype.more=function(){return this.pos<this.length},I.QueryLexer.EOS="EOS",I.QueryLexer.FIELD="FIELD",I.QueryLexer.TERM="TERM",I.QueryLexer.EDIT_DISTANCE="EDIT_DISTANCE",I.QueryLexer.BOOST="BOOST",I.QueryLexer.PRESENCE="PRESENCE",I.QueryLexer.lexField=function(e){return e.backup(),e.emit(I.QueryLexer.FIELD),e.ignore(),I.QueryLexer.lexText},I.QueryLexer.lexTerm=function(e){if(e.width()>1&&(e.backup(),e.emit(I.QueryLexer.TERM)),e.ignore(),e.more())return I.QueryLexer.lexText},I.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(I.QueryLexer.EDIT_DISTANCE),I.QueryLexer.lexText},I.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(I.QueryLexer.BOOST),I.QueryLexer.lexText},I.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(I.QueryLexer.TERM)},I.QueryLexer.termSeparator=I.tokenizer.separator,I.QueryLexer.lexText=function(e){for(;;){var t=e.next();if(t==I.QueryLexer.EOS)return I.QueryLexer.lexEOS;if(92!=t.charCodeAt(0)){if(":"==t)return I.QueryLexer.lexField;if("~"==t)return e.backup(),e.width()>0&&e.emit(I.QueryLexer.TERM),I.QueryLexer.lexEditDistance;if("^"==t)return e.backup(),e.width()>0&&e.emit(I.QueryLexer.TERM),I.QueryLexer.lexBoost;if("+"==t&&1===e.width())return e.emit(I.QueryLexer.PRESENCE),I.QueryLexer.lexText;if("-"==t&&1===e.width())return e.emit(I.QueryLexer.PRESENCE),I.QueryLexer.lexText;if(t.match(I.QueryLexer.termSeparator))return I.QueryLexer.lexTerm}else e.escapeCharacter()}},I.QueryParser=function(e,t){this.lexer=new I.QueryLexer(e),this.query=t,this.currentClause={},this.lexemeIdx=0},I.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=I.QueryParser.parseClause;e;)e=e(this);return this.query},I.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},I.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},I.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},I.QueryParser.parseClause=function(e){var t=e.peekLexeme();if(null!=t)switch(t.type){case I.QueryLexer.PRESENCE:return I.QueryParser.parsePresence;case I.QueryLexer.FIELD:return I.QueryParser.parseField;case I.QueryLexer.TERM:return I.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+t.type;throw t.str.length>=1&&(r+=" with value '"+t.str+"'"),new I.QueryParseError(r,t.start,t.end)}},I.QueryParser.parsePresence=function(e){var t=e.consumeLexeme();if(null!=t){switch(t.str){case"-":e.currentClause.presence=I.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=I.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+t.str+"'";throw new I.QueryParseError(r,t.start,t.end)}var i=e.peekLexeme();if(null==i)throw r="expecting term or field, found nothing",new I.QueryParseError(r,t.start,t.end);switch(i.type){case I.QueryLexer.FIELD:return I.QueryParser.parseField;case I.QueryLexer.TERM:return I.QueryParser.parseTerm;default:throw r="expecting term or field, found '"+i.type+"'",new I.QueryParseError(r,i.start,i.end)}}},I.QueryParser.parseField=function(e){var t=e.consumeLexeme();if(null!=t){if(-1==e.query.allFields.indexOf(t.str)){var r=e.query.allFields.map((function(e){return"'"+e+"'"})).join(", "),i="unrecognised field '"+t.str+"', possible fields: "+r;throw new I.QueryParseError(i,t.start,t.end)}e.currentClause.fields=[t.str];var n=e.peekLexeme();if(null==n)throw i="expecting term, found nothing",new I.QueryParseError(i,t.start,t.end);if(n.type===I.QueryLexer.TERM)return I.QueryParser.parseTerm;throw i="expecting term, found '"+n.type+"'",new I.QueryParseError(i,n.start,n.end)}},I.QueryParser.parseTerm=function(e){var t=e.consumeLexeme();if(null!=t){e.currentClause.term=t.str.toLowerCase(),-1!=t.str.indexOf("*")&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(null!=r)switch(r.type){case I.QueryLexer.TERM:return e.nextClause(),I.QueryParser.parseTerm;case I.QueryLexer.FIELD:return e.nextClause(),I.QueryParser.parseField;case I.QueryLexer.EDIT_DISTANCE:return I.QueryParser.parseEditDistance;case I.QueryLexer.BOOST:return I.QueryParser.parseBoost;case I.QueryLexer.PRESENCE:return e.nextClause(),I.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+r.type+"'";throw new I.QueryParseError(i,r.start,r.end)}else e.nextClause()}},I.QueryParser.parseEditDistance=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new I.QueryParseError(i,t.start,t.end)}e.currentClause.editDistance=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case I.QueryLexer.TERM:return e.nextClause(),I.QueryParser.parseTerm;case I.QueryLexer.FIELD:return e.nextClause(),I.QueryParser.parseField;case I.QueryLexer.EDIT_DISTANCE:return I.QueryParser.parseEditDistance;case I.QueryLexer.BOOST:return I.QueryParser.parseBoost;case I.QueryLexer.PRESENCE:return e.nextClause(),I.QueryParser.parsePresence;default:throw i="Unexpected lexeme type '"+n.type+"'",new I.QueryParseError(i,n.start,n.end)}else e.nextClause()}},I.QueryParser.parseBoost=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="boost must be numeric";throw new I.QueryParseError(i,t.start,t.end)}e.currentClause.boost=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case I.QueryLexer.TERM:return e.nextClause(),I.QueryParser.parseTerm;case I.QueryLexer.FIELD:return e.nextClause(),I.QueryParser.parseField;case I.QueryLexer.EDIT_DISTANCE:return I.QueryParser.parseEditDistance;case I.QueryLexer.BOOST:return I.QueryParser.parseBoost;case I.QueryLexer.PRESENCE:return e.nextClause(),I.QueryParser.parsePresence;default:throw i="Unexpected lexeme type '"+n.type+"'",new I.QueryParseError(i,n.start,n.end)}else e.nextClause()}},void 0===(n="function"==typeof(i=function(){return I})?i.call(t,r,t,e):i)||(e.exports=n)}()},567:(e,t,r)=>{var i=r(314),n=["add","done","toJS","fromExternalJS","load","dispose","search","Worker"];e.exports=function(){var e=new Worker(URL.createObjectURL(new Blob(['/*! For license information please see 1a77c0465d2508da59cb.worker.js.LICENSE.txt */\n(()=>{var e={336:(e,t,r)=>{var i,n;!function(){var s,o,a,u,l,c,h,d,f,p,y,m,g,x,v,w,Q,k,S,E,P,L,b,T,O,I,R=function(e){var t=new R.Builder;return t.pipeline.add(R.trimmer,R.stopWordFilter,R.stemmer),t.searchPipeline.add(R.stemmer),e.call(t,t),t.build()};R.version="2.3.9",R.utils={},R.utils.warn=(s=this,function(e){s.console&&console.warn&&console.warn(e)}),R.utils.asString=function(e){return null==e?"":e.toString()},R.utils.clone=function(e){if(null==e)return e;for(var t=Object.create(null),r=Object.keys(e),i=0;i<r.length;i++){var n=r[i],s=e[n];if(Array.isArray(s))t[n]=s.slice();else{if("string"!=typeof s&&"number"!=typeof s&&"boolean"!=typeof s)throw new TypeError("clone is not deep and does not support nested objects");t[n]=s}}return t},R.FieldRef=function(e,t,r){this.docRef=e,this.fieldName=t,this._stringValue=r},R.FieldRef.joiner="/",R.FieldRef.fromString=function(e){var t=e.indexOf(R.FieldRef.joiner);if(-1===t)throw"malformed field ref string";var r=e.slice(0,t),i=e.slice(t+1);return new R.FieldRef(i,r,e)},R.FieldRef.prototype.toString=function(){return null==this._stringValue&&(this._stringValue=this.fieldName+R.FieldRef.joiner+this.docRef),this._stringValue},R.Set=function(e){if(this.elements=Object.create(null),e){this.length=e.length;for(var t=0;t<this.length;t++)this.elements[e[t]]=!0}else this.length=0},R.Set.complete={intersect:function(e){return e},union:function(){return this},contains:function(){return!0}},R.Set.empty={intersect:function(){return this},union:function(e){return e},contains:function(){return!1}},R.Set.prototype.contains=function(e){return!!this.elements[e]},R.Set.prototype.intersect=function(e){var t,r,i,n=[];if(e===R.Set.complete)return this;if(e===R.Set.empty)return e;this.length<e.length?(t=this,r=e):(t=e,r=this),i=Object.keys(t.elements);for(var s=0;s<i.length;s++){var o=i[s];o in r.elements&&n.push(o)}return new R.Set(n)},R.Set.prototype.union=function(e){return e===R.Set.complete?R.Set.complete:e===R.Set.empty?this:new R.Set(Object.keys(this.elements).concat(Object.keys(e.elements)))},R.idf=function(e,t){var r=0;for(var i in e)"_index"!=i&&(r+=Object.keys(e[i]).length);var n=(t-r+.5)/(r+.5);return Math.log(1+Math.abs(n))},R.Token=function(e,t){this.str=e||"",this.metadata=t||{}},R.Token.prototype.toString=function(){return this.str},R.Token.prototype.update=function(e){return this.str=e(this.str,this.metadata),this},R.Token.prototype.clone=function(e){return e=e||function(e){return e},new R.Token(e(this.str,this.metadata),this.metadata)},R.tokenizer=function(e,t){if(null==e||null==e)return[];if(Array.isArray(e))return e.map((function(e){return new R.Token(R.utils.asString(e).toLowerCase(),R.utils.clone(t))}));for(var r=e.toString().toLowerCase(),i=r.length,n=[],s=0,o=0;s<=i;s++){var a=s-o;if(r.charAt(s).match(R.tokenizer.separator)||s==i){if(a>0){var u=R.utils.clone(t)||{};u.position=[o,a],u.index=n.length,n.push(new R.Token(r.slice(o,s),u))}o=s+1}}return n},R.tokenizer.separator=/[\\s\\-]+/,R.Pipeline=function(){this._stack=[]},R.Pipeline.registeredFunctions=Object.create(null),R.Pipeline.registerFunction=function(e,t){t in this.registeredFunctions&&R.utils.warn("Overwriting existing registered function: "+t),e.label=t,R.Pipeline.registeredFunctions[e.label]=e},R.Pipeline.warnIfFunctionNotRegistered=function(e){e.label&&e.label in this.registeredFunctions||R.utils.warn("Function is not registered with pipeline. This may cause problems when serialising the index.\\n",e)},R.Pipeline.load=function(e){var t=new R.Pipeline;return e.forEach((function(e){var r=R.Pipeline.registeredFunctions[e];if(!r)throw new Error("Cannot load unregistered function: "+e);t.add(r)})),t},R.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach((function(e){R.Pipeline.warnIfFunctionNotRegistered(e),this._stack.push(e)}),this)},R.Pipeline.prototype.after=function(e,t){R.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");r+=1,this._stack.splice(r,0,t)},R.Pipeline.prototype.before=function(e,t){R.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");this._stack.splice(r,0,t)},R.Pipeline.prototype.remove=function(e){var t=this._stack.indexOf(e);-1!=t&&this._stack.splice(t,1)},R.Pipeline.prototype.run=function(e){for(var t=this._stack.length,r=0;r<t;r++){for(var i=this._stack[r],n=[],s=0;s<e.length;s++){var o=i(e[s],s,e);if(null!=o&&""!==o)if(Array.isArray(o))for(var a=0;a<o.length;a++)n.push(o[a]);else n.push(o)}e=n}return e},R.Pipeline.prototype.runString=function(e,t){var r=new R.Token(e,t);return this.run([r]).map((function(e){return e.toString()}))},R.Pipeline.prototype.reset=function(){this._stack=[]},R.Pipeline.prototype.toJSON=function(){return this._stack.map((function(e){return R.Pipeline.warnIfFunctionNotRegistered(e),e.label}))},R.Vector=function(e){this._magnitude=0,this.elements=e||[]},R.Vector.prototype.positionForIndex=function(e){if(0==this.elements.length)return 0;for(var t=0,r=this.elements.length/2,i=r-t,n=Math.floor(i/2),s=this.elements[2*n];i>1&&(s<e&&(t=n),s>e&&(r=n),s!=e);)i=r-t,n=t+Math.floor(i/2),s=this.elements[2*n];return s==e||s>e?2*n:s<e?2*(n+1):void 0},R.Vector.prototype.insert=function(e,t){this.upsert(e,t,(function(){throw"duplicate index"}))},R.Vector.prototype.upsert=function(e,t,r){this._magnitude=0;var i=this.positionForIndex(e);this.elements[i]==e?this.elements[i+1]=r(this.elements[i+1],t):this.elements.splice(i,0,e,t)},R.Vector.prototype.magnitude=function(){if(this._magnitude)return this._magnitude;for(var e=0,t=this.elements.length,r=1;r<t;r+=2){var i=this.elements[r];e+=i*i}return this._magnitude=Math.sqrt(e)},R.Vector.prototype.dot=function(e){for(var t=0,r=this.elements,i=e.elements,n=r.length,s=i.length,o=0,a=0,u=0,l=0;u<n&&l<s;)(o=r[u])<(a=i[l])?u+=2:o>a?l+=2:o==a&&(t+=r[u+1]*i[l+1],u+=2,l+=2);return t},R.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},R.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),t=1,r=0;t<this.elements.length;t+=2,r++)e[r]=this.elements[t];return e},R.Vector.prototype.toJSON=function(){return this.elements},R.stemmer=(o={ational:"ate",tional:"tion",enci:"ence",anci:"ance",izer:"ize",bli:"ble",alli:"al",entli:"ent",eli:"e",ousli:"ous",ization:"ize",ation:"ate",ator:"ate",alism:"al",iveness:"ive",fulness:"ful",ousness:"ous",aliti:"al",iviti:"ive",biliti:"ble",logi:"log"},a={icate:"ic",ative:"",alize:"al",iciti:"ic",ical:"ic",ful:"",ness:""},u="[aeiouy]",l="[^aeiou][^aeiouy]*",c=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),h=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*[aeiouy][aeiou]*[^aeiou][^aeiouy]*"),d=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy][aeiou]*[^aeiou][^aeiouy]*([aeiouy][aeiou]*)?$"),f=new RegExp("^([^aeiou][^aeiouy]*)?[aeiouy]"),p=/^(.+?)(ss|i)es$/,y=/^(.+?)([^s])s$/,m=/^(.+?)eed$/,g=/^(.+?)(ed|ing)$/,x=/.$/,v=/(at|bl|iz)$/,w=new RegExp("([^aeiouylsz])\\\\1$"),Q=new RegExp("^"+l+u+"[^aeiouwxy]$"),k=/^(.+?[^aeiou])y$/,S=/^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/,E=/^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/,P=/^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/,L=/^(.+?)(s|t)(ion)$/,b=/^(.+?)e$/,T=/ll$/,O=new RegExp("^"+l+u+"[^aeiouwxy]$"),I=function(e){var t,r,i,n,s,u,l;if(e.length<3)return e;if("y"==(i=e.substr(0,1))&&(e=i.toUpperCase()+e.substr(1)),s=y,(n=p).test(e)?e=e.replace(n,"$1$2"):s.test(e)&&(e=e.replace(s,"$1$2")),s=g,(n=m).test(e)){var I=n.exec(e);(n=c).test(I[1])&&(n=x,e=e.replace(n,""))}else s.test(e)&&(t=(I=s.exec(e))[1],(s=f).test(t)&&(u=w,l=Q,(s=v).test(e=t)?e+="e":u.test(e)?(n=x,e=e.replace(n,"")):l.test(e)&&(e+="e")));return(n=k).test(e)&&(e=(t=(I=n.exec(e))[1])+"i"),(n=S).test(e)&&(t=(I=n.exec(e))[1],r=I[2],(n=c).test(t)&&(e=t+o[r])),(n=E).test(e)&&(t=(I=n.exec(e))[1],r=I[2],(n=c).test(t)&&(e=t+a[r])),s=L,(n=P).test(e)?(t=(I=n.exec(e))[1],(n=h).test(t)&&(e=t)):s.test(e)&&(t=(I=s.exec(e))[1]+I[2],(s=h).test(t)&&(e=t)),(n=b).test(e)&&(t=(I=n.exec(e))[1],s=d,u=O,((n=h).test(t)||s.test(t)&&!u.test(t))&&(e=t)),s=h,(n=T).test(e)&&s.test(e)&&(n=x,e=e.replace(n,"")),"y"==i&&(e=i.toLowerCase()+e.substr(1)),e},function(e){return e.update(I)}),R.Pipeline.registerFunction(R.stemmer,"stemmer"),R.generateStopWordFilter=function(e){var t=e.reduce((function(e,t){return e[t]=t,e}),{});return function(e){if(e&&t[e.toString()]!==e.toString())return e}},R.stopWordFilter=R.generateStopWordFilter(["a","able","about","across","after","all","almost","also","am","among","an","and","any","are","as","at","be","because","been","but","by","can","cannot","could","dear","did","do","does","either","else","ever","every","for","from","get","got","had","has","have","he","her","hers","him","his","how","however","i","if","in","into","is","it","its","just","least","let","like","likely","may","me","might","most","must","my","neither","no","nor","not","of","off","often","on","only","or","other","our","own","rather","said","say","says","she","should","since","so","some","than","that","the","their","them","then","there","these","they","this","tis","to","too","twas","us","wants","was","we","were","what","when","where","which","while","who","whom","why","will","with","would","yet","you","your"]),R.Pipeline.registerFunction(R.stopWordFilter,"stopWordFilter"),R.trimmer=function(e){return e.update((function(e){return e.replace(/^\\W+/,"").replace(/\\W+$/,"")}))},R.Pipeline.registerFunction(R.trimmer,"trimmer"),R.TokenSet=function(){this.final=!1,this.edges={},this.id=R.TokenSet._nextId,R.TokenSet._nextId+=1},R.TokenSet._nextId=1,R.TokenSet.fromArray=function(e){for(var t=new R.TokenSet.Builder,r=0,i=e.length;r<i;r++)t.insert(e[r]);return t.finish(),t.root},R.TokenSet.fromClause=function(e){return"editDistance"in e?R.TokenSet.fromFuzzyString(e.term,e.editDistance):R.TokenSet.fromString(e.term)},R.TokenSet.fromFuzzyString=function(e,t){for(var r=new R.TokenSet,i=[{node:r,editsRemaining:t,str:e}];i.length;){var n=i.pop();if(n.str.length>0){var s,o=n.str.charAt(0);o in n.node.edges?s=n.node.edges[o]:(s=new R.TokenSet,n.node.edges[o]=s),1==n.str.length&&(s.final=!0),i.push({node:s,editsRemaining:n.editsRemaining,str:n.str.slice(1)})}if(0!=n.editsRemaining){if("*"in n.node.edges)var a=n.node.edges["*"];else a=new R.TokenSet,n.node.edges["*"]=a;if(0==n.str.length&&(a.final=!0),i.push({node:a,editsRemaining:n.editsRemaining-1,str:n.str}),n.str.length>1&&i.push({node:n.node,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)}),1==n.str.length&&(n.node.final=!0),n.str.length>=1){if("*"in n.node.edges)var u=n.node.edges["*"];else u=new R.TokenSet,n.node.edges["*"]=u;1==n.str.length&&(u.final=!0),i.push({node:u,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)})}if(n.str.length>1){var l,c=n.str.charAt(0),h=n.str.charAt(1);h in n.node.edges?l=n.node.edges[h]:(l=new R.TokenSet,n.node.edges[h]=l),1==n.str.length&&(l.final=!0),i.push({node:l,editsRemaining:n.editsRemaining-1,str:c+n.str.slice(2)})}}}return r},R.TokenSet.fromString=function(e){for(var t=new R.TokenSet,r=t,i=0,n=e.length;i<n;i++){var s=e[i],o=i==n-1;if("*"==s)t.edges[s]=t,t.final=o;else{var a=new R.TokenSet;a.final=o,t.edges[s]=a,t=a}}return r},R.TokenSet.prototype.toArray=function(){for(var e=[],t=[{prefix:"",node:this}];t.length;){var r=t.pop(),i=Object.keys(r.node.edges),n=i.length;r.node.final&&(r.prefix.charAt(0),e.push(r.prefix));for(var s=0;s<n;s++){var o=i[s];t.push({prefix:r.prefix.concat(o),node:r.node.edges[o]})}}return e},R.TokenSet.prototype.toString=function(){if(this._str)return this._str;for(var e=this.final?"1":"0",t=Object.keys(this.edges).sort(),r=t.length,i=0;i<r;i++){var n=t[i];e=e+n+this.edges[n].id}return e},R.TokenSet.prototype.intersect=function(e){for(var t=new R.TokenSet,r=void 0,i=[{qNode:e,output:t,node:this}];i.length;){r=i.pop();for(var n=Object.keys(r.qNode.edges),s=n.length,o=Object.keys(r.node.edges),a=o.length,u=0;u<s;u++)for(var l=n[u],c=0;c<a;c++){var h=o[c];if(h==l||"*"==l){var d=r.node.edges[h],f=r.qNode.edges[l],p=d.final&&f.final,y=void 0;h in r.output.edges?(y=r.output.edges[h]).final=y.final||p:((y=new R.TokenSet).final=p,r.output.edges[h]=y),i.push({qNode:f,output:y,node:d})}}}return t},R.TokenSet.Builder=function(){this.previousWord="",this.root=new R.TokenSet,this.uncheckedNodes=[],this.minimizedNodes={}},R.TokenSet.Builder.prototype.insert=function(e){var t,r=0;if(e<this.previousWord)throw new Error("Out of order word insertion");for(var i=0;i<e.length&&i<this.previousWord.length&&e[i]==this.previousWord[i];i++)r++;for(this.minimize(r),t=0==this.uncheckedNodes.length?this.root:this.uncheckedNodes[this.uncheckedNodes.length-1].child,i=r;i<e.length;i++){var n=new R.TokenSet,s=e[i];t.edges[s]=n,this.uncheckedNodes.push({parent:t,char:s,child:n}),t=n}t.final=!0,this.previousWord=e},R.TokenSet.Builder.prototype.finish=function(){this.minimize(0)},R.TokenSet.Builder.prototype.minimize=function(e){for(var t=this.uncheckedNodes.length-1;t>=e;t--){var r=this.uncheckedNodes[t],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}},R.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},R.Index.prototype.search=function(e){return this.query((function(t){new R.QueryParser(e,t).parse()}))},R.Index.prototype.query=function(e){for(var t=new R.Query(this.fields),r=Object.create(null),i=Object.create(null),n=Object.create(null),s=Object.create(null),o=Object.create(null),a=0;a<this.fields.length;a++)i[this.fields[a]]=new R.Vector;for(e.call(t,t),a=0;a<t.clauses.length;a++){var u,l=t.clauses[a],c=R.Set.empty;u=l.usePipeline?this.pipeline.runString(l.term,{fields:l.fields}):[l.term];for(var h=0;h<u.length;h++){var d=u[h];l.term=d;var f=R.TokenSet.fromClause(l),p=this.tokenSet.intersect(f).toArray();if(0===p.length&&l.presence===R.Query.presence.REQUIRED){for(var y=0;y<l.fields.length;y++)s[F=l.fields[y]]=R.Set.empty;break}for(var m=0;m<p.length;m++){var g=p[m],x=this.invertedIndex[g],v=x._index;for(y=0;y<l.fields.length;y++){var w=x[F=l.fields[y]],Q=Object.keys(w),k=g+"/"+F,S=new R.Set(Q);if(l.presence==R.Query.presence.REQUIRED&&(c=c.union(S),void 0===s[F]&&(s[F]=R.Set.complete)),l.presence!=R.Query.presence.PROHIBITED){if(i[F].upsert(v,l.boost,(function(e,t){return e+t})),!n[k]){for(var E=0;E<Q.length;E++){var P,L=Q[E],b=new R.FieldRef(L,F),T=w[L];void 0===(P=r[b])?r[b]=new R.MatchData(g,F,T):P.add(g,F,T)}n[k]=!0}}else void 0===o[F]&&(o[F]=R.Set.empty),o[F]=o[F].union(S)}}}if(l.presence===R.Query.presence.REQUIRED)for(y=0;y<l.fields.length;y++)s[F=l.fields[y]]=s[F].intersect(c)}var O=R.Set.complete,I=R.Set.empty;for(a=0;a<this.fields.length;a++){var F;s[F=this.fields[a]]&&(O=O.intersect(s[F])),o[F]&&(I=I.union(o[F]))}var C=Object.keys(r),N=[],j=Object.create(null);if(t.isNegated())for(C=Object.keys(this.fieldVectors),a=0;a<C.length;a++){b=C[a];var _=R.FieldRef.fromString(b);r[b]=new R.MatchData}for(a=0;a<C.length;a++){var D=(_=R.FieldRef.fromString(C[a])).docRef;if(O.contains(D)&&!I.contains(D)){var A,B=this.fieldVectors[_],z=i[_.fieldName].similarity(B);if(void 0!==(A=j[D]))A.score+=z,A.matchData.combine(r[_]);else{var V={ref:D,score:z,matchData:r[_]};j[D]=V,N.push(V)}}}return N.sort((function(e,t){return t.score-e.score}))},R.Index.prototype.toJSON=function(){var e=Object.keys(this.invertedIndex).sort().map((function(e){return[e,this.invertedIndex[e]]}),this),t=Object.keys(this.fieldVectors).map((function(e){return[e,this.fieldVectors[e].toJSON()]}),this);return{version:R.version,fields:this.fields,fieldVectors:t,invertedIndex:e,pipeline:this.pipeline.toJSON()}},R.Index.load=function(e){var t={},r={},i=e.fieldVectors,n=Object.create(null),s=e.invertedIndex,o=new R.TokenSet.Builder,a=R.Pipeline.load(e.pipeline);e.version!=R.version&&R.utils.warn("Version mismatch when loading serialised index. Current version of lunr \'"+R.version+"\' does not match serialized index \'"+e.version+"\'");for(var u=0;u<i.length;u++){var l=(h=i[u])[0],c=h[1];r[l]=new R.Vector(c)}for(u=0;u<s.length;u++){var h,d=(h=s[u])[0],f=h[1];o.insert(d),n[d]=f}return o.finish(),t.fields=e.fields,t.fieldVectors=r,t.invertedIndex=n,t.tokenSet=o.root,t.pipeline=a,new R.Index(t)},R.Builder=function(){this._ref="id",this._fields=Object.create(null),this._documents=Object.create(null),this.invertedIndex=Object.create(null),this.fieldTermFrequencies={},this.fieldLengths={},this.tokenizer=R.tokenizer,this.pipeline=new R.Pipeline,this.searchPipeline=new R.Pipeline,this.documentCount=0,this._b=.75,this._k1=1.2,this.termIndex=0,this.metadataWhitelist=[]},R.Builder.prototype.ref=function(e){this._ref=e},R.Builder.prototype.field=function(e,t){if(/\\//.test(e))throw new RangeError("Field \'"+e+"\' contains illegal character \'/\'");this._fields[e]=t||{}},R.Builder.prototype.b=function(e){this._b=e<0?0:e>1?1:e},R.Builder.prototype.k1=function(e){this._k1=e},R.Builder.prototype.add=function(e,t){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=t||{},this.documentCount+=1;for(var n=0;n<i.length;n++){var s=i[n],o=this._fields[s].extractor,a=o?o(e):e[s],u=this.tokenizer(a,{fields:[s]}),l=this.pipeline.run(u),c=new R.FieldRef(r,s),h=Object.create(null);this.fieldTermFrequencies[c]=h,this.fieldLengths[c]=0,this.fieldLengths[c]+=l.length;for(var d=0;d<l.length;d++){var f=l[d];if(null==h[f]&&(h[f]=0),h[f]+=1,null==this.invertedIndex[f]){var p=Object.create(null);p._index=this.termIndex,this.termIndex+=1;for(var y=0;y<i.length;y++)p[i[y]]=Object.create(null);this.invertedIndex[f]=p}null==this.invertedIndex[f][s][r]&&(this.invertedIndex[f][s][r]=Object.create(null));for(var m=0;m<this.metadataWhitelist.length;m++){var g=this.metadataWhitelist[m],x=f.metadata[g];null==this.invertedIndex[f][s][r][g]&&(this.invertedIndex[f][s][r][g]=[]),this.invertedIndex[f][s][r][g].push(x)}}}},R.Builder.prototype.calculateAverageFieldLengths=function(){for(var e=Object.keys(this.fieldLengths),t=e.length,r={},i={},n=0;n<t;n++){var s=R.FieldRef.fromString(e[n]),o=s.fieldName;i[o]||(i[o]=0),i[o]+=1,r[o]||(r[o]=0),r[o]+=this.fieldLengths[s]}var a=Object.keys(this._fields);for(n=0;n<a.length;n++){var u=a[n];r[u]=r[u]/i[u]}this.averageFieldLength=r},R.Builder.prototype.createFieldVectors=function(){for(var e={},t=Object.keys(this.fieldTermFrequencies),r=t.length,i=Object.create(null),n=0;n<r;n++){for(var s=R.FieldRef.fromString(t[n]),o=s.fieldName,a=this.fieldLengths[s],u=new R.Vector,l=this.fieldTermFrequencies[s],c=Object.keys(l),h=c.length,d=this._fields[o].boost||1,f=this._documents[s.docRef].boost||1,p=0;p<h;p++){var y,m,g,x=c[p],v=l[x],w=this.invertedIndex[x]._index;void 0===i[x]?(y=R.idf(this.invertedIndex[x],this.documentCount),i[x]=y):y=i[x],m=y*((this._k1+1)*v)/(this._k1*(1-this._b+this._b*(a/this.averageFieldLength[o]))+v),m*=d,m*=f,g=Math.round(1e3*m)/1e3,u.insert(w,g)}e[s]=u}this.fieldVectors=e},R.Builder.prototype.createTokenSet=function(){this.tokenSet=R.TokenSet.fromArray(Object.keys(this.invertedIndex).sort())},R.Builder.prototype.build=function(){return this.calculateAverageFieldLengths(),this.createFieldVectors(),this.createTokenSet(),new R.Index({invertedIndex:this.invertedIndex,fieldVectors:this.fieldVectors,tokenSet:this.tokenSet,fields:Object.keys(this._fields),pipeline:this.searchPipeline})},R.Builder.prototype.use=function(e){var t=Array.prototype.slice.call(arguments,1);t.unshift(this),e.apply(this,t)},R.MatchData=function(e,t,r){for(var i=Object.create(null),n=Object.keys(r||{}),s=0;s<n.length;s++){var o=n[s];i[o]=r[o].slice()}this.metadata=Object.create(null),void 0!==e&&(this.metadata[e]=Object.create(null),this.metadata[e][t]=i)},R.MatchData.prototype.combine=function(e){for(var t=Object.keys(e.metadata),r=0;r<t.length;r++){var i=t[r],n=Object.keys(e.metadata[i]);null==this.metadata[i]&&(this.metadata[i]=Object.create(null));for(var s=0;s<n.length;s++){var o=n[s],a=Object.keys(e.metadata[i][o]);null==this.metadata[i][o]&&(this.metadata[i][o]=Object.create(null));for(var u=0;u<a.length;u++){var l=a[u];null==this.metadata[i][o][l]?this.metadata[i][o][l]=e.metadata[i][o][l]:this.metadata[i][o][l]=this.metadata[i][o][l].concat(e.metadata[i][o][l])}}}},R.MatchData.prototype.add=function(e,t,r){if(!(e in this.metadata))return this.metadata[e]=Object.create(null),void(this.metadata[e][t]=r);if(t in this.metadata[e])for(var i=Object.keys(r),n=0;n<i.length;n++){var s=i[n];s in this.metadata[e][t]?this.metadata[e][t][s]=this.metadata[e][t][s].concat(r[s]):this.metadata[e][t][s]=r[s]}else this.metadata[e][t]=r},R.Query=function(e){this.clauses=[],this.allFields=e},R.Query.wildcard=new String("*"),R.Query.wildcard.NONE=0,R.Query.wildcard.LEADING=1,R.Query.wildcard.TRAILING=2,R.Query.presence={OPTIONAL:1,REQUIRED:2,PROHIBITED:3},R.Query.prototype.clause=function(e){return"fields"in e||(e.fields=this.allFields),"boost"in e||(e.boost=1),"usePipeline"in e||(e.usePipeline=!0),"wildcard"in e||(e.wildcard=R.Query.wildcard.NONE),e.wildcard&R.Query.wildcard.LEADING&&e.term.charAt(0)!=R.Query.wildcard&&(e.term="*"+e.term),e.wildcard&R.Query.wildcard.TRAILING&&e.term.slice(-1)!=R.Query.wildcard&&(e.term=e.term+"*"),"presence"in e||(e.presence=R.Query.presence.OPTIONAL),this.clauses.push(e),this},R.Query.prototype.isNegated=function(){for(var e=0;e<this.clauses.length;e++)if(this.clauses[e].presence!=R.Query.presence.PROHIBITED)return!1;return!0},R.Query.prototype.term=function(e,t){if(Array.isArray(e))return e.forEach((function(e){this.term(e,R.utils.clone(t))}),this),this;var r=t||{};return r.term=e.toString(),this.clause(r),this},R.QueryParseError=function(e,t,r){this.name="QueryParseError",this.message=e,this.start=t,this.end=r},R.QueryParseError.prototype=new Error,R.QueryLexer=function(e){this.lexemes=[],this.str=e,this.length=e.length,this.pos=0,this.start=0,this.escapeCharPositions=[]},R.QueryLexer.prototype.run=function(){for(var e=R.QueryLexer.lexText;e;)e=e(this)},R.QueryLexer.prototype.sliceString=function(){for(var e=[],t=this.start,r=this.pos,i=0;i<this.escapeCharPositions.length;i++)r=this.escapeCharPositions[i],e.push(this.str.slice(t,r)),t=r+1;return e.push(this.str.slice(t,this.pos)),this.escapeCharPositions.length=0,e.join("")},R.QueryLexer.prototype.emit=function(e){this.lexemes.push({type:e,str:this.sliceString(),start:this.start,end:this.pos}),this.start=this.pos},R.QueryLexer.prototype.escapeCharacter=function(){this.escapeCharPositions.push(this.pos-1),this.pos+=1},R.QueryLexer.prototype.next=function(){if(this.pos>=this.length)return R.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},R.QueryLexer.prototype.width=function(){return this.pos-this.start},R.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},R.QueryLexer.prototype.backup=function(){this.pos-=1},R.QueryLexer.prototype.acceptDigitRun=function(){var e,t;do{t=(e=this.next()).charCodeAt(0)}while(t>47&&t<58);e!=R.QueryLexer.EOS&&this.backup()},R.QueryLexer.prototype.more=function(){return this.pos<this.length},R.QueryLexer.EOS="EOS",R.QueryLexer.FIELD="FIELD",R.QueryLexer.TERM="TERM",R.QueryLexer.EDIT_DISTANCE="EDIT_DISTANCE",R.QueryLexer.BOOST="BOOST",R.QueryLexer.PRESENCE="PRESENCE",R.QueryLexer.lexField=function(e){return e.backup(),e.emit(R.QueryLexer.FIELD),e.ignore(),R.QueryLexer.lexText},R.QueryLexer.lexTerm=function(e){if(e.width()>1&&(e.backup(),e.emit(R.QueryLexer.TERM)),e.ignore(),e.more())return R.QueryLexer.lexText},R.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(R.QueryLexer.EDIT_DISTANCE),R.QueryLexer.lexText},R.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(R.QueryLexer.BOOST),R.QueryLexer.lexText},R.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(R.QueryLexer.TERM)},R.QueryLexer.termSeparator=R.tokenizer.separator,R.QueryLexer.lexText=function(e){for(;;){var t=e.next();if(t==R.QueryLexer.EOS)return R.QueryLexer.lexEOS;if(92!=t.charCodeAt(0)){if(":"==t)return R.QueryLexer.lexField;if("~"==t)return e.backup(),e.width()>0&&e.emit(R.QueryLexer.TERM),R.QueryLexer.lexEditDistance;if("^"==t)return e.backup(),e.width()>0&&e.emit(R.QueryLexer.TERM),R.QueryLexer.lexBoost;if("+"==t&&1===e.width())return e.emit(R.QueryLexer.PRESENCE),R.QueryLexer.lexText;if("-"==t&&1===e.width())return e.emit(R.QueryLexer.PRESENCE),R.QueryLexer.lexText;if(t.match(R.QueryLexer.termSeparator))return R.QueryLexer.lexTerm}else e.escapeCharacter()}},R.QueryParser=function(e,t){this.lexer=new R.QueryLexer(e),this.query=t,this.currentClause={},this.lexemeIdx=0},R.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=R.QueryParser.parseClause;e;)e=e(this);return this.query},R.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},R.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},R.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},R.QueryParser.parseClause=function(e){var t=e.peekLexeme();if(null!=t)switch(t.type){case R.QueryLexer.PRESENCE:return R.QueryParser.parsePresence;case R.QueryLexer.FIELD:return R.QueryParser.parseField;case R.QueryLexer.TERM:return R.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+t.type;throw t.str.length>=1&&(r+=" with value \'"+t.str+"\'"),new R.QueryParseError(r,t.start,t.end)}},R.QueryParser.parsePresence=function(e){var t=e.consumeLexeme();if(null!=t){switch(t.str){case"-":e.currentClause.presence=R.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=R.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator\'"+t.str+"\'";throw new R.QueryParseError(r,t.start,t.end)}var i=e.peekLexeme();if(null==i)throw r="expecting term or field, found nothing",new R.QueryParseError(r,t.start,t.end);switch(i.type){case R.QueryLexer.FIELD:return R.QueryParser.parseField;case R.QueryLexer.TERM:return R.QueryParser.parseTerm;default:throw r="expecting term or field, found \'"+i.type+"\'",new R.QueryParseError(r,i.start,i.end)}}},R.QueryParser.parseField=function(e){var t=e.consumeLexeme();if(null!=t){if(-1==e.query.allFields.indexOf(t.str)){var r=e.query.allFields.map((function(e){return"\'"+e+"\'"})).join(", "),i="unrecognised field \'"+t.str+"\', possible fields: "+r;throw new R.QueryParseError(i,t.start,t.end)}e.currentClause.fields=[t.str];var n=e.peekLexeme();if(null==n)throw i="expecting term, found nothing",new R.QueryParseError(i,t.start,t.end);if(n.type===R.QueryLexer.TERM)return R.QueryParser.parseTerm;throw i="expecting term, found \'"+n.type+"\'",new R.QueryParseError(i,n.start,n.end)}},R.QueryParser.parseTerm=function(e){var t=e.consumeLexeme();if(null!=t){e.currentClause.term=t.str.toLowerCase(),-1!=t.str.indexOf("*")&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(null!=r)switch(r.type){case R.QueryLexer.TERM:return e.nextClause(),R.QueryParser.parseTerm;case R.QueryLexer.FIELD:return e.nextClause(),R.QueryParser.parseField;case R.QueryLexer.EDIT_DISTANCE:return R.QueryParser.parseEditDistance;case R.QueryLexer.BOOST:return R.QueryParser.parseBoost;case R.QueryLexer.PRESENCE:return e.nextClause(),R.QueryParser.parsePresence;default:var i="Unexpected lexeme type \'"+r.type+"\'";throw new R.QueryParseError(i,r.start,r.end)}else e.nextClause()}},R.QueryParser.parseEditDistance=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new R.QueryParseError(i,t.start,t.end)}e.currentClause.editDistance=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case R.QueryLexer.TERM:return e.nextClause(),R.QueryParser.parseTerm;case R.QueryLexer.FIELD:return e.nextClause(),R.QueryParser.parseField;case R.QueryLexer.EDIT_DISTANCE:return R.QueryParser.parseEditDistance;case R.QueryLexer.BOOST:return R.QueryParser.parseBoost;case R.QueryLexer.PRESENCE:return e.nextClause(),R.QueryParser.parsePresence;default:throw i="Unexpected lexeme type \'"+n.type+"\'",new R.QueryParseError(i,n.start,n.end)}else e.nextClause()}},R.QueryParser.parseBoost=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="boost must be numeric";throw new R.QueryParseError(i,t.start,t.end)}e.currentClause.boost=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case R.QueryLexer.TERM:return e.nextClause(),R.QueryParser.parseTerm;case R.QueryLexer.FIELD:return e.nextClause(),R.QueryParser.parseField;case R.QueryLexer.EDIT_DISTANCE:return R.QueryParser.parseEditDistance;case R.QueryLexer.BOOST:return R.QueryParser.parseBoost;case R.QueryLexer.PRESENCE:return e.nextClause(),R.QueryParser.parsePresence;default:throw i="Unexpected lexeme type \'"+n.type+"\'",new R.QueryParseError(i,n.start,n.end)}else e.nextClause()}},void 0===(n="function"==typeof(i=function(){return R})?i.call(t,r,t,e):i)||(e.exports=n)}()}},t={};function r(i){var n=t[i];if(void 0!==n)return n.exports;var s=t[i]={exports:{}};return e[i](s,s.exports,r),s.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var i in t)r.o(t,i)&&!r.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var i={};(()=>{"use strict";r.d(i,{add:()=>l,done:()=>c,toJS:()=>h,fromExternalJS:()=>d,load:()=>f,dispose:()=>p,search:()=>y});var e=r(336),t=(Object.defineProperty,(e,t,r)=>new Promise(((i,n)=>{var s=e=>{try{a(r.next(e))}catch(e){n(e)}},o=e=>{try{a(r.throw(e))}catch(e){n(e)}},a=e=>e.done?i(e.value):Promise.resolve(e.value).then(s,o);a((r=r.apply(e,t)).next())})));let n,s,o,a=[];function u(){n=new e.Builder,n.field("title"),n.field("description"),n.ref("ref"),n.pipeline.add(e.trimmer,e.stopWordFilter,e.stemmer),o=new Promise((e=>{s=e}))}function l(e,t,r){const i=a.push(r)-1,s={title:e.toLowerCase(),description:t.toLowerCase(),ref:i};n.add(s)}function c(){return t(this,null,(function*(){s(n.build())}))}function h(){return t(this,null,(function*(){return{store:a,index:(yield o).toJSON()}}))}function d(e,r){return t(this,null,(function*(){try{if(importScripts(e),!self[r])throw new Error("Broken index file format");yield f(self[r])}catch(e){console.error("Failed to load search index: "+e.message)}}))}function f(r){return t(this,null,(function*(){a=r.store,s(e.Index.load(r.index))}))}function p(){return t(this,null,(function*(){a=[],u()}))}function y(r,i=0){return t(this,null,(function*(){if(0===r.trim().length)return[];let t=(yield o).query((t=>{r.trim().toLowerCase().split(/\\s+/).forEach((r=>{if(1===r.length)return;const i=(t=>"*"+e.stemmer(new e.Token(t,{}))+"*")(r);t.term(i,{})}))}));return i>0&&(t=t.slice(0,i)),t.map((e=>({meta:a[e.ref],score:e.score})))}))}e.tokenizer.separator=/\\s+/,u(),addEventListener("message",(function(e){var t,r=e.data,n=r.type,s=r.method,o=r.id,a=r.params;"RPC"===n&&s&&((t=i[s])?Promise.resolve().then((function(){return t.apply(i,a)})):Promise.reject("No such method")).then((function(e){postMessage({type:"RPC",id:o,result:e})})).catch((function(e){var t={message:e};e.stack&&(t.message=e.message,t.stack=e.stack,t.name=e.name),postMessage({type:"RPC",id:o,error:t})}))})),postMessage({type:"RPC",method:"ready"})})()})();'])),{name:"[fullhash].worker.js"});return i(e,n),e}},314:e=>{e.exports=function(e,t){var r=0,i={};e.addEventListener("message",(function(t){var r=t.data;if("RPC"===r.type)if(r.id){var n=i[r.id];n&&(delete i[r.id],r.error?n[1](Object.assign(Error(r.error.message),r.error)):n[0](r.result))}else{var s=document.createEvent("Event");s.initEvent(r.method,!1,!1),s.data=r.params,e.dispatchEvent(s)}})),t.forEach((function(t){e[t]=function(){var n=arguments;return new Promise((function(s,o){var a=++r;i[a]=[s,o],e.postMessage({type:"RPC",id:a,method:t,params:[].slice.call(n)})}))}}))}}},t={};function r(i){var n=t[i];if(void 0!==n)return n.exports;var s=t[i]={exports:{}};return e[i](s,s.exports,r),s.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var i in t)r.o(t,i)&&!r.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{"use strict";r.r(i),r.d(i,{SearchStore:()=>n});const e="undefined"!=typeof window&&"HTMLElement"in window;"undefined"==typeof Element||Element.prototype.scrollIntoViewIfNeeded||(Element.prototype.scrollIntoViewIfNeeded=function(e){e=0===arguments.length||!!e;const t=this.parentNode,r=window.getComputedStyle(t,void 0),i=parseInt(r.getPropertyValue("border-top-width"),10),n=parseInt(r.getPropertyValue("border-left-width"),10),s=this.offsetTop-t.offsetTop<t.scrollTop,o=this.offsetTop-t.offsetTop+this.clientHeight-i>t.scrollTop+t.clientHeight,a=this.offsetLeft-t.offsetLeft<t.scrollLeft,u=this.offsetLeft-t.offsetLeft+this.clientWidth-n>t.scrollLeft+t.clientWidth,l=s&&!o;(s||o)&&e&&(t.scrollTop=this.offsetTop-t.offsetTop-t.clientHeight/2-i+this.clientHeight/2),(a||u)&&e&&(t.scrollLeft=this.offsetLeft-t.offsetLeft-t.clientWidth/2-n+this.clientWidth/2),(s||o||a||u)&&!e&&this.scrollIntoView(l)});var t=Object.defineProperty;class n{constructor(){var i,n,s;i=this,n="searchWorker",s=function(){let t;if(e)try{t=r(567)}catch(e){t=r(27).ZP}else t=r(27).ZP;return new t}(),((e,r,i)=>{r in e?t(e,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[r]=i})(i,"symbol"!=typeof n?n+"":n,s)}indexItems(e){const t=e=>{e.forEach((e=>{"group"!==e.type&&this.add(e.name,e.description||"",e.id),t(e.items)}))};t(e),this.searchWorker.done()}add(e,t,r){this.searchWorker.add(e,t,r)}dispose(){this.searchWorker.terminate(),this.searchWorker.dispose()}search(e){return this.searchWorker.search(e)}toJS(){return e=this,null,t=function*(){return this.searchWorker.toJS()},new Promise(((r,i)=>{var n=e=>{try{o(t.next(e))}catch(e){i(e)}},s=e=>{try{o(t.throw(e))}catch(e){i(e)}},o=e=>e.done?r(e.value):Promise.resolve(e.value).then(n,s);o((t=t.apply(e,null)).next())}));var e,t}load(e){this.searchWorker.load(e)}fromExternalJS(e,t){e&&t&&this.searchWorker.fromExternalJS(e,t)}}})(),i})()}));
@@ -1,3 +1,4 @@
1
+ import type { SearchResult } from './types';
1
2
  export default class Worker {
2
3
  add: typeof add;
3
4
  done: typeof done;
@@ -7,15 +8,6 @@ export default class Worker {
7
8
  dispose: typeof dispose;
8
9
  fromExternalJS: typeof fromExternalJS;
9
10
  }
10
- export interface SearchDocument {
11
- title: string;
12
- description: string;
13
- id: string;
14
- }
15
- export interface SearchResult<T = string> {
16
- meta: T;
17
- score: number;
18
- }
19
11
  export declare function add<T>(title: string, description: string, meta?: T): void;
20
12
  export declare function done(): Promise<void>;
21
13
  export declare function toJS(): Promise<any>;
@@ -1,8 +1,8 @@
1
1
  import type { OpenAPIExternalDocumentation, OpenAPIDefinition } from '../types';
2
- import type { ContentItemModel } from './MenuBuilder';
2
+ import type { RedocProNormalizedOptions } from '../../../services';
3
+ import type { ContentItemModel } from './types';
3
4
  import { ApiInfoModel, SecuritySchemesModel, WebhookModel } from './models';
4
5
  import { OpenAPIParser } from './OpenAPIParser';
5
- import type { RedocProNormalizedOptions } from '../../../services';
6
6
  /**
7
7
  * Store that contains all the specification related information in the form of tree
8
8
  */
@@ -1,2 +1,6 @@
1
1
  export declare const SECTION_ATTR = "data-section-id";
2
2
  export declare const FIELD_ATTR = "data-field-id";
3
+ export declare const GROUP_DEPTH = 0;
4
+ export declare const LEGACY_REGEXP = "^ {0,3}<!-- ReDoc-Inject:\\s+?<({component}).*?/?>\\s+?-->\\s*$";
5
+ export declare const MDX_COMPONENT_REGEXP: string;
6
+ export declare const COMPONENT_REGEXP: string;