rapidoc 9.1.7 → 9.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 (57) hide show
  1. package/.github/FUNDING.yml +13 -0
  2. package/CONTRIBUTING.md +1 -1
  3. package/LICENSE.txt +3 -1
  4. package/README.md +24 -6
  5. package/index.html +6 -4
  6. package/package.json +16 -16
  7. package/src/components/api-request.js +104 -78
  8. package/src/components/api-response.js +11 -8
  9. package/src/components/dialog-box.js +1 -1
  10. package/src/components/json-tree.js +15 -4
  11. package/src/components/schema-table.js +40 -18
  12. package/src/components/schema-tree.js +44 -15
  13. package/src/components/tag-input.js +1 -1
  14. package/src/json-schema-viewer.js +2 -2
  15. package/src/rapidoc-mini.js +27 -2
  16. package/src/rapidoc.js +41 -3
  17. package/src/styles/border-styles.js +1 -1
  18. package/src/styles/custom-styles.js +1 -1
  19. package/src/styles/dialog-box-styles.js +1 -1
  20. package/src/styles/endpoint-styles.js +10 -10
  21. package/src/styles/flex-styles.js +1 -1
  22. package/src/styles/font-styles.js +1 -1
  23. package/src/styles/info-styles.js +1 -1
  24. package/src/styles/input-styles.js +1 -1
  25. package/src/styles/nav-styles.js +4 -2
  26. package/src/styles/prism-styles.js +1 -1
  27. package/src/styles/schema-styles.js +4 -2
  28. package/src/styles/tab-styles.js +2 -1
  29. package/src/styles/table-styles.js +1 -1
  30. package/src/templates/advance-search-template.js +1 -1
  31. package/src/templates/callback-template.js +11 -4
  32. package/src/templates/code-samples-template.js +2 -2
  33. package/src/templates/components-template.js +4 -2
  34. package/src/templates/endpoint-template.js +23 -16
  35. package/src/templates/expanded-endpoint-template.js +77 -71
  36. package/src/templates/focused-endpoint-template.js +2 -2
  37. package/src/templates/header-template.js +2 -2
  38. package/src/templates/json-schema-viewer-template.js +3 -3
  39. package/src/templates/logo-template.js +1 -1
  40. package/src/templates/main-body-template.js +2 -2
  41. package/src/templates/navbar-template.js +22 -9
  42. package/src/templates/overview-template.js +3 -3
  43. package/src/templates/security-scheme-template.js +54 -44
  44. package/src/templates/server-template.js +4 -4
  45. package/src/utils/schema-utils.js +74 -27
  46. package/src/utils/spec-parser.js +1 -1
  47. package/src/utils/theme.js +12 -5
  48. package/webpack.config.js +1 -1
  49. package/.vscode/settings.json +0 -12
  50. package/dist/index.html +0 -6
  51. package/dist/index.html.gz +0 -0
  52. package/dist/rapidoc-min.js +0 -2
  53. package/dist/rapidoc-min.js.LICENSE.txt +0 -87
  54. package/dist/rapidoc-min.js.LICENSE.txt.gz +0 -0
  55. package/dist/rapidoc-min.js.gz +0 -0
  56. package/dist/rapidoc.js +0 -35243
  57. package/dist/report.html +0 -38
@@ -0,0 +1,13 @@
1
+ # These are supported funding model platforms
2
+
3
+ github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4
+ patreon: # Replace with a single Patreon username
5
+ open_collective: rapidoc
6
+ ko_fi: # Replace with a single Ko-fi username
7
+ tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8
+ community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9
+ liberapay: # Replace with a single Liberapay username
10
+ issuehunt: # Replace with a single IssueHunt username
11
+ otechie: # Replace with a single Otechie username
12
+ lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
13
+ custom: ['paypal.me/mrin'] # Replace with up to 4 custom sponsorship URLs e.g.,
package/CONTRIBUTING.md CHANGED
@@ -22,7 +22,7 @@
22
22
 
23
23
  For development
24
24
  ```shell
25
- git clone https://github.com/mrin9/RapiDoc.git
25
+ git clone https://github.com/rapi-doc/RapiDoc.git
26
26
  yarn install
27
27
  yarn serve
28
28
  # open http://localhost:8080
package/LICENSE.txt CHANGED
@@ -1,5 +1,7 @@
1
1
  MIT License
2
2
 
3
+ Copyright (c) 2022 Mrinmoy Majumdar
4
+
3
5
  Permission is hereby granted, free of charge, to any person obtaining
4
6
  a copy of this software and associated documentation files (the
5
7
  "Software"), to deal in the Software without restriction, including
@@ -17,4 +19,4 @@ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
19
  NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
20
  LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
21
  OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
- WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
package/README.md CHANGED
@@ -1,10 +1,13 @@
1
- <img alt="MrinDoc logo" src="https://github.com/mrin9/RapiDoc/blob/master/logo.png" width="60px" />
1
+ <img alt="MrinDoc logo" src="https://github.com/rapi-doc/RapiDoc/blob/master/logo.png" width="60px" />
2
2
 
3
3
 
4
4
  <p align="center">
5
5
  <img src="https://img.shields.io/badge/license-MIT-blue.svg?style=flat-square"/>
6
- <img src="https://img.shields.io/github/size/mrin9/rapidoc/dist/rapidoc-min.js.svg?colorB=blue&label=minified&style=flat-square">
7
- <img src="https://img.shields.io/github/size/mrin9/rapidoc/dist/rapidoc-min.js.gz.svg?colorB=blue&label=zip&style=flat-square">
6
+ <img src="https://img.shields.io/github/size/rapi-doc/rapidoc/dist/rapidoc-min.js.svg?colorB=blue&label=minified&style=flat-square">
7
+ <img src="https://img.shields.io/github/size/rapi-doc/rapidoc/dist/rapidoc-min.js.gz.svg?colorB=blue&label=zip&style=flat-square">
8
+ <a href="https://discord.gg/X9evUeFY" alt="Join us on Discord">
9
+ <img src="https://img.shields.io/discord/848913990360629268?style=flat-square" />
10
+ </a>
8
11
  <a href="https://www.webcomponents.org/element/rapidoc" alt="published on webcomponents.org">
9
12
  <img src="https://img.shields.io/badge/webcomponents.org-rapidoc-blue.svg?style=social"/>
10
13
  </a>
@@ -13,6 +16,10 @@
13
16
  # RapiDoc
14
17
  Custom Element for Open-API spec viewing
15
18
 
19
+ Join the [RapiDoc community on Discord](https://discord.gg/X9evUeFY)
20
+
21
+ Sponsored by [Zuplo](https://zuplo.link/rapidoc-2) - Get a Stripe-like API experience for your customers in minutes - documentation, rate-limiting and API-key auth in minutes.
22
+
16
23
  ## Features
17
24
  - Supports Swagger 2.0, OpenAPI 3.x.x
18
25
  - Works with any framework or with no framework
@@ -42,10 +49,10 @@ Custom Element for Open-API spec viewing
42
49
 
43
50
 
44
51
  ## Documentation
45
- [Check out the usage and demos](https://mrin9.github.io/RapiDoc/)
52
+ [Check out the usage and demos](https://rapi-doc.github.io/RapiDoc/)
46
53
 
47
54
  ## Examples
48
- [Examples and Test cases](https://mrin9.github.io/RapiDoc/list.html)
55
+ [Examples and Test cases](https://rapi-doc.github.io/RapiDoc/list.html)
49
56
 
50
57
 
51
58
  ## Build Process
@@ -61,4 +68,15 @@ npm run build
61
68
  npm run serve
62
69
  ```
63
70
 
64
- ## Contribution
71
+ ## Roadmap
72
+ - ✅ Upgrade to use `lit 2`
73
+ - Pre Rendering / Server Side Rendering (SSR) of RapiDoc
74
+ - Improve PDF generation of OpenAPI spec Using RapiPDF
75
+ - Create a Command Line interface (CLI) to make it automation friendly
76
+ - Add localization support
77
+ - Follow Web Content Accessibility Guidelines (WCAG 2)
78
+ - Improve Homepage, Documentation and Examples
79
+ - Create groundwork for automated testing
80
+ - Create a live playground (Something like swagger editor)
81
+ - Create a short animation/video to show how RapiDoc/RapiPDF works
82
+
package/index.html CHANGED
@@ -28,24 +28,26 @@
28
28
  https://assets.zuora.com/zuora-documentation/swagger.yaml <<< Large spec with lot of markdown
29
29
  ./specs/petstore_anyof.yaml <<< contains complex one-of with inline primitives and recursive objects
30
30
  ./specs/oneof1.yaml <<< nested oneof
31
+ https://cesdev.eng.sonicwall.com/api/q/openapi
31
32
  -->
32
33
  <rapi-doc
33
- spec-url = "./specs/temp.yaml"
34
+ spec-url = "./specs/data-types.yaml"
34
35
  id="thedoc"
35
36
  theme = "dark"
36
37
  render-style="read"
37
- schema-style="tree"
38
- use-path-in-nav-bar="true"
38
+ schema-style="table"
39
+ show-method-in-nav-bar = "true"
40
+ use-path-in-nav-bar = "true"
39
41
  show-components = "true"
40
42
  show-info = "true"
41
43
  show-header = "true"
42
44
  allow-search = "false"
43
45
  allow-advanced-search = "true"
44
46
  allow-spec-url-load="false"
45
- allow-spec-file-load="false"
46
47
  allow-spec-file-download="true"
47
48
  allow-server-selection = "true"
48
49
  allow-authentication = "true"
50
+ use-summary-to-list-example = "true"
49
51
  update-route="false"
50
52
  match-type="regex"
51
53
  persist-auth="true"
package/package.json CHANGED
@@ -1,11 +1,12 @@
1
1
  {
2
2
  "name": "rapidoc",
3
- "version": "9.1.7",
3
+ "version": "9.3.0",
4
4
  "description": "RapiDoc - Open API spec viewer with built in console",
5
5
  "author": "Mrinmoy Majumdar <mrin9@yahoo.com>",
6
+ "homepage": "https://rapidocweb.com",
6
7
  "repository": {
7
8
  "type": "git",
8
- "url": "https://github.com/mrin9/RapiDoc.git"
9
+ "url": "https://github.com/rapi-doc/RapiDoc.git"
9
10
  },
10
11
  "license": "MIT",
11
12
  "keywords": [
@@ -32,13 +33,12 @@
32
33
  "module": "dist/rapidoc-min.js",
33
34
  "mode": "production",
34
35
  "dependencies": {
35
- "@apitools/openapi-parser": "^0.0.14",
36
+ "@apitools/openapi-parser": "^0.0.24",
36
37
  "base64-arraybuffer": "^1.0.2",
37
38
  "buffer": "^6.0.3",
38
- "lit-element": "2.5.1",
39
- "lit-html": "1.4.1",
40
- "marked": "^4.0.12",
41
- "prismjs": "^1.26.0"
39
+ "lit": "^2.2.4",
40
+ "marked": "^4.0.16",
41
+ "prismjs": "^1.28.0"
42
42
  },
43
43
  "scripts": {
44
44
  "build": "NODE_ENV=production webpack --mode=production",
@@ -50,18 +50,18 @@
50
50
  "lint-fix": "./node_modules/eslint/bin/eslint.js --fix ./src/**"
51
51
  },
52
52
  "devDependencies": {
53
- "@babel/core": "^7.17.5",
53
+ "@babel/core": "^7.18.0",
54
54
  "@babel/eslint-parser": "^7.17.0",
55
- "@babel/preset-env": "^7.16.11",
56
- "babel-loader": "^8.2.3",
55
+ "@babel/preset-env": "^7.18.0",
56
+ "babel-loader": "^8.2.5",
57
57
  "babel-plugin-template-html-minifier": "^4.1.0",
58
58
  "clean-webpack-plugin": "^4.0.0",
59
- "compression-webpack-plugin": "^9.2.0",
60
- "css-loader": "^6.6.0",
61
- "eslint": "^8.9.0",
59
+ "compression-webpack-plugin": "^10.0.0",
60
+ "css-loader": "^6.7.1",
61
+ "eslint": "^8.16.0",
62
62
  "eslint-config-airbnb": "^19.0.4",
63
63
  "eslint-import-resolver-webpack": "^0.13.2",
64
- "eslint-plugin-import": "^2.25.4",
64
+ "eslint-plugin-import": "^2.26.0",
65
65
  "eslint-webpack-plugin": "3.1.1",
66
66
  "file-loader": "^6.2.0",
67
67
  "filemanager-webpack-plugin": "^6.1.7",
@@ -70,10 +70,10 @@
70
70
  "style-loader": "^3.3.1",
71
71
  "terser-webpack-plugin": "^5.3.1",
72
72
  "unminified-webpack-plugin": "^3.0.0",
73
- "webpack": "^5.69.1",
73
+ "webpack": "^5.72.1",
74
74
  "webpack-bundle-analyzer": "^4.5.0",
75
75
  "webpack-cli": "^4.9.2",
76
- "webpack-dev-server": "^4.7.4"
76
+ "webpack-dev-server": "^4.9.0"
77
77
  },
78
78
  "engines": {
79
79
  "node": ">=10.21.0"