mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 03:41:45 +00:00
Revert "Merge pull request #10902 from nikhiljindal/gh-pages"
This reverts commit 3020fe8ebfbb9ee0a1f76fd9afb09b8d577e420e, reversing changes made to de15703af096cad38d40361d696e236d197895cf.
This commit is contained in:
parent
fbb5ce6636
commit
e1d904ea47
1
third_party/swagger-ui/README.md
vendored
1
third_party/swagger-ui/README.md
vendored
@ -15,6 +15,7 @@ https://github.com/swagger-api/swagger-ui#how-to-use-it
|
||||
## Local Modifications
|
||||
- Updated the url in index.html to "../../swaggerapi" as per instructions at:
|
||||
https://github.com/swagger-api/swagger-ui#how-to-use-it
|
||||
- Modified swagger-ui.js to list resources and operations in sorted order: https://github.com/GoogleCloudPlatform/kubernetes/pull/3421
|
||||
- Set supportedSubmitMethods: [] in index.html to remove "Try it out" buttons.
|
||||
|
||||
LICENSE file has been created for compliance purposes.
|
||||
|
1172
third_party/swagger-ui/css/print.css
vendored
1172
third_party/swagger-ui/css/print.css
vendored
File diff suppressed because it is too large
Load Diff
17
third_party/swagger-ui/css/screen.css
vendored
17
third_party/swagger-ui/css/screen.css
vendored
@ -274,9 +274,6 @@
|
||||
font-weight: bold;
|
||||
font-size: 25px;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap .footer {
|
||||
margin-top: 20px;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap p.big,
|
||||
.swagger-section .swagger-ui-wrap div.big p {
|
||||
font-size: 1em;
|
||||
@ -426,17 +423,6 @@
|
||||
.swagger-section .swagger-ui-wrap .model-signature .description .propWrap .optionsWrapper .optionName {
|
||||
font-weight: bold;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:first-child,
|
||||
.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:last-child {
|
||||
display: inline;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap .model-signature .description .propDesc.markdown > p:not(:first-child):before {
|
||||
display: block;
|
||||
content: '';
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap .model-signature .description span:last-of-type.propDesc.markdown > p:only-child {
|
||||
margin-right: -3px;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap .model-signature .propName {
|
||||
font-weight: bold;
|
||||
}
|
||||
@ -1080,9 +1066,6 @@
|
||||
.swagger-section .swagger-ui-wrap form.form_box p strong {
|
||||
color: black;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap .operation-status td.markdown > p:last-child {
|
||||
padding-bottom: 0;
|
||||
}
|
||||
.swagger-section .title {
|
||||
font-style: bold;
|
||||
}
|
||||
|
250
third_party/swagger-ui/css/style.css
vendored
250
third_party/swagger-ui/css/style.css
vendored
@ -1,250 +0,0 @@
|
||||
.swagger-section #header a#logo {
|
||||
font-size: 1.5em;
|
||||
font-weight: bold;
|
||||
text-decoration: none;
|
||||
background: transparent url(../images/logo.png) no-repeat left center;
|
||||
padding: 20px 0 20px 40px;
|
||||
}
|
||||
#text-head {
|
||||
font-size: 80px;
|
||||
font-family: 'Roboto', sans-serif;
|
||||
color: #ffffff;
|
||||
float: right;
|
||||
margin-right: 20%;
|
||||
}
|
||||
.navbar-fixed-top .navbar-nav {
|
||||
height: auto;
|
||||
}
|
||||
.navbar-fixed-top .navbar-brand {
|
||||
height: auto;
|
||||
}
|
||||
.navbar-header {
|
||||
height: auto;
|
||||
}
|
||||
.navbar-inverse {
|
||||
background-color: #000;
|
||||
border-color: #000;
|
||||
}
|
||||
#navbar-brand {
|
||||
margin-left: 20%;
|
||||
}
|
||||
.navtext {
|
||||
font-size: 10px;
|
||||
}
|
||||
.h1,
|
||||
h1 {
|
||||
font-size: 60px;
|
||||
}
|
||||
.navbar-default .navbar-header .navbar-brand {
|
||||
color: #a2dfee;
|
||||
}
|
||||
/* tag titles */
|
||||
.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a {
|
||||
color: #393939;
|
||||
font-family: 'Arvo', serif;
|
||||
font-size: 1.5em;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 a:hover {
|
||||
color: black;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap ul#resources li.resource div.heading h2 {
|
||||
color: #525252;
|
||||
padding-left: 0px;
|
||||
display: block;
|
||||
clear: none;
|
||||
float: left;
|
||||
font-family: 'Arvo', serif;
|
||||
font-weight: bold;
|
||||
}
|
||||
.navbar-default .navbar-collapse,
|
||||
.navbar-default .navbar-form {
|
||||
border-color: #0A0A0A;
|
||||
}
|
||||
.container1 {
|
||||
width: 1500px;
|
||||
margin: auto;
|
||||
margin-top: 0;
|
||||
background-image: url('../images/shield.png');
|
||||
background-repeat: no-repeat;
|
||||
background-position: -40px -20px;
|
||||
margin-bottom: 210px;
|
||||
}
|
||||
.container-inner {
|
||||
width: 1200px;
|
||||
margin: auto;
|
||||
background-color: rgba(223, 227, 228, 0.75);
|
||||
padding-bottom: 40px;
|
||||
padding-top: 40px;
|
||||
border-radius: 15px;
|
||||
}
|
||||
.header-content {
|
||||
padding: 0;
|
||||
width: 1000px;
|
||||
}
|
||||
.title1 {
|
||||
font-size: 80px;
|
||||
font-family: 'Vollkorn', serif;
|
||||
color: #404040;
|
||||
text-align: center;
|
||||
padding-top: 40px;
|
||||
padding-bottom: 100px;
|
||||
}
|
||||
#icon {
|
||||
margin-top: -18px;
|
||||
}
|
||||
.subtext {
|
||||
font-size: 25px;
|
||||
font-style: italic;
|
||||
color: #08b;
|
||||
text-align: right;
|
||||
padding-right: 250px;
|
||||
}
|
||||
.bg-primary {
|
||||
background-color: #00468b;
|
||||
}
|
||||
.navbar-default .nav > li > a,
|
||||
.navbar-default .nav > li > a:focus {
|
||||
color: #08b;
|
||||
}
|
||||
.navbar-default .nav > li > a,
|
||||
.navbar-default .nav > li > a:hover {
|
||||
color: #08b;
|
||||
}
|
||||
.navbar-default .nav > li > a,
|
||||
.navbar-default .nav > li > a:focus:hover {
|
||||
color: #08b;
|
||||
}
|
||||
.text-faded {
|
||||
font-size: 25px;
|
||||
font-family: 'Vollkorn', serif;
|
||||
}
|
||||
.section-heading {
|
||||
font-family: 'Vollkorn', serif;
|
||||
font-size: 45px;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
hr {
|
||||
border-color: #00468b;
|
||||
padding-bottom: 10px;
|
||||
}
|
||||
.description {
|
||||
margin-top: 20px;
|
||||
padding-bottom: 200px;
|
||||
}
|
||||
.description li {
|
||||
font-family: 'Vollkorn', serif;
|
||||
font-size: 25px;
|
||||
color: #525252;
|
||||
margin-left: 28%;
|
||||
padding-top: 5px;
|
||||
}
|
||||
.gap {
|
||||
margin-top: 200px;
|
||||
}
|
||||
.troubleshootingtext {
|
||||
color: rgba(255, 255, 255, 0.7);
|
||||
padding-left: 30%;
|
||||
}
|
||||
.troubleshootingtext li {
|
||||
list-style-type: circle;
|
||||
font-size: 25px;
|
||||
padding-bottom: 5px;
|
||||
}
|
||||
.overlay {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
z-index: 1000;
|
||||
}
|
||||
.block.response_body.json:hover {
|
||||
cursor: pointer;
|
||||
}
|
||||
.backdrop {
|
||||
color: blue;
|
||||
}
|
||||
#myModal {
|
||||
height: 100%;
|
||||
}
|
||||
.modal-backdrop {
|
||||
bottom: 0;
|
||||
position: fixed;
|
||||
}
|
||||
.curl {
|
||||
padding: 10px;
|
||||
font-family: "Anonymous Pro", "Menlo", "Consolas", "Bitstream Vera Sans Mono", "Courier New", monospace;
|
||||
font-size: 0.9em;
|
||||
max-height: 400px;
|
||||
margin-top: 5px;
|
||||
overflow-y: auto;
|
||||
background-color: #fcf6db;
|
||||
border: 1px solid #e5e0c6;
|
||||
border-radius: 4px;
|
||||
}
|
||||
.curl_title {
|
||||
font-size: 1.1em;
|
||||
margin: 0;
|
||||
padding: 15px 0 5px;
|
||||
font-family: 'Open Sans', 'Helvetica Neue', Arial, sans-serif;
|
||||
font-weight: 500;
|
||||
line-height: 1.1;
|
||||
}
|
||||
.footer {
|
||||
display: none;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap h2 {
|
||||
padding: 0;
|
||||
}
|
||||
h2 {
|
||||
margin: 0;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
.markdown p {
|
||||
font-size: 15px;
|
||||
font-family: 'Arvo', serif;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap .code {
|
||||
font-size: 15px;
|
||||
font-family: 'Arvo', serif;
|
||||
}
|
||||
.swagger-section .swagger-ui-wrap b {
|
||||
font-family: 'Arvo', serif;
|
||||
}
|
||||
#signin:hover {
|
||||
cursor: pointer;
|
||||
}
|
||||
.dropdown-menu {
|
||||
padding: 15px;
|
||||
}
|
||||
.navbar-right .dropdown-menu {
|
||||
left: 0;
|
||||
right: auto;
|
||||
}
|
||||
#signinbutton {
|
||||
width: 100%;
|
||||
height: 32px;
|
||||
font-size: 13px;
|
||||
font-weight: bold;
|
||||
color: #08b;
|
||||
}
|
||||
.navbar-default .nav > li .details {
|
||||
color: #000000;
|
||||
text-transform: none;
|
||||
font-size: 15px;
|
||||
font-weight: normal;
|
||||
font-family: 'Open Sans', sans-serif;
|
||||
font-style: italic;
|
||||
line-height: 20px;
|
||||
top: -2px;
|
||||
}
|
||||
.navbar-default .nav > li .details:hover {
|
||||
color: black;
|
||||
}
|
||||
#signout {
|
||||
width: 100%;
|
||||
height: 32px;
|
||||
font-size: 13px;
|
||||
font-weight: bold;
|
||||
color: #08b;
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
third_party/swagger-ui/images/favicon-16x16.png
vendored
BIN
third_party/swagger-ui/images/favicon-16x16.png
vendored
Binary file not shown.
Before Width: | Height: | Size: 645 B |
BIN
third_party/swagger-ui/images/favicon-32x32.png
vendored
BIN
third_party/swagger-ui/images/favicon-32x32.png
vendored
Binary file not shown.
Before Width: | Height: | Size: 1.6 KiB |
BIN
third_party/swagger-ui/images/favicon.ico
vendored
BIN
third_party/swagger-ui/images/favicon.ico
vendored
Binary file not shown.
Before Width: | Height: | Size: 5.3 KiB |
99
third_party/swagger-ui/index.html
vendored
99
third_party/swagger-ui/index.html
vendored
@ -100,3 +100,102 @@
|
||||
<div id="swagger-ui-container" class="swagger-ui-wrap"></div>
|
||||
</body>
|
||||
</html>
|
||||
=======
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Swagger UI</title>
|
||||
<link href='css/typography.css' media='screen' rel='stylesheet' type='text/css'/>
|
||||
<link href='css/reset.css' media='screen' rel='stylesheet' type='text/css'/>
|
||||
<link href='css/screen.css' media='screen' rel='stylesheet' type='text/css'/>
|
||||
<link href='css/reset.css' media='print' rel='stylesheet' type='text/css'/>
|
||||
<link href='css/screen.css' media='print' rel='stylesheet' type='text/css'/>
|
||||
<script type="text/javascript" src="lib/shred.bundle.js"></script>
|
||||
<script src='lib/jquery-1.8.0.min.js' type='text/javascript'></script>
|
||||
<script src='lib/jquery.slideto.min.js' type='text/javascript'></script>
|
||||
<script src='lib/jquery.wiggle.min.js' type='text/javascript'></script>
|
||||
<script src='lib/jquery.ba-bbq.min.js' type='text/javascript'></script>
|
||||
<script src='lib/handlebars-2.0.0.js' type='text/javascript'></script>
|
||||
<script src='lib/underscore-min.js' type='text/javascript'></script>
|
||||
<script src='lib/backbone-min.js' type='text/javascript'></script>
|
||||
<script src='lib/swagger-client.js' type='text/javascript'></script>
|
||||
<script src='swagger-ui.js' type='text/javascript'></script>
|
||||
<script src='lib/highlight.7.3.pack.js' type='text/javascript'></script>
|
||||
<script src='lib/marked.js' type='text/javascript'></script>
|
||||
|
||||
<!-- enabling this will enable oauth2 implicit scope support -->
|
||||
<script src='lib/swagger-oauth.js' type='text/javascript'></script>
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
var url = window.location.search.match(/url=([^&]+)/);
|
||||
if (url && url.length > 1) {
|
||||
url = decodeURIComponent(url[1]);
|
||||
} else {
|
||||
url = "../../swagger-spec/";
|
||||
}
|
||||
window.swaggerUi = new SwaggerUi({
|
||||
url: url,
|
||||
dom_id: "swagger-ui-container",
|
||||
supportedSubmitMethods: [],
|
||||
onComplete: function(swaggerApi, swaggerUi){
|
||||
if(typeof initOAuth == "function") {
|
||||
/*
|
||||
initOAuth({
|
||||
clientId: "your-client-id",
|
||||
realm: "your-realms",
|
||||
appName: "your-app-name"
|
||||
});
|
||||
*/
|
||||
}
|
||||
$('pre code').each(function(i, e) {
|
||||
hljs.highlightBlock(e)
|
||||
});
|
||||
},
|
||||
onFailure: function(data) {
|
||||
log("Unable to Load SwaggerUI");
|
||||
},
|
||||
docExpansion: "none",
|
||||
sorter : "alpha"
|
||||
});
|
||||
|
||||
function addApiKeyAuthorization() {
|
||||
var key = $('#input_apiKey')[0].value;
|
||||
log("key: " + key);
|
||||
if(key && key.trim() != "") {
|
||||
log("added key " + key);
|
||||
window.authorizations.add("api_key", new ApiKeyAuthorization("api_key", key, "query"));
|
||||
}
|
||||
}
|
||||
|
||||
$('#input_apiKey').change(function() {
|
||||
addApiKeyAuthorization();
|
||||
});
|
||||
|
||||
// if you have an apiKey you would like to pre-populate on the page for demonstration purposes...
|
||||
/*
|
||||
var apiKey = "myApiKeyXXXX123456789";
|
||||
$('#input_apiKey').val(apiKey);
|
||||
addApiKeyAuthorization();
|
||||
*/
|
||||
|
||||
window.swaggerUi.load();
|
||||
});
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body class="swagger-section">
|
||||
<div id='header'>
|
||||
<div class="swagger-ui-wrap">
|
||||
<a id="logo" href="http://swagger.io">swagger</a>
|
||||
<form id='api_selector'>
|
||||
<div class='input'><input placeholder="http://example.com/api" id="input_baseUrl" name="baseUrl" type="text"/></div>
|
||||
<div class='input'><input placeholder="api_key" id="input_apiKey" name="apiKey" type="text"/></div>
|
||||
<div class='input'><a id="explore" href="#">Explore</a></div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="message-bar" class="swagger-ui-wrap"> </div>
|
||||
<div id="swagger-ui-container" class="swagger-ui-wrap"></div>
|
||||
</body>
|
||||
</html>
|
||||
|
File diff suppressed because one or more lines are too long
35
third_party/swagger-ui/lib/swagger-oauth.js
vendored
35
third_party/swagger-ui/lib/swagger-oauth.js
vendored
@ -4,7 +4,6 @@ var popupDialog;
|
||||
var clientId;
|
||||
var realm;
|
||||
var oauth2KeyName;
|
||||
var redirect_uri;
|
||||
|
||||
function handleLogin() {
|
||||
var scopes = [];
|
||||
@ -97,19 +96,18 @@ function handleLogin() {
|
||||
var authSchemes = window.swaggerUi.api.authSchemes;
|
||||
var host = window.location;
|
||||
var pathname = location.pathname.substring(0, location.pathname.lastIndexOf("/"));
|
||||
var defaultRedirectUrl = host.protocol + '//' + host.host + pathname + '/o2c.html';
|
||||
var redirectUrl = window.oAuthRedirectUrl || defaultRedirectUrl;
|
||||
var redirectUrl = host.protocol + '//' + host.host + pathname + '/o2c.html';
|
||||
var url = null;
|
||||
|
||||
for (var key in authSchemes) {
|
||||
if (authSchemes.hasOwnProperty(key)) {
|
||||
var flow = authSchemes[key].flow;
|
||||
|
||||
|
||||
if(authSchemes[key].type === 'oauth2' && flow && (flow === 'implicit' || flow === 'accessCode')) {
|
||||
var dets = authSchemes[key];
|
||||
url = dets.authorizationUrl + '?response_type=' + (flow === 'implicit' ? 'token' : 'code');
|
||||
window.swaggerUi.tokenName = dets.tokenName || 'access_token';
|
||||
window.swaggerUi.tokenUrl = (flow === 'accessCode' ? dets.tokenUrl : null);
|
||||
window.swaggerUi.tokenUrl = (flow === 'accessCode' ? dets.tokenUrl : null);
|
||||
}
|
||||
else if(authSchemes[key].grantTypes) {
|
||||
// 1.2 support
|
||||
@ -136,23 +134,17 @@ function handleLogin() {
|
||||
|
||||
for(k =0; k < o.length; k++) {
|
||||
var scope = $(o[k]).attr('scope');
|
||||
|
||||
|
||||
if (scopes.indexOf(scope) === -1)
|
||||
scopes.push(scope);
|
||||
}
|
||||
|
||||
// Implicit auth recommends a state parameter.
|
||||
var state = Math.random ();
|
||||
|
||||
window.enabledScopes=scopes;
|
||||
|
||||
redirect_uri = redirectUrl;
|
||||
|
||||
url += '&redirect_uri=' + encodeURIComponent(redirectUrl);
|
||||
url += '&realm=' + encodeURIComponent(realm);
|
||||
url += '&client_id=' + encodeURIComponent(clientId);
|
||||
url += '&scope=' + encodeURIComponent(scopes.join(' '));
|
||||
url += '&state=' + encodeURIComponent(state);
|
||||
url += '&scope=' + encodeURIComponent(scopes);
|
||||
|
||||
window.open(url);
|
||||
});
|
||||
@ -203,30 +195,29 @@ function initOAuth(opts) {
|
||||
});
|
||||
}
|
||||
|
||||
window.processOAuthCode = function processOAuthCode(data) {
|
||||
function processOAuthCode(data) {
|
||||
var params = {
|
||||
'client_id': clientId,
|
||||
'code': data.code,
|
||||
'grant_type': 'authorization_code',
|
||||
'redirect_uri': redirect_uri
|
||||
'grant_type': 'authorization_code'
|
||||
}
|
||||
$.ajax(
|
||||
{
|
||||
url : window.swaggerUi.tokenUrl,
|
||||
type: "POST",
|
||||
data: params,
|
||||
success:function(data, textStatus, jqXHR)
|
||||
success:function(data, textStatus, jqXHR)
|
||||
{
|
||||
onOAuthComplete(data);
|
||||
},
|
||||
error: function(jqXHR, textStatus, errorThrown)
|
||||
error: function(jqXHR, textStatus, errorThrown)
|
||||
{
|
||||
onOAuthComplete("");
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
window.onOAuthComplete = function onOAuthComplete(token) {
|
||||
function onOAuthComplete(token) {
|
||||
if(token) {
|
||||
if(token.error) {
|
||||
var checkbox = $('input[type=checkbox],.secured')
|
||||
@ -273,12 +264,12 @@ window.onOAuthComplete = function onOAuthComplete(token) {
|
||||
// all scopes are satisfied
|
||||
$(o).find('.api-ic').addClass('ic-info');
|
||||
$(o).find('.api-ic').removeClass('ic-warning');
|
||||
$(o).find('.api-ic').removeClass('ic-error');
|
||||
$(o).find('.api-ic').removeClass('ic-error');
|
||||
}
|
||||
}
|
||||
});
|
||||
window.swaggerUi.api.clientAuthorizations.add(oauth2KeyName, new SwaggerClient.ApiKeyAuthorization('Authorization', 'Bearer ' + b, 'header'));
|
||||
window.authorizations.add(oauth2KeyName, new ApiKeyAuthorization('Authorization', 'Bearer ' + b, 'header'));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
File diff suppressed because one or more lines are too long
32848
third_party/swagger-ui/swagger-ui.js
vendored
32848
third_party/swagger-ui/swagger-ui.js
vendored
File diff suppressed because one or more lines are too long
18
third_party/swagger-ui/swagger-ui.min.js
vendored
18
third_party/swagger-ui/swagger-ui.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user