Merge branch 'master' into bug/3816-oas3-authorize-always-showing

This commit is contained in:
kyle
2017-10-26 15:49:05 -07:00
committed by GitHub
3 changed files with 18 additions and 6 deletions

View File

@@ -80,7 +80,12 @@ export const parseToJson = (str) => ({specActions, specSelectors, errActions}) =
} }
export const resolveSpec = (json, url) => ({specActions, specSelectors, errActions, fn: { fetch, resolve, AST }, getConfigs}) => { export const resolveSpec = (json, url) => ({specActions, specSelectors, errActions, fn: { fetch, resolve, AST }, getConfigs}) => {
const { modelPropertyMacro, parameterMacro } = getConfigs() const {
modelPropertyMacro,
parameterMacro,
requestInterceptor,
responseInterceptor
} = getConfigs()
if(typeof(json) === "undefined") { if(typeof(json) === "undefined") {
json = specSelectors.specJson() json = specSelectors.specJson()
@@ -93,8 +98,15 @@ export const resolveSpec = (json, url) => ({specActions, specSelectors, errActio
let specStr = specSelectors.specStr() let specStr = specSelectors.specStr()
return resolve({fetch, spec: json, baseDoc: url, modelPropertyMacro, parameterMacro }) return resolve({
.then( ({spec, errors}) => { fetch,
spec: json,
baseDoc: url,
modelPropertyMacro,
parameterMacro,
requestInterceptor,
responseInterceptor
}).then( ({spec, errors}) => {
errActions.clear({ errActions.clear({
type: "thrown" type: "thrown"
}) })

View File

@@ -1,6 +1,6 @@
# Add a plugin # Add a plugin
### Swagger-UX relies on plugins for all the good stuff. ### Swagger-UI relies on plugins for all the good stuff.
Plugins allow you to add Plugins allow you to add
- `statePlugins` - `statePlugins`

View File

@@ -129,7 +129,7 @@ export default class Topbar extends React.Component {
<div className="topbar"> <div className="topbar">
<div className="wrapper"> <div className="wrapper">
<div className="topbar-wrapper"> <div className="topbar-wrapper">
<Link href="#" title="Swagger UX"> <Link href="#">
<img height="30" width="30" src={ Logo } alt="Swagger UI"/> <img height="30" width="30" src={ Logo } alt="Swagger UI"/>
<span>swagger</span> <span>swagger</span>
</Link> </Link>