mirror of
https://github.com/ascribe/onion.git
synced 2025-01-03 18:35:09 +01:00
reformat intendation for login modal handler
This commit is contained in:
parent
35a287b8a1
commit
d514a553f2
@ -75,7 +75,6 @@ let PropertyCollapsile = React.createClass({
|
|||||||
onClick={this.handleFocus}
|
onClick={this.handleFocus}
|
||||||
onFocus={this.handleFocus}>
|
onFocus={this.handleFocus}>
|
||||||
<input
|
<input
|
||||||
id="checkboxCollapsible"
|
|
||||||
type="checkbox"
|
type="checkbox"
|
||||||
ref="checkboxCollapsible"/>
|
ref="checkboxCollapsible"/>
|
||||||
{/* PLEASE LEAVE THE SPACE BETWEEN LABEL and this.props.label */}
|
{/* PLEASE LEAVE THE SPACE BETWEEN LABEL and this.props.label */}
|
||||||
|
@ -5,39 +5,39 @@ import React from 'react';
|
|||||||
import Button from 'react-bootstrap/lib/Button';
|
import Button from 'react-bootstrap/lib/Button';
|
||||||
import Modal from 'react-bootstrap/lib/Modal';
|
import Modal from 'react-bootstrap/lib/Modal';
|
||||||
import OverlayMixin from 'react-bootstrap/lib/OverlayMixin';
|
import OverlayMixin from 'react-bootstrap/lib/OverlayMixin';
|
||||||
import { getLangText } from '../utils/lang_utils.js'
|
import { getLangText } from '../utils/lang_utils.js';
|
||||||
|
|
||||||
let LoginModalHandler = React.createClass({
|
let LoginModalHandler = React.createClass({
|
||||||
mixins: [OverlayMixin],
|
mixins: [OverlayMixin],
|
||||||
|
|
||||||
getInitialState() {
|
getInitialState() {
|
||||||
return {
|
return {
|
||||||
isModalOpen: true
|
isModalOpen: true
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
||||||
handleToggle() {
|
handleToggle() {
|
||||||
this.setState({
|
this.setState({
|
||||||
isModalOpen: !this.state.isModalOpen
|
isModalOpen: !this.state.isModalOpen
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
if (!this.state.isModalOpen || !(this.props.query.login === '')) {
|
if(!this.state.isModalOpen || !(this.props.query.login === '')) {
|
||||||
return <span/>;
|
return <span/>;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<Modal title='Modal heading' onRequestHide={this.handleToggle}>
|
||||||
|
<div className='modal-body'>
|
||||||
|
This modal is controlled by our custom trigger component.
|
||||||
|
</div>
|
||||||
|
<div className='modal-footer'>
|
||||||
|
<Button onClick={this.handleToggle}>{getLangText('Close')}</Button>
|
||||||
|
</div>
|
||||||
|
</Modal>
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
|
||||||
<Modal title='Modal heading' onRequestHide={this.handleToggle}>
|
|
||||||
<div className='modal-body'>
|
|
||||||
This modal is controlled by our custom trigger component.
|
|
||||||
</div>
|
|
||||||
<div className='modal-footer'>
|
|
||||||
<Button onClick={this.handleToggle}>{getLangText('Close')}</Button>
|
|
||||||
</div>
|
|
||||||
</Modal>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
|
||||||
export default LoginModalHandler;
|
export default LoginModalHandler;
|
Loading…
Reference in New Issue
Block a user