Skip to content

Commit 996433d

Browse files
committed
merged
2 parents 958e748 + a04b562 commit 996433d

File tree

6 files changed

+12
-8
lines changed

6 files changed

+12
-8
lines changed

dist/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747
if(typeof initOAuth == "function") {
4848
initOAuth({
4949
clientId: "your-client-id",
50+
clientSecret: "your-client-secret",
5051
realm: "your-realms",
5152
appName: "your-app-name"
5253
});

dist/lib/swagger-oauth.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ var clientId;
55
var realm;
66
var oauth2KeyName;
77
var redirect_uri;
8+
var clientSecret;
89

910
function handleLogin() {
1011
var scopes = [];
@@ -185,6 +186,7 @@ function initOAuth(opts) {
185186
popupMask = (o.popupMask||$('#api-common-mask'));
186187
popupDialog = (o.popupDialog||$('.api-popup-dialog'));
187188
clientId = (o.clientId||errors.push('missing client id'));
189+
clientSecret = (o.clientSecret||errors.push('missing client secret'));
188190
realm = (o.realm||errors.push('missing realm'));
189191

190192
if(errors.length > 0){
@@ -207,6 +209,7 @@ function initOAuth(opts) {
207209
window.processOAuthCode = function processOAuthCode(data) {
208210
var params = {
209211
'client_id': clientId,
212+
'client_secret': clientSecret,
210213
'code': data.code,
211214
'grant_type': 'authorization_code',
212215
'redirect_uri': redirect_uri

dist/swagger-ui.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* swagger-ui - Swagger UI is a dependency-free collection of HTML, JavaScript, and CSS assets that dynamically generate beautiful documentation from a Swagger-compliant API
33
* @version v2.1.0
44
* @link http://swagger.io
5-
* @license Apache 2.0
5+
* @license Apache-2.0
66
*/
77
(function(){this["Handlebars"] = this["Handlebars"] || {};
88
this["Handlebars"]["templates"] = this["Handlebars"]["templates"] || {};
@@ -533,7 +533,7 @@ this["Handlebars"]["templates"]["param_list"] = Handlebars.template({"1":functio
533533
+ escapeExpression(((helper = (helper = helpers.valueId || (depth0 != null ? depth0.valueId : depth0)) != null ? helper : helperMissing),(typeof helper === functionType ? helper.call(depth0, {"name":"valueId","hash":{},"data":data}) : helper)))
534534
+ "'>"
535535
+ escapeExpression(((helper = (helper = helpers.name || (depth0 != null ? depth0.name : depth0)) != null ? helper : helperMissing),(typeof helper === functionType ? helper.call(depth0, {"name":"name","hash":{},"data":data}) : helper)))
536-
+ "</labe></td>\n<td>\n <select ";
536+
+ "</label></td>\n<td>\n <select ";
537537
stack1 = ((helpers.isArray || (depth0 && depth0.isArray) || helperMissing).call(depth0, depth0, {"name":"isArray","hash":{},"fn":this.program(3, data),"inverse":this.noop,"data":data}));
538538
if (stack1 != null) { buffer += stack1; }
539539
buffer += " class=\"parameter ";
@@ -30840,7 +30840,7 @@ window.SwaggerUi.Views = {};
3084030840
});
3084130841
} else if (typeof exports === 'object') {
3084230842
// Node. Does not work with strict CommonJS, but
30843-
// only CommonJS-like enviroments that support module.exports,
30843+
// only CommonJS-like environments that support module.exports,
3084430844
// like Node.
3084530845
module.exports = factory(require('b'));
3084630846
} else {
@@ -31078,7 +31078,7 @@ SwaggerUi.Views.MainView = Backbone.View.extend({
3107831078
this.model.validatorUrl = null;
3107931079
} else {
3108031080
// Default validator
31081-
if(window.location.protocol === 'https') {
31081+
if(window.location.protocol === 'https:') {
3108231082
this.model.validatorUrl = 'https://online.swagger.io/validator';
3108331083
}
3108431084
else {

dist/swagger-ui.min.js

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

src/main/javascript/SwaggerUi.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ window.SwaggerUi.Views = {};
257257
});
258258
} else if (typeof exports === 'object') {
259259
// Node. Does not work with strict CommonJS, but
260-
// only CommonJS-like enviroments that support module.exports,
260+
// only CommonJS-like environments that support module.exports,
261261
// like Node.
262262
module.exports = factory(require('b'));
263263
} else {

src/main/template/param_list.handlebars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<td class='code{{#if required}} required{{/if}}'><label for='{{valueId}}'>{{name}}</labe></td>
1+
<td class='code{{#if required}} required{{/if}}'><label for='{{valueId}}'>{{name}}</label></td>
22
<td>
33
<select {{#isArray this}} multiple="multiple"{{/isArray}} class="parameter {{#if required}} required {{/if}}" name="{{name}}" id="{{valueId}}">
44

0 commit comments

Comments
 (0)