-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Expand file tree
/
Copy pathindex.js
More file actions
53 lines (51 loc) · 1.58 KB
/
Copy pathindex.js
File metadata and controls
53 lines (51 loc) · 1.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
import EditorPreviewSwaggerUI from './components/EditorPreviewSwaggerUI/EditorPreviewSwaggerUI.jsx';
import JumpToPath from './components/JumpToPath.jsx';
import EditorPreviewWrapper from './extensions/editor-preview/wrap-components/EditorPreviewWrapper.jsx';
import RequestBodyWrapper from './components/RequestBodyWrapper.jsx';
import { previewUnmounted } from './actions/preview-unmounted.js';
import {
jumpToPath,
jumpToPathStarted,
jumpToPathSuccess,
jumpToPathFailure,
} from './actions/jump-to-path.js';
import {
previewUnmounted as previewUnmountedWrap,
jumpToPathSuccess as jumpToPathSuccessWrap,
} from './wrap-actions.js';
import { detectContentTypeSuccess as detectContentTypeSuccessWrap } from './extensions/editor-content-type/wrap-actions.js';
import reducers from './reducers.js';
import { selectURL } from './selectors.js';
const EditorPreviewSwaggerUIPlugin = () => ({
components: {
EditorPreviewSwaggerUI,
JumpToPath,
},
wrapComponents: {
EditorPreview: EditorPreviewWrapper,
RequestBody: RequestBodyWrapper,
},
statePlugins: {
editor: {
wrapActions: {
detectContentTypeSuccess: detectContentTypeSuccessWrap,
},
},
editorPreviewSwaggerUI: {
actions: {
previewUnmounted,
jumpToPath,
jumpToPathStarted,
jumpToPathSuccess,
jumpToPathFailure,
},
wrapActions: {
previewUnmounted: previewUnmountedWrap,
jumpToPathSuccess: jumpToPathSuccessWrap,
},
selectors: { selectURL },
reducers,
},
},
});
export default EditorPreviewSwaggerUIPlugin;