diff --git a/dev-helpers/index.html b/dev-helpers/index.html
index 684f9204135..13d990cf7fa 100644
--- a/dev-helpers/index.html
+++ b/dev-helpers/index.html
@@ -54,6 +54,9 @@
presets: [
SwaggerEditorStandalonePreset
],
+ plugins: [
+ SwaggerEditorStandalonePreset.plugins.TopbarNewEditorButton,
+ ],
queryConfigEnabled: true,
})
diff --git a/src/standalone/index.js b/src/standalone/index.js
index f0a866770e6..bb279855431 100644
--- a/src/standalone/index.js
+++ b/src/standalone/index.js
@@ -2,6 +2,7 @@ import TopbarPlugin from "./topbar"
import TopbarInsertPlugin from "./topbar-insert"
import TopbarMenuFileImportFile from "./topbar-menu-file-import_file"
import TopbarMenuEditConvert from "./topbar-menu-edit-convert"
+import TopbarNewEditorButton from "./topbar-new-editor-button"
import StandaloneLayout from "./standalone-layout"
let StandaloneLayoutPlugin = function() {
@@ -12,7 +13,7 @@ let StandaloneLayoutPlugin = function() {
}
}
-export default function () {
+function standalonePreset () {
return [
TopbarPlugin,
TopbarInsertPlugin,
@@ -21,3 +22,14 @@ export default function () {
StandaloneLayoutPlugin
]
}
+
+standalonePreset.plugins = {
+ TopbarPlugin,
+ TopbarInsertPlugin,
+ TopbarMenuFileImportFile,
+ TopbarMenuEditConvert,
+ TopbarNewEditorButton,
+ StandaloneLayoutPlugin,
+}
+
+export default standalonePreset
diff --git a/src/standalone/topbar-new-editor-button/components/NewEditorButton.jsx b/src/standalone/topbar-new-editor-button/components/NewEditorButton.jsx
new file mode 100644
index 00000000000..88b439e6dcb
--- /dev/null
+++ b/src/standalone/topbar-new-editor-button/components/NewEditorButton.jsx
@@ -0,0 +1,19 @@
+import React from "react"
+import PropTypes from "prop-types"
+
+const NewEditorButton = ({ getComponent }) => {
+ const Link = getComponent("Link")
+
+ return (
+
+ Try our new Editor
+
+ )
+}
+
+NewEditorButton.propTypes = {
+ getComponent: PropTypes.func.isRequired,
+}
+
+
+export default NewEditorButton
diff --git a/src/standalone/topbar-new-editor-button/index.js b/src/standalone/topbar-new-editor-button/index.js
new file mode 100644
index 00000000000..97a9756bbc4
--- /dev/null
+++ b/src/standalone/topbar-new-editor-button/index.js
@@ -0,0 +1,9 @@
+import NewEditorButton from "./components/NewEditorButton"
+
+const TopbarNewEditorButtonPlugin = () => ({
+ components: {
+ TopbarNewEditorButton: NewEditorButton,
+ }
+})
+
+export default TopbarNewEditorButtonPlugin
diff --git a/src/standalone/topbar/logo_small.svg b/src/standalone/topbar/assets/logo_small.svg
similarity index 100%
rename from src/standalone/topbar/logo_small.svg
rename to src/standalone/topbar/assets/logo_small.svg
diff --git a/src/standalone/topbar/components/AboutMenu.jsx b/src/standalone/topbar/components/AboutMenu.jsx
new file mode 100644
index 00000000000..1b756276711
--- /dev/null
+++ b/src/standalone/topbar/components/AboutMenu.jsx
@@ -0,0 +1,23 @@
+import React from "react"
+import PropTypes from "prop-types"
+
+import DropdownMenu from "./DropdownMenu"
+
+const AboutMenu = ({ getComponent, ...rest }) => {
+ const Link = getComponent("Link")
+
+ return (
+