@stainless-api/docs-ui 0.1.0-beta.48 → 0.1.0-beta.49
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.
- package/dist/{breadcrumbs-TNRag6Vy.d.ts → breadcrumbs-DEyC9k79.d.ts} +2 -2
- package/dist/breadcrumbs-nSFZO5Gf.js +63 -0
- package/dist/component-DRO8kQSp.js +23 -0
- package/dist/{component-generics-F0_Dx7UT.js → component-generics-B6Fn47Mz.js} +1 -1
- package/dist/{component-generics-Cs7jFHLq.d.ts → component-generics-COP53CRn.d.ts} +2 -2
- package/dist/component-generics-fyFHB6qA.d.ts +30 -0
- package/dist/components/MaskedInput.d.ts +1 -1
- package/dist/components/MaskedInput.js +1 -1
- package/dist/components/breadcrumbs.d.ts +1 -1
- package/dist/components/breadcrumbs.js +7 -9
- package/dist/components/icons.d.ts +11 -11
- package/dist/components/icons.js +1 -1
- package/dist/components/index.d.ts +9 -9
- package/dist/components/index.js +16 -9
- package/dist/components/method.d.ts +1 -1
- package/dist/components/method.js +8 -9
- package/dist/components/overview.d.ts +1 -1
- package/dist/components/overview.js +9 -9
- package/dist/components/primitives.d.ts +1 -1
- package/dist/components/primitives.js +6 -9
- package/dist/components/properties.d.ts +1 -1
- package/dist/components/properties.js +7 -9
- package/dist/components/sdk.d.ts +1 -1
- package/dist/components/sdk.js +8 -9
- package/dist/components/sidebar.d.ts +1 -1
- package/dist/components/sidebar.js +9 -9
- package/dist/components/snippets.d.ts +2 -2
- package/dist/components/snippets.js +7 -9
- package/dist/components-D7M-BwNI.js +71 -0
- package/dist/contexts/component-generics.d.ts +1 -1
- package/dist/contexts/component-generics.js +1 -1
- package/dist/contexts/component-types.d.ts +10 -10
- package/dist/contexts/component.d.ts +13 -13
- package/dist/contexts/component.js +25 -9
- package/dist/contexts/docs.d.ts +1 -1
- package/dist/contexts/docs.js +1 -1
- package/dist/contexts/index.d.ts +16 -17
- package/dist/contexts/index.js +6 -10
- package/dist/contexts/markdown.d.ts +1 -1
- package/dist/contexts/markdown.js +2 -2
- package/dist/contexts/navigation.d.ts +1 -1
- package/dist/contexts/navigation.js +1 -1
- package/dist/contexts/use-components.d.ts +9 -9
- package/dist/contexts/use-components.js +2 -2
- package/dist/contexts-p3rRZDlM.js +39 -0
- package/dist/csharp-CDSxfCZE.js +283 -0
- package/dist/docs-yYrp-uzs.d.ts +47 -0
- package/dist/go-1c3S5ETL.js +303 -0
- package/dist/http-2QNWXH9t.js +330 -0
- package/dist/{index-Dt1TxDPe.d.ts → index-BQpRynot.d.ts} +8 -8
- package/dist/{index-BPQVqZ6-.d.ts → index-CnilsjrJ.d.ts} +30 -30
- package/dist/index-Ct0NcQUK.d.ts +274 -0
- package/dist/{index-D_zoydBM.d.ts → index-D6NhcxHd.d.ts} +6 -7
- package/dist/index-LboM0f0c.d.ts +15 -0
- package/dist/index-avtZIGmX.d.ts +13 -0
- package/dist/index.d.ts +18 -19
- package/dist/index.js +27 -12
- package/dist/java-BbjF_oUI.js +403 -0
- package/dist/languages/csharp.d.ts +10 -10
- package/dist/languages/csharp.js +7 -9
- package/dist/languages/go.d.ts +10 -10
- package/dist/languages/go.js +7 -9
- package/dist/languages/http.d.ts +10 -10
- package/dist/languages/http.js +17 -9
- package/dist/languages/index.d.ts +10 -10
- package/dist/languages/index.js +24 -9
- package/dist/languages/java.d.ts +10 -10
- package/dist/languages/java.js +7 -9
- package/dist/languages/python.d.ts +10 -10
- package/dist/languages/python.js +7 -9
- package/dist/languages/ruby.d.ts +10 -10
- package/dist/languages/ruby.js +7 -9
- package/dist/languages/typescript.d.ts +10 -10
- package/dist/languages/typescript.js +7 -9
- package/dist/languages-BCYZjzuS.js +26 -0
- package/dist/markdown/index.d.ts +4 -3
- package/dist/markdown/index.js +103 -10
- package/dist/markdown/md.js +1 -1
- package/dist/markdown/printer.d.ts +2 -0
- package/dist/markdown/printer.js +28 -0
- package/dist/markdown/utils.d.ts +2 -2
- package/dist/markdown/utils.js +1 -1
- package/dist/{markdown-J4fsbXbi.d.ts → markdown-C8o8WrwG.d.ts} +2 -2
- package/dist/{markdown-Bx-mQFEj.js → markdown-CxdeWgjV.js} +1 -1
- package/dist/markdown-DA2cRtlr.d.ts +22 -0
- package/dist/{method-uqti5jIi.d.ts → method-B6eAtYl2.d.ts} +7 -7
- package/dist/method-CE08mUME.js +115 -0
- package/dist/{navigation-DztmhdsO.d.ts → navigation-BfAVGPgw.d.ts} +3 -3
- package/dist/navigation-CjBnMcop.d.ts +29 -0
- package/dist/{overview-CXiAiRu3.d.ts → overview-CswoJHww.d.ts} +6 -6
- package/dist/overview-DeZSiqFa.d.ts +39 -0
- package/dist/overview-S2hUqPXA.js +139 -0
- package/dist/primitives-BIWfwN5L.js +258 -0
- package/dist/{primitives-CS8fdjfv.d.ts → primitives-Caj5rKBc.d.ts} +9 -9
- package/dist/primitives-CbqXZ-5f.d.ts +97 -0
- package/dist/printer-DBw4S_Jn.d.ts +13 -0
- package/dist/printer-DVZVkqAr.d.ts +13 -0
- package/dist/printer-bNxiG6UB.js +74 -0
- package/dist/{properties-Bf600pp5.d.ts → properties-BkUlpvU4.d.ts} +5 -5
- package/dist/properties-jlGW3USi.js +131 -0
- package/dist/python-USOwFDv_.js +279 -0
- package/dist/{routing-BcGPNh2R.d.ts → routing-CMqh1cTZ.d.ts} +1 -1
- package/dist/routing-Dhmv52Fd.d.ts +54 -0
- package/dist/{routing-BGBmkDBL.js → routing-Wbb7YECB.js} +1 -1
- package/dist/routing.d.ts +1 -1
- package/dist/routing.js +1 -1
- package/dist/ruby-CSvGbSLe.js +387 -0
- package/dist/{sdk-CuOpWo9I.d.ts → sdk-BOwYR0k6.d.ts} +14 -14
- package/dist/sdk-CSCbbn3O.js +336 -0
- package/dist/sdk-CdhDsvo3.d.ts +118 -0
- package/dist/{sidebar-CqfIoVcr.d.ts → sidebar-BXz93vSy.d.ts} +5 -5
- package/dist/sidebar-CWyvCrJ0.js +81 -0
- package/dist/snippets-BQLXEIf6.js +161 -0
- package/dist/{snippets-BwifQYD4.d.ts → snippets-CbVFNmfq.d.ts} +8 -8
- package/dist/snippets-Wjo2dJNw.d.ts +51 -0
- package/dist/spec.d.ts +3 -3
- package/dist/spec.js +2 -2
- package/dist/style.d.ts +1 -1
- package/dist/style.js +1 -1
- package/dist/styles/resets.css +2 -1
- package/dist/styles.css +7 -3
- package/dist/typescript-DXG9psK3.js +449 -0
- package/dist/{use-components-BAHidYIO.js → use-components-RWQbviGq.js} +1 -1
- package/dist/{utils-DAOeBdRL.d.ts → utils-CTGH5e8c.d.ts} +2 -2
- package/dist/utils-DNKOwa7D.d.ts +21 -0
- package/dist/{utils-0z34vxY4.js → utils-D_1AWSRX.js} +2 -2
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js +1 -1
- package/package.json +6 -20
- package/dist/contexts/search.d.ts +0 -2
- package/dist/contexts/search.js +0 -11
- package/dist/contexts-D3ClFTt3.js +0 -4117
- package/dist/pagefind-BHm6c3fb.js +0 -15
- package/dist/search/index.d.ts +0 -25
- package/dist/search/index.js +0 -332
- package/dist/search/mcp.d.ts +0 -13
- package/dist/search/mcp.js +0 -43
- package/dist/search/providers/algolia.d.ts +0 -24
- package/dist/search/providers/algolia.js +0 -11
- package/dist/search/providers/fuse.d.ts +0 -18
- package/dist/search/providers/fuse.js +0 -27
- package/dist/search/providers/pagefind.d.ts +0 -6
- package/dist/search/providers/pagefind.js +0 -3
- package/dist/search/providers/walker.d.ts +0 -9
- package/dist/search/providers/walker.js +0 -31
- package/dist/search/types.d.ts +0 -2
- package/dist/search/types.js +0 -3
- package/dist/search-DvzBAFUW.d.ts +0 -21
- package/dist/types-9YHj_ZeX.d.ts +0 -91
- package/dist/types-mRzd9aqe.js +0 -35
- /package/dist/{chunk-BWfJHHBp.js → chunk-DRcLgZ1e.js} +0 -0
- /package/dist/{docs-DGpIHBGY.d.ts → docs-B8-nCRaa.d.ts} +0 -0
- /package/dist/{docs-CNvEp0VL.js → docs-CXqi26jB.js} +0 -0
- /package/dist/{icons-DzBceOQw.js → icons-Ckod9aod.js} +0 -0
- /package/dist/{md-D5AxFoS4.js → md-oM2tUaCA.js} +0 -0
- /package/dist/{navigation-bydkHNUW.js → navigation-C5TN0SgC.js} +0 -0
- /package/dist/{style-D8hwSwrv.d.ts → style-D7RO5ymE.d.ts} +0 -0
- /package/dist/{style-0miv2y38.js → style-gnVEeXFj.js} +0 -0
- /package/dist/{utils-CiZXDoFR.js → utils-CqnL9Fc3.js} +0 -0
- /package/dist/{utils-BcWczffA.d.ts → utils-d8paVwKN.d.ts} +0 -0
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
import { a as useLanguage, c as useSnippet, r as useDeclaration } from "./docs-CXqi26jB.js";
|
|
2
|
+
import { r as useHighlight } from "./markdown-CxdeWgjV.js";
|
|
3
|
+
import { t as useComponents } from "./use-components-RWQbviGq.js";
|
|
4
|
+
import { t as style_default } from "./style-gnVEeXFj.js";
|
|
5
|
+
import * as React$1 from "react";
|
|
6
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
|
+
import { CheckIcon, CircleAlertIcon, CopyIcon } from "lucide-react";
|
|
8
|
+
import clsx from "clsx";
|
|
9
|
+
import { Button } from "@stainless-api/ui-primitives";
|
|
10
|
+
|
|
11
|
+
//#region src/components/snippets.tsx
|
|
12
|
+
function SnippetCode({ content, language }) {
|
|
13
|
+
const lang = useLanguage();
|
|
14
|
+
const highlighted = useHighlight(content, language || lang);
|
|
15
|
+
return /* @__PURE__ */ jsx("div", {
|
|
16
|
+
className: style_default.SnippetCode,
|
|
17
|
+
children: /* @__PURE__ */ jsx("pre", {
|
|
18
|
+
className: style_default.SnippetCodeContent,
|
|
19
|
+
"data-stldocs-copy-content": true,
|
|
20
|
+
children: /* @__PURE__ */ jsx("code", {
|
|
21
|
+
className: language === "json" ? "snippet-json" : "snippet",
|
|
22
|
+
dangerouslySetInnerHTML: { __html: highlighted }
|
|
23
|
+
})
|
|
24
|
+
})
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
function SnippetContainer({ children }) {
|
|
28
|
+
return /* @__PURE__ */ jsx("div", {
|
|
29
|
+
className: clsx(style_default.Snippet),
|
|
30
|
+
children
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
function SnippetRequestContainer({ children }) {
|
|
34
|
+
return /* @__PURE__ */ jsx("div", { children });
|
|
35
|
+
}
|
|
36
|
+
function Snippet({ requestTitle, method, transformRequestSnippet }) {
|
|
37
|
+
const Docs = useComponents();
|
|
38
|
+
const language = useLanguage();
|
|
39
|
+
const originalSnippet = useSnippet(method.stainlessPath, void 0, language === "http" ? "curl" : "default");
|
|
40
|
+
const decl = useDeclaration(method.stainlessPath, false);
|
|
41
|
+
if (!originalSnippet) {
|
|
42
|
+
console.warn(`Snippet not found for method '${method.stainlessPath}'`);
|
|
43
|
+
return null;
|
|
44
|
+
}
|
|
45
|
+
const signature = decl && "qualified" in decl ? decl.qualified : void 0;
|
|
46
|
+
const responses = method.exampleResponses;
|
|
47
|
+
const snippet = transformRequestSnippet ? transformRequestSnippet({
|
|
48
|
+
snippet: originalSnippet,
|
|
49
|
+
language
|
|
50
|
+
}) : originalSnippet;
|
|
51
|
+
return /* @__PURE__ */ jsxs(Docs.SnippetContainer, {
|
|
52
|
+
signature,
|
|
53
|
+
children: [snippet && /* @__PURE__ */ jsx(Docs.SnippetRequestContainer, {
|
|
54
|
+
signature,
|
|
55
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
56
|
+
className: style_default.SnippetRequest,
|
|
57
|
+
"data-stldocs-copy-parent": true,
|
|
58
|
+
children: [/* @__PURE__ */ jsxs("div", {
|
|
59
|
+
className: style_default.SnippetRequestTitle,
|
|
60
|
+
children: [
|
|
61
|
+
/* @__PURE__ */ jsxs("div", {
|
|
62
|
+
className: style_default.SnippetRequestTitleMethod,
|
|
63
|
+
children: [/* @__PURE__ */ jsx(Docs.MethodRoute, {
|
|
64
|
+
httpMethod: method.httpMethod,
|
|
65
|
+
iconOnly: true
|
|
66
|
+
}), /* @__PURE__ */ jsx("h5", { children: method.summary ?? method.title })]
|
|
67
|
+
}),
|
|
68
|
+
/* @__PURE__ */ jsx("div", {
|
|
69
|
+
className: style_default.SnippetRequestTitleContent,
|
|
70
|
+
children: requestTitle
|
|
71
|
+
}),
|
|
72
|
+
/* @__PURE__ */ jsx(Docs.SnippetButtons, { content: snippet })
|
|
73
|
+
]
|
|
74
|
+
}), /* @__PURE__ */ jsx(Docs.SnippetCode, {
|
|
75
|
+
content: snippet,
|
|
76
|
+
signature
|
|
77
|
+
})]
|
|
78
|
+
})
|
|
79
|
+
}), responses && /* @__PURE__ */ jsx(Docs.SnippetResponse, { responses })]
|
|
80
|
+
});
|
|
81
|
+
}
|
|
82
|
+
function SnippetButtons({ content }) {
|
|
83
|
+
const [CopyButtonIcon, setCopyIcon] = React$1.useState(CopyIcon);
|
|
84
|
+
async function handleCopy() {
|
|
85
|
+
try {
|
|
86
|
+
await navigator.clipboard.writeText(content);
|
|
87
|
+
setCopyIcon(CheckIcon);
|
|
88
|
+
} catch {
|
|
89
|
+
setCopyIcon(CircleAlertIcon);
|
|
90
|
+
}
|
|
91
|
+
setTimeout(() => setCopyIcon(CopyIcon), 1e3);
|
|
92
|
+
}
|
|
93
|
+
return /* @__PURE__ */ jsx(Button, {
|
|
94
|
+
variant: "ghost",
|
|
95
|
+
"data-stldocs-snippet-copy": true,
|
|
96
|
+
children: /* @__PURE__ */ jsx(CopyButtonIcon, {
|
|
97
|
+
size: 16,
|
|
98
|
+
className: style_default.Icon,
|
|
99
|
+
onClick: handleCopy
|
|
100
|
+
})
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
function SnippetResponse({ responses }) {
|
|
104
|
+
const { SnippetCode: SnippetCode$1 } = useComponents();
|
|
105
|
+
if (!responses) return null;
|
|
106
|
+
const mappedResponses = Object.keys(responses).map((key) => {
|
|
107
|
+
const responseContent = responses[key];
|
|
108
|
+
if (!responseContent) return null;
|
|
109
|
+
const responseType = Object.keys(responseContent)[0];
|
|
110
|
+
if (!responseType) return null;
|
|
111
|
+
const response = responseContent[responseType];
|
|
112
|
+
if (!response) return null;
|
|
113
|
+
const examples = response?.examples;
|
|
114
|
+
if (!examples) return null;
|
|
115
|
+
const exampleType = Object.keys(examples)[0];
|
|
116
|
+
if (!exampleType) return null;
|
|
117
|
+
let value = examples[exampleType]?.value;
|
|
118
|
+
if (!value) return null;
|
|
119
|
+
let language = "none";
|
|
120
|
+
if (responseType === "application/json" || typeof value === "object") {
|
|
121
|
+
language = "json";
|
|
122
|
+
value = JSON.stringify(value, null, 2);
|
|
123
|
+
}
|
|
124
|
+
return {
|
|
125
|
+
language,
|
|
126
|
+
responseCode: key,
|
|
127
|
+
content: value
|
|
128
|
+
};
|
|
129
|
+
}).filter(Boolean);
|
|
130
|
+
if (mappedResponses.length === 0) return null;
|
|
131
|
+
return /* @__PURE__ */ jsx("div", {
|
|
132
|
+
className: style_default.SnippetMultiResponse,
|
|
133
|
+
children: /* @__PURE__ */ jsxs("div", {
|
|
134
|
+
className: clsx(style_default.Snippet),
|
|
135
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
136
|
+
className: clsx(style_default.SnippetResponseTab, mappedResponses.length === 1 && style_default.SnippetResponseTabSingleReturn),
|
|
137
|
+
children: mappedResponses.map(({ responseCode }, index) => /* @__PURE__ */ jsx("div", {
|
|
138
|
+
"data-snippet-response-tab-id": `snippet-response-tab-${responseCode}-${index}`,
|
|
139
|
+
className: clsx(style_default.SnippetResponseTabItem, index === 0 && style_default.SnippetResponseTabItemActive),
|
|
140
|
+
children: /* @__PURE__ */ jsxs(Button, {
|
|
141
|
+
disabled: mappedResponses.length === 1,
|
|
142
|
+
variant: "ghost",
|
|
143
|
+
children: [responseCode, " example"]
|
|
144
|
+
})
|
|
145
|
+
}, `snippet-response-tab-item-${responseCode}-${index}`))
|
|
146
|
+
}), mappedResponses.map(({ responseCode, content, language }, index) => {
|
|
147
|
+
return /* @__PURE__ */ jsx("div", {
|
|
148
|
+
className: clsx(style_default.SnippetResponsePane, index === 0 && style_default.SnippetResponsePaneActive),
|
|
149
|
+
"data-snippet-response-pane-id": `snippet-response-tab-${responseCode}-${index}`,
|
|
150
|
+
children: /* @__PURE__ */ jsx(SnippetCode$1, {
|
|
151
|
+
content,
|
|
152
|
+
language
|
|
153
|
+
})
|
|
154
|
+
}, `snippet-response-${responseCode}-${index}`);
|
|
155
|
+
})]
|
|
156
|
+
})
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
//#endregion
|
|
161
|
+
export { SnippetRequestContainer as a, SnippetContainer as i, SnippetButtons as n, SnippetResponse as o, SnippetCode as r, Snippet as t };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as TransformRequestSnippetFn } from "./sdk-
|
|
1
|
+
import { C as TransformRequestSnippetFn } from "./sdk-CdhDsvo3.js";
|
|
2
2
|
import * as React$1 from "react";
|
|
3
|
-
import * as
|
|
3
|
+
import * as react_jsx_runtime52 from "react/jsx-runtime";
|
|
4
4
|
import * as SDKJSON from "@stainless/sdk-json";
|
|
5
5
|
|
|
6
6
|
//#region src/components/snippets.d.ts
|
|
@@ -12,7 +12,7 @@ type SnippetCodeProps = {
|
|
|
12
12
|
declare function SnippetCode({
|
|
13
13
|
content,
|
|
14
14
|
language
|
|
15
|
-
}: SnippetCodeProps):
|
|
15
|
+
}: SnippetCodeProps): react_jsx_runtime52.JSX.Element;
|
|
16
16
|
type SnippetProps = {
|
|
17
17
|
method: SDKJSON.Method;
|
|
18
18
|
requestTitle?: React$1.ReactNode;
|
|
@@ -24,28 +24,28 @@ type SnippetContainerProps = {
|
|
|
24
24
|
};
|
|
25
25
|
declare function SnippetContainer({
|
|
26
26
|
children
|
|
27
|
-
}: SnippetContainerProps):
|
|
27
|
+
}: SnippetContainerProps): react_jsx_runtime52.JSX.Element;
|
|
28
28
|
type SnippetRequestContainerProps = {
|
|
29
29
|
children?: React$1.ReactNode;
|
|
30
30
|
signature?: string;
|
|
31
31
|
};
|
|
32
32
|
declare function SnippetRequestContainer({
|
|
33
33
|
children
|
|
34
|
-
}: SnippetRequestContainerProps):
|
|
34
|
+
}: SnippetRequestContainerProps): react_jsx_runtime52.JSX.Element;
|
|
35
35
|
declare function Snippet({
|
|
36
36
|
requestTitle,
|
|
37
37
|
method,
|
|
38
38
|
transformRequestSnippet
|
|
39
|
-
}: SnippetProps):
|
|
39
|
+
}: SnippetProps): react_jsx_runtime52.JSX.Element | null;
|
|
40
40
|
declare function SnippetButtons({
|
|
41
41
|
content
|
|
42
42
|
}: {
|
|
43
43
|
content: string;
|
|
44
|
-
}):
|
|
44
|
+
}): react_jsx_runtime52.JSX.Element;
|
|
45
45
|
declare function SnippetResponse({
|
|
46
46
|
responses
|
|
47
47
|
}: {
|
|
48
48
|
responses: SDKJSON.Method['exampleResponses'];
|
|
49
|
-
}):
|
|
49
|
+
}): react_jsx_runtime52.JSX.Element | null;
|
|
50
50
|
//#endregion
|
|
51
51
|
export { SnippetContainer as a, SnippetRequestContainer as c, SnippetCodeProps as i, SnippetRequestContainerProps as l, SnippetButtons as n, SnippetContainerProps as o, SnippetCode as r, SnippetProps as s, Snippet as t, SnippetResponse as u };
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { C as TransformRequestSnippetFn } from "./sdk-BOwYR0k6.js";
|
|
2
|
+
import * as React$1 from "react";
|
|
3
|
+
import * as react_jsx_runtime51 from "react/jsx-runtime";
|
|
4
|
+
import * as SDKJSON from "@stainless/sdk-json";
|
|
5
|
+
|
|
6
|
+
//#region src/components/snippets.d.ts
|
|
7
|
+
type SnippetCodeProps = {
|
|
8
|
+
content: string;
|
|
9
|
+
signature?: string;
|
|
10
|
+
language?: string;
|
|
11
|
+
};
|
|
12
|
+
declare function SnippetCode({
|
|
13
|
+
content,
|
|
14
|
+
language
|
|
15
|
+
}: SnippetCodeProps): react_jsx_runtime51.JSX.Element;
|
|
16
|
+
type SnippetProps = {
|
|
17
|
+
method: SDKJSON.Method;
|
|
18
|
+
requestTitle?: React$1.ReactNode;
|
|
19
|
+
transformRequestSnippet?: TransformRequestSnippetFn;
|
|
20
|
+
};
|
|
21
|
+
type SnippetContainerProps = {
|
|
22
|
+
children: React$1.ReactNode;
|
|
23
|
+
signature?: string;
|
|
24
|
+
};
|
|
25
|
+
declare function SnippetContainer({
|
|
26
|
+
children
|
|
27
|
+
}: SnippetContainerProps): react_jsx_runtime51.JSX.Element;
|
|
28
|
+
type SnippetRequestContainerProps = {
|
|
29
|
+
children?: React$1.ReactNode;
|
|
30
|
+
signature?: string;
|
|
31
|
+
};
|
|
32
|
+
declare function SnippetRequestContainer({
|
|
33
|
+
children
|
|
34
|
+
}: SnippetRequestContainerProps): react_jsx_runtime51.JSX.Element;
|
|
35
|
+
declare function Snippet({
|
|
36
|
+
requestTitle,
|
|
37
|
+
method,
|
|
38
|
+
transformRequestSnippet
|
|
39
|
+
}: SnippetProps): react_jsx_runtime51.JSX.Element | null;
|
|
40
|
+
declare function SnippetButtons({
|
|
41
|
+
content
|
|
42
|
+
}: {
|
|
43
|
+
content: string;
|
|
44
|
+
}): react_jsx_runtime51.JSX.Element;
|
|
45
|
+
declare function SnippetResponse({
|
|
46
|
+
responses
|
|
47
|
+
}: {
|
|
48
|
+
responses: SDKJSON.Method['exampleResponses'];
|
|
49
|
+
}): react_jsx_runtime51.JSX.Element | null;
|
|
50
|
+
//#endregion
|
|
51
|
+
export { SnippetContainer as a, SnippetRequestContainer as c, SnippetCodeProps as i, SnippetRequestContainerProps as l, SnippetButtons as n, SnippetContainerProps as o, SnippetCode as r, SnippetProps as s, Snippet as t, SnippetResponse as u };
|
package/dist/spec.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as DocsLanguage } from "./routing-
|
|
1
|
+
import { t as DocsLanguage } from "./routing-CMqh1cTZ.js";
|
|
2
2
|
import * as SDKJSON from "@stainless/sdk-json";
|
|
3
3
|
|
|
4
4
|
//#region src/spec.d.ts
|
|
@@ -36,13 +36,13 @@ declare function generateNavigation(resource: Partial<SDKJSON.Resource>): {
|
|
|
36
36
|
declare function generateSpecForResource(spec: SDKJSON.Spec, name: string, lang: DocsLanguage, transforms: SpecTransforms): Partial<SDKJSON.Spec>;
|
|
37
37
|
declare function transform(spec: SDKJSON.Spec, transforms: SpecTransforms): {
|
|
38
38
|
name: string;
|
|
39
|
-
lang: "
|
|
39
|
+
lang: "http" | "node" | "python" | "go" | "typescript" | "terraform" | "ruby" | "java" | "kotlin" | "csharp" | "php";
|
|
40
40
|
spec: Partial<SDKJSON.Spec>;
|
|
41
41
|
}[];
|
|
42
42
|
declare function split(spec: SDKJSON.Spec, transforms?: SpecTransforms): {
|
|
43
43
|
resources: ReturnType<typeof transform>;
|
|
44
44
|
navigation: {
|
|
45
|
-
languages: ("
|
|
45
|
+
languages: ("http" | "node" | "python" | "go" | "typescript" | "terraform" | "ruby" | "java" | "kotlin")[] | undefined;
|
|
46
46
|
resources: {
|
|
47
47
|
[k: string]: {
|
|
48
48
|
title: string | undefined;
|
package/dist/spec.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as Languages } from "./routing-
|
|
2
|
-
import { r as isResourceEmpty } from "./utils-
|
|
1
|
+
import { n as Languages } from "./routing-Wbb7YECB.js";
|
|
2
|
+
import { r as isResourceEmpty } from "./utils-D_1AWSRX.js";
|
|
3
3
|
|
|
4
4
|
//#region src/spec.ts
|
|
5
5
|
const defaultTransforms = {
|
package/dist/style.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as _default } from "./style-
|
|
1
|
+
import { t as _default } from "./style-D7RO5ymE.js";
|
|
2
2
|
export { _default as default };
|
package/dist/style.js
CHANGED
package/dist/styles/resets.css
CHANGED
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
display: block;
|
|
21
21
|
color: var(--stl-color-foreground);
|
|
22
22
|
font-weight: 500;
|
|
23
|
-
line-height: var(--stl-typography-line-height-
|
|
23
|
+
line-height: var(--stl-typography-line-height-heading);
|
|
24
|
+
font-family: var(--stl-typography-font-heading);
|
|
24
25
|
}
|
|
25
26
|
|
|
26
27
|
display: block;
|
package/dist/styles.css
CHANGED
|
@@ -3,8 +3,10 @@
|
|
|
3
3
|
:root {
|
|
4
4
|
--stl-typography-font: 'Geist', system-ui, sans-serif;
|
|
5
5
|
--stl-typography-font-mono: 'Geist Mono', ui-monospace, monospace;
|
|
6
|
+
--stl-typography-font-heading: var(--stl-typography-font);
|
|
7
|
+
|
|
6
8
|
--stl-typography-line-height: 1.5;
|
|
7
|
-
--stl-typography-line-height-
|
|
9
|
+
--stl-typography-line-height-heading: 1.2;
|
|
8
10
|
|
|
9
11
|
--stl-typography-text-body: var(--stl-typography-scale-base);
|
|
10
12
|
--stl-typography-text-body-sm: var(--stl-typography-scale-sm);
|
|
@@ -79,7 +81,8 @@ body {
|
|
|
79
81
|
:where(h1, h2, h3, h4, h5, h6):where(:not(.stl-ui-not-prose *), .stl-ui-not-prose .stl-ui-prose *) {
|
|
80
82
|
color: var(--stl-color-foreground);
|
|
81
83
|
font-weight: 500;
|
|
82
|
-
line-height: var(--stl-typography-line-height-
|
|
84
|
+
line-height: var(--stl-typography-line-height-heading);
|
|
85
|
+
font-family: var(--stl-typography-font-heading);
|
|
83
86
|
}
|
|
84
87
|
|
|
85
88
|
:where(h1:not(.stl-ui-not-prose *), .stl-ui-not-prose .stl-ui-prose h1) {
|
|
@@ -1110,7 +1113,8 @@ a.stl-ui-button {
|
|
|
1110
1113
|
display: block;
|
|
1111
1114
|
color: var(--stl-color-foreground);
|
|
1112
1115
|
font-weight: 500;
|
|
1113
|
-
line-height: var(--stl-typography-line-height-
|
|
1116
|
+
line-height: var(--stl-typography-line-height-heading);
|
|
1117
|
+
font-family: var(--stl-typography-font-heading);
|
|
1114
1118
|
}
|
|
1115
1119
|
|
|
1116
1120
|
display: block;
|