docusaurus-theme-openapi-docs 1.1.7 → 1.1.10

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.
Files changed (34) hide show
  1. package/lib/theme/ApiDemoPanel/Body/index.js +11 -1
  2. package/lib/theme/ApiDemoPanel/CodeTabs/styles.module.css +7 -1
  3. package/lib/theme/ApiDemoPanel/Curl/index.js +80 -22
  4. package/lib/theme/ApiDemoPanel/Curl/languages.json +1386 -0
  5. package/lib/theme/ApiItem/Layout/styles.module.css +120 -20
  6. package/lib/theme/ResponseSamples/index.js +2 -2
  7. package/lib-next/theme/ApiDemoPanel/Body/index.js +10 -1
  8. package/lib-next/theme/ApiDemoPanel/CodeTabs/styles.module.css +7 -1
  9. package/lib-next/theme/ApiDemoPanel/Curl/index.js +85 -17
  10. package/lib-next/theme/ApiDemoPanel/Curl/languages.json +1386 -0
  11. package/lib-next/theme/ApiItem/Layout/styles.module.css +120 -20
  12. package/lib-next/theme/ResponseSamples/index.js +2 -2
  13. package/package.json +6 -5
  14. package/src/theme/ApiDemoPanel/Body/index.tsx +10 -1
  15. package/src/theme/ApiDemoPanel/CodeTabs/styles.module.css +7 -1
  16. package/src/theme/ApiDemoPanel/Curl/index.tsx +89 -22
  17. package/src/theme/ApiDemoPanel/Curl/languages.json +1386 -0
  18. package/src/theme/ApiItem/Layout/styles.module.css +120 -20
  19. package/src/theme/ResponseSamples/index.js +2 -2
  20. package/lib/theme/ApiItem/Layout/icons/bash-original.svg +0 -1
  21. package/lib/theme/ApiItem/Layout/icons/go-original-wordmark.svg +0 -1
  22. package/lib/theme/ApiItem/Layout/icons/javascript-original.svg +0 -1
  23. package/lib/theme/ApiItem/Layout/icons/linux-original.svg +0 -1
  24. package/lib/theme/ApiItem/Layout/icons/python-original.svg +0 -1
  25. package/lib-next/theme/ApiItem/Layout/icons/bash-original.svg +0 -1
  26. package/lib-next/theme/ApiItem/Layout/icons/go-original-wordmark.svg +0 -1
  27. package/lib-next/theme/ApiItem/Layout/icons/javascript-original.svg +0 -1
  28. package/lib-next/theme/ApiItem/Layout/icons/linux-original.svg +0 -1
  29. package/lib-next/theme/ApiItem/Layout/icons/python-original.svg +0 -1
  30. package/src/theme/ApiItem/Layout/icons/bash-original.svg +0 -1
  31. package/src/theme/ApiItem/Layout/icons/go-original-wordmark.svg +0 -1
  32. package/src/theme/ApiItem/Layout/icons/javascript-original.svg +0 -1
  33. package/src/theme/ApiItem/Layout/icons/linux-original.svg +0 -1
  34. package/src/theme/ApiItem/Layout/icons/python-original.svg +0 -1
@@ -73,6 +73,8 @@
73
73
 
74
74
  :global(.theme-api-markdown code) {
75
75
  max-width: 600px;
76
+ max-height: 500px;
77
+ overflow: auto;
76
78
  }
77
79
 
78
80
  @media (min-width: 997px) {
@@ -159,18 +161,20 @@
159
161
  padding-left: 2px;
160
162
  }
161
163
 
164
+ /* CodeTabs */
165
+
162
166
  :global(.code__tab--python::after) {
163
167
  content: "";
164
- width: 32px;
165
- height: 32px;
166
- background: url(./icons/python-original.svg);
168
+ width: 28px;
169
+ height: 28px;
170
+ background: url("https://raw.githubusercontent.com/devicons/devicon/master/icons/python/python-original.svg");
167
171
  margin-block: auto;
168
172
  }
169
173
 
170
174
  :global(.code__tab--python) {
171
175
  color: var(--ifm-color-success);
172
- padding-left: 2rem;
173
- padding-right: 2rem;
176
+ padding-left: 1.4rem;
177
+ padding-right: 1.4rem;
174
178
  }
175
179
 
176
180
  :global(.code__tab--python.tabs__item--active) {
@@ -185,16 +189,16 @@
185
189
 
186
190
  :global(.code__tab--go::after) {
187
191
  content: "";
188
- width: 32px;
189
- height: 32px;
190
- background: url(./icons/go-original-wordmark.svg);
192
+ width: 28px;
193
+ height: 28px;
194
+ background: url("https://raw.githubusercontent.com/devicons/devicon/master/icons/go/go-original-wordmark.svg");
191
195
  margin-block: auto;
192
196
  }
193
197
 
194
198
  :global(.code__tab--go) {
195
199
  color: var(--ifm-color-info);
196
- padding-left: 2rem;
197
- padding-right: 2rem;
200
+ padding-left: 1.4rem;
201
+ padding-right: 1.4rem;
198
202
  }
199
203
 
200
204
  :global(.code__tab--go.tabs__item--active) {
@@ -209,16 +213,16 @@
209
213
 
210
214
  :global(.code__tab--javascript::after) {
211
215
  content: "";
212
- width: 32px;
213
- height: 32px;
214
- background: url(./icons/javascript-original.svg);
216
+ width: 28px;
217
+ height: 28px;
218
+ background: url("https://raw.githubusercontent.com/devicons/devicon/master/icons/javascript/javascript-original.svg");
215
219
  margin-block: auto;
216
220
  }
217
221
 
218
222
  :global(.code__tab--javascript) {
219
223
  color: var(--ifm-color-warning);
220
- padding-left: 2rem;
221
- padding-right: 2rem;
224
+ padding-left: 1.4rem;
225
+ padding-right: 1.4rem;
222
226
  }
223
227
 
224
228
  :global(.code__tab--javascript.tabs__item--active) {
@@ -233,16 +237,16 @@
233
237
 
234
238
  :global(.code__tab--bash::after) {
235
239
  content: "";
236
- width: 32px;
237
- height: 32px;
238
- background: url(./icons/linux-original.svg);
240
+ width: 28px;
241
+ height: 28px;
242
+ background: url("https://raw.githubusercontent.com/devicons/devicon/master/icons/linux/linux-original.svg");
239
243
  margin-block: auto;
240
244
  }
241
245
 
242
246
  :global(.code__tab--bash) {
243
247
  color: var(--ifm-color-danger);
244
- padding-left: 2rem;
245
- padding-right: 2rem;
248
+ padding-left: 1.4rem;
249
+ padding-right: 1.4rem;
246
250
  }
247
251
 
248
252
  :global(.code__tab--bash.tabs__item--active) {
@@ -254,3 +258,99 @@
254
258
  max-height: 500px;
255
259
  overflow: auto;
256
260
  }
261
+
262
+ :global(.code__tab--ruby::after) {
263
+ content: "";
264
+ width: 28px;
265
+ height: 28px;
266
+ background: url("https://raw.githubusercontent.com/devicons/devicon/master/icons/ruby/ruby-plain.svg");
267
+ margin-block: auto;
268
+ }
269
+
270
+ :global(.code__tab--ruby) {
271
+ color: var(--ifm-color-danger);
272
+ padding-left: 1.4rem;
273
+ padding-right: 1.4rem;
274
+ }
275
+
276
+ :global(.code__tab--ruby.tabs__item--active) {
277
+ border-bottom-color: var(--ifm-color-danger);
278
+ background-color: var(--ifm-color-emphasis-100);
279
+ }
280
+
281
+ :global(.language-ruby) {
282
+ max-height: 500px;
283
+ overflow: auto;
284
+ }
285
+
286
+ :global(.code__tab--csharp::after) {
287
+ content: "";
288
+ width: 28px;
289
+ height: 28px;
290
+ background: url("https://raw.githubusercontent.com/devicons/devicon/master/icons/csharp/csharp-original.svg");
291
+ margin-block: auto;
292
+ }
293
+
294
+ :global(.code__tab--csharp) {
295
+ color: var(--ifm-color-gray-500);
296
+ padding-left: 1.4rem;
297
+ padding-right: 1.4rem;
298
+ }
299
+
300
+ :global(.code__tab--csharp.tabs__item--active) {
301
+ border-bottom-color: var(--ifm-color-gray-500);
302
+ background-color: var(--ifm-color-emphasis-100);
303
+ }
304
+
305
+ :global(.language-csharp) {
306
+ max-height: 500px;
307
+ overflow: auto;
308
+ }
309
+
310
+ :global(.code__tab--nodejs::after) {
311
+ content: "";
312
+ width: 28px;
313
+ height: 28px;
314
+ background: url("https://raw.githubusercontent.com/devicons/devicon/master/icons/nodejs/nodejs-original.svg");
315
+ margin-block: auto;
316
+ }
317
+
318
+ :global(.code__tab--nodejs) {
319
+ color: var(--ifm-color-success);
320
+ padding-left: 1.4rem;
321
+ padding-right: 1.4rem;
322
+ }
323
+
324
+ :global(.code__tab--nodejs.tabs__item--active) {
325
+ border-bottom-color: var(--ifm-color-success);
326
+ background-color: var(--ifm-color-emphasis-100);
327
+ }
328
+
329
+ :global(.language-nodejs) {
330
+ max-height: 500px;
331
+ overflow: auto;
332
+ }
333
+
334
+ :global(.code__tab--php::after) {
335
+ content: "";
336
+ width: 28px;
337
+ height: 28px;
338
+ background: url("https://raw.githubusercontent.com/devicons/devicon/master/icons/php/php-original.svg");
339
+ margin-block: auto;
340
+ }
341
+
342
+ :global(.code__tab--php) {
343
+ color: var(--ifm-color-gray-500);
344
+ padding-left: 1.4rem;
345
+ padding-right: 1.4rem;
346
+ }
347
+
348
+ :global(.code__tab--php.tabs__item--active) {
349
+ border-bottom-color: var(--ifm-color-gray-500);
350
+ background-color: var(--ifm-color-emphasis-100);
351
+ }
352
+
353
+ :global(.language-php) {
354
+ max-height: 500px;
355
+ overflow: auto;
356
+ }
@@ -11,11 +11,11 @@ import CodeBlock from "@theme/CodeBlock";
11
11
 
12
12
  import styles from "./styles.module.css";
13
13
 
14
- function ResponseSamples({ responseExample }) {
14
+ function ResponseSamples({ responseExample, language }) {
15
15
  return (
16
16
  <div className={styles.responseSamplesContainer}>
17
17
  <CodeBlock
18
- language="javascript"
18
+ language={language ? language : "json"}
19
19
  className={styles.responseSamplesCodeBlock}
20
20
  >
21
21
  {responseExample}
@@ -1 +0,0 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128"><path fill="none" d="M4.24 4.24h119.53v119.53H4.24z"/><path fill="#293138" d="M109.01 28.64L71.28 6.24c-2.25-1.33-4.77-2-7.28-2s-5.03.67-7.28 2.01l-37.74 22.4c-4.5 2.67-7.28 7.61-7.28 12.96v44.8c0 5.35 2.77 10.29 7.28 12.96l37.73 22.4c2.25 1.34 4.76 2 7.28 2 2.51 0 5.03-.67 7.28-2l37.74-22.4c4.5-2.67 7.28-7.62 7.28-12.96V41.6c0-5.34-2.77-10.29-7.28-12.96zM79.79 98.59l.06 3.22c0 .39-.25.83-.55.99l-1.91 1.1c-.3.15-.56-.03-.56-.42l-.03-3.17c-1.63.68-3.29.84-4.34.42-.2-.08-.29-.37-.21-.71l.69-2.91c.06-.23.18-.46.34-.6.06-.06.12-.1.18-.13.11-.06.22-.07.31-.03 1.14.38 2.59.2 3.99-.5 1.78-.9 2.97-2.72 2.95-4.52-.02-1.64-.9-2.31-3.05-2.33-2.74.01-5.3-.53-5.34-4.57-.03-3.32 1.69-6.78 4.43-8.96l-.03-3.25c0-.4.24-.84.55-1l1.85-1.18c.3-.15.56.04.56.43l.03 3.25c1.36-.54 2.54-.69 3.61-.44.23.06.34.38.24.75l-.72 2.88c-.06.22-.18.44-.33.58a.77.77 0 01-.19.14c-.1.05-.19.06-.28.05-.49-.11-1.65-.36-3.48.56-1.92.97-2.59 2.64-2.58 3.88.02 1.48.77 1.93 3.39 1.97 3.49.06 4.99 1.58 5.03 5.09.05 3.44-1.79 7.15-4.61 9.41zm26.34-60.5l-35.7 22.05c-4.45 2.6-7.73 5.52-7.74 10.89v43.99c0 3.21 1.3 5.29 3.29 5.9-.65.11-1.32.19-1.98.19-2.09 0-4.15-.57-5.96-1.64l-37.73-22.4c-3.69-2.19-5.98-6.28-5.98-10.67V41.6c0-4.39 2.29-8.48 5.98-10.67l37.74-22.4c1.81-1.07 3.87-1.64 5.96-1.64s4.15.57 5.96 1.64l37.74 22.4c3.11 1.85 5.21 5.04 5.8 8.63-1.27-2.67-4.09-3.39-7.38-1.47z"/><path fill="#4FA847" d="M99.12 90.73l-9.4 5.62c-.25.15-.43.31-.43.61v2.46c0 .3.2.43.45.28l9.54-5.8c.25-.15.29-.42.29-.72v-2.17c0-.3-.2-.42-.45-.28z"/></svg>
@@ -1 +0,0 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128"><g fill="#00acd7" fill-rule="evenodd"><path d="M11.156 54.829c-.243 0-.303-.122-.182-.303l1.273-1.637c.12-.182.424-.303.666-.303H34.55c.243 0 .303.182.182.364l-1.03 1.576c-.121.181-.424.363-.606.363zM2.004 60.404c-.242 0-.303-.12-.182-.303l1.273-1.636c.121-.182.424-.303.667-.303h27.636c.242 0 .364.182.303.364l-.485 1.454c-.06.243-.303.364-.545.364zM16.67 65.98c-.242 0-.302-.182-.181-.364l.848-1.515c.122-.182.364-.363.607-.363h12.12c.243 0 .364.181.364.424l-.12 1.454c0 .243-.243.425-.425.425zM79.58 53.738c-3.819.97-6.425 1.697-10.182 2.666-.91.243-.97.303-1.758-.606-.909-1.03-1.576-1.697-2.848-2.303-3.819-1.878-7.516-1.333-10.97.91-4.121 2.666-6.242 6.605-6.182 11.514.06 4.849 3.394 8.849 8.182 9.516 4.121.545 7.576-.91 10.303-4 .545-.667 1.03-1.394 1.636-2.243H56.064c-1.272 0-1.575-.788-1.151-1.818.788-1.879 2.242-5.03 3.09-6.606.183-.364.607-.97 1.516-.97h22.06c-.12 1.637-.12 3.273-.363 4.91-.667 4.363-2.303 8.363-4.97 11.878-4.364 5.758-10.06 9.333-17.273 10.303-5.939.788-11.454-.364-16.302-4-4.485-3.394-7.03-7.879-7.697-13.454-.788-6.606 1.151-12.546 5.151-17.758 4.303-5.636 10-9.212 16.97-10.485 5.697-1.03 11.151-.363 16.06 2.97 3.212 2.121 5.515 5.03 7.03 8.545.364.546.122.849-.606 1.03z"/><path d="M99.64 87.253c-5.515-.122-10.546-1.697-14.788-5.334-3.576-3.09-5.818-7.03-6.545-11.697-1.091-6.848.787-12.909 4.909-18.302 4.424-5.819 9.757-8.849 16.97-10.122 6.181-1.09 12-.484 17.272 3.091 4.788 3.273 7.757 7.697 8.545 13.515 1.03 8.182-1.333 14.849-6.97 20.546-4 4.06-8.909 6.606-14.545 7.757-1.636.303-3.273.364-4.848.546zm14.424-24.485c-.06-.788-.06-1.394-.182-2-1.09-6-6.606-9.394-12.363-8.06-5.637 1.272-9.273 4.848-10.606 10.545-1.091 4.727 1.212 9.515 5.575 11.454 3.334 1.455 6.667 1.273 9.879-.363 4.788-2.485 7.394-6.364 7.697-11.576z" fill-rule="nonzero"/></g></svg>
@@ -1 +0,0 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 128 128"><path fill="#F0DB4F" d="M1.408 1.408h125.184v125.185H1.408z"/><path fill="#323330" d="M116.347 96.736c-.917-5.711-4.641-10.508-15.672-14.981-3.832-1.761-8.104-3.022-9.377-5.926-.452-1.69-.512-2.642-.226-3.665.821-3.32 4.784-4.355 7.925-3.403 2.023.678 3.938 2.237 5.093 4.724 5.402-3.498 5.391-3.475 9.163-5.879-1.381-2.141-2.118-3.129-3.022-4.045-3.249-3.629-7.676-5.498-14.756-5.355l-3.688.477c-3.534.893-6.902 2.748-8.877 5.235-5.926 6.724-4.236 18.492 2.975 23.335 7.104 5.332 17.54 6.545 18.873 11.531 1.297 6.104-4.486 8.08-10.234 7.378-4.236-.881-6.592-3.034-9.139-6.949-4.688 2.713-4.688 2.713-9.508 5.485 1.143 2.499 2.344 3.63 4.26 5.795 9.068 9.198 31.76 8.746 35.83-5.176.165-.478 1.261-3.666.38-8.581zM69.462 58.943H57.753l-.048 30.272c0 6.438.333 12.34-.714 14.149-1.713 3.558-6.152 3.117-8.175 2.427-2.059-1.012-3.106-2.451-4.319-4.485-.333-.584-.583-1.036-.667-1.071l-9.52 5.83c1.583 3.249 3.915 6.069 6.902 7.901 4.462 2.678 10.459 3.499 16.731 2.059 4.082-1.189 7.604-3.652 9.448-7.401 2.666-4.915 2.094-10.864 2.07-17.444.06-10.735.001-21.468.001-32.237z"/></svg>