Skip to content

Commit

Permalink
page public display through context fix
Browse files Browse the repository at this point in the history
  • Loading branch information
bruno12mota committed Oct 1, 2015
1 parent 73e3e20 commit 86de3d9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/components/elements/button/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ Button.propTypes = {

Button.contextTypes = {
editing: React.PropTypes.bool.isRequired,
elementContentChange: React.PropTypes.func.isRequired,
elementContentChange: React.PropTypes.func,
selected: React.PropTypes.any
};

Expand Down
6 changes: 4 additions & 2 deletions lib/components/page/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,8 @@ export default class Page extends Component {
getChildContext () {
return {
editing: false,
renderElement: this.renderElementBind
renderElement: this.renderElementBind,
display: this.state.display
};
}

Expand Down Expand Up @@ -137,5 +138,6 @@ Page.propTypes = {

Page.childContextTypes = {
editing: React.PropTypes.bool.isRequired,
renderElement: React.PropTypes.func.isRequired
renderElement: React.PropTypes.func.isRequired,
display: React.PropTypes.string.isRequired
};

0 comments on commit 86de3d9

Please sign in to comment.