Skip to content

Commit 6ee6dcc

Browse files
authored
fix: Update the response openapi explorer component (#2332)
Reported here: https://apify.slack.com/archives/C0L33UM7Z/p1773238202192069 First time working with docs, Im not sure if we commonly do patches of the docusaurus package, but couldn't find better solution. <img width="377" height="143" alt="Screenshot 2026-03-12 at 14 36 34" src="https://github.com/user-attachments/assets/71b9ae41-fba7-4055-ba4b-49bc5a080ba2" />
1 parent 1d3c0ba commit 6ee6dcc

1 file changed

Lines changed: 48 additions & 0 deletions

File tree

patches/docusaurus-theme-openapi-docs+4.7.1.patch

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,54 @@ index f8f722f..ec0c117 100644
7575
onChange: (e) => {
7676
const val = e.target.value;
7777
dispatch(
78+
diff --git a/node_modules/docusaurus-theme-openapi-docs/lib/theme/ApiExplorer/Response/index.js b/node_modules/docusaurus-theme-openapi-docs/lib/theme/ApiExplorer/Response/index.js
79+
index 2f777ec..f3a22a2 100644
80+
--- a/node_modules/docusaurus-theme-openapi-docs/lib/theme/ApiExplorer/Response/index.js
81+
+++ b/node_modules/docusaurus-theme-openapi-docs/lib/theme/ApiExplorer/Response/index.js
82+
@@ -156,12 +156,14 @@ function Response({ item }) {
83+
{
84+
className:
85+
"openapi-explorer__response-placeholder-message",
86+
- },
87+
- (0, Translate_1.translate)({
88+
- id: translationIds_1.OPENAPI_RESPONSE.PLACEHOLDER,
89+
- message:
90+
- "Click the <code>Send API Request</code> button above and see the response here!",
91+
- })
92+
+ dangerouslySetInnerHTML: {
93+
+ __html: (0, Translate_1.translate)({
94+
+ id: translationIds_1.OPENAPI_RESPONSE.PLACEHOLDER,
95+
+ message:
96+
+ "Click the <code>Send API Request</code> button above and see the response here!",
97+
+ }),
98+
+ },
99+
+ }
100+
)
101+
)
102+
),
103+
@@ -200,12 +202,16 @@ function Response({ item }) {
104+
)
105+
: react_1.default.createElement(
106+
"p",
107+
- { className: "openapi-explorer__response-placeholder-message" },
108+
- (0, Translate_1.translate)({
109+
- id: translationIds_1.OPENAPI_RESPONSE.PLACEHOLDER,
110+
- message:
111+
- "Click the <code>Send API Request</code> button above and see the response here!",
112+
- })
113+
+ {
114+
+ className: "openapi-explorer__response-placeholder-message",
115+
+ dangerouslySetInnerHTML: {
116+
+ __html: (0, Translate_1.translate)({
117+
+ id: translationIds_1.OPENAPI_RESPONSE.PLACEHOLDER,
118+
+ message:
119+
+ "Click the <code>Send API Request</code> button above and see the response here!",
120+
+ }),
121+
+ },
122+
+ }
123+
)
124+
)
125+
);
78126
diff --git a/node_modules/docusaurus-theme-openapi-docs/lib/theme/ApiExplorer/buildPostmanRequest.js b/node_modules/docusaurus-theme-openapi-docs/lib/theme/ApiExplorer/buildPostmanRequest.js
79127
index bcebb1c..ac03ec1 100644
80128
--- a/node_modules/docusaurus-theme-openapi-docs/lib/theme/ApiExplorer/buildPostmanRequest.js

0 commit comments

Comments
 (0)