@stainless-api/docs-ui 0.1.0-beta.10 → 0.1.0-beta.11
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-Z-hEqjcp.d.ts +19 -0
- package/dist/chunk-Bp6m_JJh.js +13 -0
- package/dist/component-generics-DzI21jRn.js +35 -0
- package/dist/component-generics-q5Dqiu2D.d.ts +30 -0
- package/dist/components/breadcrumbs.d.ts +2 -11
- package/dist/components/breadcrumbs.js +16 -52
- package/dist/components/chat.d.ts +13 -5
- package/dist/components/chat.js +138 -74
- package/dist/components/dropdown.d.ts +2 -17
- package/dist/components/dropdown.js +4 -18
- package/dist/components/icons.d.ts +50 -27
- package/dist/components/icons.js +3 -34
- package/dist/components/index.d.ts +12 -9
- package/dist/components/index.js +16 -10
- package/dist/components/method.d.ts +2 -41
- package/dist/components/method.js +16 -44
- package/dist/components/overview.d.ts +2 -21
- package/dist/components/overview.js +16 -49
- package/dist/components/primitives.d.ts +2 -60
- package/dist/components/primitives.js +16 -117
- package/dist/components/properties.d.ts +2 -24
- package/dist/components/properties.js +16 -24
- package/dist/components/scripts/dropdown.d.ts +11 -4
- package/dist/components/scripts/dropdown.js +49 -63
- package/dist/components/sdk.d.ts +3 -78
- package/dist/components/sdk.js +16 -153
- package/dist/components/sidebar.d.ts +2 -22
- package/dist/components/sidebar.js +16 -30
- package/dist/components/snippets.d.ts +4 -28
- package/dist/components/snippets.js +16 -76
- package/dist/contexts/component-generics.d.ts +2 -25
- package/dist/contexts/component-generics.js +3 -24
- package/dist/contexts/component-types.d.ts +18 -4
- package/dist/contexts/component-types.js +1 -2
- package/dist/contexts/component.d.ts +31 -14
- package/dist/contexts/component.js +16 -14
- package/dist/contexts/docs.d.ts +2 -34
- package/dist/contexts/docs.js +3 -43
- package/dist/contexts/index.d.ts +20 -7
- package/dist/contexts/index.js +16 -15
- package/dist/contexts/markdown.d.ts +2 -13
- package/dist/contexts/markdown.js +4 -29
- package/dist/contexts/navigation.d.ts +3 -19
- package/dist/contexts/navigation.js +3 -14
- package/dist/contexts/search.d.ts +4 -13
- package/dist/contexts/search.js +16 -15
- package/dist/contexts/use-components.d.ts +16 -1
- package/dist/contexts/use-components.js +4 -3
- package/dist/contexts-DRxRO-xO.js +3747 -0
- package/dist/docs-Dh8kE1va.js +50 -0
- package/dist/docs-EUy-wfbA.d.ts +43 -0
- package/dist/dropdown-B7VyGMOw.d.ts +43 -0
- package/dist/dropdown-DtgAi6lb.js +62 -0
- package/dist/icons-DdKM-01E.js +753 -0
- package/dist/index-AicgPYKB.d.ts +239 -0
- package/dist/index-BhwLhiWk.d.ts +14 -0
- package/dist/index-YnpUtXLB.d.ts +16 -0
- package/dist/index.d.ts +22 -6
- package/dist/index.js +16 -7
- package/dist/languages/go.d.ts +13 -21
- package/dist/languages/go.js +16 -116
- package/dist/languages/http.d.ts +13 -25
- package/dist/languages/http.js +16 -130
- package/dist/languages/index.d.ts +13 -37
- package/dist/languages/index.js +16 -10
- package/dist/languages/java.d.ts +13 -23
- package/dist/languages/java.js +16 -120
- package/dist/languages/python.d.ts +13 -22
- package/dist/languages/python.js +16 -104
- package/dist/languages/ruby.d.ts +13 -22
- package/dist/languages/ruby.js +16 -125
- package/dist/languages/typescript.d.ts +13 -22
- package/dist/languages/typescript.js +16 -134
- package/dist/markdown/index.d.ts +11 -6
- package/dist/markdown/index.js +16 -80
- package/dist/markdown/md.d.ts +15 -11
- package/dist/markdown/md.js +3 -34
- package/dist/markdown/utils.d.ts +4 -17
- package/dist/markdown/utils.js +3 -30
- package/dist/markdown-BXfX1D7C.js +42 -0
- package/dist/markdown-nFyAEX_K.d.ts +22 -0
- package/dist/md-Dg8aOyMA.js +41 -0
- package/dist/method-DpsVuzZW.d.ts +71 -0
- package/dist/navigation-aoYZ_tl4.js +24 -0
- package/dist/navigation-nyXBY-75.d.ts +29 -0
- package/dist/overview-C8e-6jGr.d.ts +38 -0
- package/dist/pagefind-ChrPfuVv.js +15 -0
- package/dist/primitives-DWz23_Ub.d.ts +99 -0
- package/dist/properties-CF71V58d.d.ts +46 -0
- package/dist/routing-DQjbRxdJ.js +189 -0
- package/dist/routing-qc0V00-j.d.ts +51 -0
- package/dist/routing.d.ts +2 -44
- package/dist/routing.js +3 -169
- package/dist/sdk-Zg3Rggk3.d.ts +118 -0
- package/dist/search/index.d.ts +26 -1
- package/dist/search/index.js +332 -2
- package/dist/search/providers/algolia.d.ts +22 -7
- package/dist/search/providers/algolia.js +16 -64
- package/dist/search/providers/fuse.d.ts +16 -9
- package/dist/search/providers/fuse.js +29 -12
- package/dist/search/providers/pagefind.d.ts +7 -2
- package/dist/search/providers/pagefind.js +3 -19
- package/dist/search/providers/walker.d.ts +8 -5
- package/dist/search/providers/walker.js +28 -19
- package/dist/search/types.d.ts +3 -79
- package/dist/search/types.js +3 -24
- package/dist/search-B6loAGmB.d.ts +21 -0
- package/dist/sidebar-C8KirYjg.d.ts +35 -0
- package/dist/snippets-EUzM4fRO.d.ts +45 -0
- package/dist/style-pN9hCoec.d.ts +181 -0
- package/dist/style-rYbbxIR_.js +182 -0
- package/dist/style.d.ts +2 -179
- package/dist/style.js +3 -179
- package/dist/styles/main.css +740 -746
- package/dist/styles/main.js +1 -0
- package/dist/styles/primitives.css +436 -428
- package/dist/styles/primitives.js +1 -0
- package/dist/styles/resets.css +34 -41
- package/dist/styles/resets.js +1 -0
- package/dist/styles/search.css +248 -248
- package/dist/styles/search.js +1 -0
- package/dist/styles/sidebar.css +59 -60
- package/dist/styles/sidebar.js +1 -0
- package/dist/styles/snippets.css +87 -88
- package/dist/styles/snippets.js +1 -0
- package/dist/styles/variables.css +86 -89
- package/dist/styles/variables.js +1 -0
- package/dist/types-CTBDtD34.d.ts +82 -0
- package/dist/types-DFN4M1Sp.js +34 -0
- package/dist/use-components-D9E85p5x.js +7 -0
- package/dist/utils-BHwvUDKn.js +30 -0
- package/dist/utils-CJfFBNgT.js +32 -0
- package/dist/utils-DQhEbvUC.d.ts +20 -0
- package/dist/utils-nDazhti8.d.ts +11 -0
- package/dist/utils.d.ts +2 -7
- package/dist/utils.js +4 -27
- package/package.json +2 -2
- package/dist/components/breadcrumbs.js.map +0 -1
- package/dist/components/chat.js.map +0 -1
- package/dist/components/dropdown.js.map +0 -1
- package/dist/components/icons.js.map +0 -1
- package/dist/components/index.js.map +0 -1
- package/dist/components/method.js.map +0 -1
- package/dist/components/overview.js.map +0 -1
- package/dist/components/primitives.js.map +0 -1
- package/dist/components/properties.js.map +0 -1
- package/dist/components/scripts/dropdown.js.map +0 -1
- package/dist/components/sdk.js.map +0 -1
- package/dist/components/sidebar.js.map +0 -1
- package/dist/components/snippets.js.map +0 -1
- package/dist/contexts/component-generics.js.map +0 -1
- package/dist/contexts/component-types.js.map +0 -1
- package/dist/contexts/component.js.map +0 -1
- package/dist/contexts/docs.js.map +0 -1
- package/dist/contexts/index.js.map +0 -1
- package/dist/contexts/markdown.js.map +0 -1
- package/dist/contexts/navigation.js.map +0 -1
- package/dist/contexts/search.js.map +0 -1
- package/dist/contexts/use-components.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/languages/go.js.map +0 -1
- package/dist/languages/http.js.map +0 -1
- package/dist/languages/index.js.map +0 -1
- package/dist/languages/java.js.map +0 -1
- package/dist/languages/python.js.map +0 -1
- package/dist/languages/ruby.js.map +0 -1
- package/dist/languages/typescript.js.map +0 -1
- package/dist/markdown/index.js.map +0 -1
- package/dist/markdown/md.js.map +0 -1
- package/dist/markdown/utils.js.map +0 -1
- package/dist/mcp.js +0 -16105
- package/dist/routing.js.map +0 -1
- package/dist/search/form.d.ts +0 -13
- package/dist/search/form.js +0 -55
- package/dist/search/form.js.map +0 -1
- package/dist/search/index.js.map +0 -1
- package/dist/search/indexer.d.ts +0 -31
- package/dist/search/indexer.js +0 -212
- package/dist/search/indexer.js.map +0 -1
- package/dist/search/mcp.d.ts +0 -8
- package/dist/search/mcp.js +0 -43
- package/dist/search/mcp.js.map +0 -1
- package/dist/search/printer.d.ts +0 -6
- package/dist/search/printer.js +0 -43
- package/dist/search/printer.js.map +0 -1
- package/dist/search/providers/algolia.js.map +0 -1
- package/dist/search/providers/fuse.js.map +0 -1
- package/dist/search/providers/pagefind.js.map +0 -1
- package/dist/search/providers/walker.js.map +0 -1
- package/dist/search/results.d.ts +0 -21
- package/dist/search/results.js +0 -58
- package/dist/search/results.js.map +0 -1
- package/dist/search/state.d.ts +0 -29
- package/dist/search/state.js +0 -38
- package/dist/search/state.js.map +0 -1
- package/dist/search/types.js.map +0 -1
- package/dist/style.js.map +0 -1
- package/dist/types/sdkjson.d.ts +0 -1
- package/dist/types/sdkjson.js +0 -2
- package/dist/types/sdkjson.js.map +0 -1
- package/dist/types/stainless-alias/lib/json-spec-v2/GoAST.d.ts +0 -120
- package/dist/types/stainless-alias/lib/json-spec-v2/GoAST.js +0 -2
- package/dist/types/stainless-alias/lib/json-spec-v2/GoAST.js.map +0 -1
- package/dist/types/stainless-alias/lib/json-spec-v2/HttpAST.d.ts +0 -100
- package/dist/types/stainless-alias/lib/json-spec-v2/HttpAST.js +0 -3
- package/dist/types/stainless-alias/lib/json-spec-v2/HttpAST.js.map +0 -1
- package/dist/types/stainless-alias/lib/json-spec-v2/JavaAST.d.ts +0 -87
- package/dist/types/stainless-alias/lib/json-spec-v2/JavaAST.js +0 -2
- package/dist/types/stainless-alias/lib/json-spec-v2/JavaAST.js.map +0 -1
- package/dist/types/stainless-alias/lib/json-spec-v2/PythonAST.d.ts +0 -110
- package/dist/types/stainless-alias/lib/json-spec-v2/PythonAST.js +0 -3
- package/dist/types/stainless-alias/lib/json-spec-v2/PythonAST.js.map +0 -1
- package/dist/types/stainless-alias/lib/json-spec-v2/RubyAST.d.ts +0 -122
- package/dist/types/stainless-alias/lib/json-spec-v2/RubyAST.js +0 -2
- package/dist/types/stainless-alias/lib/json-spec-v2/RubyAST.js.map +0 -1
- package/dist/types/stainless-alias/lib/json-spec-v2/TSAST.d.ts +0 -146
- package/dist/types/stainless-alias/lib/json-spec-v2/TSAST.js +0 -3
- package/dist/types/stainless-alias/lib/json-spec-v2/TSAST.js.map +0 -1
- package/dist/types/stainless-alias/lib/json-spec-v2/TerraformAST.d.ts +0 -89
- package/dist/types/stainless-alias/lib/json-spec-v2/TerraformAST.js +0 -3
- package/dist/types/stainless-alias/lib/json-spec-v2/TerraformAST.js.map +0 -1
- package/dist/types/stainless-alias/lib/json-spec-v2/types.d.ts +0 -190
- package/dist/types/stainless-alias/lib/json-spec-v2/types.js +0 -105
- package/dist/types/stainless-alias/lib/json-spec-v2/types.js.map +0 -1
- package/dist/utils.js.map +0 -1
|
@@ -1,24 +1,16 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
const { collapseDescription, types } = useSettings().properties ?? {};
|
|
18
|
-
const textContent = (_jsxs(_Fragment, { children: [typeof deprecated === 'string' && _jsx("div", { className: style.PropertyDeprecatedMessage, children: deprecated }), description && _jsx(Docs.PropertyDescription, { description: description }), constraints && _jsx("div", { className: style.PropertyContent, children: constraints })] }));
|
|
19
|
-
const rich = (_jsxs(_Fragment, { children: [_jsxs("div", { className: style.PropertyDeclaration, children: [deprecated && _jsx("span", { className: style.PropertyDeprecated, children: "Deprecated" }), declaration, badges && _jsx("span", { className: style.PropertyBadges, children: badges })] }), collapseDescription === false ? textContent : null] }));
|
|
20
|
-
const simple = (_jsxs(_Fragment, { children: [name && (_jsxs("div", { className: style.PropertyHeader, children: [deprecated && _jsx("span", { className: style.PropertyDeprecated, children: "Deprecated" }), name && _jsx("span", { className: style.PropertyName, children: name }), typeName && _jsx("span", { className: style.PropertyTypeName, children: typeName }), badges && _jsx("span", { className: style.PropertyBadges, children: badges })] })), type && _jsx("div", { className: style.PropertyType, children: type }), collapseDescription === false ? textContent : null] }));
|
|
21
|
-
const content = (_jsx("div", { id: id, className: style.PropertyInfo, children: types === 'simple' ? simple : rich }));
|
|
22
|
-
return (_jsx("div", { className: style.Property, "data-stldocs-language": language, children: children || (collapseDescription !== false && description) ? (_jsxs(Docs.Expander, { summary: content, muted: !children, open: expand, children: [collapseDescription !== false ? textContent : null, additional, children && _jsx("div", { className: style.PropertyChildren, children: children })] })) : (content) }));
|
|
23
|
-
}
|
|
24
|
-
//# sourceMappingURL=properties.js.map
|
|
1
|
+
import "../component-generics-DzI21jRn.js";
|
|
2
|
+
import "../docs-Dh8kE1va.js";
|
|
3
|
+
import "../navigation-aoYZ_tl4.js";
|
|
4
|
+
import "../markdown-BXfX1D7C.js";
|
|
5
|
+
import "../routing-DQjbRxdJ.js";
|
|
6
|
+
import "../style-rYbbxIR_.js";
|
|
7
|
+
import "../use-components-D9E85p5x.js";
|
|
8
|
+
import { $t as PropertyDescription, Qt as Property, en as PropertyToggle } from "../contexts-DRxRO-xO.js";
|
|
9
|
+
import "../icons-DdKM-01E.js";
|
|
10
|
+
import "../utils-CJfFBNgT.js";
|
|
11
|
+
import "../dropdown-DtgAi6lb.js";
|
|
12
|
+
import "../md-Dg8aOyMA.js";
|
|
13
|
+
import "../utils-BHwvUDKn.js";
|
|
14
|
+
import "../types-DFN4M1Sp.js";
|
|
15
|
+
|
|
16
|
+
export { Property, PropertyDescription, PropertyToggle };
|
|
@@ -1,5 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
//#region src/components/scripts/dropdown.d.ts
|
|
2
|
+
declare function initDropdown({
|
|
3
|
+
dropdownId,
|
|
4
|
+
onSelect,
|
|
5
|
+
isFixed
|
|
6
|
+
}: {
|
|
7
|
+
dropdownId: string;
|
|
8
|
+
onSelect?: (value: string) => void;
|
|
9
|
+
isFixed?: boolean;
|
|
5
10
|
}): void;
|
|
11
|
+
//#endregion
|
|
12
|
+
export { initDropdown };
|
|
@@ -1,64 +1,50 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
document.addEventListener('keydown', (e) => {
|
|
48
|
-
if (e.key === 'Escape' && isOpen) {
|
|
49
|
-
closeDropdown();
|
|
50
|
-
}
|
|
51
|
-
});
|
|
52
|
-
// Close dropdown when clicking on dropdown items
|
|
53
|
-
const dropdownItems = menu.querySelectorAll('.stldocs-dropdown-item');
|
|
54
|
-
dropdownItems.forEach((item) => {
|
|
55
|
-
item.addEventListener('click', () => {
|
|
56
|
-
closeDropdown();
|
|
57
|
-
const selectedValue = item.getAttribute('data-dropdown-value');
|
|
58
|
-
if (selectedValue && onSelect) {
|
|
59
|
-
onSelect(selectedValue);
|
|
60
|
-
}
|
|
61
|
-
});
|
|
62
|
-
});
|
|
1
|
+
//#region src/components/scripts/dropdown.ts
|
|
2
|
+
function initDropdown({ dropdownId, onSelect, isFixed }) {
|
|
3
|
+
const dropdown = document.getElementById(dropdownId);
|
|
4
|
+
if (!dropdown) return;
|
|
5
|
+
const button = dropdown.querySelector("button");
|
|
6
|
+
const menu = dropdown.querySelector(".stldocs-dropdown-menu");
|
|
7
|
+
if (!button || !menu) return;
|
|
8
|
+
let isOpen = false;
|
|
9
|
+
function toggleDropdown() {
|
|
10
|
+
if (!button || !menu) return;
|
|
11
|
+
isOpen = !isOpen;
|
|
12
|
+
if (isOpen) {
|
|
13
|
+
if (isFixed) {
|
|
14
|
+
const buttonRect = button.getBoundingClientRect();
|
|
15
|
+
menu.style.top = `${buttonRect.bottom}px`;
|
|
16
|
+
menu.style.left = `${buttonRect.left}px`;
|
|
17
|
+
}
|
|
18
|
+
menu.classList.add("open");
|
|
19
|
+
button.setAttribute("aria-expanded", "true");
|
|
20
|
+
} else {
|
|
21
|
+
menu.classList.remove("open");
|
|
22
|
+
button.setAttribute("aria-expanded", "false");
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
function closeDropdown() {
|
|
26
|
+
if (!button || !menu) return;
|
|
27
|
+
isOpen = false;
|
|
28
|
+
menu.classList.remove("open");
|
|
29
|
+
button.setAttribute("aria-expanded", "false");
|
|
30
|
+
}
|
|
31
|
+
button.addEventListener("click", (e) => {
|
|
32
|
+
toggleDropdown();
|
|
33
|
+
});
|
|
34
|
+
document.addEventListener("click", (e) => {
|
|
35
|
+
if (!dropdown.contains(e.target)) closeDropdown();
|
|
36
|
+
});
|
|
37
|
+
document.addEventListener("keydown", (e) => {
|
|
38
|
+
if (e.key === "Escape" && isOpen) closeDropdown();
|
|
39
|
+
});
|
|
40
|
+
menu.querySelectorAll(".stldocs-dropdown-item").forEach((item) => {
|
|
41
|
+
item.addEventListener("click", () => {
|
|
42
|
+
closeDropdown();
|
|
43
|
+
const selectedValue = item.getAttribute("data-dropdown-value");
|
|
44
|
+
if (selectedValue && onSelect) onSelect(selectedValue);
|
|
45
|
+
});
|
|
46
|
+
});
|
|
63
47
|
}
|
|
64
|
-
|
|
48
|
+
|
|
49
|
+
//#endregion
|
|
50
|
+
export { initDropdown };
|
package/dist/components/sdk.d.ts
CHANGED
|
@@ -1,78 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
export type PropertyModelContextType = {
|
|
5
|
-
modelPath?: string;
|
|
6
|
-
propertyPath?: string;
|
|
7
|
-
};
|
|
8
|
-
export declare const PropertyModelContext: React.Context<PropertyModelContextType>;
|
|
9
|
-
export declare function usePropertyModel(): PropertyModelContextType;
|
|
10
|
-
export type ReferenceNestingContextType = string[];
|
|
11
|
-
export declare const ReferenceNestingContext: React.Context<ReferenceNestingContextType>;
|
|
12
|
-
export declare function useReferenceNesting(): ReferenceNestingContextType;
|
|
13
|
-
export type SDKSnippetLanguagesType = Record<SDKJSON.SnippetLanguage, {
|
|
14
|
-
name: string;
|
|
15
|
-
icon: string;
|
|
16
|
-
}>;
|
|
17
|
-
export declare const SDKSnippetLanguages: SDKSnippetLanguagesType;
|
|
18
|
-
export type TransformRequestSnippetFn = ({ snippet, language, }: {
|
|
19
|
-
snippet: string;
|
|
20
|
-
language: DocsLanguage;
|
|
21
|
-
}) => string;
|
|
22
|
-
type SDKChildrenProps = {
|
|
23
|
-
paths: SDKJSON.ID[];
|
|
24
|
-
expand?: boolean;
|
|
25
|
-
depth?: number;
|
|
26
|
-
};
|
|
27
|
-
export declare function SDKChildren({ paths, expand, depth }: SDKChildrenProps): import("react/jsx-runtime").JSX.Element;
|
|
28
|
-
type SDKDeclarationProps = {
|
|
29
|
-
path: string;
|
|
30
|
-
expand?: boolean;
|
|
31
|
-
depth?: number;
|
|
32
|
-
};
|
|
33
|
-
export declare function SDKDeclaration({ path, expand, depth }: SDKDeclarationProps): import("react/jsx-runtime").JSX.Element | null;
|
|
34
|
-
export type SDKConstraintsProps = {
|
|
35
|
-
constraints?: Record<string, any>;
|
|
36
|
-
};
|
|
37
|
-
export declare function SDKConstraints({ constraints }: SDKConstraintsProps): import("react/jsx-runtime").JSX.Element | undefined;
|
|
38
|
-
type SDKIconProps = {
|
|
39
|
-
language: SDKJSON.SnippetLanguage;
|
|
40
|
-
size?: number;
|
|
41
|
-
};
|
|
42
|
-
export declare function SDKIcon({ language }: SDKIconProps): import("react/jsx-runtime").JSX.Element | null;
|
|
43
|
-
export type SDKRequestTitleProps = {
|
|
44
|
-
snippetLanguage: SDKJSON.SnippetLanguage;
|
|
45
|
-
};
|
|
46
|
-
export declare function SDKRequestTitle({ snippetLanguage }: SDKRequestTitleProps): import("react/jsx-runtime").JSX.Element;
|
|
47
|
-
type SDKExampleProps = {
|
|
48
|
-
method: SDKJSON.Method;
|
|
49
|
-
transformRequestSnippet?: TransformRequestSnippetFn;
|
|
50
|
-
};
|
|
51
|
-
export declare function SDKExample({ method, transformRequestSnippet }: SDKExampleProps): import("react/jsx-runtime").JSX.Element;
|
|
52
|
-
export type SDKMethodProps = {
|
|
53
|
-
method: SDKJSON.Method;
|
|
54
|
-
transformRequestSnippet?: TransformRequestSnippetFn;
|
|
55
|
-
};
|
|
56
|
-
export declare function SDKMethodHeader({ method }: SDKMethodProps): import("react/jsx-runtime").JSX.Element;
|
|
57
|
-
export declare function SDKMethodInfo({ method }: SDKMethodProps): import("react/jsx-runtime").JSX.Element;
|
|
58
|
-
export declare function SDKMethod({ method, transformRequestSnippet }: SDKMethodProps): import("react/jsx-runtime").JSX.Element | undefined;
|
|
59
|
-
export type SDKModelProps = {
|
|
60
|
-
model: SDKJSON.Model;
|
|
61
|
-
};
|
|
62
|
-
export declare function SDKModel({ model }: SDKModelProps): import("react/jsx-runtime").JSX.Element | null;
|
|
63
|
-
type SDKReferenceProps = {
|
|
64
|
-
stainlessPath: string;
|
|
65
|
-
children?: React.ReactNode;
|
|
66
|
-
};
|
|
67
|
-
export declare function SDKReference({ stainlessPath, children }: SDKReferenceProps): string | number | bigint | boolean | import("react/jsx-runtime").JSX.Element | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | null | undefined;
|
|
68
|
-
type SDKLanguageBlockProps = {
|
|
69
|
-
language: DocsLanguage;
|
|
70
|
-
version: string;
|
|
71
|
-
install: string;
|
|
72
|
-
links: {
|
|
73
|
-
repo: string;
|
|
74
|
-
docs: string;
|
|
75
|
-
};
|
|
76
|
-
};
|
|
77
|
-
export declare function SDKLanguageBlock({ language, version, install, links }: SDKLanguageBlockProps): import("react/jsx-runtime").JSX.Element;
|
|
78
|
-
export {};
|
|
1
|
+
import "../routing-qc0V00-j.js";
|
|
2
|
+
import { C as TransformRequestSnippetFn, S as SDKSnippetLanguagesType, T as useReferenceNesting, _ as SDKModelProps, a as SDKChildren, b as SDKRequestTitleProps, c as SDKDeclaration, d as SDKLanguageBlock, f as SDKMethod, g as SDKModel, h as SDKMethodProps, i as ReferenceNestingContextType, l as SDKExample, m as SDKMethodInfo, n as PropertyModelContextType, o as SDKConstraints, p as SDKMethodHeader, r as ReferenceNestingContext, s as SDKConstraintsProps, t as PropertyModelContext, u as SDKIcon, v as SDKReference, w as usePropertyModel, x as SDKSnippetLanguages, y as SDKRequestTitle } from "../sdk-Zg3Rggk3.js";
|
|
3
|
+
export { PropertyModelContext, PropertyModelContextType, ReferenceNestingContext, ReferenceNestingContextType, SDKChildren, SDKConstraints, SDKConstraintsProps, SDKDeclaration, SDKExample, SDKIcon, SDKLanguageBlock, SDKMethod, SDKMethodHeader, SDKMethodInfo, SDKMethodProps, SDKModel, SDKModelProps, SDKReference, SDKRequestTitle, SDKRequestTitleProps, SDKSnippetLanguages, SDKSnippetLanguagesType, TransformRequestSnippetFn, usePropertyModel, useReferenceNesting };
|
package/dist/components/sdk.js
CHANGED
|
@@ -1,153 +1,16 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export
|
|
17
|
-
return React.useContext(ReferenceNestingContext);
|
|
18
|
-
}
|
|
19
|
-
export const SDKSnippetLanguages = {
|
|
20
|
-
'node.default': { name: 'TypeScript', icon: 'typescript' },
|
|
21
|
-
'typescript.default': { name: 'TypeScript', icon: 'typescript' },
|
|
22
|
-
'python.default': { name: 'Python', icon: 'python' },
|
|
23
|
-
'go.default': { name: 'Go', icon: 'go' },
|
|
24
|
-
'java.default': { name: 'Java', icon: 'java' },
|
|
25
|
-
'kotlin.default': { name: 'Kotlin', icon: 'kotlin' },
|
|
26
|
-
'http.curl': { name: 'cURL', icon: 'http' },
|
|
27
|
-
'http.powershell': { name: 'Powershell', icon: 'powershell' },
|
|
28
|
-
'terraform.default': { name: 'Terraform', icon: 'terraform' },
|
|
29
|
-
'ruby.default': { name: 'Ruby', icon: 'ruby' },
|
|
30
|
-
};
|
|
31
|
-
export function SDKChildren({ paths, expand, depth }) {
|
|
32
|
-
const Docs = useComponents();
|
|
33
|
-
return (_jsx("div", { className: style.Properties, children: paths.map((path, i) => (_jsx(Docs.SDKDeclaration, { path: path, expand: expand, depth: depth }, i))) }));
|
|
34
|
-
}
|
|
35
|
-
export function SDKDeclaration({ path, expand, depth = 0 }) {
|
|
36
|
-
const Lang = useLanguageComponents();
|
|
37
|
-
const Docs = useComponents();
|
|
38
|
-
const decl = useDeclaration(path);
|
|
39
|
-
const settings = useSettings();
|
|
40
|
-
const model = usePropertyModel();
|
|
41
|
-
const nesting = useReferenceNesting();
|
|
42
|
-
const { selectedPath } = useNavigation();
|
|
43
|
-
if (!decl)
|
|
44
|
-
return null;
|
|
45
|
-
if (decl.kind.endsWith('Reference')) {
|
|
46
|
-
const refId = decl['type']['$ref'];
|
|
47
|
-
if (refId && refId !== path && !nesting.includes(refId)) {
|
|
48
|
-
return (_jsx(ReferenceNestingContext.Provider, { value: [...nesting, refId], children: _jsx(SDKDeclaration, { path: refId, expand: expand, depth: depth }) }));
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
const isUnion = 'childrenParentSchema' in decl && ['enum', 'union'].includes(decl.childrenParentSchema);
|
|
52
|
-
const id = model?.propertyPath ? `${model.propertyPath} + ${path}` : path;
|
|
53
|
-
const shouldExpand = (selectedPath.startsWith(path) && nesting.length < 1) ||
|
|
54
|
-
(settings.properties?.expandDepth && depth <= settings.properties?.expandDepth && !isUnion) ||
|
|
55
|
-
expand;
|
|
56
|
-
const content = (_jsx(Lang.Property, { decl: decl, children: ({ ...props }) => (_jsx(Docs.Property, { id: id, expand: shouldExpand, constraints: decl['constraints'] && _jsx(Docs.SDKConstraints, { constraints: decl['constraints'] }), declaration: _jsx(Lang.Declaration, { decl: decl }), description: decl['docstring'], deprecated: decl.deprecated, ...props, children: 'children' in decl &&
|
|
57
|
-
decl.children.length > 0 &&
|
|
58
|
-
(settings.properties?.includeModelProperties !== false || !('modelPath' in decl)) && (_jsxs(_Fragment, { children: [isUnion && _jsx("div", { className: style.PropertyAnnotation, children: "Accepts one of the following:" }), _jsx(Docs.SDKChildren, { paths: decl.children, depth: depth + 1 })] })) })) }));
|
|
59
|
-
if ('modelPath' in decl) {
|
|
60
|
-
const value = { modelPath: decl.modelPath, propertyPath: decl.stainlessPath };
|
|
61
|
-
return _jsx(PropertyModelContext.Provider, { value: value, children: content });
|
|
62
|
-
}
|
|
63
|
-
return content;
|
|
64
|
-
}
|
|
65
|
-
export function SDKConstraints({ constraints }) {
|
|
66
|
-
if (constraints)
|
|
67
|
-
return (_jsx("div", { className: style.PropertyConstraints, children: Object.entries(constraints).map(([name, value]) => (_jsxs("div", { className: style.PropertyConstraint, children: [_jsx("span", { className: style.PropertyConstraintName, children: name }), _jsx("span", { className: style.PropertyConstraintValue, children: value })] }, name))) }));
|
|
68
|
-
}
|
|
69
|
-
const snippetIcons = {
|
|
70
|
-
'node.default': TypescriptIcon,
|
|
71
|
-
'typescript.default': TypescriptIcon,
|
|
72
|
-
'go.default': GoIcon,
|
|
73
|
-
'python.default': PythonIcon,
|
|
74
|
-
'terraform.default': TerraformIcon,
|
|
75
|
-
'http.curl': CurlIcon,
|
|
76
|
-
'http.powershell': PowershellIcon,
|
|
77
|
-
'ruby.default': RubyIcon,
|
|
78
|
-
'java.default': JavaIcon,
|
|
79
|
-
'kotlin.default': KotlinIcon,
|
|
80
|
-
};
|
|
81
|
-
export function SDKIcon({ language }) {
|
|
82
|
-
const LangIcon = snippetIcons[language];
|
|
83
|
-
if (!LangIcon)
|
|
84
|
-
return null;
|
|
85
|
-
return _jsx(LangIcon, { className: clsx(style.Icon, language.split('.').shift()) });
|
|
86
|
-
}
|
|
87
|
-
export function SDKRequestTitle({ snippetLanguage }) {
|
|
88
|
-
const languageName = SDKSnippetLanguages[snippetLanguage]?.name;
|
|
89
|
-
return (_jsxs("span", { className: style.SnippetRequestTitleLanguage, children: [_jsx(SDKIcon, { language: snippetLanguage }), " ", languageName] }));
|
|
90
|
-
}
|
|
91
|
-
export function SDKExample({ method, transformRequestSnippet }) {
|
|
92
|
-
// TODO: support language variants in snippets
|
|
93
|
-
const Docs = useComponents();
|
|
94
|
-
const language = useLanguage();
|
|
95
|
-
const snippetLanguage = getLanguageSnippet(language);
|
|
96
|
-
return (_jsx(Docs.Snippet, { requestTitle: _jsx(Docs.SDKRequestTitle, { snippetLanguage: snippetLanguage }), method: method, transformRequestSnippet: transformRequestSnippet }));
|
|
97
|
-
}
|
|
98
|
-
export function SDKMethodHeader({ method }) {
|
|
99
|
-
const Docs = useComponents();
|
|
100
|
-
const Lang = useLanguageComponents();
|
|
101
|
-
const decl = useDeclaration(method.stainlessPath);
|
|
102
|
-
return (_jsx(Docs.MethodHeader, { level: "h1", title: method.summary ?? method.title, signature: _jsx(Lang.MethodSignature, { decl: decl }), badges: method.deprecated && _jsx(Docs.Badge, { id: "deprecated", children: "Deprecated" }), children: _jsx(Docs.MethodRoute, { httpMethod: method.httpMethod, endpoint: method.endpoint.split(' ', 2).at(-1) }) }));
|
|
103
|
-
}
|
|
104
|
-
export function SDKMethodInfo({ method }) {
|
|
105
|
-
const Docs = useComponents();
|
|
106
|
-
const Lang = useLanguageComponents();
|
|
107
|
-
const decl = useDeclaration(method.stainlessPath);
|
|
108
|
-
const spec = useSpec();
|
|
109
|
-
const language = useLanguage();
|
|
110
|
-
if (Lang.MethodInfo)
|
|
111
|
-
return _jsx(Lang.MethodInfo, { decl: decl });
|
|
112
|
-
function shouldExpand(items) {
|
|
113
|
-
if (items.length > 1)
|
|
114
|
-
return false;
|
|
115
|
-
const decl = spec?.decls?.[language]?.[items[0]];
|
|
116
|
-
return decl && 'children' in decl && decl.children.length > 0;
|
|
117
|
-
}
|
|
118
|
-
return (_jsx(Docs.MethodInfo, { parameters: 'paramsChildren' in decl &&
|
|
119
|
-
Array.isArray(decl.paramsChildren) &&
|
|
120
|
-
decl.paramsChildren.length > 0 && (_jsx(Docs.SDKChildren, { expand: shouldExpand(decl.paramsChildren), paths: decl.paramsChildren })), returns: 'responseChildren' in decl &&
|
|
121
|
-
decl.responseChildren.length > 0 && (_jsx(Docs.SDKChildren, { expand: shouldExpand(decl.responseChildren), paths: decl.responseChildren })) }));
|
|
122
|
-
}
|
|
123
|
-
export function SDKMethod({ method, transformRequestSnippet }) {
|
|
124
|
-
const Docs = useComponents();
|
|
125
|
-
const decl = useDeclaration(method?.stainlessPath);
|
|
126
|
-
const layout = useContentPanelLayout();
|
|
127
|
-
if (!decl)
|
|
128
|
-
return;
|
|
129
|
-
return (_jsxs(Docs.Method, { id: method.stainlessPath, header: _jsx(Docs.SDKMethodHeader, { method: method }), className: clsx({
|
|
130
|
-
[style.MethodSinglePane]: layout === 'single-pane',
|
|
131
|
-
[style.MethodDoublePane]: layout === 'double-pane',
|
|
132
|
-
}), children: [_jsxs("div", { className: style.MethodContentColumn, children: [_jsx(Docs.MethodDescription, { description: method.description }), _jsx(Docs.SDKMethodInfo, { method: method })] }), _jsx("div", { className: style.MethodExample + ' not-content', children: _jsx(Docs.SDKExample, { method: method, transformRequestSnippet: transformRequestSnippet }) }), _jsxs("div", { className: style.MethodResponseColumn, children: [_jsx("h5", { children: "Returns Examples" }), _jsx(Docs.SnippetResponse, { responses: method.exampleResponses })] })] }));
|
|
133
|
-
}
|
|
134
|
-
export function SDKModel({ model }) {
|
|
135
|
-
const Docs = useComponents();
|
|
136
|
-
const decl = useDeclaration(`${model.stainlessPath} > (schema)`);
|
|
137
|
-
if (!decl)
|
|
138
|
-
return null;
|
|
139
|
-
return (_jsx("div", { className: style.Model, tabIndex: 0, children: _jsx("div", { className: style.ResourceContentProperties, children: _jsx(Docs.SDKDeclaration, { path: `${model.stainlessPath} > (schema)` }) }) }));
|
|
140
|
-
}
|
|
141
|
-
export function SDKReference({ stainlessPath, children }) {
|
|
142
|
-
const Docs = useComponents();
|
|
143
|
-
if (!stainlessPath || !stainlessPath.endsWith('(schema)'))
|
|
144
|
-
return children;
|
|
145
|
-
const link = (_jsx("span", { className: style.TypeReference, children: _jsx(Docs.Link, { stainlessPath: stainlessPath, children: children }) }));
|
|
146
|
-
return link;
|
|
147
|
-
}
|
|
148
|
-
export function SDKLanguageBlock({ language, version, install, links }) {
|
|
149
|
-
const Docs = useComponents();
|
|
150
|
-
const lang = `${language}.default`;
|
|
151
|
-
return (_jsxs("div", { className: style.LanguageBlock, children: [_jsxs("div", { className: style.LanguageBlockContent, children: [_jsx("div", { className: style.LanguageBlockContentIcon, children: _jsx(Docs.SDKIcon, { language: lang, size: 24 }) }), _jsxs("div", { className: style.LanguageBlockContentInfo, children: [_jsx("div", { className: style.LanguageBlockContentInfoLanguage, children: Docs.SDKSnippetLanguages[lang].name }), _jsx("div", { className: style.LanguageBlockContentInfoVersion, children: version })] })] }), _jsxs("div", { className: style.LanguageBlockInstall, "data-stldocs-copy-parent": true, children: [_jsx("pre", { "data-stldocs-copy-content": true, children: install }), ' ', _jsx(Button, { variant: "ghost", size: "sm", "data-stldocs-snippet-copy": true, children: _jsx(Copy, { size: 16, className: style.Icon }) })] }), _jsxs("div", { className: style.LanguageBlockLinks, children: [_jsx(Button, { href: links.repo, variant: "outline", children: _jsx(Button.Icon, { icon: Github }) }), _jsxs(Button, { href: links.docs, variant: "outline", children: [_jsx(Button.Icon, { icon: BookOpen }), _jsx(Button.Label, { children: "Read Docs" })] })] })] }));
|
|
152
|
-
}
|
|
153
|
-
//# sourceMappingURL=sdk.js.map
|
|
1
|
+
import "../component-generics-DzI21jRn.js";
|
|
2
|
+
import "../docs-Dh8kE1va.js";
|
|
3
|
+
import "../navigation-aoYZ_tl4.js";
|
|
4
|
+
import "../markdown-BXfX1D7C.js";
|
|
5
|
+
import "../routing-DQjbRxdJ.js";
|
|
6
|
+
import "../style-rYbbxIR_.js";
|
|
7
|
+
import "../use-components-D9E85p5x.js";
|
|
8
|
+
import { At as SDKRequestTitle, Ct as SDKIcon, Dt as SDKMethodInfo, Et as SDKMethodHeader, Mt as usePropertyModel, Nt as useReferenceNesting, Ot as SDKModel, St as SDKExample, Tt as SDKMethod, _t as PropertyModelContext, bt as SDKConstraints, jt as SDKSnippetLanguages, kt as SDKReference, vt as ReferenceNestingContext, wt as SDKLanguageBlock, xt as SDKDeclaration, yt as SDKChildren } from "../contexts-DRxRO-xO.js";
|
|
9
|
+
import "../icons-DdKM-01E.js";
|
|
10
|
+
import "../utils-CJfFBNgT.js";
|
|
11
|
+
import "../dropdown-DtgAi6lb.js";
|
|
12
|
+
import "../md-Dg8aOyMA.js";
|
|
13
|
+
import "../utils-BHwvUDKn.js";
|
|
14
|
+
import "../types-DFN4M1Sp.js";
|
|
15
|
+
|
|
16
|
+
export { PropertyModelContext, ReferenceNestingContext, SDKChildren, SDKConstraints, SDKDeclaration, SDKExample, SDKIcon, SDKLanguageBlock, SDKMethod, SDKMethodHeader, SDKMethodInfo, SDKModel, SDKReference, SDKRequestTitle, SDKSnippetLanguages, usePropertyModel, useReferenceNesting };
|
|
@@ -1,22 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
type SidebarExpanderProps = {
|
|
4
|
-
open?: boolean;
|
|
5
|
-
summary: React.ReactNode;
|
|
6
|
-
children?: React.ReactNode;
|
|
7
|
-
};
|
|
8
|
-
export declare function SidebarExpander({ open, summary, children }: SidebarExpanderProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
-
export type SidebarMethodProps = {
|
|
10
|
-
method: SDKJSON.Method;
|
|
11
|
-
};
|
|
12
|
-
export declare function SidebarMethod({ method }: SidebarMethodProps): import("react/jsx-runtime").JSX.Element;
|
|
13
|
-
export type SidebarResourceProps = {
|
|
14
|
-
resource: SDKJSON.Resource;
|
|
15
|
-
};
|
|
16
|
-
export declare function SidebarResource({ resource }: SidebarResourceProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
-
export type SidebarProps = {
|
|
18
|
-
resources: SDKJSON.Resource[];
|
|
19
|
-
selectedPath?: string;
|
|
20
|
-
};
|
|
21
|
-
export declare function Sidebar({ resources }: SidebarProps): import("react/jsx-runtime").JSX.Element;
|
|
22
|
-
export {};
|
|
1
|
+
import { a as SidebarProps, i as SidebarMethodProps, n as SidebarExpander, o as SidebarResource, r as SidebarMethod, s as SidebarResourceProps, t as Sidebar } from "../sidebar-C8KirYjg.js";
|
|
2
|
+
export { Sidebar, SidebarExpander, SidebarMethod, SidebarMethodProps, SidebarProps, SidebarResource, SidebarResourceProps };
|
|
@@ -1,30 +1,16 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
export
|
|
17
|
-
const Docs = useComponents();
|
|
18
|
-
const { selectedPath } = useNavigation();
|
|
19
|
-
const subresources = Object.values(resource.subresources ?? {}).map((sub) => (_jsx(SidebarResource, { resource: sub }, sub.stainlessPath)));
|
|
20
|
-
const methods = Object.values(resource.methods).map((method) => (_jsx(SidebarMethod, { method: method }, method.stainlessPath)));
|
|
21
|
-
const hasChildren = subresources.length > 0 || methods.length > 0;
|
|
22
|
-
const title = (_jsx("div", { className: style.SidebarResourceTitle, children: _jsx(Docs.Link, { stainlessPath: resource.stainlessPath, children: resource.title }) }));
|
|
23
|
-
return (_jsx("div", { className: style.SidebarResource, "data-selected": resource.stainlessPath === selectedPath, children: hasChildren ? (_jsxs(SidebarExpander, { summary: title, open: true, children: [methods, subresources] })) : (title) }));
|
|
24
|
-
}
|
|
25
|
-
export function Sidebar({ resources }) {
|
|
26
|
-
return (_jsx("div", { className: `${style.Root} ${style.Sidebar}`, children: resources
|
|
27
|
-
.filter((resource) => !isResourceEmpty(resource))
|
|
28
|
-
.map((resource) => (_jsx(SidebarResource, { resource: resource }, resource.stainlessPath))) }));
|
|
29
|
-
}
|
|
30
|
-
//# sourceMappingURL=sidebar.js.map
|
|
1
|
+
import "../component-generics-DzI21jRn.js";
|
|
2
|
+
import "../docs-Dh8kE1va.js";
|
|
3
|
+
import "../navigation-aoYZ_tl4.js";
|
|
4
|
+
import "../markdown-BXfX1D7C.js";
|
|
5
|
+
import "../routing-DQjbRxdJ.js";
|
|
6
|
+
import "../style-rYbbxIR_.js";
|
|
7
|
+
import "../use-components-D9E85p5x.js";
|
|
8
|
+
import { at as SidebarResource, it as SidebarMethod, nt as Sidebar, rt as SidebarExpander } from "../contexts-DRxRO-xO.js";
|
|
9
|
+
import "../icons-DdKM-01E.js";
|
|
10
|
+
import "../utils-CJfFBNgT.js";
|
|
11
|
+
import "../dropdown-DtgAi6lb.js";
|
|
12
|
+
import "../md-Dg8aOyMA.js";
|
|
13
|
+
import "../utils-BHwvUDKn.js";
|
|
14
|
+
import "../types-DFN4M1Sp.js";
|
|
15
|
+
|
|
16
|
+
export { Sidebar, SidebarExpander, SidebarMethod, SidebarResource };
|
|
@@ -1,28 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
export
|
|
5
|
-
content: string;
|
|
6
|
-
signature?: string;
|
|
7
|
-
language?: string;
|
|
8
|
-
};
|
|
9
|
-
export declare function SnippetCode({ content, language }: SnippetCodeProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
-
export type SnippetProps = {
|
|
11
|
-
method: SDKJSON.Method;
|
|
12
|
-
requestTitle?: React.ReactNode;
|
|
13
|
-
transformRequestSnippet?: TransformRequestSnippetFn;
|
|
14
|
-
};
|
|
15
|
-
export type SnippetContainerProps = {
|
|
16
|
-
children: React.ReactNode;
|
|
17
|
-
signature?: string;
|
|
18
|
-
};
|
|
19
|
-
export declare function SnippetContainer({ children }: SnippetContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
20
|
-
export type SnippetRequestContainerProps = {
|
|
21
|
-
children?: React.ReactNode;
|
|
22
|
-
signature?: string;
|
|
23
|
-
};
|
|
24
|
-
export declare function SnippetRequestContainer({ children }: SnippetRequestContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
25
|
-
export declare function Snippet({ requestTitle, method, transformRequestSnippet }: SnippetProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
-
export declare function SnippetResponse({ responses }: {
|
|
27
|
-
responses: SDKJSON.Method['exampleResponses'];
|
|
28
|
-
}): import("react/jsx-runtime").JSX.Element | null;
|
|
1
|
+
import "../routing-qc0V00-j.js";
|
|
2
|
+
import "../sdk-Zg3Rggk3.js";
|
|
3
|
+
import { a as SnippetContainerProps, c as SnippetRequestContainerProps, i as SnippetContainer, l as SnippetResponse, n as SnippetCode, o as SnippetProps, r as SnippetCodeProps, s as SnippetRequestContainer, t as Snippet } from "../snippets-EUzM4fRO.js";
|
|
4
|
+
export { Snippet, SnippetCode, SnippetCodeProps, SnippetContainer, SnippetContainerProps, SnippetProps, SnippetRequestContainer, SnippetRequestContainerProps, SnippetResponse };
|