Merge pull request #1285 from swagger-api/develop_2.0

Merged from develop_2.0
This commit is contained in:
Tony Tam
2015-05-14 09:00:23 -04:00
14 changed files with 145 additions and 66 deletions

View File

@@ -1,7 +1,7 @@
{ {
"name": "swagger-ui", "name": "swagger-ui",
"main": "dist/index.html", "main": "dist/index.html",
"version": "2.1.4-M2", "version": "2.1.5-M2",
"authors": [ "authors": [
"Mohsen Azimi <me@azimi.me>" "Mohsen Azimi <me@azimi.me>"
], ],

3
dist/css/print.css vendored
View File

@@ -1069,6 +1069,9 @@
.swagger-section .swagger-ui-wrap form.form_box p strong { .swagger-section .swagger-ui-wrap form.form_box p strong {
color: black; color: black;
} }
.swagger-section .swagger-ui-wrap .operation-status td.markdown > p:last-child {
padding-bottom: 0;
}
.swagger-section .title { .swagger-section .title {
font-style: bold; font-style: bold;
} }

3
dist/css/screen.css vendored
View File

@@ -1069,6 +1069,9 @@
.swagger-section .swagger-ui-wrap form.form_box p strong { .swagger-section .swagger-ui-wrap form.form_box p strong {
color: black; color: black;
} }
.swagger-section .swagger-ui-wrap .operation-status td.markdown > p:last-child {
padding-bottom: 0;
}
.swagger-section .title { .swagger-section .title {
font-style: bold; font-style: bold;
} }

2
dist/index.html vendored
View File

@@ -52,7 +52,7 @@
log("Unable to Load SwaggerUI"); log("Unable to Load SwaggerUI");
}, },
docExpansion: "none", docExpansion: "none",
sorter : "alpha" apisSorter: "alpha"
}); });
function addApiKeyAuthorization(){ function addApiKeyAuthorization(){

155
dist/swagger-ui.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -8,7 +8,7 @@
} }
], ],
"description": "Swagger UI is a dependency-free collection of HTML, JavaScript, and CSS assets that dynamically generate beautiful documentation from a Swagger-compliant API", "description": "Swagger UI is a dependency-free collection of HTML, JavaScript, and CSS assets that dynamically generate beautiful documentation from a Swagger-compliant API",
"version": "2.1.4-M2", "version": "2.1.5-M2",
"homepage": "http://swagger.io", "homepage": "http://swagger.io",
"license": "Apache 2.0", "license": "Apache 2.0",
"main": "dist/swagger-ui.js", "main": "dist/swagger-ui.js",
@@ -50,6 +50,6 @@
"less": "^2.4.0", "less": "^2.4.0",
"mocha": "^2.1.0", "mocha": "^2.1.0",
"selenium-webdriver": "^2.45.0", "selenium-webdriver": "^2.45.0",
"swagger-client": "2.1.5-M2" "swagger-client": "2.1.6-M2"
} }
} }

View File

@@ -1069,6 +1069,9 @@
.swagger-section .swagger-ui-wrap form.form_box p strong { .swagger-section .swagger-ui-wrap form.form_box p strong {
color: black; color: black;
} }
.swagger-section .swagger-ui-wrap .operation-status td.markdown > p:last-child {
padding-bottom: 0;
}
.swagger-section .title { .swagger-section .title {
font-style: bold; font-style: bold;
} }

View File

@@ -1069,6 +1069,9 @@
.swagger-section .swagger-ui-wrap form.form_box p strong { .swagger-section .swagger-ui-wrap form.form_box p strong {
color: black; color: black;
} }
.swagger-section .swagger-ui-wrap .operation-status td.markdown > p:last-child {
padding-bottom: 0;
}
.swagger-section .title { .swagger-section .title {
font-style: bold; font-style: bold;
} }

View File

@@ -52,7 +52,7 @@
log("Unable to Load SwaggerUI"); log("Unable to Load SwaggerUI");
}, },
docExpansion: "none", docExpansion: "none",
sorter : "alpha" apisSorter: "alpha"
}); });
function addApiKeyAuthorization(){ function addApiKeyAuthorization(){

View File

@@ -90,7 +90,9 @@ window.SwaggerUi = Backbone.Router.extend({
if (url && url.indexOf('http') !== 0) { if (url && url.indexOf('http') !== 0) {
url = this.buildUrl(window.location.href.toString(), url); url = this.buildUrl(window.location.href.toString(), url);
} }
if(this.api) {
this.options.authorizations = this.api.clientAuthorizations;
}
this.options.url = url; this.options.url = url;
this.headerView.update(url); this.headerView.update(url);

View File

@@ -1085,6 +1085,10 @@
} }
} }
} }
.operation-status td.markdown > p:last-child {
padding-bottom: 0;
}
} }
} }

View File

@@ -24,6 +24,6 @@
{{/each}} {{/each}}
</select> </select>
</td> </td>
<td class="markdown">{{{description}}}</td> <td class="markdown">{{#if required}}<strong>{{/if}}{{{description}}}{{#if required}}</strong>{{/if}}</td>
<td>{{{paramType}}}</td> <td>{{{paramType}}}</td>
<td><span class="model-signature"></span></td> <td><span class="model-signature"></span></td>

View File

@@ -1,5 +1,5 @@
<td width='15%' class='code'>{{code}}</td> <td width='15%' class='code'>{{code}}</td>
<td>{{{message}}}</td> <td class="markdown">{{{message}}}</td>
<td width='50%'><span class="model-signature" /></td> <td width='50%'><span class="model-signature" /></td>
<td class="headers"> <td class="headers">
<table> <table>