@mintlify/msft-sdk 1.1.61 → 1.1.63

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 (234) hide show
  1. package/dist/api-playground/ApiPlayground/Response/DownloadFileButton.js +6 -5
  2. package/dist/api-playground/ApiPlayground/Response/ResponseBody/CodeResponseContent.js +13 -12
  3. package/dist/api-playground/ApiPlayground/Response/ResponsePlaceholder.js +8 -7
  4. package/dist/api-playground/ApiPlayground/Response/ResponseTable.js +3 -2
  5. package/dist/api-playground/ApiPlayground/Response/ResponseTopbar.js +9 -8
  6. package/dist/api-playground/ApiPlayground/Response/index.js +4 -3
  7. package/dist/api-playground/ApiPlayground/components/AdditionalPropertyButton.js +42 -21
  8. package/dist/api-playground/ApiPlayground/components/ParamFieldWrapper.js +13 -9
  9. package/dist/api-playground/ApiPlayground/components/PlaygroundModalWrapper.js +6 -5
  10. package/dist/api-playground/ApiPlayground/components/SendPill.js +3 -2
  11. package/dist/api-playground/ApiPlayground/components/TypeDropdown.js +6 -5
  12. package/dist/api-playground/EndpointFields/ParamFields/ExampleDescription.js +3 -2
  13. package/dist/api-playground/EndpointFields/components/Description.js +6 -5
  14. package/dist/api-playground/EndpointFields/components/OptionDropdown.js +9 -8
  15. package/dist/api-playground/EndpointFields/components/SectionHeading.js +8 -7
  16. package/dist/api-playground-2/ApiExamples.js +19 -20
  17. package/dist/api-playground-2/ApiFields.js +20 -247
  18. package/dist/api-playground-2/EndpointHeader.js +59 -47
  19. package/dist/api-playground-2/OperationPage.js +70 -66
  20. package/dist/api-playground-2/Playground.js +67 -83
  21. package/dist/api-playground-2/SchemaPage.js +22 -9
  22. package/dist/api-playground-2/components/EndpointFields/Body.js +40 -0
  23. package/dist/api-playground-2/components/EndpointFields/Parameters.js +90 -0
  24. package/dist/api-playground-2/components/EndpointFields/Response.js +146 -0
  25. package/dist/api-playground-2/components/EndpointFields/Security.js +88 -0
  26. package/dist/api-playground-2/components/EndpointFields/fields/ArrayParamField.js +93 -0
  27. package/dist/api-playground-2/components/EndpointFields/fields/Enum.js +29 -11
  28. package/dist/api-playground-2/components/EndpointFields/fields/ObjectParamField.js +145 -0
  29. package/dist/api-playground-2/components/EndpointFields/fields/PrimitiveParamField.js +60 -48
  30. package/dist/api-playground-2/components/EndpointFields/fields/SchemaField.js +230 -0
  31. package/dist/api-playground-2/components/Example/GeneratedRequestExample.js +93 -89
  32. package/dist/api-playground-2/components/Example/GeneratedResponseExample.js +18 -17
  33. package/dist/api-playground-2/components/Example/RequestExample.js +92 -93
  34. package/dist/api-playground-2/components/Example/ResponseExample.js +19 -15
  35. package/dist/api-playground-2/components/Request/ParameterSection.js +20 -18
  36. package/dist/api-playground-2/components/Request/SecuritySection.js +53 -43
  37. package/dist/api-playground-2/components/Request/inputs/ArrayInput.js +89 -40
  38. package/dist/api-playground-2/components/Request/inputs/DifferentiatedInput.js +12 -12
  39. package/dist/api-playground-2/components/Request/inputs/FileInput.js +16 -15
  40. package/dist/api-playground-2/components/Request/inputs/InputContainer.js +76 -57
  41. package/dist/api-playground-2/components/Request/inputs/NumberInput.js +10 -9
  42. package/dist/api-playground-2/components/Request/inputs/ObjectInput.js +98 -80
  43. package/dist/api-playground-2/components/Request/inputs/OneOfInput.js +55 -47
  44. package/dist/api-playground-2/components/Request/inputs/SelectInput.js +18 -17
  45. package/dist/api-playground-2/components/Request/inputs/StringInput.js +19 -18
  46. package/dist/api-playground-2/components/Request/inputs/TextInput.js +12 -11
  47. package/dist/api-playground-2/components/SendPillWrapper.js +35 -0
  48. package/dist/api-playground-2/contexts/ApiPlaygroundContext.js +3 -5
  49. package/dist/api-playground-2/generators/createCookies.js +23 -0
  50. package/dist/api-playground-2/generators/createHeaders.js +53 -36
  51. package/dist/api-playground-2/generators/createQueryString.js +30 -0
  52. package/dist/api-playground-2/generators/generateAuthPlaceholder.js +14 -0
  53. package/dist/api-playground-2/generators/generateInteractiveCodeSample.js +27 -25
  54. package/dist/api-playground-2/generators/generateRequest.js +47 -51
  55. package/dist/api-playground-2/generators/generateResponseExampleMap.js +15 -11
  56. package/dist/api-playground-2/generators/generateSnippet.js +1 -1
  57. package/dist/api-playground-2/generators/generateSnippetMap.js +13 -11
  58. package/dist/api-playground-2/hooks/useCopyPathWithInputs.js +11 -11
  59. package/dist/api-playground-2/hooks/useInitializeInputs.js +185 -88
  60. package/dist/api-playground-2/hooks/usePlaygroundInputsStore.js +70 -25
  61. package/dist/api-playground-2/hooks/useSelectedBaseUrl.js +13 -0
  62. package/dist/api-playground-2/hooks/useSelectedExample.js +10 -0
  63. package/dist/api-playground-2/hooks/useSelectedRequestBodyContentType.js +12 -0
  64. package/dist/api-playground-2/hooks/useSelectedResponseContentType.js +12 -0
  65. package/dist/api-playground-2/hooks/useSelectedSecurityOption.js +31 -0
  66. package/dist/api-playground-2/hooks/useSendPlaygroundRequest.js +114 -101
  67. package/dist/api-playground-2/schemaGraph/addApiReferenceDataFromMdxAndDocsConfig.js +23 -32
  68. package/dist/api-playground-2/schemaGraph/addTypeLabelsToSchema.js +50 -0
  69. package/dist/api-playground-2/schemaGraph/addUniqueKeysToSchema.js +40 -24
  70. package/dist/api-playground-2/schemaGraph/getExampleBodyInputs.js +94 -0
  71. package/dist/api-playground-2/schemaGraph/getSchemaGraphOperationData.js +56 -50
  72. package/dist/api-playground-2/schemaGraph/processExamples.js +117 -52
  73. package/dist/api-playground-2/schemaGraph/processSchema.js +10 -0
  74. package/dist/api-playground-2/schemaGraph/processSecurityOptions.js +58 -28
  75. package/dist/api-playground-2/schemaGraph/reduceCompositions.js +220 -181
  76. package/dist/api-playground-2/schemaGraph/resolveOperationWithDependencies.js +128 -89
  77. package/dist/api-playground-2/schemaGraph/resolveSchemaWithDependencies.js +15 -16
  78. package/dist/api-playground-2/schemaGraph/sortSchemaByRequired.js +14 -12
  79. package/dist/api-playground-2/schemaGraph/utils.js +185 -147
  80. package/dist/common/guards.js +11 -19
  81. package/dist/components/Api/Expandable.js +10 -9
  82. package/dist/components/Api/Param.js +11 -13
  83. package/dist/components/Api/dropdown-menu.js +10 -9
  84. package/dist/components/content-components/code-group.js +4 -4
  85. package/dist/contexts/EndpointLocationContext.js +3 -3
  86. package/dist/hooks/useApiParamFieldOption.js +10 -0
  87. package/dist/hooks/useEndpoint.js +3 -3
  88. package/dist/hooks/useKeyboardShortcut.js +13 -13
  89. package/dist/hooks/useSendPlaygroundRequest.js +14 -146
  90. package/dist/httpsnippet/src/helpers/code-builder.js +27 -0
  91. package/dist/httpsnippet/src/helpers/escape.js +11 -0
  92. package/dist/httpsnippet/src/helpers/headers.js +13 -0
  93. package/dist/httpsnippet/src/helpers/reducer.js +7 -0
  94. package/dist/httpsnippet/src/helpers/shell.js +5 -0
  95. package/dist/httpsnippet/src/helpers/url-format.js +35 -0
  96. package/dist/httpsnippet/src/helpers/url-parse.js +76 -0
  97. package/dist/httpsnippet/src/index.js +157 -0
  98. package/dist/httpsnippet/src/targets/c/libcurl/client.js +22 -0
  99. package/dist/httpsnippet/src/targets/c/target.js +15 -0
  100. package/dist/httpsnippet/src/targets/clojure/clj_http/client.js +120 -0
  101. package/dist/httpsnippet/src/targets/clojure/target.js +14 -0
  102. package/dist/httpsnippet/src/targets/csharp/httpclient/client.js +76 -0
  103. package/dist/httpsnippet/src/targets/csharp/restsharp/client.js +63 -0
  104. package/dist/httpsnippet/src/targets/csharp/target.js +17 -0
  105. package/dist/httpsnippet/src/targets/go/native/client.js +24 -0
  106. package/dist/httpsnippet/src/targets/go/target.js +15 -0
  107. package/dist/httpsnippet/src/targets/http/http1.1/client.js +34 -0
  108. package/dist/httpsnippet/src/targets/http/target.js +14 -0
  109. package/dist/httpsnippet/src/targets/index.js +43 -0
  110. package/dist/httpsnippet/src/targets/java/asynchttp/client.js +23 -0
  111. package/dist/httpsnippet/src/targets/java/nethttp/client.js +28 -0
  112. package/dist/httpsnippet/src/targets/java/okhttp/client.js +23 -0
  113. package/dist/httpsnippet/src/targets/java/target.js +20 -0
  114. package/dist/httpsnippet/src/targets/java/unirest/client.js +23 -0
  115. package/dist/httpsnippet/src/targets/javascript/axios/client.js +50 -0
  116. package/dist/httpsnippet/src/targets/javascript/fetch/client.js +61 -0
  117. package/dist/httpsnippet/src/targets/javascript/jquery/client.js +51 -0
  118. package/dist/httpsnippet/src/targets/javascript/target.js +20 -0
  119. package/dist/httpsnippet/src/targets/javascript/xhr/client.js +49 -0
  120. package/dist/httpsnippet/src/targets/json/native/client.js +39 -0
  121. package/dist/httpsnippet/src/targets/json/target.js +14 -0
  122. package/dist/httpsnippet/src/targets/kotlin/okhttp/client.js +23 -0
  123. package/dist/httpsnippet/src/targets/kotlin/target.js +14 -0
  124. package/dist/httpsnippet/src/targets/node/axios/client.js +40 -0
  125. package/dist/httpsnippet/src/targets/node/fetch/client.js +68 -0
  126. package/dist/httpsnippet/src/targets/node/native/client.js +45 -0
  127. package/dist/httpsnippet/src/targets/node/target.js +19 -0
  128. package/dist/httpsnippet/src/targets/objc/helpers.js +27 -0
  129. package/dist/httpsnippet/src/targets/objc/nsurlsession/client.js +63 -0
  130. package/dist/httpsnippet/src/targets/objc/target.js +14 -0
  131. package/dist/httpsnippet/src/targets/ocaml/cohttp/client.js +32 -0
  132. package/dist/httpsnippet/src/targets/ocaml/target.js +14 -0
  133. package/dist/httpsnippet/src/targets/php/curl/client.js +85 -0
  134. package/dist/httpsnippet/src/targets/php/guzzle/client.js +57 -0
  135. package/dist/httpsnippet/src/targets/php/helpers.js +65 -0
  136. package/dist/httpsnippet/src/targets/php/http1/client.js +28 -0
  137. package/dist/httpsnippet/src/targets/php/http2/client.js +55 -0
  138. package/dist/httpsnippet/src/targets/php/target.js +21 -0
  139. package/dist/httpsnippet/src/targets/powershell/common.js +19 -0
  140. package/dist/httpsnippet/src/targets/powershell/restmethod/client.js +14 -0
  141. package/dist/httpsnippet/src/targets/powershell/target.js +16 -0
  142. package/dist/httpsnippet/src/targets/powershell/webrequest/client.js +14 -0
  143. package/dist/httpsnippet/src/targets/python/helpers.js +33 -0
  144. package/dist/httpsnippet/src/targets/python/requests/client.js +74 -0
  145. package/dist/httpsnippet/src/targets/python/target.js +15 -0
  146. package/dist/httpsnippet/src/targets/r/httr/client.js +46 -0
  147. package/dist/httpsnippet/src/targets/r/target.js +14 -0
  148. package/dist/httpsnippet/src/targets/ruby/native/client.js +37 -0
  149. package/dist/httpsnippet/src/targets/ruby/target.js +14 -0
  150. package/dist/httpsnippet/src/targets/shell/curl/client.js +92 -0
  151. package/dist/httpsnippet/src/targets/shell/httpie/client.js +56 -0
  152. package/dist/httpsnippet/src/targets/shell/target.js +19 -0
  153. package/dist/httpsnippet/src/targets/shell/wget/client.js +30 -0
  154. package/dist/httpsnippet/src/targets/swift/helpers.js +38 -0
  155. package/dist/httpsnippet/src/targets/swift/target.js +14 -0
  156. package/dist/httpsnippet/src/targets/swift/urlsession/client.js +59 -0
  157. package/dist/index.d.ts +65 -58
  158. package/dist/index.js +109 -111
  159. package/dist/openapi/generateTypeStringFromSchema.js +2 -31
  160. package/dist/styles.css +1 -1
  161. package/package.json +17 -4
  162. package/dist/api-playground/ApiPlayground/Request/BodySection.js +0 -64
  163. package/dist/api-playground/ApiPlayground/Request/ParameterSection.js +0 -32
  164. package/dist/api-playground/ApiPlayground/Request/PlaygroundModal.js +0 -201
  165. package/dist/api-playground/ApiPlayground/Request/SecuritySection.js +0 -146
  166. package/dist/api-playground/ApiPlayground/Request/ServerSection.js +0 -30
  167. package/dist/api-playground/ApiPlayground/Request/index.js +0 -43
  168. package/dist/api-playground/ApiPlayground/Request/inputs/ArrayInput.js +0 -93
  169. package/dist/api-playground/ApiPlayground/Request/inputs/DifferentiatedInput.js +0 -90
  170. package/dist/api-playground/ApiPlayground/Request/inputs/FileInput.js +0 -62
  171. package/dist/api-playground/ApiPlayground/Request/inputs/NullInput.js +0 -33
  172. package/dist/api-playground/ApiPlayground/Request/inputs/NumberInput.js +0 -61
  173. package/dist/api-playground/ApiPlayground/Request/inputs/ObjectChildren.js +0 -109
  174. package/dist/api-playground/ApiPlayground/Request/inputs/ObjectInput.js +0 -87
  175. package/dist/api-playground/ApiPlayground/Request/inputs/RecursiveInput.js +0 -61
  176. package/dist/api-playground/ApiPlayground/Request/inputs/SelectInput.js +0 -54
  177. package/dist/api-playground/ApiPlayground/Request/inputs/StringInput.js +0 -67
  178. package/dist/api-playground/ApiPlayground/Request/inputs/TextInput.js +0 -44
  179. package/dist/api-playground/ApiPlayground/components/EndpointsMenu.js +0 -42
  180. package/dist/api-playground/ApiPlayground/components/EndpointsMenuLink.js +0 -43
  181. package/dist/api-playground/ApiPlayground/components/EndpointsMenuSearch.js +0 -38
  182. package/dist/api-playground/ApiPlayground/components/InputContainer.js +0 -128
  183. package/dist/api-playground/ApiPlayground/components/InputSectionContainer.js +0 -59
  184. package/dist/api-playground/ApiPlayground/components/PathHeader.js +0 -162
  185. package/dist/api-playground/ApiPlayground/components/TrashButton.js +0 -26
  186. package/dist/api-playground/ApiPlayground/index.js +0 -67
  187. package/dist/api-playground/EndpointFields/ParamFields/PrimitiveParamField/Enum.js +0 -19
  188. package/dist/api-playground/EndpointFields/ParamFields/PrimitiveParamField/NumberMetadata.js +0 -18
  189. package/dist/api-playground/EndpointFields/ParamFields/PrimitiveParamField/StringMetadata.js +0 -28
  190. package/dist/api-playground/EndpointFields/ParamFields/PrimitiveParamField/index.js +0 -5
  191. package/dist/api-playground/EndpointFields/ParamFields/RecursiveParamField.js +0 -13
  192. package/dist/api-playground/EndpointFields/index.js +0 -7
  193. package/dist/api-playground-2/components/EndpointFields/EndpointSecurity.js +0 -87
  194. package/dist/api-playground-2/components/EndpointFields/fields/SimpleArrayParamField.js +0 -89
  195. package/dist/api-playground-2/components/EndpointFields/fields/SimpleObjectParamField.js +0 -121
  196. package/dist/api-playground-2/components/EndpointFields/fields/SimplePrimitiveParamField.js +0 -74
  197. package/dist/api-playground-2/components/EndpointFields/fields/SimpleSchemaField.js +0 -252
  198. package/dist/common/potentiallyParseOpenApiString.js +0 -24
  199. package/dist/common/replaceSlashIndex.js +0 -6
  200. package/dist/common/slugToTitle.js +0 -10
  201. package/dist/constants/prism-languages.js +0 -19
  202. package/dist/contexts/ApiPlaygroundInputsContext.js +0 -17
  203. package/dist/contexts/MDXContentContext.js +0 -17
  204. package/dist/hooks/useApiPlaygroundInputs.js +0 -6
  205. package/dist/hooks/useApiPlaygroundPrefillExamples.js +0 -39
  206. package/dist/hooks/useBaseUrlOptions.js +0 -18
  207. package/dist/hooks/useComponentSchemas.js +0 -9
  208. package/dist/hooks/useGenerateNextAdditionalProperties.js +0 -11
  209. package/dist/hooks/useGenerateNextItems.js +0 -11
  210. package/dist/hooks/useGenerateNextProperties.js +0 -11
  211. package/dist/hooks/useMDXContent.js +0 -6
  212. package/dist/hooks/useMDXContentController/useApiPlaygroundInputs.js +0 -9
  213. package/dist/hooks/useMDXContentController/useMDXContentCallbacks/useSetApiBaseIndexCallback.js +0 -15
  214. package/dist/hooks/useMDXContentController/useMDXContentCallbacks/useSetApiPlaygroundInputsCallback.js +0 -15
  215. package/dist/hooks/usePlaygroundSchemaOptions.js +0 -42
  216. package/dist/hooks/usePrefilledInputs/index.js +0 -65
  217. package/dist/hooks/usePrefilledInputs/storedServerVariables.js +0 -29
  218. package/dist/hooks/useSecurityOption.js +0 -10
  219. package/dist/hooks/useSetDefaultValue.js +0 -63
  220. package/dist/openapi/filterEnums.js +0 -20
  221. package/dist/openapi/generateNextAdditionalProperties.js +0 -7
  222. package/dist/openapi/generateNextItems.js +0 -7
  223. package/dist/openapi/generateNextProperties.js +0 -23
  224. package/dist/openapi/generateOptionLabels.js +0 -20
  225. package/dist/openapi/generateSimpleLabels.js +0 -4
  226. package/dist/openapi/getAuthFilteredSchemaArray.js +0 -18
  227. package/dist/paths/isEqualIgnoringLeadingSlash.js +0 -21
  228. package/dist/paths/optionallyRemoveLeadingSlash.js +0 -6
  229. package/dist/paths/optionallyRemoveTrailingSlash.js +0 -6
  230. package/dist/utils/api-playground/defaults.js +0 -15
  231. package/dist/utils/api-playground/paramFieldDefaults.js +0 -10
  232. package/dist/utils/api-reference/getFilteredSecurityOptions.js +0 -4
  233. package/dist/utils/api-reference/getNextPropertiesByType.js +0 -5
  234. package/dist/utils/flattenObject.js +0 -10
@@ -1,42 +0,0 @@
1
- import { jsxs as l, jsx as i } from "react/jsx-runtime";
2
- import { potentiallyParseOpenApiString as M } from "../../../common/potentiallyParseOpenApiString.js";
3
- import { slugToTitle as f } from "../../../common/slugToTitle.js";
4
- import { ChevronDownFilled as k } from "@fluentui/react-icons";
5
- import { useState as P, useMemo as h } from "react";
6
- import { MethodPill as A } from "../../../components/Api/MethodPill.js";
7
- import { DropdownMenu as y, DropdownMenuTrigger as D, DropdownMenuContent as N } from "../../../components/Api/dropdown-menu.js";
8
- import { useMDXContent as S } from "../../../hooks/useMDXContent.js";
9
- import { EndpointsMenuLink as C } from "./EndpointsMenuLink.js";
10
- import { EndpointsMenuSearch as T } from "./EndpointsMenuSearch.js";
11
- const g = (r) => r.reduce((t, e) => "pages" in e ? [...t, ...g(e.pages)] : "openapi" in e || "api" in e || "asyncapi" in e ? [...t, e] : t, []), E = (r) => r.map((t) => {
12
- {
13
- const e = t.openapi || t.api;
14
- if (e == null)
15
- return;
16
- const n = M(e);
17
- return n == null ? void 0 : {
18
- method: n.method,
19
- title: t.title || f(t.href),
20
- href: t.href,
21
- type: "openapi",
22
- playground: t.playground
23
- };
24
- }
25
- }).filter((t) => t != null), G = ({ endpoint: r, channel: t, operation: e, pathname: n }) => {
26
- var u;
27
- const [{ pageMetadata: a }] = S(), s = a.title || f(n), [m, x] = P(""), p = g(((u = a.navigation) == null ? void 0 : u.groupsOrPages) ?? []), d = h(() => E(p), [p]), v = e ? e.title || s : r ? r.title || s : (t == null ? void 0 : t.title) || s, c = e ? e.method : r ? r.method : "websocket", w = c === "websocket", b = h(() => m ? d.filter((o) => o.title.toLowerCase().includes(m.toLowerCase())) : d, [m, d]);
28
- return /* @__PURE__ */ l(y, { children: [
29
- /* @__PURE__ */ i(D, { className: "mint:hidden mint:lg:block", children: /* @__PURE__ */ l("div", { className: "mint:flex mint:items-center mint:gap-x-2 mint:border-standard mint:rounded-xl mint:p-1.5 mint:pr-3 mint:min-w-80 mint:hover:bg-gray-50 mint:dark:hover:bg-white/5", children: [
30
- /* @__PURE__ */ i(A, { method: c, shortMethod: w, isActive: !0 }),
31
- /* @__PURE__ */ i("div", { className: "mint:flex-1 mint:text-left mint:text-sm mint:font-medium mint:text-gray-900 mint:dark:text-white mint:truncate", children: v }),
32
- /* @__PURE__ */ i("div", { children: /* @__PURE__ */ i(k, { className: "mint:w-4 mint:h-4 mint:text-gray-500 mint:dark:text-gray-400" }) })
33
- ] }) }),
34
- /* @__PURE__ */ i(N, { className: "mint:hidden mint:lg:block mint:w-80 mint:border mint:border-gray-100 mint:dark:border-white/10 mint:rounded-xl mint:px-2 mint:pb-2 mint:pt-0", children: /* @__PURE__ */ l("div", { className: "mint:flex mint:flex-col", children: [
35
- /* @__PURE__ */ i(T, { search: m, setSearch: x }),
36
- b.map((o) => /* @__PURE__ */ i("div", { children: /* @__PURE__ */ i(C, { page: o, pathname: n }) }, `search-${o.title}-${o.href}`))
37
- ] }) })
38
- ] });
39
- };
40
- export {
41
- G as EndpointsMenu
42
- };
@@ -1,43 +0,0 @@
1
- import { jsx as n, jsxs as l } from "react/jsx-runtime";
2
- import { MethodPill as a } from "../../../components/Api/MethodPill.js";
3
- import { isEqualIgnoringLeadingSlash as c } from "../../../paths/isEqualIgnoringLeadingSlash.js";
4
- import { cn as u } from "../../../utils/cn.js";
5
- const w = ({ page: t, pathname: o }) => {
6
- const i = c(t.href, o), m = t.type === "openapi", d = t.playground === "none" || t.playground === "simple" || t.method === "webhook", s = (h) => {
7
- h.preventDefault();
8
- const e = d ? t.href : `${t.href}?playground=open`;
9
- if (typeof window < "u" && window.next) {
10
- const r = window.next.router;
11
- if (r) {
12
- r.push(e);
13
- return;
14
- }
15
- }
16
- window.location.href = e;
17
- };
18
- return /* @__PURE__ */ n("a", { href: t.href, title: t.title, children: /* @__PURE__ */ l(
19
- "div",
20
- {
21
- onClick: s,
22
- className: u(
23
- "mint:flex mint:items-center mint:gap-x-2 mint:hover:bg-gray-50 mint:dark:hover:bg-white/5 mint:rounded-xl mint:p-1.5 mint:group mint:cursor-pointer",
24
- i ? "mint:bg-gray-50 mint:dark:bg-white/5 mint:text-[#643FB2] mint:dark:text-[#C9AAF9] mint:font-medium" : "mint:text-gray-700 mint:hover:text-gray-900 mint:dark:text-gray-400 mint:dark:hover:text-gray-300"
25
- ),
26
- children: [
27
- /* @__PURE__ */ n(
28
- a,
29
- {
30
- method: t.method,
31
- shortMethod: m,
32
- className: "mint:font-medium mint:px-1 mint:py-px mint:text-xs mint:rounded-md",
33
- isActive: i
34
- }
35
- ),
36
- /* @__PURE__ */ n("div", { className: "mint:text-sm mint:truncate", children: t.title })
37
- ]
38
- }
39
- ) });
40
- };
41
- export {
42
- w as EndpointsMenuLink
43
- };
@@ -1,38 +0,0 @@
1
- import { jsx as n, jsxs as r } from "react/jsx-runtime";
2
- import a from "lodash/debounce";
3
- import { SearchIcon as o } from "lucide-react";
4
- import { cn as d } from "../../../utils/cn.js";
5
- const g = ({
6
- search: e,
7
- setSearch: i
8
- }) => {
9
- const m = a(async (t) => {
10
- i(t);
11
- }, 20);
12
- return /* @__PURE__ */ n(
13
- "div",
14
- {
15
- className: d(
16
- "mint:h-[52px] mint:sticky mint:z-[2] mint:-mb-1 mint:-mx-2 mint:pb-0 mint:p-2 mint:left-0 mint:top-0"
17
- ),
18
- children: /* @__PURE__ */ r("div", { className: "mint:p-1.5 mint:border mint:border-gray-200/70 mint:dark:border-white/10 mint:rounded-[0.6rem] mint:bg-white mint:dark:bg-gray-950 mint:border-solid mint:flex mint:items-center mint:gap-x-2 mint:mb-2", children: [
19
- /* @__PURE__ */ n(o, { size: 16, className: "mint:min-w-4 mint:flex-none mint:text-gray-400 mint:dark:text-gray-600" }),
20
- /* @__PURE__ */ n(
21
- "input",
22
- {
23
- type: "text",
24
- value: e,
25
- onChange: (t) => m(t.target.value),
26
- autoFocus: !0,
27
- placeholder: "Search for endpoint...",
28
- "aria-label": "Search for an endpoint",
29
- className: "mint:w-full mint:text-sm mint:text-gray-900 mint:dark:text-gray-100 mint:placeholder-gray-400 mint:dark:placeholder-gray-600 mint:font-light mint:focus:outline-0 mint:dark:bg-gray-950"
30
- }
31
- )
32
- ] })
33
- }
34
- );
35
- };
36
- export {
37
- g as EndpointsMenuSearch
38
- };
@@ -1,128 +0,0 @@
1
- import { jsxs as m, jsx as i, Fragment as s } from "react/jsx-runtime";
2
- import { useState as C } from "react";
3
- import { isEnum as $ } from "../../EndpointFields/ParamFields/PrimitiveParamField/index.js";
4
- import { Description as g } from "../../EndpointFields/components/Description.js";
5
- import { InfoPill as j, RequiredPill as B, DeprecatedPill as P } from "../../../components/Api/Param.js";
6
- import T from "../../../components/Api/ErrorBoundary.js";
7
- import { containsMarkdownTable as q } from "../../../utils/containsMarkdownTable.js";
8
- import { cn as e } from "../../../utils/cn.js";
9
- import { ArrayCount as E } from "./ArrayCount.js";
10
- import { ObjectExpandButton as S } from "./ObjectExpandButton.js";
11
- import { TrashButton as D } from "./TrashButton.js";
12
- const U = ({
13
- name: d,
14
- children: y,
15
- schema: t,
16
- onClear: a,
17
- isObject: r,
18
- isArray: c,
19
- parentNames: n,
20
- arrayIndex: o,
21
- typeDropdown: p,
22
- defaultExpanded: f = !0,
23
- style: u,
24
- explode: v
25
- }) => {
26
- const [l, k] = C(f), b = t.type === "object" ? Object.keys(t.properties).length : 0, h = "format" in t && typeof t.format == "string" ? `${t.type}<${t.format}>` : t.type, x = $(t) && t.description && q(t.description);
27
- return /* @__PURE__ */ m(T, { children: [
28
- /* @__PURE__ */ m(
29
- "div",
30
- {
31
- className: e(
32
- "mint:flex mint:space-x-3 mint:items-start",
33
- o != null && !r && "mint:flex mint:items-center"
34
- ),
35
- children: [
36
- o != null && /* @__PURE__ */ i(E, { className: e(r && "mint:mt-8"), children: o + 1 }),
37
- /* @__PURE__ */ m(
38
- "div",
39
- {
40
- className: e(
41
- "mint:flex-1 mint:grid mint:lg:grid-cols-2 mint:gap-x-12 mint:gap-y-4 mint:py-5 mint:max-w-full",
42
- c && "mint:flex mint:flex-col",
43
- r && "mint:gap-y-0 mint:flex mint:flex-col mint:border mint:border-gray-50 mint:dark:border-white/5 mint:rounded-xl mint:px-4 mint:py-0 mint:my-5",
44
- o !== void 0 && "mint:py-1 mint:my-2"
45
- ),
46
- children: [
47
- /* @__PURE__ */ m(
48
- "div",
49
- {
50
- className: e(
51
- "mint:space-y-2",
52
- r && "mint:pt-8 mint:py-5 mint:border-b mint:border-gray-50 mint:dark:border-white/5",
53
- !l && "mint:border-none",
54
- o != null && !r && "mint:flex mint:items-center"
55
- ),
56
- children: [
57
- /* @__PURE__ */ m("div", { className: "mint:flex mint:items-center mint:justify-between mint:font-mono mint:font-bold", children: [
58
- /* @__PURE__ */ m(
59
- "div",
60
- {
61
- className: "mint:flex mint:flex-wrap mint:items-center mint:gap-2 mint:text-xs mint:truncate",
62
- title: n ? `${n.join(".")}.${d}` : d,
63
- children: [
64
- /* @__PURE__ */ i("div", { className: e("mint:text-sm mint:truncate", d == null && "mint:hidden"), children: n && n.length > 0 && u === "deepObject" && v ? /* @__PURE__ */ m(s, { children: [
65
- /* @__PURE__ */ i("span", { className: "mint:text-gray-500 mint:dark:text-gray-400", children: n.map((w, N) => /* @__PURE__ */ m(s, { children: [
66
- w,
67
- N === 0 ? "[" : "]["
68
- ] })) }),
69
- /* @__PURE__ */ i("span", { className: "mint:font-semibold mint:text-gray-900 mint:dark:text-gray-100", children: d }),
70
- /* @__PURE__ */ i("span", { className: "mint:text-gray-500 mint:dark:text-gray-400", children: "]" })
71
- ] }) : /* @__PURE__ */ m(s, { children: [
72
- /* @__PURE__ */ i("span", { className: "mint:text-gray-500 mint:dark:text-gray-400", children: n ? `${n.join(".")}.` : "" }),
73
- /* @__PURE__ */ i("span", { className: "mint:font-semibold mint:text-gray-900 mint:dark:text-gray-100", children: d })
74
- ] }) }),
75
- p ?? /* @__PURE__ */ i(j, { children: h }),
76
- t.required && /* @__PURE__ */ i(B, {}),
77
- t.deprecated && /* @__PURE__ */ i(P, {})
78
- ]
79
- }
80
- ),
81
- r && /* @__PURE__ */ i(
82
- S,
83
- {
84
- onClick: () => k(!l),
85
- count: b,
86
- labeled: f == !1
87
- }
88
- )
89
- ] }),
90
- t.description && !x && /* @__PURE__ */ i(
91
- g,
92
- {
93
- markdown: t.description,
94
- className: "mint:text-gray-500 mint:dark:text-gray-400"
95
- }
96
- )
97
- ]
98
- }
99
- ),
100
- l && /* @__PURE__ */ i(
101
- "div",
102
- {
103
- className: e(
104
- "mint:grid mint:grid-cols-1 mint:w-full mint:items-start mint:divide-y mint:divide-gray-50 mint:dark:divide-white/5",
105
- c && "mint:divide-y-0"
106
- ),
107
- children: y
108
- }
109
- )
110
- ]
111
- }
112
- ),
113
- (o != null || n) && a && /* @__PURE__ */ i(
114
- D,
115
- {
116
- className: e(r && "mint:mt-8", n && "mint:mt-7"),
117
- onClick: () => a()
118
- }
119
- )
120
- ]
121
- }
122
- ),
123
- t.description && x && /* @__PURE__ */ i(g, { markdown: t.description, className: "mint:text-gray-500 mint:dark:text-gray-400" })
124
- ] });
125
- };
126
- export {
127
- U as InputContainer
128
- };
@@ -1,59 +0,0 @@
1
- import { jsxs as i, jsx as t } from "react/jsx-runtime";
2
- import { useState as s } from "react";
3
- import { ChevronRightFilled as c, CheckmarkCircleRegular as g, ErrorCircleRegular as x } from "@fluentui/react-icons";
4
- import { cn as e } from "../../../utils/cn.js";
5
- const k = ({
6
- name: d,
7
- validationState: m,
8
- children: r,
9
- rightElement: a
10
- }) => {
11
- const [n, o] = s(!0);
12
- return /* @__PURE__ */ i("div", { children: [
13
- /* @__PURE__ */ i(
14
- "button",
15
- {
16
- "aria-label": "Expand Input Section",
17
- onClick: () => o((l) => !l),
18
- className: e(
19
- "mint:flex mint:w-full mint:px-4 mint:py-2.5 mint:items-center mint:justify-between mint:border-standard mint:cursor-pointer mint:hover:bg-gray-50 mint:dark:hover:bg-white/5",
20
- n ? "mint:border-b-0! mint:border-t mint:border-x mint:rounded-t-2xl" : "mint:rounded-2xl"
21
- ),
22
- children: [
23
- /* @__PURE__ */ i("div", { className: "mint:flex mint:items-center mint:gap-x-1.5", children: [
24
- /* @__PURE__ */ t(
25
- c,
26
- {
27
- className: e(
28
- "mint:h-3 mint:w-3 mint:bg-gray-400 mint:dark:bg-gray-500 mint:transition-transform",
29
- n && "mint:rotate-180"
30
- )
31
- }
32
- ),
33
- /* @__PURE__ */ i("div", { className: "mint:flex-1 mint:flex mint:items-center mint:space-x-2", children: [
34
- /* @__PURE__ */ t("div", { className: "mint:text-sm mint:font-medium mint:text-gray-800 mint:dark:text-gray-200 mint:leading-6", children: d }),
35
- m ? m === "invalid" ? /* @__PURE__ */ t(b, {}) : /* @__PURE__ */ t(u, {}) : null
36
- ] })
37
- ] }),
38
- a
39
- ]
40
- }
41
- ),
42
- /* @__PURE__ */ i(
43
- "div",
44
- {
45
- className: e(
46
- "mint:bg-background-light mint:dark:bg-background-dark mint:flex-1 mint:px-4 mint:rounded-b-xl mint:border-standard mint:border-t-0! mint:divide-y mint:divide-gray-100 mint:dark:divide-white/10",
47
- n && r ? "" : "mint:hidden"
48
- ),
49
- children: [
50
- /* @__PURE__ */ t("div", {}),
51
- r
52
- ]
53
- }
54
- )
55
- ] });
56
- }, b = () => /* @__PURE__ */ t(g, { className: "mint:h-4 mint:w-4 mint:bg-[#2AB673]" }), u = () => /* @__PURE__ */ t(x, { className: "mint:h-4 mint:w-4 mint:bg-[#CB3A32]" });
57
- export {
58
- k as InputSectionContainer
59
- };
@@ -1,162 +0,0 @@
1
- import { jsxs as c, jsx as n, Fragment as y } from "react/jsx-runtime";
2
- import { SpinnerIosRegular as N, PlayRegular as P, ChevronUpDownFilled as w, CheckmarkCircleRegular as k, CopySelectRegular as C } from "@fluentui/react-icons";
3
- import { useState as g, useContext as f, useEffect as S, useMemo as B } from "react";
4
- import { getMethodColor as x } from "../../../components/Api/colors.js";
5
- import { MethodPill as I } from "../../../components/Api/MethodPill.js";
6
- import { useApiPlaygroundInputs as $ } from "../../../hooks/useMDXContentController/useApiPlaygroundInputs.js";
7
- import { addPathParams as W, joinWithSingleSlash as E, addServerVariables as M } from "../../../hooks/useSendPlaygroundRequest.js";
8
- import { copyToClipboard as R } from "../../../utils/copyToClipboard.js";
9
- import { ApiPlaygroundContext as v } from "../ApiPlaygroundContext.js";
10
- import { cn as h } from "../../../utils/cn.js";
11
- const _ = ({
12
- endpoint: t,
13
- display: m,
14
- onClickInteractive: r,
15
- hasGrayBackground: s
16
- }) => /* @__PURE__ */ c("div", { className: "mint:flex mint:items-center mint:space-x-1.5", children: [
17
- /* @__PURE__ */ n(j, { endpoint: t, display: m, hasGrayBackground: s }),
18
- m === "simple" ? null : /* @__PURE__ */ n(A, { method: t.method, label: "Try it", onClick: r })
19
- ] }), U = () => {
20
- const { baseUrlOptions: t, selectedBaseUrlIndex: m, setSelectedBaseUrlIndex: r } = f(v), [s, o] = g(0), i = t == null ? void 0 : t[m];
21
- return S(() => {
22
- const e = document.createElement("span");
23
- e.className = "mint:text-sm mint:absolute mint:font-mono mint:invisible";
24
- const a = sessionStorage.getItem("selectedBaseUrl");
25
- a && a !== i && t && r && t.includes(a) ? (r(t.indexOf(a)), e.textContent = a) : e.textContent = i ?? "", document.body.appendChild(e), o(e.offsetWidth + 16), document.body.removeChild(e);
26
- }, [i, r, m, t]), !t || t.length <= 1 || !r ? null : /* @__PURE__ */ c("div", { className: "mint:flex mint:items-center mint:gap-1 mint:relative mint:-mr-1", children: [
27
- /* @__PURE__ */ n(
28
- "select",
29
- {
30
- "aria-label": "Base Path Selector",
31
- className: "mint:bg-transparent mint:text-sm mint:text-gray-600 mint:dark:text-gray-400 mint:outline-0 mint:font-mono mint:cursor-pointer mint:hover:text-gray-900 mint:dark:hover:text-gray-300",
32
- value: m,
33
- onClick: (e) => e.stopPropagation(),
34
- onChange: (e) => {
35
- sessionStorage.setItem("selectedBaseUrl", t[Number(e.target.value)] ?? ""), r(Number(e.target.value));
36
- },
37
- style: { width: `${s}px` },
38
- children: t.map((e, a) => /* @__PURE__ */ n("option", { value: a, children: e }, e))
39
- }
40
- ),
41
- /* @__PURE__ */ n(
42
- w,
43
- {
44
- className: "mint:absolute mint:right-0 mint:w-3 mint:h-3 mint:text-gray-400 mint:dark:text-white/30 mint:pointer-events-none"
45
- }
46
- )
47
- ] });
48
- }, j = ({ endpoint: t, display: m, hasGrayBackground: r }) => {
49
- const [s, o] = g(!1), { baseUrlOptions: i, selectedBaseUrlIndex: e } = f(v), a = $(), l = (i == null ? void 0 : i[e]) ?? (i == null ? void 0 : i[0]) ?? "", p = async () => {
50
- const d = W(t.path, a.path), b = E(M(l, a.server), d);
51
- await R(b) === "success" && (o(!0), setTimeout(() => {
52
- o(!1);
53
- }, 2e3));
54
- };
55
- return /* @__PURE__ */ c(
56
- "div",
57
- {
58
- className: h(
59
- "mint:relative mint:flex-1 mint:flex mint:gap-2 mint:min-w-0 mint:rounded-xl mint:items-center mint:cursor-pointer mint:p-1.5 mint:pr-0 mint:overflow-hidden",
60
- m != "simple" && "mint:border-standard",
61
- r && "mint:bg-gray-50 mint:dark:bg-white/5"
62
- ),
63
- onClick: p,
64
- children: [
65
- /* @__PURE__ */ n(
66
- I,
67
- {
68
- method: t.type === "webhook" ? "webhook" : t.method,
69
- isActive: !1
70
- }
71
- ),
72
- /* @__PURE__ */ c("div", { className: "mint:flex mint:items-center mint:space-x-2 mint:overflow-x-auto mint:flex-1 mint:no-scrollbar", children: [
73
- t.type !== "webhook" && /* @__PURE__ */ n(U, {}),
74
- /* @__PURE__ */ n(
75
- F,
76
- {
77
- endpoint: t,
78
- display: m,
79
- isCopiedActive: s,
80
- hasGrayBackground: r
81
- }
82
- )
83
- ] })
84
- ]
85
- }
86
- );
87
- }, F = ({
88
- endpoint: t,
89
- isCopiedActive: m,
90
- hasGrayBackground: r
91
- }) => {
92
- const s = B(() => t.path.split("/").flatMap((o, i) => {
93
- const e = [];
94
- return i > 0 && e.push(/* @__PURE__ */ n(T, {}, i)), o.split("{").forEach((a, l) => {
95
- if (a.includes("}")) {
96
- const [p, d] = a.split("}");
97
- e.push(
98
- /* @__PURE__ */ n(H, { method: t.method, children: p }, `${i}-${l}-param`)
99
- ), d && e.push(/* @__PURE__ */ n(u, { children: d }, `${i}-${l}`));
100
- } else a && e.push(/* @__PURE__ */ n(u, { children: a }, `${i}-${l}`));
101
- }), e;
102
- }), [t.path, t.method]);
103
- return /* @__PURE__ */ c("div", { className: "mint:group mint:flex mint:items-center mint:flex-1 mint:gap-0.5 mint:font-mono mint:pr-1.5", children: [
104
- /* @__PURE__ */ n(
105
- "div",
106
- {
107
- className: h(
108
- "mint:absolute mint:right-0 mint:p-2 mint:bg-background-light mint:dark:bg-background-dark mint:rounded-lg",
109
- r && "mint:bg-transparent mint:dark:bg-transparent",
110
- m ? "mint:block" : "mint:hidden mint:group-hover:block"
111
- ),
112
- children: m ? /* @__PURE__ */ n(
113
- k,
114
- {
115
- className: "mint:w-4 mint:h-4 mint:bg-primary mint:dark:bg-primary-light"
116
- }
117
- ) : /* @__PURE__ */ n(C, { className: "mint:w-4 mint:h-4 mint:bg-gray-400 mint:dark:bg-white/30" })
118
- }
119
- ),
120
- s
121
- ] });
122
- }, u = ({ children: t }) => /* @__PURE__ */ n("div", { className: "mint:text-sm mint:font-medium mint:text-gray-800 mint:dark:text-white mint:min-w-max", children: t }), H = ({ children: t, method: m }) => {
123
- const { activeNavPillBg: r, activeNavPillText: s, inactiveNavPillText: o, inactiveNavPillBg: i } = x(m);
124
- return /* @__PURE__ */ n(
125
- "div",
126
- {
127
- className: h("mint:text-sm mint:font-mono mint:font-medium mint:rounded-md mint:px-1 mint:border-2 mint:min-w-max", r, s, o, i),
128
- children: `{${t}}`
129
- }
130
- );
131
- }, T = () => /* @__PURE__ */ n("div", { className: "mint:text-sm mint:text-gray-400", children: "/" }), A = ({
132
- label: t,
133
- method: m,
134
- onClick: r,
135
- isSending: s,
136
- className: o
137
- }) => {
138
- const { activeNavPillBg: i } = x(m);
139
- return /* @__PURE__ */ n(
140
- "button",
141
- {
142
- className: h(
143
- "try-it-button",
144
- "mint:flex mint:items-center mint:justify-center mint:px-3 mint:h-9 mint:text-white mint:font-medium mint:rounded-xl mint:mouse-pointer mint:disabled:opacity-70 mint:hover:opacity-80 mint:gap-1.5",
145
- i,
146
- o
147
- ),
148
- onClick: r,
149
- disabled: s,
150
- "data-testid": "try-it-button",
151
- children: s ? /* @__PURE__ */ n(N, { className: "mint:w-4 mint:h-4 mint:bg-white mint:animate-spin" }) : /* @__PURE__ */ c(y, { children: [
152
- /* @__PURE__ */ n("span", { children: t }),
153
- /* @__PURE__ */ n(P, { className: "mint:w-3 mint:h-3 mint:bg-white" })
154
- ] })
155
- }
156
- );
157
- };
158
- export {
159
- _ as EndpointHeader,
160
- j as PathHeader,
161
- A as SendPill
162
- };
@@ -1,26 +0,0 @@
1
- import { jsx as t } from "react/jsx-runtime";
2
- import { useSelectedLocale as m } from "../../../utils/locales/index.js";
3
- import { TrashIcon as o } from "lucide-react";
4
- import "@mintlify/validation";
5
- import { cn as i } from "../../../utils/cn.js";
6
- const x = ({
7
- className: r,
8
- onClick: e
9
- }) => {
10
- const a = m();
11
- return /* @__PURE__ */ t(
12
- "button",
13
- {
14
- className: i(
15
- "mint:px-1 mint:text-gray-400 mint:dark:text-gray-600 mint:hover:text-gray-600 mint:dark:hover:text-gray-400",
16
- r
17
- ),
18
- onClick: e,
19
- "aria-label": a["aria.deleteItem"],
20
- children: /* @__PURE__ */ t(o, { className: "mint:w-4 mint:h-4" })
21
- }
22
- );
23
- };
24
- export {
25
- x as TrashButton
26
- };
@@ -1,67 +0,0 @@
1
- import { jsx as n } from "react/jsx-runtime";
2
- import { useContext as U, useState as o, useEffect as b } from "react";
3
- import { DocsConfigContext as L } from "../../contexts/ConfigContext.js";
4
- import { EndpointLocationProvider as T } from "../../contexts/EndpointLocationContext.js";
5
- import { useBaseUrlOptions as j } from "../../hooks/useBaseUrlOptions.js";
6
- import { useKeyboardShortcut as y } from "../../hooks/useKeyboardShortcut.js";
7
- import { useApiPlaygroundInputs as F } from "../../hooks/useMDXContentController/useApiPlaygroundInputs.js";
8
- import { useSetApiBaseIndexCallback as K } from "../../hooks/useMDXContentController/useMDXContentCallbacks/useSetApiBaseIndexCallback.js";
9
- import { useSetApiPlaygroundInputsCallback as D } from "../../hooks/useMDXContentController/useMDXContentCallbacks/useSetApiPlaygroundInputsCallback.js";
10
- import { useSendPlaygroundRequest as N } from "../../hooks/useSendPlaygroundRequest.js";
11
- import Q from "../../components/Api/ErrorBoundary.js";
12
- import { ApiPlaygroundContext as W } from "./ApiPlaygroundContext.js";
13
- import { Request as _ } from "./Request/index.js";
14
- const se = ({ endpoint: r, display: f, pathname: x }) => {
15
- var p, m;
16
- const { docsConfig: a } = U(L), h = F(), I = D(), g = K(), e = j(), [c, P] = o(0), [l, i] = o(!1), [S, w] = o(!1), [E, B] = o(), [k, z] = o(0), v = Object.keys(r.request.body)[k], [A, C] = o(0), R = (e == null ? void 0 : e[c]) ?? (e == null ? void 0 : e[0]) ?? "";
17
- b(() => {
18
- new URLSearchParams(window.location.search).has("playground") && requestAnimationFrame(() => {
19
- i(!0);
20
- });
21
- }, []);
22
- const d = N({
23
- endpoint: r,
24
- baseUrl: R,
25
- contentType: v ?? "application/json",
26
- setIsFetching: w,
27
- setResult: B
28
- }), q = (t) => {
29
- P(t), g(t);
30
- }, u = (t) => {
31
- if (i(t), t) {
32
- const s = new URL(window.location.href);
33
- s.searchParams.set("playground", "open"), window.history.replaceState({}, "", s);
34
- } else {
35
- const s = new URL(window.location.href);
36
- s.searchParams.delete("playground"), window.history.replaceState({}, "", s);
37
- }
38
- };
39
- return y({
40
- key: "Enter",
41
- callback: ((m = (p = a == null ? void 0 : a.api) == null ? void 0 : p.playground) == null ? void 0 : m.display) === "interactive" ? d : void 0
42
- }), y({
43
- key: "Escape",
44
- callback: l ? () => u(!1) : void 0,
45
- isSingleKey: !0
46
- }), /* @__PURE__ */ n(Q, { children: /* @__PURE__ */ n(
47
- W.Provider,
48
- {
49
- value: {
50
- isSending: S,
51
- sendRequest: d,
52
- result: E,
53
- setSelectedBaseUrlIndex: q,
54
- selectedBaseUrlIndex: c,
55
- baseUrlOptions: e,
56
- isPlaygroundExpanded: l,
57
- setIsPlaygroundExpanded: u,
58
- selectedExampleIndex: A,
59
- setSelectedExampleIndex: C
60
- },
61
- children: /* @__PURE__ */ n("div", { className: "mint:flex mint:w-full mint:flex-col mint:space-y-4", children: /* @__PURE__ */ n(T, { location: "request", children: /* @__PURE__ */ n(_, { inputs: h, setInputs: I, endpoint: r, display: f, pathname: x }) }) })
62
- }
63
- ) });
64
- };
65
- export {
66
- se as ApiPlayground
67
- };
@@ -1,19 +0,0 @@
1
- import { jsxs as i, jsx as l } from "react/jsx-runtime";
2
- import { useSelectedLocale as o } from "../../../../utils/locales/index.js";
3
- import { getXFilteredEnumValues as m } from "../../../../openapi/filterEnums.js";
4
- const d = ({ schema: r }) => {
5
- const e = m({ schema: r, userGroups: void 0 }), s = o();
6
- return e.length === 0 ? null : /* @__PURE__ */ i("div", { className: "mint:whitespace-pre-wrap mint:prose-sm mint:mt-6", children: [
7
- s.availableOptions,
8
- ":",
9
- " ",
10
- e.map((t, n) => /* @__PURE__ */ i("div", { className: "mint:inline-block", children: [
11
- /* @__PURE__ */ l("code", { children: t }),
12
- n !== e.length - 1 && ",",
13
- " "
14
- ] }, `${t}-${n}`))
15
- ] });
16
- };
17
- export {
18
- d as EnumOptions
19
- };
@@ -1,18 +0,0 @@
1
- import { jsxs as u, Fragment as r, jsx as l } from "react/jsx-runtime";
2
- const o = ({ schema: i }) => {
3
- const e = i.exclusiveMinimum || i.exclusiveMinimum !== void 0, n = i.exclusiveMaximum || i.exclusiveMaximum !== void 0;
4
- let m = "";
5
- return i.maximum !== void 0 && (m = `x ${n ? "<" : "<="} ${i.maximum}`), i.minimum !== void 0 && (m = `x ${e ? ">" : ">="} ${i.minimum}`), i.maximum !== void 0 && i.minimum !== void 0 && (m = `${i.minimum} ${e ? "<" : "<="} x ${n ? "<" : "<="} ${i.maximum}`), m === "" && i.multipleOf === void 0 ? null : /* @__PURE__ */ u("div", { className: "mint:prose mint:prose-sm mint:prose-gray mint:dark:prose-invert mint:mt-6", children: [
6
- m && /* @__PURE__ */ u(r, { children: [
7
- "Required range: ",
8
- /* @__PURE__ */ l("code", { children: m })
9
- ] }),
10
- i.multipleOf && /* @__PURE__ */ u(r, { children: [
11
- "Must be a multiple of ",
12
- /* @__PURE__ */ l("code", { children: i.multipleOf })
13
- ] })
14
- ] });
15
- };
16
- export {
17
- o as NumberMetadata
18
- };
@@ -1,28 +0,0 @@
1
- import { jsxs as n, Fragment as t, jsx as e } from "react/jsx-runtime";
2
- import "@mintlify/validation";
3
- import { cn as d } from "../../../../utils/cn.js";
4
- const s = ({
5
- schema: r,
6
- description: i
7
- }) => /* @__PURE__ */ n(t, { children: [
8
- r.const !== void 0 && /* @__PURE__ */ n("div", { className: d("mint:prose mint:prose-sm mint:prose-gray mint:dark:prose-invert", i && "mint:mt-6"), children: [
9
- "Allowed value: ",
10
- /* @__PURE__ */ e("code", { children: `"${r.const}"` })
11
- ] }),
12
- (r.minLength !== void 0 || r.maxLength !== void 0) && /* @__PURE__ */ e("div", { className: d("mint:prose mint:prose-sm mint:prose-gray mint:dark:prose-invert", i && "mint:mt-6"), children: /* @__PURE__ */ e(o, { minLength: r.minLength, maxLength: r.maxLength }) })
13
- ] }), o = ({ minLength: r, maxLength: i }) => r === i && r !== void 0 ? /* @__PURE__ */ n(t, { children: [
14
- "Required string length: ",
15
- /* @__PURE__ */ e("code", { children: r })
16
- ] }) : r && i ? /* @__PURE__ */ n(t, { children: [
17
- "Required string length: ",
18
- /* @__PURE__ */ e("code", { children: `${r} - ${i}` })
19
- ] }) : r ? /* @__PURE__ */ n(t, { children: [
20
- "Minimum length: ",
21
- /* @__PURE__ */ e("code", { children: r })
22
- ] }) : i ? /* @__PURE__ */ n(t, { children: [
23
- "Maximum length: ",
24
- /* @__PURE__ */ e("code", { children: i })
25
- ] }) : "";
26
- export {
27
- s as StringMetadata
28
- };
@@ -1,5 +0,0 @@
1
- import "react/jsx-runtime";
2
- const t = (e) => e.type === "enum<integer>" || e.type === "enum<number>" || e.type === "enum<string>";
3
- export {
4
- t as isEnum
5
- };
@@ -1,13 +0,0 @@
1
- import "react/jsx-runtime";
2
- import i from "@sindresorhus/slugify";
3
- import "../../../contexts/EndpointLocationContext.js";
4
- const s = (r, t, e, $) => i(
5
- `${r ? `${r}-` : ""}${e ? `${e}-` : ""}${t || ""}-`,
6
- {
7
- decamelize: !0
8
- }
9
- ), m = (r, t) => r ? `${t ? `${t}` : ""}${r}.` : "";
10
- export {
11
- s as buildRecursiveParamFieldId,
12
- m as getRecursiveParentName
13
- };