diff --git a/src/components/registration/RegistrationStep1.js b/src/components/registration/RegistrationStep1.js new file mode 100644 index 0000000..147cc5c --- /dev/null +++ b/src/components/registration/RegistrationStep1.js @@ -0,0 +1,235 @@ +import React from 'react'; +import { Label } from '../ui/label'; +import { Input } from '../ui/input'; +import { Checkbox } from '../ui/checkbox'; + +const RegistrationStep1 = ({ formData, setFormData, handleInputChange }) => { + const leadSourceOptions = [ + 'Current member', + 'Friend', + 'OutSmart Magazine', + 'Search engine (Google etc.)', + "I've known about LOAF for a long time", + 'Other' + ]; + + const handleLeadSourceChange = (source) => { + setFormData(prev => { + const sources = prev.lead_sources.includes(source) + ? prev.lead_sources.filter(s => s !== source) + : [...prev.lead_sources, source]; + return { ...prev, lead_sources: sources }; + }); + }; + + return ( +
+ {/* Personal Information */} +
+

+ Personal Information +

+ + {/* First Name, Last Name */} +
+
+ + +
+
+ + +
+
+ + {/* Phone, Date of Birth */} +
+
+ + +
+
+ + +
+
+ + {/* Address */} +
+ + +
+ + {/* City, State, Zipcode */} +
+
+ + +
+
+ + +
+
+ + +
+
+
+ + {/* How Did You Hear About Us */} +
+

+ How Did You Hear About Us? * +

+
+ {leadSourceOptions.map((source) => ( +
+ handleLeadSourceChange(source)} + data-testid={`lead-source-${source.toLowerCase().replace(/\s+/g, '-')}`} + /> + +
+ ))} +
+
+ + {/* Partner Information */} +
+

+ Partner Information (Optional) +

+ +
+
+ + +
+
+ + +
+
+ +
+
+ + setFormData(prev => ({ ...prev, partner_is_member: checked })) + } + data-testid="partner-is-member-checkbox" + /> + +
+ +
+ + setFormData(prev => ({ ...prev, partner_plan_to_become_member: checked })) + } + data-testid="partner-plan-member-checkbox" + /> + +
+
+
+
+ ); +}; + +export default RegistrationStep1; diff --git a/src/components/registration/RegistrationStep2.js b/src/components/registration/RegistrationStep2.js new file mode 100644 index 0000000..0a98d1d --- /dev/null +++ b/src/components/registration/RegistrationStep2.js @@ -0,0 +1,186 @@ +import React from 'react'; +import { Label } from '../ui/label'; +import { Input } from '../ui/input'; +import { Textarea } from '../ui/textarea'; +import { Checkbox } from '../ui/checkbox'; + +const RegistrationStep2 = ({ formData, setFormData, handleInputChange }) => { + const volunteerOptions = [ + 'Welcoming new members at events', + 'Sending out birthday cards', + 'Care Team Calls', + 'Sharing ideas for events', + 'Researching grants', + 'Applying for grants', + 'Assisting with TeatherLOAFers', + 'Assisting with ActiveLOAFers', + 'Assisting with weekday Lunch Bunch', + 'Uploading Photos to the Website', + 'Assisting with eNewsletter', + 'Other administrative task' + ]; + + const handleVolunteerChange = (option) => { + setFormData(prev => { + const interests = prev.volunteer_interests.includes(option) + ? prev.volunteer_interests.filter(i => i !== option) + : [...prev.volunteer_interests, option]; + return { ...prev, volunteer_interests: interests }; + }); + }; + + return ( +
+ {/* Newsletter Publication Preferences */} +
+

+ Newsletter Publication Preferences * +

+

+ Please check what information may be published in LOAF Newsletter +

+ +
+
+ + setFormData(prev => ({ ...prev, newsletter_publish_name: checked })) + } + /> + +
+ +
+ + setFormData(prev => ({ ...prev, newsletter_publish_photo: checked })) + } + /> + +
+ +
+ + setFormData(prev => ({ ...prev, newsletter_publish_birthday: checked })) + } + /> + +
+ +
+ + setFormData(prev => ({ ...prev, newsletter_publish_none: checked })) + } + /> + +
+
+
+ + {/* Referral */} +
+

+ Referral +

+
+ + +

+ If referred by a current member, you may skip the event attendance requirement. +

+
+
+ + {/* Volunteer Interests */} +
+

+ Volunteer Interests (Optional) +

+

+ I may at some time be interested in volunteering with LOAF in the following ways (training is provided) +

+ +
+ {volunteerOptions.map((option) => ( +
+ handleVolunteerChange(option)} + /> + +
+ ))} +
+
+ + {/* Scholarship Request */} +
+
+ + setFormData(prev => ({ ...prev, scholarship_requested: checked })) + } + /> + +
+

+ Scholarship information is kept confidential +

+ + {formData.scholarship_requested && ( +
+ +