test
bosn 6 years ago
parent 924c000bcd
commit 19ed4040ff

@ -5,8 +5,8 @@
"main": "app.js",
"scripts": {
"dev": "npm run start",
"build-css": "node-sass src/ -o build/",
"watch-css": "npm run build-css && node-sass src/ -o build/ --watch --recursive",
"build-css": "node-sass src/ -o src/",
"watch-css": "npm run build-css && node-sass src/ -o src/ --watch --recursive",
"start-js": "react-scripts start",
"start": "npm-run-all -p watch-css start-js --max-old-space-size=4096",
"build": "npm run lint && npm run build-css && react-scripts build",

@ -128,6 +128,7 @@ class InterfaceEditor extends Component<
bodyOption={this.state.summaryState.bodyOption}
requestParamsType={this.state.summaryState.requestParamsType}
handleChangeProperty={this.handleChangeProperty}
handleDeleteMemoryProperty={this.handleDeleteMemoryProperty}
/>
<ResponsePropertyList
properties={this.state.properties}
@ -136,6 +137,7 @@ class InterfaceEditor extends Component<
mod={mod}
itf={this.state.itf}
handleChangeProperty={this.handleChangeProperty}
handleDeleteMemoryProperty={this.handleDeleteMemoryProperty}
/>
<RModal
when={this.state.moveInterfaceDialogOpen}

@ -43,7 +43,6 @@ type InterfaceSummaryState = {
}
class InterfaceSummary extends Component<InterfaceSummaryProps, InterfaceSummaryState> {
static contextTypes = {
onAddForeignRoomCase: PropTypes.func.isRequired,
onDeleteInterface: PropTypes.func.isRequired,
}
constructor(props: any) {
@ -264,17 +263,6 @@ class InterfaceSummary extends Component<InterfaceSummaryProps, InterfaceSummary
}
}
handleUpdate = () => { /** empty */ }
createCase = (e: any, repositoryId: any, interfaceId: any, name: any) => {
e.preventDefault()
this.setState({ name })
const { onAddForeignRoomCase } = this.context
onAddForeignRoomCase({
id: repositoryId,
itf: interfaceId,
name,
})
// itf.repositoryId
}
}
const mapStateToProps = (state: RootState) => ({
room: state.foreign,

@ -295,7 +295,7 @@ class PropertyList extends Component<any, any> {
}
handleDeleteMemoryProperty = (e: any, property: any) => {
e.preventDefault()
const { handleDeleteMemoryProperty } = this.context
const { handleDeleteMemoryProperty } = this.props
handleDeleteMemoryProperty(property)
}
handleSortProperties = (_: any, sortable: any) => {

Loading…
Cancel
Save