mirror of
https://github.com/Redocly/redoc.git
synced 2024-11-25 18:13:44 +03:00
chore: prettier all
This commit is contained in:
parent
93e844c3d0
commit
528b8fbebc
|
@ -28,7 +28,14 @@ export class FieldDetails extends React.PureComponent<FieldProps> {
|
|||
<div>
|
||||
<TypePrefix>{schema.typePrefix}</TypePrefix>
|
||||
<TypeName>{schema.displayType}</TypeName>
|
||||
{schema.displayFormat && <TypeFormat> <{schema.displayFormat}> </TypeFormat>}
|
||||
{schema.displayFormat && (
|
||||
<TypeFormat>
|
||||
{' '}
|
||||
<
|
||||
{schema.displayFormat}
|
||||
>{' '}
|
||||
</TypeFormat>
|
||||
)}
|
||||
{schema.title && <TypeTitle> ({schema.title}) </TypeTitle>}
|
||||
<ConstraintsView constraints={schema.constraints} />
|
||||
{schema.nullable && <NullableLabel> Nullable </NullableLabel>}
|
||||
|
|
|
@ -34,7 +34,9 @@ export class MediaTypeSamples extends React.Component<PayloadSamplesProps> {
|
|||
return (
|
||||
<SmallTabs>
|
||||
<TabList>
|
||||
{examplesNames.map(name => <Tab key={name}> {examples[name].summary || name} </Tab>)}
|
||||
{examplesNames.map(name => (
|
||||
<Tab key={name}> {examples[name].summary || name} </Tab>
|
||||
))}
|
||||
</TabList>
|
||||
{examplesNames.map(name => (
|
||||
<TabPanel key={name}>{sampleView(examples[name].value)}</TabPanel>
|
||||
|
|
|
@ -24,7 +24,7 @@ export const SearchInput = styled.input.attrs({
|
|||
outline: none;
|
||||
`;
|
||||
|
||||
export const SearchIcon = styled((props: {className?: string}) => (
|
||||
export const SearchIcon = styled((props: { className?: string }) => (
|
||||
<svg
|
||||
className={props.className}
|
||||
version="1.1"
|
||||
|
|
|
@ -72,7 +72,9 @@ export class SecurityRequirement extends React.PureComponent<SecurityRequirement
|
|||
<SecurityRequirementAndWrap key={scheme.id}>
|
||||
<Link to={scheme.sectionId}>{scheme.id}</Link>
|
||||
{scheme.scopes.length > 0 && ' ('}
|
||||
{scheme.scopes.map(scope => <ScopeName key={scope}>{scope}</ScopeName>)}
|
||||
{scheme.scopes.map(scope => (
|
||||
<ScopeName key={scope}>{scope}</ScopeName>
|
||||
))}
|
||||
{scheme.scopes.length > 0 && ') '}
|
||||
</SecurityRequirementAndWrap>
|
||||
);
|
||||
|
@ -117,7 +119,9 @@ export class SecurityRequirements extends React.PureComponent<SecurityRequiremen
|
|||
<AuthHeader>Authorizations: </AuthHeader>
|
||||
</AuthHeaderColumn>
|
||||
<SecuritiesColumn>
|
||||
{securities.map((security, idx) => <SecurityRequirement key={idx} security={security} />)}
|
||||
{securities.map((security, idx) => (
|
||||
<SecurityRequirement key={idx} security={security} />
|
||||
))}
|
||||
</SecuritiesColumn>
|
||||
</Wrap>
|
||||
);
|
||||
|
|
|
@ -52,12 +52,14 @@ export class MenuStore {
|
|||
/**
|
||||
* active item absolute index (when flattened). -1 means nothing is selected
|
||||
*/
|
||||
@observable activeItemIdx: number = -1;
|
||||
@observable
|
||||
activeItemIdx: number = -1;
|
||||
|
||||
/**
|
||||
* whether sidebar with menu is opened or not
|
||||
*/
|
||||
@observable sideBarOpened: boolean = false;
|
||||
@observable
|
||||
sideBarOpened: boolean = false;
|
||||
|
||||
items: IMenuItem[];
|
||||
flatItems: IMenuItem[];
|
||||
|
|
|
@ -10,7 +10,8 @@ import { SchemaModel } from './Schema';
|
|||
* Field or Parameter model ready to be used by components
|
||||
*/
|
||||
export class FieldModel {
|
||||
@observable expanded: boolean = false;
|
||||
@observable
|
||||
expanded: boolean = false;
|
||||
|
||||
schema: SchemaModel;
|
||||
name: string;
|
||||
|
|
|
@ -21,8 +21,10 @@ export class GroupModel implements IMenuItem {
|
|||
parent?: GroupModel;
|
||||
externalDocs?: OpenAPIExternalDocumentation;
|
||||
|
||||
@observable active: boolean = false;
|
||||
@observable expanded: boolean = false;
|
||||
@observable
|
||||
active: boolean = false;
|
||||
@observable
|
||||
expanded: boolean = false;
|
||||
|
||||
depth: number;
|
||||
level: number;
|
||||
|
|
|
@ -14,7 +14,8 @@ import { RedocNormalizedOptions } from '../RedocNormalizedOptions';
|
|||
export class MediaContentModel {
|
||||
mediaTypes: MediaTypeModel[];
|
||||
|
||||
@observable activeMimeIdx = 0;
|
||||
@observable
|
||||
activeMimeIdx = 0;
|
||||
|
||||
/**
|
||||
* @param isRequestType needed to know if skipe RO/RW fields in objects
|
||||
|
|
|
@ -40,9 +40,12 @@ export class OperationModel implements IMenuItem {
|
|||
|
||||
depth: number;
|
||||
|
||||
@observable ready?: boolean = true;
|
||||
@observable active: boolean = false;
|
||||
@observable expanded: boolean = false;
|
||||
@observable
|
||||
ready?: boolean = true;
|
||||
@observable
|
||||
active: boolean = false;
|
||||
@observable
|
||||
expanded: boolean = false;
|
||||
//#endregion
|
||||
|
||||
pointer: string;
|
||||
|
|
|
@ -9,7 +9,8 @@ import { FieldModel } from './Field';
|
|||
import { MediaContentModel } from './MediaContent';
|
||||
|
||||
export class ResponseModel {
|
||||
@observable expanded: boolean;
|
||||
@observable
|
||||
expanded: boolean;
|
||||
|
||||
content?: MediaContentModel;
|
||||
code: string;
|
||||
|
|
|
@ -48,7 +48,8 @@ export class SchemaModel {
|
|||
oneOf?: SchemaModel[];
|
||||
oneOfType: string;
|
||||
discriminatorProp: string;
|
||||
@observable activeOneOf: number = 0;
|
||||
@observable
|
||||
activeOneOf: number = 0;
|
||||
|
||||
rawSchema: OpenAPISchema;
|
||||
schema: MergedOpenAPISchema;
|
||||
|
|
Loading…
Reference in New Issue
Block a user