@redocly/openapi-docs 3.10.0-next.3 → 3.10.0-next.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/redocly-openapi-docs.min.js +252 -252
- package/lib/components/PropertyDetails/Examples.js +1 -1
- package/lib/components/PropertyDetails/styled.d.ts +0 -1
- package/lib/components/PropertyDetails/styled.js +2 -2
- package/lib/hooks/useOtelTelemetry.d.ts +1 -1
- package/lib-esm/components/PropertyDetails/Examples.js +1 -1
- package/lib-esm/components/PropertyDetails/styled.d.ts +0 -1
- package/lib-esm/components/PropertyDetails/styled.js +1 -1
- package/lib-esm/hooks/useOtelTelemetry.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.Examples=Examples,exports.getSerializedValue=getSerializedValue;const jsx_runtime_1=require("react/jsx-runtime"),common_1=require("../common"),utils_1=require("../../utils"),styled_1=require("./styled"),hooks_1=require("../../hooks");function Examples({field:e}){const
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.Examples=Examples,exports.getSerializedValue=getSerializedValue;const jsx_runtime_1=require("react/jsx-runtime"),common_1=require("../common"),utils_1=require("../../utils"),styled_1=require("./styled"),hooks_1=require("../../hooks"),Markdown_1=require("../Markdown");function Examples({field:e}){const r=(0,hooks_1.useTranslate)();return e.examples?(0,jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment,{children:[(0,jsx_runtime_1.jsxs)(common_1.FieldLabel,{children:[" ",r("openapi.examples","Examples"),": "]}),(0,jsx_runtime_1.jsx)(styled_1.ExamplesList,{children:Object.entries(e.examples).map((([r,s])=>{const i=(0,utils_1.normalizeText)(s.description);return(0,jsx_runtime_1.jsxs)(styled_1.ExampleWrap,{children:[(0,jsx_runtime_1.jsxs)(styled_1.ExampleSummary,{children:[(0,utils_1.normalizeText)(s.summary)||r," "]}),i&&(0,jsx_runtime_1.jsx)(Markdown_1.Markdown,{source:i}),(0,jsx_runtime_1.jsx)(common_1.ExampleValue,{children:getSerializedValue(e,s.value)})]},r)}))})]}):null}function getSerializedValue(e,r){return e.in?(0,utils_1.tryDecodeURIComponent)((0,utils_1.serializeParameterValue)(e,r)):r}
|
|
2
2
|
//# sourceMappingURL=Examples.js.map
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export declare const DescriptionEnumsBlock: import("styled-components").StyledComponent<"main", any, import("@redocly/theme").MarkdownProps, never>;
|
|
2
2
|
export declare const TypeWrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
3
|
-
export declare const ExampleDescription: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
4
3
|
export declare const ExampleSummary: import("styled-components").StyledComponent<"label", any, {}, never>;
|
|
5
4
|
export declare const ExampleWrap: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
6
5
|
export declare const ExamplesList: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
"use strict";var __importDefault=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(exports,"__esModule",{value:!0}),exports.FieldDescriptionWrapper=exports.ExamplesList=exports.ExampleWrap=exports.ExampleSummary=exports.
|
|
1
|
+
"use strict";var __importDefault=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(exports,"__esModule",{value:!0}),exports.FieldDescriptionWrapper=exports.ExamplesList=exports.ExampleWrap=exports.ExampleSummary=exports.TypeWrapper=exports.DescriptionEnumsBlock=void 0;const styled_components_1=__importDefault(require("styled-components")),theme_1=require("@redocly/theme");exports.DescriptionEnumsBlock=(0,styled_components_1.default)(theme_1.Markdown)`
|
|
2
2
|
table.md {
|
|
3
3
|
margin: var(--spacing-xs) 0 0;
|
|
4
4
|
}
|
|
5
5
|
`,exports.TypeWrapper=styled_components_1.default.div`
|
|
6
6
|
line-height: 20px;
|
|
7
|
-
`,exports.
|
|
7
|
+
`,exports.ExampleSummary=styled_components_1.default.label`
|
|
8
8
|
display: block;
|
|
9
9
|
font-size: inherit;
|
|
10
10
|
margin-bottom: 0.2em;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare function useOtelTelemetry(): {
|
|
2
|
-
send(action: "error" | "page.viewed" | "search.ai.query" | "search.query" | "search.result.clicked" | "openapi_docs.viewed" | "openapi_docs.performance_metrics" | "openapi_docs.download_definition.clicked" | "openapi_docs.select_language.clicked" | "openapi_docs.expand_collapse_all.clicked" | "openapi_docs.copy_code_snippet.clicked" | "openapi_docs.switch_servers.clicked" | "openapi_docs.examples_switcher.clicked" | "openapi_docs.try_it.opened" | "asyncapi_docs.performance_metrics" | "asyncapi_docs.viewed" | "asyncapi_docs.switch_message.clicked" | "asyncapi_docs.switch_example.clicked" | "asyncapi_docs.message.clicked", data: unknown): void;
|
|
2
|
+
send(action: "error" | "page.viewed" | "search.ai.query" | "search.query" | "feedback.sent" | "search.result.clicked" | "openapi_docs.viewed" | "openapi_docs.performance_metrics" | "openapi_docs.download_definition.clicked" | "openapi_docs.select_language.clicked" | "openapi_docs.expand_collapse_all.clicked" | "openapi_docs.copy_code_snippet.clicked" | "openapi_docs.switch_servers.clicked" | "openapi_docs.examples_switcher.clicked" | "openapi_docs.try_it.opened" | "asyncapi_docs.performance_metrics" | "asyncapi_docs.viewed" | "asyncapi_docs.switch_message.clicked" | "asyncapi_docs.switch_example.clicked" | "asyncapi_docs.message.clicked", data: unknown): void;
|
|
3
3
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsxs as _jsxs,jsx as _jsx,Fragment as _Fragment}from"react/jsx-runtime";import{ExampleValue,FieldLabel}from"../common";import{tryDecodeURIComponent,normalizeText,serializeParameterValue}from"../../utils";import{ExampleWrap,ExamplesList,ExampleSummary
|
|
1
|
+
import{jsxs as _jsxs,jsx as _jsx,Fragment as _Fragment}from"react/jsx-runtime";import{ExampleValue,FieldLabel}from"../common";import{tryDecodeURIComponent,normalizeText,serializeParameterValue}from"../../utils";import{ExampleWrap,ExamplesList,ExampleSummary}from"./styled";import{useTranslate}from"../../hooks";import{Markdown}from"../Markdown";export function Examples({field:e}){const r=useTranslate();return e.examples?_jsxs(_Fragment,{children:[_jsxs(FieldLabel,{children:[" ",r("openapi.examples","Examples"),": "]}),_jsx(ExamplesList,{children:Object.entries(e.examples).map((([r,a])=>{const m=normalizeText(a.description);return _jsxs(ExampleWrap,{children:[_jsxs(ExampleSummary,{children:[normalizeText(a.summary)||r," "]}),m&&_jsx(Markdown,{source:m}),_jsx(ExampleValue,{children:getSerializedValue(e,a.value)})]},r)}))})]}):null}export function getSerializedValue(e,r){return e.in?tryDecodeURIComponent(serializeParameterValue(e,r)):r}
|
|
2
2
|
//# sourceMappingURL=Examples.js.map
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export declare const DescriptionEnumsBlock: import("styled-components").StyledComponent<"main", any, import("@redocly/theme").MarkdownProps, never>;
|
|
2
2
|
export declare const TypeWrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
3
|
-
export declare const ExampleDescription: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
4
3
|
export declare const ExampleSummary: import("styled-components").StyledComponent<"label", any, {}, never>;
|
|
5
4
|
export declare const ExampleWrap: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
6
5
|
export declare const ExamplesList: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
@@ -4,7 +4,7 @@ import styled from"styled-components";import{Markdown as MarkdownWrapper}from"@r
|
|
|
4
4
|
}
|
|
5
5
|
`;export const TypeWrapper=styled.div`
|
|
6
6
|
line-height: 20px;
|
|
7
|
-
`;export const
|
|
7
|
+
`;export const ExampleSummary=styled.label`
|
|
8
8
|
display: block;
|
|
9
9
|
font-size: inherit;
|
|
10
10
|
margin-bottom: 0.2em;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export declare function useOtelTelemetry(): {
|
|
2
|
-
send(action: "error" | "page.viewed" | "search.ai.query" | "search.query" | "search.result.clicked" | "openapi_docs.viewed" | "openapi_docs.performance_metrics" | "openapi_docs.download_definition.clicked" | "openapi_docs.select_language.clicked" | "openapi_docs.expand_collapse_all.clicked" | "openapi_docs.copy_code_snippet.clicked" | "openapi_docs.switch_servers.clicked" | "openapi_docs.examples_switcher.clicked" | "openapi_docs.try_it.opened" | "asyncapi_docs.performance_metrics" | "asyncapi_docs.viewed" | "asyncapi_docs.switch_message.clicked" | "asyncapi_docs.switch_example.clicked" | "asyncapi_docs.message.clicked", data: unknown): void;
|
|
2
|
+
send(action: "error" | "page.viewed" | "search.ai.query" | "search.query" | "feedback.sent" | "search.result.clicked" | "openapi_docs.viewed" | "openapi_docs.performance_metrics" | "openapi_docs.download_definition.clicked" | "openapi_docs.select_language.clicked" | "openapi_docs.expand_collapse_all.clicked" | "openapi_docs.copy_code_snippet.clicked" | "openapi_docs.switch_servers.clicked" | "openapi_docs.examples_switcher.clicked" | "openapi_docs.try_it.opened" | "asyncapi_docs.performance_metrics" | "asyncapi_docs.viewed" | "asyncapi_docs.switch_message.clicked" | "asyncapi_docs.switch_example.clicked" | "asyncapi_docs.message.clicked", data: unknown): void;
|
|
3
3
|
};
|