We want a component that handles modal stack, which would allow us to:
- Properly set
z-indexfor modals - Close modals properly (e.g., on
escape)
<StackManager self={this}>
{(n, handler) => (
import {confirm, Confirm, ConfirmNode} from 'react-confirm';
// Root
<Confirm />
// Event handler
confirm('hi');
// In case you need to check if it's open or not| import React, {Component} from 'react'; | |
| export default class AssignedMembersWidget extends Component { | |
| state = { | |
| // List of users to select from | |
| selection: [], | |
| fetching: false | |
| } | |
| componentDidMount() { |
| import React, {Component} from 'react' | |
| export default class AssignedMembersWidget extends Component { | |
| state = { | |
| selection: [], | |
| fetching: false, | |
| error: '', | |
| loading: false | |
| } |
| import PropTypes from 'prop-types'; | |
| import React, { Component, cloneElement } from 'react'; | |
| import {findDOMNode} from 'react-dom'; | |
| import Transition from 'react-addons-css-transition-group'; | |
| import {Gateway} from 'react-gateway'; | |
| import Outside from 'react-click-outside'; | |
| import classnames from 'classnames'; | |
| import withinBoundaries from './withinBoundaries'; | |
| // @TODO: Animations. This became "undoable" when we added boundary checking |
| class PassContext extends React.Component { | |
| getChildContext() { | |
| return { | |
| dragDropManager: this.props.dragDropManager | |
| }; | |
| } | |
| render() { | |
| return this.props.children; | |
| } |
| import React, {Component, PropTypes as T} from 'react'; | |
| import history from 'app/history'; | |
| class SearchInput extends Component { | |
| constructor(props, context) { | |
| super(props); | |
| this.state = { | |
| input: context.location.query.search || '' | |
| } |
| import React, {Component, PropTypes as T} from 'react'; | |
| export default class Column extends Component { | |
| render() { | |
| return null; | |
| } | |
| } | |
| Column.propTypes = { | |
| heading: T.string, |
| /** | |
| * Get placeholder index, like for example in a list, through node top offset. | |
| * Used for drag-n-drops. | |
| * | |
| * @param {number} y The actual top offset | |
| * @param {number} scroll Scroll count | |
| * @return {number} | |
| */ | |
| function getPlaceholderIndex(y, scroll) { | |
| const height = 70; |