Skip to content

Commit

Permalink
Wrapping span is an inline-block and bump version to 2.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
tazsingh committed Jul 10, 2017
1 parent cdc2e68 commit bf062cc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-loadable-visibility",
"version": "2.1.1",
"version": "2.2.0",
"description": "A wrapper around react-loadable for elements that are visible on the page",
"main": "lib/index.js",
"repository": "https://github.com/stratiformltd/react-loadable-visibility",
Expand Down
4 changes: 2 additions & 2 deletions src/createLoadableVisibilityComponent.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,14 +87,14 @@ function createLoadableVisibilityComponent (args, {
}

if (LoadingComponent) {
return <span ref={this.attachRef}>
return <span style={{display: 'inline-block'}} ref={this.attachRef}>
{React.createElement(LoadingComponent, {
isLoading: true,
})}
</span>
}

return <span ref={this.attachRef} />
return <span style={{display: 'inline-block'}} ref={this.attachRef} />
}
}
}
Expand Down

0 comments on commit bf062cc

Please sign in to comment.