diff options
author | Leonid Logvinov <logvinov.leon@gmail.com> | 2017-12-22 22:05:32 +0800 |
---|---|---|
committer | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-01-03 18:37:38 +0800 |
commit | e744e4cd989bd3ae1070c59f7baa8097f18b8b06 (patch) | |
tree | a7fde03873f3c1b8689d3991edbb362f8022e5f0 /packages/website/ts/pages/documentation/event_definition.tsx | |
parent | 9a96e8c704b6f84e00bbe848159a4819844cf09d (diff) | |
download | dexon-0x-contracts-e744e4cd989bd3ae1070c59f7baa8097f18b8b06.tar.gz dexon-0x-contracts-e744e4cd989bd3ae1070c59f7baa8097f18b8b06.tar.zst dexon-0x-contracts-e744e4cd989bd3ae1070c59f7baa8097f18b8b06.zip |
Apply prettier config
Diffstat (limited to 'packages/website/ts/pages/documentation/event_definition.tsx')
-rw-r--r-- | packages/website/ts/pages/documentation/event_definition.tsx | 36 |
1 files changed, 16 insertions, 20 deletions
diff --git a/packages/website/ts/pages/documentation/event_definition.tsx b/packages/website/ts/pages/documentation/event_definition.tsx index 2fef019d2..0e53e38e7 100644 --- a/packages/website/ts/pages/documentation/event_definition.tsx +++ b/packages/website/ts/pages/documentation/event_definition.tsx @@ -1,10 +1,10 @@ import * as _ from 'lodash'; import * as React from 'react'; -import {DocsInfo} from 'ts/pages/documentation/docs_info'; -import {Type} from 'ts/pages/documentation/type'; -import {AnchorTitle} from 'ts/pages/shared/anchor_title'; -import {Event, EventArg, HeaderSizes} from 'ts/types'; -import {colors} from 'ts/utils/colors'; +import { DocsInfo } from 'ts/pages/documentation/docs_info'; +import { Type } from 'ts/pages/documentation/type'; +import { AnchorTitle } from 'ts/pages/shared/anchor_title'; +import { Event, EventArg, HeaderSizes } from 'ts/types'; +import { colors } from 'ts/utils/colors'; interface EventDefinitionProps { event: Event; @@ -29,7 +29,7 @@ export class EventDefinition extends React.Component<EventDefinitionProps, Event <div id={`${this.props.sectionName}-${event.name}`} className="pb2" - style={{overflow: 'hidden', width: '100%'}} + style={{ overflow: 'hidden', width: '100%' }} onMouseOver={this._setAnchorVisibility.bind(this, true)} onMouseOut={this._setAnchorVisibility.bind(this, false)} > @@ -39,29 +39,24 @@ export class EventDefinition extends React.Component<EventDefinitionProps, Event id={event.name} shouldShowAnchor={this.state.shouldShowAnchor} /> - <div style={{fontSize: 16}}> + <div style={{ fontSize: 16 }}> <pre> - <code className="hljs"> - {this._renderEventCode()} - </code> + <code className="hljs">{this._renderEventCode()}</code> </pre> </div> </div> ); } private _renderEventCode() { - const indexed = <span style={{color: colors.green}}> indexed</span>; + const indexed = <span style={{ color: colors.green }}> indexed</span>; const eventArgs = _.map(this.props.event.eventArgs, (eventArg: EventArg) => { const type = ( - <Type - type={eventArg.type} - sectionName={this.props.sectionName} - docsInfo={this.props.docsInfo} - /> + <Type type={eventArg.type} sectionName={this.props.sectionName} docsInfo={this.props.docsInfo} /> ); return ( <span key={`eventArg-${eventArg.name}`}> - {eventArg.name}{eventArg.isIndexed ? indexed : ''}: {type}, + {eventArg.name} + {eventArg.isIndexed ? indexed : ''}: {type}, </span> ); }); @@ -71,9 +66,10 @@ export class EventDefinition extends React.Component<EventDefinitionProps, Event return ( <span> {`{`} - <br /> - {'\t'}{argList} - <br /> + <br /> + {'\t'} + {argList} + <br /> {`}`} </span> ); |