@@ -44,7 +44,6 @@ const volunteerPeriodsInDays: $ReadOnlyArray<SelectOption> = [
4444 ["6 months - 1 year", 365],
4545].map(textDaysPair => ( { label : textDaysPair [ 0 ] , value : textDaysPair [ 1 ] } ) ) ;
4646
47- const OtherRoleOption : SelectOption = { label : "Other" , value : "Other" } ;
4847
4948/**
5049 * Modal for volunteering to join a project
@@ -80,7 +79,6 @@ class ProjectVolunteerModal extends React.PureComponent<Props, State> {
8079 value : position . roleTag . tag_name ,
8180 label : tagOptionDisplay ( position . roleTag ) ,
8281 } ) )
83- . concat ( OtherRoleOption )
8482 ) ;
8583
8684 let state : State = {
@@ -187,12 +185,6 @@ class ProjectVolunteerModal extends React.PureComponent<Props, State> {
187185 { ! _ . isEmpty ( this . props . positions )
188186 ? this . _renderExistingPositionDropdown ( )
189187 : null }
190- { _ . isEmpty ( this . props . positions ) ||
191- ( this . state . existingPositionOption &&
192- this . state . existingPositionOption . value ===
193- OtherRoleOption . value )
194- ? this . _renderOtherRoleDropdown ( )
195- : null }
196188 < Form . Label >
197189 How long do you expect to be able to contribute to this
198190 project?
@@ -242,21 +234,12 @@ class ProjectVolunteerModal extends React.PureComponent<Props, State> {
242234 ) ;
243235 }
244236
245- _selectedExistingPositionTag ( ) : ?string {
246- return this . state . existingPositionOption &&
247- this . state . existingPositionOption . value !== OtherRoleOption . value
237+ _selectedTag ( ) : ?string {
238+ return this . state . existingPositionOption
248239 ? this . state . existingPositionOption . value
249240 : null ;
250241 }
251242
252- _selectedOtherRoleTag ( ) : ?string {
253- return this . state . roleTag && this . state . roleTag . tag_name ;
254- }
255-
256- _selectedTag ( ) : ?string {
257- return this . _selectedExistingPositionTag ( ) || this . _selectedOtherRoleTag ( ) ;
258- }
259-
260243 _renderExistingPositionDropdown ( ) : React$Node {
261244 return (
262245 < div className = "form-group" >
@@ -276,21 +259,6 @@ class ProjectVolunteerModal extends React.PureComponent<Props, State> {
276259 ) ;
277260 }
278261
279- _renderOtherRoleDropdown ( ) : React$Node {
280- return (
281- < div className = "form-group" >
282- < label htmlFor = "project_technologies" > Role You are Applying For</ label >
283- < TagSelector
284- value = { [ this . state . roleTag ] }
285- category = { TagCategory . ROLE }
286- allowMultiSelect = { false }
287- isClearable = { false }
288- onSelection = { this . onRoleChange . bind ( this ) }
289- />
290- </ div >
291- ) ;
292- }
293-
294262 _renderVolunteerPeriodDropdown ( ) : React$Node {
295263 return (
296264 < Select
0 commit comments