@scalar/api-reference 1.32.9 → 1.33.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (404) hide show
  1. package/CHANGELOG.md +99 -0
  2. package/dist/browser/standalone.js +17026 -16443
  3. package/dist/browser/webpack-stats.json +1 -1
  4. package/dist/components/Anchor/Anchor.vue.d.ts.map +1 -1
  5. package/dist/components/Anchor/Anchor.vue.js +50 -5
  6. package/dist/components/Anchor/Anchor.vue2.js +2 -42
  7. package/dist/components/ApiReference.vue.js +6 -6
  8. package/dist/components/ApiReferenceLayout.vue.d.ts.map +1 -1
  9. package/dist/components/ApiReferenceLayout.vue.js +6 -6
  10. package/dist/components/ApiReferenceLayout.vue2.js +167 -176
  11. package/dist/components/ApiReferenceLayout.vue3.js +4 -0
  12. package/dist/components/ApiReferenceLayout.vue4.js +4 -0
  13. package/dist/components/ApiReferenceLayout.vue5.js +4 -0
  14. package/dist/components/ApiReferenceLayout.vue6.js +4 -0
  15. package/dist/components/Badge/Badge.vue.d.ts.map +1 -1
  16. package/dist/components/Badge/Badge.vue.js +4 -4
  17. package/dist/components/Badge/Badge.vue2.js +4 -0
  18. package/dist/components/ClassicHeader.vue.js +1 -1
  19. package/dist/components/ClassicHeader.vue2.js +4 -0
  20. package/dist/components/Content/ClientLibraries/ClientLibraries.vue.d.ts +14 -1
  21. package/dist/components/Content/ClientLibraries/ClientLibraries.vue.d.ts.map +1 -1
  22. package/dist/components/Content/ClientLibraries/ClientLibraries.vue.js +3 -3
  23. package/dist/components/Content/ClientLibraries/ClientLibraries.vue2.js +74 -84
  24. package/dist/components/Content/ClientLibraries/ClientLibraries.vue3.js +4 -0
  25. package/dist/components/Content/ClientLibraries/ClientSelector.vue.d.ts +8 -0
  26. package/dist/components/Content/ClientLibraries/ClientSelector.vue.d.ts.map +1 -1
  27. package/dist/components/Content/ClientLibraries/ClientSelector.vue.js +2 -2
  28. package/dist/components/Content/ClientLibraries/ClientSelector.vue2.js +81 -80
  29. package/dist/components/Content/ClientLibraries/ClientSelector.vue3.js +4 -0
  30. package/dist/components/Content/ClientLibraries/featured-clients.d.ts +11 -0
  31. package/dist/components/Content/ClientLibraries/featured-clients.d.ts.map +1 -0
  32. package/dist/components/Content/ClientLibraries/featured-clients.js +17 -0
  33. package/dist/components/Content/Content.vue.d.ts +5 -6
  34. package/dist/components/Content/Content.vue.d.ts.map +1 -1
  35. package/dist/components/Content/Content.vue.js +49 -6
  36. package/dist/components/Content/Content.vue2.js +2 -160
  37. package/dist/components/Content/Content.vue3.js +5 -0
  38. package/dist/components/Content/Introduction/Description.vue.d.ts.map +1 -1
  39. package/dist/components/Content/Introduction/Description.vue.js +3 -3
  40. package/dist/components/Content/Introduction/Description.vue3.js +4 -0
  41. package/dist/components/Content/Introduction/Introduction.vue.d.ts +7 -17
  42. package/dist/components/Content/Introduction/Introduction.vue.d.ts.map +1 -1
  43. package/dist/components/Content/Introduction/Introduction.vue.js +2 -2
  44. package/dist/components/Content/Introduction/Introduction.vue2.js +103 -118
  45. package/dist/components/Content/Introduction/Introduction.vue3.js +4 -0
  46. package/dist/components/Content/Introduction/IntroductionSection.vue.d.ts +25 -0
  47. package/dist/components/Content/Introduction/IntroductionSection.vue.d.ts.map +1 -0
  48. package/dist/components/Content/Introduction/IntroductionSection.vue.js +7 -0
  49. package/dist/components/Content/Introduction/IntroductionSection.vue2.js +159 -0
  50. package/dist/components/Content/Introduction/IntroductionSection.vue3.js +4 -0
  51. package/dist/components/Content/Models/{ModelsAccordion.vue.d.ts → ClassicLayout.vue.d.ts} +2 -2
  52. package/dist/components/Content/Models/ClassicLayout.vue.d.ts.map +1 -0
  53. package/dist/components/Content/Models/ClassicLayout.vue.js +7 -0
  54. package/dist/components/Content/Models/{ModelsAccordion.vue2.js → ClassicLayout.vue2.js} +30 -30
  55. package/dist/components/Content/Models/ClassicLayout.vue3.js +4 -0
  56. package/dist/components/Content/Models/Models.vue.d.ts +3 -1
  57. package/dist/components/Content/Models/Models.vue.d.ts.map +1 -1
  58. package/dist/components/Content/Models/Models.vue.js +38 -5
  59. package/dist/components/Content/Models/Models.vue2.js +2 -114
  60. package/dist/components/Content/Models/ModernLayout.vue.d.ts +7 -0
  61. package/dist/components/Content/Models/ModernLayout.vue.d.ts.map +1 -0
  62. package/dist/components/Content/Models/ModernLayout.vue.js +7 -0
  63. package/dist/components/Content/Models/ModernLayout.vue2.js +100 -0
  64. package/dist/components/Content/Models/ModernLayout.vue3.js +4 -0
  65. package/dist/components/Content/Models/index.d.ts +0 -1
  66. package/dist/components/Content/Models/index.d.ts.map +1 -1
  67. package/dist/components/Content/Operations/TraversedEntry.vue.d.ts +21 -0
  68. package/dist/components/Content/Operations/TraversedEntry.vue.d.ts.map +1 -0
  69. package/dist/components/Content/Operations/TraversedEntry.vue.js +95 -0
  70. package/dist/components/Content/Operations/TraversedEntry.vue2.js +4 -0
  71. package/dist/components/Content/Operations/TraversedEntryContainer.vue.d.ts +17 -0
  72. package/dist/components/Content/Operations/TraversedEntryContainer.vue.d.ts.map +1 -0
  73. package/dist/components/Content/Operations/TraversedEntryContainer.vue.js +56 -0
  74. package/dist/components/Content/Operations/TraversedEntryContainer.vue2.js +4 -0
  75. package/dist/components/Content/Operations/index.d.ts +2 -0
  76. package/dist/components/Content/Operations/index.d.ts.map +1 -0
  77. package/dist/components/Content/Schema/Schema.vue.js +1 -1
  78. package/dist/components/Content/Schema/Schema.vue3.js +4 -0
  79. package/dist/components/Content/Schema/SchemaComposition.vue.d.ts.map +1 -1
  80. package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue.d.ts.map +1 -1
  81. package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue.js +3 -3
  82. package/dist/components/Content/Schema/SchemaEnumPropertyItem.vue3.js +4 -0
  83. package/dist/components/Content/Schema/SchemaEnumValues.vue.d.ts.map +1 -1
  84. package/dist/components/Content/Schema/SchemaEnumValues.vue.js +3 -3
  85. package/dist/components/Content/Schema/SchemaEnumValues.vue2.js +63 -68
  86. package/dist/components/Content/Schema/SchemaEnumValues.vue3.js +4 -0
  87. package/dist/components/Content/Schema/SchemaHeading.vue.d.ts.map +1 -1
  88. package/dist/components/Content/Schema/SchemaHeading.vue.js +4 -4
  89. package/dist/components/Content/Schema/SchemaHeading.vue2.js +23 -22
  90. package/dist/components/Content/Schema/SchemaHeading.vue3.js +4 -0
  91. package/dist/components/Content/Schema/SchemaProperty.vue.d.ts.map +1 -1
  92. package/dist/components/Content/Schema/SchemaProperty.vue.js +2 -2
  93. package/dist/components/Content/Schema/SchemaProperty.vue2.js +34 -33
  94. package/dist/components/Content/Schema/SchemaProperty.vue3.js +4 -0
  95. package/dist/components/Content/Schema/SchemaPropertyDetail.vue.d.ts.map +1 -1
  96. package/dist/components/Content/Schema/SchemaPropertyDetail.vue.js +2 -2
  97. package/dist/components/Content/Schema/SchemaPropertyDetail.vue3.js +4 -0
  98. package/dist/components/Content/Schema/SchemaPropertyExamples.vue.js +3 -3
  99. package/dist/components/Content/Schema/SchemaPropertyExamples.vue3.js +4 -0
  100. package/dist/components/Content/Schema/SchemaPropertyHeading.vue.d.ts.map +1 -1
  101. package/dist/components/Content/Schema/SchemaPropertyHeading.vue.js +3 -3
  102. package/dist/components/Content/Schema/SchemaPropertyHeading.vue2.js +26 -23
  103. package/dist/components/Content/Schema/SchemaPropertyHeading.vue3.js +4 -0
  104. package/dist/components/Content/Schema/helpers/merge-all-of-schemas.d.ts +2 -1
  105. package/dist/components/Content/Schema/helpers/merge-all-of-schemas.d.ts.map +1 -1
  106. package/dist/components/Content/Schema/helpers/merge-all-of-schemas.js +59 -52
  107. package/dist/components/Content/Schema/helpers/optimize-value-for-display.d.ts.map +1 -1
  108. package/dist/components/Content/Schema/helpers/optimize-value-for-display.js +24 -20
  109. package/dist/components/Content/Schema/helpers/schema-name.d.ts +1 -1
  110. package/dist/components/Content/Schema/helpers/schema-name.d.ts.map +1 -1
  111. package/dist/components/Content/{Tag/TagAccordion.vue.d.ts → Tags/ClassicLayout.vue.d.ts} +3 -3
  112. package/dist/components/Content/Tags/ClassicLayout.vue.d.ts.map +1 -0
  113. package/dist/components/Content/Tags/ClassicLayout.vue.js +7 -0
  114. package/dist/components/Content/Tags/ClassicLayout.vue2.js +51 -0
  115. package/dist/components/Content/Tags/ClassicLayout.vue3.js +4 -0
  116. package/dist/components/Content/{Tag/TagSection.vue.d.ts → Tags/ModernLayout.vue.d.ts} +17 -13
  117. package/dist/components/Content/Tags/ModernLayout.vue.d.ts.map +1 -0
  118. package/dist/components/Content/Tags/ModernLayout.vue.js +7 -0
  119. package/dist/components/Content/Tags/ModernLayout.vue2.js +69 -0
  120. package/dist/components/Content/Tags/ModernLayout.vue3.js +4 -0
  121. package/dist/components/Content/Tags/Tag.vue.d.ts +25 -0
  122. package/dist/components/Content/Tags/Tag.vue.d.ts.map +1 -0
  123. package/dist/components/Content/Tags/Tag.vue.js +27 -0
  124. package/dist/components/Content/{Tag/Tag.vue.d.ts → Tags/TagSection.vue.d.ts} +3 -6
  125. package/dist/components/Content/Tags/TagSection.vue.d.ts.map +1 -0
  126. package/dist/components/Content/Tags/TagSection.vue.js +104 -0
  127. package/dist/components/Content/Tags/TagSection.vue2.js +4 -0
  128. package/dist/components/Content/Tags/index.d.ts +2 -0
  129. package/dist/components/Content/Tags/index.d.ts.map +1 -0
  130. package/dist/components/GettingStarted.vue.js +1 -1
  131. package/dist/components/GettingStarted.vue3.js +4 -0
  132. package/dist/components/HttpMethod/HttpMethod.vue.d.ts.map +1 -1
  133. package/dist/components/HttpMethod/HttpMethod.vue.js +8 -6
  134. package/dist/components/{Content/Lazy → Lazy}/Lazy.vue.d.ts +1 -10
  135. package/dist/components/Lazy/Lazy.vue.d.ts.map +1 -0
  136. package/dist/components/Lazy/Lazy.vue2.js +25 -0
  137. package/dist/components/Lazy/index.d.ts +3 -0
  138. package/dist/components/Lazy/index.d.ts.map +1 -0
  139. package/dist/components/Lazy/lazyBus.d.ts +8 -0
  140. package/dist/components/Lazy/lazyBus.d.ts.map +1 -0
  141. package/dist/components/Lazy/lazyBus.js +7 -0
  142. package/dist/components/LinkList/LinkList.vue.d.ts +20 -0
  143. package/dist/components/LinkList/LinkList.vue.d.ts.map +1 -0
  144. package/dist/components/LinkList/LinkList.vue.js +7 -0
  145. package/dist/components/LinkList/LinkList.vue2.js +32 -0
  146. package/dist/components/LinkList/LinkList.vue3.js +4 -0
  147. package/dist/components/LinkList/index.d.ts +2 -0
  148. package/dist/components/LinkList/index.d.ts.map +1 -0
  149. package/dist/components/LoadingSkeleton.vue.d.ts.map +1 -1
  150. package/dist/components/LoadingSkeleton.vue.js +3 -3
  151. package/dist/components/LoadingSkeleton.vue3.js +4 -0
  152. package/dist/components/MobileHeader.vue.js +1 -1
  153. package/dist/components/MobileHeader.vue3.js +4 -0
  154. package/dist/components/OperationPath.vue.js +1 -1
  155. package/dist/components/OperationPath.vue3.js +4 -0
  156. package/dist/components/{Content/Tag → OperationsList}/OperationsList.vue.d.ts +2 -5
  157. package/dist/components/OperationsList/OperationsList.vue.d.ts.map +1 -0
  158. package/dist/components/OperationsList/OperationsList.vue.js +7 -0
  159. package/dist/components/OperationsList/OperationsList.vue2.js +60 -0
  160. package/dist/components/OperationsList/OperationsList.vue3.js +4 -0
  161. package/dist/components/{Content/Tag → OperationsList}/OperationsListItem.vue.d.ts +2 -4
  162. package/dist/components/OperationsList/OperationsListItem.vue.d.ts.map +1 -0
  163. package/dist/components/OperationsList/OperationsListItem.vue.js +7 -0
  164. package/dist/components/OperationsList/OperationsListItem.vue2.js +63 -0
  165. package/dist/components/OperationsList/OperationsListItem.vue3.js +4 -0
  166. package/dist/components/OperationsList/index.d.ts +2 -0
  167. package/dist/components/OperationsList/index.d.ts.map +1 -0
  168. package/dist/components/ScreenReader.vue.js +1 -1
  169. package/dist/components/ScreenReader.vue3.js +4 -0
  170. package/dist/components/Section/CompactSection.vue.d.ts.map +1 -1
  171. package/dist/components/Section/CompactSection.vue.js +3 -3
  172. package/dist/components/Section/CompactSection.vue2.js +35 -36
  173. package/dist/components/Section/CompactSection.vue3.js +4 -0
  174. package/dist/components/Section/Section.vue.js +1 -1
  175. package/dist/components/Section/Section.vue3.js +4 -0
  176. package/dist/components/Section/SectionAccordion.vue.d.ts.map +1 -1
  177. package/dist/components/Section/SectionAccordion.vue.js +3 -3
  178. package/dist/components/Section/SectionAccordion.vue2.js +42 -36
  179. package/dist/components/Section/SectionAccordion.vue3.js +4 -0
  180. package/dist/components/Section/SectionColumn.vue.js +1 -1
  181. package/dist/components/Section/SectionColumn.vue2.js +4 -0
  182. package/dist/components/Section/SectionColumns.vue.js +1 -1
  183. package/dist/components/Section/SectionColumns.vue2.js +4 -0
  184. package/dist/components/Section/SectionContainer.vue.d.ts +9 -2
  185. package/dist/components/Section/SectionContainer.vue.d.ts.map +1 -1
  186. package/dist/components/Section/SectionContainer.vue.js +5 -11
  187. package/dist/components/Section/SectionContainer.vue2.js +18 -0
  188. package/dist/components/Section/SectionContainer.vue3.js +4 -0
  189. package/dist/components/Section/SectionContainerAccordion.vue.d.ts.map +1 -1
  190. package/dist/components/Section/SectionContainerAccordion.vue.js +3 -3
  191. package/dist/components/Section/SectionContainerAccordion.vue3.js +4 -0
  192. package/dist/components/Section/SectionContent.vue.js +1 -1
  193. package/dist/components/Section/SectionContent.vue3.js +4 -0
  194. package/dist/components/Section/SectionHeader.vue.d.ts +1 -0
  195. package/dist/components/Section/SectionHeader.vue.d.ts.map +1 -1
  196. package/dist/components/Section/SectionHeader.vue.js +3 -3
  197. package/dist/components/Section/SectionHeader.vue2.js +11 -10
  198. package/dist/components/Section/SectionHeader.vue3.js +4 -0
  199. package/dist/components/Section/SectionHeaderTag.vue.js +1 -1
  200. package/dist/components/Section/SectionHeaderTag.vue3.js +4 -0
  201. package/dist/components/SectionFlare/SectionFlare.vue.d.ts +3 -0
  202. package/dist/components/SectionFlare/SectionFlare.vue.d.ts.map +1 -0
  203. package/dist/components/SectionFlare/SectionFlare.vue.js +13 -0
  204. package/dist/components/SectionFlare/SectionFlare.vue2.js +4 -0
  205. package/dist/components/SectionFlare/index.d.ts +2 -0
  206. package/dist/components/SectionFlare/index.d.ts.map +1 -0
  207. package/dist/components/ShowMoreButton.vue.d.ts.map +1 -1
  208. package/dist/components/ShowMoreButton.vue.js +3 -3
  209. package/dist/components/ShowMoreButton.vue2.js +12 -12
  210. package/dist/components/ShowMoreButton.vue3.js +4 -0
  211. package/dist/features/Operation/Operation.vue.d.ts +11 -7
  212. package/dist/features/Operation/Operation.vue.d.ts.map +1 -1
  213. package/dist/features/Operation/Operation.vue.js +66 -48
  214. package/dist/features/Operation/components/ContentTypeSelect.vue.d.ts.map +1 -1
  215. package/dist/features/Operation/components/ContentTypeSelect.vue.js +28 -30
  216. package/dist/features/Operation/components/ParameterHeaders.vue.js +1 -1
  217. package/dist/features/Operation/components/ParameterHeaders.vue3.js +4 -0
  218. package/dist/features/Operation/components/ParameterList.vue.js +1 -1
  219. package/dist/features/Operation/components/ParameterList.vue3.js +4 -0
  220. package/dist/features/Operation/components/ParameterListItem.vue.d.ts.map +1 -1
  221. package/dist/features/Operation/components/ParameterListItem.vue.js +2 -2
  222. package/dist/features/Operation/components/ParameterListItem.vue2.js +31 -29
  223. package/dist/features/Operation/components/ParameterListItem.vue3.js +4 -0
  224. package/dist/features/Operation/components/RequestBody.vue.js +1 -1
  225. package/dist/features/Operation/components/RequestBody.vue3.js +4 -0
  226. package/dist/features/Operation/components/callbacks/Callback.vue.d.ts +8 -6
  227. package/dist/features/Operation/components/callbacks/Callback.vue.d.ts.map +1 -1
  228. package/dist/features/Operation/components/callbacks/Callback.vue.js +4 -4
  229. package/dist/features/Operation/components/callbacks/Callback.vue2.js +22 -29
  230. package/dist/features/Operation/components/callbacks/Callback.vue3.js +4 -0
  231. package/dist/features/Operation/components/callbacks/Callbacks.vue.d.ts +5 -3
  232. package/dist/features/Operation/components/callbacks/Callbacks.vue.d.ts.map +1 -1
  233. package/dist/features/Operation/components/callbacks/Callbacks.vue.js +25 -18
  234. package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts +17 -12
  235. package/dist/features/Operation/layouts/ClassicLayout.vue.d.ts.map +1 -1
  236. package/dist/features/Operation/layouts/ClassicLayout.vue.js +2 -2
  237. package/dist/features/Operation/layouts/ClassicLayout.vue2.js +178 -162
  238. package/dist/features/Operation/layouts/ClassicLayout.vue3.js +4 -0
  239. package/dist/features/Operation/layouts/ModernLayout.vue.d.ts +18 -13
  240. package/dist/features/Operation/layouts/ModernLayout.vue.d.ts.map +1 -1
  241. package/dist/features/Operation/layouts/ModernLayout.vue.js +3 -3
  242. package/dist/features/Operation/layouts/ModernLayout.vue2.js +132 -126
  243. package/dist/features/Operation/layouts/ModernLayout.vue3.js +4 -0
  244. package/dist/features/Search/SearchModal.vue.js +4 -4
  245. package/dist/features/Search/SearchModal.vue2.js +9 -9
  246. package/dist/features/Search/SearchModal.vue3.js +4 -0
  247. package/dist/features/api-client-modal/ApiClientModal.vue.d.ts.map +1 -1
  248. package/dist/features/api-client-modal/useApiClient.d.ts +5188 -5128
  249. package/dist/features/api-client-modal/useApiClient.d.ts.map +1 -1
  250. package/dist/features/base-url/BaseUrl.vue.d.ts.map +1 -1
  251. package/dist/features/base-url/BaseUrl.vue.js +26 -26
  252. package/dist/features/download-link/DownloadLink.vue.js +2 -2
  253. package/dist/features/download-link/DownloadLink.vue3.js +4 -0
  254. package/dist/features/example-responses/ExampleResponse.vue.d.ts +4 -2
  255. package/dist/features/example-responses/ExampleResponse.vue.d.ts.map +1 -1
  256. package/dist/features/example-responses/ExampleResponse.vue.js +3 -3
  257. package/dist/features/example-responses/ExampleResponse.vue2.js +15 -14
  258. package/dist/features/example-responses/ExampleResponse.vue3.js +4 -0
  259. package/dist/features/example-responses/ExampleResponseTab.vue.js +3 -3
  260. package/dist/features/example-responses/ExampleResponseTab.vue3.js +4 -0
  261. package/dist/features/example-responses/ExampleResponseTabList.vue.js +2 -2
  262. package/dist/features/example-responses/ExampleResponseTabList.vue3.js +4 -0
  263. package/dist/features/example-responses/ExampleResponses.vue.d.ts +3 -2
  264. package/dist/features/example-responses/ExampleResponses.vue.d.ts.map +1 -1
  265. package/dist/features/example-responses/ExampleResponses.vue.js +4 -4
  266. package/dist/features/example-responses/ExampleResponses.vue2.js +110 -104
  267. package/dist/features/example-responses/ExampleResponses.vue3.js +4 -0
  268. package/dist/features/external-docs/ExternalDocs.vue.d.ts +7 -0
  269. package/dist/features/external-docs/ExternalDocs.vue.d.ts.map +1 -0
  270. package/dist/features/external-docs/ExternalDocs.vue.js +36 -0
  271. package/dist/features/external-docs/ExternalDocs.vue2.js +4 -0
  272. package/dist/features/external-docs/index.d.ts +2 -0
  273. package/dist/features/external-docs/index.d.ts.map +1 -0
  274. package/dist/features/info-object/Contact.vue.d.ts +7 -0
  275. package/dist/features/info-object/Contact.vue.d.ts.map +1 -0
  276. package/dist/features/info-object/Contact.vue.js +44 -0
  277. package/dist/features/info-object/Contact.vue2.js +4 -0
  278. package/dist/features/info-object/License.vue.d.ts +7 -0
  279. package/dist/features/info-object/License.vue.d.ts.map +1 -0
  280. package/dist/features/info-object/License.vue.js +37 -0
  281. package/dist/features/info-object/License.vue2.js +4 -0
  282. package/dist/features/info-object/TermsOfService.vue.d.ts +7 -0
  283. package/dist/features/info-object/TermsOfService.vue.d.ts.map +1 -0
  284. package/dist/features/info-object/TermsOfService.vue.js +30 -0
  285. package/dist/features/info-object/TermsOfService.vue2.js +4 -0
  286. package/dist/features/info-object/index.d.ts +4 -0
  287. package/dist/features/info-object/index.d.ts.map +1 -0
  288. package/dist/features/sidebar/components/Sidebar.vue.js +3 -3
  289. package/dist/features/sidebar/components/Sidebar.vue3.js +4 -0
  290. package/dist/features/sidebar/components/SidebarElement.vue.js +3 -3
  291. package/dist/features/sidebar/components/SidebarElement.vue3.js +4 -0
  292. package/dist/features/sidebar/components/SidebarGroup.vue.js +1 -1
  293. package/dist/features/sidebar/components/SidebarGroup.vue3.js +4 -0
  294. package/dist/features/sidebar/components/SidebarHttpBadge.vue.js +1 -1
  295. package/dist/features/sidebar/components/SidebarHttpBadge.vue3.js +4 -0
  296. package/dist/features/sidebar/helpers/create-sidebar.js +12 -12
  297. package/dist/features/test-request-button/TestRequestButton.vue.d.ts +3 -2
  298. package/dist/features/test-request-button/TestRequestButton.vue.d.ts.map +1 -1
  299. package/dist/features/test-request-button/TestRequestButton.vue.js +3 -3
  300. package/dist/features/test-request-button/TestRequestButton.vue2.js +21 -19
  301. package/dist/features/test-request-button/TestRequestButton.vue3.js +4 -0
  302. package/dist/features/traverse-schema/index.d.ts +2 -1
  303. package/dist/features/traverse-schema/index.d.ts.map +1 -1
  304. package/dist/helpers/convert-security-scheme.js +23 -0
  305. package/dist/helpers/test-utils.d.ts +51 -0
  306. package/dist/helpers/test-utils.d.ts.map +1 -0
  307. package/dist/index.d.ts +1 -1
  308. package/dist/index.d.ts.map +1 -1
  309. package/dist/index.js +24 -23
  310. package/dist/style.css +1 -1
  311. package/dist/types.d.ts +5 -0
  312. package/dist/types.d.ts.map +1 -1
  313. package/dist/v2/ApiReferenceWorkspace.vue.d.ts +4 -2
  314. package/dist/v2/ApiReferenceWorkspace.vue.d.ts.map +1 -1
  315. package/dist/v2/ApiReferenceWorkspace.vue.js +100 -83
  316. package/dist/v2/ApiReferenceWorkspace.vue2.js +4 -0
  317. package/dist/v2/ApiReferenceWorkspace.vue3.js +1 -1
  318. package/dist/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue.d.ts +2 -4
  319. package/dist/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue.d.ts.map +1 -1
  320. package/dist/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue.js +4 -0
  321. package/dist/v2/blocks/scalar-request-example-block/components/ExamplePicker.vue2.js +72 -0
  322. package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue.d.ts +4 -13
  323. package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue.d.ts.map +1 -1
  324. package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue.js +7 -0
  325. package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue2.js +231 -0
  326. package/dist/v2/blocks/scalar-request-example-block/components/RequestExample.vue3.js +4 -0
  327. package/dist/v2/blocks/scalar-request-example-block/helpers/find-client.d.ts +1 -0
  328. package/dist/v2/blocks/scalar-request-example-block/helpers/find-client.d.ts.map +1 -1
  329. package/dist/v2/blocks/scalar-request-example-block/helpers/find-client.js +21 -3
  330. package/dist/v2/blocks/scalar-request-example-block/helpers/generate-client-options.d.ts +12 -13
  331. package/dist/v2/blocks/scalar-request-example-block/helpers/generate-client-options.d.ts.map +1 -1
  332. package/dist/v2/blocks/scalar-request-example-block/helpers/generate-client-options.js +33 -0
  333. package/dist/v2/blocks/scalar-request-example-block/helpers/generate-code-snippet.js +29 -0
  334. package/dist/v2/blocks/scalar-request-example-block/helpers/get-secrets.js +10 -0
  335. package/dist/v2/blocks/scalar-request-example-block/index.d.ts +2 -2
  336. package/dist/v2/blocks/scalar-request-example-block/types.d.ts +11 -3
  337. package/dist/v2/blocks/scalar-request-example-block/types.d.ts.map +1 -1
  338. package/dist/v2/events/definitions.js +7 -0
  339. package/dist/v2/events/index.d.ts +1 -1
  340. package/dist/v2/events/listeners.d.ts +1 -1
  341. package/package.json +18 -18
  342. package/LICENSE +0 -21
  343. package/dist/blocks/constants.js +0 -6
  344. package/dist/blocks/helpers/getPointer.js +0 -12
  345. package/dist/blocks/hooks/useBlockProps.d.ts +0 -31
  346. package/dist/blocks/hooks/useBlockProps.d.ts.map +0 -1
  347. package/dist/blocks/hooks/useBlockProps.js +0 -24
  348. package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.d.ts +0 -16
  349. package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.d.ts.map +0 -1
  350. package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.js +0 -36
  351. package/dist/components/Content/Lazy/Lazy.vue.d.ts.map +0 -1
  352. package/dist/components/Content/Lazy/Lazy.vue2.js +0 -22
  353. package/dist/components/Content/Lazy/Loading.vue.d.ts +0 -18
  354. package/dist/components/Content/Lazy/Loading.vue.d.ts.map +0 -1
  355. package/dist/components/Content/Lazy/Loading.vue.js +0 -163
  356. package/dist/components/Content/Lazy/Loading.vue3.js +0 -5
  357. package/dist/components/Content/Lazy/index.d.ts +0 -3
  358. package/dist/components/Content/Lazy/index.d.ts.map +0 -1
  359. package/dist/components/Content/Lazy/lazyBus.d.ts +0 -4
  360. package/dist/components/Content/Lazy/lazyBus.d.ts.map +0 -1
  361. package/dist/components/Content/Lazy/lazyBus.js +0 -5
  362. package/dist/components/Content/Models/ModelsAccordion.vue.d.ts.map +0 -1
  363. package/dist/components/Content/Models/ModelsAccordion.vue.js +0 -7
  364. package/dist/components/Content/Tag/OperationsList.vue.d.ts.map +0 -1
  365. package/dist/components/Content/Tag/OperationsList.vue.js +0 -7
  366. package/dist/components/Content/Tag/OperationsList.vue2.js +0 -58
  367. package/dist/components/Content/Tag/OperationsListItem.vue.d.ts.map +0 -1
  368. package/dist/components/Content/Tag/OperationsListItem.vue.js +0 -7
  369. package/dist/components/Content/Tag/OperationsListItem.vue2.js +0 -67
  370. package/dist/components/Content/Tag/Tag.vue.d.ts.map +0 -1
  371. package/dist/components/Content/Tag/Tag.vue.js +0 -99
  372. package/dist/components/Content/Tag/TagAccordion.vue.d.ts.map +0 -1
  373. package/dist/components/Content/Tag/TagAccordion.vue.js +0 -7
  374. package/dist/components/Content/Tag/TagAccordion.vue2.js +0 -50
  375. package/dist/components/Content/Tag/TagList.vue.d.ts +0 -22
  376. package/dist/components/Content/Tag/TagList.vue.d.ts.map +0 -1
  377. package/dist/components/Content/Tag/TagList.vue.js +0 -73
  378. package/dist/components/Content/Tag/TagList.vue2.js +0 -4
  379. package/dist/components/Content/Tag/TagSection.vue.d.ts.map +0 -1
  380. package/dist/components/Content/Tag/TagSection.vue.js +0 -7
  381. package/dist/components/Content/Tag/TagSection.vue2.js +0 -67
  382. package/dist/components/Content/Tag/index.d.ts +0 -3
  383. package/dist/components/Content/Tag/index.d.ts.map +0 -1
  384. package/dist/features/example-request/ExamplePicker.vue.d.ts +0 -13
  385. package/dist/features/example-request/ExamplePicker.vue.d.ts.map +0 -1
  386. package/dist/features/example-request/ExamplePicker.vue.js +0 -7
  387. package/dist/features/example-request/ExamplePicker.vue2.js +0 -57
  388. package/dist/features/example-request/ExampleRequest.vue.d.ts +0 -85
  389. package/dist/features/example-request/ExampleRequest.vue.d.ts.map +0 -1
  390. package/dist/features/example-request/ExampleRequest.vue.js +0 -7
  391. package/dist/features/example-request/ExampleRequest.vue2.js +0 -348
  392. package/dist/features/example-request/TextSelect.vue.d.ts +0 -34
  393. package/dist/features/example-request/TextSelect.vue.d.ts.map +0 -1
  394. package/dist/features/example-request/TextSelect.vue.js +0 -48
  395. package/dist/features/example-request/TextSelect.vue3.js +0 -5
  396. package/dist/features/example-request/index.d.ts +0 -3
  397. package/dist/features/example-request/index.d.ts.map +0 -1
  398. package/dist/stores/useHttpClientStore.d.ts +0 -43
  399. package/dist/stores/useHttpClientStore.d.ts.map +0 -1
  400. package/dist/stores/useHttpClientStore.js +0 -70
  401. package/dist/v2/hooks/useStore.d.ts +0 -9
  402. package/dist/v2/hooks/useStore.d.ts.map +0 -1
  403. /package/dist/components/Content/{Tag → Tags}/Tag.vue2.js +0 -0
  404. /package/dist/components/{Content/Lazy → Lazy}/Lazy.vue.js +0 -0
@@ -1,348 +0,0 @@
1
- import { defineComponent as ye, useId as ve, ref as j, inject as Q, computed as c, watch as Y, onMounted as ge, createBlock as w, createCommentVNode as J, unref as r, openBlock as g, withCtx as s, createVNode as n, renderSlot as T, createTextVNode as K, createElementBlock as U, Fragment as Z, toDisplayString as D, createElementVNode as _ } from "vue";
2
- import { useWorkspace as xe } from "@scalar/api-client/store";
3
- import { getHarRequest as he, getSnippet as qe } from "@scalar/api-client/views/Components/CodeSnippet";
4
- import { filterSecurityRequirements as Ee } from "@scalar/api-client/views/Request/RequestSection";
5
- import { ScalarCard as ee, ScalarCardHeader as Se, ScalarCardSection as te, ScalarCodeBlock as Ke, ScalarCardFooter as be } from "@scalar/components";
6
- import { freezeElement as ke } from "@scalar/helpers/dom/freeze-element";
7
- import { requestSchema as Ce, createExampleFromRequest as Oe } from "@scalar/oas-utils/entities/spec";
8
- import { isDereferenced as Ne } from "@scalar/openapi-types/helpers";
9
- import H from "../../components/ScreenReader.vue.js";
10
- import { useConfig as Te } from "../../hooks/useConfig.js";
11
- import { EXAMPLE_CONTEXT as Ve, DISCRIMINATOR_CONTEXT as Re } from "../../hooks/useDiscriminator.js";
12
- import { useHttpClientStore as $e } from "../../stores/useHttpClientStore.js";
13
- import Be from "./ExamplePicker.vue.js";
14
- import je from "./TextSelect.vue.js";
15
- /* empty css */
16
- import ae from "../../components/HttpMethod/HttpMethod.vue.js";
17
- import { useExampleStore as we } from "../../legacy/stores/useExampleStore.js";
18
- const Je = ["id"], Ue = {
19
- key: 0,
20
- class: "request-card-footer-addon"
21
- }, De = { class: "request-header" }, at = /* @__PURE__ */ ye({
22
- __name: "ExampleRequest",
23
- props: {
24
- server: {},
25
- collection: {},
26
- operation: {},
27
- request: {},
28
- method: {},
29
- fallback: { type: Boolean },
30
- schemas: {}
31
- },
32
- setup(l) {
33
- const { selectedExampleKey: I, operationId: le } = we(), { requestExamples: b, securitySchemes: M, requestExampleMutators: V } = xe(), re = Te(), {
34
- httpClient: u,
35
- setHttpClient: oe,
36
- availableTargets: A,
37
- httpTargetTitle: se,
38
- httpClientTitle: ne
39
- } = $e(), F = ve(), x = j(!1), k = Q(Ve), f = Q(Re), R = c(() => {
40
- var e;
41
- return (e = f == null ? void 0 : f.value) == null ? void 0 : e.selectedType;
42
- }), P = c(
43
- () => {
44
- var e;
45
- return ((e = f == null ? void 0 : f.value) == null ? void 0 : e.hasDiscriminator) || !1;
46
- }
47
- ), d = c(() => {
48
- var t;
49
- const e = ["x-custom-examples", "x-codeSamples", "x-code-samples"];
50
- for (const a of e)
51
- if ((t = l.operation) != null && t[a])
52
- return [...l.operation[a]];
53
- return [];
54
- }), o = j(
55
- // Default to first custom example
56
- d.value.length ? {
57
- targetKey: "customExamples",
58
- clientKey: 0
59
- } : (
60
- // Otherwise use the globally selected HTTP client
61
- {
62
- targetKey: u.targetKey,
63
- clientKey: u.clientKey
64
- }
65
- )
66
- );
67
- Y(u, () => {
68
- o.value = {
69
- targetKey: u.targetKey,
70
- clientKey: u.clientKey
71
- };
72
- });
73
- const X = c(() => {
74
- const e = C.value;
75
- return Object.keys(e).length > 1;
76
- }), ue = () => {
77
- var q, E, S;
78
- if (o.value.targetKey === "customExamples")
79
- return ((q = d.value[o.value.clientKey]) == null ? void 0 : q.source) ?? "";
80
- const e = u.clientKey, t = u.targetKey, a = l.request || Ce.parse({
81
- uid: l.operation.operationId || "temp-request",
82
- method: l.method,
83
- path: l.operation.path,
84
- parameters: l.operation.parameters || [],
85
- requestBody: l.operation.requestBody,
86
- examples: [],
87
- type: "request",
88
- selectedSecuritySchemeUids: [],
89
- selectedServerUid: "",
90
- servers: [],
91
- summary: l.operation.summary || "Example Request"
92
- });
93
- let i = b[((S = (E = l.request) == null ? void 0 : E.examples) == null ? void 0 : S[0]) ?? ""];
94
- if (!i) {
95
- const N = C.value, m = Object.keys(N)[0];
96
- i = Oe(a, m);
97
- }
98
- const p = Ee(
99
- l.operation.security || l.collection.security,
100
- l.collection.selectedSecuritySchemeUids,
101
- M
102
- ), y = he({
103
- operation: a,
104
- example: i,
105
- server: l.server,
106
- securitySchemes: p
107
- }), [h, O] = qe(t, e, y);
108
- return h ? h.message ?? "" : O;
109
- }, z = c(() => {
110
- try {
111
- return ue();
112
- } catch (e) {
113
- return console.error("[generateSnippet]", e), "";
114
- }
115
- }), C = c(() => {
116
- var a;
117
- if (!Ne(l.operation.requestBody))
118
- return {};
119
- const e = ((a = l.operation.requestBody) == null ? void 0 : a.content) ?? {}, t = Object.values(e)[0];
120
- return (t == null ? void 0 : t.examples) ?? {};
121
- }), ie = c(() => {
122
- var t, a;
123
- const e = (
124
- // Specified language
125
- ((t = o.value) == null ? void 0 : t.targetKey) === "customExamples" ? ((a = d.value[o.value.clientKey]) == null ? void 0 : a.lang) ?? "plaintext" : (
126
- // Or language for the globally selected HTTP client
127
- u.targetKey
128
- )
129
- );
130
- return e === "shell" && z.value.includes("curl") ? "curl" : e === "Objective-C" ? "objc" : e;
131
- }), ce = c(
132
- () => Object.values(M).flatMap((e) => e.type === "apiKey" ? e.value : (e == null ? void 0 : e.type) === "http" ? [
133
- e.token,
134
- e.password,
135
- btoa(`${e.username}:${e.password}`)
136
- ] : e.type === "oauth2" ? Object.values(e.flows).map((t) => t.token) : [])
137
- ), me = c(() => {
138
- const e = A.value.map((t) => ({
139
- value: t.key,
140
- label: t.title,
141
- options: t.clients.map((a) => ({
142
- value: JSON.stringify({
143
- targetKey: t.key,
144
- clientKey: a.client
145
- }),
146
- label: a.title
147
- }))
148
- }));
149
- return d.value.length && e.unshift({
150
- value: "customExamples",
151
- label: "Examples",
152
- options: d.value.map((t, a) => ({
153
- value: JSON.stringify({
154
- targetKey: "customExamples",
155
- clientKey: a
156
- }),
157
- label: t.label ?? t.lang ?? `Example #${a + 1}`
158
- }))
159
- }), e;
160
- }), $ = j(null);
161
- function de(e) {
162
- const t = JSON.parse(e);
163
- if ($.value) {
164
- const a = ke($.value.$el);
165
- setTimeout(() => {
166
- a();
167
- }, 300);
168
- }
169
- t.targetKey === "customExamples" || o.value.targetKey === "customExamples" && t.targetKey === u.targetKey && t.clientKey === u.clientKey ? o.value = t : oe(t);
170
- }
171
- function pe(e) {
172
- var i, p;
173
- if (!e)
174
- return;
175
- I.value = e, le.value = l.operation.operationId;
176
- const t = b[((p = (i = l.request) == null ? void 0 : i.examples) == null ? void 0 : p[0]) ?? ""], a = C.value[e];
177
- if (t && (a != null && a.value))
178
- try {
179
- V.edit(
180
- t.uid,
181
- "body.raw.value",
182
- JSON.stringify(a.value, null, 2)
183
- );
184
- } catch (y) {
185
- console.error("[handleExampleUpdate]", y);
186
- }
187
- }
188
- ge(() => {
189
- P.value && R.value && !x.value && L(R.value);
190
- });
191
- const L = (e) => {
192
- var t, a, i, p, y, h, O, q, E, S, N;
193
- if (!x.value)
194
- try {
195
- x.value = !0;
196
- const m = b[((a = (t = l.request) == null ? void 0 : t.examples) == null ? void 0 : a[0]) ?? ""];
197
- if (m && (k != null && k.generateExampleValue)) {
198
- const fe = (p = (i = m.body) == null ? void 0 : i.raw) != null && p.value ? JSON.parse(m.body.raw.value) : void 0, B = k.generateExampleValue(
199
- Array.isArray(fe)
200
- );
201
- if (V.edit(
202
- m.uid,
203
- "body.raw.value",
204
- JSON.stringify(B, null, 2)
205
- ), (h = (y = l.request) == null ? void 0 : y.examples) != null && h[0]) {
206
- const v = b[(q = (O = l.request) == null ? void 0 : O.examples) == null ? void 0 : q[0]];
207
- v && V.edit(
208
- v.uid,
209
- "body.raw.value",
210
- JSON.stringify(B, null, 2)
211
- );
212
- }
213
- if ((N = (S = (E = l.operation.requestBody) == null ? void 0 : E.content) == null ? void 0 : S["application/json"]) != null && N.examples) {
214
- const v = l.operation.requestBody.content["application/json"].examples;
215
- Object.keys(v).forEach((W) => {
216
- var G;
217
- (G = v[W]) != null && G.value && (v[W].value = B);
218
- });
219
- }
220
- }
221
- } catch (m) {
222
- console.error("[handleDiscriminatorChange]", m);
223
- } finally {
224
- x.value = !1;
225
- }
226
- };
227
- return Y(R, (e) => {
228
- e && P.value && !x.value && L();
229
- }), (e, t) => r(A).length || d.value.length ? (g(), w(r(ee), {
230
- key: 0,
231
- class: "request-card dark-mode",
232
- ref_key: "elem",
233
- ref: $
234
- }, {
235
- default: s(() => [
236
- n(r(Se), { class: "pr-0.75" }, {
237
- actions: s(() => [
238
- n(je, {
239
- class: "request-client-picker",
240
- controls: `${r(F)}-example`,
241
- modelValue: JSON.stringify(o.value),
242
- options: me.value,
243
- "onUpdate:modelValue": de
244
- }, {
245
- default: s(() => [
246
- o.value.targetKey === "customExamples" ? (g(), U(Z, { key: 0 }, [
247
- n(H, null, {
248
- default: s(() => t[1] || (t[1] = [
249
- K("Selected Example:")
250
- ])),
251
- _: 1,
252
- __: [1]
253
- }),
254
- K(" " + D(d.value[o.value.clientKey].label ?? "Example"), 1)
255
- ], 64)) : (g(), U(Z, { key: 1 }, [
256
- n(H, null, {
257
- default: s(() => t[2] || (t[2] = [
258
- K("Selected HTTP client:")
259
- ])),
260
- _: 1,
261
- __: [2]
262
- }),
263
- K(" " + D(r(se)) + " " + D(r(ne)), 1)
264
- ], 64))
265
- ]),
266
- _: 1
267
- }, 8, ["controls", "modelValue", "options"])
268
- ]),
269
- default: s(() => [
270
- n(H, null, {
271
- default: s(() => t[0] || (t[0] = [
272
- K("Request Example for")
273
- ])),
274
- _: 1,
275
- __: [0]
276
- }),
277
- n(r(ae), {
278
- as: "span",
279
- class: "request-method",
280
- method: e.method
281
- }, null, 8, ["method"]),
282
- T(e.$slots, "header", {}, void 0, !0)
283
- ]),
284
- _: 3
285
- }),
286
- n(r(te), { class: "request-editor-section custom-scroll border-none p-0" }, {
287
- default: s(() => [
288
- _("div", {
289
- id: `${r(F)}-example`,
290
- class: "code-snippet"
291
- }, [
292
- n(r(Ke), {
293
- class: "bg-b-2 !min-h-full -outline-offset-2",
294
- content: z.value,
295
- hideCredentials: ce.value,
296
- lang: ie.value,
297
- lineNumbers: ""
298
- }, null, 8, ["content", "hideCredentials", "lang"])
299
- ], 8, Je)
300
- ]),
301
- _: 1
302
- }),
303
- (X.value || !r(re).hideTestRequestButton) && e.$slots.footer ? (g(), w(r(be), {
304
- key: 0,
305
- class: "request-card-footer bg-b-3"
306
- }, {
307
- default: s(() => [
308
- X.value ? (g(), U("div", Ue, [
309
- n(Be, {
310
- class: "request-example-selector",
311
- examples: C.value,
312
- modelValue: r(I),
313
- "onUpdate:modelValue": pe
314
- }, null, 8, ["examples", "modelValue"])
315
- ])) : J("", !0),
316
- T(e.$slots, "footer", {}, void 0, !0)
317
- ]),
318
- _: 3
319
- })) : J("", !0)
320
- ]),
321
- _: 3
322
- }, 512)) : e.fallback ? (g(), w(r(ee), {
323
- key: 1,
324
- class: "request-card dark-mode"
325
- }, {
326
- default: s(() => [
327
- n(r(te), { class: "request-card-simple" }, {
328
- default: s(() => [
329
- _("div", De, [
330
- n(r(ae), {
331
- as: "span",
332
- class: "request-method",
333
- method: e.method
334
- }, null, 8, ["method"]),
335
- T(e.$slots, "header", {}, void 0, !0)
336
- ]),
337
- T(e.$slots, "footer", {}, void 0, !0)
338
- ]),
339
- _: 3
340
- })
341
- ]),
342
- _: 3
343
- })) : J("", !0);
344
- }
345
- });
346
- export {
347
- at as default
348
- };
@@ -1,34 +0,0 @@
1
- type __VLS_Props = {
2
- modelValue: any;
3
- options: {
4
- value: string;
5
- label: string;
6
- options?: {
7
- value: string;
8
- label: string;
9
- }[];
10
- }[];
11
- controls?: string;
12
- };
13
- declare function __VLS_template(): {
14
- attrs: Partial<{}>;
15
- slots: {
16
- default?(_: {}): any;
17
- };
18
- refs: {};
19
- rootEl: HTMLLabelElement;
20
- };
21
- type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
22
- declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
23
- "update:modelValue": (value: any) => any;
24
- }, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
25
- "onUpdate:modelValue"?: ((value: any) => any) | undefined;
26
- }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, HTMLLabelElement>;
27
- declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
28
- export default _default;
29
- type __VLS_WithTemplateSlots<T, S> = T & {
30
- new (): {
31
- $slots: S;
32
- };
33
- };
34
- //# sourceMappingURL=TextSelect.vue.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"TextSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/features/example-request/TextSelect.vue"],"names":[],"mappings":"AA4HA,KAAK,WAAW,GAAG;IACjB,UAAU,EAAE,GAAG,CAAA;IACf,OAAO,EAAE;QACP,KAAK,EAAE,MAAM,CAAA;QACb,KAAK,EAAE,MAAM,CAAA;QACb,OAAO,CAAC,EAAE;YACR,KAAK,EAAE,MAAM,CAAA;YACb,KAAK,EAAE,MAAM,CAAA;SACd,EAAE,CAAA;KACJ,EAAE,CAAA;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,CAAC;AAkBF,iBAAS,cAAc;WAyDT,OAAO,IAA6B;;yBARrB,GAAG;;;;EAa/B;AAUD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;+FAQnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1,48 +0,0 @@
1
- import { defineComponent as m, computed as v, createElementBlock as l, openBlock as o, normalizeClass as b, createElementVNode as u, renderSlot as _, Fragment as s, renderList as r, toDisplayString as p } from "vue";
2
- const g = { class: "text-select-label" }, f = ["aria-controls", "tabindex", "value"], k = ["label"], y = ["value"], V = ["value"], S = /* @__PURE__ */ m({
3
- __name: "TextSelect",
4
- props: {
5
- modelValue: {},
6
- options: {},
7
- controls: {}
8
- },
9
- emits: ["update:modelValue"],
10
- setup(i) {
11
- const d = i, c = v(
12
- () => d.options.flatMap((e) => e.options ?? e).length
13
- );
14
- return (e, n) => (o(), l("label", {
15
- class: b(["text-select", c.value === 1 ? "text-select--single-option" : ""])
16
- }, [
17
- u("span", g, [
18
- _(e.$slots, "default")
19
- ]),
20
- u("select", {
21
- "aria-controls": e.controls,
22
- tabindex: e.options.length === 1 ? -1 : 0,
23
- value: e.modelValue,
24
- onInput: n[0] || (n[0] = (t) => e.$emit("update:modelValue", t.target.value))
25
- }, [
26
- (o(!0), l(s, null, r(e.options, (t) => (o(), l(s, {
27
- key: t.value
28
- }, [
29
- t.options ? (o(), l("optgroup", {
30
- key: 0,
31
- label: t.label
32
- }, [
33
- (o(!0), l(s, null, r(t.options, (a) => (o(), l("option", {
34
- key: a.value,
35
- value: a.value
36
- }, p(a.label), 9, y))), 128))
37
- ], 8, k)) : (o(), l("option", {
38
- key: t.value,
39
- value: t.value
40
- }, p(t.label), 9, V))
41
- ], 64))), 128))
42
- ], 40, f)
43
- ], 2));
44
- }
45
- });
46
- export {
47
- S as default
48
- };
@@ -1,5 +0,0 @@
1
- import o from "./TextSelect.vue.js";
2
- /* empty css */
3
- export {
4
- o as default
5
- };
@@ -1,3 +0,0 @@
1
- export { default as ExamplePicker } from './ExamplePicker.vue.js';
2
- export { default as ExampleRequest } from './ExampleRequest.vue.js';
3
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/features/example-request/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,qBAAqB,CAAA;AAC9D,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,sBAAsB,CAAA"}
@@ -1,43 +0,0 @@
1
- import type { HiddenClients } from '@scalar/types/legacy';
2
- import type { Target, TargetId } from '@scalar/types/snippetz';
3
- import { type Ref } from 'vue';
4
- /**
5
- * Gets the client title from the availableTargets
6
- * { targetKey: 'shell', clientKey: 'curl' } -> 'Shell'
7
- */
8
- declare function getTargetTitle(client: HttpClientState): string;
9
- /**
10
- * Gets the client title from the availableTargets
11
- * { targetKey: 'shell', clientKey: 'curl' } -> 'cURL'
12
- */
13
- declare function getClientTitle(client: HttpClientState): string;
14
- /**
15
- * Filters out hidden clients from the available targets (based on the given configuration).
16
- */
17
- export declare function filterHiddenClients(targets: Target[], exclude: Ref<HiddenClients>): Target[];
18
- /** The selected HTTP client */
19
- export type HttpClientState = {
20
- targetKey: TargetId;
21
- clientKey: string;
22
- };
23
- declare function setDefaultHttpClient(httpClient?: HttpClientState): void;
24
- declare function resetState(): void;
25
- /** Keep track of the available and the selected HTTP client(s) */
26
- export declare const useHttpClientStore: () => {
27
- httpClient: {
28
- readonly targetKey: TargetId;
29
- readonly clientKey: string;
30
- };
31
- resetState: typeof resetState;
32
- setHttpClient: (newState: Partial<HttpClientState>) => void;
33
- setDefaultHttpClient: typeof setDefaultHttpClient;
34
- excludedClients: Ref<HiddenClients>;
35
- setExcludedClients: (v: HiddenClients) => void;
36
- availableTargets: import("vue").ComputedRef<Target[]>;
37
- getClientTitle: typeof getClientTitle;
38
- getTargetTitle: typeof getTargetTitle;
39
- httpTargetTitle: import("vue").ComputedRef<string>;
40
- httpClientTitle: import("vue").ComputedRef<string>;
41
- };
42
- export {};
43
- //# sourceMappingURL=useHttpClientStore.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useHttpClientStore.d.ts","sourceRoot":"","sources":["../../src/stores/useHttpClientStore.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAA;AACzD,OAAO,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAA;AAC9D,OAAO,EAAE,KAAK,GAAG,EAAqC,MAAM,KAAK,CAAA;AASjE;;;GAGG;AACH,iBAAS,cAAc,CAAC,MAAM,EAAE,eAAe,UAE9C;AAED;;;GAGG;AACH,iBAAS,cAAc,CAAC,MAAM,EAAE,eAAe,UAM9C;AAYD;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,OAAO,EAAE,GAAG,CAAC,aAAa,CAAC,GAAG,MAAM,EAAE,CAoD5F;AASD,+BAA+B;AAC/B,MAAM,MAAM,eAAe,GAAG;IAAE,SAAS,EAAE,QAAQ,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE,CAAA;AAMxE,iBAAS,oBAAoB,CAAC,UAAU,CAAC,EAAE,eAAe,QAOzD;AAiCD,iBAAS,UAAU,SAElB;AAeD,kEAAkE;AAClE,eAAO,MAAM,kBAAkB;;4BAhEY,QAAQ;4BAAa,MAAM;;;8BAqDrC,OAAO,CAAC,eAAe,CAAC;;qBAiBP,GAAG,CAAC,aAAa,CAAC;4BACxC,aAAa;;;;;;CAaxC,CAAA"}
@@ -1,70 +0,0 @@
1
- import { safeLocalStorage as T, REFERENCE_LS_KEYS as m } from "@scalar/helpers/object/local-storage";
2
- import { objectReplace as p } from "@scalar/helpers/object/object-replace";
3
- import { snippetz as A } from "@scalar/snippetz";
4
- import { computed as o, readonly as a, ref as C, reactive as k } from "vue";
5
- const y = {
6
- targetKey: "shell",
7
- clientKey: "curl"
8
- }, { clients: H } = A();
9
- function d(t) {
10
- var n;
11
- return ((n = r.value.find((e) => e.key === t.targetKey)) == null ? void 0 : n.title) ?? t.targetKey;
12
- }
13
- function E(t) {
14
- var n, e;
15
- return ((e = (n = r.value.find((i) => i.key === t.targetKey)) == null ? void 0 : n.clients.find((i) => i.client === t.clientKey)) == null ? void 0 : e.title) ?? t.clientKey;
16
- }
17
- const L = o(() => d(l)), S = o(() => E(l));
18
- function _(t, n) {
19
- return n.value === !0 ? [] : t.flatMap((e) => {
20
- var i;
21
- return typeof n.value != "object" ? [] : Array.isArray(n.value) ? (e.clients = e.clients.filter(
22
- // @ts-expect-error Typescript, chill. It's all good. It has to be an array.
23
- (s) => !n.value.includes(s.client)
24
- ), e.clients.length ? [e] : []) : n.value[e.key] === !0 ? [] : (Array.isArray(n.value[e.key]) && (e.clients = e.clients.filter((s) => !// @ts-expect-error We checked whether it's an Array already.
25
- n.value[e.key].includes(s.client))), (i = e == null ? void 0 : e.clients) != null && i.length ? [e] : []);
26
- });
27
- }
28
- const r = o(() => _(H(), c)), c = C({}), f = C();
29
- function b(t) {
30
- t !== void 0 && (f.value = t, K(u()));
31
- }
32
- const u = () => {
33
- var t, n, e, i;
34
- return v(f.value) ? f.value : v(y) ? y : {
35
- targetKey: (t = r.value[0]) == null ? void 0 : t.key,
36
- clientKey: (i = (e = (n = r.value[0]) == null ? void 0 : n.clients) == null ? void 0 : e[0]) == null ? void 0 : i.client
37
- };
38
- };
39
- function v(t) {
40
- return t === void 0 ? !1 : !!r.value.find(
41
- (n) => n.key === t.targetKey && n.clients.find((e) => e.client === t.clientKey)
42
- );
43
- }
44
- function D() {
45
- p(l, u());
46
- }
47
- const l = k(u()), K = (t) => {
48
- Object.assign(l, {
49
- ...l,
50
- ...t
51
- }), T().setItem(m.SELECTED_CLIENT_DEPRECATED, JSON.stringify(l));
52
- }, I = () => ({
53
- httpClient: a(l),
54
- resetState: D,
55
- setHttpClient: K,
56
- setDefaultHttpClient: b,
57
- excludedClients: a(c),
58
- setExcludedClients: (t) => {
59
- c.value = t, p(l, u());
60
- },
61
- availableTargets: r,
62
- getClientTitle: E,
63
- getTargetTitle: d,
64
- httpTargetTitle: L,
65
- httpClientTitle: S
66
- });
67
- export {
68
- _ as filterHiddenClients,
69
- I as useHttpClientStore
70
- };
@@ -1,9 +0,0 @@
1
- import type { WorkspaceStore } from '@scalar/workspace-store/client';
2
- /**
3
- * Composable for accessing the new workspace store
4
- *
5
- * When called with a store it provides that store
6
- * When called without parameters, it returns the injected store
7
- */
8
- export declare const useStore: (store?: WorkspaceStore) => WorkspaceStore;
9
- //# sourceMappingURL=useStore.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useStore.d.ts","sourceRoot":"","sources":["../../../src/v2/hooks/useStore.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAA;AAKpE;;;;;GAKG;AACH,eAAO,MAAM,QAAQ,WAAY,cAAc,mBAe9C,CAAA"}