import * as React from "react"; import { BaseConfigureBuildModalProps } from "./view.pc"; import { Dispatch } from "redux"; import { configureBuildModalXClicked, configureBuildModalBackgroundClicked, openAppScriptConfigChanged, buildScriptConfigChanged } from "../../actions"; import { ProjectInfo } from "../../state"; export type Props = { projectInfo: ProjectInfo; dispatch: Dispatch; }; export default (Base: React.ComponentClass) => class ConfigureBuildController extends React.PureComponent { onCloseButtonClick = () => { this.props.dispatch(configureBuildModalXClicked()); }; onBackgroundClick = () => { this.props.dispatch(configureBuildModalBackgroundClicked()); }; onOpenCommandChangeComplete = (value: string) => { this.props.dispatch(openAppScriptConfigChanged(value)); }; onBuildCommandChangeComplete = (value: string) => { this.props.dispatch(buildScriptConfigChanged(value)); }; render() { const { onCloseButtonClick, onBackgroundClick, onBuildCommandChangeComplete, onOpenCommandChangeComplete } = this; const { projectInfo, dispatch, ...rest } = this.props; return ( ); } };