"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.getSerializedValue=exports.Examples=void 0;const jsx_runtime_1=require("react/jsx-runtime"),common_1=require("../common"),utils_1=require("../../utils"),styled_1=require("./styled");function Examples({field:e}){return e.examples?(0,jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment,{children:[(0,jsx_runtime_1.jsx)(common_1.FieldLabel,{children:" 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.jsxs)(styled_1.ExampleDescription,{children:[i," "]}),(0,jsx_runtime_1.jsx)(common_1.ExampleValue,{children:getSerializedValue(e,s.value)})]},r)}))})]}):null}function getSerializedValue(e,r){return e.in?decodeURIComponent((0,utils_1.serializeParameterValue)(e,r)):r}exports.Examples=Examples,exports.getSerializedValue=getSerializedValue;
//# sourceMappingURL=Examples.js.map