zudoku 0.34.3 → 0.34.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/lib/plugins/openapi/OperationList.js +9 -6
- package/dist/lib/plugins/openapi/OperationList.js.map +1 -1
- package/dist/vite/plugin-api.js +1 -1
- package/dist/vite/plugin-api.js.map +1 -1
- package/lib/{OasProvider-CR2nG1Eg.js → OasProvider-CDyf845G.js} +2 -2
- package/lib/{OasProvider-CR2nG1Eg.js.map → OasProvider-CDyf845G.js.map} +1 -1
- package/lib/{OperationList-DndcCJUG.js → OperationList-DdCWaqeE.js} +1882 -1869
- package/lib/{OperationList-DndcCJUG.js.map → OperationList-DdCWaqeE.js.map} +1 -1
- package/lib/{index-DK7IuUyR.js → index-BO-sA1cw.js} +3 -3
- package/lib/{index-DK7IuUyR.js.map → index-BO-sA1cw.js.map} +1 -1
- package/lib/zudoku.plugin-openapi.js +1 -1
- package/package.json +1 -1
- package/src/lib/plugins/openapi/OperationList.tsx +20 -6
|
@@ -5,7 +5,7 @@ import "./chunk-HA7DTUK3-ZGg2W6yV.js";
|
|
|
5
5
|
import "./hook-CfCFKZ-2.js";
|
|
6
6
|
import "./ui/Button.js";
|
|
7
7
|
import "./joinUrl-10po2Jdj.js";
|
|
8
|
-
import { U as n, o as s } from "./index-
|
|
8
|
+
import { U as n, o as s } from "./index-BO-sA1cw.js";
|
|
9
9
|
export {
|
|
10
10
|
n as UNTAGGED_PATH,
|
|
11
11
|
s as openApiPlugin
|
package/package.json
CHANGED
|
@@ -147,17 +147,21 @@ export const OperationList = ({
|
|
|
147
147
|
const description = schema.description;
|
|
148
148
|
const navigate = useNavigate();
|
|
149
149
|
const operations = schema.operations;
|
|
150
|
+
const tagDescription = schema.tags.find((t) => t.name === tag)?.description;
|
|
151
|
+
|
|
150
152
|
// Prefetch for Playground
|
|
151
153
|
useApiIdentities();
|
|
152
154
|
|
|
153
155
|
// The summary property is preferable here as it is a short description of
|
|
154
156
|
// the API, whereas the description property is typically longer and supports
|
|
155
157
|
// commonmark formatting, making it ill-suited for use in the meta description
|
|
156
|
-
const metaDescription =
|
|
157
|
-
?
|
|
158
|
-
:
|
|
159
|
-
?
|
|
160
|
-
:
|
|
158
|
+
const metaDescription = tagDescription
|
|
159
|
+
? sanitizeMarkdownForMetatag(tagDescription)
|
|
160
|
+
: summary
|
|
161
|
+
? summary
|
|
162
|
+
: description
|
|
163
|
+
? sanitizeMarkdownForMetatag(description)
|
|
164
|
+
: undefined;
|
|
161
165
|
|
|
162
166
|
const showVersions = Object.entries(versions).length > 1;
|
|
163
167
|
|
|
@@ -168,7 +172,7 @@ export const OperationList = ({
|
|
|
168
172
|
data-pagefind-meta="section:openapi"
|
|
169
173
|
>
|
|
170
174
|
<Helmet>
|
|
171
|
-
<title>{title}</title>
|
|
175
|
+
<title>{[tag, title].filter(Boolean).join(" - ")}</title>
|
|
172
176
|
{metaDescription && (
|
|
173
177
|
<meta name="description" content={metaDescription} />
|
|
174
178
|
)}
|
|
@@ -243,6 +247,16 @@ export const OperationList = ({
|
|
|
243
247
|
</CollapsibleContent>
|
|
244
248
|
)}
|
|
245
249
|
</Collapsible>
|
|
250
|
+
{tagDescription && (
|
|
251
|
+
<p
|
|
252
|
+
className={cn(
|
|
253
|
+
ProseClasses,
|
|
254
|
+
"my-4 max-w-full prose-img:max-w-prose",
|
|
255
|
+
)}
|
|
256
|
+
>
|
|
257
|
+
<Markdown content={tagDescription} />
|
|
258
|
+
</p>
|
|
259
|
+
)}
|
|
246
260
|
</div>
|
|
247
261
|
<hr />
|
|
248
262
|
<div className="my-4 flex items-center justify-end gap-4">
|