Skip to content

Commit

Permalink
minor cleanup after refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
denniswangcodes committed Nov 9, 2023
1 parent 33b45a7 commit d009704
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ function SignupNonProfit() {
return focusAreas.map((focusArea) => {
return (
<Chip
key={focusArea}
className={classes.chip}
label={focusArea}
sx={{ fontSize: '16px' }}
Expand Down Expand Up @@ -171,6 +172,7 @@ function SignupNonProfit() {

const handleChange = (evt: React.ChangeEvent<HTMLInputElement>): void => {
const { name, value, checked }: { name: string; value: string; checked: boolean } = evt.target;
console.log('CHECK IS HERE', checked);
setFormData((fData) => ({
...fData,
[name]: name === 'accept_terms' ? checked : value,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ type TStepOneProps = {
classes: Record<'header' | 'input' | 'label', string>;
};

export default function StepZero({ classes, formData }: TStepOneProps) {
export default function StepFive({ classes, formData }: TStepOneProps) {
console.log('FINAL FORM BRO', formData);
return (
<Box sx={{ height: '100%', minWidth: '780px' }}>
<Typography
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,13 @@ import { Box, Avatar, TextField } from '@mui/material';

type TStepOneProps = {
formData: {
organization_name: string;
organization_phone: string;
street: string;
city: string;
state: string;
zip_code: string;
employer_identification_number: string;
irs_classification: string;
bio: string;
};
classes: Record<'header' | 'input' | 'label', string>;
handleChange: (evt: React.ChangeEvent<HTMLInputElement>) => void;
};

export default function StepZero({ classes, formData, handleChange }: TStepOneProps) {
export default function StepFour({ classes, formData, handleChange }: TStepOneProps) {
return (
<Box sx={{ height: '100%', minWidth: '780px' }}>
<Typography
Expand Down Expand Up @@ -67,6 +60,7 @@ export default function StepZero({ classes, formData, handleChange }: TStepOnePr
fullWidth
placeholder="Tell us about your organization..."
name="bio"
value={formData.bio}
onChange={handleChange}
/>
</Grid>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ type TStepOneProps = {
handleChange: (evt: React.ChangeEvent<HTMLInputElement>) => void;
};

export default function StepZero({ classes, formData, emailError, handleChange }: TStepOneProps) {
export default function StepOne({ classes, formData, emailError, handleChange }: TStepOneProps) {
return (
<Box sx={{ height: '100%', minWidth: '780px' }}>
<Typography
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,13 @@ import { Box } from '@mui/material';

type TStepOneProps = {
formData: {
organization_name: string;
organization_phone: string;
street: string;
city: string;
state: string;
zip_code: string;
employer_identification_number: string;
irs_classification: string;
focusAreas: string[];
};
classes: Record<'header' | 'input', string>;
makeChips: () => any;
};

export default function StepZero({ classes, formData, makeChips }: TStepOneProps) {
export default function StepThree({ classes, formData, makeChips }: TStepOneProps) {
return (
<Box sx={{ height: '100%', minWidth: '780px' }}>
<Typography
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ type TStepOneProps = {
handleChange: (evt: React.ChangeEvent<HTMLInputElement>) => void;
};

export default function StepZero({ classes, formData, handleChange }: TStepOneProps) {
export default function StepTwo({ classes, formData, handleChange }: TStepOneProps) {
return (
<Box sx={{ height: '100%', minWidth: '780px' }}>
<Typography
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,6 @@ export default function StepZero({
</Grid>
<Grid item xs={12}>
<label>IRS Nonprofit Organization Classification</label>
{/* @ts-ignore */}
<Select
input={<OutlinedInput />}
inputProps={{ 'aria-label': 'Without label' }}
Expand Down

0 comments on commit d009704

Please sign in to comment.