Skip to content

Commit bcfd827

Browse files
committed
fixed extra spacing between status-codes, array type representation in object tree
1 parent 59ae5f6 commit bcfd827

File tree

14 files changed

+215
-38
lines changed

14 files changed

+215
-38
lines changed

dist/index.html

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
<!doctype html>
2+
<html lang="en">
3+
4+
<head>
5+
<meta name="viewport" content="width=device-width, minimum-scale=1, initial-scale=1, user-scalable=yes">
6+
<title>RapiPdf</title>
7+
</head>
8+
9+
<body>
10+
<!--
11+
Some sample spec to try
12+
http://10.21.83.83:8080/api/swagger.json
13+
https://api.apis.guru/v2/specs/stripe.com/2019-08-14/swagger.json
14+
https://api.apis.guru/v2/specs/github.com/v3/swagger.json
15+
https://api.apis.guru/v2/specs/bitbucket.org/2.0/swagger.json
16+
https://petstore.swagger.io/v2/swagger.json
17+
https://assets.zuora.com/zuora-documentation/swagger.yaml <<< Large spec with lot of markdown
18+
-->
19+
20+
<!--
21+
<rapi-pdf id='rapipdf' spec-url="./examples/specs/test.json" include-info="false" include-security="false" include-toc="false"> </rapi-pdf>
22+
-->
23+
<rapi-pdf id='rapipdf' spec-url="./examples/specs/petstore.json"> </rapi-pdf>
24+
25+
26+
<button onclick="changeSpec()">Change Spec</button>
27+
<script type="text/javascript">
28+
function changeSpec(){
29+
let el = document.getElementById("rapipdf");
30+
el.setAttribute('spec-url', 'set new attrib');
31+
}
32+
</script>
33+
34+
35+
<script type="text/javascript" src="rapipdf-min.js"></script></body>
36+
37+
</html>

dist/index.html.gz

585 Bytes
Binary file not shown.

dist/rapipdf-min.js

Lines changed: 55 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/rapipdf-min.js.gz

1.04 MB
Binary file not shown.

dist/rapipdf-min.js.map

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/rapipdf-min.js.map.gz

150 Bytes
Binary file not shown.

dist/report.html

Lines changed: 67 additions & 0 deletions
Large diffs are not rendered by default.

docs/rapipdf-min.js

Lines changed: 10 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/specs/basic.json

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,31 @@
4545
"type": "object",
4646
"additionalProperties": false,
4747
"properties": {
48-
"empId" : { "type": "string", "description": "Employee ID"},
49-
"firstName" : { "type": "string", "description": "First name" },
50-
"lastName" : { "type": "string", "description": "Last Name" },
51-
"jobTitle" : { "type": "string", "description": "Job title" },
52-
"department": { "type": "string", "description": "Department name"},
53-
"salary" : { "type": "number", "description": "Salary per annum"}
48+
"name": { "type": "string"},
49+
"age": { "type": "integer"},
50+
"departments" : {
51+
"type": "array",
52+
"items": {
53+
"type": "string"
54+
}
55+
},
56+
"tags" : {
57+
"type": "array",
58+
"items": {
59+
"$ref": "#/definitions/department"
60+
}
61+
}
62+
}
63+
},
64+
"department": {
65+
"description": "Employee Details",
66+
"type": "object",
67+
"additionalProperties": false,
68+
"properties": {
69+
"deptId": { "type": "integer"},
70+
"name": { "type": "string"}
5471
}
5572
}
73+
5674
}
5775
}

package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "rapipdf",
3-
"version": "1.2.0",
3+
"version": "2.0.0",
44
"description": "RapiPdf - Generate PDF from Open API spec",
55
"author": "Mrinmoy Majumdar <[email protected]>",
66
"repository": {
@@ -21,7 +21,9 @@
2121
"rapipdf",
2222
"swagger",
2323
"swagger ui",
24-
"pdf"
24+
"pdf",
25+
"swagger pdf",
26+
"openapi pdf"
2527
],
2628
"main": "rapipdf.js",
2729
"module": "rapipdf.js",

0 commit comments

Comments
 (0)