import React from 'react'; import PropTypes from 'prop-types'; import ls from './Window.less' import Fa from "./Fa"; export default class Window extends React.Component { constructor({initWidth, initLeft, initTop}) { super(); this.state = { width: initWidth, left: initLeft, top: initTop } } render() { let {children, title, minimizable, onClose} = this.props; return
{title.toUpperCase()}
{minimizable && _}
{children}
} getStyle() { return { width: this.state.width, height: this.state.height, left: this.state.left, top: this.state.top, zIndex: 1 } } } Window.defaultProps = { minimizable: false, };