apiuikit 1.1.0 → 1.3.0

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 (89) hide show
  1. package/README.md +1 -0
  2. package/dist/CodeSamples-6zm8Tjnl.js +4280 -0
  3. package/dist/CodeSamples-OTh-LQZJ.cjs +50 -0
  4. package/dist/apiuikit.cjs.js +1 -1
  5. package/dist/apiuikit.css +1 -1
  6. package/dist/apiuikit.es.js +30 -22
  7. package/dist/config/config.d.ts +48 -0
  8. package/dist/contexts/useSpec.d.ts +3 -0
  9. package/dist/helpers/jsonPointer.d.ts +5 -0
  10. package/dist/helpers/llmsTxt.d.ts +51 -0
  11. package/dist/helpers/specAdapters.d.ts +32 -0
  12. package/dist/helpers/toMarkdown.d.ts +5 -6
  13. package/dist/hooks/useDocumentProviderValue.d.ts +3 -1
  14. package/dist/{index-EeGvEXPN.cjs → index-B-1zJx9W.cjs} +1 -1
  15. package/dist/{index-B5IBIM-V.cjs → index-BlUAYvlu.cjs} +1 -1
  16. package/dist/{index-DM2MTkYV.js → index-CdicOrT3.js} +1 -1
  17. package/dist/index-DCDYBZcY.js +1461 -0
  18. package/dist/{index-iXpNcBcP.js → index-DNLwvW38.js} +1 -1
  19. package/dist/index-D_7O8w46.cjs +133 -0
  20. package/dist/index-DxCSxdSs.js +13615 -0
  21. package/dist/index-d8kJa7YD.cjs +4 -0
  22. package/dist/index.d.ts +4 -1
  23. package/dist/markdown-assets/protoToJsonSchema-CBPWaboT.js +6193 -0
  24. package/dist/markdown-assets/protoToJsonSchema-CgkcluFJ.js +83 -0
  25. package/dist/markdown.cjs +91 -0
  26. package/dist/markdown.d.ts +8 -0
  27. package/dist/markdown.es.js +2101 -0
  28. package/dist/{protoToJsonSchema-CcEvAEt4.js → protoToJsonSchema-BiGedOci.js} +112 -108
  29. package/dist/{protoToJsonSchema-BNZrP3Fa.cjs → protoToJsonSchema-CXmX3vNq.cjs} +10 -10
  30. package/dist/{protobufSchemaParser-BaWs_7UI.js → protobufSchemaParser-Bq5Fy-MT.js} +2 -2
  31. package/dist/{protobufSchemaParser-7sU6XBEb.cjs → protobufSchemaParser-CsPesPSp.cjs} +1 -1
  32. package/dist/shims/utilInspect.d.ts +2 -0
  33. package/package.json +8 -3
  34. package/dist/components/Navigation/tests/spineTicks.test.d.ts +0 -1
  35. package/dist/components/schema/tests/SchemaTab.test.d.ts +0 -1
  36. package/dist/components/schema/tests/schemaUtils.test.d.ts +0 -1
  37. package/dist/components/tests/Authorization.test.d.ts +0 -1
  38. package/dist/components/tests/Bindings.test.d.ts +0 -1
  39. package/dist/components/tests/ChannelAddress.test.d.ts +0 -1
  40. package/dist/components/tests/CodeBlock.test.d.ts +0 -1
  41. package/dist/components/tests/CodeSamples.test.d.ts +0 -1
  42. package/dist/components/tests/CopyMarkdownButton.test.d.ts +0 -1
  43. package/dist/components/tests/ErrorBoundary.test.d.ts +0 -1
  44. package/dist/components/tests/MarkdownExportMenu.test.d.ts +0 -1
  45. package/dist/components/tests/RenderExtensions.test.d.ts +0 -1
  46. package/dist/containers/AsyncAPI/tests/AsyncAPI.test.d.ts +0 -1
  47. package/dist/containers/AsyncAPI/tests/AsyncAPIErrorBoundary.test.d.ts +0 -1
  48. package/dist/containers/AsyncAPI/tests/AsyncAPIRenderer.test.d.ts +0 -1
  49. package/dist/containers/AsyncAPI/tests/searchHighlight.test.d.ts +0 -1
  50. package/dist/containers/OpenAPI/tests/OpenAPI.test.d.ts +0 -1
  51. package/dist/containers/OpenAPI/tests/OpenAPIErrorBoundary.test.d.ts +0 -1
  52. package/dist/containers/OpenAPI/tests/OpenAPIRenderer.test.d.ts +0 -1
  53. package/dist/containers/Path/tests/PathOperation.test.d.ts +0 -1
  54. package/dist/containers/Path/tests/Paths.test.d.ts +0 -1
  55. package/dist/helpers/avro/tests/avroToJsonSchema.test.d.ts +0 -1
  56. package/dist/helpers/protobuf/tests/protoToJsonSchema.test.d.ts +0 -1
  57. package/dist/helpers/protobuf/tests/protobufSchemaParser.test.d.ts +0 -1
  58. package/dist/helpers/tests/codeSamples.test.d.ts +0 -1
  59. package/dist/helpers/tests/exampleSchema.test.d.ts +0 -1
  60. package/dist/helpers/tests/openapiSearchIndex.test.d.ts +0 -1
  61. package/dist/helpers/tests/resolveDocument.test.d.ts +0 -1
  62. package/dist/helpers/tests/schemaFormat.test.d.ts +0 -1
  63. package/dist/helpers/tests/toMarkdown.test.d.ts +0 -1
  64. package/dist/index-BqogUhNO.js +0 -19011
  65. package/dist/index-mYBY1Eu8.cjs +0 -177
  66. package/dist/public/tests/sections.test.d.ts +0 -1
  67. package/dist/stories/AsyncAPI.stories.d.ts +0 -14
  68. package/dist/stories/AsyncAPIRenderer.stories.d.ts +0 -17
  69. package/dist/stories/Authorization.stories.d.ts +0 -13
  70. package/dist/stories/Bindings.stories.d.ts +0 -12
  71. package/dist/stories/ChannelAddress.stories.d.ts +0 -13
  72. package/dist/stories/CodeBlock.stories.d.ts +0 -11
  73. package/dist/stories/Examples.stories.d.ts +0 -11
  74. package/dist/stories/Information.stories.d.ts +0 -9
  75. package/dist/stories/Message.stories.d.ts +0 -11
  76. package/dist/stories/Messages.stories.d.ts +0 -11
  77. package/dist/stories/Operation.stories.d.ts +0 -10
  78. package/dist/stories/Operations.stories.d.ts +0 -16
  79. package/dist/stories/SchemaTab.stories.d.ts +0 -12
  80. package/dist/stories/SchemaTree.stories.d.ts +0 -24
  81. package/dist/stories/SearchPanel.stories.d.ts +0 -16
  82. package/dist/stories/Server.stories.d.ts +0 -12
  83. package/dist/stories/TabToggle.stories.d.ts +0 -10
  84. package/dist/stories/Tabs.stories.d.ts +0 -11
  85. package/dist/stories/documentContextDecorator.d.ts +0 -25
  86. package/dist/stories/noCanvasDocsPage.d.ts +0 -9
  87. package/dist/utils/tests/hasRef.test.d.ts +0 -1
  88. package/dist/utils/tests/theme.test.d.ts +0 -1
  89. package/dist/utils/tests/useElementRect.test.d.ts +0 -1
@@ -1,5 +1,5 @@
1
- import { protoToJsonSchema as e } from "./protoToJsonSchema-CcEvAEt4.js";
2
- import { r as a, X as t, i as s } from "./index-BqogUhNO.js";
1
+ import { protoToJsonSchema as e } from "./protoToJsonSchema-BiGedOci.js";
2
+ import { r as a, X as t, i as s } from "./index-DxCSxdSs.js";
3
3
  function n(r) {
4
4
  if (typeof r != "string")
5
5
  return ["Protobuf schema must be a string of .proto source"];
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./protoToJsonSchema-BNZrP3Fa.cjs"),e=require("./index-mYBY1Eu8.cjs");function n(r){if(typeof r!="string")return["Protobuf schema must be a string of .proto source"];try{return t.protoToJsonSchema(r),[]}catch(o){return[o instanceof Error?o.message:"Failed to parse protobuf schema"]}}const s=["application/vnd.google.protobuf","application/vnd.google.protobuf;version=2","application/vnd.google.protobuf;version=3"];function a(){return{validate:u,parse:i,getMimeTypes:()=>s}}function c(r){e.registerSchemaParserWithFallback(r,a(),e.isProtobufSchemaFormat)}function u(r){return n(r.data).map(o=>({message:o,path:r.path}))}function i(r){if(typeof r.data!="string")return{[e.X_LIB_CONVERSION_ERROR]:"Protobuf schema must be a string of .proto source"};try{return t.protoToJsonSchema(r.data)}catch(o){return{[e.X_LIB_CONVERSION_ERROR]:o instanceof Error?o.message:"Failed to convert Protobuf schema"}}}exports.ProtobufSchemaParser=a;exports.registerProtobufSchemaParser=c;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./protoToJsonSchema-CXmX3vNq.cjs"),e=require("./index-D_7O8w46.cjs");function n(r){if(typeof r!="string")return["Protobuf schema must be a string of .proto source"];try{return t.protoToJsonSchema(r),[]}catch(o){return[o instanceof Error?o.message:"Failed to parse protobuf schema"]}}const s=["application/vnd.google.protobuf","application/vnd.google.protobuf;version=2","application/vnd.google.protobuf;version=3"];function a(){return{validate:u,parse:i,getMimeTypes:()=>s}}function c(r){e.registerSchemaParserWithFallback(r,a(),e.isProtobufSchemaFormat)}function u(r){return n(r.data).map(o=>({message:o,path:r.path}))}function i(r){if(typeof r.data!="string")return{[e.X_LIB_CONVERSION_ERROR]:"Protobuf schema must be a string of .proto source"};try{return t.protoToJsonSchema(r.data)}catch(o){return{[e.X_LIB_CONVERSION_ERROR]:o instanceof Error?o.message:"Failed to convert Protobuf schema"}}}exports.ProtobufSchemaParser=a;exports.registerProtobufSchemaParser=c;
@@ -0,0 +1,2 @@
1
+ declare const inspect: (value: unknown) => string;
2
+ export default inspect;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "apiuikit",
3
- "version": "1.1.0",
3
+ "version": "1.3.0",
4
4
  "description": "A React UI library for rendering your API specifications",
5
5
  "license": "Apache-2.0",
6
6
  "bugs": {
@@ -24,6 +24,11 @@
24
24
  "import": "./dist/apiuikit.es.js",
25
25
  "require": "./dist/apiuikit.cjs.js"
26
26
  },
27
+ "./markdown": {
28
+ "types": "./dist/markdown.d.ts",
29
+ "import": "./dist/markdown.es.js",
30
+ "require": "./dist/markdown.cjs"
31
+ },
27
32
  "./style.css": "./dist/apiuikit.css"
28
33
  },
29
34
  "files": [
@@ -32,9 +37,9 @@
32
37
  ],
33
38
  "scripts": {
34
39
  "dev": "vite",
35
- "build": "vite build",
40
+ "build": "vite build && vite build --config vite.markdown.config.ts",
36
41
  "watch": "vite build --watch",
37
- "prepublishOnly": "cp ../../README.md ./README.md && vite build",
42
+ "prepublishOnly": "cp ../../README.md ./README.md && npm run build",
38
43
  "typecheck": "node scripts/typecheck.mjs",
39
44
  "typecheck:strict": "tsc -b",
40
45
  "test": "vitest run",
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};