Skip to content

Commit 6677cd1

Browse files
yunkon-kimgithub-actions[bot]
authored andcommitted
Update swagger-ui to v5.30.2
1 parent dc1733d commit 6677cd1

10 files changed

+11
-192
lines changed

dist/oauth2-redirect.html

Lines changed: 1 addition & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -1,79 +1,6 @@
11
<!doctype html>
22
<html lang="en-US">
3-
<head>
4-
<title>Swagger UI: OAuth2 Redirect</title>
5-
</head>
63
<body>
7-
<script>
8-
'use strict';
9-
function run () {
10-
var oauth2 = window.opener.swaggerUIRedirectOauth2;
11-
var sentState = oauth2.state;
12-
var redirectUrl = oauth2.redirectUrl;
13-
var isValid, qp, arr;
14-
15-
if (/code|token|error/.test(window.location.hash)) {
16-
qp = window.location.hash.substring(1).replace('?', '&');
17-
} else {
18-
qp = location.search.substring(1);
19-
}
20-
21-
arr = qp.split("&");
22-
arr.forEach(function (v,i,_arr) { _arr[i] = '"' + v.replace('=', '":"') + '"';});
23-
qp = qp ? JSON.parse('{' + arr.join() + '}',
24-
function (key, value) {
25-
return key === "" ? value : decodeURIComponent(value);
26-
}
27-
) : {};
28-
29-
isValid = qp.state === sentState;
30-
31-
if ((
32-
oauth2.auth.schema.get("flow") === "accessCode" ||
33-
oauth2.auth.schema.get("flow") === "authorizationCode" ||
34-
oauth2.auth.schema.get("flow") === "authorization_code"
35-
) && !oauth2.auth.code) {
36-
if (!isValid) {
37-
oauth2.errCb({
38-
authId: oauth2.auth.name,
39-
source: "auth",
40-
level: "warning",
41-
message: "Authorization may be unsafe, passed state was changed in server. The passed state wasn't returned from auth server."
42-
});
43-
}
44-
45-
if (qp.code) {
46-
delete oauth2.state;
47-
oauth2.auth.code = qp.code;
48-
oauth2.callback({auth: oauth2.auth, redirectUrl: redirectUrl});
49-
} else {
50-
let oauthErrorMsg;
51-
if (qp.error) {
52-
oauthErrorMsg = "["+qp.error+"]: " +
53-
(qp.error_description ? qp.error_description+ ". " : "no accessCode received from the server. ") +
54-
(qp.error_uri ? "More info: "+qp.error_uri : "");
55-
}
56-
57-
oauth2.errCb({
58-
authId: oauth2.auth.name,
59-
source: "auth",
60-
level: "error",
61-
message: oauthErrorMsg || "[Authorization failed]: no accessCode received from the server."
62-
});
63-
}
64-
} else {
65-
oauth2.callback({auth: oauth2.auth, token: qp, isValid: isValid, redirectUrl: redirectUrl});
66-
}
67-
window.close();
68-
}
69-
70-
if (document.readyState !== 'loading') {
71-
run();
72-
} else {
73-
document.addEventListener('DOMContentLoaded', function () {
74-
run();
75-
});
76-
}
77-
</script>
4+
<script src="oauth2-redirect.js"></script>
785
</body>
796
</html>

dist/oauth2-redirect.js

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/swagger-ui-bundle.js

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

dist/swagger-ui-es-bundle-core.js

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

dist/swagger-ui-es-bundle.js

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

dist/swagger-ui-standalone-preset.js

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

dist/swagger-ui.css

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

dist/swagger-ui.js

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

index.html

Lines changed: 2 additions & 111 deletions
Original file line numberDiff line numberDiff line change
@@ -3,126 +3,17 @@
33
<html lang="en">
44
<head>
55
<meta charset="UTF-8">
6-
<meta name="viewport" content="width=device-width, initial-scale=1.0">
7-
<title>Cloud-Barista API Documentation Hub</title>
8-
<meta name="description" content="Centralized API documentation portal for Cloud-Barista ecosystem projects">
9-
<meta name="keywords" content="Cloud-Barista, API, Documentation, Swagger, Multi-cloud">
6+
<title>Swagger UI</title>
107
<link rel="stylesheet" type="text/css" href="dist/swagger-ui.css" />
118
<link rel="stylesheet" type="text/css" href="dist/index.css" />
129
<link rel="icon" type="image/png" href="dist/favicon-32x32.png" sizes="32x32" />
1310
<link rel="icon" type="image/png" href="dist/favicon-16x16.png" sizes="16x16" />
14-
15-
<style>
16-
#readme-content {
17-
margin: 20px auto;
18-
max-width: 1200px;
19-
padding: 0 20px;
20-
display: none;
21-
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
22-
line-height: 1.6;
23-
}
24-
25-
#readme-content h1 {
26-
border-bottom: 2px solid #e1e4e8;
27-
padding-bottom: 10px;
28-
}
29-
30-
#readme-content h2 {
31-
border-bottom: 1px solid #e1e4e8;
32-
padding-bottom: 8px;
33-
margin-top: 32px;
34-
}
35-
36-
#readme-content h3 {
37-
margin-top: 24px;
38-
margin-bottom: 16px;
39-
}
40-
41-
#readme-content blockquote {
42-
border-left: 4px solid #dfe2e5;
43-
padding-left: 16px;
44-
margin-left: 0;
45-
color: #6a737d;
46-
font-style: italic;
47-
}
48-
49-
#readme-content code {
50-
background-color: rgba(27,31,35,0.05);
51-
border-radius: 3px;
52-
font-size: 85%;
53-
margin: 0;
54-
padding: 0.2em 0.4em;
55-
}
56-
57-
#readme-content a {
58-
color: #0366d6;
59-
text-decoration: none;
60-
}
61-
62-
#readme-content a:hover {
63-
text-decoration: underline;
64-
}
65-
66-
#readme-content ul, #readme-content ol {
67-
padding-left: 30px;
68-
}
69-
70-
#readme-content li {
71-
margin-bottom: 4px;
72-
}
73-
</style>
7411
</head>
7512

7613
<body>
7714
<div id="swagger-ui"></div>
78-
<div id="readme-content"></div>
79-
8015
<script src="dist/swagger-ui-bundle.js" charset="UTF-8"> </script>
8116
<script src="dist/swagger-ui-standalone-preset.js" charset="UTF-8"> </script>
82-
<script src="https://cdn.jsdelivr.net/npm/marked/marked.min.js"> </script>
83-
<script>
84-
85-
function getUrlParameter(name) {
86-
name = name.replace(/[\[]/, '\\[').replace(/[\]]/, '\\]');
87-
var regex = new RegExp('[\\?&]' + name + '=([^&#]*)');
88-
var results = regex.exec(location.search);
89-
return results === null ? '' : decodeURIComponent(results[1].replace(/\+/g, ' '));
90-
}
91-
92-
function fetchReadme(url) {
93-
fetch(url)
94-
.then(response => response.text())
95-
.then(text => {
96-
document.getElementById('readme-content').style.display = 'block';
97-
document.getElementById('readme-content').innerHTML = marked.parse(text);
98-
})
99-
.catch(error => console.error('Error fetching README:', error));
100-
}
101-
102-
var swaggerUrl = getUrlParameter('url');
103-
104-
if (!swaggerUrl) {
105-
document.getElementById('readme-content').style.display = 'block';
106-
fetchReadme('https://raw.githubusercontent.com/cloud-barista/api/main/README.md');
107-
} else {
108-
const ui = SwaggerUIBundle({
109-
url: swaggerUrl,
110-
dom_id: '#swagger-ui',
111-
deepLinking: true,
112-
tagsSorter: "alpha",
113-
operationsSorter: "alpha",
114-
presets: [
115-
SwaggerUIBundle.presets.apis,
116-
SwaggerUIStandalonePreset
117-
],
118-
plugins: [
119-
SwaggerUIBundle.plugins.DownloadUrl
120-
],
121-
layout: "StandaloneLayout"
122-
});
123-
124-
window.ui = ui;
125-
}
126-
</script>
17+
<script src="dist/swagger-initializer.js" charset="UTF-8"> </script>
12718
</body>
12819
</html>

swagger-ui.version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v5.28.1
1+
v5.30.2

0 commit comments

Comments
 (0)