diff options
author | Fabio Berger <me@fabioberger.com> | 2017-12-22 04:24:54 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2017-12-22 04:24:54 +0800 |
commit | e01c0f054d2dbb043aec8b4cb8e1c47f83bd5eb9 (patch) | |
tree | 241b630db5044974cc17130f149ca64728d9c619 /packages/website/ts/pages/documentation/method_block.tsx | |
parent | d725de72861c6a6218c7f4822a339175a2da7403 (diff) | |
parent | cb3582289ff94857d5956bbd71dbf68ee3f42ecf (diff) | |
download | dexon-0x-contracts-e01c0f054d2dbb043aec8b4cb8e1c47f83bd5eb9.tar.gz dexon-0x-contracts-e01c0f054d2dbb043aec8b4cb8e1c47f83bd5eb9.tar.zst dexon-0x-contracts-e01c0f054d2dbb043aec8b4cb8e1c47f83bd5eb9.zip |
Merge branch 'development' into fix/docLinks
* development:
Update and standardize contracts README
Add to CHANGELOG
Refactor toBaseUnitAmount so that it throws if user supplies unitAmount with too many decimals
Make assertion stricter so that one cannot submit invalid baseUnit amounts to `toUnitAmount`
Add some missed underscores, update changelog and comments
Add new underscore-privates rule to @0xproject/tslint-config and fix lint errors
# Conflicts:
# packages/website/ts/pages/documentation/documentation.tsx
# packages/website/ts/pages/shared/nested_sidebar_menu.tsx
Diffstat (limited to 'packages/website/ts/pages/documentation/method_block.tsx')
-rw-r--r-- | packages/website/ts/pages/documentation/method_block.tsx | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/packages/website/ts/pages/documentation/method_block.tsx b/packages/website/ts/pages/documentation/method_block.tsx index 60dfc17db..147bc34d6 100644 --- a/packages/website/ts/pages/documentation/method_block.tsx +++ b/packages/website/ts/pages/documentation/method_block.tsx @@ -58,19 +58,19 @@ export class MethodBlock extends React.Component<MethodBlockProps, MethodBlockSt id={`${this.props.sectionName}-${method.name}`} style={{overflow: 'hidden', width: '100%'}} className="pb4" - onMouseOver={this.setAnchorVisibility.bind(this, true)} - onMouseOut={this.setAnchorVisibility.bind(this, false)} + onMouseOver={this._setAnchorVisibility.bind(this, true)} + onMouseOut={this._setAnchorVisibility.bind(this, false)} > {!method.isConstructor && <div className="flex"> {(method as TypescriptMethod).isStatic && - this.renderChip('Static') + this._renderChip('Static') } {(method as SolidityMethod).isConstant && - this.renderChip('Constant') + this._renderChip('Constant') } {(method as SolidityMethod).isPayable && - this.renderChip('Payable') + this._renderChip('Payable') } <AnchorTitle headerSize={HeaderSizes.H3} @@ -110,7 +110,7 @@ export class MethodBlock extends React.Component<MethodBlockProps, MethodBlockSt > ARGUMENTS </h4> - {this.renderParameterDescriptions(method.parameters)} + {this._renderParameterDescriptions(method.parameters)} </div> } {method.returnComment && @@ -129,7 +129,7 @@ export class MethodBlock extends React.Component<MethodBlockProps, MethodBlockSt </div> ); } - private renderChip(text: string) { + private _renderChip(text: string) { return ( <div className="p1 mr1" @@ -139,7 +139,7 @@ export class MethodBlock extends React.Component<MethodBlockProps, MethodBlockSt </div> ); } - private renderParameterDescriptions(parameters: Parameter[]) { + private _renderParameterDescriptions(parameters: Parameter[]) { const descriptions = _.map(parameters, parameter => { const isOptional = parameter.isOptional; return ( @@ -168,7 +168,7 @@ export class MethodBlock extends React.Component<MethodBlockProps, MethodBlockSt }); return descriptions; } - private setAnchorVisibility(shouldShowAnchor: boolean) { + private _setAnchorVisibility(shouldShowAnchor: boolean) { this.setState({ shouldShowAnchor, }); |