A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/markerikson/project-minimek/commit/bee1c966ea9cfb67448c79be4039891fe9921fee below:

Use FormEditWrapper to buffer changes from Pilot inputs · markerikson/project-minimek@bee1c96 · GitHub

@@ -4,6 +4,8 @@ import {Form, Dropdown, Grid, Button} from "semantic-ui-react";

4 4 5 5

import schema from "app/schema";

6 6 7 +

import FormEditWrapper from "common/components/FormEditWrapper";

8 + 7 9

import {selectCurrentPilot, selectIsEditingPilot} from "../pilotsSelectors";

8 10 9 11

import {

@@ -103,16 +105,21 @@ export class PilotDetails extends Component {

103 105 104 106

return (

105 107

<Form size="large">

106 -

<Form.Field

107 -

name="name"

108 -

label="Name"

109 -

width={16}

110 -

placeholder="Name"

111 -

value={name}

112 -

disabled={!canStopEditing}

108 +

<FormEditWrapper

109 +

singleValue={true}

110 +

value={ {name} }

113 111

onChange={this.onInputChanged}

114 -

control="input"

115 -

/>

112 +

passIsEditing={false}

113 +

>

114 +

<Form.Field

115 +

name="name"

116 +

label="Name"

117 +

width={16}

118 +

placeholder="Name"

119 +

disabled={!canStopEditing}

120 +

control="input"

121 +

/>

122 +

</FormEditWrapper>

116 123

<Form.Field

117 124

name="rank"

118 125

label="Rank"

@@ -125,16 +132,21 @@ export class PilotDetails extends Component {

125 132

onChange={this.onDropdownChanged}

126 133

disabled={!canStopEditing}

127 134

/>

128 -

<Form.Field

129 -

name="age"

130 -

width={6}

131 -

label="Age"

132 -

placeholder="Age"

133 -

control="input"

134 -

value={age}

135 +

<FormEditWrapper

136 +

singleValue={true}

137 +

value={ {age} }

135 138

onChange={this.onInputChanged}

136 -

disabled={!canStopEditing}

137 -

/>

139 +

passIsEditing={false}

140 +

>

141 +

<Form.Field

142 +

name="age"

143 +

width={6}

144 +

label="Age"

145 +

placeholder="Age"

146 +

control="input"

147 +

disabled={!canStopEditing}

148 +

/>

149 +

</FormEditWrapper>

138 150

<Form.Field

139 151

name="gunnery"

140 152

label="Gunnery"


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4