diff --git a/src/core/plugins/allow-try-it-out-if-host.js b/src/core/plugins/allow-try-it-out-if-host.js deleted file mode 100644 index a6608fb4..00000000 --- a/src/core/plugins/allow-try-it-out-if-host.js +++ /dev/null @@ -1,36 +0,0 @@ -import React, { PropTypes } from "react" - -export default function (system) { - return { - components: { - NoHostWarning, - }, - statePlugins: { - spec: { - selectors: { - allowTryItOutFor, - } - } - } - } -} - -// This is a quick style. How do we improve this? -const style = { - backgroundColor: "#e7f0f7", - padding: "1rem", - borderRadius: "3px", -} - -function NoHostWarning() { - return ( -
Note: The interactive forms are disabled, as no `host` property was found in the specification. Please see: OAI 2.0/#swagger-object
- ) -} - -// Only allow if, there is a host field -function allowTryItOutFor(state) { - return ({specSelectors}) => { - return specSelectors.hasHost(state) - } -} diff --git a/src/core/presets/apis.js b/src/core/presets/apis.js index b6de37ff..3d4b5961 100644 --- a/src/core/presets/apis.js +++ b/src/core/presets/apis.js @@ -1,11 +1,10 @@ import BasePreset from "./base" -import allowTryItOutIfHost from "core/plugins/allow-try-it-out-if-host" +// Just the base, for now. export default function PresetApis() { return [ BasePreset, - allowTryItOutIfHost, ] }