From 1504ade0e2fe3f6dfb22cf995d5f4e73a394402c Mon Sep 17 00:00:00 2001 From: Roman Hotsiy Date: Mon, 29 Jul 2019 17:31:27 +0300 Subject: [PATCH] chore: add docs --- README.md | 1 + src/components/SideMenu/SideMenu.tsx | 5 +---- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index cae15bb3..140d20c0 100644 --- a/README.md +++ b/README.md @@ -244,6 +244,7 @@ You can use all of the following options with standalone version on tag * `disableSearch` - disable search indexing and search box * `onlyRequiredInSamples` - shows only required fields in request samples. * `jsonSampleExpandLevel` - set the default expand level for JSON payload samples (responses and request body). Special value 'all' expands all levels. The default value is `2`. +* `menuToggle` - if true clicking second time on expanded menu item will collapse it, default `false` * `theme` - ReDoc theme. Not documented yet. For details check source code: [theme.ts](https://github.com/Redocly/redoc/blob/master/src/theme.ts) ## Advanced usage of standalone version diff --git a/src/components/SideMenu/SideMenu.tsx b/src/components/SideMenu/SideMenu.tsx index f63d9c46..34643054 100644 --- a/src/components/SideMenu/SideMenu.tsx +++ b/src/components/SideMenu/SideMenu.tsx @@ -9,10 +9,7 @@ import { PerfectScrollbarWrap } from '../../common-elements/perfect-scrollbar'; import { RedocAttribution } from './styled.elements'; @observer -export class SideMenu extends React.Component<{ - menu: MenuStore; - className?: string; -}> { +export class SideMenu extends React.Component<{ menu: MenuStore; className?: string }> { static contextType = OptionsContext; private _updateScroll?: () => void;